Commit Graph

9491 Commits

Author SHA1 Message Date
Kevin Ansfield
3d16b50fc0 Version bump to 2.21.1 2019-04-30 11:10:02 +02:00
Kevin Ansfield
6cc7c37c21 Updated Ghost-Admin to 2.21.1 2019-04-30 11:10:02 +02:00
Florian Schlittenbauer
8eb4d4c888 replace deprecated del() with delete() call 2019-04-29 09:09:55 +02:00
Zimo
a6d7c46f2c Updated members payment failed copy and style
no-issue
2019-04-25 15:54:30 +02:00
Fabien O'Carroll
bf90733ce1 Updated token generation to use plans on member
no-issue

This is to remove duplication of logic, that now lives solely in the
getMember method
2019-04-25 13:38:26 +02:00
Fabien O'Carroll
70343f7923 Updated getMember to return plans
no-issue

Plans are distinct from subscriptions, as in theory a subscription could
have many plans. These moves the construction of the plans array into
the getMember function so that every consumer has access to the same
data.
2019-04-25 13:38:26 +02:00
Rish
b207ea35ec Updated signup flow to handle invalid payments
no issue
2019-04-24 13:23:00 +02:00
Fabien O'Carroll
7574d9af68 Added members-theme-bindings library to public
no-issue

This file is copied across on install, making it easy to update via
package.json, tbh we could not commit it to the repo - but it makes
sense to be able to see it when browing the file explorer. Any bumps in
package.json will update the file, so that it is prompted to be
commited.
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
18ba613e45 Added member.js file to initialise theme bindings 2019-04-24 12:46:00 +02:00
Fabien O'Carroll
59c57a9216 Copied members-theme-bindings to public post install
no-issue
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
5d02d1999c Installed @tryghost/members-theme-bindings@0.1.0
no-issue
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
8689493cf5 Updated ghost_head to include the members scripts
no-issue

This conditionally adds the members scripts based on the labs setting
for members, and the context of the rendering to NOT be for AMP
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
d638d6e979 Added middleware for serving members.js from core
no-issue
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
ed1a42f7f3 Exported raw middleware from serve-public-file
no-issue

The current public file middleware handles route matching itself, which
means it is applied to express via the use method. Due to use being a
"global" application of middleware, this means it is not possible to
apply a labs middleware before the public file serving middleware
without it affecting the entire route stack.

This commit exports a piece of raw middleware that can be used with the
get method of express, so that we can attach middleware beforehand.

This will be used to conditionally serve the members specific public
files, based on the labs flag for members.
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
d7fadfeff7 Fixed bug with deleting members after config change 2019-04-24 12:46:00 +02:00
Fabien O'Carroll
235d6a0366 Refactored labs middleware to remove duplication
no-issue

Also exposes a generic interface now.
2019-04-24 12:46:00 +02:00
Fabien O'Carroll
2edda4c757 Version bump to 2.21.0 2019-04-23 11:34:46 +02:00
Fabien O'Carroll
01af342969 Updated Ghost-Admin to 2.21.0 2019-04-23 11:34:46 +02:00
Fabien O'Carroll
1ca9b2003c Updated Casper to 2.9.11 2019-04-23 11:34:46 +02:00
Nazar Gargol
cb322fc1be Improved error context usage
refs #10571

- Change was done to avoid usage of hardcoded value and provide more context. Additionally errorDetails are formatted in a readable way
2019-04-23 09:45:11 +02:00
Nazar Gargol
63337dd823 Changed context used in error to help
refs #10571

- The context should provide the context in which the error has happened instead current value was more suited to purposes of help
2019-04-23 09:31:24 +02:00
Nazar Gargol
cea598597b Restructured theme check logic
refs #10571

