Commit Graph

28 Commits

Author SHA1 Message Date
Renovate Bot
9223d9d1ae Update dependency sinon to v13 2022-01-31 00:29:57 +00:00
Renovate Bot
0da6639d63 Update dependency mocha to v9.2.0 2022-01-24 12:09:30 +00:00
Renovate Bot
1fd73d9429 Update Test & linting packages 2022-01-20 16:21:37 +00:00
Renovate Bot
0649cf36c9 Pin dependency @nexes/nql to 0.6.0 2022-01-20 14:27:59 +00:00
Renovate Bot
5a145de5b9 Update dependency c8 to v7.11.0 2022-01-20 14:22:54 +00:00
Renovate Bot
d8196129cb Update dependency mocha to v9.1.4 2022-01-14 20:50:48 +00:00
Kevin Ansfield
8eeefab2e1 Published new versions
- @tryghost/custom-theme-settings-service@0.3.1
 - @tryghost/email-analytics-provider-mailgun@1.0.5
 - @tryghost/email-analytics-service@1.0.4
2021-10-26 10:15:36 +01:00
Kevin Ansfield
5c2f25d016 Fixed "Error parsing filter" when a theme name contains . chars
no issue

- we were passing the theme name directly in the model query filter string without any surrounding `'` chars meaning we were generating invalid filters
2021-10-26 10:14:39 +01:00
Renovate Bot
3399769cc9 Update dependency c8 to v7.10.0 2021-10-21 15:24:51 +02:00
Daniel Lockyer
73f21a5065 Added codecov.io coverage uploader to CI
refs https://linear.app/tryghost/issue/CORE-74/improve-the-test-situation

- this commit adds the codecov GitHub Action into CI so we can upload
  coverage reports
- the coverage files need to be in XML for them to work with
  codecov, so this commit also adds cobertura (XML) as a reporter
2021-10-20 14:36:35 +02:00
Kevin Ansfield
106f26eece Published new versions
- @tryghost/custom-theme-settings-service@0.3.0
2021-10-20 13:19:51 +01:00
Thibaut Patel
38e9f84d41 Published new versions
- @tryghost/custom-theme-settings-service@0.2.0
 - @tryghost/email-analytics-provider-mailgun@1.0.4
 - @tryghost/email-analytics-service@1.0.3
2021-10-20 11:46:57 +02:00
Renovate Bot
63668b8df3 Update dependency mocha to v9.1.3 2021-10-20 06:31:15 +00:00
Naz
1579d7f3ed Published new versions
- @tryghost/custom-theme-settings-service@0.1.2
 - @tryghost/email-analytics-provider-mailgun@1.0.3
2021-10-11 17:16:38 +02:00
Renovate Bot
c034eecb41 Pin dependency sinon to 11.1.2 2021-10-11 01:47:57 +00:00
Kevin Ansfield
265d18aeda Published new versions
- @tryghost/custom-theme-settings-service@0.1.1
2021-10-08 15:43:36 +01:00
Kevin Ansfield
43adbccb3a Published new versions
- @tryghost/custom-theme-settings-service@0.1.0
2021-10-07 16:58:21 +01:00
Kevin Ansfield
88fc9c7964 Added tests for Service class, fixed error when throwing invalid option error
refs https://github.com/TryGhost/Team/issues/1104

- there was a mismatch of template options when throwing error on invalid select value meaning we were erroring but with the wrong error type and message
- added missing `lodash` dependency in package.json
2021-10-07 16:57:52 +01:00
Kevin Ansfield
ae83e5bbf3 Published new versions
- @tryghost/custom-theme-settings-service@0.0.6
2021-10-04 12:14:33 +01:00
Kevin Ansfield
5e40a03336 Published new versions
- @tryghost/custom-theme-settings-service@0.0.5
 - @tryghost/email-analytics-provider-mailgun@1.0.2
 - @tryghost/email-analytics-service@1.0.2
2021-09-28 15:51:13 +01:00
Kevin Ansfield
bc31453dde Added .updateSettings() to custom theme settings service
refs https://github.com/TryGhost/Team/issues/1070

- receives settings array as provided by through Ghost's API
- errors if a provided setting key does not already exist in the database (settings are only created when syncing with a theme)
- errors if a provided select setting value does not match the theme-provided options
- providing there were no errors, updates each value in the database if it's changed along with the internal cache of full setting objects and the public key/value cache
- returns the same list of settings as `.listSettings()` for API consistency
2021-09-28 15:50:46 +01:00
Renovate Bot
372e89f8ce Update dependency mocha to v9.1.2 2021-09-28 08:59:37 +00:00
Kevin Ansfield
d3e8033b1f Published new versions
- @tryghost/custom-theme-settings-service@0.0.4
2021-09-23 23:42:04 +01:00
Kevin Ansfield
1733041c8f Published new versions
- @tryghost/custom-theme-settings-service@0.0.3
2021-09-23 20:35:36 +01:00
Kevin Ansfield
e98b9d764d Published new versions
- @tryghost/custom-theme-settings-service@0.0.2
2021-09-23 09:17:25 +01:00
Kevin Ansfield
0f5ccb7131 Published new versions
- @tryghost/custom-theme-settings-service@0.0.1
 - @tryghost/email-analytics-provider-mailgun@1.0.1
 - @tryghost/email-analytics-service@1.0.1
2021-09-22 22:00:51 +01:00
Kevin Ansfield
cf9cee0208 First pass at custom-theme-settings-service functionality
refs https://github.com/TryGhost/Team/issues/1070

- added `bread` util that acts as a wrapper for the provided model, if we have any business functionality needed when settings are added/removed then it will go here
- added primary "server" service that handles syncing of custom theme data extracted from a theme with the settings that are in the database and exported as "Service". Syncing rules on theme activation:
    - if a new setting is seen, create it with the default value
    - if a setting has it's type changed, remove it and create a new setting with the default value
    - if a select setting's value is not a valid option, reset it to the default value
- added shared "frontend/server" service that exposes an in-memory cache of key/value pairs for the currently active theme
2021-09-22 21:56:45 +01:00
Kevin Ansfield
56012f5f21 slimer new custom-theme-settings-service 2021-09-21 17:21:52 +01:00