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

[Gutenberg] Audio upload processor #15420

Merged
merged 7 commits into from
Dec 7, 2020
Merged

Conversation

etoledom
Copy link
Contributor

@etoledom etoledom commented Dec 1, 2020

gutenberg PR: WordPress/gutenberg#27401
gutenberg-mobile PR: wordpress-mobile/gutenberg-mobile#2854

This PR implements the Audio upload processor to be used together with the Audio block.

This PR also improves the file type filet for the on-device file picker: Now only file extensions allowed by the blog can be picked. Previously any video/image extensions could be picked for the Audio/Video blocks. This is also now used on the Audio block to avoid Apple-only audio filetypes (common on audio files recorded in iPhones).

To test:
Test running metro server on wordpress-mobile/gutenberg-mobile#2854

  • On a new post, add an Audio block.
  • Add to it a relatively large Audio file.
  • While the upload is happening, close the editor saving as a draft.
    • The post card will show an upload in progress.
  • Wait for the upload to finish and the post to be saved remotely.
  • Open the saved post.
  • Switch to HTML mode.
    • Check that the Audio block id has a positive number.
    • Check that the src URL is a remote (non-local) URL.

cc @jd-alexander

PR submission checklist:

  • I have considered adding unit tests where possible.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@etoledom etoledom added the Gutenberg Editing and display of Gutenberg blocks. label Dec 1, 2020
@etoledom etoledom added this to the 16.4 milestone Dec 1, 2020
@etoledom etoledom requested a review from guarani December 1, 2020 15:21
@etoledom etoledom self-assigned this Dec 1, 2020
@peril-wordpress-mobile
Copy link

peril-wordpress-mobile bot commented Dec 1, 2020

You can trigger an installable build for these changes by visiting CircleCI here.

@peril-wordpress-mobile
Copy link

peril-wordpress-mobile bot commented Dec 1, 2020

You can trigger optional UI/connected tests for these changes by visiting CircleCI here.

Copy link
Contributor

@guarani guarani left a comment

Choose a reason for hiding this comment

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

Looks good to me @etoledom! Left a few minor code comments.

Base automatically changed from gutenberg/enable-file-block to develop December 4, 2020 23:48
@etoledom etoledom merged commit 5a3d37e into develop Dec 7, 2020
@etoledom etoledom deleted the gutenberg/audio-block-processor branch December 7, 2020 12:26
@etoledom
Copy link
Contributor Author

etoledom commented Dec 7, 2020

Thank you @guarani 🙏
Nice catch! Committed the suggestions 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Gutenberg Editing and display of Gutenberg blocks.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants