Skip to content

Commit

Permalink
VOTE-2846: add new wysiwyg description field for Registration form se…
Browse files Browse the repository at this point in the history
…lector (#1016)
  • Loading branch information
mlloydbixal authored Oct 1, 2024
1 parent dbd4606 commit d5589cb
Show file tree
Hide file tree
Showing 5 changed files with 73 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ dependencies:
- field.field.block_content.registration_form_selector.field_digital_form_paragraph
- field.field.block_content.registration_form_selector.field_enable_digital_form_link
- field.field.block_content.registration_form_selector.field_heading
- field.field.block_content.registration_form_selector.field_pdf_description
- field.field.block_content.registration_form_selector.field_registration_form_link
- field.field.block_content.registration_form_selector.field_submit_button_label
module:
Expand Down Expand Up @@ -38,6 +39,7 @@ third_party_settings:
required_fields: true
group_pdf_form_links:
children:
- field_pdf_description
- field_description
- field_registration_form_link
- field_default_option_label
Expand All @@ -62,15 +64,15 @@ mode: default
content:
field_default_option_label:
type: string_textfield
weight: 7
weight: 29
region: content
settings:
size: 60
placeholder: ''
third_party_settings: { }
field_description:
type: string_textfield
weight: 5
weight: 27
region: content
settings:
size: 60
Expand Down Expand Up @@ -107,9 +109,17 @@ content:
size: 60
placeholder: ''
third_party_settings: { }
field_pdf_description:
type: text_textarea
weight: 26
region: content
settings:
rows: 5
placeholder: ''
third_party_settings: { }
field_registration_form_link:
type: link_attributes
weight: 6
weight: 28
region: content
settings:
placeholder_url: ''
Expand All @@ -127,7 +137,7 @@ content:
third_party_settings: { }
field_submit_button_label:
type: string_textfield
weight: 8
weight: 30
region: content
settings:
size: 60
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ dependencies:
- field.field.block_content.registration_form_selector.field_digital_form_paragraph
- field.field.block_content.registration_form_selector.field_enable_digital_form_link
- field.field.block_content.registration_form_selector.field_heading
- field.field.block_content.registration_form_selector.field_pdf_description
- field.field.block_content.registration_form_selector.field_registration_form_link
- field.field.block_content.registration_form_selector.field_submit_button_label
module:
Expand All @@ -26,30 +27,30 @@ content:
settings:
link_to_entity: false
third_party_settings: { }
weight: 2
weight: 3
region: content
field_description:
type: string
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
weight: 1
weight: 2
region: content
field_digital_form_link_label:
type: string
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
weight: 9
weight: 7
region: content
field_digital_form_paragraph:
type: text_default
label: hidden
settings: { }
third_party_settings: { }
weight: 8
weight: 6
region: content
field_enable_digital_form_link:
type: boolean
Expand All @@ -59,7 +60,7 @@ content:
format_custom_false: ''
format_custom_true: ''
third_party_settings: { }
weight: 10
weight: 8
region: content
field_heading:
type: string
Expand All @@ -69,6 +70,13 @@ content:
third_party_settings: { }
weight: 0
region: content
field_pdf_description:
type: text_default
label: hidden
settings: { }
third_party_settings: { }
weight: 1
region: content
field_registration_form_link:
type: link_separate
label: hidden
Expand All @@ -79,15 +87,15 @@ content:
rel: '0'
target: '0'
third_party_settings: { }
weight: 4
weight: 5
region: content
field_submit_button_label:
type: string
label: hidden
settings:
link_to_entity: false
third_party_settings: { }
weight: 3
weight: 4
region: content
hidden:
langcode: true
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
uuid: 29cfbab3-1a6c-41f0-b476-51c1c8c4f9bd
langcode: en
status: true
dependencies:
config:
- block_content.type.registration_form_selector
- field.storage.block_content.field_pdf_description
- filter.format.simple_html
module:
- text
id: block_content.registration_form_selector.field_pdf_description
field_name: field_pdf_description
entity_type: block_content
bundle: registration_form_selector
label: Description
description: ''
required: true
translatable: true
default_value: { }
default_value_callback: ''
settings:
allowed_formats:
- simple_html
field_type: text_long
19 changes: 19 additions & 0 deletions config/sync/field.storage.block_content.field_pdf_description.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
uuid: 8460258d-47d7-4d93-95d3-616c24befbe0
langcode: en
status: true
dependencies:
module:
- block_content
- text
id: block_content.field_pdf_description
field_name: field_pdf_description
entity_type: block_content
type: text_long
settings: { }
module: text
locked: false
cardinality: 1
translatable: true
indexes: { }
persist_with_no_fields: false
custom_storage: false
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
{% endif %}

<form class="usa-form" method="get" id="register_form_download" data-test="nvrfForm">
<p>{{ content.field_description | field_value }}</p>
<p>{{ content.field_pdf_description | field_value | default(content.field_description | field_value) }}</p>
<div class="field">
<label class="usa-sr-only" for="js-user-selection">{{ content.field_default_option_label }}</label>
{# NVRF language selector #}
Expand Down

0 comments on commit d5589cb

Please sign in to comment.