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

Add Twitter/X up-sell for new limit #896

Closed
wants to merge 7 commits into from

Conversation

Soare-Robert-Daniel
Copy link
Contributor

@Soare-Robert-Daniel Soare-Robert-Daniel commented Nov 20, 2023

Summary

Added the new components to display new upsell to increase the limit posts on Twitter/X.

New reusable components:

  • Snackbar
  • Popup

Workflow:

  • Every user will see a big notification about Twitter API changes. This notification will inform about the new changes and also act as an up-sell. This can only be dismissed by I Acknoledge -- this is a safeguard against clicking to be sure that users do not lose the coupon.
  • For the small notification, we have the following condition to show:
    • The user does not have a Marketer plan;
    • The user used the Twitter Integration (value checked with the option 'rop_twitter_last_posted');
    • The user has consumed all the available shares. (all plans) (checking isValid from our endpoint);
    • If it is a free plan, show it once a week after it is dismissed;
    • If it is a paid plan, show it once three weeks after it was dismissed.

Screenshots

image

image

Testing

⚠️ You will need a Twitter account.

  1. When you enter the Dashboard the pop-up will appear. ⚠️ If it the first install, the pop-ul will show on a page refresh, because on the first install the tutorial (the small blue pop-up) is active and the big notification can disrupt the experience.
  2. Add the Twitter account and share a post.
  3. If you are on a free plan, after sharing, you should see a small notification when you go to the dashboard.

@Soare-Robert-Daniel Soare-Robert-Daniel self-assigned this Nov 20, 2023
@Soare-Robert-Daniel Soare-Robert-Daniel marked this pull request as ready for review November 27, 2023 10:33
Copy link
Contributor

@preda-bogdan preda-bogdan left a comment

Choose a reason for hiding this comment

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

A small NIT I have about type coherence, will not block for this.

includes/admin/class-rop-admin.php Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants