Skip to content

Releases: ampproject/amp-wp

1.2 Release Candidate 1

14 Jun 18:39
0efb9cf
Compare
Choose a tag to compare
Pre-release

This is the first release candidate of the AMP plugin with AMP Stories editor. For an overview of the editor for AMP Stories, please see the AMP Stories Experimental docs.

For AMP Stories, there have been 36+ pull requests merged since 1.2-beta2. Some changes to highlight include:

  • AMP Stories can now be used exclusively, without needing to also use AMP for the rest of the website. The AMP settings screen now has checkboxes for the “Website” and “Stories” experiences, allowing you to pick which are appropriate for your site. The Stories experience is marked as BETA because this feature is new and much more is planned than is included in this MVP first release, not mentioning improvements to come from user feedback. See #2470, #2550.
  • Allow dragging of entire blocks, eliminating the drag handle. See #2389.
  • Add story page templates for fandom vertical. See #2479.
  • Improve "Resolve Block" flow when block validation errors occur. See #2484.
  • Add a new image size that is optimized for the story page height, eliminating the use of the oversized full image, and thus saving bandwidth. Add warning when adding a video to a page background when it is larger than 1MB per second. See #2509.
  • Fix ability to duplicate story pages. See #2540.
  • Let newly-added blank pages omit the initial Text block that is present when starting new stories. See #2633.

👉 Please note that old stories authored in previous releases will likely appear with block validation errors in the editor. This is because the block format has been in flux during development, but once 1.2 stable is released then backwards compatibility for old block formats will be maintained.

For general AMP changes, there have been 15+ pull requests merged since 1.2-beta2. Some changes to highlight include:

  • The “Native” mode has been renamed as “Standard”. This is the AMP-first website experience, where the “Transitional” mode is paired AMP scheme that can be used on the road to going AMP-first. The Reader mode remains as is with its classic templates. See #2507, #2550.
  • Always allow switching between Standard, Transitional, and Reader modes even on sites that are defined with amp theme support; the default mode will correspond to what the theme defines (with add_theme_support('amp') defaulting to Standard, and add_theme_support('amp', ['paired' => true]) defaulting to Transitional), but the user can always override based on their site's needs. See #2312, #2550, #2622.
  • Suppress admin bar from being shown during validation requests. See #2500.
  • Always perform CSS tree shaking, regardless of total size. This removes the tree shaking checkbox from the admin screen. See #2508. See #2536.
  • Update AMP validator spec to v1905292322390. See #2537.
  • Prevent sending response through post-processor if Content-Type is not text/html. This fixes integration with plugins that generate non-HTML templates, like XML sitemaps. See #2536.
  • Fix layout of Gallery as amp-carousel. See #2505.

Please review the v1.2 milestone for what else to expect in the subsequent stable release. See also diff 1.2-beta2...1.2-RC1.

To test AMP Stories, you will need the latest version of the Gutenberg plugin installed (v5.8+ specifically), since the AMP Stories editor uses bleeding-edge features of WordPress's block editor which are not yet in a WordPress core release. You can then install the amp.zip build below by uploading it in the WordPress admin. Once active, enable the AMP Stories feature from the AMP admin settings screen.

To install as a Git submodule, consider 1.2-RC1-built.

The 1.2 stable release is due by June 20th, 2019.

1.2-beta2: Further refinements to AMP Stories editor and much more

04 Jun 16:59
4530a2c
Compare
Choose a tag to compare

This is the second beta of the AMP plugin with AMP Stories editor. For an overview of the experimental editor for AMP Stories, please see the AMP Stories Experimental docs.

For AMP Stories, there have been 29+ pull requests merged since 1.2-beta1. Some changes to highlight include:

  • Add new filter for adding support for <amp-story-auto-ads>. See #2492.
  • Add amp_story_supports_landscape filter for initial opt-in to landscape support for stories. See #2468.
  • Add Tag and Category taxonomies to Stories. See #2469.
  • Improve behavior for editing selected blocks. See #2459.
  • Improve template insertion and add a new template with rotated text. See #2343, #2481.
  • Add color options to Call-to-Action block. See #2478.
  • Greatly improve font size calculation and resizing of blocks. See #2446, #2458, #2416, #2385.

