no refs
- price amount helper was previously always returning whole numbers after rounding-off amount values
- this change updates the behavior to show decimal values upto 2 places when the amount is not a whole number, and a whole number otherwise
closes https://github.com/TryGhost/Team/issues/1158
Offer feature doesn't make sense when paid memberships are disabled on a site, this change removes the Offer option from sidebar if Stripe is disconnected (no paid memberships)
refs https://github.com/TryGhost/Team/issues/1149
- added fixed width of the main menu to the tablet-size media queries so it doesn't snap back to a smaller width after animating
refs https://github.com/TryGhost/Team/issues/1149
- added `ember-css-transitions` library that provides a modifier that adds/removes classes used for animating elements in and out, automatically creating a clone for destroyed elements
- added a wrapper class around the `main` and `design` nav menu contents so they could be individually animated
- used the new `{{css-transition}}` modifier to animate the sidebar menus in/out
- ensured main menu doesn't animate on first render of the parent `<GhNavMenu>` component so there's no animation when Admin is loaded
refs https://github.com/TryGhost/Admin/pull/2063
- `<GhFileUploader>` was using `.set()` inside a browser-level event handler but wasn't checking that the component hadn't been destroyed
refs https://github.com/TryGhost/Team/issues/1149
- added a `@data.onActivationSuccess` option to the upload-theme modal that if present is called when activation of a theme is completed as part of the upload process
- added a `startThemeUpload()` action to the `change-theme` controller so that we can pass in an `onActivationSuccess` which transitions to the `design.settings.index` screen
- removed unnecessary `@tracked` decorators on class properties that have `store.peekAll('theme')` assigned to them
no issue
- if a theme was uploaded with the same name as a previously deleted theme it was not being shown in the themes list, and if activated could not be found/seen as active breaking the design menu
refs https://github.com/TryGhost/Team/issues/1149
- `customThemeSettings.rollback()` was not performing the correct job, changed to rollback attributes on each model rather than resetting everything to empty
- moved leave confirmation handling to the `settings.design.index` route so that it's always called when moving to the change-theme route, previously with the behaviour on the main `settings.design` route the willtransition/deactivate was not called when expected because that route is still active when on `settings.design.change-theme`
refs https://github.com/TryGhost/Team/issues/1149
- replicated the visible iframe's `scrollTop` to the hidden iframe before swapping visibility between them so the scroll position remains consistent even though the contents and frames are fully reloaded and swapped
refs https://github.com/TryGhost/Team/issues/1149
- changed `current-when` for the design settings title to only be active on the index screen which corresponds to the setting groups being active/usable
- updated styles to use the `.active` class rather than just `:focus`
refs https://github.com/TryGhost/Team/issues/1149
- use ember-keyboard's `{{on-key}}` modifier to attach keyboard event listener when the design settings index screen is shown - ensures that ctrl/cmd+s on the change-theme screen won't trigger an unexpected save
- blur active element when saving so the preview is updated and reflects what has just been saved (text fields only update preview on blur)
no refs
- without marking input fields in template as `readonly` value, it updates the value directly on any change which is undesirable and causes side-effects in actual update of property
refs https://github.com/TryGhost/Team/issues/1162
- fixes decimal value for fixed type discount not working
- updates offer name placeholder to Display title
- removed default offer description value in portal preview
no issue
- if there are no settings loaded then we shouldn't try to save an empty `custom-theme-setting-list` record because it will result in an invalid API request
refs https://github.com/TryGhost/Team/issues/1151
- we were setting `emailOnly` on the publish menu component but not resetting it meaning when you re-opened the menu after previously selecting "Send" the menu would still show "Send" but the state was inconsistent because the underlying `distributionAction` property _was_ reset
- dropped setting `emailOnly` directly in favour of making it a computed property based on `distributionAction === 'send'` so we only have to worry about changing distribution action and everything else updates for us automatically
refs https://github.com/TryGhost/Team/issues/1149
If you were part way scrolled through the themes list and you clicked the "Advanced" button, the installed themes list was displayed at the top of the scrollable element but the browser kept the scroll position so it looked like nothing happened.
- updated `toggleAdvanced()` action to scroll the main container to the top so that the installed themes list is immediately viewable when you use the button to open/navigate to it
refs https://github.com/TryGhost/Team/issues/1149
- added Casper to the hardcoded official themes list with a ref of `'default'` so that the install theme process knows to process it differently
- updated the install-theme modal
- removed the `willOverwriteDefault` getter because it's a path that can't be reached and is now handled differently
- changed `installThemeTask` to only perform an activation when a default theme is passed in