From b9ec1832583c916be50bc36d1a50b14dba16b9e3 Mon Sep 17 00:00:00 2001 From: dzieko Date: Tue, 28 Jun 2022 10:36:22 +0200 Subject: [PATCH] input emit, wymuszeni doswiezenia pola bo usuwa z globalnej zmiennej --- src/components/plugin/SectionHtml.vue | 1 + src/components/plugin/SectionText.vue | 2 ++ src/components/plugin/SectionTextarea.vue | 2 ++ 3 files changed, 5 insertions(+) diff --git a/src/components/plugin/SectionHtml.vue b/src/components/plugin/SectionHtml.vue index 62eee14..71fce10 100644 --- a/src/components/plugin/SectionHtml.vue +++ b/src/components/plugin/SectionHtml.vue @@ -40,6 +40,7 @@ export default { this.name = (this.value && this.value.name) ? this.value.name : this.name; this.text = (this.value && this.value.text) ? this.value.text : this.text; if (this.value.open) this.modalBox = true; + this.$emit('input',this.value); }, data: function () { return { diff --git a/src/components/plugin/SectionText.vue b/src/components/plugin/SectionText.vue index 26181fb..e0959c8 100644 --- a/src/components/plugin/SectionText.vue +++ b/src/components/plugin/SectionText.vue @@ -78,6 +78,8 @@ export default { this.align = (this.value && this.value.align) ? this.value.align : this.align; if (this.value.open) this.modalBox = true; console.log('pagebuilder', this.$pagebuilder); + this.$emit('input',this.value); + }, methods: { removeItem: function () { diff --git a/src/components/plugin/SectionTextarea.vue b/src/components/plugin/SectionTextarea.vue index 9118e32..8414b96 100644 --- a/src/components/plugin/SectionTextarea.vue +++ b/src/components/plugin/SectionTextarea.vue @@ -43,6 +43,8 @@ export default { this.name = (this.value && this.value.name) ? this.value.name : this.name; this.text = (this.value && this.value.text) ? this.value.text : this.text; if (this.value.open) this.modalBox = true; + this.$emit('input',this.value); + }, data: function () { return {