For general AMP changes, there have been 33+ pull requests merged since 1.2-beta1. Some changes to highlight include:

  • Add support for remaining core themes, including Twenty Ten, Twenty Eleven, Twenty Twelve, Twenty Thirteen, and Twenty Fourteen. See #2476, #2407, #1873.
  • Introduce stylesheet prioritization when determining which to concatenate. This is a big one as it prevents unimportant stylesheets (like the admin bar or print styles) from being included while excluding the all important theme styles. Now the style.css from the theme should always be included (unless after tree shaking it is more than 50KB). See #2346, #2405.
  • Improve form handling when submission handler does no redirection. See #2425. Please also read the Handling Form Submissions playbook.
  • Improve validation of the nodes in the head. See #2420.
  • Enforce the unique constraints from the validator. See #2451.

Please review the v1.2 milestone for what else to expect in subsequent pre-releases and the next stable release.

To test AMP Stories, you will need the latest version of the Gutenberg plugin installed, since the AMP Stories editor uses bleeding-edge features of WordPress's block editor which are not yet in a WordPress core release. You can then install the amp.zip build below by uploading it in the WordPress admin. Once active, enable the AMP Stories feature from the AMP admin settings screen.

To install as a Git submodule, consider 1.2-beta2-built.

The 1.2 stable release is due by June 20th, 2019.

1.1.3

29 May 16:27
d34833d
Compare
Choose a tag to compare

Releasing fix which missed 1.1.2:

  • Exempt curl_multi_* functions from being required dependencies due to a FasterImage update which has support for falling-back to synchronous mode. See #2423, willwashburn/fasterimage#18, #2422. Props westonruter, willwashburn, mehrdadabed.

See 1.1.3 milestone and diff of changes from 1.1.2.

To install as a Git submodule, consider https://github.com/ampproject/amp-wp/releases/tag/1.1.3-built

1.1.2

28 May 23:15
ac06994
Compare
Choose a tag to compare
  • Improve checking for required PHP dependencies before initializing plugin, checking for required extensions, functions, and classes; improve how dependency errors are communicated. See #2183, #2190, #2319, #2208, #2423. Props westonruter, swissspidy.
  • Exempt curl_multi_* functions from being required dependencies due to a FasterImage update which has support for falling-back to synchronous mode. See #2423, willwashburn/fasterimage#18, #2422. Props westonruter, willwashburn, mehrdadabed. (Missed release. See v1.1.3.)
  • Prevent sending Server-Timing headers by default; add amp_response_caching_enabled filter for controlling response caching, to uncouple from WP_DEBUG. See #2268. Props carlalexander, westonruter, jerclarke.
  • Inject width/height attributes into video elements from the Video block where previously they were unavailable in the video shortcode. See #2207. Props westonruter.
  • Improve handling of layout for images: remove display:inline from style attribute to prevent intrinsic images from failing to render and better support the fixed-height layout and other layouts that don't require dimensions. See #1803, #2209. Props westonruter, randomascii.
  • Add "View AMP" link to admin bar on non-AMP page in Reader mode. See #2227, #2203. Props westonruter, amedina.
  • Fix CSS tree shaking when class names contain escaped non-alphanumeric characters. See #2260, #2259. Props westonruter, octoper.
  • Prevent Unicode character escape sequences from showing up in comment forms. See #2293, #2286. Props westonruter, vralle.
  • Improve compatibility with Gutenberg 5.7. See #2308. Props westonruter.
  • Update other Composer dependencies. See #2356, #2387. Props renovate-bot.

See 1.1.2 milestone and diff of changes from 1.1.1.

To install as a Git submodule, consider https://github.com/ampproject/amp-wp/releases/tag/1.1.2-built

