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

Free Trials: Add expiring state to PlanStatus #1708

Merged
merged 2 commits into from
Dec 18, 2015

Conversation

drewblaisdell
Copy link
Contributor

Fixes part of #1151.

This PR updates the render() of PlanStatus and its child, PlanStatusProgress, to display a red progress bar/'days remaining' text and a primary 'Purchase Now' button if the trial expires within five days.

screen shot 2015-12-16 at 3 03 54 pm

Testing

Review

  • Code
  • Product

@drewblaisdell drewblaisdell added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. [Type] Task Free Trials labels Dec 16, 2015
@drewblaisdell drewblaisdell self-assigned this Dec 16, 2015
@drewblaisdell drewblaisdell added this to the No-cc Free Trials: v1 milestone Dec 16, 2015
@@ -37,26 +31,32 @@ const PlanStatusProgress = React.createClass( {
},

renderDaysRemaining() {
const { plan } = this.props;

return this.translate(
'%(daysUntilExpiry)s day remaining',
'%(daysUntilExpiry)s days remaining',
Copy link
Contributor

Choose a reason for hiding this comment

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

If the daysUntilExpiry argument is always an integer we could reference it as %(daysUntilExpiry)d instead.

@stephanethomas
Copy link
Contributor

Did we really need to move the progress bar into its own folder? As far as I know it's perfectly fine to have sub-components.

@stephanethomas stephanethomas added [Status] Needs Author Reply and removed [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Dec 18, 2015
@drewblaisdell drewblaisdell force-pushed the add/plan-status-expiring-state branch 2 times, most recently from 46d4153 to 3235938 Compare December 18, 2015 19:45
@drewblaisdell drewblaisdell added [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. and removed [Status] Needs Author Reply labels Dec 18, 2015
@drewblaisdell
Copy link
Contributor Author

Thanks for looking, @stephanethomas. I moved PlanStatusProgress back into plan-status/ and addressed your other notes.

@stephanethomas
Copy link
Contributor

Code looks good.

@ghost
Copy link

ghost commented Dec 18, 2015

👍 LGTM, awaiting pull 1780 for proper expiry messaging

@ghost ghost added [Status] Ready to Merge and removed [Status] Needs Review The PR is ready for review. This also triggers e2e canary tests and wp-desktop tests automatically. labels Dec 18, 2015
drewblaisdell added a commit that referenced this pull request Dec 18, 2015
Free Trials: Add expiring state to `PlanStatus`
@drewblaisdell drewblaisdell merged commit 3e10398 into master Dec 18, 2015
@drewblaisdell drewblaisdell deleted the add/plan-status-expiring-state branch December 18, 2015 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants