cnhis-design-vue 3.1.41-beta.5 → 3.1.41-beta.6
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
import{reactive as e,defineComponent as t,inject as r,provide as n,computed as o,watch as l,onUnmounted as
|
|
1
|
+
import{reactive as e,defineComponent as t,inject as r,provide as n,computed as o,watch as l,onUnmounted as s,onMounted as a,withModifiers as i,createVNode as u,mergeProps as c}from"vue";import{checkInSetupEnv as p}from"../../../../shared/utils/index.js";import{useField as d,useForm as m,RecursionField as f}from"@formily/vue";import{noop as v,isArray as h,isNumber as y}from"lodash-es";import"../../index.js";import{InjectionFormUUID as b,InjectionBusinessCollector as j}from"../constants/index.js";import{useFieldListAdaptor as x}from"./useFieldListAdaptor.js";import{createObjSchema as g}from"../utils/schema.js";const F=e(new Map);function O(e,t,r=0){F.set(e,F.get(e)||{});F.get(e)[t+""]=r}function $(e,t,r=!0){const n=F.get(e);return n?Object.entries(n).reduce(((e,[n,o])=>r&&n===`${t}`||n.startsWith(`${t}.`)?e+o:e),0):0}function E(e,t){const r=F.get(e);r&&Reflect.deleteProperty(r,t+"")}function K(e){F.delete(e)}const P=t({props:{fieldItems:{type:Array,default:()=>[]},name:{type:String,required:!0}},setup(e){const t=r(b),p=r(j),h=d(),y=r(t+"_virtualParent",""),F=`${y?y+".":""}${h.value.address}`;function K(e){return`${F}.${e}`}n(t+"_virtualParent",F);const{schemaAdaptor:P}=x(p);function S(e){return Object.assign(e,{"x-decorator-props":{...e["x-decorator-props"],labelPlacement:"left",showFeedback:!1,showLabel:!!e.title},"x-component-props":{...e["x-component-props"],size:"small"}})}const _=o((()=>{const t=P(e.fieldItems);return Object.values(t).forEach(S),g(t)}));l(_,(()=>{return e=_.value,void Object.values(e.properties||{}).forEach((e=>{var r;O(t,K(e.name),null==(r=null==e?void 0:e["x-decorator-props"])?void 0:r.span)}));var e}),{immediate:!0});const k=m();function w(){return e.fieldItems.map((e=>k.value.query(e.val_key).take()))}s((()=>{var e;w().forEach((e=>{e&&(e.display="none")})),e=_.value,Object.values(e.properties||{}).forEach((e=>{E(t,K(e.name))}))})),a((()=>{w().forEach((e=>{e&&(e.display="visible")}))}));const I=i(v,["stop"]),A=["onClick","onKeydown","onKeyup","onKeypress"].reduce(((e,t)=>(e[t]=I,e)),{});return()=>{return u("section",c({class:"form-render__labelField",style:{"--column":(e=_.value,Object.values(e.properties||{}).reduce(((e,r)=>e+$(t,K(r.name))),0))}},A),[u(f,{basePath:".",schema:_.value},null)]);var e}}});function S(e,t){p();const r=o((()=>e.options.some((e=>h(e.childrenFields)&&e.childrenFields.length))));function n(e,t,r="value"){if(h(e)?e.includes(t[r]):e===t[r])return h(t.childrenFields)&&t.childrenFields.length}return{renderComplexOption:function({value:e,option:t,valueKey:o="value",labelKey:l="label"}){return[t[l],r.value&&n(e,t,o)?u(P,{fieldItems:t.childrenFields,name:t[o]},null):null]},valueRef:o({get(){return t=e.value,y(t)?t+"":t;var t},set(e){t("update:value",e)}}),hasComplexOption:r}}function _(){return{getSpan:$,setSpan:O,deleteSpan:E,clearSpan:K}}export{S as useComplexOptions,_ as useComplexOptionsSpan};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{COMPONENT_NAMESPACE as s}from"../../shared/global/variable.js";import{safeComponentRegister as o}from"../../shared/utils/index.js";import t from"./src/IhoTable.vue.js";import
|
|
1
|
+
import{COMPONENT_NAMESPACE as s}from"../../shared/global/variable.js";import{safeComponentRegister as o}from"../../shared/utils/index.js";import{once as t}from"lodash-es";import e from"./src/IhoTable.vue.js";import a from"./src/plugins/index.js";import"vue";import"./src/constants/index.js";import"@vueuse/shared";import"../../shared/utils/tapable/SyncHook.js";import"../../shared/utils/tapable/SyncBailHook.js";import"../../shared/utils/tapable/SyncWaterfallHook.js";import"../../shared/utils/tapable/SyncLoopHook.js";import"../../shared/utils/tapable/AsyncParallelHook.js";import"../../shared/utils/tapable/AsyncParallelBailHook.js";import"../../shared/utils/tapable/AsyncSeriesHook.js";import"../../shared/utils/tapable/AsyncSeriesBailHook.js";import"../../shared/utils/tapable/AsyncSeriesLoopHook.js";import"../../shared/utils/tapable/AsyncSeriesWaterfallHook.js";export{AbstractConfigHooks,AbstractDataHooks,AbstractDomInsertHooks,AbstractEventHooks,AbstractExposeHooks,AbstractFieldHooks,AbstractSetupHooks}from"./src/types/pluginType.js";import{useTablePlugin as r}from"./src/hooks/useTablePlugin.js";export{defineTablePlugin,useTablePlugin}from"./src/hooks/useTablePlugin.js";export{useColumnConfigAdaptor}from"./src/hooks/useColumnConfigAdaptor.js";const{use:l}=r(),i=t((s=>{l(Object.values(a).map((s=>s())),s)})),p=e;p.install=function(t){o(t,p,s+"IhoTable")};export{p as default,i as useIhoTablePresetPlugins};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createVNode as e}from"vue";import"../../../../index.js";import{WIDGET_TYPE as r}from"../../../constants/index.js";import{getRowHeight as n}from"../../../utils/index.js";import{defineTablePlugin as o}from"../../../hooks/useTablePlugin.js";function l(){const l={blue:"blue",sky:"skyblue",azure:"azure",palegreen:"palegreen",yellow:"yellow",darkorange:"darkorange",magenta:"magenta",purple:"purple",maroon:"maroon",orange:"orange",green:"green",red:"red",grey:"grey"};return o({name:"
|
|
1
|
+
import{createVNode as e}from"vue";import"../../../../index.js";import{WIDGET_TYPE as r}from"../../../constants/index.js";import{getRowHeight as n}from"../../../utils/index.js";import{defineTablePlugin as o}from"../../../hooks/useTablePlugin.js";function l(){const l={blue:"blue",sky:"skyblue",azure:"azure",palegreen:"palegreen",yellow:"yellow",darkorange:"darkorange",magenta:"magenta",purple:"purple",maroon:"maroon",orange:"orange",green:"green",red:"red",grey:"grey"};return o({name:"colorRendererPlugin",vxe(o){o.renderer.add(r.COLOR,{renderCell(r,{row:o,column:a}){const t=o[a.field];if(!t)return[];const[u,i]=t.split("-");return[e("div",{style:{background:l[i]||u,height:n()-8+"px"}},null)]}})}})}export{l as colorRendererPlugin};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "cnhis-design-vue",
|
|
3
|
-
"version": "3.1.41-beta.
|
|
3
|
+
"version": "3.1.41-beta.6",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"module": "./es/components/index.js",
|
|
6
6
|
"main": "./es/components/index.js",
|
|
@@ -61,5 +61,5 @@
|
|
|
61
61
|
"iOS 7",
|
|
62
62
|
"last 3 iOS versions"
|
|
63
63
|
],
|
|
64
|
-
"gitHead": "
|
|
64
|
+
"gitHead": "700fb2f0e1c77a5b92d736338257f497347aaa9a"
|
|
65
65
|
}
|