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

Recurring Payments block - added example #13823

Closed
wants to merge 1 commit into from

Conversation

MichaelArestad
Copy link
Contributor

Master issue: #13510

Adds example to Recurring Payments block

In progress notes

I don't believe the current preview is very good. In fact, no preview is better than this, however, this will get the conversation started.

When hovering over the block, you see a loading state where it tries to talk to Stripe:
image

When that fails, you see this:
image

Ideally, this is what we want the user to see:
image

I need someone like @gravityrail or an experienced JS dev to remove the notice and loading state for the preview so the button shows up instantly. Sadly, this is beyond what I'm comfortable with.

Changes proposed in this Pull Request:

  • Implements the ability to preview the block before inserting it.

Is this a new feature or does it add/remove features to an existing part of Jetpack?

  • This is a new feature of Gutenberg we are moving to support.

Testing instructions:

  • Go to the post editor
  • Click the + to open a block inserter from the top bar
  • Hover over the recurring payments block

Proposed changelog entry for your changes:

  • We should probably add one changelog entry for all the blocks we add examples to. Something like: "Added previews to Jetpack blocks within the Gutenberg editor."

@MichaelArestad MichaelArestad added [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it [Status] In Progress [Focus] Blocks Issues related to the block editor, aka Gutenberg, and its extensions developed in Jetpack [Block] Payment Button aka Recurring Payments labels Oct 23, 2019
@MichaelArestad MichaelArestad added this to the 7.9 milestone Oct 23, 2019
@MichaelArestad MichaelArestad requested a review from a team October 23, 2019 21:58
@MichaelArestad MichaelArestad self-assigned this Oct 23, 2019
@matticbot
Copy link
Contributor

Caution: This PR has changes that must be merged to WordPress.com
Hello MichaelArestad! These changes need to be synced to WordPress.com - If you 're an a11n, please commandeer, review, and approve D34422-code before merging this PR. Thank you!

@jetpackbot
Copy link
Collaborator

jetpackbot commented Oct 23, 2019

Thank you for the great PR description!

When this PR is ready for review, please apply the [Status] Needs Review label. If you are an a11n, please have someone from your team review the code if possible. The Jetpack team will also review this PR and merge it to be included in the next Jetpack release.

Scheduled Jetpack release: May 5, 2020.
Scheduled code freeze: April 28, 2020

Generated by 🚫 dangerJS against a70075b

@simison
Copy link
Member

simison commented Oct 24, 2019

FYI @artpi in case you have spare cycles!

@jeherve jeherve modified the milestones: 7.9, 8.0 Oct 29, 2019
@jeherve jeherve modified the milestones: 8.0, 8.1 Nov 22, 2019
@jeherve jeherve removed this from the 8.1 milestone Dec 13, 2019
@artpi
Copy link
Contributor

artpi commented Dec 17, 2019

Oh nice, I just discovered it and it's from October! Jeez, I must have seen it and forgot, sorry!
Added to Recurring Payments Trello!

@stale
Copy link

stale bot commented Mar 17, 2020

This PR has been marked as stale. This happened because:

  • It has been inactive in the past 3 months.
  • It hasn’t been labeled `[Pri] Blocker`, `[Pri] High`.

No further action is needed. But it's worth checking if this PR has clear testing instructions, is it up to date with master, and it is still valid. Feel free to close this issue if you think it's not valid anymore — if you do, please add a brief explanation.

@stale stale bot added the [Status] Stale label Mar 17, 2020
@artpi artpi force-pushed the add/recurring-payments-preview branch from c9e9a3b to a70075b Compare April 7, 2020 17:48
@matticbot
Copy link
Contributor

MichaelArestad, Your synced wpcom patch D34422-code has been updated.

@stale stale bot removed the [Status] Stale label Apr 7, 2020
@artpi
Copy link
Contributor

artpi commented Apr 7, 2020

@MichaelArestad - thank you for this!
We will definitely not be changing recurring payments block to fake the preview.
The upgrade nudge and stripe connection requirement is a needed step.

Do you think there's a way to use another block (button) as a preview and just "fake it" ?

@MichaelArestad
Copy link
Contributor Author

Do you think there's a way to use another block (button) as a preview and just "fake it" ?

There totally is, but it's a little over my head.

@artpi
Copy link
Contributor

artpi commented Apr 29, 2020

Note to whoever takes this task:

  • change to static markup for preview
  • premium content block as well

@artpi artpi removed the request for review from a team April 29, 2020 10:10
@jeherve
Copy link
Member

jeherve commented Mar 2, 2022

I'll close this PR for now because of the lack of activity on this. We can always reopen in the future if needed, but it will need a rebase, so it may be easier to start a new PR at this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Payment Button aka Recurring Payments [Focus] Blocks Issues related to the block editor, aka Gutenberg, and its extensions developed in Jetpack Touches WP.com Files [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants