Commit Graph

7762 Commits

Author SHA1 Message Date
Sanne de Vries
67fa946bff Updated theme preview page 2021-10-13 15:33:53 +02:00
Sanne de Vries
2c173e6212 Updated copy for theme-install modals 2021-10-13 14:57:39 +02:00
Kevin Ansfield
7c2ba1c242 Wired up desktop/mobile toggle on design settings screen
no issue

- ensured that we're only swapping classes on existing elements or inserting/removing elements around the iframe to avoid re-rendering and the associated loading+layout flash
2021-10-13 13:22:49 +01:00
Kevin Ansfield
d63cfa472f Fixed design nav open/close icon misalignment
no issue

- icons seemed to disappear when sections above are opened, or they lost attachment when scrolling
- added `position: relative` to the nav item container so the `position: absolute` children are correctly contained
2021-10-13 12:47:33 +01:00
Kevin Ansfield
8e10d38d1f Added .active class to design nav items when open
no issue

- matches nav items that use `<LinkTo>`
- fixes sections headers going in and out of bold styling whilst interacting with the menu/forms
2021-10-13 12:42:25 +01:00
Kevin Ansfield
2476aff3d7 Forced close of design sections when clicking "Change theme" link
refs f9a2626ae4

- nav menu felt inconsistent where clicking a section nav item closes all other sections but clicking the change-theme nav item didn't
2021-10-13 12:33:15 +01:00
Kevin Ansfield
51efc0765d Improved rendering/re-rendering of <GhHtmlIframe>
no issue

There was noticeable flickering as content is loaded into the iframe or re-rendered because we show everything from the moment html is injected in, meaning the full loading and layout process is shown.

- changed to using two iframes with one being hidden
- when `@html` changes we inject the html into the hidden iframe
- once all loading finishes on the hidden iframe (or 500ms timeout occurs to account for slower connections) we swap the iframe visibility so we end up switching between two fully (mostly) rendered displays resulting in much less flicker
2021-10-13 12:21:53 +01:00
Sanne de Vries
34e4add038 Updated advanced section on new themes page 2021-10-13 12:59:49 +02:00
Kevin Ansfield
d8bdd45add Added current theme display to design screen nav sidebar
no issue

