diff --git a/content/docs/3_reference/3_panel/3_fields/0_slug/reference-article.txt b/content/docs/3_reference/3_panel/3_fields/0_slug/reference-article.txt index 36c930a88d..a20558067a 100644 --- a/content/docs/3_reference/3_panel/3_fields/0_slug/reference-article.txt +++ b/content/docs/3_reference/3_panel/3_fields/0_slug/reference-article.txt @@ -29,14 +29,6 @@ fields: (field-options: slug) -## How to use in templates/snippets - -```php -
- -
-``` - ## Sync option You can sync the slug field with another field. Whenever the editor types something into the synced field, the slug field will update with a sluggified version of the input: @@ -48,7 +40,21 @@ fields: type: slug sync: title ``` + +Please note that when your field to sync uses camelCase, you still have to reference the field with all lowercase letters: + +```yaml +fields: + sectionHeadline: + type: text + id: + label: Id + type: slug + sync: sectionheadline +``` +The same applies for the `wizard` option below. + ## Wizard option @@ -78,3 +84,26 @@ fields: sync: title allow: _ ``` + + +The slug field also works within blocks or structure field items to sync fields within a block/structure field item. +```yaml +fields: + structure: + type: structure + fields: + text: + type: text + slug: + type: slug + sync: text + + + +## How to use in templates/snippets + +```php +
+ +
+``` \ No newline at end of file