discourse/spec/fixtures
Alan Guo Xiang Tan 7bcfe60a76
DEV: Validate default value for type: objects theme settings (#25833)
Why this change?

This change adds validation for the default value for `type: objects` theme
settings when a setting theme field is uploaded. This helps the theme
author to ensure that the objects which they specifc in the default
value adhere to the schema which they have declared.

When an error is encountered in one of the objects, the error
message will look something like:

`"The property at JSON Pointer '/0/title' must be at least 5 characters
long."`

We use a JSON Pointer to reference the property in the object which is
something most json-schema validator uses as well.

What does this change do?

1. This commit once again changes the shape of hash returned by
   `ThemeSettingsObjectValidator.validate`. Instead of using the
   property name as the key previously, we have decided to avoid
   multiple levels of nesting and instead use a JSON Pointer as the key
   which helps to simplify the implementation.

2 Introduces `ThemeSettingsObjectValidator.validate_objects` which
  returns an array of validation error messages for all the objects
  passed to the method.
2024-02-27 09:16:37 +08:00
..
backups FIX: Backups should use relative paths for local uploads 2020-08-21 15:22:28 +02:00
csv FEATURE: Add support for case-sensitive Watched Words (#17445) 2022-08-02 10:06:03 +02:00
db DEV: Allow DROP NOT NULL in pre-deploy migrations (#20775) 2023-03-22 14:43:32 +00:00
emails DEV: Add email fixture (#23364) 2023-09-01 16:29:47 +10:00
encodings
feed FIX: Select best link from Atom feed (#15663) 2022-01-21 17:54:18 +02:00
i18n FIX: Missing translation when translation override contained a %{key} (#16625) 2022-05-04 17:35:22 +02:00
images SECURITY: Reduce maximum size of SVG sprite cache to prevent DoS 2023-09-12 15:31:28 -03:00
json DEV: Fix flaky core backend spec (#22650) 2023-07-18 07:01:19 +08:00
md A11Y: Set role=presentation if alt attr is missing (#18546) 2022-10-12 14:07:37 +03:00
media FIX: Add attachment content-disposition for all non-image files (#10058) 2020-06-17 11:16:37 +10:00
mmdb
multisite
onebox DEV: Fix various spec linting issues (#24672) 2023-12-04 13:45:19 +01:00
pdf FEATURE: Add attachments to outgoing emails 2019-07-25 15:57:45 +02:00
plugins FEATURE: Serve RTL versions of admin and plugins CSS bundles for RTL locales (#21876) 2023-06-01 05:27:11 +03:00
scss
site_settings DEV: Improve site setting rename generator (#25354) 2024-01-25 10:45:46 +10:00
theme_settings DEV: Validate default value for type: objects theme settings (#25833) 2024-02-27 09:16:37 +08:00
themes DEV: Add skip_migrations param when importing remote theme (#25218) 2024-01-11 14:04:02 +08:00
woff2