1.2-beta1: Featuring the AMP Stories Editor

22 May 00:05
e3d25e9
Compare
Choose a tag to compare

This is the first pre-release that merges the AMP Stories functionality into the main develop branch. For an overview of the experimental editor for AMP Stories, please see the AMP Stories Experimental docs.

While the vast majority of closed issues and merged pull requests in this release are for AMP Stories (273+), there are also a couple dozen not related to AMP Stories. A few of note:

Please review the v1.2 milestone for what else to expect in subsequent pre-releases and the next stable release.

To test AMP Stories, you will need the latest version of the Gutenberg plugin installed, since the AMP Stories editor uses bleeding-edge features of WordPress's block editor which are not yet in a WordPress core release. You can then install the amp.zip build below by uploading it in the WordPress admin. Once active, enable the AMP Stories feature from the AMP admin settings screen.

To install as a Git submodule, consider https://github.com/ampproject/amp-wp/releases/tag/1.2-beta1-built

1.1.1

23 Apr 16:58
885e488
Compare
Choose a tag to compare
  • Fix first_child_tag_name_oneof constraint to only apply if first child exists. This prevents sanitizer from erroneously removing amp-state[src] elements. Props westonruter. See #2152.
  • Prevent wp_targeted_link_rel() from corrupting JSON in amp_validation_error's term_description. See #2158. Props westonruter.
  • Improve i18n strings and placeholders. See #2140. Props swissspidy.
  • Fix link to outdated wiki page for AMP analytics. See #2141. Props swissspidy.

See 1.1.1 milestone and diff of changes from 1.1.0.

1.2-alpha1: AMP Stories Editor Preview Release

18 Apr 08:21
e2a87b8
Compare
Choose a tag to compare

For an overview of the experimental editor for AMP Stories, please see: https://github.com/ampproject/amp-wp/wiki/AMP-Stories-Experimental

Note that you will need the latest version of the Gutenberg plugin installed, since the AMP Stories editor uses bleeding-edge features of WordPress's block editor which are not yet in a WordPress core release.

To test, please install the amp.zip build below by uploading it in the WordPress admin. Once active, enable the AMP Stories feature from the AMP admin settings screen.

1.1.0

16 Apr 11:08
70934bb
Compare
Choose a tag to compare

Please read the 1.1 release post.

For the full list of issues and pull requests in this release, please see the 1.1 milestone.

Headline Changes

  • Fixed AMP compatibility with Twenty Nineteen theme (via tree shaking improvements, see CSS Processing below).
  • Introduce theme support flags to streamline implementation of nav menu mobile toggle and submenu dropdowns. See #1745, #1986. Props felixarntz.
  • Definitively fix issues with images in AMP not visually matching non-AMP version (e.g. with stretching or oversizing). See #2036. Props westonruter.
  • Add support for service worker installed via PWA feature plugin; extend service worker to cache AMP CDN assets, cache Google Fonts, and cache images (following AMP by Example). See #1261, #2070, #2074, #2134. Props westonruter, felixarntz.
  • Rebrand Paired mode as Transitional mode; update descriptions for Native and Transitional modes. See #2034, #2089, #2116, #2135. Props felixarntz, westonruter, albertomedina.
  • Rebrand Classic mode as Reader mode; add optional “Exit Reader Mode” link to header. See #2034. Props felixarntz, westonruter.

