diff --git a/resources/js/components/forms/components/VSelect.vue b/resources/js/components/forms/components/VSelect.vue index 6c68cc823..0e2879c48 100644 --- a/resources/js/components/forms/components/VSelect.vue +++ b/resources/js/components/forms/components/VSelect.vue @@ -57,8 +57,8 @@ - @@ -67,8 +67,8 @@ {{ (allowCreation ? 'Type something to add an option': 'No option available') }}. - Create {{ searchTerm }} @@ -127,6 +127,11 @@ export default { } }, computed: { + optionStyle () { + return { + '--bg-form-color': this.color + } + }, inputStyle () { return { '--tw-ring-color': this.color diff --git a/resources/js/components/open/forms/components/FormFieldsEditor.vue b/resources/js/components/open/forms/components/FormFieldsEditor.vue index 9bf56f535..4abfbec5e 100644 --- a/resources/js/components/open/forms/components/FormFieldsEditor.vue +++ b/resources/js/components/open/forms/components/FormFieldsEditor.vue @@ -294,10 +294,10 @@ export default { this.$store.commit('open/working_form/openSettingsForField', this.formFields.length-1) }, removeBlock(blockIndex) { - this.closeSidebar() const newFields = clonedeep(this.formFields) newFields.splice(blockIndex, 1) this.$set(this, 'formFields', newFields) + this.closeSidebar() }, closeSidebar() { this.$store.commit('open/working_form/closeEditFieldSidebar') diff --git a/resources/js/components/open/forms/fields/FormFieldEditSidebar.vue b/resources/js/components/open/forms/fields/FormFieldEditSidebar.vue index 7b54e6f37..b0eb1067b 100644 --- a/resources/js/components/open/forms/fields/FormFieldEditSidebar.vue +++ b/resources/js/components/open/forms/fields/FormFieldEditSidebar.vue @@ -121,18 +121,18 @@ export default { this.$set(this.field, 'type', newType) }, removeBlock() { - this.closeSidebar() const newFields = clonedeep(this.form.properties) newFields.splice(this.selectedFieldIndex, 1) this.$set(this.form, 'properties', newFields) + this.closeSidebar() }, duplicateBlock() { - this.closeSidebar() const newFields = clonedeep(this.form.properties) const newField = clonedeep(this.form.properties[this.selectedFieldIndex]) newField.id = this.generateUUID() newFields.push(newField) this.$set(this.form, 'properties', newFields) + this.closeSidebar() }, closeSidebar() { this.$store.commit('open/working_form/closeEditFieldSidebar') diff --git a/resources/sass/app.scss b/resources/sass/app.scss index 27806698b..bf630dc47 100644 --- a/resources/sass/app.scss +++ b/resources/sass/app.scss @@ -18,6 +18,10 @@ body.dark * { @layer base { + :root { + --bg-form-color: #2563eb; + } + p, div { @apply text-gray-900 dark:text-white; } diff --git a/tailwind.config.js b/tailwind.config.js index a57431c16..42dc0aa5e 100644 --- a/tailwind.config.js +++ b/tailwind.config.js @@ -68,7 +68,8 @@ module.exports = { backgroundDark: '#272B2C', help: '#37352f99', helpDark: '#fff9' - } + }, + 'form-color': 'var(--bg-form-color)' }, transitionProperty: { height: 'height',
{{ (allowCreation ? 'Type something to add an option': 'No option available') }}.