@myissue/vue-website-page-builder 3.2.86 → 3.2.91
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +46 -3
- package/dist/vue-website-page-builder.css +1 -1
- package/dist/vue-website-page-builder.js +9217 -9022
- package/dist/vue-website-page-builder.umd.cjs +38 -38
- package/package.json +2 -2
- package/src/Components/Homepage/Footer.vue +9 -7
- package/src/Components/Homepage/Navbar.vue +6 -4
- package/src/Components/Layouts/FullWidthElement.vue +6 -6
- package/src/Components/Modals/BuilderComponents.vue +12 -6
- package/src/Components/Modals/DynamicModalBuilder.vue +39 -47
- package/src/Components/Modals/MediaLibraryModal.vue +2 -2
- package/src/Components/Modals/ModalBuilder.vue +23 -19
- package/src/Components/PageBuilder/DefaultComponents/DefaultBuilderComponents.vue +29 -17
- package/src/Components/PageBuilder/DefaultComponents/DefaultMediaLibraryComponent.vue +2 -2
- package/src/Components/PageBuilder/EditorMenu/Editables/BackgroundColorEditor.vue +22 -20
- package/src/Components/PageBuilder/EditorMenu/Editables/BorderRadius.vue +17 -17
- package/src/Components/PageBuilder/EditorMenu/Editables/Borders.vue +28 -26
- package/src/Components/PageBuilder/EditorMenu/Editables/ClassEditor.vue +13 -11
- package/src/Components/PageBuilder/EditorMenu/Editables/ComponentTopMenu.vue +5 -5
- package/src/Components/PageBuilder/EditorMenu/Editables/DeleteElement.vue +4 -4
- package/src/Components/PageBuilder/EditorMenu/Editables/EditGetElement.vue +22 -19
- package/src/Components/PageBuilder/EditorMenu/Editables/ElementEditor.vue +11 -11
- package/src/Components/PageBuilder/EditorMenu/Editables/ImageEditor.vue +4 -4
- package/src/Components/PageBuilder/EditorMenu/Editables/LinkEditor.vue +74 -66
- package/src/Components/PageBuilder/EditorMenu/Editables/ManageBackgroundOpacity.vue +26 -21
- package/src/Components/PageBuilder/EditorMenu/Editables/ManageOpacity.vue +26 -21
- package/src/Components/PageBuilder/EditorMenu/Editables/Margin.vue +101 -0
- package/src/Components/PageBuilder/EditorMenu/Editables/OpacityEditor.vue +2 -3
- package/src/Components/PageBuilder/EditorMenu/Editables/{PaddingPlusMargin.vue → Padding.vue} +8 -41
- package/src/Components/PageBuilder/EditorMenu/Editables/TextColorEditor.vue +22 -20
- package/src/Components/PageBuilder/EditorMenu/Editables/Typography.vue +63 -58
- package/src/Components/PageBuilder/EditorMenu/EditorAccordion.vue +7 -4
- package/src/Components/PageBuilder/EditorMenu/RightSidebarEditor.vue +24 -19
- package/src/Components/PageBuilder/Settings/AdvancedPageBuilderSettings.vue +132 -98
- package/src/Components/PageBuilder/Settings/PageBuilderSettings.vue +216 -146
- package/src/Components/PageBuilder/ToolbarOption/ToolbarOption.vue +14 -14
- package/src/Components/TipTap/TipTap.vue +4 -4
- package/src/Components/TipTap/TipTapInput.vue +39 -33
- package/src/DemoComponents/DemoBuilderComponents.vue +1 -1
- package/src/DemoComponents/DemoUnsplash.vue +79 -56
- package/src/DemoComponents/HomeSection.vue +20 -16
- package/src/DemoComponents/html.json +4 -4
- package/src/PageBuilder/PageBuilder.vue +62 -57
- package/src/PageBuilder/Preview.vue +4 -20
- package/src/composables/PageBuilderClass.ts +66 -120
- package/src/css/app.css +161 -448
- package/src/css/dev-global.css +137 -0
- package/src/main.ts +1 -0
- package/src/tailwind-safelist.html +1 -1
- package/src/utils/builder/tailwaind-colors.ts +488 -488
- package/src/utils/builder/tailwind-border-radius.ts +40 -40
- package/src/utils/builder/tailwind-border-style-width-color.ts +231 -231
- package/src/utils/builder/tailwind-font-sizes.ts +56 -57
- package/src/utils/builder/tailwind-font-styles.ts +44 -11
- package/src/utils/builder/tailwind-opacities.ts +30 -30
- package/src/utils/builder/tailwind-padding-margin.ts +136 -136
- package/dist/components.json +0 -36
- package/src/Components/Loaders/FullScreenSpinner.vue +0 -9
- package/src/Components/Loaders/SmallUniversalSpinner.vue +0 -26
|
@@ -87,21 +87,21 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
87
87
|
<template #title>Link</template>
|
|
88
88
|
<template #content>
|
|
89
89
|
<!-- Hyperlink ability / start -->
|
|
90
|
-
<div v-if="getHyperlinkAbility === false" class="rounded-md bg-red-50 p-2">
|
|
91
|
-
<div class="flex items-center">
|
|
92
|
-
<div class="flex-shrink-0">
|
|
93
|
-
<span class="myMediumIcon material-symbols-outlined"> warning </span>
|
|
90
|
+
<div v-if="getHyperlinkAbility === false" class="pbx-rounded-md pbx-bg-red-50 pbx-p-2">
|
|
91
|
+
<div class="pbx-flex pbx-items-center">
|
|
92
|
+
<div class="pbx-flex-shrink-0">
|
|
93
|
+
<span class="pbx-myMediumIcon material-symbols-outlined"> warning </span>
|
|
94
94
|
</div>
|
|
95
|
-
<div class="ml-2">
|
|
96
|
-
<p class="text-sm font-medium text-green-800">
|
|
95
|
+
<div class="pbx-ml-2">
|
|
96
|
+
<p class="pbx-text-sm pbx-font-medium pbx-text-green-800">
|
|
97
97
|
Not able to add hyperlink on this element
|
|
98
98
|
</p>
|
|
99
99
|
</div>
|
|
100
|
-
<div class="ml-auto pl-3">
|
|
101
|
-
<div class="-mx-1.5 -my-1.5">
|
|
100
|
+
<div class="pbx-ml-auto pbx-pl-3">
|
|
101
|
+
<div class="pbx-mx-1.5 pbx-my-1.5">
|
|
102
102
|
<button
|
|
103
103
|
type="button"
|
|
104
|
-
class="inline-flex rounded-md bg-green-50 p-1.5 text-green-500 hover:bg-green-100 focus:outline-none focus:ring-2 focus:ring-green-600 focus:ring-offset-2 focus:ring-offset-green-50"
|
|
104
|
+
class="pbx-inline-flex pbx-rounded-md pbx-bg-green-50 pbx-p-1.5 pbx-text-green-500 hover:pbx-bg-green-100 focus:pbx-outline-none focus:pbx-ring-2 focus:pbx-ring-green-600 focus:pbx-ring-offset-2 focus:pbx-ring-offset-green-50"
|
|
105
105
|
></button>
|
|
106
106
|
</div>
|
|
107
107
|
</div>
|
|
@@ -109,35 +109,35 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
109
109
|
</div>
|
|
110
110
|
<!-- Hyperlink ability / end -->
|
|
111
111
|
<div v-if="getHyperlinkAbility === true">
|
|
112
|
-
<div class="my-2 py-2">
|
|
113
|
-
<div class="flex items-center justify-between gap-2 w-full">
|
|
114
|
-
<p class="myPrimaryParagraph">Enable hyperlink</p>
|
|
112
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
113
|
+
<div class="pbx-flex pbx-items-center pbx-justify-between pbx-gap-2 pbx-w-full">
|
|
114
|
+
<p class="pbx-myPrimaryParagraph">Enable hyperlink</p>
|
|
115
115
|
<!-- Toggle start -->
|
|
116
116
|
<Switch
|
|
117
117
|
v-model="hyperlinkEnable"
|
|
118
118
|
@click="handleToggleHyperlinkEnable('removeHyperlink')"
|
|
119
119
|
:class="[
|
|
120
|
-
hyperlinkEnable ? 'bg-myPrimaryLinkColor' : 'bg-gray-200',
|
|
121
|
-
'relative inline-flex h-6 w-11 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-myPrimaryLinkColor focus:ring-offset-2',
|
|
120
|
+
hyperlinkEnable ? 'pbx-bg-myPrimaryLinkColor' : 'pbx-bg-gray-200',
|
|
121
|
+
'pbx-relative pbx-inline-flex pbx-h-6 pbx-w-11 pbx-flex-shrink-0 pbx-cursor-pointer pbx-rounded-full pbx-border-2 pbx-border-transparent pbx-transition-colors pbx-duration-200 pbx-ease-in-out focus:pbx-outline-none focus:pbx-ring-2 focus:pbx-ring-myPrimaryLinkColor focus:pbx-ring-offset-2',
|
|
122
122
|
]"
|
|
123
123
|
>
|
|
124
|
-
<span class="sr-only">Use setting</span>
|
|
124
|
+
<span class="pbx-sr-only">Use setting</span>
|
|
125
125
|
<span
|
|
126
126
|
:class="[
|
|
127
|
-
hyperlinkEnable ? 'translate-x-5' : 'translate-x-0',
|
|
128
|
-
'pointer-events-none relative inline-block h-5 w-5 transform rounded-full bg-white shadow ring-0 transition duration-200 ease-in-out',
|
|
127
|
+
hyperlinkEnable ? 'pbx-translate-x-5' : 'pbx-translate-x-0',
|
|
128
|
+
'pbx-pointer-events-none pbx-relative pbx-inline-block pbx-h-5 pbx-w-5 pbx-transform pbx-rounded-full pbx-bg-white pbx-shadow pbx-ring-0 pbx-transition pbx-duration-200 pbx-ease-in-out',
|
|
129
129
|
]"
|
|
130
130
|
>
|
|
131
131
|
<span
|
|
132
132
|
:class="[
|
|
133
133
|
hyperlinkEnable
|
|
134
|
-
? 'opacity-0 ease-out duration-100'
|
|
135
|
-
: 'opacity-100 ease-in duration-200',
|
|
136
|
-
'absolute inset-0 flex h-full w-full items-center justify-center transition-opacity',
|
|
134
|
+
? 'pbx-opacity-0 pbx-ease-out pbx-duration-100'
|
|
135
|
+
: 'pbx-opacity-100 pbx-ease-in pbx-duration-200',
|
|
136
|
+
'pbx-absolute pbx-inset-0 pbx-flex pbx-h-full pbx-w-full pbx-items-center pbx-justify-center pbx-transition-opacity',
|
|
137
137
|
]"
|
|
138
138
|
aria-hidden="true"
|
|
139
139
|
>
|
|
140
|
-
<svg class="h-3 w-3 text-gray-400" fill="none" viewBox="0 0 12 12">
|
|
140
|
+
<svg class="pbx-h-3 pbx-w-3 pbx-text-gray-400" fill="none" viewBox="0 0 12 12">
|
|
141
141
|
<path
|
|
142
142
|
d="M4 8l2-2m0 0l2-2M6 6L4 4m2 2l2 2"
|
|
143
143
|
stroke="currentColor"
|
|
@@ -150,14 +150,14 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
150
150
|
<span
|
|
151
151
|
:class="[
|
|
152
152
|
hyperlinkEnable
|
|
153
|
-
? 'opacity-100 ease-in duration-200'
|
|
154
|
-
: 'opacity-0 ease-out duration-100',
|
|
155
|
-
'absolute inset-0 flex h-full w-full items-center justify-center transition-opacity',
|
|
153
|
+
? 'pbx-opacity-100 pbx-ease-in pbx-duration-200'
|
|
154
|
+
: 'pbx-opacity-0 pbx-ease-out pbx-duration-100',
|
|
155
|
+
'pbx-absolute pbx-inset-0 pbx-flex pbx-h-full pbx-w-full pbx-items-center pbx-justify-center pbx-transition-opacity',
|
|
156
156
|
]"
|
|
157
157
|
aria-hidden="true"
|
|
158
158
|
>
|
|
159
159
|
<svg
|
|
160
|
-
class="h-3 w-3 text-myPrimaryLinkColor"
|
|
160
|
+
class="pbx-h-3 pbx-w-3 pbx-text-myPrimaryLinkColor"
|
|
161
161
|
fill="currentColor"
|
|
162
162
|
viewBox="0 0 12 12"
|
|
163
163
|
>
|
|
@@ -172,19 +172,22 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
172
172
|
</div>
|
|
173
173
|
</div>
|
|
174
174
|
<!-- attached url - start -->
|
|
175
|
-
<div
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
175
|
+
<div
|
|
176
|
+
v-if="getElementContainsHyperlink === true"
|
|
177
|
+
class="pbx-rounded-md pbx-bg-green-50 pbx-p-2"
|
|
178
|
+
>
|
|
179
|
+
<div class="pbx-flex pbx-items-center">
|
|
180
|
+
<div class="pbx-flex-shrink-0">
|
|
181
|
+
<span class="pbx-myMediumIcon material-symbols-outlined"> check </span>
|
|
179
182
|
</div>
|
|
180
|
-
<div class="ml-2">
|
|
181
|
-
<p class="text-sm font-medium text-green-800">Hyperlink added</p>
|
|
183
|
+
<div class="pbx-ml-2">
|
|
184
|
+
<p class="pbx-text-sm pbx-font-medium pbx-text-green-800">Hyperlink added</p>
|
|
182
185
|
</div>
|
|
183
|
-
<div class="ml-auto pl-3">
|
|
184
|
-
<div class="-mx-1.5 -my-1.5">
|
|
186
|
+
<div class="pbx-ml-auto pbx-pl-3">
|
|
187
|
+
<div class="pbx-mx-1.5 pbx-my-1.5">
|
|
185
188
|
<button
|
|
186
189
|
type="button"
|
|
187
|
-
class="inline-flex rounded-md bg-green-50 p-1.5 text-green-500 hover:bg-green-100 focus:outline-none focus:ring-2 focus:ring-green-600 focus:ring-offset-2 focus:ring-offset-green-50"
|
|
190
|
+
class="pbx-inline-flex pbx-rounded-md pbx-bg-green-50 pbx-p-1.5 pbx-text-green-500 hover:pbx-bg-green-100 focus:pbx-outline-none focus:pbx-ring-2 focus:pbx-ring-green-600 focus:pbx-ring-offset-2 focus:pbx-ring-offset-green-50"
|
|
188
191
|
></button>
|
|
189
192
|
</div>
|
|
190
193
|
</div>
|
|
@@ -192,81 +195,86 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
192
195
|
</div>
|
|
193
196
|
<!-- attached url - end -->
|
|
194
197
|
<!-- no attached url - start -->
|
|
195
|
-
<div
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
198
|
+
<div
|
|
199
|
+
v-if="getElementContainsHyperlink === false"
|
|
200
|
+
class="pbx-rounded-md pbx-bg-red-50 pbx-p-2"
|
|
201
|
+
>
|
|
202
|
+
<div class="pbx-flex pbx-items-center">
|
|
203
|
+
<div class="pbx-flex-shrink-0">
|
|
204
|
+
<span class="pbx-myMediumIcon material-symbols-outlined"> warning </span>
|
|
199
205
|
</div>
|
|
200
|
-
<div class="ml-2">
|
|
201
|
-
<p class="text-sm font-medium text-green-800">No hyperlink added</p>
|
|
206
|
+
<div class="pbx-ml-2">
|
|
207
|
+
<p class="pbx-text-sm pbx-font-medium pbx-text-green-800">No hyperlink added</p>
|
|
202
208
|
</div>
|
|
203
|
-
<div class="ml-auto pl-3">
|
|
204
|
-
<div class="-mx-1.5 -my-1.5">
|
|
209
|
+
<div class="pbx-ml-auto pbx-pl-3">
|
|
210
|
+
<div class="pbx-mx-1.5 pbx-my-1.5">
|
|
205
211
|
<button
|
|
206
212
|
type="button"
|
|
207
|
-
class="inline-flex rounded-md bg-green-50 p-1.5 text-green-500 hover:bg-green-100 focus:outline-none focus:ring-2 focus:ring-green-600 focus:ring-offset-2 focus:ring-offset-green-50"
|
|
213
|
+
class="pbx-inline-flex pbx-rounded-md pbx-bg-green-50 pbx-p-1.5 pbx-text-green-500 hover:pbx-bg-green-100 focus:pbx-outline-none focus:pbx-ring-2 focus:pbx-ring-green-600 focus:pbx-ring-offset-2 focus:pbx-ring-offset-green-50"
|
|
208
214
|
></button>
|
|
209
215
|
</div>
|
|
210
216
|
</div>
|
|
211
217
|
</div>
|
|
212
218
|
</div>
|
|
213
219
|
<!-- no attached url - end -->
|
|
214
|
-
<div v-if="hyperlinkEnable === true" class="my-2 py-2">
|
|
215
|
-
<div
|
|
220
|
+
<div v-if="hyperlinkEnable === true" class="pbx-my-2 pbx-py-2">
|
|
221
|
+
<div
|
|
222
|
+
class="pbx-relative pbx-flex pbx-items-center pbx-w-full pbx-border pbx-myPrimaryInput pbx-py-0 pbx-p-0"
|
|
223
|
+
>
|
|
216
224
|
<input
|
|
217
225
|
v-model="urlInput"
|
|
218
226
|
type="text"
|
|
219
227
|
placeholder="URL.."
|
|
220
228
|
autocomplete="off"
|
|
221
|
-
class="myPrimaryInput border-none rounded-r-none ml-0 w-full"
|
|
229
|
+
class="pbx-myPrimaryInput pbx-border-none pbx-rounded-r-none pbx-ml-0 pbx-w-full"
|
|
222
230
|
@keydown.enter.tab.prevent="handleHyperlink()"
|
|
223
231
|
/>
|
|
224
232
|
<div
|
|
225
|
-
class="border border-gray-200 border-none rounded flex items-center justify-center h-full w-8"
|
|
233
|
+
class="pbx-border pbx-border-gray-200 pbx-border-none pbx-rounded pbx-flex pbx-items-center pbx-justify-center pbx-h-full pbx-w-8"
|
|
226
234
|
>
|
|
227
|
-
<kbd class="myPrimaryParagraph text-gray-400 border-none"> ⏎ </kbd>
|
|
235
|
+
<kbd class="pbx-myPrimaryParagraph pbx-text-gray-400 pbx-border-none"> ⏎ </kbd>
|
|
228
236
|
</div>
|
|
229
237
|
</div>
|
|
230
238
|
|
|
231
239
|
<p
|
|
232
240
|
v-if="getHyperlinkMessage !== null"
|
|
233
|
-
class="myPrimaryParagraph text-myPrimarySuccesColor mt-1"
|
|
241
|
+
class="pbx-myPrimaryParagraph pbx-text-myPrimarySuccesColor pbx-mt-1"
|
|
234
242
|
>
|
|
235
243
|
{{ getHyperlinkMessage }}
|
|
236
244
|
</p>
|
|
237
|
-
<p v-if="getHyperlinkError !== null" class="myPrimaryParagraphError mt-1">
|
|
245
|
+
<p v-if="getHyperlinkError !== null" class="pbx-myPrimaryParagraphError pbx-mt-1">
|
|
238
246
|
{{ getHyperlinkError }}
|
|
239
247
|
</p>
|
|
240
248
|
|
|
241
|
-
<div class="my-2 py-2">
|
|
242
|
-
<div class="flex items-center justify-between gap-2 w-full">
|
|
243
|
-
<p class="myPrimaryParagraph">Open in new tab</p>
|
|
249
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
250
|
+
<div class="pbx-flex pbx-items-center pbx-justify-between pbx-gap-2 pbx-w-full">
|
|
251
|
+
<p class="pbx-myPrimaryParagraph">Open in new tab</p>
|
|
244
252
|
<!-- Toggle start -->
|
|
245
253
|
<Switch
|
|
246
254
|
v-model="openHyperlinkInNewTab"
|
|
247
255
|
@click="handleToggleOpenHyperlinkInNewTab"
|
|
248
256
|
:class="[
|
|
249
|
-
openHyperlinkInNewTab ? 'bg-myPrimaryLinkColor' : 'bg-gray-200',
|
|
250
|
-
'relative inline-flex h-6 w-11 flex-shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus:ring-2 focus:ring-myPrimaryLinkColor focus:ring-offset-2',
|
|
257
|
+
openHyperlinkInNewTab ? 'pbx-bg-myPrimaryLinkColor' : 'pbx-bg-gray-200',
|
|
258
|
+
'pbx-relative pbx-inline-flex pbx-h-6 pbx-w-11 pbx-flex-shrink-0 pbx-cursor-pointer pbx-rounded-full pbx-border-2 pbx-border-transparent pbx-transition-colors pbx-duration-200 pbx-ease-in-out focus:pbx-outline-none focus:pbx-ring-2 focus:pbx-ring-myPrimaryLinkColor focus:pbx-ring-offset-2',
|
|
251
259
|
]"
|
|
252
260
|
>
|
|
253
|
-
<span class="sr-only">Use setting</span>
|
|
261
|
+
<span class="pbx-sr-only">Use setting</span>
|
|
254
262
|
<span
|
|
255
263
|
:class="[
|
|
256
|
-
openHyperlinkInNewTab ? 'translate-x-5' : 'translate-x-0',
|
|
257
|
-
'pointer-events-none relative inline-block h-5 w-5 transform rounded-full bg-white shadow ring-0 transition duration-200 ease-in-out',
|
|
264
|
+
openHyperlinkInNewTab ? 'pbx-translate-x-5' : 'pbx-translate-x-0',
|
|
265
|
+
'pbx-pointer-events-none pbx-relative pbx-inline-block pbx-h-5 pbx-w-5 pbx-transform pbx-rounded-full pbx-bg-white pbx-shadow pbx-ring-0 pbx-transition pbx-duration-200 pbx-ease-in-out',
|
|
258
266
|
]"
|
|
259
267
|
>
|
|
260
268
|
<span
|
|
261
269
|
:class="[
|
|
262
270
|
openHyperlinkInNewTab
|
|
263
|
-
? 'opacity-0 ease-out duration-100'
|
|
264
|
-
: 'opacity-100 ease-in duration-200',
|
|
265
|
-
'absolute inset-0 flex h-full w-full items-center justify-center transition-opacity',
|
|
271
|
+
? 'pbx-opacity-0 pbx-ease-out pbx-duration-100'
|
|
272
|
+
: 'pbx-opacity-100 pbx-ease-in pbx-duration-200',
|
|
273
|
+
'pbx-absolute pbx-inset-0 pbx-flex pbx-h-full pbx-w-full pbx-items-center pbx-justify-center pbx-transition-opacity',
|
|
266
274
|
]"
|
|
267
275
|
aria-hidden="true"
|
|
268
276
|
>
|
|
269
|
-
<svg class="h-3 w-3 text-gray-400" fill="none" viewBox="0 0 12 12">
|
|
277
|
+
<svg class="pbx-h-3 pbx-w-3 pbx-text-gray-400" fill="none" viewBox="0 0 12 12">
|
|
270
278
|
<path
|
|
271
279
|
d="M4 8l2-2m0 0l2-2M6 6L4 4m2 2l2 2"
|
|
272
280
|
stroke="currentColor"
|
|
@@ -279,14 +287,14 @@ const handleToggleOpenHyperlinkInNewTab = async function () {
|
|
|
279
287
|
<span
|
|
280
288
|
:class="[
|
|
281
289
|
openHyperlinkInNewTab
|
|
282
|
-
? 'opacity-100 ease-in duration-200'
|
|
283
|
-
: 'opacity-0 ease-out duration-100',
|
|
284
|
-
'absolute inset-0 flex h-full w-full items-center justify-center transition-opacity',
|
|
290
|
+
? 'pbx-opacity-100 pbx-ease-in pbx-duration-200'
|
|
291
|
+
: 'pbx-opacity-0 pbx-ease-out pbx-duration-100',
|
|
292
|
+
'pbx-absolute pbx-inset-0 pbx-flex pbx-h-full pbx-w-full pbx-items-center pbx-justify-center pbx-transition-opacity',
|
|
285
293
|
]"
|
|
286
294
|
aria-hidden="true"
|
|
287
295
|
>
|
|
288
296
|
<svg
|
|
289
|
-
class="h-3 w-3 text-myPrimaryLinkColor"
|
|
297
|
+
class="pbx-h-3 pbx-w-3 pbx-text-myPrimaryLinkColor"
|
|
290
298
|
fill="currentColor"
|
|
291
299
|
viewBox="0 0 12 12"
|
|
292
300
|
>
|
|
@@ -31,41 +31,43 @@ watch(
|
|
|
31
31
|
</script>
|
|
32
32
|
|
|
33
33
|
<template>
|
|
34
|
-
<div class="my-2 py-2">
|
|
35
|
-
<label class="myPrimaryInputLabel"> Background opacity</label>
|
|
34
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
35
|
+
<label class="pbx-myPrimaryInputLabel"> Background opacity</label>
|
|
36
36
|
|
|
37
37
|
<Listbox as="div" v-model="opacityVueModel">
|
|
38
|
-
<div class="relative">
|
|
39
|
-
<ListboxButton class="myPrimarySelect">
|
|
40
|
-
<span class="flex items-center gap-2">
|
|
38
|
+
<div class="pbx-relative">
|
|
39
|
+
<ListboxButton class="pbx-myPrimarySelect">
|
|
40
|
+
<span class="pbx-flex pbx-items-center pbx-gap-2">
|
|
41
41
|
<div v-if="opacityVueModel === 'none'">
|
|
42
|
-
<div class="myPrimaryColorPreview border-none">
|
|
42
|
+
<div class="pbx-myPrimaryColorPreview pbx-border-none">
|
|
43
43
|
<span class="material-symbols-outlined"> ev_shadow </span>
|
|
44
44
|
</div>
|
|
45
45
|
</div>
|
|
46
46
|
|
|
47
47
|
<div
|
|
48
48
|
v-if="opacityVueModel !== 'none'"
|
|
49
|
-
class="aspect-square w-6 h-6 bg-gray-950"
|
|
49
|
+
class="pbx-aspect-square pbx-w-6 pbx-h-6 pbx-bg-gray-950"
|
|
50
50
|
:class="`${opacityVueModel}`"
|
|
51
51
|
></div>
|
|
52
52
|
|
|
53
|
-
<span class="block truncate" :class="[opacityVueModel !== 'none' ? '' : '']">{{
|
|
53
|
+
<span class="pbx-block pbx-truncate" :class="[opacityVueModel !== 'none' ? '' : '']">{{
|
|
54
54
|
opacityVueModel === 'none' ? 'Transparent' : opacityVueModel
|
|
55
55
|
}}</span>
|
|
56
56
|
</span>
|
|
57
|
-
<span
|
|
57
|
+
<span
|
|
58
|
+
class="pbx-pointer-events-none pbx-absolute pbx-inset-y-0 pbx-right-0 pbx-ml-3 pbx-flex pbx-items-center pbx-pr-2"
|
|
59
|
+
>
|
|
58
60
|
<span class="material-symbols-outlined"> keyboard_arrow_down </span>
|
|
59
61
|
</span>
|
|
60
62
|
</ListboxButton>
|
|
61
63
|
|
|
62
64
|
<transition
|
|
63
|
-
leave-active-class="transition ease-in duration-100"
|
|
64
|
-
leave-from-class="opacity-100"
|
|
65
|
-
leave-to-class="opacity-0"
|
|
65
|
+
leave-active-class="pbx-transition pbx-ease-in pbx-duration-100"
|
|
66
|
+
leave-from-class="pbx-opacity-100"
|
|
67
|
+
leave-to-class="pbx-opacity-0"
|
|
66
68
|
>
|
|
67
69
|
<ListboxOptions
|
|
68
|
-
class="absolute z-10 mt-1 max-h-56 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm"
|
|
70
|
+
class="pbx-absolute pbx-z-10 pbx-mt-1 pbx-max-h-56 pbx-w-full pbx-overflow-auto pbx-rounded-md pbx-bg-white pbx-py-1 pbx-text-base pbx-shadow-lg pbx-ring-1 pbx-ring-black pbx-ring-opacity-5 focus:pbx-outline-none sm:pbx-text-sm"
|
|
69
71
|
>
|
|
70
72
|
<ListboxOption
|
|
71
73
|
as="template"
|
|
@@ -77,26 +79,29 @@ watch(
|
|
|
77
79
|
>
|
|
78
80
|
<li
|
|
79
81
|
:class="[
|
|
80
|
-
active ? 'bg-myPrimaryLinkColor text-white' : 'text-myPrimaryDarkGrayColor',
|
|
81
|
-
'relative cursor-default select-none py-2 pl-3 pr-9',
|
|
82
|
+
active ? 'bg-myPrimaryLinkColor text-white' : 'pbx-text-myPrimaryDarkGrayColor',
|
|
83
|
+
'pbx-relative pbx-cursor-default pbx-select-none pbx-py-2 pbx-pl-3 pbx-pr-9',
|
|
82
84
|
]"
|
|
83
85
|
>
|
|
84
|
-
<div class="flex items-center">
|
|
85
|
-
<div
|
|
86
|
-
|
|
86
|
+
<div class="pbx-flex pbx-items-center">
|
|
87
|
+
<div
|
|
88
|
+
v-if="backgroundOpacity === 'none'"
|
|
89
|
+
class="pbx-aspect-square pbx-w-6 pbx-h-6"
|
|
90
|
+
>
|
|
91
|
+
<div class="pbx-myPrimaryColorPreview pbx-border-none">
|
|
87
92
|
<span class="material-symbols-outlined"> ev_shadow </span>
|
|
88
93
|
</div>
|
|
89
94
|
</div>
|
|
90
95
|
|
|
91
96
|
<div
|
|
92
97
|
v-if="backgroundOpacity !== 'none'"
|
|
93
|
-
class="aspect-square w-6 h-6 bg-gray-950"
|
|
98
|
+
class="pbx-aspect-square pbx-w-6 pbx-h-6 pbx-bg-gray-950"
|
|
94
99
|
:class="`${backgroundOpacity}`"
|
|
95
100
|
></div>
|
|
96
|
-
<span v-if="backgroundOpacity !== 'none'" class="ml-3">{{
|
|
101
|
+
<span v-if="backgroundOpacity !== 'none'" class="pbx-ml-3">{{
|
|
97
102
|
backgroundOpacity
|
|
98
103
|
}}</span>
|
|
99
|
-
<span v-if="backgroundOpacity === 'none'" class="ml-3">Transparent</span>
|
|
104
|
+
<span v-if="backgroundOpacity === 'none'" class="pbx-ml-3">Transparent</span>
|
|
100
105
|
</div>
|
|
101
106
|
</li>
|
|
102
107
|
</ListboxOption>
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { ref, computed, watch } from 'vue'
|
|
3
|
-
import EditorAccordion from '../EditorAccordion.vue'
|
|
4
3
|
import PageBuilderClass from '../../../../composables/PageBuilderClass.ts'
|
|
5
4
|
import tailwindOpacities from '../../../../utils/builder/tailwind-opacities'
|
|
6
5
|
import {
|
|
@@ -31,41 +30,43 @@ watch(
|
|
|
31
30
|
</script>
|
|
32
31
|
|
|
33
32
|
<template>
|
|
34
|
-
<div class="my-2 py-2">
|
|
35
|
-
<label class="myPrimaryInputLabel"> Opacity</label>
|
|
33
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
34
|
+
<label class="pbx-myPrimaryInputLabel"> Opacity</label>
|
|
36
35
|
|
|
37
36
|
<Listbox as="div" v-model="opacityVueModel">
|
|
38
|
-
<div class="relative">
|
|
39
|
-
<ListboxButton class="myPrimarySelect">
|
|
40
|
-
<span class="flex items-center gap-2">
|
|
37
|
+
<div class="pbx-relative">
|
|
38
|
+
<ListboxButton class="pbx-myPrimarySelect">
|
|
39
|
+
<span class="pbx-flex pbx-items-center pbx-gap-2">
|
|
41
40
|
<div v-if="opacityVueModel === 'none'">
|
|
42
|
-
<div class="myPrimaryColorPreview border-none">
|
|
41
|
+
<div class="pbx-myPrimaryColorPreview pbx-border-none">
|
|
43
42
|
<span class="material-symbols-outlined"> ev_shadow </span>
|
|
44
43
|
</div>
|
|
45
44
|
</div>
|
|
46
45
|
|
|
47
46
|
<div
|
|
48
47
|
v-if="opacityVueModel !== 'none'"
|
|
49
|
-
class="aspect-square w-6 h-6 bg-gray-950"
|
|
48
|
+
class="pbx-aspect-square pbx-w-6 pbx-h-6 pbx-bg-gray-950"
|
|
50
49
|
:class="`${opacityVueModel}`"
|
|
51
50
|
></div>
|
|
52
51
|
|
|
53
|
-
<span class="block truncate" :class="[opacityVueModel !== 'none' ? '' : '']">{{
|
|
52
|
+
<span class="pbx-block pbx-truncate" :class="[opacityVueModel !== 'none' ? '' : '']">{{
|
|
54
53
|
opacityVueModel === 'none' ? 'Transparent' : opacityVueModel
|
|
55
54
|
}}</span>
|
|
56
55
|
</span>
|
|
57
|
-
<span
|
|
56
|
+
<span
|
|
57
|
+
class="pbx-pointer-events-none pbx-absolute pbx-inset-y-0 pbx-right-0 pbx-ml-3 pbx-flex pbx-items-center pbx-pr-2"
|
|
58
|
+
>
|
|
58
59
|
<span class="material-symbols-outlined"> keyboard_arrow_down </span>
|
|
59
60
|
</span>
|
|
60
61
|
</ListboxButton>
|
|
61
62
|
|
|
62
63
|
<transition
|
|
63
|
-
leave-active-class="transition ease-in duration-100"
|
|
64
|
-
leave-from-class="opacity-100"
|
|
65
|
-
leave-to-class="opacity-0"
|
|
64
|
+
leave-active-class="pbx-transition pbx-ease-in pbx-duration-100"
|
|
65
|
+
leave-from-class="pbx-opacity-100"
|
|
66
|
+
leave-to-class="pbx-opacity-0"
|
|
66
67
|
>
|
|
67
68
|
<ListboxOptions
|
|
68
|
-
class="absolute z-10 mt-1 max-h-56 w-full overflow-auto rounded-md bg-white py-1 text-base shadow-lg ring-1 ring-black ring-opacity-5 focus:outline-none sm:text-sm"
|
|
69
|
+
class="pbx-absolute pbx-z-10 pbx-mt-1 pbx-max-h-56 pbx-w-full pbx-overflow-auto pbx-rounded-md pbx-bg-white pbx-py-1 pbx-text-base pbx-shadow-lg pbx-ring-1 pbx-ring-black pbx-ring-opacity-5 focus:pbx-outline-none sm:pbx-text-sm"
|
|
69
70
|
>
|
|
70
71
|
<ListboxOption
|
|
71
72
|
as="template"
|
|
@@ -77,24 +78,28 @@ watch(
|
|
|
77
78
|
>
|
|
78
79
|
<li
|
|
79
80
|
:class="[
|
|
80
|
-
active
|
|
81
|
-
|
|
81
|
+
active
|
|
82
|
+
? 'pbx-bg-myPrimaryLinkColor text-white'
|
|
83
|
+
: 'pbx-text-myPrimaryDarkGrayColor',
|
|
84
|
+
'pbx-relative pbx-cursor-default pbx-select-none pbx-py-2 pbx-pl-3 pbx-pr-9',
|
|
82
85
|
]"
|
|
83
86
|
>
|
|
84
|
-
<div class="flex items-center">
|
|
87
|
+
<div class="pbx-flex pbx-items-center">
|
|
85
88
|
<div v-if="elementOpacity === 'none'">
|
|
86
|
-
<div class="myPrimaryColorPreview border-none">
|
|
89
|
+
<div class="pbx-myPrimaryColorPreview pbx-border-none">
|
|
87
90
|
<span class="material-symbols-outlined"> ev_shadow </span>
|
|
88
91
|
</div>
|
|
89
92
|
</div>
|
|
90
93
|
|
|
91
94
|
<div
|
|
92
95
|
v-if="elementOpacity !== 'none'"
|
|
93
|
-
class="aspect-square w-6 h-6 bg-gray-950"
|
|
96
|
+
class="pbx-aspect-square pbx-w-6 pbx-h-6 pbx-bg-gray-950"
|
|
94
97
|
:class="`${elementOpacity}`"
|
|
95
98
|
></div>
|
|
96
|
-
<span v-if="elementOpacity === 'none'" class="ml-3">Transparent</span>
|
|
97
|
-
<span v-if="elementOpacity !== 'none'" class="ml-3">{{
|
|
99
|
+
<span v-if="elementOpacity === 'none'" class="pbx-ml-3">Transparent</span>
|
|
100
|
+
<span v-if="elementOpacity !== 'none'" class="pbx-ml-3">{{
|
|
101
|
+
elementOpacity
|
|
102
|
+
}}</span>
|
|
98
103
|
</div>
|
|
99
104
|
</li>
|
|
100
105
|
</ListboxOption>
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
<script setup>
|
|
2
|
+
import { ref, computed, watch } from 'vue'
|
|
3
|
+
import { sharedPageBuilderStore } from '../../../../stores/shared-store'
|
|
4
|
+
import EditorAccordion from '../EditorAccordion.vue'
|
|
5
|
+
import PageBuilderClass from '../../../../composables/PageBuilderClass.ts'
|
|
6
|
+
import tailwindPaddingPlusMargin from '../../../../utils/builder/tailwind-padding-margin'
|
|
7
|
+
|
|
8
|
+
// Use shared store instance
|
|
9
|
+
const pageBuilderStateStore = sharedPageBuilderStore
|
|
10
|
+
|
|
11
|
+
const pageBuilderClass = new PageBuilderClass(pageBuilderStateStore)
|
|
12
|
+
const fontVerticalPadding = ref(null)
|
|
13
|
+
const fontHorizontalPadding = ref(null)
|
|
14
|
+
const fontVerticalMargin = ref(null)
|
|
15
|
+
const fontHorizontalMargin = ref(null)
|
|
16
|
+
const getFontVerticalPadding = computed(() => {
|
|
17
|
+
return pageBuilderStateStore.getFontVerticalPadding
|
|
18
|
+
})
|
|
19
|
+
const getFontHorizontalPadding = computed(() => {
|
|
20
|
+
return pageBuilderStateStore.getFontHorizontalPadding
|
|
21
|
+
})
|
|
22
|
+
const getFontVerticalMargin = computed(() => {
|
|
23
|
+
return pageBuilderStateStore.getFontVerticalMargin
|
|
24
|
+
})
|
|
25
|
+
const getFontHorizontalMargin = computed(() => {
|
|
26
|
+
return pageBuilderStateStore.getFontHorizontalMargin
|
|
27
|
+
})
|
|
28
|
+
|
|
29
|
+
watch(
|
|
30
|
+
getFontVerticalPadding,
|
|
31
|
+
async (newValue) => {
|
|
32
|
+
fontVerticalPadding.value = newValue
|
|
33
|
+
await pageBuilderClass.initializeElementStyles()
|
|
34
|
+
},
|
|
35
|
+
{ immediate: true },
|
|
36
|
+
)
|
|
37
|
+
watch(
|
|
38
|
+
getFontHorizontalPadding,
|
|
39
|
+
async (newValue) => {
|
|
40
|
+
fontHorizontalPadding.value = newValue
|
|
41
|
+
await pageBuilderClass.initializeElementStyles()
|
|
42
|
+
},
|
|
43
|
+
{ immediate: true },
|
|
44
|
+
)
|
|
45
|
+
watch(
|
|
46
|
+
getFontVerticalMargin,
|
|
47
|
+
async (newValue) => {
|
|
48
|
+
fontVerticalMargin.value = newValue
|
|
49
|
+
await pageBuilderClass.initializeElementStyles()
|
|
50
|
+
},
|
|
51
|
+
{ immediate: true },
|
|
52
|
+
)
|
|
53
|
+
watch(
|
|
54
|
+
getFontHorizontalMargin,
|
|
55
|
+
async (newValue) => {
|
|
56
|
+
fontHorizontalMargin.value = newValue
|
|
57
|
+
await pageBuilderClass.initializeElementStyles()
|
|
58
|
+
},
|
|
59
|
+
{ immediate: true },
|
|
60
|
+
)
|
|
61
|
+
</script>
|
|
62
|
+
<template>
|
|
63
|
+
<EditorAccordion>
|
|
64
|
+
<template #title>Margin</template>
|
|
65
|
+
<template #content>
|
|
66
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
67
|
+
<label class="pbx-myPrimaryInputLabel"> Vertical Margin </label>
|
|
68
|
+
<select
|
|
69
|
+
v-model="fontVerticalMargin"
|
|
70
|
+
class="pbx-myPrimarySelect"
|
|
71
|
+
@change="pageBuilderClass.handleVerticalMargin(fontVerticalMargin)"
|
|
72
|
+
>
|
|
73
|
+
<option disabled value="">Select</option>
|
|
74
|
+
<option
|
|
75
|
+
v-for="verticalMargin in tailwindPaddingPlusMargin.verticalMargin"
|
|
76
|
+
:key="verticalMargin"
|
|
77
|
+
>
|
|
78
|
+
{{ verticalMargin }}
|
|
79
|
+
</option>
|
|
80
|
+
</select>
|
|
81
|
+
</div>
|
|
82
|
+
<hr />
|
|
83
|
+
<div class="pbx-my-2 pbx-py-2">
|
|
84
|
+
<label class="pbx-myPrimaryInputLabel"> Horizontal Margin </label>
|
|
85
|
+
<select
|
|
86
|
+
v-model="fontHorizontalMargin"
|
|
87
|
+
class="pbx-myPrimarySelect"
|
|
88
|
+
@change="pageBuilderClass.handleHorizontalMargin(fontHorizontalMargin)"
|
|
89
|
+
>
|
|
90
|
+
<option disabled value="">Select</option>
|
|
91
|
+
<option
|
|
92
|
+
v-for="horizontalMargin in tailwindPaddingPlusMargin.horizontalMargin"
|
|
93
|
+
:key="horizontalMargin"
|
|
94
|
+
>
|
|
95
|
+
{{ horizontalMargin }}
|
|
96
|
+
</option>
|
|
97
|
+
</select>
|
|
98
|
+
</div>
|
|
99
|
+
</template>
|
|
100
|
+
</EditorAccordion>
|
|
101
|
+
</template>
|
|
@@ -6,11 +6,10 @@ import ManageOpacity from './ManageOpacity.vue'
|
|
|
6
6
|
|
|
7
7
|
<template>
|
|
8
8
|
<EditorAccordion>
|
|
9
|
-
<template #title>Opacity
|
|
9
|
+
<template #title>Opacity & Transparency </template>
|
|
10
10
|
<template #content>
|
|
11
|
-
<p class="myPrimaryParagraph font-medium py-0 my-4">Opacity</p>
|
|
12
|
-
<!-- Text color - end -->
|
|
13
11
|
<ManageOpacity></ManageOpacity>
|
|
12
|
+
<hr />
|
|
14
13
|
<ManageBackgroundOpacity></ManageBackgroundOpacity>
|
|
15
14
|
</template>
|
|
16
15
|
</EditorAccordion>
|