Conversion Sanitizers and Embed Handlers

  • Expand and fix conversion of Facebook embeds. See #1956. Props westonruter.
  • Enqueue component scripts for attributes that require extensions (e.g. amp-lightbox-gallery for amp-img[lightbox]). See #1855. Props westonruter.
  • Add noscript fallbacks for amp-img, amp-audio, amp-video, and amp-iframe (containing the original non-AMP elements); improve audio conversion to amp-audio; add AMP [fallback] for amp-audio/amp-video. See #1861, #1913. Props westonruter.
  • Prevent doubling of validation errors for noscript fallbacks; introduce add_noscript_fallback sanitizer param to control whether fallbacks are added; prevent using img as noscript if it uses the HTTP protocol. See #2131. Props westonruter, felixarntz.
  • Introduce filter to normalize image URLs used for dimension extraction. See #1960. Props alexrah, westonruter.
  • Make element IDs unique in cloned elements for sticky nav menu in Twenty Seventeen. See #2009. Props westonruter.
  • Add support for Archives widget block when displaying as dropdown; fix display of Categories block. See #2018. Props westonruter.
  • Prevent over-eager removal of parents of invalid elements by considering attributes. See #2051. Props westonruter.
  • Eliminate comments walker in favor of comments sanitizer. See #1878. Props swissspidy, westonruter.
  • Prevent placeholder blocks for audio and image from causing validation errors. See #2090. Props westonruter.

Theme Support

  • Fix ambiguity in matching templates by incorporating template priority order from core. See #1938. Props westonruter.
  • Use same regex as WordPress for template hierarchy filters. See #1876. Props swissspidy.
  • Add prototype service worker streaming for AMP documents. See #1503. Props westonruter.
  • Prevent serving AMP for post embeds. See #1934. Props westonruter.

Reader Mode

  • Add CSS style to support RTL language in frontend. See #1674. Props mostafaabd.
  • Remove Merriweather font in favor of Georgia, eliminating external stylesheet to improve performance. See #1748. Props westonruter.
  • Remove “Powered by WordPress” in classic footer template. See #1837. Props westonruter.

URLs

  • Use more permanent redirects for AMP URLs. See #1857. Props westonruter.
  • Add ETag to post-processor response with support for 304 status. See #1481. Props westonruter.
  • Add double quotes around the ETag header value; recognize multiple quoted ETags in If-None-Match header. See #1829. Props ataylorme, westonruter.
  • Use of use home_url() instead of site_url() where applicable. See #1816. Props felixarntz, westonruter.
  • Avoid infinite URL space under /amp/ endpoint in classic mode. See #1846. Props westonruter.

Validation and Compatibility Tool

  • Add source information for Embeds; discontinue extracting iframe from paragraphs. See #1468. Props westonruter.
  • Add Must-Use Plugins source in summaries. See #1469. Props westonruter.
  • Improve AMP validation performance by not needlessly doing output buffering on filter calls. See #1795. Props westonruter, felixarntz.
  • Improve validation of children. See #1860. Props miina, westonruter.

CSS Processing

  • Add attribute-based CSS selector tree shaking. See #2080. Props westonruter.
  • Expand externalization of data: URLs in @font-face rules, which further reduces total CSS in Twenty Nineteen. See #2079. Props westonruter.
  • Fix tree shaking for dynamically-added class names. See #1959. Props westonruter.
  • Add tree shaking for :lang() selectors. See #1901. Props westonruter.
  • Prevent tree-shaking class names for amp-geo when component on page. See #2017. Props westonruter.
  • Prevent erroneously converting form to amp-form in CSS selectors. See #2130. Props westonruter.
  • Strip old-school CDATA and HTML comments from XHTML-compatible style elements. See #1844. Props westonruter.
  • Suppress style[amp-custom] manifest HTML comment when not WP_DEBUG. See #1843. Props westonruter, swissspidy.
  • Exclude duplicate stylesheets from amp-custom style manifest. See #1858. Props westonruter.
  • Fall-back to HTTP request whenever stylesheet is not found locally or a dynamic resource. See #1852. Props westonruter, felixarntz.
  • Improve grammar in description of tree shaking option. See #1802. Props danielmcclure.

