Commit Graph

2 Commits

Author SHA1 Message Date
Kevin Ansfield
6dc733ae3a Fixed <GhEmailPreviewLink> default text and whitespace
refs 21f2a58a8a

- passed in arg is `@data` not `@email` because it can be an email or post object
- added `~` handlebars syntax to collapse white-space so links can be surrounded by other chars without spaces being visible, eg `"<GhEmailPreviewLink />"`
2022-01-25 13:27:58 +00:00
Kevin Ansfield
21f2a58a8a Refactored post email preview modal
refs https://github.com/TryGhost/Team/issues/559
refs https://github.com/TryGhost/Team/issues/1277

- switched modal implementation to the newer promise-modal style
- added `<GhEmailPreviewLink>` component that renders a link that when clicked opens the modal
  - removes the need for templates/controllers to manually handle modal opening/closing and to pass actions down from parents
  - updated all places we were triggering an email preview modal to use `<GhEmailPreviewLink>`
2022-01-25 13:17:05 +00:00