From f1866f679545c84c98913398f45412cd78bc51ad Mon Sep 17 00:00:00 2001 From: Skaiir Date: Thu, 12 Sep 2024 16:56:30 +0200 Subject: [PATCH] test --- .../form-js-carbon-styles/src/carbon-styles.js | 9 ++++----- .../form-js-carbon-styles/src/carbon-styles.scss | 9 ++++----- .../render/components/form-fields/Checklist.js | 15 ++++++--------- .../src/render/components/form-fields/Radio.js | 6 +++++- 4 files changed, 19 insertions(+), 20 deletions(-) diff --git a/packages/form-js-carbon-styles/src/carbon-styles.js b/packages/form-js-carbon-styles/src/carbon-styles.js index ef4a67ac1..4fc701545 100644 --- a/packages/form-js-carbon-styles/src/carbon-styles.js +++ b/packages/form-js-carbon-styles/src/carbon-styles.js @@ -301,8 +301,7 @@ const READONLY_STYLES = css` } } - &.fjs-checked .fjs-input[type='checkbox'], - .fjs-form-field-label.fjs-checked .fjs-input[type='checkbox'] { + &.fjs-checked .fjs-input[type='checkbox'] { &:before { border: 1px solid var(--cds-icon-disabled); background: transparent; @@ -418,8 +417,8 @@ const LABEL_DESCRIPTION_ERROR_STYLES = css` margin-bottom: var(--cds-spacing-03); } - .fjs-form-field.fjs-form-field-radio .fjs-form-field-label:not(:first-of-type), - .fjs-form-field.fjs-form-field-checklist .fjs-form-field-label:not(:first-of-type) { + .fjs-form-field.fjs-form-field-radio .fjs-inline-label:not(:first-of-type), + .fjs-form-field.fjs-form-field-checklist .fjs-inline-label:not(:first-of-type) { margin: 0; margin-bottom: 0.1875rem; } @@ -515,7 +514,7 @@ const CHECKBOX_STYLES = css` } .fjs-form-field.fjs-checked .fjs-input[type='checkbox'], - .fjs-form-field .fjs-form-field-label.fjs-checked .fjs-input[type='checkbox'] { + .fjs-form-field .fjs-inline-label.fjs-checked .fjs-input[type='checkbox'] { &:before { border: none; border-width: 1px; diff --git a/packages/form-js-carbon-styles/src/carbon-styles.scss b/packages/form-js-carbon-styles/src/carbon-styles.scss index f4cb5dedc..fc31e17d9 100644 --- a/packages/form-js-carbon-styles/src/carbon-styles.scss +++ b/packages/form-js-carbon-styles/src/carbon-styles.scss @@ -408,8 +408,7 @@ } } - &.fjs-checked .fjs-input[type='checkbox'], - .fjs-form-field-label.fjs-checked .fjs-input[type='checkbox'] { + &.fjs-checked .fjs-input[type='checkbox'] { &:before { border: 1px solid var(--cds-icon-disabled); background: transparent; @@ -535,8 +534,8 @@ margin-bottom: var(--cds-spacing-03); } - .fjs-form-field.fjs-form-field-radio .fjs-form-field-label:not(:first-of-type), - .fjs-form-field.fjs-form-field-checklist .fjs-form-field-label:not(:first-of-type) { + .fjs-form-field.fjs-form-field-radio .fjs-inline-label:not(:first-of-type), + .fjs-form-field.fjs-form-field-checklist .fjs-inline-label:not(:first-of-type) { margin: 0; margin-bottom: 0.1875rem; } @@ -632,7 +631,7 @@ } .fjs-form-field.fjs-checked .fjs-input[type='checkbox'], - .fjs-form-field .fjs-form-field-label.fjs-checked .fjs-input[type='checkbox'] { + .fjs-form-field .fjs-inline-label.fjs-checked .fjs-input[type='checkbox'] { &:before { border: none; border-width: 1px; diff --git a/packages/form-js-viewer/src/render/components/form-fields/Checklist.js b/packages/form-js-viewer/src/render/components/form-fields/Checklist.js index ca07b5933..8db1ae068 100644 --- a/packages/form-js-viewer/src/render/components/form-fields/Checklist.js +++ b/packages/form-js-viewer/src/render/components/form-fields/Checklist.js @@ -73,7 +73,11 @@ export function Checklist(props) { const isChecked = hasEqualValue(option.value, values); return ( -
+
0} aria-describedby={[descriptionId, errorMessageId].join(' ')} /> -
); })} diff --git a/packages/form-js-viewer/src/render/components/form-fields/Radio.js b/packages/form-js-viewer/src/render/components/form-fields/Radio.js index e3161151b..5d9552088 100644 --- a/packages/form-js-viewer/src/render/components/form-fields/Radio.js +++ b/packages/form-js-viewer/src/render/components/form-fields/Radio.js @@ -69,7 +69,11 @@ export function Radio(props) { const isChecked = isEqual(option.value, value); return ( -
+