@fangzhongya/vue-archive 0.0.92 → 0.0.93
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/index.css +1 -1
- package/dist/node/index.cjs +1 -1
- package/dist/node/index.js +1 -1
- package/dist/packages/components/code/highlight.vue2.cjs +1 -1
- package/dist/packages/components/code/highlight.vue2.js +1 -1
- package/dist/packages/utils/glob.cjs +1 -1
- package/dist/packages/utils/glob.js +1 -1
- package/package.json +11 -11
- /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_dd6f49d866ebfd1af8876034987b0674 → @highlightjs_vue-plugin@2.1_f671e88abd525d7ca020aa9ff175b142}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.cjs +0 -0
- /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_dd6f49d866ebfd1af8876034987b0674 → @highlightjs_vue-plugin@2.1_f671e88abd525d7ca020aa9ff175b142}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.js +0 -0
package/dist/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
:root{--bor-cor: rgb(239, 248, 255);--but-cor: rgb(27, 155, 253);--but-hover-cor: rgb(0, 145, 255);--bg-but-hover-cor: rgb(128, 199, 253);--bg-aside-cor: rgb(228, 251, 197);--bg-aside-on-cor: rgb(78, 250, 87);--bg-index-cor: rgb(248, 248, 248);--bg-table-th-cor: rgb(207, 246, 251);--bg-table-td-cor: rgb(221, 243, 246);--bg-test-cor: rgb(236 255 236);--bg-test-err-cor: rgb(255, 210, 210);--bg-test-pro-cor: rgb(203, 246, 255);--bg-test-err-pro-cor: rgb(251, 203, 255);--te-test-err-cor: rgb(247, 56, 56);--te-test-pro-cor: rgb(106, 131, 255);--bg-test-body: rgb(255, 255, 255);--bg-code-highlig: rgb(255, 251, 223);--bg-code: rgb(255, 255, 255);--bg-box-cor: rgb(198, 198, 198);--bg-md-cor: rgb(255, 233, 243);--bg-use-cor: rgb(193, 219, 255);--bg-use-component-cor: rgb(246, 246, 246);--text-cor: rgb(0, 0, 0);--fs-1: 12px;--fs-2: 14px;--fs-3: 16px;--fs-4: 18px;--fs-5: 20px}.__document{position:fixed;top:0;left:0;width:100vw;height:100vh;overflow:auto;text-align:left;width:100%;height:100%;padding:0;margin:0}.__document .but-div{cursor:pointer
|
|
1
|
+
:root{--bor-cor: rgb(239, 248, 255);--but-cor: rgb(27, 155, 253);--but-hover-cor: rgb(0, 145, 255);--bg-but-hover-cor: rgb(128, 199, 253);--bg-aside-cor: rgb(228, 251, 197);--bg-aside-on-cor: rgb(78, 250, 87);--bg-index-cor: rgb(248, 248, 248);--bg-table-th-cor: rgb(207, 246, 251);--bg-table-td-cor: rgb(221, 243, 246);--bg-test-cor: rgb(236 255 236);--bg-test-err-cor: rgb(255, 210, 210);--bg-test-pro-cor: rgb(203, 246, 255);--bg-test-err-pro-cor: rgb(251, 203, 255);--te-test-err-cor: rgb(247, 56, 56);--te-test-pro-cor: rgb(106, 131, 255);--bg-test-body: rgb(255, 255, 255);--bg-code-highlig: rgb(255, 251, 223);--bg-code: rgb(255, 255, 255);--bg-box-cor: rgb(198, 198, 198);--bg-md-cor: rgb(255, 233, 243);--bg-use-cor: rgb(193, 219, 255);--bg-use-component-cor: rgb(246, 246, 246);--text-cor: rgb(0, 0, 0);--fs-1: 12px;--fs-2: 14px;--fs-3: 16px;--fs-4: 18px;--fs-5: 20px}.__document{position:fixed;top:0;left:0;width:100vw;height:100vh;overflow:auto;text-align:left;width:100%;height:100%;padding:0;margin:0}.__document .but-div{cursor:pointer}.__document .but-div:hover{color:var(--but-hover-cor);background-color:var(--bg-but-hover-cor)}.__document .but-div{color:var(--but-cor);padding:5px 10px}.__document .aside{width:250px;overflow:hidden;padding:20px 20px 20px 10px}.__document .aside .aside-li{padding:5px 10px;height:60px;font-size:20px;font-weight:600;border-bottom:1px solid var(--bor-cor);cursor:pointer}.__document .aside .aside-li:hover{color:var(--but-hover-cor);background-color:var(--bg-but-hover-cor)}.__document .aside .aside-li{display:flex;flex-direction:row;align-items:center}.__document .aside .aside-li.on{background-color:var(--bg-aside-on-cor)}.__document .aside .aside-li .aside-li-name{width:100%}.__document .aside .aside-li .aside-li-name .aside-li-name-alias{font-size:var(--fs-2)}.__document .aside .aside-li .aside-li-name .aside-li-name-aliass{font-size:var(--fs-1)}.__document .md{position:relative}.__document .use .use-component{padding:10px;display:flex;justify-content:center;align-items:center;height:300px;background-color:var(--bg-use-component-cor)}.__document .set-code .set-code-buts{display:flex;align-items:center}.__document .form-item.error{background-color:var(--te-test-err-cor)}.__document .compo .compo-top .compo-top-name{padding:10px;font-size:var(--fs-4)}.__document .compo .compo-top .compo-top-name .compo-top-name-li{font-size:var(--fs-2)}.__document .compo .compo-top .compo-top-info{padding:10px;display:flex;flex-direction:row;align-items:center}.__document .compo .compo-top .compo-top-info .compo-top-athor,.__document .compo .compo-top .compo-top-info .compo-top-date{flex:1;display:flex;flex-direction:row;align-items:center}.__document .compo .compo-top .compo-top-descriptions{padding:0 10px;font-size:var(--fs-2)}.__document .compo .compo-li h4{margin:10px 0 0;padding:10px}.__document .compo .compo-li .compo-talbe{width:100%}.__document .compo .compo-li .compo-talbe .compo-talbe-body{border:1px solid var(--bor-cor);width:100%}.__document .compo .compo-li .compo-talbe .compo-talbe-body td,.__document .compo .compo-li .compo-talbe .compo-talbe-body th{padding:5px 10px;border-bottom:1px solid var(--bor-cor)}.__document .compo .compo-li .compo-talbe .compo-talbe-body th{background-color:var(--bg-table-th-cor)}.__document .compo .compo-li .compo-talbe .compo-talbe-body td{background-color:var(--bg-table-td-cor)}.__document .compo .compo-li .compo-talbe .compo-talbe-body tr:last-child td{border-bottom:0}.__document .compo .compo-li .compo-talbe .compo-talbe-body .compo-talbe-zw{width:100%;text-align:center;padding:10px}.__document .compo .compo-md{padding:10px;background-color:var(--bg-md-cor)}.__document .compo .compo-use{padding:10px;background-color:var(--bg-use-cor)}.__document .main .main-but{text-align:right;display:flex;flex-direction:row;align-items:center}.__document .test.error .test-top{background-color:var(--bg-test-err-cor)}.__document .test.proposal .test-top{background-color:var(--bg-test-pro-cor)}.__document .test.error-proposal .test-top{background-color:var(--bg-test-err-pro-cor)}.__document .test .test-top{padding:5px;background-color:var(--bg-test-cor)}.__document .test .test-top .test-top-error{color:var(--te-test-err-cor)}.__document .test .test-top .test-top-proposal{color:var(--te-test-pro-cor)}.__document .test .test-div .test-body{padding:5px;background-color:var(--bg-test-body)}.__document .code{padding:0}.__document .code .code-top .code-top-but,.__document .code .code-top .code-top-but .top-but-files{display:flex;flex-direction:row;align-items:center}.__document .code .code-highlightjs{padding:0}.__document .code .code-highlightjs .hljs{background-color:var(--bg-code-highlig)}.__document .box-url{position:relative}.__document .box-url:hover .box-url-box{display:block}.__document .box-url .box-url-box{position:fixed;top:25px;display:none;background-color:var(--bg-box-cor);font-size:var(--fs-1);color:var(--text-cor);z-index:100000}.__document .box-url .box-url-box .box-div-li{height:20px;line-height:20px;display:flex;flex-direction:row;align-items:center}.__document .box-url .box-url-box .box-div-li .box-div-li-span{white-space:nowrap;padding:5px 10px}.__document .box-url .box-url-box .box-div-but{padding:10px;cursor:pointer}.__document .box-url .box-url-box .box-div-but:hover{color:var(--but-hover-cor);background-color:var(--bg-but-hover-cor)}.__document .box-url .box-url-box .box-div-but{color:var(--but-cor)}.__document .__document-index{width:100%;height:100%;padding:0;margin:0;display:flex;flex-direction:row}.__document .__document-index .index-aside{position:relative;z-index:100}.__document .__document-index .index-aside .index-aside-div{height:100%;overflow-y:auto;background-color:var(--bg-aside-cor)}.__document .__document-index .index-body{flex:1;position:relative;background-color:var(--bg-index-cor)}.__document .__document-index .index-body .index-div{padding:20px;position:absolute;inset:0;overflow-y:auto}.__document .__document-tests{padding:10px;height:100%;position:relative}.__document .__document-tests .tests-top .but-div.on{background-color:var(--bg-aside-on-cor)}.__document .__document-develop,.__document .__document-single{padding:10px;height:100%;position:relative}.__document .__document-single .single-top .single-top-li{display:flex;flex-direction:row;align-items:center}.__document .__document-single .single-top .single-top-li .single-top-li-span{padding:5px 10px}.__document .__document-compon{box-sizing:border-box;height:100%;width:100%;position:relative;display:flex}.__document .__document-compon .__document-compon-body{padding:10px;flex:1;overflow-y:auto}.__document .__document-compon .__document-compon-body.choice{padding-left:30px}.__document .__document-compon .__document-compon-choice{display:flex;overflow-y:auto;background-color:var(--bg-aside-cor)}.__document .__document-compon .__document-compon-choice .__document-compon-choice-but{cursor:pointer}.__document .__document-compon .__document-compon-choice .__document-compon-choice-but:hover{color:var(--but-hover-cor);background-color:var(--bg-but-hover-cor)}.form-input-text{padding:10px;height:160px;width:100%;box-sizing:border-box}.editor-div{padding:10px;height:160px;background-color:#eee}.editor-div .editor-code{height:100%;width:100%;min-height:80px;background-color:#fff}.form-input{font-size:16px}.form-select{position:relative;font-size:16px}.form-select .form-select-input{padding:10px;width:100%;font-size:16px;box-sizing:border-box}.form-select .form-select-box{position:absolute;width:100%;z-index:100;background-color:#000;text-align:center}.form-select .form-select-box .form-select-list-div{border:1px solid #000000}.form-select .form-select-box .form-select-list-div .form-select-list-li{background-color:#e9e9e9;padding:10px;cursor:pointer;border-bottom:1px solid #000000}.form-select{position:relative}.form-select .form-select-box{position:absolute;background-color:#fff;text-align:center}.form-select .form-select-box .form-select-list-div{border:1px solid #fff}.form-select .form-select-box .form-select-list-div .form-select-list-li{padding:10px;border-bottom:1px solid #eee}.form-select .form-select-box .form-select-list-div .form-select-list-li:last-child{border:0}.form-select .form-select-box .form-select-list-div .form-select-list-li.active{color:#0051ff}.form-boolean{display:flex;font-size:16px;padding:10px}.form-boolean .form-boolean-div{margin-right:10px}.form-string{font-size:16px}.form-string .form-string-text{padding:10px;width:100%;box-sizing:border-box}.form-number{font-size:16px}.form-number .form-number-input{padding:10px;width:100%;box-sizing:border-box}.set-emit .set-emit-li{padding:10px}.set-emit .set-emit-name{font-size:18px;padding:5px 0}.set-emit .set-emit-value{font-size:16px;background-color:azure}pre code.hljs{display:block;overflow-x:auto;padding:1em}code.hljs{padding:3px 5px}/*!
|
|
2
2
|
Theme: StackOverflow Light
|
|
3
3
|
Description: Light theme as used on stackoverflow.com
|
|
4
4
|
Author: stackoverflow.com
|
package/dist/node/index.cjs
CHANGED
|
@@ -2146,7 +2146,7 @@ function getTestArrs(arr, com, exa) {
|
|
|
2146
2146
|
"/([^/]+)\\." + defaultExtensions.join("|") + "$"
|
|
2147
2147
|
);
|
|
2148
2148
|
let ms = key.match(reg) || key.match(reg2);
|
|
2149
|
-
if (ms && ms
|
|
2149
|
+
if (ms && ms[1]) {
|
|
2150
2150
|
let value = "";
|
|
2151
2151
|
if (ms && ms.length > 1) {
|
|
2152
2152
|
value = ms[1];
|
package/dist/node/index.js
CHANGED
|
@@ -2128,7 +2128,7 @@ function getTestArrs(arr, com, exa) {
|
|
|
2128
2128
|
"/([^/]+)\\." + defaultExtensions.join("|") + "$"
|
|
2129
2129
|
);
|
|
2130
2130
|
let ms = key.match(reg) || key.match(reg2);
|
|
2131
|
-
if (ms && ms
|
|
2131
|
+
if (ms && ms[1]) {
|
|
2132
2132
|
let value = "";
|
|
2133
2133
|
if (ms && ms.length > 1) {
|
|
2134
2134
|
value = ms[1];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";;/* empty css */require("../../../_virtual/common.cjs");const e=require("../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.
|
|
1
|
+
"use strict";;/* empty css */require("../../../_virtual/common.cjs");const e=require("../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.1_f671e88abd525d7ca020aa9ff175b142/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.cjs"),n=require("vue"),t=n.defineComponent({props:{language:{type:String},code:{type:String}},components:{highlightjs:e.component}});module.exports=t;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* empty css */
|
|
2
2
|
import "../../../_virtual/common.js";
|
|
3
|
-
import o from "../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.
|
|
3
|
+
import o from "../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.1_f671e88abd525d7ca020aa9ff175b142/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.js";
|
|
4
4
|
import { defineComponent as t } from "vue";
|
|
5
5
|
const m = t({
|
|
6
6
|
props: {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("../config.cjs"),B=require("@fangzhongya/utils/html/getVueText"),c=require("./common.cjs"),F=require("@fangzhongya/utils/basic/object/mergeObject");require("@fangzhongya/utils/basic/array/toggleArray");const T=require("@fangzhongya/utils/name/humpToLine"),A=require("@fangzhongya/utils/name/lineToLargeHump");require("@fangzhongya/utils/basic/string/appearNum");const W=require("@fangzhongya/utils/basic/string/firstLower"),D=require("@fangzhongya/utils/basic/array/duplicateRemoval"),M=require("@fangzhongya/utils/basic/array/asyncMergeArray");require("@fangzhongya/utils/basic/string/firstUpper");const w=require("@fangzhongya/utils/urls/getSuffix");require("@fangzhongya/utils/basic/array/replaceAfter");const J=require("./index.cjs"),h={},R={},I=[],K={},j={},g={};function Q(){return q.getConfig("example")}function X(t,e,n,r){const a=F.mergeObject(e,n||{},3,!0);a.exampless=a.exampless||[],a.examplessRaw=a.examplessRaw||[];const s=[],i=a.examples;i&&Object.keys(i).forEach(o=>{s.push(o),j[o]=i[o]});const l=a.examplesRaw,u=[];if(a.urls&&a.urls.length>0?(a.exampless=a.urls,a.urls.forEach(o=>{u.push(o),l&&(g[o]=N(l,o))})):(a.exampless=s,l&&Object.keys(l).forEach(o=>{u.push(o),g[o]=N(l,o)})),a.examples=void 0,e.tests&&r){const o=e.testsNanme||"/tests/";typeof o=="string"?Object.keys(r).forEach(f=>{f.includes(o)&&(a.exampless.push(f),u.push(f),g[f]=N(r,f))}):Object.keys(r).forEach(f=>{o.test(f)&&(a.exampless.push(f),u.push(f),g[f]=N(r,f))})}a.exampless=[...new Set(a.exampless)],a.examplessRaw=[...new Set(u)],a.examplesRaw=void 0,K[t]=a}function N(t,e){return typeof t=="function"?t:t&&(t[e]||t)}const b={};function Y(t){const e=q.getConfig("resolve");if(b[t])return b[t];for(let n of e)if(t.startsWith(n.find+"/")){const a=n.replacement.replaceAll("\\","/")+t.replace(n.find+"/","/");return b[t]=a,a}}async function Z(t,e){let n="";if(e=="vue"?n=B.getVueTexts(t).script:(e=="js"||e=="ts"||e=="")&&(n=t),n){const r=await J.getTextImport(n),a=[];return r&&r.length>0&&r.forEach(s=>{if(s)if(s.startsWith("./")||s.startsWith("../"))a.push(s);else{const i=Y(s);i&&a.push(i)}}),a}}function _(t){return new Promise(e=>{t?t.raw?e(t.raw):t.getRaw?t.getRaw(t).then(n=>{const r=C(n);t.raw=r,t.getRaw=null,e(r)}):e(""):e("")})}function U(t,e){t=(t||"")+"";let n="";switch(t){case"1":n=e.tdir+"/";break;case"2":n=e.adir+"/";break;case"3":n=e.tdir+"/"+e.adir+"/";break}return n}function z(t,e,n){t=(t||"")+"",n=(n||"")+"";let r=T.humpToLine(e.name),a=[];t==="1"?e.alias&&a.push(e.alias+"-"+r):t==="3"?e.alias&&e.alias+"":t==="4"?e.aliasNames?.forEach(i=>{a.push(T.humpToLine(i))}):t=="9"&&(a.push(r),e.aliasNames?.forEach(i=>{a.push(T.humpToLine(i))})),a.length==0&&a.push(r);let s=[];return n==="1"?a.forEach(i=>{let l=A.lineToLargeHump(i);s.push(l,W.firstLower(l))}):n==="2"?a.forEach(i=>{let l=A.lineToLargeHump(i);s.push(i,l,W.firstLower(l))}):s=[...a],s=[...new Set(s)],s}function y(t,e,n,r){const a=[];return n.examplessRaw.forEach(s=>{for(let i=0;i<e.length;i++){const l=e[i];if(s==t+l+n.md+".md"){a.push({cwd:n.cwd||r.cwd,topurl:t,comkey:r.key,suffix:w.getSuffix(s),name:r.name,value:l,key:s,raw:"",getRaw:c.getRawValue(g,s)});break}}}),a}function P(t){O();const e=h[t];if(e.tests&&Object.keys(e.tests).length>0)return e.tests;{const n=K[e.dir],r=n.dir+U(n.level||0,e),a=z(n.aliaslevel||0,e,n.componentName||0);e.mds=y(r,a,n,e);const s={};return n.exampless.forEach(i=>{for(let l=0;l<a.length;l++){const u=a[l];if(i.startsWith(r+u+"/")){const o=new RegExp("/([^/]+)/index\\."+c.defaultExtensions.join("|")+"$"),f=new RegExp("/([^/]+)\\."+c.defaultExtensions.join("|")+"$");let p=i.match(o)||i.match(f);if(p&&p.length>0){let m="";p&&p.length>1&&(m=p[1]),s[i]={topurl:r,name:u,value:m,suffix:w.getSuffix(i),comname:e.name,comkey:e.key,cwd:n.cwd||e.cwd,key:i,dir:e.dir,url:i,component:j[i],raw:"",getRaw:c.getRawValue(g,i)};break}}}}),n.tests&&k(s,e,n),e.tests=s,s}}function k(t,e,n){const r=e.url.substring(0,e.url.lastIndexOf("/"+e.value+"/"))+"/"+e.value,a=n.testsNanme||"/tests/";typeof a=="string"?n.examplessRaw.forEach(s=>{if(s.startsWith(r+"/")){if(s==r+n.md+".md")e.mds=e.mds||[],e.mds.push({cwd:e.cwd,topurl:r,comkey:e.key,suffix:w.getSuffix(s),name:e.name,value:e.value,key:s,raw:"",getRaw:c.getRawValue(g,s)});else if(s.startsWith(r+a)){const i=new RegExp("/([^/]+)/index\\."+c.defaultExtensions.join("|")+"$"),l=new RegExp("/([^/]+)\\."+c.defaultExtensions.join("|")+"$");let u=s.match(i)||s.match(l);if(u&&u
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("../config.cjs"),B=require("@fangzhongya/utils/html/getVueText"),c=require("./common.cjs"),F=require("@fangzhongya/utils/basic/object/mergeObject");require("@fangzhongya/utils/basic/array/toggleArray");const T=require("@fangzhongya/utils/name/humpToLine"),A=require("@fangzhongya/utils/name/lineToLargeHump");require("@fangzhongya/utils/basic/string/appearNum");const W=require("@fangzhongya/utils/basic/string/firstLower"),D=require("@fangzhongya/utils/basic/array/duplicateRemoval"),M=require("@fangzhongya/utils/basic/array/asyncMergeArray");require("@fangzhongya/utils/basic/string/firstUpper");const w=require("@fangzhongya/utils/urls/getSuffix");require("@fangzhongya/utils/basic/array/replaceAfter");const J=require("./index.cjs"),h={},R={},I=[],K={},j={},g={};function Q(){return q.getConfig("example")}function X(t,e,n,r){const a=F.mergeObject(e,n||{},3,!0);a.exampless=a.exampless||[],a.examplessRaw=a.examplessRaw||[];const s=[],i=a.examples;i&&Object.keys(i).forEach(o=>{s.push(o),j[o]=i[o]});const l=a.examplesRaw,u=[];if(a.urls&&a.urls.length>0?(a.exampless=a.urls,a.urls.forEach(o=>{u.push(o),l&&(g[o]=N(l,o))})):(a.exampless=s,l&&Object.keys(l).forEach(o=>{u.push(o),g[o]=N(l,o)})),a.examples=void 0,e.tests&&r){const o=e.testsNanme||"/tests/";typeof o=="string"?Object.keys(r).forEach(f=>{f.includes(o)&&(a.exampless.push(f),u.push(f),g[f]=N(r,f))}):Object.keys(r).forEach(f=>{o.test(f)&&(a.exampless.push(f),u.push(f),g[f]=N(r,f))})}a.exampless=[...new Set(a.exampless)],a.examplessRaw=[...new Set(u)],a.examplesRaw=void 0,K[t]=a}function N(t,e){return typeof t=="function"?t:t&&(t[e]||t)}const b={};function Y(t){const e=q.getConfig("resolve");if(b[t])return b[t];for(let n of e)if(t.startsWith(n.find+"/")){const a=n.replacement.replaceAll("\\","/")+t.replace(n.find+"/","/");return b[t]=a,a}}async function Z(t,e){let n="";if(e=="vue"?n=B.getVueTexts(t).script:(e=="js"||e=="ts"||e=="")&&(n=t),n){const r=await J.getTextImport(n),a=[];return r&&r.length>0&&r.forEach(s=>{if(s)if(s.startsWith("./")||s.startsWith("../"))a.push(s);else{const i=Y(s);i&&a.push(i)}}),a}}function _(t){return new Promise(e=>{t?t.raw?e(t.raw):t.getRaw?t.getRaw(t).then(n=>{const r=C(n);t.raw=r,t.getRaw=null,e(r)}):e(""):e("")})}function U(t,e){t=(t||"")+"";let n="";switch(t){case"1":n=e.tdir+"/";break;case"2":n=e.adir+"/";break;case"3":n=e.tdir+"/"+e.adir+"/";break}return n}function z(t,e,n){t=(t||"")+"",n=(n||"")+"";let r=T.humpToLine(e.name),a=[];t==="1"?e.alias&&a.push(e.alias+"-"+r):t==="3"?e.alias&&e.alias+"":t==="4"?e.aliasNames?.forEach(i=>{a.push(T.humpToLine(i))}):t=="9"&&(a.push(r),e.aliasNames?.forEach(i=>{a.push(T.humpToLine(i))})),a.length==0&&a.push(r);let s=[];return n==="1"?a.forEach(i=>{let l=A.lineToLargeHump(i);s.push(l,W.firstLower(l))}):n==="2"?a.forEach(i=>{let l=A.lineToLargeHump(i);s.push(i,l,W.firstLower(l))}):s=[...a],s=[...new Set(s)],s}function y(t,e,n,r){const a=[];return n.examplessRaw.forEach(s=>{for(let i=0;i<e.length;i++){const l=e[i];if(s==t+l+n.md+".md"){a.push({cwd:n.cwd||r.cwd,topurl:t,comkey:r.key,suffix:w.getSuffix(s),name:r.name,value:l,key:s,raw:"",getRaw:c.getRawValue(g,s)});break}}}),a}function P(t){O();const e=h[t];if(e.tests&&Object.keys(e.tests).length>0)return e.tests;{const n=K[e.dir],r=n.dir+U(n.level||0,e),a=z(n.aliaslevel||0,e,n.componentName||0);e.mds=y(r,a,n,e);const s={};return n.exampless.forEach(i=>{for(let l=0;l<a.length;l++){const u=a[l];if(i.startsWith(r+u+"/")){const o=new RegExp("/([^/]+)/index\\."+c.defaultExtensions.join("|")+"$"),f=new RegExp("/([^/]+)\\."+c.defaultExtensions.join("|")+"$");let p=i.match(o)||i.match(f);if(p&&p.length>0){let m="";p&&p.length>1&&(m=p[1]),s[i]={topurl:r,name:u,value:m,suffix:w.getSuffix(i),comname:e.name,comkey:e.key,cwd:n.cwd||e.cwd,key:i,dir:e.dir,url:i,component:j[i],raw:"",getRaw:c.getRawValue(g,i)};break}}}}),n.tests&&k(s,e,n),e.tests=s,s}}function k(t,e,n){const r=e.url.substring(0,e.url.lastIndexOf("/"+e.value+"/"))+"/"+e.value,a=n.testsNanme||"/tests/";typeof a=="string"?n.examplessRaw.forEach(s=>{if(s.startsWith(r+"/")){if(s==r+n.md+".md")e.mds=e.mds||[],e.mds.push({cwd:e.cwd,topurl:r,comkey:e.key,suffix:w.getSuffix(s),name:e.name,value:e.value,key:s,raw:"",getRaw:c.getRawValue(g,s)});else if(s.startsWith(r+a)){const i=new RegExp("/([^/]+)/index\\."+c.defaultExtensions.join("|")+"$"),l=new RegExp("/([^/]+)\\."+c.defaultExtensions.join("|")+"$");let u=s.match(i)||s.match(l);if(u&&u[1]){let o="";u&&u.length>1&&(o=u[1]),t[s]={topurl:r,name:e.value,value:o,suffix:w.getSuffix(s),comname:e.name,comkey:e.key,cwd:n.cwd||e.cwd,key:s,dir:e.dir,url:s,component:j[s],raw:"",getRaw:c.getRawValue(g,s)}}}}}):n.examplessRaw.forEach(s=>{if(s.startsWith(r+"/")){if(s==r+n.md+".md")e.mds=e.mds||[],e.mds.push({cwd:e.cwd,topurl:r,comkey:e.key,suffix:w.getSuffix(s),name:e.name,value:e.value,key:s,raw:"",getRaw:c.getRawValue(g,s)});else if(a.test(s)){const i=new RegExp("/([^/]+)/index\\."+c.defaultExtensions.join("|")+"$"),l=new RegExp("/([^/]+)\\."+c.defaultExtensions.join("|")+"$");let u=s.match(i)||s.match(l);if(u&&u.length>0){let o="";u&&u.length>1&&(o=u[1]),t[s]={cwd:n.cwd||e.cwd,topurl:r,name:e.value,value:o,suffix:w.getSuffix(s),comname:e.name,comkey:e.key,key:s,dir:e.dir,url:s,component:j[s],raw:"",getRaw:c.getRawValue(g,s)}}}}})}function ee(t){if(t){const e=P(t);return Object.values(e)}else return[]}function te(t,e,n){O();const r=P(n),a=[];if(e){let s=r[e];if(s)return a.push(s),a}return Object.values(r).forEach(s=>{s.name+"/"+s.value==t&&a.push(s)}),a}function se(t){return P(t),h[t].mds}async function V(t,e,n){let r=t.key,a=t.dir,s=t.url,i=t.comprops,l=t.curprops,u=await Z(e,n||t.suffix)||[],o=s.split("/");return u.map(f=>{if(f.startsWith("./")){let p=o.slice(0,o.length-1).join("/"),m=f.substring(2);const d=p.replace(/^\.\/|((\.\.\/)+)/,"/");let x=r.indexOf(d)+d.length;return{key:r.substring(0,x)+"/"+m,name:f,cwd:t.cwd,comprops:i,curprops:l,value:m,suffix:w.getSuffix(f),head:p,dir:a,url:p+"/"+m}}else if(f.startsWith("../")){let p=f.split("/"),m=0;for(let L=0;L<p.length;L++)if(p[L]!=".."){m=L;break}let d=p.slice(m,p.length),x=o.slice(0,o.length-m-1).join("/"),E=d.join("/");const S=x.replace(/^\.\/|((\.\.\/)+)/,"/");let G=r.indexOf(S)+S.length;return{key:r.substring(0,G)+"/"+E,name:E,cwd:t.cwd,comprops:i,curprops:l,value:E,suffix:w.getSuffix(f),head:x,dir:a,url:x+"/"+E}}else{const p=a.replace(/^\.\/|((\.\.\/)+)/,"/");let m=f.indexOf(p)+p.length,d=f.substring(m),x=a.substring(0,a.length-1);return{key:f,name:d,comprops:i,curprops:l,value:d,suffix:w.getSuffix(f),head:x,dir:a,cwd:t.cwd,url:x+"/"+d}}})}function ne(t){return new Promise(e=>{if(t&&t.length>0){let n=t.map(r=>({...r,raw:"",suffix:w.getSuffix(r.key),getRaw:c.getRawValue(g,r.key)}));M.asyncMergeArray(n,(r,a,s,i)=>{s.raw?r():s.getRaw?s.getRaw(s).then(l=>{const u=C(l);s.raw=u,s.getRaw=null,r()}):r()}).then(()=>{e(n)})}else e([])})}function re(){const t=Q();q.getConfig("components")?.forEach(n=>{const r=le(n);let a=n.dir||"";X(a,t,n.example,r)})}const $="default";function ae(t){let e=T.humpToLine(t.name),n=[...t.aliasNames];n.push(e),n.forEach(r=>{I.push({name:r,value:t.key})})}function ie(t,e){e?.forEach(n=>{h[n.key]=n,ae(n)})}function le(t){let e,n;const r=t.resolver;r&&Object.keys(r).forEach(s=>{typeof t[s]>"u"&&(t[s]=r[s])}),e=t.alias||$;let a=t?.urls||Object.keys(t.componentsRaw);return n=c.getComponentsArr(a,t,t.componentsRaw,t.components),n&&n?.props&&n.props.forEach(s=>{R[s.url]=s}),ie(e,n.components),t.componentsRaw}function oe(t){return O(),h[t]}function O(){return Object.keys(h).length==0&&re(),Object.values(h)}function ue(){return O(),R}function fe(t,e,n){O();const r=[];if(n){let s=h[n];if(s&&s.key)return[s]}let a=T.humpToLine(t);return I.forEach(s=>{e?s.name.includes(a)&&r.push(h[s.value]):s.name==a&&r.push(h[s.value])}),D.duplicateRemoval(r,"key")}async function ce(t,e){let n=t;if(t){let r=(await V(e,t)).filter(a=>c.isComprops(a.key,e.comprops)||c.isCurprops(a.key,e.curprops));n=await H(r)+n}return n}function pe(t){const e=t.url,n=t.key;return R[e]||R[e+".js"]||R[e+".ts"]||R[n]||R[n+".js"]||R[n+".ts"]}function v(t){return new Promise(e=>{if(t&&t.length>0){let n=t.map(r=>pe(r)).filter(r=>!!r);M.asyncMergeArray(n,(r,a,s,i)=>{s.raw?r():s.getRaw?s.getRaw(s).then(async l=>{const u=C(l);let o=await ce(u,t[i]);s.raw=o,s.getRaw=null,r()}):r()}).then(()=>{e(n)})}else e([])})}async function H(t){return((await v(t))?.map(r=>r.raw)||[]).join(`
|
|
2
2
|
`)}async function me(t,e){let n=t;if(t&&(e.comprops||e.curprops)){let r=(await V(e,t)).filter(s=>c.isComprops(s.key,e.comprops)||c.isCurprops(s.key,e.curprops));n=await H(r)+n}return n}function C(t){return t&&typeof t=="object"?t.default||"":(t||"")+""}function ge(t){return new Promise(e=>{if(t){O();const n=h[t];n?n.raw?e(n.raw):n.getRaw?n.getRaw(n).then(r=>{const a=C(r);me(a,n).then(s=>{n.raw=s,n.getRaw=null,e(s)})}):e(""):e("")}else e("")})}exports.defaultName=$;exports.getCompoName=fe;exports.getCompoNameKey=oe;exports.getCompoNameObj=O;exports.getComponentPropsObjs=ue;exports.getGetRawValue=C;exports.getKeyMds=se;exports.getLevelUrl=U;exports.getLocalTextArr=ne;exports.getLocalTextComponents=ge;exports.getLocalTextTests=_;exports.getPropsRaws=v;exports.getTestImportUrl=V;exports.getTestName=ee;exports.getTestNameObj=te;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fangzhongya/vue-archive",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.93",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description ": "vue 组件注释生成文档",
|
|
7
7
|
"author": "fangzhongya ",
|
|
@@ -18,39 +18,39 @@
|
|
|
18
18
|
"registry": "https://registry.npmjs.org/"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
|
-
"@codemirror/autocomplete": "6.18.
|
|
21
|
+
"@codemirror/autocomplete": "6.18.7",
|
|
22
22
|
"@codemirror/lang-css": "^6.3.1",
|
|
23
|
-
"@codemirror/lang-html": "^6.4.
|
|
23
|
+
"@codemirror/lang-html": "^6.4.10",
|
|
24
24
|
"@codemirror/lang-javascript": "^6.2.4",
|
|
25
25
|
"@codemirror/lang-json": "^6.0.2",
|
|
26
26
|
"@codemirror/state": "^6.5.2",
|
|
27
|
-
"@codemirror/view": "^6.38.
|
|
27
|
+
"@codemirror/view": "^6.38.2",
|
|
28
28
|
"@fangzhongya/create": "0.2.34",
|
|
29
29
|
"@fangzhongya/utils": "0.0.28",
|
|
30
30
|
"@fangzhongya/vue-components": "0.1.18",
|
|
31
31
|
"@highlightjs/vue-plugin": "^2.1.0",
|
|
32
|
-
"@types/node": "^24.
|
|
32
|
+
"@types/node": "^24.4.0",
|
|
33
33
|
"@vitejs/plugin-vue": "^6.0.1",
|
|
34
34
|
"codemirror": "^6.0.2",
|
|
35
35
|
"fast-glob": "^3.3.3",
|
|
36
|
-
"sass": "^1.
|
|
36
|
+
"sass": "^1.92.1",
|
|
37
37
|
"ts-node": "^10.9.2",
|
|
38
38
|
"tsup": "^8.5.0",
|
|
39
39
|
"typescript": "^5.9.2",
|
|
40
40
|
"unplugin-vue-components": "^29.0.0",
|
|
41
|
-
"vite": "^7.1.
|
|
41
|
+
"vite": "^7.1.5",
|
|
42
42
|
"vite-plugin-dts": "4.5.4",
|
|
43
43
|
"vitest": "^3.2.4",
|
|
44
|
-
"vue-tsc": "^3.0.
|
|
44
|
+
"vue-tsc": "^3.0.7"
|
|
45
45
|
},
|
|
46
46
|
"dependencies": {
|
|
47
47
|
"comment-parser": "^1.4.1",
|
|
48
48
|
"highlight.js": "^11.11.1",
|
|
49
49
|
"markdown-it": "^14.1.0",
|
|
50
|
-
"monaco-editor": "^0.
|
|
50
|
+
"monaco-editor": "^0.53.0",
|
|
51
51
|
"prettier": "^3.6.2",
|
|
52
|
-
"vue": "^3.5.
|
|
53
|
-
"vue-router": "^4.
|
|
52
|
+
"vue": "^3.5.21",
|
|
53
|
+
"vue-router": "^4.5.1"
|
|
54
54
|
},
|
|
55
55
|
"types": "./dist/packages/index.d.ts",
|
|
56
56
|
"main": "./dist/packages/index.cjs",
|
|
File without changes
|