Commit Graph

9182 Commits

Author SHA1 Message Date
Simon Backx
6adecb5db1 Removed newsletter name from activity feed if no multiple newsletters
refs https://github.com/TryGhost/Team/issues/1563

- Check if we have multiple newsletters in the members-events-fetcher
- Pass the resulting value to the `parse-member-event` helper
- Pass the value to the activity feed table and table-row components
2022-05-04 10:23:32 +02:00
Peter Zimon
300cd79d3e Updated Dashboard spacings 2022-05-03 17:08:30 +02:00
Peter Zimon
3996455aa1 Updated minicharts positions 2022-05-03 16:34:17 +02:00
Peter Zimon
d0a77a48ba Dashboard typography cleanup 2022-05-03 16:26:05 +02:00
Simon Backx
a3218b0a2b Improved newsletter activity feed copy
refs https://github.com/TryGhost/Team/issues/1570
refs https://ghost.slack.com/archives/C02G9E68C/p1651581277636729?thread_ts=1651569897.474819&cid=C02G9E68C

Activity feed now shows 'Subscribed to newsletter – Weekly newsletter" text
2022-05-03 14:37:45 +02:00
Simon Backx
5c6316f051 Fixed linting error 2022-05-03 14:25:50 +02:00
Simon Backx
da3b3850f5 Added the newsletter name to the activity feed
refs https://github.com/TryGhost/Team/issues/1563

