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

feat(billing): subscribe to all products (client side) #22768

Merged
merged 97 commits into from
Jun 21, 2024

Conversation

zlwaterfield
Copy link
Contributor

@zlwaterfield zlwaterfield commented Jun 6, 2024

See: https://github.com/PostHog/billing/pull/676

This PR is adding the UI changes for subscribe to all products. More details on the overall project in the PR linked above. The surface area for billing includes billing page, page gates and onboarding billing steps - so those are the areas this code will change.

As you can see it uses a mixture of the SUBSCRIBE_TO_ALL_PRODUCTS ff + the subscription_level to determine what experience to show. How the logic works

  • if they have the SUBSCRIBE_TO_ALL_PRODUCTS ff
    • if they have free / paid subscription_level then use the new experiences
    • else default to existing experience (because we don't want to change people who are partially subscribed until we backfill)
  • else default to existing experience

The core changes:

  • add a feature flag that allows this to be rolled out over time
  • keep the experience the same for existing users who have a subscription
  • aligning terminology in the new experiences
    • free <> paid -> upgrade / downgrade
    • addon -> add / remove
    • no usage for subscribe/unsubscribe
  • mild UI and spacing improvements to the billing page

Note: this does not yet include the changes to the onboarding plan comparison showing all products

There is an intentional focus on not changing the experience for existing users.

Further notes:

  • the use of has_active_subscription will probably be migrated to use subscription_level in the future
  • there's some UX issues around the pay gate upgrade loading - need to look into.

Other PRs before this one to help make the changes simpler:

@zlwaterfield zlwaterfield self-assigned this Jun 6, 2024
@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

7 snapshot changes in total. 0 added, 7 modified, 0 deleted:

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

7 snapshot changes in total. 0 added, 7 modified, 0 deleted:

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

13 snapshot changes in total. 0 added, 13 modified, 0 deleted:

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

11 snapshot changes in total. 0 added, 11 modified, 0 deleted:

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

2 snapshot changes in total. 0 added, 2 modified, 0 deleted:

  • chromium: 0 added, 2 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

2 snapshot changes in total. 0 added, 2 modified, 0 deleted:

  • chromium: 0 added, 2 modified, 0 deleted (diff for shard 1)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

2 snapshot changes in total. 0 added, 2 modified, 0 deleted:

  • chromium: 0 added, 2 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

3 snapshot changes in total. 0 added, 3 modified, 0 deleted:

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

1 snapshot changes in total. 0 added, 1 modified, 0 deleted:

  • chromium: 0 added, 1 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@zlwaterfield zlwaterfield enabled auto-merge (squash) June 20, 2024 18:23
@posthog-bot
Copy link
Contributor

📸 UI snapshots have been updated

2 snapshot changes in total. 0 added, 2 modified, 0 deleted:

  • chromium: 0 added, 2 modified, 0 deleted (diff for shard 2)
  • webkit: 0 added, 0 modified, 0 deleted

Triggered by this commit.

👉 Review this PR's diff of snapshots.

@zlwaterfield zlwaterfield disabled auto-merge June 20, 2024 22:27
@raquelmsmith
Copy link
Member

Test failures here are not related to this PR so going to push it out

@raquelmsmith raquelmsmith merged commit 99767a5 into master Jun 21, 2024
89 of 91 checks passed
@raquelmsmith raquelmsmith deleted the zach/subscribe-to-all-products/plan-levels branch June 21, 2024 16:04
thmsobrmlr pushed a commit that referenced this pull request Jun 24, 2024
Co-authored-by: Raquel Smith <[email protected]>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
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.

3 participants