component-library-for-vue 2.0.2 → 2.1.0

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/README.md CHANGED
@@ -389,3 +389,280 @@ PcDialog
389
389
  2️⃣ `buttons` 会自动渲染 `PcButton`
390
390
  3️⃣ 如果不传 `default slot`,内容区域不会显示
391
391
  4️⃣ 按下 `ESC` 或点击关闭按钮会触发 `close`
392
+
393
+
394
+ # 📘 PcTabs(用户使用指南)
395
+
396
+ ## 👋 组件介绍
397
+
398
+ `PcTabs` 是一个简单易用的标签页组件,适用于页面内容切换场景,支持:
399
+
400
+ * 横向 / 纵向布局切换
401
+ * 内容插槽灵活扩展
402
+ * 状态缓存(切换不丢数据)
403
+ * 平滑的 tab 指示动画
404
+
405
+ ---
406
+
407
+ ### 1️⃣ 引入组件
408
+
409
+ ```js
410
+ components: {
411
+ PcTabs
412
+ }
413
+ ```
414
+
415
+ ---
416
+
417
+ ### 2️⃣ 基础使用
418
+
419
+ ```vue
420
+ <template>
421
+ <PcTabs v-model="activeTab" :tabs="tabs">
422
+ <template #tab1>
423
+ <div>这是 Tab1 内容</div>
424
+ </template>
425
+
426
+ <template #tab2>
427
+ <div>这是 Tab2 内容</div>
428
+ </template>
429
+ </PcTabs>
430
+ </template>
431
+
432
+ <script>
433
+ export default {
434
+ data() {
435
+ return {
436
+ activeTab: 'tab1',
437
+ tabs: [
438
+ { label: 'Tab1', value: 'tab1' },
439
+ { label: 'Tab2', value: 'tab2' }
440
+ ]
441
+ }
442
+ }
443
+ }
444
+ </script>
445
+ ```
446
+
447
+ ---
448
+
449
+ ## 📌 参数说明(Props)
450
+
451
+ | 参数 | 说明 | 类型 | 默认值 |
452
+ | --------- | --------- | ------- | ---------- |
453
+ | v-model | 当前选中的 tab | String | — |
454
+ | tabs | tab 列表数据 | Array | [] |
455
+ | keepAlive | 是否缓存内容 | Boolean | true |
456
+ | direction | 布局方向 | String | horizontal |
457
+
458
+ ---
459
+
460
+ ## 📊 tabs 数据格式
461
+
462
+ ```js
463
+ [
464
+ {
465
+ label: '用户信息',
466
+ value: 'user'
467
+ },
468
+ {
469
+ label: '订单列表',
470
+ value: 'order'
471
+ }
472
+ ]
473
+ ```
474
+
475
+ ---
476
+
477
+ ## 🎯 插槽使用(重点)
478
+
479
+ 每个 tab 的内容通过 **具名插槽** 渲染:
480
+
481
+ ```vue
482
+ <template #user>
483
+ <UserInfo />
484
+ </template>
485
+
486
+ <template #order>
487
+ <OrderList />
488
+ </template>
489
+ ```
490
+
491
+ 👉 **注意:**
492
+
493
+ * 插槽名称必须等于 `tabs` 里的 `value`
494
+ * 否则内容不会显示
495
+
496
+ ---
497
+
498
+ ## 🔄 keepAlive(是否缓存)
499
+
500
+ ### 开启(默认)
501
+
502
+ ```vue
503
+ <PcTabs :keepAlive="true" />
504
+ ```
505
+
506
+ ✔ 切换 tab 时内容不会销毁
507
+ ✔ 表单数据 / 滚动位置会保留
508
+
509
+ ---
510
+
511
+ ### 关闭
512
+
513
+ ```vue
514
+ <PcTabs :keepAlive="false" />
515
+ ```
516
+
517
+ ✔ 每次切换都会重新渲染
518
+ ✔ 适合数据实时刷新的场景
519
+
520
+ ---
521
+
522
+ ## 📐 布局模式
523
+
524
+ ### 🧭 横向(默认)
525
+
526
+ ```vue
527
+ <PcTabs direction="horizontal" />
528
+ ```
529
+
530
+ 效果:
531
+
532
+ * tabs 在顶部
533
+ * 带滑动下划线
534
+
535
+ ---
536
+
537
+ ### 📚 纵向
538
+
539
+ ```vue
540
+ <PcTabs direction="vertical" />
541
+ ```
542
+
543
+ 效果:
544
+
545
+ * tabs 在左侧
546
+ * 内容在右侧
547
+
548
+ ---
549
+
550
+ ## 🎨 常见使用场景
551
+
552
+ ### ✅ 表单分步填写
553
+
554
+ ```vue
555
+ tabs: [
556
+ { label: '基本信息', value: 'base' },
557
+ { label: '详细信息', value: 'detail' }
558
+ ]
559
+ ```
560
+
561
+ ---
562
+
563
+ ### ✅ 后台管理页面
564
+
565
+ ```vue
566
+ tabs: [
567
+ { label: '用户管理', value: 'user' },
568
+ { label: '角色管理', value: 'role' },
569
+ { label: '权限管理', value: 'auth' }
570
+ ]
571
+ ```
572
+
573
+ ---
574
+
575
+ ### ✅ 内容分类展示
576
+
577
+ ```vue
578
+ tabs: [
579
+ { label: '推荐', value: 'recommend' },
580
+ { label: '最新', value: 'latest' }
581
+ ]
582
+ ```
583
+
584
+ ---
585
+
586
+ ## ⚠️ 注意事项
587
+
588
+ ### 1. value 必须唯一
589
+
590
+ ```js
591
+ ❌ 错误
592
+ { label: 'A', value: 'same' }
593
+ { label: 'B', value: 'same' }
594
+
595
+ ✅ 正确
596
+ { label: 'A', value: 'a' }
597
+ { label: 'B', value: 'b' }
598
+ ```
599
+
600
+ ---
601
+
602
+ ### 2. 插槽名必须匹配
603
+
604
+ ```vue
605
+ ❌ 错误
606
+ tabs: [{ value: 'tab1' }]
607
+ <template #tab2></template>
608
+
609
+ ✅ 正确
610
+ <template #tab1></template>
611
+ ```
612
+
613
+ ---
614
+
615
+ ### 3. v-model 必须有默认值
616
+
617
+ ```js
618
+ data() {
619
+ return {
620
+ activeTab: 'tab1' // 推荐设置默认值
621
+ }
622
+ }
623
+ ```
624
+
625
+ ---
626
+
627
+ ## 💡 小技巧
628
+
629
+ ### 🔹 动态切换 tab
630
+
631
+ ```js
632
+ this.activeTab = 'tab2'
633
+ ```
634
+
635
+ ---
636
+
637
+ ### 🔹 获取当前 tab
638
+
639
+ ```js
640
+ watch: {
641
+ activeTab(val) {
642
+ console.log('当前 tab:', val)
643
+ }
644
+ }
645
+ ```
646
+
647
+ ---
648
+
649
+ ### 🔹 控制默认选中
650
+
651
+ ```js
652
+ data() {
653
+ return {
654
+ activeTab: this.tabs[0].value
655
+ }
656
+ }
657
+ ```
658
+
659
+ ---
660
+
661
+ ## ✅ 总结
662
+
663
+ `PcTabs` 的核心使用方式可以总结为一句话:
664
+
665
+ 👉 **用 tabs 定义结构,用插槽定义内容,用 v-model 控制状态**
666
+
667
+ 适合绝大多数页面切换场景,简单但足够灵活。
668
+
package/es/index/index.js CHANGED
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see index.js.LICENSE.txt */
2
- var t={183(t,e,n){n.d(e,{A:()=>o});var r=n(194);r.A.install=function(t){t.component(r.A.name,r.A)};const o=r.A},491(t,e,n){n.d(e,{A:()=>s});var r=function(){var t=this,e=t._self._c;return t.visible?e("div",{staticClass:"pc pc-dialog__box",style:[t.cusStyle]},[t.ifShowMask?e("div",{staticClass:"pc-dialog__layout",on:{click:function(t){t.stopPropagation()}}}):t._e(),t._v(" "),e("div",{staticClass:"pc-dialog__content__wrap"},[e("div",{staticClass:"pc-dialog__content"},[e("div",{staticClass:"pc-dialog__header"},[e("p",{staticClass:"pc-dialog__title pc-text-ellipsis"},[t._v(t._s(t.title))]),t._v(" "),e("p",{staticClass:"pc-dialog__sub-title pc-text-ellipsis"},[t._v(t._s(t.subTitle))]),t._v(" "),e("div",{staticClass:"pc-dialog__close",on:{click:t.close}},[e("svg",{attrs:{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M6.2253 4.81108C5.83477 4.42056 5.20161 4.42056 4.81108 4.81108C4.42056 5.20161 4.42056 5.83477 4.81108 6.2253L10.5858 12L4.81114 17.7747C4.42062 18.1652 4.42062 18.7984 4.81114 19.1889C5.20167 19.5794 5.83483 19.5794 6.22535 19.1889L12 13.4142L17.7747 19.1889C18.1652 19.5794 18.7984 19.5794 19.1889 19.1889C19.5794 18.7984 19.5794 18.1652 19.1889 17.7747L13.4142 12L19.189 6.2253C19.5795 5.83477 19.5795 5.20161 19.189 4.81108C18.7985 4.42056 18.1653 4.42056 17.7748 4.81108L12 10.5858L6.2253 4.81108Z",fill:"currentColor"}})])])]),t._v(" "),t.ifShowMain?e("div",{staticClass:"pc-dialog__main"},[t._t("default")],2):t._e(),t._v(" "),t.buttons&&t.buttons.length?[e("div",{class:["pc-dialog__footer","pc-flex","pc-flex-end",{border:t.ifShowMain}]},t._l(t.buttons,function(n,r){return e("PcButton",t._b({key:r},"PcButton",n,!1))}),1)]:[e("div",{staticStyle:{height:"10px"}})]],2)])]):t._e()};r._withStripped=!0;var o=n(705);const i={name:"PcDialog",components:{PcButton:n(194).A},model:{prop:"visible",event:"update:visible"},props:{title:{type:String,default:""},subTitle:{type:String,default:""},ifShowMask:{type:Boolean,default:!0},width:{type:Number,default:400},buttons:{type:Array,default:function(){return[]}},visible:{type:Boolean,default:!0}},emits:["close"],data:function(){return{}},computed:{cusStyle:function(){return(0,o.A)({},"--width","".concat(this.width,"px"))},ifShowMain:function(){return Boolean(this.$scopedSlots.default)}},watch:{visible:function(t){document.body.style.overflow=t?"hidden":""}},mounted:function(){var t=this;this.$nextTick(function(){document.body.prepend(t.$el),t.bindEsc()})},beforeDestroy:function(){this.unbindEsc(),this.$el.parentNode===document.body&&document.body.removeChild(this.$el)},methods:{close:function(){this.$emit("close"),this.$emit("update:visible",!1)},handleEsc:function(t){"Escape"===t.key&&this.close()},bindEsc:function(){document.addEventListener("keydown",this.handleEsc)},unbindEsc:function(){document.removeEventListener("keydown",this.handleEsc)}}},a=(0,n(486).A)(i,r,[],!1,null,"01f0e5c2",null).exports;a.install=function(t){t.component(a.name,a)};const s=a},671(t,e,n){n.d(e,{A:()=>f});var r=function(){var t=this,e=t._self._c;return e("div",{ref:"waterfall",staticClass:"waterfall",style:[t.cusStyle]},[t._t("header"),t._v(" "),t.data.length?[e("div",{staticClass:"waterfall-container"},t._l(t.columnsData,function(n,r){return e("div",{key:r,staticClass:"waterfall-column"},t._l(n,function(n,r){return e("div",{key:r,staticClass:"waterfall-item"},[t._t("item",null,{item:n})],2)}),0)}),0)]:[t._t("empty")],t._v(" "),t._t("footer")],2)};function o(t,e,n,r,o,i,a){try{var s=t[i](a),u=s.value}catch(t){return void n(t)}s.done?e(u):Promise.resolve(u).then(r,o)}r._withStripped=!0;var i=n(705),a=n(756),s=n.n(a);const u={name:"PcWaterFall",props:{list:{type:Array,default:function(){return[]}},gapX:{type:Number,default:20},gapY:{type:Number,default:20},columns:{type:Number,default:2}},data:function(){return{current:0,columnsData:[],columnsHeight:[]}},computed:{data:{get:function(){return this.list}},cusStyle:function(){return(0,i.A)((0,i.A)((0,i.A)({},"--gap-x","".concat(this.gapX,"px")),"--gap-y","".concat(this.gapY,"px")),"--column",this.columns)}},watch:{list:{handler:function(t,e){t.length?(t.length<(null==e?void 0:e.length)&&this.reset(),this.init()):this.reset()},immediate:!0},columns:function(){var t=this;this.reset(),this.$nextTick(function(){t.init()})}},methods:{reset:function(){this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0}),this.current=0},init:function(){this.list.length?(0===this.current&&(this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0})),this.renderList()):this.reset()},renderList:function(){var t,e=this;return(t=s().mark(function t(){var n,r,o;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:n=e.current;case 1:if(!(n<e.list.length)){t.next=4;break}return r=e.list[n],o=e.getMinColumn(),e.columnsData[o].push(r),t.next=2,e.$nextTick();case 2:e.calcHeight(o);case 3:n++,t.next=1;break;case 4:e.current=e.list.length;case 5:case"end":return t.stop()}},t)}),function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function s(t){o(a,r,i,s,u,"next",t)}function u(t){o(a,r,i,s,u,"throw",t)}s(void 0)})})()},getMinColumn:function(){var t=this.columnsHeight[0],e=0;return this.columnsHeight.forEach(function(n,r){n<t&&(t=n,e=r)}),e},calcHeight:function(t){var e=this.$el.querySelectorAll(".waterfall-column");this.columnsHeight[t]=e[t].offsetHeight}}},c=u,l=(0,n(486).A)(c,r,[],!1,null,"7c5bcaac",null).exports;l.install=function(t){t.component(l.name,l)};const f=l},893(t,e,n){n.d(e,{A:()=>a});var r=function(){return(0,this._self._c)("canvas",{ref:"canvas"})};r._withStripped=!0;const o={name:"PcWaterMark",props:{width:{type:Number,default:300},height:{type:Number,default:150},src:{type:String,required:!0},text:{type:String,default:""},fontSize:{type:Number,default:16},color:{type:String,default:"#000"},deg:{type:Number,default:45,validator:function(t){return!(t<0||t>360)||(console.warn("[Watermark] deg must be between 0 and 360"),!1)}},gapY:{type:Number,default:20},gapX:{type:Number,default:20}},mounted:function(){this.init()},methods:{init:function(){var t=this,e=this.$refs.canvas,n=e.getContext("2d"),r=window.devicePixelRatio||1;e.width=this.width*r,e.height=this.height*r,e.style.width="".concat(this.width,"px"),e.style.height="".concat(this.height,"px"),n.scale(r,r);var o=new Image;o.crossOrigin="anonymous",o.src=this.src,o.onload=function(){n.drawImage(o,0,0,t.width,t.height),n.font="".concat(t.fontSize,"px sans-serif"),n.fillStyle=t.color,n.textAlign="left",n.textBaseline="middle";var e=n.measureText(t.text).width;n.save(),n.translate(t.width/2,t.height/2),n.rotate(t.deg*Math.PI/180),n.translate(-t.width/2,-t.height/2);for(var r=t.fontSize+t.gapY,i=e+t.gapX,a=-t.height;a<2*t.height;a+=r)for(var s=-t.width;s<2*t.width;s+=i)n.fillText(t.text,s,a);n.restore()}}}},i=(0,n(486).A)(o,r,[],!1,null,null,null).exports;i.install=function(t){t.component(i.name,i)};const a=i},194(t,e,n){n.d(e,{A:()=>i});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-button pc-inline-flex pc-flex-center pc-flex-align-center"},["text"===t.type?[e("span",{class:["pc-button__text",{disabled:t.disabled}],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t._v(t._s(t.text))])]:[e("button",{class:["pc-button__wrap pc-flex pc-flex-center pc-flex-align-center",{disabled:t.disabled||t.loading},t.type],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t.loading?[e("svg",{staticClass:"pc-rotate",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024",width:"14",height:"14"}},[e("path",{attrs:{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"}})])]:t._e(),t._v(" "),e("span",{staticClass:"pc-button__text"},[t._v(t._s(t.text))])],2)]],2)};r._withStripped=!0;const o={name:"PcButton",props:{type:{type:String,default:"primary",validator:function(t){return!!["primary","hollow","text"].includes(t)||(console.warn("只支持primary、hollow或者text类型"),!1)}},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},text:{type:String,required:!0},click:{type:Function,default:function(){return function(){}}}},emits:["click"],methods:{clickButton:function(){this.disabled||this.loading||("[object Function]"===Object.prototype.toString.call(this.click)&&this.click(),this.$emit("click"))}}},i=(0,n(486).A)(o,r,[],!1,null,"12b3918a",null).exports},486(t,e,n){function r(t,e,n,r,o,i,a,s){var u,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),a?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},c._ssrRegister=u):o&&(u=s?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(c.functional){c._injectStyles=u;var l=c.render;c.render=function(t,e){return u.call(e),l(t,e)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:c}}n.d(e,{A:()=>r})},172(t){t.exports=function(t,e){this.v=t,this.k=e},t.exports.__esModule=!0,t.exports.default=t.exports},993(t,e,n){var r=n(546);function o(){var e,n,i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.toStringTag||"@@toStringTag";function u(t,o,i,a){var s=o&&o.prototype instanceof l?o:l,u=Object.create(s.prototype);return r(u,"_invoke",function(t,r,o){var i,a,s,u=0,l=o||[],f=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,s=e,p.n=n,c}};function d(t,r){for(a=t,s=r,n=0;!f&&u&&!o&&n<l.length;n++){var o,i=l[n],d=p.p,h=i[2];t>3?(o=h===r)&&(s=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=t<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<h&&(o=t<3||i[0]>r||r>h)&&(i[4]=t,i[5]=r,p.n=h,a=0))}if(o||t>1)return c;throw f=!0,r}return function(o,l,h){if(u>1)throw TypeError("Generator is already running");for(f&&1===l&&d(l,h),a=l,s=h;(n=a<2?e:s)||!f;){i||(a?a<3?(a>1&&(p.n=-1),d(a,s)):p.n=s:p.v=s);try{if(u=2,i){if(a||(o="next"),n=i[o]){if(!(n=n.call(i,s)))throw TypeError("iterator result is not an object");if(!n.done)return n;s=n.value,a<2&&(a=0)}else 1===a&&(n=i.return)&&n.call(i),a<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((n=(f=p.n<0)?s:t.call(r,p))!==c)break}catch(t){i=e,a=1,s=t}finally{u=1}}return{value:n,done:f}}}(t,i,a),!0),u}var c={};function l(){}function f(){}function p(){}n=Object.getPrototypeOf;var d=[][a]?n(n([][a]())):(r(n={},a,function(){return this}),n),h=p.prototype=l.prototype=Object.create(d);function v(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,r(t,s,"GeneratorFunction")),t.prototype=Object.create(h),t}return f.prototype=p,r(h,"constructor",p),r(p,"constructor",f),f.displayName="GeneratorFunction",r(p,s,"GeneratorFunction"),r(h),r(h,s,"Generator"),r(h,a,function(){return this}),r(h,"toString",function(){return"[object Generator]"}),(t.exports=o=function(){return{w:u,m:v}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},869(t,e,n){var r=n(887);t.exports=function(t,e,n,o,i){var a=r(t,e,n,o,i);return a.next().then(function(t){return t.done?t.value:a.next()})},t.exports.__esModule=!0,t.exports.default=t.exports},887(t,e,n){var r=n(993),o=n(791);t.exports=function(t,e,n,i,a){return new o(r().w(t,e,n,i),a||Promise)},t.exports.__esModule=!0,t.exports.default=t.exports},791(t,e,n){var r=n(172),o=n(546);t.exports=function t(e,n){function i(t,o,a,s){try{var u=e[t](o),c=u.value;return c instanceof r?n.resolve(c.v).then(function(t){i("next",t,a,s)},function(t){i("throw",t,a,s)}):n.resolve(c).then(function(t){u.value=t,a(u)},function(t){return i("throw",t,a,s)})}catch(t){s(t)}}var a;this.next||(o(t.prototype),o(t.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),o(this,"_invoke",function(t,e,r){function o(){return new n(function(e,n){i(t,r,e,n)})}return a=a?a.then(o,o):o()},!0)},t.exports.__esModule=!0,t.exports.default=t.exports},546(t){function e(n,r,o,i){var a=Object.defineProperty;try{a({},"",{})}catch(n){a=0}t.exports=e=function(t,n,r,o){function i(n,r){e(t,n,function(t){return this._invoke(n,r,t)})}n?a?a(t,n,{value:r,enumerable:!o,configurable:!o,writable:!o}):t[n]=r:(i("next",0),i("throw",1),i("return",2))},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r,o,i)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},373(t){t.exports=function(t){var e=Object(t),n=[];for(var r in e)n.unshift(r);return function t(){for(;n.length;)if((r=n.pop())in e)return t.value=r,t.done=!1,t;return t.done=!0,t}},t.exports.__esModule=!0,t.exports.default=t.exports},633(t,e,n){var r=n(172),o=n(993),i=n(869),a=n(887),s=n(791),u=n(373),c=n(579);function l(){var e=o(),n=e.m(l),f=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function p(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===f||"GeneratorFunction"===(e.displayName||e.name))}var d={throw:1,return:2,break:3,continue:3};function h(t){var e,n;return function(r){e||(e={stop:function(){return n(r.a,2)},catch:function(){return r.v},abrupt:function(t,e){return n(r.a,d[t],e)},delegateYield:function(t,o,i){return e.resultName=o,n(r.d,c(t),i)},finish:function(t){return n(r.f,t)}},n=function(t,n,o){r.p=e.prev,r.n=e.next;try{return t(n,o)}finally{e.next=r.n}}),e.resultName&&(e[e.resultName]=r.v,e.resultName=void 0),e.sent=r.v,e.next=r.n;try{return t.call(this,e)}finally{r.p=e.prev,r.n=e.next}}}return(t.exports=l=function(){return{wrap:function(t,n,r,o){return e.w(h(t),n,r,o&&o.reverse())},isGeneratorFunction:p,mark:e.m,awrap:function(t,e){return new r(t,e)},AsyncIterator:s,async:function(t,e,n,r,o){return(p(e)?a:i)(h(t),e,n,r,o)},keys:u,values:c}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=l,t.exports.__esModule=!0,t.exports.default=t.exports},579(t,e,n){var r=n(738).default;t.exports=function(t){if(null!=t){var e=t["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],n=0;if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}}}throw new TypeError(r(t)+" is not iterable")},t.exports.__esModule=!0,t.exports.default=t.exports},738(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},756(t,e,n){var r=n(633)();t.exports=r;try{regeneratorRuntime=r}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},705(t,e,n){function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e,n){return(e=function(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>o})}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var r={};n.d(r,{AM:()=>s.A,Ay:()=>c,Mk:()=>o.A,Ow:()=>a.A,uA:()=>i.A});var o=n(893),i=n(183),a=n(491),s=n(671),u=[o.A,i.A,a.A,s.A];const c={install:function(t){u.forEach(function(e){console.log(e.name),e.install(t)})}},l=r.uA,f=r.Ow,p=r.Mk,d=r.AM,h=r.Ay;export{l as PcButton,f as PcDialog,p as PcWaterMark,d as PcWaterfall,h as default};
2
+ var t={183(t,e,n){n.d(e,{A:()=>o});var r=n(194);r.A.install=function(t){t.component(r.A.name,r.A)};const o=r.A},491(t,e,n){n.d(e,{A:()=>s});var r=function(){var t=this,e=t._self._c;return t.visible?e("div",{staticClass:"pc pc-dialog__box",style:[t.cusStyle]},[t.ifShowMask?e("div",{staticClass:"pc-dialog__layout",on:{click:function(t){t.stopPropagation()}}}):t._e(),t._v(" "),e("div",{staticClass:"pc-dialog__content__wrap"},[e("div",{staticClass:"pc-dialog__content"},[e("div",{staticClass:"pc-dialog__header"},[e("p",{staticClass:"pc-dialog__title pc-text-ellipsis"},[t._v(t._s(t.title))]),t._v(" "),e("p",{staticClass:"pc-dialog__sub-title pc-text-ellipsis"},[t._v(t._s(t.subTitle))]),t._v(" "),e("div",{staticClass:"pc-dialog__close",on:{click:t.close}},[e("svg",{attrs:{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M6.2253 4.81108C5.83477 4.42056 5.20161 4.42056 4.81108 4.81108C4.42056 5.20161 4.42056 5.83477 4.81108 6.2253L10.5858 12L4.81114 17.7747C4.42062 18.1652 4.42062 18.7984 4.81114 19.1889C5.20167 19.5794 5.83483 19.5794 6.22535 19.1889L12 13.4142L17.7747 19.1889C18.1652 19.5794 18.7984 19.5794 19.1889 19.1889C19.5794 18.7984 19.5794 18.1652 19.1889 17.7747L13.4142 12L19.189 6.2253C19.5795 5.83477 19.5795 5.20161 19.189 4.81108C18.7985 4.42056 18.1653 4.42056 17.7748 4.81108L12 10.5858L6.2253 4.81108Z",fill:"currentColor"}})])])]),t._v(" "),t.ifShowMain?e("div",{staticClass:"pc-dialog__main"},[t._t("default")],2):t._e(),t._v(" "),t.buttons&&t.buttons.length?[e("div",{class:["pc-dialog__footer","pc-flex","pc-flex-end",{border:t.ifShowMain}]},t._l(t.buttons,function(n,r){return e("PcButton",t._b({key:r},"PcButton",n,!1))}),1)]:[e("div",{staticStyle:{height:"10px"}})]],2)])]):t._e()};r._withStripped=!0;var o=n(705);const i={name:"PcDialog",components:{PcButton:n(194).A},model:{prop:"visible",event:"update:visible"},props:{title:{type:String,default:""},subTitle:{type:String,default:""},ifShowMask:{type:Boolean,default:!0},width:{type:Number,default:400},buttons:{type:Array,default:function(){return[]}},visible:{type:Boolean,default:!0}},emits:["close"],data:function(){return{}},computed:{cusStyle:function(){return(0,o.A)({},"--width","".concat(this.width,"px"))},ifShowMain:function(){return Boolean(this.$scopedSlots.default)}},watch:{visible:function(t){document.body.style.overflow=t?"hidden":""}},mounted:function(){var t=this;this.$nextTick(function(){document.body.prepend(t.$el),t.bindEsc()})},beforeDestroy:function(){this.unbindEsc(),this.$el.parentNode===document.body&&document.body.removeChild(this.$el)},methods:{close:function(){this.$emit("close"),this.$emit("update:visible",!1)},handleEsc:function(t){"Escape"===t.key&&this.close()},bindEsc:function(){document.addEventListener("keydown",this.handleEsc)},unbindEsc:function(){document.removeEventListener("keydown",this.handleEsc)}}},a=(0,n(486).A)(i,r,[],!1,null,"01f0e5c2",null).exports;a.install=function(t){t.component(a.name,a)};const s=a},814(t,e,n){n.d(e,{A:()=>u});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-tabs",style:[t.cusStyle]},["vertical"===t.direction?[e("div",{staticClass:"pc-tabs_v_wrap pc-flex"},[e("div",{staticClass:"pc-tabs_list_v pc-flex pc-flex-column"},t._l(t.tabs,function(n,r){return e("p",{key:n.value,ref:"tab-item"+r,refInFor:!0,class:["pc-tabs_list_item","pc-text-ellipsis",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,r)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tabs_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]:[e("div",{staticClass:"pc-tabs_h_wrap pc-flex pc-flex-column"},[e("div",{staticClass:"pc-tabs_list_h pc-flex pc-flex-align-center"},t._l(t.tabs,function(n,r){return e("p",{key:n.value,ref:"tab-item"+r,refInFor:!0,class:["pc-tabs_list_item",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,r)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tab_active"}),t._v(" "),e("div",{staticClass:"pc-tab_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]],2)};r._withStripped=!0;var o=n(705);const i={name:"PcTabs",model:{prop:"value",event:"update:change"},props:{value:{type:String,default:""},tabs:{type:Array,default:function(){return[]}},keepAlive:{type:Boolean,default:!0},direction:{type:String,default:"horizontal"}},data:function(){return{curTabValue:"",offsetLeft:0,offsetWidth:0}},computed:{cusStyle:function(){return(0,o.A)((0,o.A)({},"--offset-left",this.offsetLeft+"px"),"--offset-width",this.offsetWidth+"px")}},watch:{value:{handler:function(t){var e;!function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(e,n){return Reflect.has(n,t)&&e.push(n[t]),e},[])}(this.tabs,"value").includes(t)?this.curTabValue=null===(e=this.tabs[0])||void 0===e?void 0:e.value:this.curTabValue=t},deep:!0,immediate:!0}},mounted:function(){var t=this;"horizontal"===this.direction&&this.$nextTick(function(){var e=t.tabs.findIndex(function(e){return e.value===t.curTabValue});if(-1!==e){var n=t.$refs["tab-item"+e][0],r=n.offsetWidth,o=n.offsetLeft;t.offsetWidth=r-20,t.offsetLeft=o}})},methods:{changeTab:function(t,e){if(this.$emit("update:change",t.value),"horizontal"===this.direction){var n=this.$refs["tab-item"+e][0].offsetWidth,r=this.$refs["tab-item"+e][0].offsetLeft;this.offsetWidth=n-20,this.offsetLeft=r}}}},a=i,s=(0,n(486).A)(a,r,[],!1,null,"6028b20c",null).exports;s.install=function(t){t.component(s.name,s)};const u=s},671(t,e,n){n.d(e,{A:()=>f});var r=function(){var t=this,e=t._self._c;return e("div",{ref:"waterfall",staticClass:"waterfall",style:[t.cusStyle]},[t._t("header"),t._v(" "),t.data.length?[e("div",{staticClass:"waterfall-container"},t._l(t.columnsData,function(n,r){return e("div",{key:r,staticClass:"waterfall-column"},t._l(n,function(n,r){return e("div",{key:r,staticClass:"waterfall-item"},[t._t("item",null,{item:n})],2)}),0)}),0)]:[t._t("empty")],t._v(" "),t._t("footer")],2)};function o(t,e,n,r,o,i,a){try{var s=t[i](a),u=s.value}catch(t){return void n(t)}s.done?e(u):Promise.resolve(u).then(r,o)}r._withStripped=!0;var i=n(705),a=n(756),s=n.n(a);const u={name:"PcWaterFall",props:{list:{type:Array,default:function(){return[]}},gapX:{type:Number,default:20},gapY:{type:Number,default:20},columns:{type:Number,default:2}},data:function(){return{current:0,columnsData:[],columnsHeight:[]}},computed:{data:{get:function(){return this.list}},cusStyle:function(){return(0,i.A)((0,i.A)((0,i.A)({},"--gap-x","".concat(this.gapX,"px")),"--gap-y","".concat(this.gapY,"px")),"--column",this.columns)}},watch:{list:{handler:function(t,e){t.length?(t.length<(null==e?void 0:e.length)&&this.reset(),this.init()):this.reset()},immediate:!0},columns:function(){var t=this;this.reset(),this.$nextTick(function(){t.init()})}},methods:{reset:function(){this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0}),this.current=0},init:function(){this.list.length?(0===this.current&&(this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0})),this.renderList()):this.reset()},renderList:function(){var t,e=this;return(t=s().mark(function t(){var n,r,o;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:n=e.current;case 1:if(!(n<e.list.length)){t.next=4;break}return r=e.list[n],o=e.getMinColumn(),e.columnsData[o].push(r),t.next=2,e.$nextTick();case 2:e.calcHeight(o);case 3:n++,t.next=1;break;case 4:e.current=e.list.length;case 5:case"end":return t.stop()}},t)}),function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function s(t){o(a,r,i,s,u,"next",t)}function u(t){o(a,r,i,s,u,"throw",t)}s(void 0)})})()},getMinColumn:function(){var t=this.columnsHeight[0],e=0;return this.columnsHeight.forEach(function(n,r){n<t&&(t=n,e=r)}),e},calcHeight:function(t){var e=this.$el.querySelectorAll(".waterfall-column");this.columnsHeight[t]=e[t].offsetHeight}}},c=u,l=(0,n(486).A)(c,r,[],!1,null,"7c5bcaac",null).exports;l.install=function(t){t.component(l.name,l)};const f=l},893(t,e,n){n.d(e,{A:()=>a});var r=function(){return(0,this._self._c)("canvas",{ref:"canvas"})};r._withStripped=!0;const o={name:"PcWaterMark",props:{width:{type:Number,default:300},height:{type:Number,default:150},src:{type:String,required:!0},text:{type:String,default:""},fontSize:{type:Number,default:16},color:{type:String,default:"#000"},deg:{type:Number,default:45,validator:function(t){return!(t<0||t>360)||(console.warn("[Watermark] deg must be between 0 and 360"),!1)}},gapY:{type:Number,default:20},gapX:{type:Number,default:20}},mounted:function(){this.init()},methods:{init:function(){var t=this,e=this.$refs.canvas,n=e.getContext("2d"),r=window.devicePixelRatio||1;e.width=this.width*r,e.height=this.height*r,e.style.width="".concat(this.width,"px"),e.style.height="".concat(this.height,"px"),n.scale(r,r);var o=new Image;o.crossOrigin="anonymous",o.src=this.src,o.onload=function(){n.drawImage(o,0,0,t.width,t.height),n.font="".concat(t.fontSize,"px sans-serif"),n.fillStyle=t.color,n.textAlign="left",n.textBaseline="middle";var e=n.measureText(t.text).width;n.save(),n.translate(t.width/2,t.height/2),n.rotate(t.deg*Math.PI/180),n.translate(-t.width/2,-t.height/2);for(var r=t.fontSize+t.gapY,i=e+t.gapX,a=-t.height;a<2*t.height;a+=r)for(var s=-t.width;s<2*t.width;s+=i)n.fillText(t.text,s,a);n.restore()}}}},i=(0,n(486).A)(o,r,[],!1,null,null,null).exports;i.install=function(t){t.component(i.name,i)};const a=i},194(t,e,n){n.d(e,{A:()=>i});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-button pc-inline-flex pc-flex-center pc-flex-align-center"},["text"===t.type?[e("span",{class:["pc-button__text",{disabled:t.disabled}],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t._v(t._s(t.text))])]:[e("button",{class:["pc-button__wrap pc-flex pc-flex-center pc-flex-align-center",{disabled:t.disabled||t.loading},t.type],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t.loading?[e("svg",{staticClass:"pc-rotate",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024",width:"14",height:"14"}},[e("path",{attrs:{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"}})])]:t._e(),t._v(" "),e("span",{staticClass:"pc-button__text"},[t._v(t._s(t.text))])],2)]],2)};r._withStripped=!0;const o={name:"PcButton",props:{type:{type:String,default:"primary",validator:function(t){return!!["primary","hollow","text"].includes(t)||(console.warn("只支持primary、hollow或者text类型"),!1)}},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},text:{type:String,required:!0},click:{type:Function,default:function(){return function(){}}}},emits:["click"],methods:{clickButton:function(){this.disabled||this.loading||("[object Function]"===Object.prototype.toString.call(this.click)&&this.click(),this.$emit("click"))}}},i=(0,n(486).A)(o,r,[],!1,null,"12b3918a",null).exports},486(t,e,n){function r(t,e,n,r,o,i,a,s){var u,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),a?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},c._ssrRegister=u):o&&(u=s?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(c.functional){c._injectStyles=u;var l=c.render;c.render=function(t,e){return u.call(e),l(t,e)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:c}}n.d(e,{A:()=>r})},172(t){t.exports=function(t,e){this.v=t,this.k=e},t.exports.__esModule=!0,t.exports.default=t.exports},993(t,e,n){var r=n(546);function o(){var e,n,i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.toStringTag||"@@toStringTag";function u(t,o,i,a){var s=o&&o.prototype instanceof l?o:l,u=Object.create(s.prototype);return r(u,"_invoke",function(t,r,o){var i,a,s,u=0,l=o||[],f=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,s=e,p.n=n,c}};function d(t,r){for(a=t,s=r,n=0;!f&&u&&!o&&n<l.length;n++){var o,i=l[n],d=p.p,h=i[2];t>3?(o=h===r)&&(s=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=t<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<h&&(o=t<3||i[0]>r||r>h)&&(i[4]=t,i[5]=r,p.n=h,a=0))}if(o||t>1)return c;throw f=!0,r}return function(o,l,h){if(u>1)throw TypeError("Generator is already running");for(f&&1===l&&d(l,h),a=l,s=h;(n=a<2?e:s)||!f;){i||(a?a<3?(a>1&&(p.n=-1),d(a,s)):p.n=s:p.v=s);try{if(u=2,i){if(a||(o="next"),n=i[o]){if(!(n=n.call(i,s)))throw TypeError("iterator result is not an object");if(!n.done)return n;s=n.value,a<2&&(a=0)}else 1===a&&(n=i.return)&&n.call(i),a<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((n=(f=p.n<0)?s:t.call(r,p))!==c)break}catch(t){i=e,a=1,s=t}finally{u=1}}return{value:n,done:f}}}(t,i,a),!0),u}var c={};function l(){}function f(){}function p(){}n=Object.getPrototypeOf;var d=[][a]?n(n([][a]())):(r(n={},a,function(){return this}),n),h=p.prototype=l.prototype=Object.create(d);function v(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,r(t,s,"GeneratorFunction")),t.prototype=Object.create(h),t}return f.prototype=p,r(h,"constructor",p),r(p,"constructor",f),f.displayName="GeneratorFunction",r(p,s,"GeneratorFunction"),r(h),r(h,s,"Generator"),r(h,a,function(){return this}),r(h,"toString",function(){return"[object Generator]"}),(t.exports=o=function(){return{w:u,m:v}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},869(t,e,n){var r=n(887);t.exports=function(t,e,n,o,i){var a=r(t,e,n,o,i);return a.next().then(function(t){return t.done?t.value:a.next()})},t.exports.__esModule=!0,t.exports.default=t.exports},887(t,e,n){var r=n(993),o=n(791);t.exports=function(t,e,n,i,a){return new o(r().w(t,e,n,i),a||Promise)},t.exports.__esModule=!0,t.exports.default=t.exports},791(t,e,n){var r=n(172),o=n(546);t.exports=function t(e,n){function i(t,o,a,s){try{var u=e[t](o),c=u.value;return c instanceof r?n.resolve(c.v).then(function(t){i("next",t,a,s)},function(t){i("throw",t,a,s)}):n.resolve(c).then(function(t){u.value=t,a(u)},function(t){return i("throw",t,a,s)})}catch(t){s(t)}}var a;this.next||(o(t.prototype),o(t.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),o(this,"_invoke",function(t,e,r){function o(){return new n(function(e,n){i(t,r,e,n)})}return a=a?a.then(o,o):o()},!0)},t.exports.__esModule=!0,t.exports.default=t.exports},546(t){function e(n,r,o,i){var a=Object.defineProperty;try{a({},"",{})}catch(n){a=0}t.exports=e=function(t,n,r,o){function i(n,r){e(t,n,function(t){return this._invoke(n,r,t)})}n?a?a(t,n,{value:r,enumerable:!o,configurable:!o,writable:!o}):t[n]=r:(i("next",0),i("throw",1),i("return",2))},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r,o,i)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},373(t){t.exports=function(t){var e=Object(t),n=[];for(var r in e)n.unshift(r);return function t(){for(;n.length;)if((r=n.pop())in e)return t.value=r,t.done=!1,t;return t.done=!0,t}},t.exports.__esModule=!0,t.exports.default=t.exports},633(t,e,n){var r=n(172),o=n(993),i=n(869),a=n(887),s=n(791),u=n(373),c=n(579);function l(){var e=o(),n=e.m(l),f=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function p(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===f||"GeneratorFunction"===(e.displayName||e.name))}var d={throw:1,return:2,break:3,continue:3};function h(t){var e,n;return function(r){e||(e={stop:function(){return n(r.a,2)},catch:function(){return r.v},abrupt:function(t,e){return n(r.a,d[t],e)},delegateYield:function(t,o,i){return e.resultName=o,n(r.d,c(t),i)},finish:function(t){return n(r.f,t)}},n=function(t,n,o){r.p=e.prev,r.n=e.next;try{return t(n,o)}finally{e.next=r.n}}),e.resultName&&(e[e.resultName]=r.v,e.resultName=void 0),e.sent=r.v,e.next=r.n;try{return t.call(this,e)}finally{r.p=e.prev,r.n=e.next}}}return(t.exports=l=function(){return{wrap:function(t,n,r,o){return e.w(h(t),n,r,o&&o.reverse())},isGeneratorFunction:p,mark:e.m,awrap:function(t,e){return new r(t,e)},AsyncIterator:s,async:function(t,e,n,r,o){return(p(e)?a:i)(h(t),e,n,r,o)},keys:u,values:c}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=l,t.exports.__esModule=!0,t.exports.default=t.exports},579(t,e,n){var r=n(738).default;t.exports=function(t){if(null!=t){var e=t["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],n=0;if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}}}throw new TypeError(r(t)+" is not iterable")},t.exports.__esModule=!0,t.exports.default=t.exports},738(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},756(t,e,n){var r=n(633)();t.exports=r;try{regeneratorRuntime=r}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},705(t,e,n){function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e,n){return(e=function(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>o})}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var r={};n.d(r,{AM:()=>s.A,Ay:()=>l,Co:()=>u.A,Mk:()=>o.A,Ow:()=>a.A,uA:()=>i.A});var o=n(893),i=n(183),a=n(491),s=n(671),u=n(814),c=[o.A,i.A,a.A,s.A,u.A];const l={install:function(t){c.forEach(function(e){console.log(e.name),e.install(t)})}},f=r.uA,p=r.Ow,d=r.Co,h=r.Mk,v=r.AM,m=r.Ay;export{f as PcButton,p as PcDialog,d as PcTabs,h as PcWaterMark,v as PcWaterfall,m as default};
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -385,3 +386,76 @@
385
386
  gap: var(--gap-y);
386
387
  }
387
388
 
389
+ .pc-tabs[data-v-6028b20c] {
390
+ height: inherit;
391
+ }
392
+ .pc-tabs_v_wrap[data-v-6028b20c] {
393
+ height: inherit;
394
+ gap: 14px;
395
+ }
396
+ .pc-tabs_v_wrap .pc-tabs_list_v[data-v-6028b20c] {
397
+ background-color: #ecf5ff;
398
+ flex-shrink: 0;
399
+ gap: 10px;
400
+ width: 150px;
401
+ overflow-y: auto;
402
+ box-sizing: border-box;
403
+ padding: 8px 12px;
404
+ height: 100%;
405
+ }
406
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c] {
407
+ flex-shrink: 0;
408
+ padding: 4px 8px;
409
+ font-size: 15px;
410
+ border-radius: var(--cl-border-radius-mini);
411
+ border: 1px solid #d9ecff;
412
+ box-sizing: border-box;
413
+ background-color: #fff;
414
+ text-align: center;
415
+ cursor: pointer;
416
+ color: var(--pc-text-color-primary);
417
+ }
418
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item.active[data-v-6028b20c] {
419
+ color: var(--pc-color-primary);
420
+ }
421
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
422
+ color: var(--pc-color-primary);
423
+ }
424
+ .pc-tabs_v_wrap .pc-tabs_content[data-v-6028b20c] {
425
+ flex: 1;
426
+ overflow: auto;
427
+ }
428
+ .pc-tabs_h_wrap[data-v-6028b20c] {
429
+ height: 100%;
430
+ }
431
+ .pc-tabs_h_wrap .pc-tabs_list_h[data-v-6028b20c] {
432
+ overflow: auto;
433
+ }
434
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c] {
435
+ font-size: 15px;
436
+ padding: 0 10px;
437
+ cursor: pointer;
438
+ color: var(--pc-text-color-primary);
439
+ flex-shrink: 0;
440
+ }
441
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item.active[data-v-6028b20c] {
442
+ color: var(--pc-color-primary);
443
+ }
444
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
445
+ color: var(--pc-color-primary);
446
+ }
447
+ .pc-tabs_h_wrap .pc-tab_active[data-v-6028b20c] {
448
+ height: 1px;
449
+ display: inline-block;
450
+ background-color: var(--pc-color-primary);
451
+ width: var(--offset-width);
452
+ transform: translateX(var(--offset-left));
453
+ transition: all 0.3s ease;
454
+ }
455
+ .pc-tabs_h_wrap .pc-tab_content[data-v-6028b20c] {
456
+ flex: 1;
457
+ overflow: auto;
458
+ height: 0;
459
+ min-height: 0;
460
+ }
461
+
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -0,0 +1 @@
1
+ var t={486(t,e,n){function i(t,e,n,i,a,r,o,s){var u,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),i&&(c.functional=!0),r&&(c._scopeId="data-v-"+r),o?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),a&&a.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(o)},c._ssrRegister=u):a&&(u=s?function(){a.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:a),u)if(c.functional){c._injectStyles=u;var l=c.render;c.render=function(t,e){return u.call(e),l(t,e)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:c}}n.d(e,{A:()=>i})},705(t,e,n){function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function a(t,e,n){return(e=function(t){var e=function(t){if("object"!=i(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==i(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>a})}},e={};function n(i){var a=e[i];if(void 0!==a)return a.exports;var r=e[i]={exports:{}};return t[i](r,r.exports,n),r.exports}n.d=(t,e)=>{for(var i in e)n.o(e,i)&&!n.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var i=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-tabs",style:[t.cusStyle]},["vertical"===t.direction?[e("div",{staticClass:"pc-tabs_v_wrap pc-flex"},[e("div",{staticClass:"pc-tabs_list_v pc-flex pc-flex-column"},t._l(t.tabs,function(n,i){return e("p",{key:n.value,ref:"tab-item"+i,refInFor:!0,class:["pc-tabs_list_item","pc-text-ellipsis",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,i)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tabs_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]:[e("div",{staticClass:"pc-tabs_h_wrap pc-flex pc-flex-column"},[e("div",{staticClass:"pc-tabs_list_h pc-flex pc-flex-align-center"},t._l(t.tabs,function(n,i){return e("p",{key:n.value,ref:"tab-item"+i,refInFor:!0,class:["pc-tabs_list_item",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,i)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tab_active"}),t._v(" "),e("div",{staticClass:"pc-tab_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]],2)};i._withStripped=!0;var a=n(705);const r={name:"PcTabs",model:{prop:"value",event:"update:change"},props:{value:{type:String,default:""},tabs:{type:Array,default:function(){return[]}},keepAlive:{type:Boolean,default:!0},direction:{type:String,default:"horizontal"}},data:function(){return{curTabValue:"",offsetLeft:0,offsetWidth:0}},computed:{cusStyle:function(){return(0,a.A)((0,a.A)({},"--offset-left",this.offsetLeft+"px"),"--offset-width",this.offsetWidth+"px")}},watch:{value:{handler:function(t){var e;!function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(e,n){return Reflect.has(n,t)&&e.push(n[t]),e},[])}(this.tabs,"value").includes(t)?this.curTabValue=null===(e=this.tabs[0])||void 0===e?void 0:e.value:this.curTabValue=t},deep:!0,immediate:!0}},mounted:function(){var t=this;"horizontal"===this.direction&&this.$nextTick(function(){var e=t.tabs.findIndex(function(e){return e.value===t.curTabValue});if(-1!==e){var n=t.$refs["tab-item"+e][0],i=n.offsetWidth,a=n.offsetLeft;t.offsetWidth=i-20,t.offsetLeft=a}})},methods:{changeTab:function(t,e){if(this.$emit("update:change",t.value),"horizontal"===this.direction){var n=this.$refs["tab-item"+e][0].offsetWidth,i=this.$refs["tab-item"+e][0].offsetLeft;this.offsetWidth=n-20,this.offsetLeft=i}}}},o=(0,n(486).A)(r,i,[],!1,null,"6028b20c",null).exports;o.install=function(t){t.component(o.name,o)};const s=o;export{s as default};
@@ -0,0 +1,73 @@
1
+ .pc-tabs[data-v-6028b20c] {
2
+ height: inherit;
3
+ }
4
+ .pc-tabs_v_wrap[data-v-6028b20c] {
5
+ height: inherit;
6
+ gap: 14px;
7
+ }
8
+ .pc-tabs_v_wrap .pc-tabs_list_v[data-v-6028b20c] {
9
+ background-color: #ecf5ff;
10
+ flex-shrink: 0;
11
+ gap: 10px;
12
+ width: 150px;
13
+ overflow-y: auto;
14
+ box-sizing: border-box;
15
+ padding: 8px 12px;
16
+ height: 100%;
17
+ }
18
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c] {
19
+ flex-shrink: 0;
20
+ padding: 4px 8px;
21
+ font-size: 15px;
22
+ border-radius: var(--cl-border-radius-mini);
23
+ border: 1px solid #d9ecff;
24
+ box-sizing: border-box;
25
+ background-color: #fff;
26
+ text-align: center;
27
+ cursor: pointer;
28
+ color: var(--pc-text-color-primary);
29
+ }
30
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item.active[data-v-6028b20c] {
31
+ color: var(--pc-color-primary);
32
+ }
33
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
34
+ color: var(--pc-color-primary);
35
+ }
36
+ .pc-tabs_v_wrap .pc-tabs_content[data-v-6028b20c] {
37
+ flex: 1;
38
+ overflow: auto;
39
+ }
40
+ .pc-tabs_h_wrap[data-v-6028b20c] {
41
+ height: 100%;
42
+ }
43
+ .pc-tabs_h_wrap .pc-tabs_list_h[data-v-6028b20c] {
44
+ overflow: auto;
45
+ }
46
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c] {
47
+ font-size: 15px;
48
+ padding: 0 10px;
49
+ cursor: pointer;
50
+ color: var(--pc-text-color-primary);
51
+ flex-shrink: 0;
52
+ }
53
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item.active[data-v-6028b20c] {
54
+ color: var(--pc-color-primary);
55
+ }
56
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
57
+ color: var(--pc-color-primary);
58
+ }
59
+ .pc-tabs_h_wrap .pc-tab_active[data-v-6028b20c] {
60
+ height: 1px;
61
+ display: inline-block;
62
+ background-color: var(--pc-color-primary);
63
+ width: var(--offset-width);
64
+ transform: translateX(var(--offset-left));
65
+ transition: all 0.3s ease;
66
+ }
67
+ .pc-tabs_h_wrap .pc-tab_content[data-v-6028b20c] {
68
+ flex: 1;
69
+ overflow: auto;
70
+ height: 0;
71
+ min-height: 0;
72
+ }
73
+
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -0,0 +1 @@
1
+ var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{getValuesByKey:()=>n});var r={};e.r(r),e.d(r,{formatTime:()=>o});var n=function(){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(t,r){return Reflect.has(r,e)&&t.push(r[e]),t},[])},o=function(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"YYYY-MM-DD HH:mm:ss";if(!e)return"";if("number"==typeof e||/^\d+$/.test(e)){var n=Number(e);10===n.toString().length&&(n*=1e3),t=new Date(n)}else if("string"==typeof e)t=t.replace(/-/g,"/");else{if(!(e instanceof Date))return"";t=e}if(isNaN(t.getTime()))return"";var o=function(e){return String(e).padStart(2,"0")},a={YYYY:t.getFullYear(),MM:o(t.getMonth()+1),DD:o(t.getDate()),HH:o(t.getHours()),mm:o(t.getMinutes()),ss:o(t.getSeconds())};return r.replace(/YYYY|MM|DD|HH|mm|ss/g,function(e){return a[e]})};export{r as DateUtils,t as ListUtils};
@@ -1,2 +1,2 @@
1
1
  /*! For license information please see index.js.LICENSE.txt */
2
- (()=>{var t={183(t,e,n){"use strict";n.d(e,{default:()=>o});var r=n(194);r.A.install=function(t){t.component(r.A.name,r.A)};const o=r.A},491(t,e,n){"use strict";n.d(e,{default:()=>s});var r=function(){var t=this,e=t._self._c;return t.visible?e("div",{staticClass:"pc pc-dialog__box",style:[t.cusStyle]},[t.ifShowMask?e("div",{staticClass:"pc-dialog__layout",on:{click:function(t){t.stopPropagation()}}}):t._e(),t._v(" "),e("div",{staticClass:"pc-dialog__content__wrap"},[e("div",{staticClass:"pc-dialog__content"},[e("div",{staticClass:"pc-dialog__header"},[e("p",{staticClass:"pc-dialog__title pc-text-ellipsis"},[t._v(t._s(t.title))]),t._v(" "),e("p",{staticClass:"pc-dialog__sub-title pc-text-ellipsis"},[t._v(t._s(t.subTitle))]),t._v(" "),e("div",{staticClass:"pc-dialog__close",on:{click:t.close}},[e("svg",{attrs:{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M6.2253 4.81108C5.83477 4.42056 5.20161 4.42056 4.81108 4.81108C4.42056 5.20161 4.42056 5.83477 4.81108 6.2253L10.5858 12L4.81114 17.7747C4.42062 18.1652 4.42062 18.7984 4.81114 19.1889C5.20167 19.5794 5.83483 19.5794 6.22535 19.1889L12 13.4142L17.7747 19.1889C18.1652 19.5794 18.7984 19.5794 19.1889 19.1889C19.5794 18.7984 19.5794 18.1652 19.1889 17.7747L13.4142 12L19.189 6.2253C19.5795 5.83477 19.5795 5.20161 19.189 4.81108C18.7985 4.42056 18.1653 4.42056 17.7748 4.81108L12 10.5858L6.2253 4.81108Z",fill:"currentColor"}})])])]),t._v(" "),t.ifShowMain?e("div",{staticClass:"pc-dialog__main"},[t._t("default")],2):t._e(),t._v(" "),t.buttons&&t.buttons.length?[e("div",{class:["pc-dialog__footer","pc-flex","pc-flex-end",{border:t.ifShowMain}]},t._l(t.buttons,function(n,r){return e("PcButton",t._b({key:r},"PcButton",n,!1))}),1)]:[e("div",{staticStyle:{height:"10px"}})]],2)])]):t._e()};r._withStripped=!0;var o=n(705);const i={name:"PcDialog",components:{PcButton:n(194).A},model:{prop:"visible",event:"update:visible"},props:{title:{type:String,default:""},subTitle:{type:String,default:""},ifShowMask:{type:Boolean,default:!0},width:{type:Number,default:400},buttons:{type:Array,default:function(){return[]}},visible:{type:Boolean,default:!0}},emits:["close"],data:function(){return{}},computed:{cusStyle:function(){return(0,o.A)({},"--width","".concat(this.width,"px"))},ifShowMain:function(){return Boolean(this.$scopedSlots.default)}},watch:{visible:function(t){document.body.style.overflow=t?"hidden":""}},mounted:function(){var t=this;this.$nextTick(function(){document.body.prepend(t.$el),t.bindEsc()})},beforeDestroy:function(){this.unbindEsc(),this.$el.parentNode===document.body&&document.body.removeChild(this.$el)},methods:{close:function(){this.$emit("close"),this.$emit("update:visible",!1)},handleEsc:function(t){"Escape"===t.key&&this.close()},bindEsc:function(){document.addEventListener("keydown",this.handleEsc)},unbindEsc:function(){document.removeEventListener("keydown",this.handleEsc)}}},a=(0,n(486).A)(i,r,[],!1,null,"01f0e5c2",null).exports;a.install=function(t){t.component(a.name,a)};const s=a},671(t,e,n){"use strict";n.d(e,{default:()=>f});var r=function(){var t=this,e=t._self._c;return e("div",{ref:"waterfall",staticClass:"waterfall",style:[t.cusStyle]},[t._t("header"),t._v(" "),t.data.length?[e("div",{staticClass:"waterfall-container"},t._l(t.columnsData,function(n,r){return e("div",{key:r,staticClass:"waterfall-column"},t._l(n,function(n,r){return e("div",{key:r,staticClass:"waterfall-item"},[t._t("item",null,{item:n})],2)}),0)}),0)]:[t._t("empty")],t._v(" "),t._t("footer")],2)};function o(t,e,n,r,o,i,a){try{var s=t[i](a),u=s.value}catch(t){return void n(t)}s.done?e(u):Promise.resolve(u).then(r,o)}r._withStripped=!0;var i=n(705),a=n(756),s=n.n(a);const u={name:"PcWaterFall",props:{list:{type:Array,default:function(){return[]}},gapX:{type:Number,default:20},gapY:{type:Number,default:20},columns:{type:Number,default:2}},data:function(){return{current:0,columnsData:[],columnsHeight:[]}},computed:{data:{get:function(){return this.list}},cusStyle:function(){return(0,i.A)((0,i.A)((0,i.A)({},"--gap-x","".concat(this.gapX,"px")),"--gap-y","".concat(this.gapY,"px")),"--column",this.columns)}},watch:{list:{handler:function(t,e){t.length?(t.length<(null==e?void 0:e.length)&&this.reset(),this.init()):this.reset()},immediate:!0},columns:function(){var t=this;this.reset(),this.$nextTick(function(){t.init()})}},methods:{reset:function(){this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0}),this.current=0},init:function(){this.list.length?(0===this.current&&(this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0})),this.renderList()):this.reset()},renderList:function(){var t,e=this;return(t=s().mark(function t(){var n,r,o;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:n=e.current;case 1:if(!(n<e.list.length)){t.next=4;break}return r=e.list[n],o=e.getMinColumn(),e.columnsData[o].push(r),t.next=2,e.$nextTick();case 2:e.calcHeight(o);case 3:n++,t.next=1;break;case 4:e.current=e.list.length;case 5:case"end":return t.stop()}},t)}),function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function s(t){o(a,r,i,s,u,"next",t)}function u(t){o(a,r,i,s,u,"throw",t)}s(void 0)})})()},getMinColumn:function(){var t=this.columnsHeight[0],e=0;return this.columnsHeight.forEach(function(n,r){n<t&&(t=n,e=r)}),e},calcHeight:function(t){var e=this.$el.querySelectorAll(".waterfall-column");this.columnsHeight[t]=e[t].offsetHeight}}},c=u,l=(0,n(486).A)(c,r,[],!1,null,"7c5bcaac",null).exports;l.install=function(t){t.component(l.name,l)};const f=l},893(t,e,n){"use strict";n.d(e,{default:()=>a});var r=function(){return(0,this._self._c)("canvas",{ref:"canvas"})};r._withStripped=!0;const o={name:"PcWaterMark",props:{width:{type:Number,default:300},height:{type:Number,default:150},src:{type:String,required:!0},text:{type:String,default:""},fontSize:{type:Number,default:16},color:{type:String,default:"#000"},deg:{type:Number,default:45,validator:function(t){return!(t<0||t>360)||(console.warn("[Watermark] deg must be between 0 and 360"),!1)}},gapY:{type:Number,default:20},gapX:{type:Number,default:20}},mounted:function(){this.init()},methods:{init:function(){var t=this,e=this.$refs.canvas,n=e.getContext("2d"),r=window.devicePixelRatio||1;e.width=this.width*r,e.height=this.height*r,e.style.width="".concat(this.width,"px"),e.style.height="".concat(this.height,"px"),n.scale(r,r);var o=new Image;o.crossOrigin="anonymous",o.src=this.src,o.onload=function(){n.drawImage(o,0,0,t.width,t.height),n.font="".concat(t.fontSize,"px sans-serif"),n.fillStyle=t.color,n.textAlign="left",n.textBaseline="middle";var e=n.measureText(t.text).width;n.save(),n.translate(t.width/2,t.height/2),n.rotate(t.deg*Math.PI/180),n.translate(-t.width/2,-t.height/2);for(var r=t.fontSize+t.gapY,i=e+t.gapX,a=-t.height;a<2*t.height;a+=r)for(var s=-t.width;s<2*t.width;s+=i)n.fillText(t.text,s,a);n.restore()}}}},i=(0,n(486).A)(o,r,[],!1,null,null,null).exports;i.install=function(t){t.component(i.name,i)};const a=i},194(t,e,n){"use strict";n.d(e,{A:()=>i});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-button pc-inline-flex pc-flex-center pc-flex-align-center"},["text"===t.type?[e("span",{class:["pc-button__text",{disabled:t.disabled}],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t._v(t._s(t.text))])]:[e("button",{class:["pc-button__wrap pc-flex pc-flex-center pc-flex-align-center",{disabled:t.disabled||t.loading},t.type],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t.loading?[e("svg",{staticClass:"pc-rotate",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024",width:"14",height:"14"}},[e("path",{attrs:{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"}})])]:t._e(),t._v(" "),e("span",{staticClass:"pc-button__text"},[t._v(t._s(t.text))])],2)]],2)};r._withStripped=!0;const o={name:"PcButton",props:{type:{type:String,default:"primary",validator:function(t){return!!["primary","hollow","text"].includes(t)||(console.warn("只支持primary、hollow或者text类型"),!1)}},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},text:{type:String,required:!0},click:{type:Function,default:function(){return function(){}}}},emits:["click"],methods:{clickButton:function(){this.disabled||this.loading||("[object Function]"===Object.prototype.toString.call(this.click)&&this.click(),this.$emit("click"))}}},i=(0,n(486).A)(o,r,[],!1,null,"12b3918a",null).exports},486(t,e,n){"use strict";function r(t,e,n,r,o,i,a,s){var u,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),a?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},c._ssrRegister=u):o&&(u=s?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(c.functional){c._injectStyles=u;var l=c.render;c.render=function(t,e){return u.call(e),l(t,e)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:c}}n.d(e,{A:()=>r})},172(t){t.exports=function(t,e){this.v=t,this.k=e},t.exports.__esModule=!0,t.exports.default=t.exports},993(t,e,n){var r=n(546);function o(){var e,n,i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.toStringTag||"@@toStringTag";function u(t,o,i,a){var s=o&&o.prototype instanceof l?o:l,u=Object.create(s.prototype);return r(u,"_invoke",function(t,r,o){var i,a,s,u=0,l=o||[],f=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,s=e,p.n=n,c}};function d(t,r){for(a=t,s=r,n=0;!f&&u&&!o&&n<l.length;n++){var o,i=l[n],d=p.p,h=i[2];t>3?(o=h===r)&&(s=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=t<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<h&&(o=t<3||i[0]>r||r>h)&&(i[4]=t,i[5]=r,p.n=h,a=0))}if(o||t>1)return c;throw f=!0,r}return function(o,l,h){if(u>1)throw TypeError("Generator is already running");for(f&&1===l&&d(l,h),a=l,s=h;(n=a<2?e:s)||!f;){i||(a?a<3?(a>1&&(p.n=-1),d(a,s)):p.n=s:p.v=s);try{if(u=2,i){if(a||(o="next"),n=i[o]){if(!(n=n.call(i,s)))throw TypeError("iterator result is not an object");if(!n.done)return n;s=n.value,a<2&&(a=0)}else 1===a&&(n=i.return)&&n.call(i),a<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((n=(f=p.n<0)?s:t.call(r,p))!==c)break}catch(t){i=e,a=1,s=t}finally{u=1}}return{value:n,done:f}}}(t,i,a),!0),u}var c={};function l(){}function f(){}function p(){}n=Object.getPrototypeOf;var d=[][a]?n(n([][a]())):(r(n={},a,function(){return this}),n),h=p.prototype=l.prototype=Object.create(d);function v(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,r(t,s,"GeneratorFunction")),t.prototype=Object.create(h),t}return f.prototype=p,r(h,"constructor",p),r(p,"constructor",f),f.displayName="GeneratorFunction",r(p,s,"GeneratorFunction"),r(h),r(h,s,"Generator"),r(h,a,function(){return this}),r(h,"toString",function(){return"[object Generator]"}),(t.exports=o=function(){return{w:u,m:v}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},869(t,e,n){var r=n(887);t.exports=function(t,e,n,o,i){var a=r(t,e,n,o,i);return a.next().then(function(t){return t.done?t.value:a.next()})},t.exports.__esModule=!0,t.exports.default=t.exports},887(t,e,n){var r=n(993),o=n(791);t.exports=function(t,e,n,i,a){return new o(r().w(t,e,n,i),a||Promise)},t.exports.__esModule=!0,t.exports.default=t.exports},791(t,e,n){var r=n(172),o=n(546);t.exports=function t(e,n){function i(t,o,a,s){try{var u=e[t](o),c=u.value;return c instanceof r?n.resolve(c.v).then(function(t){i("next",t,a,s)},function(t){i("throw",t,a,s)}):n.resolve(c).then(function(t){u.value=t,a(u)},function(t){return i("throw",t,a,s)})}catch(t){s(t)}}var a;this.next||(o(t.prototype),o(t.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),o(this,"_invoke",function(t,e,r){function o(){return new n(function(e,n){i(t,r,e,n)})}return a=a?a.then(o,o):o()},!0)},t.exports.__esModule=!0,t.exports.default=t.exports},546(t){function e(n,r,o,i){var a=Object.defineProperty;try{a({},"",{})}catch(n){a=0}t.exports=e=function(t,n,r,o){function i(n,r){e(t,n,function(t){return this._invoke(n,r,t)})}n?a?a(t,n,{value:r,enumerable:!o,configurable:!o,writable:!o}):t[n]=r:(i("next",0),i("throw",1),i("return",2))},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r,o,i)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},373(t){t.exports=function(t){var e=Object(t),n=[];for(var r in e)n.unshift(r);return function t(){for(;n.length;)if((r=n.pop())in e)return t.value=r,t.done=!1,t;return t.done=!0,t}},t.exports.__esModule=!0,t.exports.default=t.exports},633(t,e,n){var r=n(172),o=n(993),i=n(869),a=n(887),s=n(791),u=n(373),c=n(579);function l(){"use strict";var e=o(),n=e.m(l),f=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function p(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===f||"GeneratorFunction"===(e.displayName||e.name))}var d={throw:1,return:2,break:3,continue:3};function h(t){var e,n;return function(r){e||(e={stop:function(){return n(r.a,2)},catch:function(){return r.v},abrupt:function(t,e){return n(r.a,d[t],e)},delegateYield:function(t,o,i){return e.resultName=o,n(r.d,c(t),i)},finish:function(t){return n(r.f,t)}},n=function(t,n,o){r.p=e.prev,r.n=e.next;try{return t(n,o)}finally{e.next=r.n}}),e.resultName&&(e[e.resultName]=r.v,e.resultName=void 0),e.sent=r.v,e.next=r.n;try{return t.call(this,e)}finally{r.p=e.prev,r.n=e.next}}}return(t.exports=l=function(){return{wrap:function(t,n,r,o){return e.w(h(t),n,r,o&&o.reverse())},isGeneratorFunction:p,mark:e.m,awrap:function(t,e){return new r(t,e)},AsyncIterator:s,async:function(t,e,n,r,o){return(p(e)?a:i)(h(t),e,n,r,o)},keys:u,values:c}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=l,t.exports.__esModule=!0,t.exports.default=t.exports},579(t,e,n){var r=n(738).default;t.exports=function(t){if(null!=t){var e=t["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],n=0;if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}}}throw new TypeError(r(t)+" is not iterable")},t.exports.__esModule=!0,t.exports.default=t.exports},738(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},756(t,e,n){var r=n(633)();t.exports=r;try{regeneratorRuntime=r}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},705(t,e,n){"use strict";function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e,n){return(e=function(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>o})}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{PcButton:()=>e.default,PcDialog:()=>o.default,PcWaterMark:()=>t.default,PcWaterfall:()=>i.default,default:()=>s});var t=n(893),e=n(183),o=n(491),i=n(671),a=[t.default,e.default,o.default,i.default];const s={install:function(t){a.forEach(function(e){console.log(e.name),e.install(t)})}}})(),module.exports=r})();
2
+ (()=>{var t={183(t,e,n){"use strict";n.d(e,{default:()=>o});var r=n(194);r.A.install=function(t){t.component(r.A.name,r.A)};const o=r.A},491(t,e,n){"use strict";n.d(e,{default:()=>s});var r=function(){var t=this,e=t._self._c;return t.visible?e("div",{staticClass:"pc pc-dialog__box",style:[t.cusStyle]},[t.ifShowMask?e("div",{staticClass:"pc-dialog__layout",on:{click:function(t){t.stopPropagation()}}}):t._e(),t._v(" "),e("div",{staticClass:"pc-dialog__content__wrap"},[e("div",{staticClass:"pc-dialog__content"},[e("div",{staticClass:"pc-dialog__header"},[e("p",{staticClass:"pc-dialog__title pc-text-ellipsis"},[t._v(t._s(t.title))]),t._v(" "),e("p",{staticClass:"pc-dialog__sub-title pc-text-ellipsis"},[t._v(t._s(t.subTitle))]),t._v(" "),e("div",{staticClass:"pc-dialog__close",on:{click:t.close}},[e("svg",{attrs:{width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"}},[e("path",{attrs:{d:"M6.2253 4.81108C5.83477 4.42056 5.20161 4.42056 4.81108 4.81108C4.42056 5.20161 4.42056 5.83477 4.81108 6.2253L10.5858 12L4.81114 17.7747C4.42062 18.1652 4.42062 18.7984 4.81114 19.1889C5.20167 19.5794 5.83483 19.5794 6.22535 19.1889L12 13.4142L17.7747 19.1889C18.1652 19.5794 18.7984 19.5794 19.1889 19.1889C19.5794 18.7984 19.5794 18.1652 19.1889 17.7747L13.4142 12L19.189 6.2253C19.5795 5.83477 19.5795 5.20161 19.189 4.81108C18.7985 4.42056 18.1653 4.42056 17.7748 4.81108L12 10.5858L6.2253 4.81108Z",fill:"currentColor"}})])])]),t._v(" "),t.ifShowMain?e("div",{staticClass:"pc-dialog__main"},[t._t("default")],2):t._e(),t._v(" "),t.buttons&&t.buttons.length?[e("div",{class:["pc-dialog__footer","pc-flex","pc-flex-end",{border:t.ifShowMain}]},t._l(t.buttons,function(n,r){return e("PcButton",t._b({key:r},"PcButton",n,!1))}),1)]:[e("div",{staticStyle:{height:"10px"}})]],2)])]):t._e()};r._withStripped=!0;var o=n(705);const i={name:"PcDialog",components:{PcButton:n(194).A},model:{prop:"visible",event:"update:visible"},props:{title:{type:String,default:""},subTitle:{type:String,default:""},ifShowMask:{type:Boolean,default:!0},width:{type:Number,default:400},buttons:{type:Array,default:function(){return[]}},visible:{type:Boolean,default:!0}},emits:["close"],data:function(){return{}},computed:{cusStyle:function(){return(0,o.A)({},"--width","".concat(this.width,"px"))},ifShowMain:function(){return Boolean(this.$scopedSlots.default)}},watch:{visible:function(t){document.body.style.overflow=t?"hidden":""}},mounted:function(){var t=this;this.$nextTick(function(){document.body.prepend(t.$el),t.bindEsc()})},beforeDestroy:function(){this.unbindEsc(),this.$el.parentNode===document.body&&document.body.removeChild(this.$el)},methods:{close:function(){this.$emit("close"),this.$emit("update:visible",!1)},handleEsc:function(t){"Escape"===t.key&&this.close()},bindEsc:function(){document.addEventListener("keydown",this.handleEsc)},unbindEsc:function(){document.removeEventListener("keydown",this.handleEsc)}}},a=(0,n(486).A)(i,r,[],!1,null,"01f0e5c2",null).exports;a.install=function(t){t.component(a.name,a)};const s=a},814(t,e,n){"use strict";n.d(e,{default:()=>u});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-tabs",style:[t.cusStyle]},["vertical"===t.direction?[e("div",{staticClass:"pc-tabs_v_wrap pc-flex"},[e("div",{staticClass:"pc-tabs_list_v pc-flex pc-flex-column"},t._l(t.tabs,function(n,r){return e("p",{key:n.value,ref:"tab-item"+r,refInFor:!0,class:["pc-tabs_list_item","pc-text-ellipsis",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,r)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tabs_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]:[e("div",{staticClass:"pc-tabs_h_wrap pc-flex pc-flex-column"},[e("div",{staticClass:"pc-tabs_list_h pc-flex pc-flex-align-center"},t._l(t.tabs,function(n,r){return e("p",{key:n.value,ref:"tab-item"+r,refInFor:!0,class:["pc-tabs_list_item",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,r)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tab_active"}),t._v(" "),e("div",{staticClass:"pc-tab_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]],2)};r._withStripped=!0;var o=n(705);const i={name:"PcTabs",model:{prop:"value",event:"update:change"},props:{value:{type:String,default:""},tabs:{type:Array,default:function(){return[]}},keepAlive:{type:Boolean,default:!0},direction:{type:String,default:"horizontal"}},data:function(){return{curTabValue:"",offsetLeft:0,offsetWidth:0}},computed:{cusStyle:function(){return(0,o.A)((0,o.A)({},"--offset-left",this.offsetLeft+"px"),"--offset-width",this.offsetWidth+"px")}},watch:{value:{handler:function(t){var e;!function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(e,n){return Reflect.has(n,t)&&e.push(n[t]),e},[])}(this.tabs,"value").includes(t)?this.curTabValue=null===(e=this.tabs[0])||void 0===e?void 0:e.value:this.curTabValue=t},deep:!0,immediate:!0}},mounted:function(){var t=this;"horizontal"===this.direction&&this.$nextTick(function(){var e=t.tabs.findIndex(function(e){return e.value===t.curTabValue});if(-1!==e){var n=t.$refs["tab-item"+e][0],r=n.offsetWidth,o=n.offsetLeft;t.offsetWidth=r-20,t.offsetLeft=o}})},methods:{changeTab:function(t,e){if(this.$emit("update:change",t.value),"horizontal"===this.direction){var n=this.$refs["tab-item"+e][0].offsetWidth,r=this.$refs["tab-item"+e][0].offsetLeft;this.offsetWidth=n-20,this.offsetLeft=r}}}},a=i,s=(0,n(486).A)(a,r,[],!1,null,"6028b20c",null).exports;s.install=function(t){t.component(s.name,s)};const u=s},671(t,e,n){"use strict";n.d(e,{default:()=>f});var r=function(){var t=this,e=t._self._c;return e("div",{ref:"waterfall",staticClass:"waterfall",style:[t.cusStyle]},[t._t("header"),t._v(" "),t.data.length?[e("div",{staticClass:"waterfall-container"},t._l(t.columnsData,function(n,r){return e("div",{key:r,staticClass:"waterfall-column"},t._l(n,function(n,r){return e("div",{key:r,staticClass:"waterfall-item"},[t._t("item",null,{item:n})],2)}),0)}),0)]:[t._t("empty")],t._v(" "),t._t("footer")],2)};function o(t,e,n,r,o,i,a){try{var s=t[i](a),u=s.value}catch(t){return void n(t)}s.done?e(u):Promise.resolve(u).then(r,o)}r._withStripped=!0;var i=n(705),a=n(756),s=n.n(a);const u={name:"PcWaterFall",props:{list:{type:Array,default:function(){return[]}},gapX:{type:Number,default:20},gapY:{type:Number,default:20},columns:{type:Number,default:2}},data:function(){return{current:0,columnsData:[],columnsHeight:[]}},computed:{data:{get:function(){return this.list}},cusStyle:function(){return(0,i.A)((0,i.A)((0,i.A)({},"--gap-x","".concat(this.gapX,"px")),"--gap-y","".concat(this.gapY,"px")),"--column",this.columns)}},watch:{list:{handler:function(t,e){t.length?(t.length<(null==e?void 0:e.length)&&this.reset(),this.init()):this.reset()},immediate:!0},columns:function(){var t=this;this.reset(),this.$nextTick(function(){t.init()})}},methods:{reset:function(){this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0}),this.current=0},init:function(){this.list.length?(0===this.current&&(this.columnsData=Array.from({length:this.columns},function(){return[]}),this.columnsHeight=Array.from({length:this.columns},function(){return 0})),this.renderList()):this.reset()},renderList:function(){var t,e=this;return(t=s().mark(function t(){var n,r,o;return s().wrap(function(t){for(;;)switch(t.prev=t.next){case 0:n=e.current;case 1:if(!(n<e.list.length)){t.next=4;break}return r=e.list[n],o=e.getMinColumn(),e.columnsData[o].push(r),t.next=2,e.$nextTick();case 2:e.calcHeight(o);case 3:n++,t.next=1;break;case 4:e.current=e.list.length;case 5:case"end":return t.stop()}},t)}),function(){var e=this,n=arguments;return new Promise(function(r,i){var a=t.apply(e,n);function s(t){o(a,r,i,s,u,"next",t)}function u(t){o(a,r,i,s,u,"throw",t)}s(void 0)})})()},getMinColumn:function(){var t=this.columnsHeight[0],e=0;return this.columnsHeight.forEach(function(n,r){n<t&&(t=n,e=r)}),e},calcHeight:function(t){var e=this.$el.querySelectorAll(".waterfall-column");this.columnsHeight[t]=e[t].offsetHeight}}},l=u,c=(0,n(486).A)(l,r,[],!1,null,"7c5bcaac",null).exports;c.install=function(t){t.component(c.name,c)};const f=c},893(t,e,n){"use strict";n.d(e,{default:()=>a});var r=function(){return(0,this._self._c)("canvas",{ref:"canvas"})};r._withStripped=!0;const o={name:"PcWaterMark",props:{width:{type:Number,default:300},height:{type:Number,default:150},src:{type:String,required:!0},text:{type:String,default:""},fontSize:{type:Number,default:16},color:{type:String,default:"#000"},deg:{type:Number,default:45,validator:function(t){return!(t<0||t>360)||(console.warn("[Watermark] deg must be between 0 and 360"),!1)}},gapY:{type:Number,default:20},gapX:{type:Number,default:20}},mounted:function(){this.init()},methods:{init:function(){var t=this,e=this.$refs.canvas,n=e.getContext("2d"),r=window.devicePixelRatio||1;e.width=this.width*r,e.height=this.height*r,e.style.width="".concat(this.width,"px"),e.style.height="".concat(this.height,"px"),n.scale(r,r);var o=new Image;o.crossOrigin="anonymous",o.src=this.src,o.onload=function(){n.drawImage(o,0,0,t.width,t.height),n.font="".concat(t.fontSize,"px sans-serif"),n.fillStyle=t.color,n.textAlign="left",n.textBaseline="middle";var e=n.measureText(t.text).width;n.save(),n.translate(t.width/2,t.height/2),n.rotate(t.deg*Math.PI/180),n.translate(-t.width/2,-t.height/2);for(var r=t.fontSize+t.gapY,i=e+t.gapX,a=-t.height;a<2*t.height;a+=r)for(var s=-t.width;s<2*t.width;s+=i)n.fillText(t.text,s,a);n.restore()}}}},i=(0,n(486).A)(o,r,[],!1,null,null,null).exports;i.install=function(t){t.component(i.name,i)};const a=i},194(t,e,n){"use strict";n.d(e,{A:()=>i});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-button pc-inline-flex pc-flex-center pc-flex-align-center"},["text"===t.type?[e("span",{class:["pc-button__text",{disabled:t.disabled}],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t._v(t._s(t.text))])]:[e("button",{class:["pc-button__wrap pc-flex pc-flex-center pc-flex-align-center",{disabled:t.disabled||t.loading},t.type],on:{click:function(e){return e.stopPropagation(),t.clickButton.apply(null,arguments)}}},[t.loading?[e("svg",{staticClass:"pc-rotate",attrs:{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024",width:"14",height:"14"}},[e("path",{attrs:{fill:"currentColor",d:"M512 64a32 32 0 0 1 32 32v192a32 32 0 0 1-64 0V96a32 32 0 0 1 32-32m0 640a32 32 0 0 1 32 32v192a32 32 0 1 1-64 0V736a32 32 0 0 1 32-32m448-192a32 32 0 0 1-32 32H736a32 32 0 1 1 0-64h192a32 32 0 0 1 32 32m-640 0a32 32 0 0 1-32 32H96a32 32 0 0 1 0-64h192a32 32 0 0 1 32 32M195.2 195.2a32 32 0 0 1 45.248 0L376.32 331.008a32 32 0 0 1-45.248 45.248L195.2 240.448a32 32 0 0 1 0-45.248m452.544 452.544a32 32 0 0 1 45.248 0L828.8 783.552a32 32 0 0 1-45.248 45.248L647.744 692.992a32 32 0 0 1 0-45.248M828.8 195.264a32 32 0 0 1 0 45.184L692.992 376.32a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0m-452.544 452.48a32 32 0 0 1 0 45.248L240.448 828.8a32 32 0 0 1-45.248-45.248l135.808-135.808a32 32 0 0 1 45.248 0"}})])]:t._e(),t._v(" "),e("span",{staticClass:"pc-button__text"},[t._v(t._s(t.text))])],2)]],2)};r._withStripped=!0;const o={name:"PcButton",props:{type:{type:String,default:"primary",validator:function(t){return!!["primary","hollow","text"].includes(t)||(console.warn("只支持primary、hollow或者text类型"),!1)}},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},text:{type:String,required:!0},click:{type:Function,default:function(){return function(){}}}},emits:["click"],methods:{clickButton:function(){this.disabled||this.loading||("[object Function]"===Object.prototype.toString.call(this.click)&&this.click(),this.$emit("click"))}}},i=(0,n(486).A)(o,r,[],!1,null,"12b3918a",null).exports},486(t,e,n){"use strict";function r(t,e,n,r,o,i,a,s){var u,l="function"==typeof t?t.options:t;if(e&&(l.render=e,l.staticRenderFns=n,l._compiled=!0),r&&(l.functional=!0),i&&(l._scopeId="data-v-"+i),a?(u=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),o&&o.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(a)},l._ssrRegister=u):o&&(u=s?function(){o.call(this,(l.functional?this.parent:this).$root.$options.shadowRoot)}:o),u)if(l.functional){l._injectStyles=u;var c=l.render;l.render=function(t,e){return u.call(e),c(t,e)}}else{var f=l.beforeCreate;l.beforeCreate=f?[].concat(f,u):[u]}return{exports:t,options:l}}n.d(e,{A:()=>r})},172(t){t.exports=function(t,e){this.v=t,this.k=e},t.exports.__esModule=!0,t.exports.default=t.exports},993(t,e,n){var r=n(546);function o(){var e,n,i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",s=i.toStringTag||"@@toStringTag";function u(t,o,i,a){var s=o&&o.prototype instanceof c?o:c,u=Object.create(s.prototype);return r(u,"_invoke",function(t,r,o){var i,a,s,u=0,c=o||[],f=!1,p={p:0,n:0,v:e,a:d,f:d.bind(e,4),d:function(t,n){return i=t,a=0,s=e,p.n=n,l}};function d(t,r){for(a=t,s=r,n=0;!f&&u&&!o&&n<c.length;n++){var o,i=c[n],d=p.p,h=i[2];t>3?(o=h===r)&&(s=i[(a=i[4])?5:(a=3,3)],i[4]=i[5]=e):i[0]<=d&&((o=t<2&&d<i[1])?(a=0,p.v=r,p.n=i[1]):d<h&&(o=t<3||i[0]>r||r>h)&&(i[4]=t,i[5]=r,p.n=h,a=0))}if(o||t>1)return l;throw f=!0,r}return function(o,c,h){if(u>1)throw TypeError("Generator is already running");for(f&&1===c&&d(c,h),a=c,s=h;(n=a<2?e:s)||!f;){i||(a?a<3?(a>1&&(p.n=-1),d(a,s)):p.n=s:p.v=s);try{if(u=2,i){if(a||(o="next"),n=i[o]){if(!(n=n.call(i,s)))throw TypeError("iterator result is not an object");if(!n.done)return n;s=n.value,a<2&&(a=0)}else 1===a&&(n=i.return)&&n.call(i),a<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),a=1);i=e}else if((n=(f=p.n<0)?s:t.call(r,p))!==l)break}catch(t){i=e,a=1,s=t}finally{u=1}}return{value:n,done:f}}}(t,i,a),!0),u}var l={};function c(){}function f(){}function p(){}n=Object.getPrototypeOf;var d=[][a]?n(n([][a]())):(r(n={},a,function(){return this}),n),h=p.prototype=c.prototype=Object.create(d);function v(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,r(t,s,"GeneratorFunction")),t.prototype=Object.create(h),t}return f.prototype=p,r(h,"constructor",p),r(p,"constructor",f),f.displayName="GeneratorFunction",r(p,s,"GeneratorFunction"),r(h),r(h,s,"Generator"),r(h,a,function(){return this}),r(h,"toString",function(){return"[object Generator]"}),(t.exports=o=function(){return{w:u,m:v}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=o,t.exports.__esModule=!0,t.exports.default=t.exports},869(t,e,n){var r=n(887);t.exports=function(t,e,n,o,i){var a=r(t,e,n,o,i);return a.next().then(function(t){return t.done?t.value:a.next()})},t.exports.__esModule=!0,t.exports.default=t.exports},887(t,e,n){var r=n(993),o=n(791);t.exports=function(t,e,n,i,a){return new o(r().w(t,e,n,i),a||Promise)},t.exports.__esModule=!0,t.exports.default=t.exports},791(t,e,n){var r=n(172),o=n(546);t.exports=function t(e,n){function i(t,o,a,s){try{var u=e[t](o),l=u.value;return l instanceof r?n.resolve(l.v).then(function(t){i("next",t,a,s)},function(t){i("throw",t,a,s)}):n.resolve(l).then(function(t){u.value=t,a(u)},function(t){return i("throw",t,a,s)})}catch(t){s(t)}}var a;this.next||(o(t.prototype),o(t.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),o(this,"_invoke",function(t,e,r){function o(){return new n(function(e,n){i(t,r,e,n)})}return a=a?a.then(o,o):o()},!0)},t.exports.__esModule=!0,t.exports.default=t.exports},546(t){function e(n,r,o,i){var a=Object.defineProperty;try{a({},"",{})}catch(n){a=0}t.exports=e=function(t,n,r,o){function i(n,r){e(t,n,function(t){return this._invoke(n,r,t)})}n?a?a(t,n,{value:r,enumerable:!o,configurable:!o,writable:!o}):t[n]=r:(i("next",0),i("throw",1),i("return",2))},t.exports.__esModule=!0,t.exports.default=t.exports,e(n,r,o,i)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},373(t){t.exports=function(t){var e=Object(t),n=[];for(var r in e)n.unshift(r);return function t(){for(;n.length;)if((r=n.pop())in e)return t.value=r,t.done=!1,t;return t.done=!0,t}},t.exports.__esModule=!0,t.exports.default=t.exports},633(t,e,n){var r=n(172),o=n(993),i=n(869),a=n(887),s=n(791),u=n(373),l=n(579);function c(){"use strict";var e=o(),n=e.m(c),f=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function p(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===f||"GeneratorFunction"===(e.displayName||e.name))}var d={throw:1,return:2,break:3,continue:3};function h(t){var e,n;return function(r){e||(e={stop:function(){return n(r.a,2)},catch:function(){return r.v},abrupt:function(t,e){return n(r.a,d[t],e)},delegateYield:function(t,o,i){return e.resultName=o,n(r.d,l(t),i)},finish:function(t){return n(r.f,t)}},n=function(t,n,o){r.p=e.prev,r.n=e.next;try{return t(n,o)}finally{e.next=r.n}}),e.resultName&&(e[e.resultName]=r.v,e.resultName=void 0),e.sent=r.v,e.next=r.n;try{return t.call(this,e)}finally{r.p=e.prev,r.n=e.next}}}return(t.exports=c=function(){return{wrap:function(t,n,r,o){return e.w(h(t),n,r,o&&o.reverse())},isGeneratorFunction:p,mark:e.m,awrap:function(t,e){return new r(t,e)},AsyncIterator:s,async:function(t,e,n,r,o){return(p(e)?a:i)(h(t),e,n,r,o)},keys:u,values:l}},t.exports.__esModule=!0,t.exports.default=t.exports)()}t.exports=c,t.exports.__esModule=!0,t.exports.default=t.exports},579(t,e,n){var r=n(738).default;t.exports=function(t){if(null!=t){var e=t["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],n=0;if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length))return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}}}throw new TypeError(r(t)+" is not iterable")},t.exports.__esModule=!0,t.exports.default=t.exports},738(t){function e(n){return t.exports=e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t.exports.__esModule=!0,t.exports.default=t.exports,e(n)}t.exports=e,t.exports.__esModule=!0,t.exports.default=t.exports},756(t,e,n){var r=n(633)();t.exports=r;try{regeneratorRuntime=r}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},705(t,e,n){"use strict";function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e,n){return(e=function(t){var e=function(t){if("object"!=r(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=r(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==r(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>o})}},e={};function n(r){var o=e[r];if(void 0!==o)return o.exports;var i=e[r]={exports:{}};return t[r](i,i.exports,n),i.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r={};(()=>{"use strict";n.r(r),n.d(r,{PcButton:()=>e.default,PcDialog:()=>o.default,PcTabs:()=>a.default,PcWaterMark:()=>t.default,PcWaterfall:()=>i.default,default:()=>u});var t=n(893),e=n(183),o=n(491),i=n(671),a=n(814),s=[t.default,e.default,o.default,i.default,a.default];const u={install:function(t){s.forEach(function(e){console.log(e.name),e.install(t)})}}})(),module.exports=r})();
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -385,3 +386,76 @@
385
386
  gap: var(--gap-y);
386
387
  }
387
388
 
389
+ .pc-tabs[data-v-6028b20c] {
390
+ height: inherit;
391
+ }
392
+ .pc-tabs_v_wrap[data-v-6028b20c] {
393
+ height: inherit;
394
+ gap: 14px;
395
+ }
396
+ .pc-tabs_v_wrap .pc-tabs_list_v[data-v-6028b20c] {
397
+ background-color: #ecf5ff;
398
+ flex-shrink: 0;
399
+ gap: 10px;
400
+ width: 150px;
401
+ overflow-y: auto;
402
+ box-sizing: border-box;
403
+ padding: 8px 12px;
404
+ height: 100%;
405
+ }
406
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c] {
407
+ flex-shrink: 0;
408
+ padding: 4px 8px;
409
+ font-size: 15px;
410
+ border-radius: var(--cl-border-radius-mini);
411
+ border: 1px solid #d9ecff;
412
+ box-sizing: border-box;
413
+ background-color: #fff;
414
+ text-align: center;
415
+ cursor: pointer;
416
+ color: var(--pc-text-color-primary);
417
+ }
418
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item.active[data-v-6028b20c] {
419
+ color: var(--pc-color-primary);
420
+ }
421
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
422
+ color: var(--pc-color-primary);
423
+ }
424
+ .pc-tabs_v_wrap .pc-tabs_content[data-v-6028b20c] {
425
+ flex: 1;
426
+ overflow: auto;
427
+ }
428
+ .pc-tabs_h_wrap[data-v-6028b20c] {
429
+ height: 100%;
430
+ }
431
+ .pc-tabs_h_wrap .pc-tabs_list_h[data-v-6028b20c] {
432
+ overflow: auto;
433
+ }
434
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c] {
435
+ font-size: 15px;
436
+ padding: 0 10px;
437
+ cursor: pointer;
438
+ color: var(--pc-text-color-primary);
439
+ flex-shrink: 0;
440
+ }
441
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item.active[data-v-6028b20c] {
442
+ color: var(--pc-color-primary);
443
+ }
444
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
445
+ color: var(--pc-color-primary);
446
+ }
447
+ .pc-tabs_h_wrap .pc-tab_active[data-v-6028b20c] {
448
+ height: 1px;
449
+ display: inline-block;
450
+ background-color: var(--pc-color-primary);
451
+ width: var(--offset-width);
452
+ transform: translateX(var(--offset-left));
453
+ transition: all 0.3s ease;
454
+ }
455
+ .pc-tabs_h_wrap .pc-tab_content[data-v-6028b20c] {
456
+ flex: 1;
457
+ overflow: auto;
458
+ height: 0;
459
+ min-height: 0;
460
+ }
461
+
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -0,0 +1 @@
1
+ (()=>{"use strict";var t={486(t,e,n){function i(t,e,n,i,r,a,o,s){var l,u="function"==typeof t?t.options:t;if(e&&(u.render=e,u.staticRenderFns=n,u._compiled=!0),i&&(u.functional=!0),a&&(u._scopeId="data-v-"+a),o?(l=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),r&&r.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(o)},u._ssrRegister=l):r&&(l=s?function(){r.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:r),l)if(u.functional){u._injectStyles=l;var c=u.render;u.render=function(t,e){return l.call(e),c(t,e)}}else{var f=u.beforeCreate;u.beforeCreate=f?[].concat(f,l):[l]}return{exports:t,options:u}}n.d(e,{A:()=>i})},705(t,e,n){function i(t){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},i(t)}function r(t,e,n){return(e=function(t){var e=function(t){if("object"!=i(t)||!t)return t;var e=t[Symbol.toPrimitive];if(void 0!==e){var n=e.call(t,"string");if("object"!=i(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(t)}(t);return"symbol"==i(e)?e:e+""}(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,{A:()=>r})}},e={};function n(i){var r=e[i];if(void 0!==r)return r.exports;var a=e[i]={exports:{}};return t[i](a,a.exports,n),a.exports}n.d=(t,e)=>{for(var i in e)n.o(e,i)&&!n.o(t,i)&&Object.defineProperty(t,i,{enumerable:!0,get:e[i]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var i={};n.r(i),n.d(i,{default:()=>l});var r=function(){var t=this,e=t._self._c;return e("div",{staticClass:"pc-tabs",style:[t.cusStyle]},["vertical"===t.direction?[e("div",{staticClass:"pc-tabs_v_wrap pc-flex"},[e("div",{staticClass:"pc-tabs_list_v pc-flex pc-flex-column"},t._l(t.tabs,function(n,i){return e("p",{key:n.value,ref:"tab-item"+i,refInFor:!0,class:["pc-tabs_list_item","pc-text-ellipsis",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,i)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tabs_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]:[e("div",{staticClass:"pc-tabs_h_wrap pc-flex pc-flex-column"},[e("div",{staticClass:"pc-tabs_list_h pc-flex pc-flex-align-center"},t._l(t.tabs,function(n,i){return e("p",{key:n.value,ref:"tab-item"+i,refInFor:!0,class:["pc-tabs_list_item",{active:n.value===t.curTabValue}],on:{click:function(e){return t.changeTab(n,i)}}},[t._v("\n "+t._s(n.label)+"\n ")])}),0),t._v(" "),e("div",{staticClass:"pc-tab_active"}),t._v(" "),e("div",{staticClass:"pc-tab_content"},[t.keepAlive?t._l(t.tabs,function(n){return e("div",{key:n.value},[e("div",{directives:[{name:"show",rawName:"v-show",value:n.value===t.curTabValue,expression:"item.value === curTabValue"}]},[t._t(n.value)],2)])}):[t._t(t.curTabValue)]],2)])]],2)};r._withStripped=!0;var a=n(705);const o={name:"PcTabs",model:{prop:"value",event:"update:change"},props:{value:{type:String,default:""},tabs:{type:Array,default:function(){return[]}},keepAlive:{type:Boolean,default:!0},direction:{type:String,default:"horizontal"}},data:function(){return{curTabValue:"",offsetLeft:0,offsetWidth:0}},computed:{cusStyle:function(){return(0,a.A)((0,a.A)({},"--offset-left",this.offsetLeft+"px"),"--offset-width",this.offsetWidth+"px")}},watch:{value:{handler:function(t){var e;!function(){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(e,n){return Reflect.has(n,t)&&e.push(n[t]),e},[])}(this.tabs,"value").includes(t)?this.curTabValue=null===(e=this.tabs[0])||void 0===e?void 0:e.value:this.curTabValue=t},deep:!0,immediate:!0}},mounted:function(){var t=this;"horizontal"===this.direction&&this.$nextTick(function(){var e=t.tabs.findIndex(function(e){return e.value===t.curTabValue});if(-1!==e){var n=t.$refs["tab-item"+e][0],i=n.offsetWidth,r=n.offsetLeft;t.offsetWidth=i-20,t.offsetLeft=r}})},methods:{changeTab:function(t,e){if(this.$emit("update:change",t.value),"horizontal"===this.direction){var n=this.$refs["tab-item"+e][0].offsetWidth,i=this.$refs["tab-item"+e][0].offsetLeft;this.offsetWidth=n-20,this.offsetLeft=i}}}},s=(0,n(486).A)(o,r,[],!1,null,"6028b20c",null).exports;s.install=function(t){t.component(s.name,s)};const l=s;module.exports=i})();
@@ -0,0 +1,73 @@
1
+ .pc-tabs[data-v-6028b20c] {
2
+ height: inherit;
3
+ }
4
+ .pc-tabs_v_wrap[data-v-6028b20c] {
5
+ height: inherit;
6
+ gap: 14px;
7
+ }
8
+ .pc-tabs_v_wrap .pc-tabs_list_v[data-v-6028b20c] {
9
+ background-color: #ecf5ff;
10
+ flex-shrink: 0;
11
+ gap: 10px;
12
+ width: 150px;
13
+ overflow-y: auto;
14
+ box-sizing: border-box;
15
+ padding: 8px 12px;
16
+ height: 100%;
17
+ }
18
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c] {
19
+ flex-shrink: 0;
20
+ padding: 4px 8px;
21
+ font-size: 15px;
22
+ border-radius: var(--cl-border-radius-mini);
23
+ border: 1px solid #d9ecff;
24
+ box-sizing: border-box;
25
+ background-color: #fff;
26
+ text-align: center;
27
+ cursor: pointer;
28
+ color: var(--pc-text-color-primary);
29
+ }
30
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item.active[data-v-6028b20c] {
31
+ color: var(--pc-color-primary);
32
+ }
33
+ .pc-tabs_v_wrap .pc-tabs_list_v .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
34
+ color: var(--pc-color-primary);
35
+ }
36
+ .pc-tabs_v_wrap .pc-tabs_content[data-v-6028b20c] {
37
+ flex: 1;
38
+ overflow: auto;
39
+ }
40
+ .pc-tabs_h_wrap[data-v-6028b20c] {
41
+ height: 100%;
42
+ }
43
+ .pc-tabs_h_wrap .pc-tabs_list_h[data-v-6028b20c] {
44
+ overflow: auto;
45
+ }
46
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c] {
47
+ font-size: 15px;
48
+ padding: 0 10px;
49
+ cursor: pointer;
50
+ color: var(--pc-text-color-primary);
51
+ flex-shrink: 0;
52
+ }
53
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item.active[data-v-6028b20c] {
54
+ color: var(--pc-color-primary);
55
+ }
56
+ .pc-tabs_h_wrap .pc-tabs_list_h .pc-tabs_list_item[data-v-6028b20c]:not(.active):hover {
57
+ color: var(--pc-color-primary);
58
+ }
59
+ .pc-tabs_h_wrap .pc-tab_active[data-v-6028b20c] {
60
+ height: 1px;
61
+ display: inline-block;
62
+ background-color: var(--pc-color-primary);
63
+ width: var(--offset-width);
64
+ transform: translateX(var(--offset-left));
65
+ transition: all 0.3s ease;
66
+ }
67
+ .pc-tabs_h_wrap .pc-tab_content[data-v-6028b20c] {
68
+ flex: 1;
69
+ overflow: auto;
70
+ height: 0;
71
+ min-height: 0;
72
+ }
73
+
@@ -57,6 +57,7 @@
57
57
  --pc-border-color-extralight: #dcdfe6;
58
58
 
59
59
  /* radius */
60
+ --cl-border-radius-mini: 2px;
60
61
  --cl-border-radius-small: 4px;
61
62
  --cl-border-radius-base: 6px;
62
63
  --cl-border-radius-round: 20px;
@@ -0,0 +1 @@
1
+ (()=>{"use strict";var e={d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{DateUtils:()=>n,ListUtils:()=>r});var r={};e.r(r),e.d(r,{getValuesByKey:()=>o});var n={};e.r(n),e.d(n,{formatTime:()=>i});var o=function(){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).reduce(function(t,r){return Reflect.has(r,e)&&t.push(r[e]),t},[])},i=function(e){var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"YYYY-MM-DD HH:mm:ss";if(!e)return"";if("number"==typeof e||/^\d+$/.test(e)){var n=Number(e);10===n.toString().length&&(n*=1e3),t=new Date(n)}else if("string"==typeof e)t=t.replace(/-/g,"/");else{if(!(e instanceof Date))return"";t=e}if(isNaN(t.getTime()))return"";var o=function(e){return String(e).padStart(2,"0")},i={YYYY:t.getFullYear(),MM:o(t.getMonth()+1),DD:o(t.getDate()),HH:o(t.getHours()),mm:o(t.getMinutes()),ss:o(t.getSeconds())};return r.replace(/YYYY|MM|DD|HH|mm|ss/g,function(e){return i[e]})};module.exports=t})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "component-library-for-vue",
3
- "version": "2.0.2",
3
+ "version": "2.1.0",
4
4
  "description": "自定义的ui组件库",
5
5
  "main": "libs/index/index.js",
6
6
  "module": "es/index/index.js",