core.data_types.schema.yml

Same filename and directory in other branches
  1. 10 core/config/schema/core.data_types.schema.yml
  2. 11.x core/config/schema/core.data_types.schema.yml
  3. 9 core/config/schema/core.data_types.schema.yml
  4. 8.9.x core/config/schema/core.data_types.schema.yml
core/config/schema/core.data_types.schema.yml

File

core/config/schema/core.data_types.schema.yml

View source
  1. # Base types provided by Drupal core.
  2. # Read https://www.drupal.org/node/1905070 for more details about configuration
  3. # schema, types and type resolution.
  4. # Undefined type used by the system to assign to elements at any level where
  5. # configuration schema is not defined. Using explicitly has the same effect as
  6. # not defining schema, so there is no point in doing that.
  7. undefined:
  8. label: 'Undefined'
  9. class: '\Drupal\Core\Config\Schema\Undefined'
  10. # Explicit type to use when no data typing is possible. Instead of using this
  11. # type, we strongly suggest you use configuration structures that can be
  12. # described with other structural elements of schema, and describe your schema
  13. # with those elements.
  14. ignore:
  15. label: 'Ignore'
  16. class: '\Drupal\Core\Config\Schema\Ignore'
  17. # Basic scalar data types from typed data.
  18. boolean:
  19. label: 'Boolean'
  20. class: '\Drupal\Core\TypedData\Plugin\DataType\BooleanData'
  21. email:
  22. label: 'Email'
  23. class: '\Drupal\Core\TypedData\Plugin\DataType\Email'
  24. constraints:
  25. Email:
  26. message: "%value is not a valid email address."
  27. integer:
  28. label: 'Integer'
  29. class: '\Drupal\Core\TypedData\Plugin\DataType\IntegerData'
  30. timestamp:
  31. label: 'Timestamp'
  32. class: '\Drupal\Core\TypedData\Plugin\DataType\Timestamp'
  33. float:
  34. label: 'Float'
  35. class: '\Drupal\Core\TypedData\Plugin\DataType\FloatData'
  36. string:
  37. label: 'String'
  38. class: '\Drupal\Core\TypedData\Plugin\DataType\StringData'
  39. uri:
  40. label: 'Uri'
  41. class: '\Drupal\Core\TypedData\Plugin\DataType\Uri'
  42. # Container data types for lists with known and unknown keys.
  43. mapping:
  44. label: Mapping
  45. class: '\Drupal\Core\Config\Schema\Mapping'
  46. definition_class: '\Drupal\Core\TypedData\MapDataDefinition'
  47. mapping: {}
  48. constraints:
  49. # By default, allow the explicitly listed mapping keys, and require their
  50. # presence unless `requiredKey: false` is specified.
  51. ValidKeys:
  52. allowedKeys: '<infer>'
  53. sequence:
  54. label: Sequence
  55. class: '\Drupal\Core\Config\Schema\Sequence'
  56. definition_class: '\Drupal\Core\Config\Schema\SequenceDataDefinition'
  57. # Simple extended data types:
  58. # Human readable string that must be plain text and editable with a text field.
  59. label:
  60. type: string
  61. label: 'Optional label'
  62. translatable: true
  63. constraints:
  64. Regex:
  65. # Forbid any kind of control character.
  66. # @see https://stackoverflow.com/a/66587087
  67. pattern: '/([^\PC])/u'
  68. match: false
  69. message: 'Labels are not allowed to span multiple lines or contain control characters.'
  70. required_label:
  71. type: label
  72. label: 'Label'
  73. constraints:
  74. NotBlank: {}
  75. # String containing plural variants, separated by EXT.
  76. plural_label:
  77. type: label
  78. label: 'Plural variants'
  79. constraints:
  80. Regex:
  81. # Normally, labels cannot contain invisible control characters. In this particular
  82. # case, an invisible character (ASCII 3, 0x03) is used to encode translation
  83. # information, so carve out an exception for that only.
  84. # @see \Drupal\views\Plugin\views\field\NumericField
  85. pattern: '/([^\PC\x03])/u'
  86. match: false
  87. message: 'Labels are not allowed to span multiple lines or contain control characters.'
  88. # Internal Drupal path
  89. path:
  90. type: string
  91. label: 'Path'
  92. # Human readable string that can contain multiple lines of text or HTML.
  93. text:
  94. type: string
  95. label: 'Text'
  96. translatable: true
  97. constraints:
  98. Regex:
  99. # Disallow all control characters except for tabs (ASCII 9, 0x09) as well
  100. # as carriage returns (ASCII 13, 0x0D) and line feeds (ASCII 10, 0x0A),
  101. # which are used for line endings:
  102. # - Windows: `\r\n`
  103. # - old macOS: `\r`
  104. # - *nix: `\n`
  105. # @see https://stackoverflow.com/a/66587087
  106. pattern: '/([^\PC\x09\x0a\x0d])/u'
  107. match: false
  108. message: 'Text is not allowed to contain control characters, only visible characters.'
  109. # A UUID.
  110. uuid:
  111. type: string
  112. label: 'UUID'
  113. constraints:
  114. Uuid: {}
  115. # PHP Date format string that is translatable.
  116. date_format:
  117. type: string
  118. label: 'Date format'
  119. translatable: true
  120. translation context: 'PHP date format'
  121. # HTML color value.
  122. color_hex:
  123. type: string
  124. label: 'Color'
  125. constraints:
  126. # TRICKY: this cannot reuse the Color::validateHex() logic because:
  127. # 1. Color::validateHex() would not allow NULL, but this constraint does.
  128. # (Anything in config can be marked optional, so NULL must never trigger
  129. # a validation error) Color::validateHex() does not allow this.
  130. # 2. The Regex constraint is something that an external tool (no matter
  131. # whether that's something generating/validating Drupal config or a
  132. # JSON:API/REST/GraphQL/… client) to also correctly validate this.
  133. Regex:
  134. # Regex copied from Color::validateHex()
  135. pattern: '/^[#]?([0-9a-fA-F]{3}){1,2}$/'
  136. message: "%value is not a valid hexadecimal color."
  137. # Machine-readable identifier that can only contain certain characters.
  138. machine_name:
  139. type: string
  140. label: 'Machine name'
  141. constraints:
  142. Regex:
  143. pattern: '/^[a-z0-9_]+$/'
  144. message: "The %value machine name is not valid."
  145. Length:
  146. # @see \Drupal\Core\Config\Entity\ConfigEntityStorage::MAX_ID_LENGTH
  147. max: 166
  148. # A language identifier.
  149. langcode:
  150. type: string
  151. label: 'Language code'
  152. constraints:
  153. NotNull: []
  154. Choice:
  155. callback: 'Drupal\Core\TypedData\Plugin\DataType\LanguageReference::getAllValidLangcodes'
  156. # A number of bytes; either a plain number or with a size indication such as "MB".
  157. # @see \Drupal\Component\Utility\Bytes
  158. bytes:
  159. type: string
  160. label: 'Bytes'
  161. constraints:
  162. Callback:
  163. callback: ['\Drupal\Component\Utility\Bytes', 'validateConstraint']
  164. weight:
  165. type: integer
  166. label: 'Weight'
  167. constraints:
  168. Range:
  169. # @see PHP_INT_MIN (32-bit)
  170. min: -2147483648
  171. # @see PHP_INT_MAX (32-bit)
  172. max: 2147483647
  173. FullyValidatable: ~
  174. # Complex extended data types:
  175. # Root of a configuration object.
  176. _core_config_info:
  177. type: mapping
  178. mapping:
  179. default_config_hash:
  180. type: string
  181. label: 'Default configuration hash'
  182. constraints:
  183. NotNull: []
  184. Regex:
  185. pattern: '/^[a-zA-Z0-9\-_]+$/'
  186. # The hash is a base64-encoded version of the config's SHA-256 hash. Given
  187. # the deterministic length of a SHA-256 hash, and the way base64 encoding
  188. # works, this is always going to be 43 characters long.
  189. Length:
  190. exactly: 43
  191. constraints:
  192. ValidKeys:
  193. allowedKeys: ['default_config_hash']
  194. config_object:
  195. type: mapping
  196. mapping:
  197. _core:
  198. # This only exists for merging configuration; it's not required.
  199. requiredKey: false
  200. type: _core_config_info
  201. langcode:
  202. requiredKey: false
  203. type: langcode
  204. constraints:
  205. # The `langcode` key:
  206. # - MUST be specified when there are translatable values
  207. # - MUST NOT be specified when there are no translatable values.
  208. # Translatable values are specified for this config schema type (a subtype of `type: config_object`) if the
  209. # `translatable` flag is present and set to `true` for *any* element in that config schema type.
  210. LangcodeRequiredIfTranslatableValues: ~
  211. # Mail text with subject and body parts.
  212. mail:
  213. type: mapping
  214. label: 'Mail'
  215. mapping:
  216. subject:
  217. type: required_label
  218. label: 'Subject'
  219. body:
  220. type: text
  221. label: 'Body'
  222. # Filter with module and status.
  223. filter:
  224. type: mapping
  225. label: 'Filter'
  226. mapping:
  227. id:
  228. type: string
  229. label: 'ID'
  230. constraints:
  231. PluginExists:
  232. manager: plugin.manager.filter
  233. interface: 'Drupal\filter\Plugin\FilterInterface'
  234. provider:
  235. type: string
  236. label: 'Provider'
  237. status:
  238. type: boolean
  239. label: 'Status'
  240. weight:
  241. type: weight
  242. label: 'Weight'
  243. settings:
  244. type: filter_settings.[%parent.id]
  245. # System action configuration base.
  246. action_configuration_default:
  247. type: sequence
  248. label: 'Action configuration'
  249. sequence:
  250. type: string
  251. theme_settings:
  252. type: config_object
  253. mapping:
  254. favicon:
  255. type: mapping
  256. label: 'Shortcut icon settings'
  257. mapping:
  258. mimetype:
  259. type: string
  260. label: 'MIME type'
  261. path:
  262. type: string
  263. label: 'Path'
  264. url:
  265. type: string
  266. label: 'URL'
  267. use_default:
  268. type: boolean
  269. label: 'Use the default shortcut icon supplied by the theme'
  270. features:
  271. type: mapping
  272. label: 'Optional features'
  273. mapping:
  274. comment_user_picture:
  275. type: boolean
  276. label: 'User pictures in comments'
  277. comment_user_verification:
  278. type: boolean
  279. label: 'User verification status in comments'
  280. favicon:
  281. type: boolean
  282. label: 'Shortcut icon'
  283. logo:
  284. type: boolean
  285. label: 'Logo'
  286. name:
  287. type: boolean
  288. label: 'Site name'
  289. node_user_picture:
  290. type: boolean
  291. label: 'User pictures in posts'
  292. slogan:
  293. type: boolean
  294. label: 'Site slogan'
  295. logo:
  296. type: mapping
  297. label: 'Logo settings'
  298. mapping:
  299. path:
  300. type: string
  301. label: 'Logo path'
  302. url:
  303. type: uri
  304. nullable: true
  305. label: 'URL'
  306. use_default:
  307. type: boolean
  308. label: 'Use default'
  309. third_party_settings:
  310. # Third party settings are always optional: they're an optional extension
  311. # point.
  312. requiredKey: false
  313. type: sequence
  314. label: 'Third party settings'
  315. sequence:
  316. type: theme_settings.third_party.[%key]
  317. # Array of routes with route_name and route_params keys.
  318. route:
  319. type: mapping
  320. label: 'Route'
  321. mapping:
  322. route_name:
  323. type: string
  324. label: 'Route Name'
  325. route_params:
  326. type: sequence
  327. label: 'Route Params'
  328. sequence:
  329. type: string
  330. label: 'Param'
  331. # Config dependencies.
  332. config_dependencies_base:
  333. type: mapping
  334. mapping:
  335. config:
  336. # All dependency keys are optional: this might not depend on any other config.
  337. requiredKey: false
  338. type: sequence
  339. label: 'Configuration entity dependencies'
  340. sequence:
  341. type: string
  342. constraints:
  343. NotBlank: []
  344. ConfigExists: []
  345. content:
  346. # All dependency keys are optional: this might not depend on any content entities.
  347. requiredKey: false
  348. type: sequence
  349. label: 'Content entity dependencies'
  350. sequence:
  351. type: string
  352. module:
  353. # All dependency keys are optional: this might not depend on any modules.
  354. requiredKey: false
  355. type: sequence
  356. label: 'Module dependencies'
  357. sequence:
  358. type: string
  359. constraints:
  360. NotBlank: []
  361. ExtensionName: []
  362. ExtensionExists:
  363. type: module
  364. theme:
  365. # All dependency keys are optional: this might not depend on any themes.
  366. requiredKey: false
  367. type: sequence
  368. label: 'Theme dependencies'
  369. sequence:
  370. type: string
  371. constraints:
  372. NotBlank: []
  373. ExtensionName: []
  374. ExtensionExists:
  375. type: theme
  376. constraints:
  377. ValidKeys:
  378. allowedKeys: '<infer>'
  379. config_dependencies:
  380. type: config_dependencies_base
  381. label: 'Configuration dependencies'
  382. mapping:
  383. enforced:
  384. # All dependency keys are optional: this may have no dependencies at all.
  385. requiredKey: false
  386. type: config_dependencies_base
  387. label: 'Enforced configuration dependencies'
  388. constraints:
  389. ValidKeys:
  390. allowedKeys: '<infer>'
  391. config_entity:
  392. type: mapping
  393. mapping:
  394. uuid:
  395. type: uuid
  396. label: 'UUID'
  397. langcode:
  398. type: langcode
  399. status:
  400. type: boolean
  401. label: 'Status'
  402. dependencies:
  403. type: config_dependencies
  404. label: 'Dependencies'
  405. third_party_settings:
  406. # Third party settings are always optional: they're an optional extension
  407. # point.
  408. requiredKey: false
  409. type: sequence
  410. label: 'Third party settings'
  411. sequence:
  412. type: '[%parent.%parent.%type].third_party.[%key]'
  413. _core:
  414. # This only exists for merging configuration; it's not required.
  415. requiredKey: false
  416. type: _core_config_info
  417. # This applies to all blocks that have no additional settings of their own.
  418. block.settings.*:
  419. type: block_settings
  420. constraints:
  421. FullyValidatable: ~
  422. block_settings:
  423. type: mapping
  424. label: 'Block settings'
  425. # This is intentionally not marked as fully validatable: each `type: block.settings.SOMETHING` must do that.
  426. mapping:
  427. id:
  428. type: string
  429. label: 'ID'
  430. label:
  431. type: label
  432. label: 'Description'
  433. label_display:
  434. type: string
  435. label: 'Display title'
  436. constraints:
  437. Choice:
  438. choices:
  439. - '0'
  440. - visible
  441. NotBlank: []
  442. provider:
  443. type: string
  444. label: 'Provider of this block plugin'
  445. constraints:
  446. NotBlank: []
  447. ExtensionName: []
  448. ExtensionExists:
  449. type: module
  450. context_mapping:
  451. requiredKey: false
  452. type: sequence
  453. label: 'Context assignments'
  454. sequence:
  455. type: string
  456. condition.plugin:
  457. type: mapping
  458. label: 'Condition'
  459. mapping:
  460. id:
  461. type: string
  462. label: 'ID'
  463. constraints:
  464. PluginExists:
  465. manager: plugin.manager.condition
  466. interface: 'Drupal\Core\Condition\ConditionInterface'
  467. negate:
  468. type: boolean
  469. label: 'Negate'
  470. context_mapping:
  471. requiredKey: false
  472. type: sequence
  473. label: 'Context assignments'
  474. sequence:
  475. type: string
  476. condition.plugin.entity_bundle:*:
  477. type: condition.plugin
  478. mapping:
  479. bundles:
  480. type: sequence
  481. sequence:
  482. type: string
  483. display_variant.plugin:
  484. type: mapping
  485. label: 'Display variant'
  486. mapping:
  487. id:
  488. type: string
  489. label: 'ID'
  490. label:
  491. type: required_label
  492. label: 'Label'
  493. weight:
  494. type: weight
  495. label: 'Weight'
  496. uuid:
  497. type: uuid
  498. layout_plugin.settings:
  499. type: mapping
  500. label: 'Layout settings'
  501. mapping:
  502. label:
  503. type: label
  504. label: 'Label'
  505. context_mapping:
  506. type: sequence
  507. label: 'Context assignments'
  508. sequence:
  509. type: string
  510. # Specify defaults.
  511. layout_plugin.settings.*:
  512. type: layout_plugin.settings
  513. base_entity_reference_field_settings:
  514. type: mapping
  515. mapping:
  516. target_type:
  517. type: string
  518. label: 'Type of item to reference'
  519. field_config_base:
  520. type: config_entity
  521. mapping:
  522. id:
  523. type: string
  524. label: 'ID'
  525. constraints:
  526. StringEqualsConcatenatedValues:
  527. separator: .
  528. values:
  529. - '%parent.entity_type'
  530. - '%parent.bundle'
  531. - '%parent.field_name'
  532. field_name:
  533. type: machine_name
  534. label: 'Field name'
  535. entity_type:
  536. type: string
  537. label: 'Entity type'
  538. constraints:
  539. PluginExists:
  540. manager: 'entity_type.manager'
  541. interface: '\Drupal\Core\Entity\FieldableEntityInterface'
  542. bundle:
  543. type: string
  544. label: 'Bundle'
  545. constraints:
  546. EntityBundleExists:
  547. entityTypeId: '%parent.entity_type'
  548. label:
  549. type: required_label
  550. label: 'Label'
  551. description:
  552. type: text
  553. label: 'Help text'
  554. required:
  555. type: boolean
  556. label: 'Required field'
  557. translatable:
  558. type: boolean
  559. label: 'Translatable'
  560. default_value:
  561. type: sequence
  562. label: 'Default values'
  563. sequence:
  564. type: field.value.[%parent.%parent.field_type]
  565. label: 'Default value'
  566. default_value_callback:
  567. type: string
  568. label: 'Default value callback'
  569. settings:
  570. type: field.field_settings.[%parent.field_type]
  571. field_type:
  572. type: string
  573. label: 'Field type'
  574. constraints:
  575. PluginExists:
  576. manager: plugin.manager.field.field_type
  577. interface: '\Drupal\Core\Field\FieldItemInterface'
  578. constraints:
  579. FullyValidatable: ~
  580. core.base_field_override.*.*.*:
  581. type: field_config_base
  582. label: 'Base field bundle override'
  583. constraints:
  584. FullyValidatable: ~
  585. core.date_format.*:
  586. type: config_entity
  587. label: 'Date format'
  588. mapping:
  589. id:
  590. type: machine_name
  591. label: 'ID'
  592. label:
  593. type: required_label
  594. label: 'Label'
  595. locked:
  596. type: boolean
  597. label: 'Locked'
  598. pattern:
  599. type: core_date_format_pattern.[%parent.locked]
  600. label: 'PHP date format'
  601. constraints:
  602. NotBlank: []
  603. # A valid date format character must appear somewhere in the value.
  604. # See https://www.php.net/manual/en/datetime.format.php
  605. Regex:
  606. pattern: '/[aABcdDeFgGhHiIjlLmMnNoOpPrsStTuUvwWxXyYzZ]/'
  607. message: 'This is not a valid date format.'
  608. constraints:
  609. FullyValidatable: ~
  610. # Unlocked date formats should use the translatable type.
  611. core_date_format_pattern.0:
  612. type: date_format
  613. label: 'Date format'
  614. # Locked date formats are just used to transport the value.
  615. core_date_format_pattern.1:
  616. type: string
  617. label: 'Date format'
  618. # Generic field settings schemas.
  619. field.storage_settings.*:
  620. type: mapping
  621. label: 'Settings'
  622. # By default, a field type has no settings, so this can safely be considered
  623. # fully validatable. A `FOO` field type that has one or more settings is
  624. # required to create a `field.storage_settings.FOO` config schema type, and
  625. # cannot possibly forget to do that, because validation errors would be
  626. # triggered if it ever tried to save a setting, since this mapping allows no
  627. # key-value pairs at all.
  628. constraints:
  629. FullyValidatable: ~
  630. field.field_settings.*:
  631. type: mapping
  632. label: 'Settings'
  633. # By default, a field type has no settings, so this can safely be considered
  634. # fully validatable. A `FOO` field type that has one or more settings is
  635. # required to create a `field.field_settings.FOO` config schema type, and
  636. # cannot possibly forget to do that, because validation errors would be
  637. # triggered if it ever tried to save a setting, since this mapping allows no
  638. # key-value pairs at all.
  639. constraints:
  640. FullyValidatable: ~
  641. field.value.*:
  642. type: mapping
  643. label: 'Default value'
  644. # Schema for the configuration of the String field type.
  645. # This field type has no field instance settings, so no specific config schema type.
  646. # @see `type: field.field_settings.*`
  647. field.storage_settings.string:
  648. type: mapping
  649. label: 'String settings'
  650. mapping:
  651. max_length:
  652. type: integer
  653. label: 'Maximum length'
  654. case_sensitive:
  655. type: boolean
  656. label: 'Case sensitive'
  657. is_ascii:
  658. type: boolean
  659. label: 'Contains US ASCII characters only'
  660. field.value.string:
  661. type: mapping
  662. label: 'Default value'
  663. mapping:
  664. value:
  665. type: label
  666. label: 'Value'
  667. # Schema for the configuration of the String (long) field type.
  668. field.storage_settings.string_long:
  669. type: mapping
  670. label: 'String (long) settings'
  671. mapping:
  672. case_sensitive:
  673. type: boolean
  674. label: 'Case sensitive'
  675. field.value.string_long:
  676. type: mapping
  677. label: 'Default value'
  678. mapping:
  679. value:
  680. type: text
  681. label: 'Value'
  682. # Schema for the configuration of the Password field type.
  683. # This field type has no field instance settings, so no specific config schema type.
  684. # @see `type: field.field_settings.*`
  685. field.storage_settings.password:
  686. type: field.storage_settings.string
  687. label: 'Password settings'
  688. # Schema for the configuration of the URI field type.
  689. # This field type has no field instance settings, so no specific config schema type.
  690. # @see `type: field.field_settings.*`
  691. field.storage_settings.uri:
  692. type: field.storage_settings.string
  693. label: 'URI settings'
  694. mapping:
  695. max_length:
  696. type: integer
  697. label: 'Maximum length'
  698. case_sensitive:
  699. type: boolean
  700. label: 'Case sensitive'
  701. field.value.uri:
  702. type: mapping
  703. label: 'Default value'
  704. mapping:
  705. value:
  706. type: string
  707. label: 'Value'
  708. # Schema for the configuration of the Created field type.
  709. # This field type has no field storage settings, so no specific config schema type.
  710. # @see `type: field.storage_settings.*`
  711. # This field type has no field instance settings, so no specific config schema type.
  712. # @see `type: field.field_settings.*`
  713. field.value.created:
  714. type: mapping
  715. label: 'Default value'
  716. mapping:
  717. value:
  718. type: integer
  719. label: 'Value'
  720. # Schema for the configuration of the Changed field type.
  721. # This field type has no field storage settings, so no specific config schema type.
  722. # @see `type: field.storage_settings.*`
  723. # This field type has no field instance settings, so no specific config schema type.
  724. # @see `type: field.field_settings.*`
  725. field.value.changed:
  726. type: mapping
  727. label: 'Default value'
  728. mapping:
  729. value:
  730. type: integer
  731. label: 'Value'
  732. # Schema for the configuration of the Entity reference field type.
  733. field.storage_settings.entity_reference:
  734. type: mapping
  735. label: 'Entity reference field storage settings'
  736. mapping:
  737. target_type:
  738. type: string
  739. label: 'Type of item to reference'
  740. field.field_settings.entity_reference:
  741. type: mapping
  742. label: 'Entity reference field settings'
  743. mapping:
  744. handler:
  745. type: string
  746. label: 'Reference method'
  747. constraints:
  748. PluginExists:
  749. manager: plugin.manager.entity_reference_selection
  750. interface: 'Drupal\Core\Entity\EntityReferenceSelection\SelectionInterface'
  751. # @todo Remove this line and explicitly require valid entity reference
  752. # selection plugin IDs in https://drupal.org/i/3420198.
  753. allowFallback: true
  754. handler_settings:
  755. type: entity_reference_selection.[%parent.handler]
  756. label: 'Entity reference selection plugin settings'
  757. field.value.entity_reference:
  758. type: mapping
  759. label: 'Default value'
  760. mapping:
  761. target_id:
  762. type: string
  763. label: 'Value'
  764. target_uuid:
  765. type: uuid
  766. # Schema for the configuration of the Boolean field type.
  767. field.field_settings.boolean:
  768. label: 'Boolean settings'
  769. type: mapping
  770. mapping:
  771. on_label:
  772. type: required_label
  773. label: 'On label'
  774. off_label:
  775. type: required_label
  776. label: 'Off label'
  777. field.value.boolean:
  778. type: mapping
  779. mapping:
  780. value:
  781. type: integer
  782. label: 'Value'
  783. # Schema for the configuration of the Email field type.
  784. # This field type has no field storage settings, so no specific config schema type.
  785. # @see `type: field.storage_settings.*`
  786. field.field_settings.email:
  787. type: mapping
  788. label: 'Email settings'
  789. sequence:
  790. type: string
  791. label: 'Setting'
  792. field.value.email:
  793. type: mapping
  794. label: 'Default value'
  795. mapping:
  796. value:
  797. type: email
  798. label: 'Value'
  799. # Schema for the configuration of the Integer field type.
  800. field.storage_settings.integer:
  801. type: mapping
  802. label: 'Integer settings'
  803. mapping:
  804. unsigned:
  805. type: boolean
  806. label: 'Unsigned'
  807. size:
  808. type: string
  809. label: 'Database storage size'
  810. field.field_settings.integer:
  811. type: mapping
  812. label: 'Integer'
  813. mapping:
  814. min:
  815. type: integer
  816. label: 'Minimum'
  817. max:
  818. type: integer
  819. label: 'Maximum'
  820. prefix:
  821. type: label
  822. label: 'Prefix'
  823. suffix:
  824. type: label
  825. label: 'Suffix'
  826. field.value.integer:
  827. type: mapping
  828. label: 'Default value'
  829. mapping:
  830. value:
  831. type: integer
  832. label: 'Value'
  833. # Schema for the configuration of the Decimal field type.
  834. field.storage_settings.decimal:
  835. type: mapping
  836. label: 'Decimal settings'
  837. mapping:
  838. precision:
  839. type: integer
  840. label: 'Precision'
  841. scale:
  842. type: integer
  843. label: 'Scale'
  844. field.field_settings.decimal:
  845. type: mapping
  846. label: 'Decimal settings'
  847. mapping:
  848. min:
  849. type: float
  850. label: 'Minimum'
  851. max:
  852. type: float
  853. label: 'Maximum'
  854. prefix:
  855. type: label
  856. label: 'Prefix'
  857. suffix:
  858. type: label
  859. label: 'Suffix'
  860. field.value.decimal:
  861. type: mapping
  862. label: 'Default value'
  863. mapping:
  864. value:
  865. type: float
  866. label: 'Value'
  867. # Schema for the configuration of the Float field type.
  868. field.storage_settings.float:
  869. type: mapping
  870. label: 'Float settings'
  871. field.field_settings.float:
  872. type: mapping
  873. label: 'Float settings'
  874. mapping:
  875. min:
  876. type: float
  877. label: 'Minimum'
  878. max:
  879. type: float
  880. label: 'Maximum'
  881. prefix:
  882. type: label
  883. label: 'Prefix'
  884. suffix:
  885. type: label
  886. label: 'Suffix'
  887. field.value.float:
  888. type: mapping
  889. label: 'Default value'
  890. mapping:
  891. value:
  892. type: float
  893. label: 'Value'
  894. # Schema for the configuration of the Timestamp field type.
  895. field.value.timestamp:
  896. type: mapping
  897. label: 'Timestamp value'
  898. mapping:
  899. value:
  900. type: timestamp
  901. label: 'Value'
  902. field.value.language:
  903. type: mapping
  904. label: 'Language value'
  905. mapping:
  906. value:
  907. # Not this doesn't make use of type: langcode because that doesn't allow null values.
  908. type: string
  909. label: 'Language value'
  910. constraints:
  911. Choice:
  912. callback: 'Drupal\Core\TypedData\Plugin\DataType\LanguageReference::getAllValidLangcodes'
  913. # Text with a text format.
  914. text_format:
  915. type: mapping
  916. label: 'Text with text format'
  917. # We declare the entire mapping of text and text format as translatable. This
  918. # causes the entire mapping to be saved to the language overrides of the
  919. # configuration. Storing only the (to be formatted) text could result in
  920. # security problems in case the text format of the source text is changed.
  921. translatable: true
  922. mapping:
  923. value:
  924. type: text
  925. label: 'Text'
  926. # Mark the actual text as translatable (in addition to the entire mapping
  927. # being marked as translatable) so that shipped configuration with
  928. # formatted text can participate in the string translation system.
  929. translatable: true
  930. format:
  931. type: string
  932. label: 'Text format'
  933. # The text format should not be translated as part of the string
  934. # translation system, so this is not marked as translatable.
  935. # Base schema for all entity reference selection handler schemas.
  936. entity_reference_selection:
  937. type: mapping
  938. label: 'Entity reference selection handler settings'
  939. mapping:
  940. target_type:
  941. type: string
  942. label: 'Type of item to reference'
  943. # Schema for all entity reference selection handlers that are not providing a
  944. # specific schema.
  945. entity_reference_selection.*:
  946. type: entity_reference_selection
  947. # Schema for the entity reference 'default' selection handler settings.
  948. entity_reference_selection.default:
  949. type: entity_reference_selection
  950. label: 'Default selection handler settings'
  951. mapping:
  952. target_bundles:
  953. type: sequence
  954. label: 'types'
  955. nullable: true
  956. sequence:
  957. type: string
  958. label: 'Bundle'
  959. sort:
  960. type: mapping
  961. label: 'Sort settings'
  962. mapping:
  963. field:
  964. type: string
  965. label: 'Sort by'
  966. direction:
  967. type: string
  968. label: 'Sort direction'
  969. auto_create:
  970. type: boolean
  971. label: 'Create referenced entities if they don''t already exist'
  972. auto_create_bundle:
  973. type: string
  974. label: 'Bundle assigned to the auto-created entities.'
  975. # Schema for all entity reference 'default:*' selection handlers that are not
  976. # providing a specific schema.
  977. entity_reference_selection.default:*:
  978. type: entity_reference_selection.default
  979. # Schema for the configuration of mailer transport DSN.
  980. mailer_dsn:
  981. type: mapping
  982. label: 'Symfony mailer transport DSN'
  983. mapping:
  984. scheme:
  985. type: string
  986. label: 'Scheme'
  987. constraints:
  988. NotBlank:
  989. message: 'The mailer DSN must contain a scheme.'
  990. Regex:
  991. # https://datatracker.ietf.org/doc/html/rfc3986#appendix-A
  992. pattern: '/^[a-z][a-z0-9+\-\.]*$/i'
  993. message: 'The mailer DSN scheme must start with a letter followed by zero or more letters, numbers, plus (+), minus (-) or periods (.)'
  994. host:
  995. type: string
  996. label: 'Host'
  997. constraints:
  998. NotBlank:
  999. message: 'The mailer DSN must contain a host (use "default" by default).'
  1000. UriHost:
  1001. message: 'The mailer DSN host should conform to RFC 3986 URI host component.'
  1002. user:
  1003. type: string
  1004. nullable: true
  1005. label: 'User'
  1006. password:
  1007. type: string
  1008. nullable: true
  1009. label: 'Password'
  1010. port:
  1011. type: integer
  1012. nullable: true
  1013. label: 'Port'
  1014. constraints:
  1015. Range:
  1016. min: 0
  1017. max: 65535
  1018. notInRangeMessage: 'The mailer DSN port must be between 0 and 65535.'
  1019. options:
  1020. type: mailer_dsn.options.[%parent.scheme]
  1021. label: 'Options'
  1022. mailer_dsn.options.*:
  1023. type: sequence
  1024. label: 'Options'
  1025. sequence:
  1026. type: string
  1027. label: Option
  1028. constraints:
  1029. NotNull: []
  1030. mailer_dsn.options.null:
  1031. type: mapping
  1032. label: 'Null transport options'
  1033. mapping: {}
  1034. mailer_dsn.options.native:
  1035. type: mailer_dsn.options.null
  1036. mailer_dsn.options.sendmail:
  1037. type: mapping
  1038. label: 'Sendmail transport options'
  1039. mapping:
  1040. command:
  1041. type: string
  1042. nullable: true
  1043. label: 'Command to be executed by sendmail transport'
  1044. constraints:
  1045. Regex:
  1046. # Forbid any kind of control character.
  1047. # @see https://stackoverflow.com/a/66587087
  1048. pattern: '/([^\PC])/u'
  1049. match: false
  1050. message: 'The command option is not allowed to span multiple lines or contain control characters.'
  1051. mailer_dsn.options.sendmail+smtp:
  1052. type: mailer_dsn.options.sendmail
  1053. label: 'Sendmail transport options'
  1054. mailer_dsn.options.smtp:
  1055. type: mapping
  1056. label: 'SMTP options'
  1057. mapping:
  1058. auto_tls:
  1059. type: boolean
  1060. nullable: true
  1061. label: 'Whether or not to enable TLS opportunistically (defaults to true).'
  1062. require_tls:
  1063. type: boolean
  1064. nullable: true
  1065. label: 'Whether or not to enforce TLS (defaults to false).'
  1066. verify_peer:
  1067. type: boolean
  1068. nullable: true
  1069. label: 'TLS Peer Verification (defaults to true)'
  1070. source_ip:
  1071. type: string
  1072. nullable: true
  1073. label: 'Bind to a specific IPv4 or IPv6 address (no default).'
  1074. constraints:
  1075. UriHost:
  1076. message: 'The source IP should conform to RFC 3986 URI host component.'
  1077. peer_fingerprint:
  1078. type: string
  1079. nullable: true
  1080. label: 'TLS Peer Fingerprint (no default)'
  1081. constraints:
  1082. Regex:
  1083. pattern: '/^[a-fA-F0-9]+$/'
  1084. message: 'The peer_fingerprint option requires an md5, sha1 or sha256 certificate fingerprint in hex with all separators (colons) removed.'
  1085. local_domain:
  1086. type: string
  1087. nullable: true
  1088. label: 'Domain name or IP address that represents the identity of the client when establishing the SMTP session (defaults to 127.0.0.1)'
  1089. constraints:
  1090. Regex:
  1091. # Forbid any kind of control character.
  1092. # @see https://stackoverflow.com/a/66587087
  1093. pattern: '/([^\PC])/u'
  1094. match: false
  1095. message: 'The local_domain is not allowed to span multiple lines or contain control characters.'
  1096. restart_threshold:
  1097. type: integer
  1098. nullable: true
  1099. label: 'Maximum number of messages to send before re-starting the transport (defaults to 100 messages)'
  1100. constraints:
  1101. PositiveOrZero: ~
  1102. restart_threshold_sleep:
  1103. type: float
  1104. nullable: true
  1105. label: 'Number of seconds to sleep between stopping and re-starting the transport (defaults to no delay)'
  1106. constraints:
  1107. PositiveOrZero: ~
  1108. ping_threshold:
  1109. type: integer
  1110. nullable: true
  1111. label: 'The minimum number of seconds between two messages required to ping the server (defaults to 100 seconds)'
  1112. constraints:
  1113. PositiveOrZero: ~
  1114. max_per_second:
  1115. type: integer
  1116. nullable: true
  1117. label: 'The number of messages to send per second (defaults to no limit)'
  1118. constraints:
  1119. PositiveOrZero: ~
  1120. mailer_dsn.options.smtps:
  1121. type: mailer_dsn.options.smtp
  1122. label: 'Secure SMTP options'

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.