Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VideoPress: Disable re-usable block feature for video blocks #31186

Merged
merged 2 commits into from
Mar 4, 2019

Conversation

mmtr
Copy link
Member

@mmtr mmtr commented Mar 4, 2019

Changes proposed in this Pull Request

This PR prevents to add the VideoPress-enhanced video blocks to list of the reusable blocks in order to avoid the issue described in #31178 (player not rendered on the published view).

This is a temporary fix for the Jetpack 7.1 release and we should properly support reusable blocks in a follow-up PR.

Testing instructions

  • Select an environment:
    • Gutenlypso.
      • Start Calypso with Calypsoify Iframe disabled: DISABLE_FEATURES=calypsoify/iframe npm start.
      • Go to /block-editor.
      • Select a site under a premium/business plan.
    • Jetpack.
      • Create a new JN site using the extensions from this branch.
      • Connect to WP.com using a premium/business subscription.
      • Go to Settings → Jetpack Constants in the site’s wp-admin and set JETPACK_BETA_BLOCKS to true.
      • Go to Jetpack → Settings and activate the VideoPress module (by enabling the "Enable high-speed, ad-free video player" option).
      • Go to Posts → New.
  • Insert a video block.
  • Make sure you cannot add it to Reusable Blocks.

screen shot 2019-03-04 at 15 29 51

Fixes #31178

@mmtr mmtr added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. [Goal] Gutenberg Working towards full integration with Gutenberg [Feature] VideoPress A feature to help you upload and insert videos on your site. labels Mar 4, 2019
@matticbot
Copy link
Contributor

@mmtr mmtr self-assigned this Mar 4, 2019
@mmtr mmtr requested review from a team March 4, 2019 14:34
@mmtr mmtr added this to the Jetpack: 7.1 milestone Mar 4, 2019
Copy link
Member

@simison simison left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tests well!

Tested:

  • Created a regular video and regular video in a reusable block without VideoPress enabled, then reloaded that page in the editor with VideoPress enabled from settings and this branch. Renders just like before — reusable block is untouched and I cannot anymore turn previous regular video block into a reusable block.
  • Tested same with VideoPress enabled blocks; VideoPress blocks turned into reusable blocks before this PR will remain untouched.
  • Cannot make video-blocks anymore reusable. 👍

Used Jetpack-Docker / wp-admin.

@mmtr mmtr merged commit e389c75 into master Mar 4, 2019
@mmtr mmtr deleted the update/videopress-gutenberg-disable-reusable branch March 4, 2019 15:05
@mmtr
Copy link
Member Author

mmtr commented Mar 4, 2019

Thanks for the review @simison!

@matticbot matticbot removed the [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. label Mar 4, 2019
@jeherve
Copy link
Member

jeherve commented Mar 4, 2019

Cherry-picked to the release branch in 8837523

jeherve added a commit that referenced this pull request Mar 5, 2019
* Implement image filters for tiled gallery block

* Jetpack Blocks: move a new set of blocks in production

See https://github.com/Automattic/jetpack/milestone/119

* Jetpack Blocks: tag new version of the blocks for the 7.1 release

* Contact Info: Fix/contact info fix sidebar (#31042)

* Contact Info Block: Remove the Sidebar for google maps link

* bug fix: use className instead of class

* Additional keywords for the Slideshow block. (#31038)

* Improvement to Autoplay delay label. (#31039)

* Slideshow: Add New Uploads At End (#31046)

* Add newly uploaded images to the end of the slideshow. Jump to the position of the new upload so user sees upload status.

* Alternate approach using comparison of image array length in componentDidUpdate to determine position.

* Contact Info: Add the ability to add the buisness hours block to the contact info (#31056)

* Contact Info Block: Improve email validation (#31033)

* Contact Info Block: Improve the email validation

By using the emailValidator that is use in more places we can provide better matching and of email addresses.

* bug fix. take into account any number of punctuation.

* Business hours: show 'closed' when data is incomplete for a given interval (#31083)

* Business hours
If data is incomplete for a given interval, display 'Closed' or null;

* adjusting logic - thanks @lezama

* further improved time validation logic

* Contact Info Block: Split phone numbers into prefix and phone number (#31026)

* Split phone numbers into prefix and phone number

This allows us to be not so strict with what a phone number is and still offer a way to prefix. things.

* Fix typos and simplify selection of first character.

* WordAds block: Update icon (#31106)

* Business Hours: Update editor styles for consistency with UI elements

* Business Hours Block: add search keywords (#31090)

* Business Hours Block:

add search keywords

* updating terms after feedback from co-workers

* Related Posts: update the message displayed when no related posts (#31126)

Discussion: p8oabR-kb-p2 #comment-2590

* Tiled Gallery: Remove i18n strings in save (#31119)

* Add deprecated declaration based on #30724

* Remove localized aria-label from save

* Form block: fix typo (#31139)

* Mailchimp: Placeholder Buttons (#31089)

* Rework of button UI hierarchy in unconnected placeholder.

* Change to Connection button styling.

* Add isBorderless to Re-check button.

* Revised button attributes for placeholder.

* Further revisions to button styles.

* Mailchimp: Form Element Spacing (#31142)

* Standardized form element spacing in the editor.

* Use rem for form element spacing.

* Business hours block: use blockIcon in placeholder (#31143)

* Fix: business hours validation (#31122)

* When saving a business hours block, don't save any data that hinges on localization.

* defaultLocalization should not be translated.

* After a conversation with @sirreal - we've decided on this approach:

drop the save component altogether, because we use server-side rendering for the block
have a <DayEdit /> and <DayPreview /> component for client side rendering, which are only rendered once we've fetched localization

* Default days should remain localized.

* Tiled gallery block: camel case product name (#31184)

* VideoPress: Disable re-usable block feature for video blocks (#31186)

* Change contact info icon to account box (#31190)

* Deselect image on filter change

* Update filter icons

via #30853 (comment)

* Slideshow: Replace Buttons With A Tags (#31175)

* Replace Slideshow buttons with A tags. Hide inner text in links. Disable ESLint rule related to anchors without HREFs.

* Remove text from PREV/NEXT/PAUSE buttons, to avoid block invalidation after language change.

* Reposition bullets element below buttons (no visible change).

* Remove localization of text for initial autoplay Pause button state. All a11y label localization will be addressed as a later block of work.

* Removing unneeded CSS now that buttons have no inner content.

* Fix WordAds block alignment

Remove content floating by removing conflicting align{left,right,center}
classes.

Gutenberg styling handles left/right alignment.

Apply center alignment based on data-align attributes.

* Jetpack Blocks: update blocks for the final 7.1 release.


Co-authored-by: Jon Surrell <jon.surrell@automattic.com>
Co-authored-by: Enej Bajgoric <enej.bajgoric@gmail.com>
Co-authored-by: Jefferson Rabb <j.max.rabb@gmail.com>
Co-authored-by: Rocco Tripaldi <tripaldir@gmail.com>
Co-authored-by: Thomas Guillot <thomasguillot@users.noreply.github.com>
Co-authored-by: Mikael Korpela <mikael@ihminen.org>
Co-authored-by: Miguel Torres <miguelmariatorresrojas@gmail.com>
Co-authored-by: Michael Turk <gititon@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] VideoPress A feature to help you upload and insert videos on your site. [Goal] Gutenberg Working towards full integration with Gutenberg
Projects
None yet
Development

Successfully merging this pull request may close these issues.

VideoPress: Reusable block does not render the player
4 participants