0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-03 23:00:14 -05:00
ghost/test/unit/services/theme-engine
Kevin Ansfield b8e2bb7b6d Allowed custom theme settings to be passed through preview data
refs https://github.com/TryGhost/Team/issues/1097

- added `customThemeSettingKeys` as an argument to `preview.handle()` because we can't know which keys should be allowed through up-front
- added `custom` as a supported setting in the preview header data
  - `custom` should be a JSON object containing any custom theme settings
  - we parse the object but only set properties on `@custom` that are known custom theme setting keys
  - if parsing fails or it's not an object then no custom data is set
- updated `updateLocalTemplateOptions()` to pull `.custom` off of the preview data and pass it through so it's accessible on `@custom` as an override to the saved custom data
2021-09-30 13:23:39 +01:00
..
engines Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
handlebars Divided f/e proxy into true proxy + rendering service 2021-09-29 13:10:14 +01:00
active.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
config.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
i18n.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00
middleware.test.js Allowed custom theme settings to be passed through preview data 2021-09-30 13:23:39 +01:00
preview.test.js Renamed tests to .test.js & updated commands 2021-07-06 20:45:01 +01:00