- When a member (un)subscribes to a specific newsletter, we should add the name of the newsletter.
- Replaced CSS lowercase/first uppercase transform with a new HBS helper so we can maintain the caps in the newsletter names.
- Copy is still WIP, refs https://ghost.slack.com/archives/C02G9E68C/p1651569897474819
2022-05-03 14:24:18 +02:00
Fabien 'egg' O'Carroll
94ae33858d Fixed mergeDates zero and one item in list (#2360)
The exit clause of the mergeDates function should return an array rather
than an object, to ensure that an array is always returned. Because we
are using the concat method when recursing, this continues to work for
longer lists.

We want to return an empty array if list is empty, this protects against
returning [undefined]
2022-05-03 12:01:23 +01:00
Peter Zimon
c2102477a7 Updated Resources design on Dashboard 2022-05-03 12:21:30 +02:00
Simon Backx
21fd205073 Fixed newsletters limited to 15 items
refs https://github.com/TryGhost/Team/issues/1565

If you had more than 15 newsletters we hit default pagination in the API and Admin didn't show any more.
2022-05-03 09:01:41 +02:00
Simon Backx
7ad8f63b22 Fixed linting errors and removed debug log 2022-05-02 10:52:27 +02:00
Simon Backx
fdf425d95a Added dynamic filter for resources
refs https://github.com/TryGhost/Team/issues/1572

- Depending on the state of the site, other resources are shown.
- Also cleaned up error catching.
2022-05-02 10:45:15 +02:00
Simon Backx
625635c6ed Added tag filter to newsletter resources module
refs https://github.com/TryGhost/Team/issues/1572

When fetching the newsletters, other resources were included. Now we filter
on the newsletter tag so we only include newsletter and not normal resources.
2022-05-02 10:22:01 +02:00
Sanne de Vries
814f9043aa Updated publish settings page
Refs https://github.com/TryGhost/Team/issues/1544
2022-05-02 08:50:48 +01:00
James Morris
8c692b1d73 Fixed linting bugs and tweaked mini chart starting heights
refs: https://github.com/TryGhost/Team/issues/1531
2022-04-28 17:55:36 +01:00
James Morris
fcd11fe471 Fixed the resources section to pull the latest
refs: https://github.com/TryGhost/Team/issues/1531
2022-04-28 17:16:40 +01:00
Sanne de Vries
88e10f2305 Updated publish settings page
Refs https://github.com/TryGhost/Team/issues/1544
2022-04-28 16:46:58 +01:00
James Morris
059ad77939 Tons of tweaks based on feedback for new Dashboard
refs: https://github.com/TryGhost/Team/issues/1531
2022-04-28 16:40:27 +01:00
Peter Zimon
f81801549b Updated copy for Dashboard resources 2022-04-28 17:33:26 +02:00
Peter Zimon
5c71448575 Udpated resources section on dashboard 2022-04-28 17:18:17 +02:00
Peter Zimon
3b3140a002 Updated resources section 2022-04-28 16:48:22 +02:00
Kevin Ansfield
f28320abae Added confirmation step to new publish flow
refs https://github.com/TryGhost/Team/issues/1542

- added `willPublish` and `willEmail` convenience getters to `PublishOptions`
- added confirmation step that is switched to when clicking the Continue button in the publish flow
- separated options and confirmation steps into discrete components used by the `publish-flow` modal
2022-04-28 15:36:01 +01:00
Kevin Ansfield
357bbf56cf Fixed PublishOptions newsletter setup
refs https://github.com/TryGhost/Team/issues/1542

- assigning the result of `peekAll('newsletter').filter()` to `newsletters` doesn't work because the live peekAll array gets transformed to a static array so it was always blank
  - assigned result of `peekAll('newsletter')` to `allNewsletters` and replaced `newsletters` property with a getter that uses `allNewsletters` to return an array of filtered and sorted newsletters
- fixed incorrect sort order for `defaultNewsletter`
- assigned default newsletter to tracked `newsletter` property as part of setup once newsletters have been fetched
- updated publish-flow template to show a real count and newsletter name
2022-04-28 15:36:01 +01:00
Daniel Lockyer
7ea5bdcdf8 Fixed success button state for POST ../email_previews/..
refs https://github.com/TryGhost/Toolbox/issues/308

- this endpoint is being switched to return a 204 with no body upon success
- if we don't change this code, the button will get stuck in a red Retry
  state because it reads the `undefined` body and thinks it's an error
- this commit makes sure we return true if the POST is successful
2022-04-28 15:33:10 +01:00
Daniel Lockyer
e1f05ed126 Renamed reset_all_passwords Authentication API endpoint to /global_password_reset
refs https://github.com/TryGhost/Toolbox/issues/308

- our API has a pattern of using nouns and not verbs for the endpoint
  names, so this changes the endpoint for v5
2022-04-28 15:33:09 +01:00
Daniel Lockyer
1068070bd2 Renamed passwordreset body object to password_reset
refs https://github.com/TryGhost/Toolbox/issues/308

- I've just renamed the endpoint to `password_reset` but we might as
  well change the body object to make the change in v5 too
2022-04-28 15:33:09 +01:00
Daniel Lockyer
5aa5770791 Renamed /passwordreset authentication API endpoint to /password_reset
refs https://github.com/TryGhost/Toolbox/issues/308

- we have a pattern of splitting words via an underscore in the API, so
  v5 splits apart `passwordreset` to `password_reset`
- I'll follow up whether we want to fixup the `passwordreset` body
  object
2022-04-28 15:33:09 +01:00
Daniel Lockyer
bc6ce7a2dd Renamed /email_preview endpoint to /email_previews
refs https://github.com/TryGhost/Toolbox/issues/308

- we have a pattern of using plurals for endpoints but `email_preview`
  was implemented without it
- in v5, we're fixing that so we need to update Admin to take that into
  account
2022-04-28 15:33:09 +01:00
Daniel Lockyer
d0ce852ded v4.46.0 2022-04-28 15:29:17 +01:00
Sanne de Vries
b23dc541c5 Fixed tooltip overflowing in edit-newsletter modal 2022-04-28 14:47:47 +01:00
Peter Zimon
b825096213 Fixed Activity feed header 2022-04-28 15:28:56 +02:00
Sanne de Vries
d3ca3eb47c Hid subscriber and post count behind multiple-newsletter-UI flag 2022-04-28 13:44:44 +01:00
Sanne de Vries
699e977a34 Fixed email footer textarea overflowing in newsletter modal
No issue
2022-04-28 13:40:22 +01:00
Simon Backx
d25b94fb77 Fixed sender name and email in email preview link
refs https://github.com/TryGhost/Team/issues/1568

Sender name and email of newsletter was not used in the preview.
2022-04-28 12:01:25 +02:00
Simon Backx
2a5fe4b7db Fixed email preview sender name and email
refs https://github.com/TryGhost/Team/issues/1568

Email and sender name were not fetched from the default newsletter
2022-04-28 11:52:42 +02:00
Simon Backx
9b87b4c40a Added basic newsletter creation test
refs https://github.com/TryGhost/Team/issues/1477

- Very basic test only
- Includes some extra test attributes in the components
- Commented out a test that was not yet fininished
2022-04-28 10:50:27 +02:00
Peter Zimon
fb5f263ace Email settings design update (#2359)
Updated Email settings and Portal settings design to make it more scalable and more consistent with the rest of the Admin.
2022-04-28 10:24:12 +02:00
Kevin Ansfield
43d417858a Switched publish flow dropdowns to expanding blocks and added publish time options
refs https://github.com/TryGhost/Team/issues/1542

- moved publish-flow modal into `components/editor-labs/modals/publish-flow` as we have enough editor-related components to keep them in one place
- updated publish flow design to use expanding blocks in place of dropdowns
  - added `openSection` property in publish-flow modal and associated action for toggling sections
  - moved "publish at" option into a separate component to keep publish-flow modal cleaner (keeps option-specific actions out of the main modal component)
  - used `{{liquid-if}}` to animate the expanding blocks
- added schedule time properties to `PublishOptions`
  - kept "is scheduled" and "scheduled at" separate so it's possible to keep the selected schedule time across selecting/deselecting the option to schedule
  - ensures schedule date is kept to the minimum 5-minute in the future across option changes
  - updated publish-management to reset the scheduled option to "Right now" when the publish-flow modal is opened if a schedule time was previously set but is now in the past
2022-04-27 18:21:01 +01:00
James Morris
38a26e8760 Added in basic loading states for charts and some layout and copy tweaks
refs: https://github.com/TryGhost/Team/issues/1531

- charts now have basic working loading states, could be improved though
- trying out staff picks description and layout tweaks
- lots of small design tweaks based on feedback
2022-04-27 17:25:46 +01:00
James Morris
ef4321d707 Fixed the gradient for MRR for new Dashboard in light mode
refs: https://github.com/TryGhost/Team/issues/1531
2022-04-27 15:38:58 +01:00
Fabien 'egg' O'Carroll
b0a875f733 Wired up subscription stats api (#2350)
refs https://github.com/TryGhost/Team/issues/1512

Adds the new endpoint `/stats/subscriptions/` which provides data for
the paid mix and paid breakdown charts.

Made the filledMissingDates function more generic by passing in a
`copyData` function which is used to populate a date from the previous
days data, if the data for that date is missing.
2022-04-27 15:11:01 +01:00
James Morris
e5d5e359d7 Fixed layout bugs with new dashboard charts
refs: https://github.com/TryGhost/Team/issues/1531

- investigated how to make the layout not break on resize
- using a width 99% hack to make chartjs react properly
- redid the markup for the minicharts for more stable loading
- added in a subtle gradient for the mrr minichart
2022-04-27 14:40:44 +01:00
Sanne de Vries
ccd722a5f7 Updated disabled newsletter dropdown in scheduled state of publish menu 2022-04-27 11:16:39 +01:00
Peter Zimon
7392457fc5 Deleted newsletter confirmation modal 2022-04-27 11:56:30 +02:00
Kevin Ansfield
7099e9e0b6 re-organised newsletter modal components 2022-04-27 11:52:17 +02:00
Kevin Ansfield
c4ad61ac0f Added disabled newsletter dropdown to scheduled state of publish menu (#2357)
no issue

If you scheduled a post to a specific newsletter it was no longer visible in the scheduled state of the publish menu making it difficult to know the behaviour when coming back to a scheduled post.

- duplicated the newsletter dropdown from the draft to the scheduled state components and disabled it the same as the other recipient options
- added temporary workaround for missing newsletter embed for the posts endpoint in the API
  - adds `newsletterId` attribute to the post model
  - uses `post.newsletterId` to find the matching newsletter model from the available newsletters list
2022-04-27 10:49:55 +01:00
Kevin Ansfield
404d3c44cf Switched to a minimal form when creating a newsletter (#2356)
no issue

The full edit newsletter form with all the settings, design options, and preview felt quite overwhelming when the only piece of data that's required to create a newsletter is the name.

- re-organised the newsletter modal components by renaming `modals/edit-newlsetter` to `modals/newsletters` to better represent the full suite of modals that are used in newsletter management
- added a `modals/newsletters/new` component containing a minimal form with name/description/opt-in-existing fields
- switched the `new-newsletter` route to open the new modal rather than the previous dual-purpose edit modal
- moved message about newsletter creation into the create modal and dropped the separate create confirmation modal
- dropped unnecessary unsaved-changes confirmation
- removed the now-unused opt-in-existing behaviour from the edit newsletter modal

Co-authored-by: Peter Zimon <peter.zimon@gmail.com>
2022-04-27 10:36:43 +01:00
Sanne de Vries
76ec5bef46 Fixed linter error 2022-04-27 10:17:16 +01:00
Sanne de Vries
75a51d6a8f Updated publish settings page design
Refs https://github.com/TryGhost/Team/issues/1544
2022-04-27 10:08:40 +01:00
James Morris
a5de8c76d6 Working on custom tooltips for new Dashboard
refs: https://github.com/TryGhost/Team/issues/1534
2022-04-26 18:57:01 +01:00