decocms 4.446.1 → 4.447.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/client/assets/{AlertCircle-CQA_p2Cp.js → AlertCircle-O5yKT_wD.js} +1 -1
- package/dist/client/assets/{AreaChart-94A56lku.js → AreaChart-DOBe6b77.js} +1 -1
- package/dist/client/assets/{ArrowLeft-Dl_7c8AB.js → ArrowLeft-Bgwvgp7N.js} +1 -1
- package/dist/client/assets/{ArrowUp-0DU20WU2.js → ArrowUp-BcguyIxa.js} +1 -1
- package/dist/client/assets/{Building02-CsHqQGTj.js → Building02-DXskyQyV.js} +1 -1
- package/dist/client/assets/{CartesianChart-OVjYagl6.js → CartesianChart-Dxs56jW8.js} +1 -1
- package/dist/client/assets/{Check-Bo3qSXwJ.js → Check-BwZg9K6a.js} +1 -1
- package/dist/client/assets/{CheckCircle-BCxvtn62.js → CheckCircle-B8nBZ9lR.js} +1 -1
- package/dist/client/assets/{ChevronUp-Ds84QUAn.js → ChevronUp-XuQjQLoK.js} +1 -1
- package/dist/client/assets/{Copy01-QNdLW2v3.js → Copy01-YmLU_wow.js} +1 -1
- package/dist/client/assets/{CreditCard01-D1KkCG7o.js → CreditCard01-CwEdzwSq.js} +1 -1
- package/dist/client/assets/{DotsVertical-Dyi1_2jC.js → DotsVertical-DEYhHh-q.js} +1 -1
- package/dist/client/assets/{ErrorBarContext-Dckliguf.js → ErrorBarContext-CoXkTI3v.js} +1 -1
- package/dist/client/assets/{Image01-0Rs0fG3a.js → Image01-DFTuvWJV.js} +1 -1
- package/dist/client/assets/{Key01-DvlZjbjO.js → Key01-CW5AmBXO.js} +1 -1
- package/dist/client/assets/{Line-BZPiXXVf.js → Line-w53GBlC_.js} +1 -1
- package/dist/client/assets/{Link01-3DcN1bgm.js → Link01-rblrB3OI.js} +1 -1
- package/dist/client/assets/{LinkBroken01-8QjnprbC.js → LinkBroken01-cRHkOCv3.js} +1 -1
- package/dist/client/assets/{LinkExternal01-CLN31q0P.js → LinkExternal01-DMr7xmMD.js} +1 -1
- package/dist/client/assets/{Monitor01-C0xXEFc5.js → Monitor01-DRRgoSgd.js} +1 -1
- package/dist/client/assets/{Palette-CaoJ793n.js → Palette-BLSfhg5D.js} +1 -1
- package/dist/client/assets/{Plus-DUwLVLW_.js → Plus-B7fu2HeJ.js} +1 -1
- package/dist/client/assets/{SearchMd-BiNHdvMf.js → SearchMd-DpRsJH0P.js} +1 -1
- package/dist/client/assets/{Sector-DrcdpRCF.js → Sector-DUcOKKda.js} +1 -1
- package/dist/client/assets/{ShoppingBag01-BlgcPhxp.js → ShoppingBag01-Bn_Ml-RN.js} +1 -1
- package/dist/client/assets/{Sun-aSGS3XrK.js → Sun-JyTPOz6f.js} +1 -1
- package/dist/client/assets/{Tool01-BuLiX0jy.js → Tool01-TfY7iJsP.js} +1 -1
- package/dist/client/assets/{Trash01-DtMJF0U3.js → Trash01-DBoWC6W0.js} +1 -1
- package/dist/client/assets/{Upload01-C2lcKrsy.js → Upload01-oBIhuFXz.js} +1 -1
- package/dist/client/assets/{User01-DmaMR1Ca.js → User01-DlDKGoyi.js} +1 -1
- package/dist/client/assets/{UserSquare-B0WZmX6s.js → UserSquare-Cij4gM7j.js} +1 -1
- package/dist/client/assets/{Users01-C8SJUk8C.js → Users01-B0qqt-bB.js} +1 -1
- package/dist/client/assets/{X-BO04Dn0R.js → X-B1izQ1KV.js} +1 -1
- package/dist/client/assets/{XAxis-DjkUxR47.js → XAxis-CxP14qz_.js} +1 -1
- package/dist/client/assets/{XClose-DwKTRWak.js → XClose-B1wwChfA.js} +1 -1
- package/dist/client/assets/{ZoomOut-hhnEYknp.js → ZoomOut-Cy6sSJWj.js} +1 -1
- package/dist/client/assets/{access-gate-g4Ol-Lnp.js → access-gate-DvGFBZwA.js} +1 -1
- package/dist/client/assets/{add-connection-dialog-BB1INtAa.js → add-connection-dialog-1TbuXfcy.js} +1 -1
- package/dist/client/assets/{agent-analytics-UbMmc2xM.js → agent-analytics-CVvlpC2h.js} +1 -1
- package/dist/client/assets/agent-app-CdSOzSAf.js +1 -0
- package/dist/client/assets/{agent-assets-DFJmMVeP.js → agent-assets-dT4w7KXp.js} +1 -1
- package/dist/client/assets/{agent-automation-gh60EKv-.js → agent-automation-QQcgGJrd.js} +1 -1
- package/dist/client/assets/{agent-automations-Cyb-cCIs.js → agent-automations-DYCzMC9n.js} +1 -1
- package/dist/client/assets/{agent-connect-sources-C93dhycr.js → agent-connect-sources-BH2pAvk9.js} +1 -1
- package/dist/client/assets/agent-deck-CepgSTaG.js +1 -0
- package/dist/client/assets/{agent-e2e-CRjvTqPc.js → agent-e2e-CE4P7SOm.js} +1 -1
- package/dist/client/assets/{agent-experiments-Od-fEEVw.js → agent-experiments-Cvf_GoyJ.js} +1 -1
- package/dist/client/assets/{agent-file-Uip3fQYD.js → agent-file-2ITxF0Ae.js} +1 -1
- package/dist/client/assets/{agent-git-BJ3uVxrR.js → agent-git-CaE7XjIB.js} +1 -1
- package/dist/client/assets/{agent-hosting-Cpk5ThRL.js → agent-hosting-JmwTdK6y.js} +1 -1
- package/dist/client/assets/{agent-icon-C8zn459s.js → agent-icon-DebFssce.js} +1 -1
- package/dist/client/assets/agent-library-DszZ1exI.js +1 -0
- package/dist/client/assets/agent-library-file-B9vfOl4A.js +1 -0
- package/dist/client/assets/{agent-monitor-DKWpCvbH.js → agent-monitor-IbBmqvCt.js} +1 -1
- package/dist/client/assets/{agent-overview-C0CBjtgK.js → agent-overview-BwNdPBpC.js} +1 -1
- package/dist/client/assets/agent-settings-Cui7mNtr.js +1 -0
- package/dist/client/assets/{agent-site-editor-C9GivBz_.js → agent-site-editor-C8eLBttq.js} +1 -1
- package/dist/client/assets/agent-site-editor-code-Y8Sm7eAb.js +2 -0
- package/dist/client/assets/{agent-site-editor-content-CGWvdS7C.js → agent-site-editor-content--b4gLs1h.js} +3 -3
- package/dist/client/assets/{agent-site-editor-preview-TbwhHm-5.js → agent-site-editor-preview-BZZnLQZf.js} +3 -3
- package/dist/client/assets/agent-view-BOncsgwo.js +1 -0
- package/dist/client/assets/{agent-view-guard-CYaQjfk2.js → agent-view-guard-B4uVbmma.js} +1 -1
- package/dist/client/assets/{agents-list-BhjRlvRY.js → agents-list-CwdDMmy-.js} +1 -1
- package/dist/client/assets/{ai-providers-UcNEAf_J.js → ai-providers-D2O1ixBz.js} +1 -1
- package/dist/client/assets/{alert-DwmQ7qtd.js → alert-CqDdaXWn.js} +1 -1
- package/dist/client/assets/{alert-dialog-zI-mFpSQ.js → alert-dialog-BaW-BGF4.js} +1 -1
- package/dist/client/assets/{analytics-sections-rNV5HZ50.js → analytics-sections-D61Wwl8L.js} +1 -1
- package/dist/client/assets/api-keys-DQSpTJNt.js +1 -0
- package/dist/client/assets/{api-keys-sSvDZG99.js → api-keys-wNYNv40Y.js} +1 -1
- package/dist/client/assets/app-editor-BS446zS8.js +1 -0
- package/dist/client/assets/{asset-utils-C3FMP3nb.js → asset-utils-D3olPYx7.js} +1 -1
- package/dist/client/assets/{auth-DQuDCDTH.js → auth-CABZOlQ0.js} +1 -1
- package/dist/client/assets/{auth-catchall-BTTBnKvo.js → auth-catchall-qhf0Gqyx.js} +1 -1
- package/dist/client/assets/{auth-entry-XM1FbOYg.js → auth-entry-nJBLD0Y2.js} +1 -1
- package/dist/client/assets/{auth-split-layout-mHJ8Mnv8.js → auth-split-layout-P-3F6VoK.js} +1 -1
- package/dist/client/assets/{authenticate-and-persist-oauth--Ui7uUW3.js → authenticate-and-persist-oauth-DBd5KhOF.js} +1 -1
- package/dist/client/assets/{automation-list-row-Cph_qNFz.js → automation-list-row-B2m3VUdV.js} +1 -1
- package/dist/client/assets/{automation-runs-Bk7987tn.js → automation-runs-BGWmky8f.js} +1 -1
- package/dist/client/assets/{automations-BusQTRzA.js → automations-C4fgolau.js} +1 -1
- package/dist/client/assets/{autosend-B7xOxZCV.js → autosend-BkG_BHpj.js} +1 -1
- package/dist/client/assets/{avatar-BxSXBdTP.js → avatar-C70_Ki0z.js} +1 -1
- package/dist/client/assets/{badge-Bkod8faG.js → badge-D10nU5hm.js} +1 -1
- package/dist/client/assets/{block-document-CFi5j69X.js → block-document-D3BljOLs.js} +1 -1
- package/dist/client/assets/{blocks-preview-workspace-context-CNAK__es.js → blocks-preview-workspace-context-DDuiEZgT.js} +1 -1
- package/dist/client/assets/{buckets-8h9eIrQM.js → buckets-B2U9XBuC.js} +1 -1
- package/dist/client/assets/{build-improve-prompt-doc-BbWygkjj.js → build-improve-prompt-doc-Cjucl5Ml.js} +1 -1
- package/dist/client/assets/{calendar-BL2c1BVO.js → calendar-BF7zRWf5.js} +1 -1
- package/dist/client/assets/{capability-load-error-AIgwu68M.js → capability-load-error-CI6r2eSt.js} +1 -1
- package/dist/client/assets/{category-editor-By6DtwpQ.js → category-editor-BPgoNKbj.js} +1 -1
- package/dist/client/assets/{chart-NHKhTpOL.js → chart-BkrO3MsD.js} +1 -1
- package/dist/client/assets/{chat-context-CvEgaFCN.js → chat-context-Crr9YCN0.js} +1 -1
- package/dist/client/assets/{chat-draft-jBRWjVIJ.js → chat-draft-BkkmQZdS.js} +1 -1
- package/dist/client/assets/{checkbox-DM1zG_bR.js → checkbox-CAXlLvHp.js} +1 -1
- package/dist/client/assets/{choose-editor-DXMPbOcS.js → choose-editor-CXZPe8wI.js} +1 -1
- package/dist/client/assets/{claim-phase-copy-DOJxxCtG.js → claim-phase-copy-DZ3Yirir.js} +1 -1
- package/dist/client/assets/{cli-auth-success-RzErssq7.js → cli-auth-success-BVdFv3bm.js} +1 -1
- package/dist/client/assets/{client-icons-CpN46V1K.js → client-icons-DrzfFqzQ.js} +1 -1
- package/dist/client/assets/{collapsible-DckFjvhZ.js → collapsible-CKOvtNeB.js} +1 -1
- package/dist/client/assets/{collection-detail-BhrjxRoz.js → collection-detail-DnoqLlcG.js} +1 -1
- package/dist/client/assets/{collection-display-button-B4IWBje6.js → collection-display-button-bxkLloWp.js} +1 -1
- package/dist/client/assets/{collection-search-Cp0gVUrY.js → collection-search-DZ1wZYuR.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-Bww62NEV.js → collection-table-wrapper-DjNNBLdq.js} +1 -1
- package/dist/client/assets/{collection-tabs-DujOg3C7.js → collection-tabs-Y0ynVKEj.js} +1 -1
- package/dist/client/assets/{column-rules-DjRlzWHk.js → column-rules-DQX2ptJC.js} +1 -1
- package/dist/client/assets/{combobox-2qhSjEFr.js → combobox-DfBcz1Tb.js} +1 -1
- package/dist/client/assets/{command-ZBxh5GnQ.js → command-BUcXz1jA.js} +1 -1
- package/dist/client/assets/{companion-mcps-section-CDnsqeV6.js → companion-mcps-section-DbjKMv-Y.js} +1 -1
- package/dist/client/assets/{config-DK92N2N0.js → config-DaCobjNE.js} +1 -1
- package/dist/client/assets/{connect-lp3YwtIU.js → connect-CPjoHilW.js} +1 -1
- package/dist/client/assets/{connect-layout-BmKB0MQt.js → connect-layout-K_gPt_sp.js} +1 -1
- package/dist/client/assets/{connection-Bw7PTYac.js → connection-D4h25APd.js} +1 -1
- package/dist/client/assets/{connection-card-BE5DxUWL.js → connection-card-XwOnt1f0.js} +1 -1
- package/dist/client/assets/{connection-detail-D4H16vJ0.js → connection-detail-D4tkjBck.js} +1 -1
- package/dist/client/assets/{connection-form-helpers-B0fzrlcU.js → connection-form-helpers-MMq14fzZ.js} +1 -1
- package/dist/client/assets/{connections-D_QAyydr.js → connections-BzC5bqYg.js} +1 -1
- package/dist/client/assets/{context-0yOwY8Xe.js → context-0fIuzLTM.js} +1 -1
- package/dist/client/assets/{context-menu-CzHrYgyK.js → context-menu-Bl0G1UDO.js} +1 -1
- package/dist/client/assets/{create-organization-dialog-uaygtZt_.js → create-organization-dialog-CFcjJ3cx.js} +1 -1
- package/dist/client/assets/{daily-pulse-DQNDzVjv.js → daily-pulse-Dus-woVV.js} +1 -1
- package/dist/client/assets/{decopilot-BdkjG-bD.js → decopilot-4kqD0JAa.js} +1 -1
- package/dist/client/assets/{device-hint-D3ZO4Iw7.js → device-hint-BcqeJvfC.js} +1 -1
- package/dist/client/assets/{dialog-DC6TmMkf.js → dialog-C_zHR8DK.js} +1 -1
- package/dist/client/assets/{discover-BLKvCoGk.js → discover-Djz6Veha.js} +1 -1
- package/dist/client/assets/{domain-settings-BVxXQdaO.js → domain-settings-CFO7Yfbv.js} +1 -1
- package/dist/client/assets/{download-app-dialog-CEx38Fcv.js → download-app-dialog-UTCmHANJ.js} +1 -1
- package/dist/client/assets/{drawer-BUMMA5sr.js → drawer-CeyU31cS.js} +1 -1
- package/dist/client/assets/{editor-CJUNgGBw.js → editor-DEzZHfDd.js} +1 -1
- package/dist/client/assets/{empty-state-ftdhK3Qw.js → empty-state-2X05DwZp.js} +1 -1
- package/dist/client/assets/{empty-state-CDvZ4pSZ.js → empty-state-BrxgsLHG.js} +1 -1
- package/dist/client/assets/{extract-connection-data-VVSQT7HS.js → extract-connection-data-DZSiJSCE.js} +1 -1
- package/dist/client/assets/{feature-gate-BYR6DKao.js → feature-gate-BweFNKr3.js} +1 -1
- package/dist/client/assets/{feature-paywall-Pv-riKE7.js → feature-paywall-DCy88YOr.js} +1 -1
- package/dist/client/assets/{file-explorer-BpCZxL2W.js → file-explorer-E1QpuooZ.js} +1 -1
- package/dist/client/assets/{file-preview-C_Ah7YRc.js → file-preview-BFYm2Ebl.js} +1 -1
- package/dist/client/assets/{file-share-button-C8uAgffH.js → file-share-button-BNECzHpC.js} +1 -1
- package/dist/client/assets/{file-type-icon-CQEUNMAM.js → file-type-icon-D0M-S9U1.js} +1 -1
- package/dist/client/assets/flat-project-Y-2R_KpZ.js +1 -0
- package/dist/client/assets/{folder-icon-B1vzKX5d.js → folder-icon-CSGYfuW8.js} +1 -1
- package/dist/client/assets/{form-R8MW_Gtw.js → form-BGxoVGvb.js} +1 -1
- package/dist/client/assets/{gateway-client-Dv4XJFUM.js → gateway-client-DqqeM3yS.js} +1 -1
- package/dist/client/assets/{general-CtUtUhHu.js → general--Lx4oqfC.js} +1 -1
- package/dist/client/assets/{home-DV_eNq6b.js → home-DyM_cAvs.js} +1 -1
- package/dist/client/assets/{icon-button-Blj1QpLb.js → icon-button-BAAffUhi.js} +1 -1
- package/dist/client/assets/{index-Bpt0MDIX.js → index-BVzkdynM.js} +1 -1
- package/dist/client/assets/{index-XL6-vv-o.js → index-B_Hj8ygS.js} +1 -1
- package/dist/client/assets/{index-CE-LgiHP.js → index-BxML1xBj.js} +1 -1
- package/dist/client/assets/{index--FVWSK_c.js → index-CJflvpaj.js} +1 -1
- package/dist/client/assets/{index-CM8cxFEW.js → index-CcuAAQfR.js} +1 -1
- package/dist/client/assets/{index-Ck6X-2qm.js → index-CpFVLV3H.js} +1 -1
- package/dist/client/assets/{index-CZDhy56e.js → index-CpuEtEqc.js} +3 -3
- package/dist/client/assets/{index-CwSrznSB.js → index-D-s3ZvIF.js} +1 -1
- package/dist/client/assets/{index-BE867Qee.js → index-D3VyLkC3.js} +3 -3
- package/dist/client/assets/{index-6OICj4ln.js → index-DXhMSpJ7.js} +1 -1
- package/dist/client/assets/{index-CaSLW3R8.js → index-Djpcf0g3.js} +1 -1
- package/dist/client/assets/{index-MmpnLDGH.js → index-Dn333xYc.js} +1 -1
- package/dist/client/assets/{index-BcuaxK20.js → index-Dyzblr5g.js} +1 -1
- package/dist/client/assets/{index-0M4CmMBW.js → index-GgUtI-aH.js} +1 -1
- package/dist/client/assets/{index-redirect-BdJPlstn.js → index-redirect-C1AnjHYu.js} +1 -1
- package/dist/client/assets/{index-Cvm8dv5Z.js → index-szJAEvQa.js} +1 -1
- package/dist/client/assets/{infiniteQueryObserver-B0NvduwT.js → infiniteQueryObserver-rGQ-BvZd.js} +1 -1
- package/dist/client/assets/{infra-billing-Ks9T1Sq9.js → infra-billing-a2nqEasz.js} +1 -1
- package/dist/client/assets/{input-DWWEe804.js → input-B-l5PYzO.js} +1 -1
- package/dist/client/assets/{input-CmcPYdOc.js → input-CQAdPV6U.js} +1 -1
- package/dist/client/assets/{input-BUuO9CZI.js → input-DJjbA9M9.js} +3 -3
- package/dist/client/assets/{integration-icon-aoXYYKdZ.js → integration-icon-Bo3BUxvM.js} +1 -1
- package/dist/client/assets/{label-CpTis3ZF.js → label-UBdu3ctU.js} +1 -1
- package/dist/client/assets/{layout-BmpAxoQw.js → layout-BtmKdLdk.js} +1 -1
- package/dist/client/assets/{legacy-agents-deep-dsUZ1M1k.js → legacy-agents-deep-YQnPtFe_.js} +1 -1
- package/dist/client/assets/{legacy-main-redirect-BSs4XNwX.js → legacy-main-redirect-CAZhbTVo.js} +1 -1
- package/dist/client/assets/library-CX4cu6RN.js +1 -0
- package/dist/client/assets/{library-tab-Bx_O7czI.js → library-tab-Cw6l7YjS.js} +1 -1
- package/dist/client/assets/{login-Bs8ZDJgZ.js → login-RaQgedvb.js} +1 -1
- package/dist/client/assets/{markdown-Bmw63uOU.js → markdown-DgNX2G8Y.js} +1 -1
- package/dist/client/assets/{mcp-app-renderer-fAGsYxUD.js → mcp-app-renderer-Gi8nuIVZ.js} +1 -1
- package/dist/client/assets/{mcp-oauth-DOvgIVsQ.js → mcp-oauth-ax5kWWJK.js} +1 -1
- package/dist/client/assets/{members-cQXKvPTX.js → members-C_--iBrh.js} +1 -1
- package/dist/client/assets/{memory-C9LPerZ9.js → memory-wojZsd5w.js} +1 -1
- package/dist/client/assets/{message-templates-s_ZoUf0b.js → message-templates-DbJIQtFs.js} +1 -1
- package/dist/client/assets/{mini-report-page-BpUKaSbF.js → mini-report-page-U0-aZ9Hl.js} +1 -1
- package/dist/client/assets/{mock-board-GWZVcMrh.js → mock-board-YpCRnBGe.js} +1 -1
- package/dist/client/assets/{monaco-editor-CQc-iURz.js → monaco-editor-Cs1rDRDm.js} +1 -1
- package/dist/client/assets/{monitoring-stats-row-CIORylAm.js → monitoring-stats-row-CcTNMb-i.js} +1 -1
- package/dist/client/assets/{multi-select-DgYPzhCT.js → multi-select-CWb2Oi6x.js} +1 -1
- package/dist/client/assets/{mustache-CSxb2mPF.js → mustache-CWsYDxkA.js} +1 -1
- package/dist/client/assets/{new-project-dialog-QzgehZk_.js → new-project-dialog-BWolKWvl.js} +1 -1
- package/dist/client/assets/{oauth-callback-xEhmpXdh.js → oauth-callback-Ld01h9Tj.js} +1 -1
- package/dist/client/assets/{oauth-callback-ai-provider-D3V_oXs6.js → oauth-callback-ai-provider-BGdom6cI.js} +1 -1
- package/dist/client/assets/{onboarding-CBuQm5u4.js → onboarding-D_NwiA9X.js} +1 -1
- package/dist/client/assets/{openai-conversation-BC7ip1oe.js → openai-conversation-DB4k1EYC.js} +1 -1
- package/dist/client/assets/{optimistic-project-sidebar-views-BRgs7fHb.js → optimistic-project-sidebar-views-DhsliVvJ.js} +1 -1
- package/dist/client/assets/{org-file-open-context-hWHGVIMb.js → org-file-open-context-kIKkchjb.js} +1 -1
- package/dist/client/assets/{organization-choice-BRq-jJ2y.js → organization-choice-DGTPCWDh.js} +1 -1
- package/dist/client/assets/{orgs-EVoggyaK.js → orgs-C5MsSx08.js} +1 -1
- package/dist/client/assets/{page-seo-form-Bj5T5rN8.js → page-seo-form-CW2BoQ-K.js} +1 -1
- package/dist/client/assets/{pair-DKzXjxOb.js → pair-qre124N2.js} +1 -1
- package/dist/client/assets/{plan-ladder-BtE6OACw.js → plan-ladder-B1XIg6KA.js} +1 -1
- package/dist/client/assets/{popover-CabOm1Wu.js → popover-DmsBpt35.js} +1 -1
- package/dist/client/assets/{post-calendar-w0VgMnGf.js → post-calendar-DOVsx0im.js} +1 -1
- package/dist/client/assets/{post-editor-B82uurtc.js → post-editor-D82mbe-R.js} +1 -1
- package/dist/client/assets/{preview-content-CN_ZoH0s.js → preview-content-CPFw8Bau.js} +1 -1
- package/dist/client/assets/{preview-dialog-DXrNofiq.js → preview-dialog-UaHza9Kp.js} +1 -1
- package/dist/client/assets/{profile-ZDdV7Sjt.js → profile-CMD3mJV4.js} +1 -1
- package/dist/client/assets/{project-app-view-Cd6lCir_.js → project-app-view-3CpE9pa5.js} +1 -1
- package/dist/client/assets/{project-feed-DKk1GtFx.js → project-feed-C4PTy6zU.js} +1 -1
- package/dist/client/assets/{project-icon-CeJwJwGP.js → project-icon-BlCsNLWV.js} +1 -1
- package/dist/client/assets/project-reports-C7tLohpM.js +1 -0
- package/dist/client/assets/project-tasks-mAIHHtBX.js +1 -0
- package/dist/client/assets/{projects-B2Tngpmc.js → projects-DnKzaVrl.js} +1 -1
- package/dist/client/assets/{projects-empty-state-BZB9j08t.js → projects-empty-state-Sx3HMMRD.js} +1 -1
- package/dist/client/assets/{prompts-DNtPf-Uo.js → prompts-iLYOGVAY.js} +1 -1
- package/dist/client/assets/record-editor-oL03Wyei.js +1 -0
- package/dist/client/assets/{redirect-editor-79Kd-396.js → redirect-editor-D_mpcVqR.js} +1 -1
- package/dist/client/assets/{reports-k2lgDaV5.js → reports-CnA1uxk8.js} +1 -1
- package/dist/client/assets/reports-DPqSriQT.js +1 -0
- package/dist/client/assets/{reports-onboarding-azHAAu-G.js → reports-onboarding-Wd1uDWK4.js} +1 -1
- package/dist/client/assets/{reports-tab-CdMrxIwA.js → reports-tab-586SqbUE.js} +2 -2
- package/dist/client/assets/{repositories-hjUQ2loa.js → repositories-DjuvrwKG.js} +1 -1
- package/dist/client/assets/{repository-binding-kLfd1JPC.js → repository-binding-qP9N-2MJ.js} +1 -1
- package/dist/client/assets/{repository-import-picker-C4bVjDlN.js → repository-import-picker-BxSMVAOp.js} +1 -1
- package/dist/client/assets/{repository-picker-CSvuMd3o.js → repository-picker-DXcVdbPo.js} +1 -1
- package/dist/client/assets/{require-capability-tQig_059.js → require-capability-Btgp_M9F.js} +1 -1
- package/dist/client/assets/{required-auth-layout-CVAQQhe-.js → required-auth-layout-BXGj5Xuz.js} +1 -1
- package/dist/client/assets/{reset-password-D34LCqZt.js → reset-password-DNvbhWv1.js} +1 -1
- package/dist/client/assets/{resizable-DncVAUZ5.js → resizable-p0Iz3mjy.js} +1 -1
- package/dist/client/assets/{resolve-tab-icon-1rWgS1Jh.js → resolve-tab-icon-BRRLdzHa.js} +1 -1
- package/dist/client/assets/{review-settings-D_4cx7Vi.js → review-settings-DL4Naz6f.js} +1 -1
- package/dist/client/assets/{rich-text-link-control-BWM1Qfc8.js → rich-text-link-control-BAQED-eE.js} +1 -1
- package/dist/client/assets/{roles-3KA0vrRL.js → roles-BKGa4A-8.js} +1 -1
- package/dist/client/assets/route-DRz2-z88.js +1 -0
- package/dist/client/assets/{route-Dnh3EpsD.js → route-DzBhuQmI.js} +1 -1
- package/dist/client/assets/route-uDEu1bUn.js +1 -0
- package/dist/client/assets/{runnable-block-editor-DjjqZBfa.js → runnable-block-editor-PtJtt2DC.js} +1 -1
- package/dist/client/assets/{sandbox-lifecycle-context-BlOR06Zw.js → sandbox-lifecycle-context-BrfabpuG.js} +1 -1
- package/dist/client/assets/{schema-CaBw1j44.js → schema-BWuVZGwp.js} +1 -1
- package/dist/client/assets/{scroll-area-BlYZotDi.js → scroll-area-m_BjZQNd.js} +1 -1
- package/dist/client/assets/{search-input-B5un_Cd7.js → search-input-B9M1xiUR.js} +1 -1
- package/dist/client/assets/{search-toggle-DgedUVLj.js → search-toggle-s-q01VSg.js} +1 -1
- package/dist/client/assets/{secret-picker-CtZnmzu1.js → secret-picker-BTuH8aWz.js} +1 -1
- package/dist/client/assets/{secrets-CSt6RJDc.js → secrets-1V4jZN7g.js} +1 -1
- package/dist/client/assets/{sections-editor-BW7HMRFS.js → sections-editor-DX4ixTgg.js} +1 -1
- package/dist/client/assets/{select-CYYv9Vtn.js → select-DC4TM20D.js} +1 -1
- package/dist/client/assets/{select-model-BMFiXFaW.js → select-model-BWaa2-GY.js} +1 -1
- package/dist/client/assets/{seo-editor-BqY8Ur2i.js → seo-editor-Bd3OOjX4.js} +1 -1
- package/dist/client/assets/{separator-Cl4FYhEq.js → separator-BEoe11dP.js} +1 -1
- package/dist/client/assets/{settings-tab-CLqtPJZG.js → settings-tab-73EvDId-.js} +1 -1
- package/dist/client/assets/{sheet-CmXNGCBA.js → sheet-gL2l7oL0.js} +1 -1
- package/dist/client/assets/{shell-layout-D2P6ouzP.js → shell-layout-CBc-iFqB.js} +1 -1
- package/dist/client/assets/{skills-C1v0xaAk.js → skills-CELE5LtE.js} +1 -1
- package/dist/client/assets/{sso-BthSYQ1g.js → sso-CxZR0IHJ.js} +1 -1
- package/dist/client/assets/{suggestion-DRMbopje.js → suggestion-Ules5agL.js} +1 -1
- package/dist/client/assets/{switch-B6KzjFhw.js → switch-CL5hy8vw.js} +1 -1
- package/dist/client/assets/{synced-repos-CnPrjVSO.js → synced-repos-BHKre5im.js} +1 -1
- package/dist/client/assets/{tab-icon-glyph-B6O2AOCF.js → tab-icon-glyph-DR0rQ-bV.js} +1 -1
- package/dist/client/assets/{table-BHDtYz9k.js → table-WwEBhzp_.js} +1 -1
- package/dist/client/assets/{tabs-CfLMYw89.js → tabs-WFH6vPjH.js} +1 -1
- package/dist/client/assets/{task-board-C7HcCxeg.js → task-board-CVGH6XO_.js} +1 -1
- package/dist/client/assets/{task-route-bn2URA0q.js → task-route-D36p4AYB.js} +1 -1
- package/dist/client/assets/{task-status-C4kf54Sm.js → task-status-CLw5rySP.js} +1 -1
- package/dist/client/assets/{taskboard-analytics-B2xD2xvd.js → taskboard-analytics-DjMTJmAz.js} +1 -1
- package/dist/client/assets/tasks-C-PeRfKF.js +1 -0
- package/dist/client/assets/{tasks-OZpkcyom.js → tasks-CNLTzE3N.js} +1 -1
- package/dist/client/assets/{textarea-D_VH3s7x.js → textarea-CoQK2oyP.js} +1 -1
- package/dist/client/assets/{thread-analytics-U5yFfcuN.js → thread-analytics-Dyt69XfV.js} +1 -1
- package/dist/client/assets/{thread-button-BHZP_s0g.js → thread-button-CXr1OWYY.js} +1 -1
- package/dist/client/assets/{thread-intent-tToQ_3Cn.js → thread-intent-CXrPEeI-.js} +1 -1
- package/dist/client/assets/{thread-route-CUOWsTdF.js → thread-route-CPId0Ds_.js} +1 -1
- package/dist/client/assets/{thread-route-Bzzi_5mF.js → thread-route-DKA9bRvS.js} +1 -1
- package/dist/client/assets/{thread-sheet-body-B0QtugED.js → thread-sheet-body-DbO-EyYS.js} +1 -1
- package/dist/client/assets/{toggle-group-BrWdayuI.js → toggle-group-CHfaqw3y.js} +1 -1
- package/dist/client/assets/{toolbar-icon-button-Dn4ZIc9O.js → toolbar-icon-button-CJrzg1xS.js} +1 -1
- package/dist/client/assets/{tooltip-2Ew10_I0.js → tooltip-BUwCxmad.js} +1 -1
- package/dist/client/assets/{track-DH05wicf.js → track-QsSY_R6p.js} +1 -1
- package/dist/client/assets/{types-DSEqfHk2.js → types-BM02pFks.js} +1 -1
- package/dist/client/assets/{usage-stats-y5sLQYFP.js → usage-stats-BZmwl_hY.js} +1 -1
- package/dist/client/assets/{use-ai-providers-jnOy5tNY.js → use-ai-providers-OUZLuzjk.js} +1 -1
- package/dist/client/assets/{use-automations-CZEM3KgU.js → use-automations-kRvu1WBi.js} +1 -1
- package/dist/client/assets/{use-autosave-Bk6osCzP.js → use-autosave-BknRtqMo.js} +1 -1
- package/dist/client/assets/{use-chat-layout-state-BbJD-IRs.js → use-chat-layout-state-PWimkJCw.js} +1 -1
- package/dist/client/assets/{use-clock-tick-BY0qK7ow.js → use-clock-tick-DK1jMfPk.js} +1 -1
- package/dist/client/assets/{use-connect-companion-D6e9vX_L.js → use-connect-companion-BE7rc0a7.js} +1 -1
- package/dist/client/assets/{use-connection-x3pfvWpW.js → use-connection-CDTsUGCD.js} +1 -1
- package/dist/client/assets/{use-copy-CJPO8CYZ.js → use-copy-4XQ35auE.js} +1 -1
- package/dist/client/assets/{use-create-virtual-mcp-BDos_868.js → use-create-virtual-mcp-Cr7lRENh.js} +1 -1
- package/dist/client/assets/{use-date-fns-locale-vNVrC6Qj.js → use-date-fns-locale-DSD5AxHp.js} +1 -1
- package/dist/client/assets/{use-debounced-autosave-zy5tN1OH.js → use-debounced-autosave-BmsH_WeG.js} +1 -1
- package/dist/client/assets/{use-debounced-value-Cjq6wHlM.js → use-debounced-value-Ddzynl8d.js} +1 -1
- package/dist/client/assets/{use-deco-credits-BBnccG_w.js → use-deco-credits-BWRF6eDW.js} +1 -1
- package/dist/client/assets/{use-decopilot-events-CCMkDtUe.js → use-decopilot-events-Coi59geF.js} +1 -1
- package/dist/client/assets/{use-delete-connection-C6BGGvaV.js → use-delete-connection-BAe608Tj.js} +1 -1
- package/dist/client/assets/{use-deployment-admin-CrwlatSG.js → use-deployment-admin-C9A5ryiv.js} +1 -1
- package/dist/client/assets/{use-fast-preview-draft-url-Z9tq3pqw.js → use-fast-preview-draft-url-D95FFIvg.js} +1 -1
- package/dist/client/assets/{use-file-configs-D6BnOxCa.js → use-file-configs-FESoyyAp.js} +1 -1
- package/dist/client/assets/{use-infinite-scroll-Cj7K2rNB.js → use-infinite-scroll-BOW8hicV.js} +1 -1
- package/dist/client/assets/{use-join-requests-8kDr2sOv.js → use-join-requests-DtLE0NgC.js} +1 -1
- package/dist/client/assets/{use-main-panel-tabs-CAIlwMdR.js → use-main-panel-tabs-Bc5UEnVE.js} +1 -1
- package/dist/client/assets/{use-mcp-auth-status-DaNrG9Qa.js → use-mcp-auth-status-DrjGrcBP.js} +1 -1
- package/dist/client/assets/{use-mcp-client-BGKUmMJU.js → use-mcp-client-DjhhnAr3.js} +1 -1
- package/dist/client/assets/{use-mcp-prompts-Brgv7p5b.js → use-mcp-prompts-CPGSJM8z.js} +1 -1
- package/dist/client/assets/{use-mcp-tools-D65vA86V.js → use-mcp-tools-CPwk0yw5.js} +1 -1
- package/dist/client/assets/{use-members-BiMQcnAS.js → use-members-CgpU7zdW.js} +1 -1
- package/dist/client/assets/{use-mobile-avjkwF6P.js → use-mobile-Dd6KUtd1.js} +1 -1
- package/dist/client/assets/{use-navigate-to-agent-DT6SP7we.js → use-navigate-to-agent-Bbk9KV3t.js} +1 -1
- package/dist/client/assets/use-new-blocks-editor-DdfQbotf.js +1 -0
- package/dist/client/assets/{use-open-billing-url-D3-Evs3P.js → use-open-billing-url-C5p05V2D.js} +1 -1
- package/dist/client/assets/{use-org-auth-client-C0kfn4Hh.js → use-org-auth-client-CGnd_KU_.js} +1 -1
- package/dist/client/assets/{use-org-fs-Bb3mK6Hx.js → use-org-fs-Cif2PgGI.js} +1 -1
- package/dist/client/assets/{use-org-repo-syncs-BaPlgvkL.js → use-org-repo-syncs-Cf0jwZet.js} +1 -1
- package/dist/client/assets/{use-org-sso-D0ubLH8o.js → use-org-sso-DnQOloxF.js} +1 -1
- package/dist/client/assets/{use-organization-roles-BjapmWnU.js → use-organization-roles-BarJOEKw.js} +1 -1
- package/dist/client/assets/{use-organization-settings-b1uEqEl7.js → use-organization-settings-DSuZT_-Z.js} +1 -1
- package/dist/client/assets/{use-panel-navigate-DM9oBo_y.js → use-panel-navigate-pf_bvwna.js} +1 -1
- package/dist/client/assets/{use-project-scope-CdG18ZwV.js → use-project-scope-B9gl4G0G.js} +1 -1
- package/dist/client/assets/{use-releases-BY6Ey7qp.js → use-releases-Cqzas87I.js} +1 -1
- package/dist/client/assets/{use-reports-diagnostic-Cea-ZR7h.js → use-reports-diagnostic-C9WXsFaU.js} +1 -1
- package/dist/client/assets/{use-secrets-BuVtrCbN.js → use-secrets-DWoy_Ekl.js} +1 -1
- package/dist/client/assets/{use-section-preview-base-BL5_n6HI.js → use-section-preview-base-B4B91XeI.js} +1 -1
- package/dist/client/assets/{use-session-runtime-BqNS_uzd.js → use-session-runtime-BtoYTkvM.js} +1 -1
- package/dist/client/assets/{use-tags-OZ8EdmaG.js → use-tags-oDh30HSX.js} +1 -1
- package/dist/client/assets/{use-task-board-analytics-DD0mNFO7.js → use-task-board-analytics-B-_ejdir.js} +1 -1
- package/dist/client/assets/{use-task-board-events-DEqI3Q6Z.js → use-task-board-events-D5YUKNR3.js} +1 -1
- package/dist/client/assets/{use-task-metadata-BZ9jc8IS.js → use-task-metadata-EBJAZAt5.js} +1 -1
- package/dist/client/assets/{use-thread-analytics-C_Ib4AtX.js → use-thread-analytics-23H9Sh0m.js} +1 -1
- package/dist/client/assets/{use-thread-outputs-BEYgt-Dh.js → use-thread-outputs-CzHRXoWD.js} +1 -1
- package/dist/client/assets/useInfiniteQuery-BzCTPJtn.js +1 -0
- package/dist/client/assets/{useQueries-BBJ9drAO.js → useQueries-OOmL0OlS.js} +1 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-Cx1jk_4I.js +1 -0
- package/dist/client/assets/{users-C0Q7tPX9.js → users-CSGmi7SW.js} +1 -1
- package/dist/client/assets/{utils-BawmeI6v.js → utils-R-urxMSv.js} +1 -1
- package/dist/client/assets/{variant-calendar-B3kfwaT1.js → variant-calendar-V9WH2c0X.js} +1 -1
- package/dist/client/assets/{variant-matcher-override-D5KXYhON.js → variant-matcher-override-Be69fnd9.js} +1 -1
- package/dist/client/assets/{view-mode-toggle-DSgKza5v.js → view-mode-toggle-hxQ2HfnS.js} +1 -1
- package/dist/client/assets/{virtual-mcp-Biy9WvuX.js → virtual-mcp-B4NgbGmF.js} +1 -1
- package/dist/client/index.html +1 -1
- package/dist/server/cli.js +1 -1
- package/dist/server/server.js +1 -1
- package/package.json +1 -1
- package/dist/client/assets/agent-app-qbb5JA2r.js +0 -1
- package/dist/client/assets/agent-deck-CqgjLBSE.js +0 -1
- package/dist/client/assets/agent-library-CSTO-y-t.js +0 -1
- package/dist/client/assets/agent-library-file-Df58itl6.js +0 -1
- package/dist/client/assets/agent-settings-Cgq30tNP.js +0 -1
- package/dist/client/assets/agent-site-editor-code-CFdjiowh.js +0 -2
- package/dist/client/assets/agent-view-DFwQL9ld.js +0 -1
- package/dist/client/assets/api-keys-vTb1XbGG.js +0 -1
- package/dist/client/assets/app-editor-CuHZFDnk.js +0 -1
- package/dist/client/assets/flat-project-BZORVBKb.js +0 -1
- package/dist/client/assets/library-CdGzPeek.js +0 -1
- package/dist/client/assets/project-reports-R5pejKr0.js +0 -1
- package/dist/client/assets/project-tasks-xxw_xxBg.js +0 -1
- package/dist/client/assets/record-editor-DdM0Ufnd.js +0 -1
- package/dist/client/assets/reports-B2qbOUEG.js +0 -1
- package/dist/client/assets/route-9df-A80E.js +0 -1
- package/dist/client/assets/route-B_mbIWRZ.js +0 -1
- package/dist/client/assets/tasks-Lw-J8js3.js +0 -1
- package/dist/client/assets/use-new-blocks-editor-BlVQ71Up.js +0 -1
- package/dist/client/assets/useInfiniteQuery-B0OQsDiL.js +0 -1
- package/dist/client/assets/useSuspenseInfiniteQuery-BjRsbalC.js +0 -1
package/dist/client/assets/{monitoring-stats-row-CIORylAm.js → monitoring-stats-row-CcTNMb-i.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as f,f2 as lt,c as Ne,l as Ie,j as I}from"./index-BE867Qee.js";import{C as Ae,d as Pe}from"./chart-NHKhTpOL.js";import{a5 as xe,ap as ot,aq as st,ar as ct,as as ut,P as ue,al as fe,$ as ve,h as dt,J as Se,a as $,at as ft,a9 as vt,s as ee,b as mt,f as J,g as Q,j as Te,k as Re,au as Fe,av as pt,aw as ht,l as Ee,ax as xt,ay as Oe,n as gt,L as le,p as yt,r as bt,D as ge,u as $e,R as kt,S as It,m as At,Z as ye,o as We,q as Pt,t as St,y as Et,v as Ot,az as Bt,z as oe,H as Ge,G as Ct,aA as jt,aB as wt,aC as Be,aD as Ve,aE as Mt,aF as Ue,K as Dt,N as Lt,O as R,T as _t,U as zt,V as Kt,aG as Nt,Q as Tt,am as Ce,a0 as Rt,a1 as Ft,C as je,Y as we}from"./CartesianChart-OVjYagl6.js";import{X as Me}from"./XAxis-DjkUxR47.js";import{s as G,b as V,A as $t,a as Wt}from"./AreaChart-94A56lku.js";import{a as Gt,S as Vt}from"./ErrorBarContext-Dckliguf.js";var be=t=>null;be.displayName="Cell";var Ye=(t,e,a)=>{var r=xe();return(i,n)=>c=>{t?.(i,n,c),r(ot({activeIndex:String(n),activeDataKey:e,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:a}))}},Xe=t=>{var e=xe();return(a,r)=>i=>{t?.(a,r,i),e(st())}},qe=(t,e,a)=>{var r=xe();return(i,n)=>c=>{t?.(i,n,c),r(ct({activeIndex:String(n),activeDataKey:e,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:a}))}},De=(t,e,a)=>{var r=a??t;if(!ue(r))return fe(r,e,0)},Ut=(t,e,a)=>{var r={},i=t.filter(ut),n=t.filter(l=>l.stackId==null),c=i.reduce((l,o)=>{var u=l[o.stackId];return u==null&&(u=[]),u.push(o),l[o.stackId]=u,l},r),s=Object.entries(c).map(l=>{var o,[u,v]=l,x=v.map(g=>g.dataKey),p=De(e,a,(o=v[0])===null||o===void 0?void 0:o.barSize);return{stackId:u,dataKeys:x,barSize:p}}),m=n.map(l=>{var o=[l.dataKey].filter(v=>v!=null),u=De(e,a,l.barSize);return{stackId:void 0,dataKeys:o,barSize:u}});return[...s,...m]};function Le(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),a.push.apply(a,r)}return a}function ie(t){for(var e=1;e<arguments.length;e++){var a=arguments[e]!=null?arguments[e]:{};e%2?Le(Object(a),!0).forEach(function(r){Yt(t,r,a[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):Le(Object(a)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(a,r))})}return t}function Yt(t,e,a){return(e=Xt(e))in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}function Xt(t){var e=qt(t,"string");return typeof e=="symbol"?e:e+""}function qt(t,e){if(typeof t!="object"||!t)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var r=a.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ht(t,e,a,r,i){var n,c=r.length;if(!(c<1)){var s=fe(t,a,0,!0),m,l=[];if(ve((n=r[0])===null||n===void 0?void 0:n.barSize)){var o=!1,u=a/c,v=r.reduce((h,y)=>h+(y.barSize||0),0);v+=(c-1)*s,v>=a&&(v-=(c-1)*s,s=0),v>=a&&u>0&&(o=!0,u*=.9,v=c*u);var x=(a-v)/2>>0,p={offset:x-s,size:0};m=r.reduce((h,y)=>{var k,C={stackId:y.stackId,dataKeys:y.dataKeys,position:{offset:p.offset+p.size+s,size:o?u:(k=y.barSize)!==null&&k!==void 0?k:0}},A=[...h,C];return p=C.position,A},l)}else{var g=fe(e,a,0,!0);a-2*g-(c-1)*s<=0&&(s=0);var b=(a-2*g-(c-1)*s)/c;b>1&&(b>>=0);var d=ve(i)?Math.min(b,i):b;m=r.reduce((h,y,k)=>[...h,{stackId:y.stackId,dataKeys:y.dataKeys,position:{offset:g+(b+s)*k+(b-d)/2,size:d}}],l)}return m}}var Zt=(t,e,a,r,i,n,c)=>{var s=ue(c)?e:c,m=Ht(a,r,i!==n?i:n,t,s);return i!==n&&m!=null&&(m=m.map(l=>ie(ie({},l),{},{position:ie(ie({},l.position),{},{offset:l.position.offset-i/2})}))),m},Jt=(t,e)=>{var a=dt(e);if(!(!t||a==null||e==null)){var{stackId:r}=e;if(r!=null){var i=t[r];if(i){var{stackedData:n}=i;if(n)return n.find(c=>c.key===a)}}}},Qt=(t,e)=>{if(!(t==null||e==null)){var a=t.find(r=>r.stackId===e.stackId&&e.dataKey!=null&&r.dataKeys.includes(e.dataKey));if(a!=null)return a.position}};function ea(t,e){return t&&typeof t=="object"&&"zIndex"in t&&typeof t.zIndex=="number"&&ve(t.zIndex)?t.zIndex:e}var ta="Invariant failed";function aa(t,e){throw new Error(ta)}function me(){return me=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},me.apply(null,arguments)}function ke(t){return f.createElement(Gt,me({shapeType:"rectangle",activeClassName:"recharts-active-bar",inActiveClassName:"recharts-inactive-bar"},t))}var ra=function(e){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return(r,i)=>{if(Se(e))return e;var n=Se(r)||ue(r);return n?e(r,i):(n||aa(),a)}},na=(t,e,a)=>a,ia=(t,e)=>e,ae=$([Re,ia],(t,e)=>t.filter(a=>a.type==="bar").find(a=>a.id===e)),la=$([ae],t=>t?.maxBarSize),oa=(t,e,a,r)=>r,sa=$([ee,Re,G,V,na],(t,e,a,r,i)=>e.filter(n=>t==="horizontal"?n.xAxisId===a:n.yAxisId===r).filter(n=>n.isPanorama===i).filter(n=>n.hide===!1).filter(n=>n.type==="bar")),ca=(t,e,a)=>{var r=ee(t),i=G(t,e),n=V(t,e);if(!(i==null||n==null))return r==="horizontal"?Ee(t,"yAxis",n,a):Ee(t,"xAxis",i,a)},ua=(t,e)=>{var a=ee(t),r=G(t,e),i=V(t,e);if(!(r==null||i==null))return a==="horizontal"?Oe(t,"xAxis",r):Oe(t,"yAxis",i)},da=$([sa,xt,ua],Ut),fa=(t,e,a)=>{var r,i,n=ae(t,e);if(n==null)return 0;var c=G(t,e),s=V(t,e);if(c==null||s==null)return 0;var m=ee(t),l=Fe(t),{maxBarSize:o}=n,u=ue(o)?l:o,v,x;return m==="horizontal"?(v=J(t,"xAxis",c,a),x=Q(t,"xAxis",c,a)):(v=J(t,"yAxis",s,a),x=Q(t,"yAxis",s,a)),(r=(i=Te(v,x,!0))!==null&&i!==void 0?i:u)!==null&&r!==void 0?r:0},He=(t,e,a)=>{var r=ee(t),i=G(t,e),n=V(t,e);if(!(i==null||n==null)){var c,s;return r==="horizontal"?(c=J(t,"xAxis",i,a),s=Q(t,"xAxis",i,a)):(c=J(t,"yAxis",n,a),s=Q(t,"yAxis",n,a)),Te(c,s)}},va=$([da,Fe,pt,ht,fa,He,la],Zt),ma=(t,e,a)=>{var r=G(t,e);if(r!=null)return J(t,"xAxis",r,a)},pa=(t,e,a)=>{var r=V(t,e);if(r!=null)return J(t,"yAxis",r,a)},ha=(t,e,a)=>{var r=G(t,e);if(r!=null)return Q(t,"xAxis",r,a)},xa=(t,e,a)=>{var r=V(t,e);if(r!=null)return Q(t,"yAxis",r,a)},ga=$([va,ae],Qt),ya=$([ca,ae],Jt),ba=$([ft,vt,ma,pa,ha,xa,ga,ee,mt,He,ya,ae,oa],(t,e,a,r,i,n,c,s,m,l,o,u,v)=>{var{chartData:x,dataStartIndex:p,dataEndIndex:g}=m;if(!(u==null||c==null||e==null||s!=="horizontal"&&s!=="vertical"||a==null||r==null||i==null||n==null||l==null)){var{data:b}=u,d;if(b!=null&&b.length>0?d=b:d=x?.slice(p,g+1),d!=null)return Xa({layout:s,barSettings:u,pos:c,parentViewBox:e,bandSize:l,xAxis:a,yAxis:r,xAxisTicks:i,yAxisTicks:n,stackedData:o,displayedData:d,offset:t,cells:v,dataStartIndex:p})}}),ka=["index"];function pe(){return pe=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},pe.apply(null,arguments)}function Ia(t,e){if(t==null)return{};var a,r,i=Aa(t,e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);for(r=0;r<n.length;r++)a=n[r],e.indexOf(a)===-1&&{}.propertyIsEnumerable.call(t,a)&&(i[a]=t[a])}return i}function Aa(t,e){if(t==null)return{};var a={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;a[r]=t[r]}return a}var Ze=f.createContext(void 0),Pa=t=>{var e=f.useContext(Ze);if(e!=null)return e.stackId;if(t!=null)return gt(t)},Sa=(t,e)=>"recharts-bar-stack-clip-path-".concat(t,"-").concat(e),Ea=t=>{var e=f.useContext(Ze);if(e!=null){var{stackId:a}=e;return"url(#".concat(Sa(a,t),")")}},Je=t=>{var{index:e}=t,a=Ia(t,ka),r=Ea(e);return f.createElement(le,pe({className:"recharts-bar-stack-layer",clipPath:r},a))},Oa=["onMouseEnter","onMouseLeave","onClick"],Ba=["value","background","tooltipPosition"],Ca=["id"],ja=["onMouseEnter","onClick","onMouseLeave"];function F(){return F=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},F.apply(null,arguments)}function _e(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),a.push.apply(a,r)}return a}function M(t){for(var e=1;e<arguments.length;e++){var a=arguments[e]!=null?arguments[e]:{};e%2?_e(Object(a),!0).forEach(function(r){wa(t,r,a[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):_e(Object(a)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(a,r))})}return t}function wa(t,e,a){return(e=Ma(e))in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}function Ma(t){var e=Da(t,"string");return typeof e=="symbol"?e:e+""}function Da(t,e){if(typeof t!="object"||!t)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var r=a.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function se(t,e){if(t==null)return{};var a,r,i=La(t,e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);for(r=0;r<n.length;r++)a=n[r],e.indexOf(a)===-1&&{}.propertyIsEnumerable.call(t,a)&&(i[a]=t[a])}return i}function La(t,e){if(t==null)return{};var a={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;a[r]=t[r]}return a}var _a=t=>{var{dataKey:e,name:a,fill:r,legendType:i,hide:n}=t;return[{inactive:n,dataKey:e,type:i,color:r,value:We(a,e),payload:t}]},za=f.memo(t=>{var{dataKey:e,stroke:a,strokeWidth:r,fill:i,name:n,hide:c,unit:s,tooltipType:m,id:l}=t,o={dataDefinedOnItem:void 0,getPosition:St,settings:{stroke:a,strokeWidth:r,fill:i,dataKey:e,nameKey:void 0,name:We(n,e),hide:c,type:m,color:i,unit:s,graphicalItemId:l}};return f.createElement(Pt,{tooltipEntrySettings:o})});function Ka(t){var e=oe(Ve),{data:a,dataKey:r,background:i,allOtherBarProps:n}=t,{onMouseEnter:c,onMouseLeave:s,onClick:m}=n,l=se(n,Oa),o=Ye(c,r,n.id),u=Xe(s),v=qe(m,r,n.id);if(!i||a==null)return null;var x=Mt(i);return f.createElement(ye,{zIndex:ea(i,ge.barBackground)},a.map((p,g)=>{var{value:b,background:d,tooltipPosition:h}=p,y=se(p,Ba);if(!d)return null;var k=o(p,g),C=u(p,g),A=v(p,g),P=M(M(M(M(M({option:i,isActive:String(g)===e},y),{},{fill:"#eee"},d),x),Ue(l,p,g)),{},{onMouseEnter:k,onMouseLeave:C,onClick:A,dataKey:r,index:g,className:"recharts-bar-background-rectangle"});return f.createElement(ke,F({key:"background-bar-".concat(g)},P))}))}function Na(t){var{showLabels:e,children:a,rects:r}=t,i=r?.map(n=>{var c={x:n.x,y:n.y,width:n.width,lowerWidth:n.width,upperWidth:n.width,height:n.height};return M(M({},c),{},{value:n.value,payload:n.payload,parentViewBox:n.parentViewBox,viewBox:c,fill:n.fill})});return f.createElement(zt,{value:e?i:void 0},a)}function Ta(t){var{shape:e,activeBar:a,baseProps:r,entry:i,index:n,dataKey:c}=t,s=oe(Ve),m=oe(Nt),l=a&&String(i.originalDataIndex)===s&&(m==null||c===m),[o,u]=f.useState(!1),[v,x]=f.useState(!1);f.useEffect(()=>{var y;return l?(u(!0),y=requestAnimationFrame(()=>{x(!0)})):x(!1),()=>{cancelAnimationFrame(y)}},[l]);var p=f.useCallback(()=>{l||u(!1)},[l]),g=l&&v,b=l||o,d;l?a===!0?d=e:d=a:d=e;var h=f.createElement(ke,F({},r,{name:String(r.name)},i,{isActive:g,option:d,index:n,dataKey:c,onTransitionEnd:p}));return b?f.createElement(ye,{zIndex:ge.activeBar},f.createElement(Je,{index:i.originalDataIndex},h)):h}function Ra(t){var{shape:e,baseProps:a,entry:r,index:i,dataKey:n}=t;return f.createElement(ke,F({},a,{name:String(a.name)},r,{isActive:!1,option:e,index:i,dataKey:n}))}function Fa(t){var e,{data:a,props:r}=t,i=(e=Kt(r))!==null&&e!==void 0?e:{},{id:n}=i,c=se(i,Ca),{shape:s,dataKey:m,activeBar:l}=r,{onMouseEnter:o,onClick:u,onMouseLeave:v}=r,x=se(r,ja),p=Ye(o,m,n),g=Xe(v),b=qe(u,m,n);return a?f.createElement(f.Fragment,null,a.map((d,h)=>f.createElement(Je,F({index:d.originalDataIndex,key:"rectangle-".concat(d?.x,"-").concat(d?.y,"-").concat(d?.value,"-").concat(h),className:"recharts-bar-rectangle"},Ue(x,d,h),{onMouseEnter:p(d,h),onMouseLeave:g(d,h),onClick:b(d,h)}),l?f.createElement(Ta,{shape:s,activeBar:l,baseProps:c,entry:d,index:h,dataKey:m}):f.createElement(Ra,{shape:s,baseProps:c,entry:d,index:h,dataKey:m})))):null}function $a(t){var{props:e,previousRectanglesRef:a}=t,{data:r,layout:i,isAnimationActive:n,animationBegin:c,animationDuration:s,animationEasing:m,onAnimationEnd:l,onAnimationStart:o}=e,u=a.current,v=Dt(e,"recharts-bar-"),[x,p]=f.useState(!1),g=!x,b=f.useCallback(()=>{typeof l=="function"&&l(),p(!1)},[l]),d=f.useCallback(()=>{typeof o=="function"&&o(),p(!0)},[o]);return f.createElement(Na,{showLabels:g,rects:r},f.createElement(Lt,{animationId:v,begin:c,duration:s,isActive:n,easing:m,onAnimationEnd:b,onAnimationStart:d,key:v},h=>{var y=h===1?r:r?.map((k,C)=>{var A=u&&u[C];if(A)return M(M({},k),{},{x:R(A.x,k.x,h),y:R(A.y,k.y,h),width:R(A.width,k.width,h),height:R(A.height,k.height,h)});if(i==="horizontal"){var P=R(0,k.height,h),w=R(k.stackedBarStart,k.y,h);return M(M({},k),{},{y:w,height:P})}var j=R(0,k.width,h),S=R(k.stackedBarStart,k.x,h);return M(M({},k),{},{width:j,x:S})});return h>0&&(a.current=y??null),y==null?null:f.createElement(le,null,f.createElement(Fa,{props:e,data:y}))}),f.createElement(_t,{label:e.label}),e.children)}function Wa(t){var e=f.useRef(null);return f.createElement($a,{previousRectanglesRef:e,props:t})}var Qe=0,Ga=(t,e)=>{var a=Array.isArray(t.value)?t.value[1]:t.value;return{x:t.x,y:t.y,value:a,errorVal:Ge(t,e)}};class Va extends f.PureComponent{render(){var{hide:e,data:a,dataKey:r,className:i,xAxisId:n,yAxisId:c,needClip:s,background:m,id:l}=this.props;if(e||a==null)return null;var o=lt("recharts-bar",i),u=l;return f.createElement(le,{className:o,id:l},s&&f.createElement("defs",null,f.createElement(Ct,{clipPathId:u,xAxisId:n,yAxisId:c})),f.createElement(le,{className:"recharts-bar-rectangles",clipPath:s?"url(#clipPath-".concat(u,")"):void 0},f.createElement(Ka,{data:a,dataKey:r,background:m,allOtherBarProps:this.props}),f.createElement(Wa,this.props)))}}var Ua={activeBar:!1,animationBegin:0,animationDuration:400,animationEasing:"ease",background:!1,hide:!1,isAnimationActive:"auto",label:!1,legendType:"rect",minPointSize:Qe,xAxisId:0,yAxisId:0,zIndex:ge.bar};function Ya(t){var{xAxisId:e,yAxisId:a,hide:r,legendType:i,minPointSize:n,activeBar:c,animationBegin:s,animationDuration:m,animationEasing:l,isAnimationActive:o}=t,{needClip:u}=Et(e,a),v=Ot(),x=$e(),p=Bt(t.children,be),g=oe(h=>ba(h,t.id,x,p));if(v!=="vertical"&&v!=="horizontal")return null;var b,d=g?.[0];return d==null||d.height==null||d.width==null?b=0:b=v==="vertical"?d.height/2:d.width/2,f.createElement(Vt,{xAxisId:e,yAxisId:a,data:g,dataPointFormatter:Ga,errorBarOffset:b},f.createElement(Va,F({},t,{layout:v,needClip:u,data:g,xAxisId:e,yAxisId:a,hide:r,legendType:i,minPointSize:n,activeBar:c,animationBegin:s,animationDuration:m,animationEasing:l,isAnimationActive:o})))}function Xa(t){var{layout:e,barSettings:{dataKey:a,minPointSize:r,hasCustomShape:i},pos:n,bandSize:c,xAxis:s,yAxis:m,xAxisTicks:l,yAxisTicks:o,stackedData:u,displayedData:v,offset:x,cells:p,parentViewBox:g,dataStartIndex:b}=t,d=e==="horizontal"?m:s,h=u?d.scale.domain():null,y=jt({numericAxis:d}),k=d.scale.map(y);return v.map((C,A)=>{var P,w,j,S,O,K;if(u){var B=u[A+b];if(B==null)return null;P=wt(B,h)}else P=Ge(C,a),Array.isArray(P)||(P=[y,P]);var E=ra(r,Qe)(P[1],A);if(e==="horizontal"){var D,N=m.scale.map(P[0]),L=m.scale.map(P[1]);if(N==null||L==null)return null;w=Be({axis:s,ticks:l,bandSize:c,offset:n.offset,entry:C,index:A}),j=(D=L??N)!==null&&D!==void 0?D:void 0,S=n.size;var _=N-L;if(O=Tt(_)?0:_,K={x:w,y:x.top,width:S,height:x.height},Math.abs(E)>0&&Math.abs(O)<Math.abs(E)){var z=Ce(O||E)*(Math.abs(E)-Math.abs(O));j-=z,O+=z}}else{var T=s.scale.map(P[0]),W=s.scale.map(P[1]);if(T==null||W==null)return null;if(w=T,j=Be({axis:m,ticks:o,bandSize:c,offset:n.offset,entry:C,index:A}),S=W-T,O=n.size,K={x:x.left,y:j,width:x.width,height:O},Math.abs(E)>0&&Math.abs(S)<Math.abs(E)){var U=Ce(S||E)*(Math.abs(E)-Math.abs(S));S+=U}}if(w==null||j==null||S==null||O==null||!i&&(S===0||O===0))return null;var te=M(M({},C),{},{stackedBarStart:k,x:w,y:j,width:S,height:O,value:u?P:P[1],payload:C,background:K,tooltipPosition:{x:w+S/2,y:j+O/2},parentViewBox:g,originalDataIndex:A},p&&p[A]&&p[A].props);return te}).filter(Boolean)}function qa(t){var e=bt(t,Ua),a=Pa(e.stackId),r=$e();return f.createElement(kt,{id:e.id,type:"bar"},i=>f.createElement(f.Fragment,null,f.createElement(It,{legendPayload:_a(e)}),f.createElement(za,{dataKey:e.dataKey,stroke:e.stroke,strokeWidth:e.strokeWidth,fill:e.fill,name:e.name,hide:e.hide,unit:e.unit,tooltipType:e.tooltipType,id:i}),f.createElement(At,{type:"bar",id:i,data:void 0,xAxisId:e.xAxisId,yAxisId:e.yAxisId,zAxisId:0,dataKey:e.dataKey,stackId:a,hide:e.hide,barSize:e.barSize,minPointSize:e.minPointSize,maxBarSize:e.maxBarSize,isPanorama:r,hasCustomShape:e.shape!=null}),f.createElement(ye,{zIndex:e.zIndex},f.createElement(Ya,F({},e,{id:i})))))}var et=f.memo(qa,yt);et.displayName="Bar";var Ha=["axis","item"],Za=f.forwardRef((t,e)=>f.createElement(Rt,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:Ha,tooltipPayloadSearcher:Ft,categoricalChartProps:t,ref:e}));const tt=60*1e3,ce=60*tt,Ja=24*ce,at=25*ce;function he(t,e){if(t.length===0)return 0;const a=[...t].sort((i,n)=>i-n),r=Math.max(0,Math.min(a.length-1,Math.ceil(e*a.length)-1));return a[r]??0}function Qa(t,e){return e<=at?t.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}):t.toLocaleDateString([],{month:"short",day:"numeric"})}function er(t,e){const a=e-t;return a<=ce?Math.max(1,Math.min(60,Math.ceil(a/tt))):a<=at?Math.max(1,Math.min(25,Math.ceil(a/ce))):Math.max(1,Math.min(31,Math.ceil(a/Ja)))}function tr(t,e,a,r){const i=e.getTime(),n=a.getTime(),c=Math.max(1,n-i),s=er(i,n),m=Math.max(1,Math.floor(c/s)),l=[];for(let o=0;o<s;o++){const u=new Date(i+o*m);l.push({t:u.toISOString(),ts:u.getTime(),label:Qa(u,c),calls:0,errors:0,durations:[]})}for(const o of t){const u=new Date(o.timestamp).getTime(),v=Math.floor((u-i)/m),x=Math.max(0,Math.min(s-1,v)),p=l[x];p&&(p.calls+=1,o.isError&&(p.errors+=1),Number.isFinite(o.durationMs)&&p.durations.push(o.durationMs))}return l.map(o=>({t:o.t,ts:o.ts,label:o.label,calls:o.calls,errors:o.errors,errorRate:o.calls>0?o.errors/o.calls*100:0,avg:Math.round(o.durations.length>0?o.durations.reduce((u,v)=>u+v,0)/o.durations.length:0),p50:Math.round(he(o.durations,.5)),p95:Math.round(he(o.durations,.95))}))}function sr(t,e,a,r,i){const n=r??t.length,c=i??t.filter(u=>u.isError).length,s=t.map(u=>u.durationMs),m=s.length>0?s.reduce((u,v)=>u+v,0)/s.length:0,l=he(s,.95),o=tr(t,e.startDate,e.endDate);return{totalCalls:n,totalErrors:c,avgDurationMs:m,p95DurationMs:l,data:o}}function ze(t){return t>=1e3?`${(t/1e3).toFixed(1)}k`:String(t)}function Ke(t){const e=Ne.c(19),{active:a,payload:r,dataKey:i,colorVar:n}=t;if(!a||!r?.length)return null;const c=r[0],s=c?.payload?.t??"";let m;e[0]!==c?.payload?.label||e[1]!==s?(m=s?new Date(s).toLocaleString([],{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"}):c?.payload?.label??"",e[0]=c?.payload?.label,e[1]=s,e[2]=m):m=e[2];const l=m,o=c?.value,u=typeof o=="number"?o:0,v=i==="avg"||i==="p50"||i==="p95",x=i==="costUsd";let p;e[3]!==x||e[4]!==v||e[5]!==u?(p=x?`$${u.toFixed(u<1?4:2)}`:v?u>=1e4?`${(u/1e3).toFixed(1)}s`:`${Math.round(u)}ms`:u.toLocaleString(),e[3]=x,e[4]=v,e[5]=u,e[6]=p):p=e[6];const g=p;let b;e[7]!==l?(b=I.jsx("div",{className:"text-[11px] text-muted-foreground mb-1",children:l}),e[7]=l,e[8]=b):b=e[8];let d;e[9]!==n?(d=I.jsx("div",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:n}}),e[9]=n,e[10]=d):d=e[10];let h;e[11]!==g?(h=I.jsx("span",{className:"text-xs font-medium tabular-nums",children:g}),e[11]=g,e[12]=h):h=e[12];let y;e[13]!==d||e[14]!==h?(y=I.jsxs("div",{className:"flex items-center gap-1.5",children:[d,h]}),e[13]=d,e[14]=h,e[15]=y):y=e[15];let k;return e[16]!==b||e[17]!==y?(k=I.jsxs("div",{className:"rounded-lg border bg-background px-3 py-2 shadow-md",children:[b,y]}),e[16]=b,e[17]=y,e[18]=k):k=e[18],k}function cr(t){const e=Ne.c(85),{data:a,dataKey:r,colorNum:i,chartHeight:n,variant:c,ariaLabel:s}=t,m=c===void 0?"bar":c,l=`var(--chart-${i})`,o=`kpi-gradient-${r}-${i}`,u=Math.max(...a.map(B=>B[r]??0),0);if(m==="area"){let B;e[0]!==n?(B=Ie(n,"w-full"),e[0]=n,e[1]=B):B=e[1];let E;e[2]!==l||e[3]!==r?(E={label:r,color:l},e[2]=l,e[3]=r,e[4]=E):E=e[4];let D;e[5]!==r||e[6]!==E?(D={[r]:E},e[5]=r,e[6]=E,e[7]=D):D=e[7];let N;e[8]===Symbol.for("react.memo_cache_sentinel")?(N={left:0,right:-12,top:8,bottom:8},e[8]=N):N=e[8];let L,_;e[9]!==l?(L=I.jsx("stop",{offset:"0%",stopColor:l,stopOpacity:.2}),_=I.jsx("stop",{offset:"100%",stopColor:l,stopOpacity:0}),e[9]=l,e[10]=L,e[11]=_):(L=e[10],_=e[11]);let z;e[12]!==o||e[13]!==L||e[14]!==_?(z=I.jsx("defs",{children:I.jsxs("linearGradient",{id:o,x1:"0",y1:"0",x2:"0",y2:"1",children:[L,_]})}),e[12]=o,e[13]=L,e[14]=_,e[15]=z):z=e[15];let T;e[16]===Symbol.for("react.memo_cache_sentinel")?(T=I.jsx(je,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),e[16]=T):T=e[16];let W;e[17]===Symbol.for("react.memo_cache_sentinel")?(W=I.jsx(Me,{dataKey:"label",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)",opacity:.7},interval:"preserveStartEnd",tickMargin:8}),e[17]=W):W=e[17];let U;e[18]===Symbol.for("react.memo_cache_sentinel")?(U={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[18]=U):U=e[18];const te=u>0?"auto":10;let Y;e[19]!==te?(Y=I.jsx(we,{orientation:"right",axisLine:!1,tickLine:!1,tick:U,tickFormatter:ze,width:40,domain:[0,te],tickCount:5}),e[19]=te,e[20]=Y):Y=e[20];let re;e[21]===Symbol.for("react.memo_cache_sentinel")?(re={stroke:"var(--border)",strokeDasharray:"4 4"},e[21]=re):re=e[21];let X;e[22]!==l||e[23]!==r?(X=I.jsx(Ae,{cursor:re,content:rt=>{const{active:nt,payload:it}=rt;return I.jsx(Ke,{active:nt,payload:it,dataKey:r,colorVar:l})}}),e[22]=l,e[23]=r,e[24]=X):X=e[24];const de=`url(#${o})`;let q;e[25]!==l?(q={r:4,fill:l,stroke:"var(--background)",strokeWidth:2},e[25]=l,e[26]=q):q=e[26];let H;e[27]!==l||e[28]!==r||e[29]!==de||e[30]!==q?(H=I.jsx($t,{type:"linear",dataKey:r,stroke:l,strokeWidth:2,fill:de,animationDuration:300,dot:!1,activeDot:q}),e[27]=l,e[28]=r,e[29]=de,e[30]=q,e[31]=H):H=e[31];let Z;e[32]!==a||e[33]!==Y||e[34]!==X||e[35]!==H||e[36]!==z?(Z=I.jsxs(Wt,{data:a,margin:N,children:[z,T,W,Y,X,H]}),e[32]=a,e[33]=Y,e[34]=X,e[35]=H,e[36]=z,e[37]=Z):Z=e[37];let ne;return e[38]!==s||e[39]!==Z||e[40]!==B||e[41]!==D?(ne=I.jsx(Pe,{role:"img","aria-label":s,className:B,config:D,children:Z}),e[38]=s,e[39]=Z,e[40]=B,e[41]=D,e[42]=ne):ne=e[42],ne}let v;e[43]!==n?(v=Ie(n,"w-full"),e[43]=n,e[44]=v):v=e[44];let x;e[45]!==l||e[46]!==r?(x={label:r,color:l},e[45]=l,e[46]=r,e[47]=x):x=e[47];let p;e[48]!==r||e[49]!==x?(p={[r]:x},e[48]=r,e[49]=x,e[50]=p):p=e[50];let g,b;e[51]===Symbol.for("react.memo_cache_sentinel")?(g={left:0,right:-12,top:8,bottom:8},b=I.jsx(je,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),e[51]=g,e[52]=b):(g=e[51],b=e[52]);let d;e[53]===Symbol.for("react.memo_cache_sentinel")?(d={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[53]=d):d=e[53];const h=a.length<=6?0:Math.floor(a.length/6);let y;e[54]!==h?(y=I.jsx(Me,{dataKey:"label",axisLine:!1,tickLine:!1,tick:d,interval:h,tickMargin:8}),e[54]=h,e[55]=y):y=e[55];let k;e[56]===Symbol.for("react.memo_cache_sentinel")?(k={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[56]=k):k=e[56];const C=u>0?"auto":10;let A;e[57]!==C?(A=I.jsx(we,{orientation:"right",axisLine:!1,tickLine:!1,tick:k,tickFormatter:ze,width:40,domain:[0,C],tickCount:5}),e[57]=C,e[58]=A):A=e[58];let P;e[59]===Symbol.for("react.memo_cache_sentinel")?(P={fill:"var(--muted)",opacity:.3},e[59]=P):P=e[59];let w;e[60]!==l||e[61]!==r?(w=I.jsx(Ae,{cursor:P,content:B=>{const{active:E,payload:D}=B;return I.jsx(Ke,{active:E,payload:D,dataKey:r,colorVar:l})}}),e[60]=l,e[61]=r,e[62]=w):w=e[62];let j;if(e[63]!==l||e[64]!==a||e[65]!==r){let B;e[67]!==l||e[68]!==r?(B=(E,D)=>I.jsx(be,{fill:(E[r]??0)===0?"var(--muted-foreground)":l,fillOpacity:(E[r]??0)===0?.15:.85},`cell-${D}`),e[67]=l,e[68]=r,e[69]=B):B=e[69],j=a.map(B),e[63]=l,e[64]=a,e[65]=r,e[66]=j}else j=e[66];let S;e[70]!==l||e[71]!==r||e[72]!==j?(S=I.jsx(et,{dataKey:r,fill:l,radius:0,minPointSize:1,children:j}),e[70]=l,e[71]=r,e[72]=j,e[73]=S):S=e[73];let O;e[74]!==a||e[75]!==A||e[76]!==w||e[77]!==S||e[78]!==y?(O=I.jsxs(Za,{data:a,margin:g,children:[b,y,A,w,S]}),e[74]=a,e[75]=A,e[76]=w,e[77]=S,e[78]=y,e[79]=O):O=e[79];let K;return e[80]!==s||e[81]!==O||e[82]!==v||e[83]!==p?(K=I.jsx(Pe,{role:"img","aria-label":s,className:v,config:p,children:O}),e[80]=s,e[81]=O,e[82]=v,e[83]=p,e[84]=K):K=e[84],K}export{Za as B,be as C,cr as K,et as a,sr as c};
|
|
1
|
+
import{r as f,f2 as lt,c as Ne,l as Ie,j as I}from"./index-D3VyLkC3.js";import{C as Ae,d as Pe}from"./chart-BkrO3MsD.js";import{a5 as xe,ap as ot,aq as st,ar as ct,as as ut,P as ue,al as fe,$ as ve,h as dt,J as Se,a as $,at as ft,a9 as vt,s as ee,b as mt,f as J,g as Q,j as Te,k as Re,au as Fe,av as pt,aw as ht,l as Ee,ax as xt,ay as Oe,n as gt,L as le,p as yt,r as bt,D as ge,u as $e,R as kt,S as It,m as At,Z as ye,o as We,q as Pt,t as St,y as Et,v as Ot,az as Bt,z as oe,H as Ge,G as Ct,aA as jt,aB as wt,aC as Be,aD as Ve,aE as Mt,aF as Ue,K as Dt,N as Lt,O as R,T as _t,U as zt,V as Kt,aG as Nt,Q as Tt,am as Ce,a0 as Rt,a1 as Ft,C as je,Y as we}from"./CartesianChart-Dxs56jW8.js";import{X as Me}from"./XAxis-CxP14qz_.js";import{s as G,b as V,A as $t,a as Wt}from"./AreaChart-DOBe6b77.js";import{a as Gt,S as Vt}from"./ErrorBarContext-CoXkTI3v.js";var be=t=>null;be.displayName="Cell";var Ye=(t,e,a)=>{var r=xe();return(i,n)=>c=>{t?.(i,n,c),r(ot({activeIndex:String(n),activeDataKey:e,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:a}))}},Xe=t=>{var e=xe();return(a,r)=>i=>{t?.(a,r,i),e(st())}},qe=(t,e,a)=>{var r=xe();return(i,n)=>c=>{t?.(i,n,c),r(ct({activeIndex:String(n),activeDataKey:e,activeCoordinate:i.tooltipPosition,activeGraphicalItemId:a}))}},De=(t,e,a)=>{var r=a??t;if(!ue(r))return fe(r,e,0)},Ut=(t,e,a)=>{var r={},i=t.filter(ut),n=t.filter(l=>l.stackId==null),c=i.reduce((l,o)=>{var u=l[o.stackId];return u==null&&(u=[]),u.push(o),l[o.stackId]=u,l},r),s=Object.entries(c).map(l=>{var o,[u,v]=l,x=v.map(g=>g.dataKey),p=De(e,a,(o=v[0])===null||o===void 0?void 0:o.barSize);return{stackId:u,dataKeys:x,barSize:p}}),m=n.map(l=>{var o=[l.dataKey].filter(v=>v!=null),u=De(e,a,l.barSize);return{stackId:void 0,dataKeys:o,barSize:u}});return[...s,...m]};function Le(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),a.push.apply(a,r)}return a}function ie(t){for(var e=1;e<arguments.length;e++){var a=arguments[e]!=null?arguments[e]:{};e%2?Le(Object(a),!0).forEach(function(r){Yt(t,r,a[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):Le(Object(a)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(a,r))})}return t}function Yt(t,e,a){return(e=Xt(e))in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}function Xt(t){var e=qt(t,"string");return typeof e=="symbol"?e:e+""}function qt(t,e){if(typeof t!="object"||!t)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var r=a.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Ht(t,e,a,r,i){var n,c=r.length;if(!(c<1)){var s=fe(t,a,0,!0),m,l=[];if(ve((n=r[0])===null||n===void 0?void 0:n.barSize)){var o=!1,u=a/c,v=r.reduce((h,y)=>h+(y.barSize||0),0);v+=(c-1)*s,v>=a&&(v-=(c-1)*s,s=0),v>=a&&u>0&&(o=!0,u*=.9,v=c*u);var x=(a-v)/2>>0,p={offset:x-s,size:0};m=r.reduce((h,y)=>{var k,C={stackId:y.stackId,dataKeys:y.dataKeys,position:{offset:p.offset+p.size+s,size:o?u:(k=y.barSize)!==null&&k!==void 0?k:0}},A=[...h,C];return p=C.position,A},l)}else{var g=fe(e,a,0,!0);a-2*g-(c-1)*s<=0&&(s=0);var b=(a-2*g-(c-1)*s)/c;b>1&&(b>>=0);var d=ve(i)?Math.min(b,i):b;m=r.reduce((h,y,k)=>[...h,{stackId:y.stackId,dataKeys:y.dataKeys,position:{offset:g+(b+s)*k+(b-d)/2,size:d}}],l)}return m}}var Zt=(t,e,a,r,i,n,c)=>{var s=ue(c)?e:c,m=Ht(a,r,i!==n?i:n,t,s);return i!==n&&m!=null&&(m=m.map(l=>ie(ie({},l),{},{position:ie(ie({},l.position),{},{offset:l.position.offset-i/2})}))),m},Jt=(t,e)=>{var a=dt(e);if(!(!t||a==null||e==null)){var{stackId:r}=e;if(r!=null){var i=t[r];if(i){var{stackedData:n}=i;if(n)return n.find(c=>c.key===a)}}}},Qt=(t,e)=>{if(!(t==null||e==null)){var a=t.find(r=>r.stackId===e.stackId&&e.dataKey!=null&&r.dataKeys.includes(e.dataKey));if(a!=null)return a.position}};function ea(t,e){return t&&typeof t=="object"&&"zIndex"in t&&typeof t.zIndex=="number"&&ve(t.zIndex)?t.zIndex:e}var ta="Invariant failed";function aa(t,e){throw new Error(ta)}function me(){return me=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},me.apply(null,arguments)}function ke(t){return f.createElement(Gt,me({shapeType:"rectangle",activeClassName:"recharts-active-bar",inActiveClassName:"recharts-inactive-bar"},t))}var ra=function(e){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return(r,i)=>{if(Se(e))return e;var n=Se(r)||ue(r);return n?e(r,i):(n||aa(),a)}},na=(t,e,a)=>a,ia=(t,e)=>e,ae=$([Re,ia],(t,e)=>t.filter(a=>a.type==="bar").find(a=>a.id===e)),la=$([ae],t=>t?.maxBarSize),oa=(t,e,a,r)=>r,sa=$([ee,Re,G,V,na],(t,e,a,r,i)=>e.filter(n=>t==="horizontal"?n.xAxisId===a:n.yAxisId===r).filter(n=>n.isPanorama===i).filter(n=>n.hide===!1).filter(n=>n.type==="bar")),ca=(t,e,a)=>{var r=ee(t),i=G(t,e),n=V(t,e);if(!(i==null||n==null))return r==="horizontal"?Ee(t,"yAxis",n,a):Ee(t,"xAxis",i,a)},ua=(t,e)=>{var a=ee(t),r=G(t,e),i=V(t,e);if(!(r==null||i==null))return a==="horizontal"?Oe(t,"xAxis",r):Oe(t,"yAxis",i)},da=$([sa,xt,ua],Ut),fa=(t,e,a)=>{var r,i,n=ae(t,e);if(n==null)return 0;var c=G(t,e),s=V(t,e);if(c==null||s==null)return 0;var m=ee(t),l=Fe(t),{maxBarSize:o}=n,u=ue(o)?l:o,v,x;return m==="horizontal"?(v=J(t,"xAxis",c,a),x=Q(t,"xAxis",c,a)):(v=J(t,"yAxis",s,a),x=Q(t,"yAxis",s,a)),(r=(i=Te(v,x,!0))!==null&&i!==void 0?i:u)!==null&&r!==void 0?r:0},He=(t,e,a)=>{var r=ee(t),i=G(t,e),n=V(t,e);if(!(i==null||n==null)){var c,s;return r==="horizontal"?(c=J(t,"xAxis",i,a),s=Q(t,"xAxis",i,a)):(c=J(t,"yAxis",n,a),s=Q(t,"yAxis",n,a)),Te(c,s)}},va=$([da,Fe,pt,ht,fa,He,la],Zt),ma=(t,e,a)=>{var r=G(t,e);if(r!=null)return J(t,"xAxis",r,a)},pa=(t,e,a)=>{var r=V(t,e);if(r!=null)return J(t,"yAxis",r,a)},ha=(t,e,a)=>{var r=G(t,e);if(r!=null)return Q(t,"xAxis",r,a)},xa=(t,e,a)=>{var r=V(t,e);if(r!=null)return Q(t,"yAxis",r,a)},ga=$([va,ae],Qt),ya=$([ca,ae],Jt),ba=$([ft,vt,ma,pa,ha,xa,ga,ee,mt,He,ya,ae,oa],(t,e,a,r,i,n,c,s,m,l,o,u,v)=>{var{chartData:x,dataStartIndex:p,dataEndIndex:g}=m;if(!(u==null||c==null||e==null||s!=="horizontal"&&s!=="vertical"||a==null||r==null||i==null||n==null||l==null)){var{data:b}=u,d;if(b!=null&&b.length>0?d=b:d=x?.slice(p,g+1),d!=null)return Xa({layout:s,barSettings:u,pos:c,parentViewBox:e,bandSize:l,xAxis:a,yAxis:r,xAxisTicks:i,yAxisTicks:n,stackedData:o,displayedData:d,offset:t,cells:v,dataStartIndex:p})}}),ka=["index"];function pe(){return pe=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},pe.apply(null,arguments)}function Ia(t,e){if(t==null)return{};var a,r,i=Aa(t,e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);for(r=0;r<n.length;r++)a=n[r],e.indexOf(a)===-1&&{}.propertyIsEnumerable.call(t,a)&&(i[a]=t[a])}return i}function Aa(t,e){if(t==null)return{};var a={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;a[r]=t[r]}return a}var Ze=f.createContext(void 0),Pa=t=>{var e=f.useContext(Ze);if(e!=null)return e.stackId;if(t!=null)return gt(t)},Sa=(t,e)=>"recharts-bar-stack-clip-path-".concat(t,"-").concat(e),Ea=t=>{var e=f.useContext(Ze);if(e!=null){var{stackId:a}=e;return"url(#".concat(Sa(a,t),")")}},Je=t=>{var{index:e}=t,a=Ia(t,ka),r=Ea(e);return f.createElement(le,pe({className:"recharts-bar-stack-layer",clipPath:r},a))},Oa=["onMouseEnter","onMouseLeave","onClick"],Ba=["value","background","tooltipPosition"],Ca=["id"],ja=["onMouseEnter","onClick","onMouseLeave"];function F(){return F=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var a=arguments[e];for(var r in a)({}).hasOwnProperty.call(a,r)&&(t[r]=a[r])}return t},F.apply(null,arguments)}function _e(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable})),a.push.apply(a,r)}return a}function M(t){for(var e=1;e<arguments.length;e++){var a=arguments[e]!=null?arguments[e]:{};e%2?_e(Object(a),!0).forEach(function(r){wa(t,r,a[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):_e(Object(a)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(a,r))})}return t}function wa(t,e,a){return(e=Ma(e))in t?Object.defineProperty(t,e,{value:a,enumerable:!0,configurable:!0,writable:!0}):t[e]=a,t}function Ma(t){var e=Da(t,"string");return typeof e=="symbol"?e:e+""}function Da(t,e){if(typeof t!="object"||!t)return t;var a=t[Symbol.toPrimitive];if(a!==void 0){var r=a.call(t,e);if(typeof r!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function se(t,e){if(t==null)return{};var a,r,i=La(t,e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);for(r=0;r<n.length;r++)a=n[r],e.indexOf(a)===-1&&{}.propertyIsEnumerable.call(t,a)&&(i[a]=t[a])}return i}function La(t,e){if(t==null)return{};var a={};for(var r in t)if({}.hasOwnProperty.call(t,r)){if(e.indexOf(r)!==-1)continue;a[r]=t[r]}return a}var _a=t=>{var{dataKey:e,name:a,fill:r,legendType:i,hide:n}=t;return[{inactive:n,dataKey:e,type:i,color:r,value:We(a,e),payload:t}]},za=f.memo(t=>{var{dataKey:e,stroke:a,strokeWidth:r,fill:i,name:n,hide:c,unit:s,tooltipType:m,id:l}=t,o={dataDefinedOnItem:void 0,getPosition:St,settings:{stroke:a,strokeWidth:r,fill:i,dataKey:e,nameKey:void 0,name:We(n,e),hide:c,type:m,color:i,unit:s,graphicalItemId:l}};return f.createElement(Pt,{tooltipEntrySettings:o})});function Ka(t){var e=oe(Ve),{data:a,dataKey:r,background:i,allOtherBarProps:n}=t,{onMouseEnter:c,onMouseLeave:s,onClick:m}=n,l=se(n,Oa),o=Ye(c,r,n.id),u=Xe(s),v=qe(m,r,n.id);if(!i||a==null)return null;var x=Mt(i);return f.createElement(ye,{zIndex:ea(i,ge.barBackground)},a.map((p,g)=>{var{value:b,background:d,tooltipPosition:h}=p,y=se(p,Ba);if(!d)return null;var k=o(p,g),C=u(p,g),A=v(p,g),P=M(M(M(M(M({option:i,isActive:String(g)===e},y),{},{fill:"#eee"},d),x),Ue(l,p,g)),{},{onMouseEnter:k,onMouseLeave:C,onClick:A,dataKey:r,index:g,className:"recharts-bar-background-rectangle"});return f.createElement(ke,F({key:"background-bar-".concat(g)},P))}))}function Na(t){var{showLabels:e,children:a,rects:r}=t,i=r?.map(n=>{var c={x:n.x,y:n.y,width:n.width,lowerWidth:n.width,upperWidth:n.width,height:n.height};return M(M({},c),{},{value:n.value,payload:n.payload,parentViewBox:n.parentViewBox,viewBox:c,fill:n.fill})});return f.createElement(zt,{value:e?i:void 0},a)}function Ta(t){var{shape:e,activeBar:a,baseProps:r,entry:i,index:n,dataKey:c}=t,s=oe(Ve),m=oe(Nt),l=a&&String(i.originalDataIndex)===s&&(m==null||c===m),[o,u]=f.useState(!1),[v,x]=f.useState(!1);f.useEffect(()=>{var y;return l?(u(!0),y=requestAnimationFrame(()=>{x(!0)})):x(!1),()=>{cancelAnimationFrame(y)}},[l]);var p=f.useCallback(()=>{l||u(!1)},[l]),g=l&&v,b=l||o,d;l?a===!0?d=e:d=a:d=e;var h=f.createElement(ke,F({},r,{name:String(r.name)},i,{isActive:g,option:d,index:n,dataKey:c,onTransitionEnd:p}));return b?f.createElement(ye,{zIndex:ge.activeBar},f.createElement(Je,{index:i.originalDataIndex},h)):h}function Ra(t){var{shape:e,baseProps:a,entry:r,index:i,dataKey:n}=t;return f.createElement(ke,F({},a,{name:String(a.name)},r,{isActive:!1,option:e,index:i,dataKey:n}))}function Fa(t){var e,{data:a,props:r}=t,i=(e=Kt(r))!==null&&e!==void 0?e:{},{id:n}=i,c=se(i,Ca),{shape:s,dataKey:m,activeBar:l}=r,{onMouseEnter:o,onClick:u,onMouseLeave:v}=r,x=se(r,ja),p=Ye(o,m,n),g=Xe(v),b=qe(u,m,n);return a?f.createElement(f.Fragment,null,a.map((d,h)=>f.createElement(Je,F({index:d.originalDataIndex,key:"rectangle-".concat(d?.x,"-").concat(d?.y,"-").concat(d?.value,"-").concat(h),className:"recharts-bar-rectangle"},Ue(x,d,h),{onMouseEnter:p(d,h),onMouseLeave:g(d,h),onClick:b(d,h)}),l?f.createElement(Ta,{shape:s,activeBar:l,baseProps:c,entry:d,index:h,dataKey:m}):f.createElement(Ra,{shape:s,baseProps:c,entry:d,index:h,dataKey:m})))):null}function $a(t){var{props:e,previousRectanglesRef:a}=t,{data:r,layout:i,isAnimationActive:n,animationBegin:c,animationDuration:s,animationEasing:m,onAnimationEnd:l,onAnimationStart:o}=e,u=a.current,v=Dt(e,"recharts-bar-"),[x,p]=f.useState(!1),g=!x,b=f.useCallback(()=>{typeof l=="function"&&l(),p(!1)},[l]),d=f.useCallback(()=>{typeof o=="function"&&o(),p(!0)},[o]);return f.createElement(Na,{showLabels:g,rects:r},f.createElement(Lt,{animationId:v,begin:c,duration:s,isActive:n,easing:m,onAnimationEnd:b,onAnimationStart:d,key:v},h=>{var y=h===1?r:r?.map((k,C)=>{var A=u&&u[C];if(A)return M(M({},k),{},{x:R(A.x,k.x,h),y:R(A.y,k.y,h),width:R(A.width,k.width,h),height:R(A.height,k.height,h)});if(i==="horizontal"){var P=R(0,k.height,h),w=R(k.stackedBarStart,k.y,h);return M(M({},k),{},{y:w,height:P})}var j=R(0,k.width,h),S=R(k.stackedBarStart,k.x,h);return M(M({},k),{},{width:j,x:S})});return h>0&&(a.current=y??null),y==null?null:f.createElement(le,null,f.createElement(Fa,{props:e,data:y}))}),f.createElement(_t,{label:e.label}),e.children)}function Wa(t){var e=f.useRef(null);return f.createElement($a,{previousRectanglesRef:e,props:t})}var Qe=0,Ga=(t,e)=>{var a=Array.isArray(t.value)?t.value[1]:t.value;return{x:t.x,y:t.y,value:a,errorVal:Ge(t,e)}};class Va extends f.PureComponent{render(){var{hide:e,data:a,dataKey:r,className:i,xAxisId:n,yAxisId:c,needClip:s,background:m,id:l}=this.props;if(e||a==null)return null;var o=lt("recharts-bar",i),u=l;return f.createElement(le,{className:o,id:l},s&&f.createElement("defs",null,f.createElement(Ct,{clipPathId:u,xAxisId:n,yAxisId:c})),f.createElement(le,{className:"recharts-bar-rectangles",clipPath:s?"url(#clipPath-".concat(u,")"):void 0},f.createElement(Ka,{data:a,dataKey:r,background:m,allOtherBarProps:this.props}),f.createElement(Wa,this.props)))}}var Ua={activeBar:!1,animationBegin:0,animationDuration:400,animationEasing:"ease",background:!1,hide:!1,isAnimationActive:"auto",label:!1,legendType:"rect",minPointSize:Qe,xAxisId:0,yAxisId:0,zIndex:ge.bar};function Ya(t){var{xAxisId:e,yAxisId:a,hide:r,legendType:i,minPointSize:n,activeBar:c,animationBegin:s,animationDuration:m,animationEasing:l,isAnimationActive:o}=t,{needClip:u}=Et(e,a),v=Ot(),x=$e(),p=Bt(t.children,be),g=oe(h=>ba(h,t.id,x,p));if(v!=="vertical"&&v!=="horizontal")return null;var b,d=g?.[0];return d==null||d.height==null||d.width==null?b=0:b=v==="vertical"?d.height/2:d.width/2,f.createElement(Vt,{xAxisId:e,yAxisId:a,data:g,dataPointFormatter:Ga,errorBarOffset:b},f.createElement(Va,F({},t,{layout:v,needClip:u,data:g,xAxisId:e,yAxisId:a,hide:r,legendType:i,minPointSize:n,activeBar:c,animationBegin:s,animationDuration:m,animationEasing:l,isAnimationActive:o})))}function Xa(t){var{layout:e,barSettings:{dataKey:a,minPointSize:r,hasCustomShape:i},pos:n,bandSize:c,xAxis:s,yAxis:m,xAxisTicks:l,yAxisTicks:o,stackedData:u,displayedData:v,offset:x,cells:p,parentViewBox:g,dataStartIndex:b}=t,d=e==="horizontal"?m:s,h=u?d.scale.domain():null,y=jt({numericAxis:d}),k=d.scale.map(y);return v.map((C,A)=>{var P,w,j,S,O,K;if(u){var B=u[A+b];if(B==null)return null;P=wt(B,h)}else P=Ge(C,a),Array.isArray(P)||(P=[y,P]);var E=ra(r,Qe)(P[1],A);if(e==="horizontal"){var D,N=m.scale.map(P[0]),L=m.scale.map(P[1]);if(N==null||L==null)return null;w=Be({axis:s,ticks:l,bandSize:c,offset:n.offset,entry:C,index:A}),j=(D=L??N)!==null&&D!==void 0?D:void 0,S=n.size;var _=N-L;if(O=Tt(_)?0:_,K={x:w,y:x.top,width:S,height:x.height},Math.abs(E)>0&&Math.abs(O)<Math.abs(E)){var z=Ce(O||E)*(Math.abs(E)-Math.abs(O));j-=z,O+=z}}else{var T=s.scale.map(P[0]),W=s.scale.map(P[1]);if(T==null||W==null)return null;if(w=T,j=Be({axis:m,ticks:o,bandSize:c,offset:n.offset,entry:C,index:A}),S=W-T,O=n.size,K={x:x.left,y:j,width:x.width,height:O},Math.abs(E)>0&&Math.abs(S)<Math.abs(E)){var U=Ce(S||E)*(Math.abs(E)-Math.abs(S));S+=U}}if(w==null||j==null||S==null||O==null||!i&&(S===0||O===0))return null;var te=M(M({},C),{},{stackedBarStart:k,x:w,y:j,width:S,height:O,value:u?P:P[1],payload:C,background:K,tooltipPosition:{x:w+S/2,y:j+O/2},parentViewBox:g,originalDataIndex:A},p&&p[A]&&p[A].props);return te}).filter(Boolean)}function qa(t){var e=bt(t,Ua),a=Pa(e.stackId),r=$e();return f.createElement(kt,{id:e.id,type:"bar"},i=>f.createElement(f.Fragment,null,f.createElement(It,{legendPayload:_a(e)}),f.createElement(za,{dataKey:e.dataKey,stroke:e.stroke,strokeWidth:e.strokeWidth,fill:e.fill,name:e.name,hide:e.hide,unit:e.unit,tooltipType:e.tooltipType,id:i}),f.createElement(At,{type:"bar",id:i,data:void 0,xAxisId:e.xAxisId,yAxisId:e.yAxisId,zAxisId:0,dataKey:e.dataKey,stackId:a,hide:e.hide,barSize:e.barSize,minPointSize:e.minPointSize,maxBarSize:e.maxBarSize,isPanorama:r,hasCustomShape:e.shape!=null}),f.createElement(ye,{zIndex:e.zIndex},f.createElement(Ya,F({},e,{id:i})))))}var et=f.memo(qa,yt);et.displayName="Bar";var Ha=["axis","item"],Za=f.forwardRef((t,e)=>f.createElement(Rt,{chartName:"BarChart",defaultTooltipEventType:"axis",validateTooltipEventTypes:Ha,tooltipPayloadSearcher:Ft,categoricalChartProps:t,ref:e}));const tt=60*1e3,ce=60*tt,Ja=24*ce,at=25*ce;function he(t,e){if(t.length===0)return 0;const a=[...t].sort((i,n)=>i-n),r=Math.max(0,Math.min(a.length-1,Math.ceil(e*a.length)-1));return a[r]??0}function Qa(t,e){return e<=at?t.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"}):t.toLocaleDateString([],{month:"short",day:"numeric"})}function er(t,e){const a=e-t;return a<=ce?Math.max(1,Math.min(60,Math.ceil(a/tt))):a<=at?Math.max(1,Math.min(25,Math.ceil(a/ce))):Math.max(1,Math.min(31,Math.ceil(a/Ja)))}function tr(t,e,a,r){const i=e.getTime(),n=a.getTime(),c=Math.max(1,n-i),s=er(i,n),m=Math.max(1,Math.floor(c/s)),l=[];for(let o=0;o<s;o++){const u=new Date(i+o*m);l.push({t:u.toISOString(),ts:u.getTime(),label:Qa(u,c),calls:0,errors:0,durations:[]})}for(const o of t){const u=new Date(o.timestamp).getTime(),v=Math.floor((u-i)/m),x=Math.max(0,Math.min(s-1,v)),p=l[x];p&&(p.calls+=1,o.isError&&(p.errors+=1),Number.isFinite(o.durationMs)&&p.durations.push(o.durationMs))}return l.map(o=>({t:o.t,ts:o.ts,label:o.label,calls:o.calls,errors:o.errors,errorRate:o.calls>0?o.errors/o.calls*100:0,avg:Math.round(o.durations.length>0?o.durations.reduce((u,v)=>u+v,0)/o.durations.length:0),p50:Math.round(he(o.durations,.5)),p95:Math.round(he(o.durations,.95))}))}function sr(t,e,a,r,i){const n=r??t.length,c=i??t.filter(u=>u.isError).length,s=t.map(u=>u.durationMs),m=s.length>0?s.reduce((u,v)=>u+v,0)/s.length:0,l=he(s,.95),o=tr(t,e.startDate,e.endDate);return{totalCalls:n,totalErrors:c,avgDurationMs:m,p95DurationMs:l,data:o}}function ze(t){return t>=1e3?`${(t/1e3).toFixed(1)}k`:String(t)}function Ke(t){const e=Ne.c(19),{active:a,payload:r,dataKey:i,colorVar:n}=t;if(!a||!r?.length)return null;const c=r[0],s=c?.payload?.t??"";let m;e[0]!==c?.payload?.label||e[1]!==s?(m=s?new Date(s).toLocaleString([],{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"}):c?.payload?.label??"",e[0]=c?.payload?.label,e[1]=s,e[2]=m):m=e[2];const l=m,o=c?.value,u=typeof o=="number"?o:0,v=i==="avg"||i==="p50"||i==="p95",x=i==="costUsd";let p;e[3]!==x||e[4]!==v||e[5]!==u?(p=x?`$${u.toFixed(u<1?4:2)}`:v?u>=1e4?`${(u/1e3).toFixed(1)}s`:`${Math.round(u)}ms`:u.toLocaleString(),e[3]=x,e[4]=v,e[5]=u,e[6]=p):p=e[6];const g=p;let b;e[7]!==l?(b=I.jsx("div",{className:"text-[11px] text-muted-foreground mb-1",children:l}),e[7]=l,e[8]=b):b=e[8];let d;e[9]!==n?(d=I.jsx("div",{className:"size-2 shrink-0 rounded-full",style:{backgroundColor:n}}),e[9]=n,e[10]=d):d=e[10];let h;e[11]!==g?(h=I.jsx("span",{className:"text-xs font-medium tabular-nums",children:g}),e[11]=g,e[12]=h):h=e[12];let y;e[13]!==d||e[14]!==h?(y=I.jsxs("div",{className:"flex items-center gap-1.5",children:[d,h]}),e[13]=d,e[14]=h,e[15]=y):y=e[15];let k;return e[16]!==b||e[17]!==y?(k=I.jsxs("div",{className:"rounded-lg border bg-background px-3 py-2 shadow-md",children:[b,y]}),e[16]=b,e[17]=y,e[18]=k):k=e[18],k}function cr(t){const e=Ne.c(85),{data:a,dataKey:r,colorNum:i,chartHeight:n,variant:c,ariaLabel:s}=t,m=c===void 0?"bar":c,l=`var(--chart-${i})`,o=`kpi-gradient-${r}-${i}`,u=Math.max(...a.map(B=>B[r]??0),0);if(m==="area"){let B;e[0]!==n?(B=Ie(n,"w-full"),e[0]=n,e[1]=B):B=e[1];let E;e[2]!==l||e[3]!==r?(E={label:r,color:l},e[2]=l,e[3]=r,e[4]=E):E=e[4];let D;e[5]!==r||e[6]!==E?(D={[r]:E},e[5]=r,e[6]=E,e[7]=D):D=e[7];let N;e[8]===Symbol.for("react.memo_cache_sentinel")?(N={left:0,right:-12,top:8,bottom:8},e[8]=N):N=e[8];let L,_;e[9]!==l?(L=I.jsx("stop",{offset:"0%",stopColor:l,stopOpacity:.2}),_=I.jsx("stop",{offset:"100%",stopColor:l,stopOpacity:0}),e[9]=l,e[10]=L,e[11]=_):(L=e[10],_=e[11]);let z;e[12]!==o||e[13]!==L||e[14]!==_?(z=I.jsx("defs",{children:I.jsxs("linearGradient",{id:o,x1:"0",y1:"0",x2:"0",y2:"1",children:[L,_]})}),e[12]=o,e[13]=L,e[14]=_,e[15]=z):z=e[15];let T;e[16]===Symbol.for("react.memo_cache_sentinel")?(T=I.jsx(je,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),e[16]=T):T=e[16];let W;e[17]===Symbol.for("react.memo_cache_sentinel")?(W=I.jsx(Me,{dataKey:"label",axisLine:!1,tickLine:!1,tick:{fontSize:11,fill:"var(--muted-foreground)",opacity:.7},interval:"preserveStartEnd",tickMargin:8}),e[17]=W):W=e[17];let U;e[18]===Symbol.for("react.memo_cache_sentinel")?(U={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[18]=U):U=e[18];const te=u>0?"auto":10;let Y;e[19]!==te?(Y=I.jsx(we,{orientation:"right",axisLine:!1,tickLine:!1,tick:U,tickFormatter:ze,width:40,domain:[0,te],tickCount:5}),e[19]=te,e[20]=Y):Y=e[20];let re;e[21]===Symbol.for("react.memo_cache_sentinel")?(re={stroke:"var(--border)",strokeDasharray:"4 4"},e[21]=re):re=e[21];let X;e[22]!==l||e[23]!==r?(X=I.jsx(Ae,{cursor:re,content:rt=>{const{active:nt,payload:it}=rt;return I.jsx(Ke,{active:nt,payload:it,dataKey:r,colorVar:l})}}),e[22]=l,e[23]=r,e[24]=X):X=e[24];const de=`url(#${o})`;let q;e[25]!==l?(q={r:4,fill:l,stroke:"var(--background)",strokeWidth:2},e[25]=l,e[26]=q):q=e[26];let H;e[27]!==l||e[28]!==r||e[29]!==de||e[30]!==q?(H=I.jsx($t,{type:"linear",dataKey:r,stroke:l,strokeWidth:2,fill:de,animationDuration:300,dot:!1,activeDot:q}),e[27]=l,e[28]=r,e[29]=de,e[30]=q,e[31]=H):H=e[31];let Z;e[32]!==a||e[33]!==Y||e[34]!==X||e[35]!==H||e[36]!==z?(Z=I.jsxs(Wt,{data:a,margin:N,children:[z,T,W,Y,X,H]}),e[32]=a,e[33]=Y,e[34]=X,e[35]=H,e[36]=z,e[37]=Z):Z=e[37];let ne;return e[38]!==s||e[39]!==Z||e[40]!==B||e[41]!==D?(ne=I.jsx(Pe,{role:"img","aria-label":s,className:B,config:D,children:Z}),e[38]=s,e[39]=Z,e[40]=B,e[41]=D,e[42]=ne):ne=e[42],ne}let v;e[43]!==n?(v=Ie(n,"w-full"),e[43]=n,e[44]=v):v=e[44];let x;e[45]!==l||e[46]!==r?(x={label:r,color:l},e[45]=l,e[46]=r,e[47]=x):x=e[47];let p;e[48]!==r||e[49]!==x?(p={[r]:x},e[48]=r,e[49]=x,e[50]=p):p=e[50];let g,b;e[51]===Symbol.for("react.memo_cache_sentinel")?(g={left:0,right:-12,top:8,bottom:8},b=I.jsx(je,{strokeDasharray:"4 4",stroke:"var(--border)",strokeOpacity:.5,vertical:!1}),e[51]=g,e[52]=b):(g=e[51],b=e[52]);let d;e[53]===Symbol.for("react.memo_cache_sentinel")?(d={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[53]=d):d=e[53];const h=a.length<=6?0:Math.floor(a.length/6);let y;e[54]!==h?(y=I.jsx(Me,{dataKey:"label",axisLine:!1,tickLine:!1,tick:d,interval:h,tickMargin:8}),e[54]=h,e[55]=y):y=e[55];let k;e[56]===Symbol.for("react.memo_cache_sentinel")?(k={fontSize:11,fill:"var(--muted-foreground)",opacity:.7},e[56]=k):k=e[56];const C=u>0?"auto":10;let A;e[57]!==C?(A=I.jsx(we,{orientation:"right",axisLine:!1,tickLine:!1,tick:k,tickFormatter:ze,width:40,domain:[0,C],tickCount:5}),e[57]=C,e[58]=A):A=e[58];let P;e[59]===Symbol.for("react.memo_cache_sentinel")?(P={fill:"var(--muted)",opacity:.3},e[59]=P):P=e[59];let w;e[60]!==l||e[61]!==r?(w=I.jsx(Ae,{cursor:P,content:B=>{const{active:E,payload:D}=B;return I.jsx(Ke,{active:E,payload:D,dataKey:r,colorVar:l})}}),e[60]=l,e[61]=r,e[62]=w):w=e[62];let j;if(e[63]!==l||e[64]!==a||e[65]!==r){let B;e[67]!==l||e[68]!==r?(B=(E,D)=>I.jsx(be,{fill:(E[r]??0)===0?"var(--muted-foreground)":l,fillOpacity:(E[r]??0)===0?.15:.85},`cell-${D}`),e[67]=l,e[68]=r,e[69]=B):B=e[69],j=a.map(B),e[63]=l,e[64]=a,e[65]=r,e[66]=j}else j=e[66];let S;e[70]!==l||e[71]!==r||e[72]!==j?(S=I.jsx(et,{dataKey:r,fill:l,radius:0,minPointSize:1,children:j}),e[70]=l,e[71]=r,e[72]=j,e[73]=S):S=e[73];let O;e[74]!==a||e[75]!==A||e[76]!==w||e[77]!==S||e[78]!==y?(O=I.jsxs(Za,{data:a,margin:g,children:[b,y,A,w,S]}),e[74]=a,e[75]=A,e[76]=w,e[77]=S,e[78]=y,e[79]=O):O=e[79];let K;return e[80]!==s||e[81]!==O||e[82]!==v||e[83]!==p?(K=I.jsx(Pe,{role:"img","aria-label":s,className:v,config:p,children:O}),e[80]=s,e[81]=O,e[82]=v,e[83]=p,e[84]=K):K=e[84],K}export{Za as B,be as C,cr as K,et as a,sr as c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as fe,r as Z,l as he,j as t,B as pe}from"./index-
|
|
1
|
+
import{c as fe,r as Z,l as he,j as t,B as pe}from"./index-D3VyLkC3.js";import{B as re}from"./badge-D10nU5hm.js";import{C as ce}from"./checkbox-CAXlLvHp.js";import{t as de}from"./ChevronUp-XuQjQLoK.js";import{C as xe,a as ge,b as me,c as ve,e as je,f as Ce}from"./command-BUcXz1jA.js";import{a as be,b as Ne,P as ye}from"./popover-DmsBpt35.js";const we=[];function Ae(o){const e=fe.c(72),{options:n,onValueChange:i,defaultValue:ee,placeholder:te,variant:se,animation:le,maxCount:ae,modalPopover:ne,asChild:ie,className:J,disabled:oe,onSearchChange:P}=o,d=ee===void 0?we:ee,Y=te===void 0?"Select items":te,V=se===void 0?"default":se,_=le===void 0?0:le,k=ae===void 0?3:ae,F=ne===void 0?!1:ne,G=ie===void 0?!1:ie,L=oe===void 0?!1:oe,[s,S]=Z.useState(d),[q,E]=Z.useState(!1);let O,B;e[0]!==d||e[1]!==s?(B=()=>{JSON.stringify(s)!==JSON.stringify(d)&&S(d)},O=[d,s],e[0]=d,e[1]=s,e[2]=O,e[3]=B):(O=e[2],B=e[3]),Z.useEffect(B,O);let D;e[4]!==i||e[5]!==s?(D=l=>{if(l.key==="Enter")E(!0);else if(l.key==="Backspace"&&!l.currentTarget.value){const a=[...s];a.pop(),S(a),i(a)}},e[4]=i,e[5]=s,e[6]=D):D=e[6];const H=D;let I;e[7]!==i||e[8]!==s?(I=l=>{const a=s.includes(l.value)?s.filter(w=>w!==l.value):[...s,l.value];S(a),i(a)},e[7]=i,e[8]=s,e[9]=I):I=e[9];const c=I;let A;e[10]!==i?(A=()=>{S([]),i([])},e[10]=i,e[11]=A):A=e[11];const Q=A;let R;e[12]===Symbol.for("react.memo_cache_sentinel")?(R=()=>{E(Ve)},e[12]=R):R=e[12];const ue=R;let T;e[13]!==Q||e[14]!==i||e[15]!==n||e[16]!==s.length?(T=()=>{if(s.length===n.length)Q();else{const l=n.map(Pe);S(l),i(l)}},e[13]=Q,e[14]=i,e[15]=n,e[16]=s.length,e[17]=T):T=e[17];const r=T;let m;e[18]!==G?(m=G?{}:{variant:"outline"},e[18]=G,e[19]=m):m=e[19];let u;e[20]!==J?(u=he("border-input data-[placeholder]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/20 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-full max-w-xs items-center justify-between gap-2 border bg-transparent px-3 py-2 text-sm shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[2px] disabled:cursor-not-allowed disabled:opacity-50 h-10 min-h-10",J),e[20]=J,e[21]=u):u=e[21];let f;e[22]!==_||e[23]!==k||e[24]!==n||e[25]!==Y||e[26]!==s||e[27]!==V?(f=s.length>0?t.jsxs("div",{className:"flex items-center justify-between w-full min-w-0",children:[t.jsxs("div",{className:"flex items-center gap-1 min-w-0 flex-1",children:[s.slice(0,k).map(l=>{const a=n.find(X=>X.value===l),w=a?.icon;return t.jsxs(re,{variant:V==="default"?"default":"secondary",className:"max-w-24",style:{animationDuration:`${_}s`},children:[w&&t.jsx(w,{className:"h-3 w-3 shrink-0"}),t.jsx("span",{className:"truncate",children:a?.label})]},l)}),s.length>k&&t.jsxs(re,{variant:V==="default"?"default":"secondary",className:"flex-shrink-0",style:{animationDuration:`${_}s`},children:["+",s.length-k]})]}),t.jsx("div",{className:"flex items-center shrink-0 ml-2",children:t.jsx(de,{size:20,className:"shrink-0 opacity-50"})})]}):t.jsxs("div",{className:"flex items-center justify-between w-full",children:[t.jsx("span",{className:"text-sm text-muted-foreground",children:Y}),t.jsx(de,{size:20,className:"shrink-0 opacity-50"})]}),e[22]=_,e[23]=k,e[24]=n,e[25]=Y,e[26]=s,e[27]=V,e[28]=f):f=e[28];let h;e[29]!==L||e[30]!==m||e[31]!==u||e[32]!==f?(h=t.jsx(be,{asChild:!0,children:t.jsx(pe,{ref:null,...m,onClick:ue,className:u,disabled:L,children:f})}),e[29]=L,e[30]=m,e[31]=u,e[32]=f,e[33]=h):h=e[33];let K;e[34]===Symbol.for("react.memo_cache_sentinel")?(K=()=>E(!1),e[34]=K):K=e[34];const U=!P;let p;e[35]!==H||e[36]!==P?(p=t.jsx(xe,{placeholder:"Search...",onKeyDown:H,onValueChange:P,className:"rounded-t-xl"}),e[35]=H,e[36]=P,e[37]=p):p=e[37];let M;e[38]===Symbol.for("react.memo_cache_sentinel")?(M=t.jsx(ge,{children:"No results found."}),e[38]=M):M=e[38];let x;e[39]!==r?(x=()=>{r()},e[39]=r,e[40]=x):x=e[40];let g;e[41]!==r?(g=l=>{l.stopPropagation(),r()},e[41]=r,e[42]=g):g=e[42];const W=s.length===n.length&&n.length>0;let v;e[43]!==W||e[44]!==r?(v=t.jsx(ce,{checked:W,onCheckedChange:r,className:"mr-2 [&_svg]:!text-primary-foreground",onClick:Se}),e[43]=W,e[44]=r,e[45]=v):v=e[45];let $;e[46]===Symbol.for("react.memo_cache_sentinel")?($=t.jsx("span",{children:"(Select All)"}),e[46]=$):$=e[46];let j;e[47]!==g||e[48]!==v?(j=t.jsxs("div",{className:"flex items-center w-full",onClick:g,children:[v,$]}),e[47]=g,e[48]=v,e[49]=j):j=e[49];let C;e[50]!==x||e[51]!==j?(C=t.jsx(me,{onSelect:x,className:"cursor-pointer",children:j},"all"),e[50]=x,e[51]=j,e[52]=C):C=e[52];let b;if(e[53]!==n||e[54]!==s||e[55]!==c){let l;e[57]!==s||e[58]!==c?(l=a=>{const w=s.includes(a.value);return t.jsx(me,{onSelect:()=>{c(a)},className:"cursor-pointer",children:t.jsxs("div",{className:"flex items-center w-full",onClick:X=>{X.stopPropagation(),c(a)},children:[t.jsx(ce,{checked:w,onCheckedChange:()=>{c(a)},className:"mr-2 [&_svg]:!text-primary-foreground",onClick:ke}),a.icon&&t.jsx(a.icon,{className:"mr-2 h-4 w-4 text-muted-foreground"}),t.jsx("span",{children:a.label})]})},a.value)},e[57]=s,e[58]=c,e[59]=l):l=e[59],b=n.map(l),e[53]=n,e[54]=s,e[55]=c,e[56]=b}else b=e[56];let N;e[60]!==C||e[61]!==b?(N=t.jsxs(ve,{className:"rounded-b-xl",children:[M,t.jsxs(je,{children:[C,b]})]}),e[60]=C,e[61]=b,e[62]=N):N=e[62];let y;e[63]!==U||e[64]!==p||e[65]!==N?(y=t.jsx(Ne,{className:"w-auto p-0 max-w-xs rounded-xl",align:"start",onEscapeKeyDown:K,children:t.jsxs(Ce,{shouldFilter:U,className:"rounded-xl",children:[p,N]})}),e[63]=U,e[64]=p,e[65]=N,e[66]=y):y=e[66];let z;return e[67]!==q||e[68]!==F||e[69]!==h||e[70]!==y?(z=t.jsxs(ye,{open:q,onOpenChange:E,modal:F,children:[h,y]}),e[67]=q,e[68]=F,e[69]=h,e[70]=y,e[71]=z):z=e[71],z}function ke(o){return o.stopPropagation()}function Se(o){return o.stopPropagation()}function Pe(o){return o.value}function Ve(o){return!o}export{Ae as M};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{o as B,e as z,K as O,b as F,r as J,j as w,B as q,t as U}from"./index-
|
|
1
|
+
import{o as B,e as z,K as O,b as F,r as J,j as w,B as q,t as U}from"./index-D3VyLkC3.js";import{u as V}from"./use-session-runtime-BtoYTkvM.js";import{u as _,z as H,A as $,B as G,y as L,q as Y}from"./claim-phase-copy-DZ3Yirir.js";import{h as X,n as Z,i as I}from"./runnable-block-editor-PtJtt2DC.js";import{o as M}from"./sandbox-git-api-B1R0585s.js";import{u as ee}from"./chat-context-Crr9YCN0.js";import{b as te}from"./sandbox-url-D3mC8qhT.js";import{a as re}from"./utils-R-urxMSv.js";import{i as se}from"./CheckCircle-B8nBZ9lR.js";import{a as ne}from"./Copy01-YmLU_wow.js";import{D as ae,b as ie,c as oe,d as ce}from"./dialog-C_zHR8DK.js";import{M as ue}from"./monaco-editor-Cs1rDRDm.js";function Qe({orgSlug:s,virtualMcpId:e,branch:t}){const r=B(),a=ee()?.taskId??null,n=X(e),i=V(e).runtime==="cms",{url:o}=_(e),c=Z({orgSlug:s,virtualMcpId:e,branch:t,localPreviewUrl:o});return z({mutationKey:Y(s,e,t),scope:L(s,e,t),mutationFn:async({blockKey:u})=>{if(o)return{ok:!0,existed:!0};if(i){const h=await H({orgSlug:s,virtualMcpId:e,branch:t},{delete:[u]});return $(r,{orgSlug:s,virtualMcpId:e,branch:t},h),await r.invalidateQueries({queryKey:M({orgSlug:s,virtualMcpId:e,branch:t,threadId:a})}),{ok:!0,existed:!0}}const f=I(n,re(u)),l=await fetch(te({orgSlug:s,virtualMcpId:e,branch:t,threadId:a},"unlink"),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({path:f})});return l.ok?l.json():G(l,"Delete")},onMutate:async({blockKey:u})=>{const f=O.decofile(c);await r.cancelQueries({queryKey:f});const l=r.getQueryData(f),h=!!l&&u in l,C=l?.[u];return r.setQueryData(f,b=>{if(!b)return b;const{[u]:p,...g}=b;return g}),{queryKey:f,blockKey:u,hadKey:h,previousValue:C}},onError:(u,f,l)=>{l&&r.setQueryData(l.queryKey,h=>l.hadKey?{...h??{},[l.blockKey]:l.previousValue}:h)},onSuccess:()=>{r.invalidateQueries({queryKey:O.liveMeta(s,e,t)})}})}function We({open:s,onOpenChange:e,pageKey:t,decofile:r,onSave:a}){const n=F(),i=r[t],o=i===void 0,c=o?"":JSON.stringify(i,null,2),[u,f]=J.useState(!1),[l,h]=J.useState(c),[C,b]=J.useState(!1),p=!a||o,g=l!==c,d=()=>{navigator.clipboard.writeText(l).then(()=>{f(!0),setTimeout(()=>f(!1),2e3)})},v=async m=>{if(!a||C)return;let S;try{S=JSON.parse(m)}catch{U.error(n("sectionsEditor.pageJsonDialog.invalidJsonError"));return}b(!0);try{await a(S),U.success(n("sectionsEditor.pageJsonDialog.saveSuccess")),e(!1)}catch(E){U.error(n("sectionsEditor.pageJsonDialog.saveError",{error:E instanceof Error?E.message:String(E)}))}finally{b(!1)}};return w.jsx(ae,{open:s,onOpenChange:e,children:w.jsxs(ie,{className:"flex h-[85vh] w-[95vw] flex-col gap-0 overflow-hidden p-0 sm:max-w-6xl",children:[w.jsxs(oe,{className:"shrink-0 px-4 py-3 border-b flex-row items-center justify-between space-y-0",children:[w.jsx(ce,{className:"text-sm font-semibold",children:n("sectionsEditor.pageJsonDialog.title")}),w.jsxs("div",{className:"flex items-center gap-2 mr-8",children:[w.jsxs(q,{variant:"ghost",size:"sm",onClick:d,className:"h-7 gap-1.5 text-xs",children:[u?w.jsx(se,{size:12}):w.jsx(ne,{size:12}),n(u?"sectionsEditor.pageJsonDialog.copied":"sectionsEditor.pageJsonDialog.copy")]}),!p&&w.jsx(q,{size:"sm",onClick:()=>v(l),disabled:!g||C,className:"h-7 text-xs",children:n(C?"sectionsEditor.pageJsonDialog.saving":"sectionsEditor.pageJsonDialog.save")})]})]}),o?w.jsxs("div",{className:"p-4 text-xs font-mono text-foreground/60",children:["// ",n("sectionsEditor.pageJsonDialog.pageNotFound")]}):w.jsx("div",{className:"min-h-0 flex-1 py-2",children:w.jsx(ue,{code:c,language:"json",readOnly:p,height:"100%",onChange:m=>h(m??""),onSave:m=>{v(m)}})})]})})}var le=Object.prototype.toString,j=Array.isArray||function(e){return le.call(e)==="[object Array]"};function K(s){return typeof s=="function"}function fe(s){return j(s)?"array":typeof s}function N(s){return s.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function A(s,e){return s!=null&&typeof s=="object"&&e in s}function pe(s,e){return s!=null&&typeof s!="object"&&s.hasOwnProperty&&s.hasOwnProperty(e)}var he=RegExp.prototype.test;function de(s,e){return he.call(s,e)}var ve=/\S/;function ye(s){return!de(ve,s)}var ge={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/","`":"`","=":"="};function we(s){return String(s).replace(/[&<>"'`=\/]/g,function(t){return ge[t]})}var me=/\s*/,Ee=/\s+/,Q=/\s*=/,xe=/\s*\}/,be=/#|\^|\/|>|\{|&|=|!/;function ke(s,e){if(!s)return[];var t=!1,r=[],a=[],n=[],i=!1,o=!1,c="",u=0;function f(){if(i&&!o)for(;n.length;)delete a[n.pop()];else n=[];i=!1,o=!1}var l,h,C;function b(k){if(typeof k=="string"&&(k=k.split(Ee,2)),!j(k)||k.length!==2)throw new Error("Invalid tags: "+k);l=new RegExp(N(k[0])+"\\s*"),h=new RegExp("\\s*"+N(k[1])),C=new RegExp("\\s*"+N("}"+k[1]))}b(e||x.tags);for(var p=new R(s),g,d,v,m,S,E;!p.eos();){if(g=p.pos,v=p.scanUntil(l),v)for(var T=0,W=v.length;T<W;++T)m=v.charAt(T),ye(m)?(n.push(a.length),c+=m):(o=!0,t=!0,c+=" "),a.push(["text",m,g,g+1]),g+=1,m===`
|
|
2
2
|
`&&(f(),c="",u=0,t=!1);if(!p.scan(l))break;if(i=!0,d=p.scan(be)||"name",p.scan(me),d==="="?(v=p.scanUntil(Q),p.scan(Q),p.scanUntil(h)):d==="{"?(v=p.scanUntil(C),p.scan(xe),p.scanUntil(h),d="&"):v=p.scanUntil(h),!p.scan(h))throw new Error("Unclosed tag at "+p.pos);if(d==">"?S=[d,v,g,p.pos,c,u,t]:S=[d,v,g,p.pos],u++,a.push(S),d==="#"||d==="^")r.push(S);else if(d==="/"){if(E=r.pop(),!E)throw new Error('Unopened section "'+v+'" at '+g);if(E[1]!==v)throw new Error('Unclosed section "'+E[1]+'" at '+g)}else d==="name"||d==="{"||d==="&"?o=!0:d==="="&&b(v)}if(f(),E=r.pop(),E)throw new Error('Unclosed section "'+E[1]+'" at '+p.pos);return Se(Ce(a))}function Ce(s){for(var e=[],t,r,a=0,n=s.length;a<n;++a)t=s[a],t&&(t[0]==="text"&&r&&r[0]==="text"?(r[1]+=t[1],r[3]=t[3]):(e.push(t),r=t));return e}function Se(s){for(var e=[],t=e,r=[],a,n,i=0,o=s.length;i<o;++i)switch(a=s[i],a[0]){case"#":case"^":t.push(a),r.push(a),t=a[4]=[];break;case"/":n=r.pop(),n[5]=a[2],t=r.length>0?r[r.length-1][4]:e;break;default:t.push(a)}return e}function R(s){this.string=s,this.tail=s,this.pos=0}R.prototype.eos=function(){return this.tail===""};R.prototype.scan=function(e){var t=this.tail.match(e);if(!t||t.index!==0)return"";var r=t[0];return this.tail=this.tail.substring(r.length),this.pos+=r.length,r};R.prototype.scanUntil=function(e){var t=this.tail.search(e),r;switch(t){case-1:r=this.tail,this.tail="";break;case 0:r="";break;default:r=this.tail.substring(0,t),this.tail=this.tail.substring(t)}return this.pos+=r.length,r};function D(s,e){this.view=s,this.cache={".":this.view},this.parent=e}D.prototype.push=function(e){return new D(e,this)};D.prototype.lookup=function(e){var t=this.cache,r;if(t.hasOwnProperty(e))r=t[e];else{for(var a=this,n,i,o,c=!1;a;){if(e.indexOf(".")>0)for(n=a.view,i=e.split("."),o=0;n!=null&&o<i.length;)o===i.length-1&&(c=A(n,i[o])||pe(n,i[o])),n=n[i[o++]];else n=a.view[e],c=A(a.view,e);if(c){r=n;break}a=a.parent}t[e]=r}return K(r)&&(r=r.call(this.view)),r};function y(){this.templateCache={_cache:{},set:function(e,t){this._cache[e]=t},get:function(e){return this._cache[e]},clear:function(){this._cache={}}}}y.prototype.clearCache=function(){typeof this.templateCache<"u"&&this.templateCache.clear()};y.prototype.parse=function(e,t){var r=this.templateCache,a=e+":"+(t||x.tags).join(":"),n=typeof r<"u",i=n?r.get(a):void 0;return i==null&&(i=ke(e,t),n&&r.set(a,i)),i};y.prototype.render=function(e,t,r,a){var n=this.getConfigTags(a),i=this.parse(e,n),o=t instanceof D?t:new D(t,void 0);return this.renderTokens(i,o,r,e,a)};y.prototype.renderTokens=function(e,t,r,a,n){for(var i="",o,c,u,f=0,l=e.length;f<l;++f)u=void 0,o=e[f],c=o[0],c==="#"?u=this.renderSection(o,t,r,a,n):c==="^"?u=this.renderInverted(o,t,r,a,n):c===">"?u=this.renderPartial(o,t,r,n):c==="&"?u=this.unescapedValue(o,t):c==="name"?u=this.escapedValue(o,t,n):c==="text"&&(u=this.rawValue(o)),u!==void 0&&(i+=u);return i};y.prototype.renderSection=function(e,t,r,a,n){var i=this,o="",c=t.lookup(e[1]);function u(h){return i.render(h,t,r,n)}if(c){if(j(c))for(var f=0,l=c.length;f<l;++f)o+=this.renderTokens(e[4],t.push(c[f]),r,a,n);else if(typeof c=="object"||typeof c=="string"||typeof c=="number")o+=this.renderTokens(e[4],t.push(c),r,a,n);else if(K(c)){if(typeof a!="string")throw new Error("Cannot use higher-order sections without the original template");c=c.call(t.view,a.slice(e[3],e[5]),u),c!=null&&(o+=c)}else o+=this.renderTokens(e[4],t,r,a,n);return o}};y.prototype.renderInverted=function(e,t,r,a,n){var i=t.lookup(e[1]);if(!i||j(i)&&i.length===0)return this.renderTokens(e[4],t,r,a,n)};y.prototype.indentPartial=function(e,t,r){for(var a=t.replace(/[^ \t]/g,""),n=e.split(`
|
|
3
3
|
`),i=0;i<n.length;i++)n[i].length&&(i>0||!r)&&(n[i]=a+n[i]);return n.join(`
|
|
4
4
|
`)};y.prototype.renderPartial=function(e,t,r,a){if(r){var n=this.getConfigTags(a),i=K(r)?r(e[1]):r[e[1]];if(i!=null){var o=e[6],c=e[5],u=e[4],f=i;c==0&&u&&(f=this.indentPartial(i,u,o));var l=this.parse(f,n);return this.renderTokens(l,t,r,f,a)}}};y.prototype.unescapedValue=function(e,t){var r=t.lookup(e[1]);if(r!=null)return r};y.prototype.escapedValue=function(e,t,r){var a=this.getConfigEscape(r)||x.escape,n=t.lookup(e[1]);if(n!=null)return typeof n=="number"&&a===x.escape?String(n):a(n)};y.prototype.rawValue=function(e){return e[1]};y.prototype.getConfigTags=function(e){return j(e)?e:e&&typeof e=="object"?e.tags:void 0};y.prototype.getConfigEscape=function(e){if(e&&typeof e=="object"&&!j(e))return e.escape};var x={name:"mustache.js",version:"4.2.0",tags:["{{","}}"],clearCache:void 0,escape:void 0,parse:void 0,render:void 0,Scanner:void 0,Context:void 0,Writer:void 0,set templateCache(s){P.templateCache=s},get templateCache(){return P.templateCache}},P=new y;x.clearCache=function(){return P.clearCache()};x.parse=function(e,t){return P.parse(e,t)};x.render=function(e,t,r,a){if(typeof e!="string")throw new TypeError('Invalid template! Template should be a "string" but "'+fe(e)+'" was given as the first argument for mustache#render(template, view, partials)');return P.render(e,t,r,a)};x.escape=we;x.Scanner=R;x.Context=D;x.Writer=y;export{We as P,x as m,Qe as u};
|
package/dist/client/assets/{new-project-dialog-QzgehZk_.js → new-project-dialog-BWolKWvl.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as y,j as t,r as w,q as _,b as S,B as N,l as M,t as K}from"./index-
|
|
1
|
+
import{c as y,j as t,r as w,q as _,b as S,B as N,l as M,t as K}from"./index-D3VyLkC3.js";import{i as A}from"./ArrowLeft-Bgwvgp7N.js";import{s as R}from"./Plus-B7fu2HeJ.js";import{D as E,b as T,c as V,d as $,h as B}from"./dialog-C_zHR8DK.js";import{I as F}from"./input-B-l5PYzO.js";import{L as H}from"./label-UBdu3ctU.js";import{R as L}from"./repository-import-picker-BxSMVAOp.js";import{u as O}from"./use-navigate-to-agent-Bbk9KV3t.js";import{S as z}from"./thread-intent-CXrPEeI-.js";import{e as Z}from"./repository-binding-qP9N-2MJ.js";const D={viewBox:"0 0 96 64",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":!0},l={stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"};function q(i){const e=y.c(9),{className:n}=i;let r,o,s,c,a,u,h;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx("path",{d:"M22 46V22",...l,opacity:.7}),o=t.jsx("circle",{cx:"22",cy:"18",r:"4",...l,opacity:.8}),s=t.jsx("circle",{cx:"22",cy:"50",r:"4",...l,opacity:.8}),c=t.jsx("path",{d:"M22 32h14a6 6 0 0 1 6 6v4",...l,opacity:.6}),a=t.jsx("circle",{cx:"42",cy:"46",r:"4",...l,opacity:.7}),u=t.jsx("path",{d:"M56 22h9l3 4h14a3 3 0 0 1 3 3v20a3 3 0 0 1-3 3H56a3 3 0 0 1-3-3V25a3 3 0 0 1 3-3Z",...l,opacity:.75}),h=t.jsx("path",{d:"M53 34h32",...l,opacity:.5}),e[0]=r,e[1]=o,e[2]=s,e[3]=c,e[4]=a,e[5]=u,e[6]=h):(r=e[0],o=e[1],s=e[2],c=e[3],a=e[4],u=e[5],h=e[6]);let d;return e[7]!==n?(d=t.jsxs("svg",{...D,className:n,children:[r,o,s,c,a,u,h]}),e[7]=n,e[8]=d):d=e[8],d}function I(i){const e=y.c(4),{className:n}=i;let r,o;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsx("path",{d:"M16 22a4 4 0 0 1 4-4h14l6 6h20a4 4 0 0 1 4 4v20a4 4 0 0 1-4 4H20a4 4 0 0 1-4-4V22Z",...l,opacity:.8}),o=t.jsx("path",{d:"M16 28h64",...l,opacity:.5}),e[0]=r,e[1]=o):(r=e[0],o=e[1]);let s;return e[2]!==n?(s=t.jsxs("svg",{...D,className:n,children:[r,o]}),e[2]=n,e[3]=s):s=e[3],s}function pe(i){const e=y.c(5),{className:n}=i;let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r=t.jsxs("g",{opacity:.55,children:[t.jsx("rect",{x:"46",y:"16",width:"128",height:"88",rx:"8",...l}),t.jsx("path",{d:"M46 34h128",...l,opacity:.6}),t.jsx("circle",{cx:"56",cy:"25",r:"2",fill:"currentColor",opacity:.6}),t.jsx("circle",{cx:"64",cy:"25",r:"2",fill:"currentColor",opacity:.45}),t.jsx("circle",{cx:"72",cy:"25",r:"2",fill:"currentColor",opacity:.3}),t.jsx("rect",{x:"58",y:"44",width:"104",height:"24",rx:"4",...l,opacity:.5}),t.jsx("rect",{x:"58",y:"76",width:"30",height:"16",rx:"3",...l,opacity:.4}),t.jsx("rect",{x:"95",y:"76",width:"30",height:"16",rx:"3",...l,opacity:.3}),t.jsx("rect",{x:"132",y:"76",width:"30",height:"16",rx:"3",...l,opacity:.22})]}),e[0]=r):r=e[0];let o;e[1]===Symbol.for("react.memo_cache_sentinel")?(o=t.jsxs("g",{transform:"rotate(-8 44 92)",children:[t.jsx("rect",{x:"22",y:"52",width:"44",height:"76",rx:"8",...l,fill:"var(--color-background)"}),t.jsx("path",{d:"M37 60h14",...l,opacity:.5}),t.jsx("rect",{x:"29",y:"68",width:"30",height:"20",rx:"3",...l,opacity:.45}),t.jsx("path",{d:"M29 96h30M29 104h20",...l,opacity:.35}),t.jsx("rect",{x:"29",y:"112",width:"30",height:"8",rx:"4",...l,opacity:.5})]}),e[1]=o):o=e[1];let s;e[2]===Symbol.for("react.memo_cache_sentinel")?(s=t.jsxs("g",{transform:"rotate(10 168 104)",children:[t.jsx("path",{d:"M150 92h30a6 6 0 0 1 6 6v26a6 6 0 0 1-6 6h-30a6 6 0 0 1-6-6V98a6 6 0 0 1 6-6Z",...l,fill:"var(--color-background)"}),t.jsx("circle",{cx:"165",cy:"104",r:"3.5",...l}),t.jsx("path",{d:"M152 116h26M152 124h16",...l,opacity:.45})]}),e[2]=s):s=e[2];let c;return e[3]!==n?(c=t.jsxs("svg",{viewBox:"0 0 220 140",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":!0,className:n,children:[r,o,s]}),e[3]=n,e[4]=c):c=e[4],c}const b=new z(!1);let k="unknown",P=null;function U(i,e){k=i,P=e?.onCreated??null,_("project_create_clicked",{source:i}),b.set(!0)}function he(){const i=y.c(2),e=w.useSyncExternalStore(b.subscribe,b.get);let n;return i[0]!==e?(n=[e,b.set],i[0]=e,i[1]=n):n=i[1],n}function C(i){const e=P;P=null,e?.(i)}function de(){return k}const W={repository:{titleKey:"projects.new.path.repository",hintKey:"projects.new.path.repository.hint",art:q,plate:"bg-chart-5/10 group-hover:bg-chart-5/16",art_:"text-chart-5"},folder:{titleKey:"projects.new.path.folder",hintKey:"projects.new.path.folder.hint",art:I,plate:"bg-chart-1/10 group-hover:bg-chart-1/16",art_:"text-chart-1"}},G=["repository","folder"];function J(i){const e=y.c(25),{path:n,onSelect:r}=i,o=S(),s=W[n],c=s.art;let a;e[0]!==s.art_||e[1]!==s.plate?(a=M("flex h-28 items-center justify-center rounded-lg transition-colors",s.plate,s.art_),e[0]=s.art_,e[1]=s.plate,e[2]=a):a=e[2];let u;e[3]!==c?(u=t.jsx(c,{className:"h-20"}),e[3]=c,e[4]=u):u=e[4];let h;e[5]!==a||e[6]!==u?(h=t.jsx("span",{className:a,children:u}),e[5]=a,e[6]=u,e[7]=h):h=e[7];let d;e[8]!==s.titleKey||e[9]!==o?(d=o(s.titleKey),e[8]=s.titleKey,e[9]=o,e[10]=d):d=e[10];let x;e[11]!==d?(x=t.jsx("span",{className:"text-sm font-medium text-foreground",children:d}),e[11]=d,e[12]=x):x=e[12];let f;e[13]!==s.hintKey||e[14]!==o?(f=o(s.hintKey),e[13]=s.hintKey,e[14]=o,e[15]=f):f=e[15];let j;e[16]!==f?(j=t.jsx("span",{className:"text-xs text-muted-foreground",children:f}),e[16]=f,e[17]=j):j=e[17];let m;e[18]!==x||e[19]!==j?(m=t.jsxs("span",{className:"flex flex-col gap-0.5 px-1 pb-1",children:[x,j]}),e[18]=x,e[19]=j,e[20]=m):m=e[20];let g;return e[21]!==r||e[22]!==h||e[23]!==m?(g=t.jsxs("button",{type:"button",onClick:r,className:"group flex flex-col gap-3 rounded-xl bg-card p-3 text-left card-shadow outline-none transition-[transform,background-color] duration-200 hover:-translate-y-0.5 hover:bg-accent/40 focus-visible:border-ring focus-visible:ring-[2px] focus-visible:ring-ring/20 motion-reduce:transition-none motion-reduce:hover:translate-y-0",children:[h,m]}),e[21]=r,e[22]=h,e[23]=m,e[24]=g):g=e[24],g}function Q(i){const e=y.c(8),{label:n,children:r,hint:o}=i;let s;e[0]!==n?(s=t.jsx(H,{children:n}),e[0]=n,e[1]=s):s=e[1];let c;e[2]!==o?(c=o&&t.jsx("p",{className:"text-xs text-muted-foreground",children:o}),e[2]=o,e[3]=c):c=e[3];let a;return e[4]!==r||e[5]!==s||e[6]!==c?(a=t.jsxs("div",{className:"flex flex-col gap-1.5",children:[s,r,c]}),e[4]=r,e[5]=s,e[6]=c,e[7]=a):a=e[7],a}function ue({open:i,onOpenChange:e,source:n="org_home"}){const r=S(),o=Z(),s=O(),[c,a]=w.useState(null),[u,h]=w.useState(""),[d,x]=w.useState(null),f=w.useRef(null),j=()=>{a(null),h(""),x(null)},m=()=>{e(!1),j()};if(c==="repository")return t.jsx(L,{open:!0,onOpenChange:p=>{p||m()},onImportComplete:({virtualMcpId:p})=>{p&&(C(p),s(p)),m()}});const g=async()=>{if(o.create.isPending)return;const p=u.trim();if(!p){x(r("projects.new.nameRequired"));return}try{const v=(await o.create.mutateAsync({title:p,description:null,status:"active",pinned:!1,connections:[],metadata:{instructions:null,project:{storeUrl:null},ui:{pinnedViews:null,layout:{defaultMainView:{type:"overview"},chatDefaultOpen:!0}}}}))?.id;_("project_created",{source:n,path:c}),m(),v&&(C(v),s(v)),K.success(r("projects.new.created",{title:p}))}catch{x(r("projects.new.failed"))}};return t.jsx(E,{open:i,onOpenChange:p=>{p?e(!0):m()},children:t.jsxs(T,{className:"sm:max-w-3xl",ref:f,onOpenAutoFocus:p=>{p.preventDefault(),f.current?.focus()},children:[t.jsxs(V,{children:[t.jsx($,{children:r("projects.new.title")}),t.jsx(B,{children:r(c?"projects.new.step.folder.title":"projects.new.subtitle")})]}),c===null?t.jsx("div",{className:"grid grid-cols-1 gap-3 animate-in fade-in-0 duration-200 sm:grid-cols-2 motion-reduce:animate-none",children:G.map(p=>t.jsx(J,{path:p,onSelect:()=>{_("project_create_path_selected",{source:n,path:p}),a(p)}},p))}):t.jsxs("form",{className:"flex flex-col gap-4 animate-in fade-in-0 slide-in-from-right-2 duration-200 motion-reduce:animate-none",onSubmit:p=>{p.preventDefault(),x(null),g()},children:[t.jsx(Q,{label:r("projects.new.nameLabel"),children:t.jsx(F,{autoFocus:!0,value:u,onChange:p=>h(p.target.value),placeholder:r("projects.new.namePlaceholder")})}),d&&t.jsx("p",{className:"text-sm text-destructive",children:d}),t.jsxs("div",{className:"flex items-center justify-between gap-2 pt-1",children:[t.jsxs(N,{type:"button",variant:"ghost",onClick:()=>j(),children:[t.jsx(A,{size:14}),r("projects.new.back")]}),t.jsx(N,{type:"submit",disabled:o.create.isPending,children:o.create.isPending?r("projects.new.creating"):r("projects.new.create")})]})]})]})})}function xe(i){const e=y.c(11),{source:n,variant:r,size:o,label:s}=i,c=r===void 0?"default":r,a=o===void 0?"sm":o,u=S();let h;e[0]!==n?(h=()=>U(n),e[0]=n,e[1]=h):h=e[1];let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx(R,{size:14}),e[2]=d):d=e[2];let x;e[3]!==s||e[4]!==u?(x=s??u("projects.home.newProject"),e[3]=s,e[4]=u,e[5]=x):x=e[5];let f;return e[6]!==a||e[7]!==h||e[8]!==x||e[9]!==c?(f=t.jsxs(N,{size:a,variant:c,onClick:h,children:[d,x]}),e[6]=a,e[7]=h,e[8]=x,e[9]=c,e[10]=f):f=e[10],f}export{pe as E,xe as N,ue as a,de as n,U as o,he as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as o,r as c,j as e,h as n}from"./index-
|
|
1
|
+
import{b as o,r as c,j as e,h as n}from"./index-D3VyLkC3.js";import{h as u}from"./mcp-oauth-ax5kWWJK.js";import"./auth-CABZOlQ0.js";function f(){const t=o(),[a,l]=c.useState(null),[r,i]=c.useState(!1);return c.useEffect(()=>{(async()=>{try{const s=await u();if(!s.success){l(s.error||t("routes.oauthCallback.authenticationFailed")),setTimeout(()=>{window.close()},3e3);return}i(!0),setTimeout(()=>{window.close()},1500)}catch(s){l(s instanceof Error?s.message:String(s)),setTimeout(()=>{window.close()},3e3)}})()},[]),e.jsx("div",{className:"min-h-screen flex items-center justify-center p-8 bg-background",children:e.jsxs("div",{className:"w-full max-w-md flex flex-col items-center justify-center gap-8",children:[r&&e.jsx("img",{src:"/empty-state-success.svg",alt:"",width:220,height:200,"aria-hidden":"true"}),!r&&!a&&e.jsx("div",{className:"flex items-center justify-center py-4",children:e.jsx(n,{className:"size-8 text-primary"})}),a&&e.jsx("img",{src:"/empty-state-error.svg",alt:"",width:220,height:200,"aria-hidden":"true"}),e.jsxs("div",{className:"flex flex-col items-center gap-2 text-center",children:[e.jsx("h2",{className:"text-lg font-medium text-foreground",children:t(a?"routes.oauthCallback.authenticationFailedTitle":r?"routes.oauthCallback.authenticationSuccessfulTitle":"routes.oauthCallback.authenticationInProgressTitle")}),e.jsx("div",{className:"text-sm text-muted-foreground",children:a?e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"mb-2",children:t("routes.oauthCallback.errorOccurred")}),e.jsx("p",{className:"text-destructive",children:a}),e.jsxs("p",{className:"mt-2",children:[e.jsx("br",{}),t("routes.oauthCallback.windowClosingAutomatically")]})]}):r?e.jsxs("p",{children:[t("routes.oauthCallback.authenticationComplete"),e.jsx("br",{}),t("routes.oauthCallback.windowClosingAutomatically")]}):e.jsx("p",{children:t("routes.oauthCallback.processingAuthentication")})})]})]})})}export{f as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as d,r as a,j as e,h}from"./index-
|
|
1
|
+
import{b as d,r as a,j as e,h}from"./index-D3VyLkC3.js";function x(){const r=d(),[s,o]=a.useState("loading"),[l,u]=a.useState(null),c=a.useRef(!1);return c.current||(c.current=!0,queueMicrotask(()=>{try{const t=new URLSearchParams(window.location.search),i=t.get("code"),n=t.get("state");if(!i||!n)throw new Error("Missing code or state parameter");if(window.opener)window.opener.postMessage({type:"AI_PROVIDER_OAUTH_CALLBACK",code:i,stateToken:n},window.location.origin),o("success"),setTimeout(()=>window.close(),1500);else throw new Error("No opener window found")}catch(t){console.error("OAuth callback error:",t),u(t instanceof Error?t.message:String(t)),o("error"),setTimeout(()=>window.close(),3e3)}})),e.jsx("div",{className:"min-h-screen flex items-center justify-center p-8 bg-background",children:e.jsxs("div",{className:"w-full max-w-md flex flex-col items-center justify-center gap-8",children:[s==="success"&&e.jsx("img",{src:"/empty-state-success.svg",alt:"",width:220,height:200,"aria-hidden":"true"}),s==="loading"&&e.jsx("div",{className:"flex items-center justify-center py-4",children:e.jsx(h,{className:"size-8 text-primary"})}),s==="error"&&e.jsx("img",{src:"/empty-state-error.svg",alt:"",width:220,height:200,"aria-hidden":"true"}),e.jsxs("div",{className:"flex flex-col items-center gap-2 text-center",children:[e.jsx("h2",{className:"text-lg font-medium text-foreground",children:r(s==="error"?"routes.oauthCallbackAiProvider.authFailed":s==="success"?"routes.oauthCallbackAiProvider.authSuccess":"routes.oauthCallbackAiProvider.authInProgress")}),e.jsx("div",{className:"text-sm text-muted-foreground",children:s==="error"?e.jsxs(e.Fragment,{children:[e.jsx("p",{className:"mb-2",children:r("routes.oauthCallbackAiProvider.errorOccurred")}),e.jsx("p",{className:"text-destructive",children:l}),e.jsx("p",{className:"mt-2",children:r("routes.oauthCallbackAiProvider.windowCloseAuto")})]}):s==="success"?e.jsx("p",{children:r("routes.oauthCallbackAiProvider.authCompleteCloseAuto")}):e.jsx("p",{children:r("routes.oauthCallbackAiProvider.processingAuth")})})]})]})})}export{x as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as ie,j as t,a as ye,h as ce,b as de,m as Ce,K as Oe,r as P,B as Ne,e as pe,p as ze,l as ae,t as he}from"./index-BE867Qee.js";import{R as Le}from"./required-auth-layout-CVAQQhe-.js";import{A as se}from"./auth-split-layout-mHJ8Mnv8.js";import{O as _e}from"./organization-choice-BRq-jJ2y.js";import{A as ve}from"./avatar-BxSXBdTP.js";import{I as Ee}from"./input-DWWEe804.js";import{L as Ae}from"./label-CpTis3ZF.js";import{S as De}from"./switch-B6KzjFhw.js";import{t as Pe}from"./Building02-CsHqQGTj.js";import{i as Re}from"./CheckCircle-BCxvtn62.js";import{t as Fe,a as Me}from"./Palette-CaoJ793n.js";import{i as $e}from"./Upload01-C2lcKrsy.js";import"./Plus-DUwLVLW_.js";import"./User01-DmaMR1Ca.js";const Te=new Set(["gmail.com","googlemail.com","outlook.com","hotmail.com","live.com","yahoo.com","yahoo.co.uk","icloud.com","me.com","mac.com","aol.com","protonmail.com","proton.me","zoho.com","yandex.com","mail.com","gmx.com","gmx.net","tutanota.com","fastmail.com"]);function xe(i){return i.toLowerCase().trim().replace(/[^a-z0-9\s_-]+/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function lt(){const i=ie.c(1);let e;return i[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(Le,{children:t.jsx(qe,{})}),i[0]=e):e=i[0],e}function fe(i){const e=ie.c(13),{title:b,description:m,logoUrl:n,logoFallback:s}=i;let a;e[0]!==s||e[1]!==n?(a=t.jsx("div",{children:n?t.jsx(ve,{url:n,fallback:s??"?",shape:"square",size:"base",className:"h-12 w-12"}):t.jsxs(t.Fragment,{children:[t.jsx("img",{src:"/logos/deco logo.svg",alt:"Deco",className:"h-12 w-12 dark:hidden"}),t.jsx("img",{src:"/logos/deco logo negative.svg",alt:"Deco",className:"h-12 w-12 hidden dark:block"})]})}),e[0]=s,e[1]=n,e[2]=a):a=e[2];let f;e[3]!==b?(f=t.jsx("h1",{className:"text-2xl font-medium leading-8",children:b}),e[3]=b,e[4]=f):f=e[4];let r;e[5]!==m?(r=t.jsx("p",{className:"text-base text-muted-foreground leading-6",children:m}),e[5]=m,e[6]=r):r=e[6];let o;e[7]!==f||e[8]!==r?(o=t.jsxs("div",{className:"space-y-2",children:[f,r]}),e[7]=f,e[8]=r,e[9]=o):o=e[9];let j;return e[10]!==a||e[11]!==o?(j=t.jsxs("div",{className:"grid gap-10",children:[a,o]}),e[10]=a,e[11]=o,e[12]=j):j=e[12],j}function qe(){const i=ie.c(4),{data:e,isPending:b}=ye.useSession();if(b){let a;return i[0]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(se,{children:t.jsx("div",{className:"flex items-center gap-2",children:t.jsx(ce,{className:"size-3.5 text-muted-foreground"})})}),i[0]=a):a=i[0],a}const m=e?.user?.email??"",n=e?.user?.name;let s;return i[1]!==n||i[2]!==m?(s=t.jsx(Ue,{email:m,userName:n}),i[1]=n,i[2]=m,i[3]=s):s=i[3],s}function Ue(i){const e=ie.c(59),{email:b,userName:m}=i,n=de(),s=b.split("@")[1]?.toLowerCase()??"",a=!!s&&!Te.has(s),f=s.split(".")[0]??"",r=f.charAt(0).toUpperCase()+f.slice(1);let o;e[0]!==r||e[1]!==a||e[2]!==m?(o=a?r:m?.split(" ")[0]??"",e[0]=r,e[1]=a,e[2]=m,e[3]=o):o=e[3];const j=o,{data:c,isLoading:v,isError:u,refetch:w}=Ce({queryKey:Oe.domainLookup(s),queryFn:Je,enabled:a});let g;e[4]===Symbol.for("react.memo_cache_sentinel")?(g=new Set,e[4]=g):g=e[4];const[_,M]=P.useState(g),[$,y]=P.useState(!1);if(v){let l;return e[5]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(ce,{className:"size-3.5 text-muted-foreground"}),e[5]=l):l=e[5],t.jsx(se,{children:t.jsxs("div",{className:"flex items-center gap-2 py-4",children:[l,t.jsx("span",{className:"text-sm text-muted-foreground",children:n("routes.onboarding.checking",{domain:s})})]})})}if(u){let l;e[6]!==w?(l=()=>w(),e[6]=w,e[7]=l):l=e[7];let d;e[8]!==n?(d=n("routes.onboarding.retry"),e[8]=n,e[9]=d):d=e[9];let h;return e[10]!==l||e[11]!==d?(h=t.jsx(Ne,{variant:"outline",size:"sm",onClick:l,children:d}),e[10]=l,e[11]=d,e[12]=h):h=e[12],t.jsx(se,{children:t.jsxs("div",{className:"flex flex-col items-start gap-3 py-4",children:[t.jsx("span",{className:"text-sm text-muted-foreground",children:n("routes.onboarding.checkFailed",{domain:s})}),h]})})}let N,A;e[13]!==c?.organizations?(N=(c?.organizations??[]).flatMap(Be),A=N.some(Ke),e[13]=c?.organizations,e[14]=N,e[15]=A):(N=e[14],A=e[15]);const p=A;if($){let l;e[16]!==m?(l=m?.split(" ")[0]??"",e[16]=m,e[17]=l):l=e[17];let d;e[18]!==y?(d=()=>y(!1),e[18]=y,e[19]=d):d=e[19];let h;return e[20]!==r||e[21]!==s||e[22]!==a||e[23]!==l||e[24]!==d?(h=t.jsx(be,{isCorporateEmail:a,emailDomain:s,domainLabel:r,defaultName:l,allowDomainClaim:!1,onBack:d}),e[20]=r,e[21]=s,e[22]=a,e[23]=l,e[24]=d,e[25]=h):h=e[25],h}if(N.length>0){let l;e[26]!==p||e[27]!==N.length||e[28]!==n?(l=p?N.length===1?n("routes.onboarding.accessSingle"):n("routes.onboarding.accessMultiple"):n("routes.onboarding.requestAccess"),e[26]=p,e[27]=N.length,e[28]=n,e[29]=l):l=e[29];let d;e[30]!==p||e[31]!==n?(d=n(p?"routes.onboarding.emailMatchesOrg":"routes.onboarding.emailMatchesOrgApproval"),e[30]=p,e[31]=n,e[32]=d):d=e[32];let h;e[33]!==l||e[34]!==d?(h=t.jsx(fe,{title:l,description:d}),e[33]=l,e[34]=d,e[35]=h):h=e[35];let O;e[36]!==M?(O=R=>M(F=>new Set(F).add(R)),e[36]=M,e[37]=O):O=e[37];let C;e[38]!==N||e[39]!==s||e[40]!==_||e[41]!==O?(C=t.jsx(_e,{organizations:N,domain:s,requestedSlugs:_,onRequestedSlug:O,onJoined:Ie}),e[38]=N,e[39]=s,e[40]=_,e[41]=O,e[42]=C):C=e[42];let z;e[43]!==y?(z=()=>y(!0),e[43]=y,e[44]=z):z=e[44];let E;e[45]!==n?(E=n("routes.onboarding.createNewOrg"),e[45]=n,e[46]=E):E=e[46];let k;e[47]!==E||e[48]!==z?(k=t.jsx("button",{type:"button",className:"text-sm text-muted-foreground hover:text-foreground transition-colors text-center",onClick:z,children:E}),e[47]=E,e[48]=z,e[49]=k):k=e[49];let L;return e[50]!==k||e[51]!==h||e[52]!==C?(L=t.jsx(se,{children:t.jsxs("div",{className:"grid gap-10",children:[h,C,k]})}),e[50]=k,e[51]=h,e[52]=C,e[53]=L):L=e[53],L}let D;return e[54]!==j||e[55]!==r||e[56]!==s||e[57]!==a?(D=t.jsx(be,{isCorporateEmail:a,emailDomain:s,domainLabel:r,defaultName:j}),e[54]=j,e[55]=r,e[56]=s,e[57]=a,e[58]=D):D=e[58],D}function Ie(i,e){window.location.href=`/${e}`}function Ke(i){return i.joinMode==="auto"}function Be(i){return i.joinMode==="auto"||i.joinMode==="request"?[{id:i.id,name:i.name,slug:i.slug,logo:i.logo,joinMode:i.joinMode}]:[]}async function Je(){const i=await fetch("/api/auth/custom/domain-lookup",{credentials:"include"});if(!i.ok)throw new Error(`Failed to look up domain (${i.status})`);return i.json()}function be(i){const e=ie.c(103),{isCorporateEmail:b,emailDomain:m,domainLabel:n,defaultName:s,allowDomainClaim:a,onBack:f}=i,r=a===void 0?!0:a,o=de(),j=b&&r?`https://www.google.com/s2/favicons?domain=${m}&sz=128`:null,[c,v]=P.useState(s),[u,w]=P.useState(j),[g,_]=P.useState(!0),[M,$]=P.useState(null);let y;e[0]!==g||e[1]!==u||e[2]!==c?(y=async()=>{const x=await fetch("/api/auth/custom/domain-setup",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:c.trim()||void 0,logo:u??void 0,claimDomain:g})}),S=await x.json();if(!x.ok||!S.success)throw new Error(S.error||"Failed to set up organization");return S},e[0]=g,e[1]=u,e[2]=c,e[3]=y):y=e[3];let N;e[4]!==g?(N=x=>{if(!x.slug)return;const S=we.filter(ke=>g||!ke.claimOnly).length,ne=Se*(S-1)+800;$(x.slug),setTimeout(()=>{window.location.href=`/${x.slug}`},ne)},e[4]=g,e[5]=N):N=e[5];let A;e[6]!==y||e[7]!==N?(A={mutationFn:y,onSuccess:N},e[6]=y,e[7]=N,e[8]=A):A=e[8];const p=pe(A);let D;e[9]!==u||e[10]!==c?(D={mutationFn:async()=>{const x=c.trim(),S=xe(x);if(!S)throw new Error("Invalid organization name");const ne=await ye.organization.create({name:x,slug:S,...u?{logo:u}:{}});if(ne?.error)throw new Error(ne.error.message||"Failed to create organization");window.location.href=`/${ne?.data?.slug??S}`}},e[9]=u,e[10]=c,e[11]=D):D=e[11];const l=pe(D);if(p.isPending||M){let x;e[12]!==n||e[13]!==c?(x=c.trim()||n,e[12]=n,e[13]=c,e[14]=x):x=e[14];let S;return e[15]!==g||e[16]!==m||e[17]!==u||e[18]!==x?(S=t.jsx(se,{children:t.jsx(Ye,{orgName:x,domain:m,claimDomain:g,logoUrl:u})}),e[15]=g,e[16]=m,e[17]=u,e[18]=x,e[19]=S):S=e[19],S}const d=l.isPending;let h;e[20]!==c?(h=xe(c.trim()),e[20]=c,e[21]=h):h=e[21];const O=!!h,C=p.error||l.error||null;let z;e[22]!==r||e[23]!==O||e[24]!==l||e[25]!==p||e[26]!==b?(z=x=>{x.preventDefault(),O&&(b&&r?p.mutate():l.mutate())},e[22]=r,e[23]=O,e[24]=l,e[25]=p,e[26]=b,e[27]=z):z=e[27];const E=z;let k;e[28]!==o?(k=o("routes.onboarding.welcomeTitle"),e[28]=o,e[29]=k):k=e[29];let L;e[30]!==o?(L=o("routes.onboarding.setupDescription"),e[30]=o,e[31]=L):L=e[31];let R;e[32]!==k||e[33]!==L?(R=t.jsx(fe,{title:k,description:L}),e[32]=k,e[33]=L,e[34]=R):R=e[34];let F;e[35]!==o?(F=o("routes.onboarding.orgAvatar"),e[35]=o,e[36]=F):F=e[36];let T;e[37]!==F?(T=t.jsx("p",{className:"text-sm font-medium",children:F}),e[37]=F,e[38]=T):T=e[38];let q;e[39]!==o?(q=o("routes.onboarding.optional"),e[39]=o,e[40]=q):q=e[40];let U;e[41]!==q?(U=t.jsx("p",{className:"text-xs text-muted-foreground",children:q}),e[41]=q,e[42]=U):U=e[42];let I;e[43]!==T||e[44]!==U?(I=t.jsxs("div",{className:"space-y-0.5",children:[T,U]}),e[43]=T,e[44]=U,e[45]=I):I=e[45];let K;e[46]!==s||e[47]!==c?(K=(c.trim()||s||"?").charAt(0).toUpperCase(),e[46]=s,e[47]=c,e[48]=K):K=e[48];const me=d||p.isPending;let B;e[49]!==u||e[50]!==K||e[51]!==me?(B=t.jsx(Ge,{value:u,fallback:K,onChange:w,disabled:me}),e[49]=u,e[50]=K,e[51]=me,e[52]=B):B=e[52];let J;e[53]!==I||e[54]!==B?(J=t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[I,B]}),e[53]=I,e[54]=B,e[55]=J):J=e[55];let G;e[56]!==o?(G=o("routes.onboarding.orgName"),e[56]=o,e[57]=G):G=e[57];let Y;e[58]!==G?(Y=t.jsx(Ae,{htmlFor:"org-name",className:"text-sm font-medium shrink-0",children:G}),e[58]=G,e[59]=Y):Y=e[59];let re;e[60]===Symbol.for("react.memo_cache_sentinel")?(re=x=>v(x.target.value),e[60]=re):re=e[60];let H;e[61]!==s||e[62]!==o?(H=s||o("routes.onboarding.myOrganizationPlaceholder"),e[61]=s,e[62]=o,e[63]=H):H=e[63];const ue=d||p.isPending;let Q;e[64]!==c||e[65]!==H||e[66]!==ue?(Q=t.jsx(Ee,{id:"org-name",value:c,onChange:re,placeholder:H,disabled:ue,className:"h-10 max-w-[220px]"}),e[64]=c,e[65]=H,e[66]=ue,e[67]=Q):Q=e[67];let W;e[68]!==Y||e[69]!==Q?(W=t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[Y,Q]}),e[68]=Y,e[69]=Q,e[70]=W):W=e[70];let V;e[71]!==r||e[72]!==g||e[73]!==p.isPending||e[74]!==m||e[75]!==b||e[76]!==d||e[77]!==o?(V=b&&r&&t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[t.jsxs("div",{className:"space-y-0.5",children:[t.jsx("p",{className:"text-sm font-medium",children:o("routes.onboarding.allowSignups",{domain:m})}),t.jsx("p",{className:"text-xs text-muted-foreground",children:o("routes.onboarding.allowSignupsDescription",{domain:m})})]}),t.jsx(De,{checked:g,onCheckedChange:_,disabled:d||p.isPending})]}),e[71]=r,e[72]=g,e[73]=p.isPending,e[74]=m,e[75]=b,e[76]=d,e[77]=o,e[78]=V):V=e[78];let X;e[79]!==J||e[80]!==W||e[81]!==V?(X=t.jsxs("div",{className:"rounded-xl card-shadow bg-background dark:bg-input/30 divide-y divide-border",children:[J,W,V]}),e[79]=J,e[80]=W,e[81]=V,e[82]=X):X=e[82];let Z;e[83]!==C||e[84]!==o?(Z=C&&t.jsx("p",{className:"text-xs text-destructive",children:C instanceof Error?C.message:o("routes.onboarding.failedCreateOrg")}),e[83]=C,e[84]=o,e[85]=Z):Z=e[85];const ge=!O||d||p.isPending;let ee;e[86]!==p.isPending||e[87]!==d||e[88]!==o?(ee=d||p.isPending?t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(ce,{className:"size-3.5"})," ",o("routes.onboarding.creating")]}):o("routes.onboarding.continue"),e[86]=p.isPending,e[87]=d,e[88]=o,e[89]=ee):ee=e[89];let te;e[90]!==ge||e[91]!==ee?(te=t.jsx(Ne,{type:"submit",size:"xl",className:"w-full",disabled:ge,children:ee}),e[90]=ge,e[91]=ee,e[92]=te):te=e[92];let oe;e[93]!==f||e[94]!==o?(oe=f&&t.jsx("button",{type:"button",className:"text-sm text-muted-foreground hover:text-foreground transition-colors text-center",onClick:f,children:o("routes.onboarding.seeAvailableOrgs")}),e[93]=f,e[94]=o,e[95]=oe):oe=e[95];let le;return e[96]!==E||e[97]!==R||e[98]!==X||e[99]!==Z||e[100]!==te||e[101]!==oe?(le=t.jsx(se,{children:t.jsxs("form",{onSubmit:E,className:"grid gap-10",children:[R,X,Z,te,oe]})}),e[96]=E,e[97]=R,e[98]=X,e[99]=Z,e[100]=te,e[101]=oe,e[102]=le):le=e[102],le}function Ge(i){const e=ie.c(18),{value:b,fallback:m,onChange:n,disabled:s}=i,a=de(),f=P.useRef(null);let r;e[0]!==n||e[1]!==a?(r=M=>{const $=M.target.files?.[0];if(!$)return;if($.size>2097152){he.error(a("routes.onboarding.imageTooLarge")),f.current&&(f.current.value="");return}const y=new FileReader;y.onerror=()=>he.error(a("routes.onboarding.failedReadImage")),y.onloadend=()=>{y.result&&n(y.result),f.current&&(f.current.value="")},y.readAsDataURL($)},e[0]=n,e[1]=a,e[2]=r):r=e[2];const o=r;let j;e[3]===Symbol.for("react.memo_cache_sentinel")?(j=()=>f.current?.click(),e[3]=j):j=e[3];let c;e[4]!==a?(c=a("routes.onboarding.uploadOrgLogo"),e[4]=a,e[5]=c):c=e[5];let v;e[6]!==s||e[7]!==o?(v=t.jsx("input",{ref:f,type:"file",accept:"image/*",onChange:o,className:"hidden",disabled:s}),e[6]=s,e[7]=o,e[8]=v):v=e[8];const u=b??void 0;let w;e[9]!==m||e[10]!==u?(w=t.jsx(ve,{url:u,fallback:m,shape:"square",size:"base"}),e[9]=m,e[10]=u,e[11]=w):w=e[11];let g;e[12]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsx("span",{className:"absolute inset-0 flex items-center justify-center bg-black/50 opacity-0 group-hover:opacity-100 transition-opacity",children:t.jsx($e,{size:14,className:"text-white"})}),e[12]=g):g=e[12];let _;return e[13]!==s||e[14]!==c||e[15]!==v||e[16]!==w?(_=t.jsxs("button",{type:"button",onClick:j,disabled:s,className:"relative rounded-lg overflow-hidden ring-1 ring-border hover:ring-2 hover:ring-ring/40 transition-all disabled:opacity-50 group","aria-label":c,children:[v,w,g]}),e[13]=s,e[14]=c,e[15]=v,e[16]=w,e[17]=_):_=e[17],_}const we=[{icon:Pe,labelKey:"routes.onboarding.step.creatingOrg",claimOnly:!1},{icon:Fe,labelKey:"routes.onboarding.step.claimingDomain",claimOnly:!0},{icon:ze,labelKey:"routes.onboarding.step.enablingAutoJoin",claimOnly:!0},{icon:Me,labelKey:"routes.onboarding.step.extractingBrand",claimOnly:!1}],Se=1500,je=[{bg:"var(--brand-green-light)",fg:"var(--brand-green-dark)"},{bg:"var(--brand-purple-light)",fg:"var(--brand-purple-dark)"},{bg:"var(--brand-yellow-light)",fg:"var(--brand-yellow-dark)"}];function Ye({orgName:i,domain:e,claimDomain:b,logoUrl:m}){const n=de(),s=we.filter(o=>b||!o.claimOnly),[a,f]=P.useState(0),r=P.useRef(!1);if(!r.current){r.current=!0;for(let o=1;o<s.length;o++)setTimeout(()=>f(o),Se*o)}return t.jsxs("div",{className:"grid gap-10",children:[t.jsx(fe,{title:n("routes.onboarding.settingUp",{orgName:i}),description:n("routes.onboarding.gettingReady",{domain:e}),logoUrl:m??null,logoFallback:i.charAt(0).toUpperCase()||"?"}),t.jsx("ul",{className:"grid gap-5",children:s.map((o,j)=>{const c=o.icon,v=j===a,u=j<a,w=je[j%je.length],g=n(o.labelKey);return t.jsxs("li",{className:"flex items-center gap-4 motion-safe:transition-opacity motion-safe:duration-300 motion-safe:ease-out",style:{opacity:u||v?1:.4},children:[t.jsxs("span",{className:ae("relative grid h-8 w-8 shrink-0 place-items-center rounded-lg","motion-safe:transition-colors motion-safe:duration-300",!u&&(v?"bg-muted text-foreground":"bg-muted text-muted-foreground")),style:u?{backgroundColor:w.bg,color:w.fg}:void 0,children:[t.jsx(Re,{size:16,className:ae("absolute motion-safe:transition-all motion-safe:duration-300 motion-safe:ease-out",u?"scale-100 opacity-100":"scale-75 opacity-0"),"aria-hidden":"true"}),t.jsx(ce,{className:ae("absolute size-4","motion-safe:transition-opacity motion-safe:duration-200",v?"opacity-100":"opacity-0")}),t.jsx(c,{size:16,className:ae("absolute motion-safe:transition-opacity motion-safe:duration-200",!u&&!v?"opacity-100":"opacity-0"),"aria-hidden":"true"})]}),t.jsx("span",{className:ae("text-base leading-6 motion-safe:transition-colors motion-safe:duration-300",v||u?"text-foreground":"text-muted-foreground"),children:g})]},o.labelKey)})})]})}export{lt as default};
|
|
1
|
+
import{c as ie,j as t,a as ye,h as ce,b as de,m as Ce,K as Oe,r as P,B as Ne,e as pe,p as ze,l as ae,t as he}from"./index-D3VyLkC3.js";import{R as Le}from"./required-auth-layout-BXGj5Xuz.js";import{A as se}from"./auth-split-layout-P-3F6VoK.js";import{O as _e}from"./organization-choice-DGTPCWDh.js";import{A as ve}from"./avatar-C70_Ki0z.js";import{I as Ee}from"./input-B-l5PYzO.js";import{L as Ae}from"./label-UBdu3ctU.js";import{S as De}from"./switch-CL5hy8vw.js";import{t as Pe}from"./Building02-DXskyQyV.js";import{i as Re}from"./CheckCircle-B8nBZ9lR.js";import{t as Fe,a as Me}from"./Palette-BLSfhg5D.js";import{i as $e}from"./Upload01-oBIhuFXz.js";import"./Plus-B7fu2HeJ.js";import"./User01-DlDKGoyi.js";const Te=new Set(["gmail.com","googlemail.com","outlook.com","hotmail.com","live.com","yahoo.com","yahoo.co.uk","icloud.com","me.com","mac.com","aol.com","protonmail.com","proton.me","zoho.com","yandex.com","mail.com","gmx.com","gmx.net","tutanota.com","fastmail.com"]);function xe(i){return i.toLowerCase().trim().replace(/[^a-z0-9\s_-]+/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}function lt(){const i=ie.c(1);let e;return i[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(Le,{children:t.jsx(qe,{})}),i[0]=e):e=i[0],e}function fe(i){const e=ie.c(13),{title:b,description:m,logoUrl:n,logoFallback:s}=i;let a;e[0]!==s||e[1]!==n?(a=t.jsx("div",{children:n?t.jsx(ve,{url:n,fallback:s??"?",shape:"square",size:"base",className:"h-12 w-12"}):t.jsxs(t.Fragment,{children:[t.jsx("img",{src:"/logos/deco logo.svg",alt:"Deco",className:"h-12 w-12 dark:hidden"}),t.jsx("img",{src:"/logos/deco logo negative.svg",alt:"Deco",className:"h-12 w-12 hidden dark:block"})]})}),e[0]=s,e[1]=n,e[2]=a):a=e[2];let f;e[3]!==b?(f=t.jsx("h1",{className:"text-2xl font-medium leading-8",children:b}),e[3]=b,e[4]=f):f=e[4];let r;e[5]!==m?(r=t.jsx("p",{className:"text-base text-muted-foreground leading-6",children:m}),e[5]=m,e[6]=r):r=e[6];let o;e[7]!==f||e[8]!==r?(o=t.jsxs("div",{className:"space-y-2",children:[f,r]}),e[7]=f,e[8]=r,e[9]=o):o=e[9];let j;return e[10]!==a||e[11]!==o?(j=t.jsxs("div",{className:"grid gap-10",children:[a,o]}),e[10]=a,e[11]=o,e[12]=j):j=e[12],j}function qe(){const i=ie.c(4),{data:e,isPending:b}=ye.useSession();if(b){let a;return i[0]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(se,{children:t.jsx("div",{className:"flex items-center gap-2",children:t.jsx(ce,{className:"size-3.5 text-muted-foreground"})})}),i[0]=a):a=i[0],a}const m=e?.user?.email??"",n=e?.user?.name;let s;return i[1]!==n||i[2]!==m?(s=t.jsx(Ue,{email:m,userName:n}),i[1]=n,i[2]=m,i[3]=s):s=i[3],s}function Ue(i){const e=ie.c(59),{email:b,userName:m}=i,n=de(),s=b.split("@")[1]?.toLowerCase()??"",a=!!s&&!Te.has(s),f=s.split(".")[0]??"",r=f.charAt(0).toUpperCase()+f.slice(1);let o;e[0]!==r||e[1]!==a||e[2]!==m?(o=a?r:m?.split(" ")[0]??"",e[0]=r,e[1]=a,e[2]=m,e[3]=o):o=e[3];const j=o,{data:c,isLoading:v,isError:u,refetch:w}=Ce({queryKey:Oe.domainLookup(s),queryFn:Je,enabled:a});let g;e[4]===Symbol.for("react.memo_cache_sentinel")?(g=new Set,e[4]=g):g=e[4];const[_,M]=P.useState(g),[$,y]=P.useState(!1);if(v){let l;return e[5]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(ce,{className:"size-3.5 text-muted-foreground"}),e[5]=l):l=e[5],t.jsx(se,{children:t.jsxs("div",{className:"flex items-center gap-2 py-4",children:[l,t.jsx("span",{className:"text-sm text-muted-foreground",children:n("routes.onboarding.checking",{domain:s})})]})})}if(u){let l;e[6]!==w?(l=()=>w(),e[6]=w,e[7]=l):l=e[7];let d;e[8]!==n?(d=n("routes.onboarding.retry"),e[8]=n,e[9]=d):d=e[9];let h;return e[10]!==l||e[11]!==d?(h=t.jsx(Ne,{variant:"outline",size:"sm",onClick:l,children:d}),e[10]=l,e[11]=d,e[12]=h):h=e[12],t.jsx(se,{children:t.jsxs("div",{className:"flex flex-col items-start gap-3 py-4",children:[t.jsx("span",{className:"text-sm text-muted-foreground",children:n("routes.onboarding.checkFailed",{domain:s})}),h]})})}let N,A;e[13]!==c?.organizations?(N=(c?.organizations??[]).flatMap(Be),A=N.some(Ke),e[13]=c?.organizations,e[14]=N,e[15]=A):(N=e[14],A=e[15]);const p=A;if($){let l;e[16]!==m?(l=m?.split(" ")[0]??"",e[16]=m,e[17]=l):l=e[17];let d;e[18]!==y?(d=()=>y(!1),e[18]=y,e[19]=d):d=e[19];let h;return e[20]!==r||e[21]!==s||e[22]!==a||e[23]!==l||e[24]!==d?(h=t.jsx(be,{isCorporateEmail:a,emailDomain:s,domainLabel:r,defaultName:l,allowDomainClaim:!1,onBack:d}),e[20]=r,e[21]=s,e[22]=a,e[23]=l,e[24]=d,e[25]=h):h=e[25],h}if(N.length>0){let l;e[26]!==p||e[27]!==N.length||e[28]!==n?(l=p?N.length===1?n("routes.onboarding.accessSingle"):n("routes.onboarding.accessMultiple"):n("routes.onboarding.requestAccess"),e[26]=p,e[27]=N.length,e[28]=n,e[29]=l):l=e[29];let d;e[30]!==p||e[31]!==n?(d=n(p?"routes.onboarding.emailMatchesOrg":"routes.onboarding.emailMatchesOrgApproval"),e[30]=p,e[31]=n,e[32]=d):d=e[32];let h;e[33]!==l||e[34]!==d?(h=t.jsx(fe,{title:l,description:d}),e[33]=l,e[34]=d,e[35]=h):h=e[35];let O;e[36]!==M?(O=R=>M(F=>new Set(F).add(R)),e[36]=M,e[37]=O):O=e[37];let C;e[38]!==N||e[39]!==s||e[40]!==_||e[41]!==O?(C=t.jsx(_e,{organizations:N,domain:s,requestedSlugs:_,onRequestedSlug:O,onJoined:Ie}),e[38]=N,e[39]=s,e[40]=_,e[41]=O,e[42]=C):C=e[42];let z;e[43]!==y?(z=()=>y(!0),e[43]=y,e[44]=z):z=e[44];let E;e[45]!==n?(E=n("routes.onboarding.createNewOrg"),e[45]=n,e[46]=E):E=e[46];let k;e[47]!==E||e[48]!==z?(k=t.jsx("button",{type:"button",className:"text-sm text-muted-foreground hover:text-foreground transition-colors text-center",onClick:z,children:E}),e[47]=E,e[48]=z,e[49]=k):k=e[49];let L;return e[50]!==k||e[51]!==h||e[52]!==C?(L=t.jsx(se,{children:t.jsxs("div",{className:"grid gap-10",children:[h,C,k]})}),e[50]=k,e[51]=h,e[52]=C,e[53]=L):L=e[53],L}let D;return e[54]!==j||e[55]!==r||e[56]!==s||e[57]!==a?(D=t.jsx(be,{isCorporateEmail:a,emailDomain:s,domainLabel:r,defaultName:j}),e[54]=j,e[55]=r,e[56]=s,e[57]=a,e[58]=D):D=e[58],D}function Ie(i,e){window.location.href=`/${e}`}function Ke(i){return i.joinMode==="auto"}function Be(i){return i.joinMode==="auto"||i.joinMode==="request"?[{id:i.id,name:i.name,slug:i.slug,logo:i.logo,joinMode:i.joinMode}]:[]}async function Je(){const i=await fetch("/api/auth/custom/domain-lookup",{credentials:"include"});if(!i.ok)throw new Error(`Failed to look up domain (${i.status})`);return i.json()}function be(i){const e=ie.c(103),{isCorporateEmail:b,emailDomain:m,domainLabel:n,defaultName:s,allowDomainClaim:a,onBack:f}=i,r=a===void 0?!0:a,o=de(),j=b&&r?`https://www.google.com/s2/favicons?domain=${m}&sz=128`:null,[c,v]=P.useState(s),[u,w]=P.useState(j),[g,_]=P.useState(!0),[M,$]=P.useState(null);let y;e[0]!==g||e[1]!==u||e[2]!==c?(y=async()=>{const x=await fetch("/api/auth/custom/domain-setup",{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:c.trim()||void 0,logo:u??void 0,claimDomain:g})}),S=await x.json();if(!x.ok||!S.success)throw new Error(S.error||"Failed to set up organization");return S},e[0]=g,e[1]=u,e[2]=c,e[3]=y):y=e[3];let N;e[4]!==g?(N=x=>{if(!x.slug)return;const S=we.filter(ke=>g||!ke.claimOnly).length,ne=Se*(S-1)+800;$(x.slug),setTimeout(()=>{window.location.href=`/${x.slug}`},ne)},e[4]=g,e[5]=N):N=e[5];let A;e[6]!==y||e[7]!==N?(A={mutationFn:y,onSuccess:N},e[6]=y,e[7]=N,e[8]=A):A=e[8];const p=pe(A);let D;e[9]!==u||e[10]!==c?(D={mutationFn:async()=>{const x=c.trim(),S=xe(x);if(!S)throw new Error("Invalid organization name");const ne=await ye.organization.create({name:x,slug:S,...u?{logo:u}:{}});if(ne?.error)throw new Error(ne.error.message||"Failed to create organization");window.location.href=`/${ne?.data?.slug??S}`}},e[9]=u,e[10]=c,e[11]=D):D=e[11];const l=pe(D);if(p.isPending||M){let x;e[12]!==n||e[13]!==c?(x=c.trim()||n,e[12]=n,e[13]=c,e[14]=x):x=e[14];let S;return e[15]!==g||e[16]!==m||e[17]!==u||e[18]!==x?(S=t.jsx(se,{children:t.jsx(Ye,{orgName:x,domain:m,claimDomain:g,logoUrl:u})}),e[15]=g,e[16]=m,e[17]=u,e[18]=x,e[19]=S):S=e[19],S}const d=l.isPending;let h;e[20]!==c?(h=xe(c.trim()),e[20]=c,e[21]=h):h=e[21];const O=!!h,C=p.error||l.error||null;let z;e[22]!==r||e[23]!==O||e[24]!==l||e[25]!==p||e[26]!==b?(z=x=>{x.preventDefault(),O&&(b&&r?p.mutate():l.mutate())},e[22]=r,e[23]=O,e[24]=l,e[25]=p,e[26]=b,e[27]=z):z=e[27];const E=z;let k;e[28]!==o?(k=o("routes.onboarding.welcomeTitle"),e[28]=o,e[29]=k):k=e[29];let L;e[30]!==o?(L=o("routes.onboarding.setupDescription"),e[30]=o,e[31]=L):L=e[31];let R;e[32]!==k||e[33]!==L?(R=t.jsx(fe,{title:k,description:L}),e[32]=k,e[33]=L,e[34]=R):R=e[34];let F;e[35]!==o?(F=o("routes.onboarding.orgAvatar"),e[35]=o,e[36]=F):F=e[36];let T;e[37]!==F?(T=t.jsx("p",{className:"text-sm font-medium",children:F}),e[37]=F,e[38]=T):T=e[38];let q;e[39]!==o?(q=o("routes.onboarding.optional"),e[39]=o,e[40]=q):q=e[40];let U;e[41]!==q?(U=t.jsx("p",{className:"text-xs text-muted-foreground",children:q}),e[41]=q,e[42]=U):U=e[42];let I;e[43]!==T||e[44]!==U?(I=t.jsxs("div",{className:"space-y-0.5",children:[T,U]}),e[43]=T,e[44]=U,e[45]=I):I=e[45];let K;e[46]!==s||e[47]!==c?(K=(c.trim()||s||"?").charAt(0).toUpperCase(),e[46]=s,e[47]=c,e[48]=K):K=e[48];const me=d||p.isPending;let B;e[49]!==u||e[50]!==K||e[51]!==me?(B=t.jsx(Ge,{value:u,fallback:K,onChange:w,disabled:me}),e[49]=u,e[50]=K,e[51]=me,e[52]=B):B=e[52];let J;e[53]!==I||e[54]!==B?(J=t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[I,B]}),e[53]=I,e[54]=B,e[55]=J):J=e[55];let G;e[56]!==o?(G=o("routes.onboarding.orgName"),e[56]=o,e[57]=G):G=e[57];let Y;e[58]!==G?(Y=t.jsx(Ae,{htmlFor:"org-name",className:"text-sm font-medium shrink-0",children:G}),e[58]=G,e[59]=Y):Y=e[59];let re;e[60]===Symbol.for("react.memo_cache_sentinel")?(re=x=>v(x.target.value),e[60]=re):re=e[60];let H;e[61]!==s||e[62]!==o?(H=s||o("routes.onboarding.myOrganizationPlaceholder"),e[61]=s,e[62]=o,e[63]=H):H=e[63];const ue=d||p.isPending;let Q;e[64]!==c||e[65]!==H||e[66]!==ue?(Q=t.jsx(Ee,{id:"org-name",value:c,onChange:re,placeholder:H,disabled:ue,className:"h-10 max-w-[220px]"}),e[64]=c,e[65]=H,e[66]=ue,e[67]=Q):Q=e[67];let W;e[68]!==Y||e[69]!==Q?(W=t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[Y,Q]}),e[68]=Y,e[69]=Q,e[70]=W):W=e[70];let V;e[71]!==r||e[72]!==g||e[73]!==p.isPending||e[74]!==m||e[75]!==b||e[76]!==d||e[77]!==o?(V=b&&r&&t.jsxs("div",{className:"flex items-center justify-between gap-4 p-4",children:[t.jsxs("div",{className:"space-y-0.5",children:[t.jsx("p",{className:"text-sm font-medium",children:o("routes.onboarding.allowSignups",{domain:m})}),t.jsx("p",{className:"text-xs text-muted-foreground",children:o("routes.onboarding.allowSignupsDescription",{domain:m})})]}),t.jsx(De,{checked:g,onCheckedChange:_,disabled:d||p.isPending})]}),e[71]=r,e[72]=g,e[73]=p.isPending,e[74]=m,e[75]=b,e[76]=d,e[77]=o,e[78]=V):V=e[78];let X;e[79]!==J||e[80]!==W||e[81]!==V?(X=t.jsxs("div",{className:"rounded-xl card-shadow bg-background dark:bg-input/30 divide-y divide-border",children:[J,W,V]}),e[79]=J,e[80]=W,e[81]=V,e[82]=X):X=e[82];let Z;e[83]!==C||e[84]!==o?(Z=C&&t.jsx("p",{className:"text-xs text-destructive",children:C instanceof Error?C.message:o("routes.onboarding.failedCreateOrg")}),e[83]=C,e[84]=o,e[85]=Z):Z=e[85];const ge=!O||d||p.isPending;let ee;e[86]!==p.isPending||e[87]!==d||e[88]!==o?(ee=d||p.isPending?t.jsxs("span",{className:"flex items-center gap-2",children:[t.jsx(ce,{className:"size-3.5"})," ",o("routes.onboarding.creating")]}):o("routes.onboarding.continue"),e[86]=p.isPending,e[87]=d,e[88]=o,e[89]=ee):ee=e[89];let te;e[90]!==ge||e[91]!==ee?(te=t.jsx(Ne,{type:"submit",size:"xl",className:"w-full",disabled:ge,children:ee}),e[90]=ge,e[91]=ee,e[92]=te):te=e[92];let oe;e[93]!==f||e[94]!==o?(oe=f&&t.jsx("button",{type:"button",className:"text-sm text-muted-foreground hover:text-foreground transition-colors text-center",onClick:f,children:o("routes.onboarding.seeAvailableOrgs")}),e[93]=f,e[94]=o,e[95]=oe):oe=e[95];let le;return e[96]!==E||e[97]!==R||e[98]!==X||e[99]!==Z||e[100]!==te||e[101]!==oe?(le=t.jsx(se,{children:t.jsxs("form",{onSubmit:E,className:"grid gap-10",children:[R,X,Z,te,oe]})}),e[96]=E,e[97]=R,e[98]=X,e[99]=Z,e[100]=te,e[101]=oe,e[102]=le):le=e[102],le}function Ge(i){const e=ie.c(18),{value:b,fallback:m,onChange:n,disabled:s}=i,a=de(),f=P.useRef(null);let r;e[0]!==n||e[1]!==a?(r=M=>{const $=M.target.files?.[0];if(!$)return;if($.size>2097152){he.error(a("routes.onboarding.imageTooLarge")),f.current&&(f.current.value="");return}const y=new FileReader;y.onerror=()=>he.error(a("routes.onboarding.failedReadImage")),y.onloadend=()=>{y.result&&n(y.result),f.current&&(f.current.value="")},y.readAsDataURL($)},e[0]=n,e[1]=a,e[2]=r):r=e[2];const o=r;let j;e[3]===Symbol.for("react.memo_cache_sentinel")?(j=()=>f.current?.click(),e[3]=j):j=e[3];let c;e[4]!==a?(c=a("routes.onboarding.uploadOrgLogo"),e[4]=a,e[5]=c):c=e[5];let v;e[6]!==s||e[7]!==o?(v=t.jsx("input",{ref:f,type:"file",accept:"image/*",onChange:o,className:"hidden",disabled:s}),e[6]=s,e[7]=o,e[8]=v):v=e[8];const u=b??void 0;let w;e[9]!==m||e[10]!==u?(w=t.jsx(ve,{url:u,fallback:m,shape:"square",size:"base"}),e[9]=m,e[10]=u,e[11]=w):w=e[11];let g;e[12]===Symbol.for("react.memo_cache_sentinel")?(g=t.jsx("span",{className:"absolute inset-0 flex items-center justify-center bg-black/50 opacity-0 group-hover:opacity-100 transition-opacity",children:t.jsx($e,{size:14,className:"text-white"})}),e[12]=g):g=e[12];let _;return e[13]!==s||e[14]!==c||e[15]!==v||e[16]!==w?(_=t.jsxs("button",{type:"button",onClick:j,disabled:s,className:"relative rounded-lg overflow-hidden ring-1 ring-border hover:ring-2 hover:ring-ring/40 transition-all disabled:opacity-50 group","aria-label":c,children:[v,w,g]}),e[13]=s,e[14]=c,e[15]=v,e[16]=w,e[17]=_):_=e[17],_}const we=[{icon:Pe,labelKey:"routes.onboarding.step.creatingOrg",claimOnly:!1},{icon:Fe,labelKey:"routes.onboarding.step.claimingDomain",claimOnly:!0},{icon:ze,labelKey:"routes.onboarding.step.enablingAutoJoin",claimOnly:!0},{icon:Me,labelKey:"routes.onboarding.step.extractingBrand",claimOnly:!1}],Se=1500,je=[{bg:"var(--brand-green-light)",fg:"var(--brand-green-dark)"},{bg:"var(--brand-purple-light)",fg:"var(--brand-purple-dark)"},{bg:"var(--brand-yellow-light)",fg:"var(--brand-yellow-dark)"}];function Ye({orgName:i,domain:e,claimDomain:b,logoUrl:m}){const n=de(),s=we.filter(o=>b||!o.claimOnly),[a,f]=P.useState(0),r=P.useRef(!1);if(!r.current){r.current=!0;for(let o=1;o<s.length;o++)setTimeout(()=>f(o),Se*o)}return t.jsxs("div",{className:"grid gap-10",children:[t.jsx(fe,{title:n("routes.onboarding.settingUp",{orgName:i}),description:n("routes.onboarding.gettingReady",{domain:e}),logoUrl:m??null,logoFallback:i.charAt(0).toUpperCase()||"?"}),t.jsx("ul",{className:"grid gap-5",children:s.map((o,j)=>{const c=o.icon,v=j===a,u=j<a,w=je[j%je.length],g=n(o.labelKey);return t.jsxs("li",{className:"flex items-center gap-4 motion-safe:transition-opacity motion-safe:duration-300 motion-safe:ease-out",style:{opacity:u||v?1:.4},children:[t.jsxs("span",{className:ae("relative grid h-8 w-8 shrink-0 place-items-center rounded-lg","motion-safe:transition-colors motion-safe:duration-300",!u&&(v?"bg-muted text-foreground":"bg-muted text-muted-foreground")),style:u?{backgroundColor:w.bg,color:w.fg}:void 0,children:[t.jsx(Re,{size:16,className:ae("absolute motion-safe:transition-all motion-safe:duration-300 motion-safe:ease-out",u?"scale-100 opacity-100":"scale-75 opacity-0"),"aria-hidden":"true"}),t.jsx(ce,{className:ae("absolute size-4","motion-safe:transition-opacity motion-safe:duration-200",v?"opacity-100":"opacity-0")}),t.jsx(c,{size:16,className:ae("absolute motion-safe:transition-opacity motion-safe:duration-200",!u&&!v?"opacity-100":"opacity-0"),"aria-hidden":"true"})]}),t.jsx("span",{className:ae("text-base leading-6 motion-safe:transition-colors motion-safe:duration-300",v||u?"text-foreground":"text-muted-foreground"),children:g})]},o.labelKey)})})]})}export{lt as default};
|
package/dist/client/assets/{openai-conversation-BC7ip1oe.js → openai-conversation-DB4k1EYC.js}
RENAMED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{e as J,f as B}from"./input-
|
|
1
|
+
import{e as J,f as B}from"./input-DJjbA9M9.js";import{au as A,av as _,cU as C,aK as U,bL as W}from"./index-D3VyLkC3.js";import"./index-D-s3ZvIF.js";import"./gateway-client-DqqeM3yS.js";import"./dialog-C_zHR8DK.js";import"./X-B1izQ1KV.js";import"./form-BGxoVGvb.js";import"./label-UBdu3ctU.js";import"./input-B-l5PYzO.js";import"./utils-CVEq3hMx.js";import"./org-file-open-context-kIKkchjb.js";import"./use-mobile-Dd6KUtd1.js";import"./use-panel-navigate-pf_bvwna.js";import"./thread-route-DKA9bRvS.js";import"./use-project-scope-B9gl4G0G.js";import"./repository-binding-qP9N-2MJ.js";import"./use-mcp-client-DjhhnAr3.js";import"./auth-CABZOlQ0.js";import"./tooltip-BUwCxmad.js";import"./index-DXhMSpJ7.js";import"./shell-layout-CBc-iFqB.js";import"./avatar-C70_Ki0z.js";import"./User01-DlDKGoyi.js";import"./Building02-DXskyQyV.js";import"./UserSquare-Cij4gM7j.js";import"./agent-icon-DebFssce.js";import"./AlertCircle-O5yKT_wD.js";import"./Tool01-TfY7iJsP.js";import"./ArrowUp-BcguyIxa.js";import"./ArrowLeft-Bgwvgp7N.js";import"./LinkBroken01-cRHkOCv3.js";import"./ShoppingBag01-Bn_Ml-RN.js";import"./ZoomOut-Cy6sSJWj.js";import"./CheckCircle-B8nBZ9lR.js";import"./Check-BwZg9K6a.js";import"./ChevronUp-XuQjQLoK.js";import"./Copy01-YmLU_wow.js";import"./CreditCard01-CwEdzwSq.js";import"./DotsVertical-DEYhHh-q.js";import"./Image01-DFTuvWJV.js";import"./Palette-BLSfhg5D.js";import"./XClose-B1wwChfA.js";import"./Key01-CW5AmBXO.js";import"./Link01-rblrB3OI.js";import"./LinkExternal01-DMr7xmMD.js";import"./Monitor01-DRRgoSgd.js";import"./Sun-JyTPOz6f.js";import"./Plus-B7fu2HeJ.js";import"./SearchMd-DpRsJH0P.js";import"./Trash01-DBoWC6W0.js";import"./Upload01-oBIhuFXz.js";import"./Users01-B0qqt-bB.js";import"./download-app-dialog-UTCmHANJ.js";import"./use-clock-tick-DK1jMfPk.js";import"./command-BUcXz1jA.js";import"./index-Djpcf0g3.js";import"./integration-icon-Bo3BUxvM.js";import"./project-icon-BlCsNLWV.js";import"./new-project-dialog-BWolKWvl.js";import"./repository-import-picker-BxSMVAOp.js";import"./use-navigate-to-agent-Bbk9KV3t.js";import"./thread-intent-CXrPEeI-.js";import"./backoff-8mStPHYB.js";import"./task-board-CVGH6XO_.js";import"./schema-BWuVZGwp.js";import"./slugify-CEUa2lfQ.js";import"./repository-picker-DXcVdbPo.js";import"./useInfiniteQuery-BzCTPJtn.js";import"./infiniteQueryObserver-rGQ-BvZd.js";import"./collection-search-DZ1wZYuR.js";import"./use-debounced-value-Ddzynl8d.js";import"./use-organization-settings-DSuZT_-Z.js";import"./use-is-desktop-app-BNujXJc_.js";import"./required-auth-layout-BXGj5Xuz.js";import"./autosend-BkG_BHpj.js";import"./use-org-sso-DnQOloxF.js";import"./chat-draft-BkkmQZdS.js";import"./use-session-runtime-BtoYTkvM.js";import"./chat-context-Crr9YCN0.js";import"./use-decopilot-events-Coi59geF.js";import"./use-ai-providers-OUZLuzjk.js";import"./location-DPIrGNp7.js";import"./select-DC4TM20D.js";import"./usage-stats-BZmwl_hY.js";import"./use-copy-4XQ35auE.js";import"./markdown-DgNX2G8Y.js";import"./format-time-CjIPQhCN.js";import"./differenceInSeconds-C3x8sHUj.js";import"./tabs-WFH6vPjH.js";import"./use-deco-credits-BWRF6eDW.js";import"./toggle-group-CHfaqw3y.js";import"./tool-namespace-DmnQIdtF.js";import"./use-open-billing-url-C5p05V2D.js";import"./decopilot-4kqD0JAa.js";import"./checkbox-CAXlLvHp.js";import"./ai-providers-logos-DD3qZ33J.js";import"./popover-DmsBpt35.js";import"./drawer-CeyU31cS.js";import"./index-GgUtI-aH.js";import"./input-CQAdPV6U.js";import"./suggestion-Ules5agL.js";import"./use-mcp-prompts-CPGSJM8z.js";import"./use-org-fs-Cif2PgGI.js";import"./question-004-sINsf4GQ.js";import"./use-members-CgpU7zdW.js";import"./use-org-auth-client-CGnd_KU_.js";import"./feature-paywall-DCy88YOr.js";import"./plan-ladder-B1XIg6KA.js";import"./add-connection-dialog-1TbuXfcy.js";import"./extract-connection-data-DZSiJSCE.js";import"./metadata-D72DunRR.js";import"./connection-D4h25APd.js";import"./connection-card-XwOnt1f0.js";import"./connection-slug-CITJ0kGN.js";import"./textarea-CoQK2oyP.js";import"./use-connection-CDTsUGCD.js";import"./connection-form-helpers-MMq14fzZ.js";import"./authenticate-and-persist-oauth-DBd5KhOF.js";import"./mcp-oauth-ax5kWWJK.js";import"./collection-tabs-Y0ynVKEj.js";import"./badge-D10nU5hm.js";import"./use-infinite-scroll-BOW8hicV.js";import"./useSuspenseInfiniteQuery-Cx1jk_4I.js";import"./use-task-board-events-D5YUKNR3.js";import"./use-chat-layout-state-PWimkJCw.js";import"./use-file-configs-FESoyyAp.js";import"./site-slug-DebpOoQq.js";class X{constructor(t,n=4e3){this.onDisconnect=t,this.graceMs=n}onDisconnect;graceMs;timer;report(t){if(t==="connected"){clearTimeout(this.timer),this.timer=void 0;return}if(t==="failed"||t==="closed"){clearTimeout(this.timer),this.timer=void 0,this.onDisconnect();return}t==="disconnected"&&!this.timer&&(this.timer=setTimeout(this.onDisconnect,this.graceMs))}dispose(){clearTimeout(this.timer),this.timer=void 0}}const H=A({type:W(["session.input_transcript.delta","session.output_transcript.delta"]),event_id:_(),delta:_(),start_ms:U().nonnegative(),end_ms:U().nonnegative()}),K=A({type:C("session.delegation.created"),offset_ms:U().nonnegative(),delegation:A({id:_(),target:C("client")})});class ${constructor(t,n){this.send=t,this.callbacks=n}send;callbacks;closed=!1;fragments=[];seen=new Set;delegated=new Set;consumed=new Set;pending=new Map;contexts=new Map;awaitingContext=new Map;receive(t,n=Date.now()){if(this.closed)return;const r=H.safeParse(t);if(r.success){const e=r.data;if(this.seen.has(e.event_id))return;this.seen.add(e.event_id);const s=e.type==="session.input_transcript.delta"?"user":"agent";if(this.fragments.push({role:s,text:e.delta,start:e.start_ms,end:e.end_ms,arrivedAt:n,id:e.event_id}),this.fragments.sort((o,i)=>o.start-i.start),this.fragments.length>4e3){this.callbacks.onError();return}this.callbacks.onMessage({role:s,message:e.delta,event_id:e.event_id});return}const a=K.safeParse(t);if(a.success){const{id:e}=a.data.delegation;if(this.delegated.has(e)||this.pending.has(e))return;if(this.delegated.size+this.pending.size>=40){this.callbacks.onError();return}this.pending.set(e,{offset:a.data.offset_ms,receivedAt:n});return}const d=A({type:C("session.thinking.appended"),client_event_id:_()}).safeParse(t);if(d.success){const e=d.data.client_event_id,s=this.awaitingContext.get(e);this.awaitingContext.delete(e),s&&(s.remaining.delete(e),s.remaining.size===0&&this.send({type:"session.commentary.append",event_id:crypto.randomUUID(),delegation_id:s.delegationId??null,content:"Studio has supplied the complete background result as context for this request. Briefly explain that result, including any failure or required approval. Acceptance or task creation alone does not mean the work completed."}));return}const p=A({type:_()}).safeParse(t);p.success&&p.data.type==="error"&&this.callbacks.onError()}tick(t=Date.now()){if(!this.closed)for(const[n,r]of this.pending){const a=this.fragments.filter(o=>o.start<r.offset),d=a.reduce((o,i)=>i.role==="user"?Math.max(o,i.arrivedAt):o,r.receivedAt);if(t-d<500)continue;const p=a.filter(o=>o.role==="user"&&!this.consumed.has(o.id));if(!p.length&&t-r.receivedAt<3e3)continue;if(this.pending.delete(n),this.delegated.add(n),!p.length){this.publishUpdate({delivery:"announce",delegationId:n,text:"No new transcribed request is available. No work was started. Ask the user to repeat the request."});continue}const e=p.map(o=>o.text).join("").trim(),s=[];for(const o of a){if(p.includes(o))continue;const i=s.at(-1);i?.role===o.role?i.text+=o.text:s.push({role:o.role,text:o.text})}if(e.length>J){this.publishUpdate({delivery:"announce",delegationId:n,text:"The spoken request is too long. No work was started. Ask the user to shorten it or continue in text."});continue}for(const o of p)this.consumed.add(o.id);this.callbacks.onDelegate({request:e,delegationId:n,transcript:B(s.map(({role:o,text:i})=>({role:o,text:i.trim()})).filter(({text:o})=>o))}).then(o=>{this.closed||this.publishUpdate({delivery:o.status==="rejected"?"announce":"context",delegationId:n,text:JSON.stringify(o)})}).catch(()=>{this.publishUpdate({delivery:"announce",delegationId:n,text:"Studio could not accept this request. Do not claim work started."})})}}publishUpdate(t){if(this.closed)return;if(t.contextId){if(this.contexts.get(t.contextId)===t.text)return;this.contexts.set(t.contextId,t.text)}const r=(t.contextId?`Updated ${t.contextId} data, superseding earlier values:
|
|
2
2
|
`:`Studio result data:
|
|
3
3
|
`)+t.text,a=new TextEncoder,d=t.delivery==="announce"&&a.encode(r).length>480,p={remaining:new Set,delegationId:t.delegationId};let e="",s=0;const o=()=>{if(!e)return;const i=crypto.randomUUID();d&&(p.remaining.add(i),this.awaitingContext.set(i,p)),this.send({type:t.delivery==="announce"&&!d?"session.commentary.append":"session.thinking.append",event_id:i,delegation_id:t.delegationId??null,content:e}),e="",s=0};for(const i of r){const v=a.encode(i).length;s+v>480&&o(),e+=i,s+=v}o()}close(){this.closed=!0,this.pending.clear(),this.awaitingContext.clear()}}async function go(E,t,n){n.throwIfAborted();const r=new RTCPeerConnection,a=r.createDataChannel("oai-events"),d=document.createElement("audio");d.autoplay=!0;let p,e,s,o,i=!1,v=!1,h,L,O=0,P=0,g,w,y=!1;const I=Promise.withResolvers(),x=Promise.withResolvers();x.promise.catch(()=>{});const b=new $(m=>{!i&&a.readyState==="open"&&a.send(JSON.stringify(m))},t),q=new X(()=>{i||t.onDisconnect()}),M=async()=>{if(!i){i=!0,q.dispose(),b.close(),clearInterval(L),n.removeEventListener("abort",T),a.close(),r.close();for(const m of p?.getTracks()??[])m.stop();d.pause(),d.srcObject=null,e&&e.state!=="closed"&&await e.close().catch(()=>{})}},T=()=>{M()};n.addEventListener("abort",T,{once:!0});const u=AbortSignal.any([n,AbortSignal.timeout(3e4)]),j=x.promise,z=()=>x.reject(u.reason);u.addEventListener("abort",z,{once:!0}),j.catch(()=>{}),a.onmessage=({data:m})=>{if(!(i||typeof m!="string"))try{const l=JSON.parse(m);typeof l=="object"&&l!==null&&"type"in l&&(l.type==="session.started"&&(v=!0,x.resolve()),l.type==="session.closed"&&(I.resolve(),h||t.onDisconnect())),h||b.receive(l)}catch{t.onError()}},a.onclose=()=>{x.reject(new Error("Voice connection closed")),I.resolve(),!i&&!h&&t.onDisconnect()},r.onconnectionstatechange=()=>{i||q.report(r.connectionState)},r.ontrack=({streams:m,track:l})=>{if(i)return;const D=m[0]??new MediaStream([l]);d.srcObject=D,e??=new AudioContext,s=e.createAnalyser(),s.fftSize=256,o=new Uint8Array(s.fftSize),e.createMediaStreamSource(D).connect(s),e.resume().catch(()=>t.onError()),d.play().catch(()=>t.onError())};function N(){if(!s||!o||i)return 0;s.getByteTimeDomainData(o);let m=0;for(const l of o)m+=((l-128)/128)**2;return Math.min(1,Math.sqrt(m/o.length)*4)}try{const m=navigator.mediaDevices.getUserMedia({audio:{echoCancellation:!0,noiseSuppression:!0,autoGainControl:!0}}).then(c=>{if(i||u.aborted){for(const f of c.getTracks())f.stop();throw new DOMException("Voice connection cancelled","AbortError")}return p=c,c}),l=await Promise.race([m,new Promise((c,f)=>u.addEventListener("abort",()=>f(u.reason),{once:!0}))]);e??=new AudioContext,g=e.createAnalyser(),g.fftSize=256,w=new Uint8Array(g.fftSize),e.createMediaStreamSource(l).connect(g),await e.resume();for(const c of l.getAudioTracks())r.addTrack(c,l);const D=await r.createOffer();await r.setLocalDescription(D),u.throwIfAborted(),r.iceGatheringState!=="complete"&&await new Promise((c,f)=>{const S=()=>{r.iceGatheringState==="complete"&&(R(),c())},k=()=>{R(),f(u.reason)},R=()=>{r.removeEventListener("icegatheringstatechange",S),u.removeEventListener("abort",k)};r.addEventListener("icegatheringstatechange",S),u.addEventListener("abort",k,{once:!0}),S(),u.aborted&&k()});const V=r.localDescription?.sdp;if(!V)throw new Error("Missing voice offer");const G=await E(V,u);return await r.setRemoteDescription({type:"answer",sdp:G.sdp}),await j,n.throwIfAborted(),u.removeEventListener("abort",z),n.removeEventListener("abort",T),t.onConnect(),L=setInterval(()=>{if(i||h)return;if(b.tick(),g&&w&&!y){g.getByteTimeDomainData(w);const f=w.reduce((S,k)=>S+((k-128)/128)**2,0)/w.length;Math.sqrt(f)>.025&&(P=Date.now())}t.onUserSpeaking(!y&&Date.now()-P<400),N()>.02&&(O=Date.now()),t.onModeChange({mode:Date.now()-O<400?"speaking":"listening"})},100),{endSession:()=>(h??=(async()=>{b.close();for(const c of p?.getTracks()??[])c.stop();if(d.pause(),v&&a.readyState==="open"){a.send(JSON.stringify({type:"session.close"}));let c;await Promise.race([I.promise,new Promise(f=>{c=setTimeout(f,3e3)})]),clearTimeout(c)}await M()})(),h),publishUpdate:c=>b.publishUpdate(c),setMicMuted:c=>{y=c;for(const f of p?.getAudioTracks()??[])f.enabled=!y;y&&t.onUserSpeaking(!1)},getOutputVolume:N}}catch(m){throw await M(),m}}export{go as startOpenAIConversation};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as a,X as f,m as S,K as y,o as v}from"./index-
|
|
1
|
+
import{c as a,X as f,m as S,K as y,o as v}from"./index-D3VyLkC3.js";import{c as d}from"./use-chat-layout-state-PWimkJCw.js";function c(e,i){return y.optimisticProjectSidebarViews(e,i)}function l(e){return typeof e=="object"&&e!==null}function b(e,i){return e[1]===i&&e[3]==="collection"&&e[4]==="VIRTUAL_MCP"}function P(e,i){if(!l(e))return e;if("item"in e&&l(e.item)&&e.item.id===i.id)return{...e,item:i};if(!("structuredContent"in e)||!l(e.structuredContent))return e;const s=e.structuredContent.items;if(!Array.isArray(s))return e;let r=!1;const t=s.map(n=>!l(n)||n.id!==i.id?n:(r=!0,i));return r?{...e,structuredContent:{...e.structuredContent,items:t}}:e}function x(e,i,s){e.setQueriesData({predicate:r=>b(r.queryKey,i)},r=>P(r,s))}function A(e,i,s){const r=e.getQueriesData({predicate:t=>b(t.queryKey,i)&&t.queryKey[5]===s});for(const[,t]of r)if(t?.item?.id===s)return t.item;return null}function V(e,i,s){return e.getQueryData(c(i,s))??null}function j(e,i){if(i)return{sidebarViews:[...i.views],sidebarViewsVersion:d};const s=e?.sidebarViews;return{sidebarViews:s===null?null:s?[...s]:void 0,sidebarViewsVersion:e?.sidebarViewsVersion}}function K(e,i,s){return i?{sidebarViews:[...i.views],sidebarViewsVersion:d}:s===void 0?{sidebarViews:e.sidebarViews===null?null:e.sidebarViews?[...e.sidebarViews]:void 0,sidebarViewsVersion:e.sidebarViewsVersion}:j(s,null)}function p(e,i,s,r,t){const n=V(e,i,s),o={revision:(n?.revision??0)+1,views:[...r],rollbackViews:n?[...n.rollbackViews]:[...t]};return e.setQueryData(c(i,s),o),{revision:o.revision,views:[...o.views],persistedViews:[...o.rollbackViews]}}function C(e,i,s){const r=V(e,i,s);return r?{revision:r.revision,views:[...r.views],persistedViews:[...r.rollbackViews]}:null}function m(e,i){const s=new Set(e),r=new Set(i);return s.size===r.size&&[...s].every(t=>r.has(t))}function R(e){return e?!m(e.views,e.persistedViews):!1}function k(e,i,s,{snapshot:r,saved:t,authoritativeViews:n}){if(!r)return{settledLatest:!1,reconciledViews:null};const o=V(e,i,s);if(!o||r.revision>o.revision)return{settledLatest:!1,reconciledViews:null};const u=n!==void 0?[...n]:t?[...r.views]:null,w={...o,rollbackViews:u??o.rollbackViews};return w.rollbackViews!==o.rollbackViews&&e.setQueryData(c(i,s),w),r.revision!==o.revision?{settledLatest:!1,reconciledViews:null}:(e.setQueryData(c(i,s),null),{settledLatest:!0,reconciledViews:t?u&&!m(u,r.views)?u:null:[...w.rollbackViews]})}function _(e){const i=a.c(5),{org:s}=f(),r=e??"";let t;i[0]!==s.id||i[1]!==r?(t=c(s.id,r),i[0]=s.id,i[1]=r,i[2]=t):t=i[2];let n;i[3]!==t?(n={queryKey:t,queryFn:O,enabled:!1,staleTime:Number.POSITIVE_INFINITY},i[3]=t,i[4]=n):n=i[4];const{data:o}=S(n);return o?.views}async function O(){return null}function L(e){const i=a.c(4),{org:s}=f(),r=v();let t;return i[0]!==s||i[1]!==r||i[2]!==e?(t={stage:(n,o)=>p(r,s.id,e,n,o),snapshot:()=>C(r,s.id,e),settle:n=>k(r,s.id,e,n)},i[0]=s,i[1]=r,i[2]=e,i[3]=t):t=i[3],t}export{L as a,b,j as i,R as o,K as p,A as r,_ as u,x as w};
|
package/dist/client/assets/{org-file-open-context-hWHGVIMb.js → org-file-open-context-kIKkchjb.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as v,d as x,f as h,j as O,r as b,e8 as I}from"./index-
|
|
1
|
+
import{c as v,d as x,f as h,j as O,r as b,e8 as I}from"./index-D3VyLkC3.js";import{u as P}from"./use-mobile-Dd6KUtd1.js";import{a as j}from"./use-panel-navigate-pf_bvwna.js";import{a as y}from"./thread-route-DKA9bRvS.js";const E=b.createContext(null);function N(a){const e=v.c(12),{children:i}=a,n=x(),c=P(),{openPanel:l}=j();let r;e[0]===Symbol.for("react.memo_cache_sentinel")?(r={strict:!1},e[0]=r):r=e[0];const m=h(r),p="org"in m&&typeof m.org=="string"?m.org:void 0,u=y()??void 0;let o;e[1]!==c||e[2]!==n||e[3]!==l?(o=d=>{if(!c){l(I(d),{search:F});return}n({to:".",search:g=>({...g,preview:d})})},e[1]=c,e[2]=n,e[3]=l,e[4]=o):o=e[4];const f=o;let t;e[5]!==f||e[6]!==p||e[7]!==u?(t={orgSlug:p,threadId:u,open:f},e[5]=f,e[6]=p,e[7]=u,e[8]=t):t=e[8];let s;return e[9]!==i||e[10]!==t?(s=O.jsx(E.Provider,{value:t,children:i}),e[9]=i,e[10]=t,e[11]=s):s=e[11],s}function F(a){return{...a,preview:void 0}}export{N as O,E as a};
|
package/dist/client/assets/{organization-choice-BRq-jJ2y.js → organization-choice-DGTPCWDh.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as G,r as H,e as A,j as s,B as L,h as B}from"./index-
|
|
1
|
+
import{c as G,r as H,e as A,j as s,B as L,h as B}from"./index-D3VyLkC3.js";import{A as I}from"./avatar-C70_Ki0z.js";import{s as K}from"./Plus-B7fu2HeJ.js";async function T(i,e,p){const o=await fetch(i,{method:"POST",credentials:"include",headers:{"Content-Type":"application/json"},body:JSON.stringify({organizationSlug:e})}),l=await o.json();if(!o.ok||!l.success)throw new Error(l.error||p);return l}function Z(i){const e=G.c(45),{organizations:p,domain:o,requestedSlugs:l,onRequestedSlug:C,onSelected:h,onJoined:c,onRequestCompleted:M,selectLabel:O,onCreateNew:S,createNewLabel:P}=i,j=O===void 0?"Select":O,_=P===void 0?"Create new organization":P;let N;e[0]===Symbol.for("react.memo_cache_sentinel")?(N=new Set,e[0]=N):N=e[0];const[J,U]=H.useState(N);let v;e[1]!==C?(v=r=>{U(t=>new Set(t).add(r)),C?.(r)},e[1]=C,e[2]=v):v=e[2];const E=v;let z;e[3]!==c?(z={mutationFn:V,onSuccess:r=>{const{organization:t,slug:x}=r;c?.(t,x)}},e[3]=c,e[4]=z):z=e[4];const n=A(z);let R;e[5]!==E||e[6]!==c||e[7]!==M?(R={mutationFn:Q,onSuccess:r=>{const{organization:t,slug:x,alreadyMember:F}=r;if(F&&x){c?.(t,x);return}E(t.slug),M?.(t)}},e[5]=E,e[6]=c,e[7]=M,e[8]=R):R=e[8];const a=A(R);let u;e[9]!==l?(u=l??[],e[9]=l,e[10]=u):u=e[10];let y;e[11]!==J||e[12]!==u?(y=new Set([...u,...J]),e[11]=J,e[12]=u,e[13]=y):y=e[13];const b=y,q=n.variables?.slug??null,w=a.variables?.slug??null;let d;e[14]!==_||e[15]!==S?(d=S&&s.jsxs("button",{type:"button",onClick:S,className:"rounded-xl border border-dashed border-border p-4 flex items-center justify-center gap-2 text-sm font-medium text-muted-foreground hover:text-foreground hover:border-foreground/40 transition-colors",children:[s.jsx(K,{size:16}),_]}),e[14]=_,e[15]=S,e[16]=d):d=e[16];let m;if(e[17]!==o||e[18]!==b||e[19]!==n||e[20]!==h||e[21]!==p||e[22]!==q||e[23]!==w||e[24]!==a||e[25]!==j){let r;e[27]!==o||e[28]!==b||e[29]!==n||e[30]!==h||e[31]!==q||e[32]!==w||e[33]!==a||e[34]!==j?(r=t=>{const x=n.isPending&&q===t.slug,F=a.isPending&&w===t.slug,$=b.has(t.slug),D=t.logo??(o?`https://www.google.com/s2/favicons?domain=${o}&sz=128`:null);return s.jsxs("div",{className:"rounded-xl card-shadow bg-background dark:bg-input/30 p-4 flex items-center gap-4",children:[s.jsx(I,{url:D??void 0,fallback:t.name.charAt(0).toUpperCase(),shape:"square",size:"base",className:"h-10 w-10 shrink-0"}),s.jsxs("div",{className:"flex-1 min-w-0",children:[s.jsx("p",{className:"text-sm font-medium truncate",children:t.name}),o&&s.jsxs("p",{className:"text-xs text-muted-foreground truncate",children:["@",o]})]}),t.joinMode==="auto"?s.jsx(L,{size:"default",onClick:()=>n.mutate(t),disabled:n.isPending,children:x?s.jsxs("span",{className:"flex items-center gap-2",children:[s.jsx(B,{className:"size-3.5"})," Joining..."]}):"Join"}):t.joinMode==="request"?$?s.jsx("span",{className:"text-xs text-muted-foreground shrink-0",children:"Request sent"}):s.jsx(L,{size:"default",variant:"outline",onClick:()=>a.mutate(t),disabled:a.isPending,children:F?s.jsxs("span",{className:"flex items-center gap-2",children:[s.jsx(B,{className:"size-3.5"})," Requesting..."]}):"Request to join"}):s.jsx(L,{size:"default",onClick:()=>h?.(t),children:j})]},t.id)},e[27]=o,e[28]=b,e[29]=n,e[30]=h,e[31]=q,e[32]=w,e[33]=a,e[34]=j,e[35]=r):r=e[35],m=p.map(r),e[17]=o,e[18]=b,e[19]=n,e[20]=h,e[21]=p,e[22]=q,e[23]=w,e[24]=a,e[25]=j,e[26]=m}else m=e[26];let g;e[36]!==n.error?(g=n.error&&s.jsx("p",{className:"text-xs text-destructive",role:"alert",children:n.error instanceof Error?n.error.message:"Failed to join organization"}),e[36]=n.error,e[37]=g):g=e[37];let f;e[38]!==a.error?(f=a.error&&s.jsx("p",{className:"text-xs text-destructive",role:"alert",children:a.error instanceof Error?a.error.message:"Failed to request access"}),e[38]=a.error,e[39]=f):f=e[39];let k;return e[40]!==m||e[41]!==g||e[42]!==f||e[43]!==d?(k=s.jsxs("div",{className:"grid grid-cols-1 gap-2",children:[d,m,g,f]}),e[40]=m,e[41]=g,e[42]=f,e[43]=d,e[44]=k):k=e[44],k}async function Q(i){const e=await T("/api/auth/custom/domain-request-join",i.slug,"Failed to request access");return{organization:i,slug:e.slug,alreadyMember:e.alreadyMember}}async function V(i){const e=await T("/api/auth/custom/domain-join",i.slug,"Failed to join organization");return{organization:i,slug:e.slug??i.slug}}export{Z as O};
|