@shwfed/config 2.3.27 → 2.3.29
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/dist/mcp.mjs +3963 -1597
- package/dist/module.json +1 -1
- package/dist/preview/assets/{config-CRqRJ0oF.js → config-6IiXCmyu.js} +1 -1
- package/dist/preview/assets/{config-C45AT0tt.js → config-BJzUh1_G.js} +1 -1
- package/dist/preview/assets/{config-CIcy6Jwg.js → config-Bl80ye-i.js} +1 -1
- package/dist/preview/assets/{config-D0YS2Bpj.js → config-CZOeZ8ty.js} +1 -1
- package/dist/preview/assets/{config-l3KurfL5.js → config-DaZD4ZSa.js} +1 -1
- package/dist/preview/assets/{config-D-i-AFgH.js → config-DhsbcNzx.js} +1 -1
- package/dist/preview/assets/{config-CXaH7a2G.js → config-Diuyh0Ex.js} +1 -1
- package/dist/preview/assets/{config-Bv_hUugV.js → config-aK67Rsw5.js} +1 -1
- package/dist/preview/assets/{config-DrpESRR5.js → config-rpX_Mc6I.js} +1 -1
- package/dist/preview/assets/{definition.vue_vue_type_script_setup_true_lang-Ck8Pbwem.js → definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js} +1 -1
- package/dist/preview/assets/index-2eQR4s3q.css +1 -0
- package/dist/preview/assets/index-DEF3_MKr.js +659 -0
- package/dist/preview/assets/index-Df-thth9.js +1 -0
- package/dist/preview/assets/{runtime-Df715bRA.js → runtime-3p1K6te5.js} +1 -1
- package/dist/preview/assets/{runtime-D42ecZyC.js → runtime-BcLnafic.js} +1 -1
- package/dist/preview/assets/{runtime-D6twt5H_.js → runtime-CSaV-359.js} +1 -1
- package/dist/preview/assets/{runtime-z_QPMN-R.js → runtime-CjR8Vi5N.js} +1 -1
- package/dist/preview/assets/{runtime-CvuGnDIa.js → runtime-D_fJCKX_.js} +1 -1
- package/dist/preview/assets/{runtime-tobnPKdV.js → runtime-DpeCgGEG.js} +1 -1
- package/dist/preview/assets/{runtime-CmCvUWLV.js → runtime-K2a1x0TJ.js} +1 -1
- package/dist/preview/assets/{runtime-BSASeqgI.js → runtime-g9Zu3VNQ.js} +1 -1
- package/dist/preview/assets/{runtime-DUyUjFqF.js → runtime-jTnh_6Dm.js} +1 -1
- package/dist/preview/index.html +2 -2
- package/dist/runtime/components/block-layout-editor/index.d.vue.ts +10 -2
- package/dist/runtime/components/block-layout-editor/index.vue +44 -8
- package/dist/runtime/components/block-layout-editor/index.vue.d.ts +10 -2
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/config.d.vue.ts +2 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/config.vue +57 -3
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/config.vue.d.ts +2 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/runtime.d.vue.ts +2 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/runtime.vue +1 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/runtime.vue.d.ts +2 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/schema.d.ts +2 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/schema.js +4 -0
- package/dist/runtime/components/config/config.vue +35 -0
- package/dist/runtime/components/config/use-editor.d.ts +11 -1
- package/dist/runtime/components/config/use-editor.js +27 -1
- package/dist/runtime/components/form/fields/2026-05-23/com.shwfed.form.field.tree.multi/config.d.vue.ts +4 -4
- package/dist/runtime/components/form/fields/2026-05-23/com.shwfed.form.field.tree.multi/config.vue.d.ts +4 -4
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/config.d.vue.ts +127 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/config.vue +593 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/config.vue.d.ts +127 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/runtime.vue +465 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/schema.d.ts +95 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.multi/schema.js +112 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/config.d.vue.ts +125 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/config.vue +525 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/config.vue.d.ts +125 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/runtime.vue +460 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/schema.d.ts +92 -0
- package/dist/runtime/components/form/fields/2026-05-26/com.shwfed.form.field.tree.combobox.single/schema.js +104 -0
- package/dist/runtime/components/form/fields/2026-05-26/tree-combobox-shared.d.ts +35 -0
- package/dist/runtime/components/form/fields/2026-05-26/tree-combobox-shared.js +31 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.d.vue.ts +163 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.vue +745 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/config.vue.d.ts +163 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/runtime.vue +383 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/schema.d.ts +264 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.multi/schema.js +183 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.d.vue.ts +163 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.vue +745 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/config.vue.d.ts +163 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/runtime.vue +402 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/schema.d.ts +264 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.combobox.single/schema.js +209 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.d.vue.ts +129 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.vue +618 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/config.vue.d.ts +129 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/runtime.vue +501 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/schema.d.ts +99 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.multi/schema.js +133 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.d.vue.ts +127 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.vue +550 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/config.vue.d.ts +127 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/runtime.vue +496 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/schema.d.ts +96 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.combobox.single/schema.js +125 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.d.vue.ts +133 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.vue +605 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/config.vue.d.ts +133 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/runtime.vue +401 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/schema.d.ts +102 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.multi/schema.js +142 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.d.vue.ts +131 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.vue +560 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/config.vue.d.ts +131 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/runtime.d.vue.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/runtime.vue +395 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/runtime.vue.d.ts +8 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/schema.d.ts +96 -0
- package/dist/runtime/components/form/fields/2026-05-28/com.shwfed.form.field.tree.single/schema.js +118 -0
- package/dist/runtime/components/form/fields/2026-05-28/tree-combobox-shared.d.ts +35 -0
- package/dist/runtime/components/form/fields/2026-05-28/tree-combobox-shared.js +31 -0
- package/dist/runtime/components/form/unit-config.vue +45 -1
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +131 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue +607 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +131 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/runtime.vue +447 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +90 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-multi/schema.js +143 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +129 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue +538 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +129 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/runtime.vue +429 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/schema.d.ts +87 -0
- package/dist/runtime/components/table/columns/2026-05-27/com.shwfed.table.column.tree-combobox-single/schema.js +135 -0
- package/dist/runtime/components/table/columns/2026-05-27/tree-combobox-shared.d.ts +35 -0
- package/dist/runtime/components/table/columns/2026-05-27/tree-combobox-shared.js +31 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.d.vue.ts +183 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue +931 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue.d.ts +183 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/runtime.vue +463 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.d.ts +283 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/schema.js +275 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.d.vue.ts +183 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue +931 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue.d.ts +183 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/runtime.vue +414 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.d.ts +283 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/schema.js +275 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.d.vue.ts +133 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue +632 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/config.vue.d.ts +133 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/runtime.vue +461 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/schema.d.ts +93 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-multi/schema.js +161 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.d.vue.ts +131 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue +563 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/config.vue.d.ts +131 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/runtime.d.vue.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/runtime.vue +443 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/runtime.vue.d.ts +9 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/schema.d.ts +90 -0
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.tree-combobox-single/schema.js +153 -0
- package/dist/runtime/components/table/columns/2026-05-28/tree-combobox-shared.d.ts +35 -0
- package/dist/runtime/components/table/columns/2026-05-28/tree-combobox-shared.js +31 -0
- package/dist/runtime/components/table/config.vue +16 -16
- package/dist/runtime/components/ui/command/CommandItem.d.vue.ts +7 -0
- package/dist/runtime/components/ui/command/CommandItem.vue +13 -4
- package/dist/runtime/components/ui/command/CommandItem.vue.d.ts +7 -0
- package/dist/runtime/components/ui/tree/Tree.d.vue.ts +2 -0
- package/dist/runtime/components/ui/tree/Tree.vue +7 -2
- package/dist/runtime/components/ui/tree/Tree.vue.d.ts +2 -0
- package/dist/runtime/components/ui/tree/TreeNode.vue +16 -26
- package/dist/runtime/share/clipboard.d.ts +26 -0
- package/dist/runtime/share/clipboard.js +82 -0
- package/dist/runtime/share/layout.d.ts +4 -0
- package/dist/runtime/share/layout.js +35 -0
- package/package.json +1 -1
- package/dist/preview/assets/index-BCE-G4Ha.css +0 -1
- package/dist/preview/assets/index-C3Ycah5_.js +0 -643
- package/dist/preview/assets/index-hWT4_I5k.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{aL as e}from"./index-DEF3_MKr.js";import{aM as r,aN as s,aO as t}from"./index-DEF3_MKr.js";export{r as TableConfig,s as createTableConfig,e as default,t as getColumnTechnicalKey};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as i,ae as x,as as p,af as M,ag as c,at as T,au as N,e as b,w as d,u,a0 as k,a1 as w,an as L,ar as S,o as A,f as I,av as z,g as r,aw as F,ax as H,a7 as V,am as $,ay as f,az as m,aA as j}from"./index-
|
|
1
|
+
import{d as i,ae as x,as as p,af as M,ag as c,at as T,au as N,e as b,w as d,u,a0 as k,a1 as w,an as L,ar as S,o as A,f as I,av as z,g as r,aw as F,ax as H,a7 as V,am as $,ay as f,az as m,aA as j}from"./index-DEF3_MKr.js";import{_ as K}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const O=i({name:"ShwfedModalLayoutActionRuntime",__name:"runtime",props:{buttonId:{},config:{},buttonTitle:{}},setup(a){const n=a,{locale:l}=x(),v=e=>{},g=$(),s=w(f,void 0),h=L(),o=k(null),C=p(n.buttonId,{close:()=>S(()=>{o.value?.()})},h),y=i({name:"ModalBoundaryBridge",setup(e,{slots:t}){return H(g),m(j,C),s&&m(f,s),()=>t.default?.()}}),E=(e,t)=>V()?.(e,t),_=M(function*(){const e=c(n.config.modalTitle,l.value)??c(n.buttonTitle,l.value)??"",{modal:t,close:B}=yield*T({title:e,width:n.config.modalWidth});o.value=()=>N(B()),yield*t,o.value=null});return(e,t)=>(A(),b(K,{"action-id":a.buttonId,effect:u(_)},{default:d(()=>[I("div",{style:z(a.config.modalMinHeight?`min-height: ${a.config.modalMinHeight}`:void 0)},[r(u(y),null,{default:d(()=>[r(F,{"slot-value":a.config.slot,configure:v,"find-entry":E},null,8,["slot-value"])]),_:1})],4)]),_:1},8,["action-id","effect"]))}});export{O as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as r,ao as f,aj as u,e as p,u as g,ak as m,al as l,am as d,an as x,o as E}from"./index-
|
|
1
|
+
import{d as r,ao as f,aj as u,e as p,u as g,ak as m,al as l,am as d,an as x,o as E}from"./index-DEF3_MKr.js";import{_}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const k=r({name:"ShwfedHttpRequestActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(n){const e=n,t=d(),c=(s,o)=>m(s,{...l(t),...o}),i=x(),a=f(()=>u(e.config.expression,c,{messageExpression:e.config.messageExpression,resultExpression:e.config.resultExpression,channel:i,triggers:{success:e.config.onSuccess,warning:e.config.onWarning,error:e.config.onError,info:e.config.onInfo}}));return(s,o)=>(E(),p(_,{"action-id":n.buttonId,effect:g(a)},null,8,["action-id","effect"]))}});export{k as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as _,ao as B,af as E,ar as r,aB as m,aC as S,aD as j,e as k,u as v,ak as x,al as C,an as L,am as b,o as R}from"./index-
|
|
1
|
+
import{d as _,ao as B,af as E,ar as r,aB as m,aC as S,aD as j,e as k,u as v,ak as x,al as C,an as L,am as b,o as R}from"./index-DEF3_MKr.js";import{_ as T}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const q=_({name:"ShwfedHttpDownloadActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(d){const c=d,g=b(),t=(e,n)=>x(e,{...C(g),...n}),l=L(),p=new Set(["success","error","warning","info"]);function f(e){const n=URL.createObjectURL(e),o=document.createElement("a");o.href=n,o.download=e.name,document.body.appendChild(o),o.click(),o.remove(),URL.revokeObjectURL(n)}const y=B(()=>E(function*(){const{template:e,messageExpression:n,resultExpression:o}=c.config,u=yield*t(e.request);if(!e.download){const s=yield*u.file();return yield*r(()=>f(s)),yield*m(l,c.config.onSuccess)}const a={json:yield*u.json()},i=o===void 0?"success":yield*S(t(o,a),s=>p.has(s)?s:"success");if(n!==void 0){const s=yield*t(n,a);yield*r(()=>j[i](s))}if(i==="success"||i==="info"){const h=yield*(yield*t(e.download,a)).file();yield*r(()=>f(h))}const w={success:c.config.onSuccess,warning:c.config.onWarning,error:c.config.onError,info:c.config.onInfo};return yield*m(l,w[i])}));return(e,n)=>(R(),k(T,{"action-id":d.buttonId,effect:v(y)},null,8,["action-id","effect"]))}});export{q as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as l,aE as g,ao as A,aq as y,aB as _,e as h,u as S,ak as b,al as k,an as j,aF as B,o as C,am as E}from"./index-
|
|
1
|
+
import{d as l,aE as g,ao as A,aq as y,aB as _,e as h,u as S,ak as b,al as k,an as j,aF as B,o as C,am as E}from"./index-DEF3_MKr.js";import{_ as F}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const I=l({name:"ShwfedStateWriteActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(r){const s=r,i=E(),f=(e,t)=>b(e,{...k(i),...t}),n=g(),o=n.kind==="form"&&n.parent?n.parent:n,u=j(),m=B((e,t,a)=>{if(Array.isArray(e[t])&&Array.isArray(a))return e[t]=a,!0});function c(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function p(e,t){return c(e)&&c(t)?m({...t},e):t}const d=A(()=>y(f(s.config.expression),e=>{for(const t of Object.keys(e)){const a=p(o.getAt(t),e[t]);o.setAt(t,a)}return _(u,s.config.onSuccess)}));return(e,t)=>(C(),h(F,{"action-id":r.buttonId,effect:S(d)},null,8,["action-id","effect"]))}});export{I as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as o}from"./definition.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import{_ as o}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";import{d as n,e as a,u as c,o as f,ap as i}from"./index-DEF3_MKr.js";const p=n({name:"ShwfedPrototypeActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(e){const t=i;return(r,s)=>(f(),a(o,{"action-id":e.buttonId,effect:c(t)},null,8,["action-id","effect"]))}});export{p as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as i,ao as f,aq as r,ar as d,e as m,u,ak as l,al as p,am as _,o as g}from"./index-
|
|
1
|
+
import{d as i,ao as f,aq as r,ar as d,e as m,u,ak as l,al as p,am as _,o as g}from"./index-DEF3_MKr.js";import{_ as h}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const x=i({name:"ShwfedNavigationActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(e){const t=e,o=_(),c=(n,a)=>l(n,{...p(o),...a}),s=f(()=>r(c(t.config.url),n=>d(()=>{window.open(n,t.config.mode)})));return(n,a)=>(g(),m(h,{"action-id":e.buttonId,effect:u(s)},null,8,["action-id","effect"]))}});export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as o}from"./definition.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import{_ as o}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";import{d as s,ao as c,aB as i,e as r,u as f,an as u,o as m}from"./index-DEF3_MKr.js";const g=s({name:"ShwfedEventDispatchActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(e){const n=e,t=u(),a=c(()=>i(t,n.config.triggers));return(p,d)=>(m(),r(o,{"action-id":e.buttonId,effect:f(a)},null,8,["action-id","effect"]))}});export{g as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as u,ae as l,e as i,u as p,$ as m,o as d,k as f,ag as _,ah as k,ak as g,al as w,am as x}from"./index-
|
|
1
|
+
import{d as u,ae as l,e as i,u as p,$ as m,o as d,k as f,ag as _,ah as k,ak as g,al as w,am as x}from"./index-DEF3_MKr.js";const B=u({name:"ShwfedMarkdownItemRuntime",__name:"runtime",props:{config:{}},setup(n){const s=n,{locale:o}=l(),t=x(),c=(e,a)=>g(e,{...w(t),...a}),r=m(()=>{const e=_(s.config.content,o.value)??"";return k(e,c)});return(e,a)=>(d(),i(p(f),{"data-slot":"buttons-markdown",source:r.value,class:"prose prose-sm prose-zinc px-1"},null,8,["source"]))}});export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as f,ae as u,af as l,ag as g,ah as m,ai as p,aj as d,e as x,u as E,ak as _,al as h,am as k,an as w,o as C}from"./index-
|
|
1
|
+
import{d as f,ae as u,af as l,ag as g,ah as m,ai as p,aj as d,e as x,u as E,ak as _,al as h,am as k,an as w,o as C}from"./index-DEF3_MKr.js";import{_ as I}from"./definition.vue_vue_type_script_setup_true_lang-C_jU8d47.js";const R=f({name:"ShwfedHttpRequestConfirmActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(s){const n=s,{locale:c}=u(),a=k(),t=(e,o)=>_(e,{...h(a),...o}),i=w(),r=l(function*(){const e=g(n.config.markdown,c.value)??"",o=m(e,t);(yield*p({content:o,icon:n.config.icon,color:n.config.color}))||(yield*d(n.config.expression,t,{messageExpression:n.config.messageExpression,resultExpression:n.config.resultExpression,channel:i,triggers:{success:n.config.onSuccess,warning:n.config.onWarning,error:n.config.onError,info:n.config.onInfo}}))});return(e,o)=>(C(),x(I,{"action-id":s.buttonId,effect:E(r)},null,8,["action-id","effect"]))}});export{R as default};
|
package/dist/preview/index.html
CHANGED
|
@@ -10,8 +10,8 @@
|
|
|
10
10
|
`--primary`, the primary button variant renders as transparent. */
|
|
11
11
|
body { --primary: #009689; }
|
|
12
12
|
</style>
|
|
13
|
-
<script type="module" crossorigin src="./assets/index-
|
|
14
|
-
<link rel="stylesheet" crossorigin href="./assets/index-
|
|
13
|
+
<script type="module" crossorigin src="./assets/index-DEF3_MKr.js"></script>
|
|
14
|
+
<link rel="stylesheet" crossorigin href="./assets/index-2eQR4s3q.css">
|
|
15
15
|
</head>
|
|
16
16
|
<body>
|
|
17
17
|
<div id="app"></div>
|
|
@@ -42,6 +42,10 @@ declare const __VLS_export: <TItem extends {
|
|
|
42
42
|
activeIndex?: number;
|
|
43
43
|
selectedItemIds?: string[];
|
|
44
44
|
}) & {
|
|
45
|
+
onPaste?: ((target: {
|
|
46
|
+
x: number;
|
|
47
|
+
y: number;
|
|
48
|
+
} | null) => any) | undefined;
|
|
45
49
|
"onUpdate:modelValue"?: ((value: Readonly<{
|
|
46
50
|
name: string;
|
|
47
51
|
media?: string;
|
|
@@ -58,6 +62,7 @@ declare const __VLS_export: <TItem extends {
|
|
|
58
62
|
"onDrill-down"?: ((itemId: string) => any) | undefined;
|
|
59
63
|
"onDelete-item"?: ((itemId: string) => any) | undefined;
|
|
60
64
|
"onDelete-items"?: ((itemIds: string[]) => any) | undefined;
|
|
65
|
+
"onCopy-items"?: ((itemIds: string[]) => any) | undefined;
|
|
61
66
|
"onUpdate:activeIndex"?: ((value: number) => any) | undefined;
|
|
62
67
|
"onUpdate:selectedItemIds"?: ((value: string[]) => any) | undefined;
|
|
63
68
|
}> & (typeof globalThis extends {
|
|
@@ -66,14 +71,17 @@ declare const __VLS_export: <TItem extends {
|
|
|
66
71
|
expose: (exposed: {}) => void;
|
|
67
72
|
attrs: any;
|
|
68
73
|
slots: {};
|
|
69
|
-
emit: (((evt: "
|
|
74
|
+
emit: (((evt: "paste", target: {
|
|
75
|
+
x: number;
|
|
76
|
+
y: number;
|
|
77
|
+
} | null) => void) & ((evt: "add-new", entry: Readonly<{
|
|
70
78
|
type: string;
|
|
71
79
|
compatibilityDate: string;
|
|
72
80
|
name: string;
|
|
73
81
|
icon: string;
|
|
74
82
|
}>, options: {
|
|
75
83
|
silent: boolean;
|
|
76
|
-
}) => void) & ((evt: "drill-down", itemId: string) => void) & ((evt: "delete-item", itemId: string) => void) & ((evt: "delete-items", itemIds: string[]) => void)) & (((event: "update:modelValue", value: Readonly<{
|
|
84
|
+
}) => void) & ((evt: "drill-down", itemId: string) => void) & ((evt: "delete-item", itemId: string) => void) & ((evt: "delete-items", itemIds: string[]) => void) & ((evt: "copy-items", itemIds: string[]) => void)) & (((event: "update:modelValue", value: Readonly<{
|
|
77
85
|
name: string;
|
|
78
86
|
media?: string;
|
|
79
87
|
layout: import("../form/schema.js").LayoutValue;
|
|
@@ -60,7 +60,7 @@ const props = defineProps({
|
|
|
60
60
|
pickerEntries: { type: Array, required: false },
|
|
61
61
|
canDelete: { type: Boolean, required: false }
|
|
62
62
|
});
|
|
63
|
-
const emit = defineEmits(["add-new", "drill-down", "delete-item", "delete-items"]);
|
|
63
|
+
const emit = defineEmits(["add-new", "drill-down", "delete-item", "delete-items", "copy-items", "paste"]);
|
|
64
64
|
let pendingAddSilent = false;
|
|
65
65
|
function captureAddModifiers(e) {
|
|
66
66
|
pendingAddSilent = e.metaKey || e.ctrlKey;
|
|
@@ -234,6 +234,18 @@ const marqueeStyle = computed(() => {
|
|
|
234
234
|
transform: `translate3d(${b.x}px, ${b.y}px, 0)`
|
|
235
235
|
};
|
|
236
236
|
});
|
|
237
|
+
const pendingPasteCell = ref(null);
|
|
238
|
+
function onPlaneContextMenu(e) {
|
|
239
|
+
const rect = canvasRef.value?.getBoundingClientRect();
|
|
240
|
+
if (!rect) {
|
|
241
|
+
pendingPasteCell.value = null;
|
|
242
|
+
return;
|
|
243
|
+
}
|
|
244
|
+
const s = stepPx.value;
|
|
245
|
+
const x = Math.floor((e.clientX - rect.left - coordinate.value.x) / s) + 1;
|
|
246
|
+
const y = Math.floor((e.clientY - rect.top - coordinate.value.y) / s) + 1;
|
|
247
|
+
pendingPasteCell.value = { x, y };
|
|
248
|
+
}
|
|
237
249
|
function onPlaneMouseDown(e) {
|
|
238
250
|
if (e.button !== 0) return;
|
|
239
251
|
if (isSpaceHeld.value) return;
|
|
@@ -791,13 +803,27 @@ function toggleFullscreen() {
|
|
|
791
803
|
class="relative overflow-hidden rounded border border-zinc-200 bg-zinc-50 select-none"
|
|
792
804
|
:class="[isFullscreen ? 'h-screen' : 'h-full']"
|
|
793
805
|
>
|
|
794
|
-
<
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
806
|
+
<ContextMenu>
|
|
807
|
+
<ContextMenuTrigger as-child>
|
|
808
|
+
<div
|
|
809
|
+
ref="planeRef"
|
|
810
|
+
class="absolute inset-0"
|
|
811
|
+
:class="[isPanning ? 'cursor-grabbing' : isSpaceHeld ? 'cursor-grab' : '']"
|
|
812
|
+
:style="bgStyle"
|
|
813
|
+
@mousedown="onPlaneMouseDown"
|
|
814
|
+
@contextmenu="onPlaneContextMenu"
|
|
815
|
+
/>
|
|
816
|
+
</ContextMenuTrigger>
|
|
817
|
+
<ContextMenuContent
|
|
818
|
+
class="min-w-auto p-1.5"
|
|
819
|
+
:to="isFullscreen ? canvasRef : null"
|
|
820
|
+
>
|
|
821
|
+
<ContextMenuItem @select="emit('paste', pendingPasteCell)">
|
|
822
|
+
<Icon icon="fluent:clipboard-paste-20-regular" />
|
|
823
|
+
<span>粘贴{{ itemNoun }}</span>
|
|
824
|
+
</ContextMenuItem>
|
|
825
|
+
</ContextMenuContent>
|
|
826
|
+
</ContextMenu>
|
|
801
827
|
|
|
802
828
|
<div
|
|
803
829
|
v-if="marqueeStyle"
|
|
@@ -912,6 +938,11 @@ function toggleFullscreen() {
|
|
|
912
938
|
:to="isFullscreen ? canvasRef : null"
|
|
913
939
|
>
|
|
914
940
|
<template v-if="selectedItemIds.length > 1 && isSelected(entry.itemId)">
|
|
941
|
+
<ContextMenuItem @select="emit('copy-items', [...selectedItemIds])">
|
|
942
|
+
<Icon icon="fluent:copy-20-regular" />
|
|
943
|
+
<span>复制 ({{ selectedItemIds.length }})</span>
|
|
944
|
+
</ContextMenuItem>
|
|
945
|
+
<ContextMenuSeparator />
|
|
915
946
|
<ContextMenuRadioGroup
|
|
916
947
|
:model-value="sharedAlignment('h') ?? ''"
|
|
917
948
|
class="my-1 flex items-center justify-center gap-0.5"
|
|
@@ -1059,6 +1090,11 @@ function toggleFullscreen() {
|
|
|
1059
1090
|
</ContextMenuItem>
|
|
1060
1091
|
</template>
|
|
1061
1092
|
<template v-else>
|
|
1093
|
+
<ContextMenuItem @select="emit('copy-items', [entry.itemId])">
|
|
1094
|
+
<Icon icon="fluent:copy-20-regular" />
|
|
1095
|
+
<span>复制</span>
|
|
1096
|
+
</ContextMenuItem>
|
|
1097
|
+
<ContextMenuSeparator />
|
|
1062
1098
|
<ContextMenuRadioGroup
|
|
1063
1099
|
:model-value="entry.placement.h ?? 'stretch'"
|
|
1064
1100
|
class="my-1 flex items-center justify-center gap-0.5"
|
|
@@ -42,6 +42,10 @@ declare const __VLS_export: <TItem extends {
|
|
|
42
42
|
activeIndex?: number;
|
|
43
43
|
selectedItemIds?: string[];
|
|
44
44
|
}) & {
|
|
45
|
+
onPaste?: ((target: {
|
|
46
|
+
x: number;
|
|
47
|
+
y: number;
|
|
48
|
+
} | null) => any) | undefined;
|
|
45
49
|
"onUpdate:modelValue"?: ((value: Readonly<{
|
|
46
50
|
name: string;
|
|
47
51
|
media?: string;
|
|
@@ -58,6 +62,7 @@ declare const __VLS_export: <TItem extends {
|
|
|
58
62
|
"onDrill-down"?: ((itemId: string) => any) | undefined;
|
|
59
63
|
"onDelete-item"?: ((itemId: string) => any) | undefined;
|
|
60
64
|
"onDelete-items"?: ((itemIds: string[]) => any) | undefined;
|
|
65
|
+
"onCopy-items"?: ((itemIds: string[]) => any) | undefined;
|
|
61
66
|
"onUpdate:activeIndex"?: ((value: number) => any) | undefined;
|
|
62
67
|
"onUpdate:selectedItemIds"?: ((value: string[]) => any) | undefined;
|
|
63
68
|
}> & (typeof globalThis extends {
|
|
@@ -66,14 +71,17 @@ declare const __VLS_export: <TItem extends {
|
|
|
66
71
|
expose: (exposed: {}) => void;
|
|
67
72
|
attrs: any;
|
|
68
73
|
slots: {};
|
|
69
|
-
emit: (((evt: "
|
|
74
|
+
emit: (((evt: "paste", target: {
|
|
75
|
+
x: number;
|
|
76
|
+
y: number;
|
|
77
|
+
} | null) => void) & ((evt: "add-new", entry: Readonly<{
|
|
70
78
|
type: string;
|
|
71
79
|
compatibilityDate: string;
|
|
72
80
|
name: string;
|
|
73
81
|
icon: string;
|
|
74
82
|
}>, options: {
|
|
75
83
|
silent: boolean;
|
|
76
|
-
}) => void) & ((evt: "drill-down", itemId: string) => void) & ((evt: "delete-item", itemId: string) => void) & ((evt: "delete-items", itemIds: string[]) => void)) & (((event: "update:modelValue", value: Readonly<{
|
|
84
|
+
}) => void) & ((evt: "drill-down", itemId: string) => void) & ((evt: "delete-item", itemId: string) => void) & ((evt: "delete-items", itemIds: string[]) => void) & ((evt: "copy-items", itemIds: string[]) => void)) & (((event: "update:modelValue", value: Readonly<{
|
|
77
85
|
name: string;
|
|
78
86
|
media?: string;
|
|
79
87
|
layout: import("../form/schema.js").LayoutValue;
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/config.d.vue.ts
CHANGED
|
@@ -10,6 +10,7 @@ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
|
10
10
|
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
11
11
|
"update:modelValue": (value: {
|
|
12
12
|
readonly type: "com.shwfed.block.tabs";
|
|
13
|
+
readonly style?: string | undefined;
|
|
13
14
|
readonly id: string;
|
|
14
15
|
readonly displayName?: string | undefined;
|
|
15
16
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -47,6 +48,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
47
48
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
48
49
|
"onUpdate:modelValue"?: ((value: {
|
|
49
50
|
readonly type: "com.shwfed.block.tabs";
|
|
51
|
+
readonly style?: string | undefined;
|
|
50
52
|
readonly id: string;
|
|
51
53
|
readonly displayName?: string | undefined;
|
|
52
54
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -13,6 +13,7 @@ import { Locale as LocaleField } from "../../../../ui/locale";
|
|
|
13
13
|
import { Markdown } from "../../../../ui/markdown";
|
|
14
14
|
import { ScrollArea } from "../../../../ui/scroll-area";
|
|
15
15
|
import { Separator } from "../../../../ui/separator";
|
|
16
|
+
import { Textarea } from "../../../../ui/textarea";
|
|
16
17
|
import { Tooltip, TooltipContent, TooltipTrigger } from "../../../../ui/tooltip";
|
|
17
18
|
import {
|
|
18
19
|
useTreeDnd
|
|
@@ -33,6 +34,7 @@ const paneFieldDescription = (f) => getStructFieldDescription(TabPaneMeta, f);
|
|
|
33
34
|
const { locale } = useI18n();
|
|
34
35
|
const tabs = computed(() => block.value.tabs);
|
|
35
36
|
const activePaneId = ref(tabs.value[0]?.id ?? "");
|
|
37
|
+
const viewMode = ref("pane");
|
|
36
38
|
function paneIndex(id) {
|
|
37
39
|
return block.value.tabs.findIndex((t) => t.id === id);
|
|
38
40
|
}
|
|
@@ -129,9 +131,23 @@ function paneLabel(t, index) {
|
|
|
129
131
|
return getLocalizedText(t.label, locale.value) ?? `\u6807\u7B7E\u9875 ${index + 1}`;
|
|
130
132
|
}
|
|
131
133
|
function selectPane(id) {
|
|
134
|
+
viewMode.value = "pane";
|
|
132
135
|
activePaneId.value = id;
|
|
133
136
|
drilledBlockId.value = null;
|
|
134
137
|
}
|
|
138
|
+
function selectGeneral() {
|
|
139
|
+
viewMode.value = "general";
|
|
140
|
+
drilledBlockId.value = null;
|
|
141
|
+
}
|
|
142
|
+
function updateBlockStyle(value) {
|
|
143
|
+
const next = { ...block.value };
|
|
144
|
+
if (value.trim() === "") {
|
|
145
|
+
delete next.style;
|
|
146
|
+
} else {
|
|
147
|
+
next.style = value;
|
|
148
|
+
}
|
|
149
|
+
block.value = next;
|
|
150
|
+
}
|
|
135
151
|
function makeId() {
|
|
136
152
|
if (typeof crypto !== "undefined" && "randomUUID" in crypto) return crypto.randomUUID();
|
|
137
153
|
return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c) => {
|
|
@@ -227,9 +243,9 @@ if (breadcrumbExt) {
|
|
|
227
243
|
const paneSuffix = breadcrumbExt.addParentSuffix();
|
|
228
244
|
const blockCrumb = breadcrumbExt.add();
|
|
229
245
|
watch(
|
|
230
|
-
[activePane, drilledBlock],
|
|
231
|
-
([pane, drilled]) => {
|
|
232
|
-
if (!pane) {
|
|
246
|
+
[activePane, drilledBlock, viewMode],
|
|
247
|
+
([pane, drilled, mode]) => {
|
|
248
|
+
if (mode === "general" || !pane) {
|
|
233
249
|
paneSuffix.value.value = null;
|
|
234
250
|
blockCrumb.label.value = null;
|
|
235
251
|
blockCrumb.back.value = null;
|
|
@@ -310,6 +326,22 @@ function deleteBlocksFromActive(ids) {
|
|
|
310
326
|
v-if="!drilledBlockId"
|
|
311
327
|
class="flex w-56 shrink-0 flex-col"
|
|
312
328
|
>
|
|
329
|
+
<div
|
|
330
|
+
class="row pl-2"
|
|
331
|
+
:class="[
|
|
332
|
+
viewMode === 'general' ? 'bg-[color-mix(in_srgb,var(--primary)_10%,white)] text-(--primary)' : 'text-zinc-700 hover:bg-zinc-50'
|
|
333
|
+
]"
|
|
334
|
+
@click="selectGeneral()"
|
|
335
|
+
>
|
|
336
|
+
<Icon
|
|
337
|
+
icon="fluent:settings-20-regular"
|
|
338
|
+
class="size-4 shrink-0"
|
|
339
|
+
/>
|
|
340
|
+
<span class="flex-1 truncate">通用配置</span>
|
|
341
|
+
</div>
|
|
342
|
+
|
|
343
|
+
<Separator class="my-2" />
|
|
344
|
+
|
|
313
345
|
<!-- Panes -->
|
|
314
346
|
<div class="flex flex-1 min-h-0 flex-col">
|
|
315
347
|
<ScrollArea class="flex-1">
|
|
@@ -446,6 +478,28 @@ function deleteBlocksFromActive(ids) {
|
|
|
446
478
|
</div>
|
|
447
479
|
</template>
|
|
448
480
|
|
|
481
|
+
<!-- General block-level settings. -->
|
|
482
|
+
<template v-else-if="viewMode === 'general'">
|
|
483
|
+
<Field orientation="vertical">
|
|
484
|
+
<FieldLabel class="text-xs text-zinc-500">
|
|
485
|
+
<template #tooltip>
|
|
486
|
+
<Markdown
|
|
487
|
+
source="应用在标签页最外层容器上的 CSS 样式字符串"
|
|
488
|
+
block
|
|
489
|
+
class="prose prose-sm prose-zinc"
|
|
490
|
+
/>
|
|
491
|
+
</template>
|
|
492
|
+
容器样式
|
|
493
|
+
</FieldLabel>
|
|
494
|
+
<Textarea
|
|
495
|
+
:model-value="block.style ?? ''"
|
|
496
|
+
placeholder="CSS 样式字符串"
|
|
497
|
+
class="min-h-20 font-mono text-xs"
|
|
498
|
+
@update:model-value="(v) => updateBlockStyle(String(v))"
|
|
499
|
+
/>
|
|
500
|
+
</Field>
|
|
501
|
+
</template>
|
|
502
|
+
|
|
449
503
|
<!-- Pane editor: tab name + active layout meta strip + canvas. -->
|
|
450
504
|
<template v-else-if="activePane && activeShell">
|
|
451
505
|
<Field orientation="vertical">
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/config.vue.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
|
10
10
|
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
11
11
|
"update:modelValue": (value: {
|
|
12
12
|
readonly type: "com.shwfed.block.tabs";
|
|
13
|
+
readonly style?: string | undefined;
|
|
13
14
|
readonly id: string;
|
|
14
15
|
readonly displayName?: string | undefined;
|
|
15
16
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -47,6 +48,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
47
48
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
48
49
|
"onUpdate:modelValue"?: ((value: {
|
|
49
50
|
readonly type: "com.shwfed.block.tabs";
|
|
51
|
+
readonly style?: string | undefined;
|
|
50
52
|
readonly id: string;
|
|
51
53
|
readonly displayName?: string | undefined;
|
|
52
54
|
readonly compatibilityDate: "2026-05-06";
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/runtime.d.vue.ts
CHANGED
|
@@ -10,6 +10,7 @@ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
|
10
10
|
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
11
11
|
"update:block": (value: {
|
|
12
12
|
readonly type: "com.shwfed.block.tabs";
|
|
13
|
+
readonly style?: string | undefined;
|
|
13
14
|
readonly id: string;
|
|
14
15
|
readonly displayName?: string | undefined;
|
|
15
16
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -47,6 +48,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
47
48
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
48
49
|
"onUpdate:block"?: ((value: {
|
|
49
50
|
readonly type: "com.shwfed.block.tabs";
|
|
51
|
+
readonly style?: string | undefined;
|
|
50
52
|
readonly id: string;
|
|
51
53
|
readonly displayName?: string | undefined;
|
|
52
54
|
readonly compatibilityDate: "2026-05-06";
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.tabs/runtime.vue.d.ts
CHANGED
|
@@ -10,6 +10,7 @@ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
|
|
|
10
10
|
declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
11
11
|
"update:block": (value: {
|
|
12
12
|
readonly type: "com.shwfed.block.tabs";
|
|
13
|
+
readonly style?: string | undefined;
|
|
13
14
|
readonly id: string;
|
|
14
15
|
readonly displayName?: string | undefined;
|
|
15
16
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -47,6 +48,7 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
47
48
|
}, string, import("vue").PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
48
49
|
"onUpdate:block"?: ((value: {
|
|
49
50
|
readonly type: "com.shwfed.block.tabs";
|
|
51
|
+
readonly style?: string | undefined;
|
|
50
52
|
readonly id: string;
|
|
51
53
|
readonly displayName?: string | undefined;
|
|
52
54
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -29,6 +29,7 @@ export declare const TabPaneMeta: Schema.Struct<{
|
|
|
29
29
|
}>;
|
|
30
30
|
export declare function schema(configure: (env: Environment) => void, blockRef: AnySchema): Schema.refine<{
|
|
31
31
|
readonly type: "com.shwfed.block.tabs";
|
|
32
|
+
readonly style?: string | undefined;
|
|
32
33
|
readonly id: string;
|
|
33
34
|
readonly displayName?: string | undefined;
|
|
34
35
|
readonly compatibilityDate: "2026-05-06";
|
|
@@ -67,6 +68,7 @@ export declare function schema(configure: (env: Environment) => void, blockRef:
|
|
|
67
68
|
type: Schema.tag<"com.shwfed.block.tabs">;
|
|
68
69
|
compatibilityDate: Schema.tag<"2026-05-06">;
|
|
69
70
|
displayName: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
71
|
+
style: Schema.optional<typeof Schema.String>;
|
|
70
72
|
tabs: Schema.refine<readonly {
|
|
71
73
|
readonly label: readonly [{
|
|
72
74
|
readonly locale: "zh";
|
|
@@ -54,6 +54,10 @@ export function schema(configure, blockRef) {
|
|
|
54
54
|
title: "\u5185\u90E8\u540D\u79F0",
|
|
55
55
|
description: "\u4EC5\u5728\u7F16\u8F91\u5668\u5185\u53EF\u89C1\u7684\u5757\u540D"
|
|
56
56
|
})),
|
|
57
|
+
style: Schema.optional(Schema.String).annotations({
|
|
58
|
+
title: "\u5BB9\u5668\u6837\u5F0F",
|
|
59
|
+
description: "\u5E94\u7528\u5728\u6807\u7B7E\u9875\u6700\u5916\u5C42\u5BB9\u5668\u4E0A\u7684 CSS \u6837\u5F0F\u5B57\u7B26\u4E32"
|
|
60
|
+
}),
|
|
57
61
|
tabs: Schema.Array(TabPane).pipe(
|
|
58
62
|
Schema.minItems(1),
|
|
59
63
|
Schema.filter((tabs) => {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
<script setup>
|
|
2
2
|
import { computed, provide, toRef, useTemplateRef } from "vue";
|
|
3
3
|
import { Icon } from "@iconify/vue";
|
|
4
|
+
import { toast } from "vue-sonner";
|
|
5
|
+
import { readClip, reidFragment, writeClip } from "../../share/clipboard";
|
|
4
6
|
import BlockLayoutEditor from "../block-layout-editor/index.vue";
|
|
5
7
|
import LayoutsSidebar from "../block-layout-editor/sidebar.vue";
|
|
6
8
|
import LayoutMetaStrip from "../block-layout-editor/meta-strip.vue";
|
|
@@ -48,6 +50,37 @@ function addBlock(entry, options) {
|
|
|
48
50
|
function onDrillDown(id) {
|
|
49
51
|
props.state.onDrillDown(id);
|
|
50
52
|
}
|
|
53
|
+
async function copyBlocks(ids) {
|
|
54
|
+
const want = new Set(ids);
|
|
55
|
+
const items = props.state.blocks.value.filter((b) => want.has(b.id));
|
|
56
|
+
if (items.length === 0) return;
|
|
57
|
+
const ls = layouts.value[activeLayoutIndex.value];
|
|
58
|
+
const placements = {};
|
|
59
|
+
if (ls) {
|
|
60
|
+
for (const id of ids) {
|
|
61
|
+
const p = ls.layout.placements[id];
|
|
62
|
+
if (p) placements[id] = p;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
if (!await writeClip("block", items, placements)) {
|
|
66
|
+
toast.error("\u590D\u5236\u5931\u8D25");
|
|
67
|
+
return;
|
|
68
|
+
}
|
|
69
|
+
toast.success(`\u5DF2\u590D\u5236 ${items.length} \u4E2A\u5757`);
|
|
70
|
+
}
|
|
71
|
+
async function pasteBlocks(target) {
|
|
72
|
+
const payload = await readClip();
|
|
73
|
+
if (!payload || payload.surface !== "block") return;
|
|
74
|
+
const { items, placements } = reidFragment(payload.items, payload.placements);
|
|
75
|
+
const pasted = items;
|
|
76
|
+
if (pasted.length === 0) return;
|
|
77
|
+
if (placements && Object.keys(placements).length > 0) {
|
|
78
|
+
props.state.addBlocksWithPlacements(pasted, placements, target);
|
|
79
|
+
} else {
|
|
80
|
+
props.state.addBlocks(pasted);
|
|
81
|
+
}
|
|
82
|
+
toast.success(`\u5DF2\u7C98\u8D34 ${pasted.length} \u4E2A\u5757`);
|
|
83
|
+
}
|
|
51
84
|
function updateActiveBlock(next) {
|
|
52
85
|
props.state.updateActiveBlock(next);
|
|
53
86
|
}
|
|
@@ -106,6 +139,8 @@ function findBlockMeta(type, compatibilityDate) {
|
|
|
106
139
|
@drill-down="onDrillDown"
|
|
107
140
|
@delete-item="(id) => props.state.removeBlock(id)"
|
|
108
141
|
@delete-items="(ids) => props.state.removeBlocks(ids)"
|
|
142
|
+
@copy-items="copyBlocks"
|
|
143
|
+
@paste="pasteBlocks"
|
|
109
144
|
/>
|
|
110
145
|
</div>
|
|
111
146
|
</div>
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ComputedRef, type Ref, type WritableComputedRef } from 'vue';
|
|
2
2
|
import type { Environment } from '../../vendor/cel-js/lib/index.js';
|
|
3
|
-
import { type LayoutSetValue, type SlotValue } from '../../share/layout.js';
|
|
3
|
+
import { type LayoutSetValue, type PlacementValue, type SlotValue } from '../../share/layout.js';
|
|
4
4
|
import type { BreadcrumbCrumb, BreadcrumbParentSuffix } from './breadcrumb-extension.js';
|
|
5
5
|
import { type BlockValue, type PageConfigValue } from './schema.js';
|
|
6
6
|
import { type BlockEntry } from './utils/resolve.js';
|
|
@@ -45,6 +45,11 @@ export interface SlotEditor {
|
|
|
45
45
|
addBlock: (entry: PickerEntry, options?: {
|
|
46
46
|
silent?: boolean;
|
|
47
47
|
}) => string;
|
|
48
|
+
addBlocks: (blocks: ReadonlyArray<BlockValue>) => void;
|
|
49
|
+
addBlocksWithPlacements: (blocks: ReadonlyArray<BlockValue>, placements: Readonly<Record<string, PlacementValue>>, target: {
|
|
50
|
+
x: number;
|
|
51
|
+
y: number;
|
|
52
|
+
} | null) => void;
|
|
48
53
|
removeBlock: (id: string) => void;
|
|
49
54
|
removeBlocks: (ids: ReadonlyArray<string>) => void;
|
|
50
55
|
updateBlock: (id: string, next: BlockValue) => void;
|
|
@@ -80,6 +85,11 @@ export interface ConfigEditorState {
|
|
|
80
85
|
addBlock: (entry: PickerEntry, options?: {
|
|
81
86
|
silent?: boolean;
|
|
82
87
|
}) => void;
|
|
88
|
+
addBlocks: (blocks: ReadonlyArray<BlockValue>) => void;
|
|
89
|
+
addBlocksWithPlacements: (blocks: ReadonlyArray<BlockValue>, placements: Readonly<Record<string, PlacementValue>>, target: {
|
|
90
|
+
x: number;
|
|
91
|
+
y: number;
|
|
92
|
+
} | null) => void;
|
|
83
93
|
removeBlock: (id: string) => void;
|
|
84
94
|
removeBlocks: (ids: ReadonlyArray<string>) => void;
|
|
85
95
|
updateActiveBlock: (next: BlockValue) => void;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Schema } from "effect";
|
|
2
2
|
import { computed, ref, shallowRef, watch } from "vue";
|
|
3
|
-
import { findFreePlacement, normalizeLayoutSet } from "../../share/layout.js";
|
|
3
|
+
import { findFreePlacement, normalizeLayoutSet, placeGroupAt } from "../../share/layout.js";
|
|
4
4
|
import { PageConfig } from "./schema.js";
|
|
5
5
|
import { BLOCKS, findBlock } from "./utils/resolve.js";
|
|
6
6
|
function deepClone(value) {
|
|
@@ -106,6 +106,28 @@ export function useSlotEditor(slot, options = {}) {
|
|
|
106
106
|
}
|
|
107
107
|
return id;
|
|
108
108
|
}
|
|
109
|
+
function addBlocks(newBlocks) {
|
|
110
|
+
if (newBlocks.length === 0) return;
|
|
111
|
+
slot.value = { ...slot.value, blocks: [...slot.value.blocks, ...newBlocks] };
|
|
112
|
+
}
|
|
113
|
+
function addBlocksWithPlacements(newBlocks, placements, target) {
|
|
114
|
+
if (newBlocks.length === 0) return;
|
|
115
|
+
const i = activeLayoutIndex.value;
|
|
116
|
+
const nextLayouts = slot.value.layouts.map((ls, idx) => {
|
|
117
|
+
if (idx !== i) return ls;
|
|
118
|
+
const shifted = placeGroupAt(ls.layout.placements, placements, target ?? { x: 1, y: 1 });
|
|
119
|
+
return normalizeLayoutSet({
|
|
120
|
+
...ls,
|
|
121
|
+
layout: { ...ls.layout, placements: { ...ls.layout.placements, ...shifted } }
|
|
122
|
+
});
|
|
123
|
+
});
|
|
124
|
+
slot.value = {
|
|
125
|
+
...slot.value,
|
|
126
|
+
blocks: [...slot.value.blocks, ...newBlocks],
|
|
127
|
+
layouts: nextLayouts
|
|
128
|
+
};
|
|
129
|
+
selectedBlockIds.value = newBlocks.map((b) => b.id);
|
|
130
|
+
}
|
|
109
131
|
function removeBlock(id) {
|
|
110
132
|
removeBlocks([id]);
|
|
111
133
|
}
|
|
@@ -154,6 +176,8 @@ export function useSlotEditor(slot, options = {}) {
|
|
|
154
176
|
layouts: layoutsAccessor,
|
|
155
177
|
pickerEntries,
|
|
156
178
|
addBlock,
|
|
179
|
+
addBlocks,
|
|
180
|
+
addBlocksWithPlacements,
|
|
157
181
|
removeBlock,
|
|
158
182
|
removeBlocks,
|
|
159
183
|
updateBlock,
|
|
@@ -375,6 +399,8 @@ export function useConfigEditor(model, options = {}) {
|
|
|
375
399
|
popOne,
|
|
376
400
|
pushBlock,
|
|
377
401
|
addBlock,
|
|
402
|
+
addBlocks: topSlotEditor.addBlocks,
|
|
403
|
+
addBlocksWithPlacements: topSlotEditor.addBlocksWithPlacements,
|
|
378
404
|
removeBlock: topSlotEditor.removeBlock,
|
|
379
405
|
removeBlocks: topSlotEditor.removeBlocks,
|
|
380
406
|
updateActiveBlock,
|