@shwfed/config 2.9.12 → 2.9.13
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 +112 -50
- package/dist/module.json +1 -1
- package/dist/preview/assets/{FieldGroup.vue_vue_type_script_setup_true_lang-CpDhqXJp.js → FieldGroup.vue_vue_type_script_setup_true_lang-DZ_H-YRf.js} +1 -1
- package/dist/preview/assets/{badge-Dsz2Rn8b.js → badge-DoNuZh0A.js} +1 -1
- package/dist/preview/assets/{config-CQLR1Zao.js → config-BDDuqAht.js} +1 -1
- package/dist/preview/assets/{config-BCvaA0as.js → config-Bhc_Vu67.js} +1 -1
- package/dist/preview/assets/{config-CRD1MpEn.js → config-BrNZsgV0.js} +1 -1
- package/dist/preview/assets/{config-Y2YuesjH.js → config-C6Cm7DWx.js} +1 -1
- package/dist/preview/assets/{config-bFWnH6k3.js → config-CIYui2J_.js} +1 -1
- package/dist/preview/assets/{config-DY7nQeRd.js → config-CLsjWZz2.js} +1 -1
- package/dist/preview/assets/{config-X6-9yQmS.js → config-Cla0Qngs.js} +1 -1
- package/dist/preview/assets/{config-if9TvUw2.js → config-D4rFsdGO.js} +1 -1
- package/dist/preview/assets/{config-vsMk-zRS.js → config-DTEJOYqA.js} +1 -1
- package/dist/preview/assets/{config-9-c5e5iP.js → config-YGBoSq6x.js} +1 -1
- package/dist/preview/assets/{config-hrBgOr32.js → config-tdZMdIN3.js} +1 -1
- package/dist/preview/assets/{config-BePS5kQb.js → config-ugF_BOWz.js} +1 -1
- package/dist/preview/assets/{definition.vue_vue_type_script_setup_true_lang-CPrYbKjH.js → definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js} +1 -1
- package/dist/preview/assets/index-B-QhiviS.js +1 -0
- package/dist/preview/assets/{index-DFRXx_kG.js → index-C3FdepLE.js} +1 -1
- package/dist/preview/assets/{index-Bvlt8fEt.js → index-CWMhB7z4.js} +200 -199
- package/dist/preview/assets/{index-DJ5rzQJr.css → index-CzzwZ7bp.css} +1 -1
- package/dist/preview/assets/{item-auVJu6jy.js → item-DecwNzYq.js} +1 -1
- package/dist/preview/assets/{runtime-Do_KQ5le.js → runtime-BK7KNEyN.js} +1 -1
- package/dist/preview/assets/{runtime-DyeSWij2.js → runtime-C3dmOj9s.js} +1 -1
- package/dist/preview/assets/{runtime-CBDARlsK.js → runtime-C5hqSHRW.js} +1 -1
- package/dist/preview/assets/{runtime-1DsatQOR.js → runtime-C8Ufkmiw.js} +1 -1
- package/dist/preview/assets/{runtime-DaaQn8fX.js → runtime-CYpXd7Pq.js} +1 -1
- package/dist/preview/assets/{runtime-H7c112vi.js → runtime-CjPtRd-T.js} +1 -1
- package/dist/preview/assets/{runtime-CmgeUPz4.js → runtime-DSUjc0Pk.js} +1 -1
- package/dist/preview/assets/{runtime-_5B97gRO.js → runtime-DZ_AwduQ.js} +1 -1
- package/dist/preview/assets/{runtime-BDvuTpxY.js → runtime-DtP98Km5.js} +1 -1
- package/dist/preview/assets/{runtime-28a_li4U.js → runtime-blb90Fhv.js} +1 -1
- package/dist/preview/assets/{schema-meta-Dc89aD6v.js → schema-meta-DWUHNP8E.js} +1 -1
- package/dist/preview/index.html +2 -2
- package/dist/runtime/components/actions/buttons/2026-05-15/com.shwfed.actions.button.event.dispatch/schema.d.ts +15 -0
- package/dist/runtime/components/actions/buttons/2026-05-15/com.shwfed.actions.button.event.dispatch/schema.js +57 -1
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/config.d.vue.ts +134 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/config.vue.d.ts +134 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/runtime.d.vue.ts +134 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/runtime.vue.d.ts +134 -0
- package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/schema.d.ts +195 -0
- package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/config.d.vue.ts +2 -0
- package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/config.vue.d.ts +2 -0
- package/dist/runtime/components/form/fields/2026-05-18/com.shwfed.form.field.table/schema.d.ts +2 -0
- package/dist/runtime/components/operations/2026-06-11/com.shwfed.operation.http.request.json/runtime.js +5 -3
- package/dist/runtime/components/operations/2026-06-11/com.shwfed.operation.http.request.json/schema.js +3 -2
- package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-remote/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-24/com.shwfed.table.column.combobox-single.remote.options-static/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-remote/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-25/com.shwfed.table.column.combobox-multi.remote.options-static/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-multi.remote/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-26/com.shwfed.table.column.combobox-single.remote/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-multi/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.d.vue.ts +2 -2
- package/dist/runtime/components/table/columns/2026-05-28/com.shwfed.table.column.combobox-single/config.vue.d.ts +2 -2
- package/dist/runtime/components/table/config.d.vue.ts +3 -3
- package/dist/runtime/components/table/config.vue +54 -20
- package/dist/runtime/components/table/config.vue.d.ts +3 -3
- package/dist/runtime/components/table/index.d.vue.ts +2 -0
- package/dist/runtime/components/table/index.vue +12 -3
- package/dist/runtime/components/table/index.vue.d.ts +2 -0
- package/dist/runtime/components/table/schema.d.ts +263 -0
- package/dist/runtime/components/table/schema.js +8 -4
- package/package.json +1 -1
- package/dist/preview/assets/index-BoyzyftU.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as O,v as M,x as k,y,o as q,c as E,z,b as A,A as x,B as i,C as J,D as L,E as s,F as T,G as V,H as D,I as G,J as H,K,L as g,M as P,N as b,O as U}from"./index-
|
|
1
|
+
import{d as O,v as M,x as k,y,o as q,c as E,z,b as A,A as x,B as i,C as J,D as L,E as s,F as T,G as V,H as D,I as G,J as H,K,L as g,M as P,N as b,O as U}from"./index-CWMhB7z4.js";import W from"./index-C3FdepLE.js";const X=O({name:"ShwfedBlockAnimatedNumberItem",__name:"item",props:{item:{}},setup(h){const n=h,j=P(),a=x(void 0),m=x(0);function u(){return K(j)}function S(e){if(typeof e=="number"&&Number.isFinite(e))return e;if(typeof e=="string"&&e.trim()!==""){const t=Number(e);return Number.isFinite(t)?t:0}return 0}const d=i(()=>a.value===void 0?g():U(a.value));function v(e){if(!e)return"";try{const t=b(s(e,{...u(),json:d.value}));return t==null?"":String(t)}catch{return""}}const w=i(()=>v(n.item.prefix)),C=i(()=>v(n.item.suffix));function F(e){if(e)try{const t=b(s(e,{...u(),json:d.value}));return t==null?void 0:typeof t=="string"||typeof t=="object"?t:String(t)}catch{return}}const I=i(()=>F(n.item.style));async function r(){const e=n.item.dataSource,t=u(),_=J(function*(){let o=g();e.request&&(o=yield*L(yield*s(e.request,t)));const B=yield*s(e.value,{...t,json:o});return{json:T(o),value:B}});try{const o=await V(D(_,G));a.value=o.json,m.value=S(o.value)}catch(o){console.warn("[shwfed-animated-number] fetch failed",o)}}const l=i(()=>(n.item.pollingInterval??0)>0),N=i(()=>Math.max(1,n.item.pollingInterval??1)*1e3),c=H(),{pause:p,resume:f}=M(()=>{r()},N,{immediate:!1});return k(()=>{r(),l.value&&c.value&&f()}),y(c,e=>{l.value&&(e?(r(),f()):p())}),y(()=>[n.item.dataSource.request??"",n.item.dataSource.value,n.item.pollingInterval??0].join("|"),()=>{r(),l.value&&c.value?f():p()}),(e,t)=>(q(),E(A(W),{value:m.value,prefix:w.value,suffix:C.value,style:z(I.value)},null,8,["value","prefix","suffix","style"]))}});export{X as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as r,aR as f,aM as d,c as u,b as m,aQ as p,o as l,E as g,K as h,M as _}from"./index-
|
|
1
|
+
import{d as r,aR as f,aM as d,c as u,b as m,aQ as p,o as l,E as g,K as h,M as _}from"./index-CWMhB7z4.js";import{_ as C}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const x=r({name:"ShwfedEventDispatchActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(e){const c=e,s=_(),a=(n,t)=>g(n,{...h(s),...t}),o=p(),i=f(()=>d(o,c.config.triggers,a));return(n,t)=>(l(),u(C,{"action-id":e.buttonId,effect:m(i)},null,8,["action-id","effect"]))}});export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as l,b3 as g,aR as A,aU as y,aM as b,c as _,b as h,E as S,K as j,aQ as k,b4 as C,M as B,o as E}from"./index-
|
|
1
|
+
import{d as l,b3 as g,aR as A,aU as y,aM as b,c as _,b as h,E as S,K as j,aQ as k,b4 as C,M as B,o as E}from"./index-CWMhB7z4.js";import{_ as M}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const F=l({name:"ShwfedStateWriteActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(s){const a=s,f=B(),c=(e,t)=>S(e,{...j(f),...t}),n=g(),o=n.kind==="form"&&n.parent?n.parent:n,u=k(),m=C((e,t,r)=>{if(Array.isArray(e[t])&&Array.isArray(r))return e[t]=r,!0});function i(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function p(e,t){return i(e)&&i(t)?m({...t},e):t}const d=A(()=>y(c(a.config.expression),e=>{for(const t of Object.keys(e)){const r=p(o.getAt(t),e[t]);o.setAt(t,r)}return b(u,a.config.onSuccess,c)}));return(e,t)=>(E(),_(M,{"action-id":s.buttonId,effect:h(d)},null,8,["action-id","effect"]))}});export{F as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as f,Y as g,C as l,aM as u,a1 as d,aN as p,aO as m,aP as x,c as E,b as _,E as h,K as C,aQ as w,M as b,o as k}from"./index-
|
|
1
|
+
import{d as f,Y as g,C as l,aM as u,a1 as d,aN as p,aO as m,aP as x,c as E,b as _,E as h,K as C,aQ as w,M as b,o as k}from"./index-CWMhB7z4.js";import{_ as I}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const M=f({name:"ShwfedHttpRequestConfirmActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(c){const n=c,{locale:i}=g(),a=b(),s=(e,o)=>h(e,{...C(a),...o}),t=w(),r=l(function*(){yield*u(t,n.config.before,s);const e=d(n.config.markdown,i.value)??"",o=p(e,s);(yield*m({content:o,icon:n.config.icon,color:n.config.color}))||(yield*x(n.config.expression,s,{messageExpression:n.config.messageExpression,resultExpression:n.config.resultExpression,channel:t,triggers:{success:n.config.onSuccess,warning:n.config.onWarning,error:n.config.onError,info:n.config.onInfo}}))});return(e,o)=>(k(),E(I,{"action-id":c.buttonId,effect:_(r)},null,8,["action-id","effect"]))}});export{M 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-CgNXv26P.js";import{d as n,c,b as a,o as f,aT as i}from"./index-CWMhB7z4.js";const _=n({name:"ShwfedPrototypeActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(t){const e=i;return(r,s)=>(f(),c(o,{"action-id":t.buttonId,effect:a(e)},null,8,["action-id","effect"]))}});export{_ as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as f,aR as u,aU as l,aV as d,c as m,b as w,E as p,K as _,M as g,o as h}from"./index-
|
|
1
|
+
import{d as f,aR as u,aU as l,aV as d,c as m,b as w,E as p,K as _,M as g,o as h}from"./index-CWMhB7z4.js";import{_ as b}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";function v(){return{resolve:e=>({href:new URL(e,window.location.href).href})}}function x(e,t){return window.location.assign(e),Promise.resolve()}const B=f({name:"ShwfedNavigationActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(e){const t=e,i=v(),a=g(),r=(n,o)=>p(n,{..._(a),...o});function c(n){try{return new URL(n,window.location.href).origin!==window.location.origin}catch{return!1}}const s=u(()=>l(r(t.config.url),n=>d(async()=>{const o=c(n);if(t.config.mode==="_blank"){window.open(o?n:i.resolve(n).href,"_blank");return}await x(n)})));return(n,o)=>(h(),m(b,{"action-id":e.buttonId,effect:w(s)},null,8,["action-id","effect"]))}});export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as u,Y as i,c as l,b as p,B as m,o as d,h as f,a1 as _,aN as k,E as w,K as x,M as g}from"./index-
|
|
1
|
+
import{d as u,Y as i,c as l,b as p,B as m,o as d,h as f,a1 as _,aN as k,E as w,K as x,M as g}from"./index-CWMhB7z4.js";const B=u({name:"ShwfedMarkdownItemRuntime",__name:"runtime",props:{config:{}},setup(s){const o=s,{locale:t}=i(),a=g(),c=(e,n)=>w(e,{...x(a),...n}),r=m(()=>{const e=_(o.config.content,t.value)??"";return k(e,c)});return(e,n)=>(d(),l(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 b,aR as E,C as _,aY as r,aM as m,b1 as S,b2 as j,c as v,b as x,E as B,K as C,aQ as L,M as R,o as k}from"./index-
|
|
1
|
+
import{d as b,aR as E,C as _,aY as r,aM as m,b1 as S,b2 as j,c as v,b as x,E as B,K as C,aQ as L,M as R,o as k}from"./index-CWMhB7z4.js";import{_ as T}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const q=b({name:"ShwfedHttpDownloadActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(d){const c=d,g=R(),t=(e,n)=>B(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=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,t)}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],t)}));return(e,n)=>(k(),v(T,{"action-id":d.buttonId,effect:x(y)},null,8,["action-id","effect"]))}});export{q as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as f,Y as u,aR as p,aS as d,aM as l,b5 as m,a1 as g,c as x,b as h,E,K as _,aQ as b,o as B,M as k}from"./index-
|
|
1
|
+
import{d as f,Y as u,aR as p,aS as d,aM as l,b5 as m,a1 as g,c as x,b as h,E,K as _,aQ as b,o as B,M as k}from"./index-CWMhB7z4.js";import{_ as C}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const I=f({name:"ShwfedHttpRequestBatchActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(n){const e=n,{locale:a}=u(),c=k(),s=(t,o)=>E(t,{..._(c),...o}),i=b(),r=p(()=>d(l(i,e.config.before,s),()=>m(e.config.expression,s,{messageExpression:e.config.messageExpression,resultExpression:e.config.resultExpression,continueOnError:e.config.continueOnError,markdown:g(e.config.markdown,a.value)??""})));return(t,o)=>(B(),x(C,{"action-id":n.buttonId,effect:h(r)},null,8,["action-id","effect"]))}});export{I as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as r,aR as f,aS as u,aM as g,aP as p,c as d,b as m,E as l,K as x,aQ as E,M as h,o as _}from"./index-
|
|
1
|
+
import{d as r,aR as f,aS as u,aM as g,aP as p,c as d,b as m,E as l,K as x,aQ as E,M as h,o as _}from"./index-CWMhB7z4.js";import{_ as b}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const B=r({name:"ShwfedHttpRequestActionRuntime",__name:"runtime",props:{buttonId:{},config:{}},setup(n){const e=n,i=h(),s=(t,c)=>l(t,{...x(i),...c}),o=E(),a=f(()=>u(g(o,e.config.before,s),()=>p(e.config.expression,s,{messageExpression:e.config.messageExpression,resultExpression:e.config.resultExpression,channel:o,triggers:{success:e.config.onSuccess,warning:e.config.onWarning,error:e.config.onError,info:e.config.onInfo}})));return(t,c)=>(_(),d(b,{"action-id":n.buttonId,effect:m(a)},null,8,["action-id","effect"]))}});export{B as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as s,Y as M,aW as b,C as p,a1 as c,aX as x,N,c as T,w as d,b as u,A as k,Q as L,aQ as S,aY as w,o as A,j as I,z as V,a as r,aZ as Y,a_ as $,aD as j,M as z,a$ as f,V as m,b0 as F}from"./index-
|
|
1
|
+
import{d as s,Y as M,aW as b,C as p,a1 as c,aX as x,N,c as T,w as d,b as u,A as k,Q as L,aQ as S,aY as w,o as A,j as I,z as V,a as r,aZ as Y,a_ as $,aD as j,M as z,a$ as f,V as m,b0 as F}from"./index-CWMhB7z4.js";import{_ as H}from"./definition.vue_vue_type_script_setup_true_lang-CgNXv26P.js";const R=s({name:"ShwfedModalLayoutActionRuntime",__name:"runtime",props:{buttonId:{},config:{},buttonTitle:{}},setup(n){const a=n,{locale:l}=M(),v=e=>{},h=z(),i=L(f,void 0),C=S(),o=k(null),g=b(a.buttonId,{close:()=>w(()=>{o.value?.()})},C),_=s({name:"ModalBoundaryBridge",setup(e,{slots:t}){return $(h),m(F,g),i&&m(f,i),()=>t.default?.()}}),E=(e,t)=>j()?.(e,t),y=p(function*(){const e=c(a.config.modalTitle,l.value)??c(a.buttonTitle,l.value)??"",{modal:t,close:B}=yield*x({title:e,width:a.config.modalWidth});o.value=()=>N(B()),yield*t,o.value=null});return(e,t)=>(A(),T(H,{"action-id":n.buttonId,effect:u(y)},{default:d(()=>[I("div",{style:V(n.config.modalMinHeight?`min-height: ${n.config.modalMinHeight}`:void 0)},[r(u(_),null,{default:d(()=>[r(Y,{"slot-value":n.config.slot,configure:v,"find-entry":E},null,8,["slot-value"])]),_:1})],4)]),_:1},8,["action-id","effect"]))}});export{R as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as o,q as l,r as p}from"./index-
|
|
1
|
+
import{p as o,q as l,r as p}from"./index-CWMhB7z4.js";function i(n){switch(n._tag){case"TypeLiteral":return n;case"Transformation":return i(n.to);case"Refinement":return i(n.from);case"Suspend":return i(n.f());default:return null}}function d(n,t){const e=i(n.ast);return e?e.propertySignatures.find(r=>r.name===t)??null:null}function y(n){const t=n.type;if(t._tag==="Union"&&n.isOptional){const e=t.types.find(r=>r._tag!=="UndefinedKeyword");if(e)return e}return t}function c(n,t,e){const r=d(n,t);if(!r)return;const u=e(r);if(o(u))return u.value;const f=y(r),s=e(f);if(o(s))return s.value;if(f!==r.type){const a=e(r.type);if(o(a))return a.value}}function m(n,t){return c(n,t,l)}function v(n,t){return c(n,t,p)}export{v as a,m as g};
|
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-CWMhB7z4.js"></script>
|
|
14
|
+
<link rel="stylesheet" crossorigin href="./assets/index-CzzwZ7bp.css">
|
|
15
15
|
</head>
|
|
16
16
|
<body>
|
|
17
17
|
<div id="app"></div>
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Schema } from 'effect';
|
|
2
2
|
import type { Environment } from '../../../../../vendor/cel-js/lib/index.js';
|
|
3
|
+
import type { MigrateFn, MigrateSource } from '../../../utils/resolve.js';
|
|
3
4
|
export declare const type: "com.shwfed.actions.button.event.dispatch";
|
|
4
5
|
export declare const compatibilityDate: "2026-05-15";
|
|
5
6
|
export declare const metadata: {
|
|
@@ -18,3 +19,17 @@ export declare function schema(_configure: (env: Environment) => void): Schema.S
|
|
|
18
19
|
}>>>;
|
|
19
20
|
}>;
|
|
20
21
|
export type Value = Schema.Schema.Type<ReturnType<typeof schema>>;
|
|
22
|
+
/**
|
|
23
|
+
* Adopts values stored under the standalone 「请求」 button
|
|
24
|
+
* (`com.shwfed.actions.button.http.request.json@2026-04-18`). That button baked
|
|
25
|
+
* the whole request lifecycle into itself — fire a request, classify the
|
|
26
|
+
* result, toast a message, then run one of four result-keyed trigger lists.
|
|
27
|
+
* The page now exposes the request as an ambient 「发送请求」 *operation* that is
|
|
28
|
+
* itself one step of a trigger chain, so the same behaviour is expressed as an
|
|
29
|
+
* ordinary 「触发事件」 button whose trigger list is `before` + the request row +
|
|
30
|
+
* the success arm, flattened in order. Migration declarations live exclusively
|
|
31
|
+
* on this (replacement) entry; the request folder is kept so not-yet-migrated
|
|
32
|
+
* configs keep loading, but it is never touched here.
|
|
33
|
+
*/
|
|
34
|
+
export declare const migrateFrom: ReadonlyArray<MigrateSource>;
|
|
35
|
+
export declare const migrate: MigrateFn;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
import { Schema } from "effect";
|
|
1
|
+
import { Effect, Schema } from "effect";
|
|
2
2
|
import { Triggers } from "../../../../../share/event-bus.js";
|
|
3
|
+
import { PAGE_TARGET_ID } from "../../../../../share/page-target.js";
|
|
4
|
+
import * as httpRequestOp from "../../../../operations/2026-06-11/com.shwfed.operation.http.request.json/schema.js";
|
|
3
5
|
export const type = "com.shwfed.actions.button.event.dispatch";
|
|
4
6
|
export const compatibilityDate = "2026-05-15";
|
|
5
7
|
export const metadata = {
|
|
@@ -18,3 +20,57 @@ export function schema(_configure) {
|
|
|
18
20
|
}))
|
|
19
21
|
});
|
|
20
22
|
}
|
|
23
|
+
export const migrateFrom = [
|
|
24
|
+
{ type: "com.shwfed.actions.button.http.request.json", compatibilityDate: "2026-04-18" }
|
|
25
|
+
];
|
|
26
|
+
export const migrate = (prev) => Effect.try({
|
|
27
|
+
try: () => {
|
|
28
|
+
if (!prev || typeof prev !== "object") {
|
|
29
|
+
throw new Error("\u89E6\u53D1\u4E8B\u4EF6\u8FC1\u79FB\u5931\u8D25\uFF1A\u539F\u503C\u4E0D\u662F\u5BF9\u8C61");
|
|
30
|
+
}
|
|
31
|
+
const {
|
|
32
|
+
type: _t,
|
|
33
|
+
compatibilityDate: _c,
|
|
34
|
+
expression,
|
|
35
|
+
before,
|
|
36
|
+
messageExpression,
|
|
37
|
+
resultExpression,
|
|
38
|
+
onSuccess,
|
|
39
|
+
onWarning,
|
|
40
|
+
onError,
|
|
41
|
+
onInfo,
|
|
42
|
+
...rest
|
|
43
|
+
} = prev;
|
|
44
|
+
const nonEmpty = (arm) => Array.isArray(arm) && arm.length > 0;
|
|
45
|
+
if (nonEmpty(onWarning) || nonEmpty(onError) || nonEmpty(onInfo)) {
|
|
46
|
+
throw new Error("\u8BE5\u300C\u8BF7\u6C42\u300D\u6309\u94AE\u914D\u7F6E\u4E86\u300C\u8B66\u544A\u300D\u300C\u9519\u8BEF\u300D\u6216\u300C\u4FE1\u606F\u300D\u5206\u652F\uFF0C\u65E0\u6CD5\u81EA\u52A8\u8FC1\u79FB\u4E3A\u89E6\u53D1\u94FE\uFF0C\u8BF7\u624B\u52A8\u6539\u5199");
|
|
47
|
+
}
|
|
48
|
+
const onCompleted = typeof messageExpression === "string" && messageExpression.length > 0 ? `(${messageExpression})` : "''";
|
|
49
|
+
const titleExpression = `json == null ? '\u8BF7\u6C42\u5931\u8D25' : ${onCompleted}`;
|
|
50
|
+
const params = {
|
|
51
|
+
expression: typeof expression === "string" ? expression : "",
|
|
52
|
+
titleExpression
|
|
53
|
+
};
|
|
54
|
+
if (typeof resultExpression === "string" && resultExpression.length > 0) {
|
|
55
|
+
params.resultExpression = resultExpression;
|
|
56
|
+
}
|
|
57
|
+
const requestRow = {
|
|
58
|
+
// The row id is the address later steps reference outputs under; mint a
|
|
59
|
+
// stable one so it survives reorders (see the Trigger schema).
|
|
60
|
+
id: crypto.randomUUID(),
|
|
61
|
+
target: PAGE_TARGET_ID,
|
|
62
|
+
operation: httpRequestOp.type,
|
|
63
|
+
compatibilityDate: httpRequestOp.compatibilityDate,
|
|
64
|
+
params
|
|
65
|
+
};
|
|
66
|
+
const beforeRows = Array.isArray(before) ? before : [];
|
|
67
|
+
const successRows = Array.isArray(onSuccess) ? onSuccess : [];
|
|
68
|
+
return {
|
|
69
|
+
...rest,
|
|
70
|
+
type,
|
|
71
|
+
compatibilityDate,
|
|
72
|
+
triggers: [...beforeRows, requestRow, ...successRows]
|
|
73
|
+
};
|
|
74
|
+
},
|
|
75
|
+
catch: (e) => e instanceof Error ? e : new Error(String(e))
|
|
76
|
+
});
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/config.d.vue.ts
CHANGED
|
@@ -135,6 +135,73 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
135
135
|
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
136
136
|
}[];
|
|
137
137
|
} | undefined;
|
|
138
|
+
readonly bottomActions?: {
|
|
139
|
+
readonly size: "default" | "sm" | "xs";
|
|
140
|
+
readonly style?: string | undefined;
|
|
141
|
+
readonly gap: number;
|
|
142
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistryItemValue | {
|
|
143
|
+
readonly disabled?: string | undefined;
|
|
144
|
+
readonly id: string;
|
|
145
|
+
readonly title: readonly [{
|
|
146
|
+
readonly locale: "zh";
|
|
147
|
+
readonly message: string;
|
|
148
|
+
}, ...{
|
|
149
|
+
readonly locale: "en" | "ja" | "ko";
|
|
150
|
+
readonly message: string;
|
|
151
|
+
}[]];
|
|
152
|
+
readonly icon?: string | undefined;
|
|
153
|
+
readonly hidden?: string | undefined;
|
|
154
|
+
readonly tooltip?: readonly [{
|
|
155
|
+
readonly locale: "zh";
|
|
156
|
+
readonly message: string;
|
|
157
|
+
}, ...{
|
|
158
|
+
readonly locale: "en" | "ja" | "ko";
|
|
159
|
+
readonly message: string;
|
|
160
|
+
}[]] | undefined;
|
|
161
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
162
|
+
readonly action?: any;
|
|
163
|
+
readonly groupId: string;
|
|
164
|
+
readonly hideTitle?: boolean | undefined;
|
|
165
|
+
} | {
|
|
166
|
+
readonly id: string;
|
|
167
|
+
readonly title: readonly [{
|
|
168
|
+
readonly locale: "zh";
|
|
169
|
+
readonly message: string;
|
|
170
|
+
}, ...{
|
|
171
|
+
readonly locale: "en" | "ja" | "ko";
|
|
172
|
+
readonly message: string;
|
|
173
|
+
}[]];
|
|
174
|
+
readonly icon?: string | undefined;
|
|
175
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistrySubItemValue | {
|
|
176
|
+
readonly disabled?: string | undefined;
|
|
177
|
+
readonly id: string;
|
|
178
|
+
readonly title: readonly [{
|
|
179
|
+
readonly locale: "zh";
|
|
180
|
+
readonly message: string;
|
|
181
|
+
}, ...{
|
|
182
|
+
readonly locale: "en" | "ja" | "ko";
|
|
183
|
+
readonly message: string;
|
|
184
|
+
}[]];
|
|
185
|
+
readonly icon?: string | undefined;
|
|
186
|
+
readonly hidden?: string | undefined;
|
|
187
|
+
readonly tooltip?: readonly [{
|
|
188
|
+
readonly locale: "zh";
|
|
189
|
+
readonly message: string;
|
|
190
|
+
}, ...{
|
|
191
|
+
readonly locale: "en" | "ja" | "ko";
|
|
192
|
+
readonly message: string;
|
|
193
|
+
}[]] | undefined;
|
|
194
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
195
|
+
readonly action?: any;
|
|
196
|
+
})[];
|
|
197
|
+
readonly groupId: string;
|
|
198
|
+
readonly hideTitle?: boolean | undefined;
|
|
199
|
+
})[];
|
|
200
|
+
readonly groups: readonly {
|
|
201
|
+
readonly id: string;
|
|
202
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
203
|
+
}[];
|
|
204
|
+
} | undefined;
|
|
138
205
|
readonly rowKey?: string | undefined;
|
|
139
206
|
readonly cellStyle?: string | undefined;
|
|
140
207
|
readonly pagination?: {
|
|
@@ -316,6 +383,73 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
316
383
|
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
317
384
|
}[];
|
|
318
385
|
} | undefined;
|
|
386
|
+
readonly bottomActions?: {
|
|
387
|
+
readonly size: "default" | "sm" | "xs";
|
|
388
|
+
readonly style?: string | undefined;
|
|
389
|
+
readonly gap: number;
|
|
390
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistryItemValue | {
|
|
391
|
+
readonly disabled?: string | undefined;
|
|
392
|
+
readonly id: string;
|
|
393
|
+
readonly title: readonly [{
|
|
394
|
+
readonly locale: "zh";
|
|
395
|
+
readonly message: string;
|
|
396
|
+
}, ...{
|
|
397
|
+
readonly locale: "en" | "ja" | "ko";
|
|
398
|
+
readonly message: string;
|
|
399
|
+
}[]];
|
|
400
|
+
readonly icon?: string | undefined;
|
|
401
|
+
readonly hidden?: string | undefined;
|
|
402
|
+
readonly tooltip?: readonly [{
|
|
403
|
+
readonly locale: "zh";
|
|
404
|
+
readonly message: string;
|
|
405
|
+
}, ...{
|
|
406
|
+
readonly locale: "en" | "ja" | "ko";
|
|
407
|
+
readonly message: string;
|
|
408
|
+
}[]] | undefined;
|
|
409
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
410
|
+
readonly action?: any;
|
|
411
|
+
readonly groupId: string;
|
|
412
|
+
readonly hideTitle?: boolean | undefined;
|
|
413
|
+
} | {
|
|
414
|
+
readonly id: string;
|
|
415
|
+
readonly title: readonly [{
|
|
416
|
+
readonly locale: "zh";
|
|
417
|
+
readonly message: string;
|
|
418
|
+
}, ...{
|
|
419
|
+
readonly locale: "en" | "ja" | "ko";
|
|
420
|
+
readonly message: string;
|
|
421
|
+
}[]];
|
|
422
|
+
readonly icon?: string | undefined;
|
|
423
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistrySubItemValue | {
|
|
424
|
+
readonly disabled?: string | undefined;
|
|
425
|
+
readonly id: string;
|
|
426
|
+
readonly title: readonly [{
|
|
427
|
+
readonly locale: "zh";
|
|
428
|
+
readonly message: string;
|
|
429
|
+
}, ...{
|
|
430
|
+
readonly locale: "en" | "ja" | "ko";
|
|
431
|
+
readonly message: string;
|
|
432
|
+
}[]];
|
|
433
|
+
readonly icon?: string | undefined;
|
|
434
|
+
readonly hidden?: string | undefined;
|
|
435
|
+
readonly tooltip?: readonly [{
|
|
436
|
+
readonly locale: "zh";
|
|
437
|
+
readonly message: string;
|
|
438
|
+
}, ...{
|
|
439
|
+
readonly locale: "en" | "ja" | "ko";
|
|
440
|
+
readonly message: string;
|
|
441
|
+
}[]] | undefined;
|
|
442
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
443
|
+
readonly action?: any;
|
|
444
|
+
})[];
|
|
445
|
+
readonly groupId: string;
|
|
446
|
+
readonly hideTitle?: boolean | undefined;
|
|
447
|
+
})[];
|
|
448
|
+
readonly groups: readonly {
|
|
449
|
+
readonly id: string;
|
|
450
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
451
|
+
}[];
|
|
452
|
+
} | undefined;
|
|
319
453
|
readonly rowKey?: string | undefined;
|
|
320
454
|
readonly cellStyle?: string | undefined;
|
|
321
455
|
readonly pagination?: {
|
package/dist/runtime/components/config/blocks/2026-05-06/com.shwfed.block.table/config.vue.d.ts
CHANGED
|
@@ -135,6 +135,73 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
135
135
|
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
136
136
|
}[];
|
|
137
137
|
} | undefined;
|
|
138
|
+
readonly bottomActions?: {
|
|
139
|
+
readonly size: "default" | "sm" | "xs";
|
|
140
|
+
readonly style?: string | undefined;
|
|
141
|
+
readonly gap: number;
|
|
142
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistryItemValue | {
|
|
143
|
+
readonly disabled?: string | undefined;
|
|
144
|
+
readonly id: string;
|
|
145
|
+
readonly title: readonly [{
|
|
146
|
+
readonly locale: "zh";
|
|
147
|
+
readonly message: string;
|
|
148
|
+
}, ...{
|
|
149
|
+
readonly locale: "en" | "ja" | "ko";
|
|
150
|
+
readonly message: string;
|
|
151
|
+
}[]];
|
|
152
|
+
readonly icon?: string | undefined;
|
|
153
|
+
readonly hidden?: string | undefined;
|
|
154
|
+
readonly tooltip?: readonly [{
|
|
155
|
+
readonly locale: "zh";
|
|
156
|
+
readonly message: string;
|
|
157
|
+
}, ...{
|
|
158
|
+
readonly locale: "en" | "ja" | "ko";
|
|
159
|
+
readonly message: string;
|
|
160
|
+
}[]] | undefined;
|
|
161
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
162
|
+
readonly action?: any;
|
|
163
|
+
readonly groupId: string;
|
|
164
|
+
readonly hideTitle?: boolean | undefined;
|
|
165
|
+
} | {
|
|
166
|
+
readonly id: string;
|
|
167
|
+
readonly title: readonly [{
|
|
168
|
+
readonly locale: "zh";
|
|
169
|
+
readonly message: string;
|
|
170
|
+
}, ...{
|
|
171
|
+
readonly locale: "en" | "ja" | "ko";
|
|
172
|
+
readonly message: string;
|
|
173
|
+
}[]];
|
|
174
|
+
readonly icon?: string | undefined;
|
|
175
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistrySubItemValue | {
|
|
176
|
+
readonly disabled?: string | undefined;
|
|
177
|
+
readonly id: string;
|
|
178
|
+
readonly title: readonly [{
|
|
179
|
+
readonly locale: "zh";
|
|
180
|
+
readonly message: string;
|
|
181
|
+
}, ...{
|
|
182
|
+
readonly locale: "en" | "ja" | "ko";
|
|
183
|
+
readonly message: string;
|
|
184
|
+
}[]];
|
|
185
|
+
readonly icon?: string | undefined;
|
|
186
|
+
readonly hidden?: string | undefined;
|
|
187
|
+
readonly tooltip?: readonly [{
|
|
188
|
+
readonly locale: "zh";
|
|
189
|
+
readonly message: string;
|
|
190
|
+
}, ...{
|
|
191
|
+
readonly locale: "en" | "ja" | "ko";
|
|
192
|
+
readonly message: string;
|
|
193
|
+
}[]] | undefined;
|
|
194
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
195
|
+
readonly action?: any;
|
|
196
|
+
})[];
|
|
197
|
+
readonly groupId: string;
|
|
198
|
+
readonly hideTitle?: boolean | undefined;
|
|
199
|
+
})[];
|
|
200
|
+
readonly groups: readonly {
|
|
201
|
+
readonly id: string;
|
|
202
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
203
|
+
}[];
|
|
204
|
+
} | undefined;
|
|
138
205
|
readonly rowKey?: string | undefined;
|
|
139
206
|
readonly cellStyle?: string | undefined;
|
|
140
207
|
readonly pagination?: {
|
|
@@ -316,6 +383,73 @@ declare const __VLS_export: import("vue").DefineComponent<__VLS_PublicProps, {},
|
|
|
316
383
|
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
317
384
|
}[];
|
|
318
385
|
} | undefined;
|
|
386
|
+
readonly bottomActions?: {
|
|
387
|
+
readonly size: "default" | "sm" | "xs";
|
|
388
|
+
readonly style?: string | undefined;
|
|
389
|
+
readonly gap: number;
|
|
390
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistryItemValue | {
|
|
391
|
+
readonly disabled?: string | undefined;
|
|
392
|
+
readonly id: string;
|
|
393
|
+
readonly title: readonly [{
|
|
394
|
+
readonly locale: "zh";
|
|
395
|
+
readonly message: string;
|
|
396
|
+
}, ...{
|
|
397
|
+
readonly locale: "en" | "ja" | "ko";
|
|
398
|
+
readonly message: string;
|
|
399
|
+
}[]];
|
|
400
|
+
readonly icon?: string | undefined;
|
|
401
|
+
readonly hidden?: string | undefined;
|
|
402
|
+
readonly tooltip?: readonly [{
|
|
403
|
+
readonly locale: "zh";
|
|
404
|
+
readonly message: string;
|
|
405
|
+
}, ...{
|
|
406
|
+
readonly locale: "en" | "ja" | "ko";
|
|
407
|
+
readonly message: string;
|
|
408
|
+
}[]] | undefined;
|
|
409
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
410
|
+
readonly action?: any;
|
|
411
|
+
readonly groupId: string;
|
|
412
|
+
readonly hideTitle?: boolean | undefined;
|
|
413
|
+
} | {
|
|
414
|
+
readonly id: string;
|
|
415
|
+
readonly title: readonly [{
|
|
416
|
+
readonly locale: "zh";
|
|
417
|
+
readonly message: string;
|
|
418
|
+
}, ...{
|
|
419
|
+
readonly locale: "en" | "ja" | "ko";
|
|
420
|
+
readonly message: string;
|
|
421
|
+
}[]];
|
|
422
|
+
readonly icon?: string | undefined;
|
|
423
|
+
readonly items: readonly (import("../../../../actions/schema.js").RegistrySubItemValue | {
|
|
424
|
+
readonly disabled?: string | undefined;
|
|
425
|
+
readonly id: string;
|
|
426
|
+
readonly title: readonly [{
|
|
427
|
+
readonly locale: "zh";
|
|
428
|
+
readonly message: string;
|
|
429
|
+
}, ...{
|
|
430
|
+
readonly locale: "en" | "ja" | "ko";
|
|
431
|
+
readonly message: string;
|
|
432
|
+
}[]];
|
|
433
|
+
readonly icon?: string | undefined;
|
|
434
|
+
readonly hidden?: string | undefined;
|
|
435
|
+
readonly tooltip?: readonly [{
|
|
436
|
+
readonly locale: "zh";
|
|
437
|
+
readonly message: string;
|
|
438
|
+
}, ...{
|
|
439
|
+
readonly locale: "en" | "ja" | "ko";
|
|
440
|
+
readonly message: string;
|
|
441
|
+
}[]] | undefined;
|
|
442
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
443
|
+
readonly action?: any;
|
|
444
|
+
})[];
|
|
445
|
+
readonly groupId: string;
|
|
446
|
+
readonly hideTitle?: boolean | undefined;
|
|
447
|
+
})[];
|
|
448
|
+
readonly groups: readonly {
|
|
449
|
+
readonly id: string;
|
|
450
|
+
readonly variant?: "default" | "link" | "destructive" | "primary" | "ghost" | undefined;
|
|
451
|
+
}[];
|
|
452
|
+
} | undefined;
|
|
319
453
|
readonly rowKey?: string | undefined;
|
|
320
454
|
readonly cellStyle?: string | undefined;
|
|
321
455
|
readonly pagination?: {
|