@mixd-id/web-scaffold 0.2.250801010 → 0.2.250801012
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/docs/components/AccountIcon.md +16 -0
- package/docs/components/Ahref.md +35 -0
- package/docs/components/Alert.md +72 -0
- package/docs/components/ArrayList.md +39 -0
- package/docs/components/Article.md +28 -0
- package/docs/components/BarChart.md +81 -0
- package/docs/components/Block.md +23 -0
- package/docs/components/Box.md +15 -0
- package/docs/components/Button.md +68 -0
- package/docs/components/Card.md +67 -0
- package/docs/components/Carousel.md +70 -0
- package/docs/components/Cart.md +20 -0
- package/docs/components/CartIcon.md +29 -0
- package/docs/components/Chart.md +53 -0
- package/docs/components/ChartBar.md +34 -0
- package/docs/components/ChatTyping.md +21 -0
- package/docs/components/Checkbox.md +63 -0
- package/docs/components/CodeEditor.md +25 -0
- package/docs/components/CollapsiblePanel.md +41 -0
- package/docs/components/ColorPicker.md +52 -0
- package/docs/components/Confirm.md +62 -0
- package/docs/components/ContextMenu.md +76 -0
- package/docs/components/ContextMenuItem.md +29 -0
- package/docs/components/CopyToClipboard.md +43 -0
- package/docs/components/Countdown.md +47 -0
- package/docs/components/Datepicker.md +61 -0
- package/docs/components/Datetimepicker.md +57 -0
- package/docs/components/DayTimeRange.md +20 -0
- package/docs/components/Dropdown.md +65 -0
- package/docs/components/ErrorText.md +15 -0
- package/docs/components/FBLogin.md +21 -0
- package/docs/components/Flex.md +44 -0
- package/docs/components/GHeatMaps.md +16 -0
- package/docs/components/GSignIn.md +21 -0
- package/docs/components/Gmaps.md +16 -0
- package/docs/components/GmapsDirection.md +20 -0
- package/docs/components/Grid.md +36 -0
- package/docs/components/HTMLEditor.md +26 -0
- package/docs/components/IconMenu.md +20 -0
- package/docs/components/Image.md +78 -0
- package/docs/components/Link.md +33 -0
- package/docs/components/MultiDropdown.md +46 -0
- package/docs/components/Radio.md +55 -0
- package/docs/components/Slider.md +47 -0
- package/docs/components/Switch.md +43 -0
- package/docs/components/Table.md +31 -0
- package/docs/components/Tabs.md +65 -0
- package/docs/components/Text.md +30 -0
- package/docs/components/Textarea.md +66 -0
- package/docs/components/Textbox.md +97 -0
- package/docs/components/Timepicker.md +62 -0
- package/docs/components/Toast.md +59 -0
- package/docs/components/Uploader.md +51 -0
- package/docs/components/Video.md +54 -0
- package/package.json +65 -2
- package/docs/components/Dashboard.md +0 -56
- package/docs/components/Header2.md +0 -16
- package/log.txt +0 -7
- package/public/assets/dashboard/bar.png +0 -0
- package/public/assets/dashboard/doughnut.png +0 -0
- package/public/assets/dashboard/metric.png +0 -0
- package/public/assets/dashboard/pie.png +0 -0
- package/public/assets/dashboard/polar-area.png +0 -0
- package/public/assets/dashboard/virtual-table.png +0 -0
- package/public/static/dashboard/bar.png +0 -0
- package/public/static/dashboard/doughnut.png +0 -0
- package/public/static/dashboard/metric.png +0 -0
- package/public/static/dashboard/pie.png +0 -0
- package/public/static/dashboard/polar-area.png +0 -0
- package/public/static/dashboard/virtual-table.png +0 -0
- package/src/components/404.vue +0 -61
- package/src/components/AccountIcon.vue +0 -19
- package/src/components/Ahref.vue +0 -200
- package/src/components/Alert.vue +0 -257
- package/src/components/ArrayList.vue +0 -49
- package/src/components/Article.vue +0 -387
- package/src/components/Block.vue +0 -31
- package/src/components/Box.vue +0 -34
- package/src/components/Button.vue +0 -258
- package/src/components/Card.vue +0 -257
- package/src/components/Carousel.vue +0 -364
- package/src/components/Cart.vue +0 -192
- package/src/components/CartIcon.vue +0 -89
- package/src/components/Chart.vue +0 -485
- package/src/components/ChartBar.vue +0 -192
- package/src/components/ChatTyping.vue +0 -69
- package/src/components/Checkbox.vue +0 -200
- package/src/components/Checkout.vue +0 -373
- package/src/components/CheckoutDelivery.vue +0 -267
- package/src/components/CodeEditor.vue +0 -50
- package/src/components/CollapsiblePanel.vue +0 -70
- package/src/components/ColorPicker.vue +0 -165
- package/src/components/ColorPicker2.vue +0 -186
- package/src/components/ColorPicker3.vue +0 -100
- package/src/components/Confirm.vue +0 -180
- package/src/components/ContextMenu.vue +0 -265
- package/src/components/ContextMenuItem.vue +0 -53
- package/src/components/ConversationBuilder.vue +0 -161
- package/src/components/CopyToClipboard.vue +0 -34
- package/src/components/Countdown.vue +0 -264
- package/src/components/DGrid.vue +0 -21
- package/src/components/DGridItem.vue +0 -263
- package/src/components/Dashboard.vue +0 -243
- package/src/components/Dashboard2.vue +0 -118
- package/src/components/DashboardComponentSelector.vue +0 -96
- package/src/components/DashboardConfigs.vue +0 -202
- package/src/components/DataList.vue +0 -92
- package/src/components/Datepicker.vue +0 -399
- package/src/components/DayTimeRange.vue +0 -126
- package/src/components/Dropdown.vue +0 -224
- package/src/components/ErrorText.vue +0 -57
- package/src/components/FBLogin.vue +0 -194
- package/src/components/Feed.vue +0 -118
- package/src/components/Flex.vue +0 -44
- package/src/components/GHeatMaps.vue +0 -317
- package/src/components/GSignIn.vue +0 -166
- package/src/components/Gmaps.vue +0 -251
- package/src/components/GmapsDirection.vue +0 -191
- package/src/components/Grid.vue +0 -35
- package/src/components/HTMLEditor.vue +0 -588
- package/src/components/IconMenu.vue +0 -95
- package/src/components/IconMenu2.vue +0 -89
- package/src/components/IconPlus.vue +0 -89
- package/src/components/Image.vue +0 -263
- package/src/components/Image360.vue +0 -140
- package/src/components/ImageFullScreen.vue +0 -101
- package/src/components/ImagePreview.vue +0 -93
- package/src/components/ImageUploader.vue +0 -114
- package/src/components/ImportModal.vue +0 -260
- package/src/components/Link.vue +0 -95
- package/src/components/List.vue +0 -1381
- package/src/components/ListContextMenu.vue +0 -88
- package/src/components/ListItem.vue +0 -160
- package/src/components/ListPage1.vue +0 -1401
- package/src/components/ListPage1Filter.vue +0 -170
- package/src/components/ListView.vue +0 -961
- package/src/components/ListViewBarSummary.vue +0 -81
- package/src/components/ListViewLineSummary.vue +0 -75
- package/src/components/ListViewLiveBarSummary.vue +0 -52
- package/src/components/ListViewMapSummary.vue +0 -56
- package/src/components/ListViewSettings.vue +0 -514
- package/src/components/ListViewTableSummary.vue +0 -77
- package/src/components/LogViewerItem.vue +0 -116
- package/src/components/MarkdownEdit.vue +0 -128
- package/src/components/MarkdownPreview.vue +0 -102
- package/src/components/MenuItem1.vue +0 -36
- package/src/components/Modal.vue +0 -456
- package/src/components/MultiDropdown.vue +0 -124
- package/src/components/MultilineText.vue +0 -174
- package/src/components/OTPField.vue +0 -139
- package/src/components/ObjectTree.vue +0 -105
- package/src/components/PageBuilder.vue +0 -449
- package/src/components/Paragraph.vue +0 -40
- package/src/components/PresetSelectorFilterItem.vue +0 -203
- package/src/components/Radio.vue +0 -109
- package/src/components/SearchModal.vue +0 -153
- package/src/components/Slider.vue +0 -317
- package/src/components/SplitPane.vue +0 -129
- package/src/components/Svg.vue +0 -33
- package/src/components/SvgEditor.vue +0 -173
- package/src/components/Switch.vue +0 -101
- package/src/components/TabView.vue +0 -105
- package/src/components/Table.vue +0 -56
- package/src/components/TableView.vue +0 -200
- package/src/components/TableViewHead.vue +0 -159
- package/src/components/Tabs.vue +0 -131
- package/src/components/Test.vue +0 -23
- package/src/components/Testimonial.vue +0 -86
- package/src/components/Text.vue +0 -34
- package/src/components/TextBlock.vue +0 -50
- package/src/components/TextEditor.vue +0 -85
- package/src/components/TextWithTag.vue +0 -298
- package/src/components/Textarea.vue +0 -184
- package/src/components/Textbox.vue +0 -216
- package/src/components/Thumbnail.vue +0 -27
- package/src/components/Timepicker.vue +0 -125
- package/src/components/Toast.vue +0 -117
- package/src/components/TreeMenu.vue +0 -122
- package/src/components/TreeView.vue +0 -106
- package/src/components/TreeView2.vue +0 -38
- package/src/components/TreeViewItem.vue +0 -453
- package/src/components/TreeViewItem1.vue +0 -282
- package/src/components/TreeViewItem2.vue +0 -55
- package/src/components/Uploader.vue +0 -45
- package/src/components/Video.vue +0 -119
- package/src/components/VirtualGrid.vue +0 -297
- package/src/components/VirtualScroll.vue +0 -282
- package/src/components/VirtualTable.vue +0 -956
- package/src/components/YoutubeVideo.vue +0 -196
- package/src/configs/dashboard/bar.js +0 -10
- package/src/configs/dashboard/collection-1.js +0 -5
- package/src/configs/dashboard/data-table.js +0 -9
- package/src/configs/dashboard/doughnut.js +0 -7
- package/src/configs/dashboard/gheatmaps.js +0 -9
- package/src/configs/dashboard/grid-2.js +0 -34
- package/src/configs/dashboard/grid-3.js +0 -34
- package/src/configs/dashboard/grid-4.js +0 -34
- package/src/configs/dashboard/grid.js +0 -15
- package/src/configs/dashboard/metric.js +0 -10
- package/src/configs/dashboard/pie.js +0 -7
- package/src/configs/dashboard/polar-area.js +0 -7
- package/src/configs/dashboard/virtual-table.js +0 -9
- package/src/configs/icons-fa.json +0 -12
- package/src/configs/web-page-builder.js +0 -118
- package/src/defs/dashboard-preset.js +0 -22
- package/src/directives/intersect.js +0 -26
- package/src/hooks/device.js +0 -14
- package/src/index.css +0 -3
- package/src/index.js +0 -648
- package/src/middleware/http/trim-string.js +0 -20
- package/src/mixin/component.js +0 -306
- package/src/mixin/ready-state.js +0 -37
- package/src/stores/components.js +0 -36
- package/src/stores/datasource.js +0 -11
- package/src/themes/default/index.js +0 -303
- package/src/utils/dashboard.js +0 -140
- package/src/utils/event-bus.js +0 -8
- package/src/utils/helpers.cjs +0 -635
- package/src/utils/helpers.js +0 -635
- package/src/utils/helpers.mjs +0 -722
- package/src/utils/importer.js +0 -209
- package/src/utils/list.mjs +0 -1509
- package/src/utils/listpage1.js +0 -1507
- package/src/utils/listview.js +0 -1287
- package/src/utils/preset-selector.cjs +0 -1455
- package/src/utils/preset-selector.js +0 -1452
- package/src/utils/preset-selector.mjs +0 -234
- package/src/utils/queue.js +0 -63
- package/src/utils/selection.js +0 -43
- package/src/utils/web.js +0 -50
- package/src/utils/web.mjs +0 -120
- package/src/utils/wss.js +0 -296
- package/src/utils/wss.mjs +0 -285
- package/src/widgets/AhrefSetting.vue +0 -97
- package/src/widgets/ArticleSetting.vue +0 -457
- package/src/widgets/BackgroundColorSetting.vue +0 -153
- package/src/widgets/BackgroundSetting.vue +0 -132
- package/src/widgets/BlockSetting.vue +0 -49
- package/src/widgets/BorderColorSetting.vue +0 -57
- package/src/widgets/BorderSetting.vue +0 -201
- package/src/widgets/BotEditor/BotEditorActions.vue +0 -163
- package/src/widgets/BotEditor/BotEditorSettings.vue +0 -21
- package/src/widgets/BotEditor.vue +0 -248
- package/src/widgets/BoxSetting.vue +0 -53
- package/src/widgets/ButtonSetting.vue +0 -113
- package/src/widgets/CarouselSetting.vue +0 -181
- package/src/widgets/CartSetting.vue +0 -46
- package/src/widgets/CheckoutSetting.vue +0 -46
- package/src/widgets/CollapsiblePanelSetting.vue +0 -46
- package/src/widgets/ColumnSelector.vue +0 -104
- package/src/widgets/ComponentPropertyLabel.vue +0 -35
- package/src/widgets/ComponentPropertySelector.vue +0 -115
- package/src/widgets/ComponentSetting.vue +0 -2220
- package/src/widgets/ComponentSetting2.vue +0 -927
- package/src/widgets/ComponentSetting3.vue +0 -231
- package/src/widgets/ContactForm.vue +0 -193
- package/src/widgets/ContactFormSetting.vue +0 -395
- package/src/widgets/CountdownSetting.vue +0 -76
- package/src/widgets/Dashboard/BarChart.vue +0 -366
- package/src/widgets/Dashboard/BarChartSetting.vue +0 -317
- package/src/widgets/Dashboard/DataTable.vue +0 -125
- package/src/widgets/Dashboard/DataTableSetting.vue +0 -243
- package/src/widgets/Dashboard/DatasourceFilterSharing.vue +0 -93
- package/src/widgets/Dashboard/DatasourcePreview.vue +0 -93
- package/src/widgets/Dashboard/DatasourceSelector.vue +0 -122
- package/src/widgets/Dashboard/Doughnut.vue +0 -199
- package/src/widgets/Dashboard/DoughnutSetting.vue +0 -196
- package/src/widgets/Dashboard/GHeatMapsSetting.vue +0 -108
- package/src/widgets/Dashboard/InteractionEdit.vue +0 -228
- package/src/widgets/Dashboard/Metric.vue +0 -135
- package/src/widgets/Dashboard/MetricSetting.vue +0 -227
- package/src/widgets/Dashboard/Pie.vue +0 -188
- package/src/widgets/Dashboard/PieSetting.vue +0 -247
- package/src/widgets/Dashboard/PolarArea.vue +0 -201
- package/src/widgets/Dashboard/PolarAreaSetting.vue +0 -195
- package/src/widgets/Dashboard/SharingModal.vue +0 -115
- package/src/widgets/Dashboard/ViewSelector.vue +0 -183
- package/src/widgets/Dashboard/VirtualColumnEdit.vue +0 -97
- package/src/widgets/Dashboard/VirtualTableSetting.vue +0 -171
- package/src/widgets/Dashboard0.vue +0 -1856
- package/src/widgets/DataListSetting.vue +0 -102
- package/src/widgets/EffectSetting.vue +0 -94
- package/src/widgets/EmbeddedVideo.vue +0 -60
- package/src/widgets/EmbeddedVideoSetting.vue +0 -50
- package/src/widgets/FAQ.vue +0 -98
- package/src/widgets/FAQSetting.vue +0 -94
- package/src/widgets/FeatureList.vue +0 -131
- package/src/widgets/FeatureListSetting.vue +0 -233
- package/src/widgets/FiltersSetting.vue +0 -88
- package/src/widgets/FlexSetting.vue +0 -174
- package/src/widgets/GridSetting.vue +0 -165
- package/src/widgets/Header.vue +0 -15
- package/src/widgets/Header0.vue +0 -41
- package/src/widgets/Header0Setting.vue +0 -75
- package/src/widgets/Header2.vue +0 -65
- package/src/widgets/Header2Setting.vue +0 -193
- package/src/widgets/HeaderSetting.vue +0 -102
- package/src/widgets/IconList.vue +0 -51
- package/src/widgets/IconListSetting.vue +0 -188
- package/src/widgets/ImageSetting.vue +0 -119
- package/src/widgets/LayoutSetting.vue +0 -251
- package/src/widgets/LinkSetting.vue +0 -209
- package/src/widgets/LinkSettingModal.vue +0 -173
- package/src/widgets/LogViewer.vue +0 -85
- package/src/widgets/MarginPaddingSetting.vue +0 -58
- package/src/widgets/MarginSetting.vue +0 -142
- package/src/widgets/MenuEditor.vue +0 -256
- package/src/widgets/MenuItem1Setting.vue +0 -78
- package/src/widgets/ModalSetting.vue +0 -94
- package/src/widgets/MultiValueSetting.vue +0 -121
- package/src/widgets/MultiValueSetting2.vue +0 -147
- package/src/widgets/OGSettingModal.vue +0 -103
- package/src/widgets/PaddingSetting.vue +0 -142
- package/src/widgets/ParagraphSetting.vue +0 -89
- package/src/widgets/PositionSetting.vue +0 -209
- package/src/widgets/PresetBar.vue +0 -990
- package/src/widgets/PresetBarPivot.vue +0 -198
- package/src/widgets/PresetBarPivotColumnEdit.vue +0 -197
- package/src/widgets/PresetSelector.vue +0 -685
- package/src/widgets/Review.vue +0 -131
- package/src/widgets/ReviewSetting.vue +0 -201
- package/src/widgets/SearchModalSetting.vue +0 -70
- package/src/widgets/Share.vue +0 -164
- package/src/widgets/ShareSetting.vue +0 -99
- package/src/widgets/SizingSetting.vue +0 -306
- package/src/widgets/SpacingSetting.vue +0 -77
- package/src/widgets/StyleSetting.vue +0 -543
- package/src/widgets/StyleSetting2.vue +0 -90
- package/src/widgets/SvgSetting.vue +0 -133
- package/src/widgets/TableSetting.vue +0 -172
- package/src/widgets/TestimonialSetting.vue +0 -161
- package/src/widgets/TextBlockSetting.vue +0 -81
- package/src/widgets/ThumbnailSetting.vue +0 -49
- package/src/widgets/TransitionSetting.vue +0 -64
- package/src/widgets/TypographySetting.vue +0 -334
- package/src/widgets/UserActionBuilder/UserActionCondition.vue +0 -99
- package/src/widgets/UserActionBuilder/UserActionConsole.vue +0 -97
- package/src/widgets/UserActionBuilder/UserActionItem.vue +0 -273
- package/src/widgets/UserActionBuilder/UserActionOutput.vue +0 -152
- package/src/widgets/UserActionBuilder/UserActionOutputDelay.vue +0 -27
- package/src/widgets/UserActionBuilder/UserActionOutputLog.vue +0 -28
- package/src/widgets/UserActionBuilder/UserActionOutputReply.vue +0 -112
- package/src/widgets/UserActionBuilder/UserActionProps.vue +0 -213
- package/src/widgets/UserActionBuilder.vue +0 -314
- package/src/widgets/WebComponentSelector.vue +0 -205
- package/src/widgets/WebDatasourceSelector.vue +0 -153
- package/src/widgets/WebLayoutSelector.vue +0 -147
- package/src/widgets/WebPageBuilder.vue +0 -2161
- package/src/widgets/WebPageBuilder2.vue +0 -1091
- package/src/widgets/WebPageBuilder3.vue +0 -411
- package/src/widgets/WebPageBuilder4/BackgroundColorSetting.vue +0 -54
- package/src/widgets/WebPageBuilder4/BackgroundPositionSetting.vue +0 -75
- package/src/widgets/WebPageBuilder4/BackgroundRepeatSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4/BackgroundSizeSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4/BlurSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4/BorderColorSetting.vue +0 -64
- package/src/widgets/WebPageBuilder4/BorderRadiusSetting.vue +0 -75
- package/src/widgets/WebPageBuilder4/BorderSizeSetting.vue +0 -69
- package/src/widgets/WebPageBuilder4/BorderStyleSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4/BoxShadowSetting.vue +0 -73
- package/src/widgets/WebPageBuilder4/ButtonSetting.vue +0 -65
- package/src/widgets/WebPageBuilder4/CarouselSetting.vue +0 -178
- package/src/widgets/WebPageBuilder4/DisplaySetting.vue +0 -76
- package/src/widgets/WebPageBuilder4/FlexAlignSetting.vue +0 -71
- package/src/widgets/WebPageBuilder4/FlexDirectionSetting.vue +0 -70
- package/src/widgets/WebPageBuilder4/FlexJustifySetting.vue +0 -74
- package/src/widgets/WebPageBuilder4/FlexPropertySetting.vue +0 -71
- package/src/widgets/WebPageBuilder4/FlexSetting.vue +0 -96
- package/src/widgets/WebPageBuilder4/FlexWrapSetting.vue +0 -69
- package/src/widgets/WebPageBuilder4/GapSetting.vue +0 -75
- package/src/widgets/WebPageBuilder4/GrayscaleSetting.vue +0 -68
- package/src/widgets/WebPageBuilder4/GridSetting.vue +0 -216
- package/src/widgets/WebPageBuilder4/HeightSetting.vue +0 -98
- package/src/widgets/WebPageBuilder4/ImageSetting.vue +0 -102
- package/src/widgets/WebPageBuilder4/MarginSetting.vue +0 -73
- package/src/widgets/WebPageBuilder4/MaxHeightSetting.vue +0 -82
- package/src/widgets/WebPageBuilder4/MaxWidthSetting.vue +0 -90
- package/src/widgets/WebPageBuilder4/MinHeightSetting.vue +0 -81
- package/src/widgets/WebPageBuilder4/MinWidthSetting.vue +0 -101
- package/src/widgets/WebPageBuilder4/MultiValueSetting.vue +0 -163
- package/src/widgets/WebPageBuilder4/OpacitySetting.vue +0 -77
- package/src/widgets/WebPageBuilder4/OverflowSetting.vue +0 -81
- package/src/widgets/WebPageBuilder4/PaddingSetting.vue +0 -57
- package/src/widgets/WebPageBuilder4/PositionSetting.vue +0 -191
- package/src/widgets/WebPageBuilder4/PropertySetting.vue +0 -176
- package/src/widgets/WebPageBuilder4/TextSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4/TreeView.vue +0 -46
- package/src/widgets/WebPageBuilder4/TreeViewItem.vue +0 -303
- package/src/widgets/WebPageBuilder4/WebPageComponentSelector.vue +0 -141
- package/src/widgets/WebPageBuilder4/WebPagePropertySelector.vue +0 -172
- package/src/widgets/WebPageBuilder4/WidthSetting.vue +0 -105
- package/src/widgets/WebPageBuilder4/ZIndexSetting.vue +0 -72
- package/src/widgets/WebPageBuilder4.vue +0 -798
- package/src/widgets/WebPagePreview.vue +0 -295
- package/src/widgets/WebPageSelector.vue +0 -173
- package/src/widgets/WebTemplateCreator.vue +0 -156
- package/src/widgets/YoutubeVideoSetting.vue +0 -68
- package/tailwind.config.js +0 -481
|
@@ -1,543 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div :class="$style.comp">
|
|
3
|
-
|
|
4
|
-
<div class="flex flex-col divide-y divide-border-50">
|
|
5
|
-
|
|
6
|
-
<div class="flex flex-col gap-4 p-6">
|
|
7
|
-
|
|
8
|
-
<strong @dblclick="log(item)">Style</strong>
|
|
9
|
-
|
|
10
|
-
<div>
|
|
11
|
-
<div class="flex flex-row">
|
|
12
|
-
<div class="flex-1">
|
|
13
|
-
<small class="text-text-400">Font Family</small>
|
|
14
|
-
</div>
|
|
15
|
-
<div class="flex flex-row gap-1 self-center">
|
|
16
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontFamily'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontFamily'] = 0">base</button>
|
|
17
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontFamily'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontFamily'] = 1">md</button>
|
|
18
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontFamily'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontFamily'] = 2">lg</button>
|
|
19
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontFamily'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontFamily'] = 3">xl</button>
|
|
20
|
-
</div>
|
|
21
|
-
</div>
|
|
22
|
-
<Dropdown v-model="media['*']['font-family'][selectorIndex('fontFamily')]" class="mt-1">
|
|
23
|
-
<option value="">Default</option>
|
|
24
|
-
<option v-for="opt in components.fontFamily"
|
|
25
|
-
:value="`${opt[1]}`">
|
|
26
|
-
{{ opt[0] }}
|
|
27
|
-
</option>
|
|
28
|
-
</Dropdown>
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
<div>
|
|
32
|
-
<div class="flex flex-row">
|
|
33
|
-
<div class="flex-1">
|
|
34
|
-
<small class="text-text-400">Font Size</small>
|
|
35
|
-
</div>
|
|
36
|
-
<div class="flex flex-row gap-1 self-center">
|
|
37
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontSize'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontSize'] = 0">base</button>
|
|
38
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontSize'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontSize'] = 1">md</button>
|
|
39
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontSize'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontSize'] = 2">lg</button>
|
|
40
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['fontSize'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['fontSize'] = 3">xl</button>
|
|
41
|
-
</div>
|
|
42
|
-
</div>
|
|
43
|
-
<Dropdown v-model="media['html, .html']['font-size'][selectorIndex('fontSize')]" class="mt-1">
|
|
44
|
-
<option value="">Default</option>
|
|
45
|
-
<option v-for="opt in components.fontSize"
|
|
46
|
-
:value="`${opt[1]}`">
|
|
47
|
-
{{ opt[0] }}
|
|
48
|
-
</option>
|
|
49
|
-
</Dropdown>
|
|
50
|
-
</div>
|
|
51
|
-
|
|
52
|
-
<div>
|
|
53
|
-
<div class="flex flex-row">
|
|
54
|
-
<div class="flex-1">
|
|
55
|
-
<small class="text-text-400">Primary Color</small>
|
|
56
|
-
</div>
|
|
57
|
-
<div class="flex flex-row gap-1 self-center">
|
|
58
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['primary'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['primary'] = 0">base</button>
|
|
59
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['primary'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['primary'] = 1">md</button>
|
|
60
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['primary'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['primary'] = 2">lg</button>
|
|
61
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['primary'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['primary'] = 3">xl</button>
|
|
62
|
-
</div>
|
|
63
|
-
</div>
|
|
64
|
-
<div class="grid grid-cols-8 gap-2 mt-2">
|
|
65
|
-
<div class="flex flex-col items-center gap-2">
|
|
66
|
-
<ColorPicker v-model="media['html, .html']['--primary-800'][selectorIndex('primary')]"
|
|
67
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
68
|
-
<small class="text-text-400 text-xs">+300</small>
|
|
69
|
-
</div>
|
|
70
|
-
|
|
71
|
-
<div class="flex flex-col items-center gap-2">
|
|
72
|
-
<ColorPicker v-model="media['html, .html']['--primary-700'][selectorIndex('primary')]"
|
|
73
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
74
|
-
<small class="text-text-400 text-xs">+200</small>
|
|
75
|
-
</div>
|
|
76
|
-
|
|
77
|
-
<div class="flex flex-col items-center gap-2">
|
|
78
|
-
<ColorPicker v-model="media['html, .html']['--primary-600'][selectorIndex('primary')]"
|
|
79
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
80
|
-
<small class="text-text-400 text-xs">+100</small>
|
|
81
|
-
</div>
|
|
82
|
-
|
|
83
|
-
<div class="flex flex-col items-center gap-2">
|
|
84
|
-
<ColorPicker v-model="media['html, .html']['--primary-500'][selectorIndex('primary')]"
|
|
85
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
86
|
-
<small class="text-text-400 text-xs">normal</small>
|
|
87
|
-
</div>
|
|
88
|
-
|
|
89
|
-
<div class="flex flex-col items-center gap-2">
|
|
90
|
-
<ColorPicker v-model="media['html, .html']['--primary-400'][selectorIndex('primary')]"
|
|
91
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
92
|
-
<small class="text-text-400 text-xs">-100</small>
|
|
93
|
-
</div>
|
|
94
|
-
|
|
95
|
-
<div class="flex flex-col items-center gap-2">
|
|
96
|
-
<ColorPicker v-model="media['html, .html']['--primary-300'][selectorIndex('primary')]"
|
|
97
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
98
|
-
<small class="text-text-400 text-xs">-200</small>
|
|
99
|
-
</div>
|
|
100
|
-
|
|
101
|
-
<div class="flex flex-col items-center gap-2">
|
|
102
|
-
<ColorPicker v-model="media['html, .html']['--primary-200'][selectorIndex('primary')]"
|
|
103
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
104
|
-
<small class="text-text-400 text-xs">-300</small>
|
|
105
|
-
</div>
|
|
106
|
-
|
|
107
|
-
<div class="flex flex-col items-center gap-2">
|
|
108
|
-
<ColorPicker v-model="media['html, .html']['--primary-100'][selectorIndex('primary')]"
|
|
109
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
110
|
-
<small class="text-text-400 text-xs">-400</small>
|
|
111
|
-
</div>
|
|
112
|
-
</div>
|
|
113
|
-
</div>
|
|
114
|
-
|
|
115
|
-
<div>
|
|
116
|
-
<div class="flex flex-row">
|
|
117
|
-
<div class="flex-1">
|
|
118
|
-
<small class="text-text-400">Secondary Color</small>
|
|
119
|
-
</div>
|
|
120
|
-
<div class="flex flex-row gap-1 self-center">
|
|
121
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['secondary'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['secondary'] = 0">base</button>
|
|
122
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['secondary'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['secondary'] = 1">md</button>
|
|
123
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['secondary'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['secondary'] = 2">lg</button>
|
|
124
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['secondary'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['secondary'] = 3">xl</button>
|
|
125
|
-
</div>
|
|
126
|
-
</div>
|
|
127
|
-
<div class="grid grid-cols-8 gap-2 mt-2">
|
|
128
|
-
<div class="flex flex-col items-center gap-2">
|
|
129
|
-
<ColorPicker v-model="media['html, .html']['--secondary-800'][selectorIndex('secondary')]"
|
|
130
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
131
|
-
<small class="text-text-400 text-xs">800</small>
|
|
132
|
-
</div>
|
|
133
|
-
|
|
134
|
-
<div class="flex flex-col items-center gap-2">
|
|
135
|
-
<ColorPicker v-model="media['html, .html']['--secondary-700'][selectorIndex('secondary')]"
|
|
136
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
137
|
-
<small class="text-text-400 text-xs">700</small>
|
|
138
|
-
</div>
|
|
139
|
-
|
|
140
|
-
<div class="flex flex-col items-center gap-2">
|
|
141
|
-
<ColorPicker v-model="media['html, .html']['--secondary-600'][selectorIndex('secondary')]"
|
|
142
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
143
|
-
<small class="text-text-400 text-xs">600</small>
|
|
144
|
-
</div>
|
|
145
|
-
|
|
146
|
-
<div class="flex flex-col items-center gap-2">
|
|
147
|
-
<ColorPicker v-model="media['html, .html']['--secondary-500'][selectorIndex('secondary')]"
|
|
148
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
149
|
-
<small class="text-text-400 text-xs">500</small>
|
|
150
|
-
</div>
|
|
151
|
-
|
|
152
|
-
<div class="flex flex-col items-center gap-2">
|
|
153
|
-
<ColorPicker v-model="media['html, .html']['--secondary-400'][selectorIndex('secondary')]"
|
|
154
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
155
|
-
<small class="text-text-400 text-xs">400</small>
|
|
156
|
-
</div>
|
|
157
|
-
|
|
158
|
-
<div class="flex flex-col items-center gap-2">
|
|
159
|
-
<ColorPicker v-model="media['html, .html']['--secondary-300'][selectorIndex('secondary')]"
|
|
160
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
161
|
-
<small class="text-text-400 text-xs">300</small>
|
|
162
|
-
</div>
|
|
163
|
-
|
|
164
|
-
<div class="flex flex-col items-center gap-2">
|
|
165
|
-
<ColorPicker v-model="media['html, .html']['--secondary-200'][selectorIndex('secondary')]"
|
|
166
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
167
|
-
<small class="text-text-400 text-xs">200</small>
|
|
168
|
-
</div>
|
|
169
|
-
|
|
170
|
-
<div class="flex flex-col items-center gap-2">
|
|
171
|
-
<ColorPicker v-model="media['html, .html']['--secondary-100'][selectorIndex('secondary')]"
|
|
172
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
173
|
-
<small class="text-text-400 text-xs">100</small>
|
|
174
|
-
</div>
|
|
175
|
-
</div>
|
|
176
|
-
</div>
|
|
177
|
-
|
|
178
|
-
<div>
|
|
179
|
-
<div class="flex flex-row">
|
|
180
|
-
<div class="flex-1">
|
|
181
|
-
<small class="text-text-400">Text Color</small>
|
|
182
|
-
</div>
|
|
183
|
-
<div class="flex flex-row gap-1 self-center">
|
|
184
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['text'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['text'] = 0">base</button>
|
|
185
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['text'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['text'] = 1">md</button>
|
|
186
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['text'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['text'] = 2">lg</button>
|
|
187
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['text'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['text'] = 3">xl</button>
|
|
188
|
-
</div>
|
|
189
|
-
</div>
|
|
190
|
-
<div class="grid grid-cols-8 gap-2 mt-2">
|
|
191
|
-
<div class="flex flex-col items-center gap-2">
|
|
192
|
-
<ColorPicker v-model="media['html, .html']['--text-800'][selectorIndex('text')]"
|
|
193
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
194
|
-
<small class="text-text-400 text-xs">800</small>
|
|
195
|
-
</div>
|
|
196
|
-
|
|
197
|
-
<div class="flex flex-col items-center gap-2">
|
|
198
|
-
<ColorPicker v-model="media['html, .html']['--text-700'][selectorIndex('text')]"
|
|
199
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
200
|
-
<small class="text-text-400 text-xs">700</small>
|
|
201
|
-
</div>
|
|
202
|
-
|
|
203
|
-
<div class="flex flex-col items-center gap-2">
|
|
204
|
-
<ColorPicker v-model="media['html, .html']['--text-600'][selectorIndex('text')]"
|
|
205
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
206
|
-
<small class="text-text-400 text-xs">600</small>
|
|
207
|
-
</div>
|
|
208
|
-
|
|
209
|
-
<div class="flex flex-col items-center gap-2">
|
|
210
|
-
<ColorPicker v-model="media['html, .html']['--text-500'][selectorIndex('text')]"
|
|
211
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
212
|
-
<small class="text-text-400 text-xs">500</small>
|
|
213
|
-
</div>
|
|
214
|
-
|
|
215
|
-
<div class="flex flex-col items-center gap-2">
|
|
216
|
-
<ColorPicker v-model="media['html, .html']['--text-400'][selectorIndex('text')]"
|
|
217
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
218
|
-
<small class="text-text-400 text-xs">400</small>
|
|
219
|
-
</div>
|
|
220
|
-
|
|
221
|
-
<div class="flex flex-col items-center gap-2">
|
|
222
|
-
<ColorPicker v-model="media['html, .html']['--text-300'][selectorIndex('text')]"
|
|
223
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
224
|
-
<small class="text-text-400 text-xs">300</small>
|
|
225
|
-
</div>
|
|
226
|
-
|
|
227
|
-
<div class="flex flex-col items-center gap-2">
|
|
228
|
-
<ColorPicker v-model="media['html, .html']['--text-200'][selectorIndex('text')]"
|
|
229
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
230
|
-
<small class="text-text-400 text-xs">200</small>
|
|
231
|
-
</div>
|
|
232
|
-
|
|
233
|
-
<div class="flex flex-col items-center gap-2">
|
|
234
|
-
<ColorPicker v-model="media['html, .html']['--text-100'][selectorIndex('text')]"
|
|
235
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
236
|
-
<small class="text-text-400 text-xs">100</small>
|
|
237
|
-
</div>
|
|
238
|
-
</div>
|
|
239
|
-
</div>
|
|
240
|
-
|
|
241
|
-
<div>
|
|
242
|
-
<div class="flex flex-row">
|
|
243
|
-
<div class="flex-1">
|
|
244
|
-
<small class="text-text-400">Background Color</small>
|
|
245
|
-
</div>
|
|
246
|
-
<div class="flex flex-row gap-1 self-center">
|
|
247
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['base'] === 0 ? 'bg-primary text-white': ''" @click="selectorIndexes['base'] = 0">base</button>
|
|
248
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['base'] === 1 ? 'bg-primary text-white': ''" @click="selectorIndexes['base'] = 1">md</button>
|
|
249
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['base'] === 2 ? 'bg-primary text-white': ''" @click="selectorIndexes['base'] = 2">lg</button>
|
|
250
|
-
<button type="button" class="text-xs px-1" :class="selectorIndexes['base'] === 3 ? 'bg-primary text-white': ''" @click="selectorIndexes['base'] = 3">xl</button>
|
|
251
|
-
</div>
|
|
252
|
-
</div>
|
|
253
|
-
<div class="grid grid-cols-8 gap-2 mt-2">
|
|
254
|
-
<div class="flex flex-col items-center gap-2">
|
|
255
|
-
<ColorPicker v-model="media['html, .html']['--base-300'][selectorIndex('base')]"
|
|
256
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
257
|
-
<small class="text-text-400 text-xs">300</small>
|
|
258
|
-
</div>
|
|
259
|
-
|
|
260
|
-
<div class="flex flex-col items-center gap-2">
|
|
261
|
-
<ColorPicker v-model="media['html, .html']['--base-400'][selectorIndex('base')]"
|
|
262
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
263
|
-
<small class="text-text-400 text-xs">400</small>
|
|
264
|
-
</div>
|
|
265
|
-
|
|
266
|
-
<div class="flex flex-col items-center gap-2">
|
|
267
|
-
<ColorPicker v-model="media['html, .html']['--base-500'][selectorIndex('base')]"
|
|
268
|
-
mode="hex" :custom-color="true" value-type="rgb" />
|
|
269
|
-
<small class="text-text-400 text-xs">500</small>
|
|
270
|
-
</div>
|
|
271
|
-
</div>
|
|
272
|
-
</div>
|
|
273
|
-
|
|
274
|
-
</div>
|
|
275
|
-
|
|
276
|
-
<div class="p-6">
|
|
277
|
-
|
|
278
|
-
<small class="text-text-400">Splash</small>
|
|
279
|
-
|
|
280
|
-
<div class="mt-1 flex flex-col items-center gap-2">
|
|
281
|
-
<Image ref="splashImg"
|
|
282
|
-
:src="item.props.splash"
|
|
283
|
-
:editable="true"
|
|
284
|
-
@change="setSplash"
|
|
285
|
-
class="aspect-square bg-text-50 rounded-lg w-[100px]" />
|
|
286
|
-
|
|
287
|
-
<div class="flex flex-row gap-8">
|
|
288
|
-
<button type="button" class="text-primary"
|
|
289
|
-
@click="$refs.splashImg.edit()">
|
|
290
|
-
Upload
|
|
291
|
-
</button>
|
|
292
|
-
<button type="button" class="text-primary"
|
|
293
|
-
@click="removeSplash">
|
|
294
|
-
Remove
|
|
295
|
-
</button>
|
|
296
|
-
</div>
|
|
297
|
-
</div>
|
|
298
|
-
|
|
299
|
-
</div>
|
|
300
|
-
|
|
301
|
-
<div class="p-6 text-center">
|
|
302
|
-
<br />
|
|
303
|
-
<button type="button" class="text-text-300 hover:text-primary" @click="resetMedia">Reset</button>
|
|
304
|
-
</div>
|
|
305
|
-
|
|
306
|
-
</div>
|
|
307
|
-
|
|
308
|
-
</div>
|
|
309
|
-
</template>
|
|
310
|
-
|
|
311
|
-
<script>
|
|
312
|
-
|
|
313
|
-
import ColorPicker from "../components/ColorPicker.vue";
|
|
314
|
-
import tinycolor from "tinycolor2";
|
|
315
|
-
|
|
316
|
-
const defaultMedia = {
|
|
317
|
-
":root": {
|
|
318
|
-
"--spacing-1": [],
|
|
319
|
-
"--spacing-2": [],
|
|
320
|
-
"--spacing-3": [],
|
|
321
|
-
"--spacing-4": [],
|
|
322
|
-
"--spacing-5": [],
|
|
323
|
-
"--spacing-6": [],
|
|
324
|
-
"--spacing-7": [],
|
|
325
|
-
"--spacing-8": [],
|
|
326
|
-
"--spacing-9": [],
|
|
327
|
-
"--spacing-10": [],
|
|
328
|
-
"--spacing-11": [],
|
|
329
|
-
"--spacing-12": []
|
|
330
|
-
},
|
|
331
|
-
"*": {
|
|
332
|
-
"font-family": [ "Poppins, sans-serif" ]
|
|
333
|
-
},
|
|
334
|
-
"html, .html": {
|
|
335
|
-
"font-size": [ '16px', '15px' ],
|
|
336
|
-
"--base-300": [ "rgb(235, 235, 235)" ],
|
|
337
|
-
"--base-400": [ "rgb(245, 245, 245)" ],
|
|
338
|
-
"--base-500": [ "rgb(255, 255, 255)" ],
|
|
339
|
-
"--primary-100": [],
|
|
340
|
-
"--primary-200": [],
|
|
341
|
-
"--primary-300": [],
|
|
342
|
-
"--primary-400": [],
|
|
343
|
-
"--primary-500": [ "rgb(0, 0, 0)" ],
|
|
344
|
-
"--primary-600": [ "rgb(15, 15, 15)" ],
|
|
345
|
-
"--primary-700": [],
|
|
346
|
-
"--primary-800": [],
|
|
347
|
-
"--primary-900": [],
|
|
348
|
-
"--secondary-100": [],
|
|
349
|
-
"--secondary-200": [],
|
|
350
|
-
"--secondary-300": [],
|
|
351
|
-
"--secondary-400": [],
|
|
352
|
-
"--secondary-500": [],
|
|
353
|
-
"--secondary-600": [],
|
|
354
|
-
"--secondary-700": [],
|
|
355
|
-
"--secondary-800": [],
|
|
356
|
-
"--secondary-900": [],
|
|
357
|
-
"--text-100": [],
|
|
358
|
-
"--text-200": [],
|
|
359
|
-
"--text-300": [],
|
|
360
|
-
"--text-400": [],
|
|
361
|
-
"--text-500": [ "rgb(33, 33, 33)" ],
|
|
362
|
-
"--text-600": [],
|
|
363
|
-
"--text-700": [],
|
|
364
|
-
"--text-800": [],
|
|
365
|
-
"--text-900": []
|
|
366
|
-
},
|
|
367
|
-
}
|
|
368
|
-
|
|
369
|
-
export default{
|
|
370
|
-
components: {ColorPicker},
|
|
371
|
-
|
|
372
|
-
emits: [ 'change' ],
|
|
373
|
-
|
|
374
|
-
inject: [ 'confirm' ],
|
|
375
|
-
|
|
376
|
-
props: {
|
|
377
|
-
|
|
378
|
-
item: {
|
|
379
|
-
type: Object,
|
|
380
|
-
required: true
|
|
381
|
-
},
|
|
382
|
-
|
|
383
|
-
viewType: String,
|
|
384
|
-
|
|
385
|
-
viewIndex: Number,
|
|
386
|
-
|
|
387
|
-
viewTypes: Array,
|
|
388
|
-
|
|
389
|
-
},
|
|
390
|
-
|
|
391
|
-
methods: {
|
|
392
|
-
|
|
393
|
-
emptyComponentText(key, index){
|
|
394
|
-
if(index > 0){
|
|
395
|
-
let text = '-'
|
|
396
|
-
for(let i = index - 1 ; i >= 0 ; i--){
|
|
397
|
-
let prevValue = this[key][i]
|
|
398
|
-
if(prevValue && typeof prevValue === 'string'){
|
|
399
|
-
prevValue = prevValue.substring(prevValue.indexOf(':') + 1)
|
|
400
|
-
const prevOpt = this.components[key].filter(_ => _[1] === prevValue).pop()
|
|
401
|
-
if(prevOpt){
|
|
402
|
-
text = prevOpt[0]
|
|
403
|
-
break
|
|
404
|
-
}
|
|
405
|
-
}
|
|
406
|
-
}
|
|
407
|
-
return text
|
|
408
|
-
}
|
|
409
|
-
return '-'
|
|
410
|
-
},
|
|
411
|
-
|
|
412
|
-
mediaOf(key, propertyKey){
|
|
413
|
-
if(!this.media[key]){
|
|
414
|
-
this.media[key] = {}
|
|
415
|
-
}
|
|
416
|
-
|
|
417
|
-
if(!this.media[key][propertyKey]){
|
|
418
|
-
this.media[key][propertyKey] = {}
|
|
419
|
-
}
|
|
420
|
-
|
|
421
|
-
return this.media[key][propertyKey]
|
|
422
|
-
},
|
|
423
|
-
|
|
424
|
-
generateShade(key, value){
|
|
425
|
-
this.mediaOf('', 'html, .html')[`${key}`] = value
|
|
426
|
-
this.mediaOf('', 'html, .html')[`${key}-500`] = value
|
|
427
|
-
|
|
428
|
-
const lightenLevels = [[50, 52], [100, 37], [200, 26], [300, 12], [400, 6]];
|
|
429
|
-
const darkenLevels = [[600, 6], [700, 12], [800, 18], [900, 24]];
|
|
430
|
-
|
|
431
|
-
for(let [ idx, lvl ] of lightenLevels){
|
|
432
|
-
this.mediaOf(this.viewType, 'html, .html')[`${key}-${idx}`] =
|
|
433
|
-
tinycolor(`rgb(${value})`).lighten(lvl).toRgbString().substring(4).slice(0, -1)
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
for(let [ idx, lvl ] of darkenLevels){
|
|
437
|
-
this.mediaOf(this.viewType, 'html, .html')[`${key}-${idx}`] =
|
|
438
|
-
tinycolor(`rgb(${value})`).darken(lvl).toRgbString().substring(4).slice(0, -1)
|
|
439
|
-
}
|
|
440
|
-
},
|
|
441
|
-
|
|
442
|
-
resetMedia(){
|
|
443
|
-
this.confirm('Reset styles?', () => {
|
|
444
|
-
this.media = defaultMedia
|
|
445
|
-
})
|
|
446
|
-
},
|
|
447
|
-
|
|
448
|
-
setSplash(base64, file){
|
|
449
|
-
|
|
450
|
-
if(file.type.indexOf('image/svg') >= 0){
|
|
451
|
-
const reader = new FileReader();
|
|
452
|
-
|
|
453
|
-
reader.onload = (e) => {
|
|
454
|
-
this.item.props.splash = e.target.result
|
|
455
|
-
};
|
|
456
|
-
|
|
457
|
-
reader.readAsText(file);
|
|
458
|
-
}
|
|
459
|
-
else{
|
|
460
|
-
this.item.props.splash = base64
|
|
461
|
-
}
|
|
462
|
-
},
|
|
463
|
-
|
|
464
|
-
removeSplash(){
|
|
465
|
-
this.item.props.splash = null
|
|
466
|
-
},
|
|
467
|
-
|
|
468
|
-
selectorIndex(selector){
|
|
469
|
-
if(!this.selectorIndexes[selector])
|
|
470
|
-
this.selectorIndexes[selector] = 0
|
|
471
|
-
return this.selectorIndexes[selector]
|
|
472
|
-
}
|
|
473
|
-
|
|
474
|
-
},
|
|
475
|
-
|
|
476
|
-
mounted() {
|
|
477
|
-
},
|
|
478
|
-
|
|
479
|
-
computed: {
|
|
480
|
-
|
|
481
|
-
media(){
|
|
482
|
-
if(!this.item.props.media)
|
|
483
|
-
this.item.props.media = JSON.parse(JSON.stringify(defaultMedia))
|
|
484
|
-
return this.item.props.media
|
|
485
|
-
}
|
|
486
|
-
|
|
487
|
-
},
|
|
488
|
-
|
|
489
|
-
data(){
|
|
490
|
-
return {
|
|
491
|
-
|
|
492
|
-
components: {
|
|
493
|
-
fontFamily: [
|
|
494
|
-
['Anton', '"Anton", sans-serif'],
|
|
495
|
-
['Arial', '"Arial", sans-serif'],
|
|
496
|
-
['Dosis', 'Dosis, sans-serif'],
|
|
497
|
-
['Lato', 'Lato, sans-serif'],
|
|
498
|
-
['Merriweather', 'Merriweather, sans-serif'],
|
|
499
|
-
['Montserrat', 'Montserrat, sans-serif'],
|
|
500
|
-
['Noto Sans', '"Noto Sans", sans-serif'],
|
|
501
|
-
['Oswald', 'Oswald, sans-serif'],
|
|
502
|
-
['Oxygen', 'Oxygen, sans-serif'],
|
|
503
|
-
['Poppins', 'Poppins, sans-serif'],
|
|
504
|
-
['Quantico', 'Quantico, sans-serif'],
|
|
505
|
-
['Raleway', 'Raleway, sans-serif'],
|
|
506
|
-
['Reddit Sans', '"Reddit Sans", sans-serif'],
|
|
507
|
-
['Roboto', '"Roboto", sans-serif'],
|
|
508
|
-
['Roboto Slab', '"Roboto Slab", serif'],
|
|
509
|
-
['Volkhov', 'Volkhov, serif'],
|
|
510
|
-
['Work Sans', '"Work Sans", serif'],
|
|
511
|
-
],
|
|
512
|
-
|
|
513
|
-
fontSize: [
|
|
514
|
-
[ '11px', '11px' ],
|
|
515
|
-
[ '12px', '12px' ],
|
|
516
|
-
[ '13px', '13px' ],
|
|
517
|
-
[ '14px', '14px' ],
|
|
518
|
-
[ '15px', '15px' ],
|
|
519
|
-
[ '16px', '16px' ],
|
|
520
|
-
[ '17px', '17px' ],
|
|
521
|
-
[ '18px', '18px' ],
|
|
522
|
-
[ '19px', '19px' ],
|
|
523
|
-
[ '20px', '20px' ],
|
|
524
|
-
[ '21px', '21px' ],
|
|
525
|
-
]
|
|
526
|
-
},
|
|
527
|
-
|
|
528
|
-
selectorIndexes: {}
|
|
529
|
-
|
|
530
|
-
}
|
|
531
|
-
},
|
|
532
|
-
|
|
533
|
-
}
|
|
534
|
-
|
|
535
|
-
</script>
|
|
536
|
-
|
|
537
|
-
<style module>
|
|
538
|
-
|
|
539
|
-
.comp{
|
|
540
|
-
@apply flex flex-col gap-8;
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
</style>
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="flex flex-col gap-5 p-5">
|
|
3
|
-
|
|
4
|
-
<div>
|
|
5
|
-
<label class="text-text-400">Font Family</label>
|
|
6
|
-
<Dropdown v-for="(_, idx) in viewTypes"
|
|
7
|
-
v-show="viewType === _.value"
|
|
8
|
-
v-model="fontFamily[idx]"
|
|
9
|
-
@change="$emit('change')">
|
|
10
|
-
<option value="">Default</option>
|
|
11
|
-
<option value="Arial, sans-serif">Arial</option>
|
|
12
|
-
<option value="Impact, sans-serif">Impact</option>
|
|
13
|
-
</Dropdown>
|
|
14
|
-
</div>
|
|
15
|
-
|
|
16
|
-
<div>
|
|
17
|
-
<label class="text-text-400">Font Weight</label>
|
|
18
|
-
<Dropdown v-for="(_, idx) in viewTypes"
|
|
19
|
-
v-show="viewType === _.value"
|
|
20
|
-
v-model="fontWeight[idx]"
|
|
21
|
-
@change="$emit('change')">
|
|
22
|
-
<option value="">Default</option>
|
|
23
|
-
<option value="light">Light</option>
|
|
24
|
-
<option value="bold">Bold</option>
|
|
25
|
-
</Dropdown>
|
|
26
|
-
</div>
|
|
27
|
-
|
|
28
|
-
<pre>{{ item }}</pre>
|
|
29
|
-
<pre>{{ viewType }}</pre>
|
|
30
|
-
</div>
|
|
31
|
-
</template>
|
|
32
|
-
|
|
33
|
-
<script>
|
|
34
|
-
|
|
35
|
-
export default{
|
|
36
|
-
|
|
37
|
-
emits: [ 'change' ],
|
|
38
|
-
|
|
39
|
-
inject: [ 'alert', 'viewTypes', 'postIframe', 'onPostMessageToIframe' ],
|
|
40
|
-
|
|
41
|
-
props: {
|
|
42
|
-
|
|
43
|
-
item: {
|
|
44
|
-
type: Object,
|
|
45
|
-
required: true
|
|
46
|
-
},
|
|
47
|
-
|
|
48
|
-
config: Object,
|
|
49
|
-
|
|
50
|
-
},
|
|
51
|
-
|
|
52
|
-
computed: {
|
|
53
|
-
|
|
54
|
-
viewType(){
|
|
55
|
-
return this.config.viewType
|
|
56
|
-
},
|
|
57
|
-
|
|
58
|
-
props(){
|
|
59
|
-
if(!this.item.props)
|
|
60
|
-
this.item.props = {}
|
|
61
|
-
return this.item.props
|
|
62
|
-
},
|
|
63
|
-
|
|
64
|
-
fontFamily(){
|
|
65
|
-
if(!Array.isArray(this.props.fontFamily)){
|
|
66
|
-
this.props.fontFamily = [ '', '', '', '' ]
|
|
67
|
-
}
|
|
68
|
-
return this.item.props.fontFamily
|
|
69
|
-
},
|
|
70
|
-
|
|
71
|
-
fontWeight(){
|
|
72
|
-
if(!Array.isArray(this.props.fontWeight)){
|
|
73
|
-
this.props.fontWeight = [ '', '', '', '' ]
|
|
74
|
-
}
|
|
75
|
-
return this.item.props.fontWeight
|
|
76
|
-
},
|
|
77
|
-
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
</script>
|
|
83
|
-
|
|
84
|
-
<style module>
|
|
85
|
-
|
|
86
|
-
.comp{
|
|
87
|
-
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
</style>
|