@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,273 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div v-if="item"
|
|
3
|
-
class="flex flex-row items-start relative">
|
|
4
|
-
|
|
5
|
-
<div ref="outer" class="flex-1 flex flex-row items-start">
|
|
6
|
-
<div class="flex flex-col self-stretch" :class="debug ? '' : ''">
|
|
7
|
-
|
|
8
|
-
<div class="flex flex-row items-center">
|
|
9
|
-
<div class="h-[1px]" :class="item.parentId > 0 ? 'bg-primary-300' : ''" :style="{ width:`${size[2]}px` }"></div>
|
|
10
|
-
|
|
11
|
-
<div :style="{ width:`${size[0]}px` }"
|
|
12
|
-
ref="item"
|
|
13
|
-
@mousedown="mouseDown"
|
|
14
|
-
@mouseover="hoverMouseOver">
|
|
15
|
-
<div class="rounded-xl p-3 border-[1px] flex relative overflow-hidden"
|
|
16
|
-
:class="isSelected ? 'border-primary bg-base-500' : 'border-primary-300 bg-base-400'"
|
|
17
|
-
@click="$emit('select', item)">
|
|
18
|
-
<div class="flex-1 flex flex-row">
|
|
19
|
-
<div class="flex-1 cursor-default whitespace-nowrap overflow-hidden text-ellipsis">
|
|
20
|
-
{{ item.name }}
|
|
21
|
-
</div>
|
|
22
|
-
<button v-if="isSelected && removable" class="text-primary" type="button" @click="$emit('remove')">
|
|
23
|
-
<svg width="16" height="16" class="fill-text-200 hover:fill-red-600" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Pro 6.0.0-alpha3 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) --><path d="M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256C397.4 512 512 397.4 512 256S397.4 0 256 0zM336.1 303c9.375 9.375 9.375 24.56 0 33.94c-9.381 9.381-24.56 9.373-33.94 0L256 289.9l-47.03 47.03c-9.381 9.381-24.56 9.373-33.94 0c-9.375-9.375-9.375-24.56 0-33.94l47.03-47.03L175 208.1c-9.375-9.375-9.375-24.56 0-33.94s24.56-9.375 33.94 0L256 222.1l47.03-47.03c9.375-9.375 24.56-9.375 33.94 0s9.375 24.56 0 33.94l-47.03 47.03L336.1 303z"/></svg>
|
|
24
|
-
</button>
|
|
25
|
-
</div>
|
|
26
|
-
|
|
27
|
-
<div v-if="item.isFallback" :class="$style.isFallback"></div>
|
|
28
|
-
</div>
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
<div v-if="hasChildren && (item.items ?? []).length < 1 && !item.isFallback"
|
|
32
|
-
class="flex flex-row items-center"
|
|
33
|
-
:style="{ width:`${size[2] * 1.2}px` }">
|
|
34
|
-
<div class="flex-1 bg-primary-300 h-[1px]"></div>
|
|
35
|
-
<button type="button"
|
|
36
|
-
@click="addItem(item)">
|
|
37
|
-
<svg width="16" height="16" class="fill-primary-600" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Pro 6.0.0-alpha3 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) --><path d="M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256C397.4 512 512 397.4 512 256S397.4 0 256 0zM352 280H280V352c0 13.2-10.8 24-23.1 24C242.8 376 232 365.2 232 352V280H160C146.8 280 136 269.2 136 256c0-13.2 10.8-24 24-24H232V160c0-13.2 10.8-24 24-24C269.2 136 280 146.8 280 160v72h72C365.2 232 376 242.8 376 256C376 269.2 365.2 280 352 280z"/></svg>
|
|
38
|
-
</button>
|
|
39
|
-
</div>
|
|
40
|
-
<div v-else-if="hasChildren && !item.isFallback" class="flex flex-row items-center" :style="{ width:`${size[2]}px` }">
|
|
41
|
-
<div class="flex-1 bg-primary-300 h-[1px]"></div>
|
|
42
|
-
</div>
|
|
43
|
-
</div>
|
|
44
|
-
|
|
45
|
-
<div class="flex-1 flex flex-row items-start">
|
|
46
|
-
<div :style="{ width:`${size[2]}px` }"></div>
|
|
47
|
-
|
|
48
|
-
<div v-if="useAdd" class="self-stretch flex flex-col items-center" :style="{ width:`${size[0]}px`, height:`${size[2] * 1.2}px` }">
|
|
49
|
-
<div class="flex-1 w-[1px] bg-primary-300"></div>
|
|
50
|
-
<button type="button" v-if="useAdd" @click="$emit('add')">
|
|
51
|
-
<svg width="16" height="16" class="fill-primary-600" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--! Font Awesome Pro 6.0.0-alpha3 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) --><path d="M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256C397.4 512 512 397.4 512 256S397.4 0 256 0zM352 280H280V352c0 13.2-10.8 24-23.1 24C242.8 376 232 365.2 232 352V280H160C146.8 280 136 269.2 136 256c0-13.2 10.8-24 24-24H232V160c0-13.2 10.8-24 24-24C269.2 136 280 146.8 280 160v72h72C365.2 232 376 242.8 376 256C376 269.2 365.2 280 352 280z"/></svg>
|
|
52
|
-
</button>
|
|
53
|
-
<div class="flex-1"></div>
|
|
54
|
-
</div>
|
|
55
|
-
<div v-else class="flex flex-col items-center" :style="{ width:`${size[0]}px`, height:`${size[2]}px` }">
|
|
56
|
-
|
|
57
|
-
</div>
|
|
58
|
-
|
|
59
|
-
<div :style="{ width:`${size[2]}px` }"></div>
|
|
60
|
-
</div>
|
|
61
|
-
|
|
62
|
-
</div>
|
|
63
|
-
|
|
64
|
-
<div v-if="hasChildren" class="flex flex-col relative" :class="debug ? '' : ''">
|
|
65
|
-
|
|
66
|
-
<UserActionItem v-for="(subItem, idx) in item.items"
|
|
67
|
-
:config="config"
|
|
68
|
-
:item="subItem"
|
|
69
|
-
:level="level + 1"
|
|
70
|
-
:index="idx"
|
|
71
|
-
:parent="item.items"
|
|
72
|
-
:isLast="idx === item.items.length - 1"
|
|
73
|
-
@select="(item0) => $emit('select', item0)"
|
|
74
|
-
@remove="item.items.splice(idx, 1)"
|
|
75
|
-
:useAdd="idx === (item.items ?? []).length - 1"
|
|
76
|
-
@add="addItem(item)" />
|
|
77
|
-
</div>
|
|
78
|
-
</div>
|
|
79
|
-
|
|
80
|
-
<div v-if="level > 0 && index > 0" class="absolute w-[1px] bg-primary-300" :style="vBorder0"></div>
|
|
81
|
-
<div v-if="level > 0 && !isLast" class="absolute w-[1px] bg-primary-300" :style="vBorder"></div>
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
</div>
|
|
85
|
-
</template>
|
|
86
|
-
|
|
87
|
-
<script>
|
|
88
|
-
|
|
89
|
-
import md5 from "md5";
|
|
90
|
-
|
|
91
|
-
let dragged = null
|
|
92
|
-
let guide1 = null
|
|
93
|
-
|
|
94
|
-
export default{
|
|
95
|
-
|
|
96
|
-
computed: {
|
|
97
|
-
|
|
98
|
-
debug(){
|
|
99
|
-
return this.item.name === 'Tea'
|
|
100
|
-
},
|
|
101
|
-
|
|
102
|
-
isSelected(){
|
|
103
|
-
return this.config.selectedUid === this.item.uid
|
|
104
|
-
},
|
|
105
|
-
|
|
106
|
-
vBorder(){
|
|
107
|
-
let bottom = `${(this.size[2] * 1.2) + (this.size[1] * .5)}px`
|
|
108
|
-
|
|
109
|
-
return {
|
|
110
|
-
top:'20px',
|
|
111
|
-
bottom: 0
|
|
112
|
-
}
|
|
113
|
-
},
|
|
114
|
-
|
|
115
|
-
vBorder0(){
|
|
116
|
-
return {
|
|
117
|
-
top: 0,
|
|
118
|
-
height: '20px'
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
},
|
|
123
|
-
|
|
124
|
-
emits: [ 'add', 'remove', 'select' ],
|
|
125
|
-
|
|
126
|
-
methods: {
|
|
127
|
-
|
|
128
|
-
addItem(item){
|
|
129
|
-
if(!Array.isArray(item.items))
|
|
130
|
-
item.items = []
|
|
131
|
-
|
|
132
|
-
const uid = md5(Date.now())
|
|
133
|
-
|
|
134
|
-
item.items.push({
|
|
135
|
-
name: 'Untitled',
|
|
136
|
-
parentId: item.id,
|
|
137
|
-
uid,
|
|
138
|
-
enabled: true
|
|
139
|
-
})
|
|
140
|
-
|
|
141
|
-
this.config.selectedUid = uid
|
|
142
|
-
},
|
|
143
|
-
|
|
144
|
-
hoverMouseOver(e){
|
|
145
|
-
if(!dragged) return
|
|
146
|
-
|
|
147
|
-
const from = this.parent.indexOf(dragged.item)
|
|
148
|
-
const to = this.parent.indexOf(this.item)
|
|
149
|
-
this.parent.splice(to, 0, this.parent.splice(from, 1)[0]);
|
|
150
|
-
},
|
|
151
|
-
|
|
152
|
-
mouseDown(e){
|
|
153
|
-
if(!this.$el || this.$el.nodeType !== 1) return
|
|
154
|
-
|
|
155
|
-
e.preventDefault()
|
|
156
|
-
|
|
157
|
-
const startY = e.clientY
|
|
158
|
-
|
|
159
|
-
dragged = {
|
|
160
|
-
item: this.item,
|
|
161
|
-
parent: this.parent,
|
|
162
|
-
startY: e.clientY,
|
|
163
|
-
index: this.parent?.indexOf(this.item)
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
const mouseMove = (e) => {
|
|
167
|
-
const distanceY = e.clientY - startY
|
|
168
|
-
|
|
169
|
-
if(!dragged.cloned && Math.abs(distanceY) > 10){
|
|
170
|
-
const cloned = this.$refs.outer.cloneNode(true)
|
|
171
|
-
cloned.style.position = 'fixed'
|
|
172
|
-
cloned.style.width = this.$refs.item.clientWidth + "px"
|
|
173
|
-
cloned.style.pointerEvents = 'none'
|
|
174
|
-
cloned.style.opacity = '0.5'
|
|
175
|
-
document.body.appendChild(cloned)
|
|
176
|
-
|
|
177
|
-
dragged.cloned = cloned
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
if(dragged.cloned){
|
|
181
|
-
dragged.cloned.style.left = (e.clientX + 3) + "px"
|
|
182
|
-
dragged.cloned.style.top = (e.clientY + 3) + "px"
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
dragged.clientY = e.clientY
|
|
186
|
-
}
|
|
187
|
-
|
|
188
|
-
const mouseUp = (e) => {
|
|
189
|
-
if(dragged?.cloned){
|
|
190
|
-
document.body.removeChild(dragged.cloned)
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
window.removeEventListener('mousemove', mouseMove)
|
|
194
|
-
window.removeEventListener('mouseup', mouseUp)
|
|
195
|
-
|
|
196
|
-
if(guide1 && guide1.parentNode){
|
|
197
|
-
guide1.parentNode.removeChild(guide1)
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
dragged = null
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
const keyUp = (e) => {
|
|
204
|
-
if(e.keyCode === 27){
|
|
205
|
-
if(dragged && this.parent){
|
|
206
|
-
const from = this.parent.indexOf(this.item)
|
|
207
|
-
const to = this.parent.indexOf(dragged.item)
|
|
208
|
-
this.parent.splice(to, 0, this.parent.splice(from, 1)[0]);
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
mouseUp(e)
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
|
|
215
|
-
window.addEventListener('mousemove', mouseMove)
|
|
216
|
-
window.addEventListener('mouseup', mouseUp)
|
|
217
|
-
window.addEventListener('keyup', keyUp)
|
|
218
|
-
},
|
|
219
|
-
|
|
220
|
-
},
|
|
221
|
-
|
|
222
|
-
name: "UserActionItem",
|
|
223
|
-
|
|
224
|
-
props: {
|
|
225
|
-
|
|
226
|
-
config: Object,
|
|
227
|
-
|
|
228
|
-
index: {
|
|
229
|
-
type: Number,
|
|
230
|
-
default: 0
|
|
231
|
-
},
|
|
232
|
-
|
|
233
|
-
isLast: Boolean,
|
|
234
|
-
|
|
235
|
-
item: Object,
|
|
236
|
-
|
|
237
|
-
level: {
|
|
238
|
-
type: Number,
|
|
239
|
-
default: 0
|
|
240
|
-
},
|
|
241
|
-
|
|
242
|
-
useAdd: undefined,
|
|
243
|
-
|
|
244
|
-
parent: Array,
|
|
245
|
-
|
|
246
|
-
removable: {
|
|
247
|
-
type: Boolean,
|
|
248
|
-
default: true
|
|
249
|
-
},
|
|
250
|
-
|
|
251
|
-
size: {
|
|
252
|
-
type: Array,
|
|
253
|
-
default: [ 160, 60, 24 ]
|
|
254
|
-
},
|
|
255
|
-
|
|
256
|
-
hasChildren: {
|
|
257
|
-
type: Boolean,
|
|
258
|
-
default: true
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
}
|
|
262
|
-
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
</script>
|
|
266
|
-
|
|
267
|
-
<style module>
|
|
268
|
-
|
|
269
|
-
.isFallback{
|
|
270
|
-
@apply absolute bottom-0 left-0 right-0 h-[4px] bg-primary;
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
</style>
|
|
@@ -1,152 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<Modal :state="state"
|
|
3
|
-
:hash="hash"
|
|
4
|
-
ref="modal"
|
|
5
|
-
:width="width"
|
|
6
|
-
:height="height">
|
|
7
|
-
|
|
8
|
-
<template v-slot:head>
|
|
9
|
-
<div class="relative p-6">
|
|
10
|
-
<h3 v-if="!instance.type">{{ $t('Select Type') }}</h3>
|
|
11
|
-
<h3 v-else>{{ $t(instance.text) }}</h3>
|
|
12
|
-
<div class="absolute top-0 right-0 p-2">
|
|
13
|
-
<button type="button" class="p-2" @click="close">
|
|
14
|
-
<svg width="24" height="24" viewBox="0 0 24 24" class="fill-text-300 hover:fill-red-500" xmlns="http://www.w3.org/2000/svg">
|
|
15
|
-
<path d="M6.53034 5.46965C6.23745 5.17676 5.76257 5.17676 5.46968 5.46965C5.17679 5.76255 5.17679 6.23742 5.46968 6.53031L10.9393 12L5.46967 17.4697C5.17678 17.7626 5.17678 18.2374 5.46967 18.5303C5.76256 18.8232 6.23744 18.8232 6.53033 18.5303L12 13.0606L17.4697 18.5303C17.7626 18.8232 18.2375 18.8232 18.5303 18.5303C18.8232 18.2374 18.8232 17.7626 18.5303 17.4697L13.0607 12L18.5303 6.53032C18.8232 6.23743 18.8232 5.76256 18.5303 5.46966C18.2374 5.17677 17.7626 5.17677 17.4697 5.46966L12 10.9393L6.53034 5.46965Z"/>
|
|
16
|
-
</svg>
|
|
17
|
-
</button>
|
|
18
|
-
</div>
|
|
19
|
-
</div>
|
|
20
|
-
</template>
|
|
21
|
-
|
|
22
|
-
<template v-slot:foot>
|
|
23
|
-
<div v-if="instance.type" class="p-6 flex flex-row gap-4 items-end">
|
|
24
|
-
<div class="flex-1">
|
|
25
|
-
<Button class="w-[100px]" :state="canApply ? 1 : -1" @click="apply">
|
|
26
|
-
{{ $t('OK') }}
|
|
27
|
-
</Button>
|
|
28
|
-
</div>
|
|
29
|
-
<div class="flex flex-row gap-2 items-center">
|
|
30
|
-
<Switch v-model="instance.params.passthrough" />
|
|
31
|
-
<label>Passthrough</label>
|
|
32
|
-
</div>
|
|
33
|
-
</div>
|
|
34
|
-
</template>
|
|
35
|
-
|
|
36
|
-
<div class="flex-1">
|
|
37
|
-
|
|
38
|
-
<div v-if="!instance.type" class="flex-1">
|
|
39
|
-
|
|
40
|
-
<div class="flex flex-col divide-border-50 border-t-[1px] border-b-[1px] border-border-50">
|
|
41
|
-
<button v-for="output in outputs"
|
|
42
|
-
type="button"
|
|
43
|
-
class="p-3 px-6 text-left"
|
|
44
|
-
@click="Object.assign(instance, output)">
|
|
45
|
-
{{ output.text }}
|
|
46
|
-
</button>
|
|
47
|
-
</div>
|
|
48
|
-
|
|
49
|
-
</div>
|
|
50
|
-
|
|
51
|
-
<div v-else>
|
|
52
|
-
<component :is="componentName" :output="instance"></component>
|
|
53
|
-
</div>
|
|
54
|
-
|
|
55
|
-
</div>
|
|
56
|
-
|
|
57
|
-
</Modal>
|
|
58
|
-
</template>
|
|
59
|
-
|
|
60
|
-
<script>
|
|
61
|
-
|
|
62
|
-
import Modal from "../../components/Modal.vue"
|
|
63
|
-
import {capitalize} from "../../utils/helpers.mjs";
|
|
64
|
-
import {defineAsyncComponent} from "vue";
|
|
65
|
-
|
|
66
|
-
export default{
|
|
67
|
-
|
|
68
|
-
components: {
|
|
69
|
-
Modal,
|
|
70
|
-
UserActionOutputReply: defineAsyncComponent(() => import('./UserActionOutputReply.vue')),
|
|
71
|
-
},
|
|
72
|
-
|
|
73
|
-
computed: {
|
|
74
|
-
|
|
75
|
-
canApply(){
|
|
76
|
-
return this.instance?.type
|
|
77
|
-
},
|
|
78
|
-
|
|
79
|
-
componentName(){
|
|
80
|
-
return this.instance._component?.name ?
|
|
81
|
-
this.instance._component?.name :
|
|
82
|
-
`UserActionOutput${capitalize(this.instance?.type)}`
|
|
83
|
-
},
|
|
84
|
-
|
|
85
|
-
height(){
|
|
86
|
-
return this.instance?.type ? 480 : 300
|
|
87
|
-
},
|
|
88
|
-
|
|
89
|
-
width(){
|
|
90
|
-
return this.instance?.type ? 420 : 300
|
|
91
|
-
},
|
|
92
|
-
|
|
93
|
-
},
|
|
94
|
-
|
|
95
|
-
emits: [ 'apply' ],
|
|
96
|
-
|
|
97
|
-
inject: [ 'socketEmit2' ],
|
|
98
|
-
|
|
99
|
-
props: {
|
|
100
|
-
state: Boolean,
|
|
101
|
-
hash: String,
|
|
102
|
-
|
|
103
|
-
outputs: Array
|
|
104
|
-
},
|
|
105
|
-
|
|
106
|
-
data(){
|
|
107
|
-
return {
|
|
108
|
-
id: null,
|
|
109
|
-
instance: null,
|
|
110
|
-
}
|
|
111
|
-
},
|
|
112
|
-
|
|
113
|
-
methods: {
|
|
114
|
-
|
|
115
|
-
apply(){
|
|
116
|
-
this.close()
|
|
117
|
-
this.$emit('apply', this.instance, this.id)
|
|
118
|
-
},
|
|
119
|
-
|
|
120
|
-
create(){
|
|
121
|
-
this.instance = {
|
|
122
|
-
params: {
|
|
123
|
-
passthrough: true
|
|
124
|
-
}
|
|
125
|
-
}
|
|
126
|
-
this.id = null
|
|
127
|
-
this.$refs.modal.open()
|
|
128
|
-
},
|
|
129
|
-
|
|
130
|
-
open(instance, id){
|
|
131
|
-
this.instance = instance
|
|
132
|
-
this.id = id
|
|
133
|
-
this.$refs.modal.open()
|
|
134
|
-
},
|
|
135
|
-
|
|
136
|
-
close(){
|
|
137
|
-
this.$refs.modal.close()
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
</script>
|
|
145
|
-
|
|
146
|
-
<style module>
|
|
147
|
-
|
|
148
|
-
.comp{
|
|
149
|
-
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
</style>
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="p-5">
|
|
3
|
-
<label>Delay</label>
|
|
4
|
-
<div class="flex flex-row gap-2 mt-2">
|
|
5
|
-
<Textbox v-model.number="output.params.value" maxlength="4" />
|
|
6
|
-
<Dropdown v-model="output.params.unit">
|
|
7
|
-
<option value="second">Seconds</option>
|
|
8
|
-
<option value="minute">Minutes</option>
|
|
9
|
-
<option value="hour">Hour</option>
|
|
10
|
-
</Dropdown>
|
|
11
|
-
</div>
|
|
12
|
-
</div>
|
|
13
|
-
</template>
|
|
14
|
-
|
|
15
|
-
<script>
|
|
16
|
-
|
|
17
|
-
export default{
|
|
18
|
-
|
|
19
|
-
props: {
|
|
20
|
-
|
|
21
|
-
output: Object
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
</script>
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="p-5">
|
|
3
|
-
<label>Text</label>
|
|
4
|
-
<TextWithTag v-model="output.params.text" :items="tagItems" />
|
|
5
|
-
</div>
|
|
6
|
-
</template>
|
|
7
|
-
|
|
8
|
-
<script>
|
|
9
|
-
|
|
10
|
-
export default{
|
|
11
|
-
|
|
12
|
-
props: {
|
|
13
|
-
|
|
14
|
-
output: Object,
|
|
15
|
-
|
|
16
|
-
tagItems: {
|
|
17
|
-
type: Array,
|
|
18
|
-
default: () => ([
|
|
19
|
-
{ text:'Name', value:'{message.inbox.name}' },
|
|
20
|
-
{ text:'Text', value:'{message.body}' }
|
|
21
|
-
])
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
</script>
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="p-6 pt-0 flex flex-col gap-5">
|
|
3
|
-
|
|
4
|
-
<div class="flex justify-center">
|
|
5
|
-
<Tabs :items="tabItems" v-model="output.params.type" />
|
|
6
|
-
</div>
|
|
7
|
-
|
|
8
|
-
<div v-if="output.params.type === 1">
|
|
9
|
-
<div>
|
|
10
|
-
<label class="text-text-400">Image</label>
|
|
11
|
-
<Image :src="output.params.imageUrl"
|
|
12
|
-
:editable="true"
|
|
13
|
-
@change="(base64, file) => output.params.imageUrl = file"
|
|
14
|
-
ref="image"
|
|
15
|
-
class="w-full min-h-[100px] border-[1px] border-border-200 bg-base-500 rounded-lg flex">
|
|
16
|
-
<template #empty>
|
|
17
|
-
<div class="flex-1 flex items-center justify-center">
|
|
18
|
-
<button type="button" @click="$refs.image.edit()">
|
|
19
|
-
<svg width="24" height="24" class="fill-text-300 hover:fill-primary" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 512"><!--! Font Awesome Pro 6.0.0-alpha3 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) --><path d="M630.8 469.1l-55.95-43.85C575.3 422.2 575.1 419.2 575.1 416l.0034-320c0-35.35-28.65-64-64-64H127.1C113.6 32 100.4 36.98 89.78 45.06L38.81 5.113C28.34-3.058 13.31-1.246 5.109 9.192C-3.063 19.63-1.235 34.72 9.187 42.89L601.2 506.9C605.6 510.3 610.8 512 615.1 512c7.125 0 14.17-3.156 18.91-9.188C643.1 492.4 641.2 477.3 630.8 469.1zM223.1 149.6l-64.29-50.39C164.2 97.15 169.9 96 175.1 96c26.51 0 48 21.49 48 48C223.1 145.9 223.4 147.7 223.1 149.6zM331.2 234.3l23.45-35.18C357.7 194.7 362.7 192 368 192s10.35 2.672 13.31 7.125l103.9 155.9L331.2 234.3zM145.1 416c-6.021 0-11.53-3.379-14.26-8.75c-2.73-5.367-2.215-11.81 1.334-16.68l70-96C206.1 290.4 210.9 288 216 288s9.916 2.441 12.93 6.574l32.46 44.51l16.43-24.65L63.99 146.8L63.99 416c0 35.35 28.65 64 64 64h361.1l-81.66-64H145.1z"/></svg>
|
|
20
|
-
</button>
|
|
21
|
-
</div>
|
|
22
|
-
</template>
|
|
23
|
-
</Image>
|
|
24
|
-
</div>
|
|
25
|
-
|
|
26
|
-
<div>
|
|
27
|
-
<label class="text-text-400">Text</label>
|
|
28
|
-
<TextWithTag rows="5" v-model="output.params.text" :items="replyTextItems" />
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
<div>
|
|
32
|
-
<label class="text-text-400">Footer</label>
|
|
33
|
-
<Textbox v-model="output.params.footer" maxlength="50" />
|
|
34
|
-
</div>
|
|
35
|
-
|
|
36
|
-
<div>
|
|
37
|
-
<div class="flex flex-row gap-2 items-center">
|
|
38
|
-
<label class="flex-1 text-text-400">Buttons</label>
|
|
39
|
-
<button type="button" class="text-primary" @click="$array(output.params, 'buttons').push({})">
|
|
40
|
-
{{ $t('Add Button') }}
|
|
41
|
-
</button>
|
|
42
|
-
</div>
|
|
43
|
-
<ListItem :items="output.params.buttons"
|
|
44
|
-
@reorder="(from, to) => { output.params.buttons.splice(to, 0, output.params.buttons.splice(from, 1)[0]); }">
|
|
45
|
-
<template v-slot="{ item, index }">
|
|
46
|
-
<div class="flex flex-row items-center gap-3">
|
|
47
|
-
<div data-reorder>
|
|
48
|
-
<svg width="14" height="14" class="fill-text-300" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><path d="M496 288H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm0-128H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16z"/></svg>
|
|
49
|
-
</div>
|
|
50
|
-
<div class="flex-1 flex flex-row gap-2 items-center">
|
|
51
|
-
<Textbox class="w-[100px]" placeholder="Text" v-model="item.text" />
|
|
52
|
-
</div>
|
|
53
|
-
<div>
|
|
54
|
-
<button type="button" @click="output.params.buttons.splice(index, 1)">
|
|
55
|
-
<svg width="16" height="16" class="fill-text-300 hover:fill-red-500" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 320 512"><path d="M207.6 256l107.72-107.72c6.23-6.23 6.23-16.34 0-22.58l-25.03-25.03c-6.23-6.23-16.34-6.23-22.58 0L160 208.4 52.28 100.68c-6.23-6.23-16.34-6.23-22.58 0L4.68 125.7c-6.23 6.23-6.23 16.34 0 22.58L112.4 256 4.68 363.72c-6.23 6.23-6.23 16.34 0 22.58l25.03 25.03c6.23 6.23 16.34 6.23 22.58 0L160 303.6l107.72 107.72c6.23 6.23 16.34 6.23 22.58 0l25.03-25.03c6.23-6.23 6.23-16.34 0-22.58L207.6 256z"/></svg>
|
|
56
|
-
</button>
|
|
57
|
-
</div>
|
|
58
|
-
</div>
|
|
59
|
-
</template>
|
|
60
|
-
</ListItem>
|
|
61
|
-
</div>
|
|
62
|
-
</div>
|
|
63
|
-
|
|
64
|
-
<div v-else>
|
|
65
|
-
|
|
66
|
-
<div>
|
|
67
|
-
<label class="text-text-400">Template</label>
|
|
68
|
-
<Dropdown v-model="output.params.value">
|
|
69
|
-
<option value="hello_world">hello_world</option>
|
|
70
|
-
<option value="welcome1">welcome1</option>
|
|
71
|
-
<option value="select_beverages">select_beverages</option>
|
|
72
|
-
<option value="test7">test7</option>
|
|
73
|
-
</Dropdown>
|
|
74
|
-
</div>
|
|
75
|
-
|
|
76
|
-
</div>
|
|
77
|
-
|
|
78
|
-
</div>
|
|
79
|
-
</template>
|
|
80
|
-
|
|
81
|
-
<script>
|
|
82
|
-
|
|
83
|
-
export default{
|
|
84
|
-
|
|
85
|
-
computed: {
|
|
86
|
-
|
|
87
|
-
replyTextItems(){
|
|
88
|
-
return [
|
|
89
|
-
{ text:"Mobile Number", value:"{mobileNumber}" },
|
|
90
|
-
{ text:"Name", value:"{name}" },
|
|
91
|
-
{ text:"Created At", value:"{createdAt}" },
|
|
92
|
-
]
|
|
93
|
-
},
|
|
94
|
-
|
|
95
|
-
tabItems(){
|
|
96
|
-
return [
|
|
97
|
-
{ text:"Text", value:1 },
|
|
98
|
-
{ text:"Template", value:2 },
|
|
99
|
-
]
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
},
|
|
103
|
-
|
|
104
|
-
props: {
|
|
105
|
-
|
|
106
|
-
output: Object
|
|
107
|
-
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
</script>
|