diff --git a/src/components/imagechoice/_imagechoice.scss b/src/components/imagechoice/_imagechoice.scss new file mode 100644 index 0000000..ba92f95 --- /dev/null +++ b/src/components/imagechoice/_imagechoice.scss @@ -0,0 +1,114 @@ +/* ===============Image choice================== */ +.cmp-adaptiveform-imagechoice { + color: #666; + flex-direction: column; + margin: 0.25rem 0; + font-size: 1rem; + display: flex; +} +.cmp-adaptiveform-imagechoice__widget { + color: #666; + flex-wrap: wrap; + gap: 20px; + margin-top: 10px; + font-size: 1rem; + display: flex +} +.cmp-adaptiveform-imagechoice__label { +} +.cmp-adaptiveform-imagechoice__label-container{ + justify-content: space-between; + align-items: center; + display: flex; +} +.cmp-adaptiveform-imagechoice__widget__label { +} +.cmp-adaptiveform-imagechoice__longdescription { + color: #969696; + background-color: #E6E6E6; + margin-top: 10px; + margin-bottom: 5px; + padding: 10px; + font-size: .875rem +} +.cmp-adaptiveform-imagechoice__longdescription p { + margin: 0; + padding: 0 +} +.cmp-adaptiveform-imagechoice__shortdescription { + margin-top: 10px; + font-size: .875rem +} +.cmp-adaptiveform-imagechoice__label-container .cmp-adaptiveform-imagechoice__questionmark { + position: unset; + right: unset +} +.cmp-adaptiveform-imagechoice__questionmark { + display: inline-block; + cursor: pointer; + background: url(/apps/forms-components-examples/clientlibs/forms-clientlib-site/styles/components/adaptive-form/resources/question.svg) 50%/cover no-repeat,#969696; + border-radius: 9px; + width: 1rem; + height: 1rem; + display: inline-block; + position: absolute; + right: 20px +} +.cmp-adaptiveform-imagechoice__options { +} +.cmp-adaptiveform-imagechoice__option { + background-repeat: no-repeat; + background-size: contain; + color: #666; +} +.cmp-adaptiveform-imagechoice__option--selected { +} +.cmp-adaptiveform-imagechoice__option input[type="checkbox"], +.cmp-adaptiveform-imagechoice__option input[type="radio"] { + position: relative; + float: none; + vertical-align: middle; +} +.cmp-adaptiveform-imagechoice__option-label { +} + +.cmp-adaptiveform-imagechoice__option__widget__image { + width: 80px; + height: 80px; +} +.cmp-adaptiveform-imagechoice__option__widget{ + top: -69px; +} +.cmp-adaptiveform-imagechoice__widget.HORIZONTAL { + min-height: 40px; +} +.cmp-adaptiveform-imagechoice__widget.VERTICAL { + flex-direction: column +} +.cmp-adaptiveform-imagechoice__widget.HORIZONTAL .cmp-adaptiveform-imagechoice-option { + max-width: 240px +} +.cmp-adaptiveform-imagechoice__errormessage { + color: #EB3C36; + margin-top: 10px; + font-size: .875rem; +} +.cmp-adaptiveform-imagechoice[data-cmp-valid=false] { + -webkit-padding-start: 5px; + border: 0 solid #EB3C36; + background: #eb3c360d; + border-inline-start-width:4px; + padding-inline-start:5px +} + +.cmp-adaptiveform-imagechoice[data-cmp-valid=true] { + -webkit-padding-start: 5px; + border: 0 solid #23B482; + border-inline-start-width:4px; + padding-inline-start:5px +} + +.cmp-adaptiveform-imagechoice__option__alt-text { + text-align: center; + margin-left: 25px; +} \ No newline at end of file diff --git a/src/resources/images/ImageChoiceSelectIcon.svg b/src/resources/images/ImageChoiceSelectIcon.svg new file mode 100644 index 0000000..4b8a98b --- /dev/null +++ b/src/resources/images/ImageChoiceSelectIcon.svg @@ -0,0 +1,9 @@ + + + + + + + diff --git a/src/theme.scss b/src/theme.scss index 73a9b5e..3d26074 100644 --- a/src/theme.scss +++ b/src/theme.scss @@ -33,3 +33,4 @@ @import 'src/components/recaptcha/_recaptcha.scss'; @import 'src/components/verticaltabs/_verticaltabs.scss'; @import 'src/components/checkbox/_checkbox.scss'; +@import 'src/components/imagechoice/_imagechoice.scss';