Infrastructure, Technical Debt, and Code Cleanup

  • Update coding standards and fix all violations. See #1810. Props felixarntz, westonruter.
  • Check if WP_CLI is defined and true before registering a WP-CLI command. See #1746. Props srtfisher.
  • Work around edge case combination of PHP 7.2+ with old ICU version. See #1987. Props swissspidy.
  • Fix tests in environments where custom content directory is set and WP_HOME/WP_SITEURL is defined. See #1848. Props westonruter, felixarntz.
  • Instruct wp-dev-lib to check all files not just those in patch. See #1822. Props westonruter.
  • Drop unnecessary sanitize_hex_color() polyfill. See #1817. Props felixarntz.
  • Remove unused $args variable. See #1835. Props paulschreiber.
  • Use constants instead of strings in AMP_Post_Meta_Box::sanitize_status(). See #1805. Props paulschreiber.
  • Add required PHPUnit testsuite name. See #1875. Props swissspidy.
  • Add Security Disclosures section from amphtml project to contributing.md. See #1854. Props westonruter.
  • Run tests using PHP 7.3 on Travis CI. See #1818. Props swissspidy.
  • Update install-wp-tests.sh. See #2027. Props swissspidy.
  • Discontinue showing theme support admin pointer in 1.1. See #2059. Props westonruter.

I18N

  • Improve I18N strings. See #1866. Props swissspidy.
  • Improve readability of non-ASCII characters in Schema.org metadata by using JSON_UNESCAPED_UNICODE. See #1997. Props ziodave.
  • Consolidate translator comments for forgotten URLs string. See #1819. Props swissspidy.
  • Remove changelog from readme to facilitate translation. See https://github.com/ampp...
Read more

1.1-RC1

15 Apr 13:47
b6f32b3
Compare
Choose a tag to compare
1.1-RC1 Pre-release
Pre-release

Changes since 1.1-beta2:

  • Prevent doubling of validation errors for noscript fallbacks; introduce add_noscript_fallback sanitizer param to control whether fallbacks are added; prevent using img as noscript if it uses the HTTP protocol. See #2131. Props westonruter, felixarntz.
  • Prevent erroneously converting form to amp-form in CSS selectors. See #2130. Props westonruter.
  • Update amphtml to v1904021746450, including experimental support for amp-script. See #2129. Props westonruter.

For a categorized breakdown/changelog of all pull requests, please see the drafted release notes for the final 1.1 release. See the v1.1 milestone for all issues and pull requests in this release.

Please test! Download the amp.zip attached to this pre-release and install it into your WordPress admin. If you have an existing version of the AMP plugin installed, you'll need to deactivate/uninstall the old one before you'll be able to upload and activate this new one. Alternatively, you can extract the contents of amp.zip into wp-content/plugins/amp. Once installed, you should see the plugin version as 1.1-RC1-20190415T133223Z-b6f32b3b.

If you find a bug, please review current issues or file a new one.

The 1.1 final release is due out by AMP Conf 2019 (April 17).

1.1-beta2

13 Apr 00:04
b9683cd
Compare
Choose a tag to compare
1.1-beta2 Pre-release
Pre-release

Changes since 1.1-beta1:

  • Add attribute-based CSS selector tree shaking. See #2080. Props westonruter.
  • Expand externalization of data: URLs in @font-face rules, which further reduces total CSS in Twenty Nineteen. See #2079. Props westonruter.
  • Prevent placeholder blocks for audio and image from causing validation errors. See #2090. Props westonruter.
  • Improve descriptions for Transitional and Native modes. See #2089, #2116. Props albertomedina, westonruter.
  • Update codebase for WPCS 2.1. See #2108. Props swisspidy.

For a categorized breakdown/changelog of all pull requests, please see the drafted release notes for the final 1.1 release. See the v1.1 milestone for all issues and pull requests in this release.

Please test! Download the amp.zip attached to this pre-release and install it into your WordPress admin. If you have an existing version of the AMP plugin installed, you'll need to deactivate/uninstall the old one before you'll be able to upload and activate this new one. Alternatively, you can extract the contents of amp.zip into wp-content/plugins/amp. Once installed, you should see the plugin version as 1.1-beta2-20190412T230712Z-b9683cdd.

If you find a bug, please review current issues or file a new one.

The 1.1 final release is due out by AMP Conf 2019 (April 17).