limixbot 0.3.72 → 0.3.74
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/assets/{ActivityPanel-CkKODTkn.js → ActivityPanel-C6LKqk4c.js} +1 -1
- package/dist/assets/{App-CTks_6Oy.js → App-Cbkqngwr.js} +112 -112
- package/dist/assets/{AppEventEditor-C5dMvU0t.js → AppEventEditor-DK9VqL46.js} +1 -1
- package/dist/assets/{BotSettingsDialog-Ynw6f_iW.js → BotSettingsDialog-D4fmPF22.js} +1 -1
- package/dist/assets/{BrowserPanel-Bk5mHx71.js → BrowserPanel-BfzGnxmv.js} +1 -1
- package/dist/assets/{BrowserProfilesManager-DGg6sMtG.js → BrowserProfilesManager-DCYle5DJ.js} +1 -1
- package/dist/assets/{CloudAddDialog-BQ6BnVr4.js → CloudAddDialog-DrSEDMmR.js} +1 -1
- package/dist/assets/{ComputerFilesPane-BNAg8wf7.js → ComputerFilesPane-DmUya1BF.js} +1 -1
- package/dist/assets/{ComputerPanel-m_-uoe7X.js → ComputerPanel-DGU7Wlq4.js} +2 -2
- package/dist/assets/{DataPanel-D_6jIY8B.js → DataPanel-mUZkg6qs.js} +1 -1
- package/dist/assets/{DesktopViewer-ibFgMuIw.js → DesktopViewer-B0jszxk4.js} +1 -1
- package/dist/assets/{FilesView-C9AHNkLW.js → FilesView-Cb0IT7bz.js} +1 -1
- package/dist/assets/{GrokMoveDialog-BeZxm-3r.js → GrokMoveDialog-DL9kjMRo.js} +1 -1
- package/dist/assets/{InspectorPanel-DAM37Y7L.js → InspectorPanel-DYzeV9El.js} +1 -1
- package/dist/assets/{KeyboardShortcutsModal-Ym7Pn6--.js → KeyboardShortcutsModal-CeTQugFb.js} +1 -1
- package/dist/assets/{LimixChannelReview-exv65AZ3.js → LimixChannelReview-YrlfoLlk.js} +1 -1
- package/dist/assets/{LiveDesktop-BXweoKuo.js → LiveDesktop-C8o4XSqz.js} +1 -1
- package/dist/assets/{LocalVmWorkspace-quoTXN8S.js → LocalVmWorkspace-eS3Xkfrl.js} +1 -1
- package/dist/assets/{MacLocalControl-DDTtAbHJ.js → MacLocalControl-CEWCeGW9.js} +1 -1
- package/dist/assets/{MarkdownFilePreview-CWv2KqDd.js → MarkdownFilePreview-BBcd2jNb.js} +1 -1
- package/dist/assets/{MenuMotion-EDKcQmjm.js → MenuMotion-DGWguBBq.js} +1 -1
- package/dist/assets/{NewBotDialog-DmwyIlKy.js → NewBotDialog-C8ex_1xI.js} +1 -1
- package/dist/assets/{PhoneAppDialog-BPZgNeRH.js → PhoneAppDialog-J_LBTU6v.js} +1 -1
- package/dist/assets/{PlacesRail-DeL2Iwjg.js → PlacesRail-BY539HeM.js} +1 -1
- package/dist/assets/{PluginsPanel-D9o8Kso2.js → PluginsPanel-HV8Tv8GU.js} +1 -1
- package/dist/assets/{ProIntroduction-DTJRKc3C.js → ProIntroduction-DPmbZKsg.js} +1 -1
- package/dist/assets/{RemoteAgentSettingsPanel-DxgvH_q6.js → RemoteAgentSettingsPanel-D65OAXq_.js} +1 -1
- package/dist/assets/{RoomPanel-BpPPacIB.js → RoomPanel-CGgc85EG.js} +1 -1
- package/dist/assets/{RoutinesPage-ChvdROGM.js → RoutinesPage-CyYuFrEO.js} +1 -1
- package/dist/assets/{SettingsModal-Ds87lS1W.js → SettingsModal-vavr8vYH.js} +1 -1
- package/dist/assets/{ShareTeamDialog-Czr9POTu.js → ShareTeamDialog-DO4u6FY-.js} +1 -1
- package/dist/assets/{SignedInSites-C8I33OKl.js → SignedInSites-Cu2ekdfe.js} +1 -1
- package/dist/assets/{TeamLibraryPanel-d5Gdiy-X.js → TeamLibraryPanel-BKAhbYEl.js} +1 -1
- package/dist/assets/{TeamMapPage-D0niSUlj.js → TeamMapPage-CPXYEQ6G.js} +1 -1
- package/dist/assets/{TriggersPage-DFdS4DRi.js → TriggersPage-BSol2wGX.js} +1 -1
- package/dist/assets/{VisibilitySection-LuAbLOEn.js → VisibilitySection-l_vjULOi.js} +1 -1
- package/dist/assets/{WebhookTrigger-C9RcWKqF.js → WebhookTrigger-0YktszeZ.js} +1 -1
- package/dist/assets/{WorksOnGrid-DEKWYfqx.js → WorksOnGrid-DIdnH3zm.js} +1 -1
- package/dist/assets/{abnfDiagram-YUKMZFIV-U_i7y8QG.js → abnfDiagram-YUKMZFIV-Ck3BodS7.js} +1 -1
- package/dist/assets/{activity-DfgP8VPw.js → activity-BTrisZvV.js} +1 -1
- package/dist/assets/{architectureDiagram-47P4ROYG-BaC3VHZ1.js → architectureDiagram-47P4ROYG-Bf-l8gpk.js} +1 -1
- package/dist/assets/{blockDiagram-E7TT5TSB-B7Okqy2u.js → blockDiagram-E7TT5TSB-BXbqNbBz.js} +1 -1
- package/dist/assets/{c4Diagram-CRA5TL53-CllkY54C.js → c4Diagram-CRA5TL53-DYSYc_X7.js} +1 -1
- package/dist/assets/{calendar-days-BJBCvVi1.js → calendar-days-B1MBh681.js} +1 -1
- package/dist/assets/channel-Br5t9_gQ.js +1 -0
- package/dist/assets/{chunk-2Q5K7J3B-BcoVdvme.js → chunk-2Q5K7J3B-B4S055aQ.js} +1 -1
- package/dist/assets/{chunk-5VM5RSS4-ChgtA8KE.js → chunk-5VM5RSS4-Cnm5CduN.js} +1 -1
- package/dist/assets/{chunk-7TKQ45FW-BpXUdmMP.js → chunk-7TKQ45FW-ayUAeOrj.js} +1 -1
- package/dist/assets/{chunk-AW2ZBBNX-0q1diEn-.js → chunk-AW2ZBBNX-UZDZ9jj9.js} +1 -1
- package/dist/assets/{chunk-FVRAUYC3-jlcj69S8.js → chunk-FVRAUYC3-Za3Zv8GA.js} +2 -2
- package/dist/assets/{chunk-HTAEGDNF-DPmbDtSM.js → chunk-HTAEGDNF-zz4u_OKh.js} +1 -1
- package/dist/assets/{chunk-JWPE2WC7-DKqcjgA7.js → chunk-JWPE2WC7-CUZeelhu.js} +1 -1
- package/dist/assets/{chunk-KQW6MTUR-C7_eW1c3.js → chunk-KQW6MTUR-CvRo-vS-.js} +1 -1
- package/dist/assets/{chunk-XXDRQBXY-D6ERutho.js → chunk-XXDRQBXY-CWX1a3j9.js} +1 -1
- package/dist/assets/{classDiagram-v2-K4WV4PDN-DT4X3U--.js → classDiagram-v2-K4WV4PDN-AhE4ur8h.js} +1 -1
- package/dist/assets/{core-CBGJN-JB.js → core-B4B8HM7P.js} +1 -1
- package/dist/assets/{cose-bilkent-JH36ORCC-BoFqrRI7.js → cose-bilkent-JH36ORCC-8LcpA2i6.js} +1 -1
- package/dist/assets/{cynefin-EF2NZ3EQ-Cb52YArt.js → cynefin-EF2NZ3EQ-CcOBMv-N.js} +1 -1
- package/dist/assets/{cynefinDiagram-3GCD6N5R-CXQNBVlZ.js → cynefinDiagram-3GCD6N5R-BYIrKxWD.js} +1 -1
- package/dist/assets/{dagre-W4DXFKR2-z2kdNZfK.js → dagre-W4DXFKR2-gYABSg7j.js} +1 -1
- package/dist/assets/{diagram-2UJZ2QOL-CviRXHM1.js → diagram-2UJZ2QOL-BqImpPq8.js} +1 -1
- package/dist/assets/{diagram-OVF4WLC6-6-Mu7-HS.js → diagram-OVF4WLC6-hfJ7nYDO.js} +1 -1
- package/dist/assets/{diagram-PFPMY2P6-B547skhI.js → diagram-PFPMY2P6-DP7Ew6RB.js} +1 -1
- package/dist/assets/{diagram-UMYRVEAY-DqmfFNbe.js → diagram-UMYRVEAY-BH7lyD9n.js} +1 -1
- package/dist/assets/{diagram-YEKJPTXX-Dw11aRk-.js → diagram-YEKJPTXX-BWxOe-Kw.js} +1 -1
- package/dist/assets/{diagram-ZIFT7M5P-B6E1IiwK.js → diagram-ZIFT7M5P-CUU8wY6I.js} +1 -1
- package/dist/assets/{ebnfDiagram-VR2GEFS7-BpYMxxde.js → ebnfDiagram-VR2GEFS7-CC8-OKzi.js} +1 -1
- package/dist/assets/{elk-IJKZMXRS-BAwaFkw3.js → elk-IJKZMXRS-CK7eIqZI.js} +1 -1
- package/dist/assets/{erDiagram-O2IAPWRE-B_lHVJZb.js → erDiagram-O2IAPWRE-BZEwIqcJ.js} +1 -1
- package/dist/assets/{file-up-QN25T_Ug.js → file-up-BazLOnwh.js} +1 -1
- package/dist/assets/{flowDiagram-OXPTDLAJ-DSts2mvy.js → flowDiagram-OXPTDLAJ-cW7YF2Xc.js} +1 -1
- package/dist/assets/{ganttDiagram-R7TSEDQI-Bi4P2ouD.js → ganttDiagram-R7TSEDQI-CgTXYKux.js} +1 -1
- package/dist/assets/{gitGraphDiagram-XJZIOB7I-BTmKWoNh.js → gitGraphDiagram-XJZIOB7I-Br3yR3lD.js} +1 -1
- package/dist/assets/{import-name-BxQB51Yn.js → import-name-DYstFRfl.js} +1 -1
- package/dist/assets/{index-BAgBrTYo.js → index-Bbdc1V8L.js} +3 -3
- package/dist/assets/{index-T_84JzFg.js → index-DijPiUag.js} +1 -1
- package/dist/assets/{infoDiagram-5W2HQ5XZ-D589l3xc.js → infoDiagram-5W2HQ5XZ-BQYrV79m.js} +1 -1
- package/dist/assets/{ishikawaDiagram-K3B6WC7H-B6JPm4IJ.js → ishikawaDiagram-K3B6WC7H-BvLMe3ra.js} +1 -1
- package/dist/assets/{journeyDiagram-COXZFDF6-BQxWMX6Y.js → journeyDiagram-COXZFDF6-B9VkM_k6.js} +1 -1
- package/dist/assets/{kanban-definition-P3RFRI5V-CGjJ6tHY.js → kanban-definition-P3RFRI5V-Dxpl08NK.js} +1 -1
- package/dist/assets/{mcp-servers-D9Je8TKG.js → mcp-servers-BP0zbTXN.js} +1 -1
- package/dist/assets/{mermaid.core-Bu-wU9fU.js → mermaid.core-DnPykQEf.js} +4 -4
- package/dist/assets/{mindmap-definition-LZFPQGKD-BmCUQhuf.js → mindmap-definition-LZFPQGKD-B9Wg9RI9.js} +1 -1
- package/dist/assets/{minimize-B3xe7UnS.js → minimize-bWLTQ4JN.js} +1 -1
- package/dist/assets/{monitor-LgR-tKnv.js → monitor-BcLBFpcy.js} +1 -1
- package/dist/assets/{new-bot-CIguBXZQ.js → new-bot-CHEWfejt.js} +1 -1
- package/dist/assets/{org-library-CazeQ3UP.js → org-library-CrH3LJsO.js} +1 -1
- package/dist/assets/{package-format-BCRjsHSJ.js → package-format-CbsdihsB.js} +1 -1
- package/dist/assets/{pegDiagram-BGZESJAR-CRMvkdSQ.js → pegDiagram-BGZESJAR-DOm5dwo-.js} +1 -1
- package/dist/assets/{pieDiagram-CAPJLFHJ-DqeJi8Qa.js → pieDiagram-CAPJLFHJ-Cd_8hZuz.js} +1 -1
- package/dist/assets/{pt-br-BJxfvqNu.js → pt-br-D4AX74IF.js} +1 -1
- package/dist/assets/{quadrantDiagram-GDMTTRAM-BXr1z38L.js → quadrantDiagram-GDMTTRAM-Dp0A2eDo.js} +1 -1
- package/dist/assets/{rail-D5pChq7j.js → rail-sbHwvZRd.js} +1 -1
- package/dist/assets/{railroadDiagram-SM67HX2B-CM7Ksj-b.js → railroadDiagram-SM67HX2B-fz4MjzKB.js} +1 -1
- package/dist/assets/{remote-desktop-panel-DOT7_iBW.js → remote-desktop-panel-CoTxZRtX.js} +1 -1
- package/dist/assets/{requirementDiagram-X7JNWC4A-BTxzZRBo.js → requirementDiagram-X7JNWC4A-BisZh_8A.js} +1 -1
- package/dist/assets/{sankeyDiagram-UM26HJRW-CUXWlkkW.js → sankeyDiagram-UM26HJRW-DG-oNbuR.js} +1 -1
- package/dist/assets/{sequenceDiagram-ZO4K6R2Y-CYzSJ-O_.js → sequenceDiagram-ZO4K6R2Y-DCcV7wv2.js} +1 -1
- package/dist/assets/{sizeCapture-INFHLROL-CdbdiH6f.js → sizeCapture-INFHLROL-CdNWR6WK.js} +1 -1
- package/dist/assets/{stateDiagram-v2-TBUQTH76-ByDdZHou.js → stateDiagram-v2-TBUQTH76-D6sGBDyA.js} +1 -1
- package/dist/assets/{styles-BkKe8nrS.js → styles-B6mWzGeo.js} +2 -2
- package/dist/assets/{swimlanes-N4OXWK64-DY3tr8Us.js → swimlanes-N4OXWK64-ZzFl7VEy.js} +1 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-CD3OBQHJ.js +8 -0
- package/dist/assets/{team-share-tMoIre3P.js → team-share-BQmv9nEJ.js} +1 -1
- package/dist/assets/{timeline-definition-YOQAKGHF-vt4Pebdq.js → timeline-definition-YOQAKGHF-BQuD1LIk.js} +1 -1
- package/dist/assets/{usecaseDiagram-VIAY4XPW-DKVyscQI.js → usecaseDiagram-VIAY4XPW-Cpa4lCIb.js} +1 -1
- package/dist/assets/{vennDiagram-BLWOH2XV-DiaQH2Os.js → vennDiagram-BLWOH2XV-wB6biU0a.js} +1 -1
- package/dist/assets/{vi-s8ZQxoDp.js → vi-DmPGsLok.js} +1 -1
- package/dist/assets/{wardleyDiagram-YMQ3BMBF-DxZ04H_Z.js → wardleyDiagram-YMQ3BMBF-CJuH3qZg.js} +1 -1
- package/dist/assets/{xychartDiagram-TAQBALBS-Mv1CKVMI.js → xychartDiagram-TAQBALBS-Bho5-WdW.js} +1 -1
- package/dist/index.html +2 -2
- package/dist/rail.html +4 -4
- package/dist-server/package.json +1 -1
- package/package.json +1 -1
- package/dist/assets/channel-DdiFRMbh.js +0 -1
- package/dist/assets/swimlanesDiagram-K3J5GTZL-BIIFML2p.js +0 -8
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as Ut}from"./chunk-XXDRQBXY-D6ERutho.js";import{s as Kt}from"./chunk-KQW6MTUR-C7_eW1c3.js";import{_ as f,L as Tt,b as Zt,a as jt,s as qt,g as Wt,v as Ht,x as Qt,c as tt,l as F,m as Xt,D as Jt,A as $t,F as te,G as ee,H as se,M as ie,K as re,N as ne,r as ae,t as oe,k as ce,u as le}from"./mermaid.core-Bu-wU9fU.js";import{c as he}from"./channel-DdiFRMbh.js";import"./styles-BkKe8nrS.js";import"./step-CkmJJ7wq.js";var Nt=(function(){var s=f(function(G,a,l,d){for(l=l||{},d=G.length;d--;l[G[d]]=a);return l},"o"),n=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],o=[2,2],c=[1,7],r=[1,9],u=[1,10],y=[1,11],g=[1,12],k=[1,30],N=[1,23],p=[1,24],b=[1,25],A=[1,26],v=[1,27],O=[1,19],C=[1,28],I=[1,29],x=[1,20],D=[1,18],L=[1,21],w=[1,22],Ot=[2,6],h=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],dt=[1,36],pt=[1,37],ft=[1,38],bt=[1,39],gt=[1,40],Z=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],V=[1,46],M=[1,47],j=[1,57],q=[43,51,53,54,55,74,75],W=[1,70],H=[1,68],B=[1,65],Q=[1,69],X=[1,71],et=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],st=[1,78],it=[1,77],rt=[1,76],Ct=[69,70,71,72,73],xt=[1,91],At=[6,9,45,50],z=[6,9,12,44,45,50,51,52],nt=[1,101],at=[1,100],ot=[1,99],J=[18,61],It=[1,110],Rt=[1,109],vt=[20,43,51,53,54,55],yt=[18,61,64,66],_t={trace:f(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",9:"NEWLINE",12:"COLON",14:"STYLE_SEPARATOR",16:"BLOCK_START",18:"BLOCK_STOP",19:"SQS",20:"SQE",21:"title",22:"title_value",23:"acc_title",24:"acc_title_value",25:"acc_descr",26:"acc_descr_value",27:"acc_descr_multiline_value",33:"END",34:"SUBGRAPH",37:"direction_tb",38:"direction_bt",39:"direction_rl",40:"direction_lr",41:"CLASSDEF",43:"UNICODE_TEXT",44:"STYLE_TEXT",45:"COMMA",46:"CLASS",47:"STYLE",50:"SEMI",51:"NUM",52:"BRKT",53:"ENTITY_NAME",54:"DECIMAL_NUM",55:"ENTITY_ONE",61:"ATTRIBUTE_WORD",62:"?",64:",",65:"ATTRIBUTE_KEY",66:"COMMENT",69:"ZERO_OR_ONE",70:"ZERO_OR_MORE",71:"ONE_OR_MORE",72:"ONLY_ONE",73:"MD_PARENT",74:"NON_IDENTIFYING",75:"IDENTIFYING",76:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:f(function(a,l,d,i,_,t,$){var e=t.length-1;switch(_){case 1:break;case 2:this.$=[];break;case 3:this.$=t[e-1].concat(t[e]);break;case 4:this.$=t[e];break;case 5:case 6:this.$=[];break;case 7:i.addEntity(t[e-4]),i.addEntity(t[e-2]),i.addRelationship(t[e-4],t[e],t[e-2],t[e-3]),this.$=[t[e-4],t[e-2]];break;case 8:i.addEntity(t[e-8]),i.addEntity(t[e-4]),i.addRelationship(t[e-8],t[e],t[e-4],t[e-5]),i.setClass([t[e-8]],t[e-6]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-8],t[e-4]];break;case 9:i.addEntity(t[e-6]),i.addEntity(t[e-2]),i.addRelationship(t[e-6],t[e],t[e-2],t[e-3]),i.setClass([t[e-6]],t[e-4]),this.$=[t[e-6],t[e-2]];break;case 10:i.addEntity(t[e-6]),i.addEntity(t[e-4]),i.addRelationship(t[e-6],t[e],t[e-4],t[e-5]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-6],t[e-4]];break;case 11:i.addEntity(t[e-3]),i.addAttributes(t[e-3],t[e-1]),this.$=[t[e-3]];break;case 12:i.addEntity(t[e-5]),i.addAttributes(t[e-5],t[e-1]),i.setClass([t[e-5]],t[e-3]),this.$=[t[e-5]];break;case 13:i.addEntity(t[e-2]),this.$=[t[e-2]];break;case 14:i.addEntity(t[e-4]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-4]];break;case 15:i.addEntity(t[e]),this.$=[t[e]];break;case 16:i.addEntity(t[e-2]),i.setClass([t[e-2]],t[e]),this.$=[t[e-2]];break;case 17:i.addEntity(t[e-6],t[e-4]),i.addAttributes(t[e-6],t[e-1]),this.$=[t[e-6]];break;case 18:i.addEntity(t[e-8],t[e-6]),i.addAttributes(t[e-8],t[e-1]),i.setClass([t[e-8]],t[e-3]),this.$=[t[e-8]];break;case 19:i.addEntity(t[e-5],t[e-3]),this.$=[t[e-5]];break;case 20:i.addEntity(t[e-7],t[e-5]),i.setClass([t[e-7]],t[e-2]),this.$=[t[e-7]];break;case 21:i.addEntity(t[e-3],t[e-1]);break;case 22:i.addEntity(t[e-5],t[e-3]),i.setClass([t[e-5]],t[e]);break;case 23:case 24:this.$=t[e].trim(),i.setAccTitle(this.$);break;case 25:case 26:this.$=t[e].trim(),i.setAccDescription(this.$);break;case 27:i.subgraphDepth?this.$=t[e]:(i.setDirection(t[e].value),this.$=[]);break;case 31:i.subgraphDepth=(i.subgraphDepth||1)-1,this.$=i.addSubGraph({text:t[e-2].id},t[e-1],{text:t[e-2].text});break;case 32:i.subgraphDepth=(i.subgraphDepth||0)+1,this.$={id:t[e-1],text:t[e-1]};break;case 33:i.subgraphDepth=(i.subgraphDepth||0)+1,this.$={id:t[e-4],text:t[e-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=t[e];break;case 35:this.$=t[e-1]+" "+t[e];break;case 36:this.$={stmt:"dir",value:"TB"};break;case 37:this.$={stmt:"dir",value:"BT"};break;case 38:this.$={stmt:"dir",value:"RL"};break;case 39:this.$={stmt:"dir",value:"LR"};break;case 40:this.$=t[e-3],i.addClass(t[e-2],t[e-1]);break;case 41:case 42:case 63:case 72:this.$=[t[e]];break;case 43:case 44:this.$=t[e-2].concat([t[e]]);break;case 45:this.$=t[e-2],i.setClass(t[e-1],t[e]);break;case 46:this.$=t[e-3],i.addCssStyles(t[e-2],t[e-1]);break;case 47:this.$=[t[e]];break;case 48:t[e-2].push(t[e]),this.$=t[e-2];break;case 50:this.$=t[e-1]+t[e];break;case 58:case 84:case 85:this.$=t[e].replace(/"/g,"");break;case 64:t[e].push(t[e-1]),this.$=t[e];break;case 65:this.$={type:t[e-1],name:t[e]};break;case 66:this.$={type:t[e-2],name:t[e-1],keys:t[e]};break;case 67:this.$={type:t[e-2],name:t[e-1],comment:t[e]};break;case 68:this.$={type:t[e-3],name:t[e-2],keys:t[e-1],comment:t[e]};break;case 69:case 71:case 74:this.$=t[e];break;case 70:this.$=t[e-1]+t[e];break;case 73:t[e-2].push(t[e]),this.$=t[e-2];break;case 75:this.$=t[e].replace(/"/g,"");break;case 76:this.$={cardA:t[e],relType:t[e-1],cardB:t[e-2]};break;case 77:this.$=i.Cardinality.ZERO_OR_ONE;break;case 78:this.$=i.Cardinality.ZERO_OR_MORE;break;case 79:this.$=i.Cardinality.ONE_OR_MORE;break;case 80:this.$=i.Cardinality.ONLY_ONE;break;case 81:this.$=i.Cardinality.MD_PARENT;break;case 82:this.$=i.Identification.NON_IDENTIFYING;break;case 83:this.$=i.Identification.IDENTIFYING;break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},s(n,o,{5:3}),{6:[1,4],7:5,8:6,9:c,10:8,21:r,23:u,25:y,27:g,28:13,29:14,30:15,31:16,32:17,34:k,37:N,38:p,39:b,40:A,41:v,43:O,46:C,47:I,51:x,53:D,54:L,55:w},s(n,Ot,{1:[2,1]}),s(h,[2,3]),s(h,[2,4]),s(h,[2,5]),s(h,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:dt,70:pt,71:ft,72:bt,73:gt}),{22:[1,41]},{24:[1,42]},{26:[1,43]},s(h,[2,26]),s(h,[2,27]),s(h,[2,28]),s(h,[2,29]),s(h,[2,30]),s(h,o,{5:44}),s(Z,[2,58]),s(Z,[2,59]),s(Z,[2,60]),s(Z,[2,61]),s(Z,[2,62]),s(h,[2,36]),s(h,[2,37]),s(h,[2,38]),s(h,[2,39]),{15:45,43:V,44:M},{15:48,43:V,44:M},{15:49,43:V,44:M},{10:50,43:O,51:x,53:D,54:L,55:w},{10:51,43:O,51:x,53:D,54:L,55:w},{15:52,43:V,44:M},{17:53,18:[1,54],56:55,57:56,61:j},{10:58,43:O,51:x,53:D,54:L,55:w},{68:59,74:[1,60],75:[1,61]},s(q,[2,77]),s(q,[2,78]),s(q,[2,79]),s(q,[2,80]),s(q,[2,81]),s(h,[2,23]),s(h,[2,24]),s(h,[2,25]),{6:[1,63],7:5,8:6,9:c,10:8,21:r,23:u,25:y,27:g,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:k,37:N,38:p,39:b,40:A,41:v,43:O,46:C,47:I,51:x,53:D,54:L,55:w},{12:W,42:64,44:H,45:B,48:66,49:67,51:Q,52:X},s(et,[2,41]),s(et,[2,42]),{15:72,43:V,44:M,45:B},{12:W,42:73,44:H,45:B,48:66,49:67,51:Q,52:X},{6:st,9:it,19:[1,75],35:74,50:rt},{12:[1,79],14:[1,80]},s(h,[2,16],{67:35,11:81,16:[1,82],45:B,69:dt,70:pt,71:ft,72:bt,73:gt}),{18:[1,83]},s(h,[2,13]),{17:84,18:[2,63],56:55,57:56,61:j},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:dt,70:pt,71:ft,72:bt,73:gt},s(Ct,[2,82]),s(Ct,[2,83]),s(h,[2,31]),s(h,Ot),{6:st,9:it,35:90,45:xt,50:rt},{43:[1,92],44:[1,93]},s(At,[2,47],{49:94,12:W,44:H,51:Q,52:X}),s(z,[2,49]),s(z,[2,54]),s(z,[2,55]),s(z,[2,56]),s(z,[2,57]),s(h,[2,45],{45:B}),{6:st,9:it,35:95,45:xt,50:rt},s(h,[2,32]),{10:97,36:96,43:O,51:x,53:D,54:L,55:w},s(h,[2,51]),s(h,[2,52]),s(h,[2,53]),{13:98,43:nt,53:at,76:ot},{15:102,43:V,44:M},{10:103,43:O,51:x,53:D,54:L,55:w},{17:104,18:[1,105],56:55,57:56,61:j},s(h,[2,11]),{18:[2,64]},s(J,[2,65],{59:106,60:107,63:108,65:It,66:Rt}),s([18,61,65,66],[2,71]),{61:[2,70]},s(h,[2,21],{14:[1,112],16:[1,111]}),s([43,51,53,54,55],[2,76]),s(h,[2,40]),{12:W,44:H,48:113,49:67,51:Q,52:X},s(et,[2,43]),s(et,[2,44]),s(z,[2,50]),s(h,[2,46]),{10:115,20:[1,114],43:O,51:x,53:D,54:L,55:w},s(vt,[2,34]),s(h,[2,7]),s(h,[2,84]),s(h,[2,85]),s(h,[2,86]),{12:[1,116],45:B},{12:[1,118],14:[1,117]},{18:[1,119]},s(h,[2,14]),s(J,[2,66],{60:120,64:[1,121],66:Rt}),s(J,[2,67]),s(yt,[2,72]),s(J,[2,75]),s(yt,[2,74]),{17:122,18:[1,123],56:55,57:56,61:j},{15:124,43:V,44:M},s(At,[2,48],{49:94,12:W,44:H,51:Q,52:X}),{6:st,9:it,35:125,50:rt},s(vt,[2,35]),{13:126,43:nt,53:at,76:ot},{15:127,43:V,44:M},{13:128,43:nt,53:at,76:ot},s(h,[2,12]),s(J,[2,68]),{63:129,65:It},{18:[1,130]},s(h,[2,19]),s(h,[2,22],{16:[1,131],45:B}),s(h,[2,33]),s(h,[2,10]),{12:[1,132],45:B},s(h,[2,9]),s(yt,[2,73]),s(h,[2,17]),{17:133,18:[1,134],56:55,57:56,61:j},{13:135,43:nt,53:at,76:ot},{18:[1,136]},s(h,[2,20]),s(h,[2,8]),s(h,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:f(function(a,l){if(l.recoverable)this.trace(a);else{var d=new Error(a);throw d.hash=l,d}},"parseError"),parse:f(function(a){var l=this,d=[0],i=[],_=[null],t=[],$=this.table,e="",lt=0,Dt=0,Ft=2,Lt=1,Yt=t.slice.call(arguments,1),m=Object.create(this.lexer),Y={yy:{}};for(var kt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,kt)&&(Y.yy[kt]=this.yy[kt]);m.setInput(a,Y.yy),Y.yy.lexer=m,Y.yy.parser=this,typeof m.yylloc>"u"&&(m.yylloc={});var mt=m.yylloc;t.push(mt);var Pt=m.options&&m.options.ranges;typeof Y.yy.parseError=="function"?this.parseError=Y.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function zt(S){d.length=d.length-2*S,_.length=_.length-S,t.length=t.length-S}f(zt,"popStack");function wt(){var S;return S=i.pop()||m.lex()||Lt,typeof S!="number"&&(S instanceof Array&&(i=S,S=i.pop()),S=l.symbols_[S]||S),S}f(wt,"lex");for(var E,P,T,Et,U={},ht,R,Vt,ut;;){if(P=d[d.length-1],this.defaultActions[P]?T=this.defaultActions[P]:((E===null||typeof E>"u")&&(E=wt()),T=$[P]&&$[P][E]),typeof T>"u"||!T.length||!T[0]){var St="";ut=[];for(ht in $[P])this.terminals_[ht]&&ht>Ft&&ut.push("'"+this.terminals_[ht]+"'");m.showPosition?St="Parse error on line "+(lt+1)+`:
|
|
1
|
+
import{g as Ut}from"./chunk-XXDRQBXY-CWX1a3j9.js";import{s as Kt}from"./chunk-KQW6MTUR-CvRo-vS-.js";import{_ as f,L as Tt,b as Zt,a as jt,s as qt,g as Wt,v as Ht,x as Qt,c as tt,l as F,m as Xt,D as Jt,A as $t,F as te,G as ee,H as se,M as ie,K as re,N as ne,r as ae,t as oe,k as ce,u as le}from"./mermaid.core-DnPykQEf.js";import{c as he}from"./channel-Br5t9_gQ.js";import"./styles-B6mWzGeo.js";import"./step-CkmJJ7wq.js";var Nt=(function(){var s=f(function(G,a,l,d){for(l=l||{},d=G.length;d--;l[G[d]]=a);return l},"o"),n=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],o=[2,2],c=[1,7],r=[1,9],u=[1,10],y=[1,11],g=[1,12],k=[1,30],N=[1,23],p=[1,24],b=[1,25],A=[1,26],v=[1,27],O=[1,19],C=[1,28],I=[1,29],x=[1,20],D=[1,18],L=[1,21],w=[1,22],Ot=[2,6],h=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],dt=[1,36],pt=[1,37],ft=[1,38],bt=[1,39],gt=[1,40],Z=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],V=[1,46],M=[1,47],j=[1,57],q=[43,51,53,54,55,74,75],W=[1,70],H=[1,68],B=[1,65],Q=[1,69],X=[1,71],et=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],st=[1,78],it=[1,77],rt=[1,76],Ct=[69,70,71,72,73],xt=[1,91],At=[6,9,45,50],z=[6,9,12,44,45,50,51,52],nt=[1,101],at=[1,100],ot=[1,99],J=[18,61],It=[1,110],Rt=[1,109],vt=[20,43,51,53,54,55],yt=[18,61,64,66],_t={trace:f(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",9:"NEWLINE",12:"COLON",14:"STYLE_SEPARATOR",16:"BLOCK_START",18:"BLOCK_STOP",19:"SQS",20:"SQE",21:"title",22:"title_value",23:"acc_title",24:"acc_title_value",25:"acc_descr",26:"acc_descr_value",27:"acc_descr_multiline_value",33:"END",34:"SUBGRAPH",37:"direction_tb",38:"direction_bt",39:"direction_rl",40:"direction_lr",41:"CLASSDEF",43:"UNICODE_TEXT",44:"STYLE_TEXT",45:"COMMA",46:"CLASS",47:"STYLE",50:"SEMI",51:"NUM",52:"BRKT",53:"ENTITY_NAME",54:"DECIMAL_NUM",55:"ENTITY_ONE",61:"ATTRIBUTE_WORD",62:"?",64:",",65:"ATTRIBUTE_KEY",66:"COMMENT",69:"ZERO_OR_ONE",70:"ZERO_OR_MORE",71:"ONE_OR_MORE",72:"ONLY_ONE",73:"MD_PARENT",74:"NON_IDENTIFYING",75:"IDENTIFYING",76:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:f(function(a,l,d,i,_,t,$){var e=t.length-1;switch(_){case 1:break;case 2:this.$=[];break;case 3:this.$=t[e-1].concat(t[e]);break;case 4:this.$=t[e];break;case 5:case 6:this.$=[];break;case 7:i.addEntity(t[e-4]),i.addEntity(t[e-2]),i.addRelationship(t[e-4],t[e],t[e-2],t[e-3]),this.$=[t[e-4],t[e-2]];break;case 8:i.addEntity(t[e-8]),i.addEntity(t[e-4]),i.addRelationship(t[e-8],t[e],t[e-4],t[e-5]),i.setClass([t[e-8]],t[e-6]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-8],t[e-4]];break;case 9:i.addEntity(t[e-6]),i.addEntity(t[e-2]),i.addRelationship(t[e-6],t[e],t[e-2],t[e-3]),i.setClass([t[e-6]],t[e-4]),this.$=[t[e-6],t[e-2]];break;case 10:i.addEntity(t[e-6]),i.addEntity(t[e-4]),i.addRelationship(t[e-6],t[e],t[e-4],t[e-5]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-6],t[e-4]];break;case 11:i.addEntity(t[e-3]),i.addAttributes(t[e-3],t[e-1]),this.$=[t[e-3]];break;case 12:i.addEntity(t[e-5]),i.addAttributes(t[e-5],t[e-1]),i.setClass([t[e-5]],t[e-3]),this.$=[t[e-5]];break;case 13:i.addEntity(t[e-2]),this.$=[t[e-2]];break;case 14:i.addEntity(t[e-4]),i.setClass([t[e-4]],t[e-2]),this.$=[t[e-4]];break;case 15:i.addEntity(t[e]),this.$=[t[e]];break;case 16:i.addEntity(t[e-2]),i.setClass([t[e-2]],t[e]),this.$=[t[e-2]];break;case 17:i.addEntity(t[e-6],t[e-4]),i.addAttributes(t[e-6],t[e-1]),this.$=[t[e-6]];break;case 18:i.addEntity(t[e-8],t[e-6]),i.addAttributes(t[e-8],t[e-1]),i.setClass([t[e-8]],t[e-3]),this.$=[t[e-8]];break;case 19:i.addEntity(t[e-5],t[e-3]),this.$=[t[e-5]];break;case 20:i.addEntity(t[e-7],t[e-5]),i.setClass([t[e-7]],t[e-2]),this.$=[t[e-7]];break;case 21:i.addEntity(t[e-3],t[e-1]);break;case 22:i.addEntity(t[e-5],t[e-3]),i.setClass([t[e-5]],t[e]);break;case 23:case 24:this.$=t[e].trim(),i.setAccTitle(this.$);break;case 25:case 26:this.$=t[e].trim(),i.setAccDescription(this.$);break;case 27:i.subgraphDepth?this.$=t[e]:(i.setDirection(t[e].value),this.$=[]);break;case 31:i.subgraphDepth=(i.subgraphDepth||1)-1,this.$=i.addSubGraph({text:t[e-2].id},t[e-1],{text:t[e-2].text});break;case 32:i.subgraphDepth=(i.subgraphDepth||0)+1,this.$={id:t[e-1],text:t[e-1]};break;case 33:i.subgraphDepth=(i.subgraphDepth||0)+1,this.$={id:t[e-4],text:t[e-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=t[e];break;case 35:this.$=t[e-1]+" "+t[e];break;case 36:this.$={stmt:"dir",value:"TB"};break;case 37:this.$={stmt:"dir",value:"BT"};break;case 38:this.$={stmt:"dir",value:"RL"};break;case 39:this.$={stmt:"dir",value:"LR"};break;case 40:this.$=t[e-3],i.addClass(t[e-2],t[e-1]);break;case 41:case 42:case 63:case 72:this.$=[t[e]];break;case 43:case 44:this.$=t[e-2].concat([t[e]]);break;case 45:this.$=t[e-2],i.setClass(t[e-1],t[e]);break;case 46:this.$=t[e-3],i.addCssStyles(t[e-2],t[e-1]);break;case 47:this.$=[t[e]];break;case 48:t[e-2].push(t[e]),this.$=t[e-2];break;case 50:this.$=t[e-1]+t[e];break;case 58:case 84:case 85:this.$=t[e].replace(/"/g,"");break;case 64:t[e].push(t[e-1]),this.$=t[e];break;case 65:this.$={type:t[e-1],name:t[e]};break;case 66:this.$={type:t[e-2],name:t[e-1],keys:t[e]};break;case 67:this.$={type:t[e-2],name:t[e-1],comment:t[e]};break;case 68:this.$={type:t[e-3],name:t[e-2],keys:t[e-1],comment:t[e]};break;case 69:case 71:case 74:this.$=t[e];break;case 70:this.$=t[e-1]+t[e];break;case 73:t[e-2].push(t[e]),this.$=t[e-2];break;case 75:this.$=t[e].replace(/"/g,"");break;case 76:this.$={cardA:t[e],relType:t[e-1],cardB:t[e-2]};break;case 77:this.$=i.Cardinality.ZERO_OR_ONE;break;case 78:this.$=i.Cardinality.ZERO_OR_MORE;break;case 79:this.$=i.Cardinality.ONE_OR_MORE;break;case 80:this.$=i.Cardinality.ONLY_ONE;break;case 81:this.$=i.Cardinality.MD_PARENT;break;case 82:this.$=i.Identification.NON_IDENTIFYING;break;case 83:this.$=i.Identification.IDENTIFYING;break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},s(n,o,{5:3}),{6:[1,4],7:5,8:6,9:c,10:8,21:r,23:u,25:y,27:g,28:13,29:14,30:15,31:16,32:17,34:k,37:N,38:p,39:b,40:A,41:v,43:O,46:C,47:I,51:x,53:D,54:L,55:w},s(n,Ot,{1:[2,1]}),s(h,[2,3]),s(h,[2,4]),s(h,[2,5]),s(h,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:dt,70:pt,71:ft,72:bt,73:gt}),{22:[1,41]},{24:[1,42]},{26:[1,43]},s(h,[2,26]),s(h,[2,27]),s(h,[2,28]),s(h,[2,29]),s(h,[2,30]),s(h,o,{5:44}),s(Z,[2,58]),s(Z,[2,59]),s(Z,[2,60]),s(Z,[2,61]),s(Z,[2,62]),s(h,[2,36]),s(h,[2,37]),s(h,[2,38]),s(h,[2,39]),{15:45,43:V,44:M},{15:48,43:V,44:M},{15:49,43:V,44:M},{10:50,43:O,51:x,53:D,54:L,55:w},{10:51,43:O,51:x,53:D,54:L,55:w},{15:52,43:V,44:M},{17:53,18:[1,54],56:55,57:56,61:j},{10:58,43:O,51:x,53:D,54:L,55:w},{68:59,74:[1,60],75:[1,61]},s(q,[2,77]),s(q,[2,78]),s(q,[2,79]),s(q,[2,80]),s(q,[2,81]),s(h,[2,23]),s(h,[2,24]),s(h,[2,25]),{6:[1,63],7:5,8:6,9:c,10:8,21:r,23:u,25:y,27:g,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:k,37:N,38:p,39:b,40:A,41:v,43:O,46:C,47:I,51:x,53:D,54:L,55:w},{12:W,42:64,44:H,45:B,48:66,49:67,51:Q,52:X},s(et,[2,41]),s(et,[2,42]),{15:72,43:V,44:M,45:B},{12:W,42:73,44:H,45:B,48:66,49:67,51:Q,52:X},{6:st,9:it,19:[1,75],35:74,50:rt},{12:[1,79],14:[1,80]},s(h,[2,16],{67:35,11:81,16:[1,82],45:B,69:dt,70:pt,71:ft,72:bt,73:gt}),{18:[1,83]},s(h,[2,13]),{17:84,18:[2,63],56:55,57:56,61:j},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:dt,70:pt,71:ft,72:bt,73:gt},s(Ct,[2,82]),s(Ct,[2,83]),s(h,[2,31]),s(h,Ot),{6:st,9:it,35:90,45:xt,50:rt},{43:[1,92],44:[1,93]},s(At,[2,47],{49:94,12:W,44:H,51:Q,52:X}),s(z,[2,49]),s(z,[2,54]),s(z,[2,55]),s(z,[2,56]),s(z,[2,57]),s(h,[2,45],{45:B}),{6:st,9:it,35:95,45:xt,50:rt},s(h,[2,32]),{10:97,36:96,43:O,51:x,53:D,54:L,55:w},s(h,[2,51]),s(h,[2,52]),s(h,[2,53]),{13:98,43:nt,53:at,76:ot},{15:102,43:V,44:M},{10:103,43:O,51:x,53:D,54:L,55:w},{17:104,18:[1,105],56:55,57:56,61:j},s(h,[2,11]),{18:[2,64]},s(J,[2,65],{59:106,60:107,63:108,65:It,66:Rt}),s([18,61,65,66],[2,71]),{61:[2,70]},s(h,[2,21],{14:[1,112],16:[1,111]}),s([43,51,53,54,55],[2,76]),s(h,[2,40]),{12:W,44:H,48:113,49:67,51:Q,52:X},s(et,[2,43]),s(et,[2,44]),s(z,[2,50]),s(h,[2,46]),{10:115,20:[1,114],43:O,51:x,53:D,54:L,55:w},s(vt,[2,34]),s(h,[2,7]),s(h,[2,84]),s(h,[2,85]),s(h,[2,86]),{12:[1,116],45:B},{12:[1,118],14:[1,117]},{18:[1,119]},s(h,[2,14]),s(J,[2,66],{60:120,64:[1,121],66:Rt}),s(J,[2,67]),s(yt,[2,72]),s(J,[2,75]),s(yt,[2,74]),{17:122,18:[1,123],56:55,57:56,61:j},{15:124,43:V,44:M},s(At,[2,48],{49:94,12:W,44:H,51:Q,52:X}),{6:st,9:it,35:125,50:rt},s(vt,[2,35]),{13:126,43:nt,53:at,76:ot},{15:127,43:V,44:M},{13:128,43:nt,53:at,76:ot},s(h,[2,12]),s(J,[2,68]),{63:129,65:It},{18:[1,130]},s(h,[2,19]),s(h,[2,22],{16:[1,131],45:B}),s(h,[2,33]),s(h,[2,10]),{12:[1,132],45:B},s(h,[2,9]),s(yt,[2,73]),s(h,[2,17]),{17:133,18:[1,134],56:55,57:56,61:j},{13:135,43:nt,53:at,76:ot},{18:[1,136]},s(h,[2,20]),s(h,[2,8]),s(h,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:f(function(a,l){if(l.recoverable)this.trace(a);else{var d=new Error(a);throw d.hash=l,d}},"parseError"),parse:f(function(a){var l=this,d=[0],i=[],_=[null],t=[],$=this.table,e="",lt=0,Dt=0,Ft=2,Lt=1,Yt=t.slice.call(arguments,1),m=Object.create(this.lexer),Y={yy:{}};for(var kt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,kt)&&(Y.yy[kt]=this.yy[kt]);m.setInput(a,Y.yy),Y.yy.lexer=m,Y.yy.parser=this,typeof m.yylloc>"u"&&(m.yylloc={});var mt=m.yylloc;t.push(mt);var Pt=m.options&&m.options.ranges;typeof Y.yy.parseError=="function"?this.parseError=Y.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function zt(S){d.length=d.length-2*S,_.length=_.length-S,t.length=t.length-S}f(zt,"popStack");function wt(){var S;return S=i.pop()||m.lex()||Lt,typeof S!="number"&&(S instanceof Array&&(i=S,S=i.pop()),S=l.symbols_[S]||S),S}f(wt,"lex");for(var E,P,T,Et,U={},ht,R,Vt,ut;;){if(P=d[d.length-1],this.defaultActions[P]?T=this.defaultActions[P]:((E===null||typeof E>"u")&&(E=wt()),T=$[P]&&$[P][E]),typeof T>"u"||!T.length||!T[0]){var St="";ut=[];for(ht in $[P])this.terminals_[ht]&&ht>Ft&&ut.push("'"+this.terminals_[ht]+"'");m.showPosition?St="Parse error on line "+(lt+1)+`:
|
|
2
2
|
`+m.showPosition()+`
|
|
3
3
|
Expecting `+ut.join(", ")+", got '"+(this.terminals_[E]||E)+"'":St="Parse error on line "+(lt+1)+": Unexpected "+(E==Lt?"end of input":"'"+(this.terminals_[E]||E)+"'"),this.parseError(St,{text:m.match,token:this.terminals_[E]||E,line:m.yylineno,loc:mt,expected:ut})}if(T[0]instanceof Array&&T.length>1)throw new Error("Parse Error: multiple actions possible at state: "+P+", token: "+E);switch(T[0]){case 1:d.push(E),_.push(m.yytext),t.push(m.yylloc),d.push(T[1]),E=null,Dt=m.yyleng,e=m.yytext,lt=m.yylineno,mt=m.yylloc;break;case 2:if(R=this.productions_[T[1]][1],U.$=_[_.length-R],U._$={first_line:t[t.length-(R||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(R||1)].first_column,last_column:t[t.length-1].last_column},Pt&&(U._$.range=[t[t.length-(R||1)].range[0],t[t.length-1].range[1]]),Et=this.performAction.apply(U,[e,Dt,lt,Y.yy,T[1],_,t].concat(Yt)),typeof Et<"u")return Et;R&&(d=d.slice(0,-1*R*2),_=_.slice(0,-1*R),t=t.slice(0,-1*R)),d.push(this.productions_[T[1]][0]),_.push(U.$),t.push(U._$),Vt=$[d[d.length-2]][d[d.length-1]],d.push(Vt);break;case 3:return!0}}return!0},"parse")},Gt=(function(){var G={EOF:1,parseError:f(function(l,d){if(this.yy.parser)this.yy.parser.parseError(l,d);else throw new Error(l)},"parseError"),setInput:f(function(a,l){return this.yy=l||this.yy||{},this._input=a,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:f(function(){var a=this._input[0];this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a;var l=a.match(/(?:\r\n?|\n).*/g);return l?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},"input"),unput:f(function(a){var l=a.length,d=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-l),this.offset-=l;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),d.length-1&&(this.yylineno-=d.length-1);var _=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:d?(d.length===i.length?this.yylloc.first_column:0)+i[i.length-d.length].length-d[0].length:this.yylloc.first_column-l},this.options.ranges&&(this.yylloc.range=[_[0],_[0]+this.yyleng-l]),this.yyleng=this.yytext.length,this},"unput"),more:f(function(){return this._more=!0,this},"more"),reject:f(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:f(function(a){this.unput(this.match.slice(a))},"less"),pastInput:f(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:f(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:f(function(){var a=this.pastInput(),l=new Array(a.length+1).join("-");return a+this.upcomingInput()+`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as a}from"./styles-
|
|
1
|
+
import{c as a}from"./styles-B6mWzGeo.js";const e=[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M12 12v6",key:"3ahymv"}],["path",{d:"m15 15-3-3-3 3",key:"15xj92"}]],o=a("file-up",e);export{o as F};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as qt}from"./chunk-5VM5RSS4-
|
|
1
|
+
import{g as qt}from"./chunk-5VM5RSS4-Cnm5CduN.js";import{g as Xt}from"./chunk-XXDRQBXY-CWX1a3j9.js";import{s as Qt}from"./chunk-KQW6MTUR-CvRo-vS-.js";import{_ as C,q as Jt,l as ee,c as Ae,r as Zt,t as $t,u as rt,b as e1,s as t1,v as s1,a as i1,g as r1,x as a1,m as n1,y as u1,J as o1,z as l1,A as st,k as it,B as c1,D as h1,E as d1,F as p1,G as f1,H as g1,I as b1,K as k1}from"./mermaid.core-DnPykQEf.js";import{c as A1}from"./chunk-7TKQ45FW-ayUAeOrj.js";import{c as m1}from"./channel-Br5t9_gQ.js";var C1="flowchart-",Pe,D1=(Pe=class{constructor(){this.vertexCounter=0,this.config=Ae(),this.diagramId="",this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=e1,this.setAccDescription=t1,this.setDiagramTitle=s1,this.getAccTitle=i1,this.getAccDescription=r1,this.getDiagramTitle=a1,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}sanitizeText(i){return n1.sanitizeText(i,this.config)}sanitizeNodeLabelType(i){switch(i){case"markdown":case"string":case"text":return i;default:return"markdown"}}setDiagramId(i){this.diagramId=i}lookUpDomId(i){for(const r of this.vertices.values())if(r.id===i)return this.diagramId?`${this.diagramId}-${r.domId}`:r.domId;return this.diagramId?`${this.diagramId}-${i}`:i}addVertex(i,r,a,n,l,b,u={},m){if(!i||i.trim().length===0)return;let h;if(m!==void 0){let k;m.includes(`
|
|
2
2
|
`)?k=m+`
|
|
3
3
|
`:k=`{
|
|
4
4
|
`+m+`
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{g as be,s as we,x as _e,v as De,a as Se,b as Ce,_ as l,c as dt,k as vt,d as Me,b2 as U,l as st,m as Ee,p as Ie,D as $e,u as Ae}from"./mermaid.core-Bu-wU9fU.js";import{ag as It}from"./styles-BkKe8nrS.js";import{t as Ye,m as Fe,a as Le,i as Oe,b as Zt,c as Qt,d as We,e as Pe,f as Ve,g as ze,h as Re,j as Ne,k as He,l as Kt,n as Jt,o as te,s as ee,p as re}from"./time-CZ0C3Dvk.js";import{l as Be}from"./linear-ChbPfC31.js";import"./step-CkmJJ7wq.js";import"./init-Dmth1JHB.js";import"./defaultLocale-CzDG__Ur.js";function qe(t){return t}var Tt=1,At=2,Ft=3,xt=4,se=1e-6;function Ge(t){return"translate("+t+",0)"}function je(t){return"translate(0,"+t+")"}function Xe(t){return e=>+t(e)}function Ue(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),s=>+t(s)+e}function Ze(){return!this.__axis}function de(t,e){var s=[],r=null,i=null,g=6,y=6,b=3,S=typeof window<"u"&&window.devicePixelRatio>1?0:.5,L=t===Tt||t===xt?-1:1,_=t===xt||t===At?"x":"y",W=t===Tt||t===Ft?Ge:je;function w(D){var N=r??(e.ticks?e.ticks.apply(e,s):e.domain()),V=i??(e.tickFormat?e.tickFormat.apply(e,s):qe),k=Math.max(g,0)+b,M=e.range(),P=+M[0]+S,O=+M[M.length-1]+S,B=(e.bandwidth?Ue:Xe)(e.copy(),S),H=D.selection?D.selection():D,I=H.selectAll(".domain").data([null]),x=H.selectAll(".tick").data(N,e).order(),h=x.exit(),E=x.enter().append("g").attr("class","tick"),f=x.select("line"),T=x.select("text");I=I.merge(I.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),x=x.merge(E),f=f.merge(E.append("line").attr("stroke","currentColor").attr(_+"2",L*g)),T=T.merge(E.append("text").attr("fill","currentColor").attr(_,L*k).attr("dy",t===Tt?"0em":t===Ft?"0.71em":"0.32em")),D!==H&&(I=I.transition(D),x=x.transition(D),f=f.transition(D),T=T.transition(D),h=h.transition(D).attr("opacity",se).attr("transform",function(v){return isFinite(v=B(v))?W(v+S):this.getAttribute("transform")}),E.attr("opacity",se).attr("transform",function(v){var p=this.parentNode.__axis;return W((p&&isFinite(p=p(v))?p:B(v))+S)})),h.remove(),I.attr("d",t===xt||t===At?y?"M"+L*y+","+P+"H"+S+"V"+O+"H"+L*y:"M"+S+","+P+"V"+O:y?"M"+P+","+L*y+"V"+S+"H"+O+"V"+L*y:"M"+P+","+S+"H"+O),x.attr("opacity",1).attr("transform",function(v){return W(B(v)+S)}),f.attr(_+"2",L*g),T.attr(_,L*k).text(V),H.filter(Ze).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===At?"start":t===xt?"end":"middle"),H.each(function(){this.__axis=B})}return w.scale=function(D){return arguments.length?(e=D,w):e},w.ticks=function(){return s=Array.from(arguments),w},w.tickArguments=function(D){return arguments.length?(s=D==null?[]:Array.from(D),w):s.slice()},w.tickValues=function(D){return arguments.length?(r=D==null?null:Array.from(D),w):r&&r.slice()},w.tickFormat=function(D){return arguments.length?(i=D,w):i},w.tickSize=function(D){return arguments.length?(g=y=+D,w):g},w.tickSizeInner=function(D){return arguments.length?(g=+D,w):g},w.tickSizeOuter=function(D){return arguments.length?(y=+D,w):y},w.tickPadding=function(D){return arguments.length?(b=+D,w):b},w.offset=function(D){return arguments.length?(S=+D,w):S},w}function Qe(t){return de(Tt,t)}function Ke(t){return de(Ft,t)}var bt={exports:{}},Je=bt.exports,ne;function tr(){return ne||(ne=1,(function(t,e){(function(s,r){t.exports=r()})(Je,(function(){var s="day";return function(r,i,g){var y=function(L){return L.add(4-L.isoWeekday(),s)},b=i.prototype;b.isoWeekYear=function(){return y(this).year()},b.isoWeek=function(L){if(!this.$utils().u(L))return this.add(7*(L-this.isoWeek()),s);var _,W,w,D,N=y(this),V=(_=this.isoWeekYear(),W=this.$u,w=(W?g.utc:g)().year(_).startOf("year"),D=4-w.isoWeekday(),w.isoWeekday()>4&&(D+=7),w.add(D,s));return N.diff(V,"week")+1},b.isoWeekday=function(L){return this.$utils().u(L)?this.day()||7:this.day(this.day()%7?L:L-7)};var S=b.startOf;b.startOf=function(L,_){var W=this.$utils(),w=!!W.u(_)||_;return W.p(L)==="isoweek"?w?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):S.bind(this)(L,_)}}}))})(bt)),bt.exports}var er=tr();const rr=It(er);var wt={exports:{}},sr=wt.exports,ie;function nr(){return ie||(ie=1,(function(t,e){(function(s,r){t.exports=r()})(sr,(function(){var s={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d/,g=/\d\d/,y=/\d\d?/,b=/\d*[^-_:/,()\s\d]+/,S={},L=function(k){return(k=+k)+(k>68?1900:2e3)},_=function(k){return function(M){this[k]=+M}},W=[/[+-]\d\d:?(\d\d)?|Z/,function(k){(this.zone||(this.zone={})).offset=(function(M){if(!M||M==="Z")return 0;var P=M.match(/([+-]|\d\d)/g),O=60*P[1]+(+P[2]||0);return O===0?0:P[0]==="+"?-O:O})(k)}],w=function(k){var M=S[k];return M&&(M.indexOf?M:M.s.concat(M.f))},D=function(k,M){var P,O=S.meridiem;if(O){for(var B=1;B<=24;B+=1)if(k.indexOf(O(B,0,M))>-1){P=B>12;break}}else P=k===(M?"pm":"PM");return P},N={A:[b,function(k){this.afternoon=D(k,!1)}],a:[b,function(k){this.afternoon=D(k,!0)}],Q:[i,function(k){this.month=3*(k-1)+1}],S:[i,function(k){this.milliseconds=100*+k}],SS:[g,function(k){this.milliseconds=10*+k}],SSS:[/\d{3}/,function(k){this.milliseconds=+k}],s:[y,_("seconds")],ss:[y,_("seconds")],m:[y,_("minutes")],mm:[y,_("minutes")],H:[y,_("hours")],h:[y,_("hours")],HH:[y,_("hours")],hh:[y,_("hours")],D:[y,_("day")],DD:[g,_("day")],Do:[b,function(k){var M=S.ordinal,P=k.match(/\d+/);if(this.day=P[0],M)for(var O=1;O<=31;O+=1)M(O).replace(/\[|\]/g,"")===k&&(this.day=O)}],w:[y,_("week")],ww:[g,_("week")],M:[y,_("month")],MM:[g,_("month")],MMM:[b,function(k){var M=w("months"),P=(w("monthsShort")||M.map((function(O){return O.slice(0,3)}))).indexOf(k)+1;if(P<1)throw new Error;this.month=P%12||P}],MMMM:[b,function(k){var M=w("months").indexOf(k)+1;if(M<1)throw new Error;this.month=M%12||M}],Y:[/[+-]?\d+/,_("year")],YY:[g,function(k){this.year=L(k)}],YYYY:[/\d{4}/,_("year")],Z:W,ZZ:W};function V(k){var M,P;M=k,P=S&&S.formats;for(var O=(k=M.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(f,T,v){var p=v&&v.toUpperCase();return T||P[v]||s[v]||P[p].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(a,d,m){return d||m.slice(1)}))}))).match(r),B=O.length,H=0;H<B;H+=1){var I=O[H],x=N[I],h=x&&x[0],E=x&&x[1];O[H]=E?{regex:h,parser:E}:I.replace(/^\[|\]$/g,"")}return function(f){for(var T={},v=0,p=0;v<B;v+=1){var a=O[v];if(typeof a=="string")p+=a.length;else{var d=a.regex,m=a.parser,u=f.slice(p),C=d.exec(u)[0];m.call(T,C),f=f.replace(C,"")}}return(function(n){var $=n.afternoon;if($!==void 0){var o=n.hours;$?o<12&&(n.hours+=12):o===12&&(n.hours=0),delete n.afternoon}})(T),T}}return function(k,M,P){P.p.customParseFormat=!0,k&&k.parseTwoDigitYear&&(L=k.parseTwoDigitYear);var O=M.prototype,B=O.parse;O.parse=function(H){var I=H.date,x=H.utc,h=H.args;this.$u=x;var E=h[1];if(typeof E=="string"){var f=h[2]===!0,T=h[3]===!0,v=f||T,p=h[2];T&&(p=h[2]),S=this.$locale(),!f&&p&&(S=P.Ls[p]),this.$d=(function(u,C,n,$){try{if(["x","X"].indexOf(C)>-1)return new Date((C==="X"?1e3:1)*u);var o=V(C)(u),G=o.year,c=o.month,A=o.day,Y=o.hours,R=o.minutes,F=o.seconds,q=o.milliseconds,z=o.zone,nt=o.week,at=new Date,yt=A||(G||c?1:at.getDate()),lt=G||at.getFullYear(),j=0;G&&!c||(j=c>0?c-1:at.getMonth());var K,Z=Y||0,ot=R||0,J=F||0,it=q||0;return z?new Date(Date.UTC(lt,j,yt,Z,ot,J,it+60*z.offset*1e3)):n?new Date(Date.UTC(lt,j,yt,Z,ot,J,it)):(K=new Date(lt,j,yt,Z,ot,J,it),nt&&(K=$(K).week(nt).toDate()),K)}catch{return new Date("")}})(I,E,x,P),this.init(),p&&p!==!0&&(this.$L=this.locale(p).$L),v&&I!=this.format(E)&&(this.$d=new Date("")),S={}}else if(E instanceof Array)for(var a=E.length,d=1;d<=a;d+=1){h[1]=E[d-1];var m=P.apply(this,h);if(m.isValid()){this.$d=m.$d,this.$L=m.$L,this.init();break}d===a&&(this.$d=new Date(""))}else B.call(this,H)}}}))})(wt)),wt.exports}var ir=nr();const ar=It(ir);var _t={exports:{}},or=_t.exports,ae;function cr(){return ae||(ae=1,(function(t,e){(function(s,r){t.exports=r()})(or,(function(){return function(s,r){var i=r.prototype,g=i.format;i.format=function(y){var b=this,S=this.$locale();if(!this.isValid())return g.bind(this)(y);var L=this.$utils(),_=(y||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(W){switch(W){case"Q":return Math.ceil((b.$M+1)/3);case"Do":return S.ordinal(b.$D);case"gggg":return b.weekYear();case"GGGG":return b.isoWeekYear();case"wo":return S.ordinal(b.week(),"W");case"w":case"ww":return L.s(b.week(),W==="w"?1:2,"0");case"W":case"WW":return L.s(b.isoWeek(),W==="W"?1:2,"0");case"k":case"kk":return L.s(String(b.$H===0?24:b.$H),W==="k"?1:2,"0");case"X":return Math.floor(b.$d.getTime()/1e3);case"x":return b.$d.getTime();case"z":return"["+b.offsetName()+"]";case"zzz":return"["+b.offsetName("long")+"]";default:return W}}));return g.bind(this)(_)}}}))})(_t)),_t.exports}var lr=cr();const ur=It(lr);var Dt={exports:{}},dr=Dt.exports,oe;function fr(){return oe||(oe=1,(function(t,e){(function(s,r){t.exports=r()})(dr,(function(){var s,r,i=1e3,g=6e4,y=36e5,b=864e5,S=31536e6,L=2628e6,_=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,W=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,w={years:S,months:L,days:b,hours:y,minutes:g,seconds:i,milliseconds:1,weeks:6048e5},D=function(I){return I instanceof B},N=function(I,x,h){return new B(I,h,x.$l)},V=function(I){return r.p(I)+"s"},k=function(I){return I<0},M=function(I){return k(I)?Math.ceil(I):Math.floor(I)},P=function(I){return Math.abs(I)},O=function(I,x){return I?k(I)?{negative:!0,format:""+P(I)+x}:{negative:!1,format:""+I+x}:{negative:!1,format:""}},B=(function(){function I(h,E,f){var T=this;if(this.$d={},this.$l=f,h===void 0&&(this.$ms=0,this.parseFromMilliseconds()),E)return N(h*w[V(E)],this);if(typeof h=="number")return this.$ms=h,this.parseFromMilliseconds(),this;if(typeof h=="object")return Object.keys(h).forEach((function(a){T.$d[V(a)]=h[a]})),this.calMilliseconds(),this;if(typeof h=="string"){var v=h.match(_);if(v){var p=v.slice(2).map((function(a){return a!=null?Number(a):0}));return this.$d.years=p[0],this.$d.months=p[1],this.$d.weeks=p[2],this.$d.days=p[3],this.$d.hours=p[4],this.$d.minutes=p[5],this.$d.seconds=p[6],this.calMilliseconds(),this}}return this}var x=I.prototype;return x.calMilliseconds=function(){var h=this;this.$ms=Object.keys(this.$d).reduce((function(E,f){return E+(h.$d[f]||0)*w[f]}),0)},x.parseFromMilliseconds=function(){var h=this.$ms;this.$d.years=M(h/S),h%=S,this.$d.months=M(h/L),h%=L,this.$d.days=M(h/b),h%=b,this.$d.hours=M(h/y),h%=y,this.$d.minutes=M(h/g),h%=g,this.$d.seconds=M(h/i),h%=i,this.$d.milliseconds=h},x.toISOString=function(){var h=O(this.$d.years,"Y"),E=O(this.$d.months,"M"),f=+this.$d.days||0;this.$d.weeks&&(f+=7*this.$d.weeks);var T=O(f,"D"),v=O(this.$d.hours,"H"),p=O(this.$d.minutes,"M"),a=this.$d.seconds||0;this.$d.milliseconds&&(a+=this.$d.milliseconds/1e3,a=Math.round(1e3*a)/1e3);var d=O(a,"S"),m=h.negative||E.negative||T.negative||v.negative||p.negative||d.negative,u=v.format||p.format||d.format?"T":"",C=(m?"-":"")+"P"+h.format+E.format+T.format+u+v.format+p.format+d.format;return C==="P"||C==="-P"?"P0D":C},x.toJSON=function(){return this.toISOString()},x.format=function(h){var E=h||"YYYY-MM-DDTHH:mm:ss",f={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return E.replace(W,(function(T,v){return v||String(f[T])}))},x.as=function(h){return this.$ms/w[V(h)]},x.get=function(h){var E=this.$ms,f=V(h);return f==="milliseconds"?E%=1e3:E=f==="weeks"?M(E/w[f]):this.$d[f],E||0},x.add=function(h,E,f){var T;return T=E?h*w[V(E)]:D(h)?h.$ms:N(h,this).$ms,N(this.$ms+T*(f?-1:1),this)},x.subtract=function(h,E){return this.add(h,E,!0)},x.locale=function(h){var E=this.clone();return E.$l=h,E},x.clone=function(){return N(this.$ms,this)},x.humanize=function(h){return s().add(this.$ms,"ms").locale(this.$l).fromNow(!h)},x.valueOf=function(){return this.asMilliseconds()},x.milliseconds=function(){return this.get("milliseconds")},x.asMilliseconds=function(){return this.as("milliseconds")},x.seconds=function(){return this.get("seconds")},x.asSeconds=function(){return this.as("seconds")},x.minutes=function(){return this.get("minutes")},x.asMinutes=function(){return this.as("minutes")},x.hours=function(){return this.get("hours")},x.asHours=function(){return this.as("hours")},x.days=function(){return this.get("days")},x.asDays=function(){return this.as("days")},x.weeks=function(){return this.get("weeks")},x.asWeeks=function(){return this.as("weeks")},x.months=function(){return this.get("months")},x.asMonths=function(){return this.as("months")},x.years=function(){return this.get("years")},x.asYears=function(){return this.as("years")},I})(),H=function(I,x,h){return I.add(x.years()*h,"y").add(x.months()*h,"M").add(x.days()*h,"d").add(x.hours()*h,"h").add(x.minutes()*h,"m").add(x.seconds()*h,"s").add(x.milliseconds()*h,"ms")};return function(I,x,h){s=h,r=h().$utils(),h.duration=function(T,v){var p=h.locale();return N(T,{$l:p},v)},h.isDuration=D;var E=x.prototype.add,f=x.prototype.subtract;x.prototype.add=function(T,v){return D(T)?H(this,T,1):E.bind(this)(T,v)},x.prototype.subtract=function(T,v){return D(T)?H(this,T,-1):f.bind(this)(T,v)}}}))})(Dt)),Dt.exports}var hr=fr();const mr=It(hr);var Lt=(function(){var t=l(function(p,a,d,m){for(d=d||{},m=p.length;m--;d[p[m]]=a);return d},"o"),e=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],s=[1,26],r=[1,27],i=[1,28],g=[1,29],y=[1,30],b=[1,31],S=[1,32],L=[1,33],_=[1,34],W=[1,9],w=[1,10],D=[1,11],N=[1,12],V=[1,13],k=[1,14],M=[1,15],P=[1,16],O=[1,19],B=[1,20],H=[1,21],I=[1,22],x=[1,23],h=[1,25],E=[1,35],f={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:l(function(a,d,m,u,C,n,$){var o=n.length-1;switch(C){case 1:return n[o-1];case 2:this.$=[];break;case 3:n[o-1].push(n[o]),this.$=n[o-1];break;case 4:case 5:this.$=n[o];break;case 6:case 7:this.$=[];break;case 8:u.setWeekday("monday");break;case 9:u.setWeekday("tuesday");break;case 10:u.setWeekday("wednesday");break;case 11:u.setWeekday("thursday");break;case 12:u.setWeekday("friday");break;case 13:u.setWeekday("saturday");break;case 14:u.setWeekday("sunday");break;case 15:u.setWeekend("friday");break;case 16:u.setWeekend("saturday");break;case 17:u.setDateFormat(n[o].substr(11)),this.$=n[o].substr(11);break;case 18:u.enableInclusiveEndDates(),this.$=n[o].substr(18);break;case 19:u.TopAxis(),this.$=n[o].substr(8);break;case 20:u.setAxisFormat(n[o].substr(11)),this.$=n[o].substr(11);break;case 21:u.setTickInterval(n[o].substr(13)),this.$=n[o].substr(13);break;case 22:u.setExcludes(n[o].substr(9)),this.$=n[o].substr(9);break;case 23:u.setIncludes(n[o].substr(9)),this.$=n[o].substr(9);break;case 24:u.setTodayMarker(n[o].substr(12)),this.$=n[o].substr(12);break;case 27:u.setDiagramTitle(n[o].substr(6)),this.$=n[o].substr(6);break;case 28:this.$=n[o].trim(),u.setAccTitle(this.$);break;case 29:case 30:this.$=n[o].trim(),u.setAccDescription(this.$);break;case 31:u.addSection(n[o].substr(8)),this.$=n[o].substr(8);break;case 33:u.addTask(n[o-1],n[o]),this.$="task";break;case 34:this.$=n[o-1],u.setClickEvent(n[o-1],n[o],null);break;case 35:this.$=n[o-2],u.setClickEvent(n[o-2],n[o-1],n[o]);break;case 36:this.$=n[o-2],u.setClickEvent(n[o-2],n[o-1],null),u.setLink(n[o-2],n[o]);break;case 37:this.$=n[o-3],u.setClickEvent(n[o-3],n[o-2],n[o-1]),u.setLink(n[o-3],n[o]);break;case 38:this.$=n[o-2],u.setClickEvent(n[o-2],n[o],null),u.setLink(n[o-2],n[o-1]);break;case 39:this.$=n[o-3],u.setClickEvent(n[o-3],n[o-1],n[o]),u.setLink(n[o-3],n[o-2]);break;case 40:this.$=n[o-1],u.setLink(n[o-1],n[o]);break;case 41:case 47:this.$=n[o-1]+" "+n[o];break;case 42:case 43:case 45:this.$=n[o-2]+" "+n[o-1]+" "+n[o];break;case 44:case 46:this.$=n[o-3]+" "+n[o-2]+" "+n[o-1]+" "+n[o];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:s,13:r,14:i,15:g,16:y,17:b,18:S,19:18,20:L,21:_,22:W,23:w,24:D,25:N,26:V,27:k,28:M,29:P,30:O,31:B,33:H,35:I,36:x,37:24,38:h,40:E},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:s,13:r,14:i,15:g,16:y,17:b,18:S,19:18,20:L,21:_,22:W,23:w,24:D,25:N,26:V,27:k,28:M,29:P,30:O,31:B,33:H,35:I,36:x,37:24,38:h,40:E},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:l(function(a,d){if(d.recoverable)this.trace(a);else{var m=new Error(a);throw m.hash=d,m}},"parseError"),parse:l(function(a){var d=this,m=[0],u=[],C=[null],n=[],$=this.table,o="",G=0,c=0,A=2,Y=1,R=n.slice.call(arguments,1),F=Object.create(this.lexer),q={yy:{}};for(var z in this.yy)Object.prototype.hasOwnProperty.call(this.yy,z)&&(q.yy[z]=this.yy[z]);F.setInput(a,q.yy),q.yy.lexer=F,q.yy.parser=this,typeof F.yylloc>"u"&&(F.yylloc={});var nt=F.yylloc;n.push(nt);var at=F.options&&F.options.ranges;typeof q.yy.parseError=="function"?this.parseError=q.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function yt(Q){m.length=m.length-2*Q,C.length=C.length-Q,n.length=n.length-Q}l(yt,"popStack");function lt(){var Q;return Q=u.pop()||F.lex()||Y,typeof Q!="number"&&(Q instanceof Array&&(u=Q,Q=u.pop()),Q=d.symbols_[Q]||Q),Q}l(lt,"lex");for(var j,K,Z,ot,J={},it,tt,Ut,pt;;){if(K=m[m.length-1],this.defaultActions[K]?Z=this.defaultActions[K]:((j===null||typeof j>"u")&&(j=lt()),Z=$[K]&&$[K][j]),typeof Z>"u"||!Z.length||!Z[0]){var $t="";pt=[];for(it in $[K])this.terminals_[it]&&it>A&&pt.push("'"+this.terminals_[it]+"'");F.showPosition?$t="Parse error on line "+(G+1)+`:
|
|
1
|
+
import{g as be,s as we,x as _e,v as De,a as Se,b as Ce,_ as l,c as dt,k as vt,d as Me,b2 as U,l as st,m as Ee,p as Ie,D as $e,u as Ae}from"./mermaid.core-DnPykQEf.js";import{ag as It}from"./styles-B6mWzGeo.js";import{t as Ye,m as Fe,a as Le,i as Oe,b as Zt,c as Qt,d as We,e as Pe,f as Ve,g as ze,h as Re,j as Ne,k as He,l as Kt,n as Jt,o as te,s as ee,p as re}from"./time-CZ0C3Dvk.js";import{l as Be}from"./linear-ChbPfC31.js";import"./step-CkmJJ7wq.js";import"./init-Dmth1JHB.js";import"./defaultLocale-CzDG__Ur.js";function qe(t){return t}var Tt=1,At=2,Ft=3,xt=4,se=1e-6;function Ge(t){return"translate("+t+",0)"}function je(t){return"translate(0,"+t+")"}function Xe(t){return e=>+t(e)}function Ue(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),s=>+t(s)+e}function Ze(){return!this.__axis}function de(t,e){var s=[],r=null,i=null,g=6,y=6,b=3,S=typeof window<"u"&&window.devicePixelRatio>1?0:.5,L=t===Tt||t===xt?-1:1,_=t===xt||t===At?"x":"y",W=t===Tt||t===Ft?Ge:je;function w(D){var N=r??(e.ticks?e.ticks.apply(e,s):e.domain()),V=i??(e.tickFormat?e.tickFormat.apply(e,s):qe),k=Math.max(g,0)+b,M=e.range(),P=+M[0]+S,O=+M[M.length-1]+S,B=(e.bandwidth?Ue:Xe)(e.copy(),S),H=D.selection?D.selection():D,I=H.selectAll(".domain").data([null]),x=H.selectAll(".tick").data(N,e).order(),h=x.exit(),E=x.enter().append("g").attr("class","tick"),f=x.select("line"),T=x.select("text");I=I.merge(I.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),x=x.merge(E),f=f.merge(E.append("line").attr("stroke","currentColor").attr(_+"2",L*g)),T=T.merge(E.append("text").attr("fill","currentColor").attr(_,L*k).attr("dy",t===Tt?"0em":t===Ft?"0.71em":"0.32em")),D!==H&&(I=I.transition(D),x=x.transition(D),f=f.transition(D),T=T.transition(D),h=h.transition(D).attr("opacity",se).attr("transform",function(v){return isFinite(v=B(v))?W(v+S):this.getAttribute("transform")}),E.attr("opacity",se).attr("transform",function(v){var p=this.parentNode.__axis;return W((p&&isFinite(p=p(v))?p:B(v))+S)})),h.remove(),I.attr("d",t===xt||t===At?y?"M"+L*y+","+P+"H"+S+"V"+O+"H"+L*y:"M"+S+","+P+"V"+O:y?"M"+P+","+L*y+"V"+S+"H"+O+"V"+L*y:"M"+P+","+S+"H"+O),x.attr("opacity",1).attr("transform",function(v){return W(B(v)+S)}),f.attr(_+"2",L*g),T.attr(_,L*k).text(V),H.filter(Ze).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===At?"start":t===xt?"end":"middle"),H.each(function(){this.__axis=B})}return w.scale=function(D){return arguments.length?(e=D,w):e},w.ticks=function(){return s=Array.from(arguments),w},w.tickArguments=function(D){return arguments.length?(s=D==null?[]:Array.from(D),w):s.slice()},w.tickValues=function(D){return arguments.length?(r=D==null?null:Array.from(D),w):r&&r.slice()},w.tickFormat=function(D){return arguments.length?(i=D,w):i},w.tickSize=function(D){return arguments.length?(g=y=+D,w):g},w.tickSizeInner=function(D){return arguments.length?(g=+D,w):g},w.tickSizeOuter=function(D){return arguments.length?(y=+D,w):y},w.tickPadding=function(D){return arguments.length?(b=+D,w):b},w.offset=function(D){return arguments.length?(S=+D,w):S},w}function Qe(t){return de(Tt,t)}function Ke(t){return de(Ft,t)}var bt={exports:{}},Je=bt.exports,ne;function tr(){return ne||(ne=1,(function(t,e){(function(s,r){t.exports=r()})(Je,(function(){var s="day";return function(r,i,g){var y=function(L){return L.add(4-L.isoWeekday(),s)},b=i.prototype;b.isoWeekYear=function(){return y(this).year()},b.isoWeek=function(L){if(!this.$utils().u(L))return this.add(7*(L-this.isoWeek()),s);var _,W,w,D,N=y(this),V=(_=this.isoWeekYear(),W=this.$u,w=(W?g.utc:g)().year(_).startOf("year"),D=4-w.isoWeekday(),w.isoWeekday()>4&&(D+=7),w.add(D,s));return N.diff(V,"week")+1},b.isoWeekday=function(L){return this.$utils().u(L)?this.day()||7:this.day(this.day()%7?L:L-7)};var S=b.startOf;b.startOf=function(L,_){var W=this.$utils(),w=!!W.u(_)||_;return W.p(L)==="isoweek"?w?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):S.bind(this)(L,_)}}}))})(bt)),bt.exports}var er=tr();const rr=It(er);var wt={exports:{}},sr=wt.exports,ie;function nr(){return ie||(ie=1,(function(t,e){(function(s,r){t.exports=r()})(sr,(function(){var s={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},r=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d/,g=/\d\d/,y=/\d\d?/,b=/\d*[^-_:/,()\s\d]+/,S={},L=function(k){return(k=+k)+(k>68?1900:2e3)},_=function(k){return function(M){this[k]=+M}},W=[/[+-]\d\d:?(\d\d)?|Z/,function(k){(this.zone||(this.zone={})).offset=(function(M){if(!M||M==="Z")return 0;var P=M.match(/([+-]|\d\d)/g),O=60*P[1]+(+P[2]||0);return O===0?0:P[0]==="+"?-O:O})(k)}],w=function(k){var M=S[k];return M&&(M.indexOf?M:M.s.concat(M.f))},D=function(k,M){var P,O=S.meridiem;if(O){for(var B=1;B<=24;B+=1)if(k.indexOf(O(B,0,M))>-1){P=B>12;break}}else P=k===(M?"pm":"PM");return P},N={A:[b,function(k){this.afternoon=D(k,!1)}],a:[b,function(k){this.afternoon=D(k,!0)}],Q:[i,function(k){this.month=3*(k-1)+1}],S:[i,function(k){this.milliseconds=100*+k}],SS:[g,function(k){this.milliseconds=10*+k}],SSS:[/\d{3}/,function(k){this.milliseconds=+k}],s:[y,_("seconds")],ss:[y,_("seconds")],m:[y,_("minutes")],mm:[y,_("minutes")],H:[y,_("hours")],h:[y,_("hours")],HH:[y,_("hours")],hh:[y,_("hours")],D:[y,_("day")],DD:[g,_("day")],Do:[b,function(k){var M=S.ordinal,P=k.match(/\d+/);if(this.day=P[0],M)for(var O=1;O<=31;O+=1)M(O).replace(/\[|\]/g,"")===k&&(this.day=O)}],w:[y,_("week")],ww:[g,_("week")],M:[y,_("month")],MM:[g,_("month")],MMM:[b,function(k){var M=w("months"),P=(w("monthsShort")||M.map((function(O){return O.slice(0,3)}))).indexOf(k)+1;if(P<1)throw new Error;this.month=P%12||P}],MMMM:[b,function(k){var M=w("months").indexOf(k)+1;if(M<1)throw new Error;this.month=M%12||M}],Y:[/[+-]?\d+/,_("year")],YY:[g,function(k){this.year=L(k)}],YYYY:[/\d{4}/,_("year")],Z:W,ZZ:W};function V(k){var M,P;M=k,P=S&&S.formats;for(var O=(k=M.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(f,T,v){var p=v&&v.toUpperCase();return T||P[v]||s[v]||P[p].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(a,d,m){return d||m.slice(1)}))}))).match(r),B=O.length,H=0;H<B;H+=1){var I=O[H],x=N[I],h=x&&x[0],E=x&&x[1];O[H]=E?{regex:h,parser:E}:I.replace(/^\[|\]$/g,"")}return function(f){for(var T={},v=0,p=0;v<B;v+=1){var a=O[v];if(typeof a=="string")p+=a.length;else{var d=a.regex,m=a.parser,u=f.slice(p),C=d.exec(u)[0];m.call(T,C),f=f.replace(C,"")}}return(function(n){var $=n.afternoon;if($!==void 0){var o=n.hours;$?o<12&&(n.hours+=12):o===12&&(n.hours=0),delete n.afternoon}})(T),T}}return function(k,M,P){P.p.customParseFormat=!0,k&&k.parseTwoDigitYear&&(L=k.parseTwoDigitYear);var O=M.prototype,B=O.parse;O.parse=function(H){var I=H.date,x=H.utc,h=H.args;this.$u=x;var E=h[1];if(typeof E=="string"){var f=h[2]===!0,T=h[3]===!0,v=f||T,p=h[2];T&&(p=h[2]),S=this.$locale(),!f&&p&&(S=P.Ls[p]),this.$d=(function(u,C,n,$){try{if(["x","X"].indexOf(C)>-1)return new Date((C==="X"?1e3:1)*u);var o=V(C)(u),G=o.year,c=o.month,A=o.day,Y=o.hours,R=o.minutes,F=o.seconds,q=o.milliseconds,z=o.zone,nt=o.week,at=new Date,yt=A||(G||c?1:at.getDate()),lt=G||at.getFullYear(),j=0;G&&!c||(j=c>0?c-1:at.getMonth());var K,Z=Y||0,ot=R||0,J=F||0,it=q||0;return z?new Date(Date.UTC(lt,j,yt,Z,ot,J,it+60*z.offset*1e3)):n?new Date(Date.UTC(lt,j,yt,Z,ot,J,it)):(K=new Date(lt,j,yt,Z,ot,J,it),nt&&(K=$(K).week(nt).toDate()),K)}catch{return new Date("")}})(I,E,x,P),this.init(),p&&p!==!0&&(this.$L=this.locale(p).$L),v&&I!=this.format(E)&&(this.$d=new Date("")),S={}}else if(E instanceof Array)for(var a=E.length,d=1;d<=a;d+=1){h[1]=E[d-1];var m=P.apply(this,h);if(m.isValid()){this.$d=m.$d,this.$L=m.$L,this.init();break}d===a&&(this.$d=new Date(""))}else B.call(this,H)}}}))})(wt)),wt.exports}var ir=nr();const ar=It(ir);var _t={exports:{}},or=_t.exports,ae;function cr(){return ae||(ae=1,(function(t,e){(function(s,r){t.exports=r()})(or,(function(){return function(s,r){var i=r.prototype,g=i.format;i.format=function(y){var b=this,S=this.$locale();if(!this.isValid())return g.bind(this)(y);var L=this.$utils(),_=(y||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(W){switch(W){case"Q":return Math.ceil((b.$M+1)/3);case"Do":return S.ordinal(b.$D);case"gggg":return b.weekYear();case"GGGG":return b.isoWeekYear();case"wo":return S.ordinal(b.week(),"W");case"w":case"ww":return L.s(b.week(),W==="w"?1:2,"0");case"W":case"WW":return L.s(b.isoWeek(),W==="W"?1:2,"0");case"k":case"kk":return L.s(String(b.$H===0?24:b.$H),W==="k"?1:2,"0");case"X":return Math.floor(b.$d.getTime()/1e3);case"x":return b.$d.getTime();case"z":return"["+b.offsetName()+"]";case"zzz":return"["+b.offsetName("long")+"]";default:return W}}));return g.bind(this)(_)}}}))})(_t)),_t.exports}var lr=cr();const ur=It(lr);var Dt={exports:{}},dr=Dt.exports,oe;function fr(){return oe||(oe=1,(function(t,e){(function(s,r){t.exports=r()})(dr,(function(){var s,r,i=1e3,g=6e4,y=36e5,b=864e5,S=31536e6,L=2628e6,_=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,W=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,w={years:S,months:L,days:b,hours:y,minutes:g,seconds:i,milliseconds:1,weeks:6048e5},D=function(I){return I instanceof B},N=function(I,x,h){return new B(I,h,x.$l)},V=function(I){return r.p(I)+"s"},k=function(I){return I<0},M=function(I){return k(I)?Math.ceil(I):Math.floor(I)},P=function(I){return Math.abs(I)},O=function(I,x){return I?k(I)?{negative:!0,format:""+P(I)+x}:{negative:!1,format:""+I+x}:{negative:!1,format:""}},B=(function(){function I(h,E,f){var T=this;if(this.$d={},this.$l=f,h===void 0&&(this.$ms=0,this.parseFromMilliseconds()),E)return N(h*w[V(E)],this);if(typeof h=="number")return this.$ms=h,this.parseFromMilliseconds(),this;if(typeof h=="object")return Object.keys(h).forEach((function(a){T.$d[V(a)]=h[a]})),this.calMilliseconds(),this;if(typeof h=="string"){var v=h.match(_);if(v){var p=v.slice(2).map((function(a){return a!=null?Number(a):0}));return this.$d.years=p[0],this.$d.months=p[1],this.$d.weeks=p[2],this.$d.days=p[3],this.$d.hours=p[4],this.$d.minutes=p[5],this.$d.seconds=p[6],this.calMilliseconds(),this}}return this}var x=I.prototype;return x.calMilliseconds=function(){var h=this;this.$ms=Object.keys(this.$d).reduce((function(E,f){return E+(h.$d[f]||0)*w[f]}),0)},x.parseFromMilliseconds=function(){var h=this.$ms;this.$d.years=M(h/S),h%=S,this.$d.months=M(h/L),h%=L,this.$d.days=M(h/b),h%=b,this.$d.hours=M(h/y),h%=y,this.$d.minutes=M(h/g),h%=g,this.$d.seconds=M(h/i),h%=i,this.$d.milliseconds=h},x.toISOString=function(){var h=O(this.$d.years,"Y"),E=O(this.$d.months,"M"),f=+this.$d.days||0;this.$d.weeks&&(f+=7*this.$d.weeks);var T=O(f,"D"),v=O(this.$d.hours,"H"),p=O(this.$d.minutes,"M"),a=this.$d.seconds||0;this.$d.milliseconds&&(a+=this.$d.milliseconds/1e3,a=Math.round(1e3*a)/1e3);var d=O(a,"S"),m=h.negative||E.negative||T.negative||v.negative||p.negative||d.negative,u=v.format||p.format||d.format?"T":"",C=(m?"-":"")+"P"+h.format+E.format+T.format+u+v.format+p.format+d.format;return C==="P"||C==="-P"?"P0D":C},x.toJSON=function(){return this.toISOString()},x.format=function(h){var E=h||"YYYY-MM-DDTHH:mm:ss",f={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return E.replace(W,(function(T,v){return v||String(f[T])}))},x.as=function(h){return this.$ms/w[V(h)]},x.get=function(h){var E=this.$ms,f=V(h);return f==="milliseconds"?E%=1e3:E=f==="weeks"?M(E/w[f]):this.$d[f],E||0},x.add=function(h,E,f){var T;return T=E?h*w[V(E)]:D(h)?h.$ms:N(h,this).$ms,N(this.$ms+T*(f?-1:1),this)},x.subtract=function(h,E){return this.add(h,E,!0)},x.locale=function(h){var E=this.clone();return E.$l=h,E},x.clone=function(){return N(this.$ms,this)},x.humanize=function(h){return s().add(this.$ms,"ms").locale(this.$l).fromNow(!h)},x.valueOf=function(){return this.asMilliseconds()},x.milliseconds=function(){return this.get("milliseconds")},x.asMilliseconds=function(){return this.as("milliseconds")},x.seconds=function(){return this.get("seconds")},x.asSeconds=function(){return this.as("seconds")},x.minutes=function(){return this.get("minutes")},x.asMinutes=function(){return this.as("minutes")},x.hours=function(){return this.get("hours")},x.asHours=function(){return this.as("hours")},x.days=function(){return this.get("days")},x.asDays=function(){return this.as("days")},x.weeks=function(){return this.get("weeks")},x.asWeeks=function(){return this.as("weeks")},x.months=function(){return this.get("months")},x.asMonths=function(){return this.as("months")},x.years=function(){return this.get("years")},x.asYears=function(){return this.as("years")},I})(),H=function(I,x,h){return I.add(x.years()*h,"y").add(x.months()*h,"M").add(x.days()*h,"d").add(x.hours()*h,"h").add(x.minutes()*h,"m").add(x.seconds()*h,"s").add(x.milliseconds()*h,"ms")};return function(I,x,h){s=h,r=h().$utils(),h.duration=function(T,v){var p=h.locale();return N(T,{$l:p},v)},h.isDuration=D;var E=x.prototype.add,f=x.prototype.subtract;x.prototype.add=function(T,v){return D(T)?H(this,T,1):E.bind(this)(T,v)},x.prototype.subtract=function(T,v){return D(T)?H(this,T,-1):f.bind(this)(T,v)}}}))})(Dt)),Dt.exports}var hr=fr();const mr=It(hr);var Lt=(function(){var t=l(function(p,a,d,m){for(d=d||{},m=p.length;m--;d[p[m]]=a);return d},"o"),e=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],s=[1,26],r=[1,27],i=[1,28],g=[1,29],y=[1,30],b=[1,31],S=[1,32],L=[1,33],_=[1,34],W=[1,9],w=[1,10],D=[1,11],N=[1,12],V=[1,13],k=[1,14],M=[1,15],P=[1,16],O=[1,19],B=[1,20],H=[1,21],I=[1,22],x=[1,23],h=[1,25],E=[1,35],f={trace:l(function(){},"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:l(function(a,d,m,u,C,n,$){var o=n.length-1;switch(C){case 1:return n[o-1];case 2:this.$=[];break;case 3:n[o-1].push(n[o]),this.$=n[o-1];break;case 4:case 5:this.$=n[o];break;case 6:case 7:this.$=[];break;case 8:u.setWeekday("monday");break;case 9:u.setWeekday("tuesday");break;case 10:u.setWeekday("wednesday");break;case 11:u.setWeekday("thursday");break;case 12:u.setWeekday("friday");break;case 13:u.setWeekday("saturday");break;case 14:u.setWeekday("sunday");break;case 15:u.setWeekend("friday");break;case 16:u.setWeekend("saturday");break;case 17:u.setDateFormat(n[o].substr(11)),this.$=n[o].substr(11);break;case 18:u.enableInclusiveEndDates(),this.$=n[o].substr(18);break;case 19:u.TopAxis(),this.$=n[o].substr(8);break;case 20:u.setAxisFormat(n[o].substr(11)),this.$=n[o].substr(11);break;case 21:u.setTickInterval(n[o].substr(13)),this.$=n[o].substr(13);break;case 22:u.setExcludes(n[o].substr(9)),this.$=n[o].substr(9);break;case 23:u.setIncludes(n[o].substr(9)),this.$=n[o].substr(9);break;case 24:u.setTodayMarker(n[o].substr(12)),this.$=n[o].substr(12);break;case 27:u.setDiagramTitle(n[o].substr(6)),this.$=n[o].substr(6);break;case 28:this.$=n[o].trim(),u.setAccTitle(this.$);break;case 29:case 30:this.$=n[o].trim(),u.setAccDescription(this.$);break;case 31:u.addSection(n[o].substr(8)),this.$=n[o].substr(8);break;case 33:u.addTask(n[o-1],n[o]),this.$="task";break;case 34:this.$=n[o-1],u.setClickEvent(n[o-1],n[o],null);break;case 35:this.$=n[o-2],u.setClickEvent(n[o-2],n[o-1],n[o]);break;case 36:this.$=n[o-2],u.setClickEvent(n[o-2],n[o-1],null),u.setLink(n[o-2],n[o]);break;case 37:this.$=n[o-3],u.setClickEvent(n[o-3],n[o-2],n[o-1]),u.setLink(n[o-3],n[o]);break;case 38:this.$=n[o-2],u.setClickEvent(n[o-2],n[o],null),u.setLink(n[o-2],n[o-1]);break;case 39:this.$=n[o-3],u.setClickEvent(n[o-3],n[o-1],n[o]),u.setLink(n[o-3],n[o-2]);break;case 40:this.$=n[o-1],u.setLink(n[o-1],n[o]);break;case 41:case 47:this.$=n[o-1]+" "+n[o];break;case 42:case 43:case 45:this.$=n[o-2]+" "+n[o-1]+" "+n[o];break;case 44:case 46:this.$=n[o-3]+" "+n[o-2]+" "+n[o-1]+" "+n[o];break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:s,13:r,14:i,15:g,16:y,17:b,18:S,19:18,20:L,21:_,22:W,23:w,24:D,25:N,26:V,27:k,28:M,29:P,30:O,31:B,33:H,35:I,36:x,37:24,38:h,40:E},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:s,13:r,14:i,15:g,16:y,17:b,18:S,19:18,20:L,21:_,22:W,23:w,24:D,25:N,26:V,27:k,28:M,29:P,30:O,31:B,33:H,35:I,36:x,37:24,38:h,40:E},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:l(function(a,d){if(d.recoverable)this.trace(a);else{var m=new Error(a);throw m.hash=d,m}},"parseError"),parse:l(function(a){var d=this,m=[0],u=[],C=[null],n=[],$=this.table,o="",G=0,c=0,A=2,Y=1,R=n.slice.call(arguments,1),F=Object.create(this.lexer),q={yy:{}};for(var z in this.yy)Object.prototype.hasOwnProperty.call(this.yy,z)&&(q.yy[z]=this.yy[z]);F.setInput(a,q.yy),q.yy.lexer=F,q.yy.parser=this,typeof F.yylloc>"u"&&(F.yylloc={});var nt=F.yylloc;n.push(nt);var at=F.options&&F.options.ranges;typeof q.yy.parseError=="function"?this.parseError=q.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function yt(Q){m.length=m.length-2*Q,C.length=C.length-Q,n.length=n.length-Q}l(yt,"popStack");function lt(){var Q;return Q=u.pop()||F.lex()||Y,typeof Q!="number"&&(Q instanceof Array&&(u=Q,Q=u.pop()),Q=d.symbols_[Q]||Q),Q}l(lt,"lex");for(var j,K,Z,ot,J={},it,tt,Ut,pt;;){if(K=m[m.length-1],this.defaultActions[K]?Z=this.defaultActions[K]:((j===null||typeof j>"u")&&(j=lt()),Z=$[K]&&$[K][j]),typeof Z>"u"||!Z.length||!Z[0]){var $t="";pt=[];for(it in $[K])this.terminals_[it]&&it>A&&pt.push("'"+this.terminals_[it]+"'");F.showPosition?$t="Parse error on line "+(G+1)+`:
|
|
2
2
|
`+F.showPosition()+`
|
|
3
3
|
Expecting `+pt.join(", ")+", got '"+(this.terminals_[j]||j)+"'":$t="Parse error on line "+(G+1)+": Unexpected "+(j==Y?"end of input":"'"+(this.terminals_[j]||j)+"'"),this.parseError($t,{text:F.match,token:this.terminals_[j]||j,line:F.yylineno,loc:nt,expected:pt})}if(Z[0]instanceof Array&&Z.length>1)throw new Error("Parse Error: multiple actions possible at state: "+K+", token: "+j);switch(Z[0]){case 1:m.push(j),C.push(F.yytext),n.push(F.yylloc),m.push(Z[1]),j=null,c=F.yyleng,o=F.yytext,G=F.yylineno,nt=F.yylloc;break;case 2:if(tt=this.productions_[Z[1]][1],J.$=C[C.length-tt],J._$={first_line:n[n.length-(tt||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(tt||1)].first_column,last_column:n[n.length-1].last_column},at&&(J._$.range=[n[n.length-(tt||1)].range[0],n[n.length-1].range[1]]),ot=this.performAction.apply(J,[o,c,G,q.yy,Z[1],C,n].concat(R)),typeof ot<"u")return ot;tt&&(m=m.slice(0,-1*tt*2),C=C.slice(0,-1*tt),n=n.slice(0,-1*tt)),m.push(this.productions_[Z[1]][0]),C.push(J.$),n.push(J._$),Ut=$[m[m.length-2]][m[m.length-1]],m.push(Ut);break;case 3:return!0}}return!0},"parse")},T=(function(){var p={EOF:1,parseError:l(function(d,m){if(this.yy.parser)this.yy.parser.parseError(d,m);else throw new Error(d)},"parseError"),setInput:l(function(a,d){return this.yy=d||this.yy||{},this._input=a,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:l(function(){var a=this._input[0];this.yytext+=a,this.yyleng++,this.offset++,this.match+=a,this.matched+=a;var d=a.match(/(?:\r\n?|\n).*/g);return d?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),a},"input"),unput:l(function(a){var d=a.length,m=a.split(/(?:\r\n?|\n)/g);this._input=a+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var u=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),m.length-1&&(this.yylineno-=m.length-1);var C=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:m?(m.length===u.length?this.yylloc.first_column:0)+u[u.length-m.length].length-m[0].length:this.yylloc.first_column-d},this.options.ranges&&(this.yylloc.range=[C[0],C[0]+this.yyleng-d]),this.yyleng=this.yytext.length,this},"unput"),more:l(function(){return this._more=!0,this},"more"),reject:l(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:l(function(a){this.unput(this.match.slice(a))},"less"),pastInput:l(function(){var a=this.matched.substr(0,this.matched.length-this.match.length);return(a.length>20?"...":"")+a.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:l(function(){var a=this.match;return a.length<20&&(a+=this._input.substr(0,20-a.length)),(a.substr(0,20)+(a.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:l(function(){var a=this.pastInput(),d=new Array(a.length+1).join("-");return a+this.upcomingInput()+`
|
package/dist/assets/{gitGraphDiagram-XJZIOB7I-BTmKWoNh.js → gitGraphDiagram-XJZIOB7I-Br3yR3lD.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{I as le}from"./chunk-2Q5K7J3B-BcoVdvme.js";import{p as he}from"./chunk-JWPE2WC7-DKqcjgA7.js";import{x as $e,v as fe,s as ge,g as ue,a as ye,b as xe,_ as h,O as Q,l as w,k as me,c as q,u as pe,P as be,D as we,m as B,Q as ke,R as ve,S as Ce}from"./mermaid.core-Bu-wU9fU.js";import{p as Ee}from"./cynefin-EF2NZ3EQ-Cb52YArt.js";import"./styles-BkKe8nrS.js";import"./step-CkmJJ7wq.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Be=ve.gitGraph,S=h(()=>ke({...Be,...Q().gitGraph}),"getConfig"),d=new le(()=>{const e=S(),r=e.mainBranchName,t=e.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:t}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function Y(){return Ce({length:7})}h(Y,"getID");function te(e,r){const t=Object.create(null);return e.reduce((s,o)=>{const i=r(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(te,"uniqBy");var Te=h(function(e){d.records.direction=e},"setDirection"),Le=h(function(e){w.debug("options str",e),e=e?.trim(),e=e||"{}";try{d.records.options=JSON.parse(e)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),Me=h(function(){return d.records.options},"getOptions"),Re=h(function(e){let r=e.msg,t=e.id;const s=e.type;let o=e.tags;w.info("commit",r,t,s,o),w.debug("Entering commit:",r,t,s,o);const i=S();t=B.sanitizeText(t,i),r=B.sanitizeText(r,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:r,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Ie=h(function(e){let r=e.name;const t=e.order;if(r=B.sanitizeText(r,S()),d.records.branches.has(r))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${r}")`);d.records.branches.set(r,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(r,{name:r,order:t}),ae(r),w.debug("in createBranch")},"branch"),Oe=h(e=>{let r=e.branch,t=e.id;const s=e.type,o=e.tags,i=S();r=B.sanitizeText(r,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(r),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(d.records.currBranch===r){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},c}if(!d.records.branches.has(r)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${r} ${t} ${s} ${o?.join(" ")}`,token:`merge ${r} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${r} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${r} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_e=h(function(e){let r=e.id,t=e.targetId,s=e.tags,o=e.parent;w.debug("Entering cherryPick:",r,t,s);const i=S();if(r=B.sanitizeText(r,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!r||!d.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(r);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ae=h(function(e){if(e=B.sanitizeText(e,S()),d.records.branches.has(e)){d.records.currBranch=e;const r=d.records.branches.get(d.records.currBranch);r===void 0||!r?d.records.head=null:d.records.head=d.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw r.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},r}},"checkout");function V(e,r,t){const s=e.indexOf(r);s===-1?e.push(t):e.splice(s,1,t)}h(V,"upsert");function J(e){const r=e.reduce((o,i)=>o.seq>i.seq?o:i,e[0]);let t="";e.forEach(function(o){o===r?t+=" *":t+=" |"});const s=[t,r.id,r.seq];for(const o in d.records.branches)d.records.branches.get(o)===r.id&&s.push(o);if(w.debug(s.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const o=d.records.commits.get(r.parents[0]);V(e,r,o),r.parents[1]&&e.push(d.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const o=d.records.commits.get(r.parents[0]);V(e,r,o)}}e=te(e,o=>o.id),J(e)}h(J,"prettyPrintCommitHistory");var Ge=h(function(){w.debug(d.records.commits);const e=ne()[0];J([e])},"prettyPrint"),He=h(function(){d.reset(),we()},"clear"),Se=h(function(){return[...d.records.branchConfig.values()].map((r,t)=>r.order!==null&&r.order!==void 0?r:{...r,order:parseFloat(`0.${t}`)}).sort((r,t)=>(r.order??0)-(t.order??0)).map(({name:r})=>({name:r}))},"getBranchesAsObjArray"),Ae=h(function(){return d.records.branches},"getBranches"),De=h(function(){return d.records.commits},"getCommits"),ne=h(function(){const e=[...d.records.commits.values()];return e.forEach(function(r){w.debug(r.id)}),e.sort((r,t)=>r.seq-t.seq),e},"getCommitsArray"),Pe=h(function(){return d.records.currBranch},"getCurrentBranch"),We=h(function(){return d.records.direction},"getDirection"),qe=h(function(){return d.records.head},"getHead"),se={commitType:m,getConfig:S,setDirection:Te,setOptions:Le,getOptions:Me,commit:Re,branch:Ie,merge:Oe,cherryPick:_e,checkout:ae,prettyPrint:Ge,clear:He,getBranchesAsObjArray:Se,getBranches:Ae,getCommits:De,getCommitsArray:ne,getCurrentBranch:Pe,getDirection:We,getHead:qe,setAccTitle:xe,getAccTitle:ye,getAccDescription:ue,setAccDescription:ge,setDiagramTitle:fe,getDiagramTitle:$e},Ne=h((e,r)=>{he(e,r),e.dir&&r.setDirection(e.dir);for(const t of e.statements)Fe(t,r)},"populate"),Fe=h((e,r)=>{const s={Commit:h(o=>r.commit(ze(o)),"Commit"),Branch:h(o=>r.branch(Ye(o)),"Branch"),Merge:h(o=>r.merge(je(o)),"Merge"),Checkout:h(o=>r.checkout(Ue(o)),"Checkout"),CherryPicking:h(o=>r.cherryPick(Ke(o)),"CherryPicking")}[e.$type];s?s(e):w.error(`Unknown statement type: ${e.$type}`)},"parseStatement"),ze=h(e=>({id:e.id,msg:e.message??"",type:e.type!==void 0?m[e.type]:m.NORMAL,tags:e.tags??void 0}),"parseCommit"),Ye=h(e=>({name:e.name,order:e.order??0}),"parseBranch"),je=h(e=>({branch:e.branch,id:e.id??"",type:e.type!==void 0?m[e.type]:void 0,tags:e.tags??void 0}),"parseMerge"),Ue=h(e=>e.branch,"parseCheckout"),Ke=h(e=>({id:e.id,targetId:"",tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),"parseCherryPicking"),Ve={parse:h(async e=>{const r=await Ee("gitGraph",e);w.debug(r),Ne(r,se)},"parse")},O=10,_=40,L=4,R=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xe=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((e,r,t=!1)=>t&&e>0?(e-1)%(r-1)+1:e%r,"calcColorIndex"),C=new Map,E=new Map,F=30,P=new Map,z=[],I=0,y="LR",Qe=h(()=>{C.clear(),E.clear(),P.clear(),I=0,z=[],y="LR"},"clear"),oe=h(e=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof e=="string"?e.split(/\\n|\n|<br\s*\/?>/gi):e).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),r.appendChild(o)}),r},"drawText"),ce=h(e=>{let r,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),e.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(r=o,s=i)}),r},"findClosestParent"),Je=h(e=>{let r="",t=1/0;return e.forEach(s=>{const o=E.get(s).y;o<=t&&(r=s,t=o)}),r||void 0},"findClosestParentBT"),Ze=h((e,r,t)=>{let s=t,o=t;const i=[];e.forEach(n=>{const a=r.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=rr(a),o=Math.max(s,o)):i.push(a),tr(a,s)}),s=o,i.forEach(n=>{ar(n,s,t)}),e.forEach(n=>{const a=r.get(n);if(a?.parents.length){const l=Je(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),er=h(e=>{const r=ce(e.parents.filter(s=>s!==null));if(!r)throw new Error(`Closest parent not found for commit ${e.id}`);const t=E.get(r)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${e.id}`);return t},"findClosestParentPos"),rr=h(e=>er(e)+_,"calculateCommitPosition"),tr=h((e,r)=>{const t=C.get(e.branch);if(!t)throw new Error(`Branch not found for commit ${e.id}`);const s=t.pos,o=r+O;return E.set(e.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ar=h((e,r,t)=>{const s=C.get(e.branch);if(!s)throw new Error(`Branch not found for commit ${e.id}`);const o=r+t,i=s.pos;E.set(e.id,{x:i,y:o})},"setRootPosition"),nr=h((e,r,t,s,o,i)=>{const{theme:n}=q(),a=j.has(n??""),l=Z.has(n??""),f=Xe.has(n??"");if(i===m.HIGHLIGHT)e.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${r.id} commit-highlight${H(o,G,l)} ${s}-outer`),e.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${r.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)e.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`);else{const g=e.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${r.id} commit${H(o,G,l)}`),i===m.MERGE){const $=e.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=e.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),sr=h((e,r,t,s,o)=>{if(r.type!==m.CHERRY_PICK&&(r.customId&&r.type===m.MERGE||r.type!==m.MERGE)&&o.showCommitLabel){const i=e.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(r.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-R).attr("y",t.y+13.5).attr("width",l.width+2*R).attr("height",l.height+2*R),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),or=h((e,r,t,s)=>{if(r.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of r.tags.reverse()){const f=e.insert("polygon"),g=e.append("circle"),$=e.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
|
|
1
|
+
import{I as le}from"./chunk-2Q5K7J3B-B4S055aQ.js";import{p as he}from"./chunk-JWPE2WC7-CUZeelhu.js";import{x as $e,v as fe,s as ge,g as ue,a as ye,b as xe,_ as h,O as Q,l as w,k as me,c as q,u as pe,P as be,D as we,m as B,Q as ke,R as ve,S as Ce}from"./mermaid.core-DnPykQEf.js";import{p as Ee}from"./cynefin-EF2NZ3EQ-CcOBMv-N.js";import"./styles-B6mWzGeo.js";import"./step-CkmJJ7wq.js";var m={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},Be=ve.gitGraph,S=h(()=>ke({...Be,...Q().gitGraph}),"getConfig"),d=new le(()=>{const e=S(),r=e.mainBranchName,t=e.mainBranchOrder;return{mainBranchName:r,commits:new Map,head:null,branchConfig:new Map([[r,{name:r,order:t}]]),branches:new Map([[r,null]]),currBranch:r,direction:"LR",seq:0,options:{}}});function Y(){return Ce({length:7})}h(Y,"getID");function te(e,r){const t=Object.create(null);return e.reduce((s,o)=>{const i=r(o);return t[i]||(t[i]=!0,s.push(o)),s},[])}h(te,"uniqBy");var Te=h(function(e){d.records.direction=e},"setDirection"),Le=h(function(e){w.debug("options str",e),e=e?.trim(),e=e||"{}";try{d.records.options=JSON.parse(e)}catch(r){w.error("error while parsing gitGraph options",r.message)}},"setOptions"),Me=h(function(){return d.records.options},"getOptions"),Re=h(function(e){let r=e.msg,t=e.id;const s=e.type;let o=e.tags;w.info("commit",r,t,s,o),w.debug("Entering commit:",r,t,s,o);const i=S();t=B.sanitizeText(t,i),r=B.sanitizeText(r,i),o=o?.map(a=>B.sanitizeText(a,i));const n={id:t||d.records.seq+"-"+Y(),message:r,seq:d.records.seq++,type:s??m.NORMAL,tags:o??[],parents:d.records.head==null?[]:[d.records.head.id],branch:d.records.currBranch};d.records.head=n,w.info("main branch",i.mainBranchName),d.records.commits.has(n.id)&&w.warn(`Commit ID ${n.id} already exists`),d.records.commits.set(n.id,n),d.records.branches.set(d.records.currBranch,n.id),w.debug("in pushCommit "+n.id)},"commit"),Ie=h(function(e){let r=e.name;const t=e.order;if(r=B.sanitizeText(r,S()),d.records.branches.has(r))throw new Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${r}")`);d.records.branches.set(r,d.records.head!=null?d.records.head.id:null),d.records.branchConfig.set(r,{name:r,order:t}),ae(r),w.debug("in createBranch")},"branch"),Oe=h(e=>{let r=e.branch,t=e.id;const s=e.type,o=e.tags,i=S();r=B.sanitizeText(r,i),t&&(t=B.sanitizeText(t,i));const n=d.records.branches.get(d.records.currBranch),a=d.records.branches.get(r),l=n?d.records.commits.get(n):void 0,f=a?d.records.commits.get(a):void 0;if(l&&f&&l.branch===r)throw new Error(`Cannot merge branch '${r}' into itself.`);if(d.records.currBranch===r){const c=new Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(l===void 0||!l){const c=new Error(`Incorrect usage of "merge". Current branch (${d.records.currBranch})has no commits`);throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["commit"]},c}if(!d.records.branches.has(r)){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") does not exist");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:[`branch ${r}`]},c}if(f===void 0||!f){const c=new Error('Incorrect usage of "merge". Branch to be merged ('+r+") has no commits");throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:['"commit"']},c}if(l===f){const c=new Error('Incorrect usage of "merge". Both branches have same head');throw c.hash={text:`merge ${r}`,token:`merge ${r}`,expected:["branch abc"]},c}if(t&&d.records.commits.has(t)){const c=new Error('Incorrect usage of "merge". Commit with id:'+t+" already exists, use different custom id");throw c.hash={text:`merge ${r} ${t} ${s} ${o?.join(" ")}`,token:`merge ${r} ${t} ${s} ${o?.join(" ")}`,expected:[`merge ${r} ${t}_UNIQUE ${s} ${o?.join(" ")}`]},c}const g=a||"",$={id:t||`${d.records.seq}-${Y()}`,message:`merged branch ${r} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,g],branch:d.records.currBranch,type:m.MERGE,customType:s,customId:!!t,tags:o??[]};d.records.head=$,d.records.commits.set($.id,$),d.records.branches.set(d.records.currBranch,$.id),w.debug(d.records.branches),w.debug("in mergeBranch")},"merge"),_e=h(function(e){let r=e.id,t=e.targetId,s=e.tags,o=e.parent;w.debug("Entering cherryPick:",r,t,s);const i=S();if(r=B.sanitizeText(r,i),t=B.sanitizeText(t,i),s=s?.map(l=>B.sanitizeText(l,i)),o=B.sanitizeText(o,i),!r||!d.records.commits.has(r)){const l=new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw l.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},l}const n=d.records.commits.get(r);if(n===void 0||!n)throw new Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(o&&!(Array.isArray(n.parents)&&n.parents.includes(o)))throw new Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");const a=n.branch;if(n.type===m.MERGE&&!o)throw new Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!t||!d.records.commits.has(t)){if(a===d.records.currBranch){const $=new Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const l=d.records.branches.get(d.records.currBranch);if(l===void 0||!l){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const f=d.records.commits.get(l);if(f===void 0||!f){const $=new Error(`Incorrect usage of "cherry-pick". Current branch (${d.records.currBranch})has no commits`);throw $.hash={text:`cherryPick ${r} ${t}`,token:`cherryPick ${r} ${t}`,expected:["cherry-pick abc"]},$}const g={id:d.records.seq+"-"+Y(),message:`cherry-picked ${n?.message} into ${d.records.currBranch}`,seq:d.records.seq++,parents:d.records.head==null?[]:[d.records.head.id,n.id],branch:d.records.currBranch,type:m.CHERRY_PICK,tags:s?s.filter(Boolean):[`cherry-pick:${n.id}${n.type===m.MERGE?`|parent:${o}`:""}`]};d.records.head=g,d.records.commits.set(g.id,g),d.records.branches.set(d.records.currBranch,g.id),w.debug(d.records.branches),w.debug("in cherryPick")}},"cherryPick"),ae=h(function(e){if(e=B.sanitizeText(e,S()),d.records.branches.has(e)){d.records.currBranch=e;const r=d.records.branches.get(d.records.currBranch);r===void 0||!r?d.records.head=null:d.records.head=d.records.commits.get(r)??null}else{const r=new Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${e}")`);throw r.hash={text:`checkout ${e}`,token:`checkout ${e}`,expected:[`branch ${e}`]},r}},"checkout");function V(e,r,t){const s=e.indexOf(r);s===-1?e.push(t):e.splice(s,1,t)}h(V,"upsert");function J(e){const r=e.reduce((o,i)=>o.seq>i.seq?o:i,e[0]);let t="";e.forEach(function(o){o===r?t+=" *":t+=" |"});const s=[t,r.id,r.seq];for(const o in d.records.branches)d.records.branches.get(o)===r.id&&s.push(o);if(w.debug(s.join(" ")),r.parents&&r.parents.length==2&&r.parents[0]&&r.parents[1]){const o=d.records.commits.get(r.parents[0]);V(e,r,o),r.parents[1]&&e.push(d.records.commits.get(r.parents[1]))}else{if(r.parents.length==0)return;if(r.parents[0]){const o=d.records.commits.get(r.parents[0]);V(e,r,o)}}e=te(e,o=>o.id),J(e)}h(J,"prettyPrintCommitHistory");var Ge=h(function(){w.debug(d.records.commits);const e=ne()[0];J([e])},"prettyPrint"),He=h(function(){d.reset(),we()},"clear"),Se=h(function(){return[...d.records.branchConfig.values()].map((r,t)=>r.order!==null&&r.order!==void 0?r:{...r,order:parseFloat(`0.${t}`)}).sort((r,t)=>(r.order??0)-(t.order??0)).map(({name:r})=>({name:r}))},"getBranchesAsObjArray"),Ae=h(function(){return d.records.branches},"getBranches"),De=h(function(){return d.records.commits},"getCommits"),ne=h(function(){const e=[...d.records.commits.values()];return e.forEach(function(r){w.debug(r.id)}),e.sort((r,t)=>r.seq-t.seq),e},"getCommitsArray"),Pe=h(function(){return d.records.currBranch},"getCurrentBranch"),We=h(function(){return d.records.direction},"getDirection"),qe=h(function(){return d.records.head},"getHead"),se={commitType:m,getConfig:S,setDirection:Te,setOptions:Le,getOptions:Me,commit:Re,branch:Ie,merge:Oe,cherryPick:_e,checkout:ae,prettyPrint:Ge,clear:He,getBranchesAsObjArray:Se,getBranches:Ae,getCommits:De,getCommitsArray:ne,getCurrentBranch:Pe,getDirection:We,getHead:qe,setAccTitle:xe,getAccTitle:ye,getAccDescription:ue,setAccDescription:ge,setDiagramTitle:fe,getDiagramTitle:$e},Ne=h((e,r)=>{he(e,r),e.dir&&r.setDirection(e.dir);for(const t of e.statements)Fe(t,r)},"populate"),Fe=h((e,r)=>{const s={Commit:h(o=>r.commit(ze(o)),"Commit"),Branch:h(o=>r.branch(Ye(o)),"Branch"),Merge:h(o=>r.merge(je(o)),"Merge"),Checkout:h(o=>r.checkout(Ue(o)),"Checkout"),CherryPicking:h(o=>r.cherryPick(Ke(o)),"CherryPicking")}[e.$type];s?s(e):w.error(`Unknown statement type: ${e.$type}`)},"parseStatement"),ze=h(e=>({id:e.id,msg:e.message??"",type:e.type!==void 0?m[e.type]:m.NORMAL,tags:e.tags??void 0}),"parseCommit"),Ye=h(e=>({name:e.name,order:e.order??0}),"parseBranch"),je=h(e=>({branch:e.branch,id:e.id??"",type:e.type!==void 0?m[e.type]:void 0,tags:e.tags??void 0}),"parseMerge"),Ue=h(e=>e.branch,"parseCheckout"),Ke=h(e=>({id:e.id,targetId:"",tags:e.tags?.length===0?void 0:e.tags,parent:e.parent}),"parseCherryPicking"),Ve={parse:h(async e=>{const r=await Ee("gitGraph",e);w.debug(r),Ne(r,se)},"parse")},O=10,_=40,L=4,R=2,G=8,j=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),X=12,Z=new Set(["redux-color","redux-dark-color"]),Xe=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),H=h((e,r,t=!1)=>t&&e>0?(e-1)%(r-1)+1:e%r,"calcColorIndex"),C=new Map,E=new Map,F=30,P=new Map,z=[],I=0,y="LR",Qe=h(()=>{C.clear(),E.clear(),P.clear(),I=0,z=[],y="LR"},"clear"),oe=h(e=>{const r=document.createElementNS("http://www.w3.org/2000/svg","text");return(typeof e=="string"?e.split(/\\n|\n|<br\s*\/?>/gi):e).forEach(s=>{const o=document.createElementNS("http://www.w3.org/2000/svg","tspan");o.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),o.setAttribute("dy","1em"),o.setAttribute("x","0"),o.setAttribute("class","row"),o.textContent=s.trim(),r.appendChild(o)}),r},"drawText"),ce=h(e=>{let r,t,s;return y==="BT"?(t=h((o,i)=>o<=i,"comparisonFunc"),s=1/0):(t=h((o,i)=>o>=i,"comparisonFunc"),s=0),e.forEach(o=>{const i=y==="TB"||y=="BT"?E.get(o)?.y:E.get(o)?.x;i!==void 0&&t(i,s)&&(r=o,s=i)}),r},"findClosestParent"),Je=h(e=>{let r="",t=1/0;return e.forEach(s=>{const o=E.get(s).y;o<=t&&(r=s,t=o)}),r||void 0},"findClosestParentBT"),Ze=h((e,r,t)=>{let s=t,o=t;const i=[];e.forEach(n=>{const a=r.get(n);if(!a)throw new Error(`Commit not found for key ${n}`);a.parents.length?(s=rr(a),o=Math.max(s,o)):i.push(a),tr(a,s)}),s=o,i.forEach(n=>{ar(n,s,t)}),e.forEach(n=>{const a=r.get(n);if(a?.parents.length){const l=Je(a.parents);s=E.get(l).y-_,s<=o&&(o=s);const f=C.get(a.branch).pos,g=s-O;E.set(a.id,{x:f,y:g})}})},"setParallelBTPos"),er=h(e=>{const r=ce(e.parents.filter(s=>s!==null));if(!r)throw new Error(`Closest parent not found for commit ${e.id}`);const t=E.get(r)?.y;if(t===void 0)throw new Error(`Closest parent position not found for commit ${e.id}`);return t},"findClosestParentPos"),rr=h(e=>er(e)+_,"calculateCommitPosition"),tr=h((e,r)=>{const t=C.get(e.branch);if(!t)throw new Error(`Branch not found for commit ${e.id}`);const s=t.pos,o=r+O;return E.set(e.id,{x:s,y:o}),{x:s,y:o}},"setCommitPosition"),ar=h((e,r,t)=>{const s=C.get(e.branch);if(!s)throw new Error(`Branch not found for commit ${e.id}`);const o=r+t,i=s.pos;E.set(e.id,{x:i,y:o})},"setRootPosition"),nr=h((e,r,t,s,o,i)=>{const{theme:n}=q(),a=j.has(n??""),l=Z.has(n??""),f=Xe.has(n??"");if(i===m.HIGHLIGHT)e.append("rect").attr("x",t.x-10+(a?3:0)).attr("y",t.y-10+(a?3:0)).attr("width",a?14:20).attr("height",a?14:20).attr("class",`commit ${r.id} commit-highlight${H(o,G,l)} ${s}-outer`),e.append("rect").attr("x",t.x-6+(a?2:0)).attr("y",t.y-6+(a?2:0)).attr("width",a?8:12).attr("height",a?8:12).attr("class",`commit ${r.id} commit${H(o,G,l)} ${s}-inner`);else if(i===m.CHERRY_PICK)e.append("circle").attr("cx",t.x).attr("cy",t.y).attr("r",a?7:10).attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x-3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("circle").attr("cx",t.x+3).attr("cy",t.y+2).attr("r",a?2.5:2.75).attr("fill",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x+3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`),e.append("line").attr("x1",t.x-3).attr("y1",t.y+1).attr("x2",t.x).attr("y2",t.y-5).attr("stroke",f?"#000000":"#fff").attr("class",`commit ${r.id} ${s}`);else{const g=e.append("circle");if(g.attr("cx",t.x),g.attr("cy",t.y),g.attr("r",a?7:10),g.attr("class",`commit ${r.id} commit${H(o,G,l)}`),i===m.MERGE){const $=e.append("circle");$.attr("cx",t.x),$.attr("cy",t.y),$.attr("r",a?5:6),$.attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}if(i===m.REVERSE){const $=e.append("path"),c=a?4:5;$.attr("d",`M ${t.x-c},${t.y-c}L${t.x+c},${t.y+c}M${t.x-c},${t.y+c}L${t.x+c},${t.y-c}`).attr("class",`commit ${s} ${r.id} commit${H(o,G,l)}`)}}},"drawCommitBullet"),sr=h((e,r,t,s,o)=>{if(r.type!==m.CHERRY_PICK&&(r.customId&&r.type===m.MERGE||r.type!==m.MERGE)&&o.showCommitLabel){const i=e.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),a=i.append("text").attr("x",s).attr("y",t.y+25).attr("class","commit-label").text(r.id),l=a.node()?.getBBox();if(l&&(n.attr("x",t.posWithOffset-l.width/2-R).attr("y",t.y+13.5).attr("width",l.width+2*R).attr("height",l.height+2*R),y==="TB"||y==="BT"?(n.attr("x",t.x-(l.width+4*L+5)).attr("y",t.y-12),a.attr("x",t.x-(l.width+4*L)).attr("y",t.y+l.height-12)):a.attr("x",t.posWithOffset-l.width/2),o.rotateCommitLabel))if(y==="TB"||y==="BT")a.attr("transform","rotate(-45, "+t.x+", "+t.y+")"),n.attr("transform","rotate(-45, "+t.x+", "+t.y+")");else{const f=-7.5-(l.width+10)/25*9.5,g=10+l.width/25*8.5;i.attr("transform","translate("+f+", "+g+") rotate(-45, "+s+", "+t.y+")")}}},"drawCommitLabel"),or=h((e,r,t,s)=>{if(r.tags.length>0){let o=0,i=0,n=0;const a=[];for(const l of r.tags.reverse()){const f=e.insert("polygon"),g=e.append("circle"),$=e.append("text").attr("y",t.y-16-o).attr("class","tag-label").text(l),c=$.node()?.getBBox();if(!c)throw new Error("Tag bbox not found");i=Math.max(i,c.width),n=Math.max(n,c.height),$.attr("x",t.posWithOffset-c.width/2),a.push({tag:$,hole:g,rect:f,yOffset:o}),o+=20}for(const{tag:l,hole:f,rect:g,yOffset:$}of a){const c=n/2,x=t.y-19.2-$;if(g.attr("class","tag-label-bkg").attr("points",`
|
|
2
2
|
${s-i/2-L/2},${x+R}
|
|
3
3
|
${s-i/2-L/2},${x-R}
|
|
4
4
|
${t.posWithOffset-i/2-L},${x-c-R}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as a}from"./App-
|
|
1
|
+
import{n as a}from"./App-Cbkqngwr.js";async function f(s,e){const t=await a("/api/teams/import?mode=add",{method:"POST",body:JSON.stringify(s)});for(const o of t.bots)e({type:"botAdded",bot:o});for(const o of t.groups??[])e({type:"groupPatched",group:o});for(const o of t.routines??[])e({type:"routinePatched",routine:o});const r=t.bots.find(o=>!o.hidden);return r&&e({type:"select",id:r.id}),{...t,...r?{first:r}:{}}}function c(s,e,t=100){const r=s.trim().slice(0,t);let o=r;for(let n=2;e.has(o.toLowerCase());n++){const i=` ${n}`;o=`${r.slice(0,t-i.length).trimEnd()}${i}`}return e.add(o.toLowerCase()),o}export{f as a,c as t};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/App-
|
|
2
|
-
import{t as s,ar as St,s as I,as as jt,h as qe,o as be,at as Je,N as Nt,I as Et,r as u,au as Ct,y as ge,av as Ie,w as Te,aw as _e,ax as Pt,ay as It,j as r,S as Ze,X as Tt,a as $,az as _t,aA as At,l as K,L as Ot,a8 as ae,R as se,ae as Ae,p as H,aB as Lt,b as Rt,x as $t,z as Ht,A as Mt,B as Dt,aC as zt,aD as Bt,E as Ft,D as Ut,F as Wt,P as Kt,_ as Qe}from"./styles-
|
|
3
|
-
`;)a+=e[a]==="\\"?2:1;t+=`${o}${" ".repeat(Math.max(0,a-n-1))}${o}`,n=a}else t+=o}return t}function go(e){const t=dn(e);if(/@import/i.test(t))return"@import is not allowed: themes cannot load other stylesheets.";if(t.includes("\\"))return"Backslash escapes are only allowed inside quoted strings.";if(ut.test(t))return"image-set(), image() and src() are not allowed: use url() with a theme file or a data: address.";const n=e.replace(/\/\*[\s\S]*?\*\//g," "),o=ct(n);if(o===null)return'A url() could not be read. Write url("/api/theme-assets/<theme>/<file>").';const a=o.find(i=>!lt(i));return a!==void 0?`url(${a.slice(0,80)}) is not allowed: themes load only their own files (${on}<theme>/<file>), data: addresses or #ids, never the internet.`:null}function de(e=typeof document>"u"?null:document.documentElement){if(!e||typeof window>"u"||typeof window.getComputedStyle!="function")return"dark";try{return window.getComputedStyle(e).getPropertyValue("--code-color-scheme").trim()==="light"?"light":"dark"}catch{return"dark"}}function yo(){const[e,t]=u.useState(()=>de());return u.useEffect(()=>{const n=()=>t(de());if(n(),typeof MutationObserver>"u")return;const o=new MutationObserver(n);return o.observe(document.documentElement,{attributes:!0,attributeFilter:["data-skin"]}),()=>o.disconnect()},[]),e}const N=[255,255,255],P=[0,0,0];function ee(e){const t=e.trim().replace(/^#/,""),n=t.length===3?[...t].map(a=>a+a).join(""):t,o=Number.parseInt(n.slice(0,6),16);return Number.isFinite(o)?[o>>16&255,o>>8&255,o&255]:P}const V=e=>Math.round(Math.min(255,Math.max(0,e))).toString(16).padStart(2,"0"),d=([e,t,n],o)=>`#${V(e)}${V(t)}${V(n)}${o===void 0?"":V(o*255)}`,v=(e,t,n)=>[0,1,2].map(o=>e[o]+(t[o]-e[o])*n);function te([e,t,n]){const o=a=>{const i=a/255;return i<=.03928?i/12.92:((i+.055)/1.055)**2.4};return .2126*o(e)+.7152*o(t)+.0722*o(n)}function me(e,t){const[n,o]=[te(e),te(t)].sort((a,i)=>i-a);return(n+.05)/(o+.05)}const $e=e=>te(ee(e))<.2?"dark":"light";function G(e,t,n){const o=te(t)<.2?N:P;let a=e;for(let i=1;i<=20&&me(a,t)<n;i++)a=v(e,o,i/20);return a}const mt=e=>me(N,e)>=me(P,e)?N:[17,17,17];function mn(e,t){const n=ee(e),o=t==="dark",a=f=>v(n,o?N:P,f),i=o?a(.08):v(n,N,.85),c=a(o?.14:.06),l=G(v(o?N:P,n,o?.04:.1),n,12),x=a(o?.22:.07);return{app:d(n),panel:d(o?v(n,P,.25):v(n,N,.45)),frame:d(o?v(n,P,.25):v(n,N,.45)),raised:d(i),"raised-hover":d(c),card:d(o?a(.07):i),inset:d(o?a(.04):n),control:d(a(o?.12:.07)),composer:d(o?a(.07):i),"composer-ring":d(a(o?.14:.12)),menu:d(i),"menu-hover":d(l,.06),"menu-active":d(l,.09),hairline:d(a(.2)),edge:d(l,.08),scrollbar:d(a(o?.25:.22)),ink:d(l),"ink-secondary":d(G(v(l,n,o?.3:.4),c,4.5)),"ink-tertiary":d(G(v(l,n,o?.42:.5),c,4.5)),"bubble-user":d(x),"bubble-user-ink":d(o?mt(x):l)}}function pn(e,t,n){const o=ee(e),a=G(o,ee(n),4.5);return{accent:d(o),"accent-ink":d(mt(o)),"accent-border":d(t==="dark"?v(o,N,.2):v(o,P,.1)),"accent-text":d(a),focus:d(a)}}class fn extends Error{}function Y(e,t){const n=globalThis[t];return typeof n=="function"&&e instanceof n}function He(e){const t=e.style;return t&&typeof t=="object"&&typeof t.getPropertyValue=="function"?t:null}function Me(e){for(let t=e.length-1;t>=0;t--){const n=e.item(t);dt(e.getPropertyValue(n))&&e.removeProperty(n)}}const hn=e=>"cssRules"in e&&typeof e.deleteRule=="function";function De(e,t,n){try{e.deleteRule(t)}catch{if(!Y(n,"CSSNamespaceRule"))throw new fn}}function pt(e){for(let t=e.cssRules.length-1;t>=0;t--){const n=e.cssRules[t];if(!n)continue;if(Y(n,"CSSKeyframesRule")){for(const a of Array.from(n.cssRules)){const i=He(a);i&&Me(i)}continue}if(Y(n,"CSSPropertyRule")){dt(n.initialValue??"")&&De(e,t,n);continue}const o=He(n);o&&Me(o),hn(n)?pt(n):!o&&!Y(n,"CSSLayerStatementRule")&&De(e,t,n)}}let R=null,ze="";function Be(e){if(!(typeof document>"u"||typeof CSSStyleSheet>"u"||!("adoptedStyleSheets"in document))&&e!==ze){ze=e,R||(R=new CSSStyleSheet,document.adoptedStyleSheets=[...document.adoptedStyleSheets,R]);try{R.replaceSync(e),pt(R)}catch{R.replaceSync("")}}}const pe="omb-theme",Fe="omb-safe-look";let A=null,F=[],ie=!1;const fe=new Set;function U(e){try{return typeof window>"u"?void 0:window[e]}catch{return}}function xn(){try{return typeof location<"u"&&new URLSearchParams(location.search).has(rn)&&U("sessionStorage")?.setItem(Fe,"1"),U("sessionStorage")?.getItem(Fe)==="1"}catch{return!1}}function ko(){return A}function wo(e){return fe.add(e),()=>{fe.delete(e)}}function bn(e){for(const t of F)e.style.removeProperty(t);F=[]}function q(){if(!(typeof document>"u"||ie)){ie=!0;try{const e=document.documentElement;bn(e);const t=xn()?null:A?.theme;if(!t){delete e.dataset.theme,Be(""),Te(_e());return}const n=t.skin??(t.canvas?Pt[$e(t.canvas)]:void 0);Te(n?It(n):_e());const o=de(e),a=t[o],i=a?.canvas??(t.canvas&&$e(t.canvas)===o?t.canvas:void 0),c=a?.accent??t.accent,l={...i?mn(i,o):{},...c?pn(c,o,i??(o==="dark"?"#121212":"#ffffff")):{},...t.colors,...a?.colors};for(const x of st){const f=l[x];f&&(e.style.setProperty(`--color-${x}`,f),F.push(`--color-${x}`))}i&&(e.style.setProperty("--code-color-scheme",o),F.push("--code-color-scheme")),t.font&&(e.style.setProperty("--font-sans",t.font),F.push("--font-sans")),e.dataset.theme=A.id,Be(t.css??"")}finally{ie=!1;for(const e of fe)e()}}}function ke(e){A=e;try{e?U("localStorage")?.setItem(pe,JSON.stringify(e)):U("localStorage")?.removeItem(pe)}catch{}q()}function gn(){try{const e=JSON.parse(U("localStorage")?.getItem(pe)??"null"),t=ye.safeParse(e?.theme);return typeof e?.id=="string"&&t.success?{id:e.id,theme:t.data}:null}catch{return null}}async function we(){try{const e=await fetch("/api/themes/active",{headers:{accept:"application/json"}});if(!e.ok)return;const t=await e.json(),n=t.theme?ye.safeParse(t.theme):null;ke(t.id&&n?.success?{id:t.id,theme:n.data}:null)}catch{}}function vo(e){const t=e.skin;(t==="system"||Je.includes(t))&&ge(t),we()}const ve=(e,t)=>fetch("/api/themes/active",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify({id:e,...t?{skin:t}:{}})}).then(n=>n.ok,()=>!1);function So(){A&&(ke(null),ve(null))}async function jo(e){const t=await ve(e);return t&&await we(),t}function yn(){ge(Ie),ke(null),ve(null,Ie)}const kn=e=>e.code==="KeyR"&&e.altKey&&e.shiftKey&&(e.metaKey||e.ctrlKey);function wn(){if(!(typeof window>"u")){if(window.addEventListener("keydown",e=>{kn(e)&&(e.preventDefault(),e.stopPropagation(),yn())},{capture:!0}),Ct(q),typeof matchMedia=="function")try{matchMedia("(prefers-color-scheme: dark)").addEventListener("change",q)}catch{}A=gn(),A&&q()}}function vn({credential:e,owner:t,team:n}){const[o]=u.useState(()=>Z()),[a,i]=u.useState(!1),[c,l]=u.useState(null);async function x(){i(!0),l(null);const f=await Qt(e,o);if(f.ok){location.replace("/");return}i(!1),l(f.error)}return r.jsx("main",{className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsxs("div",{className:"w-full max-w-[420px]",children:[r.jsx("h1",{className:"text-[20px] font-semibold",children:n?s("pair.browser.teamTitle",{team:n,owner:t}):s("pair.browser.title",{owner:t})}),r.jsx("p",{className:"mt-1.5 text-[14px] text-ink-secondary",children:s("pair.browser.notYou")}),c?r.jsx("p",{role:"alert",className:"mt-3 text-[13px] text-danger",children:c}):null,r.jsx("button",{type:"button",onClick:()=>{x()},disabled:a,className:"mt-5 w-full rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink disabled:opacity-50",children:s(a?"pair.signingIn":"pair.continue")})]})})}const Se="bg-composer ring-1 ring-inset ring-ink/[0.07]",Sn="bg-composer ring-[0.5px] ring-ink/10",No=`${Sn} shadow-(--shadow-float)`,ft="transition-colors duration-[120ms] hover:bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]",jn=`${ft} aria-expanded:bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]`,Eo="bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]",Co="focus-visible:outline-2 focus-visible:-outline-offset-2! focus-visible:outline-focus",ht="flex size-9 shrink-0 items-center justify-center rounded-full text-ink/90",je="focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",Nn=`${ht} ${Se} ${jn} ${je}`,Po=`${ht} ${Se} ${ft} ${je}`,En=`flex size-[26px] shrink-0 items-center justify-center rounded-lg text-ink-secondary transition-colors hover:bg-ink/[0.06] hover:text-ink aria-expanded:bg-ink/[0.06] aria-expanded:text-ink ${je}`,Io="flex size-10 shrink-0 items-center justify-center rounded-full border border-hairline bg-card text-ink hover:bg-raised focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",Cn="flex size-9 shrink-0 items-center justify-center rounded-xl text-ink-secondary hover:bg-raised/60 hover:text-ink focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus";function To({open:e,onToggle:t,corner:n=!1,ref:o}){return r.jsx("button",{ref:o,type:"button","data-sidebar-search-toggle":!0,onClick:t,"aria-label":s("sidebar.searchAria"),"aria-expanded":e,title:s("sidebar.searchAria"),className:n?En:Nn,children:r.jsx(Ze,{size:n?17:18,strokeWidth:1.5,"aria-hidden":"true"})})}function _o({query:e,onQuery:t,onClose:n}){return r.jsx("div",{"data-sidebar-search-pill":!0,className:"px-3 pb-2 pt-0.5",children:r.jsxs("div",{className:$("flex h-[34px] items-center gap-2 rounded-full pl-3 pr-1.5 text-ink-secondary focus-within:ring-focus",Se),children:[r.jsx(Ze,{size:15,"aria-hidden":"true",className:"shrink-0"}),r.jsx("input",{autoFocus:!0,value:e,onChange:o=>t(o.target.value),onKeyDown:o=>{o.key==="Escape"&&(o.preventDefault(),n())},placeholder:s("sidebar.searchAria"),"aria-label":s("sidebar.searchAria"),className:"min-w-0 flex-1 bg-transparent text-[13px] text-ink placeholder:text-ink-tertiary focus:outline-none"}),r.jsx("button",{type:"button",onClick:n,"aria-label":s("sidebar.searchClose"),title:s("sidebar.searchClose"),className:"flex size-6 shrink-0 items-center justify-center rounded-full text-ink-tertiary hover:bg-raised hover:text-ink focus-visible:outline focus-visible:outline-2 focus-visible:outline-focus",children:r.jsx(Tt,{size:14,"aria-hidden":"true"})})]})})}function Pn(e,{howTo:t=!1,onClosed:n}={}){return e.menu(t?{from:"howto"}:void 0).finally(()=>{t&&n?.()})}function Ao(e){e({type:"cloudHowTo",open:!1})}function Ue({text:e}){return r.jsxs("span",{className:"font-normal text-ink-secondary",children:[" · ",e]})}function In(e){return e?.sleeps===!0?!0:e?.status==="paid"?!1:null}function Tn(e){const t=e&&!window.ogb?.remoteClient?.active?window.ogb?.cloudPlan:void 0,n=e||window.ogb?.remoteClient?.active?void 0:window.ogb?.cloudAccount,[o,a]=u.useState(null),[i,c]=u.useState(!1);return u.useEffect(()=>{if(!t)return;let l=!0;return t.state().then(x=>{l&&a(In(x))}).catch(()=>{}),()=>{l=!1}},[t]),u.useEffect(()=>n?.onState(l=>c(l.waking===!0)),[n]),{sleeps:t?o:null,waking:i}}function _n({cloudHome:e=!1,howTo:t=!1,onMenuClosed:n}){const o=window.ogb?.workspaces,[a,i]=u.useState(null),[c,l]=u.useState(!1),[x,f]=u.useState("");u.useEffect(()=>{let p=!0;const k=()=>{o?.state().then(E=>{p&&i(E)}).catch(()=>{})};k();const T=o?.onChanged?.(k);return()=>{p=!1,T?.()}},[o]);const w=Tn(e||a?.home===!0),m=w.sleeps===null?"":s(w.sleeps?"cloudSetup.sleepsWhenIdle":"cloudSetup.alwaysOn"),g=w.waking?s("cloudHome.waking"):"";return{bridge:o,current:a,cloudHome:e,open:c,error:x,onLine:m,waking:g,openMenu:()=>{!o||c||(f(""),l(!0),Pn(o,{howTo:t,onClosed:n}).catch(()=>f(s("sidebar.switchServerError"))).finally(()=>l(!1)))},switchable:!!o&&a?.home!==!0}}function An(e){const t=_t(),n=r.jsx(On,{...e});return At(t)?r.jsx("div",{"data-switcher-beside-rail":!0,className:t.beside?"hidden":"contents md:hidden",children:n}):n}function On({compact:e=!1,inline:t=!1,pill:n=!1,rail:o=!1,cloudHome:a=!1,owner:i=null,howTo:c=!1,place:l,onMenuClosed:x}){const f=l||s("cloudSetup.myCloud"),{bridge:w,current:m,open:g,error:y,onLine:p,waking:k,openMenu:T}=_n({cloudHome:a,howTo:c,onMenuClosed:x}),E=b=>p?`${b} · ${p}`:b;if(!w||m?.home===!0){if(!a&&!m?.home)return null;const b=i?s("sidebar.cloudOwner",{email:i}):"",j=`${E(f)}${b?` · ${b}`:""}`;return o?r.jsx("div",{"data-cloud-home-indicator":!0,"data-workspace-switcher":"rail",role:"img","aria-label":j,title:j,className:"flex size-9 items-center justify-center text-ink-secondary",children:r.jsx(K,{size:18,"aria-hidden":"true"})}):t?r.jsxs("div",{"data-cloud-home-indicator":!0,"data-workspace-switcher":"inline",title:j,className:n?"flex h-8 min-w-0 items-center gap-1 rounded-full bg-raised/50 px-3 text-[13px] font-medium text-ink":"flex min-w-0 items-center gap-1.5 px-1.5 text-[13px] font-medium text-ink",children:[r.jsx(K,{size:n?15:14,"aria-hidden":"true",className:n?"hidden shrink-0 text-ink-secondary @max-[124px]/sidebar-top:block":"shrink-0 text-ink-secondary"}),r.jsx("span",{className:n?"min-w-0 truncate @max-[124px]/sidebar-top:hidden":"min-w-0 truncate",children:f}),(p||b)&&r.jsxs("span",{className:"sr-only",children:[p?` · ${p}`:"",b?` · ${b}`:""]})]}):r.jsx("div",{"data-cloud-home-indicator":!0,className:$("py-1.5",e?"px-2":"px-3"),children:r.jsxs("div",{title:j,className:$("flex items-center gap-2 py-2 text-[13px] font-medium text-ink",e?"justify-center px-1":"px-2"),children:[r.jsx(K,{size:16,"aria-hidden":"true",className:"shrink-0 text-ink-secondary"}),e?r.jsx("span",{className:"sr-only",children:j}):r.jsxs("span",{className:"min-w-0 flex-1 truncate",children:[f,p&&r.jsx(Ue,{text:p}),b&&r.jsx("span",{className:"block truncate text-[12px] font-normal text-ink-secondary",children:b})]})]})})}const O=m?.profileName??(m?.local&&!m.localPath?s("place.local"):m?.name)??(a?f:s("sidebar.servers")),S=m?.local===!1||a&&!m?K:Ot,M=a?E(O):O,_=m?.origin?`${M} · ${m.origin}`:M,L=s("sidebar.switchServer",{name:M});return o?r.jsxs("div",{"data-workspace-switcher":"rail",className:"relative",children:[r.jsx("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:$(Cn,"aria-expanded:bg-raised"),style:{WebkitAppRegion:"no-drag"},children:ae(m?.color)?r.jsx(se,{color:m?.color,size:18}):r.jsx(S,{size:18,"aria-hidden":"true"})}),y&&r.jsx("p",{role:"alert",className:"absolute bottom-0 left-full z-40 ml-2 w-56 rounded-md bg-menu px-2 py-1 text-[11px] text-danger shadow-lg",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"absolute bottom-0 left-full z-40 ml-2 w-56 rounded-md bg-menu px-2 py-1 text-[11px] text-ink-secondary shadow-lg",children:k})]}):t?r.jsxs("div",{"data-workspace-switcher":"inline",className:"flex min-w-0",children:[r.jsxs("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:n?"flex h-8 min-w-0 max-w-full items-center gap-1 overflow-hidden rounded-full bg-raised/50 pl-2.5 pr-1.5 text-left text-[13px] font-medium text-ink hover:bg-raised aria-expanded:bg-raised focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus":"flex h-7 min-w-0 max-w-full items-center gap-1.5 overflow-hidden rounded-md px-1.5 text-left text-[13px] font-medium text-ink hover:bg-control focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",style:{WebkitAppRegion:"no-drag"},children:[ae(m?.color)?r.jsx(se,{color:m?.color,size:16}):r.jsx(S,{size:n?15:14,"aria-hidden":"true","data-switcher-icon":!0,className:n?"hidden shrink-0 text-ink-secondary @max-[124px]/sidebar-top:block":"shrink-0 text-ink-secondary"}),r.jsx("span",{className:n?"min-w-0 truncate @max-[124px]/sidebar-top:hidden":"min-w-0 truncate @max-[96px]/sidebar-top:hidden",children:O}),r.jsx(Ae,{size:n?12:11,"aria-hidden":"true",className:n?"shrink-0 text-ink-tertiary":"shrink-0 text-ink-secondary"})]}),y&&r.jsx("p",{role:"alert",className:"absolute right-2 top-full z-40 mt-1 w-56 max-w-[calc(100%-1rem)] rounded-md bg-menu px-2 py-1 text-[11px] text-danger shadow-lg",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"absolute right-2 top-full z-40 mt-1 w-56 max-w-[calc(100%-1rem)] rounded-md bg-menu px-2 py-1 text-[11px] text-ink-secondary shadow-lg",children:k})]}):r.jsxs("div",{className:$("py-1.5",e?"px-2":"px-3"),children:[r.jsxs("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:$("flex w-full items-center gap-2 rounded-lg py-2 text-left text-[13px] font-medium text-ink hover:bg-control focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",e?"justify-center px-1":"px-2"),style:{WebkitAppRegion:"no-drag"},children:[ae(m?.color)?r.jsx(se,{color:m?.color,size:20}):r.jsx(S,{size:16,className:"shrink-0 text-ink-secondary"}),!e&&r.jsxs(r.Fragment,{children:[r.jsxs("span",{className:"min-w-0 flex-1 truncate",children:[O,a&&p&&r.jsx(Ue,{text:p})]}),r.jsx(Ae,{size:13,className:"shrink-0 text-ink-secondary"})]})]}),y&&r.jsx("p",{role:"alert",className:"mt-1 text-[11px] text-danger",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"mt-1 text-[11px] text-ink-secondary",children:k})]})}function Ln(e){const t=e&&typeof e=="object"?e.membership:void 0,n=t&&typeof t=="object"?t:{};let o=null;if(typeof n.peopleUrl=="string")try{new URL(n.peopleUrl).protocol==="https:"&&(o=n.peopleUrl)}catch{o=null}return{authority:n.authority==="portal"?"portal":"local",pairingCodes:n.pairingCodes!==!1,peopleUrl:o}}const Oo=()=>({type:"toggleAppSettings",open:!0,section:"companion",phonePairing:!0});function Lo(e){const t=typeof window>"u"?void 0:window.ogb;return Rn({companion:!!t?.companion,remoteClient:t?.remoteClient?.active===!0,cloudHome:e})}function Rn(e){return e.cloudHome?"cloud":e.companion&&!e.remoteClient?"computer":"server"}const $n={computer:"sidebar.menu.connectPhone.computer",cloud:"sidebar.menu.connectPhone.cloud",server:"sidebar.menu.connectPhone.server"};function Ro(e,t){const n=t?.session?.kind==="session"?t.session.team?.name:void 0;return n?{target:e,subtitleKey:"sidebar.menu.connectPhone.team",team:n}:e!=="computer"&&!(t&&t.pairingCodes&&tt(t.session))?null:{target:e,subtitleKey:$n[e]}}function $o(e,t){if(!e)return[];const n={...e,id:"here"};return e.target,[n]}let We=null;function Ho(e=fetch){return We??=ne(e).then(async t=>{if(!tt(t))return{session:t,pairingCodes:!1};const n=await e("/api/config",{credentials:"same-origin"}).then(o=>o.ok?o.json():null).catch(()=>null);return{session:t,pairingCodes:Ln(n).pairingCodes}}),We}const Hn="data-phone-pairing-action";function Mo(e,t=n=>window.requestAnimationFrame(n)){return e?(t(()=>{e.scrollIntoView?.({block:"start"}),(e.querySelector(`[${Hn}]:not([disabled])`)??e).focus({preventScroll:!0})}),!0):!1}function Do(e){const t=new URL(e);return t.searchParams.get("desktop-settings")!=="phone"?null:(t.searchParams.delete("desktop-settings"),`${t.pathname}${t.search}${t.hash}`)}function le(e){const t=new URLSearchParams(e);if(t.get("desktop-settings")==="phone")return"/?desktop-settings=phone";const n=t.get("next");return n&&/^\/(?!\/)/.test(n)&&!n.startsWith("/pair")&&!/[\\\s]/.test(n)?n:"/"}const Mn="23456789ABCDEFGHJKLMNPQRSTUVWXYZ",Dn=12,zn="omb_pair_",Bn=/^omb_pair_[A-Za-z0-9_-]{43}$/;function xt(e){return e.toUpperCase().replace(/[^A-Z0-9]/g,"").replace(/0/g,"O").replace(/1/g,"I")}function Fn(e){return xt(e).match(/.{1,4}/g)?.join("-")??e}const Un={emailCode:"serverError.pair.emailCode",oldCode:"serverError.pair.oldCode",scriptKey:"serverError.pair.scriptKey",notACode:"serverError.pair.notACode"};function Wn(e){let t;try{t=new URL(e)}catch{return null}const n=new URLSearchParams(t.hash.replace(/^#/,""));return t.searchParams.get("token")??t.searchParams.get("code")??n.get("code")}function Ne(e){let t=e.trim();if(!t)return{kind:"empty"};if(/^[a-z][a-z0-9+.-]*:\/\//i.test(t)){const a=Wn(t);if(!a)return{kind:"wrong",problem:"notACode"};t=a.trim()}if(t.startsWith("omb_sess_"))return{kind:"wrong",problem:"scriptKey"};if(t.startsWith(zn))return Bn.test(t)?{kind:"credential",credential:t}:{kind:"wrong",problem:"notACode"};const n=t.replace(/[\s-]/g,"");if(/^\d{8}$/.test(n))return{kind:"wrong",problem:"emailCode"};if(/^\d{6}$/.test(n))return{kind:"wrong",problem:"oldCode"};const o=xt(t);return o.length!==Dn||[...o].some(a=>!Mn.includes(a))?{kind:"wrong",problem:"notACode"}:{kind:"code",code:o}}const z="mt-1 w-full rounded-md border border-hairline/40 bg-inset px-3 py-2 text-[14px] text-ink outline-none focus:border-accent-border",Ke="mt-5 w-full rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink disabled:opacity-50",B="mt-4 block text-[12px] font-medium text-ink-secondary";function Kn(e,t=typeof window<"u"&&!!window.ogb?.workspaces){return!!e&&t}function Vn({mode:e,sent:t,email:n,cloudHome:o}){return e==="email"?t?s("pair.intro.emailSent",{email:n}):s("pair.intro.email"):o?s("pair.intro.cloud",{app:H(),open:s("cloudHome.connect"),section:s("settings.section.cloudAccount")}):s("pair.intro.code")}function Xn(e){const t=Ne(e);return t.kind==="wrong"&&t.problem!=="notACode"?s(Un[t.problem]):null}function Gn(e){const t=Ne(e).kind;return t==="code"||t==="credential"}function Yn(e,t){const n=Ne(t),o=n.kind==="code"?`&code=${encodeURIComponent(Fn(n.code))}`:"";return`openmausbot://pair?address=${encodeURIComponent(e)}${o}`}function qn(e){return e.protocol==="http:"&&!Lt(e.hostname)}function Ve(e,t=Xt()){if(!e?.capabilities.cloudTeam||typeof t!="string")return null;try{const n=new URL(t),o=n.protocol==="http:"&&["127.0.0.1","localhost","[::1]"].includes(n.hostname);return(n.protocol==="https:"||o)&&!n.username&&!n.password&&!n.hash?n.href:null}catch{return null}}function Jn(e,t){return e?.capabilities.cloudTeam?e.label:e?.capabilities.cloudHome?s("pair.myCloud"):s(t==="email"?"pair.signInTo":"pair.connectTo",{name:e?.label??s("pair.thisOpenMausBot",{app:H()})})}function Zn({team:e}){return r.jsx("main",{"data-team-left":!0,className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsx("p",{role:"status",className:"max-w-[420px] text-[16px]",children:s("homeLine.left",{name:e??s("pair.thisOpenMausBot",{app:H()})})})})}function X({initialCode:e,initialEmail:t=null,reason:n}){const[o,a]=u.useState(e??""),[i,c]=u.useState(nt()),[l,x]=u.useState(null),[f,w]=u.useState(null),[m,g]=u.useState(!1),[y,p]=u.useState(null),[k,T]=u.useState(()=>Z()),[E,O]=u.useState(t&&!e?"email":"code"),[S,M]=u.useState(t??""),[_,L]=u.useState(""),[b,j]=u.useState(!1),[oe,gt]=u.useState(()=>Kn(e));u.useEffect(()=>{if(!oe||!e)return;let h=!0;return ue({code:e,label:i,attemptId:k}).then(C=>{if(h){if(C.ok){location.replace(le(location.search));return}gt(!1),p(C.error)}}),()=>{h=!1}},[]),u.useEffect(()=>{fetch("/.well-known/openmausbot/environment").then(h=>h.ok?h.json():null).then(h=>{x(h)}).catch(()=>{x(null)}),ne().then(w)},[]);const re=Gt(f),yt=l?.capabilities.emailSignIn===!0,D=l?.capabilities.cloudHome===!0,kt=!D&&l?.capabilities.cloudTeam!==!0,Ce=Xn(o),W=typeof location<"u"&&typeof location.protocol=="string"?location:null;async function wt(h){h.preventDefault(),g(!0),p(null);const C=await ue({code:o,label:i,attemptId:k});if(g(!1),C.ok){location.replace(le(location.search));return}p(C.error)}async function vt(h){h.preventDefault(),g(!0),p(null);const C=b?await tn({email:S,code:_,label:i}):await en(S);if(g(!1),!C.ok){p(C.error);return}if(b){location.replace(le(location.search));return}j(!0)}function Pe(h){O(h),p(null)}return r.jsxs("main",{className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:[r.jsx("div",{className:"absolute left-3 top-12 max-w-[280px]",children:r.jsx(An,{})}),r.jsxs("div",{className:"w-full max-w-[420px]",children:[W&&qn(W)?r.jsx("p",{role:"alert",className:"mb-4 rounded-md border border-warning/30 bg-warning/10 px-3 py-2 text-[13px] text-warning",children:s("pair.notEncrypted")}):null,oe?r.jsx("p",{role:"status",className:"text-[20px] font-semibold",children:D?s("pair.openingCloud"):s("pair.connectingTo",{name:l?.label??s("pair.thisOpenMausBot")})}):r.jsxs(r.Fragment,{children:[r.jsx("h1",{className:"text-[20px] font-semibold",children:Jn(l,E)}),r.jsxs("p",{className:"mt-1.5 text-[14px] leading-relaxed text-ink-secondary",children:[l&&!D?`${s("pair.version",{version:l.version,platform:l.platform})} `:"",Vn({mode:E,sent:b,email:S,cloudHome:D})]}),Le(n)&&!re?r.jsx("p",{className:"mt-3 text-[13px] text-ink-secondary",children:Le(n)}):null,y&&D&&e?r.jsx("p",{className:"mt-3 text-[13px] text-ink-secondary",children:s("pair.expired",{app:H(),open:s("cloudHome.connect"),section:s("settings.section.cloudAccount")})}):null,!re&&Ve(l)?r.jsxs("div",{"data-team-sign-in":!0,className:"mt-4 flex flex-col items-start gap-1.5",children:[r.jsx("a",{href:Ve(l),className:"rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink",children:s("pair.team.open",{team:l.label})}),r.jsx("p",{className:"text-[13px] text-ink-secondary",children:s("pair.team.openHint")})]}):null]}),oe?null:re?r.jsxs("p",{className:"mt-4 text-[14px]",children:[s("pair.alreadyConnected")," ",r.jsx("a",{href:"/",className:"text-accent underline",children:s("pair.openApp")})]}):E==="email"?r.jsxs("form",{onSubmit:vt,children:[r.jsx("label",{className:B,htmlFor:"signin-email",children:s("cloudBuy.signIn.email")}),r.jsx("input",{id:"signin-email",type:"email",value:S,onChange:h=>{M(h.target.value),j(!1),L("")},autoComplete:"email",inputMode:"email",spellCheck:!1,className:z}),b?r.jsxs(r.Fragment,{children:[r.jsx("label",{className:B,htmlFor:"signin-code",children:s("pair.emailCode")}),r.jsx("input",{id:"signin-code",value:_,onChange:h=>L(h.target.value),placeholder:"12345678",autoComplete:"one-time-code",inputMode:"numeric",spellCheck:!1,className:`${z} font-mono text-[15px] tracking-[0.12em]`}),r.jsx("label",{className:B,htmlFor:"signin-label",children:s("pair.deviceLabel")}),r.jsx("input",{id:"signin-label",value:i,onChange:h=>c(h.target.value),maxLength:80,className:z})]}):null,y?r.jsx("p",{className:"mt-3 text-[13px] text-danger",children:y}):null,r.jsx("button",{type:"submit",disabled:m||!S.includes("@")||b&&_.replace(/\D/g,"").length<8,className:Ke,children:s(m?b?"pair.signingIn":"pair.sending":b?"pair.signIn":"cloudBuy.signIn.send")}),b?r.jsx("button",{type:"button",onClick:()=>j(!1),className:"mt-3 w-full text-[13px] text-ink-secondary underline",children:s("pair.resend")}):null,r.jsx("button",{type:"button",onClick:()=>Pe("code"),className:"mt-3 w-full text-[13px] text-ink-secondary underline",children:s("pair.useCode")})]}):r.jsxs("form",{onSubmit:wt,children:[r.jsx("label",{className:B,htmlFor:"pair-code",children:s("pair.code")}),r.jsx("input",{id:"pair-code",value:o,onChange:h=>{a(h.target.value),T(Z())},placeholder:"XXXX-XXXX-XXXX","aria-describedby":e&&o===e?"pair-code-from-link":void 0,autoComplete:"one-time-code",autoCapitalize:"characters",spellCheck:!1,className:`${z} font-mono text-[15px] tracking-[0.12em]`}),e&&o===e?r.jsx("p",{id:"pair-code-from-link",className:"mt-1 text-[12px] text-ink-secondary",children:s("pair.fromLink")}):null,r.jsx("label",{className:B,htmlFor:"pair-label",children:s("pair.deviceLabel")}),r.jsx("input",{id:"pair-label",value:i,onChange:h=>c(h.target.value),maxLength:80,className:z}),Ce?r.jsx("p",{role:"alert",className:"mt-3 text-[13px] text-danger",children:Ce}):y?r.jsx("p",{className:"mt-3 text-[13px] text-danger",children:y}):null,r.jsx("button",{type:"submit",disabled:m||!Gn(o),className:Ke,children:s(m?"pair.connecting":"pair.connect")}),W?.origin?r.jsxs("p",{className:"mt-3 text-[13px] text-ink-secondary",children:[s("pair.onPhone")," ",r.jsx("a",{href:Yn(W.origin,o),className:"text-accent underline",children:s("pair.openInApp",{app:H()})})]}):null,kt?r.jsxs("p",{className:"mt-3 text-[13px] text-ink-secondary",children:[s("pair.noCode")," ",r.jsx("code",{className:"select-all rounded bg-inset px-1.5 py-0.5 text-[12px] text-ink",children:"npx limixbot pair"})]}):null,yt?r.jsxs("p",{className:"mt-5 border-t border-hairline/40 pt-4 text-[13px] text-ink-secondary",children:[s("pair.invitedByEmail")," ",r.jsx("button",{type:"button",onClick:()=>Pe("email"),className:"text-accent underline",children:s("pair.useEmail")})]}):null]})]})]})}const zo="cloud-welcome-done",Qn="unauthorized: you are no longer in this team",Xe=[["reserving","cloudHome.step.reserving"],["storage","cloudHome.step.storage"],["starting","cloudHome.step.starting"],["checking","cloudHome.step.checking"]];function eo({step:e}){const t=Xe.findIndex(([n])=>n===e);return r.jsx("ol",{"data-cloud-setup":e,className:"flex flex-col gap-1 text-[13px]",children:Xe.map(([n,o],a)=>r.jsx("li",{"aria-current":a===t?"step":void 0,className:a===t?"font-medium text-ink":a<t?"text-ink-secondary line-through decoration-ink-secondary/40":"text-ink-secondary",children:s(o)},n))})}const to={stopped:"cloudHome.stopped","payment-problem":"cloudHome.paymentProblem",failed:"cloudHome.failed"},Ge={host:"cloudHome.unreachableHost",no_answer:"cloudHome.unreachable"};function no(e,t=Date.now()){const n=new Date(e).getFullYear()!==new Date(t).getFullYear();return new Intl.DateTimeFormat(Rt(),{day:"numeric",month:"long",...n?{year:"numeric"}:{}}).format(new Date(e))}function oo(e,t=Date.now()){const n=e?.name??null,o=(a,i)=>n?s(i,{name:n}):s(a);return e?.screen==="setup"?{title:o("homeScreen.setup","homeScreen.setupNamed"),body:s(e.slow?"cloudHome.slow":"homeScreen.setupBody"),reason:null,action:null,busy:!0}:e?.screen==="offline"?{title:o("homeScreen.offline","homeScreen.offlineNamed"),body:s("homeScreen.offlineBack"),reason:e.cause&&Object.hasOwn(Ge,e.cause)?s(Ge[e.cause]):e.reason??null,action:"retry",busy:!1}:e?.screen==="signin"?{title:o("homeScreen.signIn","homeScreen.signInNamed"),body:s(e.other?"homeScreen.signInOther":"homeScreen.signInEnded"),reason:null,action:"sign-in",busy:!1}:e?.screen==="plan"&&e.member&&e.machine!=="failed"?{title:o("homeScreen.plan","homeScreen.planNamed"),body:s("cloudHome.stoppedMember"),reason:null,action:null,busy:!1}:e?.screen==="plan"?{title:o("homeScreen.plan","homeScreen.planNamed"),body:s(to[e.machine]??"cloudHome.failed"),reason:null,action:e.machine==="failed"?null:"manage",busy:!1}:e?.screen==="ended"?{title:o("cloudHome.ended","cloudHome.endedNamed"),body:e.deleteAt?s("cloudHome.endedFiles",{date:no(e.deleteAt,t)}):null,reason:null,action:"buy",busy:!1}:e?.screen==="checkout"?{title:o("cloudHome.checkout","cloudHome.checkoutNamed"),body:null,reason:null,action:"continue",busy:!1}:e?.screen==="payment"?{title:o("cloudHome.payment","cloudHome.paymentNamed"),body:s("cloudHome.paymentBody"),reason:null,action:"card",busy:!1}:e?.screen==="waking"?{title:s("homeScreen.waking"),body:null,reason:null,action:null,busy:!0}:e?.screen==="moving"?{title:o("homeScreen.moving","homeScreen.movingNamed"),body:null,reason:null,action:null,busy:!0}:{title:o("homeScreen.opening","homeScreen.openingNamed"),body:null,reason:null,action:null,busy:!0}}const ro={retry:"cloudHome.tryAgain",buy:"cloudHome.buyAgain",continue:"cloudHome.continue",card:"cloudHome.updateCard"};function ao({name:e,remove:t}){const[n,o]=u.useState(!1),[a,i]=u.useState(!1),[c,l]=u.useState(null),x=()=>{i(!0),l(null),t().then(f=>{i(!1),f!=="removed"&&f!=="gone"&&(o(!1),l(f==="refused"?"refused":"failed"))},()=>{i(!1),o(!1),l("failed")})};return r.jsxs("div",{"data-home-remove":!0,className:"flex flex-col items-start gap-2",children:[n?r.jsxs("div",{role:"alertdialog","aria-label":s("rail.remove"),className:"flex flex-col gap-2 rounded-xl border border-hairline/70 bg-card/70 px-4 py-3",children:[r.jsx("p",{className:"text-[13px] leading-relaxed text-ink",children:s("rail.removeAsk",{name:e})}),r.jsxs("div",{className:"flex gap-2",children:[r.jsx("button",{type:"button","data-home-remove-confirm":!0,className:"ui-button ui-button-primary",disabled:a,onClick:x,children:s("rail.removeYes")}),r.jsx("button",{type:"button",className:"ui-button",disabled:a,onClick:()=>o(!1),children:s("rail.removeNo")})]})]}):r.jsx("button",{type:"button","data-home-remove-ask":!0,className:"text-[13px] text-ink-secondary underline-offset-2 hover:text-ink hover:underline",onClick:()=>{l(null),o(!0)},children:s("rail.remove")}),c&&r.jsx("p",{role:"alert",className:"text-[13px] text-danger",children:s(c==="refused"?"rail.removeRefused":"rail.removeFailed")})]})}function so({bridge:e,manage:t}){const[n,o]=u.useState(null),[a,i]=u.useState(!1);u.useEffect(()=>{let g=!0;const y=e.onState(k=>o(k)),p=()=>{e.retry().then(k=>{g&&o(k)}).catch(()=>{})};return e.state().then(k=>{g&&o(k)}).catch(()=>{}).then(p),window.addEventListener("online",p),window.addEventListener("focus",p),()=>{g=!1,y(),window.removeEventListener("online",p),window.removeEventListener("focus",p)}},[e]);const c=oo(n),l=g=>{i(!1),g().catch(()=>i(!0))},x=window.ogb?.cloudAdd?.reopen,f={retry:()=>e.retry().then(g=>o(g)),...t?{manage:t,buy:t,card:t,continue:async()=>{x&&await x().catch(()=>!1)||await t()}}:{}},w=c.action&&c.action!=="sign-in"&&c.action!=="manage"?c.action:null,m=(n?.screen==="ended"||n?.screen==="payment")&&n.removable===!0&&typeof e.remove=="function";return r.jsx("main",{"data-home-screen":n?.screen??"opening",className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",style:{WebkitAppRegion:"drag"},children:r.jsxs("div",{className:"flex w-full max-w-[420px] flex-col items-start gap-3",style:{WebkitAppRegion:"no-drag"},children:[r.jsxs("p",{role:"status",className:"flex items-center gap-2 text-[20px] font-semibold",children:[c.busy&&r.jsx("span",{"aria-hidden":"true",className:"size-3.5 shrink-0 animate-spin rounded-full border-2 border-hairline border-t-accent"}),c.title]}),c.body&&r.jsx("p",{className:"text-[14px] leading-relaxed text-ink-secondary",children:c.body}),n?.screen==="setup"&&r.jsx(eo,{step:n.step??"reserving"}),c.reason&&r.jsx("p",{"data-home-reason":!0,className:"text-[13px] leading-relaxed text-ink-secondary",children:c.reason}),c.action==="sign-in"&&r.jsx("button",{type:"button",className:"ui-button ui-button-primary mt-2",onClick:()=>l(()=>e.signIn()),children:s("homeScreen.signInButton")}),c.action==="manage"&&t&&r.jsx("button",{type:"button",className:"ui-button mt-2",onClick:()=>l(t),children:s("cloudAccount.manageInBrowser")}),w&&f[w]&&r.jsx("button",{type:"button","data-home-action":w,className:w==="retry"?"ui-button mt-2":"ui-button ui-button-primary mt-2",onClick:()=>l(f[w]),children:s(ro[w])}),m&&r.jsx(ao,{name:n.name??s("cloudSetup.myCloud"),remove:()=>e.remove()}),a&&r.jsx("p",{role:"alert",className:"text-[13px] text-danger",children:s("cloudAccount.actionFailed")})]})})}function io({bridge:e,fallback:t}){const[n,o]=u.useState(!1);return u.useEffect(()=>{e.repair().catch(()=>o(!0))},[e]),n?r.jsx(r.Fragment,{children:t}):r.jsx("main",{"data-home-screen":"opening",className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsx("p",{role:"status",className:"w-full max-w-[420px] text-[20px] font-semibold",children:s("homeScreen.opening")})})}const Ee="omb.session-ended";let he=!1,ce=null;const xe=new Set;function Bo(){he||ce||(ce=ne().then(e=>{if(e.kind==="unauthenticated"){he=!0;try{sessionStorage.setItem(Ee,"1")}catch{}for(const t of xe)t()}}).finally(()=>{ce=null}))}function Ye(){return he}function Fo(){return u.useSyncExternalStore(e=>(xe.add(e),()=>xe.delete(e)),Ye,Ye)}function lo(){try{return sessionStorage.getItem(Ee)==="1"}catch{return!1}}function co(){try{sessionStorage.removeItem(Ee)}catch{}}$t();ge(Ht());Mt(Dt());nn();zt(Bt());wn();const J=Ft(),uo=new Set(["/home","/pair","/desktop-viewer"]),bt=()=>Qe(()=>import("./App-CTks_6Oy.js").then(e=>e.jV),__vite__mapDeps([0,1,2,3,4,5])).catch(e=>({default:()=>{throw e}})),mo=uo.has(location.pathname)?null:bt(),po=()=>fetch("/.well-known/openmausbot/environment").then(e=>e.json()).then(e=>e.capabilities?.cloudTeam===!0&&typeof e.label=="string"?e.label:null,()=>null);async function fo(){const e=window.ogb?.home;if(location.pathname==="/home"&&e)return r.jsx(so,{bridge:e,manage:window.ogb?.cloudPlan?.manage});if(location.pathname==="/pair"){const o=qt();if(o){const a=await Zt(o);return await J,a?r.jsx(vn,{credential:o,owner:a.owner,team:a.team}):r.jsx(X,{initialCode:null,reason:s("pair.browser.signInFailed")})}return r.jsx(X,{initialCode:Yt(),initialEmail:Jt()})}const t=await ne();if(t.kind==="unauthenticated"){if(await J,t.error===Qn)return r.jsx(Zn,{team:await po()});const o=r.jsx(X,{initialCode:null,reason:lo()?s("pair.sessionEnded"):t.error});return e?r.jsx(io,{bridge:e,fallback:o}):o}if(co(),t.kind==="session"&&Vt(t.teamSignIn),t.kind==="loopback"&&t.trust==="service")return await J,r.jsx(X,{initialCode:null,reason:s("pair.serviceTrust")});if(location.pathname==="/desktop-viewer"){const{DesktopViewer:o}=await Qe(async()=>{const{DesktopViewer:a}=await import("./DesktopViewer-ibFgMuIw.js");return{DesktopViewer:a}},__vite__mapDeps([6,1,2,7,8,5,4,9]));return r.jsx(o,{})}const{default:n}=await(mo??bt());return we(),r.jsx(n,{})}document.title=H();Promise.all([Ut(),fo(),J]).then(([,e])=>{Wt.createRoot(document.getElementById("root")).render(r.jsx(u.StrictMode,{children:r.jsx(Kt,{children:e})}))});export{Po as A,bo as B,eo as C,Co as D,No as E,En as F,An as G,To as H,_o as I,Sn as J,de as K,Eo as L,zo as M,Fo as N,X as O,Io as P,Do as Q,Nn as S,at as T,Ln as a,Mo as b,xn as c,yn as d,jo as e,So as f,Lo as g,vo as h,tt as i,jn as j,Se as k,we as l,$o as m,Bo as n,Pn as o,Oo as p,xo as q,ne as r,wo as s,go as t,yo as u,Ho as v,ko as w,Ro as x,_n as y,Ao as z};
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/App-Cbkqngwr.js","assets/styles-B6mWzGeo.js","assets/styles-CDO5XxMJ.css","assets/PlacesRail-BY539HeM.js","assets/monitor-BcLBFpcy.js","assets/MenuMotion-DGWguBBq.js","assets/DesktopViewer-B0jszxk4.js","assets/desktop-connection-Dfaq6k5a.js","assets/desktop-viewer-CF-OpSo0.js","assets/minimize-bWLTQ4JN.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{t as s,ar as St,s as I,as as jt,h as qe,o as be,at as Je,N as Nt,I as Et,r as u,au as Ct,y as ge,av as Ie,w as Te,aw as _e,ax as Pt,ay as It,j as r,S as Ze,X as Tt,a as $,az as _t,aA as At,l as K,L as Ot,a8 as ae,R as se,ae as Ae,p as H,aB as Lt,b as Rt,x as $t,z as Ht,A as Mt,B as Dt,aC as zt,aD as Bt,E as Ft,D as Ut,F as Wt,P as Kt,_ as Qe}from"./styles-B6mWzGeo.js";function xo(e,t){if(!t)return;if(t.kind!=="session")return t.kind==="loopback"?e:void 0;if(t.team||t.scopes.includes("admin"))return e;const n=t.email;if(n?.trim())return e?.email?.trim().toLowerCase()===n.trim().toLowerCase()?e:{email:n}}const et="omb.team-sign-in";function Vt(e){try{e&&globalThis.localStorage?.setItem(et,e)}catch{}}function Xt(){try{return globalThis.localStorage?.getItem(et)??null}catch{return null}}async function ne(e=fetch){let t;try{t=await e("/api/auth/session",{credentials:"same-origin"})}catch(a){return{kind:"unreachable",error:a instanceof Error?a.message:String(a)}}const n=await t.json().catch(()=>({})),o=Object(n);return t.status===401||t.status===403?{kind:"unauthenticated",error:typeof o.error=="string"?o.error:`${t.status}`}:t.ok?o.kind==="session"&&typeof o.id=="string"?{kind:"session",id:o.id,label:typeof o.label=="string"?o.label:"",...typeof o.email=="string"?{email:o.email}:{},scopes:Array.isArray(o.scopes)?o.scopes.filter(a=>typeof a=="string"):[],expiresAt:typeof o.expiresAt=="number"?o.expiresAt:0,...typeof o.reactor=="string"?{reactor:o.reactor}:{},...typeof o.teamSignIn=="string"?{teamSignIn:o.teamSignIn}:{},...Oe(o.team)?{team:Oe(o.team),openedThreads:Array.isArray(o.openedThreads)?o.openedThreads.filter(a=>typeof a=="string"):[]}:{},...o.cloudGuest===!0?{cloudGuest:!0,openedThreads:Array.isArray(o.openedThreads)?o.openedThreads.filter(a=>typeof a=="string"):[]}:{}}:o.trust==="service"?{kind:"loopback",trust:"service"}:{kind:"loopback"}:{kind:"unreachable",error:`${t.status} ${t.statusText}`}}function Oe(e){const t=Object(e);return typeof t.id=="string"&&typeof t.name=="string"&&typeof t.role=="string"?{id:t.id,name:t.name,role:t.role}:null}function Gt(e){return e?.kind==="session"||e?.kind==="loopback"&&e.trust!=="service"}function tt(e){return e?e.kind==="loopback"?e.trust!=="service":e.kind==="session"&&e.scopes.includes("admin"):!1}function Yt(){const e=/[#&]code=([^&]+)/.exec(location.hash);return e?(history.replaceState(null,"",location.pathname+location.search),decodeURIComponent(e[1])):null}function qt(){if(!/[#&]signin=/.test(location.hash))return null;const e=/[#&]signin=(omb_pair_[A-Za-z0-9_-]{43})(?:&|$)/.exec(location.hash);return history.replaceState(null,"",location.pathname+location.search),e?e[1]:null}function Jt(){const e=new URLSearchParams(location.search),t=e.get("email")?.trim().toLowerCase()??"";if(!t)return null;e.delete("email");const n=e.toString();return history.replaceState(null,"",location.pathname+(n?`?${n}`:"")+location.hash),/^[^@\s]+@[^@\s]+\.[^@\s]+$/.test(t)?t:null}function nt(e=navigator.userAgent){const t=/Edg\//.test(e)?"Edge":/OPR\//.test(e)?"Opera":/Chrome\//.test(e)?"Chrome":/Firefox\//.test(e)?"Firefox":/Safari\//.test(e)?"Safari":"Browser",n=/iPhone/.test(e)?"iPhone":/iPad/.test(e)?"iPad":/Android/.test(e)?"Android":/Mac OS X/.test(e)?"Mac":/Windows/.test(e)?"Windows":/Linux/.test(e)?"Linux":"";return n?`${t} on ${n}`:t}function Z(){return typeof crypto?.randomUUID=="function"?crypto.randomUUID():`${Date.now().toString(36)}-${Math.random().toString(36).slice(2,14)}`}function ot(e,t){const n=Reflect.get(Object(e),"error");return St(e,typeof n=="string"?n:`${t.status} ${t.statusText}`)}async function ue(e,t=fetch){let n;try{n=await t("/api/auth/pair",{method:"POST",credentials:"same-origin",headers:{"content-type":"application/json"},body:JSON.stringify({code:e.code,label:e.label,cookie:!0,attemptId:e.attemptId??Z(),...e.browser?{browser:!0}:{}})})}catch(a){return{ok:!1,error:s("pair.unreachable",{error:a instanceof Error?a.message:String(a)})}}const o=await n.json().catch(()=>({}));return n.ok?{ok:!0}:{ok:!1,error:ot(o,n)}}async function Zt(e,t=fetch){try{const n=await t("/api/auth/pair",{method:"POST",credentials:"same-origin",headers:{"content-type":"application/json"},body:JSON.stringify({code:e,browser:!0,preview:!0})}),o=Object(await n.json().catch(()=>({}))),a=Reflect.get(o,"owner"),i=Reflect.get(o,"team");return n.ok&&typeof a=="string"&&a?{owner:a,...typeof i=="string"&&i.trim()?{team:i.trim()}:{}}:null}catch{return null}}function Qt(e,t,n=fetch){return ue({code:e,label:nt(),attemptId:t,browser:!0},n)}function bo(e){const t=Object(e);return t.cloudHome===!0&&typeof t.owner=="string"&&t.owner?t.owner:null}async function rt(e,t,n){let o;try{o=await n(e,{method:"POST",credentials:"same-origin",headers:{"content-type":"application/json"},body:JSON.stringify(t)})}catch(i){return{ok:!1,error:s("pair.unreachable",{error:i instanceof Error?i.message:String(i)})}}const a=await o.json().catch(()=>({}));return o.ok?{ok:!0}:{ok:!1,error:ot(a,o)}}function en(e,t=fetch){return rt("/api/auth/email/start",{email:e},t)}function tn(e,t=fetch){return rt("/api/auth/email/verify",{email:e.email,code:e.code,label:e.label},t)}function Le(e){return!e||/through a proxy|loopback host required|cross-origin request|^40[13]$/i.test(e)?null:e}function nn(){window.ogb?.softwareRendering===!0&&(document.documentElement.dataset.softwareRendering="")}const on="/api/theme-assets/",rn="safe-look",at={cssChars:1e5,assetBytes:10*1024*1024},an=/^[a-z0-9][a-z0-9-]{0,47}$/,sn=/^[a-z0-9][a-z0-9_-]{0,79}\.(png|jpe?g|webp|gif|avif|svg|woff2?|ttf|otf)$/,ln=/^\/api\/theme-assets\/[a-z0-9][a-z0-9-]{0,47}\/[a-z0-9][a-z0-9_-]{0,79}\.[a-z0-9]{2,5}$/,st=["app","panel","frame","raised","raised-hover","card","inset","control","composer","composer-ring","menu","menu-hover","menu-active","hairline","edge","scrollbar","ink","ink-secondary","ink-tertiary","accent","accent-border","accent-text","accent-ink","focus","bubble-user","bubble-user-ink","success","success-ink","danger","danger-ink","warning"],Q=I().trim().regex(/^#(?:[0-9a-f]{3}|[0-9a-f]{6})$/i,"a hex colour such as #1a2b3c"),cn=I().trim().min(1).max(120).regex(/^[#a-z0-9(),.%\s/+-]+$/i,"a CSS colour such as #1a2b3c, rgb(…) or color-mix(…)").refine(e=>!/url|image|src|attr/i.test(e),"a colour, not a file"),it=jt(qe(st),cn),Re=be({canvas:Q.optional(),accent:Q.optional(),colors:it.optional()}).strict(),ye=be({name:I().trim().min(1).max(60),skin:qe([...Je,"system"]).optional(),canvas:Q.optional(),accent:Q.optional(),colors:it.optional(),light:Re.optional(),dark:Re.optional(),font:I().trim().max(300).regex(/^[\w\s"',.-]*$/,'a font-family list such as "Inter Variable", serif').optional(),css:I().max(at.cssChars).optional()}).strict(),un=1;be({mausbotTheme:Et(un),id:I().regex(an).optional(),theme:ye,assets:Nt(I().regex(sn),I().max(Math.ceil(at.assetBytes*1.4)).regex(/^data:[\w/+.-]+;base64,[A-Za-z0-9+/=]+$/)).optional()}).strict();function lt(e){return/^data:/i.test(e)||e.startsWith("#")||ln.test(e)&&!e.includes("..")}function ct(e){const t=e.toLowerCase(),n=[];for(let o=t.indexOf("url(");o!==-1;o=t.indexOf("url(",o+4)){let a=o+4;for(;/\s/.test(e[a]??"");)a++;const i=e[a];let c;if(i==='"'||i==="'"){const l=e.indexOf(i,a+1);if(l===-1)return null;for(c=e.slice(a+1,l),a=l+1;/\s/.test(e[a]??"");)a++;if(e[a]!==")")return null}else{const l=e.indexOf(")",a);if(l===-1||(c=e.slice(a,l).trim(),/[\s"'(]/.test(c)))return null}n.push(c.trim())}return n}const ut=/image-set\(|\bimage\(|\bsrc\(/i;function dt(e){if(e.includes("\\")||ut.test(e))return!0;const t=ct(e);return t===null||t.some(n=>!lt(n))}function dn(e){let t="";for(let n=0;n<e.length;n++){const o=e[n];if(o==="/"&&e[n+1]==="*"){const a=e.indexOf("*/",n+2);n=a===-1?e.length:a+1,t+=" "}else if(o==='"'||o==="'"){let a=n+1;for(;a<e.length&&e[a]!==o&&e[a]!==`
|
|
3
|
+
`;)a+=e[a]==="\\"?2:1;t+=`${o}${" ".repeat(Math.max(0,a-n-1))}${o}`,n=a}else t+=o}return t}function go(e){const t=dn(e);if(/@import/i.test(t))return"@import is not allowed: themes cannot load other stylesheets.";if(t.includes("\\"))return"Backslash escapes are only allowed inside quoted strings.";if(ut.test(t))return"image-set(), image() and src() are not allowed: use url() with a theme file or a data: address.";const n=e.replace(/\/\*[\s\S]*?\*\//g," "),o=ct(n);if(o===null)return'A url() could not be read. Write url("/api/theme-assets/<theme>/<file>").';const a=o.find(i=>!lt(i));return a!==void 0?`url(${a.slice(0,80)}) is not allowed: themes load only their own files (${on}<theme>/<file>), data: addresses or #ids, never the internet.`:null}function de(e=typeof document>"u"?null:document.documentElement){if(!e||typeof window>"u"||typeof window.getComputedStyle!="function")return"dark";try{return window.getComputedStyle(e).getPropertyValue("--code-color-scheme").trim()==="light"?"light":"dark"}catch{return"dark"}}function yo(){const[e,t]=u.useState(()=>de());return u.useEffect(()=>{const n=()=>t(de());if(n(),typeof MutationObserver>"u")return;const o=new MutationObserver(n);return o.observe(document.documentElement,{attributes:!0,attributeFilter:["data-skin"]}),()=>o.disconnect()},[]),e}const N=[255,255,255],P=[0,0,0];function ee(e){const t=e.trim().replace(/^#/,""),n=t.length===3?[...t].map(a=>a+a).join(""):t,o=Number.parseInt(n.slice(0,6),16);return Number.isFinite(o)?[o>>16&255,o>>8&255,o&255]:P}const V=e=>Math.round(Math.min(255,Math.max(0,e))).toString(16).padStart(2,"0"),d=([e,t,n],o)=>`#${V(e)}${V(t)}${V(n)}${o===void 0?"":V(o*255)}`,v=(e,t,n)=>[0,1,2].map(o=>e[o]+(t[o]-e[o])*n);function te([e,t,n]){const o=a=>{const i=a/255;return i<=.03928?i/12.92:((i+.055)/1.055)**2.4};return .2126*o(e)+.7152*o(t)+.0722*o(n)}function me(e,t){const[n,o]=[te(e),te(t)].sort((a,i)=>i-a);return(n+.05)/(o+.05)}const $e=e=>te(ee(e))<.2?"dark":"light";function G(e,t,n){const o=te(t)<.2?N:P;let a=e;for(let i=1;i<=20&&me(a,t)<n;i++)a=v(e,o,i/20);return a}const mt=e=>me(N,e)>=me(P,e)?N:[17,17,17];function mn(e,t){const n=ee(e),o=t==="dark",a=f=>v(n,o?N:P,f),i=o?a(.08):v(n,N,.85),c=a(o?.14:.06),l=G(v(o?N:P,n,o?.04:.1),n,12),x=a(o?.22:.07);return{app:d(n),panel:d(o?v(n,P,.25):v(n,N,.45)),frame:d(o?v(n,P,.25):v(n,N,.45)),raised:d(i),"raised-hover":d(c),card:d(o?a(.07):i),inset:d(o?a(.04):n),control:d(a(o?.12:.07)),composer:d(o?a(.07):i),"composer-ring":d(a(o?.14:.12)),menu:d(i),"menu-hover":d(l,.06),"menu-active":d(l,.09),hairline:d(a(.2)),edge:d(l,.08),scrollbar:d(a(o?.25:.22)),ink:d(l),"ink-secondary":d(G(v(l,n,o?.3:.4),c,4.5)),"ink-tertiary":d(G(v(l,n,o?.42:.5),c,4.5)),"bubble-user":d(x),"bubble-user-ink":d(o?mt(x):l)}}function pn(e,t,n){const o=ee(e),a=G(o,ee(n),4.5);return{accent:d(o),"accent-ink":d(mt(o)),"accent-border":d(t==="dark"?v(o,N,.2):v(o,P,.1)),"accent-text":d(a),focus:d(a)}}class fn extends Error{}function Y(e,t){const n=globalThis[t];return typeof n=="function"&&e instanceof n}function He(e){const t=e.style;return t&&typeof t=="object"&&typeof t.getPropertyValue=="function"?t:null}function Me(e){for(let t=e.length-1;t>=0;t--){const n=e.item(t);dt(e.getPropertyValue(n))&&e.removeProperty(n)}}const hn=e=>"cssRules"in e&&typeof e.deleteRule=="function";function De(e,t,n){try{e.deleteRule(t)}catch{if(!Y(n,"CSSNamespaceRule"))throw new fn}}function pt(e){for(let t=e.cssRules.length-1;t>=0;t--){const n=e.cssRules[t];if(!n)continue;if(Y(n,"CSSKeyframesRule")){for(const a of Array.from(n.cssRules)){const i=He(a);i&&Me(i)}continue}if(Y(n,"CSSPropertyRule")){dt(n.initialValue??"")&&De(e,t,n);continue}const o=He(n);o&&Me(o),hn(n)?pt(n):!o&&!Y(n,"CSSLayerStatementRule")&&De(e,t,n)}}let R=null,ze="";function Be(e){if(!(typeof document>"u"||typeof CSSStyleSheet>"u"||!("adoptedStyleSheets"in document))&&e!==ze){ze=e,R||(R=new CSSStyleSheet,document.adoptedStyleSheets=[...document.adoptedStyleSheets,R]);try{R.replaceSync(e),pt(R)}catch{R.replaceSync("")}}}const pe="omb-theme",Fe="omb-safe-look";let A=null,F=[],ie=!1;const fe=new Set;function U(e){try{return typeof window>"u"?void 0:window[e]}catch{return}}function xn(){try{return typeof location<"u"&&new URLSearchParams(location.search).has(rn)&&U("sessionStorage")?.setItem(Fe,"1"),U("sessionStorage")?.getItem(Fe)==="1"}catch{return!1}}function ko(){return A}function wo(e){return fe.add(e),()=>{fe.delete(e)}}function bn(e){for(const t of F)e.style.removeProperty(t);F=[]}function q(){if(!(typeof document>"u"||ie)){ie=!0;try{const e=document.documentElement;bn(e);const t=xn()?null:A?.theme;if(!t){delete e.dataset.theme,Be(""),Te(_e());return}const n=t.skin??(t.canvas?Pt[$e(t.canvas)]:void 0);Te(n?It(n):_e());const o=de(e),a=t[o],i=a?.canvas??(t.canvas&&$e(t.canvas)===o?t.canvas:void 0),c=a?.accent??t.accent,l={...i?mn(i,o):{},...c?pn(c,o,i??(o==="dark"?"#121212":"#ffffff")):{},...t.colors,...a?.colors};for(const x of st){const f=l[x];f&&(e.style.setProperty(`--color-${x}`,f),F.push(`--color-${x}`))}i&&(e.style.setProperty("--code-color-scheme",o),F.push("--code-color-scheme")),t.font&&(e.style.setProperty("--font-sans",t.font),F.push("--font-sans")),e.dataset.theme=A.id,Be(t.css??"")}finally{ie=!1;for(const e of fe)e()}}}function ke(e){A=e;try{e?U("localStorage")?.setItem(pe,JSON.stringify(e)):U("localStorage")?.removeItem(pe)}catch{}q()}function gn(){try{const e=JSON.parse(U("localStorage")?.getItem(pe)??"null"),t=ye.safeParse(e?.theme);return typeof e?.id=="string"&&t.success?{id:e.id,theme:t.data}:null}catch{return null}}async function we(){try{const e=await fetch("/api/themes/active",{headers:{accept:"application/json"}});if(!e.ok)return;const t=await e.json(),n=t.theme?ye.safeParse(t.theme):null;ke(t.id&&n?.success?{id:t.id,theme:n.data}:null)}catch{}}function vo(e){const t=e.skin;(t==="system"||Je.includes(t))&&ge(t),we()}const ve=(e,t)=>fetch("/api/themes/active",{method:"PUT",headers:{"content-type":"application/json"},body:JSON.stringify({id:e,...t?{skin:t}:{}})}).then(n=>n.ok,()=>!1);function So(){A&&(ke(null),ve(null))}async function jo(e){const t=await ve(e);return t&&await we(),t}function yn(){ge(Ie),ke(null),ve(null,Ie)}const kn=e=>e.code==="KeyR"&&e.altKey&&e.shiftKey&&(e.metaKey||e.ctrlKey);function wn(){if(!(typeof window>"u")){if(window.addEventListener("keydown",e=>{kn(e)&&(e.preventDefault(),e.stopPropagation(),yn())},{capture:!0}),Ct(q),typeof matchMedia=="function")try{matchMedia("(prefers-color-scheme: dark)").addEventListener("change",q)}catch{}A=gn(),A&&q()}}function vn({credential:e,owner:t,team:n}){const[o]=u.useState(()=>Z()),[a,i]=u.useState(!1),[c,l]=u.useState(null);async function x(){i(!0),l(null);const f=await Qt(e,o);if(f.ok){location.replace("/");return}i(!1),l(f.error)}return r.jsx("main",{className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsxs("div",{className:"w-full max-w-[420px]",children:[r.jsx("h1",{className:"text-[20px] font-semibold",children:n?s("pair.browser.teamTitle",{team:n,owner:t}):s("pair.browser.title",{owner:t})}),r.jsx("p",{className:"mt-1.5 text-[14px] text-ink-secondary",children:s("pair.browser.notYou")}),c?r.jsx("p",{role:"alert",className:"mt-3 text-[13px] text-danger",children:c}):null,r.jsx("button",{type:"button",onClick:()=>{x()},disabled:a,className:"mt-5 w-full rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink disabled:opacity-50",children:s(a?"pair.signingIn":"pair.continue")})]})})}const Se="bg-composer ring-1 ring-inset ring-ink/[0.07]",Sn="bg-composer ring-[0.5px] ring-ink/10",No=`${Sn} shadow-(--shadow-float)`,ft="transition-colors duration-[120ms] hover:bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]",jn=`${ft} aria-expanded:bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]`,Eo="bg-[color-mix(in_srgb,var(--color-composer),var(--color-ink)_7%)]",Co="focus-visible:outline-2 focus-visible:-outline-offset-2! focus-visible:outline-focus",ht="flex size-9 shrink-0 items-center justify-center rounded-full text-ink/90",je="focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",Nn=`${ht} ${Se} ${jn} ${je}`,Po=`${ht} ${Se} ${ft} ${je}`,En=`flex size-[26px] shrink-0 items-center justify-center rounded-lg text-ink-secondary transition-colors hover:bg-ink/[0.06] hover:text-ink aria-expanded:bg-ink/[0.06] aria-expanded:text-ink ${je}`,Io="flex size-10 shrink-0 items-center justify-center rounded-full border border-hairline bg-card text-ink hover:bg-raised focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",Cn="flex size-9 shrink-0 items-center justify-center rounded-xl text-ink-secondary hover:bg-raised/60 hover:text-ink focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus";function To({open:e,onToggle:t,corner:n=!1,ref:o}){return r.jsx("button",{ref:o,type:"button","data-sidebar-search-toggle":!0,onClick:t,"aria-label":s("sidebar.searchAria"),"aria-expanded":e,title:s("sidebar.searchAria"),className:n?En:Nn,children:r.jsx(Ze,{size:n?17:18,strokeWidth:1.5,"aria-hidden":"true"})})}function _o({query:e,onQuery:t,onClose:n}){return r.jsx("div",{"data-sidebar-search-pill":!0,className:"px-3 pb-2 pt-0.5",children:r.jsxs("div",{className:$("flex h-[34px] items-center gap-2 rounded-full pl-3 pr-1.5 text-ink-secondary focus-within:ring-focus",Se),children:[r.jsx(Ze,{size:15,"aria-hidden":"true",className:"shrink-0"}),r.jsx("input",{autoFocus:!0,value:e,onChange:o=>t(o.target.value),onKeyDown:o=>{o.key==="Escape"&&(o.preventDefault(),n())},placeholder:s("sidebar.searchAria"),"aria-label":s("sidebar.searchAria"),className:"min-w-0 flex-1 bg-transparent text-[13px] text-ink placeholder:text-ink-tertiary focus:outline-none"}),r.jsx("button",{type:"button",onClick:n,"aria-label":s("sidebar.searchClose"),title:s("sidebar.searchClose"),className:"flex size-6 shrink-0 items-center justify-center rounded-full text-ink-tertiary hover:bg-raised hover:text-ink focus-visible:outline focus-visible:outline-2 focus-visible:outline-focus",children:r.jsx(Tt,{size:14,"aria-hidden":"true"})})]})})}function Pn(e,{howTo:t=!1,onClosed:n}={}){return e.menu(t?{from:"howto"}:void 0).finally(()=>{t&&n?.()})}function Ao(e){e({type:"cloudHowTo",open:!1})}function Ue({text:e}){return r.jsxs("span",{className:"font-normal text-ink-secondary",children:[" · ",e]})}function In(e){return e?.sleeps===!0?!0:e?.status==="paid"?!1:null}function Tn(e){const t=e&&!window.ogb?.remoteClient?.active?window.ogb?.cloudPlan:void 0,n=e||window.ogb?.remoteClient?.active?void 0:window.ogb?.cloudAccount,[o,a]=u.useState(null),[i,c]=u.useState(!1);return u.useEffect(()=>{if(!t)return;let l=!0;return t.state().then(x=>{l&&a(In(x))}).catch(()=>{}),()=>{l=!1}},[t]),u.useEffect(()=>n?.onState(l=>c(l.waking===!0)),[n]),{sleeps:t?o:null,waking:i}}function _n({cloudHome:e=!1,howTo:t=!1,onMenuClosed:n}){const o=window.ogb?.workspaces,[a,i]=u.useState(null),[c,l]=u.useState(!1),[x,f]=u.useState("");u.useEffect(()=>{let p=!0;const k=()=>{o?.state().then(E=>{p&&i(E)}).catch(()=>{})};k();const T=o?.onChanged?.(k);return()=>{p=!1,T?.()}},[o]);const w=Tn(e||a?.home===!0),m=w.sleeps===null?"":s(w.sleeps?"cloudSetup.sleepsWhenIdle":"cloudSetup.alwaysOn"),g=w.waking?s("cloudHome.waking"):"";return{bridge:o,current:a,cloudHome:e,open:c,error:x,onLine:m,waking:g,openMenu:()=>{!o||c||(f(""),l(!0),Pn(o,{howTo:t,onClosed:n}).catch(()=>f(s("sidebar.switchServerError"))).finally(()=>l(!1)))},switchable:!!o&&a?.home!==!0}}function An(e){const t=_t(),n=r.jsx(On,{...e});return At(t)?r.jsx("div",{"data-switcher-beside-rail":!0,className:t.beside?"hidden":"contents md:hidden",children:n}):n}function On({compact:e=!1,inline:t=!1,pill:n=!1,rail:o=!1,cloudHome:a=!1,owner:i=null,howTo:c=!1,place:l,onMenuClosed:x}){const f=l||s("cloudSetup.myCloud"),{bridge:w,current:m,open:g,error:y,onLine:p,waking:k,openMenu:T}=_n({cloudHome:a,howTo:c,onMenuClosed:x}),E=b=>p?`${b} · ${p}`:b;if(!w||m?.home===!0){if(!a&&!m?.home)return null;const b=i?s("sidebar.cloudOwner",{email:i}):"",j=`${E(f)}${b?` · ${b}`:""}`;return o?r.jsx("div",{"data-cloud-home-indicator":!0,"data-workspace-switcher":"rail",role:"img","aria-label":j,title:j,className:"flex size-9 items-center justify-center text-ink-secondary",children:r.jsx(K,{size:18,"aria-hidden":"true"})}):t?r.jsxs("div",{"data-cloud-home-indicator":!0,"data-workspace-switcher":"inline",title:j,className:n?"flex h-8 min-w-0 items-center gap-1 rounded-full bg-raised/50 px-3 text-[13px] font-medium text-ink":"flex min-w-0 items-center gap-1.5 px-1.5 text-[13px] font-medium text-ink",children:[r.jsx(K,{size:n?15:14,"aria-hidden":"true",className:n?"hidden shrink-0 text-ink-secondary @max-[124px]/sidebar-top:block":"shrink-0 text-ink-secondary"}),r.jsx("span",{className:n?"min-w-0 truncate @max-[124px]/sidebar-top:hidden":"min-w-0 truncate",children:f}),(p||b)&&r.jsxs("span",{className:"sr-only",children:[p?` · ${p}`:"",b?` · ${b}`:""]})]}):r.jsx("div",{"data-cloud-home-indicator":!0,className:$("py-1.5",e?"px-2":"px-3"),children:r.jsxs("div",{title:j,className:$("flex items-center gap-2 py-2 text-[13px] font-medium text-ink",e?"justify-center px-1":"px-2"),children:[r.jsx(K,{size:16,"aria-hidden":"true",className:"shrink-0 text-ink-secondary"}),e?r.jsx("span",{className:"sr-only",children:j}):r.jsxs("span",{className:"min-w-0 flex-1 truncate",children:[f,p&&r.jsx(Ue,{text:p}),b&&r.jsx("span",{className:"block truncate text-[12px] font-normal text-ink-secondary",children:b})]})]})})}const O=m?.profileName??(m?.local&&!m.localPath?s("place.local"):m?.name)??(a?f:s("sidebar.servers")),S=m?.local===!1||a&&!m?K:Ot,M=a?E(O):O,_=m?.origin?`${M} · ${m.origin}`:M,L=s("sidebar.switchServer",{name:M});return o?r.jsxs("div",{"data-workspace-switcher":"rail",className:"relative",children:[r.jsx("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:$(Cn,"aria-expanded:bg-raised"),style:{WebkitAppRegion:"no-drag"},children:ae(m?.color)?r.jsx(se,{color:m?.color,size:18}):r.jsx(S,{size:18,"aria-hidden":"true"})}),y&&r.jsx("p",{role:"alert",className:"absolute bottom-0 left-full z-40 ml-2 w-56 rounded-md bg-menu px-2 py-1 text-[11px] text-danger shadow-lg",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"absolute bottom-0 left-full z-40 ml-2 w-56 rounded-md bg-menu px-2 py-1 text-[11px] text-ink-secondary shadow-lg",children:k})]}):t?r.jsxs("div",{"data-workspace-switcher":"inline",className:"flex min-w-0",children:[r.jsxs("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:n?"flex h-8 min-w-0 max-w-full items-center gap-1 overflow-hidden rounded-full bg-raised/50 pl-2.5 pr-1.5 text-left text-[13px] font-medium text-ink hover:bg-raised aria-expanded:bg-raised focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus":"flex h-7 min-w-0 max-w-full items-center gap-1.5 overflow-hidden rounded-md px-1.5 text-left text-[13px] font-medium text-ink hover:bg-control focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",style:{WebkitAppRegion:"no-drag"},children:[ae(m?.color)?r.jsx(se,{color:m?.color,size:16}):r.jsx(S,{size:n?15:14,"aria-hidden":"true","data-switcher-icon":!0,className:n?"hidden shrink-0 text-ink-secondary @max-[124px]/sidebar-top:block":"shrink-0 text-ink-secondary"}),r.jsx("span",{className:n?"min-w-0 truncate @max-[124px]/sidebar-top:hidden":"min-w-0 truncate @max-[96px]/sidebar-top:hidden",children:O}),r.jsx(Ae,{size:n?12:11,"aria-hidden":"true",className:n?"shrink-0 text-ink-tertiary":"shrink-0 text-ink-secondary"})]}),y&&r.jsx("p",{role:"alert",className:"absolute right-2 top-full z-40 mt-1 w-56 max-w-[calc(100%-1rem)] rounded-md bg-menu px-2 py-1 text-[11px] text-danger shadow-lg",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"absolute right-2 top-full z-40 mt-1 w-56 max-w-[calc(100%-1rem)] rounded-md bg-menu px-2 py-1 text-[11px] text-ink-secondary shadow-lg",children:k})]}):r.jsxs("div",{className:$("py-1.5",e?"px-2":"px-3"),children:[r.jsxs("button",{type:"button","aria-label":L,"aria-haspopup":"menu","aria-expanded":g,"data-cloud-home-indicator":a||void 0,"data-tour":"server-switcher",title:_,onClick:T,className:$("flex w-full items-center gap-2 rounded-lg py-2 text-left text-[13px] font-medium text-ink hover:bg-control focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus",e?"justify-center px-1":"px-2"),style:{WebkitAppRegion:"no-drag"},children:[ae(m?.color)?r.jsx(se,{color:m?.color,size:20}):r.jsx(S,{size:16,className:"shrink-0 text-ink-secondary"}),!e&&r.jsxs(r.Fragment,{children:[r.jsxs("span",{className:"min-w-0 flex-1 truncate",children:[O,a&&p&&r.jsx(Ue,{text:p})]}),r.jsx(Ae,{size:13,className:"shrink-0 text-ink-secondary"})]})]}),y&&r.jsx("p",{role:"alert",className:"mt-1 text-[11px] text-danger",children:y}),k&&!y&&r.jsx("p",{role:"status","data-cloud-waking":!0,className:"mt-1 text-[11px] text-ink-secondary",children:k})]})}function Ln(e){const t=e&&typeof e=="object"?e.membership:void 0,n=t&&typeof t=="object"?t:{};let o=null;if(typeof n.peopleUrl=="string")try{new URL(n.peopleUrl).protocol==="https:"&&(o=n.peopleUrl)}catch{o=null}return{authority:n.authority==="portal"?"portal":"local",pairingCodes:n.pairingCodes!==!1,peopleUrl:o}}const Oo=()=>({type:"toggleAppSettings",open:!0,section:"companion",phonePairing:!0});function Lo(e){const t=typeof window>"u"?void 0:window.ogb;return Rn({companion:!!t?.companion,remoteClient:t?.remoteClient?.active===!0,cloudHome:e})}function Rn(e){return e.cloudHome?"cloud":e.companion&&!e.remoteClient?"computer":"server"}const $n={computer:"sidebar.menu.connectPhone.computer",cloud:"sidebar.menu.connectPhone.cloud",server:"sidebar.menu.connectPhone.server"};function Ro(e,t){const n=t?.session?.kind==="session"?t.session.team?.name:void 0;return n?{target:e,subtitleKey:"sidebar.menu.connectPhone.team",team:n}:e!=="computer"&&!(t&&t.pairingCodes&&tt(t.session))?null:{target:e,subtitleKey:$n[e]}}function $o(e,t){if(!e)return[];const n={...e,id:"here"};return e.target,[n]}let We=null;function Ho(e=fetch){return We??=ne(e).then(async t=>{if(!tt(t))return{session:t,pairingCodes:!1};const n=await e("/api/config",{credentials:"same-origin"}).then(o=>o.ok?o.json():null).catch(()=>null);return{session:t,pairingCodes:Ln(n).pairingCodes}}),We}const Hn="data-phone-pairing-action";function Mo(e,t=n=>window.requestAnimationFrame(n)){return e?(t(()=>{e.scrollIntoView?.({block:"start"}),(e.querySelector(`[${Hn}]:not([disabled])`)??e).focus({preventScroll:!0})}),!0):!1}function Do(e){const t=new URL(e);return t.searchParams.get("desktop-settings")!=="phone"?null:(t.searchParams.delete("desktop-settings"),`${t.pathname}${t.search}${t.hash}`)}function le(e){const t=new URLSearchParams(e);if(t.get("desktop-settings")==="phone")return"/?desktop-settings=phone";const n=t.get("next");return n&&/^\/(?!\/)/.test(n)&&!n.startsWith("/pair")&&!/[\\\s]/.test(n)?n:"/"}const Mn="23456789ABCDEFGHJKLMNPQRSTUVWXYZ",Dn=12,zn="omb_pair_",Bn=/^omb_pair_[A-Za-z0-9_-]{43}$/;function xt(e){return e.toUpperCase().replace(/[^A-Z0-9]/g,"").replace(/0/g,"O").replace(/1/g,"I")}function Fn(e){return xt(e).match(/.{1,4}/g)?.join("-")??e}const Un={emailCode:"serverError.pair.emailCode",oldCode:"serverError.pair.oldCode",scriptKey:"serverError.pair.scriptKey",notACode:"serverError.pair.notACode"};function Wn(e){let t;try{t=new URL(e)}catch{return null}const n=new URLSearchParams(t.hash.replace(/^#/,""));return t.searchParams.get("token")??t.searchParams.get("code")??n.get("code")}function Ne(e){let t=e.trim();if(!t)return{kind:"empty"};if(/^[a-z][a-z0-9+.-]*:\/\//i.test(t)){const a=Wn(t);if(!a)return{kind:"wrong",problem:"notACode"};t=a.trim()}if(t.startsWith("omb_sess_"))return{kind:"wrong",problem:"scriptKey"};if(t.startsWith(zn))return Bn.test(t)?{kind:"credential",credential:t}:{kind:"wrong",problem:"notACode"};const n=t.replace(/[\s-]/g,"");if(/^\d{8}$/.test(n))return{kind:"wrong",problem:"emailCode"};if(/^\d{6}$/.test(n))return{kind:"wrong",problem:"oldCode"};const o=xt(t);return o.length!==Dn||[...o].some(a=>!Mn.includes(a))?{kind:"wrong",problem:"notACode"}:{kind:"code",code:o}}const z="mt-1 w-full rounded-md border border-hairline/40 bg-inset px-3 py-2 text-[14px] text-ink outline-none focus:border-accent-border",Ke="mt-5 w-full rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink disabled:opacity-50",B="mt-4 block text-[12px] font-medium text-ink-secondary";function Kn(e,t=typeof window<"u"&&!!window.ogb?.workspaces){return!!e&&t}function Vn({mode:e,sent:t,email:n,cloudHome:o}){return e==="email"?t?s("pair.intro.emailSent",{email:n}):s("pair.intro.email"):o?s("pair.intro.cloud",{app:H(),open:s("cloudHome.connect"),section:s("settings.section.cloudAccount")}):s("pair.intro.code")}function Xn(e){const t=Ne(e);return t.kind==="wrong"&&t.problem!=="notACode"?s(Un[t.problem]):null}function Gn(e){const t=Ne(e).kind;return t==="code"||t==="credential"}function Yn(e,t){const n=Ne(t),o=n.kind==="code"?`&code=${encodeURIComponent(Fn(n.code))}`:"";return`openmausbot://pair?address=${encodeURIComponent(e)}${o}`}function qn(e){return e.protocol==="http:"&&!Lt(e.hostname)}function Ve(e,t=Xt()){if(!e?.capabilities.cloudTeam||typeof t!="string")return null;try{const n=new URL(t),o=n.protocol==="http:"&&["127.0.0.1","localhost","[::1]"].includes(n.hostname);return(n.protocol==="https:"||o)&&!n.username&&!n.password&&!n.hash?n.href:null}catch{return null}}function Jn(e,t){return e?.capabilities.cloudTeam?e.label:e?.capabilities.cloudHome?s("pair.myCloud"):s(t==="email"?"pair.signInTo":"pair.connectTo",{name:e?.label??s("pair.thisOpenMausBot",{app:H()})})}function Zn({team:e}){return r.jsx("main",{"data-team-left":!0,className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsx("p",{role:"status",className:"max-w-[420px] text-[16px]",children:s("homeLine.left",{name:e??s("pair.thisOpenMausBot",{app:H()})})})})}function X({initialCode:e,initialEmail:t=null,reason:n}){const[o,a]=u.useState(e??""),[i,c]=u.useState(nt()),[l,x]=u.useState(null),[f,w]=u.useState(null),[m,g]=u.useState(!1),[y,p]=u.useState(null),[k,T]=u.useState(()=>Z()),[E,O]=u.useState(t&&!e?"email":"code"),[S,M]=u.useState(t??""),[_,L]=u.useState(""),[b,j]=u.useState(!1),[oe,gt]=u.useState(()=>Kn(e));u.useEffect(()=>{if(!oe||!e)return;let h=!0;return ue({code:e,label:i,attemptId:k}).then(C=>{if(h){if(C.ok){location.replace(le(location.search));return}gt(!1),p(C.error)}}),()=>{h=!1}},[]),u.useEffect(()=>{fetch("/.well-known/openmausbot/environment").then(h=>h.ok?h.json():null).then(h=>{x(h)}).catch(()=>{x(null)}),ne().then(w)},[]);const re=Gt(f),yt=l?.capabilities.emailSignIn===!0,D=l?.capabilities.cloudHome===!0,kt=!D&&l?.capabilities.cloudTeam!==!0,Ce=Xn(o),W=typeof location<"u"&&typeof location.protocol=="string"?location:null;async function wt(h){h.preventDefault(),g(!0),p(null);const C=await ue({code:o,label:i,attemptId:k});if(g(!1),C.ok){location.replace(le(location.search));return}p(C.error)}async function vt(h){h.preventDefault(),g(!0),p(null);const C=b?await tn({email:S,code:_,label:i}):await en(S);if(g(!1),!C.ok){p(C.error);return}if(b){location.replace(le(location.search));return}j(!0)}function Pe(h){O(h),p(null)}return r.jsxs("main",{className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:[r.jsx("div",{className:"absolute left-3 top-12 max-w-[280px]",children:r.jsx(An,{})}),r.jsxs("div",{className:"w-full max-w-[420px]",children:[W&&qn(W)?r.jsx("p",{role:"alert",className:"mb-4 rounded-md border border-warning/30 bg-warning/10 px-3 py-2 text-[13px] text-warning",children:s("pair.notEncrypted")}):null,oe?r.jsx("p",{role:"status",className:"text-[20px] font-semibold",children:D?s("pair.openingCloud"):s("pair.connectingTo",{name:l?.label??s("pair.thisOpenMausBot")})}):r.jsxs(r.Fragment,{children:[r.jsx("h1",{className:"text-[20px] font-semibold",children:Jn(l,E)}),r.jsxs("p",{className:"mt-1.5 text-[14px] leading-relaxed text-ink-secondary",children:[l&&!D?`${s("pair.version",{version:l.version,platform:l.platform})} `:"",Vn({mode:E,sent:b,email:S,cloudHome:D})]}),Le(n)&&!re?r.jsx("p",{className:"mt-3 text-[13px] text-ink-secondary",children:Le(n)}):null,y&&D&&e?r.jsx("p",{className:"mt-3 text-[13px] text-ink-secondary",children:s("pair.expired",{app:H(),open:s("cloudHome.connect"),section:s("settings.section.cloudAccount")})}):null,!re&&Ve(l)?r.jsxs("div",{"data-team-sign-in":!0,className:"mt-4 flex flex-col items-start gap-1.5",children:[r.jsx("a",{href:Ve(l),className:"rounded-md bg-accent px-4 py-2 text-[14px] font-medium text-accent-ink",children:s("pair.team.open",{team:l.label})}),r.jsx("p",{className:"text-[13px] text-ink-secondary",children:s("pair.team.openHint")})]}):null]}),oe?null:re?r.jsxs("p",{className:"mt-4 text-[14px]",children:[s("pair.alreadyConnected")," ",r.jsx("a",{href:"/",className:"text-accent underline",children:s("pair.openApp")})]}):E==="email"?r.jsxs("form",{onSubmit:vt,children:[r.jsx("label",{className:B,htmlFor:"signin-email",children:s("cloudBuy.signIn.email")}),r.jsx("input",{id:"signin-email",type:"email",value:S,onChange:h=>{M(h.target.value),j(!1),L("")},autoComplete:"email",inputMode:"email",spellCheck:!1,className:z}),b?r.jsxs(r.Fragment,{children:[r.jsx("label",{className:B,htmlFor:"signin-code",children:s("pair.emailCode")}),r.jsx("input",{id:"signin-code",value:_,onChange:h=>L(h.target.value),placeholder:"12345678",autoComplete:"one-time-code",inputMode:"numeric",spellCheck:!1,className:`${z} font-mono text-[15px] tracking-[0.12em]`}),r.jsx("label",{className:B,htmlFor:"signin-label",children:s("pair.deviceLabel")}),r.jsx("input",{id:"signin-label",value:i,onChange:h=>c(h.target.value),maxLength:80,className:z})]}):null,y?r.jsx("p",{className:"mt-3 text-[13px] text-danger",children:y}):null,r.jsx("button",{type:"submit",disabled:m||!S.includes("@")||b&&_.replace(/\D/g,"").length<8,className:Ke,children:s(m?b?"pair.signingIn":"pair.sending":b?"pair.signIn":"cloudBuy.signIn.send")}),b?r.jsx("button",{type:"button",onClick:()=>j(!1),className:"mt-3 w-full text-[13px] text-ink-secondary underline",children:s("pair.resend")}):null,r.jsx("button",{type:"button",onClick:()=>Pe("code"),className:"mt-3 w-full text-[13px] text-ink-secondary underline",children:s("pair.useCode")})]}):r.jsxs("form",{onSubmit:wt,children:[r.jsx("label",{className:B,htmlFor:"pair-code",children:s("pair.code")}),r.jsx("input",{id:"pair-code",value:o,onChange:h=>{a(h.target.value),T(Z())},placeholder:"XXXX-XXXX-XXXX","aria-describedby":e&&o===e?"pair-code-from-link":void 0,autoComplete:"one-time-code",autoCapitalize:"characters",spellCheck:!1,className:`${z} font-mono text-[15px] tracking-[0.12em]`}),e&&o===e?r.jsx("p",{id:"pair-code-from-link",className:"mt-1 text-[12px] text-ink-secondary",children:s("pair.fromLink")}):null,r.jsx("label",{className:B,htmlFor:"pair-label",children:s("pair.deviceLabel")}),r.jsx("input",{id:"pair-label",value:i,onChange:h=>c(h.target.value),maxLength:80,className:z}),Ce?r.jsx("p",{role:"alert",className:"mt-3 text-[13px] text-danger",children:Ce}):y?r.jsx("p",{className:"mt-3 text-[13px] text-danger",children:y}):null,r.jsx("button",{type:"submit",disabled:m||!Gn(o),className:Ke,children:s(m?"pair.connecting":"pair.connect")}),W?.origin?r.jsxs("p",{className:"mt-3 text-[13px] text-ink-secondary",children:[s("pair.onPhone")," ",r.jsx("a",{href:Yn(W.origin,o),className:"text-accent underline",children:s("pair.openInApp",{app:H()})})]}):null,kt?r.jsxs("p",{className:"mt-3 text-[13px] text-ink-secondary",children:[s("pair.noCode")," ",r.jsx("code",{className:"select-all rounded bg-inset px-1.5 py-0.5 text-[12px] text-ink",children:"npx limixbot pair"})]}):null,yt?r.jsxs("p",{className:"mt-5 border-t border-hairline/40 pt-4 text-[13px] text-ink-secondary",children:[s("pair.invitedByEmail")," ",r.jsx("button",{type:"button",onClick:()=>Pe("email"),className:"text-accent underline",children:s("pair.useEmail")})]}):null]})]})]})}const zo="cloud-welcome-done",Qn="unauthorized: you are no longer in this team",Xe=[["reserving","cloudHome.step.reserving"],["storage","cloudHome.step.storage"],["starting","cloudHome.step.starting"],["checking","cloudHome.step.checking"]];function eo({step:e}){const t=Xe.findIndex(([n])=>n===e);return r.jsx("ol",{"data-cloud-setup":e,className:"flex flex-col gap-1 text-[13px]",children:Xe.map(([n,o],a)=>r.jsx("li",{"aria-current":a===t?"step":void 0,className:a===t?"font-medium text-ink":a<t?"text-ink-secondary line-through decoration-ink-secondary/40":"text-ink-secondary",children:s(o)},n))})}const to={stopped:"cloudHome.stopped","payment-problem":"cloudHome.paymentProblem",failed:"cloudHome.failed"},Ge={host:"cloudHome.unreachableHost",no_answer:"cloudHome.unreachable"};function no(e,t=Date.now()){const n=new Date(e).getFullYear()!==new Date(t).getFullYear();return new Intl.DateTimeFormat(Rt(),{day:"numeric",month:"long",...n?{year:"numeric"}:{}}).format(new Date(e))}function oo(e,t=Date.now()){const n=e?.name??null,o=(a,i)=>n?s(i,{name:n}):s(a);return e?.screen==="setup"?{title:o("homeScreen.setup","homeScreen.setupNamed"),body:s(e.slow?"cloudHome.slow":"homeScreen.setupBody"),reason:null,action:null,busy:!0}:e?.screen==="offline"?{title:o("homeScreen.offline","homeScreen.offlineNamed"),body:s("homeScreen.offlineBack"),reason:e.cause&&Object.hasOwn(Ge,e.cause)?s(Ge[e.cause]):e.reason??null,action:"retry",busy:!1}:e?.screen==="signin"?{title:o("homeScreen.signIn","homeScreen.signInNamed"),body:s(e.other?"homeScreen.signInOther":"homeScreen.signInEnded"),reason:null,action:"sign-in",busy:!1}:e?.screen==="plan"&&e.member&&e.machine!=="failed"?{title:o("homeScreen.plan","homeScreen.planNamed"),body:s("cloudHome.stoppedMember"),reason:null,action:null,busy:!1}:e?.screen==="plan"?{title:o("homeScreen.plan","homeScreen.planNamed"),body:s(to[e.machine]??"cloudHome.failed"),reason:null,action:e.machine==="failed"?null:"manage",busy:!1}:e?.screen==="ended"?{title:o("cloudHome.ended","cloudHome.endedNamed"),body:e.deleteAt?s("cloudHome.endedFiles",{date:no(e.deleteAt,t)}):null,reason:null,action:"buy",busy:!1}:e?.screen==="checkout"?{title:o("cloudHome.checkout","cloudHome.checkoutNamed"),body:null,reason:null,action:"continue",busy:!1}:e?.screen==="payment"?{title:o("cloudHome.payment","cloudHome.paymentNamed"),body:s("cloudHome.paymentBody"),reason:null,action:"card",busy:!1}:e?.screen==="waking"?{title:s("homeScreen.waking"),body:null,reason:null,action:null,busy:!0}:e?.screen==="moving"?{title:o("homeScreen.moving","homeScreen.movingNamed"),body:null,reason:null,action:null,busy:!0}:{title:o("homeScreen.opening","homeScreen.openingNamed"),body:null,reason:null,action:null,busy:!0}}const ro={retry:"cloudHome.tryAgain",buy:"cloudHome.buyAgain",continue:"cloudHome.continue",card:"cloudHome.updateCard"};function ao({name:e,remove:t}){const[n,o]=u.useState(!1),[a,i]=u.useState(!1),[c,l]=u.useState(null),x=()=>{i(!0),l(null),t().then(f=>{i(!1),f!=="removed"&&f!=="gone"&&(o(!1),l(f==="refused"?"refused":"failed"))},()=>{i(!1),o(!1),l("failed")})};return r.jsxs("div",{"data-home-remove":!0,className:"flex flex-col items-start gap-2",children:[n?r.jsxs("div",{role:"alertdialog","aria-label":s("rail.remove"),className:"flex flex-col gap-2 rounded-xl border border-hairline/70 bg-card/70 px-4 py-3",children:[r.jsx("p",{className:"text-[13px] leading-relaxed text-ink",children:s("rail.removeAsk",{name:e})}),r.jsxs("div",{className:"flex gap-2",children:[r.jsx("button",{type:"button","data-home-remove-confirm":!0,className:"ui-button ui-button-primary",disabled:a,onClick:x,children:s("rail.removeYes")}),r.jsx("button",{type:"button",className:"ui-button",disabled:a,onClick:()=>o(!1),children:s("rail.removeNo")})]})]}):r.jsx("button",{type:"button","data-home-remove-ask":!0,className:"text-[13px] text-ink-secondary underline-offset-2 hover:text-ink hover:underline",onClick:()=>{l(null),o(!0)},children:s("rail.remove")}),c&&r.jsx("p",{role:"alert",className:"text-[13px] text-danger",children:s(c==="refused"?"rail.removeRefused":"rail.removeFailed")})]})}function so({bridge:e,manage:t}){const[n,o]=u.useState(null),[a,i]=u.useState(!1);u.useEffect(()=>{let g=!0;const y=e.onState(k=>o(k)),p=()=>{e.retry().then(k=>{g&&o(k)}).catch(()=>{})};return e.state().then(k=>{g&&o(k)}).catch(()=>{}).then(p),window.addEventListener("online",p),window.addEventListener("focus",p),()=>{g=!1,y(),window.removeEventListener("online",p),window.removeEventListener("focus",p)}},[e]);const c=oo(n),l=g=>{i(!1),g().catch(()=>i(!0))},x=window.ogb?.cloudAdd?.reopen,f={retry:()=>e.retry().then(g=>o(g)),...t?{manage:t,buy:t,card:t,continue:async()=>{x&&await x().catch(()=>!1)||await t()}}:{}},w=c.action&&c.action!=="sign-in"&&c.action!=="manage"?c.action:null,m=(n?.screen==="ended"||n?.screen==="payment")&&n.removable===!0&&typeof e.remove=="function";return r.jsx("main",{"data-home-screen":n?.screen??"opening",className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",style:{WebkitAppRegion:"drag"},children:r.jsxs("div",{className:"flex w-full max-w-[420px] flex-col items-start gap-3",style:{WebkitAppRegion:"no-drag"},children:[r.jsxs("p",{role:"status",className:"flex items-center gap-2 text-[20px] font-semibold",children:[c.busy&&r.jsx("span",{"aria-hidden":"true",className:"size-3.5 shrink-0 animate-spin rounded-full border-2 border-hairline border-t-accent"}),c.title]}),c.body&&r.jsx("p",{className:"text-[14px] leading-relaxed text-ink-secondary",children:c.body}),n?.screen==="setup"&&r.jsx(eo,{step:n.step??"reserving"}),c.reason&&r.jsx("p",{"data-home-reason":!0,className:"text-[13px] leading-relaxed text-ink-secondary",children:c.reason}),c.action==="sign-in"&&r.jsx("button",{type:"button",className:"ui-button ui-button-primary mt-2",onClick:()=>l(()=>e.signIn()),children:s("homeScreen.signInButton")}),c.action==="manage"&&t&&r.jsx("button",{type:"button",className:"ui-button mt-2",onClick:()=>l(t),children:s("cloudAccount.manageInBrowser")}),w&&f[w]&&r.jsx("button",{type:"button","data-home-action":w,className:w==="retry"?"ui-button mt-2":"ui-button ui-button-primary mt-2",onClick:()=>l(f[w]),children:s(ro[w])}),m&&r.jsx(ao,{name:n.name??s("cloudSetup.myCloud"),remove:()=>e.remove()}),a&&r.jsx("p",{role:"alert",className:"text-[13px] text-danger",children:s("cloudAccount.actionFailed")})]})})}function io({bridge:e,fallback:t}){const[n,o]=u.useState(!1);return u.useEffect(()=>{e.repair().catch(()=>o(!0))},[e]),n?r.jsx(r.Fragment,{children:t}):r.jsx("main",{"data-home-screen":"opening",className:"flex min-h-screen items-center justify-center bg-app px-6 text-ink",children:r.jsx("p",{role:"status",className:"w-full max-w-[420px] text-[20px] font-semibold",children:s("homeScreen.opening")})})}const Ee="omb.session-ended";let he=!1,ce=null;const xe=new Set;function Bo(){he||ce||(ce=ne().then(e=>{if(e.kind==="unauthenticated"){he=!0;try{sessionStorage.setItem(Ee,"1")}catch{}for(const t of xe)t()}}).finally(()=>{ce=null}))}function Ye(){return he}function Fo(){return u.useSyncExternalStore(e=>(xe.add(e),()=>xe.delete(e)),Ye,Ye)}function lo(){try{return sessionStorage.getItem(Ee)==="1"}catch{return!1}}function co(){try{sessionStorage.removeItem(Ee)}catch{}}$t();ge(Ht());Mt(Dt());nn();zt(Bt());wn();const J=Ft(),uo=new Set(["/home","/pair","/desktop-viewer"]),bt=()=>Qe(()=>import("./App-Cbkqngwr.js").then(e=>e.jV),__vite__mapDeps([0,1,2,3,4,5])).catch(e=>({default:()=>{throw e}})),mo=uo.has(location.pathname)?null:bt(),po=()=>fetch("/.well-known/openmausbot/environment").then(e=>e.json()).then(e=>e.capabilities?.cloudTeam===!0&&typeof e.label=="string"?e.label:null,()=>null);async function fo(){const e=window.ogb?.home;if(location.pathname==="/home"&&e)return r.jsx(so,{bridge:e,manage:window.ogb?.cloudPlan?.manage});if(location.pathname==="/pair"){const o=qt();if(o){const a=await Zt(o);return await J,a?r.jsx(vn,{credential:o,owner:a.owner,team:a.team}):r.jsx(X,{initialCode:null,reason:s("pair.browser.signInFailed")})}return r.jsx(X,{initialCode:Yt(),initialEmail:Jt()})}const t=await ne();if(t.kind==="unauthenticated"){if(await J,t.error===Qn)return r.jsx(Zn,{team:await po()});const o=r.jsx(X,{initialCode:null,reason:lo()?s("pair.sessionEnded"):t.error});return e?r.jsx(io,{bridge:e,fallback:o}):o}if(co(),t.kind==="session"&&Vt(t.teamSignIn),t.kind==="loopback"&&t.trust==="service")return await J,r.jsx(X,{initialCode:null,reason:s("pair.serviceTrust")});if(location.pathname==="/desktop-viewer"){const{DesktopViewer:o}=await Qe(async()=>{const{DesktopViewer:a}=await import("./DesktopViewer-B0jszxk4.js");return{DesktopViewer:a}},__vite__mapDeps([6,1,2,7,8,5,4,9]));return r.jsx(o,{})}const{default:n}=await(mo??bt());return we(),r.jsx(n,{})}document.title=H();Promise.all([Ut(),fo(),J]).then(([,e])=>{Wt.createRoot(document.getElementById("root")).render(r.jsx(u.StrictMode,{children:r.jsx(Kt,{children:e})}))});export{Po as A,bo as B,eo as C,Co as D,No as E,En as F,An as G,To as H,_o as I,Sn as J,de as K,Eo as L,zo as M,Fo as N,X as O,Io as P,Do as Q,Nn as S,at as T,Ln as a,Mo as b,xn as c,yn as d,jo as e,So as f,Lo as g,vo as h,tt as i,jn as j,Se as k,we as l,$o as m,Bo as n,Pn as o,Oo as p,xo as q,ne as r,wo as s,go as t,yo as u,Ho as v,ko as w,Ro as x,_n as y,Ao as z};
|