refs https://github.com/TryGhost/members.js/issues/20
- Allows paid/free member to update their newsletter subscription status
- Newsletter subscription status is immediately updated on toggle
refs https://github.com/TryGhost/members.js/issues/20
- Uses new member update endpoint to update logged-in member's profile info
- Member can update their name, email and newsletter subscription status
refs https://github.com/TryGhost/members.js/issues/29
- Create stripe checkout session in Ghost now supports passing metadata for custom info like name
- This allows storing member name post-signup after payment through stripe checkout is completed
no issue
- Adding default margin for action button can cause unwanted behavior where margin needs to be avoided.
- Allow higher level components to directly add margin if needed
refs https://github.com/TryGhost/members.js/issues/20
- Adds default page handling for paid member to open paid account area
- Refactors dev mode default page to be picked from env file if available
no issue
- Fixes custom trigger button not getting close class through any other way other than trigger
- Updates class name for open and close state by adding `gh-members-` namespace
refs https://github.com/TryGhost/members.js/issues/25
- No dependency on adminUrl anymore as endpoints exist on site url
- Members.js script is auto initialized, no need for explicit init in themes anymore
- No local .env values need to be set for development as script loads data from fixtures directly
closes https://github.com/TryGhost/members.js/issues/25
- Remove dependency on admin url for initialization as member endpoints now exist on site directly
- Auto initializes the script on load as need not wait on any external dependency
- API fetch cleanup in parent container
- Updates tests
refs https://github.com/TryGhost/members.js/issues/25
- Members endpoints were refactored in core to exist directly on site as `<SITE>/members/api/<RESOURCE>`
- All endpoints needed are now directly on SITE and removes the need for AdminURL
- Init method is updated to read site data from fixtures for local development, as no admin endpoint exists now
Core Refs:
0cba02b370fa4dfa1b21c70c49258e
no issue
- By default, CRA's webpack bundle combines and appends the main css at root level, so they are not applied inside any iframe.
- JSX Styles don't work for `:hover` and other similar selectors which is needed to style certain components like checkboxes
- This uses a hack where we append `<style> </style>` tag with all CSS inside the head of iframe dynamically as string
- We can create separate variables to keep styles grouped logically, and export them as one appended style string to apply styles in iframe.
no issue
- Updates `yarn script` to use same consistent format we use across org
- Removes use of `npm` in publish
- Adds `preship` to run lint - ideally should run tests but react tests run in interactive mode and are very slow atm, need to sort that out first.
refs https://github.com/TryGhost/members.js/issues/20
Updates trigger default icon to use member's gravatar if logged in via common component, which fallbacks to user icon when gravatar is blank.