- fetch themes in the background when sidebar is rendered in case they haven't been loaded so far (current screen design means the first time the nav bar is seen the themes are unlikely to have been loaded already)
- added `activeTheme` getter to grab the active theme from the live themes list
2021-10-13 10:39:23 +01:00
renovate[bot]
f08bf3cd7a Update dependency @tryghost/members-csv to v1.1.7 (#2100)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-13 09:12:34 +01:00
Kevin Ansfield
f9a2626ae4 Changed design menu to only show one open section at a time
no issue

- we want the menu to feel more like a typical navigation sidebar
2021-10-13 09:11:57 +01:00
renovate[bot]
852732b232 Update dependency @tryghost/limit-service to v0.6.4 (#2094)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-13 08:55:22 +01:00
Sanne de Vries
d4cb6d019e Updated design settings sidemenu 2021-10-12 19:14:17 +02:00
Kevin Ansfield
569e4576d5 Added install+activate process to view theme screen
closes https://github.com/TryGhost/Team/issues/1130

- migrated install theme process to new modal system and changed to install+activate
- added "Use theme" button that opens the new install+activate modal
- when the view theme screen opens the install modal, an `onSuccess` callback is passed which sets a property that will skip closing the install modal when the view theme modal is closed and transitions to the `settings.design` route leaving the "success" modal state on screen
- added a `skipErrors` option to `themeManage.activateThemeTask` so that it can be used from processes that already handle theme errors without opening extra modals on top
2021-10-12 16:47:44 +01:00
Kevin Ansfield
342d9a242c Converted <GhLoadingSpinner> to glimmer component
no issue

- allows for attributes such as class/style to be set on it's container for better display in varying situations
2021-10-12 16:47:44 +01:00
Sanne de Vries
5a048c105e Fixed color picker and image uploaders in design settings 2021-10-12 16:37:30 +02:00
Kevin Ansfield
3f7cdb34d9 Added auto-check of match helper flag when enabling custom theme settings
no issue

- custom themes settings isn't really usable without the `{{match}}` helper so to help avoid confusion we'll now enable it whenever the custom theme settings flag is enabled
- added `requires` array to the feature definition which when set will enable all flags in the array when the main feature is enabled
2021-10-12 15:33:03 +01:00
Kevin Ansfield
3477be5974 Removed hardcoded style from design settings index
no issue

- by using flex display on the outer container we can get rid of the hardcoded height calc style and let the browser handle the layout more naturally
2021-10-12 15:23:55 +01:00
Kevin Ansfield
8ec5b83097 Fixed save button on design settings screen
refs https://github.com/TryGhost/Team/issues/1130

- when moving the design settings screen from a modal to normal routes the save process was misplaced and the template not updated
- moved all the design settings behaviour over to the index controller where it belongs and updated the template to use `this.saveTask` rather than `@data.saveTask` as was used in the modal
2021-10-12 15:19:27 +01:00
Kevin Ansfield
265a19f550 Added initial view-theme modal for installing from themes list
refs https://github.com/TryGhost/Team/issues/1130

- added new route for viewing themes so back/forward buttons can be used
  - takes theme name as a parameter
  - opens a fullscreen modal with an iframe containing the theme demo
- changed installable themes list to link to new route
- swapped `previewUrl` in theme data to point at the real demo rather than the ghost.org demo page
2021-10-12 14:28:05 +01:00
Sanne de Vries
87c3a0a359 Fixed upload theme button style 2021-10-12 15:01:20 +02:00
Kevin Ansfield
c01c2b3c74 Fixed theme's list not auto-updating on upload
no issue

- the ember data live record array needs to live on a tracked property rather than a getter for the template to auto-update
2021-10-12 13:51:11 +01:00
Sanne de Vries
c721bb3b1f Updated design settings sidemenu 2021-10-12 14:30:12 +02:00
Rishabh
aefc762a20 Added offer urls to email cta card
refs https://github.com/TryGhost/Team/issues/1134

- allows site owners to easily include offer URLs in their email CTA
- will be updated to include active offers only
2021-10-12 17:03:45 +05:30
Naz
93893fe7f1 Fixed 'Publish & Send' CTA in page publish menu
https://linear.app/tryghost/issue/CORE-100/publishandsend-text-visible-on-page-publish-menu

- Page publish menu should not have any knowledge about "email-only" posts, the text in the publish menu should never show any variation of the "send" option.
2021-10-12 12:32:39 +02:00
Kevin Ansfield
924da56c94 Moved theme table to change-theme screen and dropped advanced screen
refs https://github.com/TryGhost/Team/issues/1130

- match latest design where the theme table is under an "advanced" toggle on the change-theme screen rather than a completely separate screen
2021-10-12 10:18:55 +01:00
Kevin Ansfield
4fa13bfa9f Fixed capitalization of API and CTA in theme setting labels
no issue

- added `{{humanize-setting-key}}` helper that uses the base `humanize` output but then forces capitalization for known acronyms
- updated `<CustomThemeSettings::Select>` to use the new helper
2021-10-12 10:11:24 +01:00
Kevin Ansfield
d3539655a0 Fixed empty setting groups showing in nav bar
refs bc5be1a808

- after removing duplication for groups in the template we were showing empty groups because the group construction wasn't considering there may be no settings for a group
2021-10-12 09:13:14 +01:00
renovate[bot]
d12090cc14 Update dependency @ember/render-modifiers to v2 (#2105)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-12 08:30:15 +01:00
Kevin Ansfield
fee190eb08 Removed unneeded customThemes limit check
no issue

- the first check when uploading a theme is the same as the second but without returning a specific error message so it shouldn't be necessary
2021-10-12 08:27:25 +01:00
Kevin Ansfield
bc5be1a808 Removed template duplication for custom theme setting groups
no issue

- added `settingGroups` array to the nav menu so that it can be looped over rather than having the same template duplicated for hard coded settings arrays
2021-10-12 07:54:34 +01:00
Kevin Ansfield
ddac463514 Fixed custom theme settings not showing in groups
no issue

- custom theme model was missing the `group` attr so the nav menu couldn't see it to assign to groups
- changed homepage group from `home` to `homepage` to match gscan
- added fallback to showing in the "Site-wide" group if an unknown group value is seen
2021-10-12 07:36:03 +01:00
Kevin Ansfield
b2177e636e Fixed enter key not triggering confirm action in delete theme modal
no issue

- added missing key handler
2021-10-12 07:26:18 +01:00
Kevin Ansfield
1d0cd80158 Added basic reset to design preview on nav bar interaction
refs https://github.com/TryGhost/Team/issues/1130

- when opening/closing sections or interacting with the general design or custom theme settings we want to switch back to showing the preview so the sidebar acts more like typical navigation and so form changes show their effect
2021-10-11 21:09:42 +01:00
Kevin Ansfield
870cf94b7a Fixed linting error
refs 13f9cb85fa

- `[i]` was left over after switching from `for` to `forEach()`
2021-10-11 19:36:58 +01:00
Kevin Ansfield
13f9cb85fa Refactored theme upload process and linked from design screens
refs https://github.com/TryGhost/Team/issues/1130

- copied theme upload modal to new modals system and refactored for Octane syntax
  -  updated to use `themeManagement` service rather than passed in actions so the modal-based process can be opened from any screen
  - added default `beforeClose()` for the modal to the modals service so it won't close if an upload is in-progress (defaults were moved directly into the class so it had access to services)
- added `themeManagement.upload` action for triggering the upload modal and providing a central place for limit checks
- added upload-triggering buttons to change-theme and advanced design screens
2021-10-11 19:30:58 +01:00
Kevin Ansfield
3345920f29 Removed unused beforeModalClose method on design route
refs 595018098d

- method removal was missed when switching from modal to standard route
2021-10-11 17:43:59 +01:00
Kevin Ansfield
42e493bb81 Initial pass at new change theme screen
refs https://github.com/TryGhost/Team/issues/1130

- added link to design sidebar
- dropped change-theme modal and associated route behaviour
- copied basic themes marketplace list into the change-theme controller/template
2021-10-11 17:14:18 +01:00
Kevin Ansfield
595018098d Switched design screen from modals to standard routes
refs https://github.com/TryGhost/Team/issues/1130

- added `ui.contextualNavMenu` property that when set will switch the main nav menu between components, if it's not set then it will show the default "main" menu component
- added `design` menu sub-component of `gh-nav-menu` ready for use via `contextualNavMenu`
  - moved sidebar contents from the design modal into this component
- updated design route to set/reset `ui.contextualNavMenu` to `design` on entering/leaving the route
  - all other design routes are sub-routes so this works across all other design screens
- moved base design modal preview into the `settings/design/index` controller/template
  - using index means that it's the default screen for `/settings/design` but will be automatically replaced by any other `design.x` routes
- moved `design/advanced` modal content into the `settings.design.advanced` controller/template and removed the modal handling from the route
2021-10-11 15:24:46 +01:00
Kevin Ansfield
7eda410dc3 Fixed html attributes not showing in design settings preview
no issue

- by using `innerHTML` we were missing the lang and class attributes on the `<html>` element that are added by themes, breaking things like dark mode
- switching to `outerHTML` includes the `<html>` element and is handled automatically by iframes when writing to the `contentWindow`
2021-10-11 15:03:49 +01:00
Sanne de Vries
de5674ebd4 Updated design page
Refs https://github.com/TryGhost/Team/issues/1130
2021-10-11 15:13:16 +02:00
Kevin Ansfield
717eb762f6 🐛 Fixed inability to re-schedule a scheduled post
closes https://github.com/TryGhost/Team/issues/1112

- when the scheduled post publish menu component was converted to a glimmer component one of the properties in a conditional was missed when changing from `this.x` to `this.args.x` meaning that every time the menu was clicked the published at time was reset as if the save type was being changed
2021-10-11 10:30:12 +01:00
renovate[bot]
0932abcb6d Update dependency ember-simple-auth to v4.0.2 (#2103)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-11 09:34:26 +01:00
renovate[bot]
9af08b2f39 Update dependency @sentry/ember to v6.13.3 (#2104)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-11 09:34:02 +01:00
Rishabh
b55ff582b8 Fixed offer tests
no refs

- adds new product fixtures
- allows loading of products data for offers page
2021-10-11 13:52:42 +05:30
Rishabh
0459a1ca23 Removed rogue unsaved change model for new offers
refs https://github.com/TryGhost/Team/issues/1126

- adds default properties of offer to a separate object to avoid unnecessary unsaved change modal on new offer and back
2021-10-11 13:33:30 +05:30
Rishabh
bfcd0b9ebd Removed unused interval field on offer modal
no refs
2021-10-11 13:03:38 +05:30
Daniel Lockyer
deef182bd2 v4.18.0 2021-10-08 16:00:25 +01:00
Rishabh
dd0ecf75b9 Added basic acceptance tests for offers
refs https://github.com/TryGhost/Team/issues/1084
refs https://github.com/TryGhost/Team/issues/1085
2021-10-08 19:45:48 +05:30
Rishabh
1107465398 Added new enable labs flag helper for tests
no refs

- allows easily enabling alpha features for tests
2021-10-08 19:45:07 +05:30
Rishabh
756bd2bdb5 Fixed cadence selection for offers
no refs

- fixes double selection needed for cadence on offers detail screen
2021-10-08 19:24:28 +05:30
Rishabh
7ef2b08883 Fixed offer percentage amount not getting set
no refs
2021-10-08 19:15:56 +05:30
Rishabh
4bbbea29ed Refined fixed discount type amount UI
refs https://github.com/TryGhost/Team/issues/1084
refs https://github.com/TryGhost/Team/issues/1085

- uses price helper to show Stripe amount instead of manual calculation
2021-10-08 18:50:18 +05:30
Peter Zimon
fa89f42e70 Fixed Offers menu title in main nav 2021-10-08 13:15:49 +02:00
Peter Zimon
cbfe554738 Fixed disabled input field contrast 2021-10-08 13:02:24 +02:00
Peter Zimon
7ac85a3c02 Formatting fixes on offers list 2021-10-08 12:55:25 +02:00
Peter Zimon
600edc0d60 Updated percentage/amount selector for offers 2021-10-08 12:48:41 +02:00
Rishabh
e82bd1579a Removed nested offers code under memberships
no refs

- offers has moved out to its own page in Admin, the old route and controller for wiring of offers under membership screen is no longer needed
2021-10-08 09:30:41 +05:30
Rishabh
267889993f Updated shareable offer link UI on list screen
refs https://github.com/TryGhost/Team/issues/1084

- updates shareable offer link UI to to open directly instead of route
- calculates offer url from code and updates in link modal
- wires copy button on link modal
- removes route based link code for modal
2021-10-08 09:28:17 +05:30
Rishabh
bbaad743a3 Refined offer detail screen
refs https://github.com/TryGhost/Team/issues/1085

- adds unsaved changes modal for navigating away
- adds link url for offer redemption
- updated amount calculation for fixed amount offers (1000 for 10 USD)
- disabled discount info section for existing offers
2021-10-08 01:43:59 +05:30
Rishabh
91292469b3 Added default values for new offers
refs https://github.com/TryGhost/Team/issues/1085

- adds default value for type and duration of offer for use in new offers
2021-10-08 01:41:30 +05:30
Rishabh
43f5d7c621 Refined offers list screen
refs https://github.com/TryGhost/Team/issues/1084

- updates offer list to show fixed amount discounts
- cleans up offer list usage
2021-10-08 01:39:42 +05:30
Naz
2089c97142 🐛 Fixed showing "reschedule" in PSM after the post is sent
https://github.com/TryGhost/Team/issues/947

- After the post is sent out there it's similar to being "published" in terms of pubslish/scheduled date
2021-10-07 15:18:51 +02:00
Naz
afbe24796a Removed stray only statement 2021-10-07 13:10:20 +02:00
Naz
843b810d1c Fixed failing test
refs https://github.com/TryGhost/Team/issues/1125
refs 4f3e340c03
refs 40269466f2

- The 'Publish & send' copy is now a default when publishing a post and has been missed to change in the refed commit
2021-10-07 13:09:55 +02:00
Naz
40269466f2 Fixed failing test
refs https://github.com/TryGhost/Team/issues/1125
refs 4f3e340c03

- The 'Publish & send' copy is now a default when publishing a post and has been missed to change in the refed commit
2021-10-07 12:55:18 +02:00
Peter Zimon
fd5e009d29 Fixed Tags empty screen button bug 2021-10-07 12:25:37 +02:00
Peter Zimon
1861c8b4eb Copy update for offer details 2021-10-07 12:17:50 +02:00
Peter Zimon
b5d30ba92e Temporarily removed Archive option for offers 2021-10-07 12:16:30 +02:00
Naz
4f3e340c03 Promoted email-only feature to general availability
refs https://github.com/TryGhost/Team/issues/1125

-- Email-only is not considered a general availability feature and can be used without special flags.
- It allows to publish a new post type "email only" that only goes out as an email newletter and is available through an undescoverable URL (does not appear anywhere publicly similarly to preview posts) on the site.
- The new "send" option in the post publishing menu allows to send this new type of post.
2021-10-07 12:07:48 +02:00
Peter Zimon
bbf1e79fbb Fixed yearly tiers URL in Portal settings
- added '/' to yearly tiers in Portal settings / Links
2021-10-07 11:49:25 +02:00
Peter Zimon
e244304538 Offer list and detail improvements
- added icon to offer value
- added link popup to list
- renamed "Delete offer" to "Archive offer"
2021-10-07 11:21:53 +02:00
Peter Zimon
b942029cc9 Added dynamic currency to offers form 2021-10-06 17:49:45 +02:00
Peter Zimon
7d61e7fda1 Added price to offers products 2021-10-06 17:11:35 +02:00
Rishabh
31e4b77525 Added initial wiring for offer screens
refs https://github.com/TryGhost/Team/issues/1084
refs https://github.com/TryGhost/Team/issues/1085

- adds model/validator/config and router for offers
- updates template for offer list and detail with dynamic values
- updated route handling for offer list and creation
- wires offer data from API to list and detail pages
2021-10-06 20:01:25 +05:30
Kevin Ansfield
12d85966c2 Fixed positioning of user menu
no issue

- CSS that was used to fix positioning of the dropdown menus on the labs theme list was too liberal. Fixed by adding a specific class for the theme list dropdowns
2021-10-06 15:29:42 +01:00
Kevin Ansfield
145211d875 Updated route-modal pattern for offer route
no issue

- match the updated pattern used in the `design` route
2021-10-06 09:31:42 +01:00
Kevin Ansfield
ef97be3ffb Fixed custom theme settings disappearing after save
refs https://github.com/TryGhost/Team/issues/1111

- on saving, `customThemeSettings.settings` was set to the `hasMany` reference on the `customThemeSettingsList` model instance but the model is then immediately unloaded and the reference goes with it
- switched to using `.toArray()` on the hasMany so that we get a stable reference to the `customThemeSetting` model instances
2021-10-05 21:45:11 +01:00
Kevin Ansfield
221db9f11e Fixed design preview and settings not updating when changing theme
refs https://github.com/TryGhost/Team/issues/1111

We now have a situation where we have modals on modals and we've lost the straightforward built-in "Data down, actions up" communication methods that we'd have workaround across nested routes/controllers. The upshot of that is we didn't have a way to trigger a refresh of the preview when a new theme was activated.

- moved the task responsible for fetching preview html from the design modal onto the `theme-management` service and adjusted it to set a tracked `previewHtml` property rather than updating an iframe directly
- added a `<GhHtmlIframe>` component that renders a basic iframe element and updates it's contents each time the `@html` argument changes
- updated design modal preview to use the new iframe component
2021-10-05 21:32:42 +01:00
Kevin Ansfield
640f028ae9 Fixed theme errors modal positioning
refs https://github.com/TryGhost/Team/issues/1111

- missed the modal classes on the newly added modal
2021-10-05 20:49:15 +01:00
Kevin Ansfield
715ee08100 Added advanced theme settings modal
refs https://github.com/TryGhost/Team/issues/1111

Extracted functionality for listing, downloading, activating, and deleting from the theme controller/template into separate components and services so that they are more composable/reusable in different situations.

- moved theme activation to a new `theme-management` service that uses the `modals` service to open the theme warnings modal or limits upgrade modal as required
  - the activate process is a task so that consumers can store a reference to the task instance and cancel it to close any related warning/limit modals (eg, when navigating away from the route or closing the modal that kicked off the process)
- created new-pattern modals for custom theme limit upgrade, theme errors, and delete confirmation so that we can treat them as promises and close where needed from parent
- duplicated theme table component as `<GhThemeTableLabs>` with an actions redesign and a refactor to handle download, activation, and deletion itself making use of the new theme-management service and modals
- fixed some oddities with design modal's transition/modal close handling by simplifying the async behaviour and being more explicit
- added advanced design modal that contains the new theme table component and linked to it from footer of design modal's sidebar
2021-10-05 20:44:27 +01:00
Kevin Ansfield
6155645a45 🐛 Fixed copy-to-clipboard buttons in Chrome + Firefox
no issue

- the method we used for copying text to the clipboard for older browsers has broken on some newer browsers
- the more modern `navigator.clipboard.writeText` API is now universally supported by our target browsers so we're able to switch to that instead which is working across the board
2021-10-05 15:32:23 +01:00
Kevin Ansfield
a15cc41f03 Removed unused blogUrl CP from theme controller
no issue

- general cleanup for easier functionality extraction to re-usable components
2021-10-05 14:37:51 +01:00
Kevin Ansfield
fe48f7ed80 Added utils service with downloadFile() method
no issue

- pattern of downloading a file by creating an iframe and setting the `src` attribute was repeated throughout the codebase and was using a mix of native and jQuery patterns
- added a `utils` service for housing one-off utility methods like this to avoid repetition and mixed patterns becoming more widespread (we want to get rid of jQuery usage)
2021-10-05 14:21:19 +01:00
Peter Zimon
611fbf5926 Added static URL to offers detail screen 2021-10-05 15:03:39 +02:00
Peter Zimon
24d28f3d79 Added static duration to Offers edit 2021-10-05 14:34:19 +02:00
Naz
349230f2f5 Removed commented post.save call in puglishmenu
refs https://linear.app/tryghost/issue/CORE-71/email-only-posts-hand-off

- The piece of code was commented out with an intention of keeping an existing pattern of only calling post's save's when edits are done in the editor or PSM. The changes in the publishmenu should not effect the model and have a need to save it
- The side-effect that still needs to be sorted is the change to the 'saveType' is effecting a model and causes a confirmation modal when leaving the post screen
2021-10-05 13:47:15 +02:00
Kevin Ansfield
2ca57e7624 Removed unused confirm-leave handling from theme settings screen
no issue

- appears to be left-over from copy/paste of an earlier screen re-structure
- cleaning up for easier extraction of functionality to new screens / modals
2021-10-05 11:37:17 +01:00
Kevin Ansfield
bf3a5198e4 Fixed missing return when opening modals
refs 37f721d76a

- change was missed from the previous commit 🤦🏻‍♂️ without it we don't get a modal reference back for managing confirmation and closing behaviour
2021-10-05 11:30:42 +01:00
Kevin Ansfield
37f721d76a Added centralized object for defining modal classNames
refs https://github.com/TryGhost/Team/issues/559

When modals are re-used across the app it's annoying to have to remember the class names that it uses in every location it's used.

- added a `DEFAULT_MODAL_OPTIONS` object to the modals service that's keyed on the modal to be opened and contains any options that are repeated across every instance
- overrode the `modals.open()` method to merge in the default options before calling `super()`
- updated invocation points of shared modals to remove duplicated class name options
2021-10-05 11:19:52 +01:00
Kevin Ansfield
f0f0498360 Fixed incorrect variable name for membership offer modal
no issue

- opened modal was assigned to `this.customizeModal` but the rest of the code expected `this.offerModal` so correct closing behaviour wasn't gauranteed
2021-10-05 11:09:40 +01:00
Naz
0af2c464b0 Fixed incorrect status showing up when sent post is updated
refs https://linear.app/tryghost/issue/CORE-79/editing-saving-a-post-that-has-already-been-sent-flashes-sent-as-the

- The mapping was wong in a previous version - when the status changes from 'sent' to 'sent' the notification box should show 'Updated' instead of 'sent', doh!
2021-10-05 23:01:52 +13:00
Daniel Lockyer
a0caf5531d Merged v4.17.1 into main
v4.17.1
2021-10-05 08:33:17 +01:00
Daniel Lockyer
59f32123e2 v4.17.1 2021-10-05 08:31:40 +01:00
Kevin Ansfield
745784e216 Removed secondary accent color picker
refs https://github.com/TryGhost/Team/issues/1102

- we're not sure this should be a built-in default setting at the moment so dropping the (non-working) color picker from the template for now
- same feature can be implemented by themes via custom settings if they want to use a secondary color
2021-10-04 18:20:42 +01:00
Kevin Ansfield
cb24eb3827 Fixed background flicker when opening design modal
refs https://github.com/TryGhost/Team/issues/1111

- added override of the `ember-promise-modals` container component so that it doesn't render the background element when `omitBackground` is passed as an option when opening the modal
- fixes the flicker by not having a dark background transition in whilst the white overlay modal is also transitioning in from transparent->opaque
2021-10-04 18:15:11 +01:00
Kevin Ansfield
463a1ea763 Fixed Slack integration test
refs 63b1e1d385

- test was using an old `/settings/design` route as something to navigate away to but the behaviour no longer matched the test expectations
- switched to using `/settings` as a more stable route
2021-10-04 16:46:37 +01:00
Kevin Ansfield
63b1e1d385 Dropped intermediate design screen and moved to full-overlay modal
refs https://github.com/TryGhost/Team/issues/1111
refs https://github.com/TryGhost/Team/issues/1103

- moved customize modal from a link on the design screen to the main design screen
- changed modal design to be a full-screen overlay with side bar that emulates standard Admin design
- added toggled groups of settings in sidebar
  - added `{{set-has}}` helper for use in conditionals matching when a Set contains an object
  - added grouping of theme settings
- dropped unfinished advanced/change theme modals
2021-10-04 16:34:28 +01:00
Peter Zimon
54447eae4b Added price to offers list 2021-10-04 17:07:13 +02:00
Peter Zimon
84c9123bfd Added mock content for offers list help 2021-10-04 16:17:32 +02:00
Peter Zimon
713fa7725a Added static offer help links 2021-10-04 15:42:05 +02:00
Peter Zimon
5343b9f6b5 Added unit to offer value 2021-10-04 15:21:28 +02:00
Peter Zimon
96ec92a47b Update offer details structure
- Added static UI to offer details page
- Deleted offer modal
2021-10-04 15:00:41 +02:00
Peter Zimon
6e6c89ba00 Updated offers list heading 2021-10-04 13:58:58 +02:00
Kevin Ansfield
5966342223 Converted <GhNavMenu> to glimmer component
no issue

- moves tag name and class into the component template for better visibility
- removed unused `isSettingsRoute` computed property
2021-10-04 12:57:30 +01:00
Peter Zimon
3013263498 Added static UI for offers list
- Added list and basic empty screen for offers list
- Removed offers list from Membership settings
2021-10-04 13:55:17 +02:00
Peter Zimon
390b2b136f Added base files for Offers structure
- Moving Offers outside settings to main menu
- Moving Integrations and Staff to settings
2021-10-04 13:01:12 +02:00
Peter Zimon
2eb0e465c2 Adjusted settings grid 2021-10-04 12:03:41 +02:00
Rishabh
bb79ff7a9a Fixed unintended save for published post on tier change
no refs

- selecting a tier in post access for a published post was also triggering a save which is not intended
- save should happen only for a draft post when changing tier for post access
2021-10-04 13:02:45 +05:30
Daniel Lockyer
230d99767f v4.17.0 2021-10-01 16:00:30 +01:00
Rishabh
bee3dd8bcd Fixed bulk delete members list test
no refs

- removes temporary comment on bulk delete member test as its updated to work with filtering in GA
2021-10-01 19:27:31 +05:30
Fabien O'Carroll
592e3df794 Added Members Filtering feature
no-issue

This adds the ability to apply complex filters to members, as well as to
perform bulk actions on the filtered set, including unsubscribing,
adding & removing labels.
2021-10-01 14:16:28 +02:00
Fabien O'Carroll
a5f158c061 Updated usage of the members bulk action endpoint
refs https://github.com/TryGhost/Team/issues/1077

The bulk action endpoint has updated the request body format and so this
must be updated to continue to work with it.
2021-10-01 14:14:38 +02:00
Kevin Ansfield
9dcd7e499a Fixed unsaved general settings being lost when switching to theme tab
no issue

- copy pasta for the general settings form meant that unsaved settings changes were rolled back when the form was destroyed meaning settings were lost when switching across to the theme settings tab
- rollback is handled higher up at the custom design modal so we don't need to handle it in the form
2021-09-30 16:47:08 +01:00
Kevin Ansfield
aa5b0705e0 Fixed "(default)" not showing next to default custom theme select options
no issue

- default option conditional was missing the `@` on the passed in argument so was always evaluating to `false`
2021-09-30 16:31:44 +01:00
Kevin Ansfield
179855ae38 Fixed unexpected unsaved changes modal when saving custom theme settings
no issue

- `customThemeSettings.settings` was not being updated with the latest models after saving so `customThemeSettings.isDirty` was still reporting `true` even though the save had completed
2021-09-30 16:29:41 +01:00
Kevin Ansfield
e8933ff7a8 Wired description field changes in design settings to preview
closes https://github.com/TryGhost/Team/issues/1101

- added `d` param with the description value to the preview header
- updated description input to trigger preview update on blur
2021-09-30 16:27:57 +01:00
Kevin Ansfield
6993e11286 Fixed close button in confirm modal causing navigation
no issue

- using an `<a>` instead of a `<button>` meant that the anchor link's default behaviour was being triggered when clicked leading to the browser navigating back to the dashboard
2021-09-30 16:26:20 +01:00
Kevin Ansfield
223e5c71cf Fixed error when saving custom design modal
no issue

- `Promise.all()` requires a promise so it was erroring about uniterable symbols
2021-09-30 14:53:39 +01:00
Aileen Nowak
a83bd7a749 Fixed typo w/ removing subscription overdue notification
no issue
2021-09-30 14:16:05 +01:00
Aileen Nowak
dcabd345bc Closed subscription notification when not applicable
no issue
2021-09-30 14:11:44 +01:00
Aileen Nowak
3ec373e33f Show notifications for overdue subscriptions and exceeded limits
no issue

- Overdue subscriptions: when a subscription is in overdue state, we'd like to inform the customers so that the owner is aware and can take action
- Exceeded limits:
    - Show a warning when the members limit is exceeded so users are aware before trying to publish a post and hitting the limit
    - Allow to redirect directly to a child route in the Ghost(Pro) app, so plan updates get easier
2021-09-30 14:00:32 +01:00
Kevin Ansfield
dab672c7b8 Wired up custom theme settings form to preview updates
refs https://github.com/TryGhost/Team/issues/1097

- added `customThemeSettings.keyValueObject` which returns a plain object with setting values assign to the setting keys on the object
- updated customize modal's preview data generation to use `customThemeSettings.keyValueObject` to assign a JSON-stringified version to the `custom` param on the `x-ghost-preview` header
- updated theme settings `<Select>` component to call the passed through `updatePreview()` action when the value changes
2021-09-30 13:30:06 +01:00
Rishabh
4b8b635306 Refined offers modal to include tier-cadence dropdown
refs https://github.com/TryGhost/Team/issues/1085

- maps the tier-cadence dropdown to correct tier list for site
- adds dynamic toggle between type of discounts in UI
2021-09-30 14:23:32 +05:30
Rishabh
9a07c59538 🐛 Fixed incorrect unsaved changes popup on memberships screen
closes https://github.com/TryGhost/Team/issues/1100

- fixes unsaved changes popup which was triggered due to incorrect price comparison on membership screen
- issue only happened if the stripe price entered translated to a decimal value as the price change check was parsing it as integer
2021-09-30 14:21:55 +05:30
Kevin Ansfield
d10e102de4 Wired up saving of custom theme settings
refs https://github.com/TryGhost/Team/issues/1070

- split select form component into it's own component so it's cleaner when we get to additional setting types
  - added change handler that updates the setting record's value when a new option is selected
- added `.isDirty` to the custom-theme-settings service so we can warn of unsaved changes and revert any changed values when needed
- added save of custom theme settings to the customize design modal's save routine
- added missing `notifications` service import to customize design controller
2021-09-28 16:50:28 +01:00
Kevin Ansfield
1e8e0485e3 Added customThemeSettings service with all-records-in-one save request
refs https://github.com/TryGhost/Team/issues/1070

- adds a `customThemeSettings` service that handles overall setting loading and saving to avoid components having to know any of the intricacies of the model setup
- adds `custom-theme-setting-list` model so that we can save multiple setting records as embedded relations
  - custom adapter ensures requests go to the `/custom_theme_settings` base route as a `PUT` request
  - custom serializer drops the default `models: []` wrapper in the save request data so the format matches the `PUT /settings` endpoint, then converts the response to look like a `custom-theme-setting-list` response
2021-09-28 16:50:28 +01:00
Sanne de Vries
57b1a344f0 Updated publish-menu Sent status in editor 2021-09-28 15:49:50 +02:00
Sanne de Vries
62bae57eac Fixed email-only button CTA in email send confirmation modal 2021-09-28 15:29:29 +02:00
Peter Zimon
d0457c0c32 Fixed tags list link color 2021-09-27 17:15:59 +02:00
renovate[bot]
491db676d9 Update dependency glob to v7.2.0 (#2095)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-09-27 11:33:47 +01:00
renovate[bot]
a5cb9a1e13 Update dependency @sentry/ember to v6.13.2 (#2093)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-09-27 11:33:36 +01:00
Kevin Ansfield
c4d6950ba9 Wired up custom theme settings display (#2096)
refs https://github.com/TryGhost/Team/issues/1070
reqs https://github.com/TryGhost/Ghost/pull/13362

- added custom theme setting model
- added fetch of custom theme settings when customize modal is opened
- used loaded theme settings to populate settings list in theme settings tab
- hid the general/theme toggle when no theme settings are present
2021-09-27 11:32:48 +01:00
Peter Zimon
f790e7df52 Added placeholders to Offers static modal 2021-09-27 12:02:29 +02:00
renovate[bot]
ef509e215a Update dependency blueimp-md5 to v2.19.0 (#2098)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-09-27 09:46:28 +01:00
renovate[bot]
ce7619e169 Update dependency ember-simple-auth to v4.0.1 (#2097)
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-09-27 09:45:48 +01:00
Kevin Ansfield
23d7aeb764 Fixed API path generation for multi-segmented model names
no issue

- if a model name has multiple segments, eg `custom-setting` then the URL generated was `/customSettings/` rather than `/custom_settings/`
2021-09-23 23:52:50 +01:00
Kevin Ansfield
7430c28001 Fixed error when opening design settings screen
no issue

- `{{did-insert}}` was left over from copy/paste but the referenced function wasn't copied so was erroring
2021-09-23 22:53:09 +01:00
Daniel Lockyer
bb8a07bc6a v4.16.0 2021-09-23 16:04:56 +01:00
Peter Zimon
7783452aeb Added static Offer form inputs 2021-09-23 13:12:01 +02:00
Peter Zimon
dce39c8a91 Minor style change in Offers 2021-09-23 12:33:19 +02:00
Daniel Lockyer
f4c11c0f03 Merged v4.15.1 into main
v4.15.1
2021-09-23 11:05:50 +01:00
Daniel Lockyer
d83dd3a6af v4.15.1 2021-09-23 10:51:29 +01:00
Sanne de Vries
182f5c91b6 Updated design settings page
Refs https://github.com/TryGhost/Team/issues/1045
2021-09-23 10:16:28 +02:00
Kevin Ansfield
1ce3e370d1 Bumped fork/hash of ember-promise-modals fork
no issue

- having problems with `yarn` pulling incorrect version from cache resulting in modals not closing due to missing functionality
2021-09-22 16:54:18 +01:00
Peter Zimon
6ee2e48c92 Added static list of offers 2021-09-22 17:23:26 +02:00
Peter Zimon
d8c42876a3 Added base files for Offer modal 2021-09-22 16:10:38 +02:00
Peter Zimon
01524cb735 Added offers Alpha flag 2021-09-22 13:20:15 +02:00
Peter Zimon
4dcc594193 Added static offers CTA to membership settings 2021-09-22 13:10:59 +02:00
Kevin Ansfield
ba030ec2ae Fixed preview flicker when moving between general and theme settings
refs https://github.com/TryGhost/Team/issues/1045

- update of the preview was being triggered by the general settings tab rendering (copy/paste from branding setup) meaning the iframe reloaded when switching between general/theme tabs
- moved the preview update task into the `customize` modal so that it can be called by the general/theme settings components as needed
- moved initial preview rendering to the iframe registration method
2021-09-21 16:15:23 +01:00