comp-hub 0.31.2 → 0.41.2
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 +3 -2
- package/bin/lib/startup.js +1 -1
- package/dist/index.js +3 -3
- package/dist/master.js +23 -23
- package/dist/website/container/assets/{index-BR_ZVtEf.js → index-BF46-8S8.js} +13 -13
- package/dist/website/container/assets/{index-Y--RAA6W.css → index-DN-EG3Qh.css} +1 -1
- package/dist/website/container/index.html +3 -2
- package/dist/website/container/js/react-jsx-loader.js +233 -0
- package/dist/website/item/assets/index-iYpmJN_Z.css +1 -0
- package/dist/website/item/assets/index-r0gnU8T3.js +62 -0
- package/dist/website/item/index.html +2 -2
- package/dist/website/main/assets/{AuthCodeSendBtn.vue_vue_type_script_setup_true_lang-C5to3ZQC.js → AuthCodeSendBtn.vue_vue_type_script_setup_true_lang-XaDuBXZe.js} +1 -1
- package/dist/website/main/assets/{BaseBadge-DUuZfvYd.js → BaseBadge-CwPduDSy.js} +1 -1
- package/dist/website/main/assets/{BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js → BaseDialog.vue_vue_type_script_setup_true_lang-CkNHSg5g.js} +1 -1
- package/dist/website/main/assets/{BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js → BaseSegmented.vue_vue_type_script_setup_true_lang-QoRVS1cj.js} +1 -1
- package/dist/website/main/assets/{CanvasAnimation.vue_vue_type_script_setup_true_lang-CisWACfW.js → CanvasAnimation.vue_vue_type_script_setup_true_lang-C4ID6BIz.js} +1 -1
- package/dist/website/main/assets/{CodeMirrorEditor-Cqow8ROO-DMgFI1zV.js → CodeMirrorEditor-Cqow8ROO-Cb1F80wf.js} +3 -3
- package/dist/website/main/assets/{EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js → EmptyStatusContainer.vue_vue_type_script_setup_true_lang-D9ipEmGE.js} +1 -1
- package/dist/website/main/assets/GithubCallback-CvYaECQV.js +1 -0
- package/dist/website/main/assets/ReplyForm.vue_vue_type_script_setup_true_lang-Cg6jGDaf.js +1 -0
- package/dist/website/main/assets/{core-DIlcfMir.js → core-yetgou6F.js} +1 -1
- package/dist/website/main/assets/{el-table-column-DUFMPIr5.js → el-table-column-BpgDq_WF.js} +1 -1
- package/dist/website/main/assets/index-3zCQDZnh.js +2 -0
- package/dist/website/main/assets/{index-72rReQ2I-sU_re5gS.js → index-72rReQ2I-BUkUG78x.js} +1 -1
- package/dist/website/main/assets/index-74ZEuWc8.js +1 -0
- package/dist/website/main/assets/index-9wcpsZe1.js +1 -0
- package/dist/website/main/assets/index-BCpgCtua.js +1 -0
- package/dist/website/main/assets/{index-HnLIbMTX.js → index-BJKOBdMx.js} +1 -1
- package/dist/website/main/assets/index-BMOsY3cQ.js +2 -0
- package/dist/website/main/assets/index-BMVmqejS.js +1 -0
- package/dist/website/main/assets/{index-BiQ2dJm4.js → index-BcfC5qCh.js} +1 -1
- package/dist/website/main/assets/{index-DwDo8mID.js → index-BnX30az1.js} +1 -1
- package/dist/website/main/assets/{index-Ct_U5I7y.js → index-BouHS9Ky.js} +1 -1
- package/dist/website/main/assets/index-Bp79GOY4.js +1 -0
- package/dist/website/main/assets/{index-Cbpqtmwk.js → index-BsZl8udl.js} +1 -1
- package/dist/website/main/assets/{index-B-fZjRMn.js → index-Bucicr-O.js} +1 -1
- package/dist/website/main/assets/index-CXKzXFNq.js +1 -0
- package/dist/website/main/assets/{index-DlU_hLR3.js → index-CbpqTP74.js} +1 -1
- package/dist/website/main/assets/{index-CxLzXF-b.js → index-CgJn84pE.js} +1 -1
- package/dist/website/main/assets/{index-CvGH1xqJ.css → index-CioMG7I6.css} +1 -1
- package/dist/website/main/assets/index-ClqLWOrM.js +1 -0
- package/dist/website/main/assets/index-CopP0_Oh.js +1 -0
- package/dist/website/main/assets/{index-Da5ZhB-r.js → index-CxeWFTBn.js} +1 -1
- package/dist/website/main/assets/index-CzxUr7HV.js +1 -0
- package/dist/website/main/assets/{index-CjE-geY_.css → index-D-8GYlU8.css} +1 -1
- package/dist/website/main/assets/{index-Jp4YN25a.js → index-D4WFMTSP.js} +1 -1
- package/dist/website/main/assets/{index-D76eWsZ1-BUecZt4E.js → index-D76eWsZ1-7KvuCuMg.js} +1 -1
- package/dist/website/main/assets/index-DCet9p8Y.js +1 -0
- package/dist/website/main/assets/{index-Cz3keLmq.js → index-DMO6XTC0.js} +1 -1
- package/dist/website/main/assets/{index-DKv4dFPY.js → index-DP0Xav0B.js} +1 -1
- package/dist/website/main/assets/index-DXY5BNS4.js +1 -0
- package/dist/website/main/assets/{index-Dms7ZQ2h-DY4-ZFKr.js → index-Dms7ZQ2h-BXeasSDQ.js} +1 -1
- package/dist/website/main/assets/{index-DqiFCfGx-BY8MJk0B.js → index-DqiFCfGx-4HZIi15Y.js} +1 -1
- package/dist/website/main/assets/{index-DxypSQ0K-CDh8t7kw.js → index-DxypSQ0K-DsBZbAQO.js} +1 -1
- package/dist/website/main/assets/{index-CnhaF7r3.js → index-FOvWqIoM.js} +1 -1
- package/dist/website/main/assets/{index-CQSvO48y.js → index-HvNFjpLq.js} +1 -1
- package/dist/website/main/assets/{index-Cu1aNpBv.js → index-KZ5xMbrf.js} +1 -1
- package/dist/website/main/assets/index-PtEeGBK6.js +1 -0
- package/dist/website/main/assets/{index-T76vWLBU-Bpnxnyfv.js → index-T76vWLBU-C2L4ZR6a.js} +1 -1
- package/dist/website/main/assets/{index-CnTuJQbj.js → index-YvDl_1WK.js} +23 -23
- package/dist/website/main/assets/{index-fZBcgzqR-QE1WZxps.js → index-fZBcgzqR-DZ4VEjtI.js} +1 -1
- package/dist/website/main/assets/{index-mqeGrL6B-DZ51JJUI.js → index-mqeGrL6B-zaO8HgOa.js} +1 -1
- package/dist/website/main/assets/{index-QDS7dx0M.js → index-rm7l2BT_.js} +1 -1
- package/dist/website/main/assets/{index.vue_vue_type_script_setup_true_lang-B5HoY3_0.js → index.vue_vue_type_script_setup_true_lang-2Z80ry6F.js} +1 -1
- package/dist/website/main/assets/index.vue_vue_type_script_setup_true_lang-C7h-Ycpm.js +1 -0
- package/dist/website/main/assets/{index.vue_vue_type_script_setup_true_lang-BBmEjb-A.js → index.vue_vue_type_script_setup_true_lang-CHyooj4T.js} +1 -1
- package/dist/website/main/assets/{index.vue_vue_type_script_setup_true_lang-t73JgDYM.js → index.vue_vue_type_script_setup_true_lang-ChXDjhzT.js} +2 -2
- package/dist/website/main/assets/index.vue_vue_type_script_setup_true_lang-Cy3ZPsfb.js +1 -0
- package/dist/website/main/assets/{index.vue_vue_type_script_setup_true_lang-87WT-7PF.js → index.vue_vue_type_script_setup_true_lang-DHWblo58.js} +1 -1
- package/dist/website/main/assets/{index.vue_vue_type_style_index_0_lang-SpJl7c7B.js → index.vue_vue_type_style_index_0_lang-Bsi5S1XY.js} +1 -1
- package/dist/website/main/assets/{index.vue_vue_type_style_index_0_lang-C30OZgOy.js → index.vue_vue_type_style_index_0_lang-DfBu8zdC.js} +1 -1
- package/dist/website/main/assets/{index.vue_vue_type_style_index_0_lang-YYZCGIEM.js → index.vue_vue_type_style_index_0_lang-Digz_UdY.js} +1 -1
- package/dist/website/main/assets/{md5-BaIvdSuD.js → md5-CWhVn6LA.js} +1 -1
- package/dist/website/main/assets/{useCacheOssStore-B5wqgiBM.js → useCacheOssStore-KoEbWj57.js} +1 -1
- package/dist/website/main/assets/useCompEditStore-Ch5sDzy4.js +1 -0
- package/dist/website/main/assets/useCompEditStore-GUrodzAV.css +1 -0
- package/dist/website/main/assets/{useKeyword-BygMrCvJ.js → useKeyword-Bmq02ywx.js} +1 -1
- package/dist/website/main/assets/{useMessage-CHhLVawp.js → useMessage-BLwQdu5o.js} +1 -1
- package/dist/website/main/assets/{useTeamHeaders-a-XSRO3U.css → useTeamHeaders-BMHQzwDq.css} +1 -1
- package/dist/website/main/assets/{useTeamHeaders-C1Nwzx4f.js → useTeamHeaders-Bttl7tEb.js} +2 -2
- package/dist/website/main/assets/{useUnreadStore-D50CXC_9.js → useUnreadStore-kWR1ykK7.js} +1 -1
- package/dist/website/main/assets/{useVscodeOpen-CJ-3bg9h.js → useVscodeOpen-DyvB87xz.js} +1 -1
- package/dist/website/main/assets/{vendor-ui-BAx7vAkH.js → vendor-ui-KquZSIP0.js} +10 -10
- package/dist/website/main/index.html +3 -3
- package/package.json +1 -1
- package/dist/website/item/assets/index-BxlM4TBc.js +0 -60
- package/dist/website/item/assets/index-Cg5t9Ndz.css +0 -1
- package/dist/website/main/assets/GithubCallback-DP3YU9rH.js +0 -1
- package/dist/website/main/assets/ReplyForm.vue_vue_type_script_setup_true_lang-BnN1jBiO.js +0 -1
- package/dist/website/main/assets/index--J05rNIX.js +0 -1
- package/dist/website/main/assets/index-B2rWNHgy.js +0 -1
- package/dist/website/main/assets/index-B6fwGRmY.js +0 -1
- package/dist/website/main/assets/index-B8TdXR68.js +0 -1
- package/dist/website/main/assets/index-BBzEF7CC.js +0 -1
- package/dist/website/main/assets/index-BQKN7xQr.js +0 -2
- package/dist/website/main/assets/index-BWKB83Cd.js +0 -1
- package/dist/website/main/assets/index-BjKOeMxH.js +0 -1
- package/dist/website/main/assets/index-D03XtNqB.js +0 -1
- package/dist/website/main/assets/index-DEvtplax.js +0 -2
- package/dist/website/main/assets/index-DQTRYmEL.js +0 -1
- package/dist/website/main/assets/index-DRytU1Iu.js +0 -1
- package/dist/website/main/assets/index-DcfKevFQ.js +0 -1
- package/dist/website/main/assets/index-tSn-zTTf.js +0 -1
- package/dist/website/main/assets/index.vue_vue_type_script_setup_true_lang-C1EYwhRp.js +0 -1
- package/dist/website/main/assets/index.vue_vue_type_script_setup_true_lang-Dl1KwcTe.js +0 -1
- package/dist/website/main/assets/useCompEditStore-Br3x5A7Q.css +0 -1
- package/dist/website/main/assets/useCompEditStore-rtFXUPNg.js +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
@charset "UTF-8";.app-container[data-v-6efeee9c]{width:100%;height:100%}.segmented[data-v-1ee57095]{--segmented-bg: #f0f0f0;--segmented-selected-bg: #409eff;--segmented-selected-shadow: none;--segmented-color: #a6a6a6;--segmented-selected-color: #ffffff;--segmented-padding: 1px;--segmented-font-size: 14px;--segmented-border-radius: 6px;--segmented-item-border-radius: 4px;--segmented-item-height: 32px;--segmented-item-min-width: 40px;--segmented-item-padding-x: 12px;display:inline-flex;position:relative;background:var(--segmented-bg);border-radius:var(--segmented-border-radius);padding:var(--segmented-padding);user-select:none;-webkit-user-select:none}html.dark .segmented[data-v-1ee57095]{--segmented-bg: #1e1e1e}.segmented--block[data-v-1ee57095]{display:flex;width:100%}.segmented--block .segmented__item[data-v-1ee57095]{flex:1;justify-content:center}.segmented--vertical[data-v-1ee57095]{flex-direction:column}.segmented.is-disabled[data-v-1ee57095]{opacity:.6;cursor:not-allowed}.segmented__indicator[data-v-1ee57095]{position:absolute;top:var(--segmented-padding);left:var(--segmented-padding);border-radius:var(--segmented-item-border-radius);background:var(--segmented-selected-bg);box-shadow:var(--segmented-selected-shadow);transition:transform .25s cubic-bezier(.4,0,.2,1),width .25s cubic-bezier(.4,0,.2,1),height .25s cubic-bezier(.4,0,.2,1);pointer-events:none;z-index:1}.segmented__item[data-v-1ee57095]{position:relative;display:inline-flex;align-items:center;height:var(--segmented-item-height);min-width:var(--segmented-item-min-width);padding:0 var(--segmented-item-padding-x);font-size:var(--segmented-font-size);color:var(--segmented-color);border-radius:var(--segmented-item-border-radius);cursor:pointer;transition:color .25s cubic-bezier(.4,0,.2,1);white-space:nowrap;z-index:2}.segmented__item[data-v-1ee57095]:hover:not(.is-disabled):not(.is-selected){color:var(--segmented-selected-color)}.segmented__item.is-selected[data-v-1ee57095]{color:var(--segmented-selected-color)}.segmented__item.is-disabled[data-v-1ee57095]{opacity:.4;cursor:not-allowed}.segmented__input[data-v-1ee57095]{position:absolute;opacity:0;width:0;height:0;pointer-events:none}.segmented__label[data-v-1ee57095]{position:relative;z-index:1;display:inline-flex;align-items:center;justify-content:center;width:100%}.segmented--large[data-v-1ee57095]{--segmented-font-size: 16px;--segmented-item-height: 40px;--segmented-item-min-width: 48px;--segmented-item-padding-x: 16px;--segmented-border-radius: 8px;--segmented-item-border-radius: 6px;--segmented-padding: 4px}.segmented--small[data-v-1ee57095]{--segmented-font-size: 12px;--segmented-item-height: 24px;--segmented-item-min-width: 32px;--segmented-item-padding-x: 8px;--segmented-border-radius: 4px;--segmented-item-border-radius: 3px;--segmented-padding: 2px}.ec-outer[data-v-5cf301e4]{width:100%;height:100%;display:flex;align-items:center;justify-content:center}.ec-outer--dark[data-v-5cf301e4]{background-color:#0d1117}.ec-outer--light[data-v-5cf301e4]{background-color:#f5f7fa}.ec-inner[data-v-5cf301e4]{width:100%;height:100%;padding:.625rem;text-align:center;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a;overflow:auto}.ec-inner--dark[data-v-5cf301e4]{background-color:#21262d}.ec-inner--light[data-v-5cf301e4]{background-color:#fff}.ec-icon[data-v-5cf301e4]{font-size:3rem;line-height:1;margin-bottom:1rem}.ec-title[data-v-5cf301e4]{margin:0;margin-bottom:1.5rem;font-size:1.25rem;line-height:1.75rem;font-weight:600}.ec-title--dark[data-v-5cf301e4]{color:#ff6b6b}.ec-title--light[data-v-5cf301e4]{color:#ff4d4f}.ec-list[data-v-5cf301e4]{display:flex;flex-direction:column;gap:.75rem;margin-bottom:1.5rem}.ec-item[data-v-5cf301e4]{border-radius:.5rem;padding:.75rem 1rem;font-size:.875rem;line-height:1.25rem;word-break:break-all;border:1px solid}.ec-item--dark[data-v-5cf301e4]{background-color:#161b22;border-color:#30363d;color:#c9d1d9}.ec-item--light[data-v-5cf301e4]{background-color:#f5f7fa;border-color:#e4e7ed;color:#606266}.ec-actions[data-v-5cf301e4]{display:flex;justify-content:center;gap:.75rem}.wc-outer[data-v-cce09743]{width:100%;height:100%;display:flex;align-items:center;justify-content:center}.wc-outer--dark[data-v-cce09743]{background-color:#0d1117}.wc-outer--light[data-v-cce09743]{background-color:#f5f7fa}.wc-inner[data-v-cce09743]{width:100%;height:100%;padding:.625rem;text-align:center;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a;overflow:auto}.wc-inner--dark[data-v-cce09743]{background-color:#21262d}.wc-inner--light[data-v-cce09743]{background-color:#fff}.wc-icon[data-v-cce09743]{font-size:3rem;line-height:1;margin-bottom:1rem}.wc-title[data-v-cce09743]{margin:0;margin-bottom:1.5rem;font-size:1.25rem;line-height:1.75rem;font-weight:600}.wc-title--dark[data-v-cce09743]{color:#d29922}.wc-title--light[data-v-cce09743]{color:#b8860b}.wc-list[data-v-cce09743]{display:flex;flex-direction:column;gap:.75rem;margin-bottom:1.5rem}.wc-item[data-v-cce09743]{border-radius:.5rem;padding:.75rem 1rem;font-size:.875rem;line-height:1.25rem;word-break:break-all;border:1px solid}.wc-item--dark[data-v-cce09743]{background-color:#161b22;border-color:#30363d;color:#c9d1d9}.wc-item--light[data-v-cce09743]{background-color:#f5f7fa;border-color:#e4e7ed;color:#606266}.wc-actions[data-v-cce09743]{display:flex;justify-content:center;gap:.75rem}.card[data-v-36db9d87]{--card-bg: #fff;--card-border-color: #e4e7ed;--card-color: #303133;--card-shadow-color: rgba(0, 0, 0, .1);border-radius:4px;border:1px solid var(--card-border-color);background-color:var(--card-bg);color:var(--card-color);overflow:hidden;transition:box-shadow .3s ease}html.dark .card[data-v-36db9d87]{--card-bg: #1d1e1f;--card-border-color: #30363d;--card-color: #c9d1d9;--card-shadow-color: rgba(0, 0, 0, .4)}.card.is-never-shadow[data-v-36db9d87],.card.is-hover-shadow[data-v-36db9d87]{box-shadow:none}.card.is-hover-shadow[data-v-36db9d87]:hover,.card.is-always-shadow[data-v-36db9d87]{box-shadow:0 2px 12px 0 var(--card-shadow-color)}.card__header[data-v-36db9d87]{padding:12px 20px;border-bottom:1px solid var(--card-border-color);font-size:16px;font-weight:500;box-sizing:border-box}.card__body[data-v-36db9d87]{padding:20px;box-sizing:border-box}.card__footer[data-v-36db9d87]{padding:12px 20px;border-top:1px solid var(--card-border-color);box-sizing:border-box}.carousel[data-v-44ca82d0]{position:relative;overflow:hidden}.carousel--horizontal[data-v-44ca82d0]{width:100%}.carousel--vertical[data-v-44ca82d0]{height:100%}.carousel__viewport[data-v-44ca82d0]{width:100%;height:100%;overflow:hidden;position:relative}.carousel__viewport--card[data-v-44ca82d0]{display:flex;align-items:center;justify-content:center}.carousel__track[data-v-44ca82d0]{display:flex;width:100%;height:100%;transition:transform .4s ease}.carousel__track--card[data-v-44ca82d0]{position:relative;width:100%;height:100%;display:block;transition:none}.carousel__track--animating[data-v-44ca82d0]{transition:transform .4s ease}.carousel__track--motion-blur[data-v-44ca82d0]{filter:blur(2px);transition:transform .4s ease,filter .4s ease}.carousel__arrow[data-v-44ca82d0]{position:absolute;top:50%;transform:translateY(-50%);width:36px;height:36px;border:none;border-radius:50%;background-color:#fffc;color:#333;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 8px #0000001a;opacity:0;transition:opacity .3s ease,background-color .3s ease;z-index:10}.carousel__arrow[data-v-44ca82d0]:hover{background-color:#fff}.carousel__arrow--always[data-v-44ca82d0]{opacity:1}.carousel__arrow--left[data-v-44ca82d0]{left:16px}.carousel__arrow--right[data-v-44ca82d0]{right:16px}.carousel:hover .carousel__arrow[data-v-44ca82d0]{opacity:1}.carousel__arrow-icon[data-v-44ca82d0]{display:inline-block;width:8px;height:8px;border-style:solid;border-color:#333;border-width:0 2px 2px 0}.carousel__arrow-icon--left[data-v-44ca82d0]{transform:rotate(135deg);margin-left:2px}.carousel__arrow-icon--right[data-v-44ca82d0]{transform:rotate(-45deg);margin-right:2px}.carousel__indicators[data-v-44ca82d0]{position:absolute;bottom:12px;left:50%;transform:translate(-50%);display:flex;gap:8px;align-items:center;list-style:none;margin:0;padding:6px 12px;z-index:10;background-color:#0006;border-radius:20px;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px)}.carousel__indicators--vertical[data-v-44ca82d0]{inset:50% 12px auto auto;transform:translateY(-50%);flex-direction:column}.carousel__indicator[data-v-44ca82d0]{width:8px;height:8px;border-radius:50%;background-color:#fff6;cursor:pointer;transition:background-color .3s ease,transform .3s ease;position:relative}.carousel__indicator span[data-v-44ca82d0]{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.carousel__indicator--active[data-v-44ca82d0]{background-color:#fff;transform:scale(1.25)}.carousel-item[data-v-6046a978]{flex-shrink:0;width:100%;height:100%;overflow:hidden;transition:transform .4s ease,opacity .4s ease}.carousel-item--card[data-v-6046a978]{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;cursor:pointer}.carousel-item--card.carousel-item--active[data-v-6046a978]{cursor:default}.async-comp-wrapper[data-v-c15f8ed8],.async-comp-container[data-v-c15f8ed8]{width:100%;height:100%;position:relative}.async-comp-container.async-comp-overflow-auto[data-v-c15f8ed8]{overflow:auto}.async-comp-container.async-comp-overflow-hidden[data-v-c15f8ed8]{overflow:hidden}.async-comp-error[data-v-c15f8ed8]{position:absolute;inset:0}.screenshot-fallback[data-v-c15f8ed8]{overflow:hidden}.screenshot-toggle[data-v-c15f8ed8]{position:absolute;top:8px;right:8px;display:flex;gap:4px;z-index:2}.toggle-btn[data-v-c15f8ed8]{display:flex;align-items:center;justify-content:center;width:28px;height:28px;border-radius:4px;cursor:pointer;transition:background .2s,color .2s;font-size:18px}.toggle-btn[data-v-c15f8ed8]:hover{background:#000000a6;color:#ffffffe6}.toggle-btn.active[data-v-c15f8ed8]{background:#000000b3;color:#fff}.screenshot-img[data-v-c15f8ed8]{width:100%;height:100%;object-fit:contain;display:block}[data-v-da931a53] .carousel__viewport{height:100%}.comp-mini-carousel[data-v-da931a53],.comp-mini-carousel-item[data-v-da931a53]{width:100%;height:100%}.comp-mini-carousel-slide[data-v-da931a53]{width:100%;height:100%;border-bottom-left-radius:.125rem;border-bottom-right-radius:.125rem}.panel-mini-wrapper[data-v-e2c6aaf1]{width:100%;height:100%;display:flex;justify-content:center;align-items:center;overflow:hidden}.panel-mini-card[data-v-e2c6aaf1]{height:100%;max-height:250px;width:340px}[data-v-e2c6aaf1] .panel-mini-card-body{padding:0!important;overflow:hidden!important;width:100%!important;height:100%!important}.panel-full-card[data-v-5b3d03a7]{flex:1;overflow:hidden;width:100%;height:100%}[data-v-5b3d03a7] .panel-full-card-body{padding:0!important;overflow:hidden!important;width:100%!important;height:100%!important}.edit-panel[data-v-9e136b95]{width:100%;height:100%;background-color:#fff}html.dark .edit-panel[data-v-9e136b95]{background-color:#141414}.edit-panel__carousel[data-v-9e136b95]{width:100%;height:100%}.edit-panel__content[data-v-9e136b95]{width:100%;height:100%;display:flex;flex-direction:column;align-items:flex-start;overflow:hidden;padding:4px}.edit-panel__tools[data-v-9e136b95]{display:flex;width:100%;justify-content:center;gap:10px;align-items:center;margin-bottom:2px}.edit-panel__refresh-btn[data-v-9e136b95]{cursor:pointer}.el-carousel__button{background-color:#fff!important;border:1px solid #4d4949!important;border-radius:4px!important;height:6px!important}.el-carousel__indicator--horizontal{padding:2px 4px}.el-carousel--horizontal,.el-carousel--vertical{overflow:visible}*{box-sizing:border-box}html,body{margin:0;padding:0;height:100%;overflow:hidden}#app{height:100%;overflow:hidden}.avatar[data-v-d80295f9]{--avatar-bg: #c0c4cc;--avatar-color: #fff;--avatar-border-color: #dcdfe6;display:inline-flex;align-items:center;justify-content:center;background-color:var(--avatar-bg);color:var(--avatar-color);overflow:hidden;vertical-align:middle;flex-shrink:0;box-sizing:border-box}html.dark .avatar[data-v-d80295f9]{--avatar-bg: #4a4a4a;--avatar-color: #e0e0e0;--avatar-border-color: #505050}.avatar--circle[data-v-d80295f9]{border-radius:50%}.avatar--square[data-v-d80295f9]{border-radius:4px}.avatar__img[data-v-d80295f9]{width:100%;height:100%;display:block}.avatar__icon[data-v-d80295f9]{width:50%;height:50%}.avatar__text[data-v-d80295f9]{line-height:1;white-space:nowrap;-webkit-user-select:none;user-select:none}.loading-wrapper[data-v-3f3f25a9]{display:flex;align-items:center;justify-content:center;min-height:120px}.loading-inline[data-v-3f3f25a9]{min-height:unset;padding:40px 0}.loading-text[data-v-3f3f25a9]{font-size:13px;color:#909399}.loading-dots[data-v-3f3f25a9]{display:inline}.loading-dot[data-v-3f3f25a9]{display:inline-block;opacity:0;animation:dot-blink-3f3f25a9 1.2s infinite}@keyframes dot-blink-3f3f25a9{0%,40%{opacity:0}50%,90%{opacity:1}to{opacity:0}}.hl[data-v-6244b909]{background:#ffe600;padding:0 2px;border-radius:2px}[data-v-2e76db44] .el-avatar--circle{border:1px solid #857e7e;padding:0!important}.dot[data-v-2fc884b4]:after{content:"";position:absolute;top:0%;right:0%;transform:translate(var(--offsetX),var(--offsetY));width:7px;height:7px;border-radius:50%;background-color:#f5222d;border:1px solid #fff}.code-container .hljs{border-radius:5px!important}.grid-container[data-v-b3cdeaeb]{display:grid;grid-template-columns:repeat(auto-fill,minmax(var(--v4923d4d0),1fr));gap:var(--cec7ae86)}.list-move,.list-enter-active,.list-leave-active{transition:all .5s ease}.list-enter-from,.list-leave-to{opacity:0;transform:translate(30px)}.list-leave-active{position:absolute;width:var(--v4923d4d0)}.list-leave-none{display:none}.transition-fade-enter-active,.transition-fade-leave-active{transition:all .3s ease}.transition-fade-enter-from{opacity:0;transform:translate(-30px)}.transition-fade-leave-to{opacity:0;transform:translate(30px)}.is-collected[data-v-3b3bc11e]{color:#facc15}.segmented[data-v-ce5b54d1]{--segmented-bg: #f0f0f0;--segmented-selected-bg: #409eff;--segmented-selected-shadow: none;--segmented-color: #a6a6a6;--segmented-selected-color: #ffffff;--segmented-padding: 1px;--segmented-font-size: 14px;--segmented-border-radius: 6px;--segmented-item-border-radius: 4px;--segmented-item-height: 32px;--segmented-item-min-width: 40px;--segmented-item-padding-x: 12px;display:inline-flex;position:relative;background:var(--segmented-bg);border-radius:var(--segmented-border-radius);padding:var(--segmented-padding);user-select:none;-webkit-user-select:none}html.dark .segmented[data-v-ce5b54d1]{--segmented-bg: #1e1e1e}.segmented--block[data-v-ce5b54d1]{display:flex;width:100%}.segmented--block .segmented__item[data-v-ce5b54d1]{flex:1;justify-content:center}.segmented--vertical[data-v-ce5b54d1]{flex-direction:column}.segmented.is-disabled[data-v-ce5b54d1]{opacity:.6;cursor:not-allowed}.segmented__indicator[data-v-ce5b54d1]{position:absolute;top:var(--segmented-padding);left:var(--segmented-padding);border-radius:var(--segmented-item-border-radius);background:var(--segmented-selected-bg);box-shadow:var(--segmented-selected-shadow);transition:transform .25s cubic-bezier(.4,0,.2,1),width .25s cubic-bezier(.4,0,.2,1),height .25s cubic-bezier(.4,0,.2,1);pointer-events:none;z-index:1}.segmented__item[data-v-ce5b54d1]{position:relative;display:inline-flex;align-items:center;height:var(--segmented-item-height);min-width:var(--segmented-item-min-width);padding:0 var(--segmented-item-padding-x);font-size:var(--segmented-font-size);color:var(--segmented-color);border-radius:var(--segmented-item-border-radius);cursor:pointer;transition:color .25s cubic-bezier(.4,0,.2,1);white-space:nowrap;z-index:2}.segmented__item[data-v-ce5b54d1]:hover:not(.is-disabled):not(.is-selected){color:var(--segmented-selected-color)}.segmented__item.is-selected[data-v-ce5b54d1]{color:var(--segmented-selected-color)}.segmented__item.is-disabled[data-v-ce5b54d1]{opacity:.4;cursor:not-allowed}.segmented__input[data-v-ce5b54d1]{position:absolute;opacity:0;width:0;height:0;pointer-events:none}.segmented__label[data-v-ce5b54d1]{position:relative;z-index:1;display:inline-flex;align-items:center;justify-content:center;width:100%}.segmented--large[data-v-ce5b54d1]{--segmented-font-size: 16px;--segmented-item-height: 40px;--segmented-item-min-width: 48px;--segmented-item-padding-x: 16px;--segmented-border-radius: 8px;--segmented-item-border-radius: 6px;--segmented-padding: 4px}.segmented--small[data-v-ce5b54d1]{--segmented-font-size: 12px;--segmented-item-height: 24px;--segmented-item-min-width: 32px;--segmented-item-padding-x: 8px;--segmented-border-radius: 4px;--segmented-item-border-radius: 3px;--segmented-padding: 2px}.ec-outer[data-v-d9cb03ff]{width:100%;height:100%;display:flex;align-items:center;justify-content:center}.ec-outer--dark[data-v-d9cb03ff]{background-color:#0d1117}.ec-outer--light[data-v-d9cb03ff]{background-color:#f5f7fa}.ec-inner[data-v-d9cb03ff]{width:100%;height:100%;padding:.625rem;text-align:center;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a;overflow:auto}.ec-inner--dark[data-v-d9cb03ff]{background-color:#21262d}.ec-inner--light[data-v-d9cb03ff]{background-color:#fff}.ec-icon[data-v-d9cb03ff]{font-size:3rem;line-height:1;margin-bottom:1rem}.ec-title[data-v-d9cb03ff]{margin:0;margin-bottom:1.5rem;font-size:1.25rem;line-height:1.75rem;font-weight:600}.ec-title--dark[data-v-d9cb03ff]{color:#ff6b6b}.ec-title--light[data-v-d9cb03ff]{color:#ff4d4f}.ec-list[data-v-d9cb03ff]{display:flex;flex-direction:column;gap:.75rem;margin-bottom:1.5rem}.ec-item[data-v-d9cb03ff]{border-radius:.5rem;padding:.75rem 1rem;font-size:.875rem;line-height:1.25rem;word-break:break-all;border:1px solid}.ec-item--dark[data-v-d9cb03ff]{background-color:#161b22;border-color:#30363d;color:#c9d1d9}.ec-item--light[data-v-d9cb03ff]{background-color:#f5f7fa;border-color:#e4e7ed;color:#606266}.ec-actions[data-v-d9cb03ff]{display:flex;justify-content:center;gap:.75rem}.wc-outer[data-v-67ce764e]{width:100%;height:100%;display:flex;align-items:center;justify-content:center}.wc-outer--dark[data-v-67ce764e]{background-color:#0d1117}.wc-outer--light[data-v-67ce764e]{background-color:#f5f7fa}.wc-inner[data-v-67ce764e]{width:100%;height:100%;padding:.625rem;text-align:center;box-shadow:0 10px 15px -3px #0000001a,0 4px 6px -4px #0000001a;overflow:auto}.wc-inner--dark[data-v-67ce764e]{background-color:#21262d}.wc-inner--light[data-v-67ce764e]{background-color:#fff}.wc-icon[data-v-67ce764e]{font-size:3rem;line-height:1;margin-bottom:1rem}.wc-title[data-v-67ce764e]{margin:0;margin-bottom:1.5rem;font-size:1.25rem;line-height:1.75rem;font-weight:600}.wc-title--dark[data-v-67ce764e]{color:#d29922}.wc-title--light[data-v-67ce764e]{color:#b8860b}.wc-list[data-v-67ce764e]{display:flex;flex-direction:column;gap:.75rem;margin-bottom:1.5rem}.wc-item[data-v-67ce764e]{border-radius:.5rem;padding:.75rem 1rem;font-size:.875rem;line-height:1.25rem;word-break:break-all;border:1px solid}.wc-item--dark[data-v-67ce764e]{background-color:#161b22;border-color:#30363d;color:#c9d1d9}.wc-item--light[data-v-67ce764e]{background-color:#f5f7fa;border-color:#e4e7ed;color:#606266}.wc-actions[data-v-67ce764e]{display:flex;justify-content:center;gap:.75rem}.enk28pe8k{fill:currentColor;d:path("M11.288 4.713Q11 4.425 11 4V2q0-.425.288-.712T12 1t.713.288T13 2v2q0 .425-.288.713T12 5t-.712-.288M16.95 7.05q-.275-.275-.275-.687t.275-.713l1.4-1.425q.3-.3.712-.3t.713.3q.275.275.275.7t-.275.7L18.35 7.05q-.275.275-.7.275t-.7-.275M20 13q-.425 0-.713-.288T19 12t.288-.712T20 11h2q.425 0 .713.288T23 12t-.288.713T22 13zm-8.712 9.713Q11 22.425 11 22v-2q0-.425.288-.712T12 19t.713.288T13 20v2q0 .425-.288.713T12 23t-.712-.288M5.65 7.05l-1.425-1.4q-.3-.3-.3-.725t.3-.7q.275-.275.7-.275t.7.275L7.05 5.65q.275.275.275.7t-.275.7q-.3.275-.7.275t-.7-.275m12.7 12.725l-1.4-1.425q-.275-.3-.275-.712t.275-.688t.688-.275t.712.275l1.425 1.4q.3.275.288.7t-.288.725q-.3.3-.725.3t-.7-.3M2 13q-.425 0-.712-.288T1 12t.288-.712T2 11h2q.425 0 .713.288T5 12t-.288.713T4 13zm2.225 6.775q-.275-.275-.275-.7t.275-.7L5.65 16.95q.275-.275.687-.275t.713.275q.3.3.3.713t-.3.712l-1.4 1.4q-.3.3-.725.3t-.7-.3M7.75 16.25Q6 14.5 6 12t1.75-4.25T12 6t4.25 1.75T18 12t-1.75 4.25T12 18t-4.25-1.75")}.o17qx8_el{fill:currentColor;d:path("M12.075 22q-2.1 0-3.937-.8t-3.2-2.162t-2.163-3.2t-.8-3.938q0-3.1 1.713-5.625t4.587-3.7q.35-.125.725-.088t.625.238q.2.175.313.488t.112.812q.05 1.975.8 3.763T13 10.975t3.2 2.15t3.775.8q.525 0 .8.088t.45.287q.2.25.263.65t-.063.725q-1.15 2.875-3.7 4.6T12.075 22M14.3 7.3l-1.6-1.6q-.3-.3-.3-.7t.3-.7l1.6-1.6q.3-.3.7-.3t.7.3l1.6 1.6q.3.3.3.7t-.3.7l-1.6 1.6q-.3.3-.7.3t-.7-.3m5 3l-.6-.6q-.3-.3-.3-.7t.3-.7l.6-.6q.3-.3.7-.3t.7.3l.6.6q.3.3.3.7t-.3.7l-.6.6q-.3.3-.7.3t-.7-.3")}.pane-card[data-v-f7e65c4e] .pane-body{padding:0!important;display:flex;flex-direction:column;overflow:hidden}.pane-card[data-v-f7e65c4e] .pane-header{padding:0!important}.pane-maximized[data-v-f7e65c4e]{position:fixed;inset:0;z-index:50}[data-v-533323fa] .el-pagination{justify-content:var(--pagination-location)}[data-v-bf03d76c] .not-matched{opacity:.6}[data-v-bf03d76c] .not-matched .el-tag__content{text-decoration:line-through}.diff-code-loading[data-v-a2ffd202]{position:absolute;top:80px;left:50%;transform:translate(-50%)}[data-v-a2ffd202] .highlight-file{animation:highlight-pulse-a2ffd202 .5s ease;animation-iteration-count:3}@keyframes highlight-pulse-a2ffd202{0%,to{box-shadow:none}50%{box-shadow:0 0 0 3px var(--el-color-primary-light-5)}}.d2h-file-wrapper{scroll-margin-top:20px}.no-diff{text-align:center;padding:20px;color:#999}.card-no-padding[data-v-9af49f91] .el-card__body{padding:0;overflow:hidden}.diff-container{display:flex;flex-direction:column;overflow:hidden}.diff-container .el-dialog__body{flex:1;overflow:hidden}.card[data-v-851bc55e]{--card-bg: #fff;--card-border-color: #e4e7ed;--card-color: #303133;--card-shadow-color: rgba(0, 0, 0, .1);border-radius:4px;border:1px solid var(--card-border-color);background-color:var(--card-bg);color:var(--card-color);overflow:hidden;transition:box-shadow .3s ease}html.dark .card[data-v-851bc55e]{--card-bg: #1d1e1f;--card-border-color: #30363d;--card-color: #c9d1d9;--card-shadow-color: rgba(0, 0, 0, .4)}.card.is-never-shadow[data-v-851bc55e],.card.is-hover-shadow[data-v-851bc55e]{box-shadow:none}.card.is-hover-shadow[data-v-851bc55e]:hover,.card.is-always-shadow[data-v-851bc55e]{box-shadow:0 2px 12px 0 var(--card-shadow-color)}.card__header[data-v-851bc55e]{padding:12px 20px;border-bottom:1px solid var(--card-border-color);font-size:16px;font-weight:500;box-sizing:border-box}.card__body[data-v-851bc55e]{padding:20px;box-sizing:border-box}.card__footer[data-v-851bc55e]{padding:12px 20px;border-top:1px solid var(--card-border-color);box-sizing:border-box}.carousel[data-v-8bba41e4]{position:relative;overflow:hidden}.carousel--horizontal[data-v-8bba41e4]{width:100%}.carousel--vertical[data-v-8bba41e4]{height:100%}.carousel__viewport[data-v-8bba41e4]{width:100%;height:100%;overflow:hidden;position:relative}.carousel__viewport--card[data-v-8bba41e4]{display:flex;align-items:center;justify-content:center}.carousel__track[data-v-8bba41e4]{display:flex;width:100%;height:100%;transition:transform .4s ease}.carousel__track--card[data-v-8bba41e4]{position:relative;width:100%;height:100%;display:block;transition:none}.carousel__track--animating[data-v-8bba41e4]{transition:transform .4s ease}.carousel__track--motion-blur[data-v-8bba41e4]{filter:blur(2px);transition:transform .4s ease,filter .4s ease}.carousel__arrow[data-v-8bba41e4]{position:absolute;top:50%;transform:translateY(-50%);width:36px;height:36px;border:none;border-radius:50%;background-color:#fffc;color:#333;cursor:pointer;display:flex;align-items:center;justify-content:center;box-shadow:0 2px 8px #0000001a;opacity:0;transition:opacity .3s ease,background-color .3s ease;z-index:10}.carousel__arrow[data-v-8bba41e4]:hover{background-color:#fff}.carousel__arrow--always[data-v-8bba41e4]{opacity:1}.carousel__arrow--left[data-v-8bba41e4]{left:16px}.carousel__arrow--right[data-v-8bba41e4]{right:16px}.carousel:hover .carousel__arrow[data-v-8bba41e4]{opacity:1}.carousel__arrow-icon[data-v-8bba41e4]{display:inline-block;width:8px;height:8px;border-style:solid;border-color:#333;border-width:0 2px 2px 0}.carousel__arrow-icon--left[data-v-8bba41e4]{transform:rotate(135deg);margin-left:2px}.carousel__arrow-icon--right[data-v-8bba41e4]{transform:rotate(-45deg);margin-right:2px}.carousel__indicators[data-v-8bba41e4]{position:absolute;bottom:12px;left:50%;transform:translate(-50%);display:flex;gap:8px;align-items:center;list-style:none;margin:0;padding:6px 12px;z-index:10;background-color:#0006;border-radius:20px;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px)}.carousel__indicators--vertical[data-v-8bba41e4]{inset:50% 12px auto auto;transform:translateY(-50%);flex-direction:column}.carousel__indicator[data-v-8bba41e4]{width:8px;height:8px;border-radius:50%;background-color:#fff6;cursor:pointer;transition:background-color .3s ease,transform .3s ease;position:relative}.carousel__indicator span[data-v-8bba41e4]{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.carousel__indicator--active[data-v-8bba41e4]{background-color:#fff;transform:scale(1.25)}.carousel-item[data-v-eb5fc1cc]{flex-shrink:0;width:100%;height:100%;overflow:hidden;transition:transform .4s ease,opacity .4s ease}.carousel-item--card[data-v-eb5fc1cc]{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;cursor:pointer}.carousel-item--card.carousel-item--active[data-v-eb5fc1cc]{cursor:default}.text-container[data-v-3179173f]{display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:var(--v26a8013a);overflow:hidden}.text-single[data-v-3179173f]{visibility:hidden;position:absolute;white-space:nowrap;width:1px}.vue-recycle-scroller__resize-observer[data-v-08cc04ab]{position:absolute;inset:0;opacity:0;pointer-events:none;z-index:-1}.vue-recycle-scroller{position:relative}.vue-recycle-scroller.direction-vertical:not(.page-mode){overflow-y:auto}.vue-recycle-scroller.direction-horizontal:not(.page-mode){overflow-x:auto}.vue-recycle-scroller.grid-mode:not(.page-mode){overflow:auto}.vue-recycle-scroller.direction-horizontal{display:flex}.vue-recycle-scroller__slot{flex:auto 0 0}.vue-recycle-scroller__item-wrapper{flex:1;box-sizing:border-box;overflow:hidden;position:relative}.vue-recycle-scroller.ready .vue-recycle-scroller__item-view{position:absolute;top:0;left:0;will-change:transform}.vue-recycle-scroller.direction-vertical .vue-recycle-scroller__item-wrapper{width:100%}.vue-recycle-scroller.direction-horizontal .vue-recycle-scroller__item-wrapper{height:100%}.vue-recycle-scroller.ready.direction-vertical .vue-recycle-scroller__item-view{width:100%}.vue-recycle-scroller.ready.direction-horizontal .vue-recycle-scroller__item-view{height:100%}::deep(.el-radio__input.is-checked + .el-radio__label) span[data-v-7c810475]:first-child{box-shadow:0 0 8px currentColor}.cdj_y1r7t{fill:currentColor;d:path("M5 11q-.825 0-1.412-.587T3 9V5q0-.825.588-1.412T5 3h4q.825 0 1.413.588T11 5v4q0 .825-.587 1.413T9 11zm0 10q-.825 0-1.412-.587T3 19v-4q0-.825.588-1.412T5 13h4q.825 0 1.413.588T11 15v4q0 .825-.587 1.413T9 21zm10-10q-.825 0-1.412-.587T13 9V5q0-.825.588-1.412T15 3h4q.825 0 1.413.588T21 5v4q0 .825-.587 1.413T19 11zm0 10q-.825 0-1.412-.587T13 19v-4q0-.825.588-1.412T15 13h4q.825 0 1.413.588T21 15v4q0 .825-.587 1.413T19 21z")}.u2_fvl-wz{fill:currentColor;d:path("M9 20h11q.825 0 1.413-.587T22 18v-2H9zM2 8h5V4H4q-.825 0-1.412.588T2 6zm0 6h5v-4H2zm2 6h3v-4H2v2q0 .825.588 1.413T4 20m5-6h13v-4H9zm0-6h13V6q0-.825-.587-1.412T20 4H9z")}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{m as b,c as S}from"./vendor-ui-BAx7vAkH.js";import{a as C,A as k,C as T,c as w,R}from"./index-CnTuJQbj.js";import{I as y,aA as N,aG as I,f as A,O as i,P as u,a2 as r,Y as m,u as n,R as h,a1 as _,$ as v,a0 as L,a as f}from"./vendor-core-Do-oxgl9.js";import{S as F}from"./index-DwDo8mID.js";const H={class:"size-full flex items-center justify-center bg-[#0d0d0d]"},O={key:0,class:"text-center"},B={class:"text-white/60 text-sm"},G={key:1,class:"text-center max-w-md px-4"},K={class:"text-white/80 text-base mb-2"},V={key:0,class:"text-white/40 text-xs mb-6 break-all"},j=y({__name:"GithubCallback",setup(D){const{PersonIcon:g}=F,{t:e}=N(),p=I(),E=C(),c=f(!0),t=f(""),s=f("");return A(async()=>{const a=new URLSearchParams(window.location.search);if(a.get("error")){c.value=!1,t.value=e("user.githubLoginFailed")||"GitHub 登录失败",s.value=decodeURIComponent(a.get("detail")||"");return}const o=a.get(k),l=a.get(T.REFRESH_TOKEN_HEADER_NAME);if(!o||!l){c.value=!1,t.value=e("user.githubLoginFailed")||"GitHub 登录失败",s.value=e("user.missingToken")||"未获取到授权令牌";return}w(o),R(l);try{await E.fetchWhoAmI(),p.replace("/")}catch(x){c.value=!1,t.value=e("user.githubLoginFailed")||"获取用户信息失败",s.value=x?.message||""}}),(a,d)=>{const o=b,l=S;return i(),u("div",H,[c.value?(i(),u("div",O,[r(o,{class:"is-loading text-3xl text-white mb-4"},{default:m(()=>[r(n(g))]),_:1}),h("p",B,_(n(e)("user.githubLoggingIn")),1)])):t.value?(i(),u("div",G,[r(o,{class:"text-3xl text-[#f56c6c] mb-4"},{default:m(()=>[r(n(g))]),_:1}),h("p",K,_(t.value),1),s.value?(i(),u("p",V,_(s.value),1)):v("",!0),r(l,{type:"primary",onClick:d[0]||(d[0]=x=>n(p).replace("/login"))},{default:m(()=>[L(_(n(e)("user.returnToLogin")||"返回登录"),1)]),_:1})])):v("",!0)])}}});export{j as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{B as V,c as b}from"./vendor-ui-BAx7vAkH.js";import"./index-CnTuJQbj.js";import{I as h,f as v,n as x,O as g,Q as B,a as k,aA as $,P as C,a2 as d,u as r,R as I,Y as c,a0 as f,a1 as p,m as S}from"./vendor-core-Do-oxgl9.js";const T=h({name:"CommentInput",__name:"CommentInput",props:{modelValue:{default:""},placeholder:{default:""},rows:{default:2},maxlength:{default:1e3},showWordLimit:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},autofocus:{type:Boolean,default:!1}},emits:["update:modelValue","submit"],setup(t,{emit:i}){const m=t,o=i,n=k(null);v(async()=>{m.autofocus&&(await x(),n.value?.focus())});function a(e){o("update:modelValue",e)}function l(e){e.key==="Enter"&&!e.shiftKey&&(e.preventDefault(),o("submit"))}return(e,u)=>{const s=V;return g(),B(s,{ref_key:"inputRef",ref:n,"model-value":t.modelValue,type:"textarea",rows:t.rows,maxlength:t.maxlength,"show-word-limit":t.showWordLimit,placeholder:t.placeholder,disabled:t.disabled,resize:"none","onUpdate:modelValue":a,onKeydown:l},null,8,["model-value","rows","maxlength","show-word-limit","placeholder","disabled"])}}});function R(t){return function(m){if(!m)return"";const o=new Date(m),a=new Date().getTime()-o.getTime(),l=Math.floor(a/6e4),e=Math.floor(a/36e5),u=Math.floor(a/864e5);if(l<1)return t("comment.time.justNow");if(l<60)return t("comment.time.minutesAgo",{n:l});if(e<24)return t("comment.time.hoursAgo",{n:e});if(u<30)return t("comment.time.daysAgo",{n:u});const s=o.getFullYear(),w=String(o.getMonth()+1).padStart(2,"0"),y=String(o.getDate()).padStart(2,"0");return`${s}-${w}-${y}`}}const D={class:"mt-3 ml-10"},M={class:"flex mt-2 gap-2"},z=h({__name:"ReplyForm",props:{modelValue:{},placeholder:{default:""},loading:{type:Boolean,default:!1}},emits:["update:modelValue","submit","cancel"],setup(t,{emit:i}){const{t:m}=$(),o=t,n=i,a=S({get:()=>o.modelValue,set:l=>n("update:modelValue",l)});return(l,e)=>{const u=b;return g(),C("div",D,[d(r(T),{modelValue:a.value,"onUpdate:modelValue":e[0]||(e[0]=s=>a.value=s),"show-word-limit":"",autofocus:"",placeholder:t.placeholder,onSubmit:e[1]||(e[1]=s=>n("submit"))},null,8,["modelValue","placeholder"]),I("div",M,[d(u,{size:"small",onClick:e[2]||(e[2]=s=>n("cancel"))},{default:c(()=>[f(p(r(m)("common.cancel")),1)]),_:1}),d(u,{size:"small",type:"primary",loading:t.loading,disabled:!a.value.trim(),onClick:e[3]||(e[3]=s=>n("submit"))},{default:c(()=>[f(p(r(m)("comment.reply")),1)]),_:1},8,["loading","disabled"])])])}}});export{z as _,T as a,R as c};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{v as I,a8 as R,F as S,N as A}from"./vendor-ui-BAx7vAkH.js";import{C as l,B as P,z as u,b as x}from"./index-CnTuJQbj.js";import{c as M,b as K}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";import{I as N,aA as B,h as D,aJ as F,aG as z,E as C,aC as Y,a7 as Q,Z as V,u as i,O as $,P as H,a2 as m,Y as _,a as d,m as r,e as g,n as U}from"./vendor-core-Do-oxgl9.js";import{u as j}from"./useKeyword-BygMrCvJ.js";import"./index-B-fZjRMn.js";import"./useCompMetaLocalStore-DBe1Ldcg.js";import"./useCacheOssStore-B5wqgiBM.js";import"./useVscodeOpen-CJ-3bg9h.js";import"./useTeamHeaders-C1Nwzx4f.js";import"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";/* empty css */import"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./useMessage-CHhLVawp.js";const G={class:"size-full p-[10px] pr-0"},pe=N({__name:"index",setup(J){const{t:n}=B(),h=D()?.uid,y=F(),v=z(),a=M(y.path)();C(l.PROVIDE_KEY_COMP_LIST_STORE,a);const f=new Map;C(l.PROVIDE_KEY_CALLBACKS,f);const E=Y("compIframeContainer"),w=d([]),c=d(!1);async function b(e){c.value=!0;const o=(await u.v1Comp.compcontrollerTags({keyword:e})).data?.rows??[];w.value=o.map(t=>({value:t,label:t})),c.value=!1}const p=d({data:[],search:{column:[{prop:"keyword",component:g(S),label:r(()=>n("common.keyword")),value:"",autoQuery:!1,attributes:{placeholder:r(()=>n("comp.keywordPlaceholder")),fetchSuggestions:O,triggerOnFocus:!1,style:"width: 350px",fitInputWidth:!0}},{prop:"tags",component:g(A),label:r(()=>n("comp.tags")),value:[],autoQuery:!1,attributes:{multiple:!0,filterable:!0,remote:!0,clearable:!0,reserveKeyword:!1,defaultFirstOption:!0,placeholder:r(()=>n("comp.pleaseInputTags")),remoteMethod:b,loading:c,options:w,style:"width: 240px"}}]},pagination:{total:0,attributes:{pageSizes:[10,20,30]}},autoLoading:!1,fetchData:T}),L=r(()=>p.value?.search?.column[0]?.value??"");j(L,E);function O(e,s){if(e.length<=1)return s([]);u.v1Keyword.keywordcontrollerQuerykeywordscomp({keyword:e,type:"compMyCollect"}).then(o=>{const{keywords:t=[]}=o.data||{};s(t)})}async function T(e){a.renderList([]),await U(),a.setLoading(!0),e.keyword&&window?.umami?.track(x.SEARCH_COMPONENT,{keyword:e.keyword,page:"collect"});const s=await u.v1Comp.compcontrollerCollectedcomps({...e,tags:Array.isArray(e.tags)?e.tags.join(","):e.tags||""}),{rows:o,total:t}=s.data??{};a.renderList(o??[]),p.value.pagination.total=t??0}function k(e){v.push({path:`/preview/${e}`})}return f.set(l.COMP_METHOD_KEY_AFTER_COMP_CANCEL_COLLECT,e=>{a.delCompListById(e)}),Q(()=>{a.$reset()}),(e,s)=>{const o=R,t=I;return V(($(),H("div",G,[m(i(P),{tableConfig:p.value},{table:_(()=>[m(o,{always:"",wrapClass:"pr-[10px]"},{default:_(()=>[m(K,{ref:"compIframeContainer",iuid:i(h),compType:i(l).IFRAME_ROUTES.CONTAINER.COLLECT,onPreview:k},null,8,["iuid","compType"])]),_:1})]),_:1},8,["tableConfig"])])),[[t,i(a).loading]])}}});export{pe as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as G,F as N,N as _,v as K,a8 as U}from"./vendor-ui-BAx7vAkH.js";import{d as B,C as u,k as M,b as v,z as m,B as z,I as h}from"./index-CnTuJQbj.js";import{c as $,b as H}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";import{I as J,aA as Q,h as V,aJ as Y,aG as j,E as y,aC as W,a as d,m as o,e as f,n as X,a7 as Z,Z as q,u as c,O as ee,P as ae,a2 as g,Y as C}from"./vendor-core-Do-oxgl9.js";import{u as te}from"./useKeyword-BygMrCvJ.js";import"./index-B-fZjRMn.js";import"./useCompMetaLocalStore-DBe1Ldcg.js";import"./useCacheOssStore-B5wqgiBM.js";import"./useVscodeOpen-CJ-3bg9h.js";import"./useTeamHeaders-C1Nwzx4f.js";import"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";/* empty css */import"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./useMessage-CHhLVawp.js";const oe={class:"size-full p-[10px] pr-0"},he=J({__name:"index",setup(se){const{t:s}=Q(),T=V()?.uid,E=Y(),S=j(),b=B(),r=$(E.path)();y(u.PROVIDE_KEY_COMP_LIST_STORE,r);const k=new Map;y(u.PROVIDE_KEY_CALLBACKS,k);const l=G(`${M}`,"XTTJ"),A=W("compIframeContainer"),w=d([]),p=d(!1);async function I(e){p.value=!0;const t=(await m.v1Comp.compcontrollerTags({keyword:e})).data?.rows??[];w.value=t.map(a=>({value:a,label:a})),p.value=!1}const L=o(()=>h.DEFAULT_TAG_GROUP.map(e=>({label:s(e.label),value:e.value}))),i=d({data:[],search:{column:[{prop:"keyword",component:f(N),label:o(()=>s("common.keyword")),value:"",autoQuery:!1,attributes:{placeholder:o(()=>s("comp.keywordPlaceholder")),fetchSuggestions:x,triggerOnFocus:!1,style:"width: 350px",fitInputWidth:!0}},{prop:"tag",component:f(_),label:o(()=>s("common.filter")),value:l.value,attributes:{options:L,style:"width: 200px",onChange:e=>{l.value=e,window?.umami?.track(v.FILTER_TAG,{tag:e,page:"share"})}}},{prop:"tags",component:f(_),label:o(()=>s("comp.tags")),value:[],autoQuery:!1,attributes:{multiple:!0,filterable:!0,remote:!0,clearable:!0,reserveKeyword:!1,defaultFirstOption:!0,placeholder:o(()=>s("comp.pleaseInputTags")),remoteMethod:I,loading:p,options:w,style:"width: 240px"}}]},pagination:{total:0,attributes:{pageSizes:[10,20,30]}},autoLoading:!1,fetchData:P}),O=o(()=>i.value?.search?.column[0]?.value??"");te(O,A);function R(e){return e===h.DEFAULT_TAG_GROUP[0].value?JSON.stringify(b?.deps||[]):"[]"}function x(e,n){if(e.length<=1)return n([]);m.v1Keyword.keywordcontrollerQuerykeywordscomp({keyword:e,type:"compShare"}).then(t=>{const{keywords:a=[]}=t.data||{};n(a)})}async function P(e){r.renderList([]),await X(),r.setLoading(!0),e.keyword&&window?.umami?.track(v.SEARCH_COMPONENT,{keyword:e.keyword,tag:l.value,page:"share"});const n={...e,deps:R(l.value),tags:Array.isArray(e.tags)?e.tags.join(","):e.tags||""},t=await m.v1Comp.compcontrollerComps({...n}),{rows:a,total:F}=t.data??{};r.renderList(a??[]),i.value.pagination.total=F??0,i.value.data=a??[]}function D(e){S.push({path:`/preview/${e}`})}return Z(()=>{r.$reset()}),(e,n)=>{const t=U,a=K;return q((ee(),ae("div",oe,[g(c(z),{tableConfig:i.value},{table:C(()=>[g(t,{always:"",wrapClass:"pr-[10px]"},{default:C(()=>[g(H,{ref:"compIframeContainer",iuid:c(T),compType:c(u).IFRAME_ROUTES.CONTAINER.SHARE,onPreview:D},null,8,["iuid","compType"])]),_:1})]),_:1},8,["tableConfig"])])),[[a,c(r).loading]])}}});export{he as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{T as W,au as R,av as P,aw as j,ax as X,ay as Z,m as ee,az as te,y as se,s as ne,c as N,aA as oe,a7 as A,aB as ae,q as re,n as le,a5 as T}from"./vendor-ui-BAx7vAkH.js";import{H as ie,U as ce,t as ue,V as de,a as me,u as _e}from"./index-CnTuJQbj.js";/* empty css *//* empty css */import{O as i,Q as w,u as e,I,P as y,a2 as s,k as he,aA as U,Y as a,R as _,a1 as c,a0 as h,m as $,aG as F,w as z,f as pe,$ as E,H as G,af as fe,U as O,ad as ge,a as V,ak as ve}from"./vendor-core-Do-oxgl9.js";import{u as we}from"./useUnreadStore-D50CXC_9.js";import{_ as ye}from"./index.vue_vue_type_script_setup_true_lang-B5HoY3_0.js";import{_ as xe}from"./index.vue_vue_type_script_setup_true_lang-BN3PGbF8.js";import{S as be}from"./index-BWKB83Cd.js";import{u as ke}from"./useVscodeOpen-CJ-3bg9h.js";import{I as M}from"./index-nNvVSsby.js";import"./useCacheOssStore-B5wqgiBM.js";const Ce='<path class="enk28pe8k"/>',$e={__name:"sunny-rounded",props:["width","height"],setup(g){const o={width:24,height:24};return(n,t)=>(i(),w(e(M),{width:g.width,height:g.height,viewBox:o,content:Ce,fallback:"material-symbols:sunny-rounded"},null,8,["width","height"]))}},Ee='<path class="o17qx8_el"/>',Ie={__name:"moon-stars-rounded",props:["width","height"],setup(g){const o={width:24,height:24};return(n,t)=>(i(),w(e(M),{width:g.width,height:g.height,viewBox:o,content:Ee,fallback:"material-symbols:moon-stars-rounded"},null,8,["width","height"]))}},Ue=I({__name:"ThemeSwitch",setup(g){const o=ie(),n=ce(o);return(t,u)=>(i(),y("div",null,[s(e(W),{modelValue:e(o),"onUpdate:modelValue":u[0]||(u[0]=r=>he(o)?o.value=r:null),"inline-prompt":"","active-icon":e(Ie),"inactive-icon":e($e),onChange:u[1]||(u[1]=r=>e(n)(r))},null,8,["modelValue","active-icon","inactive-icon"])]))}}),Le={class:"flex items-center cursor-pointer"},Be={class:"mx-1"},Se=I({__name:"I18nDropdown",setup(g){const{locale:o}=U(),n=$(()=>o.value),t=$(()=>n.value==="zh"?"简体中文":"English"),u=r=>{o.value=r,localStorage.setItem(de.LOCALE_KEY,r)};return(r,p)=>(i(),w(e(j),{trigger:"click",onCommand:u},{dropdown:a(()=>[s(e(R),null,{default:a(()=>[s(e(P),{command:"zh",disabled:n.value==="zh"},{default:a(()=>[...p[0]||(p[0]=[h(" 简体中文 ",-1)])]),_:1},8,["disabled"]),s(e(P),{command:"en",disabled:n.value==="en"},{default:a(()=>[...p[1]||(p[1]=[h(" English ",-1)])]),_:1},8,["disabled"])]),_:1})]),default:a(()=>[_("span",Le,[_("span",Be,c(t.value),1),s(e(ue),{icon:"material-symbols:keyboard-arrow-down-rounded"})])]),_:1}))}}),Ve={class:"flex items-center outline-none cursor-pointer gap-2 relative"},Pe={class:"truncate leading-normal"},De={class:"relative"},Te={key:0,class:"absolute -top-1 -right-1 size-[16px] rounded-full bg-red-500 text-white text-[10px] flex items-center justify-center font-bold leading-none"},ze={class:"flex items-center gap-2"},Oe={key:0,class:"size-[8px] rounded-full bg-red-500 inline-block"},Re=I({__name:"index",setup(g){const{t:o}=U(),n=me(),t=we(),u=F(),r=Z();function p(m){m&&t.fetchUnreadCounts()}const x=m=>{m==="logout"?n.logout():m==="info"?u.push({name:"userInfo"}):m==="myComments"&&u.push({name:"myComments"})},{pause:f,resume:b}=X(()=>{n.isRealUserLogin()&&t.fetchUnreadCounts()},3e4,{immediate:!1});return z(r,m=>{m==="visible"&&n.isRealUserLogin()?(b(),t.fetchUnreadCounts()):f()}),z(()=>n.isRealUserLogin(),m=>{m?(t.fetchUnreadCounts(),r.value==="visible"&&b()):(t.reset(),f())}),pe(()=>{n.isRealUserLogin()&&t.fetchUnreadCounts()}),(m,D)=>{const k=P,L=R,B=j;return i(),w(B,{onCommand:x,onVisibleChange:p},{dropdown:a(()=>[s(L,null,{default:a(()=>[e(n).isRealUserLogin()?(i(),y(G,{key:0},[s(k,{command:"info"},{default:a(()=>[h(c(e(o)("user.userInfo")),1)]),_:1}),s(k,{command:"myComments"},{default:a(()=>[_("span",ze,[h(c(e(o)("route.myComments"))+" ",1),e(t).totalCount>0?(i(),y("span",Oe)):E("",!0)])]),_:1}),s(k,{command:"logout"},{default:a(()=>[h(c(e(o)("user.logout")),1)]),_:1})],64)):(i(),w(k,{key:1,command:"logout"},{default:a(()=>[h(c(e(o)("user.goLogin")),1)]),_:1}))]),_:1})]),default:a(()=>[_("div",Ve,[_("span",Pe,c(e(n).displayName),1),_("div",De,[s(ye,{size:32,src:e(n).avatar,text:e(n).avatarStr},null,8,["src","text"]),e(t).totalCount>0?(i(),y("span",Te,c(e(t).totalCount>99?"99+":e(t).totalCount),1)):E("",!0)])])]),_:1})}}}),je={class:"py-1"},Ne=["onClick"],Ae={class:"flex-1 min-w-0"},Fe=["title"],Ge={class:"text-xs text-gray-400"},Me={key:0,class:"text-center text-gray-400 py-4 text-sm"},He=I({__name:"index",setup(g){const{openCompPathInVscode:o,handlePath:n}=ke(),{t}=U(),u=V(!1),r=V([]),p=V(null),x=$(()=>window.__GLOBAL_CONFIG__?.cwd||""),f=$(()=>window.__GLOBAL_CONFIG__?.projectHash||""),b=$(()=>r.value.find(l=>l.hash===f.value)),m=$(()=>n(x.value));function D(l){if(!l)return"";const v=l.includes("\\")?"\\":"/",C=l.replace(/[\\/]$/,"").split(v);return C.length<=2?l:`...${v}${C.slice(-2).join(v)}`}function k(){o(x.value,"./package.json")}async function L(){try{const v=await(await fetch("/__master__/projects")).json();r.value=v.projects||[]}catch{r.value=[]}}function B(l){l.hash!==f.value&&(window.location.href=`/${l.hash}/main/`)}async function H(l){try{await le.confirm(t("project.deregisterConfirm",{hash:l.hash,cwd:l.cwd}),t("project.deregisterTitle"),{confirmButtonText:t("common.confirm"),cancelButtonText:t("common.cancel"),type:"warning"})}catch{return}p.value=l.hash;try{(await(await fetch("/__master__/deregister",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({hash:l.hash})})).json()).success&&(r.value=r.value.filter(S=>S.hash!==l.hash),T.success(t("project.deregisterSuccess",{hash:l.hash})))}catch{T.error(t("project.deregisterFailed"))}finally{p.value=null}}return(l,v)=>{const C=ee,S=A,q=se,Y=ne,J=N,K=re;return i(),w(K,{visible:u.value,"onUpdate:visible":v[0]||(v[0]=d=>u.value=d),placement:"bottom-start",width:400,trigger:"click",onShow:L},{reference:a(()=>[s(S,{href:"javascript:void(0)",type:"primary",underline:"always",title:b.value?.cwd??x.value,class:"truncate max-w-[300px]"},{default:a(()=>[h(c(m.value)+" ",1),s(C,{class:"ml-1",style:{"vertical-align":"middle"}},{default:a(()=>[s(e(ae))]),_:1})]),_:1},8,["title"])]),default:a(()=>[_("div",je,[_("div",{class:"flex items-center px-3 py-2 hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer rounded text-sm",onClick:k},[s(C,{class:"mr-2"},{default:a(()=>[s(e(te))]),_:1}),h(" "+c(e(t)("project.openInEditor")),1)]),s(q,{style:{margin:"4px 0"}}),(i(!0),y(G,null,fe(r.value,d=>(i(),y("div",{key:d.hash,class:O(["flex items-center justify-between px-3 py-2 hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer rounded",{"bg-blue-50 dark:bg-blue-900/20":d.hash===f.value}]),onClick:Q=>B(d)},[_("div",Ae,[_("div",{class:O(["text-sm truncate",{"font-bold":d.hash===f.value}]),title:d.cwd},c(D(d.cwd)),11,Fe),_("div",Ge,[h(c(d.hash)+" ",1),d.hash===f.value?(i(),w(Y,{key:0,size:"small",type:"primary",class:"ml-1","disable-transitions":!0},{default:a(()=>[h(c(e(t)("project.current")),1)]),_:1})):E("",!0)])]),d.hash!==f.value?(i(),w(J,{key:0,text:"",type:"danger",size:"small",icon:e(oe),loading:p.value===d.hash,onClick:ge(Q=>H(d),["stop"])},null,8,["icon","loading","onClick"])):E("",!0)],10,Ne))),128)),r.value.length===0?(i(),y("div",Me,c(e(t)("project.noRegistered")),1)):E("",!0)])]),_:1},8,["visible"])}}}),qe={class:"h-full px-[20px] flex items-center relative justify-between gap-10"},Ye={class:"flex items-center gap-10 flex-1"},rt=I({__name:"index",setup(g){const o=F(),{t:n}=U(),t=_e();function u(){o.push({name:"upload"})}return(r,p)=>{const x=A,f=ve("Icon"),b=N;return i(),y("div",qe,[_("div",Ye,[s(xe,{logoClass:"h-[30px]"}),s(be),s(x,{href:e(t),type:"primary",underline:"always",target:"_blank",class:"truncate"},{default:a(()=>[h(c(e(n)("common.docsTutorial")),1)]),_:1},8,["href"]),s(He),s(b,{class:"ml-auto",round:"",type:"primary",onClick:u},{default:a(()=>[s(f,{icon:"material-symbols:upload",height:22}),h(" "+c(e(n)("route.upload")),1)]),_:1}),s(e(Ue)),s(e(Se))]),s(Re)])}}});export{rt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as x,u as A,a5 as u}from"./vendor-ui-BAx7vAkH.js";import{W as L,X as w,C as c,Y as D,Z as R,$ as y}from"./index-CnTuJQbj.js";import{I as N,aA as I,aJ as $,a as o,f as B,ak as S,O as f,P as T,Q as z,W as V,$ as q,m as d,n as G}from"./vendor-core-Do-oxgl9.js";const O={class:"size-full"},U=N({__name:"index",emits:["select"],setup(W,{emit:v}){const{locale:m,t:l}=I(),h={zh:"zhCN",en:"en"},p=d(()=>h[m.value]),t=o(null),n=o(!0),_=$(),r=x(`${L}_${_.path}`,""),g=v,E=A(),P=`${R()}/api/vuefinder`,F=new w({baseURL:P,url:{list:"/list"}}),i=o(r.value||c.FILE_MANAGER_DIRNAME),C=d(()=>({selectionMode:"single",driver:F,features:{search:!1,upload:!1,delete:!1,rename:!1,preview:!1,edit:!1,archive:!1,unarchive:!1,newfile:!1,newfolder:!1,fullscreen:!1,download:!1,language:!0,move:!1,copy:!1,history:!1,theme:!1,pinned:!1},contextMenuItems:[...y,{id:"select-folder",title:()=>l("file.select"),action:(a,e)=>{if(e.length>1){u.error(l("file.multiSelect"));return}const{type:s="dir"}=e[0];if(s!=="dir"){u.error(l("file.onlyDir"));return}g("select",e[0])},show:(a,e)=>{const{target:s,items:k}=e;return k.length>1?!1:s?.type==="dir"}}],config:{initialPath:i.value,theme:E.value?"valorite":"silver"}}));function M(a){r.value=a,!a&&t.value&&(n.value=!1,G(()=>{n.value=!0,i.value=c.FILE_MANAGER_DIRNAME,t.value?.refresh()}))}return B(()=>{t.value=D("vueFinder")}),(a,e)=>{const s=S("VueFinder");return f(),T("div",O,[n.value?(f(),z(s,V({key:0,id:"vueFinder",locale:p.value},C.value,{onPathChange:M}),null,16,["locale"])):q("",!0)])}}});export{U as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as _,O as v,P as E,a2 as c,u as m,aJ as D,E as M,f as P,Y as R,$ as x,a as k,m as z}from"./vendor-core-Do-oxgl9.js";import{c as O,p as V}from"./index-B-fZjRMn.js";import{C,d as $,z as F,E as f}from"./index-CnTuJQbj.js";import{_ as N}from"./index.vue_vue_type_script_setup_true_lang-Dl1KwcTe.js";import{_ as B}from"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./vendor-ui-BAx7vAkH.js";import"./useMessage-CHhLVawp.js";const L={class:"size-full"},j=_({__name:"index",props:{version:{type:String,default:""},compAttrs:{type:Object,default:()=>({})}},setup(e){return(p,a)=>(v(),E("div",L,[c(N,{compAttrs:e.compAttrs,version:e.version,bgColor:e.compAttrs?.bgColor,compType:m(C).IFRAME_ROUTES.ITEM.PREVIEW_REMOTE},null,8,["compAttrs","version","bgColor","compType"])]))}}),K={key:0,class:"size-full"},Q=_({__name:"index",setup(e){const p=D(),a=$(),A=new Map;M(C.PROVIDE_KEY_CALLBACKS,A);const{compId:t,version:r=""}=p.params,l=k(!1),o=O(t)(),d=z(()=>o.detail[r]);async function y(){if(await a.initSetting(),!t)throw new Error("compId is required");const n=await F.v1Comp.compcontrollerCompdetail({compId:t,version:r}),{objectId:u,version:s,files:g,dep:b}=n.data,w={objectId:u,version:s,files:g.map(i=>i.path)},S=await f.comp.compcontrollerCompfilesosssignedurl(w),h=V(b,a.deps).map(i=>i.name),I=await f.module.modulecontrollerPrebuild({deps:h}),{entryNameToFile:T={}}=I.data;o.setDetail(s,{...n.data,_id:t}),o.setDepEntryNameToFile(s,T),o.setVersionToFileAccessPath(s,S.data.signedUrls)}return P(async()=>{await y(),l.value=!0}),(n,u)=>l.value?(v(),E("div",K,[c(m(B),{isEmpty:!d.value,class:"size-full"},{default:R(()=>[c(j,{compAttrs:d.value,version:m(r)},null,8,["compAttrs","version"])]),_:1},8,["isEmpty"])])):x("",!0)}});export{Q as default};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-B8TdXR68.js","./vendor-ui-BAx7vAkH.js","./vendor-core-Do-oxgl9.js","./index-CnTuJQbj.js","./index-CjE-geY_.css"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{m as oe,C as P,n as ae,q as te,E as S,b as z,z as re}from"./index-CnTuJQbj.js";import{a8 as le,af as se,ag as ne,c as ie,a as Y,t as ce,a9 as me,w as de,ad as pe,n as ue,a5 as M}from"./vendor-ui-BAx7vAkH.js";/* empty css */import{u as _e,c as fe,C as he,_ as ge}from"./useCompEditStore-rtFXUPNg.js";import{I as K,aA as J,ak as B,O as g,Q as I,Y as s,a2 as n,R as o,a1 as d,u as i,U as k,$ as G,P as X,H as ve,af as ye,a0 as j,a as O,l as be,aG as xe,aJ as Ee,E as we,aC as H,a7 as Ce,k as Se,aL as ke,m as Re,n as q}from"./vendor-core-Do-oxgl9.js";import{_ as Te}from"./index.vue_vue_type_script_setup_true_lang-87WT-7PF.js";import{_ as Pe}from"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import{_ as Ie}from"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";import{u as De}from"./useTeamHeaders-C1Nwzx4f.js";/* empty css *//* empty css */import"./index-B-fZjRMn.js";import"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./v4-EwEgHOG0.js";import"./useMessage-CHhLVawp.js";import"./useVscodeOpen-CJ-3bg9h.js";import"./PanelBackground.vue_vue_type_script_setup_true_lang-C8JwSZDA.js";import"./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js";import"./BaseBadge-DUuZfvYd.js";import"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";import"./core-DIlcfMir.js";const Oe={class:"flex items-center gap-2"},Ne={class:"text-sm font-semibold"},Le={class:"px-1 pb-3"},Fe={class:"text-sm leading-relaxed mb-1"},Ae={class:"text-xs leading-relaxed mb-4 opacity-60"},Ue={class:"flex flex-col gap-2"},$e={class:"text-sm font-medium"},Ve={class:"text-sm font-medium"},ze={class:"flex items-center gap-2"},Me={class:"text-sm font-semibold"},je={class:"px-1 pb-3"},Be={class:"text-[13px] leading-relaxed mb-3"},Xe={class:"flex items-center flex-wrap gap-1.5 pt-2 border-t border-gray-200 dark:border-gray-700"},Ye={class:"text-xs font-medium opacity-50"},Ge={class:"flex justify-end items-center gap-2.5"},He=K({__name:"index",setup(Q,{expose:N}){const{t}=J(),_=O(!1),f=be({similarList:[],needRename:!1,editedName:"",folderName:""}),r=O(!0),x=O(["rename"]);let l=null,R=null;const{src:D}=_e("COMP_REPEAT.md");function v(E){return Object.assign(f,E),r.value=!0,x.value=E.needRename?["rename"]:E.similarList.length?["duplicate"]:[],_.value=!0,new Promise((c,y)=>{l=c,R=y})}function L(){R?.()}function h(){_.value=!1,R?.()}function F(){_.value=!1,l?.({shouldRename:r.value})}return N({open:v,close:h}),(E,c)=>{const y=B("Icon"),T=ne,A=B("router-link"),U=se,$=le,a=ie;return g(),I(i(Ie),{modelValue:_.value,"onUpdate:modelValue":c[3]||(c[3]=e=>_.value=e),title:i(t)("comp.uploadConfirmTitle"),width:"1000px",top:"10vh",onClosed:L},{footer:s(()=>[o("div",Ge,[n(a,{onClick:h},{default:s(()=>[j(d(i(t)("common.cancel")),1)]),_:1}),n(a,{type:"primary",onClick:F},{default:s(()=>[j(d(i(t)("common.confirm")),1)]),_:1})])]),default:s(()=>[n($,{class:"!h-[70vh] pr-5"},{default:s(()=>[n(U,{modelValue:x.value,"onUpdate:modelValue":c[2]||(c[2]=e=>x.value=e),class:"!border-none"},{default:s(()=>[f.needRename?(g(),I(T,{key:0,name:"rename"},{title:s(()=>[o("div",Oe,[n(y,{icon:"material-symbols:drive-file-rename-outline-rounded",width:"18",height:"18"}),o("span",Ne,d(i(t)("comp.renameFolderTitle")),1)])]),default:s(()=>[o("div",Le,[o("p",Fe,d(i(t)("comp.renameFolderTip",{editedName:f.editedName,folderName:f.folderName})),1),o("p",Ae,d(i(t)("comp.renameFolderQuestion")),1),o("div",Ue,[o("label",{class:k(["flex items-center gap-3 px-3.5 py-3 rounded-lg border cursor-pointer transition-all duration-200",r.value?"border-[var(--el-color-primary)] bg-[var(--el-color-primary-light-9)] dark:bg-[var(--el-color-primary-light-3)]/15":"border-gray-200 dark:border-gray-700 hover:border-[var(--el-color-primary-light-5)]"]),onClick:c[0]||(c[0]=e=>r.value=!0)},[o("span",{class:k(["flex items-center justify-center w-5 h-5 rounded-full border-1.5 flex-shrink-0 transition-all duration-200",r.value?"border-[var(--el-color-primary)] bg-[var(--el-color-primary)]":"border-gray-300 dark:border-gray-600"])},[o("span",{class:k(["w-2 h-2 rounded-full bg-white transition-transform duration-200",r.value?"scale-100":"scale-0"])},null,2)],2),o("span",$e,d(i(t)("comp.renameSyncYes")),1)],2),o("label",{class:k(["flex items-center gap-3 px-3.5 py-3 rounded-lg border cursor-pointer transition-all duration-200",r.value?"border-gray-200 dark:border-gray-700 hover:border-[var(--el-color-primary-light-5)]":"border-[var(--el-color-primary)] bg-[var(--el-color-primary-light-9)] dark:bg-[var(--el-color-primary-light-3)]/15"]),onClick:c[1]||(c[1]=e=>r.value=!1)},[o("span",{class:k(["flex items-center justify-center w-5 h-5 rounded-full border-1.5 flex-shrink-0 transition-all duration-200",r.value?"border-gray-300 dark:border-gray-600":"border-[var(--el-color-primary)] bg-[var(--el-color-primary)]"])},[o("span",{class:k(["w-2 h-2 rounded-full bg-white transition-transform duration-200",r.value?"scale-0":"scale-100"])},null,2)],2),o("span",Ve,d(i(t)("comp.renameSyncNo")),1)],2)])])]),_:1})):G("",!0),f.similarList.length?(g(),I(T,{key:1,name:"duplicate"},{title:s(()=>[o("div",ze,[n(y,{icon:"material-symbols:warning-rounded",width:"18",height:"18"}),o("span",Me,d(i(t)("comp.similarFound")),1)])]),default:s(()=>[o("div",je,[o("div",Be,[n(Pe,{src:i(D)},null,8,["src"])]),o("div",Xe,[o("span",Ye,d(i(t)("comp.similar"))+":",1),(g(!0),X(ve,null,ye(f.similarList,e=>(g(),I(A,{key:e._id,to:`/similarPreview/${e._id}`,target:"_blank",class:"inline-flex items-center gap-0.5 text-xs font-medium no-underline text-[var(--el-color-primary)] bg-[var(--el-color-primary-light-9)] dark:bg-[var(--el-color-primary-light-3)]/15 hover:bg-[var(--el-color-primary-light-7)] dark:hover:bg-[var(--el-color-primary-light-3)]/25 px-2.5 py-1 rounded-full transition-colors duration-150"},{default:s(()=>[j(d(e.name)+" ",1),n(y,{icon:"material-symbols:open-in-new-rounded",width:"12",height:"12",class:"opacity-50"})]),_:2},1032,["to"]))),128))])])]),_:1})):G("",!0)]),_:1},8,["modelValue"])]),_:1})]),_:1},8,["modelValue","title"])}}}),qe={class:"size-full p-[10px]"},Ke={class:"overflow-hidden size-full"},Je={key:0,class:"cursor-not-allowed bg-gray-100 dark:bg-gray-800 absolute inset-0 flex items-center justify-center"},Qe={class:"text-gray-500"},xo=K({__name:"index",setup(Q){const N=ke(()=>te(()=>import("./index-B8TdXR68.js"),__vite__mapDeps([0,1,2,3,4]),import.meta.url)),{t}=J(),_=xe(),f=Ee(),{teamId:r}=De(),x=Y(oe,!1),l=fe(f.path,P.DIALOG_TYPE_ADD)();we(P.PROVIDE_KEY_COMP_EDIT_STORE,l);const R=H("dialogPutTreaty"),D=H("dialogUploadConfirmRef"),v=Y(ae,330);v.value<=0&&(v.value=330);const L=O(""),h=Re(()=>l.selectedFolder?.path);async function F(a){const e=await S.comp.compcontrollerDir({compPath:a}),{tree:m,files:p}=e.data;l.setOriginalDirectory(m),l.setOriginalDirectoryList(p);const u=m?.children||[];if(u?.length){const b=u.find(ee=>ee.name===P.COMP_CONFIG_FILENAME);if(!b)return"NOT_EXIST";const w=await S.comp.compcontrollerFile({filePath:b.path}),{content:C}=w.data,V=JSON.parse(C).__id__;if(!V)return"NOT_EXIST";const Z=await re.v1Comp.compcontrollerCheckcompexistbyid({compId:V}),{exist:W}=Z.data;if(W)return L.value=V,"EXIST"}return"NOT_EXIST"}const E=async(a,e)=>{if(e()){if(l.$reset(),!x.value){R.value?.open(m=>{m&&(x.value=!0,c(a))});return}c(a)}};async function c(a){const e=pe.service({fullscreen:!0}),m=await F(a.path);if(m==="NOT_EXIST"){const p=await S.comp.compcontrollerDep({compPath:a.path}),{thirdParty:u}=p.data;l.setSelectedFolder(a),q(()=>{l.initPreviewCompList(),l.setCompDep(u),e.close()}),window?.umami?.track(z.UPLOAD_SELECT_FOLDER,{path:a.path})}else m==="EXIST"&&ue.confirm(t("comp.compAlreadyUploaded"),t("common.warning"),{confirmButtonText:t("common.confirm"),cancelButtonText:t("common.cancel"),type:"warning"}).catch(()=>{}).finally(()=>{e.close()})}async function y(){const a=l.extraInfo.name;try{await S.comp.compcontrollerRenamedir({compPath:h.value,newName:a}),M.success(t("message.success.renameFolder"))}catch{M.warning(t("message.error.renameFolder"))}}async function T({shouldRename:a}){const e=l.getCompSubmitParams();await S.comp.compcontrollerSubmit({...e,...r?{teamId:r}:{}}),M.success(t("message.success.upload")),window?.umami?.track(z.UPLOAD_SUCCESS,{compPath:h.value,teamId:r}),a&&await y(),await U(),l.$reset()}async function A({end:a}){try{const e=await S.comp.compcontrollerCheckcomprepeat({compPath:h.value,...r?{teamId:r}:{}}),{similarList:m=[]}=e.data,p=l.extraInfo.name,u=l.selectedFolder.basename,b=!!(p&&p!==u);if(!(m.length>0)&&!b){await T({shouldRename:!1}),a();return}const C=await D.value.open({similarList:m,needRename:b,editedName:p,folderName:u}).catch(()=>null);if(C===null)return;await T({shouldRename:C.shouldRename})}catch(e){console.error("上传失败:",e),window?.umami?.track(z.UPLOAD_FAILED,{compPath:h.value,teamId:r,error:String(e)})}finally{a()}}async function U(){r?await _.push({name:"team",params:{teamId:r},query:{[P.ROUTE_STATE_KEY_VERSION]:Date.now()}}):await _.push({name:"mine",query:{[P.ROUTE_STATE_KEY_VERSION]:Date.now()}})}async function $(){const a=l.selectedFolder;l.$reset(),await q(),c(a)}return Ce(()=>{l.$reset()}),(a,e)=>{const m=ce,p=B("Icon"),u=me,b=de;return g(),X("div",qe,[n(b,null,{default:s(()=>[n(m,{size:i(v),"onUpdate:size":e[0]||(e[0]=w=>Se(v)?v.value=w:null),collapsible:"",max:"30%"},{default:s(()=>[o("div",Ke,[n(Te,null,{default:s(({isLogin:w})=>[n(i(N),{onSelect:C=>E(C,w)},null,8,["onSelect"])]),_:1})])]),_:1},8,["size"]),n(m,{class:"size-full rounded-sm relative !overflow-hidden"},{default:s(()=>[h.value?(g(),I(he,{key:1,onConfirmUpload:A,onReload:$})):(g(),X("div",Je,[n(u,null,{image:s(()=>[o("div",null,[n(p,{icon:"material-symbols:folder-info"})])]),description:s(()=>[o("span",Qe,d(i(t)("comp.pleaseSelectFolderFirst")),1)]),_:1})]))]),_:1})]),_:1}),n(ge,{ref:"dialogPutTreaty"},null,512),n(He,{ref_key:"dialogUploadConfirmRef",ref:D},null,512)])}}});export{xo as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{s as i}from"./vendor-ui-BAx7vAkH.js";import{d as u,e as d,_}from"./index-CnTuJQbj.js";import{I as l,aA as m,aG as g,O as f,Q as S,Y as h,R as x,U as C,u as a,a1 as t,m as U}from"./vendor-core-Do-oxgl9.js";const b=l({__name:"index",setup(k){const{t:e}=m(),o=u(),s=d(),r=g(),n=U(()=>s.isUpgrade?e("upgrade.hasUpdate"):e("upgrade.betaVersion"));function p(){r.push({name:"upgrade"})}return(V,y)=>{const c=i;return f(),S(c,{type:"primary",round:"",class:"cursor-pointer","disable-transitions":"",onClick:p},{default:h(()=>[x("span",{class:C({"is-upgrade":a(s).isUpgrade})},t(n.value)+" "+t(a(o).compHubVersion),3)]),_:1})}}}),R=_(b,[["__scopeId","data-v-7cb44021"]]);export{R as S};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a7 as B,a as J,f as Q,b as Z,B as ee,c as te,y as se,m as ae,a5 as V}from"./vendor-ui-BAx7vAkH.js";import{u as oe,a as le,L as ne,b as _,z as ie,C as T,_ as D}from"./index-CnTuJQbj.js";/* empty css */import{_ as re}from"./index.vue_vue_type_script_setup_true_lang-BN3PGbF8.js";import{S as ue}from"./index-BWKB83Cd.js";import{I as L,aA as G,O as w,P as b,R as n,a2 as e,a1 as m,u as o,Y as i,a0 as v,aG as ce,aC as de,l as $,d as me,H as A,$ as O,a as P,m as F}from"./vendor-core-Do-oxgl9.js";import{m as pe}from"./md5-BaIvdSuD.js";import{_ as _e}from"./AuthCodeSendBtn.vue_vue_type_script_setup_true_lang-C5to3ZQC.js";import{S as fe}from"./index-DwDo8mID.js";import{_ as ge}from"./CanvasAnimation.vue_vue_type_script_setup_true_lang-CisWACfW.js";import"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";const he={class:"flex bg-gray-600 items-center justify-center overflow-hidden"},ve={class:"w-full rounded-2xl p-8 md:p-12"},we={class:"flex mb-[10px]"},be={class:"text-2sm text-gray-300 mb-[50px] ml-2"},Ce={class:"relative pl-6 border-l-4 border-indigo-400 mb-8"},xe={class:"leading-relaxed text-gray-300"},ye={class:"flex items-center gap-2 mb-6"},Ie=L({__name:"index",setup(k){const{t:f}=G(),s=oe();return(y,h)=>{const p=B;return w(),b("div",he,[n("section",ve,[n("header",we,[e(re)]),n("h2",be,m(o(f)("common.siteSubtitle")),1),n("blockquote",Ce,[n("p",xe,m(o(f)("common.siteSlogan")),1),h[0]||(h[0]=n("footer",{class:"mt-4 text-sm text-gray-500"},null,-1))]),n("div",ye,[e(ue),e(p,{href:o(s),type:"primary",underline:"always",target:"_blank"},{default:i(()=>[v(m(o(f)("common.docsTutorial")),1)]),_:1},8,["href"])])])])}}}),Ee={class:"flex items-center justify-center bg-[#0d0d0d] size-full overflow-hidden"},Se={class:"h-full"},Te={class:"flex items-center gap-1 w-full"},$e={class:"text-[#666] text-xs"},Le={class:"flex justify-between"},ke=L({__name:"index",setup(k){const{GithubIcon:f}=fe,{t:s}=G(),y=ce(),h=le(),p=de("form"),I=J(ne,"account"),C=P(!1),E=P(!1),g=$([{name:s("user.accountLogin"),type:"account",select:I.value==="account"},{name:s("user.emailLogin"),type:"email",select:I.value==="email"}]),l=$({account:"",password:"",email:"",authCode:""}),H=$({account:[{required:!0,message:s("user.pleaseInputAccount"),trigger:"blur"}],password:[{required:!0,message:s("user.pleaseInputPassword"),trigger:"blur"}],email:[{required:!0,message:s("common.pleaseInput")+s("user.email"),trigger:"blur"},{type:"email",message:s("user.pleaseInputCorrectEmail"),trigger:"blur"}],authCode:[{required:!0,message:s("user.pleaseInputAuthCode"),trigger:"blur"}]}),N=F(()=>g.find(a=>!a.select)??g[1]),x=F(()=>g.find(a=>a.select)??g[0]);function R(a){g.forEach(t=>{t.select=!1}),a.select=!0}function j(){y.replace("/")}async function z({end:a,startCountdown:t}){if(x.value?.type==="email"&&l.email){if(!await p.value?.validateField("email").catch(()=>!1)){a();return}ie.v1Email.emailcontrollerSendcode({email:l.email}).then(()=>{V.success(s("message.success.sendAuthCode")),t(),window?.umami?.track(_.SEND_AUTH_CODE_SUCCESS,{email:l.email})}).catch(()=>{window?.umami?.track(_.SEND_AUTH_CODE_FAILED,{email:l.email})}).finally(()=>{a()})}}function q(){p.value&&p.value.validate(a=>{if(!a)return;const t={account:{fields:["account","password"],getParams:d=>({account:d.account,password:pe(d.password)})},email:{fields:["email","authCode"],getParams:d=>({email:d.email,authCode:d.authCode})}},r=x.value?.type,u=r&&t[r];if(!u)return;u.fields.every(d=>!!l[d])&&M(u.getParams(l))})}function M(a){p.value&&p.value.validate(t=>{t&&(C.value=!0,h.login(a).then(()=>{y.replace("/").finally(()=>{C.value=!1,V.success(s("user.loginSuccess")),window?.umami?.track(_.LOGIN_BUTTON_SUCCESS,{form:a}),window?.umami?.identify({id:h.userId})})}).catch(r=>{window?.umami?.track(_.LOGIN_BUTTON_FAILED,{form:a,error:r})}).finally(()=>{C.value=!1}))})}function W(){E.value=!0;const a=window.__GLOBAL_CONFIG__?.projectHash,t=a?`/${a}/${T.WEBSITE_PATH_MAIN}`:`/${T.WEBSITE_PATH_MAIN}`,r=encodeURIComponent(`${window.location.origin}${t}/github-callback`);window.location.href=`/${T.REMOTE_SERVICE_PREFIX}/api/v1/auth/github?redirect_uri=${r}`}return me(()=>{g.forEach(a=>{a.select&&(I.value=a.type)})}),(a,t)=>{const r=ee,u=Z,S=te,d=se,Y=ae,U=B,K=Q;return w(),b("div",Ee,[e(K,{ref:"form",class:"w-[70%]",model:l,rules:H,"status-icon":""},{default:i(()=>[n("div",Se,[x.value.type==="account"?(w(),b(A,{key:0},[e(u,{prop:"account"},{default:i(()=>[e(r,{modelValue:l.account,"onUpdate:modelValue":t[0]||(t[0]=c=>l.account=c),placeholder:o(s)("user.pleaseInputUsername")},null,8,["modelValue","placeholder"])]),_:1}),e(u,{prop:"password"},{default:i(()=>[e(r,{modelValue:l.password,"onUpdate:modelValue":t[1]||(t[1]=c=>l.password=c),placeholder:o(s)("user.pleaseInputPassword"),type:"password"},null,8,["modelValue","placeholder"])]),_:1}),t[6]||(t[6]=n("div",{class:"toolbar"},null,-1))],64)):O("",!0),x.value.type==="email"?(w(),b(A,{key:1},[e(u,{prop:"email"},{default:i(()=>[e(r,{modelValue:l.email,"onUpdate:modelValue":t[2]||(t[2]=c=>l.email=c),placeholder:o(s)("common.pleaseInput")+o(s)("user.email")},null,8,["modelValue","placeholder"])]),_:1}),e(u,{prop:"authCode"},{default:i(()=>[n("div",Te,[e(r,{modelValue:l.authCode,"onUpdate:modelValue":t[3]||(t[3]=c=>l.authCode=c),placeholder:o(s)("user.pleaseInputAuthCode")},null,8,["modelValue","placeholder"]),e(o(_e),{id:o(_).SEND_AUTH_CODE,disabled:!l.email,text:o(s)("user.sendAuthCode"),"countdown-text":"user.resendAfterSeconds",duration:60,onSend:t[4]||(t[4]=({end:c,startCountdown:X})=>z({end:c,startCountdown:X}))},null,8,["id","disabled","text"])])]),_:1})],64)):O("",!0),e(u,null,{default:i(()=>[e(S,{id:o(_).LOGIN_BUTTON,disabled:E.value,class:"w-full",loading:C.value,type:"primary",onClick:q},{default:i(()=>[v(m(o(s)("user.login")),1)]),_:1},8,["id","disabled","loading"])]),_:1}),e(u,null,{default:i(()=>[e(d,{class:"!bg-red"},{default:i(()=>[n("span",$e,m(o(s)("common.or")),1)]),_:1}),e(S,{class:"w-full",color:"#141414",loading:E.value,onClick:W},{default:i(()=>[e(Y,{class:"mr-1"},{default:i(()=>[e(o(f))]),_:1}),v(" "+m(o(s)("user.loginWithGithub")),1)]),_:1},8,["loading"])]),_:1})]),n("div",Le,[e(U,{id:o(_).SKIP_LOGIN,href:"javascript:void(0)",onClick:j},{default:i(()=>[v(m(o(s)("user.skip")),1)]),_:1},8,["id"]),e(U,{type:"primary",onClick:t[5]||(t[5]=c=>R(N.value))},{default:i(()=>[v(m(N.value.name),1)]),_:1})])]),_:1},8,["model","rules"])])}}}),Ne=D(ke,[["__scopeId","data-v-fcb0eb68"]]),Ue={class:"size-full relative"},Ve={class:"absolute inset-0 flex items-center justify-center"},Ae={class:"login-content-container"},Oe={class:"flex size-full"},Pe=L({__name:"index",setup(k){return(f,s)=>(w(),b("div",Ue,[e(o(ge)),n("div",Ve,[n("div",Ae,[n("div",Oe,[e(Ie,{class:"size-full flex-1"}),e(Ne,{class:"flex-1"})])])])]))}}),Ye=D(Pe,[["__scopeId","data-v-78f66c71"]]);export{Ye as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a8 as a}from"./vendor-ui-BAx7vAkH.js";import"./index-CnTuJQbj.js";import{_ as s}from"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import{I as c,aJ as n,O as l,Q as m,Y as u,a2 as i,m as p}from"./vendor-core-Do-oxgl9.js";import"./core-DIlcfMir.js";const C=c({__name:"index",setup(_){const o=n(),t=p(()=>{const{markdownSrc:r}=o.query;return r||""});return(r,f)=>{const e=a;return l(),m(e,{"wrap-class":"md-container",class:"size-full w-[1300px] mx-auto"},{default:u(()=>[i(s,{src:t.value,"show-toc":!0,scrollContainer:".md-container"},null,8,["src"])]),_:1})}}});export{C as default};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./index-DQTRYmEL.js","./vendor-ui-BAx7vAkH.js","./vendor-core-Do-oxgl9.js","./index-CnTuJQbj.js","./index-CjE-geY_.css","./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js","./index-B-fZjRMn.js","./useCompMetaLocalStore-DBe1Ldcg.js","./useCacheOssStore-B5wqgiBM.js","./useVscodeOpen-CJ-3bg9h.js","./useTeamHeaders-C1Nwzx4f.js","./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js","./useTeamHeaders-a-XSRO3U.css","./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js","./useMessage-CHhLVawp.js","./el-link-CPQZ-olG.css","./useCompEditStore-rtFXUPNg.js","./v4-EwEgHOG0.js","./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js","./core-DIlcfMir.js","./index-Dj51p5I8.css","./PanelBackground.vue_vue_type_script_setup_true_lang-C8JwSZDA.js","./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js","./BaseBadge-DUuZfvYd.js","./BaseBadge-ledSuDnX.css","./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js","./useCompEditStore-Br3x5A7Q.css","./el-card-BAyktVMS.css","./index.vue_vue_type_style_index_0_lang-C30OZgOy.js","./index-CdWXO9ks.css","./useKeyword-BygMrCvJ.js","./index-DKv4dFPY.js","./index-DFsl7Pen.css","./index-Da5ZhB-r.js","./el-table-column-DUFMPIr5.js","./el-table-column-B3ZEEuPD.css","./moment-B-YVwB4U.js","./index-HnLIbMTX.js","./index-Cbpqtmwk.js","./index.vue_vue_type_script_setup_true_lang-B5HoY3_0.js","./index-DOlF0Z_P.css","./index-CxLzXF-b.js","./index-CnhaF7r3.js","./AuthCodeSendBtn.vue_vue_type_script_setup_true_lang-C5to3ZQC.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{_ as ce,B as q,C as P,T as J,z as N,t as L,j as me,x as de,b as pe,q as M}from"./index-CnTuJQbj.js";import{ak as ue,m as _e,g as fe,c as W,a8 as X,a6 as ve,al as he,F as ge,N as be,a5 as ye,aa as Z,am as Ce,s as we,a as xe,ae as Te,n as Ae}from"./vendor-ui-BAx7vAkH.js";import{_ as Ee}from"./el-table-column-DUFMPIr5.js";/* empty css */import{_ as ke}from"./index.vue_vue_type_script_setup_true_lang-B5HoY3_0.js";import{I as $,O as g,P as B,R as r,a1 as f,S as G,m as i,ac as Ie,Q as E,u as e,W as ee,Y as s,aD as Le,a2 as a,_ as H,aA as z,am as De,an as Se,a0 as D,aJ as te,E as Y,aC as ae,w as oe,a7 as se,h as $e,n as Me,aF as ne,a as F,e as j,aG as Oe,aQ as Re,aR as Ve,f as Pe,k as Ne,aL as O}from"./vendor-core-Do-oxgl9.js";import{c as Be,b as ze,d as K}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";import{_ as Ue}from"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";import{u as Fe}from"./useKeyword-BygMrCvJ.js";import{d as Ge,I as Q,c as He}from"./useMessage-CHhLVawp.js";import{u as le}from"./useTeamHeaders-C1Nwzx4f.js";import{I as ie}from"./index-nNvVSsby.js";import{_ as Ke}from"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import{_ as Ye}from"./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js";import"./useCacheOssStore-B5wqgiBM.js";import"./index-B-fZjRMn.js";import"./useCompMetaLocalStore-DBe1Ldcg.js";import"./useVscodeOpen-CJ-3bg9h.js";/* empty css */import"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";const je={class:"flex items-center justify-center gap-[6px] leading-[15px]"},Qe={class:"text-xs leading-3 align-middle"},qe={class:"inline-block align-middle shrink-0"},Je=$({__name:"UserAvatar",props:{nickname:{type:String,default:""},teamUserNickname:{type:String,default:""}},setup(m){const t=m,o=i(()=>t.teamUserNickname||t.nickname||"--");return(c,C)=>(g(),B("div",je,[r("span",Qe,f(o.value),1),r("div",qe,[G(c.$slots,"avatar",{},void 0,!0)])]))}}),We=ce(Je,[["__scopeId","data-v-f90b87fa"]]),Xe=$({__name:"SkeletonContainer",setup(m){const t=Ie();return(o,c)=>(g(),E(e(ue),ee({rows:3,animated:""},e(t)),{default:s(()=>[G(o.$slots,"default")]),template:s(()=>[G(o.$slots,"template")]),_:3},16))}}),Ze='<path class="cdj_y1r7t"/>',et={__name:"grid-view-rounded",props:["width","height"],setup(m){const t={width:24,height:24};return(o,c)=>(g(),E(e(ie),{width:m.width,height:m.height,viewBox:t,content:Ze,fallback:"material-symbols:grid-view-rounded"},null,8,["width","height"]))}},tt='<path class="u2_fvl-wz"/>',at={__name:"view-list",props:["width","height"],setup(m){const t={width:24,height:24};return(o,c)=>(g(),E(e(ie),{width:m.width,height:m.height,viewBox:t,content:tt,fallback:"material-symbols:view-list"},null,8,["width","height"]))}},ot=$({__name:"ViewToggle",props:{modelValue:{},modelModifiers:{}},emits:["update:modelValue"],setup(m){const t=Le(m,"modelValue"),o=i(()=>t.value==="grid"?at:et);function c(){t.value=t.value==="grid"?"list":"grid"}return(C,l)=>(g(),B("div",{class:"flex items-center rounded-sm cursor-pointer",onClick:c},[a(e(_e),{style:{"font-size":"25px"}},{default:s(()=>[(g(),E(H(o.value)))]),_:1})]))}}),st={class:"size-full overflow-hidden"},nt=$({__name:"ViewCompList",props:{data:{type:Array,default:()=>[]},selectedRows:{type:Array,default:()=>[]}},emits:["add-one-comp"],setup(m,{emit:t}){const{t:o}=z(),c=m,C=t,l=i(()=>({data:c.data,column:[{prop:"name",label:o("comp.name"),align:"center"},{prop:"version",label:o("comp.version"),align:"center"},{prop:"isAdd",label:o("team.added"),align:"center",formatter:d=>d.isAdd?o("common.yes"):o("common.no")},{prop:"desc",label:o("common.description"),align:"center",showOverflowTooltip:{popperClass:"table-text-tooltip"}},{slot:"operation",prop:"operation",label:o("common.operation"),align:"center"}],isPagination:!1,autoLoading:!1})),w=(d,p)=>{p.start(),C("add-one-comp",d._id,()=>{p.end()})};return(d,p)=>{const I=W,x=fe;return g(),B("div",st,[a(e(q),{ref:"baseTable",tableConfig:l.value,border:"",stripe:""},{operation:s(({col:T})=>[a(x,De(Se(T)),{default:s(({row:u})=>[r("div",null,[a(e(Ue),null,{default:s(({instance:n,loading:_})=>[a(I,{type:"primary",disabled:u.isAdd,loading:_,onClick:S=>w(u,n)},{default:s(()=>[D(f(u.isAdd?e(o)("team.added"):e(o)("common.add")),1)]),_:2},1032,["disabled","loading","onClick"])]),_:2},1024)])]),_:1},16)]),_:1},8,["tableConfig"])])}}}),lt={class:"size-full overflow-hidden"},it=$({__name:"ViewCompGrid",props:{data:{type:Array,default:()=>[]},keyword:{type:String,default:""}},emits:["add-one-comp"],setup(m,{emit:t}){const o=m,c=t,C=$e(),l=te(),{sendMessageToTargetIframe:w,messageListener:d}=He(),p=Ge(!1,window.__GLOBAL_CONFIG__.subPort),{addListener:I}=d(),x=Be(`${l.path}_${P.SCOPE_ID_TEAM_ADD_MY_COMP}`)();Y(P.PROVIDE_KEY_COMP_LIST_STORE,x);const T=new Map;Y(P.PROVIDE_KEY_CALLBACKS,T);const u=ae("compIframeContainer");Fe(i(()=>o.keyword),u);const n=async()=>{x.renderList([]),await Me(),x.setLoading(!0);const _=ve(o.data);x.renderList(_??[])};return I(Q.ACTION_ADD_COMP_START_LOADING,_=>{c("add-one-comp",_,()=>{u.value?.sendMessageToTargetIframeByCompId(S=>{S&&w(S,Q.ACTION_ADD_COMP_FINISH_LOADING,"",p)})})}),oe(()=>o.data,()=>n(),{immediate:!0,deep:!0}),se(()=>{x.$reset()}),(_,S)=>{const b=X;return g(),B("div",lt,[a(b,{always:"",wrapClass:"pr-[10px]"},{default:s(()=>[a(ze,{ref:"compIframeContainer",iuid:e(C)?.uid,compType:e(P).IFRAME_ROUTES.CONTAINER.TEAM_ADD},null,8,["iuid","compType"])]),_:1})])}}}),rt={class:"size-full flex flex-col overflow-auto overflow-x-hidden"},ct={class:"flex gap-2 pb-2"},mt=$({__name:"index",setup(m,{expose:t}){const{t:o}=z(),{headers:c,teamId:C}=le(),l=K(C)(),w=F(!1),d=F(""),p=F({data:[],search:{column:[{prop:"keyword",component:j(ge),label:i(()=>o("common.keyword")),value:"",autoQuery:!1,attributes:{placeholder:i(()=>o("comp.keywordPlaceholder")),fetchSuggestions:x,triggerOnFocus:!1,style:"width: 350px",fitInputWidth:!0}},{prop:"status",label:i(()=>o("common.status")),component:j(be),value:"NotAdded",attributes:{style:{width:"120px"},clearable:!0,options:[{label:i(()=>o("team.added")),value:"Added"},{label:i(()=>o("team.notAdded")),value:"NotAdded"}]}}]},pagination:{total:0,attributes:{pageSizes:[10,20,30]}},fetchData:T}),I=i(()=>p.value?.search?.column[0]?.value??"");function x(b,y){if(b.length<=1)return y([]);N.v1Keyword.keywordcontrollerQuerykeywordscomp({keyword:b,type:"compMy"},{headers:c}).then(k=>{const{keywords:A=[]}=k.data||{};y(A)})}async function T(b){const y=await N.v1Team.teamcontrollerAddtoteammycomps({...b},{headers:c}),{rows:k,total:A}=y.data||{};p.value.data=k||[],p.value.pagination.total=A||0}function u(){w.value=!0}function n(){w.value=!1}function _(){d.value=d.value??"list"}function S(b,y){N.v1Team.teamcontrollerCopycomp({compIds:[b]},{headers:c}).then(()=>{p.value.data?.forEach(A=>{b===A._id&&(A.isAdd=!0)});const k=l.teamDetail.compCount+1;l.setTeamDetail({...l.teamDetail,compCount:k}),ye.success(o("team.addSuccess"))}).finally(y)}return t({open:u,close:n}),(b,y)=>{const k=he;return g(),E(k,{modelValue:w.value,"onUpdate:modelValue":y[1]||(y[1]=A=>w.value=A),title:e(o)("team.addComp"),resizable:"","with-header":!1,size:"50%","append-to-body":"",onOpened:_},{default:s(()=>[r("div",rt,[a(e(q),{tableConfig:p.value},{tableBefore:s(()=>[r("div",ct,[a(e(ot),{modelValue:d.value,"onUpdate:modelValue":y[0]||(y[0]=A=>d.value=A),class:"ml-auto"},null,8,["modelValue"])])]),table:s(()=>[a(e(J),null,{default:s(()=>[(g(),E(ne,null,[(g(),E(H(d.value==="grid"?it:nt),{data:p.value.data,keyword:I.value,onAddOneComp:S},null,40,["data","keyword"]))],1024))]),_:1})]),_:1},8,["tableConfig"])])]),_:1},8,["modelValue","title"])}}}),dt={class:"size-full overflow-hidden flex items-center gap-6"},pt={class:"flex-shrink-0"},ut={class:"flex flex-1 flex-col gap-3 overflow-hidden"},_t={class:"flex items-center gap-3"},ft={class:"text-xl font-bold"},vt={class:"flex items-center gap-1 rounded-full px-3 py-0.5 text-xs"},ht={class:"flex flex-wrap items-center gap-3"},gt={class:"!flex items-center gap-1"},bt={class:"!flex items-center gap-1"},yt={class:"!flex items-center gap-1"},Ct={class:"!flex items-center gap-1"},wt={class:"!flex items-center gap-1"},xt={class:"flex items-center gap-3 flex-shrink-0"},Tt=$({__name:"index",setup(m){const{t}=z(),o=te(),c=Oe(),{teamId:C}=o.params,l=K(C)(),w=ae("teamAddCompDrawer");function d(){w.value?.open()}function p(){c.push({name:"uploadTeam",params:{teamId:C}})}return(I,x)=>{const T=Ce,u=we,n=W,_=Z;return g(),E(_,{"body-class":"!p-0",class:"size-full rounded-sm p-4"},{default:s(()=>[a(e(Xe),{rows:4,loading:e(l).loading},{default:s(()=>[r("div",dt,[r("div",pt,[a(T,{size:64,class:"bg-indigo-100"},{default:s(()=>[a(e(L),{icon:"material-symbols:layers-rounded",class:"text-3xl"})]),_:1})]),r("div",ut,[r("div",_t,[r("h2",ft,f(e(l).teamName),1),r("span",vt,[a(e(L),{icon:"material-symbols:check-circle-rounded",class:"text-green-500"}),D(" "+f(e(l).description),1)])]),r("div",ht,[a(u,{round:"",type:"info","disable-transitions":""},{default:s(()=>[r("div",gt,[a(e(L),{icon:"material-symbols:person-rounded"}),D(" "+f(e(t)("team.creator"))+" ",1),a(e(We),ee(e(l).creator,{teamUserNickname:e(l).creatorNickname}),{avatar:s(()=>[a(ke,{size:15,src:e(l).creator?.avatar},null,8,["src"])]),_:1},16,["teamUserNickname"])])]),_:1}),a(u,{round:"",type:"info","disable-transitions":""},{default:s(()=>[r("div",bt,[a(e(L),{icon:"material-symbols:tag-rounded"}),D(" "+f(e(t)("team.code"))+" ",1),a(e(Ee),{class:"text-xs",text:e(l).code},null,8,["text"])])]),_:1}),a(u,{round:"",type:"info","disable-transitions":""},{default:s(()=>[r("div",yt,[a(e(L),{icon:"material-symbols:group-rounded"}),D(" "+f(e(t)("team.member"))+" "+f(e(l).memberCount)+" "+f(e(t)("common.person")),1)])]),_:1}),a(u,{round:"",type:"info","disable-transitions":""},{default:s(()=>[r("div",Ct,[a(e(L),{icon:"material-symbols:widgets-rounded"}),D(" "+f(e(t)("team.compCount"))+" "+f(e(l).compCount)+" "+f(e(t)("common.unit")),1)])]),_:1}),a(u,{round:"",type:"info","disable-transitions":""},{default:s(()=>[r("div",wt,[a(e(L),{icon:"material-symbols:download-rounded"}),D(" "+f(e(t)("team.downloadCount"))+" "+f(e(l).totalDownloadCount),1)])]),_:1})]),r("div",xt,[a(n,{class:"!rounded-full !px-5 !py-2 !h-auto",onClick:d},{default:s(()=>[a(e(L),{icon:"material-symbols:format-list-bulleted-rounded",class:"mr-1"}),D(" "+f(e(t)("team.addFromMine")),1)]),_:1}),a(n,{type:"primary",class:"!rounded-full !px-5 !py-2 !h-auto",onClick:p},{default:s(()=>[a(e(L),{icon:"material-symbols:upload-rounded",class:"mr-1"}),D(" "+f(e(t)("comp.upload")),1)]),_:1})])])])]),_:1},8,["loading"]),a(mt,{ref:"teamAddCompDrawer"},null,512)]),_:1})}}}),At={class:"mt-2"},Yt=$({__name:"index",setup(m){const{t}=z(),o=O(()=>M(()=>import("./index-DQTRYmEL.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30]),import.meta.url)),c=O(()=>M(()=>import("./index-DKv4dFPY.js"),__vite__mapDeps([31,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,17,30,32,27]),import.meta.url)),C=O(()=>M(()=>import("./index-Da5ZhB-r.js"),__vite__mapDeps([33,1,2,3,4,34,35,5,6,7,8,9,10,11,12,13,14,15,36,25]),import.meta.url)),l=O(()=>M(()=>import("./index-HnLIbMTX.js"),__vite__mapDeps([37,1,2,3,4,10,11,12,5,6,7,8,9,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30]),import.meta.url)),w=O(()=>M(()=>import("./index-Cbpqtmwk.js"),__vite__mapDeps([38,1,2,3,4,34,35,5,6,7,8,9,10,11,12,13,14,15,39,40]),import.meta.url)),d=O(()=>M(()=>import("./index-CxLzXF-b.js"),__vite__mapDeps([41,1,2,3,4,34,35,5,6,7,8,9,10,11,12,13,14,15,39,40,25]),import.meta.url)),p=O(()=>M(()=>import("./index-CnhaF7r3.js"),__vite__mapDeps([42,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,43,25,27]),import.meta.url)),I=[{label:i(()=>t("team.compLib")),value:"TeamCompList",component:o,visible:()=>!0},{label:i(()=>t("team.groupConfig")),value:"TeamCompGroup",component:c,visible:()=>n.isCreator},{label:i(()=>t("team.compManage")),value:"TeamCompManage",component:C,visible:()=>n.isCreator},{label:i(()=>t("team.myCompList")),value:"TeamMyCompList",component:l,visible:()=>!0},{label:i(()=>t("team.member")),value:"TeamMemberList",component:w,visible:()=>!0},{label:i(()=>t("team.applyList")),value:"TeamApplyList",component:d,visible:()=>n.isCreator},{label:i(()=>t("common.setting")),value:"TeamSet",component:p,visible:()=>!0}],{headers:x,teamId:T}=le(),u=me(),n=K(T)(),_=xe(`${de}-${T}`,I[0]?.value),S=i(()=>Object.keys(n.teamDetail).length===0),b=i(()=>I.filter(v=>v.visible())),y=i(()=>b.value.find(h=>h.value===_.value)?.component||{render:()=>null}),k=async(v,h)=>{if(!n.canSaveCopy)return;const R=v.matched[v.matched.length-1],V=h.matched[h.matched.length-1];if(!(!R||!V)&&(!v.redirectedFrom||R.path===V.path)){const U={confirmButtonText:t("team.leave"),cancelButtonText:t("common.cancel"),type:"warning"};return await Ae.confirm(t("team.unsavedDataLeave"),t("common.info"),U).then(()=>!0).catch(()=>!1)}};function A(v,h){u.addPayLoad(`/team/${v}`,{name:h??""})}return Re(k),Ve(k),Pe(()=>{n.setLoading(!0),N.v1Team.teamcontrollerDetail({headers:x}).then(v=>{const{compIdInLeafNodeMap:h}=v.data;n.setTeamDetail(v.data),n.setSelectedRowsToLeafNodeMap(h||{}),A(T??"",n.teamDetail?.name??"")}).catch(()=>{n.$reset()}).finally(()=>{n.setLoading(!1)})}),oe(_,(v,h)=>{h&&v!==h&&window?.umami?.track(pe.TEAM_TAB_CHANGE,{teamId:T,from:h,to:v})}),se(()=>{n.$reset()}),(v,h)=>{const R=Z,V=Te,U=X;return g(),E(U,{"wrap-class":"team-container p-[10px] pt-0",class:"size-full overflow-x-hidden",always:""},{default:s(()=>[a(e(Ke),{isEmpty:S.value,loading:e(n).loading,emptyDescription:e(t)("team.noTeamInfo")},{default:s(()=>[a(Tt,{class:"mt-[10px]"}),a(R,{"body-class":"!p-0",class:"sticky top-0 w-full z-100 mt-1"},{default:s(()=>[a(e(Ye),{modelValue:e(_),"onUpdate:modelValue":h[0]||(h[0]=re=>Ne(_)?_.value=re:null),options:b.value},null,8,["modelValue","options"])]),_:1}),r("div",At,[a(e(J),null,{default:s(()=>[(g(),E(ne,null,[(g(),E(H(y.value)))],1024))]),_:1})]),a(V,{right:100,bottom:100,target:".team-container"})]),_:1},8,["isEmpty","loading","emptyDescription"])]),_:1})}}});export{Yt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{v as K,F as $,C as G,N as F,ad as Y,n as z}from"./vendor-ui-BAx7vAkH.js";import{C as i,B as H,z as c,b as y}from"./index-CnTuJQbj.js";import{I as V,h as Q,aA as j,aJ as J,aG as W,E as _,aC as I,a7 as Z,Z as X,u as p,O as q,P as ee,a2 as h,Y as te,a as w,m as n,e as T,n as oe}from"./vendor-core-Do-oxgl9.js";import{c as ae,d as re,b as se}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";import{c as ne}from"./useCompEditStore-rtFXUPNg.js";import{_ as ie}from"./index.vue_vue_type_style_index_0_lang-C30OZgOy.js";import{u as ce}from"./useTeamHeaders-C1Nwzx4f.js";import{u as le}from"./useKeyword-BygMrCvJ.js";import"./index-B-fZjRMn.js";import"./useCompMetaLocalStore-DBe1Ldcg.js";import"./useCacheOssStore-B5wqgiBM.js";import"./useVscodeOpen-CJ-3bg9h.js";/* empty css */import"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";import"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./useMessage-CHhLVawp.js";/* empty css */import"./v4-EwEgHOG0.js";import"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import"./core-DIlcfMir.js";import"./PanelBackground.vue_vue_type_script_setup_true_lang-C8JwSZDA.js";import"./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js";import"./BaseBadge-DUuZfvYd.js";import"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";const pe={class:"size-full overflow-hidden"},xe=V({__name:"index",setup(me){const S=Q()?.uid,{t:a}=j(),v=J(),b=W(),{headers:m,teamId:u}=ce(),s=ae(`${v.path}_${i.SCOPE_ID_TEAM_COMP_LIST}`)();_(i.PROVIDE_KEY_COMP_LIST_STORE,s);const k=new Map;_(i.PROVIDE_KEY_CALLBACKS,k);const L=ne(v.path,i.DIALOG_TYPE_EDIT)();_(i.PROVIDE_KEY_COMP_EDIT_STORE,L);const C=re(u)(),O=I("compUpdateDialog"),R=I("compIframeContainer"),E=w([]),d=w(!1);async function P(e){d.value=!0;const o=(await c.v1Comp.compcontrollerTags({keyword:e})).data?.rows??[];E.value=o.map(r=>({value:r,label:r})),d.value=!1}const f=w({data:[],search:{column:[{prop:"keyword",component:T($),label:n(()=>a("common.keyword")),value:"",autoQuery:!1,attributes:{placeholder:n(()=>a("comp.keywordPlaceholder")),fetchSuggestions:D,triggerOnFocus:!1,style:"width: 350px",fitInputWidth:!0}},{prop:"group",component:T(G),label:n(()=>a("team.group")),value:"",attributes:{options:n(()=>C.menuGroup),clearable:!0,props:{value:"id",checkStrictly:!0}}},{prop:"tags",component:T(F),label:n(()=>a("comp.tags")),value:[],autoQuery:!1,attributes:{multiple:!0,filterable:!0,remote:!0,clearable:!0,reserveKeyword:!1,defaultFirstOption:!0,placeholder:n(()=>a("comp.pleaseInputTags")),remoteMethod:P,loading:d,options:E,style:"width: 240px"}}]},pagination:{total:0,attributes:{pageSizes:[10,20,30]}},autoLoading:!1,fetchData:M}),A=n(()=>f.value?.search?.column[0]?.value??"");le(A,R);function D(e,t){if(e.length<=1)return t([]);c.v1Keyword.keywordcontrollerQuerykeywordscomp({keyword:e,type:"compTeam"},{headers:m}).then(o=>{const{keywords:r=[]}=o.data||{};t(r)})}async function M(e){s.renderList([]),await oe(),s.setLoading(!0),e.keyword&&window?.umami?.track(y.SEARCH_COMPONENT,{keyword:e.keyword,page:"team"});const{group:t=[]}=e||{};delete e.group,t.length&&window?.umami?.track(y.TEAM_FILTER_GROUP,{teamId:u,group:t});const o=t?.[t.length-1];if(o){let l=C.getSelectedGroupLeafNodes(o);l=l.length===0?[o]:l,e.leafNodeIds=l}const r=await c.v1Team.teamcontrollerTeamcomps({...e,tags:Array.isArray(e.tags)?e.tags.join(","):e.tags||"",scene:"library"},{headers:m}),{rows:g,total:N}=r.data??{};s.renderList(g??[]),f.value.pagination.total=N??0}function U(e){b.push({path:`/previewTeam/${u}/${e}`})}async function x(e){const t=Y.service({fullscreen:!0});try{const o=e,r=await c.v1Team.teamcontrollerCheckcompupdatepermission({compId:o},{headers:m}),{result:g}=r.data||{};if(g==="cannot_update"){z.confirm(a("message.noUpdatePermission"),a("common.info"),{confirmButtonText:a("common.confirm"),cancelButtonText:a("common.cancel"),type:"warning"}).finally(()=>{});return}O.value?.open(o)}finally{t.close()}}function B(e){c.v1Comp.compcontrollerCompdetail({compId:e}).then(t=>{s.updateCompListItemById(e,t.data)})}return Z(()=>{s.$reset()}),(e,t)=>{const o=K;return X((q(),ee("div",pe,[h(p(H),{tableConfig:f.value},{table:te(()=>[h(se,{ref:"compIframeContainer",iuid:p(S),compType:p(i).IFRAME_ROUTES.CONTAINER.TEAM_ALL,onPreview:U,onUpdate:x},null,8,["iuid","compType"])]),_:1},8,["tableConfig"]),h(ie,{ref:"compUpdateDialog",onUpdateSuccess:B},null,512)])),[[o,p(s).loading]])}}});export{xe as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{I as u,O as d,P as _,a2 as r,u as f,aJ as P,E as w,f as x,Y as I,a as M,m as p}from"./vendor-core-Do-oxgl9.js";import{c as T}from"./useCompMetaLocalStore-DBe1Ldcg.js";import{C as v,E as n}from"./index-CnTuJQbj.js";import{_ as g}from"./index.vue_vue_type_script_setup_true_lang-BBmEjb-A.js";import{_ as O}from"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./vendor-ui-BAx7vAkH.js";import"./useVscodeOpen-CJ-3bg9h.js";import"./useMessage-CHhLVawp.js";const R={class:"size-full"},b=u({__name:"index",props:{version:{},compAttrs:{}},setup(a){return(l,t)=>(d(),_("div",R,[r(g,{compAttrs:a.compAttrs,version:a.version,compType:f(v).IFRAME_ROUTES.ITEM.PREVIEW_LOCAL},null,8,["compAttrs","version","compType"])]))}}),k={class:"size-full"},Y=u({__name:"index",setup(a){const l=P(),{compId:t}=l.params,e=T(t)(),h=new Map;w(v.PROVIDE_KEY_CALLBACKS,h);const o=M(!1),s=p(()=>e.detail),E=p(()=>Object.keys(s.value??{}).length>0);async function A(){if(!t)return;o.value=!0;const c=await n.comp.compcontrollerLocalcompdetailbypathhash({fullPathHash:t}),i=await n.comp.compcontrollerDep({compPath:c.data.path}),{thirdParty:m=[]}=i.data,y=m.map(L=>L.name),C=await n.module.modulecontrollerPrebuild({deps:y}),{entryNameToFile:D={}}=C.data;e.setDetail(c.data),e.setDep(m),e.setDepToFile(D),o.value=!1}return x(async()=>{await A()}),(c,i)=>(d(),_("div",k,[r(f(O),{isEmpty:!E.value,loading:o.value,class:"size-full"},{default:I(()=>[r(b,{compAttrs:s.value,version:s.value.version},null,8,["compAttrs","version"])]),_:1},8,["isEmpty","loading"])]))}});export{Y as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{v as P,a8 as A,F as x,N as K}from"./vendor-ui-BAx7vAkH.js";import{C as s,B as U,z as c,b as N}from"./index-CnTuJQbj.js";import{c as B,b as Y}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";import{_ as F}from"./index.vue_vue_type_style_index_0_lang-C30OZgOy.js";import{c as z}from"./useCompEditStore-rtFXUPNg.js";import{I as H,aA as V,h as $,aJ as Q,aG as G,E as d,aC as C,a7 as j,Z as J,u as l,O as W,P as Z,a2 as m,Y as E,a as f,m as n,e as h,n as X}from"./vendor-core-Do-oxgl9.js";import{u as q}from"./useKeyword-BygMrCvJ.js";import"./index-B-fZjRMn.js";import"./useCompMetaLocalStore-DBe1Ldcg.js";import"./useCacheOssStore-B5wqgiBM.js";import"./useVscodeOpen-CJ-3bg9h.js";import"./useTeamHeaders-C1Nwzx4f.js";import"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";/* empty css */import"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import"./useMessage-CHhLVawp.js";import"./v4-EwEgHOG0.js";/* empty css */import"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import"./core-DIlcfMir.js";import"./PanelBackground.vue_vue_type_script_setup_true_lang-C8JwSZDA.js";import"./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js";import"./BaseBadge-DUuZfvYd.js";import"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";const ee={class:"size-full p-[10px] pr-0"},Se=H({__name:"index",setup(te){const{t:i}=V(),y=$()?.uid,_=Q(),v=G(),a=B(_.path)();d(s.PROVIDE_KEY_COMP_LIST_STORE,a);const I=z(_.path,s.DIALOG_TYPE_EDIT)();d(s.PROVIDE_KEY_COMP_EDIT_STORE,I);const g=new Map;d(s.PROVIDE_KEY_CALLBACKS,g);const O=C("compUpdateDialog"),T=C("compIframeContainer"),w=f([]),u=f(!1);async function S(e){u.value=!0;const r=(await c.v1Comp.compcontrollerTags({keyword:e})).data?.rows??[];w.value=r.map(o=>({value:o,label:o})),u.value=!1}const p=f({data:[],search:{column:[{prop:"keyword",component:h(x),label:n(()=>i("common.keyword")),value:"",autoQuery:!1,attributes:{placeholder:n(()=>i("comp.keywordPlaceholder")),fetchSuggestions:k,triggerOnFocus:!1,style:"width: 350px",fitInputWidth:!0}},{prop:"tags",component:h(K),label:n(()=>i("comp.tags")),value:[],autoQuery:!1,attributes:{multiple:!0,filterable:!0,remote:!0,clearable:!0,reserveKeyword:!1,defaultFirstOption:!0,placeholder:n(()=>i("comp.pleaseInputTags")),remoteMethod:S,loading:u,options:w,style:"width: 240px"}}]},pagination:{total:0,attributes:{pageSizes:[10,20,30]}},autoLoading:!1,fetchData:R}),b=n(()=>p.value?.search?.column[0]?.value??"");q(b,T);function k(e,t){if(e.length<=1)return t([]);c.v1Keyword.keywordcontrollerQuerykeywordscomp({keyword:e,type:"compMy"}).then(r=>{const{keywords:o=[]}=r.data||{};t(o)})}async function R(e){a.renderList([]),await X(),a.setLoading(!0),e.keyword&&window?.umami?.track(N.SEARCH_COMPONENT,{keyword:e.keyword,page:"mine"});const t=await c.v1Comp.compcontrollerMycomps({...e,tags:Array.isArray(e.tags)?e.tags.join(","):e.tags||""}),{rows:r,total:o}=t.data??{};a.renderList(r??[]),p.value.pagination.total=o??0}function L(e){v.push({path:`/preview/${e}`})}async function D(e){O.value?.open(e)}function M(e){c.v1Comp.compcontrollerCompdetail({compId:e}).then(t=>{a.updateCompListItemById(e,t.data)})}return g.set(s.COMP_METHOD_KEY_AFTER_COMP_DEL,()=>{p.value.pagination.total--}),j(()=>{a.$reset()}),(e,t)=>{const r=A,o=P;return J((W(),Z("div",ee,[m(l(U),{tableConfig:p.value},{table:E(()=>[m(r,{always:"",wrapClass:"pr-[10px]"},{default:E(()=>[m(Y,{ref:"compIframeContainer",iuid:l(y),compType:l(s).IFRAME_ROUTES.CONTAINER.MINE,onPreview:L,onUpdate:D},null,8,["iuid","compType"])]),_:1})]),_:1},8,["tableConfig"]),m(F,{ref:"compUpdateDialog",onUpdateSuccess:M},null,512)])),[[o,l(a).loading]])}}});export{Se as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{_ as e}from"./index.vue_vue_type_style_index_0_lang-SpJl7c7B.js";import{I as o,O as t,P as s,a2 as a}from"./vendor-core-Do-oxgl9.js";import"./vendor-xterm-mNFjEaKn.js";import"./index-CnTuJQbj.js";import"./vendor-ui-BAx7vAkH.js";const r={class:"size-full"},d=o({__name:"index",setup(n){return(_,c)=>(t(),s("div",r,[a(e)]))}});export{d as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as C,_ as $,C as x,z as B}from"./index-CnTuJQbj.js";import{c as I,aa as R,ai as D,y as L}from"./vendor-ui-BAx7vAkH.js";import{I as k,aA as b,O as o,Q as l,Y as c,P as E,S as w,$ as _,R as y,a1 as h,u as a,a2 as v,U as M,a as S,aJ as A,aG as O,E as T,f as N,a7 as P,aC as V,ae as K,a0 as z,m as U}from"./vendor-core-Do-oxgl9.js";/* empty css */import{_ as Y}from"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import{u as g}from"./useTeamHeaders-C1Nwzx4f.js";import{c as H,b as j}from"./index.vue_vue_type_script_setup_true_lang-t73JgDYM.js";const F={class:"flex items-center justify-between px-3 py-2 select-none"},G={class:"text-sm font-medium"},J={class:"flex gap-[6px]"},Q={key:0,class:"flex-1 p-2 overflow-auto"},q=k({__name:"BasePane",props:{title:{type:String,default:""},actions:{type:Array,default:()=>["close","maximize","minimize"]}},emits:["close","maximize","minimize"],setup(t,{emit:i}){const{t:u}=b(),m=t,n=i,e=S(!1),d=S(!1);function f(){n("close")}function p(){e.value=!e.value,n("maximize",e.value)}function s(r){return m.actions.includes(r)}return(r,ee)=>(o(),l(a(R),{"body-class":"pane-body","header-class":"pane-header",class:M(["pane-card w-full h-full",{"pane-maximized":e.value}])},{header:c(()=>[y("div",F,[y("div",G,h(t.title),1),y("div",J,[w(r.$slots,"beforeActions",{},void 0,!0),s("close")?(o(),l(a(I),{key:0,type:"primary",circle:"",onClick:f},{default:c(()=>[v(a(C),{icon:"material-symbols:close"})]),_:1})):_("",!0),s("maximize")?(o(),l(a(I),{key:1,type:"primary",circle:"",title:a(u)("common.maximizeRestore"),onClick:p},{default:c(()=>[e.value?(o(),l(a(C),{key:1,icon:"material-symbols:fullscreen-exit"})):(o(),l(a(C),{key:0,icon:"material-symbols:fullscreen"}))]),_:1},8,["title"])):_("",!0)])])]),default:c(()=>[d.value?_("",!0):(o(),E("div",Q,[w(r.$slots,"default",{isMaximized:e.value},void 0,!0)]))]),_:3},8,["class"]))}}),re=$(q,[["__scopeId","data-v-96c02aae"]]),W={class:"min-h-[400px]"},X=k({__name:"index",setup(t){const i=A(),u=O(),{compId:m}=i.params,{headers:n}=g(),e=H(i.path)();T(x.PROVIDE_KEY_COMP_LIST_STORE,e);const d=new Map;T(x.PROVIDE_KEY_CALLBACKS,d);const f=async()=>{if(e.setLoading(!0),!m)return;const s=await B.v1Comp.compcontrollerSimilarcomps({compId:m},{headers:n}),{rows:r}=s.data||{};await e.renderList(r),e.setLoading(!1)};function p(s){u.push({path:`/preview/${s}`})}return N(()=>{f()}),P(()=>{e.$reset()}),(s,r)=>(o(),E("div",W,[v(j,{compType:a(x).IFRAME_ROUTES.CONTAINER.SIMILAR,onPreview:p},null,8,["compType"])]))}}),Z={ref:"similarComp",class:"mt-[10px] overflow-hidden"},le=k({__name:"index",props:{mdSrc:{type:String,default:""},compDesc:{type:String,default:""},scrollContainer:{type:String,default:""},stickyTopDistance:{type:Number,default:45},showSimilarComp:{type:Boolean,default:!0}},setup(t){const{t:i}=b(),{teamId:u}=g(),m=U(()=>i(u?"team.similarCompInTeam":"team.similarComp")),n=S(!1),e=V("similarComp");return D(e,([d])=>{n.value||(n.value=d?.isIntersecting||!1)}),(d,f)=>{const p=L,s=R;return o(),l(Y,{showToc:!0,src:t.mdSrc,scrollContainer:t.scrollContainer,stickyTopDistance:t.stickyTopDistance},K({empty:c(()=>[z(h(t.compDesc||a(i)("common.noReadme")),1)]),_:2},[t.showSimilarComp?{name:"footer",fn:c(()=>[y("div",Z,[v(p,{"content-position":"center"},{default:c(()=>[z(h(m.value),1)]),_:1}),v(s,{"body-class":"!p-1",class:"mt-[10px]"},{default:c(()=>[n.value?(o(),l(X,{key:0})):_("",!0)]),_:1})],512)]),key:"0"}:void 0]),1032,["src","scrollContainer","stickyTopDistance"])}}});export{re as B,le as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{d as v,a as w,C as L}from"./index-CnTuJQbj.js";import{c as O}from"./index-B-fZjRMn.js";import{u as G}from"./vendor-ui-BAx7vAkH.js";import{I as P,aA as k,aC as W,w as b,O as M,P as h,R as B,u as D,m}from"./vendor-core-Do-oxgl9.js";import{u as F,a as N,I as o,b as l,c as R}from"./useMessage-CHhLVawp.js";const y={class:"size-full"},U=["src"],Y=P({__name:"index",props:{compType:{},version:{},compAttrs:{},iuid:{},bgColor:{}},setup(f){const s=f,{locale:u}=k(),_=v(),T=w(),r=F(!1,window.__GLOBAL_CONFIG__.subPort),{instanceUid:E,messageListener:g,sendMessageToTargetIframe:n}=R(),{addListener:i}=g(),{createIframeParams:I}=N(),S=G().value,c=W("iframe"),A=(()=>{const e={topOrigin:window.location.origin,userId:T.userId??"",instanceUid:[E.value,s.iuid].join(",")??"",compId:s.compAttrs?._id??"",isSfc:!0},t={params:I(e),isDark:S.toString()},a=new URLSearchParams(t).toString();return`${r}/${L.WEBSITE_PATH_ITEM}/${s.compType}?${a}`})();async function d(){const e=c.value?.contentWindow;if(e){const t=O(s.compAttrs?._id)(),a=t.depEntryNameToFile[s.version],p=t.versionToFileAccessPath[s.version],C={item:s.compAttrs,depEntryNameToFile:a,versionToFileAccessPath:p};n(e,o.ITEM_INIT_SET,C,r)}}return i(o.ITEM_INIT_GET,()=>{d()}),i(o.SETTING_DATA_LEAF_GET,l(m(()=>_.deps),()=>{const e=c.value?.contentWindow;e&&n(e,o.SETTING_DATA_LEAF_SET,_.deps,r)}).triggerCallback),i(o.LOCALE_GET,()=>{const{stopWatch:e,triggerCallback:t}=l(m(()=>u.value),()=>{const a=c.value?.contentWindow;a?n(a,o.LOCALE_SET,u.value,r):e()});t()}),i(o.BG_COLOR_GET,l(m(()=>s.bgColor??""),()=>{const e=c.value?.contentWindow;e&&n(e,o.BG_COLOR_SET,s.bgColor??"",r)}).triggerCallback),b([()=>s.version,()=>s.compAttrs],async([e,t])=>{e&&t&&d()}),(e,t)=>(M(),h("div",y,[B("iframe",{ref:"iframe",class:"size-full",src:D(A),frameborder:"0"},null,8,U)]))}});export{Y as _};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
.grid-container[data-v-0e1fb53a]{display:grid;grid-template-columns:repeat(auto-fill,minmax(var(--v435dab90),1fr));gap:var(--v6971b9fd)}.list-move,.list-enter-active,.list-leave-active{transition:all .5s ease}.list-enter-from,.list-leave-to{opacity:0;transform:translate(30px)}.list-leave-active{position:absolute;width:var(--v435dab90)}.list-leave-none{display:none}.active[data-v-73844fcf]{border:1px solid #23b2c5;border-radius:8px}.el-descriptions__label.el-descriptions__cell.is-bordered-label{color:var(--el-text-color-regular);background:var(--el-descriptions-item-bordered-label-background);font-weight:700}.el-descriptions__label:not(.is-bordered-label){color:var(--el-text-color-primary);margin-right:16px}.el-descriptions__label.el-descriptions__cell:not(.is-bordered-label).is-vertical-label{padding-bottom:6px}.el-descriptions__content.el-descriptions__cell.is-bordered-content{color:var(--el-text-color-primary)}.el-descriptions__content:not(.is-bordered-label){color:var(--el-text-color-regular)}.el-descriptions--large .el-descriptions__label:not(.is-bordered-label){margin-right:16px}.el-descriptions--large .el-descriptions__label.el-descriptions__cell:not(.is-bordered-label).is-vertical-label{padding-bottom:8px}.el-descriptions--small .el-descriptions__label:not(.is-bordered-label){margin-right:12px}.el-descriptions--small .el-descriptions__label.el-descriptions__cell:not(.is-bordered-label).is-vertical-label{padding-bottom:4px}.el-descriptions{--el-descriptions-table-border:1px solid var(--el-border-color-lighter);--el-descriptions-item-bordered-label-background:var(--el-fill-color-light);box-sizing:border-box;font-size:var(--el-font-size-base);color:var(--el-text-color-primary)}.el-descriptions__header{justify-content:space-between;align-items:center;margin-bottom:16px;display:flex}.el-descriptions__title{color:var(--el-text-color-primary);font-size:16px;font-weight:700}.el-descriptions__body{background-color:var(--el-fill-color-blank)}.el-descriptions__body .el-descriptions__table{border-collapse:collapse;width:100%}.el-descriptions__body .el-descriptions__table .el-descriptions__cell{box-sizing:border-box;text-align:left;font-size:14px;line-height:23px}.el-descriptions__body .el-descriptions__table .el-descriptions__cell.is-left{text-align:left}.el-descriptions__body .el-descriptions__table .el-descriptions__cell.is-center{text-align:center}.el-descriptions__body .el-descriptions__table .el-descriptions__cell.is-right{text-align:right}.el-descriptions__body .el-descriptions__table.is-bordered .el-descriptions__cell{border:var(--el-descriptions-table-border);padding:8px 11px}.el-descriptions__body .el-descriptions__table:not(.is-bordered) .el-descriptions__cell{padding-bottom:12px}.el-descriptions--large{font-size:14px}.el-descriptions--large .el-descriptions__header{margin-bottom:20px}.el-descriptions--large .el-descriptions__header .el-descriptions__title{font-size:16px}.el-descriptions--large .el-descriptions__body .el-descriptions__table .el-descriptions__cell{font-size:14px}.el-descriptions--large .el-descriptions__body .el-descriptions__table.is-bordered .el-descriptions__cell{padding:12px 15px}.el-descriptions--large .el-descriptions__body .el-descriptions__table:not(.is-bordered) .el-descriptions__cell{padding-bottom:16px}.el-descriptions--small{font-size:12px}.el-descriptions--small .el-descriptions__header{margin-bottom:12px}.el-descriptions--small .el-descriptions__header .el-descriptions__title{font-size:14px}.el-descriptions--small .el-descriptions__body .el-descriptions__table .el-descriptions__cell{font-size:12px}.el-descriptions--small .el-descriptions__body .el-descriptions__table.is-bordered .el-descriptions__cell{padding:4px 7px}.el-descriptions--small .el-descriptions__body .el-descriptions__table:not(.is-bordered) .el-descriptions__cell{padding-bottom:8px}[data-v-163f7ee7] .el-segmented__item-label{overflow:unset}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{b as me,C as We,c as ne,f as he,B as Ce,aa as Oe,a8 as te,a5 as ge,N as je,ac as ze,a6 as Re,O as qe,as as Xe,at as Je,I as Qe,K as Ze,s as Me,u as et,w as tt,t as ot,a7 as at,S as nt}from"./vendor-ui-BAx7vAkH.js";import{_ as De,C as i,y as Pe,o as de,g as ae,z as st,p as fe,E as J,N as rt,d as lt,T as it,b as Te}from"./index-CnTuJQbj.js";/* empty css *//* empty css */import{I as B,aS as ct,O as d,Q as y,Y as s,S as Ae,aa as pt,P as N,m as h,aA as G,ak as we,R as L,a2 as p,u as c,ad as xe,aD as Ne,j as U,aC as ee,H as Q,af as Z,a0 as F,a1 as b,U as ut,aE as Ve,n as Ee,a as W,w as j,d as dt,$,aG as mt,E as _t,aF as ft,_ as Et,W as vt,h as ht,l as Ct,aB as gt}from"./vendor-core-Do-oxgl9.js";import{c as ye,p as It}from"./index-B-fZjRMn.js";import{_ as ke}from"./EmptyStatusContainer.vue_vue_type_script_setup_true_lang-CAB4mEGu.js";import{v as ve}from"./v4-EwEgHOG0.js";import{u as Tt,a as Pt,e as yt,b as X,I as Le,c as Ot}from"./useMessage-CHhLVawp.js";import{u as Fe,_ as $e,a as Dt}from"./index.vue_vue_type_style_index_0_lang-YYZCGIEM.js";import{_ as wt}from"./BaseDialog.vue_vue_type_script_setup_true_lang-DhPHn879.js";import{u as bt}from"./useVscodeOpen-CJ-3bg9h.js";import{D as At,a as Lt}from"./useTeamHeaders-C1Nwzx4f.js";import{_ as St}from"./PanelBackground.vue_vue_type_script_setup_true_lang-C8JwSZDA.js";import{_ as Rt}from"./BaseSegmented.vue_vue_type_script_setup_true_lang-D46cMrVi.js";import{B as Mt}from"./BaseBadge-DUuZfvYd.js";import{_ as xt}from"./LoadingWrapper.vue_vue_type_script_setup_true_lang-DYO0UGlK.js";const Nt={key:1,class:"grid-container"},Vt=B({__name:"GridContainer",props:{itemMinWidth:{type:Number,default:300},gap:{type:Number,default:20},useTransition:{type:Boolean,default:!0},useLeaveTransition:{type:Boolean,default:!0}},setup(T){ct(a=>({v435dab90:e.value,v6971b9fd:o.value}));const r=T,o=h(()=>r.gap+"px"),e=h(()=>r.itemMinWidth+"px");return(a,t)=>T.useTransition?(d(),y(pt,{key:0,class:"grid-container",name:"list",tag:"div","leave-active-class":T.useLeaveTransition?void 0:"list-leave-none","leave-to-class":T.useLeaveTransition?void 0:"list-leave-none"},{default:s(()=>[Ae(a.$slots,"default",{},void 0,!0)]),_:3},8,["leave-active-class","leave-to-class"])):(d(),N("div",Nt,[Ae(a.$slots,"default",{},void 0,!0)]))}}),kt=De(Vt,[["__scopeId","data-v-0e1fb53a"]]),Ft={class:"flex justify-between items-center w-full gap-1"},$t=B({__name:"PreviewPathItem",props:{modelValue:{},pathConfig:{},cascaderOptions:{},disabled:{type:Boolean}},emits:["change","view"],setup(T,{emit:r}){const o=T,e=r,{t:a}=G(),t={value:"path",label:"name"},l=h(()=>{const m=o.modelValue[o.pathConfig.pathKey];return Array.isArray(m)?m:[]}),f=h(()=>o.modelValue.activeTab===o.pathConfig.type);function C(m){e("change",m??[])}function v(){e("view")}return(m,g)=>{const u=We,w=we("Icon"),O=ne,E=me;return d(),y(E,{label:T.pathConfig.label+":",prop:T.pathConfig.prop},{default:s(()=>[L("div",Ft,[p(u,{class:"flex-1","model-value":l.value,options:T.cascaderOptions,props:t,placeholder:c(a)("comp.pleaseSelectPreviewFile"),clearable:T.pathConfig.clearable,onChange:C},null,8,["model-value","options","placeholder","clearable"]),p(O,{type:f.value?"primary":"info",circle:"",disabled:T.disabled,onClick:xe(v,["stop"])},{default:s(()=>[p(w,{icon:"material-symbols:eye-tracking"})]),_:1},8,["type","disabled"])])]),_:1},8,["label","prop"])}}}),Ut={class:"text-right"},Bt=B({__name:"Item",props:Ve({index:{}},{modelValue:{default:()=>({_id:"",desc:"",miniPath:[],fullPath:[],activeTab:i.COMP_EDIT_TAB_TYPE_MINI,miniEntryUrl:"",fullEntryUrl:""})},modelModifiers:{}}),emits:["update:modelValue"],setup(T,{expose:r}){const o={LOCAL_PREFIX:i.COMP_PREVIEW_PREFIX_LOCAL,VUE_EXTENSION:".vue"},e=T,a=Ne(T,"modelValue"),{t}=G(),l=U(i.PROVIDE_KEY_COMP_EDIT_STORE),f=ee("form"),C=h(()=>l.compCarouselIndex===m.value),v=h(()=>e.index===0),m=h(()=>l.previewList.findIndex(n=>n._id===a.value._id)),g=h(()=>l.selectedFolder?.path),u=h(()=>l.directory?Pe.mapTree(l.directory,P=>{const R=P.type==="file"&&P.name.endsWith(o.VUE_EXTENSION);return P.disabled=P.type==="file"&&!R,P}).children??[]:[]),w=h(()=>v.value?{miniPath:[{required:!0,validator:(n,P,R)=>{!P||P.length===0?R(new Error(t("comp.pleaseSelectPreviewFile"))):R()},trigger:"blur"}]}:{}),O=h(()=>[{type:i.COMP_EDIT_TAB_TYPE_MINI,label:t("comp.miniPreviewFile"),prop:v.value?"miniPath":"",pathKey:"miniPath",urlKey:"miniEntryUrl",clearable:!v.value},{type:i.COMP_EDIT_TAB_TYPE_FULL,label:t("comp.fullPreviewFile"),prop:"fullPath",pathKey:"fullPath",urlKey:"fullEntryUrl",clearable:!0}]);function E(n){if(!n.length)return"";const P=l.isOnlineUpdate||l.isAddComp,R=l.isOfflineUpdate&&l.editCompId;if(P){const Y=de.getPreviewUrl(g.value,n);return`${o.LOCAL_PREFIX}/${Y}`}return R?I(n):""}function I(n){const R=ye(l.editCompId)().latestVersionToFileAccessPath,Y=new Map(R.map(({path:ie,signedUrl:ce})=>[ie,ce])),q=ae.replaceBackslashWithSlash(n.at(-1)??"");return Y.get(q)??""}function _(n){a.value={...a.value,desc:n}}function S(){l.setCompCarouselIndex(m.value)}function D(n){a.value={...a.value,activeTab:n}}async function x(n,P){const R=P??[],Y=E(R),q={[i.COMP_EDIT_TAB_TYPE_MINI]:{miniPath:R,miniEntryUrl:Y},[i.COMP_EDIT_TAB_TYPE_FULL]:{fullPath:R,fullEntryUrl:Y}};a.value={...a.value,...q[n]},n===i.COMP_EDIT_TAB_TYPE_MINI&&v.value&&(await Ee(),f.value?.validateField("miniPath"))}function k(){a.value._id&&l.delPreviewCompItemById(a.value._id)}function z(){return f.value?.validate()}return r({validateForm:z}),(n,P)=>{const R=Ce,Y=me,q=he,ie=ne,ce=Oe;return d(),y(ce,{"body-class":"!p-0",class:ut(["cursor-pointer p-[5px] overflow-auto",{active:C.value}]),onClick:S},{default:s(()=>[p(q,{ref:"form",model:a.value,rules:w.value,"label-width":"auto"},{default:s(()=>[(d(!0),N(Q,null,Z(O.value,se=>(d(),y($t,{key:se.type,modelValue:a.value,"onUpdate:modelValue":P[0]||(P[0]=pe=>a.value=pe),"path-config":se,"cascader-options":u.value,disabled:!C.value,onChange:pe=>x(se.type,pe),onView:()=>D(se.type)},null,8,["modelValue","path-config","cascader-options","disabled","onChange","onView"]))),128)),p(Y,{label:c(t)("comp.remarkDesc")+":"},{default:s(()=>[p(R,{"model-value":a.value.desc,type:"textarea",onInput:_},null,8,["model-value"])]),_:1},8,["label"])]),_:1},8,["model","rules"]),L("div",Ut,[p(ie,{type:"danger",disabled:v.value,onClick:xe(k,["stop"])},{default:s(()=>[F(b(c(t)("common.delete")),1)]),_:1},8,["disabled"])])]),_:1},8,["class"])}}}),Gt=De(Bt,[["__scopeId","data-v-73844fcf"]]),Yt={class:"size-full overflow-auto flex flex-col gap-2 items-start"},Ht=B({__name:"index",setup(T){const{t:r}=G(),o=U(i.PROVIDE_KEY_COMP_EDIT_STORE),e=U(i.PROVIDE_KEY_CALLBACKS),a=ee("items");async function t(){if(o.previewList.length>=5){ge.error(r("comp.maxPreviewEntry",{n:5}));return}o.addPreviewCompItem({_id:ve(),miniPath:[],fullPath:[],activeTab:i.COMP_EDIT_TAB_TYPE_MINI,miniEntryUrl:"",fullEntryUrl:""}),await Ee(),o.setCompCarouselIndex(o.previewList.length-1)}function l(f){const{_id:C}=f;C&&o.updatePreviewCompItemById(C,f)}return e.set(i.COMP_METHOD_KEY_CHECK_PREVIEW_LIST_FORM,()=>{a.value?.forEach(f=>{f?.validateForm()})}),(f,C)=>{const v=ne,m=te;return d(),N("div",Yt,[p(v,{type:"primary",onClick:t},{default:s(()=>[F(b(c(r)("comp.addPreviewEntry")),1)]),_:1}),p(m,{class:"flex-1 overflow-x-hidden size-full"},{default:s(()=>[p(c(ke),{class:"size-full",isEmpty:!c(o).previewList.length,emptyDescription:c(r)("comp.pleaseAddPreviewEntry")},{default:s(()=>[p(c(kt),{"item-min-width":350},{default:s(()=>[(d(!0),N(Q,null,Z(c(o).previewList,(g,u)=>(d(),y(Gt,{ref_for:!0,ref:"items",key:g._id,index:u,"model-value":g,"onUpdate:modelValue":l},null,8,["index","model-value"]))),128))]),_:1})]),_:1},8,["isEmpty","emptyDescription"])]),_:1})])}}}),Kt={style:{color:"#909399","font-size":"12px","margin-top":"4px"}},Wt=B({__name:"ExtraInfo",setup(T){const{t:r}=G(),o=U(i.PROVIDE_KEY_COMP_EDIT_STORE),e=U(i.PROVIDE_KEY_CALLBACKS),a=ee("form"),t=W(200),l=W([...o.extraInfo.tags||[]]),f=W([]),C=W(!1);async function v(E){C.value=!0;const _=(await st.v1Comp.compcontrollerTags({keyword:E})).data?.rows??[];f.value=_.map(S=>({value:S,label:S})),C.value=!1}const m={name:[{required:!0,validator:(E,I,_)=>{if(!I)return _(new Error(r("comp.compNameRequired")));ae.validateCompName(I)?_():_(new Error(r("comp.compNameNamingRule")))},trigger:["blur"]}],description:[{required:!0,message:r("comp.remarksDescRequired"),trigger:"blur"},{min:3,max:t.value,message:r("comp.lengthBetween",{min:3,max:t.value}),trigger:"blur"}],tags:[{validator:(E,I,_)=>{if(!I||!Array.isArray(I)||I.length===0)return _();const S=ae.validateTags(I);S.valid?_():_(new Error(r(`comp.${S.error}`)))},trigger:["blur","change"]}]},g=h(()=>o.selectedFolder.basename);async function u(){await a.value?.validate()}function w(E){o.setExtraInfo({...o.extraInfo,description:E.trim()})}function O(E){o.setExtraInfo({...o.extraInfo,name:E.trim()})}return j(l,E=>{const I=ae.normalizeTags(E),_=o.extraInfo.tags||[];I.join(",")!==_.join(",")&&o.setExtraInfo({...o.extraInfo,tags:I})}),j(()=>o.extraInfo.tags,E=>{const I=E||[];I.join(",")!==l.value.join(",")&&(l.value=[...I])}),j(g,E=>{o.extraInfo.name||o.setExtraInfo({...o.extraInfo,name:E})},{immediate:!0}),e.set(i.COMP_METHOD_KEY_CHECK_EXTRA_INFO_FORM,u),(E,I)=>{const _=Ce,S=me,D=ze,x=je,k=he,z=te;return d(),y(z,{class:"size-full"},{default:s(()=>[p(k,{ref:"form","label-width":"auto",model:c(o).extraInfo,rules:m},{default:s(()=>[p(S,{label:c(r)("comp.name")+":",prop:"name"},{default:s(()=>[p(_,{maxlength:50,"show-word-limit":"","model-value":c(o).extraInfo.name,placeholder:c(r)("comp.pleaseInputCompName"),onInput:O},null,8,["model-value","placeholder"])]),_:1},8,["label"]),p(S,{label:c(r)("comp.remarksDesc")+":",prop:"description"},{default:s(()=>[p(_,{maxlength:t.value,"show-word-limit":"","model-value":c(o).extraInfo.description,placeholder:c(r)("comp.pleaseInputRemarks"),rows:4,type:"textarea",onInput:w},null,8,["maxlength","model-value","placeholder"])]),_:1},8,["label"]),p(S,{label:c(r)("comp.tags")+":",prop:"tags"},{default:s(()=>[p(x,{modelValue:l.value,"onUpdate:modelValue":I[0]||(I[0]=n=>l.value=n),multiple:"",filterable:"",remote:"","allow-create":"","default-first-option":"","reserve-keyword":!1,"remote-method":v,loading:C.value,placeholder:c(r)("comp.pleaseInputTags"),style:{width:"100%"}},{default:s(()=>[(d(!0),N(Q,null,Z(f.value,n=>(d(),y(D,{key:n.value,label:n.label,value:n.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue","loading","placeholder"]),L("div",Kt,b(c(r)("comp.tagsHelp")),1)]),_:1},8,["label"])]),_:1},8,["model"])]),_:1})}}}),jt={class:"flex items-center gap-[50px]"},zt=B({__name:"Dir",setup(T){const r={children:"children",label:"name"},o=U(i.PROVIDE_KEY_COMP_EDIT_STORE),e=W([]);return j(()=>o.directory,a=>{a?.children&&(e.value=Re(a.children))},{deep:!0,immediate:!0}),(a,t)=>{const l=qe,f=te;return d(),y(f,{class:"size-full tree-container"},{default:s(()=>[p(l,{data:e.value,props:r},{default:s(({node:C})=>[L("div",jt,[L("span",null,b(C.label),1)])]),_:1},8,["data"])]),_:1})}}}),qt={class:"flex gap-[10px] items-center justify-center"},Xt={class:"inline-block"},Jt={key:0,class:"flex items-center justify-center text-[20px] font-bold text-gray-500"},Qt={class:"inline-block"},Zt={class:"size-full flex justify-center items-center"},eo={class:"inline-block"},to={class:"flex gap-2"},oo={key:0},ao={class:"ml-auto"},no=B({__name:"Deps",setup(T){const{t:r}=G(),o=h(()=>({TITLE_LOCAL:r("comp.localDep"),TITLE_ONLINE:r("comp.onlineDep"),TITLE_FINAL:r("comp.finalDep"),LABEL_LOCAL:r("comp.localVersion"),LABEL_ONLINE:r("comp.onlineVersion"),EMPTY_ONLINE_DEPS:r("comp.onlineDepEmpty"),TAG_CONSISTENT:r("comp.versionConsistent"),TAG_CHANGE:r("comp.versionChange"),TAG_CHANGE_CONFIRMED:r("comp.versionChangeConfirmed"),TAG_ADD:r("comp.newDep"),TYPE_CONSISTENT:"consistent",TYPE_CHANGE:"change",TYPE_ADD:"add",SOURCE_LOCAL:"local",SOURCE_ONLINE:"online"})),e=U(i.PROVIDE_KEY_COMP_EDIT_STORE),a=W({}),t=h(()=>de.handleDepData(e.compDep)),l=h(()=>de.handleDepData(e.onlineCompDep)),f=h(()=>{const m={};return l.value.length===0&&e.isEditComp||t.value.forEach(g=>{const u={},w=l.value.find(O=>O.name===g.name);w?fe.isVersionEqual(g.version??"",w.version??"")?(u.selectedVersion=g.version,u.type=o.value.TYPE_CONSISTENT):(u.type=o.value.TYPE_CHANGE,u.selectedVersion=a.value[g.name]||"",u.versions=[{version:g.version,type:o.value.SOURCE_LOCAL},{version:w.version,type:o.value.SOURCE_ONLINE}]):(u.selectedVersion=a.value[g.name]||(e.isEditComp?"":g.version),u.type=o.value.TYPE_ADD,u.versions=[{version:g.version,type:o.value.SOURCE_LOCAL}]),m[g.name]=u}),m}),C=h(()=>Object.keys(l.value).length===0);function v(m,g){a.value[m]=g}return j(()=>f.value,m=>{for(const g in m){const u=m[g];u.type!==o.value.TYPE_CHANGE&&(u.type===o.value.TYPE_ADD&&e.isEditComp||(a.value[g]=u.selectedVersion))}},{immediate:!0,deep:!0}),dt(()=>{e.setAffirmCompDep(Re(a.value))}),(m,g)=>{const u=Je,w=Xe,O=Oe,E=Ze,I=Qe,_=Me,S=te;return d(),y(S,{class:"size-full"},{default:s(()=>[L("div",qt,[p(O,{"body-class":"!p-0",class:"p-[5px]"},{default:s(()=>[L("div",null,[p(w,{title:o.value.TITLE_LOCAL,column:1,border:"","label-width":"auto"},{default:s(()=>[(d(!0),N(Q,null,Z(t.value,(D,x)=>(d(),y(u,{key:x},{label:s(()=>[L("div",Xt,b(D.name),1)]),default:s(()=>[F(" "+b(D.version),1)]),_:2},1024))),128))]),_:1},8,["title"])])]),_:1}),C.value?$("",!0):(d(),N("div",Jt,"+")),C.value?$("",!0):(d(),y(O,{key:1,"body-class":"!p-0",class:"p-[5px]"},{default:s(()=>[p(c(ke),{isEmpty:C.value,class:"size-full"},{"empty-content":s(()=>[L("div",Zt,b(o.value.EMPTY_ONLINE_DEPS),1)]),default:s(()=>[p(w,{title:o.value.TITLE_ONLINE,column:1,border:"","label-width":"auto"},{default:s(()=>[(d(!0),N(Q,null,Z(l.value,(D,x)=>(d(),y(u,{key:x},{label:s(()=>[L("div",Qt,b(D.name),1)]),default:s(()=>[F(" "+b(D.version),1)]),_:2},1024))),128))]),_:1},8,["title"])]),_:1},8,["isEmpty"])]),_:1})),g[0]||(g[0]=L("div",{class:"flex items-center justify-center text-[20px] font-bold text-gray-500"},"=",-1)),p(O,{"body-class":"!p-0 !overflow-hidden",class:"p-[5px] overflow-hidden"},{default:s(()=>[p(w,{title:o.value.TITLE_FINAL,column:1,border:"","label-width":"auto"},{default:s(()=>[(d(!0),N(Q,null,Z(f.value,(D,x)=>(d(),y(u,{key:x},{label:s(()=>[L("div",eo,b(x),1)]),default:s(()=>[L("div",to,[L("div",null,[D.versions?.length?(d(),y(I,{key:1,"model-value":D.selectedVersion,size:"small",class:"ml-[10px]",onChange:k=>v(x,k)},{default:s(()=>[(d(!0),N(Q,null,Z(D.versions,k=>(d(),y(E,{key:k.version,value:k.version},{default:s(()=>[L("span",null,b(k.type===o.value.SOURCE_LOCAL?o.value.LABEL_LOCAL:o.value.LABEL_ONLINE)+" "+b(k.version),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["model-value","onChange"])):(d(),N("span",oo,b(D.selectedVersion),1))]),L("div",ao,[D.type===o.value.TYPE_CONSISTENT?(d(),y(_,{key:0,type:"info","disable-transitions":""},{default:s(()=>[F(b(o.value.TAG_CONSISTENT),1)]),_:1})):D.type===o.value.TYPE_CHANGE&&!D.selectedVersion?(d(),y(_,{key:1,type:"danger","disable-transitions":""},{default:s(()=>[F(b(o.value.TAG_CHANGE),1)]),_:1})):D.type===o.value.TYPE_CHANGE&&D.selectedVersion?(d(),y(_,{key:2,type:"success","disable-transitions":""},{default:s(()=>[F(b(o.value.TAG_CHANGE_CONFIRMED),1)]),_:1})):D.type===o.value.TYPE_ADD&&!D.selectedVersion?(d(),y(_,{key:3,type:"danger","disable-transitions":""},{default:s(()=>[F(b(o.value.TAG_ADD),1)]),_:1})):D.type===o.value.TYPE_ADD&&D.selectedVersion?(d(),y(_,{key:4,type:"success","disable-transitions":""},{default:s(()=>[F(b(o.value.TAG_ADD),1)]),_:1})):$("",!0)])])]),_:2},1024))),128))]),_:1},8,["title"])]),_:1})])]),_:1})}}}),so={class:"flex items-center gap-[4px]"},ro={key:0},lo=B({__name:"VersionInput",props:Ve({disabled:{type:Boolean},latestVersion:{}},{modelValue:{default:()=>({major:"",minor:"",patch:""})},modelModifiers:{}}),emits:["update:modelValue"],setup(T){const r=T,o=Ne(T,"modelValue"),{t:e}=G(),a=["major","minor","patch"],t={width:"60px"};function l(v){return`${v.major}.${v.minor}.${v.patch}`}function f(v,m){const g={...o.value,[m]:v},u=l(g);if(C(u)){ge.warning(e("comp.versionCannotBeLessThanLatest",{version:r.latestVersion}));return}o.value=g}function C(v){return r.latestVersion?fe.compareVersions(v,r.latestVersion)===i.VERSION_COMPARE_LESS:!1}return(v,m)=>{const g=Ce;return d(),N("div",so,[(d(),N(Q,null,Z(a,(u,w)=>(d(),N(Q,{key:u},[p(g,{"model-value":o.value[u],style:t,min:0,size:"small",type:"number",disabled:T.disabled,onInput:O=>f(O,u)},null,8,["model-value","disabled","onInput"]),w<a.length-1?(d(),N("span",ro,".")):$("",!0)],64))),64))])}}}),io={class:"flex gap-2 items-center"},co={key:0},po={class:"flex items-center gap-2"},uo={key:0},mo={class:"text-red-500"},_o=B({__name:"index",emits:["show-diff"],setup(T){const{t:r}=G(),o=U(i.PROVIDE_KEY_COMP_EDIT_STORE),e=U(i.PROVIDE_KEY_CALLBACKS),a=W({major:"",minor:"",patch:""}),t=h(()=>o.selectedFolder?.path??""),l=h(()=>o.configStatus?.compJsonPath??""),f=h(()=>o.configStatus?.entryIndexPath??""),C=h(()=>o.configStatus?.errorMsg??""),v=h(()=>o.isNeedAddVersion||o.isEditCompFileChange);async function m(){const E=await J.comp.compcontrollerCheck({compPath:t.value});o.setConfigStatus(E.data)}async function g(){await J.comp.compcontrollerGeneratecompjson({compPath:t.value});const E=await J.comp.compcontrollerDir({compPath:t.value}),{tree:I,files:_}=E.data;o.setOriginalDirectory(I),o.setOriginalDirectoryList(_),await m(),ge.success(r("common.generateSuccess"))}function u(E){const[I="1",_="0",S="0"]=E.split(".");return{major:I,minor:_,patch:S}}function w(E){const{major:I,minor:_,patch:S}=E,D=["undefined","null"];return![I,_,S].some(x=>x===""||rt.isType(x,D))}function O(E){return`${E.major}.${E.minor}.${E.patch}`}return j(a,async(E,I)=>{if(!w(E))return;const _=O(E),S=I?O(I):"";_!==S&&(await J.comp.compcontrollerUpdateversion({compPath:t.value,version:_}),await m(),o.setLocalCompVersion(_))},{deep:!0}),j(()=>o.localCompVersion,E=>{E&&(a.value=u(E))},{immediate:!0}),e.set(i.COMP_METHOD_KEY_CHECK_COMP_CONFIG,m),(E,I)=>{const _=me,S=ne,D=Me,x=he,k=te;return d(),y(k,{class:"size-full"},{default:s(()=>[p(x,{"label-width":"auto"},{default:s(()=>[p(_,{label:c(r)("comp.entryFile")+":"},{default:s(()=>[L("span",null,b(f.value),1)]),_:1},8,["label"]),p(_,{label:c(r)("comp.configFile")+":"},{default:s(()=>[L("div",io,[l.value?(d(),N("span",co,b(l.value),1)):(d(),y(S,{key:1,size:"small",onClick:g},{default:s(()=>[F(b(c(r)("common.generate")),1)]),_:1})),C.value&&l.value?(d(),y(S,{key:2,size:"small",onClick:g},{default:s(()=>[F(b(c(r)("common.regenerate")),1)]),_:1})):$("",!0)])]),_:1},8,["label"]),p(_,{label:c(r)("comp.version")+":"},{default:s(()=>[L("div",po,[p(lo,{modelValue:a.value,"onUpdate:modelValue":I[0]||(I[0]=z=>a.value=z),"latest-version":c(o).prodCompVersion,disabled:!c(o).compFileIsChange},null,8,["modelValue","latest-version","disabled"]),v.value?(d(),N("div",uo,[c(o).isNeedAddVersion?(d(),y(D,{key:0,type:"danger","disable-transitions":!0},{default:s(()=>[F(b(c(r)("comp.fileChangedNeedVersion")),1)]),_:1})):$("",!0),c(o).isEditCompFileChange?(d(),y(S,{key:1,size:"small",class:"ml-2",onClick:I[1]||(I[1]=z=>E.$emit("show-diff"))},{default:s(()=>[F(b(c(r)("comp.viewFileChanges")),1)]),_:1})):$("",!0)])):c(o).isVersionChangeButFileSame?(d(),y(D,{key:1,type:"danger","disable-transitions":!0},{default:s(()=>[F(b(c(r)("comp.versionChangedButFileSame")),1)]),_:1})):$("",!0)])]),_:1},8,["label"]),C.value?(d(),y(_,{key:0,label:c(r)("comp.errorMsg")+":"},{default:s(()=>[L("span",mo,b(C.value),1)]),_:1},8,["label"])):$("",!0)]),_:1})]),_:1})}}}),fo=B({__name:"UpgradeLog",setup(T){const{t:r}=G(),o=U(i.PROVIDE_KEY_COMP_EDIT_STORE),e=U(i.PROVIDE_KEY_CALLBACKS),a=W(200),t=ee("form"),l=h(()=>({upgradeLog:[{required:!0,message:r("comp.pleaseInputUpgradeLog"),trigger:"blur"},{min:3,max:a.value,message:r("comp.lengthBetween",{min:3,max:a.value}),trigger:"blur"}]}));function f(v){o.setUpgradeInfo({...o.upgradeInfo,upgradeLog:v})}async function C(){await t.value?.validate()}return e.set(i.COMP_METHOD_KEY_CHECK_UPGRADE_LOG_FORM,C),(v,m)=>{const g=Ce,u=me,w=te;return d(),y(w,{class:"size-full"},{default:s(()=>[p(c(he),{ref:"form","label-width":"auto",model:c(o).upgradeInfo,rules:l.value},{default:s(()=>[p(u,{label:c(r)("comp.upgradeLog")+":",prop:"upgradeLog"},{default:s(()=>[p(g,{maxlength:a.value,"show-word-limit":"","model-value":c(o).upgradeInfo.upgradeLog,placeholder:c(r)("comp.pleaseInputUpgradeLog"),rows:4,type:"textarea",onInput:f},null,8,["maxlength","model-value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model","rules"])]),_:1})}}}),Eo={class:"size-full"},vo=["src"],ho=B({__name:"index",props:{compType:{},iuid:{}},setup(T,{expose:r}){const o=T,e=U(i.PROVIDE_KEY_COMP_EDIT_STORE),a=U(i.PROVIDE_KEY_CALLBACKS),{IFRAME_POST_MESSAGE_TYPE:t}=yt,{locale:l}=G(),f=lt(),{instanceUid:C,messageListener:v,sendMessageToTargetIframe:m,requestResponse:g}=Ot(),u=Tt(!1,window.__GLOBAL_CONFIG__.subPort),{createIframeParams:w}=Pt(),{addListener:O}=v(),I=et().value,_=ee("iframe"),S=W(!1),D=h(()=>e.selectedFolder?.path),x=(()=>{const n={topOrigin:window.location.origin,instanceUid:[C.value,o.iuid].filter(Boolean).join(",")??"",isSfc:!0},P={params:w(n),isDark:I.toString()},R=new URLSearchParams(P).toString();return`${u}/${i.WEBSITE_PATH_ITEM}/${o.compType}?${R}`})();async function k(){const P=It(e.compDep,f.deps).map(q=>q.name),R=await J.module.modulecontrollerPrebuild({deps:P}),{entryNameToFile:Y={}}=R.data;return Y}O(t.COMP_PREVIEW_LIST_GET,X(h(()=>e.previewList),()=>{const n=_.value?.contentWindow;n&&m(n,t.COMP_PREVIEW_LIST_SET,e.previewList,u)}).triggerCallback),O(t.SELECTED_FOLDER_GET,X(h(()=>e.selectedFolder),()=>{const n=_.value?.contentWindow;n&&m(n,t.SELECTED_FOLDER_SET,e.selectedFolder,u)}).triggerCallback),O(t.COMP_RENDER_INFO_GET,X(h(()=>e.compDep),async()=>{const n=_.value?.contentWindow;if(n){const P=await k();m(n,t.COMP_RENDER_INFO_SET,{entryNameToFile:P,compDep:e.compDep,signedUrls:e.signedUrls},u)}}).triggerCallback),O(t.SHOW_REFRESH_BTN_GET,X(h(()=>e.isShowRefreshBtn),()=>{const n=_.value?.contentWindow;n&&m(n,t.SHOW_REFRESH_BTN_SET,e.isShowRefreshBtn,u)}).triggerCallback),O(t.IS_ONLINE_UPDATE_GET,X(h(()=>e.isOnlineUpdate),()=>{const n=_.value?.contentWindow;n&&m(n,t.IS_ONLINE_UPDATE_SET,e.isOnlineUpdate,u)}).triggerCallback),O(t.IS_ADD_GET,X(h(()=>e.isAddComp),()=>{const n=_.value?.contentWindow;n&&m(n,t.IS_ADD_SET,e.isAddComp,u)}).triggerCallback),O(t.CAROUSEL_INDEX_GET,X(h(()=>e.compCarouselIndex),()=>{const n=_.value?.contentWindow;n&&m(n,t.CAROUSEL_INDEX_SET,e.compCarouselIndex,u)}).triggerCallback),O(t.BG_COLOR_GET,X(h(()=>e.compBgColor),()=>{const n=_.value?.contentWindow;n&&m(n,t.BG_COLOR_SET,e.compBgColor,u)}).triggerCallback),O(t.COMP_EDIT_TAB_TYPE_SET,n=>{n._id&&e.updatePreviewCompItemById(n._id,n)}),O(t.ACTION_REFRESH,n=>{if(n.activeTab===i.COMP_EDIT_TAB_TYPE_MINI&&n.miniPath?.length){const P=de.getPreviewUrl(D?.value||"",n.miniPath),R=P?`${i.COMP_PREVIEW_PREFIX_LOCAL}/${P}?v=${ve()}`:"";e.updatePreviewCompItemById(n._id,{...n,miniEntryUrl:R})}if(n.activeTab===i.COMP_EDIT_TAB_TYPE_FULL&&n.fullPath?.length){const P=de.getPreviewUrl(D?.value||"",n.fullPath||[]),R=P?`${i.COMP_PREVIEW_PREFIX_LOCAL}/${P}?v=${ve()}`:"";e.updatePreviewCompItemById(n._id,{...n,fullEntryUrl:R})}}),O(t.BG_COLOR_SET,n=>{e.setCompBgColor(n)}),O(t.LOCALE_GET,()=>{const{stopWatch:n,triggerCallback:P}=X(h(()=>l.value),()=>{const R=_.value?.contentWindow;R?m(R,t.LOCALE_SET,l.value,u):n()});P()}),O(t.COMP_RENDER_ERROR_SET,({hasError:n,hasWarn:P})=>{S.value=n||P});async function z(){return(await g({targetWindow:_.value?.contentWindow,requestType:t.COMP_SCREENSHOT_REQUEST,responseType:t.COMP_SCREENSHOT_RESPONSE,data:{},targetOrigin:u}))?.screenshot||null}return r({requestScreenshot:z}),O(Le.SETTING_DATA_LEAF_GET,X(h(()=>f.deps),()=>{const n=_.value?.contentWindow;n&&m(n,Le.SETTING_DATA_LEAF_SET,f.deps,u)}).triggerCallback),j(S,n=>{n?a.set(i.COMP_METHOD_KEY_GET_COMP_ERROR,()=>!0):a.delete(i.COMP_METHOD_KEY_GET_COMP_ERROR)},{immediate:!0}),(n,P)=>(d(),N("div",Eo,[L("iframe",{ref:"iframe",class:"size-full",src:c(x),frameborder:"0"},null,8,vo)]))}}),Se=B({__name:"MarkdownPreview",props:{result:{}},setup(T){const{t:r}=G(),o=mt(),{markdownSrc:e}=Fe();function a(){const{href:t}=o.resolve({name:"mdPreview",query:{markdownSrc:e.value}});window.open(t,"_blank")}return(t,l)=>{const f=we("Icon"),C=ne,v=te;return d(),y(v,{"wrap-class":"md-container",class:"relative"},{default:s(()=>[c(e)?(d(),y(C,{key:0,type:"primary",circle:"",title:c(r)("common.newPage"),class:"absolute top-0 right-3 z-100",onClick:a},{default:s(()=>[p(f,{icon:"material-symbols:screen-share-rounded"})]),_:1},8,["title"])):$("",!0),p($e,{result:T.result,src:c(e),"show-toc":!0,scrollContainer:".md-container","is-debug":!0},null,8,["result","src"])]),_:1})}}}),Co=T=>{const{locale:r}=G();return{src:h(()=>`/${i.WEBSITE_PATH_MAIN}/md/${T.replace(".md",`.${r.value}.md`)}`)}},go={class:"h-[70vh] overflow-hidden flex flex-col"},Io={key:0,class:"flex justify-end"},To={class:"text-lg"},Po={class:"text-lg"},yo=B({__name:"index",props:{isAction:{type:Boolean,default:!0}},setup(T,{expose:r}){const{t:o}=G(),e=W(!1),{src:a}=Co("PUT_TREATY.md");let t;function l(v){e.value=!0,t=v}function f(){e.value=!1}function C(v){t?.(v),f()}return r({open:l,close:f}),(v,m)=>{const g=te,u=ne;return d(),y(c(wt),{modelValue:e.value,"onUpdate:modelValue":m[2]||(m[2]=w=>e.value=w),title:"",width:"55%","show-close":"",top:"10vh"},{default:s(()=>[L("div",go,[p(g,{class:"flex-1 flex justify-center"},{default:s(()=>[p($e,{src:c(a)},null,8,["src"])]),_:1}),T.isAction?(d(),N("div",Io,[p(u,{onClick:m[0]||(m[0]=w=>C(!1))},{default:s(()=>[L("span",To,b(c(o)("team.reject")),1)]),_:1}),p(u,{type:"primary",onClick:m[1]||(m[1]=w=>C(!0))},{default:s(()=>[L("span",Po,b(c(o)("team.agree")),1)]),_:1})])):$("",!0)])]),_:1},8,["modelValue"])}}}),Oo={class:"size-full"},Do={class:"flex justify-between mt-auto items-center p-1"},wo={class:"flex gap-2 items-center"},bo={class:"text-xs"},Ao={class:"flex-1 overflow-hidden p-2"},Lo={class:"flex justify-center p-1"},So=B({__name:"index",emits:["confirmUpload","reload"],setup(T,{emit:r}){const o=r,{t:e}=G(),a=ht(),t=U(i.PROVIDE_KEY_COMP_EDIT_STORE),l=ee("compIframeEditRef"),f=Ct(new Map);_t(i.PROVIDE_KEY_CALLBACKS,f);const C=ee("diffDialog"),v=ee("dialogPutTreaty"),{openCompPathInVscode:m}=bt(),{buildDiffTree:g}=Lt(),u=W([]),w=h(()=>t.selectedFolder?.path),O=h(()=>!t.isOnlineUpdate||!t.editCompId?null:ye(t.editCompId)()),E=h(()=>O.value?.localCompInfo[0]?.fullPath??""),I=h(()=>E.value);function _(){E.value&&m(E.value,`./${i.COMP_CONFIG_FILENAME}`)}const S=h(()=>({version:e("comp.remoteVersionPrefix")+t.prodCompVersion})),D=h(()=>({version:e("comp.localVersionPrefix")+t.localCompVersion})),{markdownSrc:x}=Fe(),k=Dt(x),z=h(()=>[{label:e("comp.previewConfig"),value:i.TAB_TYPE_PREVIEW,isDot:t.previewIsError,component:Ht,visible:()=>!0,validate:()=>t.previewIsError?{valid:!1,callbackKey:i.COMP_METHOD_KEY_CHECK_PREVIEW_LIST_FORM}:{valid:!0}},{label:e("comp.baseInfo"),value:i.TAB_TYPE_EXTRA,isDot:t.extraIsError,component:Wt,visible:()=>!0,validate:()=>t.extraIsError?{valid:!1,callbackKey:i.COMP_METHOD_KEY_CHECK_EXTRA_INFO_FORM}:{valid:!0}},{label:e("comp.checkConfig"),value:i.TAB_TYPE_CONFIG,isDot:t.configIsError,component:_o,visible:()=>t.isOnlineUpdate||t.isAddComp,validate:()=>t.configIsError?{valid:!1,callbackKey:i.COMP_METHOD_KEY_CHECK_COMP_CONFIG}:{valid:!0}},{label:e("comp.dep"),value:i.TAB_TYPE_DEPS,isDot:t.compDepIsError,component:no,visible:()=>t.isOnlineUpdate||t.isAddComp,validate:()=>t.compDepIsError?{valid:!1}:{valid:!0}},{label:e("comp.upgradeLog"),value:i.TAB_TYPE_UPGRADE_LOG,isDot:t.upgradeLogIsError,component:fo,visible:()=>t.isShowUpgradeLogTab,validate:()=>t.upgradeLogIsError?{valid:!1,callbackKey:i.COMP_METHOD_KEY_CHECK_UPGRADE_LOG_FORM}:{valid:!0}},{label:"README.md",value:i.TAB_TYPE_README,isDot:t.markdownIsError,component:Se,visible:()=>!t.isOfflineUpdate,validate:()=>t.markdownIsError?{valid:!1}:{valid:!0}},{label:e("comp.dir"),value:i.TAB_TYPE_DIR,component:zt,visible:()=>t.isOnlineUpdate||t.isAddComp}]),n=h(()=>z.value.filter(A=>A.visible?.()??!0)),P=h(()=>n.value.find(M=>M.value===t.activeName)?.component||{render:()=>null}),R=h(()=>P.value===Se?{result:k.result.value}:{});function Y(){v.value?.open()}function q(A,M){M(A),t.setCompBgColor(A??""),window?.umami?.track(Te.EDIT_BG_COLOR_CHANGE,{color:A})}function ie(A){t.setActiveName(A)}async function ce(){for(const A of f.keys())if(A.startsWith(i.COMP_METHOD_KEY_GET_COMP_ERROR)&&f.get(A)?.())return!0;return!1}async function se(A){if(A.start(),await ce()&&(t.isOnlineUpdate||t.isAddComp)){ge.error(e("message.error.pleaseFixCompileError")),A.end();return}for(const M of n.value){if(!M.validate)continue;const V=M.validate();if(!V.valid){t.setActiveName(""),await Ee(),t.setActiveName(M.value),V.callbackKey&&f.get(V.callbackKey)?.(),A.end();return}}if(t.isAddComp||t.isOnlineUpdate){const M=w.value;if(M)try{const V=await l.value?.requestScreenshot();if(V){const H=V.replace(/^data:image\/\w+;base64,/,"");await J.comp.compcontrollerWritefile({compPath:M,filename:i.COMP_SCREENSHOT_MINI_FILENAME,content:H})}}catch(V){console.error("截图写入失败,继续上传:",V)}}o("confirmUpload",{end:A.end})}async function pe(){const A=await J.comp.compcontrollerCheck({compPath:w.value});t.setConfigStatus(A.data)}async function Ue(){const M=(t.originalDirectory.children||[]).find(K=>K.name===i.COMP_CONFIG_FILENAME);if(!M)return;const V=await J.comp.compcontrollerFile({filePath:M.path}),{content:H}=V.data,oe=JSON.parse(H);t.setLocalCompVersion(oe.version)}async function Be(){await Ie(),u.value=be(),await Ee(),C.value?.open(),window?.umami?.track(Te.EDIT_VIEW_DIFF,{compPath:w.value})}async function Ge(){await Ie(),u.value=be()}function be(){const A=t.localDirectory?.children??[],M=t.onlineDirectory?.children??[],H=ye(t.editCompId)().latestVersionToFileAccessPath,oe=w.value.replace(i.FILE_MANAGER_DIRNAME,"");return g(M,A,K=>H.find(re=>re.path===K)?.signedUrl??"",K=>`${i.COMP_PREVIEW_PREFIX_LOCAL}/${oe}${K}`)}async function Ie(){const A=await J.comp.compcontrollerDir({compPath:w.value}),{tree:M,files:V}=A.data;t.setOriginalDirectory(M),t.setOriginalDirectoryList(V)}function Ye(){o("reload")}return j(()=>t.originalDirectory,async()=>{await Ue()},{immediate:!0,deep:!0}),j(()=>w.value,async(A,M)=>{A===M||!A||(await Ie(),await pe())},{immediate:!0}),j(k.result,A=>{if(!A)return;const{headings:M=[]}=A;if(M.length){const V=M.every(H=>{const oe=H.tokens.map(re=>re?.text||"").join(""),{valid:K}=ae.validateHash(oe);return K});t.setMarkdownValid(V)}}),(A,M)=>{const V=we("Icon"),H=at,oe=nt,K=Oe,re=ot,He=ne,Ke=tt;return d(),N("div",Oo,[p(Ke,{class:"size-full",layout:"vertical"},{default:s(()=>[p(re,{class:"size-full",size:"50%",min:300},{default:s(()=>[p(K,{"body-class":"!p-0",class:"size-full"},{default:s(()=>[p(c(St),{class:"size-full flex flex-col",bg:c(t).compBgColor},{default:s(({bg:le,updateColor:_e})=>[p(ho,{ref_key:"compIframeEditRef",ref:l,class:"flex-1",compType:c(i).IFRAME_ROUTES.ITEM.EDIT_PANEL,iuid:c(a)?.uid},null,8,["compType","iuid"]),L("div",Do,[L("div",wo,[c(t).isOnlineUpdate||c(t).isAddComp?(d(),y(H,{key:0,title:c(e)("comp.reload"),class:"ml-2",type:"primary",underline:"always",onClick:Ye},{default:s(()=>[p(V,{icon:"material-symbols:frame-reload",height:c(i).COMP_ACTION_ICON_HEIGHT},null,8,["height"])]),_:1},8,["title"])):$("",!0),p(H,{title:c(e)("comp.uploadProtocol"),type:"primary",underline:"always",onClick:M[0]||(M[0]=ue=>Y())},{default:s(()=>[p(V,{icon:"material-symbols:docs",height:c(i).COMP_ACTION_ICON_HEIGHT},null,8,["height"])]),_:1},8,["title"]),c(t).isOnlineUpdate&&E.value?(d(),y(H,{key:1,title:E.value,type:"primary",underline:"always",class:"text-xs",onClick:_},{default:s(()=>[F(b(I.value),1)]),_:1},8,["title"])):$("",!0)]),L("div",bo,[L("span",null,b(c(e)("comp.bgPanel"))+":",1),p(oe,{modelValue:le,clearable:"",onChange:ue=>q(ue,_e),onActiveChange:ue=>q(ue,_e)},null,8,["modelValue","onChange","onActiveChange"])])])]),_:1},8,["bg"])]),_:1})]),_:1}),p(re,{class:"size-full",collapsible:""},{default:s(()=>[p(K,{"body-class":"!p-0 flex flex-col",class:"size-full"},{default:s(()=>[p(K,{"body-class":"!p-0"},{default:s(()=>[p(c(Rt),{"model-value":c(t).activeName,options:n.value,onChange:ie},{default:s(({item:le})=>[p(c(Mt),{"is-dot":le.isDot},{default:s(()=>[F(b(le.label),1)]),_:2},1032,["is-dot"])]),_:1},8,["model-value","options"])]),_:1}),L("div",Ao,[p(c(it),null,{default:s(()=>[(d(),y(ft,null,[(d(),y(Et(P.value),vt(R.value,{onShowDiff:Be}),null,16))],1024))]),_:1})]),L("div",Lo,[p(c(xt),null,{default:s(({instance:le,loading:_e})=>[p(He,{id:c(Te).UPLOAD_CONFIRM,loading:_e,type:"primary",class:"w-[200px]",round:"",onClick:ue=>se(le)},{default:s(()=>[F(b(c(t).compSubmitBtnText),1)]),_:1},8,["id","loading","onClick"])]),_:1})])]),_:1})]),_:1})]),_:1}),p(yo,{ref:"dialogPutTreaty",isAction:!1},null,512),u.value.length?(d(),y(c(At),{key:0,ref:"diffDialog",resultTree:u.value,oldMeta:S.value,newMeta:D.value,onRefresh:Ge},null,8,["resultTree","oldMeta","newMeta"])):$("",!0)])}}}),qo=De(So,[["__scopeId","data-v-163f7ee7"]]),Xo=(T,r)=>{const{t:o}=G();return gt(`compEdit_${T}`,{state:()=>({scopeId:T,extraInfo:{},upgradeInfo:{},previewList:[],compDep:[],onlineCompDep:[],affirmCompDep:{},activeName:"preview",compCarouselIndex:0,selectedFolder:{},originalDirectory:{},originalDirectoryList:[],compDialogType:r??"",editCompId:"",compBgColor:"",configStatus:{},compDetail:{},localCompHash:"",remoteCompHash:"",localCompVersion:"",loading:!1,compUpdateType:"",signedUrls:[],markdownValid:!0}),getters:{isInitState:e=>e.compDialogType.trim()==="",isEditComp:e=>e.compDialogType===i.DIALOG_TYPE_EDIT,isAddComp:e=>e.compDialogType===i.DIALOG_TYPE_ADD,isOnlineUpdate:e=>e.compUpdateType===i.COMP_UPDATE_TYPE_ONLINE,isOfflineUpdate:e=>e.compUpdateType===i.COMP_UPDATE_TYPE_OFFLINE,isShowRefreshBtn(){return this.isOnlineUpdate||this.isAddComp},prodCompVersion:e=>e.compDetail?.version||"",versionCompareResult(){return!this.localCompVersion||!this.prodCompVersion?i.VERSION_COMPARE_GREATER:fe.compareVersions(this.localCompVersion,this.prodCompVersion)},isEditCompFileChange(){return this.compFileIsChange&&this.isEditComp},isNeedAddVersion(){return this.versionCompareResult!==1&&this.isEditCompFileChange},compSubmitBtnText(){return this.isEditComp?o("comp.update"):this.isAddComp?o("comp.upload"):""},previewIsError(e){return this.isInitState||this.loading?!1:!e.previewList[0]?.miniPath?.length},configIsException:e=>{const{errorMsg:a}=e.configStatus;return!!a},configIsError(){return this.isInitState||this.loading||this.isOfflineUpdate?!1:!!(this.isNeedAddVersion||this.configIsException||this.isVersionChangeButFileSame)},extraIsError(e){if(this.isInitState||this.loading)return!1;const a=e.extraInfo.name?.trim()||"";if((e.extraInfo?.description||"").length<3||!ae.validateCompName(a))return!0;const l=e.extraInfo.tags;return!!(l&&l.length>0&&!ae.validateTags(l).valid)},compDepIsError(e){if(!e.onlineCompDep.length||this.isOfflineUpdate)return!1;let a=!1;return e.compDep.forEach(t=>{const l=e.onlineCompDep.find(v=>v.name===t.name),f=e.affirmCompDep[t.name]??e.affirmCompDep[t?.parent?.name??""];!(l?.version&&fe.isVersionEqual(t?.version,l.version))&&!f&&(a=!0)}),a},compFileIsChange:e=>e.localCompHash!==e.remoteCompHash,isVersionChangeButFileSame(){return this.versionCompareResult!==i.VERSION_COMPARE_SAME&&!this.compFileIsChange&&this.isEditComp},isShowUpgradeLogTab(e){return this.isInitState||this.loading?!1:!!(this.compFileIsChange&&e.editCompId)},upgradeLogIsError(e){if(this.isOfflineUpdate)return!1;const a=e.upgradeInfo?.upgradeLog||"",t=this.versionCompareResult===i.VERSION_COMPARE_GREATER;return(a.length||0)<3&&(this.compFileIsChange||t)&&this.isEditComp},markdownIsError(e){return this.hasMdFile?!e.markdownValid:!1},affirmCompDepVersion:e=>e.compDep.map(a=>{const t=e.affirmCompDep[a.name],l=e.affirmCompDep[a?.parent?.name??""],f=t??l??a.version,C=a.parent?{parent:{...a.parent,version:f}}:{};return{...a,version:f,...C}}),localDirectory:e=>{const{srcPath:a,sep:t}=window.__GLOBAL_CONFIG__,l=e.selectedFolder.path;if(!l||Object.keys(e.originalDirectory).length===0)return null;const f=l.replace(i.FILE_MANAGER_DIRNAME,"").replaceAll("/",t);return Pe.mapTree(e.originalDirectory,v=>(v.path=v.path.replace(`${a}${t}${f}`,""),v))},onlineDirectory:e=>e.compDetail.files?.length?Pe.convertFlatToTree(e.compDetail.files,{pathSeparator:"\\",createNode:(a,t,l)=>({name:t,path:l.startsWith("\\")?l:"\\"+l,type:a,children:[]})}):null,directory(){return this.localDirectory?this.localDirectory:this.onlineDirectory},hasMdFile(){return this.directory?.children?.find(e=>e.name===i.COMP_README_FILENAME)!==void 0}},actions:{setMarkdownValid(e){this.$patch({markdownValid:e})},setSignedUrls(e){this.$patch({signedUrls:e})},setCompUpdateType(e){this.$patch({compUpdateType:e})},setLocalCompVersion(e){this.$patch({localCompVersion:e})},setOriginalDirectory(e){this.$patch({originalDirectory:e})},setOriginalDirectoryList(e){this.$patch({originalDirectoryList:e})},setLoading(e){this.$patch({loading:e})},setLocalCompHash(e){this.$patch({localCompHash:e})},setRemoteCompHash(e){this.$patch({remoteCompHash:e})},setCompDetail(e){this.$patch({compDetail:e})},setUpgradeInfo(e){this.$patch({upgradeInfo:e})},setConfigStatus(e){this.$patch({configStatus:e})},setExtraInfo(e){this.$patch({extraInfo:e})},addPreviewCompItem(e){this.$patch(a=>{a.previewList.push(e)})},delPreviewCompItemById(e){this.$patch(a=>{a.previewList=a.previewList.filter(t=>t._id!==e)})},setPreviewCompList(e){this.$patch({previewList:e})},updatePreviewCompItemById(e,a){this.$patch(t=>{const l=t.previewList.findIndex(f=>f._id===e);l!==-1&&(t.previewList[l]=a)})},initPreviewCompList(){this.$patch(e=>{e.compDialogType===i.DIALOG_TYPE_ADD&&(e.previewList=[{_id:ve(),miniPath:[],fullPath:[],activeTab:i.COMP_EDIT_TAB_TYPE_MINI,miniEntryUrl:"",fullEntryUrl:""}])})},setCompDep(e){this.$patch({compDep:e})},setOnlineCompDep(e){this.$patch({onlineCompDep:e})},setAffirmCompDep(e){this.$patch({affirmCompDep:e})},setActiveName(e){this.$patch({activeName:e})},setCompCarouselIndex(e){this.$patch({compCarouselIndex:e})},setSelectedFolder(e){this.$patch({selectedFolder:e})},setEditCompId(e){this.$patch({editCompId:e})},setCompBgColor(e){this.$patch({compBgColor:e})},getCompSubmitParams(){if(this.extraIsError)throw new Error("组件信息不完整,请检查组件名称和描述");if(this.previewIsError)throw new Error("预览配置不完整,请检查预览配置");if(this.configIsError)throw new Error("配置检查未通过,请检查配置");const e=this.selectedFolder.path,{name:a,description:t,tags:l}=this.extraInfo,f=this.previewList.map(m=>({miniPath:m.miniPath,fullPath:m.fullPath,desc:m?.desc||""})),C=this.upgradeInfo?.upgradeLog??"",v=this.isEditComp?{upgradeDesc:C}:{};return{compPath:e,dep:this.affirmCompDepVersion,name:a,desc:t,previewConfigs:f,bgColor:this.compBgColor,tags:l,...v}}}})};export{qo as C,yo as _,Xo as c,Co as u};
|