- Removes dependency on 'context' property being set in error when
checking a theme
- Refactoring was needed to be able to avoid passing checked theme as a
part of thrown error (logic was relying on error having this specific
data in context property). This created a problem where we controlled
the logic flow with data in error object.
- Introduced 2 different types of theme check handling, one behaves the
same way as before, the other gives more granulac control to the caller
to decide what to do with returned errors.
2019-04-22 22:34:12 +02:00
Vikas Potluri
d989d62c10 Migrated encode, facebook_url and foreach helpers to es6 (#10655)
refs #9589 

* updated encode helper to use newer code standards
* updated facebook_url helper to use newer code standards
* updated foreach helper to use newer code standards
2019-04-22 17:54:42 +02:00
ml4den
8732d40967 Fixed a typo for non-verb "setup" (#10680)
no-issue
2019-04-22 17:47:28 +02:00
Rishabh Garg
8191513a86 Updated members site config keys (#10702)
no issue
2019-04-22 17:23:58 +02:00
Nazar Gargol
2253b2d18c 🐛 Fixed redirect for pages causing 404
closes #10649

- `resourceType` in API v0.1 is only of 'post' type. Because in admin we now distinguish between 2 types of editable resources: 'posts' and 'page' the redirect has to be based on 'entry.page' flag
2019-04-22 15:08:09 +02:00
Fabien O'Carroll
1facbc5c02
Excluded dotfiles and SECURITY.md via .npmignore (#10700)
refs #9441

The grunt-contrib-copy doesn't automatically include dotfiles, which is
whats used to build the release zip. These files aren't necessary when
using ghost as a dependency. This updates to exclude them from the npm
packages, which means the output of `npm pack` and `grunt release` give
the same content.
2019-04-22 13:37:26 +02:00
Daniel Milnes
0c12b37493 Updated Twitter URL in Readme (#10698)
Update Twitter URL in help section from https://twitter.com/tryghost to https://twitter.com/Ghost
2019-04-22 10:05:55 +02:00
kirrg001
ab49d1eed6 Added comments for routing service
no issue

- jsdoc
- inline comments
2019-04-21 23:55:22 +02:00
kirrg001
e07c0ecdc4 Added comments for url service
no issue

- jsdoc
- inline comments
2019-04-21 00:14:40 +02:00
Nazar Gargol
e1dca54bf7 🎨 Made notifications dismissible per user
refs #10656

- To make sure more users see important updates or announcements
notification dismissal now works per user instead of globally
- Expanded acceptance test for notification deletion
- Expanded regression test covering multiuser dismissal of notification
- Added clarifying comment about destroyAll method use in API
2019-04-19 09:43:14 +02:00
Fabien O'Carroll
39ed3f9145
Updated members auth pages to use gateway-protocol (#10695)
no-issue

This swaps out a hand copied library with the published one on npm
2019-04-18 15:53:36 +02:00
Hannah Wolfe
b5af42a9ef Updated .travis.yml w/ simpler renovate logic
- This worked in tests!
2019-04-18 13:35:41 +01:00
Nazar Gargol
809e610842 Added notification access persmission for users of Editor role
closes #9546

- Updated permissions  fixture for Editor role
- Added migration for permissions for Editor users
- Updated tests
2019-04-18 13:02:23 +02:00
Hannah Wolfe
e4c235f603
Temporarily remove renovate handling 2019-04-18 10:09:01 +01:00
kirrg001
6dd65d7176 Corrected general comment in update check unit
no issue
2019-04-17 20:52:50 +02:00
kirrg001
22c2d0cbcb Added comments for update check service
no issue

- jsdoc
- inline comments
- clarified variable names
2019-04-17 20:03:26 +02:00
Zimo
5a0113f24c Added close event on member pages background click 2019-04-17 16:34:14 +02:00
Peter Zimon
fb8a127729
Members refine buttons (#10692)
* Members: disabled signup button during signup

* Members: disabled non-Stripe signup button during signup

* Members: added check to Log in button logged in state
2019-04-17 16:16:03 +02:00
Zimo
01fa787227 Updated mobile styles for members upgrade screen 2019-04-17 16:06:04 +02:00
Rish
c53e66d49a Version bump to 2.20.1 2019-04-17 18:31:47 +05:30
Rish
67f2b41f27 Updated Ghost-Admin to 2.20.1 2019-04-17 18:31:47 +05:30
Rish
db9c2d1eca Fixed lint issues
no issue
2019-04-17 18:26:32 +05:30
Nazar Gargol
c519ce55e3 Fixed failing integration test
refs #9875

- Moved the comment about filtering by version closer to version checks as it doesn't apply to whole `.filter(...)` block
2019-04-17 14:48:09 +02:00
Rishabh Garg
876e310aea
Updated check for members-ssr use at theme layer (#10693)
no issue

### Context

As part of updating the theme layer to use members-ssr [here](f9899cb8c4), we introduced a case where if `enableDeveloperExperiments` is not switched on, the whole theme loading will crash due to unavailability of `ssr` property on members service [here](https://github.com/TryGhost/Ghost/blob/master/core/server/services/members/index.js#L12). Since we switch on `enableDeveloperExperiments` by default on master now, the issue won't be reproducible locally until explicitly switched off. 

This PR includes a patch fix which adds dummy `ssr` object to members service `api` object and members middleware check on APIs to ensure no crash in case developer flags is not switched on. 

Longer term it will be definitely useful to upgrade the dummy `api` object to trigger on member labs than the developer flag.
2019-04-17 17:38:12 +05:30
Fabien O'Carroll
5cb8972e2c Fixed subscription issue with null coupons
no-issue

Coupons were being sent as null to the api, so we support non required fields
2019-04-17 13:41:27 +02:00
Rish
ab3b0d95a2 🐛 Fixed fetching RSS in case of posts with no content
refs #10679

- Handles `null` html values in calculation
2019-04-17 15:12:01 +05:30
Rish
4d0643fb49 🐛 Fixed crash in calculating reading time for empty posts
no issue

- Updated helpers package to fix `null` html cases in case of empty post content
2019-04-17 15:12:01 +05:30
Fabien O'Carroll
500ec826c3 Added default disabled state of false to FormInput
no-issue
2019-04-17 10:35:17 +02:00
Fabien O'Carroll
78165a9981 Removed unused onClick handler in StripeSubscribePage
no-issue
2019-04-17 10:35:17 +02:00