@robot-admin/naive-ui-components 0.23.0 → 0.23.1
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/CHANGELOG.md +6 -0
- package/README.md +1 -1
- package/README_EN.md +1 -1
- package/dist/C_DataPicker.css +1 -0
- package/dist/C_SplitPane2.cjs +1 -1
- package/dist/C_SplitPane2.js +1 -1
- package/dist/constants.d.cts +3 -3
- package/dist/constants.d.ts +3 -3
- package/dist/constants2.d.cts +6 -6
- package/dist/constants2.d.ts +6 -6
- package/dist/constants3.d.cts +1 -1
- package/dist/constants3.d.ts +1 -1
- package/dist/constants4.d.cts +3 -3
- package/dist/constants4.d.ts +3 -3
- package/dist/constants5.d.cts +2 -2
- package/dist/constants5.d.ts +2 -2
- package/dist/data2.d.cts +9 -9
- package/dist/data2.d.ts +9 -9
- package/dist/index.vue.d.cts +4 -4
- package/dist/index.vue.d.ts +4 -4
- package/dist/index10.vue.d.cts +2 -2
- package/dist/index10.vue.d.ts +6 -6
- package/dist/index11.vue.d.cts +6 -6
- package/dist/index11.vue.d.ts +2 -2
- package/dist/index12.vue.d.cts +2 -2
- package/dist/index13.vue.d.ts +5 -5
- package/dist/index14.vue.d.cts +5 -5
- package/dist/index15.vue.d.ts +7 -7
- package/dist/index16.vue.d.cts +7 -7
- package/dist/index16.vue.d.ts +1 -1
- package/dist/index17.vue.d.cts +1 -1
- package/dist/index17.vue.d.ts +1 -1
- package/dist/index18.vue.d.cts +1 -1
- package/dist/index18.vue.d.ts +2 -2
- package/dist/index19.vue.d.cts +2 -2
- package/dist/index19.vue.d.ts +2 -2
- package/dist/index2.vue.d.cts +2 -2
- package/dist/index2.vue.d.ts +2 -2
- package/dist/index20.vue.d.cts +2 -2
- package/dist/index21.vue.d.ts +3 -3
- package/dist/index22.vue.d.cts +3 -3
- package/dist/index22.vue.d.ts +4 -4
- package/dist/index23.vue.d.cts +4 -4
- package/dist/index23.vue.d.ts +3 -3
- package/dist/index25.vue.d.cts +1 -1
- package/dist/index25.vue.d.ts +1 -1
- package/dist/index26.vue.d.cts +3 -3
- package/dist/index26.vue.d.ts +3 -3
- package/dist/index27.vue.d.cts +2 -2
- package/dist/index27.vue.d.ts +2 -2
- package/dist/index28.vue.d.cts +1 -1
- package/dist/index28.vue.d.ts +1 -1
- package/dist/index29.vue.d.cts +3 -3
- package/dist/index29.vue.d.ts +3 -3
- package/dist/index3.vue.d.cts +5 -5
- package/dist/index3.vue.d.ts +5 -5
- package/dist/index30.vue.d.cts +2 -2
- package/dist/index30.vue.d.ts +2 -2
- package/dist/index5.vue.d.cts +3 -3
- package/dist/index6.vue.d.ts +2 -2
- package/dist/index7.vue.d.cts +2 -2
- package/dist/index7.vue.d.ts +2 -2
- package/dist/index8.vue.d.cts +2 -2
- package/dist/index8.vue.d.ts +2 -2
- package/dist/index9.vue.d.cts +2 -2
- package/dist/index9.vue.d.ts +2 -2
- package/dist/mapUtils.d.cts +4 -4
- package/dist/mapUtils.d.ts +4 -4
- package/dist/presets.d.cts +1 -1
- package/dist/presets.d.ts +1 -1
- package/dist/style.css +1 -0
- package/dist/useCollapsePanel.d.cts +5 -5
- package/dist/useCollapsePanel.d.ts +5 -5
- package/dist/useCropperCore.d.cts +12 -12
- package/dist/useCropperCore.d.ts +12 -12
- package/dist/useDynamicFormState.d.cts +9 -9
- package/dist/useDynamicFormState.d.ts +9 -9
- package/dist/useEdgeInteraction.d.cts +3 -3
- package/dist/useEdgeInteraction.d.ts +3 -3
- package/dist/useInfiniteScroll.d.cts +3 -3
- package/dist/useInfiniteScroll.d.ts +3 -3
- package/dist/useQRCode.d.cts +3 -3
- package/dist/useQRCode.d.ts +3 -3
- package/dist/useSignatureHistory.d.cts +4 -4
- package/dist/useSignatureHistory.d.ts +4 -4
- package/dist/useSplitResize.d.cts +7 -7
- package/dist/useSplitResize.d.ts +7 -7
- package/dist/useWorkflowValidation.d.cts +7 -7
- package/dist/useWorkflowValidation.d.ts +7 -7
- package/dist/verification.d.cts +2 -2
- package/dist/verification.d.ts +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
| 按需消费 | 60 个独立组件入口、自动导入 Resolver、组件样式入口,以及表单/表格的基础样式层级 |
|
|
34
34
|
| 独立接入 | 支持全量注册与局部导入;反馈、文案和全局配置可由宿主提供,表单弹窗可接入结构兼容的 Headless CRUD |
|
|
35
35
|
|
|
36
|
-
组件库负责界面与交互;业务接口、身份权限、上传服务和第三方平台配置由应用接入。当前仓库版本 **0.23.
|
|
36
|
+
组件库负责界面与交互;业务接口、身份权限、上传服务和第三方平台配置由应用接入。当前仓库版本 **0.23.1**,版本变化见 [CHANGELOG](./CHANGELOG.md)。
|
|
37
37
|
|
|
38
38
|
表单与搜索共用 `config.density: 'compact'`:收紧字段、布局和空校验区,实际错误仍自然展开。表单弹窗默认紧凑,页脚按钮 22px;搜索可继承应用密度。紧凑数字输入默认隐藏步进按钮,保留键盘、精度和上下限,也可逐字段开启。按需设置默认值与显式覆盖见[表单密度](./docs/guides/form-density.md)。
|
|
39
39
|
|
package/README_EN.md
CHANGED
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
| Selective loading | 60 component entries, an auto-import resolver, component CSS and base styles for forms and tables |
|
|
34
34
|
| Application integration | Global registration or local imports; injectable feedback, locale and defaults; form dialogs compatible with structurally matching headless CRUD controllers |
|
|
35
35
|
|
|
36
|
-
The library handles UI and interaction. Applications supply business APIs, authentication, authorization, upload services and platform configuration. The current repository version is **0.23.
|
|
36
|
+
The library handles UI and interaction. Applications supply business APIs, authentication, authorization, upload services and platform configuration. The current repository version is **0.23.1**; see the [changelog](./CHANGELOG.md) for release details.
|
|
37
37
|
|
|
38
38
|
Forms and search share `config.density: 'compact'`, reducing field spacing and empty validation space while allowing errors to expand naturally. Form modals default to compact density with 22px footer buttons, and search can inherit application density. Compact numeric fields hide step buttons by default while retaining keyboard interaction, precision and limits; individual fields can enable buttons. See [form density](./docs/guides/form-density.en.md) for on-demand defaults and explicit overrides.
|
|
39
39
|
|
package/dist/C_DataPicker.css
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
@import "./C_Table.base.css";
|
|
2
2
|
.c-data-picker[data-v-30310910] {
|
|
3
|
+
width: 100%;
|
|
3
4
|
min-width: 0;
|
|
4
5
|
}
|
|
5
6
|
.c-data-picker__trigger[data-v-30310910], .c-data-picker__search[data-v-30310910], .c-data-picker__actions[data-v-30310910], .c-data-picker__selection[data-v-30310910] {
|
package/dist/C_SplitPane2.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
require(`./chunk.cjs`);const e=require(`./useComponentLocale.cjs`),t=require(`./export-helper.cjs`);let n=require(`vue`);const r=(e,t)=>typeof e==`number`&&Number.isFinite(e)?e:t,i=e=>Math.max(4,r(e,6));function a(e){let t=Math.max(0,Math.min(100,r(e.minSize,0))),n=Math.max(0,Math.min(100,r(e.maxSize,100))),i=Math.min(t,n),a=Math.max(t,n),o=Math.max(0,r(e.availableLength,0));if(!o)return{min:i,max:a};let s=Math.max(0,r(e.minFirstSize,0)),c=Math.max(0,r(e.minSecondSize,0)),l=Math.max(i,s/o*100),u=Math.min(a,100-c/o*100);if(l<=u)return{min:l,max:u};let d=s+c?s/(s+c)*100:50,f=Math.max(i,Math.min(a,d));return{min:f,max:f}}function o(e,t,n){return Math.min(n,Math.max(t,r(e,50)))}const s=new WeakMap;function c(e){return`button`in e&&e.button!==0?!1:!(`isPrimary`in e)||e.isPrimary}function l(e,t,n){if(!(`touches`in e))return t===`horizontal`?e.clientX:e.clientY;let r=n===void 0?e.touches[0]:Array.from(e.touches).find(e=>e.identifier===n);if(r)return t===`horizontal`?r.clientX:r.clientY}function u(e,t){return t===void 0||!(`pointerId`in e)?!0:e.pointerId===t}function d(e,t){let{style:n}=e.body,r=t===`horizontal`?`col-resize`:`row-resize`,i=[`cursor`,`user-select`].map(e=>({name:e,value:n.getPropertyValue(e),priority:n.getPropertyPriority(e),owned:e===`cursor`?r:`none`}));for(let e of i)n.setProperty(e.name,e.owned);return()=>{for(let e of i)n.getPropertyValue(e.name)===e.owned&&(e.value?n.setProperty(e.name,e.value,e.priority):n.removeProperty(e.name))}}function f(e){return`pointerId`in e?{move:[`pointermove`],end:[`pointerup`,`pointercancel`]}:`touches`in e?{move:[`touchmove`],end:[`touchend`,`touchcancel`]}:{move:[`mousemove`],end:[`mouseup`]}}function p(e,t){let n=l(e,t.direction);if(n===void 0)return;let r=t.element.ownerDocument,i=r.defaultView;s.get(r)?.();let a=d(r,t.direction),o=`pointerId`in e?e.pointerId:void 0,c=`touches`in e?e.touches[0]?.identifier:void 0,p=!0;e.preventDefault(),e.stopPropagation(),e.currentTarget?.focus();let m=e=>{if(!u(e,o))return;let r=l(e,t.direction,c);r!==void 0&&(e.cancelable&&e.preventDefault(),t.onDelta(r-n))},h=e=>{if(!(e&&!u(e,o))&&p){p=!1,a();for(let[e,t]of v)r.removeEventListener(e,t);i?.removeEventListener(`blur`,h),s.get(r)===h&&s.delete(r),t.onEnd()}},g=()=>{r.hidden&&h()},_=f(e),v=[..._.move.map(e=>[e,m]),..._.end.map(e=>[e,h]),[`visibilitychange`,g]];for(let[e,t]of v)r.addEventListener(e,t,{passive:!1});return i?.addEventListener(`blur`,h),s.set(r,h),h}function m(e){return e===0?`first`:e===100?`second`:null}function h(e,t,n,r,i){if(e===`Home`)return i.min;if(e===`End`)return i.max;let a=t===`horizontal`?`ArrowLeft`:`ArrowUp`,o=t===`horizontal`?`ArrowRight`:`ArrowDown`;if(e===a)return r-n;if(e===o)return r+n}function g(e){let{containerRef:t,direction:s,disabled:l,collapsible:u}=e,d=(0,n.ref)(0),f=(0,n.computed)(()=>i((0,n.toValue)(e.gutterSize))),g=(0,n.computed)(()=>Math.max(0,d.value-f.value)),_=(0,n.computed)(()=>a({minSize:(0,n.toValue)(e.minSize),maxSize:(0,n.toValue)(e.maxSize),minFirstSize:(0,n.toValue)(e.minFirstSize)??0,minSecondSize:(0,n.toValue)(e.minSecondSize)??0,availableLength:g.value})),v=(0,n.ref)(o((0,n.toValue)(e.defaultSize),_.value.min,_.value.max)),y=(0,n.computed)(()=>(0,n.toValue)(e.size)!==void 0),b=(0,n.computed)(()=>y.value?r((0,n.toValue)(e.size),50):v.value),x=(0,n.computed)(()=>u.value?b.value===0?`first`:b.value===100?`second`:null:null),S=(0,n.computed)(()=>x.value?x.value===`first`?0:100:o(b.value,_.value.min,_.value.max)),C=(0,n.ref)(!1),w=(0,n.computed)(()=>x.value===`first`),T=(0,n.computed)(()=>x.value===`second`),E=r((0,n.toValue)(e.defaultSize),50),D=x.value?o(E>0&&E<100?E:50,_.value.min,_.value.max):S.value,O,k,A=(t,n=!1)=>{if(!Number.isFinite(t))return;let r=n?t:o(t,_.value.min,_.value.max);r!==b.value&&(y.value||(v.value=r),e.onUpdateSize?.(r))};(0,n.watch)(S,(t,n)=>{let r=m(n),i=x.value;!r&&i&&(D=n),r&&r!==i&&e.onExpand?.(r),i&&i!==r&&e.onCollapse?.(i),e.onResize?.(t,100-t)},{flush:`sync`}),(0,n.watch)(_,()=>{x.value||A(S.value)},{flush:`sync`}),(0,n.watch)([l,s],()=>O?.(),{flush:`sync`}),(0,n.watch)(u,()=>{x.value||A(S.value)},{flush:`sync`});let j=()=>{let e=t.value;if(!e)return;let n=e.getBoundingClientRect();d.value=s.value===`horizontal`?n.width:n.height};(0,n.watch)(s,j,{flush:`post`}),(0,n.onMounted)(()=>{j(),typeof ResizeObserver<`u`&&t.value&&(k=new ResizeObserver(j),k.observe(t.value))});let M=(e=`first`)=>{!u.value||x.value===e||(x.value||(D=S.value),A(e===`first`?0:100,!0))},N=()=>{x.value&&A(D)},P=(e=`first`)=>{x.value===e?N():M(e)};return(0,n.onUnmounted)(()=>{O?.(),k?.disconnect()}),{panelSize:S,isDragging:C,collapsedTarget:x,isFirstCollapsed:w,isSecondCollapsed:T,bounds:_,gutterSize:f,handleMouseDown:n=>{if(l.value||C.value||!c(n))return;let r=t.value;if(!r||(j(),!g.value))return;let i=S.value;O=p(n,{element:r,direction:s.value,onDelta:e=>A(i+e/g.value*100),onEnd:()=>{C.value=!1,O=void 0,e.onDragEnd?.(S.value)}}),O&&(C.value=!0,e.onDragStart?.(S.value))},handleDoubleClick:()=>{l.value||P(`first`)},handleKeyDown:t=>{if(l.value||t.target!==t.currentTarget)return;if(t.key===`Enter`){u.value&&(t.preventDefault(),x.value?N():M(`first`));return}let i=Math.max(0,r((0,n.toValue)(e.step),2))||2,a=t.shiftKey?10:1,o=h(t.key,s.value,i*a,S.value,_.value);o!==void 0&&(t.preventDefault(),A(o))},collapse:M,expand:N,toggle:P,resetSize:()=>A(r((0,n.toValue)(e.defaultSize),50)),setSize:e=>A(e),getPanelInfo:()=>({first:{size:S.value,collapsed:w.value},second:{size:100-S.value,collapsed:T.value}})}}const _=[`aria-hidden`,`inert`],v={class:`split-panel__content`},y=[`aria-orientation`,`aria-valuenow`,`aria-valuemin`,`aria-valuemax`,`aria-disabled`,`aria-label`,`tabindex`],b=[`disabled`,`aria-label`,`aria-expanded`,`title`],x={class:`split-gutter__visual`,"aria-hidden":`true`},S={class:`split-gutter__dots`},C=[`disabled`,`aria-label`,`aria-expanded`,`title`],w=[`aria-hidden`,`inert`],T={class:`split-panel__content`},E=(0,n.defineComponent)({name:`C_SplitPane`,__name:`index`,props:{ariaLabel:{},direction:{default:`horizontal`},size:{},defaultSize:{default:50},minSize:{default:0},maxSize:{default:100},minFirstSize:{default:0},minSecondSize:{default:0},disabled:{type:Boolean,default:!1},collapsible:{type:Boolean,default:!0},showCollapseButton:{type:Boolean,default:!0},gutterSize:{default:6},step:{default:2}},emits:[`update:size`,`resize`,`collapse`,`expand`,`drag-start`,`drag-end`],setup(t,{expose:r,emit:i}){let{t:a}=e.t(),o=t,s=i,c=(0,n.useId)(),l=`split-${c}-first`,u=`split-${c}-second`,d=(0,n.ref)(null),{panelSize:f,bounds:p,gutterSize:m,isDragging:h,isFirstCollapsed:E,isSecondCollapsed:D,handleMouseDown:O,handleDoubleClick:k,handleKeyDown:A,collapse:j,expand:M,toggle:N,resetSize:P,setSize:F,getPanelInfo:I}=g({containerRef:d,direction:(0,n.toRef)(o,`direction`),size:(0,n.toRef)(o,`size`),defaultSize:(0,n.toRef)(o,`defaultSize`),minSize:(0,n.toRef)(o,`minSize`),maxSize:(0,n.toRef)(o,`maxSize`),minFirstSize:(0,n.toRef)(o,`minFirstSize`),minSecondSize:(0,n.toRef)(o,`minSecondSize`),gutterSize:(0,n.toRef)(o,`gutterSize`),disabled:(0,n.toRef)(o,`disabled`),collapsible:(0,n.toRef)(o,`collapsible`),step:(0,n.toRef)(o,`step`),onUpdateSize:e=>s(`update:size`,e),onResize:(e,t)=>s(`resize`,e,t),onCollapse:e=>s(`collapse`,e),onExpand:e=>s(`expand`,e),onDragStart:e=>s(`drag-start`,e),onDragEnd:e=>s(`drag-end`,e)}),L=(0,n.computed)(()=>({flex:`${f.value} 1 0px`})),R=(0,n.computed)(()=>({flex:`${100-f.value} 1 0px`})),z=(0,n.computed)(()=>o.direction===`horizontal`?{width:`${m.value}px`}:{height:`${m.value}px`});return r({collapse:j,expand:M,toggle:N,resetSize:P,getPanelInfo:I,setSize:F}),(e,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,{ref_key:`containerRef`,ref:d,class:(0,n.normalizeClass)([`c-split-pane`,[`c-split-pane--${t.direction}`,{"c-split-pane--dragging":(0,n.unref)(h),"c-split-pane--disabled":t.disabled,"c-split-pane--collapsed-first":(0,n.unref)(E),"c-split-pane--collapsed-second":(0,n.unref)(D)}]])},[(0,n.createCommentVNode)(` 首面板 `),(0,n.createElementVNode)(`div`,{class:`split-panel split-panel--first`,id:l,style:(0,n.normalizeStyle)(L.value),"aria-hidden":(0,n.unref)(E)||void 0,inert:(0,n.unref)(E)},[(0,n.createElementVNode)(`div`,v,[(0,n.renderSlot)(e.$slots,`first`,{size:(0,n.unref)(f),collapsed:(0,n.unref)(E)},void 0,!0)])],12,_),(0,n.createCommentVNode)(` 分割线手柄 `),(0,n.createElementVNode)(`div`,{class:`split-gutter`,style:(0,n.normalizeStyle)(z.value),role:`separator`,"aria-orientation":t.direction===`horizontal`?`vertical`:`horizontal`,"aria-valuenow":(0,n.unref)(f),"aria-valuemin":(0,n.unref)(E)?0:(0,n.unref)(p).min,"aria-valuemax":(0,n.unref)(D)?100:(0,n.unref)(p).max,"aria-disabled":t.disabled||void 0,"aria-controls":l,"aria-label":t.ariaLabel??(0,n.unref)(a)(`split.resize`),tabindex:t.disabled?-1:0,onPointerdown:r[6]||=(...e)=>(0,n.unref)(O)&&(0,n.unref)(O)(...e),onDblclick:r[7]||=(...e)=>(0,n.unref)(k)&&(0,n.unref)(k)(...e),onKeydown:r[8]||=(...e)=>(0,n.unref)(A)&&(0,n.unref)(A)(...e)},[(0,n.createElementVNode)(`div`,{class:(0,n.normalizeClass)([`split-gutter__controls`,{"split-gutter__controls--with-collapse":t.showCollapseButton&&t.collapsible}])},[t.showCollapseButton&&t.collapsible?((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:0,class:`split-gutter__collapse-btn split-gutter__collapse-btn--first`,type:`button`,disabled:t.disabled,"aria-label":(0,n.unref)(E)?(0,n.unref)(a)(`split.expandFirst`):(0,n.unref)(a)(`split.collapseFirst`),"aria-expanded":!(0,n.unref)(E),"aria-controls":l,title:(0,n.unref)(E)?(0,n.unref)(a)(`split.expandFirst`):(0,n.unref)(a)(`split.collapseFirst`),onClick:r[0]||=(0,n.withModifiers)(e=>(0,n.unref)(N)(`first`),[`stop`]),onPointerdown:r[1]||=(0,n.withModifiers)(()=>{},[`stop`]),onDblclick:r[2]||=(0,n.withModifiers)(()=>{},[`stop`])},[...r[9]||=[(0,n.createElementVNode)(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[(0,n.createElementVNode)(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,b)):(0,n.createCommentVNode)(`v-if`,!0),(0,n.createElementVNode)(`div`,x,[(0,n.createElementVNode)(`div`,S,[((0,n.openBlock)(),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(3,e=>(0,n.createElementVNode)(`span`,{key:e,class:`split-gutter__dot`})),64))])]),t.showCollapseButton&&t.collapsible?((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:1,class:`split-gutter__collapse-btn split-gutter__collapse-btn--second`,type:`button`,disabled:t.disabled,"aria-label":(0,n.unref)(D)?(0,n.unref)(a)(`split.expandSecond`):(0,n.unref)(a)(`split.collapseSecond`),"aria-expanded":!(0,n.unref)(D),"aria-controls":u,title:(0,n.unref)(D)?(0,n.unref)(a)(`split.expandSecond`):(0,n.unref)(a)(`split.collapseSecond`),onClick:r[3]||=(0,n.withModifiers)(e=>(0,n.unref)(N)(`second`),[`stop`]),onPointerdown:r[4]||=(0,n.withModifiers)(()=>{},[`stop`]),onDblclick:r[5]||=(0,n.withModifiers)(()=>{},[`stop`])},[...r[10]||=[(0,n.createElementVNode)(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[(0,n.createElementVNode)(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,C)):(0,n.createCommentVNode)(`v-if`,!0)],2)],44,y),(0,n.createCommentVNode)(` 第二面板 `),(0,n.createElementVNode)(`div`,{class:`split-panel split-panel--second`,id:u,style:(0,n.normalizeStyle)(R.value),"aria-hidden":(0,n.unref)(D)||void 0,inert:(0,n.unref)(D)},[(0,n.createElementVNode)(`div`,T,[(0,n.renderSlot)(e.$slots,`second`,{size:100-(0,n.unref)(f),collapsed:(0,n.unref)(D)},void 0,!0)])],12,w)],2))}});var D=t.t(E,[[`__scopeId`,`data-v-265c2994`]]);Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return D}});
|
|
1
|
+
require(`./chunk.cjs`);const e=require(`./useComponentLocale.cjs`),t=require(`./export-helper.cjs`);let n=require(`vue`);const r=(e,t)=>typeof e==`number`&&Number.isFinite(e)?e:t,i=e=>Math.max(4,r(e,6));function a(e){let t=Math.max(0,Math.min(100,r(e.minSize,0))),n=Math.max(0,Math.min(100,r(e.maxSize,100))),i=Math.min(t,n),a=Math.max(t,n),o=Math.max(0,r(e.availableLength,0));if(!o)return{min:i,max:a};let s=Math.max(0,r(e.minFirstSize,0)),c=Math.max(0,r(e.minSecondSize,0)),l=Math.max(i,s/o*100),u=Math.min(a,100-c/o*100);if(l<=u)return{min:l,max:u};let d=s+c?s/(s+c)*100:50,f=Math.max(i,Math.min(a,d));return{min:f,max:f}}function o(e,t,n){return Math.min(n,Math.max(t,r(e,50)))}const s=new WeakMap;function c(e){return`button`in e&&e.button!==0?!1:!(`isPrimary`in e)||e.isPrimary}function l(e,t,n){if(!(`touches`in e))return t===`horizontal`?e.clientX:e.clientY;let r=n===void 0?e.touches[0]:Array.from(e.touches).find(e=>e.identifier===n);if(r)return t===`horizontal`?r.clientX:r.clientY}function u(e,t){return t===void 0||!(`pointerId`in e)?!0:e.pointerId===t}function d(e,t){let{style:n}=e.body,r=t===`horizontal`?`col-resize`:`row-resize`,i=[`cursor`,`user-select`].map(e=>({name:e,value:n.getPropertyValue(e),priority:n.getPropertyPriority(e),owned:e===`cursor`?r:`none`}));for(let e of i)n.setProperty(e.name,e.owned);return()=>{for(let e of i)n.getPropertyValue(e.name)===e.owned&&(e.value?n.setProperty(e.name,e.value,e.priority):n.removeProperty(e.name))}}function f(e){return`pointerId`in e?{move:[`pointermove`],end:[`pointerup`,`pointercancel`]}:`touches`in e?{move:[`touchmove`],end:[`touchend`,`touchcancel`]}:{move:[`mousemove`],end:[`mouseup`]}}function p(e,t){let n=l(e,t.direction);if(n===void 0)return;let r=t.element.ownerDocument,i=r.defaultView;s.get(r)?.();let a=d(r,t.direction),o=`pointerId`in e?e.pointerId:void 0,c=`touches`in e?e.touches[0]?.identifier:void 0,p=!0;e.preventDefault(),e.stopPropagation(),e.currentTarget?.focus({preventScroll:!0});let m=e=>{if(!u(e,o))return;let r=l(e,t.direction,c);r!==void 0&&(e.cancelable&&e.preventDefault(),t.onDelta(r-n))},h=e=>{if(!(e&&!u(e,o))&&p){p=!1,a();for(let[e,t]of v)r.removeEventListener(e,t);i?.removeEventListener(`blur`,h),s.get(r)===h&&s.delete(r),t.onEnd()}},g=()=>{r.hidden&&h()},_=f(e),v=[..._.move.map(e=>[e,m]),..._.end.map(e=>[e,h]),[`visibilitychange`,g]];for(let[e,t]of v)r.addEventListener(e,t,{passive:!1});return i?.addEventListener(`blur`,h),s.set(r,h),h}function m(e){return e===0?`first`:e===100?`second`:null}function h(e,t,n,r,i){if(e===`Home`)return i.min;if(e===`End`)return i.max;let a=t===`horizontal`?`ArrowLeft`:`ArrowUp`,o=t===`horizontal`?`ArrowRight`:`ArrowDown`;if(e===a)return r-n;if(e===o)return r+n}function g(e){let{containerRef:t,direction:s,disabled:l,collapsible:u}=e,d=(0,n.ref)(0),f=(0,n.computed)(()=>i((0,n.toValue)(e.gutterSize))),g=(0,n.computed)(()=>Math.max(0,d.value-f.value)),_=(0,n.computed)(()=>a({minSize:(0,n.toValue)(e.minSize),maxSize:(0,n.toValue)(e.maxSize),minFirstSize:(0,n.toValue)(e.minFirstSize)??0,minSecondSize:(0,n.toValue)(e.minSecondSize)??0,availableLength:g.value})),v=(0,n.ref)(o((0,n.toValue)(e.defaultSize),_.value.min,_.value.max)),y=(0,n.computed)(()=>(0,n.toValue)(e.size)!==void 0),b=(0,n.computed)(()=>y.value?r((0,n.toValue)(e.size),50):v.value),x=(0,n.computed)(()=>u.value?b.value===0?`first`:b.value===100?`second`:null:null),S=(0,n.computed)(()=>x.value?x.value===`first`?0:100:o(b.value,_.value.min,_.value.max)),C=(0,n.ref)(!1),w=(0,n.computed)(()=>x.value===`first`),T=(0,n.computed)(()=>x.value===`second`),E=r((0,n.toValue)(e.defaultSize),50),D=x.value?o(E>0&&E<100?E:50,_.value.min,_.value.max):S.value,O,k,A=(t,n=!1)=>{if(!Number.isFinite(t))return;let r=n?t:o(t,_.value.min,_.value.max);r!==b.value&&(y.value||(v.value=r),e.onUpdateSize?.(r))};(0,n.watch)(S,(t,n)=>{let r=m(n),i=x.value;!r&&i&&(D=n),r&&r!==i&&e.onExpand?.(r),i&&i!==r&&e.onCollapse?.(i),e.onResize?.(t,100-t)},{flush:`sync`}),(0,n.watch)(_,()=>{x.value||A(S.value)},{flush:`sync`}),(0,n.watch)([l,s],()=>O?.(),{flush:`sync`}),(0,n.watch)(u,()=>{x.value||A(S.value)},{flush:`sync`});let j=()=>{let e=t.value;if(!e)return;let n=e.getBoundingClientRect();d.value=s.value===`horizontal`?n.width:n.height};(0,n.watch)(s,j,{flush:`post`}),(0,n.onMounted)(()=>{j(),typeof ResizeObserver<`u`&&t.value&&(k=new ResizeObserver(j),k.observe(t.value))});let M=(e=`first`)=>{!u.value||x.value===e||(x.value||(D=S.value),A(e===`first`?0:100,!0))},N=()=>{x.value&&A(D)},P=(e=`first`)=>{x.value===e?N():M(e)};return(0,n.onUnmounted)(()=>{O?.(),k?.disconnect()}),{panelSize:S,isDragging:C,collapsedTarget:x,isFirstCollapsed:w,isSecondCollapsed:T,bounds:_,gutterSize:f,handleMouseDown:n=>{if(l.value||C.value||!c(n))return;let r=t.value;if(!r||(j(),!g.value))return;let i=S.value;O=p(n,{element:r,direction:s.value,onDelta:e=>A(i+e/g.value*100),onEnd:()=>{C.value=!1,O=void 0,e.onDragEnd?.(S.value)}}),O&&(C.value=!0,e.onDragStart?.(S.value))},handleDoubleClick:()=>{l.value||P(`first`)},handleKeyDown:t=>{if(l.value||t.target!==t.currentTarget)return;if(t.key===`Enter`){u.value&&(t.preventDefault(),x.value?N():M(`first`));return}let i=Math.max(0,r((0,n.toValue)(e.step),2))||2,a=t.shiftKey?10:1,o=h(t.key,s.value,i*a,S.value,_.value);o!==void 0&&(t.preventDefault(),A(o))},collapse:M,expand:N,toggle:P,resetSize:()=>A(r((0,n.toValue)(e.defaultSize),50)),setSize:e=>A(e),getPanelInfo:()=>({first:{size:S.value,collapsed:w.value},second:{size:100-S.value,collapsed:T.value}})}}const _=[`aria-hidden`,`inert`],v={class:`split-panel__content`},y=[`aria-orientation`,`aria-valuenow`,`aria-valuemin`,`aria-valuemax`,`aria-disabled`,`aria-label`,`tabindex`],b=[`disabled`,`aria-label`,`aria-expanded`,`title`],x={class:`split-gutter__visual`,"aria-hidden":`true`},S={class:`split-gutter__dots`},C=[`disabled`,`aria-label`,`aria-expanded`,`title`],w=[`aria-hidden`,`inert`],T={class:`split-panel__content`},E=(0,n.defineComponent)({name:`C_SplitPane`,__name:`index`,props:{ariaLabel:{},direction:{default:`horizontal`},size:{},defaultSize:{default:50},minSize:{default:0},maxSize:{default:100},minFirstSize:{default:0},minSecondSize:{default:0},disabled:{type:Boolean,default:!1},collapsible:{type:Boolean,default:!0},showCollapseButton:{type:Boolean,default:!0},gutterSize:{default:6},step:{default:2}},emits:[`update:size`,`resize`,`collapse`,`expand`,`drag-start`,`drag-end`],setup(t,{expose:r,emit:i}){let{t:a}=e.t(),o=t,s=i,c=(0,n.useId)(),l=`split-${c}-first`,u=`split-${c}-second`,d=(0,n.ref)(null),{panelSize:f,bounds:p,gutterSize:m,isDragging:h,isFirstCollapsed:E,isSecondCollapsed:D,handleMouseDown:O,handleDoubleClick:k,handleKeyDown:A,collapse:j,expand:M,toggle:N,resetSize:P,setSize:F,getPanelInfo:I}=g({containerRef:d,direction:(0,n.toRef)(o,`direction`),size:(0,n.toRef)(o,`size`),defaultSize:(0,n.toRef)(o,`defaultSize`),minSize:(0,n.toRef)(o,`minSize`),maxSize:(0,n.toRef)(o,`maxSize`),minFirstSize:(0,n.toRef)(o,`minFirstSize`),minSecondSize:(0,n.toRef)(o,`minSecondSize`),gutterSize:(0,n.toRef)(o,`gutterSize`),disabled:(0,n.toRef)(o,`disabled`),collapsible:(0,n.toRef)(o,`collapsible`),step:(0,n.toRef)(o,`step`),onUpdateSize:e=>s(`update:size`,e),onResize:(e,t)=>s(`resize`,e,t),onCollapse:e=>s(`collapse`,e),onExpand:e=>s(`expand`,e),onDragStart:e=>s(`drag-start`,e),onDragEnd:e=>s(`drag-end`,e)}),L=(0,n.computed)(()=>({flex:`${f.value} 1 0px`})),R=(0,n.computed)(()=>({flex:`${100-f.value} 1 0px`})),z=(0,n.computed)(()=>o.direction===`horizontal`?{width:`${m.value}px`}:{height:`${m.value}px`});return r({collapse:j,expand:M,toggle:N,resetSize:P,getPanelInfo:I,setSize:F}),(e,r)=>((0,n.openBlock)(),(0,n.createElementBlock)(`div`,{ref_key:`containerRef`,ref:d,class:(0,n.normalizeClass)([`c-split-pane`,[`c-split-pane--${t.direction}`,{"c-split-pane--dragging":(0,n.unref)(h),"c-split-pane--disabled":t.disabled,"c-split-pane--collapsed-first":(0,n.unref)(E),"c-split-pane--collapsed-second":(0,n.unref)(D)}]])},[(0,n.createCommentVNode)(` 首面板 `),(0,n.createElementVNode)(`div`,{class:`split-panel split-panel--first`,id:l,style:(0,n.normalizeStyle)(L.value),"aria-hidden":(0,n.unref)(E)||void 0,inert:(0,n.unref)(E)},[(0,n.createElementVNode)(`div`,v,[(0,n.renderSlot)(e.$slots,`first`,{size:(0,n.unref)(f),collapsed:(0,n.unref)(E)},void 0,!0)])],12,_),(0,n.createCommentVNode)(` 分割线手柄 `),(0,n.createElementVNode)(`div`,{class:`split-gutter`,style:(0,n.normalizeStyle)(z.value),role:`separator`,"aria-orientation":t.direction===`horizontal`?`vertical`:`horizontal`,"aria-valuenow":(0,n.unref)(f),"aria-valuemin":(0,n.unref)(E)?0:(0,n.unref)(p).min,"aria-valuemax":(0,n.unref)(D)?100:(0,n.unref)(p).max,"aria-disabled":t.disabled||void 0,"aria-controls":l,"aria-label":t.ariaLabel??(0,n.unref)(a)(`split.resize`),tabindex:t.disabled?-1:0,onPointerdown:r[6]||=(...e)=>(0,n.unref)(O)&&(0,n.unref)(O)(...e),onDblclick:r[7]||=(...e)=>(0,n.unref)(k)&&(0,n.unref)(k)(...e),onKeydown:r[8]||=(...e)=>(0,n.unref)(A)&&(0,n.unref)(A)(...e)},[(0,n.createElementVNode)(`div`,{class:(0,n.normalizeClass)([`split-gutter__controls`,{"split-gutter__controls--with-collapse":t.showCollapseButton&&t.collapsible}])},[t.showCollapseButton&&t.collapsible?((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:0,class:`split-gutter__collapse-btn split-gutter__collapse-btn--first`,type:`button`,disabled:t.disabled,"aria-label":(0,n.unref)(E)?(0,n.unref)(a)(`split.expandFirst`):(0,n.unref)(a)(`split.collapseFirst`),"aria-expanded":!(0,n.unref)(E),"aria-controls":l,title:(0,n.unref)(E)?(0,n.unref)(a)(`split.expandFirst`):(0,n.unref)(a)(`split.collapseFirst`),onClick:r[0]||=(0,n.withModifiers)(e=>(0,n.unref)(N)(`first`),[`stop`]),onPointerdown:r[1]||=(0,n.withModifiers)(()=>{},[`stop`]),onDblclick:r[2]||=(0,n.withModifiers)(()=>{},[`stop`])},[...r[9]||=[(0,n.createElementVNode)(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[(0,n.createElementVNode)(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,b)):(0,n.createCommentVNode)(`v-if`,!0),(0,n.createElementVNode)(`div`,x,[(0,n.createElementVNode)(`div`,S,[((0,n.openBlock)(),(0,n.createElementBlock)(n.Fragment,null,(0,n.renderList)(3,e=>(0,n.createElementVNode)(`span`,{key:e,class:`split-gutter__dot`})),64))])]),t.showCollapseButton&&t.collapsible?((0,n.openBlock)(),(0,n.createElementBlock)(`button`,{key:1,class:`split-gutter__collapse-btn split-gutter__collapse-btn--second`,type:`button`,disabled:t.disabled,"aria-label":(0,n.unref)(D)?(0,n.unref)(a)(`split.expandSecond`):(0,n.unref)(a)(`split.collapseSecond`),"aria-expanded":!(0,n.unref)(D),"aria-controls":u,title:(0,n.unref)(D)?(0,n.unref)(a)(`split.expandSecond`):(0,n.unref)(a)(`split.collapseSecond`),onClick:r[3]||=(0,n.withModifiers)(e=>(0,n.unref)(N)(`second`),[`stop`]),onPointerdown:r[4]||=(0,n.withModifiers)(()=>{},[`stop`]),onDblclick:r[5]||=(0,n.withModifiers)(()=>{},[`stop`])},[...r[10]||=[(0,n.createElementVNode)(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[(0,n.createElementVNode)(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,C)):(0,n.createCommentVNode)(`v-if`,!0)],2)],44,y),(0,n.createCommentVNode)(` 第二面板 `),(0,n.createElementVNode)(`div`,{class:`split-panel split-panel--second`,id:u,style:(0,n.normalizeStyle)(R.value),"aria-hidden":(0,n.unref)(D)||void 0,inert:(0,n.unref)(D)},[(0,n.createElementVNode)(`div`,T,[(0,n.renderSlot)(e.$slots,`second`,{size:100-(0,n.unref)(f),collapsed:(0,n.unref)(D)},void 0,!0)])],12,w)],2))}});var D=t.t(E,[[`__scopeId`,`data-v-265c2994`]]);Object.defineProperty(exports,`n`,{enumerable:!0,get:function(){return g}}),Object.defineProperty(exports,`t`,{enumerable:!0,get:function(){return D}});
|
package/dist/C_SplitPane2.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./useComponentLocale.js";import{t}from"./export-helper.js";import{Fragment as n,computed as r,createCommentVNode as i,createElementBlock as a,createElementVNode as o,defineComponent as s,normalizeClass as c,normalizeStyle as l,onMounted as u,onUnmounted as d,openBlock as f,ref as p,renderList as m,renderSlot as h,toRef as g,toValue as _,unref as v,useId as y,watch as b,withModifiers as x}from"vue";const S=(e,t)=>typeof e==`number`&&Number.isFinite(e)?e:t,C=e=>Math.max(4,S(e,6));function w(e){let t=Math.max(0,Math.min(100,S(e.minSize,0))),n=Math.max(0,Math.min(100,S(e.maxSize,100))),r=Math.min(t,n),i=Math.max(t,n),a=Math.max(0,S(e.availableLength,0));if(!a)return{min:r,max:i};let o=Math.max(0,S(e.minFirstSize,0)),s=Math.max(0,S(e.minSecondSize,0)),c=Math.max(r,o/a*100),l=Math.min(i,100-s/a*100);if(c<=l)return{min:c,max:l};let u=o+s?o/(o+s)*100:50,d=Math.max(r,Math.min(i,u));return{min:d,max:d}}function T(e,t,n){return Math.min(n,Math.max(t,S(e,50)))}const E=new WeakMap;function D(e){return`button`in e&&e.button!==0?!1:!(`isPrimary`in e)||e.isPrimary}function O(e,t,n){if(!(`touches`in e))return t===`horizontal`?e.clientX:e.clientY;let r=n===void 0?e.touches[0]:Array.from(e.touches).find(e=>e.identifier===n);if(r)return t===`horizontal`?r.clientX:r.clientY}function k(e,t){return t===void 0||!(`pointerId`in e)?!0:e.pointerId===t}function A(e,t){let{style:n}=e.body,r=t===`horizontal`?`col-resize`:`row-resize`,i=[`cursor`,`user-select`].map(e=>({name:e,value:n.getPropertyValue(e),priority:n.getPropertyPriority(e),owned:e===`cursor`?r:`none`}));for(let e of i)n.setProperty(e.name,e.owned);return()=>{for(let e of i)n.getPropertyValue(e.name)===e.owned&&(e.value?n.setProperty(e.name,e.value,e.priority):n.removeProperty(e.name))}}function j(e){return`pointerId`in e?{move:[`pointermove`],end:[`pointerup`,`pointercancel`]}:`touches`in e?{move:[`touchmove`],end:[`touchend`,`touchcancel`]}:{move:[`mousemove`],end:[`mouseup`]}}function M(e,t){let n=O(e,t.direction);if(n===void 0)return;let r=t.element.ownerDocument,i=r.defaultView;E.get(r)?.();let a=A(r,t.direction),o=`pointerId`in e?e.pointerId:void 0,s=`touches`in e?e.touches[0]?.identifier:void 0,c=!0;e.preventDefault(),e.stopPropagation(),e.currentTarget?.focus();let l=e=>{if(!k(e,o))return;let r=O(e,t.direction,s);r!==void 0&&(e.cancelable&&e.preventDefault(),t.onDelta(r-n))},u=e=>{if(!(e&&!k(e,o))&&c){c=!1,a();for(let[e,t]of p)r.removeEventListener(e,t);i?.removeEventListener(`blur`,u),E.get(r)===u&&E.delete(r),t.onEnd()}},d=()=>{r.hidden&&u()},f=j(e),p=[...f.move.map(e=>[e,l]),...f.end.map(e=>[e,u]),[`visibilitychange`,d]];for(let[e,t]of p)r.addEventListener(e,t,{passive:!1});return i?.addEventListener(`blur`,u),E.set(r,u),u}function N(e){return e===0?`first`:e===100?`second`:null}function P(e,t,n,r,i){if(e===`Home`)return i.min;if(e===`End`)return i.max;let a=t===`horizontal`?`ArrowLeft`:`ArrowUp`,o=t===`horizontal`?`ArrowRight`:`ArrowDown`;if(e===a)return r-n;if(e===o)return r+n}function F(e){let{containerRef:t,direction:n,disabled:i,collapsible:a}=e,o=p(0),s=r(()=>C(_(e.gutterSize))),c=r(()=>Math.max(0,o.value-s.value)),l=r(()=>w({minSize:_(e.minSize),maxSize:_(e.maxSize),minFirstSize:_(e.minFirstSize)??0,minSecondSize:_(e.minSecondSize)??0,availableLength:c.value})),f=p(T(_(e.defaultSize),l.value.min,l.value.max)),m=r(()=>_(e.size)!==void 0),h=r(()=>m.value?S(_(e.size),50):f.value),g=r(()=>a.value?h.value===0?`first`:h.value===100?`second`:null:null),v=r(()=>g.value?g.value===`first`?0:100:T(h.value,l.value.min,l.value.max)),y=p(!1),x=r(()=>g.value===`first`),E=r(()=>g.value===`second`),O=S(_(e.defaultSize),50),k=g.value?T(O>0&&O<100?O:50,l.value.min,l.value.max):v.value,A,j,F=(t,n=!1)=>{if(!Number.isFinite(t))return;let r=n?t:T(t,l.value.min,l.value.max);r!==h.value&&(m.value||(f.value=r),e.onUpdateSize?.(r))};b(v,(t,n)=>{let r=N(n),i=g.value;!r&&i&&(k=n),r&&r!==i&&e.onExpand?.(r),i&&i!==r&&e.onCollapse?.(i),e.onResize?.(t,100-t)},{flush:`sync`}),b(l,()=>{g.value||F(v.value)},{flush:`sync`}),b([i,n],()=>A?.(),{flush:`sync`}),b(a,()=>{g.value||F(v.value)},{flush:`sync`});let I=()=>{let e=t.value;if(!e)return;let r=e.getBoundingClientRect();o.value=n.value===`horizontal`?r.width:r.height};b(n,I,{flush:`post`}),u(()=>{I(),typeof ResizeObserver<`u`&&t.value&&(j=new ResizeObserver(I),j.observe(t.value))});let L=(e=`first`)=>{!a.value||g.value===e||(g.value||(k=v.value),F(e===`first`?0:100,!0))},R=()=>{g.value&&F(k)},z=(e=`first`)=>{g.value===e?R():L(e)};return d(()=>{A?.(),j?.disconnect()}),{panelSize:v,isDragging:y,collapsedTarget:g,isFirstCollapsed:x,isSecondCollapsed:E,bounds:l,gutterSize:s,handleMouseDown:r=>{if(i.value||y.value||!D(r))return;let a=t.value;if(!a||(I(),!c.value))return;let o=v.value;A=M(r,{element:a,direction:n.value,onDelta:e=>F(o+e/c.value*100),onEnd:()=>{y.value=!1,A=void 0,e.onDragEnd?.(v.value)}}),A&&(y.value=!0,e.onDragStart?.(v.value))},handleDoubleClick:()=>{i.value||z(`first`)},handleKeyDown:t=>{if(i.value||t.target!==t.currentTarget)return;if(t.key===`Enter`){a.value&&(t.preventDefault(),g.value?R():L(`first`));return}let r=Math.max(0,S(_(e.step),2))||2,o=t.shiftKey?10:1,s=P(t.key,n.value,r*o,v.value,l.value);s!==void 0&&(t.preventDefault(),F(s))},collapse:L,expand:R,toggle:z,resetSize:()=>F(S(_(e.defaultSize),50)),setSize:e=>F(e),getPanelInfo:()=>({first:{size:v.value,collapsed:x.value},second:{size:100-v.value,collapsed:E.value}})}}const I=[`aria-hidden`,`inert`],L={class:`split-panel__content`},R=[`aria-orientation`,`aria-valuenow`,`aria-valuemin`,`aria-valuemax`,`aria-disabled`,`aria-label`,`tabindex`],z=[`disabled`,`aria-label`,`aria-expanded`,`title`],B={class:`split-gutter__visual`,"aria-hidden":`true`},V={class:`split-gutter__dots`},H=[`disabled`,`aria-label`,`aria-expanded`,`title`],U=[`aria-hidden`,`inert`],W={class:`split-panel__content`};var G=t(s({name:`C_SplitPane`,__name:`index`,props:{ariaLabel:{},direction:{default:`horizontal`},size:{},defaultSize:{default:50},minSize:{default:0},maxSize:{default:100},minFirstSize:{default:0},minSecondSize:{default:0},disabled:{type:Boolean,default:!1},collapsible:{type:Boolean,default:!0},showCollapseButton:{type:Boolean,default:!0},gutterSize:{default:6},step:{default:2}},emits:[`update:size`,`resize`,`collapse`,`expand`,`drag-start`,`drag-end`],setup(t,{expose:s,emit:u}){let{t:d}=e(),_=t,b=u,S=y(),C=`split-${S}-first`,w=`split-${S}-second`,T=p(null),{panelSize:E,bounds:D,gutterSize:O,isDragging:k,isFirstCollapsed:A,isSecondCollapsed:j,handleMouseDown:M,handleDoubleClick:N,handleKeyDown:P,collapse:G,expand:K,toggle:q,resetSize:J,setSize:Y,getPanelInfo:X}=F({containerRef:T,direction:g(_,`direction`),size:g(_,`size`),defaultSize:g(_,`defaultSize`),minSize:g(_,`minSize`),maxSize:g(_,`maxSize`),minFirstSize:g(_,`minFirstSize`),minSecondSize:g(_,`minSecondSize`),gutterSize:g(_,`gutterSize`),disabled:g(_,`disabled`),collapsible:g(_,`collapsible`),step:g(_,`step`),onUpdateSize:e=>b(`update:size`,e),onResize:(e,t)=>b(`resize`,e,t),onCollapse:e=>b(`collapse`,e),onExpand:e=>b(`expand`,e),onDragStart:e=>b(`drag-start`,e),onDragEnd:e=>b(`drag-end`,e)}),Z=r(()=>({flex:`${E.value} 1 0px`})),Q=r(()=>({flex:`${100-E.value} 1 0px`})),$=r(()=>_.direction===`horizontal`?{width:`${O.value}px`}:{height:`${O.value}px`});return s({collapse:G,expand:K,toggle:q,resetSize:J,getPanelInfo:X,setSize:Y}),(e,r)=>(f(),a(`div`,{ref_key:`containerRef`,ref:T,class:c([`c-split-pane`,[`c-split-pane--${t.direction}`,{"c-split-pane--dragging":v(k),"c-split-pane--disabled":t.disabled,"c-split-pane--collapsed-first":v(A),"c-split-pane--collapsed-second":v(j)}]])},[i(` 首面板 `),o(`div`,{class:`split-panel split-panel--first`,id:C,style:l(Z.value),"aria-hidden":v(A)||void 0,inert:v(A)},[o(`div`,L,[h(e.$slots,`first`,{size:v(E),collapsed:v(A)},void 0,!0)])],12,I),i(` 分割线手柄 `),o(`div`,{class:`split-gutter`,style:l($.value),role:`separator`,"aria-orientation":t.direction===`horizontal`?`vertical`:`horizontal`,"aria-valuenow":v(E),"aria-valuemin":v(A)?0:v(D).min,"aria-valuemax":v(j)?100:v(D).max,"aria-disabled":t.disabled||void 0,"aria-controls":C,"aria-label":t.ariaLabel??v(d)(`split.resize`),tabindex:t.disabled?-1:0,onPointerdown:r[6]||=(...e)=>v(M)&&v(M)(...e),onDblclick:r[7]||=(...e)=>v(N)&&v(N)(...e),onKeydown:r[8]||=(...e)=>v(P)&&v(P)(...e)},[o(`div`,{class:c([`split-gutter__controls`,{"split-gutter__controls--with-collapse":t.showCollapseButton&&t.collapsible}])},[t.showCollapseButton&&t.collapsible?(f(),a(`button`,{key:0,class:`split-gutter__collapse-btn split-gutter__collapse-btn--first`,type:`button`,disabled:t.disabled,"aria-label":v(A)?v(d)(`split.expandFirst`):v(d)(`split.collapseFirst`),"aria-expanded":!v(A),"aria-controls":C,title:v(A)?v(d)(`split.expandFirst`):v(d)(`split.collapseFirst`),onClick:r[0]||=x(e=>v(q)(`first`),[`stop`]),onPointerdown:r[1]||=x(()=>{},[`stop`]),onDblclick:r[2]||=x(()=>{},[`stop`])},[...r[9]||=[o(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[o(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,z)):i(`v-if`,!0),o(`div`,B,[o(`div`,V,[(f(),a(n,null,m(3,e=>o(`span`,{key:e,class:`split-gutter__dot`})),64))])]),t.showCollapseButton&&t.collapsible?(f(),a(`button`,{key:1,class:`split-gutter__collapse-btn split-gutter__collapse-btn--second`,type:`button`,disabled:t.disabled,"aria-label":v(j)?v(d)(`split.expandSecond`):v(d)(`split.collapseSecond`),"aria-expanded":!v(j),"aria-controls":w,title:v(j)?v(d)(`split.expandSecond`):v(d)(`split.collapseSecond`),onClick:r[3]||=x(e=>v(q)(`second`),[`stop`]),onPointerdown:r[4]||=x(()=>{},[`stop`]),onDblclick:r[5]||=x(()=>{},[`stop`])},[...r[10]||=[o(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[o(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,H)):i(`v-if`,!0)],2)],44,R),i(` 第二面板 `),o(`div`,{class:`split-panel split-panel--second`,id:w,style:l(Q.value),"aria-hidden":v(j)||void 0,inert:v(j)},[o(`div`,W,[h(e.$slots,`second`,{size:100-v(E),collapsed:v(j)},void 0,!0)])],12,U)],2))}}),[[`__scopeId`,`data-v-265c2994`]]);export{F as n,G as t};
|
|
1
|
+
import{t as e}from"./useComponentLocale.js";import{t}from"./export-helper.js";import{Fragment as n,computed as r,createCommentVNode as i,createElementBlock as a,createElementVNode as o,defineComponent as s,normalizeClass as c,normalizeStyle as l,onMounted as u,onUnmounted as d,openBlock as f,ref as p,renderList as m,renderSlot as h,toRef as g,toValue as _,unref as v,useId as y,watch as b,withModifiers as x}from"vue";const S=(e,t)=>typeof e==`number`&&Number.isFinite(e)?e:t,C=e=>Math.max(4,S(e,6));function w(e){let t=Math.max(0,Math.min(100,S(e.minSize,0))),n=Math.max(0,Math.min(100,S(e.maxSize,100))),r=Math.min(t,n),i=Math.max(t,n),a=Math.max(0,S(e.availableLength,0));if(!a)return{min:r,max:i};let o=Math.max(0,S(e.minFirstSize,0)),s=Math.max(0,S(e.minSecondSize,0)),c=Math.max(r,o/a*100),l=Math.min(i,100-s/a*100);if(c<=l)return{min:c,max:l};let u=o+s?o/(o+s)*100:50,d=Math.max(r,Math.min(i,u));return{min:d,max:d}}function T(e,t,n){return Math.min(n,Math.max(t,S(e,50)))}const E=new WeakMap;function D(e){return`button`in e&&e.button!==0?!1:!(`isPrimary`in e)||e.isPrimary}function O(e,t,n){if(!(`touches`in e))return t===`horizontal`?e.clientX:e.clientY;let r=n===void 0?e.touches[0]:Array.from(e.touches).find(e=>e.identifier===n);if(r)return t===`horizontal`?r.clientX:r.clientY}function k(e,t){return t===void 0||!(`pointerId`in e)?!0:e.pointerId===t}function A(e,t){let{style:n}=e.body,r=t===`horizontal`?`col-resize`:`row-resize`,i=[`cursor`,`user-select`].map(e=>({name:e,value:n.getPropertyValue(e),priority:n.getPropertyPriority(e),owned:e===`cursor`?r:`none`}));for(let e of i)n.setProperty(e.name,e.owned);return()=>{for(let e of i)n.getPropertyValue(e.name)===e.owned&&(e.value?n.setProperty(e.name,e.value,e.priority):n.removeProperty(e.name))}}function j(e){return`pointerId`in e?{move:[`pointermove`],end:[`pointerup`,`pointercancel`]}:`touches`in e?{move:[`touchmove`],end:[`touchend`,`touchcancel`]}:{move:[`mousemove`],end:[`mouseup`]}}function M(e,t){let n=O(e,t.direction);if(n===void 0)return;let r=t.element.ownerDocument,i=r.defaultView;E.get(r)?.();let a=A(r,t.direction),o=`pointerId`in e?e.pointerId:void 0,s=`touches`in e?e.touches[0]?.identifier:void 0,c=!0;e.preventDefault(),e.stopPropagation(),e.currentTarget?.focus({preventScroll:!0});let l=e=>{if(!k(e,o))return;let r=O(e,t.direction,s);r!==void 0&&(e.cancelable&&e.preventDefault(),t.onDelta(r-n))},u=e=>{if(!(e&&!k(e,o))&&c){c=!1,a();for(let[e,t]of p)r.removeEventListener(e,t);i?.removeEventListener(`blur`,u),E.get(r)===u&&E.delete(r),t.onEnd()}},d=()=>{r.hidden&&u()},f=j(e),p=[...f.move.map(e=>[e,l]),...f.end.map(e=>[e,u]),[`visibilitychange`,d]];for(let[e,t]of p)r.addEventListener(e,t,{passive:!1});return i?.addEventListener(`blur`,u),E.set(r,u),u}function N(e){return e===0?`first`:e===100?`second`:null}function P(e,t,n,r,i){if(e===`Home`)return i.min;if(e===`End`)return i.max;let a=t===`horizontal`?`ArrowLeft`:`ArrowUp`,o=t===`horizontal`?`ArrowRight`:`ArrowDown`;if(e===a)return r-n;if(e===o)return r+n}function F(e){let{containerRef:t,direction:n,disabled:i,collapsible:a}=e,o=p(0),s=r(()=>C(_(e.gutterSize))),c=r(()=>Math.max(0,o.value-s.value)),l=r(()=>w({minSize:_(e.minSize),maxSize:_(e.maxSize),minFirstSize:_(e.minFirstSize)??0,minSecondSize:_(e.minSecondSize)??0,availableLength:c.value})),f=p(T(_(e.defaultSize),l.value.min,l.value.max)),m=r(()=>_(e.size)!==void 0),h=r(()=>m.value?S(_(e.size),50):f.value),g=r(()=>a.value?h.value===0?`first`:h.value===100?`second`:null:null),v=r(()=>g.value?g.value===`first`?0:100:T(h.value,l.value.min,l.value.max)),y=p(!1),x=r(()=>g.value===`first`),E=r(()=>g.value===`second`),O=S(_(e.defaultSize),50),k=g.value?T(O>0&&O<100?O:50,l.value.min,l.value.max):v.value,A,j,F=(t,n=!1)=>{if(!Number.isFinite(t))return;let r=n?t:T(t,l.value.min,l.value.max);r!==h.value&&(m.value||(f.value=r),e.onUpdateSize?.(r))};b(v,(t,n)=>{let r=N(n),i=g.value;!r&&i&&(k=n),r&&r!==i&&e.onExpand?.(r),i&&i!==r&&e.onCollapse?.(i),e.onResize?.(t,100-t)},{flush:`sync`}),b(l,()=>{g.value||F(v.value)},{flush:`sync`}),b([i,n],()=>A?.(),{flush:`sync`}),b(a,()=>{g.value||F(v.value)},{flush:`sync`});let I=()=>{let e=t.value;if(!e)return;let r=e.getBoundingClientRect();o.value=n.value===`horizontal`?r.width:r.height};b(n,I,{flush:`post`}),u(()=>{I(),typeof ResizeObserver<`u`&&t.value&&(j=new ResizeObserver(I),j.observe(t.value))});let L=(e=`first`)=>{!a.value||g.value===e||(g.value||(k=v.value),F(e===`first`?0:100,!0))},R=()=>{g.value&&F(k)},z=(e=`first`)=>{g.value===e?R():L(e)};return d(()=>{A?.(),j?.disconnect()}),{panelSize:v,isDragging:y,collapsedTarget:g,isFirstCollapsed:x,isSecondCollapsed:E,bounds:l,gutterSize:s,handleMouseDown:r=>{if(i.value||y.value||!D(r))return;let a=t.value;if(!a||(I(),!c.value))return;let o=v.value;A=M(r,{element:a,direction:n.value,onDelta:e=>F(o+e/c.value*100),onEnd:()=>{y.value=!1,A=void 0,e.onDragEnd?.(v.value)}}),A&&(y.value=!0,e.onDragStart?.(v.value))},handleDoubleClick:()=>{i.value||z(`first`)},handleKeyDown:t=>{if(i.value||t.target!==t.currentTarget)return;if(t.key===`Enter`){a.value&&(t.preventDefault(),g.value?R():L(`first`));return}let r=Math.max(0,S(_(e.step),2))||2,o=t.shiftKey?10:1,s=P(t.key,n.value,r*o,v.value,l.value);s!==void 0&&(t.preventDefault(),F(s))},collapse:L,expand:R,toggle:z,resetSize:()=>F(S(_(e.defaultSize),50)),setSize:e=>F(e),getPanelInfo:()=>({first:{size:v.value,collapsed:x.value},second:{size:100-v.value,collapsed:E.value}})}}const I=[`aria-hidden`,`inert`],L={class:`split-panel__content`},R=[`aria-orientation`,`aria-valuenow`,`aria-valuemin`,`aria-valuemax`,`aria-disabled`,`aria-label`,`tabindex`],z=[`disabled`,`aria-label`,`aria-expanded`,`title`],B={class:`split-gutter__visual`,"aria-hidden":`true`},V={class:`split-gutter__dots`},H=[`disabled`,`aria-label`,`aria-expanded`,`title`],U=[`aria-hidden`,`inert`],W={class:`split-panel__content`};var G=t(s({name:`C_SplitPane`,__name:`index`,props:{ariaLabel:{},direction:{default:`horizontal`},size:{},defaultSize:{default:50},minSize:{default:0},maxSize:{default:100},minFirstSize:{default:0},minSecondSize:{default:0},disabled:{type:Boolean,default:!1},collapsible:{type:Boolean,default:!0},showCollapseButton:{type:Boolean,default:!0},gutterSize:{default:6},step:{default:2}},emits:[`update:size`,`resize`,`collapse`,`expand`,`drag-start`,`drag-end`],setup(t,{expose:s,emit:u}){let{t:d}=e(),_=t,b=u,S=y(),C=`split-${S}-first`,w=`split-${S}-second`,T=p(null),{panelSize:E,bounds:D,gutterSize:O,isDragging:k,isFirstCollapsed:A,isSecondCollapsed:j,handleMouseDown:M,handleDoubleClick:N,handleKeyDown:P,collapse:G,expand:K,toggle:q,resetSize:J,setSize:Y,getPanelInfo:X}=F({containerRef:T,direction:g(_,`direction`),size:g(_,`size`),defaultSize:g(_,`defaultSize`),minSize:g(_,`minSize`),maxSize:g(_,`maxSize`),minFirstSize:g(_,`minFirstSize`),minSecondSize:g(_,`minSecondSize`),gutterSize:g(_,`gutterSize`),disabled:g(_,`disabled`),collapsible:g(_,`collapsible`),step:g(_,`step`),onUpdateSize:e=>b(`update:size`,e),onResize:(e,t)=>b(`resize`,e,t),onCollapse:e=>b(`collapse`,e),onExpand:e=>b(`expand`,e),onDragStart:e=>b(`drag-start`,e),onDragEnd:e=>b(`drag-end`,e)}),Z=r(()=>({flex:`${E.value} 1 0px`})),Q=r(()=>({flex:`${100-E.value} 1 0px`})),$=r(()=>_.direction===`horizontal`?{width:`${O.value}px`}:{height:`${O.value}px`});return s({collapse:G,expand:K,toggle:q,resetSize:J,getPanelInfo:X,setSize:Y}),(e,r)=>(f(),a(`div`,{ref_key:`containerRef`,ref:T,class:c([`c-split-pane`,[`c-split-pane--${t.direction}`,{"c-split-pane--dragging":v(k),"c-split-pane--disabled":t.disabled,"c-split-pane--collapsed-first":v(A),"c-split-pane--collapsed-second":v(j)}]])},[i(` 首面板 `),o(`div`,{class:`split-panel split-panel--first`,id:C,style:l(Z.value),"aria-hidden":v(A)||void 0,inert:v(A)},[o(`div`,L,[h(e.$slots,`first`,{size:v(E),collapsed:v(A)},void 0,!0)])],12,I),i(` 分割线手柄 `),o(`div`,{class:`split-gutter`,style:l($.value),role:`separator`,"aria-orientation":t.direction===`horizontal`?`vertical`:`horizontal`,"aria-valuenow":v(E),"aria-valuemin":v(A)?0:v(D).min,"aria-valuemax":v(j)?100:v(D).max,"aria-disabled":t.disabled||void 0,"aria-controls":C,"aria-label":t.ariaLabel??v(d)(`split.resize`),tabindex:t.disabled?-1:0,onPointerdown:r[6]||=(...e)=>v(M)&&v(M)(...e),onDblclick:r[7]||=(...e)=>v(N)&&v(N)(...e),onKeydown:r[8]||=(...e)=>v(P)&&v(P)(...e)},[o(`div`,{class:c([`split-gutter__controls`,{"split-gutter__controls--with-collapse":t.showCollapseButton&&t.collapsible}])},[t.showCollapseButton&&t.collapsible?(f(),a(`button`,{key:0,class:`split-gutter__collapse-btn split-gutter__collapse-btn--first`,type:`button`,disabled:t.disabled,"aria-label":v(A)?v(d)(`split.expandFirst`):v(d)(`split.collapseFirst`),"aria-expanded":!v(A),"aria-controls":C,title:v(A)?v(d)(`split.expandFirst`):v(d)(`split.collapseFirst`),onClick:r[0]||=x(e=>v(q)(`first`),[`stop`]),onPointerdown:r[1]||=x(()=>{},[`stop`]),onDblclick:r[2]||=x(()=>{},[`stop`])},[...r[9]||=[o(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[o(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,z)):i(`v-if`,!0),o(`div`,B,[o(`div`,V,[(f(),a(n,null,m(3,e=>o(`span`,{key:e,class:`split-gutter__dot`})),64))])]),t.showCollapseButton&&t.collapsible?(f(),a(`button`,{key:1,class:`split-gutter__collapse-btn split-gutter__collapse-btn--second`,type:`button`,disabled:t.disabled,"aria-label":v(j)?v(d)(`split.expandSecond`):v(d)(`split.collapseSecond`),"aria-expanded":!v(j),"aria-controls":w,title:v(j)?v(d)(`split.expandSecond`):v(d)(`split.collapseSecond`),onClick:r[3]||=x(e=>v(q)(`second`),[`stop`]),onPointerdown:r[4]||=x(()=>{},[`stop`]),onDblclick:r[5]||=x(()=>{},[`stop`])},[...r[10]||=[o(`svg`,{class:`split-gutter__chevron`,viewBox:`0 0 16 16`,"aria-hidden":`true`,focusable:`false`},[o(`path`,{d:`m9.5 4.5-3.5 3.5 3.5 3.5`})],-1)]],40,H)):i(`v-if`,!0)],2)],44,R),i(` 第二面板 `),o(`div`,{class:`split-panel split-panel--second`,id:w,style:l(Q.value),"aria-hidden":v(j)||void 0,inert:v(j)},[o(`div`,W,[h(e.$slots,`second`,{size:100-v(E),collapsed:v(j)},void 0,!0)])],12,U)],2))}}),[[`__scopeId`,`data-v-265c2994`]]);export{F as n,G as t};
|
package/dist/constants.d.cts
CHANGED
|
@@ -108,16 +108,16 @@ interface CronEmits {
|
|
|
108
108
|
//#endregion
|
|
109
109
|
//#region src/components/C_Cron/index.vue.d.ts
|
|
110
110
|
declare const __VLS_export: vue.DefineComponent<CronProps, CronExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
111
|
-
change: (value: string) => any;
|
|
112
111
|
"update:modelValue": (value: string) => any;
|
|
112
|
+
change: (value: string) => any;
|
|
113
113
|
"validation-change": (result: CronValidation) => any;
|
|
114
114
|
}, string, vue.PublicProps, Readonly<CronProps> & Readonly<{
|
|
115
|
-
onChange?: ((value: string) => any) | undefined;
|
|
116
115
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
116
|
+
onChange?: ((value: string) => any) | undefined;
|
|
117
117
|
"onValidation-change"?: ((result: CronValidation) => any) | undefined;
|
|
118
118
|
}>, {
|
|
119
|
-
showPreview: boolean;
|
|
120
119
|
disabled: boolean;
|
|
120
|
+
showPreview: boolean;
|
|
121
121
|
showTemplates: boolean;
|
|
122
122
|
showSecond: boolean;
|
|
123
123
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
package/dist/constants.d.ts
CHANGED
|
@@ -108,16 +108,16 @@ interface CronEmits {
|
|
|
108
108
|
//#endregion
|
|
109
109
|
//#region src/components/C_Cron/index.vue.d.ts
|
|
110
110
|
declare const __VLS_export: vue.DefineComponent<CronProps, CronExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
111
|
-
change: (value: string) => any;
|
|
112
111
|
"update:modelValue": (value: string) => any;
|
|
112
|
+
change: (value: string) => any;
|
|
113
113
|
"validation-change": (result: CronValidation) => any;
|
|
114
114
|
}, string, vue.PublicProps, Readonly<CronProps> & Readonly<{
|
|
115
|
-
onChange?: ((value: string) => any) | undefined;
|
|
116
115
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
116
|
+
onChange?: ((value: string) => any) | undefined;
|
|
117
117
|
"onValidation-change"?: ((result: CronValidation) => any) | undefined;
|
|
118
118
|
}>, {
|
|
119
|
-
showPreview: boolean;
|
|
120
119
|
disabled: boolean;
|
|
120
|
+
showPreview: boolean;
|
|
121
121
|
showTemplates: boolean;
|
|
122
122
|
showSecond: boolean;
|
|
123
123
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
package/dist/constants2.d.cts
CHANGED
|
@@ -196,31 +196,31 @@ type __VLS_Slots = {} & {
|
|
|
196
196
|
area?: (props: typeof __VLS_11) => any;
|
|
197
197
|
};
|
|
198
198
|
declare const __VLS_base: vue.DefineComponent<UploadProps, UploadExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
199
|
-
error: (file: UploadFileItem, error: Error) => any;
|
|
200
199
|
change: (fileList: UploadFileItem[]) => any;
|
|
201
200
|
success: (file: UploadFileItem, response: unknown) => any;
|
|
202
|
-
|
|
201
|
+
error: (file: UploadFileItem, error: Error) => any;
|
|
203
202
|
progress: (file: UploadFileItem, percent: number) => any;
|
|
203
|
+
remove: (file: UploadFileItem) => any;
|
|
204
204
|
finish: (fileList: UploadFileItem[]) => any;
|
|
205
205
|
exceed: (files: File[], fileList: UploadFileItem[]) => any;
|
|
206
206
|
}, string, vue.PublicProps, Readonly<UploadProps> & Readonly<{
|
|
207
|
-
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
208
207
|
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
209
208
|
onSuccess?: ((file: UploadFileItem, response: unknown) => any) | undefined;
|
|
210
|
-
|
|
209
|
+
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
211
210
|
onProgress?: ((file: UploadFileItem, percent: number) => any) | undefined;
|
|
211
|
+
onRemove?: ((file: UploadFileItem) => any) | undefined;
|
|
212
212
|
onFinish?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
213
213
|
onExceed?: ((files: File[], fileList: UploadFileItem[]) => any) | undefined;
|
|
214
214
|
}>, {
|
|
215
215
|
disabled: boolean;
|
|
216
|
-
data: Record<string, unknown>;
|
|
217
216
|
multiple: boolean;
|
|
217
|
+
data: Record<string, unknown>;
|
|
218
218
|
draggable: boolean;
|
|
219
219
|
action: string;
|
|
220
|
-
maxSize: number;
|
|
221
220
|
headers: Record<string, string>;
|
|
222
221
|
directory: boolean;
|
|
223
222
|
accept: string;
|
|
223
|
+
maxSize: number;
|
|
224
224
|
maxCount: number;
|
|
225
225
|
pasteable: boolean;
|
|
226
226
|
chunked: boolean;
|
package/dist/constants2.d.ts
CHANGED
|
@@ -196,31 +196,31 @@ type __VLS_Slots = {} & {
|
|
|
196
196
|
area?: (props: typeof __VLS_11) => any;
|
|
197
197
|
};
|
|
198
198
|
declare const __VLS_base: vue.DefineComponent<UploadProps, UploadExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
199
|
-
error: (file: UploadFileItem, error: Error) => any;
|
|
200
199
|
change: (fileList: UploadFileItem[]) => any;
|
|
201
200
|
success: (file: UploadFileItem, response: unknown) => any;
|
|
202
|
-
|
|
201
|
+
error: (file: UploadFileItem, error: Error) => any;
|
|
203
202
|
progress: (file: UploadFileItem, percent: number) => any;
|
|
203
|
+
remove: (file: UploadFileItem) => any;
|
|
204
204
|
finish: (fileList: UploadFileItem[]) => any;
|
|
205
205
|
exceed: (files: File[], fileList: UploadFileItem[]) => any;
|
|
206
206
|
}, string, vue.PublicProps, Readonly<UploadProps> & Readonly<{
|
|
207
|
-
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
208
207
|
onChange?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
209
208
|
onSuccess?: ((file: UploadFileItem, response: unknown) => any) | undefined;
|
|
210
|
-
|
|
209
|
+
onError?: ((file: UploadFileItem, error: Error) => any) | undefined;
|
|
211
210
|
onProgress?: ((file: UploadFileItem, percent: number) => any) | undefined;
|
|
211
|
+
onRemove?: ((file: UploadFileItem) => any) | undefined;
|
|
212
212
|
onFinish?: ((fileList: UploadFileItem[]) => any) | undefined;
|
|
213
213
|
onExceed?: ((files: File[], fileList: UploadFileItem[]) => any) | undefined;
|
|
214
214
|
}>, {
|
|
215
215
|
disabled: boolean;
|
|
216
|
-
data: Record<string, unknown>;
|
|
217
216
|
multiple: boolean;
|
|
217
|
+
data: Record<string, unknown>;
|
|
218
218
|
draggable: boolean;
|
|
219
219
|
action: string;
|
|
220
|
-
maxSize: number;
|
|
221
220
|
headers: Record<string, string>;
|
|
222
221
|
directory: boolean;
|
|
223
222
|
accept: string;
|
|
223
|
+
maxSize: number;
|
|
224
224
|
maxCount: number;
|
|
225
225
|
pasteable: boolean;
|
|
226
226
|
chunked: boolean;
|
package/dist/constants3.d.cts
CHANGED
|
@@ -251,11 +251,11 @@ declare const __VLS_base: vue.DefineComponent<NotificationCenterProps, Notificat
|
|
|
251
251
|
onViewAll?: (() => any) | undefined;
|
|
252
252
|
}>, {
|
|
253
253
|
storageKey: string;
|
|
254
|
-
pageSize: number;
|
|
255
254
|
autoStart: boolean;
|
|
256
255
|
desktopNotification: boolean;
|
|
257
256
|
maxBadgeCount: number;
|
|
258
257
|
pollingInterval: number;
|
|
258
|
+
pageSize: number;
|
|
259
259
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
260
260
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
261
261
|
declare const _default: typeof __VLS_export;
|
package/dist/constants3.d.ts
CHANGED
|
@@ -251,11 +251,11 @@ declare const __VLS_base: vue.DefineComponent<NotificationCenterProps, Notificat
|
|
|
251
251
|
onViewAll?: (() => any) | undefined;
|
|
252
252
|
}>, {
|
|
253
253
|
storageKey: string;
|
|
254
|
-
pageSize: number;
|
|
255
254
|
autoStart: boolean;
|
|
256
255
|
desktopNotification: boolean;
|
|
257
256
|
maxBadgeCount: number;
|
|
258
257
|
pollingInterval: number;
|
|
258
|
+
pageSize: number;
|
|
259
259
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
260
260
|
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
261
261
|
declare const _default: typeof __VLS_export;
|
package/dist/constants4.d.cts
CHANGED
|
@@ -125,16 +125,16 @@ interface FormulaEditorExpose {
|
|
|
125
125
|
//#endregion
|
|
126
126
|
//#region src/components/C_FormulaEditor/index.vue.d.ts
|
|
127
127
|
declare const __VLS_export: vue.DefineComponent<FormulaEditorProps, FormulaEditorExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
128
|
-
change: (value: string) => any;
|
|
129
128
|
"update:modelValue": (value: string) => any;
|
|
129
|
+
change: (value: string) => any;
|
|
130
130
|
"validation-change": (result: FormulaValidation) => any;
|
|
131
131
|
}, string, vue.PublicProps, Readonly<FormulaEditorProps> & Readonly<{
|
|
132
|
-
onChange?: ((value: string) => any) | undefined;
|
|
133
132
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
133
|
+
onChange?: ((value: string) => any) | undefined;
|
|
134
134
|
"onValidation-change"?: ((result: FormulaValidation) => any) | undefined;
|
|
135
135
|
}>, {
|
|
136
|
-
showPreview: boolean;
|
|
137
136
|
disabled: boolean;
|
|
137
|
+
showPreview: boolean;
|
|
138
138
|
showKeyboard: boolean;
|
|
139
139
|
showVariablePanel: boolean;
|
|
140
140
|
editableSampleData: boolean;
|
package/dist/constants4.d.ts
CHANGED
|
@@ -125,16 +125,16 @@ interface FormulaEditorExpose {
|
|
|
125
125
|
//#endregion
|
|
126
126
|
//#region src/components/C_FormulaEditor/index.vue.d.ts
|
|
127
127
|
declare const __VLS_export: vue.DefineComponent<FormulaEditorProps, FormulaEditorExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
128
|
-
change: (value: string) => any;
|
|
129
128
|
"update:modelValue": (value: string) => any;
|
|
129
|
+
change: (value: string) => any;
|
|
130
130
|
"validation-change": (result: FormulaValidation) => any;
|
|
131
131
|
}, string, vue.PublicProps, Readonly<FormulaEditorProps> & Readonly<{
|
|
132
|
-
onChange?: ((value: string) => any) | undefined;
|
|
133
132
|
"onUpdate:modelValue"?: ((value: string) => any) | undefined;
|
|
133
|
+
onChange?: ((value: string) => any) | undefined;
|
|
134
134
|
"onValidation-change"?: ((result: FormulaValidation) => any) | undefined;
|
|
135
135
|
}>, {
|
|
136
|
-
showPreview: boolean;
|
|
137
136
|
disabled: boolean;
|
|
137
|
+
showPreview: boolean;
|
|
138
138
|
showKeyboard: boolean;
|
|
139
139
|
showVariablePanel: boolean;
|
|
140
140
|
editableSampleData: boolean;
|
package/dist/constants5.d.cts
CHANGED
|
@@ -262,8 +262,8 @@ type PlayerInstance = InstanceType<typeof xgplayer.default>;
|
|
|
262
262
|
//#endregion
|
|
263
263
|
//#region src/components/C_VideoPlayer/index.vue.d.ts
|
|
264
264
|
declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
265
|
-
ready: () => any;
|
|
266
265
|
error: (error: Error) => any;
|
|
266
|
+
ready: () => any;
|
|
267
267
|
ended: () => any;
|
|
268
268
|
stateChange: (state: PlayerState) => any;
|
|
269
269
|
qualityChange: (quality: QualityLevel) => any;
|
|
@@ -275,8 +275,8 @@ declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExp
|
|
|
275
275
|
quizAnswer: (quizId: string, answer: string | string[], isCorrect: boolean) => any;
|
|
276
276
|
timeUpdate: (currentTime: number, duration: number) => any;
|
|
277
277
|
}, string, vue.PublicProps, Readonly<VideoPlayerProps> & Readonly<{
|
|
278
|
-
onReady?: (() => any) | undefined;
|
|
279
278
|
onError?: ((error: Error) => any) | undefined;
|
|
279
|
+
onReady?: (() => any) | undefined;
|
|
280
280
|
onEnded?: (() => any) | undefined;
|
|
281
281
|
onStateChange?: ((state: PlayerState) => any) | undefined;
|
|
282
282
|
onQualityChange?: ((quality: QualityLevel) => any) | undefined;
|
package/dist/constants5.d.ts
CHANGED
|
@@ -262,8 +262,8 @@ type PlayerInstance = InstanceType<typeof xgplayer.default>;
|
|
|
262
262
|
//#endregion
|
|
263
263
|
//#region src/components/C_VideoPlayer/index.vue.d.ts
|
|
264
264
|
declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExpose, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
265
|
-
ready: () => any;
|
|
266
265
|
error: (error: Error) => any;
|
|
266
|
+
ready: () => any;
|
|
267
267
|
ended: () => any;
|
|
268
268
|
stateChange: (state: PlayerState) => any;
|
|
269
269
|
qualityChange: (quality: QualityLevel) => any;
|
|
@@ -275,8 +275,8 @@ declare const __VLS_export: vue.DefineComponent<VideoPlayerProps, VideoPlayerExp
|
|
|
275
275
|
quizAnswer: (quizId: string, answer: string | string[], isCorrect: boolean) => any;
|
|
276
276
|
timeUpdate: (currentTime: number, duration: number) => any;
|
|
277
277
|
}, string, vue.PublicProps, Readonly<VideoPlayerProps> & Readonly<{
|
|
278
|
-
onReady?: (() => any) | undefined;
|
|
279
278
|
onError?: ((error: Error) => any) | undefined;
|
|
279
|
+
onReady?: (() => any) | undefined;
|
|
280
280
|
onEnded?: (() => any) | undefined;
|
|
281
281
|
onStateChange?: ((state: PlayerState) => any) | undefined;
|
|
282
282
|
onQualityChange?: ((quality: QualityLevel) => any) | undefined;
|
package/dist/data2.d.cts
CHANGED
|
@@ -65,27 +65,27 @@ type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_37>]?: (props: typeof _
|
|
|
65
65
|
declare const __VLS_base: vue.DefineComponent<CTabsProps, {
|
|
66
66
|
activeValue: vue.WritableComputedRef<TabsValue | null, TabsValue | null>;
|
|
67
67
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
68
|
-
close: (value: TabsValue) => any;
|
|
69
|
-
add: () => any;
|
|
70
|
-
change: (value: TabsValue, item: TabsItem | undefined) => any;
|
|
71
68
|
"update:modelValue": (value: TabsValue) => any;
|
|
69
|
+
change: (value: TabsValue, item: TabsItem | undefined) => any;
|
|
70
|
+
add: () => any;
|
|
71
|
+
close: (value: TabsValue) => any;
|
|
72
72
|
}, string, vue.PublicProps, Readonly<CTabsProps> & Readonly<{
|
|
73
|
-
onClose?: ((value: TabsValue) => any) | undefined;
|
|
74
|
-
onAdd?: (() => any) | undefined;
|
|
75
|
-
onChange?: ((value: TabsValue, item: TabsItem | undefined) => any) | undefined;
|
|
76
73
|
"onUpdate:modelValue"?: ((value: TabsValue) => any) | undefined;
|
|
74
|
+
onChange?: ((value: TabsValue, item: TabsItem | undefined) => any) | undefined;
|
|
75
|
+
onAdd?: (() => any) | undefined;
|
|
76
|
+
onClose?: ((value: TabsValue) => any) | undefined;
|
|
77
77
|
}>, {
|
|
78
|
+
modelValue: TabsValue | null;
|
|
78
79
|
type: TabsType;
|
|
79
80
|
size: TabsSize;
|
|
80
81
|
defaultValue: TabsValue | null;
|
|
81
|
-
items: readonly TabsItem[];
|
|
82
|
-
modelValue: TabsValue | null;
|
|
83
82
|
placement: TabsPlacement;
|
|
84
83
|
displayDirective: TabsDisplayDirective;
|
|
84
|
+
items: readonly TabsItem[];
|
|
85
85
|
animated: boolean;
|
|
86
|
-
addable: boolean;
|
|
87
86
|
closable: boolean;
|
|
88
87
|
justifyContent: TabsJustifyContent;
|
|
88
|
+
addable: boolean;
|
|
89
89
|
tabsOnly: boolean;
|
|
90
90
|
paneClass: string;
|
|
91
91
|
paneStyle: string | vue.CSSProperties;
|
package/dist/data2.d.ts
CHANGED
|
@@ -65,27 +65,27 @@ type __VLS_Slots = {} & { [K in NonNullable<typeof __VLS_37>]?: (props: typeof _
|
|
|
65
65
|
declare const __VLS_base: vue.DefineComponent<CTabsProps, {
|
|
66
66
|
activeValue: vue.WritableComputedRef<TabsValue | null, TabsValue | null>;
|
|
67
67
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
68
|
-
close: (value: TabsValue) => any;
|
|
69
|
-
add: () => any;
|
|
70
|
-
change: (value: TabsValue, item: TabsItem | undefined) => any;
|
|
71
68
|
"update:modelValue": (value: TabsValue) => any;
|
|
69
|
+
change: (value: TabsValue, item: TabsItem | undefined) => any;
|
|
70
|
+
add: () => any;
|
|
71
|
+
close: (value: TabsValue) => any;
|
|
72
72
|
}, string, vue.PublicProps, Readonly<CTabsProps> & Readonly<{
|
|
73
|
-
onClose?: ((value: TabsValue) => any) | undefined;
|
|
74
|
-
onAdd?: (() => any) | undefined;
|
|
75
|
-
onChange?: ((value: TabsValue, item: TabsItem | undefined) => any) | undefined;
|
|
76
73
|
"onUpdate:modelValue"?: ((value: TabsValue) => any) | undefined;
|
|
74
|
+
onChange?: ((value: TabsValue, item: TabsItem | undefined) => any) | undefined;
|
|
75
|
+
onAdd?: (() => any) | undefined;
|
|
76
|
+
onClose?: ((value: TabsValue) => any) | undefined;
|
|
77
77
|
}>, {
|
|
78
|
+
modelValue: TabsValue | null;
|
|
78
79
|
type: TabsType;
|
|
79
80
|
size: TabsSize;
|
|
80
81
|
defaultValue: TabsValue | null;
|
|
81
|
-
items: readonly TabsItem[];
|
|
82
|
-
modelValue: TabsValue | null;
|
|
83
82
|
placement: TabsPlacement;
|
|
84
83
|
displayDirective: TabsDisplayDirective;
|
|
84
|
+
items: readonly TabsItem[];
|
|
85
85
|
animated: boolean;
|
|
86
|
-
addable: boolean;
|
|
87
86
|
closable: boolean;
|
|
88
87
|
justifyContent: TabsJustifyContent;
|
|
88
|
+
addable: boolean;
|
|
89
89
|
tabsOnly: boolean;
|
|
90
90
|
paneClass: string;
|
|
91
91
|
paneStyle: string | vue.CSSProperties;
|
package/dist/index.vue.d.cts
CHANGED
|
@@ -61,23 +61,23 @@ type __VLS_Props = {
|
|
|
61
61
|
};
|
|
62
62
|
declare const __VLS_export: vue.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
63
63
|
error: (error: unknown) => any;
|
|
64
|
+
ended: (index: number) => any;
|
|
64
65
|
play: (index: number) => any;
|
|
65
66
|
pause: () => any;
|
|
66
|
-
ended: (index: number) => any;
|
|
67
67
|
modeChange: (mode: string) => any;
|
|
68
68
|
}, string, vue.PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
69
69
|
onError?: ((error: unknown) => any) | undefined;
|
|
70
|
+
onEnded?: ((index: number) => any) | undefined;
|
|
70
71
|
onPlay?: ((index: number) => any) | undefined;
|
|
71
72
|
onPause?: (() => any) | undefined;
|
|
72
|
-
onEnded?: ((index: number) => any) | undefined;
|
|
73
73
|
onModeChange?: ((mode: string) => any) | undefined;
|
|
74
74
|
}>, {
|
|
75
75
|
theme: "default" | "minimal";
|
|
76
|
+
mode: "list" | "loop" | "single" | "shuffle";
|
|
77
|
+
autoplay: boolean;
|
|
76
78
|
initialIndex: number;
|
|
77
79
|
showPlaylist: boolean;
|
|
78
80
|
showCover: boolean;
|
|
79
|
-
autoplay: boolean;
|
|
80
|
-
mode: "list" | "loop" | "single" | "shuffle";
|
|
81
81
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
82
82
|
declare const _default: typeof __VLS_export;
|
|
83
83
|
//#endregion
|
package/dist/index.vue.d.ts
CHANGED
|
@@ -61,23 +61,23 @@ type __VLS_Props = {
|
|
|
61
61
|
};
|
|
62
62
|
declare const __VLS_export: vue.DefineComponent<__VLS_Props, {}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {
|
|
63
63
|
error: (error: unknown) => any;
|
|
64
|
+
ended: (index: number) => any;
|
|
64
65
|
play: (index: number) => any;
|
|
65
66
|
pause: () => any;
|
|
66
|
-
ended: (index: number) => any;
|
|
67
67
|
modeChange: (mode: string) => any;
|
|
68
68
|
}, string, vue.PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
69
69
|
onError?: ((error: unknown) => any) | undefined;
|
|
70
|
+
onEnded?: ((index: number) => any) | undefined;
|
|
70
71
|
onPlay?: ((index: number) => any) | undefined;
|
|
71
72
|
onPause?: (() => any) | undefined;
|
|
72
|
-
onEnded?: ((index: number) => any) | undefined;
|
|
73
73
|
onModeChange?: ((mode: string) => any) | undefined;
|
|
74
74
|
}>, {
|
|
75
75
|
theme: "default" | "minimal";
|
|
76
|
+
mode: "list" | "loop" | "single" | "shuffle";
|
|
77
|
+
autoplay: boolean;
|
|
76
78
|
initialIndex: number;
|
|
77
79
|
showPlaylist: boolean;
|
|
78
80
|
showCover: boolean;
|
|
79
|
-
autoplay: boolean;
|
|
80
|
-
mode: "list" | "loop" | "single" | "shuffle";
|
|
81
81
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
82
82
|
declare const _default: typeof __VLS_export;
|
|
83
83
|
//#endregion
|
package/dist/index10.vue.d.cts
CHANGED
|
@@ -32,9 +32,9 @@ declare const __VLS_export: vue.DefineComponent<Props, {
|
|
|
32
32
|
onCopy?: ((code: string) => any) | undefined;
|
|
33
33
|
}>, {
|
|
34
34
|
trim: boolean;
|
|
35
|
-
code: string;
|
|
36
|
-
language: string;
|
|
37
35
|
showHeader: boolean;
|
|
36
|
+
language: string;
|
|
37
|
+
code: string;
|
|
38
38
|
showLineNumbers: boolean;
|
|
39
39
|
wordWrap: boolean;
|
|
40
40
|
showFullscreen: boolean;
|
package/dist/index10.vue.d.ts
CHANGED
|
@@ -61,27 +61,27 @@ declare const __VLS_export: vue.DefineComponent<ContextMenuProps, {
|
|
|
61
61
|
close: () => void; /** 当前是否可见 */
|
|
62
62
|
visible: vue.ComputedRef<boolean>;
|
|
63
63
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
64
|
+
close: () => any;
|
|
65
|
+
select: (item: ContextMenuItem) => any;
|
|
64
66
|
open: (position: {
|
|
65
67
|
x: number;
|
|
66
68
|
y: number;
|
|
67
69
|
}) => any;
|
|
68
|
-
close: () => any;
|
|
69
|
-
select: (item: ContextMenuItem) => any;
|
|
70
70
|
}, string, vue.PublicProps, Readonly<ContextMenuProps> & Readonly<{
|
|
71
|
+
onClose?: (() => any) | undefined;
|
|
72
|
+
onSelect?: ((item: ContextMenuItem) => any) | undefined;
|
|
71
73
|
onOpen?: ((position: {
|
|
72
74
|
x: number;
|
|
73
75
|
y: number;
|
|
74
76
|
}) => any) | undefined;
|
|
75
|
-
onClose?: (() => any) | undefined;
|
|
76
|
-
onSelect?: ((item: ContextMenuItem) => any) | undefined;
|
|
77
77
|
}>, {
|
|
78
78
|
disabled: boolean;
|
|
79
|
-
minWidth: number;
|
|
80
79
|
items: ContextMenuItem[];
|
|
80
|
+
zIndex: number;
|
|
81
|
+
minWidth: number;
|
|
81
82
|
maxWidth: number;
|
|
82
83
|
subMenuPlacement: "right" | "left";
|
|
83
84
|
autoClose: boolean;
|
|
84
|
-
zIndex: number;
|
|
85
85
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
86
86
|
declare const _default: typeof __VLS_export;
|
|
87
87
|
//#endregion
|
package/dist/index11.vue.d.cts
CHANGED
|
@@ -61,27 +61,27 @@ declare const __VLS_export: vue.DefineComponent<ContextMenuProps, {
|
|
|
61
61
|
close: () => void; /** 当前是否可见 */
|
|
62
62
|
visible: vue.ComputedRef<boolean>;
|
|
63
63
|
}, {}, {}, {}, vue.ComponentOptionsMixin, vue.ComponentOptionsMixin, {} & {
|
|
64
|
+
close: () => any;
|
|
65
|
+
select: (item: ContextMenuItem) => any;
|
|
64
66
|
open: (position: {
|
|
65
67
|
x: number;
|
|
66
68
|
y: number;
|
|
67
69
|
}) => any;
|
|
68
|
-
close: () => any;
|
|
69
|
-
select: (item: ContextMenuItem) => any;
|
|
70
70
|
}, string, vue.PublicProps, Readonly<ContextMenuProps> & Readonly<{
|
|
71
|
+
onClose?: (() => any) | undefined;
|
|
72
|
+
onSelect?: ((item: ContextMenuItem) => any) | undefined;
|
|
71
73
|
onOpen?: ((position: {
|
|
72
74
|
x: number;
|
|
73
75
|
y: number;
|
|
74
76
|
}) => any) | undefined;
|
|
75
|
-
onClose?: (() => any) | undefined;
|
|
76
|
-
onSelect?: ((item: ContextMenuItem) => any) | undefined;
|
|
77
77
|
}>, {
|
|
78
78
|
disabled: boolean;
|
|
79
|
-
minWidth: number;
|
|
80
79
|
items: ContextMenuItem[];
|
|
80
|
+
zIndex: number;
|
|
81
|
+
minWidth: number;
|
|
81
82
|
maxWidth: number;
|
|
82
83
|
subMenuPlacement: "right" | "left";
|
|
83
84
|
autoClose: boolean;
|
|
84
|
-
zIndex: number;
|
|
85
85
|
}, {}, {}, {}, string, vue.ComponentProvideOptions, false, {}, any>;
|
|
86
86
|
declare const _default: typeof __VLS_export;
|
|
87
87
|
//#endregion
|
package/dist/index11.vue.d.ts
CHANGED
|
@@ -1109,8 +1109,8 @@ interface DataPickerEmits<T extends object> {
|
|
|
1109
1109
|
//#region src/components/C_DataPicker/index.vue.d.ts
|
|
1110
1110
|
declare const __VLS_export: <T extends object>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
1111
1111
|
props: vue.PublicProps & __VLS_PrettifyLocal<DataPickerProps<T> & {
|
|
1112
|
-
onSelect?: ((rows: T[]) => any) | undefined;
|
|
1113
1112
|
"onUpdate:modelValue"?: ((value: DataPickerValue | DataPickerValue[] | null) => any) | undefined;
|
|
1113
|
+
onSelect?: ((rows: T[]) => any) | undefined;
|
|
1114
1114
|
}> & (typeof globalThis extends {
|
|
1115
1115
|
__VLS_PROPS_FALLBACK: infer P;
|
|
1116
1116
|
} ? P : {});
|
|
@@ -1120,7 +1120,7 @@ declare const __VLS_export: <T extends object>(__VLS_props: NonNullable<Awaited<
|
|
|
1120
1120
|
}>) => void;
|
|
1121
1121
|
attrs: any;
|
|
1122
1122
|
slots: {};
|
|
1123
|
-
emit: ((evt: "
|
|
1123
|
+
emit: ((evt: "update:modelValue", value: DataPickerValue | DataPickerValue[] | null) => void) & ((evt: "select", rows: T[]) => void);
|
|
1124
1124
|
}>) => vue.VNode & {
|
|
1125
1125
|
__ctx?: NonNullable<Awaited<typeof __VLS_setup>>;
|
|
1126
1126
|
};
|