refs TryGhost/Ghost#12365
Portal now allows direct checkout links for monthly/yearly plans via Portal links or data attributes, allowing members to directly signup to a paid plan. This PR adds -
- A new portal signup link for monthly plan - `/signup/monthly`
- A new portal signup link for yearly plan - `/signup/yearly`
Co-authored-by: Peter Zimon <zimo@ghost.org>
Made post email preview design consistent with the new email settings design preview.
* changed background
* added fake container windows and faux sender/recipient content
* updated mobile and dark mode
no-issue
This adds three initial customisation options for newsletters:
1. Show/Hide site title and logo
2. Set font to serif/sans serif
3. Display a publish with Ghost badge
This is the first step in allowing customisation of the look and feel of newsletters.
Co-authored-by: Rish <zrishabhgarg@gmail.com>
Co-authored-by: Peter Zimon <zimo@ghost.org>
refs 6140a98351
- Adds free/paid member counts to newsletter option in publish menu
- Updates default state for newsletter sending option based on number of members for free/paid
- Updates styling for checkboxes based on enabled/disabled state
- we don't need to run linting twice as we do currently in the Firefox &
Chrome jobs
- also pins the Node version to 12.18.0 so we can be sure what Node
version we're running with
no issue
The toolbar display/positioning logic was recently changed so that the toolbar is shown when a `saveAsSnippet` action is passed in. However the `_setToolbarProperties` method wasn't taking into account the toolbar element not being present when in editing mode such as when a block-editable card (markdown, html, code) is created.
- remove conditional logic that may change over time and replace it with checks for the toolbar element existing
refs 8ad11fe082
- Removes Portal settings access from behind flag and includes it by default.
Portal script is now enabled as default, the change here allows Site owners to access Portal settings via Ghost-Admin
no issue
- extracted item matching into a separate function
- modified item matching to work with arrays (existing exact match behaviour) or functions which can be defined per-item
- changed snippet item `matches` to a function that does a naive match or the typed query to any part of the snippet's title
no issue
Snippets are pieces of saved content that are given a name and made available for easy and quick insertion when editing posts or pages. They can contain rich text, cards, or a combination of both making it faster and less error-prone to re-use pieces of content across multiple posts. Snippet length is not constrained meaning they can also stand in as post type templates alleviating the need to keep drafts around as templates and copy/pasting each time they are used.
Feature changes:
- added "create snippet" icon to selection and card toolbars
- added "Snippets" section to the plus and slash menus
- for the slash menu, continuing to type after opening the menu will filter by snippet name
- all saved snippets are available to all staff users
- snippets can be deleted by clicking the trash can icon when hovering the mouse over a snippet entry in the plus or slash menus
- creation/deletion of snippets is available to staff users with the owner, admin, or editor role
This commit:
- removed developer experiments guard around snippet UI
no issue
- snippets can only be created and deleted by owners/admins/editors
- added a property in the editor controller to determine if the logged in user has sufficient permissions, then only pass the appropriate save/delete snippet actions to the editor component if the check is passed
- updates koenig menus and toolbars to skip rendering of buttons if the associated action function is not available
refs https://github.com/TryGhost/Ghost/issues/12256, https://github.com/TryGhost/Ghost/issues/12255
Currently when listing subscriptions for Members in both the Admin and the Theme, we only show the subscriptions which have a status of trialing or active.
Based on discussion, the `unpaid` and `past_due` states on Stripe also represent owner's intention of considering a subscription as active instead of `cancelled`, so we allow any subscriptions under these 2 states to be also listed for a member and consider them as `paid`. This updates Admin to consider those subscriptions as active as well.
- Subscriptions will go into a past_due state if the payment is missed, this should be considered a grace period where the member still has access.
- After this the subscriptions will either go to the unpaid or the cancelled state - this can be configured on an account by account basis in the Stripe dashboard. `unpaid` is considered as an intention to keep the subscription to allow for re-activation later.
no issue
- when deleting a snippet we display a confirmation modal, if the background is clicked to dismiss the modal then the menus closed too which is a different behaviour to clicking the close/cancel button inside the dialog
- adjusted the "ignore click" selector in the menus to include all fullscreen modal elements
no issue
- show a delete icon when a snippet is hovered in plus/slash menus
- show a confirmation dialog when the delete icon is clicked
- keep menus open whilst displaying the delete confirmation dialog
no issue
- bumps eslint and eslint-plugin-ember versions
- octane rules are enabled by default
- disabled them in our eslintrc.json so we can switch to warn/error whilst migrating to octane
- fixed a couple of linting errors from new/updated rules
no issue
- it doesn't make sense to create snippets of bookmark/embed cards before they contain any content so we avoid passing the save snippet function through until content exists and the card has left it's input state
no issue
- with the addition of snippets the card menu contents height and potential label width are both growing considerably making the grid layout unworkable
no issue
- show the toolbar icon for any `<KoenigCard>` instance that has the `saveAsSnippet` action passed to it
- currently that's all cards except the HR card because that's a primitive element rather than containing any user-defined content
- add `koenigUi.inputHasFocus` so that card toolbars can be hidden when the snippet input is displayed
no issue
- allows quick access to the preview without having to open post settings menu and click the preview link or hit Ctrl/Cmd+S and click the link in the success notification
* Added auto focusing preview on the signup page while being on links and clicking on any setting in the sidebar
* Refine upload custom portal icon button
* Updated copy for sidebar and links screen
* Added grouping to links list
no issue
- all of our models which allow users to name something use `name` as the field descriptor rather than `title` so `snippet.title` was renamed for consistency
- also fixes typo in the plus-menu component that stopped clicking on snippets from working
closes https://github.com/TryGhost/Team/issues/411
- adds "Create snippet" icon to the editor toolbar
- uses the same link input component design for specifying snippet titles
- snippets are loaded in the background when the editor is accessed
- snippets are listed at the bottom of the card menus of the + and / menus
- clicking a snippet inserts the snippet's contents in place of the current blank section
no refs.
- in Portal settings domain and the path are separated visually so that it conveys the concept of using the relative URL instead of absolute
- for similar reasons, copy link copies only the path part
no issue
- without this there's no indication the config flag is set when you have no access to the config file or you don't know which features are currently behind the flag
no issue
- fixed all `no-shadow` linter warnings
- changed `no-shadow` eslint rule from `warn` to `error` so we don't re-introduce shadowed variables in the future
no refs.
- updated moment locale to display '1 minute' instead of 'a minute' to be more explicit about scheduled time
- removed full stop from the scheduler message in editor header
no issue
- borders are necessary on selected cards to keep consistent spacing between selected/non-selected cards
- use transparent borders in dark mode rather than eliminating borders
- moved transparent card background style to `_koenig-dark.css` so it only affects dark mode - we want to keep the background colour for light mode so that we don't get mis-aligned backgrounds in certain cards
no issue
- now that we no longer have the `ember-sticky-element` dependency we're free to upgrade `ember-in-viewport`
- remove package.json resolution so latest version gets installed
- remove ember-in-viewport from renovate ignore config
- update `<GhScrollTrigger>` to match latest `ember-in-viewport` usage and convert to a glimmer component
- ensure `scrollableArea` is always set so that the trigger doesn't stop working after the first trigger
no issue
- native `position: sticky` support is now good enough across the board of our supported browser versions to use in place of a JS version for our use cases
- `ember-sticky-element` is preventing the dependency update of `ember-in-viewport` so removing it will allow a lot of our sub-dependencies to be updated
no issue
- Current logic was not setting empty accent color in portal preview which was misleading when no accent color is set
- Updated preview url to contain empty accent color which is picked by Portal preview
no issue
- Safari 12 support was automatically dropped when Safari 14 was released this September. This created quite a step-change in level of JS that is left as native in the build output causing problems for users who haven't upgraded or are stuck on browser versions ~1yr old
- adjusted the browser support to include last 3 versions of Safari, giving another year (most likely based on Apple's historic release schedule) of older browser support
no issue
- Social account(twitter/facebook) values in general settings were only updated to settings upstream on focus out
- Uses `notifyPropertyChange` to avoid multiple `.set()` workarounds
Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
closes https://github.com/TryGhost/Ghost/issues/12014
- `startDateLabel` was never populated after refactoring the members chart to use the members stats service
- use the first date that's returned as part of the members stats days array so that we can account for any potential time period being selected
Co-authored-by: Kevin Ansfield <kevin@lookingsideways.co.uk>
no issue
On newer iOS devices with no home button, we have this bar at the bottom of the screen instead. When installed as a PWA, the mobile nav sits under that bar. I'm unsure how much Ghost is used this way, but this is a small QOL improvement for those who do.
This PR uses the native `env` CSS custom properties Safari has to add a propriety amount of `padding-bottom` to the mobile nav bar, and also the global container to prevent anything in the iframe from being hidden by the taller nav bar. If the device does not support these `env` vars, is has no adverse affect. In order for this to work, the `<meta name="viewport" />` tag needs `viewport-fit=cover` added to it.
MDN docs for reference: https://developer.mozilla.org/en-US/docs/Web/CSS/env
closes https://github.com/TryGhost/Ghost/issues/11786
`GhTokenInput` uses `PowerSelect` component of `ember-power-select` internally in `app/components/gh-token-input/select-multiple`.
When you open that component, [you can find](d36f38f39e/addon/components/power-select.ts (L262-L278)) that it calls `stopImmediatePropagation` when ctrl/cmd or meta key is down.
```js
handleTriggerKeydown(e: KeyboardEvent) {
if (this.args.onKeydown && this.args.onKeydown(this.storedAPI, e) === false) {
e.stopImmediatePropagation();
return;
}
if (e.ctrlKey || e.metaKey) {
e.stopImmediatePropagation();
return;
}
if ((e.keyCode >= 48 && e.keyCode <= 90) || isNumpadKeyEvent(e)) { // Keys 0-9, a-z or numpad keys
(this.triggerTypingTask as unknown as Performable).perform(e);
} else if (e.keyCode === 32) { // Space
this._handleKeySpace(this.storedAPI, e);
} else {
return this._routeKeydown(this.storedAPI, e);
}
}
```
Because of that, I had to dispatch event directly to the root of the Ghost admin app.
refs https://github.com/TryGhost/Ghost-Admin/pull/1701
- swap `ember-cli-uglify` for `ember-cli-terser` to match ember-cli 3.21.1's generated package.json
- swap `broccoli-uglify-sourcemap` for `broccoli-terser-sourcemap` used manually in our production builds to keep dependencies the same across custom and built-in build artefacts
no issue
depends on https://github.com/TryGhost/Ghost/pull/12211
- Other than dev flag, the Portal is now also enabled behind a dedicated `portal` flag
- Shows/hides Portal settings based on dev or Portal flag
refs https://github.com/TryGhost/Ghost-Admin/pull/1701
- swap `ember-cli-uglify` for `ember-cli-terser` to match ember-cli 3.21.1's generated package.json
- swap `broccoli-uglify-sourcemap` for `broccoli-terser-sourcemap` used manually in our production builds to keep dependencies the same across custom and built-in build artefacts
- we recently had an issue where a dependency update broke the
release process because it was building in production mode, but our CI
never ran in this mode and we missed it
- this commit adds a test to run in prod mode so hopefully we catch it
next time
closes https://github.com/TryGhost/Team/issues/347
- removes the warning banner directing users to use Ghost Desktop/a
desktop browser because users are happy with the experience of editing
on mobile/tablets