@forsion/unit 2.13.0 → 2.13.1
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/main.mjs +5 -3
- package/package.json +1 -1
- package/release.json +5 -5
- package/web/assets/{ArtificialView-BSv3Mx5C.js → ArtificialView-XwHMLUFb.js} +1 -1
- package/web/assets/{AutomationBuilder-BuiHtVB-.js → AutomationBuilder-hqs0QhMt.js} +1 -1
- package/web/assets/{CalendarConfigView-BJtG6cqN.js → CalendarConfigView-DKib8Oed.js} +1 -1
- package/web/assets/{CalendarView-C-FX1RED.js → CalendarView-DJ5iOzvu.js} +1 -1
- package/web/assets/{CapabilityMenu-kx1TIJYN.js → CapabilityMenu-SwVlZ06x.js} +1 -1
- package/web/assets/{CheckboxInput-eW7xdiRS.js → CheckboxInput-BC-5a_C9.js} +1 -1
- package/web/assets/{Chrome-B77-lQyh.js → Chrome-HdfyYV3i.js} +1 -1
- package/web/assets/{CodeView-Df3AiSIi.js → CodeView-CFL6yQ-6.js} +3 -3
- package/web/assets/{DashboardGridView-MlO1dpuo.js → DashboardGridView-B9DCWYVb.js} +12 -12
- package/web/assets/{EventCard-CDmeCbI8.js → EventCard-B_ndpqH_.js} +1 -1
- package/web/assets/{ExcalidrawCanvas-D9vkBh_5.js → ExcalidrawCanvas-BQ4KKLJP.js} +1 -1
- package/web/assets/{FloatingToc-tART_jC4.js → FloatingToc-Ce9GamvH.js} +1 -1
- package/web/assets/{HomepageView-Trqmd3RV.js → HomepageView-RCOfcVbE.js} +1 -1
- package/web/assets/{ImageStudioPanels-BfCVTnKC.js → ImageStudioPanels-lkS_y2uM.js} +2 -2
- package/web/assets/{ImageStudioView-KJhx0wJk.js → ImageStudioView-UPv52acl.js} +1 -1
- package/web/assets/{InlineFiles-BHwivGbQ.js → InlineFiles-CQbQumkf.js} +1 -1
- package/web/assets/{MarkdownBlock-D8LgHFYY.js → MarkdownBlock-CkqiwPXa.js} +19 -19
- package/web/assets/{ModelPill-DrW2cG0l.js → ModelPill-CY-rU1RU.js} +2 -2
- package/web/assets/{MuseLibraryView-CW78Uivf.js → MuseLibraryView-CtTHlVnT.js} +2 -2
- package/web/assets/{MuseView-Cb6R_l4i.js → MuseView-CC2A7MBs.js} +2 -2
- package/web/assets/{PageHistoryPanel-BQs9IWTP.js → PageHistoryPanel-KhKT1DLy.js} +2 -2
- package/web/assets/{PdfAnnotator-BFTBkxvO.js → PdfAnnotator-DUyrgY-t.js} +1 -1
- package/web/assets/{ProductView-mB-S0j81.js → ProductView-CgsIYZqD.js} +1 -1
- package/web/assets/{RightPanel-BVZeVO3c.js → RightPanel-BHDgqTFs.js} +3 -3
- package/web/assets/RunLocationPicker-DBnXYV5B.js +38 -0
- package/web/assets/{SidebarRow-D77yrSLf.js → SidebarRow-BAJxbMcx.js} +1 -1
- package/web/assets/{SketchCard-CAAr_cqF.js → SketchCard-BGYz-bXP.js} +1 -1
- package/web/assets/{StudioGuestSurface-DthpuVGg.js → StudioGuestSurface-lt6znmkl.js} +1 -1
- package/web/assets/{TodoListView-C3ZkMIIf.js → TodoListView-DPKhee6i.js} +1 -1
- package/web/assets/{Tooltip-D9Dt9ZTr.js → Tooltip-ZxrDqN4p.js} +1 -1
- package/web/assets/{UnifiedPage-C75y-MKT.js → UnifiedPage-BX6ZQL0h.js} +27 -27
- package/web/assets/{amadeus-manual.en-D5wZKuag.js → amadeus-manual.en-DzRWr4BL.js} +15 -15
- package/web/assets/{amadeus-manual.zh-Br5fidrj.js → amadeus-manual.zh-DW32DkL7.js} +15 -15
- package/web/assets/{appStore-B1ynyt42.js → appStore-DWP8UET9.js} +99 -79
- package/web/assets/appStore-wtOILggO.css +1 -0
- package/web/assets/{arrow-up-right-R10mR2I6.js → arrow-up-right-DrCXuWS7.js} +1 -1
- package/web/assets/{astryxBridge-CU_kQTEl.js → astryxBridge-D-m4_kYt.js} +3 -3
- package/web/assets/{automationListSource-B8EIRmDW.js → automationListSource-C8BNy6RY.js} +1 -1
- package/web/assets/{book-open-DBJ3dDpw.js → book-open-OLNm7OaB.js} +1 -1
- package/web/assets/{calendarNavStore-DGvUlU5N.js → calendarNavStore-Cylfvv3s.js} +1 -1
- package/web/assets/{canvasPrefs-DwL_OAAo.js → canvasPrefs-8taQ42Cz.js} +1 -1
- package/web/assets/{chatBoxSurface-Lq-2qfd3.js → chatBoxSurface-CIlzs45H.js} +1 -1
- package/web/assets/{circle-question-mark-HPZpZQxd.js → circle-question-mark-XbAFplz1.js} +1 -1
- package/web/assets/{circle-x-BZfe7d6S.js → circle-x-fcReAZaE.js} +1 -1
- package/web/assets/{client-DxGbwZLy.js → client-0MPbodA6.js} +1 -1
- package/web/assets/{code-xml-joKQ-qGS.js → code-xml-Cuna8Kh4.js} +1 -1
- package/web/assets/{codeStudioStore-C7rGKlOC.js → codeStudioStore-BBU62GTy.js} +1 -1
- package/web/assets/{codingNavigation-CjeWG4xm.js → codingNavigation-DDlPpPk5.js} +7 -7
- package/web/assets/{create-BjBRKATq.js → create-BGtEfCcg.js} +2 -2
- package/web/assets/{dashboardSurface-Cojgf_-U.js → dashboardSurface-BYM3C7WG.js} +1 -1
- package/web/assets/{deskCapture-DnGWk1iq.js → deskCapture-BiUCmqfc.js} +1 -1
- package/web/assets/{diff2html-Cd1rVi_Z.js → diff2html-BNp2FTbk.js} +1 -1
- package/web/assets/{docx-preview-CK0k1mUD.js → docx-preview-CFznGVOU.js} +1 -1
- package/web/assets/{emoji-Cjm3bKiF.js → emoji-6zl4yfOS.js} +1 -1
- package/web/assets/{floatingTocSurface-Dd1pT5j5.js → floatingTocSurface-DreXPCa6.js} +1 -1
- package/web/assets/{foldActions-Dm-uAt3L.js → foldActions-05QcQziQ.js} +1 -1
- package/web/assets/{folder-CvZyHIgb.js → folder-BpsfOHD4.js} +1 -1
- package/web/assets/{folder-plus-BRScGQ9m.js → folder-plus-BeQHr4AZ.js} +1 -1
- package/web/assets/{gestures-CZQVefU0.js → gestures-DQBCcK4y.js} +1 -1
- package/web/assets/{hand-D3QspKYq.js → hand-Bko7ms15.js} +1 -1
- package/web/assets/{hard-drive-BQsHSala.js → hard-drive-BpuI5ebj.js} +1 -1
- package/web/assets/{i18n.generated-BZRHO2Nc.js → i18n.generated-BuLjnmY8.js} +1 -1
- package/web/assets/{imageStudio-Cy3_437s.js → imageStudio-BLVNKmEG.js} +2 -2
- package/web/assets/{index-BPhwi4-v.js → index-BF10xp_K.js} +1 -1
- package/web/assets/{index-GjLSlygt.js → index-BHm6K743.js} +1 -1
- package/web/assets/{index-Bh_nLVTc.js → index-BM2o7PeV.js} +5 -5
- package/web/assets/{index-BcVGjCAJ.js → index-BgnNNv3e.js} +1 -1
- package/web/assets/{index-CcOag8eb.js → index-C0Gy2NQ6.js} +1 -1
- package/web/assets/{index-0AYHATDX.js → index-C1doZp5H.js} +1 -1
- package/web/assets/{index-9BmmlTjY.js → index-C4L6vjd_.js} +1 -1
- package/web/assets/{index-8ag1K7AZ.js → index-CD3yIkOA.js} +1 -1
- package/web/assets/{index-Dkd-nl1u.js → index-CJeUgjPU.js} +1 -1
- package/web/assets/{index-B5GxvbNm.js → index-CLHoq1w-.js} +1 -1
- package/web/assets/{index-DElrDw66.js → index-CUZI62qU.js} +1 -1
- package/web/assets/{index-BgtO11q8.js → index-Cff42k7q.js} +1 -1
- package/web/assets/{index-Dj-PygjB.js → index-Ck_O3Jdd.js} +1 -1
- package/web/assets/index-CuiYK18N.js +1 -0
- package/web/assets/{index-Bpc3R3DS.js → index-CwcOeZdT.js} +1 -1
- package/web/assets/{index-DJLWTPtq.js → index-D6AycQIz.js} +1 -1
- package/web/assets/{index-C9yo04Ck.js → index-D7gVhvNY.js} +1 -1
- package/web/assets/{index-BnWj6ggb.js → index-D9UZQy42.js} +1 -1
- package/web/assets/{index-D6mpAJ9S.js → index-DuBQ0j2g.js} +1 -1
- package/web/assets/{index-1FhRiJ_X.js → index-OD1gSX3h.js} +1 -1
- package/web/assets/{index-DNE_PBJt.js → index-Uo5tswys.js} +1 -1
- package/web/assets/{index-BgDZGDqt.js → index-o8cj0pRH.js} +1 -1
- package/web/assets/{index-BdZaheMZ.js → index-rHjhbwvm.js} +1 -1
- package/web/assets/{index-4E9nrhwf.js → index-rggq2czF.js} +1 -1
- package/web/assets/{index-D0FLFLfh.js → index-sCXThwqZ.js} +1 -1
- package/web/assets/{invitePage-B4gMvEKi.js → invitePage-b0HGvMj6.js} +1 -1
- package/web/assets/{ipc-CPhL3bPp.js → ipc-CxAyeo8q.js} +1 -1
- package/web/assets/{jszip.min-DAJT9RUA.js → jszip.min-B94KpE21.js} +1 -1
- package/web/assets/{layout-grid-DfUfnvDS.js → layout-grid-BBVuEdWG.js} +1 -1
- package/web/assets/{linkFollow-C6PHGUxk.js → linkFollow-B7ivDZMM.js} +5 -5
- package/web/assets/{list-tree-DaGpnIYu.js → list-tree-4-0QDbLu.js} +1 -1
- package/web/assets/{listFold-Q_8mh5ZG.js → listFold-DLuxXiIj.js} +1 -1
- package/web/assets/{lock-DQ_yL4nF.js → lock-CnbZm4vo.js} +1 -1
- package/web/assets/{log-out-DFwTeh2X.js → log-out-BEynWaHa.js} +1 -1
- package/web/assets/{main-NgUPPqDn.css → main-BiS_5wrB.css} +1 -1
- package/web/assets/main-sIq2N9Z5.js +20 -0
- package/web/assets/{markdownEditorSurface-e_oMhqx-.js → markdownEditorSurface-ZSJ3RHAv.js} +1 -1
- package/web/assets/{mdMarkStore-DjN4bf1T.js → mdMarkStore-DQHDjG7s.js} +2 -2
- package/web/assets/{mdMarks-cmL6vzR-.js → mdMarks-DbIcRa0O.js} +1 -1
- package/web/assets/{message-square-plus-CEHkduIL.js → message-square-plus-CpiKDvle.js} +1 -1
- package/web/assets/{messages-CBtmbpur.js → messages-_jta1lSI.js} +1 -1
- package/web/assets/minus-C9ndHJ9O.js +1 -0
- package/web/assets/{mobileEntry-qR7BAROr.js → mobileEntry-CPmU_c4m.js} +1 -1
- package/web/assets/{nativeDownload-CziEyW_p.js → nativeDownload-BYT082bY.js} +1 -1
- package/web/assets/{pageChrome-DFz_AAzZ.js → pageChrome-D3Niv1JM.js} +1 -1
- package/web/assets/{pageTree-yVO1_fSy.js → pageTree-CgfvpzIj.js} +1 -1
- package/web/assets/{pen-tool-uxsFELYC.js → pen-tool-BXEFnU2i.js} +1 -1
- package/web/assets/{pencil-BSbra1Ra.js → pencil-cqvCkekG.js} +1 -1
- package/web/assets/pluginChat-BbBukMuN.js +2 -0
- package/web/assets/{redo-2-BK5LMNa5.js → redo-2-BO7wCDwy.js} +1 -1
- package/web/assets/{rotate-ccw-HedfU4na.js → rotate-ccw-BvipPIjC.js} +1 -1
- package/web/assets/{sharePage-CpzDpuU1.js → sharePage-XbN50US7.js} +2 -2
- package/web/assets/{shareViewer-BwzH2bIs.js → shareViewer-BaYogetW.js} +1 -1
- package/web/assets/{star-CgYon3z4.js → star-BQWMXnn7.js} +1 -1
- package/web/assets/tableSurface-BXqqidd1.js +1 -0
- package/web/assets/{terminal-krsPf1mc.js → terminal-l9k6RDrH.js} +1 -1
- package/web/assets/{terminalView-4e2_u5_I.js → terminalView-Cpnt5_0P.js} +1 -1
- package/web/assets/{type-GJYLEhY-.js → type-CFoaj2eD.js} +1 -1
- package/web/assets/{undo-2-DCTs4Ro4.js → undo-2-DusxpdLa.js} +1 -1
- package/web/assets/{unitAccount-D3xjX3cu.js → unitAccount-DwutFPPw.js} +1 -1
- package/web/assets/{unitBridge-D5JcIkAP.js → unitBridge-CcgQpkqV.js} +1 -1
- package/web/assets/{unitCloudTransport-B44L3x6M.js → unitCloudTransport-vA7cLDts.js} +1 -1
- package/web/assets/{unitOwnerAccess-CRUHWGpf.js → unitOwnerAccess-LBlJ1YfA.js} +1 -1
- package/web/assets/{unitShim-_VzxvdEG.js → unitShim-B_M9IrbC.js} +3 -3
- package/web/assets/{upload-MVVRQtkj.js → upload-ZrOj6tXA.js} +1 -1
- package/web/assets/{userSpaces-CI4eqEgh.js → userSpaces-uJOnsedR.js} +1 -1
- package/web/assets/viewportLock-D3SNkwS2.js +631 -0
- package/web/assets/{workflow-DzeW9OXR.js → workflow-DPoG4QE2.js} +1 -1
- package/web/assets/{zoom-in-CovPsw4g.js → zoom-in-lbTgzdQP.js} +1 -1
- package/web/index.html +27 -7
- package/web/assets/RunLocationPicker-CyVa0RJa.js +0 -38
- package/web/assets/appStore-BC_CQv-L.css +0 -1
- package/web/assets/index-BaRySZ-M.js +0 -1
- package/web/assets/main-CwqZ_ymb.js +0 -19
- package/web/assets/minus-BUT48dAC.js +0 -1
- package/web/assets/pluginChat-BMFnf_j2.js +0 -2
- package/web/assets/tableSurface-CmDwnKnd.js +0 -1
- package/web/assets/viewportLock-BH26xHQO.js +0 -611
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as K,b as H,fp as W,dk as L,bo as q,ah as B,aE as J,km as Q,dA as V,R as X,Y as Z,aJ as ee,nP as te}from"./appStore-B1ynyt42.js";import{u as F,d as c,q as re,j as e,b2 as G,aO as ae,r as oe}from"./index-Bh_nLVTc.js";import"./client-DxGbwZLy.js";import{E as _,a as se,b as ce}from"./emoji-Cjm3bKiF.js";import{U as O}from"./upload-MVVRQtkj.js";const ne=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],fe=K("info",ne);const ie=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 14s1.5 2 4 2 4-2 4-2",key:"1y1vjs"}],["line",{x1:"9",x2:"9.01",y1:"9",y2:"9",key:"yxxnd0"}],["line",{x1:"15",x2:"15.01",y1:"9",y2:"9",key:"1p4y9e"}]],ke=K("smile",ie);oe({"pgchrome.coverDragHint":{zh:"上下拖动图片调整位置",en:"Drag the image up or down to reposition"},"pgchrome.coverDone":{zh:"完成",en:"Done"},"pgchrome.coverChange":{zh:"更换封面",en:"Change cover"},"pgchrome.coverReposition":{zh:"调整位置",en:"Reposition"},"pgchrome.coverRemove":{zh:"移除",en:"Remove"},"pgchrome.coverTitle":{zh:"封面",en:"Cover"},"pgchrome.close":{zh:"关闭封面选择器",en:"Close cover picker"},"pgchrome.featured":{zh:"精选图片",en:"Featured images"},"pgchrome.results":{zh:"搜索结果",en:"Search results"},"pgchrome.chooseCover":{zh:"选择封面 {index}",en:"Choose cover {index}"},"pgchrome.imageUrl":{zh:"图片链接",en:"Image URL"},"pgchrome.urlHint":{zh:"使用公开可访问的图片链接。",en:"Use a publicly accessible image URL."},"pgchrome.uploadTitle":{zh:"上传封面图片",en:"Upload a cover image"},"pgchrome.tabGallery":{zh:"图库",en:"Gallery"},"pgchrome.tabUrl":{zh:"链接",en:"Link"},"pgchrome.tabUpload":{zh:"上传",en:"Upload"},"pgchrome.searchPlaceholder":{zh:"搜索图片…",en:"Search images…"},"pgchrome.search":{zh:"搜索",en:"Search"},"pgchrome.searchUnavailable":{zh:"图库接口暂不可达,可从上方精选挑,或用「链接/上传」。",en:"The image library is unreachable right now — pick a featured cover above, or use Link or Upload."},"pgchrome.searchEmpty":{zh:"没搜到结果,上方为精选封面。",en:"No results — the covers above are our featured picks."},"pgchrome.urlPlaceholder":{zh:"粘贴图片地址(https://…)",en:"Paste an image URL (https://…)"},"pgchrome.setCover":{zh:"设为封面",en:"Set as cover"},"pgchrome.chooseLocal":{zh:"选择本地图片…",en:"Choose a local image…"},"pgchrome.uploadHint":{zh:"图片会保存到当前智库的附件位置。",en:"Images are saved with attachments in this vault."},"pgchrome.emojiPlaceholder":{zh:"搜索 emoji(中/英),或粘贴任意字符后回车…",en:"Search emoji (Chinese or English), or paste any character and press Enter…"},"pgchrome.emojiEmpty":{zh:"没有匹配的 emoji —— 回车可直接用你输入的字符",en:"No matching emoji — press Enter to use what you typed"},"pgchrome.removeIcon":{zh:"移除图标",en:"Remove icon"}});const be=/^(未命名|untitled)(-\d+)?$/i;function le(){const n=H(s=>s.manifest?.fmExtra??"");return c.useMemo(()=>{const s=G(n).cover;return typeof s=="string"&&s.trim()?s.trim():null},[n])}function me(){const n=H(s=>s.manifest?.fmExtra??"");return c.useMemo(()=>{const s=G(n).cover_y,p=typeof s=="number"?s:typeof s=="string"?parseFloat(s):NaN;return Number.isFinite(p)?Math.max(0,Math.min(100,p)):50},[n])}function A(n){const s=n.naturalWidth,p=n.naturalHeight,h=n.clientWidth,d=n.clientHeight;return!s||!p||!h||!d?0:p*Math.max(h/s,d/p)-d}function ye({page:n,cover:s,coverY:p,onSetCover:h,onSetCoverY:d,readOnly:a=!1}={}){const{t:u}=F(),I=H(r=>r.activePage),m=le(),i=me(),g=W(),[z,j]=c.useState(null),[D,N]=c.useState(null),[x,P]=c.useState(!1),[R,f]=c.useState(0),M=c.useRef(null),E=c.useRef(null),k=n??I;c.useEffect(()=>{const r=M.current;if(!r)return;const o=()=>f(A(r));o();const t=new ResizeObserver(o);return t.observe(r),()=>t.disconnect()},[k,s,m]),c.useEffect(()=>{x&&R<1&&P(!1)},[x,R]);const v=s!==void 0?s:m,w=D??(p??i),C=h??(r=>{k&&g.getState().setPageCover(k,r)}),U=d??(r=>{k&&g.getState().setPageCoverY(k,r)});if(!k||!v)return null;const T=/^https?:\/\//i.test(v)?v:re(v);return e.jsxs("div",{className:`amx-cover${x?" amx-cover-repo":""}`,children:[e.jsx("img",{ref:M,src:T,alt:"",draggable:!1,style:{objectPosition:`50% ${w}%`},onLoad:r=>f(A(r.currentTarget)),onPointerDown:r=>{if(!x||!r.isPrimary||r.pointerType==="mouse"&&r.button!==0)return;const o=A(r.currentTarget);if(o<1)return;r.preventDefault(),r.currentTarget.setPointerCapture(r.pointerId);const t=r.currentTarget.currentCSSZoom||1;E.current={id:r.pointerId,startY:r.clientY,base:w,z:t,slack:o,cur:w}},onPointerMove:r=>{const o=E.current;if(!o||o.id!==r.pointerId)return;const t=(r.clientY-o.startY)/o.z;o.cur=Math.max(0,Math.min(100,o.base-t/o.slack*100)),N(o.cur)},onPointerUp:r=>{const o=E.current;if(!o||o.id!==r.pointerId)return;E.current=null,N(null);const t=Math.round(o.cur*10)/10;t!==o.base&&U(t)},onPointerCancel:()=>{E.current=null,N(null)},onError:r=>{r.target.style.opacity="0.15"}}),e.jsx("div",{className:"amx-cover-grad"}),x&&e.jsx("div",{className:"amx-cover-hint",children:u("pgchrome.coverDragHint")}),!a&&e.jsx("div",{className:"amx-cover-tools",children:x?e.jsx("button",{onClick:()=>P(!1),children:u("pgchrome.coverDone")}):e.jsxs(e.Fragment,{children:[e.jsx("button",{onClick:r=>{const o=r.currentTarget.getBoundingClientRect();j({x:o.right,y:o.bottom+6})},children:u("pgchrome.coverChange")}),R>=1&&e.jsx("button",{onClick:()=>P(!0),children:u("pgchrome.coverReposition")}),e.jsx("button",{onClick:()=>C(null),children:u("pgchrome.coverRemove")})]})}),z&&e.jsx(pe,{page:k,x:z.x,y:z.y,onApply:h??void 0,onClose:()=>j(null)})]})}const he=["aurora","forest","ocean","alpine","metro","night","coast","mist","valley","dune","lake","bloom"].map(n=>({thumb:`https://picsum.photos/seed/${n}/320/180`,full:`https://picsum.photos/seed/${n}/1600/900`,source:"Picsum"}));function pe({page:n,x:s,y:p,onClose:h,onApply:d}){const{t:a}=F(),u=!!L.searchImages,I=W(),[m,i]=c.useState("gallery"),[g,z]=c.useState(""),[j,D]=c.useState(null),[N,x]=c.useState(!1),[P,R]=c.useState(!1),[f,M]=c.useState(""),[E,k]=c.useState(null),v=c.useId(),$=c.useRef([]),w=c.useRef(h);w.current=h,c.useEffect(()=>{const t=document.activeElement instanceof HTMLElement?document.activeElement:null,l=b=>{b.key==="Escape"&&(b.preventDefault(),b.stopPropagation(),w.current())};return document.addEventListener("keydown",l,!0),()=>{document.removeEventListener("keydown",l,!0),t?.isConnected&&t.focus({preventScroll:!0})}},[]);const C=[{id:"gallery",label:"pgchrome.tabGallery",icon:Q},{id:"url",label:"pgchrome.tabUrl",icon:V},{id:"upload",label:"pgchrome.tabUpload",icon:O}],U=t=>{k(t),d?d(t):I.getState().setPageCover(n,t)},T=()=>{const t=g.trim();!t||!L.searchImages||(x(!0),R(!1),L.searchImages(t).then(l=>{D(l),x(!1)}).catch(()=>{D(null),R(!0),x(!1)}))},r=()=>{const t=document.createElement("input");t.type="file",t.accept="image/*",t.onchange=()=>{const l=t.files?.[0];l&&(async()=>{try{const b=new Uint8Array(await l.arrayBuffer()),{opts:S}=await te(),{pageRel:y}=await L.saveAttachment(n,l.name||"cover.png",b,S);U(ae(n.split("/").slice(0,-1).join("/"),y))}catch{}})()},t.click()},o=t=>e.jsx("div",{className:"amx-coverpick-grid",children:t.map((l,b)=>e.jsxs("button",{className:"amx-coverpick-item","aria-label":a("pgchrome.chooseCover",{index:b+1}),"aria-pressed":E===l.full,onClick:()=>U(l.full),children:[e.jsxs("span",{className:"amx-coverpick-thumb",children:[e.jsx(Z,{size:20,strokeWidth:1.7,"aria-hidden":"true"}),e.jsx("img",{src:l.thumb,alt:"",loading:"lazy",onError:S=>{S.currentTarget.hidden=!0}}),E===l.full&&e.jsx("span",{className:"amx-coverpick-selected",children:e.jsx(ee,{size:14,"aria-hidden":"true"})})]}),l.author&&e.jsx("span",{className:"amx-coverpick-cap",children:l.author})]},l.full))});return q.createPortal(e.jsx("div",{className:"ui-popover-backdrop am-app",onMouseDown:h,children:e.jsxs(B,{className:"ui-popover amx-coverpick",role:"dialog","aria-label":a("pgchrome.coverTitle"),x:s-336,y:p,onMouseDown:t=>t.stopPropagation(),children:[e.jsxs("div",{className:"amx-coverpick-header",children:[e.jsx("span",{children:a("pgchrome.coverTitle")}),e.jsx("button",{className:"amx-coverpick-close",onClick:h,"aria-label":a("pgchrome.close"),children:e.jsx(J,{size:14,strokeWidth:1.7,"aria-hidden":"true"})})]}),e.jsx("div",{className:"amx-coverpick-tabs",role:"tablist","aria-label":a("pgchrome.coverTitle"),children:C.map(({id:t,label:l,icon:b},S)=>e.jsxs("button",{ref:y=>{$.current[S]=y},id:`${v}-${t}`,role:"tab","aria-selected":m===t,"aria-controls":v,tabIndex:m===t?0:-1,onClick:()=>i(t),onKeyDown:y=>{const Y=y.key==="ArrowRight"?(S+1)%C.length:y.key==="ArrowLeft"?(S+C.length-1)%C.length:y.key==="Home"?0:y.key==="End"?C.length-1:-1;Y<0||(y.preventDefault(),i(C[Y].id),$.current[Y]?.focus())},children:[e.jsx(b,{size:14,strokeWidth:1.7,"aria-hidden":"true"}),a(l)]},t))}),e.jsxs("div",{id:v,role:"tabpanel","aria-labelledby":`${v}-${m}`,className:"amx-coverpick-panel",children:[m==="gallery"&&e.jsxs("div",{className:"amx-coverpick-body",children:[u&&e.jsxs("div",{className:"amx-coverpick-search",children:[e.jsx(X,{size:14,strokeWidth:1.7,"aria-hidden":"true"}),e.jsx("input",{"aria-label":a("pgchrome.searchPlaceholder"),placeholder:a("pgchrome.searchPlaceholder"),value:g,onChange:t=>z(t.target.value),onKeyDown:t=>{t.key==="Enter"&&T()}}),e.jsx("button",{className:"amx-coverpick-go",disabled:N||!g.trim(),onClick:T,children:N?"…":a("pgchrome.search")})]}),e.jsx("div",{className:"amx-coverpick-section",children:a(j?.length?"pgchrome.results":"pgchrome.featured")}),o(j&&j.length>0?j:he),!N&&P&&e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.searchUnavailable")}),!N&&!P&&j?.length===0&&e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.searchEmpty")})]}),m==="url"&&e.jsxs("div",{className:"amx-coverpick-body amx-coverpick-url",children:[e.jsx("label",{htmlFor:`${v}-url-input`,children:a("pgchrome.imageUrl")}),e.jsx("input",{id:`${v}-url-input`,placeholder:a("pgchrome.urlPlaceholder"),value:f,onChange:t=>M(t.target.value),onKeyDown:t=>{t.key==="Enter"&&/^https?:\/\//i.test(f.trim())&&U(f.trim())}}),e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.urlHint")}),e.jsx("button",{className:"amx-coverpick-go",disabled:!/^https?:\/\//i.test(f.trim()),onClick:()=>{/^https?:\/\//i.test(f.trim())&&U(f.trim())},children:a("pgchrome.setCover")})]}),m==="upload"&&e.jsxs("div",{className:"amx-coverpick-body amx-coverpick-upload",children:[e.jsx(O,{size:24,strokeWidth:1.5,"aria-hidden":"true"}),e.jsx("div",{className:"amx-coverpick-upload-title",children:a("pgchrome.uploadTitle")}),e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.uploadHint")}),e.jsx("button",{className:"amx-coverpick-go",onClick:r,children:a("pgchrome.chooseLocal")})]})]})]})}),document.body)}const je=()=>_[Math.floor(Math.random()*_.length)];function Ne({x:n,y:s,current:p,onPick:h,onClose:d}){const{t:a}=F(),[u,I]=c.useState(""),m=se(u);return e.jsx("div",{className:"amx-db-popwrap",onMouseDown:d,children:e.jsxs(B,{className:"amx-db-pop amx-iconpick",x:n,y:s,onMouseDown:i=>i.stopPropagation(),children:[e.jsx("input",{className:"amx-db-pop-input",autoFocus:!0,placeholder:a("pgchrome.emojiPlaceholder"),value:u,onChange:i=>I(i.target.value),onKeyDown:i=>{if(i.key==="Escape"){d();return}i.key!=="Enter"||!u.trim()||h(m&&m.length?m[0]:u.trim())}}),e.jsxs("div",{className:"amx-iconpick-grid",children:[m?m.map(i=>e.jsx("button",{className:`amx-iconpick-item${p===i?" active":""}`,onClick:()=>h(i),children:i},i)):ce.map(i=>e.jsxs(c.Fragment,{children:[e.jsx("div",{className:"amx-iconpick-group",children:a(i.nameKey)}),i.items.map(([g,z])=>e.jsx("button",{className:`amx-iconpick-item${p===g?" active":""}`,title:z,onClick:()=>h(g),children:g},`${i.nameKey}-${g}`))]},i.nameKey)),m&&m.length===0&&e.jsx("div",{className:"amx-iconpick-empty",children:a("pgchrome.emojiEmpty")})]}),p&&e.jsx("button",{className:"amx-db-opt amx-db-opt-clear",onClick:()=>h(null),children:a("pgchrome.removeIcon")})]})})}export{pe as C,fe as I,ye as N,ke as S,be as U,Ne as a,je as r,le as u};
|
|
1
|
+
import{F as K,b as H,fr as W,dl as L,bp as q,ah as B,aE as J,ko as Q,dB as V,R as X,Y as Z,aJ as ee,nR as te}from"./appStore-DWP8UET9.js";import{u as F,d as c,q as re,j as e,b2 as G,aO as ae,r as oe}from"./index-BM2o7PeV.js";import"./client-0MPbodA6.js";import{E as _,a as se,b as ce}from"./emoji-6zl4yfOS.js";import{U as O}from"./upload-ZrOj6tXA.js";const ne=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],fe=K("info",ne);const ie=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 14s1.5 2 4 2 4-2 4-2",key:"1y1vjs"}],["line",{x1:"9",x2:"9.01",y1:"9",y2:"9",key:"yxxnd0"}],["line",{x1:"15",x2:"15.01",y1:"9",y2:"9",key:"1p4y9e"}]],ke=K("smile",ie);oe({"pgchrome.coverDragHint":{zh:"上下拖动图片调整位置",en:"Drag the image up or down to reposition"},"pgchrome.coverDone":{zh:"完成",en:"Done"},"pgchrome.coverChange":{zh:"更换封面",en:"Change cover"},"pgchrome.coverReposition":{zh:"调整位置",en:"Reposition"},"pgchrome.coverRemove":{zh:"移除",en:"Remove"},"pgchrome.coverTitle":{zh:"封面",en:"Cover"},"pgchrome.close":{zh:"关闭封面选择器",en:"Close cover picker"},"pgchrome.featured":{zh:"精选图片",en:"Featured images"},"pgchrome.results":{zh:"搜索结果",en:"Search results"},"pgchrome.chooseCover":{zh:"选择封面 {index}",en:"Choose cover {index}"},"pgchrome.imageUrl":{zh:"图片链接",en:"Image URL"},"pgchrome.urlHint":{zh:"使用公开可访问的图片链接。",en:"Use a publicly accessible image URL."},"pgchrome.uploadTitle":{zh:"上传封面图片",en:"Upload a cover image"},"pgchrome.tabGallery":{zh:"图库",en:"Gallery"},"pgchrome.tabUrl":{zh:"链接",en:"Link"},"pgchrome.tabUpload":{zh:"上传",en:"Upload"},"pgchrome.searchPlaceholder":{zh:"搜索图片…",en:"Search images…"},"pgchrome.search":{zh:"搜索",en:"Search"},"pgchrome.searchUnavailable":{zh:"图库接口暂不可达,可从上方精选挑,或用「链接/上传」。",en:"The image library is unreachable right now — pick a featured cover above, or use Link or Upload."},"pgchrome.searchEmpty":{zh:"没搜到结果,上方为精选封面。",en:"No results — the covers above are our featured picks."},"pgchrome.urlPlaceholder":{zh:"粘贴图片地址(https://…)",en:"Paste an image URL (https://…)"},"pgchrome.setCover":{zh:"设为封面",en:"Set as cover"},"pgchrome.chooseLocal":{zh:"选择本地图片…",en:"Choose a local image…"},"pgchrome.uploadHint":{zh:"图片会保存到当前智库的附件位置。",en:"Images are saved with attachments in this vault."},"pgchrome.emojiPlaceholder":{zh:"搜索 emoji(中/英),或粘贴任意字符后回车…",en:"Search emoji (Chinese or English), or paste any character and press Enter…"},"pgchrome.emojiEmpty":{zh:"没有匹配的 emoji —— 回车可直接用你输入的字符",en:"No matching emoji — press Enter to use what you typed"},"pgchrome.removeIcon":{zh:"移除图标",en:"Remove icon"}});const be=/^(未命名|untitled)(-\d+)?$/i;function le(){const n=H(s=>s.manifest?.fmExtra??"");return c.useMemo(()=>{const s=G(n).cover;return typeof s=="string"&&s.trim()?s.trim():null},[n])}function me(){const n=H(s=>s.manifest?.fmExtra??"");return c.useMemo(()=>{const s=G(n).cover_y,p=typeof s=="number"?s:typeof s=="string"?parseFloat(s):NaN;return Number.isFinite(p)?Math.max(0,Math.min(100,p)):50},[n])}function A(n){const s=n.naturalWidth,p=n.naturalHeight,h=n.clientWidth,d=n.clientHeight;return!s||!p||!h||!d?0:p*Math.max(h/s,d/p)-d}function ye({page:n,cover:s,coverY:p,onSetCover:h,onSetCoverY:d,readOnly:a=!1}={}){const{t:u}=F(),I=H(r=>r.activePage),m=le(),i=me(),g=W(),[z,j]=c.useState(null),[D,N]=c.useState(null),[x,R]=c.useState(!1),[P,f]=c.useState(0),M=c.useRef(null),E=c.useRef(null),k=n??I;c.useEffect(()=>{const r=M.current;if(!r)return;const o=()=>f(A(r));o();const t=new ResizeObserver(o);return t.observe(r),()=>t.disconnect()},[k,s,m]),c.useEffect(()=>{x&&P<1&&R(!1)},[x,P]);const v=s!==void 0?s:m,w=D??(p??i),C=h??(r=>{k&&g.getState().setPageCover(k,r)}),U=d??(r=>{k&&g.getState().setPageCoverY(k,r)});if(!k||!v)return null;const T=/^https?:\/\//i.test(v)?v:re(v);return e.jsxs("div",{className:`amx-cover${x?" amx-cover-repo":""}`,children:[e.jsx("img",{ref:M,src:T,alt:"",draggable:!1,style:{objectPosition:`50% ${w}%`},onLoad:r=>f(A(r.currentTarget)),onPointerDown:r=>{if(!x||!r.isPrimary||r.pointerType==="mouse"&&r.button!==0)return;const o=A(r.currentTarget);if(o<1)return;r.preventDefault(),r.currentTarget.setPointerCapture(r.pointerId);const t=r.currentTarget.currentCSSZoom||1;E.current={id:r.pointerId,startY:r.clientY,base:w,z:t,slack:o,cur:w}},onPointerMove:r=>{const o=E.current;if(!o||o.id!==r.pointerId)return;const t=(r.clientY-o.startY)/o.z;o.cur=Math.max(0,Math.min(100,o.base-t/o.slack*100)),N(o.cur)},onPointerUp:r=>{const o=E.current;if(!o||o.id!==r.pointerId)return;E.current=null,N(null);const t=Math.round(o.cur*10)/10;t!==o.base&&U(t)},onPointerCancel:()=>{E.current=null,N(null)},onError:r=>{r.target.style.opacity="0.15"}}),e.jsx("div",{className:"amx-cover-grad"}),x&&e.jsx("div",{className:"amx-cover-hint",children:u("pgchrome.coverDragHint")}),!a&&e.jsx("div",{className:"amx-cover-tools",children:x?e.jsx("button",{onClick:()=>R(!1),children:u("pgchrome.coverDone")}):e.jsxs(e.Fragment,{children:[e.jsx("button",{onClick:r=>{const o=r.currentTarget.getBoundingClientRect();j({x:o.right,y:o.bottom+6})},children:u("pgchrome.coverChange")}),P>=1&&e.jsx("button",{onClick:()=>R(!0),children:u("pgchrome.coverReposition")}),e.jsx("button",{onClick:()=>C(null),children:u("pgchrome.coverRemove")})]})}),z&&e.jsx(pe,{page:k,x:z.x,y:z.y,onApply:h??void 0,onClose:()=>j(null)})]})}const he=["aurora","forest","ocean","alpine","metro","night","coast","mist","valley","dune","lake","bloom"].map(n=>({thumb:`https://picsum.photos/seed/${n}/320/180`,full:`https://picsum.photos/seed/${n}/1600/900`,source:"Picsum"}));function pe({page:n,x:s,y:p,onClose:h,onApply:d}){const{t:a}=F(),u=!!L.searchImages,I=W(),[m,i]=c.useState("gallery"),[g,z]=c.useState(""),[j,D]=c.useState(null),[N,x]=c.useState(!1),[R,P]=c.useState(!1),[f,M]=c.useState(""),[E,k]=c.useState(null),v=c.useId(),$=c.useRef([]),w=c.useRef(h);w.current=h,c.useEffect(()=>{const t=document.activeElement instanceof HTMLElement?document.activeElement:null,l=b=>{b.key==="Escape"&&(b.preventDefault(),b.stopPropagation(),w.current())};return document.addEventListener("keydown",l,!0),()=>{document.removeEventListener("keydown",l,!0),t?.isConnected&&t.focus({preventScroll:!0})}},[]);const C=[{id:"gallery",label:"pgchrome.tabGallery",icon:Q},{id:"url",label:"pgchrome.tabUrl",icon:V},{id:"upload",label:"pgchrome.tabUpload",icon:O}],U=t=>{k(t),d?d(t):I.getState().setPageCover(n,t)},T=()=>{const t=g.trim();!t||!L.searchImages||(x(!0),P(!1),L.searchImages(t).then(l=>{D(l),x(!1)}).catch(()=>{D(null),P(!0),x(!1)}))},r=()=>{const t=document.createElement("input");t.type="file",t.accept="image/*",t.onchange=()=>{const l=t.files?.[0];l&&(async()=>{try{const b=new Uint8Array(await l.arrayBuffer()),{opts:S}=await te(),{pageRel:y}=await L.saveAttachment(n,l.name||"cover.png",b,S);U(ae(n.split("/").slice(0,-1).join("/"),y))}catch{}})()},t.click()},o=t=>e.jsx("div",{className:"amx-coverpick-grid",children:t.map((l,b)=>e.jsxs("button",{className:"amx-coverpick-item","aria-label":a("pgchrome.chooseCover",{index:b+1}),"aria-pressed":E===l.full,onClick:()=>U(l.full),children:[e.jsxs("span",{className:"amx-coverpick-thumb",children:[e.jsx(Z,{size:20,strokeWidth:1.7,"aria-hidden":"true"}),e.jsx("img",{src:l.thumb,alt:"",loading:"lazy",onError:S=>{S.currentTarget.hidden=!0}}),E===l.full&&e.jsx("span",{className:"amx-coverpick-selected",children:e.jsx(ee,{size:14,"aria-hidden":"true"})})]}),l.author&&e.jsx("span",{className:"amx-coverpick-cap",children:l.author})]},l.full))});return q.createPortal(e.jsx("div",{className:"ui-popover-backdrop am-app",onMouseDown:h,children:e.jsxs(B,{className:"ui-popover amx-coverpick",role:"dialog","aria-label":a("pgchrome.coverTitle"),x:s-336,y:p,onMouseDown:t=>t.stopPropagation(),children:[e.jsxs("div",{className:"amx-coverpick-header",children:[e.jsx("span",{children:a("pgchrome.coverTitle")}),e.jsx("button",{className:"amx-coverpick-close",onClick:h,"aria-label":a("pgchrome.close"),children:e.jsx(J,{size:14,strokeWidth:1.7,"aria-hidden":"true"})})]}),e.jsx("div",{className:"amx-coverpick-tabs",role:"tablist","aria-label":a("pgchrome.coverTitle"),children:C.map(({id:t,label:l,icon:b},S)=>e.jsxs("button",{ref:y=>{$.current[S]=y},id:`${v}-${t}`,role:"tab","aria-selected":m===t,"aria-controls":v,tabIndex:m===t?0:-1,onClick:()=>i(t),onKeyDown:y=>{const Y=y.key==="ArrowRight"?(S+1)%C.length:y.key==="ArrowLeft"?(S+C.length-1)%C.length:y.key==="Home"?0:y.key==="End"?C.length-1:-1;Y<0||(y.preventDefault(),i(C[Y].id),$.current[Y]?.focus())},children:[e.jsx(b,{size:14,strokeWidth:1.7,"aria-hidden":"true"}),a(l)]},t))}),e.jsxs("div",{id:v,role:"tabpanel","aria-labelledby":`${v}-${m}`,className:"amx-coverpick-panel",children:[m==="gallery"&&e.jsxs("div",{className:"amx-coverpick-body",children:[u&&e.jsxs("div",{className:"amx-coverpick-search",children:[e.jsx(X,{size:14,strokeWidth:1.7,"aria-hidden":"true"}),e.jsx("input",{"aria-label":a("pgchrome.searchPlaceholder"),placeholder:a("pgchrome.searchPlaceholder"),value:g,onChange:t=>z(t.target.value),onKeyDown:t=>{t.key==="Enter"&&T()}}),e.jsx("button",{className:"amx-coverpick-go",disabled:N||!g.trim(),onClick:T,children:N?"…":a("pgchrome.search")})]}),e.jsx("div",{className:"amx-coverpick-section",children:a(j?.length?"pgchrome.results":"pgchrome.featured")}),o(j&&j.length>0?j:he),!N&&R&&e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.searchUnavailable")}),!N&&!R&&j?.length===0&&e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.searchEmpty")})]}),m==="url"&&e.jsxs("div",{className:"amx-coverpick-body amx-coverpick-url",children:[e.jsx("label",{htmlFor:`${v}-url-input`,children:a("pgchrome.imageUrl")}),e.jsx("input",{id:`${v}-url-input`,placeholder:a("pgchrome.urlPlaceholder"),value:f,onChange:t=>M(t.target.value),onKeyDown:t=>{t.key==="Enter"&&/^https?:\/\//i.test(f.trim())&&U(f.trim())}}),e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.urlHint")}),e.jsx("button",{className:"amx-coverpick-go",disabled:!/^https?:\/\//i.test(f.trim()),onClick:()=>{/^https?:\/\//i.test(f.trim())&&U(f.trim())},children:a("pgchrome.setCover")})]}),m==="upload"&&e.jsxs("div",{className:"amx-coverpick-body amx-coverpick-upload",children:[e.jsx(O,{size:24,strokeWidth:1.5,"aria-hidden":"true"}),e.jsx("div",{className:"amx-coverpick-upload-title",children:a("pgchrome.uploadTitle")}),e.jsx("div",{className:"amx-coverpick-hint",children:a("pgchrome.uploadHint")}),e.jsx("button",{className:"amx-coverpick-go",onClick:r,children:a("pgchrome.chooseLocal")})]})]})]})}),document.body)}const je=()=>_[Math.floor(Math.random()*_.length)];function Ne({x:n,y:s,current:p,onPick:h,onClose:d}){const{t:a}=F(),[u,I]=c.useState(""),m=se(u);return e.jsx("div",{className:"amx-db-popwrap",onMouseDown:d,children:e.jsxs(B,{className:"amx-db-pop amx-iconpick",x:n,y:s,onMouseDown:i=>i.stopPropagation(),children:[e.jsx("input",{className:"amx-db-pop-input",autoFocus:!0,placeholder:a("pgchrome.emojiPlaceholder"),value:u,onChange:i=>I(i.target.value),onKeyDown:i=>{if(i.key==="Escape"){d();return}i.key!=="Enter"||!u.trim()||h(m&&m.length?m[0]:u.trim())}}),e.jsxs("div",{className:"amx-iconpick-grid",children:[m?m.map(i=>e.jsx("button",{className:`amx-iconpick-item${p===i?" active":""}`,onClick:()=>h(i),children:i},i)):ce.map(i=>e.jsxs(c.Fragment,{children:[e.jsx("div",{className:"amx-iconpick-group",children:a(i.nameKey)}),i.items.map(([g,z])=>e.jsx("button",{className:`amx-iconpick-item${p===g?" active":""}`,title:z,onClick:()=>h(g),children:g},`${i.nameKey}-${g}`))]},i.nameKey)),m&&m.length===0&&e.jsx("div",{className:"amx-iconpick-empty",children:a("pgchrome.emojiEmpty")})]}),p&&e.jsx("button",{className:"amx-db-opt amx-db-opt-clear",onClick:()=>h(null),children:a("pgchrome.removeIcon")})]})})}export{pe as C,fe as I,ye as N,ke as S,be as U,Ne as a,je as r,le as u};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{rb as k,rc as j,rd as M}from"./appStore-DWP8UET9.js";import{b4 as P,b0 as N}from"./index-BM2o7PeV.js";const T=720,v=400,A=/^["']?canvas["']?[ \t]*:[ \t]*(.*)$/m,V=/^\uFEFF?---\r?\n([\s\S]*?)\r?\n---[ \t]*(?:\r?\n|$)/;function F(o){const t=V.exec(o??"");return t?A.exec(t[1]):null}function E(o){const t=o.trim();if(t.startsWith("'")&&t.endsWith("'")&&t.length>=2)return t.slice(1,-1).replace(/''/g,"'");if(t.startsWith('"')&&t.endsWith('"')&&t.length>=2)try{return JSON.parse(t)}catch{return t.slice(1,-1)}return t}const d=(o,t)=>typeof o=="number"&&Number.isFinite(o)?Math.round(o):t;function B(o){if(k(o)!=="v3")return!1;const t=F(o);if(!t)return!1;try{const r=JSON.parse(E(t[1]));return!!r&&typeof r=="object"&&!Array.isArray(r)}catch{return!1}}function J(o,t,r){if(k(t)!=="v3")return{ok:!1,reason:"not-v3"};const i=F(t);if(!i)return{ok:!1,reason:"plugin-structured-frontmatter"};let n;try{n=JSON.parse(E(i[1]))}catch{return{ok:!1,reason:"plugin-structured-frontmatter"}}if(!n||typeof n!="object"||Array.isArray(n))return{ok:!1,reason:"plugin-structured-frontmatter"};const s=P(o,t,r),c=n.n??{},a=new Set((n.s??[]).map(e=>String(e.id??"")).filter(Boolean)),u=[],m=[];for(const e of s.manifest.root.children){const l=e.columns.length>1;for(const f of e.columns)for(const p of f.children){const g=p.ref,x=Object.prototype.hasOwnProperty.call(c,g);if(x&&l)return{ok:!1,reason:"plugin-structured-frontmatter"};if(x)m.push(g);else{const S=(s.blocks[g]?.content??"").replace(/^(?:[ \t]*\r?\n)+/,"").trimEnd();S&&u.push(S)}}}if(s.manifest.root.children.some(e=>e.columns.length>1))return{ok:!1,reason:"plugin-structured-frontmatter"};const R=m.map(e=>{const l=(s.blocks[e]?.content??"").replace(/^(?:[ \t]*\r?\n)+/,"").trimEnd();return l?`${N(e)}
|
|
2
2
|
|
|
3
3
|
${l}`:N(e)}),y=m.map(e=>{const l=c[e]??{},f=d(l.h,0);return{ref:e,x:d(l.x,0),y:d(l.y,0),w:d(l.w,v)||v,...f>0?{h:f}:{}}}),b=e=>e?a.has(e)?{id:e}:{ref:e}:null,h=[];for(const e of n.s??[]){const l=String(e.id??"");if(!l)continue;const f=String(e.t??"rect");h.push({id:l,type:f==="text"?"text":"shape",...f==="text"?{}:{shape:f},x:d(e.x,0),y:d(e.y,0),w:d(e.w,0),h:d(e.h,0),...e.text?{text:e.text}:{}})}(n.e??[]).forEach((e,l)=>{const f=b(e.a),p=b(e.b);!f||!p||h.push({id:`e${l+1}`,type:"connector",from:f,to:p,...e.label?{label:e.label}:{}})});const C=y.length||h.length?JSON.stringify({v:1,mode:n.mode==="canvas"?"canvas":"doc",main:{x:0,y:0,w:T},cards:y,...h.length?{elements:h}:{}}):null,O=(s.manifest.fmExtra??"").split(`
|
|
4
4
|
`).filter(e=>!A.test(e)).join(`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as e}from"./appStore-
|
|
1
|
+
import{F as e}from"./appStore-DWP8UET9.js";const a=[["path",{d:"M15.707 21.293a1 1 0 0 1-1.414 0l-1.586-1.586a1 1 0 0 1 0-1.414l5.586-5.586a1 1 0 0 1 1.414 0l1.586 1.586a1 1 0 0 1 0 1.414z",key:"nt11vn"}],["path",{d:"m18 13-1.375-6.874a1 1 0 0 0-.746-.776L3.235 2.028a1 1 0 0 0-1.207 1.207L5.35 15.879a1 1 0 0 0 .776.746L13 18",key:"15qc1e"}],["path",{d:"m2.3 2.3 7.286 7.286",key:"1wuzzi"}],["circle",{cx:"11",cy:"11",r:"2",key:"xmgehs"}]],c=e("pen-tool",a);export{c as P};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as a}from"./appStore-
|
|
1
|
+
import{F as a}from"./appStore-DWP8UET9.js";const e=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],c=a("pencil",e);export{c as P};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{j as r,K as w,u as j,r as A}from"./index-BM2o7PeV.js";import{hU as I,s as f,u as g,hO as N,hP as _,b as E,rB as O,hQ as C,hR as T,hX as L,g4 as P}from"./appStore-DWP8UET9.js";import{w as $,n as b}from"./viewportLock-D3SNkwS2.js";import{C as D}from"./codingNavigation-DDlPpPk5.js";import"./nativeDownload-BYT082bY.js";import"./ipc-CxAyeo8q.js";import"./client-0MPbodA6.js";import"./UnifiedPage-BX6ZQL0h.js";import"./MarkdownBlock-CkqiwPXa.js";import"./index-CuiYK18N.js";import"./linkFollow-B7ivDZMM.js";import"./mdMarks-DbIcRa0O.js";import"./emoji-6zl4yfOS.js";import"./listFold-DLuxXiIj.js";import"./book-open-OLNm7OaB.js";import"./pageChrome-D3Niv1JM.js";import"./upload-ZrOj6tXA.js";import"./SketchCard-BGYz-bXP.js";import"./arrow-up-right-DrCXuWS7.js";import"./Chrome-HdfyYV3i.js";import"./minus-C9ndHJ9O.js";import"./canvasPrefs-8taQ42Cz.js";import"./hand-Bko7ms15.js";import"./type-CFoaj2eD.js";import"./foldActions-05QcQziQ.js";import"./lock-CnbZm4vo.js";import"./undo-2-DusxpdLa.js";import"./code-xml-Cuna8Kh4.js";import"./message-square-plus-CpiKDvle.js";import"./RunLocationPicker-DBnXYV5B.js";import"./codeStudioStore-BBU62GTy.js";import"./RightPanel-BHDgqTFs.js";import"./folder-plus-BeQHr4AZ.js";import"./folder-BpsfOHD4.js";import"./pencil-cqvCkekG.js";import"./ModelPill-CY-rU1RU.js";import"./create-BGtEfCcg.js";import"./approvalText-Cy2UAUAQ.js";import"./SidebarRow-BAJxbMcx.js";import"./rotate-ccw-BvipPIjC.js";import"./hard-drive-BpuI5ebj.js";import"./CapabilityMenu-SwVlZ06x.js";import"./circle-x-fcReAZaE.js";import"./userSpaces-uJOnsedR.js";import"./automationListSource-C8BNy6RY.js";import"./messages-_jta1lSI.js";import"./workflow-DPoG4QE2.js";import"./list-tree-4-0QDbLu.js";import"./layout-grid-BBVuEdWG.js";import"./terminal-l9k6RDrH.js";import"./star-BQWMXnn7.js";import"./DashboardGridView-B9DCWYVb.js";import"./FloatingToc-Ce9GamvH.js";import"./pageTree-CgfvpzIj.js";import"./pluginExt-Byb64tQO.js";import"./pen-tool-BXEFnU2i.js";import"./redo-2-BO7wCDwy.js";import"./AutomationBuilder-hqs0QhMt.js";import"./gestures-DQBCcK4y.js";import"./circle-question-mark-XbAFplz1.js";import"./InlineFiles-CQbQumkf.js";import"./MuseView-CC2A7MBs.js";import"./i18n.generated-BuLjnmY8.js";import"./log-out-BEynWaHa.js";import"./index-Ck_O3Jdd.js";/* empty css */import"./StudioGuestSurface-lt6znmkl.js";import"./pdf.worker.min-CGb3BKV9.js";import"./zoom-in-lbTgzdQP.js";import"./mdMarkStore-DQHDjG7s.js";A({"pluginChat.failed":{zh:"对话没接上:{error}",en:"Could not open the chat: {error}"},"pluginChat.noEngine":{zh:"引擎还没连上",en:"the engine is not connected"},"pluginChat.noFolder":{zh:"这台设备上打不开这个文件夹",en:"this folder is not available on this device"},"pluginChat.noAgent":{zh:"没有这个 Agent:{agent}",en:"no such agent: {agent}"}});const x="engine is not connected",y="folder is not available on this host: ",d="unknown agent: ",v="tangu.pluginChats",M=15e3,S=()=>{try{return JSON.parse(localStorage.getItem(v)||"{}")||{}}catch{return{}}},k=e=>String(e?.message??e),u=new Map;async function R(e){if(!await $(M))return{ok:!1,error:x};const t=e.resolveCwd?.()||void 0;if(e.folder&&!t)return{ok:!1,error:`${y}${e.folder}`};const n=`${e.owner}
|
|
2
|
+
${t??""}`,i=u.get(n);if(i)return i;const m=(async()=>{const s=e.agent?.trim()||void 0;if(s&&!await b(s))return{ok:!1,error:`${d}${s}`};const c=S()[n];if(c)try{const o=await I(f(),c);if(!o.archived)return g.getState().adoptSession(o),{ok:!0,sessionId:o.id}}catch(o){if(o?.status!==404)return{ok:!1,error:k(o)}}const a=g.getState(),p=s?a.agentDefs.find(o=>o.slug===s):void 0,l=s??a.defaultAgentSlug,h=N(_({...t?{...O(C(a.desktopConfig,!0),{}),execMode:"host",cwd:t}:{...C(a.desktopConfig,!1),execMode:"sandbox"},...p?.thinkingLevel?{thinkingLevel:p.thinkingLevel,...p.thinkingLevel!=="max"?{ultra:!1}:{}}:{},...l?{agentSlug:l}:{}},E.getState().vaultRoot||null));try{const o=await T(f(),{...e.title?{title:e.title}:{},...t?{project_path:t,project_name:t.replace(/[\\/]+$/,"").split(/[\\/]/).pop()||t}:{projectless:!0},...p?.model?{model_id:p.model}:{},agent_config:h});g.getState().adoptSession({...o,agent_config:o.agent_config||h},{fresh:!0});try{localStorage.setItem(v,JSON.stringify({...S(),[n]:o.id}))}catch{}return{ok:!0,sessionId:o.id}}catch(o){return{ok:!1,error:k(o)}}})();return u.set(n,m),m.finally(()=>{u.delete(n)}),m}const z=(e,t)=>e===x?t("pluginChat.noEngine"):e.startsWith(y)?t("pluginChat.noFolder"):e.startsWith(d)?t("pluginChat.noAgent",{agent:e.slice(d.length)}):e;function F({leaf:e,state:t,retry:n}){const{t:i}=j();return t?.ok&&t.sessionId?r.jsx("div",{"data-plugin-chat":e.type,style:{height:"100%",minHeight:0,display:"flex",flexDirection:"column"},children:r.jsx(D,{leaf:e,params:{followActive:!1,sessionId:t.sessionId,childSurface:!0}},t.sessionId)}):r.jsx("div",{className:"empty-state","data-plugin-chat":e.type,role:t?"alert":"status",style:{height:"100%",padding:16,textAlign:"center"},children:t?r.jsxs(r.Fragment,{children:[r.jsx("span",{children:i("pluginChat.failed",{error:z(t.error||"",i)})}),r.jsx("button",{className:"btn ghost sm",onClick:n,children:i("common.retry")})]}):r.jsx("span",{children:i("common.loading")})})}function ie(e,t,n){const i=L(t),m={id:i,type:i,loc:"right",params:{},setTitle(){},setParams(){},close(){}},s=P(e,null,n),c=l=>s.render(r.jsx(w,{children:r.jsx(F,{leaf:m,state:l,retry:()=>{p()}})}));let a;const p=()=>(c(null),a=R(t).then(l=>(c(l),l)),a);return{ready:p(),latest:()=>a,dispose:s.dispose}}export{R as ensurePluginChat,ie as mountPluginChat};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as o}from"./appStore-
|
|
1
|
+
import{F as o}from"./appStore-DWP8UET9.js";const e=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M12 18v-6",key:"17g6i2"}],["path",{d:"m9 15 3 3 3-3",key:"1npd3o"}]],t=o("file-down",e);const a=[["path",{d:"m15 14 5-5-5-5",key:"12vg1m"}],["path",{d:"M20 9H9.5A5.5 5.5 0 0 0 4 14.5A5.5 5.5 0 0 0 9.5 20H13",key:"6uklza"}]],n=o("redo-2",a);export{t as F,n as R};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as t}from"./appStore-
|
|
1
|
+
import{F as t}from"./appStore-DWP8UET9.js";const e=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],a=t("rotate-ccw",e);export{a as R};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./shareViewer-
|
|
2
|
-
import{t as n,i as g,_ as m,g as u,r as f}from"./index-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./shareViewer-BaYogetW.js","./index-BM2o7PeV.js","./client-0MPbodA6.js","./i18n.generated-BuLjnmY8.js","./appStore-DWP8UET9.js","./nativeDownload-BYT082bY.js","./ipc-CxAyeo8q.js","./appStore-wtOILggO.css","./MarkdownBlock-CkqiwPXa.js","./index-CuiYK18N.js","./linkFollow-B7ivDZMM.js","./mdMarks-DbIcRa0O.js","./emoji-6zl4yfOS.js","./listFold-DLuxXiIj.js","./book-open-OLNm7OaB.js","./MarkdownBlock--__nPQGh.css","./i18n-ecQQxiMQ.css","./UnifiedPage-BX6ZQL0h.js","./pageChrome-D3Niv1JM.js","./upload-ZrOj6tXA.js","./pageChrome-CovzZPdb.css","./SketchCard-BGYz-bXP.js","./arrow-up-right-DrCXuWS7.js","./Chrome-HdfyYV3i.js","./minus-C9ndHJ9O.js","./canvasPrefs-8taQ42Cz.js","./hand-Bko7ms15.js","./type-CFoaj2eD.js","./foldActions-05QcQziQ.js","./lock-CnbZm4vo.js","./undo-2-DusxpdLa.js","./code-xml-Cuna8Kh4.js","./message-square-plus-CpiKDvle.js","./UnifiedPage-CWXc_mo1.css","./pageTree-CgfvpzIj.js","./shareViewer-DLVrwanO.css"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{t as n,i as g,_ as m,g as u,r as f}from"./index-BM2o7PeV.js";f({"sharepage.rateLimited":{zh:"访问过于频繁,稍后再试",en:"Too many requests — please try again later"},"sharepage.gone":{zh:"分享不存在或已撤销",en:"This share does not exist or has been revoked"},"sharepage.loadFailed":{zh:"加载失败",en:"Failed to load"}});function c(r){const s=document.getElementById("root")??document.body.appendChild(document.createElement("div"));s.innerHTML="";const e=document.createElement("div");e.style.cssText='padding:48px;text-align:center;font:15px/1.6 -apple-system,"PingFang SC","Segoe UI",Roboto,sans-serif;opacity:.75',e.textContent=r,s.appendChild(e)}async function y(r,s=u()){const e=`${s}/amadeus/public/shares/${encodeURIComponent(r)}`;let t;try{const a=await fetch(e);if(!a.ok){c(a.status===429?n("sharepage.rateLimited"):n("sharepage.gone"));return}t=await a.json()}catch{c(n("sharepage.loadFailed"));return}let o={root:t.path,pages:[t.path],folders:[]};try{const a=await fetch(`${e}/tree`);if(a.ok){const d=await a.json(),p=l=>!l.split("/").some(h=>h.startsWith("."));o={root:d.root,pages:d.pages.filter(p),folders:d.folders.filter(p)}}}catch{}t.mode==="page"&&!o.pages.includes(t.path)&&o.pages.unshift(t.path);const i={tree:o,current:t.path};g({apiBase:s,token:r,tree:()=>i.tree,currentPage:()=>i.current}),(await m(()=>import("./shareViewer-BaYogetW.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35]),import.meta.url)).mountShareViewer({token:r,base:e,meta:t,tree:o,onCurrentChange:a=>{i.current=a}})}function b(r,s){y(r,s?.apiBase).catch(e=>{console.error("[share] boot failed:",e),c(n("sharepage.loadFailed"))})}export{b as mountSharePage};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{k as Qa,j as oe,aJ as Du,D as Pl,d as ct,bb as zu,L as Lu,u as Bu,ab as Ks,m as Fu,R as Pu,r as Uu}from"./index-Bh_nLVTc.js";import{c as qu}from"./client-DxGbwZLy.js";import{W as $u}from"./i18n.generated-BZRHO2Nc.js";import{rv as Hu,rw as Gu,rx as Ku,ry as Wu,w as Vu,b8 as Yu,z as Xu,y as Zu,x as ju,b as Qu,i as Ju,dk as e1}from"./appStore-B1ynyt42.js";import{S as t1,U as n1}from"./UnifiedPage-C75y-MKT.js";import{r as r1,m as i1,b as a1,s as s1,p as o1}from"./pageTree-yVO1_fSy.js";import"./MarkdownBlock-D8LgHFYY.js";import"./index-BaRySZ-M.js";import"./linkFollow-C6PHGUxk.js";import"./mdMarks-cmL6vzR-.js";import"./emoji-Cjm3bKiF.js";import"./listFold-Q_8mh5ZG.js";import"./book-open-DBJ3dDpw.js";import"./nativeDownload-CziEyW_p.js";import"./ipc-CPhL3bPp.js";import"./pageChrome-DFz_AAzZ.js";import"./upload-MVVRQtkj.js";import"./SketchCard-CAAr_cqF.js";import"./arrow-up-right-R10mR2I6.js";import"./Chrome-B77-lQyh.js";import"./minus-BUT48dAC.js";import"./canvasPrefs-DwL_OAAo.js";import"./hand-D3QspKYq.js";import"./type-GJYLEhY-.js";import"./foldActions-Dm-uAt3L.js";import"./lock-DQ_yL4nF.js";import"./undo-2-DCTs4Ro4.js";import"./code-xml-joKQ-qGS.js";import"./message-square-plus-CEHkduIL.js";function Ws(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const s=n.slice(i,r).trim();(s||!a)&&t.push(s),i=r+1,r=n.indexOf(",",i)}return t}function l1(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const c1=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,u1=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,d1={};function Vs(e,t){return(d1.jsx?u1:c1).test(e)}const h1=/[ \t\n\f\r]/g;function m1(e){return typeof e=="object"?e.type==="text"?Ys(e.value):!1:Ys(e)}function Ys(e){return e.replace(h1,"")===""}class _r{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}_r.prototype.normal={};_r.prototype.property={};_r.prototype.space=void 0;function Ul(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new _r(n,r,t)}function xr(e){return e.toLowerCase()}class kt{constructor(t,n){this.attribute=n,this.property=t}}kt.prototype.attribute="";kt.prototype.booleanish=!1;kt.prototype.boolean=!1;kt.prototype.commaOrSpaceSeparated=!1;kt.prototype.commaSeparated=!1;kt.prototype.defined=!1;kt.prototype.mustUseProperty=!1;kt.prototype.number=!1;kt.prototype.overloadedBoolean=!1;kt.prototype.property="";kt.prototype.spaceSeparated=!1;kt.prototype.space=void 0;let p1=0;const pe=qn(),Xe=qn(),wa=qn(),$=qn(),De=qn(),Pn=qn(),At=qn();function qn(){return 2**++p1}const Ea=Object.freeze(Object.defineProperty({__proto__:null,boolean:pe,booleanish:Xe,commaOrSpaceSeparated:At,commaSeparated:Pn,number:$,overloadedBoolean:wa,spaceSeparated:De},Symbol.toStringTag,{value:"Module"})),Fi=Object.keys(Ea);class Ja extends kt{constructor(t,n,r,i){let a=-1;if(super(t,n),Xs(this,"space",i),typeof r=="number")for(;++a<Fi.length;){const s=Fi[a];Xs(this,Fi[a],(r&Ea[s])===Ea[s])}}}Ja.prototype.defined=!0;function Xs(e,t,n){n&&(e[t]=n)}function tr(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new Ja(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[xr(r)]=r,n[xr(a.attribute)]=r}return new _r(t,n,e.space)}const ql=tr({properties:{ariaActiveDescendant:null,ariaAtomic:Xe,ariaAutoComplete:null,ariaBusy:Xe,ariaChecked:Xe,ariaColCount:$,ariaColIndex:$,ariaColSpan:$,ariaControls:De,ariaCurrent:null,ariaDescribedBy:De,ariaDetails:null,ariaDisabled:Xe,ariaDropEffect:De,ariaErrorMessage:null,ariaExpanded:Xe,ariaFlowTo:De,ariaGrabbed:Xe,ariaHasPopup:null,ariaHidden:Xe,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:De,ariaLevel:$,ariaLive:null,ariaModal:Xe,ariaMultiLine:Xe,ariaMultiSelectable:Xe,ariaOrientation:null,ariaOwns:De,ariaPlaceholder:null,ariaPosInSet:$,ariaPressed:Xe,ariaReadOnly:Xe,ariaRelevant:null,ariaRequired:Xe,ariaRoleDescription:De,ariaRowCount:$,ariaRowIndex:$,ariaRowSpan:$,ariaSelected:Xe,ariaSetSize:$,ariaSort:null,ariaValueMax:$,ariaValueMin:$,ariaValueNow:$,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function $l(e,t){return t in e?e[t]:t}function Hl(e,t){return $l(e,t.toLowerCase())}const f1=tr({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Pn,acceptCharset:De,accessKey:De,action:null,allow:null,allowFullScreen:pe,allowPaymentRequest:pe,allowUserMedia:pe,alpha:pe,alt:null,as:null,async:pe,autoCapitalize:null,autoComplete:De,autoFocus:pe,autoPlay:pe,blocking:De,capture:null,charSet:null,checked:pe,cite:null,className:De,closedBy:null,colorSpace:null,cols:$,colSpan:$,command:null,commandFor:null,content:null,contentEditable:Xe,controls:pe,controlsList:De,coords:$|Pn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:pe,defer:pe,dir:null,dirName:null,disabled:pe,download:wa,draggable:Xe,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:pe,formTarget:null,headers:De,height:$,hidden:wa,high:$,href:null,hrefLang:null,htmlFor:De,httpEquiv:De,id:null,imageSizes:null,imageSrcSet:null,inert:pe,inputMode:null,integrity:null,is:null,isMap:pe,itemId:null,itemProp:De,itemRef:De,itemScope:pe,itemType:De,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:pe,low:$,manifest:null,max:null,maxLength:$,media:null,method:null,min:null,minLength:$,multiple:pe,muted:pe,name:null,nonce:null,noModule:pe,noValidate:pe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:pe,optimum:$,pattern:null,ping:De,placeholder:null,playsInline:pe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:pe,referrerPolicy:null,rel:De,required:pe,reversed:pe,rows:$,rowSpan:$,sandbox:De,scope:null,scoped:pe,seamless:pe,selected:pe,shadowRootClonable:pe,shadowRootCustomElementRegistry:pe,shadowRootDelegatesFocus:pe,shadowRootMode:null,shadowRootSerializable:pe,shape:null,size:$,sizes:null,slot:null,span:$,spellCheck:Xe,src:null,srcDoc:null,srcLang:null,srcSet:null,start:$,step:null,style:null,tabIndex:$,target:null,title:null,translate:null,type:null,typeMustMatch:pe,useMap:null,value:Xe,width:$,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:De,axis:null,background:null,bgColor:null,border:$,borderColor:null,bottomMargin:$,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:pe,declare:pe,event:null,face:null,frame:null,frameBorder:null,hSpace:$,leftMargin:$,link:null,longDesc:null,lowSrc:null,marginHeight:$,marginWidth:$,noResize:pe,noHref:pe,noShade:pe,noWrap:pe,object:null,profile:null,prompt:null,rev:null,rightMargin:$,rules:null,scheme:null,scrolling:Xe,standby:null,summary:null,text:null,topMargin:$,valueType:null,version:null,vAlign:null,vLink:null,vSpace:$,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:pe,disablePictureInPicture:pe,disableRemotePlayback:pe,exportParts:Pn,part:De,prefix:null,property:null,results:$,security:null,unselectable:null},space:"html",transform:Hl}),g1=tr({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",maskType:"mask-type",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:At,accentHeight:$,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:$,amplitude:$,arabicForm:null,ascent:$,attributeName:null,attributeType:null,azimuth:$,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:$,by:null,calcMode:null,capHeight:$,className:De,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:$,diffuseConstant:$,direction:null,display:null,dur:null,divisor:$,dominantBaseline:null,download:pe,dx:null,dy:null,edgeMode:null,editable:null,elevation:$,enableBackground:null,end:null,event:null,exponent:$,externalResourcesRequired:null,fill:null,fillOpacity:$,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Pn,g2:Pn,glyphName:Pn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:$,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:$,horizOriginX:$,horizOriginY:$,id:null,ideographic:$,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:$,k:$,k1:$,k2:$,k3:$,k4:$,kernelMatrix:At,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:$,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:$,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:$,overlineThickness:$,paintOrder:null,panose1:null,path:null,pathLength:$,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:De,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:$,pointsAtY:$,pointsAtZ:$,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:At,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:At,rev:At,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:At,requiredFeatures:At,requiredFonts:At,requiredFormats:At,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:$,specularExponent:$,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:$,strikethroughThickness:$,string:null,stroke:null,strokeDashArray:At,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:$,strokeOpacity:$,strokeWidth:null,style:null,surfaceScale:$,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:At,tabIndex:$,tableValues:null,target:null,targetX:$,targetY:$,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:At,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:$,underlineThickness:$,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:$,values:null,vAlphabetic:$,vMathematical:$,vectorEffect:null,vHanging:$,vIdeographic:$,version:null,vertAdvY:$,vertOriginX:$,vertOriginY:$,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:$,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:$l}),Gl=tr({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),Kl=tr({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Hl}),Wl=tr({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),b1={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},v1=/[A-Z]/g,Zs=/-[a-z]/g,y1=/^data[-\w.:]+$/i;function Vl(e,t){const n=xr(t);let r=t,i=kt;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&y1.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Zs,w1);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Zs.test(a)){let s=a.replace(v1,x1);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=Ja}return new i(r,t)}function x1(e){return"-"+e.toLowerCase()}function w1(e){return e.charAt(1).toUpperCase()}const Yl=Ul([ql,f1,Gl,Kl,Wl],"html"),mi=Ul([ql,g1,Gl,Kl,Wl],"svg");function js(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function E1(e){return e.join(" ").trim()}var Kn={},Pi,Qs;function k1(){if(Qs)return Pi;Qs=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,i=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,s=/^[;\s]*/,o=/^\s+|\s+$/g,l=`
|
|
1
|
+
import{k as Qa,j as oe,aJ as Du,D as Pl,d as ct,bb as zu,L as Lu,u as Bu,ab as Ks,m as Fu,R as Pu,r as Uu}from"./index-BM2o7PeV.js";import{c as qu}from"./client-0MPbodA6.js";import{W as $u}from"./i18n.generated-BuLjnmY8.js";import{rx as Hu,ry as Gu,rz as Ku,rA as Wu,w as Vu,ba as Yu,z as Xu,y as Zu,x as ju,b as Qu,i as Ju,dl as e1}from"./appStore-DWP8UET9.js";import{S as t1,U as n1}from"./UnifiedPage-BX6ZQL0h.js";import{r as r1,m as i1,b as a1,s as s1,p as o1}from"./pageTree-CgfvpzIj.js";import"./MarkdownBlock-CkqiwPXa.js";import"./index-CuiYK18N.js";import"./linkFollow-B7ivDZMM.js";import"./mdMarks-DbIcRa0O.js";import"./emoji-6zl4yfOS.js";import"./listFold-DLuxXiIj.js";import"./book-open-OLNm7OaB.js";import"./nativeDownload-BYT082bY.js";import"./ipc-CxAyeo8q.js";import"./pageChrome-D3Niv1JM.js";import"./upload-ZrOj6tXA.js";import"./SketchCard-BGYz-bXP.js";import"./arrow-up-right-DrCXuWS7.js";import"./Chrome-HdfyYV3i.js";import"./minus-C9ndHJ9O.js";import"./canvasPrefs-8taQ42Cz.js";import"./hand-Bko7ms15.js";import"./type-CFoaj2eD.js";import"./foldActions-05QcQziQ.js";import"./lock-CnbZm4vo.js";import"./undo-2-DusxpdLa.js";import"./code-xml-Cuna8Kh4.js";import"./message-square-plus-CpiKDvle.js";function Ws(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const s=n.slice(i,r).trim();(s||!a)&&t.push(s),i=r+1,r=n.indexOf(",",i)}return t}function l1(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const c1=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,u1=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,d1={};function Vs(e,t){return(d1.jsx?u1:c1).test(e)}const h1=/[ \t\n\f\r]/g;function m1(e){return typeof e=="object"?e.type==="text"?Ys(e.value):!1:Ys(e)}function Ys(e){return e.replace(h1,"")===""}class _r{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}_r.prototype.normal={};_r.prototype.property={};_r.prototype.space=void 0;function Ul(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new _r(n,r,t)}function xr(e){return e.toLowerCase()}class kt{constructor(t,n){this.attribute=n,this.property=t}}kt.prototype.attribute="";kt.prototype.booleanish=!1;kt.prototype.boolean=!1;kt.prototype.commaOrSpaceSeparated=!1;kt.prototype.commaSeparated=!1;kt.prototype.defined=!1;kt.prototype.mustUseProperty=!1;kt.prototype.number=!1;kt.prototype.overloadedBoolean=!1;kt.prototype.property="";kt.prototype.spaceSeparated=!1;kt.prototype.space=void 0;let p1=0;const pe=qn(),Xe=qn(),wa=qn(),$=qn(),De=qn(),Pn=qn(),At=qn();function qn(){return 2**++p1}const Ea=Object.freeze(Object.defineProperty({__proto__:null,boolean:pe,booleanish:Xe,commaOrSpaceSeparated:At,commaSeparated:Pn,number:$,overloadedBoolean:wa,spaceSeparated:De},Symbol.toStringTag,{value:"Module"})),Fi=Object.keys(Ea);class Ja extends kt{constructor(t,n,r,i){let a=-1;if(super(t,n),Xs(this,"space",i),typeof r=="number")for(;++a<Fi.length;){const s=Fi[a];Xs(this,Fi[a],(r&Ea[s])===Ea[s])}}}Ja.prototype.defined=!0;function Xs(e,t,n){n&&(e[t]=n)}function tr(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new Ja(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[xr(r)]=r,n[xr(a.attribute)]=r}return new _r(t,n,e.space)}const ql=tr({properties:{ariaActiveDescendant:null,ariaAtomic:Xe,ariaAutoComplete:null,ariaBusy:Xe,ariaChecked:Xe,ariaColCount:$,ariaColIndex:$,ariaColSpan:$,ariaControls:De,ariaCurrent:null,ariaDescribedBy:De,ariaDetails:null,ariaDisabled:Xe,ariaDropEffect:De,ariaErrorMessage:null,ariaExpanded:Xe,ariaFlowTo:De,ariaGrabbed:Xe,ariaHasPopup:null,ariaHidden:Xe,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:De,ariaLevel:$,ariaLive:null,ariaModal:Xe,ariaMultiLine:Xe,ariaMultiSelectable:Xe,ariaOrientation:null,ariaOwns:De,ariaPlaceholder:null,ariaPosInSet:$,ariaPressed:Xe,ariaReadOnly:Xe,ariaRelevant:null,ariaRequired:Xe,ariaRoleDescription:De,ariaRowCount:$,ariaRowIndex:$,ariaRowSpan:$,ariaSelected:Xe,ariaSetSize:$,ariaSort:null,ariaValueMax:$,ariaValueMin:$,ariaValueNow:$,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function $l(e,t){return t in e?e[t]:t}function Hl(e,t){return $l(e,t.toLowerCase())}const f1=tr({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:Pn,acceptCharset:De,accessKey:De,action:null,allow:null,allowFullScreen:pe,allowPaymentRequest:pe,allowUserMedia:pe,alpha:pe,alt:null,as:null,async:pe,autoCapitalize:null,autoComplete:De,autoFocus:pe,autoPlay:pe,blocking:De,capture:null,charSet:null,checked:pe,cite:null,className:De,closedBy:null,colorSpace:null,cols:$,colSpan:$,command:null,commandFor:null,content:null,contentEditable:Xe,controls:pe,controlsList:De,coords:$|Pn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:pe,defer:pe,dir:null,dirName:null,disabled:pe,download:wa,draggable:Xe,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:pe,formTarget:null,headers:De,height:$,hidden:wa,high:$,href:null,hrefLang:null,htmlFor:De,httpEquiv:De,id:null,imageSizes:null,imageSrcSet:null,inert:pe,inputMode:null,integrity:null,is:null,isMap:pe,itemId:null,itemProp:De,itemRef:De,itemScope:pe,itemType:De,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:pe,low:$,manifest:null,max:null,maxLength:$,media:null,method:null,min:null,minLength:$,multiple:pe,muted:pe,name:null,nonce:null,noModule:pe,noValidate:pe,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:pe,optimum:$,pattern:null,ping:De,placeholder:null,playsInline:pe,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:pe,referrerPolicy:null,rel:De,required:pe,reversed:pe,rows:$,rowSpan:$,sandbox:De,scope:null,scoped:pe,seamless:pe,selected:pe,shadowRootClonable:pe,shadowRootCustomElementRegistry:pe,shadowRootDelegatesFocus:pe,shadowRootMode:null,shadowRootSerializable:pe,shape:null,size:$,sizes:null,slot:null,span:$,spellCheck:Xe,src:null,srcDoc:null,srcLang:null,srcSet:null,start:$,step:null,style:null,tabIndex:$,target:null,title:null,translate:null,type:null,typeMustMatch:pe,useMap:null,value:Xe,width:$,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:De,axis:null,background:null,bgColor:null,border:$,borderColor:null,bottomMargin:$,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:pe,declare:pe,event:null,face:null,frame:null,frameBorder:null,hSpace:$,leftMargin:$,link:null,longDesc:null,lowSrc:null,marginHeight:$,marginWidth:$,noResize:pe,noHref:pe,noShade:pe,noWrap:pe,object:null,profile:null,prompt:null,rev:null,rightMargin:$,rules:null,scheme:null,scrolling:Xe,standby:null,summary:null,text:null,topMargin:$,valueType:null,version:null,vAlign:null,vLink:null,vSpace:$,allowTransparency:null,autoCorrect:null,autoSave:null,credentialless:pe,disablePictureInPicture:pe,disableRemotePlayback:pe,exportParts:Pn,part:De,prefix:null,property:null,results:$,security:null,unselectable:null},space:"html",transform:Hl}),g1=tr({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",maskType:"mask-type",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:At,accentHeight:$,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:$,amplitude:$,arabicForm:null,ascent:$,attributeName:null,attributeType:null,azimuth:$,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:$,by:null,calcMode:null,capHeight:$,className:De,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:$,diffuseConstant:$,direction:null,display:null,dur:null,divisor:$,dominantBaseline:null,download:pe,dx:null,dy:null,edgeMode:null,editable:null,elevation:$,enableBackground:null,end:null,event:null,exponent:$,externalResourcesRequired:null,fill:null,fillOpacity:$,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:Pn,g2:Pn,glyphName:Pn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:$,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:$,horizOriginX:$,horizOriginY:$,id:null,ideographic:$,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:$,k:$,k1:$,k2:$,k3:$,k4:$,kernelMatrix:At,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:$,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskType:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:$,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:$,overlineThickness:$,paintOrder:null,panose1:null,path:null,pathLength:$,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:De,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:$,pointsAtY:$,pointsAtZ:$,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:At,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:At,rev:At,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:At,requiredFeatures:At,requiredFonts:At,requiredFormats:At,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:$,specularExponent:$,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:$,strikethroughThickness:$,string:null,stroke:null,strokeDashArray:At,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:$,strokeOpacity:$,strokeWidth:null,style:null,surfaceScale:$,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:At,tabIndex:$,tableValues:null,target:null,targetX:$,targetY:$,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:At,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:$,underlineThickness:$,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:$,values:null,vAlphabetic:$,vMathematical:$,vectorEffect:null,vHanging:$,vIdeographic:$,version:null,vertAdvY:$,vertOriginX:$,vertOriginY:$,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:$,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:$l}),Gl=tr({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),Kl=tr({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Hl}),Wl=tr({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),b1={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},v1=/[A-Z]/g,Zs=/-[a-z]/g,y1=/^data[-\w.:]+$/i;function Vl(e,t){const n=xr(t);let r=t,i=kt;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&y1.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Zs,w1);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Zs.test(a)){let s=a.replace(v1,x1);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=Ja}return new i(r,t)}function x1(e){return"-"+e.toLowerCase()}function w1(e){return e.charAt(1).toUpperCase()}const Yl=Ul([ql,f1,Gl,Kl,Wl],"html"),mi=Ul([ql,g1,Gl,Kl,Wl],"svg");function js(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function E1(e){return e.join(" ").trim()}var Kn={},Pi,Qs;function k1(){if(Qs)return Pi;Qs=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,i=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,s=/^[;\s]*/,o=/^\s+|\s+$/g,l=`
|
|
2
2
|
`,c="/",u="*",d="",f="comment",p="declaration";function v(E,x){if(typeof E!="string")throw new TypeError("First argument must be a string");if(!E)return[];x=x||{};var T=1,M=1;function R(Z){var U=Z.match(t);U&&(T+=U.length);var se=Z.lastIndexOf(l);M=~se?Z.length-se:M+Z.length}function D(){var Z={line:T,column:M};return function(U){return U.position=new S(Z),B(),U}}function S(Z){this.start=Z,this.end={line:T,column:M},this.source=x.source}S.prototype.content=E;function L(Z){var U=new Error(x.source+":"+T+":"+M+": "+Z);if(U.reason=Z,U.filename=x.source,U.line=T,U.column=M,U.source=E,!x.silent)throw U}function P(Z){var U=Z.exec(E);if(U){var se=U[0];return R(se),E=E.slice(se.length),U}}function B(){P(n)}function I(Z){var U;for(Z=Z||[];U=X();)U!==!1&&Z.push(U);return Z}function X(){var Z=D();if(!(c!=E.charAt(0)||u!=E.charAt(1))){for(var U=2;d!=E.charAt(U)&&(u!=E.charAt(U)||c!=E.charAt(U+1));)++U;if(U+=2,d===E.charAt(U-1))return L("End of comment missing");var se=E.slice(2,U-2);return M+=2,R(se),E=E.slice(U),M+=2,Z({type:f,comment:se})}}function K(){var Z=D(),U=P(r);if(U){if(X(),!P(i))return L("property missing ':'");var se=P(a),Se=Z({type:p,property:y(U[0].replace(e,d)),value:se?y(se[0].replace(e,d)):d});return P(s),Se}}function he(){var Z=[];I(Z);for(var U;U=K();)U!==!1&&(Z.push(U),I(Z));return Z}return B(),he()}function y(E){return E?E.replace(o,d):d}return Pi=v,Pi}var Js;function S1(){if(Js)return Kn;Js=1;var e=Kn&&Kn.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(Kn,"__esModule",{value:!0}),Kn.default=n;const t=e(k1());function n(r,i){let a=null;if(!r||typeof r!="string")return a;const s=(0,t.default)(r),o=typeof i=="function";return s.forEach(l=>{if(l.type!=="declaration")return;const{property:c,value:u}=l;o?i(c,u,l):u&&(a=a||{},a[c]=u)}),a}return Kn}var ur={},eo;function _1(){if(eo)return ur;eo=1,Object.defineProperty(ur,"__esModule",{value:!0}),ur.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,i=/^-(ms)-/,a=function(c){return!c||n.test(c)||e.test(c)},s=function(c,u){return u.toUpperCase()},o=function(c,u){return"".concat(u,"-")},l=function(c,u){return u===void 0&&(u={}),a(c)?c:(c=c.toLowerCase(),u.reactCompat?c=c.replace(i,o):c=c.replace(r,o),c.replace(t,s))};return ur.camelCase=l,ur}var dr,to;function T1(){if(to)return dr;to=1;var e=dr&&dr.__importDefault||function(i){return i&&i.__esModule?i:{default:i}},t=e(S1()),n=_1();function r(i,a){var s={};return!i||typeof i!="string"||(0,t.default)(i,function(o,l){o&&l&&(s[(0,n.camelCase)(o,a)]=l)}),s}return r.default=r,dr=r,dr}var A1=T1();const N1=Qa(A1),Xl=Zl("end"),es=Zl("start");function Zl(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function C1(e){const t=es(e),n=Xl(e);if(t&&n)return{start:t,end:n}}function gr(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?no(e.position):"start"in e||"end"in e?no(e):"line"in e||"column"in e?ka(e):""}function ka(e){return ro(e&&e.line)+":"+ro(e&&e.column)}function no(e){return ka(e&&e.start)+"-"+ka(e&&e.end)}function ro(e){return e&&typeof e=="number"?e:1}class ht extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",a={},s=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a={...n}),typeof t=="string"?i=t:!a.cause&&t&&(s=!0,i=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const l=r.indexOf(":");l===-1?a.ruleId=r:(a.source=r.slice(0,l),a.ruleId=r.slice(l+1))}if(!a.place&&a.ancestors&&a.ancestors){const l=a.ancestors[a.ancestors.length-1];l&&(a.place=l.position)}const o=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file="",this.message=i,this.line=o?o.line:void 0,this.name=gr(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=s&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}ht.prototype.file="";ht.prototype.name="";ht.prototype.reason="";ht.prototype.message="";ht.prototype.stack="";ht.prototype.column=void 0;ht.prototype.line=void 0;ht.prototype.ancestors=void 0;ht.prototype.cause=void 0;ht.prototype.fatal=void 0;ht.prototype.place=void 0;ht.prototype.ruleId=void 0;ht.prototype.source=void 0;const ts={}.hasOwnProperty,M1=new Map,I1=/[A-Z]/g,R1=new Set(["table","tbody","thead","tfoot","tr"]),O1=new Set(["td","th"]),jl="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function D1(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=$1(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=q1(n,t.jsx,t.jsxs)}const i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?mi:Yl,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Ql(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function Ql(e,t,n){if(t.type==="element")return z1(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return L1(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return F1(e,t,n);if(t.type==="mdxjsEsm")return B1(e,t);if(t.type==="root")return P1(e,t,n);if(t.type==="text")return U1(e,t)}function z1(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=mi,e.schema=i),e.ancestors.push(t);const a=e0(e,t.tagName,!1),s=H1(e,t);let o=rs(e,t);return R1.has(t.tagName)&&(o=o.filter(function(l){return typeof l=="string"?!m1(l):!0})),Jl(e,s,a,t),ns(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function L1(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}wr(e,t.position)}function B1(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);wr(e,t.position)}function F1(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=mi,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:e0(e,t.name,!0),s=G1(e,t),o=rs(e,t);return Jl(e,s,a,t),ns(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function P1(e,t,n){const r={};return ns(r,rs(e,t)),e.create(t,e.Fragment,r,n)}function U1(e,t){return t.value}function Jl(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function ns(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function q1(e,t,n){return r;function r(i,a,s,o){const c=Array.isArray(s.children)?n:t;return o?c(a,s,o):c(a,s)}}function $1(e,t){return n;function n(r,i,a,s){const o=Array.isArray(a.children),l=es(r);return t(i,a,s,o,{columnNumber:l?l.column-1:void 0,fileName:e,lineNumber:l?l.line:void 0},void 0)}}function H1(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&ts.call(t.properties,i)){const a=K1(e,i,t.properties[i]);if(a){const[s,o]=a;e.tableCellAlignToStyle&&s==="align"&&typeof o=="string"&&O1.has(t.tagName)?r=o:n[s]=o}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function G1(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const a=r.data.estree.body[0];a.type;const s=a.expression;s.type;const o=s.properties[0];o.type,Object.assign(n,e.evaluater.evaluateExpression(o.argument))}else wr(e,t.position);else{const i=r.name;let a;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const o=r.value.data.estree.body[0];o.type,a=e.evaluater.evaluateExpression(o.expression)}else wr(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function rs(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:M1;for(;++r<t.children.length;){const a=t.children[r];let s;if(e.passKeys){const l=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(l){const c=i.get(l)||0;s=l+"-"+c,i.set(l,c+1)}}const o=Ql(e,a,s);o!==void 0&&n.push(o)}return n}function K1(e,t,n){const r=Vl(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?l1(n):E1(n)),r.property==="style"){let i=typeof n=="object"?n:W1(e,String(n));return e.stylePropertyNameCase==="css"&&(i=V1(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?b1[r.property]||r.property:r.attribute,n]}}function W1(e,t){try{return N1(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,i=new ht("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=jl+"#cannot-parse-style-attribute",i}}function e0(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const i=t.split(".");let a=-1,s;for(;++a<i.length;){const o=Vs(i[a])?{type:"Identifier",name:i[a]}:{type:"Literal",value:i[a]};s=s?{type:"MemberExpression",object:s,property:o,computed:!!(a&&o.type==="Literal"),optional:!1}:o}r=s}else r=Vs(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return ts.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);wr(e)}function wr(e,t){const n=new ht("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=jl+"#cannot-handle-mdx-estrees-without-createevaluater",n}function V1(e){const t={};let n;for(n in e)ts.call(e,n)&&(t[Y1(n)]=e[n]);return t}function Y1(e){let t=e.replace(I1,X1);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function X1(e){return"-"+e.toLowerCase()}const Ui={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},Z1={};function is(e,t){const n=Z1,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return t0(e,r,i)}function t0(e,t,n){if(j1(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return io(e.children,t,n)}return Array.isArray(e)?io(e,t,n):""}function io(e,t,n){const r=[];let i=-1;for(;++i<e.length;)r[i]=t0(e[i],t,n);return r.join("")}function j1(e){return!!(e&&typeof e=="object")}const ao=document.createElement("i");function as(e){const t="&"+e+";";ao.innerHTML=t;const n=ao.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function Nt(e,t,n,r){const i=e.length;let a=0,s;if(t<0?t=-t>i?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)s=Array.from(r),s.unshift(t,n),e.splice(...s);else for(n&&e.splice(t,n);a<r.length;)s=r.slice(a,a+1e4),s.unshift(t,0),e.splice(...s),a+=1e4,t+=1e4}function zt(e,t){return e.length>0?(Nt(e,e.length,0,t),e):t}const so={}.hasOwnProperty;function n0(e){const t={};let n=-1;for(;++n<e.length;)Q1(t,e[n]);return t}function Q1(e,t){let n;for(n in t){const i=(so.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let s;if(a)for(s in a){so.call(i,s)||(i[s]=[]);const o=a[s];J1(i[s],Array.isArray(o)?o:o?[o]:[])}}}function J1(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Nt(e,0,0,r)}function r0(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function $t(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const vt=Cn(/[A-Za-z]/),ut=Cn(/[\dA-Za-z]/),ed=Cn(/[#-'*+\--9=?A-Z^-~]/);function ni(e){return e!==null&&(e<32||e===127)}const Sa=Cn(/\d/),td=Cn(/[\dA-Fa-f]/),nd=Cn(/[!-/:-@[-`{-~]/);function re(e){return e!==null&&e<-2}function ze(e){return e!==null&&(e<0||e===32)}function ke(e){return e===-2||e===-1||e===32}const pi=Cn(new RegExp("\\p{P}|\\p{S}","u")),Un=Cn(/\s/);function Cn(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function nr(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const a=e.charCodeAt(n);let s="";if(a===37&&ut(e.charCodeAt(n+1))&&ut(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(s=String.fromCharCode(a));else if(a>55295&&a<57344){const o=e.charCodeAt(n+1);a<56320&&o>56319&&o<57344?(s=String.fromCharCode(a,o),i=1):s="�"}else s=String.fromCharCode(a);s&&(t.push(e.slice(r,n),encodeURIComponent(s)),r=n+i+1,s=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function we(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return s;function s(l){return ke(l)?(e.enter(n),o(l)):t(l)}function o(l){return ke(l)&&a++<i?(e.consume(l),o):(e.exit(n),t(l))}}const rd={tokenize:id};function id(e){const t=e.attempt(this.parser.constructs.contentInitial,r,i);let n;return t;function r(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),we(e,t,"linePrefix")}function i(o){return e.enter("paragraph"),a(o)}function a(o){const l=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=l),n=l,s(o)}function s(o){if(o===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(o);return}return re(o)?(e.consume(o),e.exit("chunkText"),a):(e.consume(o),s)}}const ad={tokenize:sd},oo={tokenize:od};function sd(e){const t=this,n=[];let r=0,i,a,s;return o;function o(M){if(r<n.length){const R=n[r];return t.containerState=R[1],e.attempt(R[0].continuation,l,c)(M)}return c(M)}function l(M){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&T();const R=t.events.length;let D=R,S;for(;D--;)if(t.events[D][0]==="exit"&&t.events[D][1].type==="chunkFlow"){S=t.events[D][1].end;break}x(r);let L=R;for(;L<t.events.length;)t.events[L][1].end={...S},L++;return Nt(t.events,D+1,0,t.events.slice(R)),t.events.length=L,c(M)}return o(M)}function c(M){if(r===n.length){if(!i)return f(M);if(i.currentConstruct&&i.currentConstruct.concrete)return v(M);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(oo,u,d)(M)}function u(M){return i&&T(),x(r),f(M)}function d(M){return t.parser.lazy[t.now().line]=r!==n.length,s=t.now().offset,v(M)}function f(M){return t.containerState={},e.attempt(oo,p,v)(M)}function p(M){return r++,n.push([t.currentConstruct,t.containerState]),f(M)}function v(M){if(M===null){i&&T(),x(0),e.consume(M);return}return i=i||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:i,contentType:"flow",previous:a}),y(M)}function y(M){if(M===null){E(e.exit("chunkFlow"),!0),x(0),e.consume(M);return}return re(M)?(e.consume(M),E(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(M),y)}function E(M,R){const D=t.sliceStream(M);if(R&&D.push(null),M.previous=a,a&&(a.next=M),a=M,i.defineSkip(M.start),i.write(D),t.parser.lazy[M.start.line]){let S=i.events.length;for(;S--;)if(i.events[S][1].start.offset<s&&(!i.events[S][1].end||i.events[S][1].end.offset>s))return;const L=t.events.length;let P=L,B,I;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){if(B){I=t.events[P][1].end;break}B=!0}for(x(r),S=L;S<t.events.length;)t.events[S][1].end={...I},S++;Nt(t.events,P+1,0,t.events.slice(L)),t.events.length=S}}function x(M){let R=n.length;for(;R-- >M;){const D=n[R];t.containerState=D[1],D[0].exit.call(t,e)}n.length=M}function T(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function od(e,t,n){return we(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function jn(e){if(e===null||ze(e)||Un(e))return 1;if(pi(e))return 2}function fi(e,t,n){const r=[];let i=-1;for(;++i<e.length;){const a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const _a={name:"attention",resolveAll:ld,tokenize:cd};function ld(e,t){let n=-1,r,i,a,s,o,l,c,u;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;l=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const d={...e[r][1].end},f={...e[n][1].start};lo(d,-l),lo(f,l),s={type:l>1?"strongSequence":"emphasisSequence",start:d,end:{...e[r][1].end}},o={type:l>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:f},a={type:l>1?"strongText":"emphasisText",start:{...e[r][1].end},end:{...e[n][1].start}},i={type:l>1?"strong":"emphasis",start:{...s.start},end:{...o.end}},e[r][1].end={...s.start},e[n][1].start={...o.end},c=[],e[r][1].end.offset-e[r][1].start.offset&&(c=zt(c,[["enter",e[r][1],t],["exit",e[r][1],t]])),c=zt(c,[["enter",i,t],["enter",s,t],["exit",s,t],["enter",a,t]]),c=zt(c,fi(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),c=zt(c,[["exit",a,t],["enter",o,t],["exit",o,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(u=2,c=zt(c,[["enter",e[n][1],t],["exit",e[n][1],t]])):u=0,Nt(e,r-1,n-r+3,c),n=r+c.length-u-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function cd(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=jn(r);let a;return s;function s(l){return a=l,e.enter("attentionSequence"),o(l)}function o(l){if(l===a)return e.consume(l),o;const c=e.exit("attentionSequence"),u=jn(l),d=!u||u===2&&i||n.includes(l),f=!i||i===2&&u||n.includes(r);return c._open=!!(a===42?d:d&&(i||!f)),c._close=!!(a===42?f:f&&(u||!d)),t(l)}}function lo(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const ud={name:"autolink",tokenize:dd};function dd(e,t,n){let r=0;return i;function i(p){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(p){return vt(p)?(e.consume(p),s):p===64?n(p):c(p)}function s(p){return p===43||p===45||p===46||ut(p)?(r=1,o(p)):c(p)}function o(p){return p===58?(e.consume(p),r=0,l):(p===43||p===45||p===46||ut(p))&&r++<32?(e.consume(p),o):(r=0,c(p))}function l(p){return p===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):p===null||p===32||p===60||ni(p)?n(p):(e.consume(p),l)}function c(p){return p===64?(e.consume(p),u):ed(p)?(e.consume(p),c):n(p)}function u(p){return ut(p)?d(p):n(p)}function d(p){return p===46?(e.consume(p),r=0,u):p===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):f(p)}function f(p){if((p===45||ut(p))&&r++<63){const v=p===45?f:d;return e.consume(p),v}return n(p)}}const Tr={partial:!0,tokenize:hd};function hd(e,t,n){return r;function r(a){return ke(a)?we(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||re(a)?t(a):n(a)}}const i0={continuation:{tokenize:pd},exit:fd,name:"blockQuote",tokenize:md};function md(e,t,n){const r=this;return i;function i(s){if(s===62){const o=r.containerState;return o.open||(e.enter("blockQuote",{_container:!0}),o.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(s),e.exit("blockQuoteMarker"),a}return n(s)}function a(s){return ke(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function pd(e,t,n){const r=this;return i;function i(s){return ke(s)?we(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):a(s)}function a(s){return e.attempt(i0,t,n)(s)}}function fd(e){e.exit("blockQuote")}const a0={name:"characterEscape",tokenize:gd};function gd(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),i}function i(a){return nd(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const s0={name:"characterReference",tokenize:bd};function bd(e,t,n){const r=this;let i=0,a,s;return o;function o(d){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),l}function l(d){return d===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(d),e.exit("characterReferenceMarkerNumeric"),c):(e.enter("characterReferenceValue"),a=31,s=ut,u(d))}function c(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,s=td,u):(e.enter("characterReferenceValue"),a=7,s=Sa,u(d))}function u(d){if(d===59&&i){const f=e.exit("characterReferenceValue");return s===ut&&!as(r.sliceSerialize(f))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(d)&&i++<a?(e.consume(d),u):n(d)}}const co={partial:!0,tokenize:yd},uo={concrete:!0,name:"codeFenced",tokenize:vd};function vd(e,t,n){const r=this,i={partial:!0,tokenize:D};let a=0,s=0,o;return l;function l(S){return c(S)}function c(S){const L=r.events[r.events.length-1];return a=L&&L[1].type==="linePrefix"?L[2].sliceSerialize(L[1],!0).length:0,o=S,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),u(S)}function u(S){return S===o?(s++,e.consume(S),u):s<3?n(S):(e.exit("codeFencedFenceSequence"),ke(S)?we(e,d,"whitespace")(S):d(S))}function d(S){return S===null||re(S)?(e.exit("codeFencedFence"),r.interrupt?t(S):e.check(co,y,R)(S)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),f(S))}function f(S){return S===null||re(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(S)):ke(S)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),we(e,p,"whitespace")(S)):S===96&&S===o?n(S):(e.consume(S),f)}function p(S){return S===null||re(S)?d(S):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),v(S))}function v(S){return S===null||re(S)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(S)):S===96&&S===o?n(S):(e.consume(S),v)}function y(S){return e.attempt(i,R,E)(S)}function E(S){return e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),x}function x(S){return a>0&&ke(S)?we(e,T,"linePrefix",a+1)(S):T(S)}function T(S){return S===null||re(S)?e.check(co,y,R)(S):(e.enter("codeFlowValue"),M(S))}function M(S){return S===null||re(S)?(e.exit("codeFlowValue"),T(S)):(e.consume(S),M)}function R(S){return e.exit("codeFenced"),t(S)}function D(S,L,P){let B=0;return I;function I(U){return S.enter("lineEnding"),S.consume(U),S.exit("lineEnding"),X}function X(U){return S.enter("codeFencedFence"),ke(U)?we(S,K,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(U):K(U)}function K(U){return U===o?(S.enter("codeFencedFenceSequence"),he(U)):P(U)}function he(U){return U===o?(B++,S.consume(U),he):B>=s?(S.exit("codeFencedFenceSequence"),ke(U)?we(S,Z,"whitespace")(U):Z(U)):P(U)}function Z(U){return U===null||re(U)?(S.exit("codeFencedFence"),L(U)):P(U)}}}function yd(e,t,n){const r=this;return i;function i(s){return s===null?n(s):(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}const qi={name:"codeIndented",tokenize:wd},xd={partial:!0,tokenize:Ed};function wd(e,t,n){const r=this;return i;function i(c){return e.enter("codeIndented"),we(e,a,"linePrefix",5)(c)}function a(c){const u=r.events[r.events.length-1];return u&&u[1].type==="linePrefix"&&u[2].sliceSerialize(u[1],!0).length>=4?s(c):n(c)}function s(c){return c===null?l(c):re(c)?e.attempt(xd,s,l)(c):(e.enter("codeFlowValue"),o(c))}function o(c){return c===null||re(c)?(e.exit("codeFlowValue"),s(c)):(e.consume(c),o)}function l(c){return e.exit("codeIndented"),t(c)}}function Ed(e,t,n){const r=this;return i;function i(s){return r.parser.lazy[r.now().line]?n(s):re(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),i):we(e,a,"linePrefix",5)(s)}function a(s){const o=r.events[r.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):re(s)?i(s):n(s)}}const kd={name:"codeText",previous:_d,resolve:Sd,tokenize:Td};function Sd(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(i=r):(r===t||e[r][1].type==="lineEnding")&&(e[i][1].type="codeTextData",r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function _d(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function Td(e,t,n){let r=0,i,a;return s;function s(d){return e.enter("codeText"),e.enter("codeTextSequence"),o(d)}function o(d){return d===96?(e.consume(d),r++,o):(e.exit("codeTextSequence"),l(d))}function l(d){return d===null?n(d):d===32?(e.enter("space"),e.consume(d),e.exit("space"),l):d===96?(a=e.enter("codeTextSequence"),i=0,u(d)):re(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),l):(e.enter("codeTextData"),c(d))}function c(d){return d===null||d===32||d===96||re(d)?(e.exit("codeTextData"),l(d)):(e.consume(d),c)}function u(d){return d===96?(e.consume(d),i++,u):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",c(d))}}class Ad{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const i=n||0;this.setCursor(Math.trunc(t));const a=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&hr(this.left,r),a.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),hr(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),hr(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);hr(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);hr(this.left,n.reverse())}}}function hr(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function o0(e){const t={};let n=-1,r,i,a,s,o,l,c;const u=new Ad(e);for(;++n<u.length;){for(;n in t;)n=t[n];if(r=u.get(n),n&&r[1].type==="chunkFlow"&&u.get(n-1)[1].type==="listItemPrefix"&&(l=r[1]._tokenizer.events,a=0,a<l.length&&l[a][1].type==="lineEndingBlank"&&(a+=2),a<l.length&&l[a][1].type==="content"))for(;++a<l.length&&l[a][1].type!=="content";)l[a][1].type==="chunkText"&&(l[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,Nd(u,n)),n=t[n],c=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(s=u.get(a),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(i&&(u.get(i)[1].type="lineEndingBlank"),s[1].type="lineEnding",i=a);else if(!(s[1].type==="linePrefix"||s[1].type==="listItemIndent"))break;i&&(r[1].end={...u.get(i)[1].start},o=u.slice(i,n),o.unshift(r),u.splice(i,n-i+1,o))}}return Nt(e,0,Number.POSITIVE_INFINITY,u.slice(0)),!c}function Nd(e,t){const n=e.get(t)[1],r=e.get(t)[2];let i=t-1;const a=[];let s=n._tokenizer;s||(s=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(s._contentTypeTextTrailing=!0));const o=s.events,l=[],c={};let u,d,f=-1,p=n,v=0,y=0;const E=[y];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(u=r.sliceStream(p),p.next||u.push(null),d&&s.defineSkip(p.start),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(u),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++f<o.length;)o[f][0]==="exit"&&o[f-1][0]==="enter"&&o[f][1].type===o[f-1][1].type&&o[f][1].start.line!==o[f][1].end.line&&(y=f+1,E.push(y),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(s.events=[],p?(p._tokenizer=void 0,p.previous=void 0):E.pop(),f=E.length;f--;){const x=o.slice(E[f],E[f+1]),T=a.pop();l.push([T,T+x.length-1]),e.splice(T,2,x)}for(l.reverse(),f=-1;++f<l.length;)c[v+l[f][0]]=v+l[f][1],v+=l[f][1]-l[f][0]-1;return c}const Cd={resolve:Id,tokenize:Rd},Md={partial:!0,tokenize:Od};function Id(e){return o0(e),e}function Rd(e,t){let n;return r;function r(o){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),i(o)}function i(o){return o===null?a(o):re(o)?e.check(Md,s,a)(o):(e.consume(o),i)}function a(o){return e.exit("chunkContent"),e.exit("content"),t(o)}function s(o){return e.consume(o),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function Od(e,t,n){const r=this;return i;function i(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),we(e,a,"linePrefix")}function a(s){if(s===null||re(s))return n(s);const o=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):e.interrupt(r.parser.constructs.flow,n,t)(s)}}function l0(e,t,n,r,i,a,s,o,l){const c=l||Number.POSITIVE_INFINITY;let u=0;return d;function d(x){return x===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(x),e.exit(a),f):x===null||x===32||x===41||ni(x)?n(x):(e.enter(r),e.enter(s),e.enter(o),e.enter("chunkString",{contentType:"string"}),y(x))}function f(x){return x===62?(e.enter(a),e.consume(x),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),p(x))}function p(x){return x===62?(e.exit("chunkString"),e.exit(o),f(x)):x===null||x===60||re(x)?n(x):(e.consume(x),x===92?v:p)}function v(x){return x===60||x===62||x===92?(e.consume(x),p):p(x)}function y(x){return!u&&(x===null||x===41||ze(x))?(e.exit("chunkString"),e.exit(o),e.exit(s),e.exit(r),t(x)):u<c&&x===40?(e.consume(x),u++,y):x===41?(e.consume(x),u--,y):x===null||x===32||x===40||ni(x)?n(x):(e.consume(x),x===92?E:y)}function E(x){return x===40||x===41||x===92?(e.consume(x),y):y(x)}}function c0(e,t,n,r,i,a){const s=this;let o=0,l;return c;function c(p){return e.enter(r),e.enter(i),e.consume(p),e.exit(i),e.enter(a),u}function u(p){return o>999||p===null||p===91||p===93&&!l||p===94&&!o&&"_hiddenFootnoteSupport"in s.parser.constructs?n(p):p===93?(e.exit(a),e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):re(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),u):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||re(p)||o++>999?(e.exit("chunkString"),u(p)):(e.consume(p),l||(l=!ke(p)),p===92?f:d)}function f(p){return p===91||p===92||p===93?(e.consume(p),o++,d):d(p)}}function u0(e,t,n,r,i,a){let s;return o;function o(f){return f===34||f===39||f===40?(e.enter(r),e.enter(i),e.consume(f),e.exit(i),s=f===40?41:f,l):n(f)}function l(f){return f===s?(e.enter(i),e.consume(f),e.exit(i),e.exit(r),t):(e.enter(a),c(f))}function c(f){return f===s?(e.exit(a),l(s)):f===null?n(f):re(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),we(e,c,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),u(f))}function u(f){return f===s||f===null||re(f)?(e.exit("chunkString"),c(f)):(e.consume(f),f===92?d:u)}function d(f){return f===s||f===92?(e.consume(f),u):u(f)}}function br(e,t){let n;return r;function r(i){return re(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):ke(i)?we(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const Dd={name:"definition",tokenize:Ld},zd={partial:!0,tokenize:Bd};function Ld(e,t,n){const r=this;let i;return a;function a(p){return e.enter("definition"),s(p)}function s(p){return c0.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function o(p){return i=$t(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(e.enter("definitionMarker"),e.consume(p),e.exit("definitionMarker"),l):n(p)}function l(p){return ze(p)?br(e,c)(p):c(p)}function c(p){return l0(e,u,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function u(p){return e.attempt(zd,d,d)(p)}function d(p){return ke(p)?we(e,f,"whitespace")(p):f(p)}function f(p){return p===null||re(p)?(e.exit("definition"),r.parser.defined.push(i),t(p)):n(p)}}function Bd(e,t,n){return r;function r(o){return ze(o)?br(e,i)(o):n(o)}function i(o){return u0(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function a(o){return ke(o)?we(e,s,"whitespace")(o):s(o)}function s(o){return o===null||re(o)?t(o):n(o)}}const Fd={name:"hardBreakEscape",tokenize:Pd};function Pd(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return re(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const Ud={name:"headingAtx",resolve:qd,tokenize:$d};function qd(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Nt(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function $d(e,t,n){let r=0;return i;function i(u){return e.enter("atxHeading"),a(u)}function a(u){return e.enter("atxHeadingSequence"),s(u)}function s(u){return u===35&&r++<6?(e.consume(u),s):u===null||ze(u)?(e.exit("atxHeadingSequence"),o(u)):n(u)}function o(u){return u===35?(e.enter("atxHeadingSequence"),l(u)):u===null||re(u)?(e.exit("atxHeading"),t(u)):ke(u)?we(e,o,"whitespace")(u):(e.enter("atxHeadingText"),c(u))}function l(u){return u===35?(e.consume(u),l):(e.exit("atxHeadingSequence"),o(u))}function c(u){return u===null||u===35||ze(u)?(e.exit("atxHeadingText"),o(u)):(e.consume(u),c)}}const Hd=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],ho=["pre","script","style","textarea"],Gd={concrete:!0,name:"htmlFlow",resolveTo:Vd,tokenize:Yd},Kd={partial:!0,tokenize:Zd},Wd={partial:!0,tokenize:Xd};function Vd(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function Yd(e,t,n){const r=this;let i,a,s,o,l;return c;function c(A){return u(A)}function u(A){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(A),d}function d(A){return A===33?(e.consume(A),f):A===47?(e.consume(A),a=!0,y):A===63?(e.consume(A),i=3,r.interrupt?t:_):vt(A)?(e.consume(A),s=String.fromCharCode(A),E):n(A)}function f(A){return A===45?(e.consume(A),i=2,p):A===91?(e.consume(A),i=5,o=0,v):vt(A)?(e.consume(A),i=4,r.interrupt?t:_):n(A)}function p(A){return A===45?(e.consume(A),r.interrupt?t:_):n(A)}function v(A){const Ve="CDATA[";return A===Ve.charCodeAt(o++)?(e.consume(A),o===Ve.length?r.interrupt?t:K:v):n(A)}function y(A){return vt(A)?(e.consume(A),s=String.fromCharCode(A),E):n(A)}function E(A){if(A===null||A===47||A===62||ze(A)){const Ve=A===47,mt=s.toLowerCase();return!Ve&&!a&&ho.includes(mt)?(i=1,r.interrupt?t(A):K(A)):Hd.includes(s.toLowerCase())?(i=6,Ve?(e.consume(A),x):r.interrupt?t(A):K(A)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(A):a?T(A):M(A))}return A===45||ut(A)?(e.consume(A),s+=String.fromCharCode(A),E):n(A)}function x(A){return A===62?(e.consume(A),r.interrupt?t:K):n(A)}function T(A){return ke(A)?(e.consume(A),T):I(A)}function M(A){return A===47?(e.consume(A),I):A===58||A===95||vt(A)?(e.consume(A),R):ke(A)?(e.consume(A),M):I(A)}function R(A){return A===45||A===46||A===58||A===95||ut(A)?(e.consume(A),R):D(A)}function D(A){return A===61?(e.consume(A),S):ke(A)?(e.consume(A),D):M(A)}function S(A){return A===null||A===60||A===61||A===62||A===96?n(A):A===34||A===39?(e.consume(A),l=A,L):ke(A)?(e.consume(A),S):P(A)}function L(A){return A===l?(e.consume(A),l=null,B):A===null||re(A)?n(A):(e.consume(A),L)}function P(A){return A===null||A===34||A===39||A===47||A===60||A===61||A===62||A===96||ze(A)?D(A):(e.consume(A),P)}function B(A){return A===47||A===62||ke(A)?M(A):n(A)}function I(A){return A===62?(e.consume(A),X):n(A)}function X(A){return A===null||re(A)?K(A):ke(A)?(e.consume(A),X):n(A)}function K(A){return A===45&&i===2?(e.consume(A),se):A===60&&i===1?(e.consume(A),Se):A===62&&i===4?(e.consume(A),Ee):A===63&&i===3?(e.consume(A),_):A===93&&i===5?(e.consume(A),Ne):re(A)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(Kd,Te,he)(A)):A===null||re(A)?(e.exit("htmlFlowData"),he(A)):(e.consume(A),K)}function he(A){return e.check(Wd,Z,Te)(A)}function Z(A){return e.enter("lineEnding"),e.consume(A),e.exit("lineEnding"),U}function U(A){return A===null||re(A)?he(A):(e.enter("htmlFlowData"),K(A))}function se(A){return A===45?(e.consume(A),_):K(A)}function Se(A){return A===47?(e.consume(A),s="",ce):K(A)}function ce(A){if(A===62){const Ve=s.toLowerCase();return ho.includes(Ve)?(e.consume(A),Ee):K(A)}return vt(A)&&s.length<8?(e.consume(A),s+=String.fromCharCode(A),ce):K(A)}function Ne(A){return A===93?(e.consume(A),_):K(A)}function _(A){return A===62?(e.consume(A),Ee):A===45&&i===2?(e.consume(A),_):K(A)}function Ee(A){return A===null||re(A)?(e.exit("htmlFlowData"),Te(A)):(e.consume(A),Ee)}function Te(A){return e.exit("htmlFlow"),t(A)}}function Xd(e,t,n){const r=this;return i;function i(s){return re(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a):n(s)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}function Zd(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(Tr,t,n)}}const jd={name:"htmlText",tokenize:Qd};function Qd(e,t,n){const r=this;let i,a,s;return o;function o(_){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(_),l}function l(_){return _===33?(e.consume(_),c):_===47?(e.consume(_),D):_===63?(e.consume(_),M):vt(_)?(e.consume(_),P):n(_)}function c(_){return _===45?(e.consume(_),u):_===91?(e.consume(_),a=0,v):vt(_)?(e.consume(_),T):n(_)}function u(_){return _===45?(e.consume(_),p):n(_)}function d(_){return _===null?n(_):_===45?(e.consume(_),f):re(_)?(s=d,Se(_)):(e.consume(_),d)}function f(_){return _===45?(e.consume(_),p):d(_)}function p(_){return _===62?se(_):_===45?f(_):d(_)}function v(_){const Ee="CDATA[";return _===Ee.charCodeAt(a++)?(e.consume(_),a===Ee.length?y:v):n(_)}function y(_){return _===null?n(_):_===93?(e.consume(_),E):re(_)?(s=y,Se(_)):(e.consume(_),y)}function E(_){return _===93?(e.consume(_),x):y(_)}function x(_){return _===62?se(_):_===93?(e.consume(_),x):y(_)}function T(_){return _===null||_===62?se(_):re(_)?(s=T,Se(_)):(e.consume(_),T)}function M(_){return _===null?n(_):_===63?(e.consume(_),R):re(_)?(s=M,Se(_)):(e.consume(_),M)}function R(_){return _===62?se(_):M(_)}function D(_){return vt(_)?(e.consume(_),S):n(_)}function S(_){return _===45||ut(_)?(e.consume(_),S):L(_)}function L(_){return re(_)?(s=L,Se(_)):ke(_)?(e.consume(_),L):se(_)}function P(_){return _===45||ut(_)?(e.consume(_),P):_===47||_===62||ze(_)?B(_):n(_)}function B(_){return _===47?(e.consume(_),se):_===58||_===95||vt(_)?(e.consume(_),I):re(_)?(s=B,Se(_)):ke(_)?(e.consume(_),B):se(_)}function I(_){return _===45||_===46||_===58||_===95||ut(_)?(e.consume(_),I):X(_)}function X(_){return _===61?(e.consume(_),K):re(_)?(s=X,Se(_)):ke(_)?(e.consume(_),X):B(_)}function K(_){return _===null||_===60||_===61||_===62||_===96?n(_):_===34||_===39?(e.consume(_),i=_,he):re(_)?(s=K,Se(_)):ke(_)?(e.consume(_),K):(e.consume(_),Z)}function he(_){return _===i?(e.consume(_),i=void 0,U):_===null?n(_):re(_)?(s=he,Se(_)):(e.consume(_),he)}function Z(_){return _===null||_===34||_===39||_===60||_===61||_===96?n(_):_===47||_===62||ze(_)?B(_):(e.consume(_),Z)}function U(_){return _===47||_===62||ze(_)?B(_):n(_)}function se(_){return _===62?(e.consume(_),e.exit("htmlTextData"),e.exit("htmlText"),t):n(_)}function Se(_){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(_),e.exit("lineEnding"),ce}function ce(_){return ke(_)?we(e,Ne,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(_):Ne(_)}function Ne(_){return e.enter("htmlTextData"),s(_)}}const ss={name:"labelEnd",resolveAll:nh,resolveTo:rh,tokenize:ih},Jd={tokenize:ah},eh={tokenize:sh},th={tokenize:oh};function nh(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const i=r.type==="labelImage"?4:2;r.type="data",t+=i}}return e.length!==n.length&&Nt(e,0,e.length,n),e}function rh(e,t){let n=e.length,r=0,i,a,s,o;for(;n--;)if(i=e[n][1],a){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;e[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(s){if(e[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(a=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(s=n);const l={type:e[a][1].type==="labelLink"?"link":"image",start:{...e[a][1].start},end:{...e[e.length-1][1].end}},c={type:"label",start:{...e[a][1].start},end:{...e[s][1].end}},u={type:"labelText",start:{...e[a+r+2][1].end},end:{...e[s-2][1].start}};return o=[["enter",l,t],["enter",c,t]],o=zt(o,e.slice(a+1,a+r+3)),o=zt(o,[["enter",u,t]]),o=zt(o,fi(t.parser.constructs.insideSpan.null,e.slice(a+r+4,s-3),t)),o=zt(o,[["exit",u,t],e[s-2],e[s-1],["exit",c,t]]),o=zt(o,e.slice(s+1)),o=zt(o,[["exit",l,t]]),Nt(e,a,e.length,o),e}function ih(e,t,n){const r=this;let i=r.events.length,a,s;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){a=r.events[i][1];break}return o;function o(f){return a?a._inactive?d(f):(s=r.parser.defined.includes($t(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(f),e.exit("labelMarker"),e.exit("labelEnd"),l):n(f)}function l(f){return f===40?e.attempt(Jd,u,s?u:d)(f):f===91?e.attempt(eh,u,s?c:d)(f):s?u(f):d(f)}function c(f){return e.attempt(th,u,d)(f)}function u(f){return t(f)}function d(f){return a._balanced=!0,n(f)}}function ah(e,t,n){return r;function r(d){return e.enter("resource"),e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),i}function i(d){return ze(d)?br(e,a)(d):a(d)}function a(d){return d===41?u(d):l0(e,s,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function s(d){return ze(d)?br(e,l)(d):u(d)}function o(d){return n(d)}function l(d){return d===34||d===39||d===40?u0(e,c,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):u(d)}function c(d){return ze(d)?br(e,u)(d):u(d)}function u(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function sh(e,t,n){const r=this;return i;function i(o){return c0.call(r,e,a,s,"reference","referenceMarker","referenceString")(o)}function a(o){return r.parser.defined.includes($t(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function s(o){return n(o)}}function oh(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),i}function i(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const lh={name:"labelStartImage",resolveAll:ss.resolveAll,tokenize:ch};function ch(e,t,n){const r=this;return i;function i(o){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(o),e.exit("labelImageMarker"),a}function a(o){return o===91?(e.enter("labelMarker"),e.consume(o),e.exit("labelMarker"),e.exit("labelImage"),s):n(o)}function s(o){return o===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(o):t(o)}}const uh={name:"labelStartLink",resolveAll:ss.resolveAll,tokenize:dh};function dh(e,t,n){const r=this;return i;function i(s){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelLink"),a}function a(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):t(s)}}const $i={name:"lineEnding",tokenize:hh};function hh(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),we(e,t,"linePrefix")}}const Jr={name:"thematicBreak",tokenize:mh};function mh(e,t,n){let r=0,i;return a;function a(c){return e.enter("thematicBreak"),s(c)}function s(c){return i=c,o(c)}function o(c){return c===i?(e.enter("thematicBreakSequence"),l(c)):r>=3&&(c===null||re(c))?(e.exit("thematicBreak"),t(c)):n(c)}function l(c){return c===i?(e.consume(c),r++,l):(e.exit("thematicBreakSequence"),ke(c)?we(e,o,"whitespace")(c):o(c))}}const wt={continuation:{tokenize:bh},exit:yh,name:"list",tokenize:gh},ph={partial:!0,tokenize:xh},fh={partial:!0,tokenize:vh};function gh(e,t,n){const r=this,i=r.events[r.events.length-1];let a=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,s=0;return o;function o(p){const v=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(v==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:Sa(p)){if(r.containerState.type||(r.containerState.type=v,e.enter(v,{_container:!0})),v==="listUnordered")return e.enter("listItemPrefix"),p===42||p===45?e.check(Jr,n,c)(p):c(p);if(!r.interrupt||p===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),l(p)}return n(p)}function l(p){return Sa(p)&&++s<10?(e.consume(p),l):(!r.interrupt||s<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(e.exit("listItemValue"),c(p)):n(p)}function c(p){return e.enter("listItemMarker"),e.consume(p),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,e.check(Tr,r.interrupt?n:u,e.attempt(ph,f,d))}function u(p){return r.containerState.initialBlankLine=!0,a++,f(p)}function d(p){return ke(p)?(e.enter("listItemPrefixWhitespace"),e.consume(p),e.exit("listItemPrefixWhitespace"),f):n(p)}function f(p){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(p)}}function bh(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(Tr,i,a);function i(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,we(e,t,"listItemIndent",r.containerState.size+1)(o)}function a(o){return r.containerState.furtherBlankLines||!ke(o)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,s(o)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(fh,t,s)(o))}function s(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,we(e,e.attempt(wt,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function vh(e,t,n){const r=this;return we(e,i,"listItemIndent",r.containerState.size+1);function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="listItemIndent"&&s[2].sliceSerialize(s[1],!0).length===r.containerState.size?t(a):n(a)}}function yh(e){e.exit(this.containerState.type)}function xh(e,t,n){const r=this;return we(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function i(a){const s=r.events[r.events.length-1];return!ke(a)&&s&&s[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const mo={name:"setextUnderline",resolveTo:wh,tokenize:Eh};function wh(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!a&&e[n][1].type==="definition"&&(a=n);const s={type:"setextHeading",start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type="setextHeadingText",a?(e.splice(i,0,["enter",s,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=s,e.push(["exit",s,t]),e}function Eh(e,t,n){const r=this;let i;return a;function a(c){let u=r.events.length,d;for(;u--;)if(r.events[u][1].type!=="lineEnding"&&r.events[u][1].type!=="linePrefix"&&r.events[u][1].type!=="content"){d=r.events[u][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=c,s(c)):n(c)}function s(c){return e.enter("setextHeadingLineSequence"),o(c)}function o(c){return c===i?(e.consume(c),o):(e.exit("setextHeadingLineSequence"),ke(c)?we(e,l,"lineSuffix")(c):l(c))}function l(c){return c===null||re(c)?(e.exit("setextHeadingLine"),t(c)):n(c)}}const kh={tokenize:Sh};function Sh(e){const t=this,n=e.attempt(Tr,r,e.attempt(this.parser.constructs.flowInitial,i,we(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Cd,i)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const _h={resolveAll:h0()},Th=d0("string"),Ah=d0("text");function d0(e){return{resolveAll:h0(e==="text"?Nh:void 0),tokenize:t};function t(n){const r=this,i=this.parser.constructs[e],a=n.attempt(i,s,o);return s;function s(u){return c(u)?a(u):o(u)}function o(u){if(u===null){n.consume(u);return}return n.enter("data"),n.consume(u),l}function l(u){return c(u)?(n.exit("data"),a(u)):(n.consume(u),l)}function c(u){if(u===null)return!0;const d=i[u];let f=-1;if(d)for(;++f<d.length;){const p=d[f];if(!p.previous||p.previous.call(r,r.previous))return!0}return!1}}}function h0(e){return t;function t(n,r){let i=-1,a;for(;++i<=n.length;)a===void 0?n[i]&&n[i][1].type==="data"&&(a=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==a+2&&(n[a][1].end=n[i-1][1].end,n.splice(a+2,i-a-2),i=a+2),a=void 0);return e?e(n,r):n}}function Nh(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],i=t.sliceStream(r);let a=i.length,s=-1,o=0,l;for(;a--;){const c=i[a];if(typeof c=="string"){for(s=c.length;c.charCodeAt(s-1)===32;)o++,s--;if(s)break;s=-1}else if(c===-2)l=!0,o++;else if(c!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const c={type:n===e.length||l||o<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?s:r.start._bufferIndex+s,_index:r.start._index+a,line:r.end.line,column:r.end.column-o,offset:r.end.offset-o},end:{...r.end}};r.end={...c.start},r.start.offset===r.end.offset?Object.assign(r,c):(e.splice(n,0,["enter",c,t],["exit",c,t]),n+=2)}n++}return e}const Ch={42:wt,43:wt,45:wt,48:wt,49:wt,50:wt,51:wt,52:wt,53:wt,54:wt,55:wt,56:wt,57:wt,62:i0},Mh={91:Dd},Ih={[-2]:qi,[-1]:qi,32:qi},Rh={35:Ud,42:Jr,45:[mo,Jr],60:Gd,61:mo,95:Jr,96:uo,126:uo},Oh={38:s0,92:a0},Dh={[-5]:$i,[-4]:$i,[-3]:$i,33:lh,38:s0,42:_a,60:[ud,jd],91:uh,92:[Fd,a0],93:ss,95:_a,96:kd},zh={null:[_a,_h]},Lh={null:[42,95]},Bh={null:[]},Fh=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:Lh,contentInitial:Mh,disable:Bh,document:Ch,flow:Rh,flowInitial:Ih,insideSpan:zh,string:Oh,text:Dh},Symbol.toStringTag,{value:"Module"}));function Ph(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const i={},a=[];let s=[],o=[];const l={attempt:L(D),check:L(S),consume:T,enter:M,exit:R,interrupt:L(S,{interrupt:!0})},c={code:null,containerState:{},defineSkip:y,events:[],now:v,parser:e,previous:null,sliceSerialize:f,sliceStream:p,write:d};let u=t.tokenize.call(c,l);return t.resolveAll&&a.push(t),c;function d(X){return s=zt(s,X),E(),s[s.length-1]!==null?[]:(P(t,0),c.events=fi(a,c.events,c),c.events)}function f(X,K){return qh(p(X),K)}function p(X){return Uh(s,X)}function v(){const{_bufferIndex:X,_index:K,line:he,column:Z,offset:U}=r;return{_bufferIndex:X,_index:K,line:he,column:Z,offset:U}}function y(X){i[X.line]=X.column,I()}function E(){let X;for(;r._index<s.length;){const K=s[r._index];if(typeof K=="string")for(X=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===X&&r._bufferIndex<K.length;)x(K.charCodeAt(r._bufferIndex));else x(K)}}function x(X){u=u(X)}function T(X){re(X)?(r.line++,r.column=1,r.offset+=X===-3?2:1,I()):X!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===s[r._index].length&&(r._bufferIndex=-1,r._index++)),c.previous=X}function M(X,K){const he=K||{};return he.type=X,he.start=v(),c.events.push(["enter",he,c]),o.push(he),he}function R(X){const K=o.pop();return K.end=v(),c.events.push(["exit",K,c]),K}function D(X,K){P(X,K.from)}function S(X,K){K.restore()}function L(X,K){return he;function he(Z,U,se){let Se,ce,Ne,_;return Array.isArray(Z)?Te(Z):"tokenize"in Z?Te([Z]):Ee(Z);function Ee(Pe){return it;function it(at){const st=at!==null&&Pe[at],ot=at!==null&&Pe.null,Ft=[...Array.isArray(st)?st:st?[st]:[],...Array.isArray(ot)?ot:ot?[ot]:[]];return Te(Ft)(at)}}function Te(Pe){return Se=Pe,ce=0,Pe.length===0?se:A(Pe[ce])}function A(Pe){return it;function it(at){return _=B(),Ne=Pe,Pe.partial||(c.currentConstruct=Pe),Pe.name&&c.parser.constructs.disable.null.includes(Pe.name)?mt():Pe.tokenize.call(K?Object.assign(Object.create(c),K):c,l,Ve,mt)(at)}}function Ve(Pe){return X(Ne,_),U}function mt(Pe){return _.restore(),++ce<Se.length?A(Se[ce]):se}}}function P(X,K){X.resolveAll&&!a.includes(X)&&a.push(X),X.resolve&&Nt(c.events,K,c.events.length-K,X.resolve(c.events.slice(K),c)),X.resolveTo&&(c.events=X.resolveTo(c.events,c))}function B(){const X=v(),K=c.previous,he=c.currentConstruct,Z=c.events.length,U=Array.from(o);return{from:Z,restore:se};function se(){r=X,c.previous=K,c.currentConstruct=he,c.events.length=Z,o=U,I()}}function I(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function Uh(e,t){const n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex;let s;if(n===i)s=[e[n].slice(r,a)];else{if(s=e.slice(n,i),r>-1){const o=s[0];typeof o=="string"?s[0]=o.slice(r):s.shift()}a>0&&s.push(e[i].slice(0,a))}return s}function qh(e,t){let n=-1;const r=[];let i;for(;++n<e.length;){const a=e[n];let s;if(typeof a=="string")s=a;else switch(a){case-5:{s="\r";break}case-4:{s=`
|
|
3
3
|
`;break}case-3:{s=`\r
|
|
4
4
|
`;break}case-2:{s=t?" ":" ";break}case-1:{if(!t&&i)continue;s=" ";break}default:s=String.fromCharCode(a)}i=a===-2,r.push(s)}return r.join("")}function $h(e){const r={constructs:n0([Fh,...(e||{}).extensions||[]]),content:i(rd),defined:[],document:i(ad),flow:i(kh),lazy:{},string:i(Th),text:i(Ah)};return r;function i(a){return s;function s(o){return Ph(r,a,o)}}}function Hh(e){for(;!o0(e););return e}const po=/[\0\t\n\r]/g;function Gh(){let e=1,t="",n=!0,r;return i;function i(a,s,o){const l=[];let c,u,d,f,p;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(s||void 0).decode(a)),d=0,t="",n&&(a.charCodeAt(0)===65279&&d++,n=void 0);d<a.length;){if(po.lastIndex=d,c=po.exec(a),f=c&&c.index!==void 0?c.index:a.length,p=a.charCodeAt(f),!c){t=a.slice(d);break}if(p===10&&d===f&&r)l.push(-3),r=void 0;else switch(r&&(l.push(-5),r=void 0),d<f&&(l.push(a.slice(d,f)),e+=f-d),p){case 0:{l.push(65533),e++;break}case 9:{for(u=Math.ceil(e/4)*4,l.push(-2);e++<u;)l.push(-1);break}case 10:{l.push(-4),e=1;break}default:r=!0,e=1}d=f+1}return o&&(r&&l.push(-5),t&&l.push(t),l.push(null)),l}}const Kh=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Wh(e){return e.replace(Kh,Vh)}function Vh(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),a=i===120||i===88;return r0(n.slice(a?2:1),a?16:10)}return as(n)||e}const m0={}.hasOwnProperty;function Yh(e,t,n){return t&&typeof t=="object"&&(n=t,t=void 0),Xh(n)(Hh($h(n).document().write(Gh()(e,t,!0))))}function Xh(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(nn),autolinkProtocol:B,autolinkEmail:B,atxHeading:a(fn),blockQuote:a(ot),characterEscape:B,characterReference:B,codeFenced:a(Ft),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(Ft,s),codeText:a(pn,s),codeTextData:B,data:B,codeFlowValue:B,definition:a(Ht),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(Gt),hardBreakEscape:a(Ae),hardBreakTrailing:a(Ae),htmlFlow:a(Pt,s),htmlFlowData:B,htmlText:a(Pt,s),htmlTextData:B,image:a(Ot),label:s,link:a(nn),listItem:a(or),listItemValue:f,listOrdered:a(Kt,d),listUnordered:a(Kt),paragraph:a(lr),reference:A,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(fn),strong:a(gn),thematicBreak:a(In)},exit:{atxHeading:l(),atxHeadingSequence:D,autolink:l(),autolinkEmail:st,autolinkProtocol:at,blockQuote:l(),characterEscapeValue:I,characterReferenceMarkerHexadecimal:mt,characterReferenceMarkerNumeric:mt,characterReferenceValue:Pe,characterReference:it,codeFenced:l(E),codeFencedFence:y,codeFencedFenceInfo:p,codeFencedFenceMeta:v,codeFlowValue:I,codeIndented:l(x),codeText:l(U),codeTextData:I,data:I,definition:l(),definitionDestinationString:R,definitionLabelString:T,definitionTitleString:M,emphasis:l(),hardBreakEscape:l(K),hardBreakTrailing:l(K),htmlFlow:l(he),htmlFlowData:I,htmlText:l(Z),htmlTextData:I,image:l(Se),label:Ne,labelText:ce,lineEnding:X,link:l(se),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:Ve,resourceDestinationString:_,resourceTitleString:Ee,resource:Te,setextHeading:l(P),setextHeadingLineSequence:L,setextHeadingText:S,strong:l(),thematicBreak:l()}};p0(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(O){let Y={type:"root",children:[]};const ue={stack:[Y],tokenStack:[],config:t,enter:o,exit:c,buffer:s,resume:u,data:n},ve=[];let Ie=-1;for(;++Ie<O.length;)if(O[Ie][1].type==="listOrdered"||O[Ie][1].type==="listUnordered")if(O[Ie][0]==="enter")ve.push(Ie);else{const St=ve.pop();Ie=i(O,St,Ie)}for(Ie=-1;++Ie<O.length;){const St=t[O[Ie][0]];m0.call(St,O[Ie][1].type)&&St[O[Ie][1].type].call(Object.assign({sliceSerialize:O[Ie][2].sliceSerialize},ue),O[Ie][1])}if(ue.tokenStack.length>0){const St=ue.tokenStack[ue.tokenStack.length-1];(St[1]||fo).call(ue,void 0,St[0])}for(Y.position={start:wn(O.length>0?O[0][1].start:{line:1,column:1,offset:0}),end:wn(O.length>0?O[O.length-2][1].end:{line:1,column:1,offset:0})},Ie=-1;++Ie<t.transforms.length;)Y=t.transforms[Ie](Y)||Y;return Y}function i(O,Y,ue){let ve=Y-1,Ie=-1,St=!1,rn,Ut,bn,Rn;for(;++ve<=ue;){const pt=O[ve];switch(pt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{pt[0]==="enter"?Ie++:Ie--,Rn=void 0;break}case"lineEndingBlank":{pt[0]==="enter"&&(rn&&!Rn&&!Ie&&!bn&&(bn=ve),Rn=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Rn=void 0}if(!Ie&&pt[0]==="enter"&&pt[1].type==="listItemPrefix"||Ie===-1&&pt[0]==="exit"&&(pt[1].type==="listUnordered"||pt[1].type==="listOrdered")){if(rn){let vn=ve;for(Ut=void 0;vn--;){const _t=O[vn];if(_t[1].type==="lineEnding"||_t[1].type==="lineEndingBlank"){if(_t[0]==="exit")continue;Ut&&(O[Ut][1].type="lineEndingBlank",St=!0),_t[1].type="lineEnding",Ut=vn}else if(!(_t[1].type==="linePrefix"||_t[1].type==="blockQuotePrefix"||_t[1].type==="blockQuotePrefixWhitespace"||_t[1].type==="blockQuoteMarker"||_t[1].type==="listItemIndent"))break}bn&&(!Ut||bn<Ut)&&(rn._spread=!0),rn.end=Object.assign({},Ut?O[Ut][1].start:pt[1].end),O.splice(Ut||ve,0,["exit",rn,pt[2]]),ve++,ue++}if(pt[1].type==="listItemPrefix"){const vn={type:"listItem",_spread:!1,start:Object.assign({},pt[1].start),end:void 0};rn=vn,O.splice(ve,0,["enter",vn,pt[2]]),ve++,ue++,bn=void 0,Rn=!0}}}return O[Y][1]._spread=St,ue}function a(O,Y){return ue;function ue(ve){o.call(this,O(ve),ve),Y&&Y.call(this,ve)}}function s(){this.stack.push({type:"fragment",children:[]})}function o(O,Y,ue){this.stack[this.stack.length-1].children.push(O),this.stack.push(O),this.tokenStack.push([Y,ue||void 0]),O.position={start:wn(Y.start),end:void 0}}function l(O){return Y;function Y(ue){O&&O.call(this,ue),c.call(this,ue)}}function c(O,Y){const ue=this.stack.pop(),ve=this.tokenStack.pop();if(ve)ve[0].type!==O.type&&(Y?Y.call(this,O,ve[0]):(ve[1]||fo).call(this,O,ve[0]));else throw new Error("Cannot close `"+O.type+"` ("+gr({start:O.start,end:O.end})+"): it’s not open");ue.position.end=wn(O.end)}function u(){return is(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function f(O){if(this.data.expectingFirstListItemValue){const Y=this.stack[this.stack.length-2];Y.start=Number.parseInt(this.sliceSerialize(O),10),this.data.expectingFirstListItemValue=void 0}}function p(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.lang=O}function v(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.meta=O}function y(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function E(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.value=O.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function x(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.value=O.replace(/(\r?\n|\r)$/g,"")}function T(O){const Y=this.resume(),ue=this.stack[this.stack.length-1];ue.label=Y,ue.identifier=$t(this.sliceSerialize(O)).toLowerCase()}function M(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.title=O}function R(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.url=O}function D(O){const Y=this.stack[this.stack.length-1];if(!Y.depth){const ue=this.sliceSerialize(O).length;Y.depth=ue}}function S(){this.data.setextHeadingSlurpLineEnding=!0}function L(O){const Y=this.stack[this.stack.length-1];Y.depth=this.sliceSerialize(O).codePointAt(0)===61?1:2}function P(){this.data.setextHeadingSlurpLineEnding=void 0}function B(O){const ue=this.stack[this.stack.length-1].children;let ve=ue[ue.length-1];(!ve||ve.type!=="text")&&(ve=Dt(),ve.position={start:wn(O.start),end:void 0},ue.push(ve)),this.stack.push(ve)}function I(O){const Y=this.stack.pop();Y.value+=this.sliceSerialize(O),Y.position.end=wn(O.end)}function X(O){const Y=this.stack[this.stack.length-1];if(this.data.atHardBreak){const ue=Y.children[Y.children.length-1];ue.position.end=wn(O.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(Y.type)&&(B.call(this,O),I.call(this,O))}function K(){this.data.atHardBreak=!0}function he(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.value=O}function Z(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.value=O}function U(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.value=O}function se(){const O=this.stack[this.stack.length-1];if(this.data.inReference){const Y=this.data.referenceType||"shortcut";O.type+="Reference",O.referenceType=Y,delete O.url,delete O.title}else delete O.identifier,delete O.label;this.data.referenceType=void 0}function Se(){const O=this.stack[this.stack.length-1];if(this.data.inReference){const Y=this.data.referenceType||"shortcut";O.type+="Reference",O.referenceType=Y,delete O.url,delete O.title}else delete O.identifier,delete O.label;this.data.referenceType=void 0}function ce(O){const Y=this.sliceSerialize(O),ue=this.stack[this.stack.length-2];ue.label=Wh(Y),ue.identifier=$t(Y).toLowerCase()}function Ne(){const O=this.stack[this.stack.length-1],Y=this.resume(),ue=this.stack[this.stack.length-1];if(this.data.inReference=!0,ue.type==="link"){const ve=O.children;ue.children=ve}else ue.alt=Y}function _(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.url=O}function Ee(){const O=this.resume(),Y=this.stack[this.stack.length-1];Y.title=O}function Te(){this.data.inReference=void 0}function A(){this.data.referenceType="collapsed"}function Ve(O){const Y=this.resume(),ue=this.stack[this.stack.length-1];ue.label=Y,ue.identifier=$t(this.sliceSerialize(O)).toLowerCase(),this.data.referenceType="full"}function mt(O){this.data.characterReferenceType=O.type}function Pe(O){const Y=this.sliceSerialize(O),ue=this.data.characterReferenceType;let ve;ue?(ve=r0(Y,ue==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):ve=as(Y);const Ie=this.stack[this.stack.length-1];Ie.value+=ve}function it(O){const Y=this.stack.pop();Y.position.end=wn(O.end)}function at(O){I.call(this,O);const Y=this.stack[this.stack.length-1];Y.url=this.sliceSerialize(O)}function st(O){I.call(this,O);const Y=this.stack[this.stack.length-1];Y.url="mailto:"+this.sliceSerialize(O)}function ot(){return{type:"blockquote",children:[]}}function Ft(){return{type:"code",lang:null,meta:null,value:""}}function pn(){return{type:"inlineCode",value:""}}function Ht(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Gt(){return{type:"emphasis",children:[]}}function fn(){return{type:"heading",depth:0,children:[]}}function Ae(){return{type:"break"}}function Pt(){return{type:"html",value:""}}function Ot(){return{type:"image",title:null,url:"",alt:null}}function nn(){return{type:"link",title:null,url:"",children:[]}}function Kt(O){return{type:"list",ordered:O.type==="listOrdered",start:null,spread:O._spread,children:[]}}function or(O){return{type:"listItem",spread:O._spread,checked:null,children:[]}}function lr(){return{type:"paragraph",children:[]}}function gn(){return{type:"strong",children:[]}}function Dt(){return{type:"text",value:""}}function In(){return{type:"thematicBreak"}}}function wn(e){return{line:e.line,column:e.column,offset:e.offset}}function p0(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?p0(e,r):Zh(e,r)}}function Zh(e,t){let n;for(n in t)if(m0.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function fo(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+gr({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+gr({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+gr({start:t.start,end:t.end})+") is still open")}function jh(e){const t=this;t.parser=n;function n(r){return Yh(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function Qh(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function Jh(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as a}from"./appStore-
|
|
1
|
+
import{F as a}from"./appStore-DWP8UET9.js";const o=[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]],l=a("star",o);export{l as S};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as n,d as a}from"./index-BM2o7PeV.js";import"./MarkdownBlock-CkqiwPXa.js";import{rj as p,g4 as y,j,rk as R,rl as h,rm as v,fo as M,rn as b}from"./appStore-DWP8UET9.js";import"./index-CuiYK18N.js";import"./linkFollow-B7ivDZMM.js";import"./client-0MPbodA6.js";import"./mdMarks-DbIcRa0O.js";import"./emoji-6zl4yfOS.js";import"./listFold-DLuxXiIj.js";import"./book-open-OLNm7OaB.js";import"./nativeDownload-BYT082bY.js";import"./ipc-CxAyeo8q.js";function g({pluginId:m,spec:t,popHost:l}){const o=j(r=>r.mode),s=a.useRef(null),i=a.useMemo(()=>R(t.error?{...t,rows:[]}:t),[t]),u=a.useMemo(()=>h(t.error?{...t,rows:[]}:t),[t]),f=a.useMemo(()=>new Map(t.rows.map(r=>[r.id,r])),[t]),x=a.useRef(t.sort?{colId:t.sort.key,dir:t.sort.dir}:null),d=a.useRef(t);d.current=t,a.useLayoutEffect(()=>{l.dataset.mode=o},[o,l]),a.useLayoutEffect(()=>{s.current&&d.current.onRender?.(s.current)});const c=r=>f.get(r.id),w=a.useMemo(()=>t.fold?.summary?r=>v(t,r.flatMap(e=>f.get(e.id)??[])):void 0,[t,f]);return n.jsx("div",{className:"amadeus-root am-app tangu-lovable amx-plugtable","data-mode":o,ref:s,children:n.jsxs(n.Fragment,{children:[n.jsx(M,{target:`plugin:${m}/${t.id}`,pagePath:`plugin:${m}`,db:i,readOnly:!0,cellMeta:u,hideHead:!0,hideTools:!!t.partial,popHost:l,selectedRowId:t.selectedId??null,initialSort:x.current,onSort:r=>d.current.onSort?.(r?{key:r.colId,dir:r.dir}:null),foldMeta:w,onRowOpen:t.onRowOpen?r=>{const e=c(r);e&&d.current.onRowOpen?.(e)}:void 0,rowAttrs:r=>{const e=c(r);return e?{...e.className?{class:e.className}:{},...b(e.attrs)??{},...b(d.current.rowAttrs?.(e))??{}}:{}}}),t.error?n.jsx("div",{className:"amx-plugtable-error",children:t.error}):t.rows.length===0&&t.empty?n.jsx("div",{className:"amx-plugtable-empty",children:t.empty}):null]})})}function L(m,t,l){p(l);const o=document.createElement("div");o.className="am-app tangu-lovable amx-plugtable-pops",document.body.appendChild(o);let s=!1;const i=y(t,n.jsx(g,{pluginId:m,spec:l,popHost:o}),()=>{s=!0,o.remove()});return{update:u=>{s||(p(u),i.render(n.jsx(g,{pluginId:m,spec:u,popHost:o})))},dispose:i.dispose}}export{L as mountPluginTable};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as e}from"./appStore-
|
|
1
|
+
import{F as e}from"./appStore-DWP8UET9.js";const o=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],a=e("terminal",o);export{a as T};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{u as ke,d as ne,j as le}from"./index-
|
|
1
|
+
import{u as ke,d as ne,j as le}from"./index-BM2o7PeV.js";import{iV as Le,j as _e}from"./appStore-DWP8UET9.js";import"./nativeDownload-BYT082bY.js";import"./ipc-CxAyeo8q.js";import"./client-0MPbodA6.js";var me={exports:{}},Ce;function De(){return Ce||(Ce=1,(function(te,ie){(function(X,J){te.exports=J()})(globalThis,(()=>(()=>{var X={4567:function(T,r,o){var l=this&&this.__decorate||function(e,i,a,u){var _,g=arguments.length,c=g<3?i:u===null?u=Object.getOwnPropertyDescriptor(i,a):u;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")c=Reflect.decorate(e,i,a,u);else for(var m=e.length-1;m>=0;m--)(_=e[m])&&(c=(g<3?_(c):g>3?_(i,a,c):_(i,a))||c);return g>3&&c&&Object.defineProperty(i,a,c),c},f=this&&this.__param||function(e,i){return function(a,u){i(a,u,e)}};Object.defineProperty(r,"__esModule",{value:!0}),r.AccessibilityManager=void 0;const n=o(9042),d=o(9924),v=o(844),p=o(4725),h=o(2585),t=o(3656);let s=r.AccessibilityManager=class extends v.Disposable{constructor(e,i,a,u){super(),this._terminal=e,this._coreBrowserService=a,this._renderService=u,this._rowColumns=new WeakMap,this._liveRegionLineCount=0,this._charsToConsume=[],this._charsToAnnounce="",this._accessibilityContainer=this._coreBrowserService.mainDocument.createElement("div"),this._accessibilityContainer.classList.add("xterm-accessibility"),this._rowContainer=this._coreBrowserService.mainDocument.createElement("div"),this._rowContainer.setAttribute("role","list"),this._rowContainer.classList.add("xterm-accessibility-tree"),this._rowElements=[];for(let _=0;_<this._terminal.rows;_++)this._rowElements[_]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[_]);if(this._topBoundaryFocusListener=_=>this._handleBoundaryFocus(_,0),this._bottomBoundaryFocusListener=_=>this._handleBoundaryFocus(_,1),this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions(),this._accessibilityContainer.appendChild(this._rowContainer),this._liveRegion=this._coreBrowserService.mainDocument.createElement("div"),this._liveRegion.classList.add("live-region"),this._liveRegion.setAttribute("aria-live","assertive"),this._accessibilityContainer.appendChild(this._liveRegion),this._liveRegionDebouncer=this.register(new d.TimeBasedDebouncer(this._renderRows.bind(this))),!this._terminal.element)throw new Error("Cannot enable accessibility before Terminal.open");this._terminal.element.insertAdjacentElement("afterbegin",this._accessibilityContainer),this.register(this._terminal.onResize((_=>this._handleResize(_.rows)))),this.register(this._terminal.onRender((_=>this._refreshRows(_.start,_.end)))),this.register(this._terminal.onScroll((()=>this._refreshRows()))),this.register(this._terminal.onA11yChar((_=>this._handleChar(_)))),this.register(this._terminal.onLineFeed((()=>this._handleChar(`
|
|
2
2
|
`)))),this.register(this._terminal.onA11yTab((_=>this._handleTab(_)))),this.register(this._terminal.onKey((_=>this._handleKey(_.key)))),this.register(this._terminal.onBlur((()=>this._clearLiveRegion()))),this.register(this._renderService.onDimensionsChange((()=>this._refreshRowsDimensions()))),this.register((0,t.addDisposableDomListener)(document,"selectionchange",(()=>this._handleSelectionChange()))),this.register(this._coreBrowserService.onDprChange((()=>this._refreshRowsDimensions()))),this._refreshRows(),this.register((0,v.toDisposable)((()=>{this._accessibilityContainer.remove(),this._rowElements.length=0})))}_handleTab(e){for(let i=0;i<e;i++)this._handleChar(" ")}_handleChar(e){this._liveRegionLineCount<21&&(this._charsToConsume.length>0?this._charsToConsume.shift()!==e&&(this._charsToAnnounce+=e):this._charsToAnnounce+=e,e===`
|
|
3
3
|
`&&(this._liveRegionLineCount++,this._liveRegionLineCount===21&&(this._liveRegion.textContent+=n.tooMuchOutput)))}_clearLiveRegion(){this._liveRegion.textContent="",this._liveRegionLineCount=0}_handleKey(e){this._clearLiveRegion(),new RegExp("\\p{Control}","u").test(e)||this._charsToConsume.push(e)}_refreshRows(e,i){this._liveRegionDebouncer.refresh(e,i,this._terminal.rows)}_renderRows(e,i){const a=this._terminal.buffer,u=a.lines.length.toString();for(let _=e;_<=i;_++){const g=a.lines.get(a.ydisp+_),c=[],m=g?.translateToString(!0,void 0,void 0,c)||"",y=(a.ydisp+_+1).toString(),k=this._rowElements[_];k&&(m.length===0?(k.innerText=" ",this._rowColumns.set(k,[0,1])):(k.textContent=m,this._rowColumns.set(k,c)),k.setAttribute("aria-posinset",y),k.setAttribute("aria-setsize",u))}this._announceCharacters()}_announceCharacters(){this._charsToAnnounce.length!==0&&(this._liveRegion.textContent+=this._charsToAnnounce,this._charsToAnnounce="")}_handleBoundaryFocus(e,i){const a=e.target,u=this._rowElements[i===0?1:this._rowElements.length-2];if(a.getAttribute("aria-posinset")===(i===0?"1":`${this._terminal.buffer.lines.length}`)||e.relatedTarget!==u)return;let _,g;if(i===0?(_=a,g=this._rowElements.pop(),this._rowContainer.removeChild(g)):(_=this._rowElements.shift(),g=a,this._rowContainer.removeChild(_)),_.removeEventListener("focus",this._topBoundaryFocusListener),g.removeEventListener("focus",this._bottomBoundaryFocusListener),i===0){const c=this._createAccessibilityTreeNode();this._rowElements.unshift(c),this._rowContainer.insertAdjacentElement("afterbegin",c)}else{const c=this._createAccessibilityTreeNode();this._rowElements.push(c),this._rowContainer.appendChild(c)}this._rowElements[0].addEventListener("focus",this._topBoundaryFocusListener),this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._terminal.scrollLines(i===0?-1:1),this._rowElements[i===0?1:this._rowElements.length-2].focus(),e.preventDefault(),e.stopImmediatePropagation()}_handleSelectionChange(){if(this._rowElements.length===0)return;const e=document.getSelection();if(!e)return;if(e.isCollapsed)return void(this._rowContainer.contains(e.anchorNode)&&this._terminal.clearSelection());if(!e.anchorNode||!e.focusNode)return void console.error("anchorNode and/or focusNode are null");let i={node:e.anchorNode,offset:e.anchorOffset},a={node:e.focusNode,offset:e.focusOffset};if((i.node.compareDocumentPosition(a.node)&Node.DOCUMENT_POSITION_PRECEDING||i.node===a.node&&i.offset>a.offset)&&([i,a]=[a,i]),i.node.compareDocumentPosition(this._rowElements[0])&(Node.DOCUMENT_POSITION_CONTAINED_BY|Node.DOCUMENT_POSITION_FOLLOWING)&&(i={node:this._rowElements[0].childNodes[0],offset:0}),!this._rowContainer.contains(i.node))return;const u=this._rowElements.slice(-1)[0];if(a.node.compareDocumentPosition(u)&(Node.DOCUMENT_POSITION_CONTAINED_BY|Node.DOCUMENT_POSITION_PRECEDING)&&(a={node:u,offset:u.textContent?.length??0}),!this._rowContainer.contains(a.node))return;const _=({node:m,offset:y})=>{const k=m instanceof Text?m.parentNode:m;let D=parseInt(k?.getAttribute("aria-posinset"),10)-1;if(isNaN(D))return console.warn("row is invalid. Race condition?"),null;const b=this._rowColumns.get(k);if(!b)return console.warn("columns is null. Race condition?"),null;let x=y<b.length?b[y]:b.slice(-1)[0]+1;return x>=this._terminal.cols&&(++D,x=0),{row:D,column:x}},g=_(i),c=_(a);if(g&&c){if(g.row>c.row||g.row===c.row&&g.column>=c.column)throw new Error("invalid range");this._terminal.select(g.column,g.row,(c.row-g.row)*this._terminal.cols-g.column+c.column)}}_handleResize(e){this._rowElements[this._rowElements.length-1].removeEventListener("focus",this._bottomBoundaryFocusListener);for(let i=this._rowContainer.children.length;i<this._terminal.rows;i++)this._rowElements[i]=this._createAccessibilityTreeNode(),this._rowContainer.appendChild(this._rowElements[i]);for(;this._rowElements.length>e;)this._rowContainer.removeChild(this._rowElements.pop());this._rowElements[this._rowElements.length-1].addEventListener("focus",this._bottomBoundaryFocusListener),this._refreshRowsDimensions()}_createAccessibilityTreeNode(){const e=this._coreBrowserService.mainDocument.createElement("div");return e.setAttribute("role","listitem"),e.tabIndex=-1,this._refreshRowDimensions(e),e}_refreshRowsDimensions(){if(this._renderService.dimensions.css.cell.height){this._accessibilityContainer.style.width=`${this._renderService.dimensions.css.canvas.width}px`,this._rowElements.length!==this._terminal.rows&&this._handleResize(this._terminal.rows);for(let e=0;e<this._terminal.rows;e++)this._refreshRowDimensions(this._rowElements[e])}}_refreshRowDimensions(e){e.style.height=`${this._renderService.dimensions.css.cell.height}px`}};r.AccessibilityManager=s=l([f(1,h.IInstantiationService),f(2,p.ICoreBrowserService),f(3,p.IRenderService)],s)},3614:(T,r)=>{function o(d){return d.replace(/\r?\n/g,"\r")}function l(d,v){return v?"\x1B[200~"+d+"\x1B[201~":d}function f(d,v,p,h){d=l(d=o(d),p.decPrivateModes.bracketedPasteMode&&h.rawOptions.ignoreBracketedPasteMode!==!0),p.triggerDataEvent(d,!0),v.value=""}function n(d,v,p){const h=p.getBoundingClientRect(),t=d.clientX-h.left-10,s=d.clientY-h.top-10;v.style.width="20px",v.style.height="20px",v.style.left=`${t}px`,v.style.top=`${s}px`,v.style.zIndex="1000",v.focus()}Object.defineProperty(r,"__esModule",{value:!0}),r.rightClickHandler=r.moveTextAreaUnderMouseCursor=r.paste=r.handlePasteEvent=r.copyHandler=r.bracketTextForPaste=r.prepareTextForTerminal=void 0,r.prepareTextForTerminal=o,r.bracketTextForPaste=l,r.copyHandler=function(d,v){d.clipboardData&&d.clipboardData.setData("text/plain",v.selectionText),d.preventDefault()},r.handlePasteEvent=function(d,v,p,h){d.stopPropagation(),d.clipboardData&&f(d.clipboardData.getData("text/plain"),v,p,h)},r.paste=f,r.moveTextAreaUnderMouseCursor=n,r.rightClickHandler=function(d,v,p,h,t){n(d,v,p),t&&h.rightClickSelect(d),v.value=h.selectionText,v.select()}},7239:(T,r,o)=>{Object.defineProperty(r,"__esModule",{value:!0}),r.ColorContrastCache=void 0;const l=o(1505);r.ColorContrastCache=class{constructor(){this._color=new l.TwoKeyMap,this._css=new l.TwoKeyMap}setCss(f,n,d){this._css.set(f,n,d)}getCss(f,n){return this._css.get(f,n)}setColor(f,n,d){this._color.set(f,n,d)}getColor(f,n){return this._color.get(f,n)}clear(){this._color.clear(),this._css.clear()}}},3656:(T,r)=>{Object.defineProperty(r,"__esModule",{value:!0}),r.addDisposableDomListener=void 0,r.addDisposableDomListener=function(o,l,f,n){o.addEventListener(l,f,n);let d=!1;return{dispose:()=>{d||(d=!0,o.removeEventListener(l,f,n))}}}},3551:function(T,r,o){var l=this&&this.__decorate||function(s,e,i,a){var u,_=arguments.length,g=_<3?e:a===null?a=Object.getOwnPropertyDescriptor(e,i):a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")g=Reflect.decorate(s,e,i,a);else for(var c=s.length-1;c>=0;c--)(u=s[c])&&(g=(_<3?u(g):_>3?u(e,i,g):u(e,i))||g);return _>3&&g&&Object.defineProperty(e,i,g),g},f=this&&this.__param||function(s,e){return function(i,a){e(i,a,s)}};Object.defineProperty(r,"__esModule",{value:!0}),r.Linkifier=void 0;const n=o(3656),d=o(8460),v=o(844),p=o(2585),h=o(4725);let t=r.Linkifier=class extends v.Disposable{get currentLink(){return this._currentLink}constructor(s,e,i,a,u){super(),this._element=s,this._mouseService=e,this._renderService=i,this._bufferService=a,this._linkProviderService=u,this._linkCacheDisposables=[],this._isMouseOut=!0,this._wasResized=!1,this._activeLine=-1,this._onShowLinkUnderline=this.register(new d.EventEmitter),this.onShowLinkUnderline=this._onShowLinkUnderline.event,this._onHideLinkUnderline=this.register(new d.EventEmitter),this.onHideLinkUnderline=this._onHideLinkUnderline.event,this.register((0,v.getDisposeArrayDisposable)(this._linkCacheDisposables)),this.register((0,v.toDisposable)((()=>{this._lastMouseEvent=void 0,this._activeProviderReplies?.clear()}))),this.register(this._bufferService.onResize((()=>{this._clearCurrentLink(),this._wasResized=!0}))),this.register((0,n.addDisposableDomListener)(this._element,"mouseleave",(()=>{this._isMouseOut=!0,this._clearCurrentLink()}))),this.register((0,n.addDisposableDomListener)(this._element,"mousemove",this._handleMouseMove.bind(this))),this.register((0,n.addDisposableDomListener)(this._element,"mousedown",this._handleMouseDown.bind(this))),this.register((0,n.addDisposableDomListener)(this._element,"mouseup",this._handleMouseUp.bind(this)))}_handleMouseMove(s){this._lastMouseEvent=s;const e=this._positionFromMouseEvent(s,this._element,this._mouseService);if(!e)return;this._isMouseOut=!1;const i=s.composedPath();for(let a=0;a<i.length;a++){const u=i[a];if(u.classList.contains("xterm"))break;if(u.classList.contains("xterm-hover"))return}this._lastBufferCell&&e.x===this._lastBufferCell.x&&e.y===this._lastBufferCell.y||(this._handleHover(e),this._lastBufferCell=e)}_handleHover(s){if(this._activeLine!==s.y||this._wasResized)return this._clearCurrentLink(),this._askForLink(s,!1),void(this._wasResized=!1);this._currentLink&&this._linkAtPosition(this._currentLink.link,s)||(this._clearCurrentLink(),this._askForLink(s,!0))}_askForLink(s,e){this._activeProviderReplies&&e||(this._activeProviderReplies?.forEach((a=>{a?.forEach((u=>{u.link.dispose&&u.link.dispose()}))})),this._activeProviderReplies=new Map,this._activeLine=s.y);let i=!1;for(const[a,u]of this._linkProviderService.linkProviders.entries())e?this._activeProviderReplies?.get(a)&&(i=this._checkLinkProviderResult(a,s,i)):u.provideLinks(s.y,(_=>{if(this._isMouseOut)return;const g=_?.map((c=>({link:c})));this._activeProviderReplies?.set(a,g),i=this._checkLinkProviderResult(a,s,i),this._activeProviderReplies?.size===this._linkProviderService.linkProviders.length&&this._removeIntersectingLinks(s.y,this._activeProviderReplies)}))}_removeIntersectingLinks(s,e){const i=new Set;for(let a=0;a<e.size;a++){const u=e.get(a);if(u)for(let _=0;_<u.length;_++){const g=u[_],c=g.link.range.start.y<s?0:g.link.range.start.x,m=g.link.range.end.y>s?this._bufferService.cols:g.link.range.end.x;for(let y=c;y<=m;y++){if(i.has(y)){u.splice(_--,1);break}i.add(y)}}}}_checkLinkProviderResult(s,e,i){if(!this._activeProviderReplies)return i;const a=this._activeProviderReplies.get(s);let u=!1;for(let _=0;_<s;_++)this._activeProviderReplies.has(_)&&!this._activeProviderReplies.get(_)||(u=!0);if(!u&&a){const _=a.find((g=>this._linkAtPosition(g.link,e)));_&&(i=!0,this._handleNewLink(_))}if(this._activeProviderReplies.size===this._linkProviderService.linkProviders.length&&!i)for(let _=0;_<this._activeProviderReplies.size;_++){const g=this._activeProviderReplies.get(_)?.find((c=>this._linkAtPosition(c.link,e)));if(g){i=!0,this._handleNewLink(g);break}}return i}_handleMouseDown(){this._mouseDownLink=this._currentLink}_handleMouseUp(s){if(!this._currentLink)return;const e=this._positionFromMouseEvent(s,this._element,this._mouseService);e&&this._mouseDownLink===this._currentLink&&this._linkAtPosition(this._currentLink.link,e)&&this._currentLink.link.activate(s,this._currentLink.link.text)}_clearCurrentLink(s,e){this._currentLink&&this._lastMouseEvent&&(!s||!e||this._currentLink.link.range.start.y>=s&&this._currentLink.link.range.end.y<=e)&&(this._linkLeave(this._element,this._currentLink.link,this._lastMouseEvent),this._currentLink=void 0,(0,v.disposeArray)(this._linkCacheDisposables))}_handleNewLink(s){if(!this._lastMouseEvent)return;const e=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);e&&this._linkAtPosition(s.link,e)&&(this._currentLink=s,this._currentLink.state={decorations:{underline:s.link.decorations===void 0||s.link.decorations.underline,pointerCursor:s.link.decorations===void 0||s.link.decorations.pointerCursor},isHovered:!0},this._linkHover(this._element,s.link,this._lastMouseEvent),s.link.decorations={},Object.defineProperties(s.link.decorations,{pointerCursor:{get:()=>this._currentLink?.state?.decorations.pointerCursor,set:i=>{this._currentLink?.state&&this._currentLink.state.decorations.pointerCursor!==i&&(this._currentLink.state.decorations.pointerCursor=i,this._currentLink.state.isHovered&&this._element.classList.toggle("xterm-cursor-pointer",i))}},underline:{get:()=>this._currentLink?.state?.decorations.underline,set:i=>{this._currentLink?.state&&this._currentLink?.state?.decorations.underline!==i&&(this._currentLink.state.decorations.underline=i,this._currentLink.state.isHovered&&this._fireUnderlineEvent(s.link,i))}}}),this._linkCacheDisposables.push(this._renderService.onRenderedViewportChange((i=>{if(!this._currentLink)return;const a=i.start===0?0:i.start+1+this._bufferService.buffer.ydisp,u=this._bufferService.buffer.ydisp+1+i.end;if(this._currentLink.link.range.start.y>=a&&this._currentLink.link.range.end.y<=u&&(this._clearCurrentLink(a,u),this._lastMouseEvent)){const _=this._positionFromMouseEvent(this._lastMouseEvent,this._element,this._mouseService);_&&this._askForLink(_,!1)}}))))}_linkHover(s,e,i){this._currentLink?.state&&(this._currentLink.state.isHovered=!0,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(e,!0),this._currentLink.state.decorations.pointerCursor&&s.classList.add("xterm-cursor-pointer")),e.hover&&e.hover(i,e.text)}_fireUnderlineEvent(s,e){const i=s.range,a=this._bufferService.buffer.ydisp,u=this._createLinkUnderlineEvent(i.start.x-1,i.start.y-a-1,i.end.x,i.end.y-a-1,void 0);(e?this._onShowLinkUnderline:this._onHideLinkUnderline).fire(u)}_linkLeave(s,e,i){this._currentLink?.state&&(this._currentLink.state.isHovered=!1,this._currentLink.state.decorations.underline&&this._fireUnderlineEvent(e,!1),this._currentLink.state.decorations.pointerCursor&&s.classList.remove("xterm-cursor-pointer")),e.leave&&e.leave(i,e.text)}_linkAtPosition(s,e){const i=s.range.start.y*this._bufferService.cols+s.range.start.x,a=s.range.end.y*this._bufferService.cols+s.range.end.x,u=e.y*this._bufferService.cols+e.x;return i<=u&&u<=a}_positionFromMouseEvent(s,e,i){const a=i.getCoords(s,e,this._bufferService.cols,this._bufferService.rows);if(a)return{x:a[0],y:a[1]+this._bufferService.buffer.ydisp}}_createLinkUnderlineEvent(s,e,i,a,u){return{x1:s,y1:e,x2:i,y2:a,cols:this._bufferService.cols,fg:u}}};r.Linkifier=t=l([f(1,h.IMouseService),f(2,h.IRenderService),f(3,p.IBufferService),f(4,h.ILinkProviderService)],t)},9042:(T,r)=>{Object.defineProperty(r,"__esModule",{value:!0}),r.tooMuchOutput=r.promptLabel=void 0,r.promptLabel="Terminal input",r.tooMuchOutput="Too much output to announce, navigate to rows manually to read"},3730:function(T,r,o){var l=this&&this.__decorate||function(h,t,s,e){var i,a=arguments.length,u=a<3?t:e===null?e=Object.getOwnPropertyDescriptor(t,s):e;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")u=Reflect.decorate(h,t,s,e);else for(var _=h.length-1;_>=0;_--)(i=h[_])&&(u=(a<3?i(u):a>3?i(t,s,u):i(t,s))||u);return a>3&&u&&Object.defineProperty(t,s,u),u},f=this&&this.__param||function(h,t){return function(s,e){t(s,e,h)}};Object.defineProperty(r,"__esModule",{value:!0}),r.OscLinkProvider=void 0;const n=o(511),d=o(2585);let v=r.OscLinkProvider=class{constructor(h,t,s){this._bufferService=h,this._optionsService=t,this._oscLinkService=s}provideLinks(h,t){const s=this._bufferService.buffer.lines.get(h-1);if(!s)return void t(void 0);const e=[],i=this._optionsService.rawOptions.linkHandler,a=new n.CellData,u=s.getTrimmedLength();let _=-1,g=-1,c=!1;for(let m=0;m<u;m++)if(g!==-1||s.hasContent(m)){if(s.loadCell(m,a),a.hasExtendedAttrs()&&a.extended.urlId){if(g===-1){g=m,_=a.extended.urlId;continue}c=a.extended.urlId!==_}else g!==-1&&(c=!0);if(c||g!==-1&&m===u-1){const y=this._oscLinkService.getLinkData(_)?.uri;if(y){const k={start:{x:g+1,y:h},end:{x:m+(c||m!==u-1?0:1),y:h}};let D=!1;if(!i?.allowNonHttpProtocols)try{const b=new URL(y);["http:","https:"].includes(b.protocol)||(D=!0)}catch{D=!0}D||e.push({text:y,range:k,activate:(b,x)=>i?i.activate(b,x,k):p(0,x),hover:(b,x)=>i?.hover?.(b,x,k),leave:(b,x)=>i?.leave?.(b,x,k)})}c=!1,a.hasExtendedAttrs()&&a.extended.urlId?(g=m,_=a.extended.urlId):(g=-1,_=-1)}}t(e)}};function p(h,t){if(confirm(`Do you want to navigate to ${t}?
|
|
4
4
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as e}from"./appStore-
|
|
1
|
+
import{F as e}from"./appStore-DWP8UET9.js";const y=[["line",{x1:"22",x2:"2",y1:"6",y2:"6",key:"15w7dq"}],["line",{x1:"22",x2:"2",y1:"18",y2:"18",key:"1ip48p"}],["line",{x1:"6",x2:"6",y1:"2",y2:"22",key:"a2lnyx"}],["line",{x1:"18",x2:"18",y1:"2",y2:"22",key:"8vb6jd"}]],o=e("frame",y);const a=[["path",{d:"M12 4v16",key:"1654pz"}],["path",{d:"M4 7V5a1 1 0 0 1 1-1h14a1 1 0 0 1 1 1v2",key:"e0r10z"}],["path",{d:"M9 20h6",key:"s66wpe"}]],p=e("type",a);export{o as F,p as T};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{F as o}from"./appStore-
|
|
1
|
+
import{F as o}from"./appStore-DWP8UET9.js";const a=[["path",{d:"M9 14 4 9l5-5",key:"102s5s"}],["path",{d:"M4 9h10.5a5.5 5.5 0 0 1 5.5 5.5a5.5 5.5 0 0 1-5.5 5.5H11",key:"f3b9sd"}]],e=o("undo-2",a);export{e as U};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{c as I,A as S,s as P}from"./index-
|
|
1
|
+
import{c as I,A as S,s as P}from"./index-BM2o7PeV.js";const m=()=>Array.from(crypto.getRandomValues(new Uint8Array(24)),a=>a.toString(16).padStart(2,"0")).join("");async function L(a,r){const e=I({apiBase:new URL(a.account.apiBase,location.origin).href,storage:sessionStorage,tokenKey:`unit:${a.instanceId}:account`,identityUrl:new URL("unit/account",r).href,allowedPaths:[new URL("unit",r).pathname]}),s=new URL(location.href),c=`unit:${a.instanceId}:login-state`,d=s.searchParams.get("token");if(d){const t=s.searchParams.get("account_state");if(s.searchParams.delete("token"),s.searchParams.delete("account_state"),history.replaceState(null,"",s.href),!t||t!==sessionStorage.getItem(c))throw new Error("Unsolicited account callback");sessionStorage.removeItem(c),await e.adoptToken(d)}const h=await e.authStatus();if(e.getToken()&&h.tokenValid===!1)await e.clearSession();else if(e.getToken()&&h.tokenValid!==!0)throw new Error("Account service unavailable");const i=e.getIdentity(),w=JSON.stringify([location.origin,a.instanceId,i?.userId||`guest:${m()}`,i?.tenantId,i?.workspaceId]);P(`unit:${w}`);const u=new Set,l=new Set,f=t=>{for(const n of l)try{n(t)}catch{}};e.subscribe(f),window.addEventListener("pageshow",t=>{t.persisted&&location.reload()});const p=async()=>{try{for(const U of u)await U();const t=new URL(a.account.loginPath,location.origin);t.searchParams.set("app","forsion-unit"),t.searchParams.set("session","tab");const n=new URL(location.href),o=m();return sessionStorage.setItem(c,o),n.searchParams.set("account_state",o),t.searchParams.set("redirect",n.href),location.assign(t.href),{ok:!0}}catch(t){throw f(await e.authStatus()),t}};let g=e.generation;const b=g,y=async(t,n)=>{if(e.generation!==b)throw new S;const o=await e.request(t,n);if(o.status===401&&e.getToken())throw await o.body?.cancel(),await e.clearSession({prepare:!1}),new S;return o};e.subscribe(()=>{g!==e.generation&&(g=e.generation,location.reload())});const k={status:e.authStatus,login:p,logout:e.logout,request:y,subscribe:t=>(l.add(t),()=>{l.delete(t)})};return{account:e,capability:k,scope:w,login:p,onAuthWillChange(t){u.add(t);const n=e.beforeChange(t);return()=>{u.delete(t),n()}},request:(t,n)=>y(new URL(t,r).href,n)}}export{L as installUnitAccount};
|