Ghost/test/unit/helpers
Kevin Ansfield 7b1aa38841
🐛 Fixed AMP validation warning from accent color style tag (#12771)
closes https://github.com/TryGhost/Ghost/issues/12770

AMP pages can't contain bare `<style>` tags, they need to have an attribute like `<style amp-custom>` and there can only be a single `<style amp-custom>` tag in the output.

- removed accent color style tag output from `{{ghost_head}}` (aliased as `{{amp_ghost_head}}`) when in an AMP context
- added a new `{{amp_style}}` helper that can be used to inject styles into the AMP template
  - outputs `:root {--ghost-accent-color: #abc123}` style if an accent color is set
2021-03-17 11:49:42 +00:00
..
test_tpl Updated {{content}} helper partial template name 2021-02-09 13:59:52 +05:30
asset_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
author_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
authors_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
body_class_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
cancel_link_spec.js Moved labs usage into cancel_link helper file 2020-04-08 19:31:55 +01:00
concat_spec.js Move tests from core to root (#11700) 2020-03-30 16:26:47 +01:00
content_spec.js Added paywall card to mark end of free content preview (#12663) 2021-02-17 23:00:26 +00:00
date_spec.js Updated default format for date helper to locale-based date string (#12733) 2021-03-05 13:35:31 +00:00
encode_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
excerpt_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
facebook_url_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
foreach_spec.js Updated default visibility in foreach for posts to all 2021-03-02 15:44:19 +05:30
get_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
ghost_foot_spec.js Updated tests that were stubbing old ghost_head/ghost_foot settings keys 2020-07-01 17:58:12 +01:00
ghost_head_spec.js 🐛 Fixed AMP validation warning from accent color style tag (#12771) 2021-03-17 11:49:42 +00:00
has_spec.js Fixed "no-shadow" eslint warning in tests 2020-10-19 17:45:26 +13:00
img_url_spec.js Moved core/server/lib/common/logging to core/shared/logging (#11857) 2020-05-28 19:30:23 +01:00
is_spec.js Moved core/server/lib/common/logging to core/shared/logging (#11857) 2020-05-28 19:30:23 +01:00
lang_spec.js Updated default format for date helper to locale-based date string (#12733) 2021-03-05 13:35:31 +00:00
link_class_spec.js Move tests from core to root (#11700) 2020-03-30 16:26:47 +01:00
link_spec.js Move tests from core to root (#11700) 2020-03-30 16:26:47 +01:00
meta_description_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
meta_title_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
navigation_spec.js 🐛 Fixed logic error in navigation for isSecondary 2020-05-18 19:15:28 +01:00
next_post_spec.js Migrate the default api version from v2 to v3 2021-02-03 15:02:51 +01:00
page_url_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
pagination_spec.js Updated links to ghost.org sites 2021-01-20 09:59:45 +13:00
plural_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
post_class_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
prev_post_spec.js Migrate the default api version from v2 to v3 2021-02-03 15:02:51 +01:00
price_spec.js Updated price helper to output well formatted prices 2021-02-25 13:01:24 +05:30
raw_spec.js Added raw handlebars helper 2020-04-06 17:26:50 +01:00
reading_time_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
t_spec.js 🐛 Fixed incorrect locale loading when changing themes 2021-01-04 17:26:22 +13:00
tags_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
title_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
twitter_url_spec.js Updated var declarations to const/let and no lists 2020-04-29 16:51:13 +01:00
url_spec.js Fixed "no-shadow" eslint warning in tests 2020-10-19 17:45:26 +13:00