@fangzhongya/vue-archive 0.0.27 → 0.0.28
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/node/index.cjs
CHANGED
|
@@ -3411,7 +3411,7 @@ function getSpecType(val) {
|
|
|
3411
3411
|
type = tarr[0].split("<")[0];
|
|
3412
3412
|
}
|
|
3413
3413
|
const zdtype = type;
|
|
3414
|
-
let selectable = (val
|
|
3414
|
+
let selectable = (val?.selectable || "").trim();
|
|
3415
3415
|
let arr = [];
|
|
3416
3416
|
if (selectable && type != "boolean") {
|
|
3417
3417
|
selectable.split(",").forEach((v) => {
|
package/dist/node/index.js
CHANGED
|
@@ -3396,7 +3396,7 @@ function getSpecType(val) {
|
|
|
3396
3396
|
type = tarr[0].split("<")[0];
|
|
3397
3397
|
}
|
|
3398
3398
|
const zdtype = type;
|
|
3399
|
-
let selectable = (val
|
|
3399
|
+
let selectable = (val?.selectable || "").trim();
|
|
3400
3400
|
let arr = [];
|
|
3401
3401
|
if (selectable && type != "boolean") {
|
|
3402
3402
|
selectable.split(",").forEach((v) => {
|
|
@@ -16,4 +16,4 @@ ${n.join(`
|
|
|
16
16
|
${g.vueFormat($," ")}
|
|
17
17
|
</template>`;e.push(f)}}),e&&e.length>0&&e.unshift(""),e}function F(s,t,e){const o=e?e[t]:"";return o||w(s.toString())}function w(s){const t=H.getFunctionFormat(g.prettierFormat(s));if(t){let e=`{
|
|
18
18
|
${g.vueFormat(g.getFunBody(t.body)," ")}
|
|
19
|
-
}`;return`function (${t.param}) ${e}`}else return"undefined"}function Z(s){const t=s.trim();return/^\(/.test(t)?w(t):JSON.stringify(s)}function E(s,t,e){const o=e?e[t]:"";return o||(typeof s=="string"?Z(s+""):JSON.stringify(s))}function D(s){let t=G(s?.type),e="any";t.length==1&&(e=t[0].split("<")[0]);const o=e;let h=(s
|
|
19
|
+
}`;return`function (${t.param}) ${e}`}else return"undefined"}function Z(s){const t=s.trim();return/^\(/.test(t)?w(t):JSON.stringify(s)}function E(s,t,e){const o=e?e[t]:"";return o||(typeof s=="string"?Z(s+""):JSON.stringify(s))}function D(s){let t=G(s?.type),e="any";t.length==1&&(e=t[0].split("<")[0]);const o=e;let h=(s?.selectable||"").trim(),$=[];return h&&e!="boolean"&&(h.split(",").forEach(f=>{if(f){let n=f.split(":");$.push({label:f,prop:n[0].trim()})}}),e=="function"?e="function":e=="array"?e="choice":e="select"),{arr:$,zdtype:o,type:e,dataType:t}}function G(s){let t=[];return(s||"").trim().toLowerCase().split(",").forEach(o=>{o=o.trim(),o&&t.push(o)}),[...new Set(t)].sort()}exports.getHmtl=A;exports.getSpecType=D;exports.setValStringify=E;
|
|
@@ -146,7 +146,7 @@ function X(s) {
|
|
|
146
146
|
let e = Y(s?.type), t = "any";
|
|
147
147
|
e.length == 1 && (t = e[0].split("<")[0]);
|
|
148
148
|
const r = t;
|
|
149
|
-
let h = (s
|
|
149
|
+
let h = (s?.selectable || "").trim(), $ = [];
|
|
150
150
|
return h && t != "boolean" && (h.split(",").forEach((l) => {
|
|
151
151
|
if (l) {
|
|
152
152
|
let n = l.split(":");
|