Skip to content
Snippets Groups Projects

Issue #3466324 by mogtofu33, grimreaper: [1.0.0-alpha3] Config Schema: flatten structure

Merged Issue #3466324 by mogtofu33, grimreaper: [1.0.0-alpha3] Config Schema: flatten structure
1 unresolved thread
1 unresolved thread
Files
20
+ 30
0
ui_icons.icon_pack_options.*:
type: ui_icons.icon_pack_options_default
label: 'Default settings'
constraints:
FullyValidatable: ~
ui_icons.icon_pack_options_default:
type: mapping
label: 'Default settings'
    • Comment on lines +1 to +7

      If you're going to follow my suggestion/recommendation at https://www.drupal.org/project/ui_icons/issues/3466324#comment-15735424, then every top-level entry in a *.schema.yml file will need additions like this:

      Suggested change
      Applied
      3 ui_icons.icon_pack_options.*:
      4 type: ui_icons.icon_pack_options_default
      5 label: 'Default settings'
      6
      7 ui_icons.icon_pack_options_default:
      8 type: mapping
      9 label: 'Default settings'
      3 ui_icons.icon_pack_options.*:
      4 type: ui_icons.icon_pack_options_default
      5 label: 'Default settings'
      6 constraints:
      7 FullyValidatable: ~
      8
      9 ui_icons.icon_pack_options_default:
      10 type: mapping
      11 label: 'Default settings'
      12 constraints:
      13 FullyValidatable: ~

      … and then you'd get a very high degree of confidence in your config schema and all config using it! :blush:

Please register or sign in to reply
constraints:
FullyValidatable: ~
mapping:
width:
type: integer
label: 'Width'
constraints:
Range:
min: 0
height:
type: integer
label: 'Height'
constraints:
Range:
min: 0
title:
type: label
label: 'Title'
alt:
type: label
label: 'Alternative text'
Loading