@panphora/clayjs 1.15.2 → 1.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -5
- package/THIRD-PARTY-NOTICES.md +16 -0
- package/compat/highlight-11.9.0.min.js +1213 -0
- package/compat/highlight-LICENSE +29 -0
- package/compat/journal-assets.lock.json +22 -0
- package/compat/overtype-2.6.1.min.js +116 -0
- package/compat/overtype-LICENSE +21 -0
- package/dist/all.js +90 -0
- package/dist/clay-dom.js +84 -0
- package/dist/clay-events.js +103 -0
- package/dist/clay-internals.js +85 -0
- package/dist/clay-options.js +93 -0
- package/dist/clay-router.js +98 -0
- package/dist/clay-ui.js +95 -0
- package/dist/clay-utils.js +84 -0
- package/dist/clay.js +146 -0
- package/dist/clay.standalone.js +83090 -58706
- package/dist/m/attrs/add-from-T5LJXFFI.js +1 -0
- package/dist/m/attrs/onaftersave-OKSWEJQF.js +1 -0
- package/dist/m/attrs/refetch-on-save-NWPPXOCZ.js +1 -0
- package/dist/m/attrs/save-freeze-FUP4Q4X3.js +1 -0
- package/dist/m/c-2AZDZWCK.js +1 -0
- package/dist/m/c-2JL6E75N.js +1 -0
- package/dist/m/c-2M73252O.js +1 -0
- package/dist/m/c-2SPVQSHC.js +1 -0
- package/dist/m/c-33HUYEDI.js +1 -0
- package/dist/m/c-33JJ6CBX.js +2 -0
- package/dist/m/c-35NBGMZB.js +1 -0
- package/dist/m/c-3GJ4SDE2.js +1 -0
- package/dist/m/c-3IQRECYS.js +1 -0
- package/dist/m/c-3OWDMNJR.js +2 -0
- package/dist/m/c-46XYM55L.js +1 -0
- package/dist/m/c-4B6H4G5V.js +1 -0
- package/dist/m/c-4DRMS4QG.js +9 -0
- package/dist/m/c-4FFHZM32.js +1 -0
- package/dist/m/c-4JZDZFF6.js +1 -0
- package/dist/m/c-4L3BTFRK.js +1 -0
- package/dist/m/c-4Q2XTQ2N.js +2 -0
- package/dist/m/c-4WKFKEKF.js +1 -0
- package/dist/m/c-4YSCRICO.js +1 -0
- package/dist/m/c-54RCDCBU.js +1 -0
- package/dist/m/c-5M4YEKCX.js +4 -0
- package/dist/m/c-5R4PTRG2.js +1 -0
- package/dist/m/c-5V3MOVJT.js +1 -0
- package/dist/m/c-5VYOWDTI.js +1 -0
- package/dist/m/c-5Y6TNX5W.js +34 -0
- package/dist/m/c-5YIHJ3TJ.js +1 -0
- package/dist/m/c-66O32MV3.js +28 -0
- package/dist/m/c-6HMB24EV.js +1 -0
- package/dist/m/c-7DJDKPGL.js +1 -0
- package/dist/m/c-7O6AFR65.js +1 -0
- package/dist/m/c-7SWMYKAI.js +1 -0
- package/dist/m/c-7VGZ7RU5.js +1 -0
- package/dist/m/c-A7LS5UZW.js +1 -0
- package/dist/m/c-ANQTJ3B5.js +2 -0
- package/dist/m/c-AQLFEATB.js +1 -0
- package/dist/m/c-AYVOREBE.js +1 -0
- package/dist/m/c-B2ZXPOS3.js +3 -0
- package/dist/m/c-BBVGTQG7.js +1 -0
- package/dist/m/c-BMIZKMPV.js +1 -0
- package/dist/m/c-BTDI4Y23.js +1 -0
- package/dist/m/c-BWFVSBDF.js +1 -0
- package/dist/m/c-BYTKL6UX.js +1 -0
- package/dist/m/c-CFHW5AMY.js +6 -0
- package/dist/m/c-CJZSLMVQ.js +1 -0
- package/dist/m/c-CYWLPPUS.js +1 -0
- package/dist/m/c-CZUSOB7V.js +1 -0
- package/dist/m/c-DBE6ORSI.js +1 -0
- package/dist/m/c-DCFSEJZG.js +1 -0
- package/dist/m/c-DNZ5IFM6.js +1 -0
- package/dist/m/c-EDHUR4MX.js +1 -0
- package/dist/m/c-EJTGYSLN.js +1 -0
- package/dist/m/c-EY6UOM54.js +1 -0
- package/dist/m/c-F3CKJTJS.js +1 -0
- package/dist/m/c-F7Y6FLPY.js +1 -0
- package/dist/m/c-FA4DZVTC.js +1 -0
- package/dist/m/c-FILLTJA7.js +1 -0
- package/dist/m/c-G2BUZITR.js +1 -0
- package/dist/m/c-GB3JTV6E.js +1 -0
- package/dist/m/c-GBGWXTX4.js +1 -0
- package/dist/m/c-GHBCCVG4.js +1 -0
- package/dist/m/c-GJAEGGXY.js +1 -0
- package/dist/m/c-GOWBDM6J.js +1 -0
- package/dist/m/c-GQ6F6IDK.js +1 -0
- package/dist/m/c-H4LG442Q.js +1 -0
- package/dist/m/c-HA6INT6J.js +1 -0
- package/dist/m/c-HPURYVZS.js +2 -0
- package/dist/m/c-HRDCD3WN.js +67 -0
- package/dist/m/c-HT33EQRN.js +1 -0
- package/dist/m/c-HVYXIS72.js +1 -0
- package/dist/m/c-IB52R237.js +1 -0
- package/dist/m/c-IJUK2GPW.js +1 -0
- package/dist/m/c-IKWNE4R4.js +1 -0
- package/dist/m/c-IU3IYEU6.js +1 -0
- package/dist/m/c-IZ2EBRAJ.js +1 -0
- package/dist/m/c-J7CA54IP.js +1 -0
- package/dist/m/c-JAX2667S.js +6 -0
- package/dist/m/c-KI7M4AY3.js +1 -0
- package/dist/m/c-KIPQJX4B.js +1 -0
- package/dist/m/c-KKWLDOPM.js +1 -0
- package/dist/m/c-KR4UW4KW.js +1 -0
- package/dist/m/c-KY3VJGUA.js +8 -0
- package/dist/m/c-L4WQSC27.js +1 -0
- package/dist/m/c-LFPHCXY3.js +1 -0
- package/dist/m/c-LR4CGEPT.js +91 -0
- package/dist/m/c-LRPUO2MX.js +1 -0
- package/dist/m/c-LTGMXXKO.js +1 -0
- package/dist/m/c-LXENEBV7.js +1 -0
- package/dist/m/c-LZJPNR2W.js +1 -0
- package/dist/m/c-MMUIUUZG.js +2 -0
- package/dist/m/c-MTQHWQC3.js +1 -0
- package/dist/m/c-N326R2JD.js +1 -0
- package/dist/m/c-N7JPUPGC.js +1 -0
- package/dist/m/c-NMJRXKPC.js +8 -0
- package/dist/m/c-NRPJEVJS.js +1 -0
- package/dist/m/c-NUHP2XDB.js +1 -0
- package/dist/m/c-NZMNXVF6.js +1 -0
- package/dist/m/c-OCSZ4QGN.js +1 -0
- package/dist/m/c-OIBUTDXI.js +1 -0
- package/dist/m/c-OIDRZKAF.js +1 -0
- package/dist/m/c-OYTFP5QN.js +1 -0
- package/dist/m/c-P7KNDG34.js +1 -0
- package/dist/m/c-PPOSCAQD.js +1 -0
- package/dist/m/c-PQ5LK6QE.js +993 -0
- package/dist/m/c-PZ4XEPUP.js +2 -0
- package/dist/m/c-QHIWXHRO.js +1 -0
- package/dist/m/c-QHWJ5ZIJ.js +1 -0
- package/dist/m/c-QIX5BJYN.js +1 -0
- package/dist/m/c-QNKREOL6.js +1 -0
- package/dist/m/c-QQHEX6HA.js +1 -0
- package/dist/m/c-R7RMANJI.js +9 -0
- package/dist/m/c-RI4NT75Y.js +1 -0
- package/dist/m/c-RM7J7BV2.js +1 -0
- package/dist/m/c-RUJKSUQW.js +1 -0
- package/dist/m/c-RVMWGXEJ.js +1 -0
- package/dist/m/c-S7H2DRCB.js +1 -0
- package/dist/m/c-S7LK4KUE.js +1 -0
- package/dist/m/c-SGCCC4FW.js +25 -0
- package/dist/m/c-SGIA4IEQ.js +188 -0
- package/dist/m/c-SWRJFCNN.js +1 -0
- package/dist/m/c-T4VO4OCB.js +1 -0
- package/dist/m/c-TCCA5BZN.js +2 -0
- package/dist/m/c-TQEMVJCS.js +1 -0
- package/dist/m/c-TQZ2JYHD.js +1 -0
- package/dist/m/c-TR6RMDQ7.js +3 -0
- package/dist/m/c-TRS6TM6O.js +1 -0
- package/dist/m/c-UGHH4MB3.js +1 -0
- package/dist/m/c-UKHTLWUW.js +1 -0
- package/dist/m/c-UL2YUY52.js +1 -0
- package/dist/m/c-UNN7LWCT.js +1 -0
- package/dist/m/c-UXBMRDZB.js +235 -0
- package/dist/m/c-V7PZZRG7.js +1 -0
- package/dist/m/c-VAK7SG37.js +1 -0
- package/dist/m/c-VDSS4K3Z.js +1 -0
- package/dist/m/c-VFX45IZQ.js +1 -0
- package/dist/m/c-VHNSBD2M.js +1 -0
- package/dist/m/c-VKEDWYDF.js +1 -0
- package/dist/m/c-VL52ADDR.js +1 -0
- package/dist/m/c-WN5AY3OZ.js +1 -0
- package/dist/m/c-WNYBLIOZ.js +1 -0
- package/dist/m/c-WRBKEJD4.js +1 -0
- package/dist/m/c-WWDBYXLK.js +1 -0
- package/dist/m/c-WYFDLITL.js +1 -0
- package/dist/m/c-XN6MBKI6.js +67 -0
- package/dist/m/c-XNNW2CWK.js +1 -0
- package/dist/m/c-XPELB6E5.js +1 -0
- package/dist/m/c-XQXZAO7N.js +1 -0
- package/dist/m/c-Y6USGTS5.js +5 -0
- package/dist/m/c-YDH7Q3NY.js +1 -0
- package/dist/m/c-YG2NJYS6.js +135 -0
- package/dist/m/c-Z36J63PP.js +1 -0
- package/dist/m/c-Z4VRC7GU.js +7 -0
- package/dist/m/c-Z6K52OLP.js +19 -0
- package/dist/m/c-ZDY2MDAA.js +21 -0
- package/dist/m/c-ZE46QDIH.js +1 -0
- package/dist/m/c-ZUCOKOHT.js +1 -0
- package/dist/m/core/admin-attrs-VGNLAUDK.js +1 -0
- package/dist/m/core/autosave-E4PEFPZ6.js +1 -0
- package/dist/m/core/conflict-notice-VQ6Y64PH.js +1 -0
- package/dist/m/core/draft-mode-WSQAT67S.js +1 -0
- package/dist/m/core/host-permission-XN3K2IW3.js +1 -0
- package/dist/m/core/is-edit-mode-JXHDVGUL.js +1 -0
- package/dist/m/core/persist-HKHA66IY.js +3 -0
- package/dist/m/core/recovery-TBBSICE2.js +1 -0
- package/dist/m/core/save-WUCHTQBE.js +1 -0
- package/dist/m/core/save-core-FJVHT5M3.js +1 -0
- package/dist/m/core/snapshot-F3SWDZMM.js +1 -0
- package/dist/m/core/unsaved-warning-STKBHE6G.js +1 -0
- package/dist/m/dom/all-APS5ZSKP.js +1 -0
- package/dist/m/dom/dom-helpers-L7OSR6S4.js +1 -0
- package/dist/m/events/index-23DPTUT4.js +1 -0
- package/dist/m/internals/index-WOVAP3RU.js +1 -0
- package/dist/m/lib/cache-bust-CGWT6ZJI.js +1 -0
- package/dist/m/lib/region-policy-SB2AWVG5.js +1 -0
- package/dist/m/loader-HXX6YNH5.js +1 -0
- package/dist/m/manifest-F22DEDAC.js +1 -0
- package/dist/m/manifest-edit-C3C7376B.js +1 -0
- package/dist/m/manifest.json +3491 -0
- package/dist/m/options/options-2LH76JQ3.js +1 -0
- package/dist/m/page/editor-XUTB2HB2.js +189 -0
- package/dist/m/plugins/ai-edit-ZQ4CGWIP.js +6 -0
- package/dist/m/plugins/bind-text-NX46N5UV.js +1 -0
- package/dist/m/plugins/cms-HP3LSTPN.js +2293 -0
- package/dist/m/plugins/demo-ZIBFAA3R.js +1 -0
- package/dist/m/plugins/derive-UAAA4V4S.js +1 -0
- package/dist/m/plugins/indicator-PV4YW2ID.js +1 -0
- package/dist/m/plugins/live-NUTTXSBS.js +1 -0
- package/dist/m/plugins/menu-HCKO3DSP.js +138 -0
- package/dist/m/plugins/message-LQ6EDH4V.js +1 -0
- package/dist/m/plugins/page-KSUH7G6J.js +2 -0
- package/dist/m/plugins/page-view-W73OW7WI.js +1 -0
- package/dist/m/plugins/people-AJJ32YCG.js +1 -0
- package/dist/m/plugins/quickcrop-QNY3PKLD.js +26 -0
- package/dist/m/plugins/quickcrop-QNY3PKLD.js.LEGAL.txt +7 -0
- package/dist/m/plugins/richclay-RC3L2F6X.js +517 -0
- package/dist/m/plugins/richclay-RC3L2F6X.js.LEGAL.txt +1 -0
- package/dist/m/plugins/sortable-YRMQX3ZU.js +1 -0
- package/dist/m/plugins/source-KHK5UUSK.js +1 -0
- package/dist/m/plugins/undo-OF2L3CXU.js +1 -0
- package/dist/m/plugins/unsent-HJFLQJ2O.js +1 -0
- package/dist/m/plugins/upgrade-ZNYODP5Y.js +1 -0
- package/dist/m/plugins/upload-XSGNILUY.js +1 -0
- package/dist/m/plugins/visitor-drafts-XK5GW55Q.js +21 -0
- package/dist/m/plugins/visitor-drafts-owner-KSSH75EV.js +1 -0
- package/dist/m/plugins/wire-ZWVWKF76.js +1 -0
- package/dist/m/reader-core-ILWLXVMP.js +68 -0
- package/dist/m/route/route-KOCZSEGN.js +1 -0
- package/dist/m/sync/live-sync-4AUVXVJU.js +1 -0
- package/dist/m/ui/index-EVHKMKBL.js +1 -0
- package/dist/m/utils/index-4TJCVLT7.js +1 -0
- package/dist/m/vendor/Sortable.vendor-A755ITLN.js +3 -0
- package/dist/m/vendor/Sortable.vendor-A755ITLN.js.LEGAL.txt +1 -0
- package/dist/m/vendor/sap-core.vendor-A7BMUYZT.js +6 -0
- package/dist/offline-manifest.json +3800 -0
- package/dist/page/themes/light-1.css +406 -0
- package/dist/server/core.cjs +23662 -22860
- package/dist/server/offline-runtime.cjs +4954 -0
- package/dist/server/offline-runtime.mjs +4923 -0
- package/dist/server/rooms.mjs +9 -0
- package/docs/guide.md +1078 -669
- package/entries/all.js +2 -0
- package/entries/clay-data.js +1 -1
- package/entries/clay-dom.js +2 -0
- package/entries/clay-events.js +2 -0
- package/entries/clay-internals.js +2 -0
- package/entries/clay-options.js +2 -0
- package/entries/clay-router.js +2 -0
- package/entries/clay-ui.js +2 -0
- package/entries/clay-utils.js +2 -0
- package/entries/clay.js +2 -0
- package/entries/sap.js +6 -6
- package/fonts/ibm-plex-mono-LICENSE +93 -0
- package/fonts/ibm-plex-mono-latin-300-normal.woff2 +0 -0
- package/fonts/ibm-plex-mono-latin-400-italic.woff2 +0 -0
- package/fonts/ibm-plex-mono-latin-400-normal.woff2 +0 -0
- package/fonts/ibm-plex-mono-latin-500-normal.woff2 +0 -0
- package/fonts/ibm-plex-mono-latin-600-normal.woff2 +0 -0
- package/fonts/ibm-plex-sans-LICENSE +93 -0
- package/fonts/ibm-plex-sans-latin-400-normal.woff2 +0 -0
- package/fonts/ibm-plex-sans-latin-500-normal.woff2 +0 -0
- package/fonts/ibm-plex-sans-latin-600-normal.woff2 +0 -0
- package/fonts/ibm-plex.css +71 -0
- package/fonts/inter-LICENSE +93 -0
- package/fonts/inter-cyrillic-ext-wght-normal.woff2 +0 -0
- package/fonts/inter-cyrillic-wght-normal.woff2 +0 -0
- package/fonts/inter-greek-ext-wght-normal.woff2 +0 -0
- package/fonts/inter-greek-wght-normal.woff2 +0 -0
- package/fonts/inter-latin-ext-wght-normal.woff2 +0 -0
- package/fonts/inter-latin-wght-normal.woff2 +0 -0
- package/fonts/inter-vietnamese-wght-normal.woff2 +0 -0
- package/fonts/inter.css +62 -0
- package/fonts/newsreader-LICENSE +93 -0
- package/fonts/newsreader-latin-ext-opsz-normal.woff2 +0 -0
- package/fonts/newsreader-latin-opsz-normal.woff2 +0 -0
- package/fonts/newsreader-vietnamese-opsz-normal.woff2 +0 -0
- package/fonts/newsreader.css +26 -0
- package/fonts/work-sans-LICENSE +93 -0
- package/fonts/work-sans-latin-wght-normal.woff2 +0 -0
- package/fonts/work-sans.css +8 -0
- package/package.json +20 -3
- package/packed-contract.json +1 -0
- package/src/attrs/add-from.js +27 -4
- package/src/attrs/save-freeze.js +7 -52
- package/src/core/admin-attrs.js +119 -12
- package/src/core/admin-contenteditable.js +12 -10
- package/src/core/admin-inputs.js +14 -15
- package/src/core/admin-onclick.js +2 -0
- package/src/core/autosave.js +74 -21
- package/src/core/conflict-download.js +22 -0
- package/src/core/conflict-notice-ui.js +1173 -0
- package/src/core/conflict-notice.js +140 -697
- package/src/core/edit-mode.js +147 -14
- package/src/core/etag.js +30 -12
- package/src/core/host-meta.js +72 -8
- package/src/core/host-permission.js +29 -0
- package/src/core/is-edit-mode.js +145 -12
- package/src/core/mode-key.js +125 -0
- package/src/core/mode-lifecycle.js +544 -0
- package/src/core/mode-receipt.js +30 -0
- package/src/core/mode-refusal.js +13 -0
- package/src/core/mode-resources.js +52 -0
- package/src/core/mode-support.js +82 -0
- package/src/core/mode-switch.js +259 -0
- package/src/core/mode-transition.js +112 -0
- package/src/core/page-data-write.js +305 -0
- package/src/core/page-data.js +26 -227
- package/src/core/page-format-wire.js +4 -0
- package/src/core/page-format.js +58 -0
- package/src/core/persist.js +37 -9
- package/src/core/preserve-authored.js +114 -0
- package/src/core/recovery.js +772 -0
- package/src/core/runtime-url.js +105 -0
- package/src/core/save-core.js +109 -12
- package/src/core/save-replace.js +72 -0
- package/src/core/save-size-notice.js +134 -0
- package/src/core/save-size.js +140 -0
- package/src/core/save.js +805 -118
- package/src/core/snapshot.js +121 -11
- package/src/core/source-map.js +157 -9
- package/src/core/unsaved-warning.js +14 -4
- package/src/core/upgrade-run.js +408 -0
- package/src/core/version.js +18 -0
- package/src/lib/assets.js +30 -0
- package/src/lib/autosave-debug-gate.js +50 -0
- package/src/lib/autosave-scheduler.js +141 -0
- package/src/lib/boot-imports.js +8 -0
- package/src/lib/derived.js +3 -1
- package/src/lib/dirty-gate.js +15 -0
- package/src/lib/doc-storage.js +33 -0
- package/src/lib/effect.js +9 -4
- package/src/lib/mutation.js +4 -2
- package/src/lib/offline-runtime.js +226 -0
- package/src/lib/preload.js +48 -0
- package/src/lib/root-attrs.js +1 -1
- package/src/lib/trash.js +18 -0
- package/src/lib/undo/capture-move.js +152 -0
- package/src/live/local-channel.js +61 -0
- package/src/live/local-lane.js +60 -9
- package/src/live/server-lane.js +6 -3
- package/src/loader-logic.js +76 -15
- package/src/loader.js +218 -30
- package/src/page/adopt-boot.js +76 -22
- package/src/page/adopt.js +25 -4
- package/src/page/awareness.js +230 -0
- package/src/page/blocks.js +79 -5
- package/src/page/blocksel.js +20 -4
- package/src/page/board-face.js +13 -0
- package/src/page/board-panel.js +5 -17
- package/src/page/board-style.js +2 -13
- package/src/page/board-view.js +1 -11
- package/src/page/board-views.js +17 -0
- package/src/page/board.js +2 -2
- package/src/page/boot-pack.js +26 -0
- package/src/page/boot.js +237 -0
- package/src/page/checklist.js +1 -1
- package/src/page/chrome.js +411 -61
- package/src/page/csv-import.js +17 -2
- package/src/page/document-title-dom.js +40 -0
- package/src/page/document-title-runtime.js +76 -0
- package/src/page/document-title.js +9 -0
- package/src/page/drag.js +48 -13
- package/src/page/drop.js +2 -1
- package/src/page/editor.js +330 -86
- package/src/page/feature-loader.js +72 -0
- package/src/page/features/board.js +12 -0
- package/src/page/features/code.js +13 -0
- package/src/page/features/media.js +290 -0
- package/src/page/features/registry.js +23 -0
- package/src/page/features/table.js +383 -0
- package/src/page/{tool-view.js → features/tool.js} +33 -2
- package/src/page/format-codec.js +215 -0
- package/src/page/format-gate.js +179 -0
- package/src/page/format-level.js +157 -0
- package/src/page/highlight-slot.js +23 -0
- package/src/page/highlight.js +30 -16
- package/src/page/history-intent.js +78 -0
- package/src/page/inline.js +18 -25
- package/src/page/items.js +52 -11
- package/src/page/link.js +1 -0
- package/src/page/markdown.js +86 -1
- package/src/page/media-views.js +3 -0
- package/src/page/media.js +33 -245
- package/src/page/outline-cache.js +11 -0
- package/src/page/placeholder.js +27 -7
- package/src/page/projection.js +196 -50
- package/src/page/reader-patch.js +306 -0
- package/src/page/recover.js +1 -1
- package/src/page/rich/page-tool.js +1 -4
- package/src/page/runtime-owner.js +27 -0
- package/src/page/save-projection.js +7 -4
- package/src/page/schema.js +14 -0
- package/src/page/table-rect-key.js +3 -0
- package/src/page/table-select.js +4 -3
- package/src/page/table-style.js +1 -1
- package/src/page/table-views.js +3 -0
- package/src/page/table.js +8 -293
- package/src/page/themes/light-1.css +139 -2
- package/src/page/themes/light-1.source.css +269 -0
- package/src/page/tool-capability.js +3 -0
- package/src/page/tool-views.js +3 -0
- package/src/page/view.js +390 -107
- package/src/page/ybind/awareness.js +172 -0
- package/src/page/ybind/binding.js +9 -1
- package/src/page/ybind/bridge.js +50 -47
- package/src/page/ybind/decode.js +52 -19
- package/src/page/ybind/doc.js +27 -2
- package/src/page/ybind/group.js +12 -3
- package/src/page/ybind/index.js +2 -0
- package/src/page/ybind/lineage.js +71 -0
- package/src/page/ybind/marks.js +25 -1
- package/src/page/ybind/migrate.js +48 -13
- package/src/page/ybind/moves.js +32 -21
- package/src/page/ybind/positions.js +50 -0
- package/src/page/ybind/provider.js +84 -22
- package/src/page/ybind/recovery-proof.js +191 -0
- package/src/page/ybind/recovery-replay.js +130 -0
- package/src/page/ybind/tokens.js +15 -6
- package/src/page/ybind/walk.js +10 -3
- package/src/page/ybind/writer.js +48 -4
- package/src/plugins/ai-edit.js +167 -32
- package/src/plugins/bind-text.js +218 -0
- package/src/plugins/cms.js +93 -0
- package/src/plugins/indicator.js +57 -5
- package/src/plugins/live.js +282 -34
- package/src/plugins/menu/claygoo.svg.js +1 -0
- package/src/plugins/menu/seo-head.js +323 -0
- package/src/plugins/menu/seo.js +849 -0
- package/src/plugins/menu.js +425 -0
- package/src/plugins/page-view.js +131 -0
- package/src/plugins/page.js +1022 -275
- package/src/plugins/people.js +158 -31
- package/src/plugins/richclay.js +119 -9
- package/src/plugins/sortable.js +370 -60
- package/src/plugins/source.js +189 -366
- package/src/plugins/undo.js +289 -19
- package/src/plugins/unsent.js +132 -0
- package/src/plugins/upgrade-run.js +1 -0
- package/src/plugins/upgrade.js +210 -0
- package/src/plugins/upload-task.js +571 -0
- package/src/plugins/upload-ui.js +265 -0
- package/src/plugins/upload.js +34 -153
- package/src/plugins/visitor-drafts/inert.js +32 -0
- package/src/plugins/visitor-drafts/owner-chip.js +3 -0
- package/src/plugins/visitor-drafts/prompt.js +2 -2
- package/src/plugins/visitor-drafts-owner.js +85 -0
- package/src/plugins/visitor-drafts.js +31 -42
- package/src/plugins/wire.js +82 -1
- package/src/reader-core.js +26 -0
- package/src/recovery/conflicts.js +287 -0
- package/src/recovery/identity.js +154 -0
- package/src/recovery/store.js +792 -0
- package/src/recovery/undo.js +257 -0
- package/src/server/checkpoint/index.js +68 -4
- package/src/server/offline-runtime/index.js +214 -0
- package/src/server/rooms/index.js +2 -1
- package/src/server/rooms/live-data-rooms.js +2 -2
- package/src/server/rooms/page-admission.js +33 -0
- package/src/server/rooms/page-lineage.js +56 -0
- package/src/server/rooms/page-rebase.js +11 -5
- package/src/server/rooms/page-state.js +2 -0
- package/src/server/rooms/page-write-admission.js +9 -3
- package/src/source/session.js +705 -0
- package/src/sync/conflict-revert.js +5 -4
- package/src/sync/conflicts-edit.js +119 -0
- package/src/sync/conflicts-facade.js +49 -0
- package/src/sync/conflicts.js +99 -1
- package/src/sync/editing-marker.js +37 -6
- package/src/sync/editing-sender.js +8 -1
- package/src/sync/live-sync-edit.js +63 -0
- package/src/sync/live-sync.js +364 -119
- package/src/sync/local-presence.js +187 -0
- package/src/sync/merge-declarations.js +10 -0
- package/src/sync/merge-engine.js +12 -0
- package/src/sync/presence-store.js +412 -0
- package/src/sync/presence-target.js +243 -0
- package/src/sync/presence.js +72 -41
- package/src/sync/saved-handoff.js +200 -0
- package/src/sync/saved-stream.js +535 -0
- package/src/sync/version-guard.js +92 -0
- package/src/sync/wire-profile.js +81 -0
- package/src/ui/bevel-controls.js +2 -8
- package/src/ui/page-scheme.js +7 -0
- package/src/ui/skins/cms.js +1 -1
- package/src/ui/theme-config.js +150 -0
- package/src/ui/theme.js +6 -138
- package/src/ui/toast-lazy.js +11 -0
- package/src/vendor/LICENSES-optional.md +253 -0
- package/src/vendor/highlight.vendor.js +3 -0
- package/src/vendor/hljs-bash.vendor.js +2 -0
- package/src/vendor/hljs-css.vendor.js +2 -0
- package/src/vendor/hljs-javascript.vendor.js +2 -0
- package/src/vendor/hljs-json.vendor.js +2 -0
- package/src/vendor/hljs-python.vendor.js +2 -0
- package/src/vendor/hljs-xml.vendor.js +2 -0
- package/src/vendor/hyper-html-api-data.vendor.js +1 -1
- package/src/vendor/hyper-html-api-upgrade.vendor.js +5 -0
- package/src/vendor/hyper-morph-identity.vendor.js +2 -0
- package/src/vendor/hyper-morph-json.vendor.js +3 -0
- package/src/vendor/hyper-morph.vendor.js +6 -6
- package/src/vendor/hyper-undo.vendor.js +1 -1
- package/src/vendor/hypercms.vendor.js +169 -84
- package/src/vendor/marked.vendor.js +68 -0
- package/src/vendor/overtype.vendor.js +994 -0
- package/src/vendor/richclay.vendor.js +17 -17
- package/src/vendor/sap-core.vendor.js +5 -5
- package/src/vendor/sap-ownership.vendor.js +11 -7
package/entries/sap.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// GENERATED — do not edit. Vendored from sapjs/dist/sap.min.js via sapjs
|
|
2
2
|
// `npm run copy-to-clayjs`. Edit the sapjs source and re-run.
|
|
3
3
|
(function () {
|
|
4
|
-
var Sap=(()=>{var
|
|
5
|
-
`+(e[0]==="W"?"sap \u26A0 ":"sap \u2717 ")+e+" "+o];return
|
|
6
|
-
`)),
|
|
7
|
-
${t}`:`"use strict"; return (${t});`;n={fn:new Function(...
|
|
4
|
+
var Sap=(()=>{var Ht=Object.defineProperty;var _n=Object.getOwnPropertyDescriptor;var Tn=Object.getOwnPropertyNames;var Nn=Object.prototype.hasOwnProperty;var Ln=(t,e)=>{for(var r in e)Ht(t,r,{get:e[r],enumerable:!0})},Rn=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Tn(e))!Nn.call(t,o)&&o!==r&&Ht(t,o,{get:()=>e[o],enumerable:!(n=_n(e,o))||n.enumerable});return t};var Cn=t=>Rn(Ht({},"__esModule",{value:!0}),t);var Nr={};Ln(Nr,{Sap:()=>jt,default:()=>Tr,mount:()=>$r,mountAll:()=>kn,runtime:()=>_r});function se(t){let e=!1,r=new Set,n=[];function o(u){u&&(n.push(u),n.length>8&&n.shift())}function i(u,E){if(o(E),u._broken){if(E==="mutation")return;p(u)}r.add(u),!e&&(e=!0,queueMicrotask(s))}function s(){e=!1;let u=[...r];r.clear();for(let E of u)g(E)}function g(u,E=!1){if(!(u._broken||u.halted)){if(u._passes=(u._passes||0)+1,u._passes>50){u._broken=!0,u._breakerRing=n.slice(),t(u,{breaker:!0});return}u._resetArmed||(u._resetArmed=!0,setTimeout(()=>{u._passes=0,u._resetArmed=!1},0)),t(u,E?{full:!0}:{})}}function b(u,E){o(E),u._broken&&p(u),g(u,!0)}function p(u){u._broken=!1,u._passes=0}return{schedule:i,runNow:b,rearm:p,ring:n}}var Vt={E01:{slug:"foreign-dialect",behavior:"HALT"},E02:{slug:"moustaches-in-text",behavior:"HALT"},E04:{slug:"duplicate-declaration",behavior:"HALT"},E05:{slug:"reserved-name",behavior:"HALT"},E06:{slug:"global-html-name",behavior:"HALT"},E07:{slug:"calc-cycle",behavior:"ERR"},E08:{slug:"expression-syntax",behavior:"HALT"},E10:{slug:"orphan-item",behavior:"HALT"},E12:{slug:"unknown-state-key",behavior:"ERR"},E15:{slug:"write-to-undeclared-key",behavior:"ERR"},E16:{slug:"write-to-computed-field",behavior:"ERR"},E17:{slug:"unresolvable-action-target",behavior:"HALT"},E18:{slug:"paint-on-form-control",behavior:"HALT"},E20:{slug:"bind-on-non-control",behavior:"HALT"},E22:{slug:"format-type",behavior:"ERR"},E24:{slug:"runtime-expression-throw",behavior:"ERR"},E26:{slug:"circuit-breaker",behavior:"HALT"},E30:{slug:"attr-on-bound-control",behavior:"HALT"},E31:{slug:"password-without-transient",behavior:"HALT"},E32:{slug:"file-bind",behavior:"HALT"},E33:{slug:"dialog-state-open",behavior:"HALT"},E34:{slug:"transient-persist-collision",behavior:"HALT"},E35:{slug:"presence-state-misuse",behavior:"HALT"},E40:{slug:"each-not-array",behavior:"ERR"},E41:{slug:"each-bad-key",behavior:"ERR"},E42:{slug:"each-template",behavior:"ERR"},E43:{slug:"bind-in-each-row",behavior:"ERR"},E50:{slug:"needs-full-sapjs",behavior:"HALT"},W03:{slug:"unknown-colon-attribute",behavior:"WARN"},W04:{slug:"expression-in-when",behavior:"WARN"},W30:{slug:"nonzero-mount-writes",behavior:"WARN"},W31:{slug:"detail-dialog-saved-open",behavior:"WARN"}},et=["disabled","readonly","required","checked","selected","multiple","open","inert","autofocus","novalidate","hidden"],ft=new Set(["title","style","hidden","lang","dir","translate","class","id","nonce","autofocus","tabindex","contenteditable","spellcheck","draggable","role","slot","part","name","value","type","itemscope","itemtype","itemid","itemprop","itemref"]),xt=new Set(["sap","scope","items","item","template","bind","calc","text","show","attr","set","trigger","move","sort","detail","each","effect","invalid","confirm","transient","default","persist","sortable","editmode"]);function St(t){if(!t||t.nodeType!==1)return"?";if(t.id)return`${t.tagName.toLowerCase()}#${t.id}`;let e=[],r=t,n=0;for(;r&&r.nodeType===1&&n<4;){let o=r.tagName.toLowerCase();if(r.hasAttribute("sap"))o+="[sap]";else if(r.parentElement){let i=0,s=0;for(let g=r.parentElement.firstElementChild;g;g=g.nextElementSibling)g.tagName===r.tagName&&(i++,g===r&&(s=i));i>1&&(o+=`:nth-of-type(${s})`)}if(e.unshift(o),r.hasAttribute("sap"))break;r=r.parentElement,n++}return e.join(" > ")}var tt=class{constructor(e){this.appName=e,this.errors=[],this.warnings=[],this.halted=!1,this.haltReason=null}block(e,r,n={}){let o=(Vt[e]||{}).slug||"error",i={code:e,slug:o,el:St(r),attr:n.attr||null,expr:n.expr||null,key:n.key||null,problem:n.problem||"",didYouMean:n.didYouMean||null,fix:n.fix||null,phase:n.phase||"runtime"},s=[`
|
|
5
|
+
`+(e[0]==="W"?"sap \u26A0 ":"sap \u2717 ")+e+" "+o];return s.push(` at ${i.el}${i.attr?` \u2014 ${i.attr}="${i.expr??""}"`:""}`),i.problem&&s.push(` problem: ${i.problem}`),i.didYouMean&&s.push(` did you mean: ${i.didYouMean}`),i.fix&&s.push(` fix: ${i.fix}`),(e[0]==="W"?console.warn:console.error)(s.join(`
|
|
6
|
+
`)),i}error(e,r,n={}){let o=this.block(e,r,n);return this.errors.push(o),o}warn(e,r,n={}){let o=this.block(e,r,n);return this.warnings.push(o),o}report(){return{ok:this.errors.length===0&&!this.halted,app:this.appName,halted:this.halted,haltReason:this.haltReason,errors:this.errors.slice(),warnings:this.warnings.slice()}}};function B(t,e){t&&t.getAttribute("sap-error")!==e&&t.setAttribute("sap-error",e)}function nt(t){t&&t.hasAttribute("sap-error")&&t.removeAttribute("sap-error")}function lt(t,e){let r=null,n=3;for(let o of e){let i=Dn(t,o);i<n&&(n=i,r=o)}return r}function Dn(t,e){let r=t.length,n=e.length,o=Array.from({length:r+1},(i,s)=>[s,...new Array(n).fill(0)]);for(let i=0;i<=n;i++)o[0][i]=i;for(let i=1;i<=r;i++)for(let s=1;s<=n;s++)o[i][s]=Math.min(o[i-1][s]+1,o[i][s-1]+1,o[i-1][s-1]+(t[i-1]===e[s-1]?0:1));return o[r][n]}var Fn=new Set(et),Mn={readonly:"readOnly",novalidate:"noValidate"},Pn=0,ae=new WeakMap;function kt(t,e="sap"){let r=t.getAttribute("data-id");if(r)return r;if(t.id)return t.id;let n=ae.get(t);return n||(n=`${e}-${(Pn++).toString(36)}`,ae.set(t,n)),n}function ue(t,e="row"){for(;;){let r=`${e}-${Math.random().toString(36).slice(2,8)}`;if(!t.getElementById(r)&&!t.querySelector(`[data-id="${r}"]`))return r}}function In(t){return t.hasAttribute("scope")||t.hasAttribute("items")||t.hasAttribute("detail")||t.hasAttribute("each")}function On(t){return t.tagName==="TEMPLATE"||t.hasAttribute("sap-ignore")||t.hasAttribute("template")||t.hasAttribute("cms-template")}function W(t,e){for(let n=t.firstElementChild;n;n=n.nextElementSibling)r(n);function r(n){if(On(n))return;let o=In(n);if(e(n,o),!o)for(let i=n.firstElementChild;i;i=i.nextElementSibling)r(i)}}function P(t){let e=t;for(;e;){if(e.hasAttribute("sap")||e.hasAttribute("scope")||e.hasAttribute("item")||e.hasAttribute("detail"))return e;e=e.parentElement}return null}function Y(t){for(let e=t;e&&e.nodeType===1;e=e.parentElement){if(e._sapEachRow)return e;if(e.hasAttribute("item")||e.hasAttribute("sap"))return null}return null}function $t(t){let e=t;for(;e;){if(e.hasAttribute("detail")||e.hasAttribute("item"))return e;e=e.parentElement}return null}function dt(t){let e=t;for(;e;){if(e.hasAttribute("detail"))return e;e=e.parentElement}return null}function X(t,e){if(t.hasAttribute("item")&&t.getAttribute("bind")===e)return t;let r=null;return W(t,n=>{!r&&n.getAttribute("bind")===e&&(r=n)}),r}function rt(t,e){let r=null;return W(t,n=>{!r&&n.getAttribute("items")===e&&(r=n)}),r}function ot(t,e){return!t||t.nodeType!==1||!t.hasAttribute("item")?!1:X(t,e)||rt(t,e)?!0:D(t.getAttribute("state")||"").some(r=>r.name===e)}function ce(t){let e=t&&t.$el;return e&&e.nodeType===1&&e.isConnected&&e.hasAttribute("item")?e:null}function _t(t){return!!t.closest("form[trigger-add]")}function H(t){let e=[];for(let r=t.firstElementChild;r;r=r.nextElementSibling)r.hasAttribute("item")&&!r.hasAttribute("template")&&!r.hasAttribute("cms-template")&&e.push(r);return e}function zt(t,e){if(!t||!e)return null;let r=[...t.querySelectorAll(`template[items="${e}"]`)].find(o=>o.closest("[sap]")===t),n=r&&r.content.firstElementChild;return n&&n.hasAttribute("item")?n:null}function Tt(t){for(let e=t.firstElementChild;e;e=e.nextElementSibling)if(e.hasAttribute("item")&&e.hasAttribute("template"))return e;return zt(t.closest("[sap]"),t.getAttribute("items"))}function D(t){let e=[];if(!t)return e;for(let r of t.trim().split(/\s+/)){if(!r)continue;let n=r,o,i=n.indexOf("=");i>=0&&(o=n.slice(i+1),n=n.slice(0,i));let s=n.split(":"),g=s[0],b="string",p=!1;for(let x of s.slice(1))x==="num"?b="num":x==="bool"?b="bool":x==="presence"?b="presence":x==="transient"&&(p=!0);let u=g,E=u.startsWith("data-")&&u.length>5?u.slice(5).replace(/-([a-z])/g,(x,$)=>$.toUpperCase()):u;e.push({name:E,attr:u,type:b,default:o,transient:p})}return e}function G(t,e){if(e==="num"){if(t==null||t==="")return 0;let r=Number(t);return Number.isNaN(r)?0:r}return e==="bool"?t==="true"||t===""||t==="1":t??""}function Ut(t,e){return e==="bool"?t?"true":"false":t==null?"":String(t)}function Gt(t,e){return Fn.has(e)&&typeof t[Mn[e]||e]=="boolean"}function K(t,e){return e.type==="presence"||e.type!=="num"&&Gt(t,e.attr||e.name)}function pt(t){return t.default!=null?t.default:t.type==="num"?"0":t.type==="bool"?"false":""}function fe(t,e){let r=e.attr||e.name;if(K(t,e))return t.hasAttribute(r);let n=t.getAttribute(r);return G(n??pt(e),e.type)}function le(t,e){return K(t,e)?e.default!=null?G(e.default,"bool"):!1:G(pt(e),e.type)}function mt(t,e,r){let n=e.attr||e.name;if(K(t,e)){r?t.hasAttribute(n)||t.setAttribute(n,""):t.hasAttribute(n)&&t.removeAttribute(n);return}t.setAttribute(n,Ut(r,e.type))}function Nt(t,e){let r=e.attr||e.name,n=t._sapTransient||(t._sapTransient={});if(!(e.name in n)){let o=t.getAttribute(r);o==null&&(o=pt(e)),n[e.name]=G(o,e.type)}return t.hasAttribute(r)&&t.removeAttribute(r),n[e.name]}function ht(t,e,r){let n=e.attr||e.name;(t._sapTransient||(t._sapTransient={}))[e.name]=r,t.hasAttribute(n)&&t.removeAttribute(n)}function bt(t,e,r){let n=String(r).split("."),o=n[n.length-1];if(n.length===1){let g=Wn(e,o);return g||(t.getAttribute("items")===o?t:t.querySelector(`[items="${o}"]:not(template)`))}let i=n[n.length-2],s=[...t.querySelectorAll(`[scope="${i}"]`)].find(g=>rt(g,o));return s?rt(s,o):null}function Wn(t,e){let r=P(t);for(;r;){if(r.getAttribute("items")===e)return r;let n=rt(r,e);if(n)return n;r=P(r.parentElement)}return null}function I(t){if(typeof t=="number")return t;if(t==null||t==="")return 0;let e=Number(typeof t=="string"?t.replace(/[$,%\s]/g,""):t);return Number.isNaN(e)?0:e}function Lt(t,e){return Array.isArray(t)?e==null?t:t.map(r=>typeof e=="function"?e(r):r?.[e]):[]}function Yt(t,e){return Lt(t,e).reduce((r,n)=>r+I(n),0)}function de(t,e){return Array.isArray(t)?e==null?t.length:t.reduce((r,n)=>r+(e(n)?1:0),0):0}function pe(t,e){let r=Lt(t,e);return r.length?Yt(t,e)/r.length:0}function me(t,e){let r=Lt(t,e).filter(n=>n!=null&&n!=="");return r.length?r.every(n=>typeof n=="number"||!Number.isNaN(Number(n)))?Math.min(...r.map(Number)):r.reduce((n,o)=>String(n)<=String(o)?n:o):0}function he(t,e){let r=Lt(t,e).filter(n=>n!=null&&n!=="");return r.length?r.every(n=>typeof n=="number"||!Number.isNaN(Number(n)))?Math.max(...r.map(Number)):r.reduce((n,o)=>String(n)>=String(o)?n:o):0}function be(t,e,r){let n=I(t)===1?e:r??e+"s";return`${t} ${n}`}function ge(t,e){let r=new Date(t),n=new Date(e);return Number.isNaN(+r)||Number.isNaN(+n)?0:Math.round((n-r)/864e5)}function q(t){return typeof t=="number"?t:Number(t)}var it={usd:t=>"$"+q(t).toLocaleString("en-US",{maximumFractionDigits:0}),usd2:t=>"$"+q(t).toLocaleString("en-US",{minimumFractionDigits:2,maximumFractionDigits:2}),pct:t=>Math.round(q(t))+"%",pct1:t=>q(t).toFixed(1)+"%",int:t=>Math.round(q(t)).toLocaleString("en-US"),num:t=>q(t).toLocaleString("en-US"),num2:t=>q(t).toLocaleString("en-US",{minimumFractionDigits:2,maximumFractionDigits:2}),compact:t=>q(t).toLocaleString("en-US",{notation:"compact"}),date:t=>{let e=new Date(t);return Number.isNaN(+e)?String(t):e.toLocaleDateString("en-US")},clock:t=>{let e=q(t),r=Math.floor(e/100),n=r%10,o=Math.floor(r/10)%60;return`${Math.floor(r/600)}:${String(o).padStart(2,"0")}.${n}`}},Bn=new Set(["usd","usd2","pct","pct1","int","num","num2","compact","clock"]);function we(t,e){if(!t)return e==null?"":String(e);let r=it[t];if(typeof r!="function"){let n=new Error(`unknown format "${t}"`);throw n.sapCode="E22",n}if(Bn.has(t)){let n=typeof e=="number"?e:Number(e);if(!Number.isFinite(n)){let o=new Error(`format "${t}" received ${typeof e=="string"?`"${e}"`:e}`);throw o.sapCode="E22",o}}return r(e)}var qn=["state","item","el","root","fmt","num","sum","count","avg","min","max","plural","days"],Rt=new Map,ye=/\bstate\.([a-z][a-z0-9_]*)/g,Ae=/\bitem\.([a-z][a-z0-9_]*)/g;function jn(t){let e=new Set,r=new Set,n;for(ye.lastIndex=0;n=ye.exec(t);)e.add(n[1]);for(Ae.lastIndex=0;n=Ae.exec(t);)r.add(n[1]);return{state:e,item:r}}function C(t,e=!1){let r=(e?"!":"")+t,n=Rt.get(r);if(n)return n;Rt.size>512&&Rt.clear();try{let o=e?`"use strict";
|
|
7
|
+
${t}`:`"use strict"; return (${t});`;n={fn:new Function(...qn,o),src:t,statement:e,deps:jn(t),error:null}}catch(o){n={fn:null,src:t,statement:e,deps:{state:new Set,item:new Set},error:o}}return Rt.set(r,n),n}function J(t,e){return O(t,e.state,e.item,e.el??null,e.root)}function O(t,e,r,n,o){if(t.error)throw t.error;return t.fn(e,r,n,o,it,I,Yt,de,pe,me,he,be,ge)}function ve(t){let e=new Map;for(let s of t)e.set(s.name,s);let r=[],n=new Map,o=[];function i(s){let g=n.get(s.name);if(g!==1){if(g===0){let b=[...o.slice(o.indexOf(s.name)),s.name].join(" -> "),p=new Error(`calc: cycle: ${b}`);throw p.sapCode="E07",p.cycle=b,p}n.set(s.name,0),o.push(s.name);for(let b of s.entry.deps.state){let p=e.get(b);p&&p!==s&&i(p)}for(let b of s.entry.deps.item){let p=e.get(b);p&&p!==s&&i(p)}o.pop(),n.set(s.name,1),r.push(s)}}for(let s of t)i(s);return r}var gt={},Q=null,xe=!0,Dt=!1;function Se(){gt={}}function ke(t){let e=Dt;return Q?Xt(Q.takeRecords()):xe&&Hn(),Dt=!!Q&&t.getRootNode()===document,e}function $e(t){Dt=t}function Ft(){Q&&Xt(Q.takeRecords())}function Hn(){if(typeof document>"u"||typeof MutationObserver!="function"){xe=!1;return}Q=new MutationObserver(Xt),Q.observe(document,{attributes:!0,childList:!0,subtree:!0})}function Xt(t){for(let e of t)if(e.type==="attributes")e.target._sapPlan&&(e.target._sapPlan=null);else for(let r of e.addedNodes)r.nodeType===1&&_e(r)}function _e(t){t._sapPlan&&(t._sapPlan=null);for(let e=t.firstElementChild;e;e=e.nextElementSibling)_e(e)}function V(t){if(!Dt)return Ee(t);let e=t._sapPlan;return e&&e.gen===gt?e:t._sapPlan=Ee(t)}function Ee(t){let e={gen:gt,inert:t.tagName==="TEMPLATE",template:!1,item:!1,scope:!1,items:!1,detail:!1,each:!1,boundary:null,bind:null,transient:!1,decls:null,calcs:null,paints:null,effects:null,invalids:null};for(let r of t.attributes){let n=r.name,o=r.value,i=n.indexOf(":");if(i<0){switch(n){case"sap-ignore":e.inert=!0;break;case"cms-template":e.inert=!0;break;case"template":e.inert=!0,e.template=!0;break;case"item":e.item=!0;break;case"scope":e.scope=!0;break;case"items":e.items=!0;break;case"detail":e.detail=!0;break;case"each":e.each=!0;break;case"bind":e.bind=o;break;case"transient":e.transient=!0;break;case"state":e.decls=D(o);break;case"text":(e.paints||(e.paints=[])).push({kind:"text",fmt:null,entry:C(o)});break;case"show":(e.paints||(e.paints=[])).push({kind:"show",entry:C(o)});break;case"effect":(e.effects||(e.effects=[])).push({entry:C(o,!0)});break;case"invalid":(e.invalids||(e.invalids=[])).push({entry:C(o)});break}continue}let s=n.slice(0,i),g=n.slice(i+1);switch(s){case"calc":(e.calcs||(e.calcs=[])).push({name:g,entry:C(o)});break;case"text":(e.paints||(e.paints=[])).push({kind:"text",fmt:g,entry:C(o)});break;case"attr":(e.paints||(e.paints=[])).push({kind:"attr",arg:g,entry:C(o)});break;case"class":(e.paints||(e.paints=[])).push({kind:"class",arg:g,entry:C(o)});break;case"css":(e.paints||(e.paints=[])).push({kind:"css",arg:g,entry:C(o)});break;case"show-when":case"option":(e.paints||(e.paints=[])).push({kind:"when",match:"show",field:g,values:o.split("|")});break;case"hide-when":(e.paints||(e.paints=[])).push({kind:"when",match:"hide",field:g,values:o.split("|")});break;case"option-not":(e.paints||(e.paints=[])).push({kind:"when",match:"show-not",field:g,values:o.split("|")});break}}return e.boundary=e.scope?"scope":e.items?"items":e.detail?"detail":e.each?"each":null,zn(e)?Vn():e}var Ct=null;function Vn(){return(!Ct||Ct.gen!==gt)&&(Ct=Object.freeze({gen:gt,inert:!1,template:!1,item:!1,scope:!1,items:!1,detail:!1,each:!1,boundary:null,bind:null,transient:!1,decls:null,calcs:null,paints:null,effects:null,invalids:null})),Ct}function zn(t){return!t.inert&&!t.item&&t.boundary===null&&t.bind===null&&!t.transient&&!t.decls&&!t.calcs&&!t.paints&&!t.effects&&!t.invalids}var Z=new WeakMap,st=null,wt=!1;function Ne(){Z=new WeakMap}function Te(t){for(let e of t){if(e.type==="attributes"){Z.delete(e.target);continue}let r=e.target.nodeType===1?e.target:e.target.parentElement;for(let n=r;n;n=n.parentElement)Z.delete(n);for(let n of e.addedNodes||[])if(n.nodeType===1){Z.delete(n);for(let o of n.querySelectorAll("*"))Z.delete(o)}}}function Le(t){let e=wt;return!st&&typeof MutationObserver=="function"&&(st=new MutationObserver(Te),st.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})),st&&Te(st.takeRecords()),wt=!!st&&t.getRootNode()===document,e}function Re(t){wt=t}function Ce(t){let e=Z.get(t);return e||Z.set(t,e={attrs:new Map,hasText:!1,text:""}),e}function De(t,e){if(!wt)return t.getAttribute(e);let r=Ce(t);return r.attrs.has(e)||r.attrs.set(e,t.getAttribute(e)),r.attrs.get(e)}function Fe(t){if(!wt)return t.textContent;let e=Ce(t);return e.hasText||(e.text=t.textContent,e.hasText=!0),e.text}function Me(t){return(t.getAttribute("type")||"text").toLowerCase()}function at(t){let e=t.tagName;if(e==="INPUT"){let r=Me(t);r==="checkbox"||r==="radio"?t.checked?t.setAttribute("checked",""):t.removeAttribute("checked"):t.setAttribute("value",t.value);return}if(e==="TEXTAREA"){t.setAttribute("data-value",t.value);return}if(e==="SELECT"){let r=t.options;for(let n=0;n<r.length;n++)r[n].selected?r[n].setAttribute("selected",""):r[n].removeAttribute("selected")}}function Pe(t,e=t){let r=t.tagName;if(r==="INPUT"){let n=Me(t);n==="checkbox"||n==="radio"?e.checked?t.hasAttribute("checked")||t.setAttribute("checked",""):t.removeAttribute("checked"):e.value!==(t.getAttribute("value")??"")&&t.setAttribute("value",e.value);return}if(r==="TEXTAREA"){let n=e.value.startsWith(`
|
|
8
8
|
`)?`
|
|
9
|
-
`+e.value:e.value;t.textContent!==n&&(t.textContent=n),t.removeAttribute("data-value");return}if(r==="SELECT"){let n=t.options,o=e.options;for(let s=0;s<n.length;s++)o[s]&&o[s].selected?n[s].hasAttribute("selected")||n[s].setAttribute("selected",""):n[s].removeAttribute("selected")}}function Lt(t){t.tagName!=="TEXTAREA"||!t.hasAttribute("data-value")||t!==t.ownerDocument.activeElement&&(t.textContent=t.getAttribute("data-value"),t.removeAttribute("data-value"))}function L(t){if(typeof window>"u")return null;let e=window.clay,r=window.hyperclay;return t==="consent"?e?.confirm||r?.consent||null:e?.[t]||r?.[t]||null}function ke(){let t=L("visitorDrafts");return!!(t&&typeof t.restored=="function"&&t.restored()?.restored)}var Ht=["clay:mutation-ready","hyperclay:mutation-ready"],Dn=["clay:sync-applied","hyperclay:livesync-applied"],Fn=["clay:ready","hyperclay:ready"],Pn=["clay:route"];function rt(t,e,r){let n=null,o=s=>{n!==null&&n!==s.type||(n=s.type,queueMicrotask(()=>{n=null}),r(s))};for(let s of e)t.addEventListener(s,o);return()=>{for(let s of e)t.removeEventListener(s,o)}}function $e(t){let e=typeof window<"u"&&window.clay&&window.clay.ready;e&&typeof e.then=="function"?e.then(()=>t(),()=>t()):t()}function Ct(t){let e=L("region");return!e||typeof e.resolveRegionPolicy!="function"||typeof e.skipForPolicy!="function"?!1:e.skipForPolicy(e.resolveRegionPolicy(t),void 0,["no-save","freeze"])}function _e(){let t=L("consent");return typeof t=="function"?t:null}function Te(t,e){if(typeof e!="function")throw new Error("Sap.batch(label, fn): fn must be a function");let r=L("undo");r&&r.flush&&r.flush();let n=e();if(n&&typeof n.then=="function")throw new Error("Sap.batch fn must be synchronous (it returned a promise)");return r&&r.commitCaptured&&r.commitCaptured(t),n}function Ne(t){if(typeof window>"u"||typeof document>"u")return;let e=()=>{let d=!1;for(let u of t.apps())u.root.isConnected?t.runNow(u,"platform"):d=!0;d&&t.pruneDisconnected(),t.remountIfPresent()},r=L("derived"),n=r&&typeof r.register=="function"?r.register(e):null,o=typeof n=="function"?null:rt(document,Dn,e),s=rt(document,Pn,e),a=!1,g=()=>{},b=()=>{if(a)return!0;let d=L("undo");if(!d||typeof d.on!="function")return!1;let u=d.on("undo",e);return typeof u!="function"?!1:typeof d.on("redo",e)!="function"?(u(),!1):(a=!0,g(),!0)};if(!b()){let d=rt(document,Ht,b),u=rt(document,Fn,b);g=()=>{d(),u()};let E=L("ready");E&&typeof E.then=="function"&&E.then(b,()=>{})}return()=>{typeof n=="function"&&n(),o&&o(),s(),g()}}function ht(t){let e=t.tagName;if(e==="INPUT"){let r=(t.getAttribute("type")||"text").toLowerCase();return r==="checkbox"?"checkbox":r==="radio"?"radio":r==="number"||r==="range"?"number":r==="hidden"?"hidden":"text"}return e==="TEXTAREA"?"text":e==="SELECT"?t.multiple?"select-multiple":"select-one":"leaf"}function In(t){if(t.validity&&t.validity.badInput)return t.hasAttribute("value")?Number(t.getAttribute("value"))||0:t._sapLastGood??0;if(t.value==="")return 0;let e=Number(t.value);return Number.isNaN(e)?t._sapLastGood??0:(t._sapLastGood=e,e)}function Le(t,e){switch(e){case"checkbox":return t.checked;case"radio":return t.checked?t.value:void 0;case"number":return In(t);case"select-one":return t.value;case"select-multiple":return[...t.selectedOptions].map(r=>r.value);case"hidden":case"text":return t.value;case"leaf":return t.textContent;default:return t.value}}function Ce(t,e,r){switch(e){case"checkbox":t.checked=!!r;break;case"radio":t.checked=String(t.value)===String(r);break;case"number":case"text":case"hidden":t.value=r==null?"":String(r);break;case"select-one":t.value=r==null?"":String(r);break;case"select-multiple":{let n=new Set((Array.isArray(r)?r:[r]).map(String));for(let o of t.options)o.selected=n.has(o.value);break}case"leaf":t.textContent=r==null?"":String(r);break;default:t.value=r==null?"":String(r)}}function Ut(t){if(t.hasAttribute("transient")){t.removeAttribute("value"),t.removeAttribute("checked"),t.removeAttribute("data-value");return}Ct(t)||nt(t)}function Mn(t){t.dispatchEvent(new Event("input",{bubbles:!0})),t.dispatchEvent(new Event("change",{bubbles:!0}))}function Rt(t,e){return Le(t,e)}function Re(t,e,r){Ce(t,e,r),Ut(t)}function R(t){let e=ht(t);return{el:t,kind:e,read(){return Le(t,e)},write(r,n={}){Ce(t,e,r),n.noMirror||Ut(t),n.silent||Mn(t)},mirror(){Ut(t)}}}var j=null,Ft=!1,ot=null;function De(t){let e=null;return{kind:"hub",subscribe(r){let n=t.onAnyChange({debounce:0,require:"observed"},r);typeof n=="function"&&(e=n)},suppress(r){t.pause();try{return r()}finally{t.resume()}},teardown(){if(e){try{e()}catch{}e=null}}}}function On(){let t=null;return{kind:"native",subscribe(e){t=new MutationObserver(n=>e(Bn(n)));let r=typeof document<"u"&&document.body||typeof document<"u"&&document.documentElement;r&&t.observe(r,{childList:!0,subtree:!0,attributes:!0,characterData:!0})},suppress(e){let r=L("undo");r&&r.pause&&r.pause();try{return e()}finally{t&&t.takeRecords(),r&&r.resume&&r.resume()}},teardown(){t&&(t.disconnect(),t=null)}}}function Bn(t){let e=[];for(let r of t)if(r.type==="attributes"){let n=r.target;n&&n.nodeType===1&&!Dt(n)&&e.push({type:"attribute",element:n})}else if(r.type==="characterData"){let n=r.target&&r.target.parentElement;n&&!Dt(n)&&e.push({type:"characterData",element:n})}else if(r.type==="childList"){for(let n of r.addedNodes)if(!(n.nodeType!==1||Dt(n))&&(e.push({type:"add",element:n}),n.querySelectorAll))for(let o of n.querySelectorAll("*"))Dt(o)||e.push({type:"add",element:o});for(let n of r.removedNodes)n.nodeType===1&&e.push({type:"remove",element:n,parent:r.target})}return e}function Dt(t){return!!(t.closest&&t.closest("[sap-ignore],[template],[cms-template]"))}function Wn(t,e){t.pruneDisconnected();let r=new Set,n=!1;for(let o of e){let s=o.type==="remove"?o.parent:o.element,a=s&&t.appFor(s);a&&r.add(a),o.type==="add"&&o.element&&o.element.nodeType===1&&o.element.hasAttribute&&o.element.hasAttribute("sap")&&!(t.isRegistered&&t.isRegistered(o.element))&&(n=!0)}n&&t.remountIfPresent();for(let o of r)o.root.isConnected&&t.schedule(o,"mutation")}function Fe(t){if(j)return j.suppress(t);let e=L("undo");if(e&&e.pause&&e.resume){e.pause();try{return t()}finally{e.resume()}}return t()}function Gt(t,e){Ft=!0,j=t,t.subscribe(r=>Wn(e,r))}function Yt(t){if(Ft||typeof window>"u"||typeof document>"u")return;let e=L("Mutation");if(e&&typeof e.onAnyChange=="function"){Gt(De(e),t);return}typeof MutationObserver=="function"&&(Gt(On(),t),ot=rt(document,Ht,function(){let n=L("Mutation");n&&(ot(),ot=null,j&&j.teardown(),Ft=!1,Gt(De(n),t))}))}function Xt(){if(j)try{j.teardown()}catch{}ot&&typeof document<"u"&&ot(),j=null,Ft=!1,ot=null}var qn=new Set(J),V=[],Ie={},Me={};function Oe(t){V.includes(t)||(V.push(t),t.boundary&&Object.assign(Ie,t.boundary),t.paintKinds&&Object.assign(Me,t.paintKinds))}function it(t,e={}){if(e.breaker){t.diag.error("E26",t.root,{problem:"recompute loop halted after 50 passes; recent triggers: "+(t._breakerRing||[]).join(", ")}),M(t.root,"loop");return}e.full&&ye();let r=Ae(t.root);try{Fe(()=>jn(t,e))}finally{Ee(r)}t._viewsChanged&&(t._viewsChanged=!1,t.root.dispatchEvent(new CustomEvent("sap:views-updated",{bubbles:!0})))}function jn(t,e){let r=t.root,n={},o=[],s=[],a=new Set;t.diag.errors=[];let g={root:n,state:n,item:null,ownerEl:r,projection:!1};function b(i,l){let m=l.attr||l.name,y=i.getAttribute(m);return y==null&&(y=ft(l),s.push({el:i,name:l.name,attr:m,value:qt(z(y,l.type),l.type)})),z(y,l.type)}function d(i,l,m){let y=l.decls;if(y)for(let x of y){if(x.transient){m[x.name]=St(i,x);continue}if(G(i,x)){m[x.name]=i.hasAttribute(x.attr);continue}m[x.name]=b(i,x)}}function u(i,l,m){let y=l.bind,x=m.item||m.state,$=ht(i);$==="radio"?(y in x||(x[y]=""),i.checked&&(x[y]=i.value)):x[y]=Rt(i,$),l.transient&&(i.removeAttribute("value"),i.removeAttribute("checked"))}function E(i,l,m){if(l.paints)for(let y of l.paints)y.kind==="when"&&a.add(y.field),o.push({def:y,el:i,ctx:m});for(let y of V)y.collect&&y.collect(w,i,l,m)}function S(i,l,m){Object.defineProperty(i,"$key",{value:At(l,"row"),enumerable:!1}),Object.defineProperty(i,"$index",{value:m,enumerable:!1}),Object.defineProperty(i,"$el",{value:l,enumerable:!1})}function k(i,l,m){let y=q(i);d(i,y,l),i._sapScope=l,!m.projection&&y.bind!=null&&u(i,y,m),E(i,y,m),y.items?p(i,l,m):_(i,l,m)}function _(i,l,m){for(let y=i.firstElementChild;y;y=y.nextElementSibling)h(y,l,m)}function h(i,l,m){let y=q(i);if(!y.inert){if(y.boundary){y.boundary==="scope"?A(i,l,m):y.boundary==="items"?(E(i,y,m),p(i,l,m)):Ie[y.boundary](w,i,y,l,m);return}!m.projection&&!m.view&&y.bind!=null&&u(i,y,m),E(i,y,m);for(let x=i.firstElementChild;x;x=x.nextElementSibling)h(x,l,m)}}function A(i,l,m){let y=i.getAttribute("scope"),x={};l[y]=x;let $={root:m.root,state:x,item:null,ownerEl:i,projection:m.projection};k(i,x,$)}function p(i,l,m){let y=i.getAttribute("items"),x=[];l[y]=x,i._sapList=x;let $=0;for(let T=i.firstElementChild;T;T=T.nextElementSibling){let gt=q(T);if(!gt.item||gt.template||T.hasAttribute("cms-template"))continue;let D={};S(D,T,$);let st={root:m.root,state:m.state,item:D,ownerEl:T,projection:m.projection};k(T,D,st),x.push(D),$++}}let w={app:t,root:r,rootObj:n,paints:o,stats:{calcs:0,lists:0},resolveDefault:b,collectEl:E,walkScope:_};for(let i of V)i.begin&&i.begin(w);if(k(r,n,g),t.halted)return;for(let i of V)i.afterIntake&&i.afterIntake(w);if(s.length&&a.size)for(let i of s)a.has(i.attr)&&i.el.getAttribute(i.attr)==null&&i.el.setAttribute(i.attr,i.value);for(let i of V)i.compute&&i.compute(w);let v=0;for(let i of V)i.reconcile&&(v+=i.reconcile(w));let f=0,c=v;for(let i of o){let l=zn(i,t);i.ctx.view?c+=l:f+=l}for(let i of V)i.afterPaint&&i.afterPaint(w);t._state=n,t._stats={fields:Object.keys(n).filter(i=>typeof n[i]!="function").length,calcs:w.stats.calcs,paints:o.length,lists:w.stats.lists,writes:f,viewWrites:c},t._viewsChanged=c>0,t._lastPass={trigger:e.trigger||"refresh",writes:f},t._debug&&console.log(`sap pass \xB7 trigger: ${t._lastPass.trigger} \xB7 writes ${f}/${o.length}`)}function Vn(t){return t.kind==="text"?t.fmt?"text:"+t.fmt:"text":t.kind==="attr"?"attr:"+t.arg:t.kind==="class"?"class:"+t.arg:t.kind==="css"?"css:"+t.arg:t.kind==="when"?(t.match==="hide"?"hide-when:":t.match==="show-not"?"option-not:":"show-when:")+t.field:t.kind}function Kt(t,e,r,n){let o=t;for(;o&&o.nodeType===1;){if(o.hasAttribute&&o.hasAttribute(e)){let s=r.includes(o.getAttribute(e));if(n?!s:s)return!0}o=o.parentElement}return!1}function zn(t,e){let r=t.def,n=t.el,o=Me[r.kind];if(o)return o(t,e);if(r.kind==="when")return Pe(r,n,null);try{let s=I(r.entry,t.ctx.state,t.ctx.item,n,t.ctx.root),a=Pe(r,n,s);return Q(n),a}catch(s){return e.diag.error(s.sapCode==="E22"?"E22":"E24",n,{attr:Vn(r),expr:r.entry&&r.entry.src,problem:String(s.message)}),M(n,s.sapCode||"E24"),0}}function Pe(t,e,r){switch(t.kind){case"text":{let n=t.fmt!=null?pe(t.fmt,r):r==null?"":String(r);return e.textContent!==n?(e.textContent=n,1):0}case"show":{let n=!r;return e.hidden!==n?(e.hidden=n,1):0}case"when":{let n=L("optionVisibility");if(n&&n._started)return e._sapWhen&&e.hidden?(e.hidden=!1,e._sapWhen=!1,1):0;let o;t.match==="hide"?o=!Kt(e,t.field,t.values,!1):t.match==="show-not"?o=Kt(e,t.field,t.values,!0):o=Kt(e,t.field,t.values,!1),e._sapWhen=!0;let s=!o;return e.hidden!==s?(e.hidden=s,1):0}case"attr":{let n=t.arg;if((n==="checked"||n==="selected")&&typeof e[n]=="boolean"&&!e.hasAttribute("bind")&&!e.closest("select[bind]")){let s=0;return e[n]!==!!r&&(e[n]=!!r,s=1),!!r!==e.hasAttribute(n)&&(r?e.setAttribute(n,""):e.removeAttribute(n),s=1),s}if(qn.has(n)){let s=e.hasAttribute(n);return r&&!s?(e.setAttribute(n,""),1):!r&&s?(e.removeAttribute(n),1):0}let o=typeof r=="boolean"?String(r):r==null?"":String(r);return e.getAttribute(n)!==o?(e.setAttribute(n,o),1):0}case"class":{let n=!!r;return e.classList.contains(t.arg)!==n?(e.classList.toggle(t.arg,n),1):0}case"css":{let n=r==null?"":String(r);return e.style.getPropertyValue("--"+t.arg)!==n?(e.style.setProperty("--"+t.arg,n),1):0}default:return 0}}var Hn=new Set(J),Be=new Set(["calc","text","attr","class","css","set","move","sort","option","option-not","show-when","hide-when","editmode"]),Un=new Set(["show-when","hide-when","option","option-not"]),Gn=/\b(?:state|item|root)\.|===|!==|&&|\|\||[()]|^\s*!/,We=new Set(["sap","scope","items","item","template","bind","show","effect","invalid","detail","state","transient","confirm","default","persist","sortable","trigger-add","trigger-remove","trigger-reset","sap-ignore","sap-error","no-save","no-watch","no-undo","no-trigger-autosave","freeze","mutations-ignore","save-remove","save-ignore","save-freeze"]),Qt=[];function qe(t){Qt.includes(t)||Qt.push(t)}function Yn(t){return t.tagName==="INPUT"||t.tagName==="SELECT"||t.tagName==="TEXTAREA"}function Jt(t){return t.hasAttribute("bind")}function Xn(t,e){e(t);for(let n=t.firstElementChild;n;n=n.nextElementSibling)r(n);function r(n){if(!n.hasAttribute("sap-ignore")){if(n.tagName==="TEMPLATE"){if(n.hasAttribute("items"))for(let o=n.content.firstElementChild;o;o=o.nextElementSibling)r(o);return}e(n);for(let o=n.firstElementChild;o;o=o.nextElementSibling)r(o)}}}function Pt(t,e){let r=!1,n=(a,g,b)=>{e.error(a,g,b),r=!0},o=t.ownerDocument.createTreeWalker(t,4),s;for(;s=o.nextNode();)if(/\{\{.*\}\}/.test(s.nodeValue||"")){n("E02",s.parentElement||t,{problem:"moustaches in text content are not a Sap feature",fix:'move the expression onto the element: text="state.x"'});break}return Xn(t,a=>{let g=new Set;for(let d of Qt)d(a,n,u=>g.add(u));let b=a.closest&&a.closest("[detail]");for(let d of[...a.attributes]){let u=d.name;if(g.has(u))continue;if(u.includes(":")){let S=u.slice(0,u.indexOf(":"));if(Be.has(S)){if(Un.has(S)&&Gn.test(d.value)){let k=u.slice(u.indexOf(":")+1);e.warn("W04",a,{attr:u,expr:d.value,problem:`${S}: compares the "${k}" attribute against a literal value, not a JS expression`,fix:`use show="${d.value}" for an expression, or a literal like ${S}:${k}="overview"`})}}else{let k=ut(S,[...Be]);e.warn("W03",a,{attr:u,problem:`unknown "${S}:" attribute`,didYouMean:k?`${k}:`:null})}}else if(!We.has(u)&&!at.has(u)&&!Hn.has(u)&&!/^(data-|aria-|on)/.test(u)&&!(u in a)){let S=ut(u,[...We]);S&&e.warn("W03",a,{attr:u,problem:`unknown "${u}" attribute`,didYouMean:S})}u==="attr:hidden"&&e.warn("W03",a,{attr:u,problem:"attr:hidden paints the wrong attribute",fix:'use show="expr"'});let E=Jt(a)||u==="attr:selected"&&a.tagName==="OPTION"&&!!a.closest("select[bind]");(u==="attr:value"||u==="attr:checked"||u==="attr:selected")&&E&&n("E30",a,{attr:u,problem:"attr: on a bound control collides with persist ownership",fix:"remove it; bind owns this attribute"}),u==="effect"&&Jt(a)&&/\b(value|checked)\s*=[^=]/.test(d.value)&&n("E30",a,{attr:u,expr:d.value,problem:"effect writes value/checked on a bound control (writes a stale value with no synthetic event)",fix:"write through onclick + Sap(this) instead"}),(u==="text"||u.startsWith("text:")||u==="show")&&Yn(a)&&(u==="show"||n("E18",a,{attr:u,problem:"paint belongs on output elements, not form controls",fix:"move the paint to an <output> or <span>"}))}if(a.hasAttribute("state")){let d=C(a.getAttribute("state")),u=new Set;for(let E of d){E.name.includes("-")&&n("E08",a,{attr:"state",problem:`field "${E.name}" is not a valid identifier (the hyphen parses as subtraction)`,fix:`rename to ${E.name.replace(/-/g,"")}`}),u.has(E.name)&&n("E04",a,{attr:"state",problem:`field "${E.name}" is declared twice in one scope`}),u.add(E.name),wt.has(E.attr)&&n("E05",a,{attr:"state",problem:`"${E.name}" is a reserved Sap word`}),at.has(E.attr)&&n("E06",a,{attr:"state",problem:`"${E.name}" is a global HTML attribute name; pick another field name`}),E.name==="open"&&a.tagName==="DIALOG"&&n("E33",a,{attr:"state",problem:"dialog open is transient",fix:"use showModal() \u2014 declare state= only on <details> or popovers"});let S=jt(a,E.attr);S&&(E.attr==="checked"||E.attr==="selected")&&n("E35",a,{attr:"state",problem:`"${E.attr}" on a form control is the control's own state, not a declared field`,fix:'bind the control instead, e.g. <input type="checkbox" bind="done">'}),S&&E.type==="num"&&n("E35",a,{attr:"state",problem:`"${E.attr}" is an HTML boolean attribute; it cannot hold a number`,fix:`declare it bare: state="${E.attr}"`}),E.transient&&(S||E.type==="presence")&&n("E35",a,{attr:"state",problem:`"${E.name}" is carried by attribute presence, which transient would strip`,fix:"declare a separate name:bool:transient field and paint the attribute from it"})}}if(Jt(a)){if(a.hasAttribute("-"),a.tagName==="INPUT"){let d=(a.getAttribute("type")||"text").toLowerCase();d==="file"&&n("E32",a,{attr:"bind",problem:"files never serialize into an HTML file",fix:"use no-save + effect instead of bind"}),d==="password"&&!a.hasAttribute("transient")&&n("E31",a,{attr:"bind",problem:"a password must never serialize into a world-readable file",fix:"add transient to the password input"})}else if(a.tagName!=="SELECT"&&a.tagName!=="TEXTAREA"){let d=a.getAttribute("contenteditable");!(d!=null&&d!=="false")&&a.children.length>0&&n("E20",a,{attr:"bind",problem:"bind on a container element is not a control; a write would overwrite its children",fix:"bind a control (input/select/textarea), a contenteditable, or an empty text leaf"})}}if(a.hasAttribute("transient")&&a.hasAttribute("persist")&&n("E34",a,{problem:"transient and persist are opposite: persist forces the live value into the saved bytes, leaking exactly what transient drops",fix:"remove one \u2014 transient to keep it out of the file, or persist to save it"}),a.tagName==="DIALOG"&&a.hasAttribute("detail")&&!(a.parentElement&&a.parentElement.closest('[clay~="freeze"], [freeze], [save-freeze]'))&&e.warn("W31",a,{attr:"detail",problem:"a detail dialog writes open when it opens, and that attribute would be saved into the file",fix:'wrap the dialog in an element with clay="freeze" (not editor-ui, which removes it from the file), and make its key field transient'}),a.hasAttribute("item")&&!a.hasAttribute("template")&&a.parentNode&&a.parentNode.nodeType===1){let d=a.parentElement;(!d||!d.hasAttribute("items"))&&n("E10",a,{problem:"an [item] must be a direct child of an [items] list",fix:'wrap it in a container with items="name"'})}if(a.hasAttribute("items")&&b&&n("E17",a,{attr:"items",problem:"nested items inside a detail panel is a v1 mount error (nested collections ship in v1.1)"}),a.hasAttribute("items")){let d=t.querySelector(`[trigger-add="${a.getAttribute("items")}"]`);!xt(a)&&!Wt(t,a.getAttribute("items"))&&W(a).length===0&&d&&n("E17",a,{attr:"items",problem:`trigger-add targets items="${a.getAttribute("items")}" but it has no [item template] to clone`})}}),r&&(e.halted=!0,e.haltReason=e.errors[0]?e.errors[0].code:"halt",M(t,e.haltReason)),!r}var je="sap-styles",Ve="[item][template]{display:none!important}[hidden]{display:none!important}[sap-error]{outline:2px solid #e5484d;outline-offset:1px}",Zt=new WeakSet;function Kn(t){if(Zt.has(t))return;let e=t.defaultView,r=e&&e.CSSStyleSheet;if(r&&"adoptedStyleSheets"in t)try{let n=new r;n.replaceSync(Ve),t.adoptedStyleSheets=[...t.adoptedStyleSheets,n],Zt.add(t);return}catch{}if(!t.getElementById(je)){let n=t.createElement("style");n.id=je,n.textContent=Ve,(t.head||t.documentElement).appendChild(n)}Zt.add(t)}var Jn=0;function ze(){return typeof performance<"u"&&performance.now?performance.now():0}function te(t){let e=t.id||t.getAttribute("sap")||`app-${Jn++}`,r=new K(e),n={root:t,name:e,diag:r,_state:null,_stats:null,_lastPass:null,_passes:0,_broken:!1,_mountMs:0,_mountWrites:0};if(!Pt(t,r))return n.halted=!0,n;Kn(t.ownerDocument);for(let a of t.querySelectorAll("textarea[data-value]"))Lt(a);let s=ze();return it(n,{trigger:"mount",full:!0}),n._mountMs=ze()-s,n._mountWrites=n._stats?n._stats.writes:0,n._mountWrites>0&&!ke()&&!L("derived")&&r.warn("W30",t,{problem:`${n._mountWrites} paint(s) ran at mount; the saved file was out of sync with its declared state`,fix:"re-save once so the file mounts clean (a settled file writes nothing)"}),n}var He=/^(set:|move:|sort:|trigger-add$|trigger-remove$|trigger-reset$)/;function It(t){return`${t.tagName.toLowerCase()}[sap]`}function Qn(t){let e=0;for(let r of t.querySelectorAll("*"))for(let n of r.attributes)if(He.test(n.name)){e++;break}for(let r of t.attributes)if(He.test(r.name)){e++;break}return e}function Ue(t){function e(g){let b=g._stats||{},d=g.root;return{root:It(d),fields:b.fields||0,calcs:b.calcs||0,paints:b.paints||0,actions:Qn(d),lists:(d.hasAttribute("items")?1:0)+d.querySelectorAll("[items]").length,rows:d.querySelectorAll("[item]:not([template])").length,warnings:g.diag.warnings.length,errors:g.diag.errors.length,mountWrites:g._mountWrites||0,ms:Math.round((g._mountMs||0)*10)/10,passes:g._passes||0,lastPass:g._lastPass||null,ok:g.diag.errors.length===0&&!g.halted}}function r(){let g=t.apps().map(e);return{ok:g.every(b=>b.ok),apps:g}}function n(g){let b=e(g);return b.ok?`sap \u2713 ${b.root} \xB7 fields ${b.fields} \xB7 calcs ${b.calcs} \xB7 paints ${b.paints} \xB7 actions ${b.actions} \xB7 lists ${b.lists} \xB7 rows ${b.rows} \xB7 warnings ${b.warnings} \xB7 mount writes ${b.mountWrites} \xB7 ${b.ms}ms`:`sap \u2717 ${b.root} \xB7 errors ${b.errors} \xB7 warnings ${b.warnings} \xB7 ${b.ms}ms`}function o(){for(let g of t.apps()){let b=n(g);g.diag.errors.length||g.halted?console.error(b):console.log(b)}}function s(){let g=[],b=[];for(let d of t.apps())g.push(...d.diag.errors),b.push(...d.diag.warnings);return{ok:g.length===0,errors:g,warnings:b,counts:{errors:g.length,warnings:b.length}}}function a(g){let b=g===void 0?!0:!!g;for(let d of t.apps())d._debug=b;return console.log(`sap debug ${b?"on":"off"} \u2014 per-pass headers will ${b?"":"no longer "}log`),b}return{status:r,report:s,debug:a,greenLine:n,printGreenLines:o,REGISTRY:Bt}}var Ge="0.6.0";function Ye({createAccessor:t,installInput:e,debugExtras:r}){let n=new Map,o=[],s=ee(it);function a(i){let l=i;for(;l;){if(l.nodeType===1&&l.hasAttribute&&l.hasAttribute("sap"))return n.get(l)||null;l=l.parentNode&&l.parentNode.host?l.parentNode.host:l.parentElement}return null}function g(){for(let i=o.length-1;i>=0;i--){let l=o[i];l.root.isConnected||(n.delete(l.root),o.splice(i,1))}}function b(i,l){if(i.moveBefore)try{i.moveBefore(l,null);return}catch{}i.appendChild(l)}function d(i,l){let m=l.parentElement;if(m){if(m.moveBefore)try{m.moveBefore(i,l);return}catch{}m.insertBefore(i,l)}}let u={apps:()=>o.slice(),appFor:a,isRegistered:i=>n.has(i),pruneDisconnected:g,schedule:(i,l)=>s.schedule(i,l),runNow:(i,l)=>s.runNow(i,l),moveInto:b,placeBefore:d,remountIfPresent:()=>v()},E=t(u),S=Ue(u),k=r?r(u,S):{},_=!1,h=!1,A=null;function p(){_||(_=!0,e(u,E,document),A=Ne(u))}function w(){let i=L("derived");i&&typeof i.mounted=="function"&&i.mounted()}function v(i=document){if(h)return[];p(),Yt(u);let l=i.querySelectorAll("[sap]"),m=[];for(let y of l){if(n.has(y))continue;let x=te(y);n.set(y,x),o.push(x),m.push(x)}for(let y of m){let x=S.greenLine(y);y.diag.errors.length||y.halted?console.error(x):console.log(x)}return w(),m}function f(i){if(h)return null;if(p(),Yt(u),!i)return v();let l=typeof i=="string"?document.querySelector(i):i;if(!l)return null;if(n.has(l))return n.get(l);let m=te(l);n.set(l,m),o.push(m);let y=S.greenLine(m);return m.diag.errors.length||m.halted?console.error(y):console.log(y),m}let c=E.Sap;return c.version=Ge,c.refresh=function(){for(let l of o)l.root.isConnected&&s.runNow(l,"refresh")},c.batch=Te,c.status=S.status,c.report=S.report,c.why=k.why,c.debug=S.debug,c.doctor=k.doctor,c.greenLine=S.greenLine,c.formats=et,c.serializeControlToAttributes=nt,c.finalizeControlForSave=Se,c.rehydrateControlFromAttributes=Lt,c.mount=f,c.config=function(l={}){return l.formats&&Object.assign(et,l.formats),c},c._registry=n,c._reset=function(){n.clear(),o.length=0,Xt()},c.unmount=function(){h=!0,n.clear(),o.length=0,Xt(),typeof A=="function"&&A()},{Sap:c,mountAll:v,mount:f,runtime:u}}function Xe(t){if(typeof document>"u")return;let e=()=>$e(()=>t());document.readyState==="loading"?document.addEventListener("DOMContentLoaded",e):e()}var Zn=["for","form","list","headers","popovertarget","commandfor","anchor","aria-activedescendant","aria-controls","aria-describedby","aria-details","aria-errormessage","aria-flowto","aria-labelledby","aria-owns"];function tr(t,e){let r=null;return O(t,n=>{!r&&n.getAttribute("scope")===e&&(r=n)}),r}function Ke(t,e,r){let n=F(t)||e;for(;n;){for(let o of C(n.getAttribute("state")||""))if(o.name===r)return{el:n,decl:o};if(n.hasAttribute("sap"))break;n=F(n.parentElement)}return null}function er(t){return typeof t=="number"?"num":typeof t=="boolean"?"bool":"string"}function Je(t){function e(h){let A=t.appFor(h);if(!A)return null;let p=H(h),w=p&&p._sapEachItem&&p._sapEachItem.$el;if(w&&w.isConnected)return{ctxEl:w,appRec:A,isRow:!0};let v=ct(h);if(v)return v._sapDetailRow?{ctxEl:v._sapDetailRow,appRec:A,isRow:!0}:{ctxEl:F(v.parentElement)||A.root,appRec:A,isRow:!1};let f=Et(h);if(f&&f.hasAttribute("item"))return{ctxEl:f,appRec:A,isRow:!0};let c=F(h)||A.root;return{ctxEl:c,appRec:A,isRow:c.hasAttribute("item")}}function r(h){let A=typeof h=="string"?document.querySelector(h):h;if(!A||A.nodeType!==1)return null;let p=e(A);return p?_(p.ctxEl,p.appRec,p.isRow):null}function n(h,A){let p=H(h);if(!p)return r(h);let w=t.appFor(h),v=p._sapEachItem&&p._sapEachItem.$el;if(v&&v.nodeType===1&&v.hasAttribute("item")&&tt(v,A))return v.isConnected?_(v,w,!0):null;let f=p.parentElement&&p.parentElement._sapDrawnEl;return!f||!f.isConnected?null:_(f,w,f.hasAttribute("item"))}function o(h,A,p){let w=U(h,p);if(w)return R(w).read();let v=Z(h,p);if(v)return W(v).map(l=>_(l,A,!0));let f=tr(h,p);if(f)return _(f,A,!1);let c=Ke(h,A.root,p);if(c)return c.decl.transient?St(c.el,c.decl):ie(c.el,c.decl);let i=h._sapScope;return i?i[p]:void 0}function s(h,A,p,w,v){w.transient?dt(h,w,p):lt(h,w,p),t.schedule(v,"set:"+A)}function a(h,A){let p=new Set,w=F(h)||A;for(;w;){for(let v of C(w.getAttribute("state")||""))p.add(v.name);if(w.hasAttribute("sap"))break;w=F(w.parentElement)}return O(h,v=>{let f=v.getAttribute("bind");f&&p.add(f)}),p}function g(h,A,p,w){let v=U(h,p);if(v){R(v).write(w);return}let f=h;for(;f;){for(let T of f.attributes)if(T.name==="calc:"+p){A.diag.error("E16",f,{attr:"calc:"+p,problem:`"${p}" is a computed field; computed fields are read-only`});return}if(f.hasAttribute("sap"))break;f=f.parentElement}let c=Ke(h,A.root,p);if(c){s(c.el,p,w,c.decl,A);return}let i=a(h,A.root);i.delete(p);let l=p.length>=4?ut(p,[...i]):null;if(l){A.diag.error("E12",h,{key:p,problem:`unknown state key "${p}"`,didYouMean:l});return}if(wt.has(p)||at.has(p)){A.diag.error("E15",h,{key:p,problem:`cannot write undeclared field "${p}" \u2014 it is a reserved/global name and cannot become state`,fix:"pick a different field name, or declare it explicitly in a state= attribute"});return}let m=A.root,y=er(w),x=m.getAttribute("state")||"",$=y==="string"?p:`${p}:${y}`;m.setAttribute("state",x?`${x} ${$}`:$),s(m,p,w,{name:p,attr:p,type:y,transient:!1},A)}function b(h){let A=h.ownerDocument,p=new Map,w=(v,f)=>{let c=re(A),i=v.getAttribute(f);i&&f==="id"&&p.set(i,c),v.setAttribute(f,c)};h.querySelectorAll("[id]").forEach(v=>w(v,"id")),h.querySelectorAll("[data-id]").forEach(v=>w(v,"data-id")),h.querySelectorAll("[sap-error]").forEach(v=>v.removeAttribute("sap-error")),h.removeAttribute("sap-error"),h.hasAttribute("data-id")?(h.removeAttribute("id"),w(h,"data-id")):w(h,"id");for(let v of[h,...h.querySelectorAll("*")])for(let f of Zn){let c=v.getAttribute(f);if(c==null)continue;let i=c.split(/\s+/).map(l=>p.get(l)||l).join(" ");i!==c&&v.setAttribute(f,i)}}function d(h,A,p){let w=pt(A.root,h,p);if(!w)return A.diag.error("E17",h,{problem:`cannot resolve a list named "${p}" from here`}),null;let v=xt(w);if(!v)return A.diag.error("E17",w,{problem:`items="${p}" has no [item template] to clone`}),null;let f=w.ownerDocument.importNode(v,!0);return f.removeAttribute("template"),b(f),w.appendChild(f),t.schedule(A,"trigger-add:"+p),_(f,A,!0)}function u(h,A){O(h,p=>{if(p.hasAttribute("bind")){let w=R(p),v=p.getAttribute("default");w.kind==="checkbox"||w.kind==="radio"?w.write(v!=null?v===""||v==="true"||p.value===v:p.hasAttribute("checked")):w.write(v??(p.getAttribute("value")||""))}});for(let p of C(h.getAttribute("state")||"")){let w=se(h,p);p.transient?dt(h,p,w):lt(h,p,w)}t.schedule(A,"trigger-reset")}function E(h,A){if(!h.isConnected)throw new Error("stale row handle: $remove() on a removed row");h.remove(),t.schedule(A,"trigger-remove")}function S(h,A,p){if(!h.isConnected)throw new Error("stale row handle: $move() on a removed row");let w=null;if(p&&p.nodeType===1?w=p:typeof p=="string"&&(w=pt(A.root,h,p)),!w){A.diag.error("E17",h,{problem:`$move() cannot resolve target "${p}"`});return}t.moveInto(w,h),t.schedule(A,"trigger-move")}function k(h){let A=h.parentElement;return A?W(A).indexOf(h):-1}function _(h,A,p){let w={get $el(){return h},get $key(){return At(h,p?"row":"scope")},get $index(){return k(h)},$add(f){return d(h,A,f)},$reset(){return u(h,A),v},$remove(){E(h,A)},$move(f){S(h,A,f)},get $appRec(){return A}},v=new Proxy(w,{get(f,c){return typeof c=="symbol"||c[0]==="$"?f[c]:o(h,A,c)},set(f,c,i){return typeof c=="string"&&c[0]==="$"?(f[c]=i,!0):(g(h,A,c,i),!0)},has(f,c){return typeof c=="string"&&c[0]==="$"?c in f:o(h,A,c)!==void 0}});return v}return{Sap:r,contextElFor:e,readField:o,writeField:g,makeProxy:_,writeTargetFor:n}}var nr=["trigger-add","trigger-remove","trigger-reset"];function rr(t){if(t.nodeType!==1)return!1;for(let e of t.attributes){let r=e.name;if(r.startsWith("set:")||r.startsWith("move:")||r.startsWith("sort:")||nr.includes(r))return!0}return!1}function or(t,e){let r=t,n=e.parentElement;for(;r&&r!==n;){if(r.nodeType===1&&rr(r)&&!(r.tagName==="FORM"&&r.hasAttribute("trigger-add")))return r;r=r.parentElement}return null}function Qe(t,e){let{Sap:r}=e;function n(f,c){let i=null,l=H(f),m=ct(f);if(l)i=l._sapEachItem??null;else if(m&&m._sapDetailRow)i=m._sapDetailRow._sapScope||null;else{let $=Et(f);$&&$.hasAttribute("item")&&(i=$._sapScope||null)}return{state:(F(f)||c.root)._sapScope||c._state||{},item:i,el:f,root:c._state||{}}}function o(f,c,i){if(!f.hasAttribute("confirm")){i();return}let l=f.getAttribute("confirm"),m=l,y=N(l);if(!y.error)try{let T=Y(y,n(f,c));(typeof T=="string"||typeof T=="number")&&(m=String(T))}catch{}let x=_e();if(!x){window.confirm(m)&&i();return}if(f._sapGatePending)return;f._sapGatePending=!0;let $=()=>{f._sapGatePending=!1};x(m,()=>{$(),i()}).catch($)}function s(f,c){for(let i of f.attributes){if(!i.name.startsWith("set:"))continue;let l=i.name.slice(4),m=N(i.value);if(m.error){c.diag.error("E08",f,{attr:i.name,expr:i.value,problem:String(m.error.message)});continue}let y;try{y=Y(m,n(f,c))}catch($){c.diag.error("E24",f,{attr:i.name,expr:i.value,problem:String($.message)});continue}let x=e.writeTargetFor(f,l);x&&(x[l]=y)}}function a(f){let c=H(f);if(!c)return f.closest("[item]");let i=c._sapEachItem&&c._sapEachItem.$el;return i&&i.nodeType===1&&i.hasAttribute("item")?i:null}function g(f,c){let i=a(f);if(!i)return;let l=W(i.parentElement),m=l.indexOf(i);c==="up"&&m>0?t.placeBefore(i,l[m-1]):c==="down"&&m<l.length-1&&t.placeBefore(l[m+1],i)}function b(f,c,i){if(c)return pt(i.root,f,c);let l=f;for(;l;){if(l.hasAttribute&&l.hasAttribute("items"))return l;l=l.parentElement}let m=F(f)||i.root,y=[];return O(m,x=>{x.hasAttribute("items")&&y.push(x)}),y[0]||null}function d(f,c){let i=f==null||f==="",l=c==null||c==="";if(i&&l)return 0;if(i)return 1;if(l)return-1;let m=Number(f),y=Number(c);return!Number.isNaN(m)&&!Number.isNaN(y)?m-y:String(f)<String(c)?-1:String(f)>String(c)?1:0}function u(f,c,i,l){let m=b(f,i,l);if(!m){l.diag.error("E17",f,{attr:"sort:"+c,problem:`no items list resolvable for sort:${c}`});return}let y=W(m),x=D=>D._sapScope?D._sapScope[c]:void 0,$=[...y].sort((D,st)=>d(x(D),x(st))),gt=$.every((D,st)=>D===y[st])?[...$].reverse():$;for(let D of gt)t.moveInto(m,D);t.schedule(l,"sort:"+c)}function E(f){if(!f||f.hidden)return;let c=f.querySelector("[bind]:not([type=hidden]), [contenteditable]");c&&typeof c.focus=="function"&&c.focus()}function S(f,c){o(f,c,()=>{let i=r(f);for(let l of[...f.attributes]){let m=l.name;if(m==="trigger-remove")i&&i.$remove();else if(m==="trigger-reset")i&&i.$reset();else if(m==="trigger-add"){let y=i&&i.$add(l.value);y&&E(y.$el)}else m==="move:up"?(g(f,"up"),t.schedule(c,"move:up")):m==="move:down"?(g(f,"down"),t.schedule(c,"move:down")):m.startsWith("move:to")?i&&i.$move(l.value):m.startsWith("sort:")&&u(f,m.slice(5),l.value,c)}[...f.attributes].some(l=>l.name.startsWith("set:"))&&s(f,c)})}function k(f){let c=f.target;if(!c||c.nodeType!==1)return;let i=t.appFor(c);if(!i)return;let l=or(c,i.root);l&&S(l,i)}function _(f){let c=R(f),i=f.getAttribute("default");c.kind==="checkbox"?c.write(i===""||i==="true"):c.write(i??"")}function h(f,c,i){let l=r(f);if(!l)return;let m=l.$add(i);if(!m)return;let y=[];O(f,x=>{x.hasAttribute("bind")&&y.push(x)});for(let x of y){if(x.type==="radio"&&!x.checked)continue;let $=x.getAttribute("bind"),T=U(m.$el,$);T?R(T).write(R(x).read()):tt(m.$el,$)&&(m[$]=R(x).read())}y.forEach(_),y.length?typeof y[0].focus=="function"&&y[0].focus():E(m.$el)}function A(f){let c=f.target;if(!c||!c.hasAttribute||!c.hasAttribute("trigger-add"))return;let i=t.appFor(c);i&&(f.preventDefault(),o(c,i,()=>h(c,i,c.getAttribute("trigger-add"))))}function p(f){let c=f.target;if(!c||c.tagName!=="DIALOG"||!c.hasAttribute("detail"))return;if(c._sapEngineClose){c._sapEngineClose=!1;return}if(c.open)return;let i=/^[\w.]+\s+by\s+state\.(\w+)\s*$/.exec(c.getAttribute("detail")||""),l=t.appFor(c);if(!i||!l)return;let m=C(c.getAttribute("state")||"").find(x=>x.name===i[1]);if(m){m.transient?dt(c,m,""):lt(c,m,""),t.schedule(l,"close");return}let y=r(c.parentElement);y&&y[i[1]]!==""&&(y[i[1]]="")}function w(f,c){let i=f.hasAttribute("bind")&&vt(f);if(!i&&f.hasAttribute("bind")&&H(f)){let m=f.getAttribute("bind"),y=f._sapViewBind?e.writeTargetFor(f,m):null;return y&&(y[m]=R(f).read()),!0}let l=ct(f);if(l&&l._sapDetailRow&&f.hasAttribute("bind")&&!i){let m=l._sapDetailRow,y=f.getAttribute("bind"),x=U(m,y);if(x&&x!==f)return R(x).write(R(f).read()),!0;if(!x&&C(m.getAttribute("state")||"").some($=>$.name===y))return e.writeField(m,c,y,R(f).read()),!0}return!1}function v(f=document){f.addEventListener("click",k),f.addEventListener("submit",A),f.addEventListener("close",p,!0)}return{install:v,routeInput:w}}function Ze(t){let e=[];function r(b){let d=b.target;if(!d||d.nodeType!==1)return;let u=t.appFor(d);if(u){d.hasAttribute("persist")&&!Ct(d)&&nt(d);for(let E of e)if(E(d,u))return;t.schedule(u,b.type+" "+(d.id||d.tagName.toLowerCase()))}}function n(b){let d=b.target,u=t.appFor(d);u&&setTimeout(()=>{d.querySelectorAll("[bind]").forEach(E=>{E.dispatchEvent(new Event("input",{bubbles:!0})),E.dispatchEvent(new Event("change",{bubbles:!0}))}),t.schedule(u,"reset")},0)}function o(b){let d=t.appFor(b.target);d&&t.schedule(d,"toggle")}function s(b){let d=b.detail||{};for(let u of[d.from,d.to,b.target]){if(!u||u.nodeType!==1)continue;let E=t.appFor(u);E&&t.schedule(E,"sorted")}}function a(b){if(b.key!=="ArrowUp"&&b.key!=="ArrowDown")return;let d=b.target;if(!d||d.nodeType!==1||d.tagName!=="INPUT"||!d.hasAttribute("bind")||!d.hasAttribute("step"))return;let u=(d.getAttribute("type")||"text").toLowerCase();if(u!=="text"&&u!=="tel"&&u!=="search"||!t.appFor(d))return;b.preventDefault();let S=P(d.getAttribute("step"))||1,k=b.key==="ArrowUp"?1:-1,_=P(d.value)+S*(b.shiftKey?10:1)*k,h=d.getAttribute("min"),A=d.getAttribute("max");h!==null&&h!==""&&_<P(h)&&(_=P(h)),A!==null&&A!==""&&_>P(A)&&(_=P(A)),R(d).write(String(Number(_.toFixed(2))))}function g(b=document){b.addEventListener("reset",n),b.addEventListener("toggle",o,!0),b.addEventListener("input",r),b.addEventListener("change",r),b.addEventListener("clay:sorted",s),b.addEventListener("keydown",a)}return{install:g,addRouter:b=>e.push(b)}}function tn(t){let e=t.toLowerCase();return/^x-text$|^x-html$/.test(e)?'use text="state.x" (Sap paints text only)':/^x-show$|^v-show$|^v-if$/.test(e)?'use show="expr" (toggles native hidden)':/^x-model$|^v-model$/.test(e)?'use bind="field"':/^@|^x-on:|^v-on:|^on:/.test(e)?"use native onclick + Sap(this) (no event directive)":/^:|^x-bind:class$|^v-bind:class$/.test(e)?'use class:NAME="expr" or attr:NAME="expr"':/^x-for$|^v-for$/.test(e)?'use items="name" on the container and item template on the row':/^x-data$/.test(e)?"declare state with state= / bind / items (no JS state object)":/^x-init$/.test(e)?"use a <script> or onclick + Sap(this)":/^bind:/.test(e)?'use bind="field"; one-way paint is attr:NAME="expr"':/^x-/.test(e)||/^v-/.test(e)?"this is a foreign-dialect attribute; Sap has no x-/v- attributes":null}function en(t){let e=[],r=n=>{for(let o of n.attributes){let s=o.name;(s.startsWith("calc:")||s==="text"||s.startsWith("text:")||s==="show"||s.startsWith("attr:")||s.startsWith("class:")||s.startsWith("css:")||s==="effect"||s==="invalid"||s.startsWith("set:")||s==="detail")&&e.push({el:n,attr:s,src:o.value})}};r(t);for(let n of t.querySelectorAll("*"))r(n);return e}function nn(t){function e(o){return o?typeof o=="string"?document.querySelector(o):o.nodeType===1?o:null:null}function r(o,s){let a=e(o);if(!a)return console.warn("sap why: element not found"),null;let g=[`sap why <${a.tagName.toLowerCase()}> \u2014 ${yt(a)}`],b=[...a.attributes].filter(u=>/^(bind|text|show|effect|invalid|detail|calc:|text:|attr:|class:|css:|set:|state|items|scope)/.test(u.name));for(let u of b)g.push(` ${u.name}="${u.value}"`);let d=a;for(;d&&!d._sapScope;)d=d.parentElement;if(d&&d._sapScope){let u=d._sapScope,E=s?[s]:Object.keys(u);g.push(" reads:");for(let S of E){let k=u[S];typeof k!="function"&&g.push(` ${S} = ${JSON.stringify(Array.isArray(k)?`[${k.length} rows]`:k)}`)}}return g.push(" serialization: textContent and value/checked attributes save with the file; reads live from properties"),console.log(g.join(`
|
|
10
|
-
`)),null}function n(){let o=[],
|
|
9
|
+
`+e.value:e.value;t.textContent!==n&&(t.textContent=n),t.removeAttribute("data-value");return}if(r==="SELECT"){let n=t.options,o=e.options;for(let i=0;i<n.length;i++)o[i]&&o[i].selected?n[i].hasAttribute("selected")||n[i].setAttribute("selected",""):n[i].removeAttribute("selected")}}function Mt(t){t.tagName!=="TEXTAREA"||!t.hasAttribute("data-value")||t!==t.ownerDocument.activeElement&&(t.textContent=t.getAttribute("data-value"),t.removeAttribute("data-value"))}function R(t){if(typeof window>"u")return null;let e=window.clay,r=window.hyperclay;return t==="consent"?e?.confirm||r?.consent||null:e?.[t]||r?.[t]||null}function Ie(){let t=R("visitorDrafts");return!!(t&&typeof t.restored=="function"&&t.restored()?.restored)}var Kt=["clay:mutation-ready","hyperclay:mutation-ready"],Un=["clay:sync-applied","hyperclay:livesync-applied"],Gn=["clay:ready","hyperclay:ready"],Yn=["clay:route"],Xn=["clay:modechange"];function yt(t,e,r){let n=null,o=i=>{n!==null&&n!==i.type||(n=i.type,queueMicrotask(()=>{n=null}),r(i))};for(let i of e)t.addEventListener(i,o);return()=>{for(let i of e)t.removeEventListener(i,o)}}function Oe(t){let e=typeof window<"u"&&window.clay&&window.clay.ready;e&&typeof e.then=="function"?e.then(()=>t(),()=>t()):t()}function Pt(t){let e=R("region");return!e||typeof e.resolveRegionPolicy!="function"||typeof e.skipForPolicy!="function"?!1:e.skipForPolicy(e.resolveRegionPolicy(t),void 0,["no-save","freeze"])}function At(){return typeof window>"u"?null:window.clay?.modeLifecycle||null}function N(t,{transient:e=!1}={}){if(e)return!0;let r=At();return typeof r?.canWrite!="function"||R("region")?.resolveRegionPolicy?.(t)?.persist==="none"?!0:r.canWrite()}function We(){let t=R("consent");return typeof t=="function"?t:null}function Be(t,e){if(typeof e!="function")throw new Error("Sap.batch(label, fn): fn must be a function");let r=R("undo");r&&r.flush&&r.flush();let n=e();if(n&&typeof n.then=="function")throw new Error("Sap.batch fn must be synchronous (it returned a promise)");return r&&r.commitCaptured&&r.commitCaptured(t),n}function qe(t){if(typeof window>"u"||typeof document>"u")return;let e=()=>{let x=!1;for(let $ of t.apps())$.root.isConnected?t.runNow($,"platform"):x=!0;x&&t.pruneDisconnected(),t.remountIfPresent()},r=R("derived"),n=r&&typeof r.register=="function"?r.register(e):null,o=typeof n=="function"?null:yt(document,Un,e),i=yt(document,Yn,e),s=null,g=!1,b=()=>{let x=s;s=null,x&&(x[2](),x[3]())},p=()=>{if(g)return!1;let x=R("undo"),$=At()?.state?.generation;if(s&&s[0]===x&&s[1]===$)return!0;if(b(),!x||typeof x.on!="function")return!1;let _=x.on("undo",e);if(typeof _!="function")return!1;let d=x.on("redo",e);return typeof d!="function"?(_(),!1):(s=[x,$,_,d],!0)};p();let u=[Kt,Gn,Xn].map(x=>yt(document,x,p)),E=R("ready");return E&&typeof E.then=="function"&&E.then(p,()=>{}),()=>{g=!0,typeof n=="function"&&n(),o&&o(),i();for(let x of u)x();b()}}function vt(t){let e=t.tagName;if(e==="INPUT"){let r=(t.getAttribute("type")||"text").toLowerCase();return r==="checkbox"?"checkbox":r==="radio"?"radio":r==="number"||r==="range"?"number":r==="hidden"?"hidden":"text"}return e==="TEXTAREA"?"text":e==="SELECT"?t.multiple?"select-multiple":"select-one":"leaf"}function Kn(t){if(t.validity&&t.validity.badInput)return t.hasAttribute("value")?Number(t.getAttribute("value"))||0:t._sapLastGood??0;if(t.value==="")return 0;let e=Number(t.value);return Number.isNaN(e)?t._sapLastGood??0:(t._sapLastGood=e,e)}function je(t,e){switch(e){case"checkbox":return t.checked;case"radio":return t.checked?t.value:void 0;case"number":return Kn(t);case"select-one":return t.value;case"select-multiple":return[...t.selectedOptions].map(r=>r.value);case"hidden":case"text":return t.value;case"leaf":return t.textContent;default:return t.value}}function He(t,e,r){switch(e){case"checkbox":t.checked=!!r;break;case"radio":t.checked=String(t.value)===String(r);break;case"number":case"text":case"hidden":t.value=r==null?"":String(r);break;case"select-one":t.value=r==null?"":String(r);break;case"select-multiple":{let n=new Set((Array.isArray(r)?r:[r]).map(String));for(let o of t.options)o.selected=n.has(o.value);break}case"leaf":t.textContent=r==null?"":String(r);break;default:t.value=r==null?"":String(r)}}function Jt(t){if(t.hasAttribute("transient")){t.removeAttribute("value"),t.removeAttribute("checked"),t.removeAttribute("data-value");return}Pt(t)||at(t)}function Jn(t){t.dispatchEvent(new Event("input",{bubbles:!0})),t.dispatchEvent(new Event("change",{bubbles:!0}))}function It(t,e){return je(t,e)}function Ve(t,e,r){He(t,e,r),Jt(t)}function M(t){let e=vt(t);return{el:t,kind:e,read(){return je(t,e)},write(r,n={}){He(t,e,r),n.noMirror||Jt(t),n.silent||Jn(t)},mirror(){Jt(t)}}}var z=null,Wt=!1,ut=null;function ze(t){let e=null;return{kind:"hub",subscribe(r){let n=t.onAnyChange({debounce:0,require:"observed"},r);typeof n=="function"&&(e=n)},suppress(r){t.pause();try{return r()}finally{t.resume()}},teardown(){if(e){try{e()}catch{}e=null}}}}function Qn(){let t=null;return{kind:"native",subscribe(e){t=new MutationObserver(n=>e(Zn(n)));let r=typeof document<"u"&&document.body||typeof document<"u"&&document.documentElement;r&&t.observe(r,{childList:!0,subtree:!0,attributes:!0,characterData:!0})},suppress(e){let r=R("undo");r&&r.pause&&r.pause();try{return e()}finally{t&&t.takeRecords(),r&&r.resume&&r.resume()}},teardown(){t&&(t.disconnect(),t=null)}}}function Zn(t){let e=[];for(let r of t)if(r.type==="attributes"){let n=r.target;n&&n.nodeType===1&&!Ot(n)&&e.push({type:"attribute",element:n})}else if(r.type==="characterData"){let n=r.target&&r.target.parentElement;n&&!Ot(n)&&e.push({type:"characterData",element:n})}else if(r.type==="childList"){for(let n of r.addedNodes)if(!(n.nodeType!==1||Ot(n))&&(e.push({type:"add",element:n}),n.querySelectorAll))for(let o of n.querySelectorAll("*"))Ot(o)||e.push({type:"add",element:o});for(let n of r.removedNodes)n.nodeType===1&&e.push({type:"remove",element:n,parent:r.target})}return e}function Ot(t){return!!(t.closest&&t.closest("[sap-ignore],[template],[cms-template]"))}function tr(t,e){t.pruneDisconnected();let r=new Set,n=!1;for(let o of e){let i=o.type==="remove"?o.parent:o.element,s=i&&t.appFor(i);s&&r.add(s),o.type==="add"&&o.element&&o.element.nodeType===1&&o.element.hasAttribute&&o.element.hasAttribute("sap")&&!(t.isRegistered&&t.isRegistered(o.element))&&(n=!0)}n&&t.remountIfPresent();for(let o of r)o.root.isConnected&&t.schedule(o,"mutation")}function Ue(t){if(z)return z.suppress(t);let e=R("undo");if(e&&e.pause&&e.resume){e.pause();try{return t()}finally{e.resume()}}return t()}function Qt(t,e){Wt=!0,z=t,t.subscribe(r=>tr(e,r))}function Zt(t){if(Wt||typeof window>"u"||typeof document>"u")return;let e=R("Mutation");if(e&&typeof e.onAnyChange=="function"){Qt(ze(e),t);return}typeof MutationObserver=="function"&&(Qt(Qn(),t),ut=yt(document,Kt,function(){let n=R("Mutation");n&&(ut(),ut=null,z&&z.teardown(),Wt=!1,Qt(ze(n),t))}))}function te(){if(z)try{z.teardown()}catch{}ut&&typeof document<"u"&&ut(),z=null,Wt=!1,ut=null}var er=new Set(et),U=[],Ye={},Xe={};function Ke(t){U.includes(t)||(U.push(t),t.boundary&&Object.assign(Ye,t.boundary),t.paintKinds&&Object.assign(Xe,t.paintKinds))}function ct(t,e={}){if(e.breaker){t.diag.error("E26",t.root,{problem:"recompute loop halted after 50 passes; recent triggers: "+(t._breakerRing||[]).join(", ")}),B(t.root,"loop");return}e.full&&(Se(),Ne());let r=ke(t.root);try{Ue(()=>nr(t,e))}finally{$e(r)}t._viewsChanged&&(t._viewsChanged=!1,t.root.dispatchEvent(new CustomEvent("sap:views-updated",{bubbles:!0})))}function nr(t,e){let r=t.root,n={},o=[],i=[],s=new Set;t.diag.errors=[];let g={root:n,state:n,item:null,ownerEl:r,projection:!1};function b(a,m,y=!1){let v=m.attr||m.name,k=y?De(a,v):a.getAttribute(v);return k==null&&(k=pt(m),i.push({el:a,name:m.name,attr:v,value:Ut(G(k,m.type),m.type)})),G(k,m.type)}function p(a,m,y,v){let k=m.decls;if(!k)return;let L=!!v.item&&!v.projection&&!v.view;for(let T of k){if(T.transient){y[T.name]=Nt(a,T);continue}if(K(a,T)){y[T.name]=a.hasAttribute(T.attr);continue}y[T.name]=b(a,T,L)}}function u(a,m,y){let v=m.bind,k=y.item||y.state,L=vt(a);L==="radio"?(v in k||(k[v]=""),a.checked&&(k[v]=a.value)):L==="leaf"&&y.item&&!y.projection&&!y.view?k[v]=Fe(a):k[v]=It(a,L),m.transient&&(a.removeAttribute("value"),a.removeAttribute("checked"))}function E(a,m,y){if(m.paints)for(let v of m.paints)v.kind==="when"&&s.add(v.field),o.push({def:v,el:a,ctx:y});for(let v of U)v.collect&&v.collect(w,a,m,y)}function x(a,m,y){Object.defineProperty(a,"$key",{value:kt(m,"row"),enumerable:!1}),Object.defineProperty(a,"$index",{value:y,enumerable:!1}),Object.defineProperty(a,"$el",{value:m,enumerable:!1})}function $(a,m,y){let v=V(a);p(a,v,m,y),a._sapScope=m,!y.projection&&v.bind!=null&&u(a,v,y),E(a,v,y),v.items?h(a,m,y):_(a,m,y)}function _(a,m,y){for(let v=a.firstElementChild;v;v=v.nextElementSibling)d(v,m,y)}function d(a,m,y){let v=V(a);if(!v.inert){if(v.boundary){v.boundary==="scope"?A(a,m,y):v.boundary==="items"?(E(a,v,y),h(a,m,y)):Ye[v.boundary](w,a,v,m,y);return}!y.projection&&!y.view&&v.bind!=null&&u(a,v,y),E(a,v,y);for(let k=a.firstElementChild;k;k=k.nextElementSibling)d(k,m,y)}}function A(a,m,y){let v=a.getAttribute("scope"),k={};m[v]=k;let L={root:y.root,state:k,item:null,ownerEl:a,projection:y.projection};$(a,k,L)}function h(a,m,y){let v=a.getAttribute("items"),k=[];m[v]=k,a._sapList=k;let L=0;for(let T=a.firstElementChild;T;T=T.nextElementSibling){let F=V(T);if(!F.item||F.template||T.hasAttribute("cms-template"))continue;let j={};x(j,T,L);let $n={root:y.root,state:y.state,item:j,ownerEl:T,projection:y.projection};$(T,j,$n),k.push(j),L++}}let w={app:t,root:r,rootObj:n,paints:o,stats:{calcs:0,lists:0},resolveDefault:b,collectEl:E,walkScope:_};for(let a of U)a.begin&&a.begin(w);let S=e.cacheReads===!1?null:Le(r);try{$(r,n,g)}finally{e.cacheReads!==!1&&Re(S)}if(t.halted)return;for(let a of U)a.afterIntake&&a.afterIntake(w);if(i.length&&s.size)for(let a of i)s.has(a.attr)&&a.el.getAttribute(a.attr)==null&&a.el.setAttribute(a.attr,a.value);for(let a of U)a.compute&&a.compute(w);let f=0;for(let a of U)a.reconcile&&(f+=a.reconcile(w));let c=0,l=f;for(let a of o){let m=or(a,t);a.ctx.view?l+=m:c+=m}for(let a of U)a.afterPaint&&a.afterPaint(w);t._state=n,t._stats={fields:Object.keys(n).filter(a=>typeof n[a]!="function").length,calcs:w.stats.calcs,paints:o.length,lists:w.stats.lists,writes:c,viewWrites:l},t._viewsChanged=l>0,t._lastPass={trigger:e.trigger||"refresh",writes:c},t._debug&&console.log(`sap pass \xB7 trigger: ${t._lastPass.trigger} \xB7 writes ${c}/${o.length}`)}function rr(t){return t.kind==="text"?t.fmt?"text:"+t.fmt:"text":t.kind==="attr"?"attr:"+t.arg:t.kind==="class"?"class:"+t.arg:t.kind==="css"?"css:"+t.arg:t.kind==="when"?(t.match==="hide"?"hide-when:":t.match==="show-not"?"option-not:":"show-when:")+t.field:t.kind}function ee(t,e,r,n){let o=t;for(;o&&o.nodeType===1;){if(o.hasAttribute&&o.hasAttribute(e)){let i=r.includes(o.getAttribute(e));if(n?!i:i)return!0}o=o.parentElement}return!1}function or(t,e){let r=t.def,n=t.el,o=Xe[r.kind];if(o)return o(t,e);if(r.kind==="when")return Ge(r,n,null);try{let i=O(r.entry,t.ctx.state,t.ctx.item,n,t.ctx.root),s=Ge(r,n,i);return nt(n),s}catch(i){return e.diag.error(i.sapCode==="E22"?"E22":"E24",n,{attr:rr(r),expr:r.entry&&r.entry.src,problem:String(i.message)}),B(n,i.sapCode||"E24"),0}}function Ge(t,e,r){switch(t.kind){case"text":{let n=t.fmt!=null?we(t.fmt,r):r==null?"":String(r);return e.textContent!==n?(e.textContent=n,1):0}case"show":{let n=!r;return e.hidden!==n?(e.hidden=n,1):0}case"when":{let n=R("optionVisibility");if(n&&n._started)return e._sapWhen&&e.hidden?(e.hidden=!1,e._sapWhen=!1,1):0;let o;t.match==="hide"?o=!ee(e,t.field,t.values,!1):t.match==="show-not"?o=ee(e,t.field,t.values,!0):o=ee(e,t.field,t.values,!1),e._sapWhen=!0;let i=!o;return e.hidden!==i?(e.hidden=i,1):0}case"attr":{let n=t.arg;if((n==="checked"||n==="selected")&&typeof e[n]=="boolean"&&!e.hasAttribute("bind")&&!e.closest("select[bind]")){let i=0;return e[n]!==!!r&&(e[n]=!!r,i=1),!!r!==e.hasAttribute(n)&&(r?e.setAttribute(n,""):e.removeAttribute(n),i=1),i}if(er.has(n)){let i=e.hasAttribute(n);return r&&!i?(e.setAttribute(n,""),1):!r&&i?(e.removeAttribute(n),1):0}let o=typeof r=="boolean"?String(r):r==null?"":String(r);return e.getAttribute(n)!==o?(e.setAttribute(n,o),1):0}case"class":{let n=!!r;return e.classList.contains(t.arg)!==n?(e.classList.toggle(t.arg,n),1):0}case"css":{let n=r==null?"":String(r);return e.style.getPropertyValue("--"+t.arg)!==n?(e.style.setProperty("--"+t.arg,n),1):0}default:return 0}}var ir=new Set(et),Je=new Set(["calc","text","attr","class","css","set","move","sort","option","option-not","show-when","hide-when","editmode","viewmode"]),sr=new Set(["show-when","hide-when","option","option-not"]),ar=/\b(?:state|item|root)\.|===|!==|&&|\|\||[()]|^\s*!/,Qe=new Set(["sap","scope","items","item","template","bind","show","effect","invalid","detail","state","transient","confirm","default","persist","sortable","trigger-add","trigger-remove","trigger-reset","sap-ignore","sap-error","no-save","no-watch","no-undo","no-trigger-autosave","freeze","mutations-ignore","save-remove","save-ignore","save-freeze"]),re=[];function Ze(t){re.includes(t)||re.push(t)}function ur(t){return t.tagName==="INPUT"||t.tagName==="SELECT"||t.tagName==="TEXTAREA"}function ne(t){return t.hasAttribute("bind")}function cr(t,e){e(t);for(let n=t.firstElementChild;n;n=n.nextElementSibling)r(n);function r(n){if(!n.hasAttribute("sap-ignore")){if(n.tagName==="TEMPLATE"){if(n.hasAttribute("items"))for(let o=n.content.firstElementChild;o;o=o.nextElementSibling)r(o);return}e(n);for(let o=n.firstElementChild;o;o=o.nextElementSibling)r(o)}}}function Bt(t,e){let r=!1,n=(s,g,b)=>{e.error(s,g,b),r=!0},o=t.ownerDocument.createTreeWalker(t,4),i;for(;i=o.nextNode();)if(/\{\{.*\}\}/.test(i.nodeValue||"")){n("E02",i.parentElement||t,{problem:"moustaches in text content are not a Sap feature",fix:'move the expression onto the element: text="state.x"'});break}return cr(t,s=>{let g=new Set;for(let p of re)p(s,n,u=>g.add(u));let b=s.closest&&s.closest("[detail]");for(let p of[...s.attributes]){let u=p.name;if(g.has(u))continue;if(u.includes(":")){let x=u.slice(0,u.indexOf(":"));if(Je.has(x)){if(sr.has(x)&&ar.test(p.value)){let $=u.slice(u.indexOf(":")+1);e.warn("W04",s,{attr:u,expr:p.value,problem:`${x}: compares the "${$}" attribute against a literal value, not a JS expression`,fix:`use show="${p.value}" for an expression, or a literal like ${x}:${$}="overview"`})}}else{let $=lt(x,[...Je]);e.warn("W03",s,{attr:u,problem:`unknown "${x}:" attribute`,didYouMean:$?`${$}:`:null})}}else if(!Qe.has(u)&&!ft.has(u)&&!ir.has(u)&&!/^(data-|aria-|on)/.test(u)&&!(u in s)){let x=lt(u,[...Qe]);x&&e.warn("W03",s,{attr:u,problem:`unknown "${u}" attribute`,didYouMean:x})}u==="attr:hidden"&&e.warn("W03",s,{attr:u,problem:"attr:hidden paints the wrong attribute",fix:'use show="expr"'});let E=ne(s)||u==="attr:selected"&&s.tagName==="OPTION"&&!!s.closest("select[bind]");(u==="attr:value"||u==="attr:checked"||u==="attr:selected")&&E&&n("E30",s,{attr:u,problem:"attr: on a bound control collides with persist ownership",fix:"remove it; bind owns this attribute"}),u==="effect"&&ne(s)&&/\b(value|checked)\s*=[^=]/.test(p.value)&&n("E30",s,{attr:u,expr:p.value,problem:"effect writes value/checked on a bound control (writes a stale value with no synthetic event)",fix:"write through onclick + Sap(this) instead"}),(u==="text"||u.startsWith("text:")||u==="show")&&ur(s)&&(u==="show"||n("E18",s,{attr:u,problem:"paint belongs on output elements, not form controls",fix:"move the paint to an <output> or <span>"}))}if(s.hasAttribute("state")){let p=D(s.getAttribute("state")),u=new Set;for(let E of p){E.name.includes("-")&&n("E08",s,{attr:"state",problem:`field "${E.name}" is not a valid identifier (the hyphen parses as subtraction)`,fix:`rename to ${E.name.replace(/-/g,"")}`}),u.has(E.name)&&n("E04",s,{attr:"state",problem:`field "${E.name}" is declared twice in one scope`}),u.add(E.name),xt.has(E.attr)&&n("E05",s,{attr:"state",problem:`"${E.name}" is a reserved Sap word`}),ft.has(E.attr)&&n("E06",s,{attr:"state",problem:`"${E.name}" is a global HTML attribute name; pick another field name`}),E.name==="open"&&s.tagName==="DIALOG"&&n("E33",s,{attr:"state",problem:"dialog open is transient",fix:"use showModal() \u2014 declare state= only on <details> or popovers"});let x=Gt(s,E.attr);x&&(E.attr==="checked"||E.attr==="selected")&&n("E35",s,{attr:"state",problem:`"${E.attr}" on a form control is the control's own state, not a declared field`,fix:'bind the control instead, e.g. <input type="checkbox" bind="done">'}),x&&E.type==="num"&&n("E35",s,{attr:"state",problem:`"${E.attr}" is an HTML boolean attribute; it cannot hold a number`,fix:`declare it bare: state="${E.attr}"`}),E.transient&&(x||E.type==="presence")&&n("E35",s,{attr:"state",problem:`"${E.name}" is carried by attribute presence, which transient would strip`,fix:"declare a separate name:bool:transient field and paint the attribute from it"})}}if(ne(s)){if(s.hasAttribute("-"),s.tagName==="INPUT"){let p=(s.getAttribute("type")||"text").toLowerCase();p==="file"&&n("E32",s,{attr:"bind",problem:"files never serialize into an HTML file",fix:"use no-save + effect instead of bind"}),p==="password"&&!s.hasAttribute("transient")&&n("E31",s,{attr:"bind",problem:"a password must never serialize into a world-readable file",fix:"add transient to the password input"})}else if(s.tagName!=="SELECT"&&s.tagName!=="TEXTAREA"){let p=s.getAttribute("contenteditable");!(p!=null&&p!=="false")&&s.children.length>0&&n("E20",s,{attr:"bind",problem:"bind on a container element is not a control; a write would overwrite its children",fix:"bind a control (input/select/textarea), a contenteditable, or an empty text leaf"})}}if(s.hasAttribute("transient")&&s.hasAttribute("persist")&&n("E34",s,{problem:"transient and persist are opposite: persist forces the live value into the saved bytes, leaking exactly what transient drops",fix:"remove one \u2014 transient to keep it out of the file, or persist to save it"}),s.tagName==="DIALOG"&&s.hasAttribute("detail")&&!(s.parentElement&&s.parentElement.closest('[clay~="freeze"], [freeze], [save-freeze]'))&&e.warn("W31",s,{attr:"detail",problem:"a detail dialog writes open when it opens, and that attribute would be saved into the file",fix:'wrap the dialog in an element with clay="freeze" (not editor-ui, which removes it from the file), and make its key field transient'}),s.hasAttribute("item")&&!s.hasAttribute("template")&&s.parentNode&&s.parentNode.nodeType===1){let p=s.parentElement;(!p||!p.hasAttribute("items"))&&n("E10",s,{problem:"an [item] must be a direct child of an [items] list",fix:'wrap it in a container with items="name"'})}if(s.hasAttribute("items")&&b&&n("E17",s,{attr:"items",problem:"nested items inside a detail panel is a v1 mount error (nested collections ship in v1.1)"}),s.hasAttribute("items")){let p=t.querySelector(`[trigger-add="${s.getAttribute("items")}"]`);!Tt(s)&&!zt(t,s.getAttribute("items"))&&H(s).length===0&&p&&n("E17",s,{attr:"items",problem:`trigger-add targets items="${s.getAttribute("items")}" but it has no [item template] to clone`})}}),r&&(e.halted=!0,e.haltReason=e.errors[0]?e.errors[0].code:"halt",B(t,e.haltReason)),!r}var tn="sap-styles",en="[item][template]{display:none!important}[hidden]{display:none!important}[sap-error]{outline:2px solid #e5484d;outline-offset:1px}",oe=new WeakSet;function fr(t){if(oe.has(t))return;let e=t.defaultView,r=e&&e.CSSStyleSheet;if(r&&"adoptedStyleSheets"in t)try{let n=new r;n.replaceSync(en),t.adoptedStyleSheets=[...t.adoptedStyleSheets,n],oe.add(t);return}catch{}if(!t.getElementById(tn)){let n=t.createElement("style");n.id=tn,n.textContent=en,(t.head||t.documentElement).appendChild(n)}oe.add(t)}var lr=0;function nn(){return typeof performance<"u"&&performance.now?performance.now():0}function ie(t){let e=t.id||t.getAttribute("sap")||`app-${lr++}`,r=new tt(e),n={root:t,name:e,diag:r,_state:null,_stats:null,_lastPass:null,_passes:0,_broken:!1,_mountMs:0,_mountWrites:0};if(!Bt(t,r))return n.halted=!0,n;fr(t.ownerDocument);for(let s of t.querySelectorAll("textarea[data-value]"))Mt(s);let i=nn();return ct(n,{trigger:"mount",full:!0}),n._mountMs=nn()-i,n._mountWrites=n._stats?n._stats.writes:0,n._mountWrites>0&&!Ie()&&!R("derived")&&r.warn("W30",t,{problem:`${n._mountWrites} paint(s) ran at mount; the saved file was out of sync with its declared state`,fix:"re-save once so the file mounts clean (a settled file writes nothing)"}),n}var rn=/^(set:|move:|sort:|trigger-add$|trigger-remove$|trigger-reset$)/;function qt(t){return`${t.tagName.toLowerCase()}[sap]`}function dr(t){let e=0;for(let r of t.querySelectorAll("*"))for(let n of r.attributes)if(rn.test(n.name)){e++;break}for(let r of t.attributes)if(rn.test(r.name)){e++;break}return e}function on(t){function e(g){let b=g._stats||{},p=g.root;return{root:qt(p),fields:b.fields||0,calcs:b.calcs||0,paints:b.paints||0,actions:dr(p),lists:(p.hasAttribute("items")?1:0)+p.querySelectorAll("[items]").length,rows:p.querySelectorAll("[item]:not([template])").length,warnings:g.diag.warnings.length,errors:g.diag.errors.length,mountWrites:g._mountWrites||0,ms:Math.round((g._mountMs||0)*10)/10,passes:g._passes||0,lastPass:g._lastPass||null,ok:g.diag.errors.length===0&&!g.halted}}function r(){let g=t.apps().map(e);return{ok:g.every(b=>b.ok),apps:g}}function n(g){let b=e(g);return b.ok?`sap \u2713 ${b.root} \xB7 fields ${b.fields} \xB7 calcs ${b.calcs} \xB7 paints ${b.paints} \xB7 actions ${b.actions} \xB7 lists ${b.lists} \xB7 rows ${b.rows} \xB7 warnings ${b.warnings} \xB7 mount writes ${b.mountWrites} \xB7 ${b.ms}ms`:`sap \u2717 ${b.root} \xB7 errors ${b.errors} \xB7 warnings ${b.warnings} \xB7 ${b.ms}ms`}function o(){for(let g of t.apps()){let b=n(g);g.diag.errors.length||g.halted?console.error(b):console.log(b)}}function i(){let g=[],b=[];for(let p of t.apps())g.push(...p.diag.errors),b.push(...p.diag.warnings);return{ok:g.length===0,errors:g,warnings:b,counts:{errors:g.length,warnings:b.length}}}function s(g){let b=g===void 0?!0:!!g;for(let p of t.apps())p._debug=b;return console.log(`sap debug ${b?"on":"off"} \u2014 per-pass headers will ${b?"":"no longer "}log`),b}return{status:r,report:i,debug:s,greenLine:n,printGreenLines:o,REGISTRY:Vt}}var sn="0.6.0";function an({createAccessor:t,installInput:e,debugExtras:r}){let n=new Map,o=[],i=se(ct);function s(l){let a=l;for(;a;){if(a.nodeType===1&&a.hasAttribute&&a.hasAttribute("sap"))return n.get(a)||null;a=a.parentNode&&a.parentNode.host?a.parentNode.host:a.parentElement}return null}function g(){for(let l=o.length-1;l>=0;l--){let a=o[l];a.root.isConnected||(n.delete(a.root),o.splice(l,1))}}function b(l,a){if(l.moveBefore)try{l.moveBefore(a,null);return}catch{}l.appendChild(a)}function p(l,a){let m=a.parentElement;if(m){if(m.moveBefore)try{m.moveBefore(l,a);return}catch{}m.insertBefore(l,a)}}let u={apps:()=>o.slice(),appFor:s,isRegistered:l=>n.has(l),pruneDisconnected:g,schedule:(l,a)=>i.schedule(l,a),runNow:(l,a)=>i.runNow(l,a),moveInto:b,placeBefore:p,remountIfPresent:()=>S()},E=t(u),x=on(u),$=r?r(u,x):{},_=!1,d=!1,A=null;function h(){_||(_=!0,e(u,E,document),A=qe(u))}function w(){let l=R("derived");l&&typeof l.mounted=="function"&&l.mounted()}function S(l=document){if(d)return[];h(),Zt(u);let a=l.querySelectorAll("[sap]"),m=[];for(let y of a){if(n.has(y))continue;let v=ie(y);n.set(y,v),o.push(v),m.push(v)}for(let y of m){let v=x.greenLine(y);y.diag.errors.length||y.halted?console.error(v):console.log(v)}return w(),m}function f(l){if(d)return null;if(h(),Zt(u),!l)return S();let a=typeof l=="string"?document.querySelector(l):l;if(!a)return null;if(n.has(a))return n.get(a);let m=ie(a);n.set(a,m),o.push(m);let y=x.greenLine(m);return m.diag.errors.length||m.halted?console.error(y):console.log(y),m}let c=E.Sap;return c.version=sn,c.refresh=function(){for(let a of o)a.root.isConnected&&i.runNow(a,"refresh")},c.batch=Be,c.status=x.status,c.report=x.report,c.why=$.why,c.debug=x.debug,c.doctor=$.doctor,c.greenLine=x.greenLine,c.formats=it,c.serializeControlToAttributes=at,c.finalizeControlForSave=Pe,c.rehydrateControlFromAttributes=Mt,c.mount=f,c.config=function(a={}){return a.formats&&Object.assign(it,a.formats),c},c._registry=n,c._reset=function(){n.clear(),o.length=0,te()},c.unmount=function(){d=!0,n.clear(),o.length=0,te(),typeof A=="function"&&A()},{Sap:c,mountAll:S,mount:f,runtime:u}}function un(t){if(typeof document>"u")return;let e=()=>Oe(()=>t());document.readyState==="loading"?document.addEventListener("DOMContentLoaded",e):e()}var pr=["for","form","list","headers","popovertarget","commandfor","anchor","aria-activedescendant","aria-controls","aria-describedby","aria-details","aria-errormessage","aria-flowto","aria-labelledby","aria-owns"];function mr(t,e){let r=null;return W(t,n=>{!r&&n.getAttribute("scope")===e&&(r=n)}),r}function cn(t,e,r){let n=P(t)||e;for(;n;){for(let o of D(n.getAttribute("state")||""))if(o.name===r)return{el:n,decl:o};if(n.hasAttribute("sap"))break;n=P(n.parentElement)}return null}function hr(t){return typeof t=="number"?"num":typeof t=="boolean"?"bool":"string"}function fn(t){function e(d){let A=t.appFor(d);if(!A)return null;let h=Y(d),w=h&&h._sapEachItem&&h._sapEachItem.$el;if(w&&w.isConnected)return{ctxEl:w,appRec:A,isRow:!0};let S=dt(d);if(S)return S._sapDetailRow?{ctxEl:S._sapDetailRow,appRec:A,isRow:!0}:{ctxEl:P(S.parentElement)||A.root,appRec:A,isRow:!1};let f=$t(d);if(f&&f.hasAttribute("item"))return{ctxEl:f,appRec:A,isRow:!0};let c=P(d)||A.root;return{ctxEl:c,appRec:A,isRow:c.hasAttribute("item")}}function r(d){let A=typeof d=="string"?document.querySelector(d):d;if(!A||A.nodeType!==1)return null;let h=e(A);return h?_(h.ctxEl,h.appRec,h.isRow):null}function n(d,A){let h=Y(d);if(!h)return r(d);let w=t.appFor(d),S=h._sapEachItem&&h._sapEachItem.$el;if(S&&S.nodeType===1&&S.hasAttribute("item")&&ot(S,A))return S.isConnected?_(S,w,!0):null;let f=h.parentElement&&h.parentElement._sapDrawnEl;return!f||!f.isConnected?null:_(f,w,f.hasAttribute("item"))}function o(d,A,h){let w=X(d,h);if(w)return M(w).read();let S=rt(d,h);if(S)return H(S).map(a=>_(a,A,!0));let f=mr(d,h);if(f)return _(f,A,!1);let c=cn(d,A.root,h);if(c)return c.decl.transient?Nt(c.el,c.decl):fe(c.el,c.decl);let l=d._sapScope;return l?l[h]:void 0}function i(d,A,h,w,S){w.transient?ht(d,w,h):mt(d,w,h),t.schedule(S,"set:"+A)}function s(d,A){let h=new Set,w=P(d)||A;for(;w;){for(let S of D(w.getAttribute("state")||""))h.add(S.name);if(w.hasAttribute("sap"))break;w=P(w.parentElement)}return W(d,S=>{let f=S.getAttribute("bind");f&&h.add(f)}),h}function g(d,A,h,w){let S=X(d,h);if(S){if(!N(S))return;M(S).write(w);return}let f=d;for(;f;){for(let L of f.attributes)if(L.name==="calc:"+h){A.diag.error("E16",f,{attr:"calc:"+h,problem:`"${h}" is a computed field; computed fields are read-only`});return}if(f.hasAttribute("sap"))break;f=f.parentElement}let c=cn(d,A.root,h);if(c){if(!N(c.el,{transient:c.decl.transient}))return;i(c.el,h,w,c.decl,A);return}let l=s(d,A.root);l.delete(h);let a=h.length>=4?lt(h,[...l]):null;if(a){A.diag.error("E12",d,{key:h,problem:`unknown state key "${h}"`,didYouMean:a});return}if(xt.has(h)||ft.has(h)){A.diag.error("E15",d,{key:h,problem:`cannot write undeclared field "${h}" \u2014 it is a reserved/global name and cannot become state`,fix:"pick a different field name, or declare it explicitly in a state= attribute"});return}let m=A.root;if(!N(m))return;let y=hr(w),v=m.getAttribute("state")||"",k=y==="string"?h:`${h}:${y}`;m.setAttribute("state",v?`${v} ${k}`:k),i(m,h,w,{name:h,attr:h,type:y,transient:!1},A)}function b(d){let A=d.ownerDocument,h=new Map,w=(S,f)=>{let c=ue(A),l=S.getAttribute(f);l&&f==="id"&&h.set(l,c),S.setAttribute(f,c)};d.querySelectorAll("[id]").forEach(S=>w(S,"id")),d.querySelectorAll("[data-id]").forEach(S=>w(S,"data-id")),d.querySelectorAll("[sap-error]").forEach(S=>S.removeAttribute("sap-error")),d.removeAttribute("sap-error"),d.hasAttribute("data-id")?(d.removeAttribute("id"),w(d,"data-id")):w(d,"id");for(let S of[d,...d.querySelectorAll("*")])for(let f of pr){let c=S.getAttribute(f);if(c==null)continue;let l=c.split(/\s+/).map(a=>h.get(a)||a).join(" ");l!==c&&S.setAttribute(f,l)}}function p(d,A,h){let w=bt(A.root,d,h);if(!w)return A.diag.error("E17",d,{problem:`cannot resolve a list named "${h}" from here`}),null;if(!N(w))return null;let S=Tt(w);if(!S)return A.diag.error("E17",w,{problem:`items="${h}" has no [item template] to clone`}),null;let f=w.ownerDocument.importNode(S,!0);return f.removeAttribute("template"),b(f),w.appendChild(f),t.schedule(A,"trigger-add:"+h),_(f,A,!0)}function u(d,A){let h=D(d.getAttribute("state")||""),w=!0;W(d,S=>{S.hasAttribute("bind")&&!N(S)&&(w=!1)});for(let S of h)N(d,{transient:S.transient})||(w=!1);if(w){W(d,S=>{if(S.hasAttribute("bind")){let f=M(S),c=S.getAttribute("default");f.kind==="checkbox"||f.kind==="radio"?f.write(c!=null?c===""||c==="true"||S.value===c:S.hasAttribute("checked")):f.write(c??(S.getAttribute("value")||""))}});for(let S of h){let f=le(d,S);S.transient?ht(d,S,f):mt(d,S,f)}t.schedule(A,"trigger-reset")}}function E(d,A){if(!d.isConnected)throw new Error("stale row handle: $remove() on a removed row");N(d)&&(d.remove(),t.schedule(A,"trigger-remove"))}function x(d,A,h){if(!d.isConnected)throw new Error("stale row handle: $move() on a removed row");let w=null;if(h&&h.nodeType===1?w=h:typeof h=="string"&&(w=bt(A.root,d,h)),!w){A.diag.error("E17",d,{problem:`$move() cannot resolve target "${h}"`});return}!N(d)||!N(w)||(t.moveInto(w,d),t.schedule(A,"trigger-move"))}function $(d){let A=d.parentElement;return A?H(A).indexOf(d):-1}function _(d,A,h){let w={get $el(){return d},get $key(){return kt(d,h?"row":"scope")},get $index(){return $(d)},$add(f){return p(d,A,f)},$reset(){return u(d,A),S},$remove(){E(d,A)},$move(f){x(d,A,f)},get $appRec(){return A}},S=new Proxy(w,{get(f,c){return typeof c=="symbol"||c[0]==="$"?f[c]:o(d,A,c)},set(f,c,l){return typeof c=="string"&&c[0]==="$"?(f[c]=l,!0):(g(d,A,c,l),!0)},has(f,c){return typeof c=="string"&&c[0]==="$"?c in f:o(d,A,c)!==void 0}});return S}return{Sap:r,contextElFor:e,readField:o,writeField:g,makeProxy:_,writeTargetFor:n}}var br=["trigger-add","trigger-remove","trigger-reset"];function gr(t){if(t.nodeType!==1)return!1;for(let e of t.attributes){let r=e.name;if(r.startsWith("set:")||r.startsWith("move:")||r.startsWith("sort:")||br.includes(r))return!0}return!1}function wr(t,e){let r=t,n=e.parentElement;for(;r&&r!==n;){if(r.nodeType===1&&gr(r)&&!(r.tagName==="FORM"&&r.hasAttribute("trigger-add")))return r;r=r.parentElement}return null}function ln(t,e){let{Sap:r}=e;function n(f,c){let l=null,a=Y(f),m=dt(f);if(a)l=a._sapEachItem??null;else if(m&&m._sapDetailRow)l=m._sapDetailRow._sapScope||null;else{let k=$t(f);k&&k.hasAttribute("item")&&(l=k._sapScope||null)}return{state:(P(f)||c.root)._sapScope||c._state||{},item:l,el:f,root:c._state||{}}}function o(f,c,l){if(!f.hasAttribute("confirm")){l();return}let a=f.getAttribute("confirm"),m=a,y=C(a);if(!y.error)try{let F=J(y,n(f,c));(typeof F=="string"||typeof F=="number")&&(m=String(F))}catch{}let v=At(),k=()=>{At()===v&&l()},L=We();if(!L){window.confirm(m)&&k();return}if(f._sapGatePending)return;f._sapGatePending=!0;let T=()=>{f._sapGatePending=!1};L(m,()=>{T(),k()}).catch(T)}function i(f,c){for(let l of f.attributes){if(!l.name.startsWith("set:"))continue;let a=l.name.slice(4),m=C(l.value);if(m.error){c.diag.error("E08",f,{attr:l.name,expr:l.value,problem:String(m.error.message)});continue}let y;try{y=J(m,n(f,c))}catch(k){c.diag.error("E24",f,{attr:l.name,expr:l.value,problem:String(k.message)});continue}let v=e.writeTargetFor(f,a);v&&(v[a]=y)}}function s(f){let c=Y(f);if(!c)return f.closest("[item]");let l=c._sapEachItem&&c._sapEachItem.$el;return l&&l.nodeType===1&&l.hasAttribute("item")?l:null}function g(f,c){let l=s(f);if(!l||!N(l)||!N(l.parentElement))return;let a=H(l.parentElement),m=a.indexOf(l);c==="up"&&m>0?t.placeBefore(l,a[m-1]):c==="down"&&m<a.length-1&&t.placeBefore(a[m+1],l)}function b(f,c,l){if(c)return bt(l.root,f,c);let a=f;for(;a;){if(a.hasAttribute&&a.hasAttribute("items"))return a;a=a.parentElement}let m=P(f)||l.root,y=[];return W(m,v=>{v.hasAttribute("items")&&y.push(v)}),y[0]||null}function p(f,c){let l=f==null||f==="",a=c==null||c==="";if(l&&a)return 0;if(l)return 1;if(a)return-1;let m=Number(f),y=Number(c);return!Number.isNaN(m)&&!Number.isNaN(y)?m-y:String(f)<String(c)?-1:String(f)>String(c)?1:0}function u(f,c,l,a){let m=b(f,l,a);if(!m){a.diag.error("E17",f,{attr:"sort:"+c,problem:`no items list resolvable for sort:${c}`});return}if(!N(m))return;let y=H(m),v=F=>F._sapScope?F._sapScope[c]:void 0,k=[...y].sort((F,j)=>p(v(F),v(j))),T=k.every((F,j)=>F===y[j])?[...k].reverse():k;for(let F of T)t.moveInto(m,F);t.schedule(a,"sort:"+c)}function E(f){if(!f||f.hidden)return;let c=f.querySelector("[bind]:not([type=hidden]), [contenteditable]");c&&typeof c.focus=="function"&&c.focus()}function x(f,c){o(f,c,()=>{let l=r(f);for(let a of[...f.attributes]){let m=a.name;if(m==="trigger-remove")l&&l.$remove();else if(m==="trigger-reset")l&&l.$reset();else if(m==="trigger-add"){let y=l&&l.$add(a.value);y&&E(y.$el)}else m==="move:up"?(g(f,"up"),t.schedule(c,"move:up")):m==="move:down"?(g(f,"down"),t.schedule(c,"move:down")):m.startsWith("move:to")?l&&l.$move(a.value):m.startsWith("sort:")&&u(f,m.slice(5),a.value,c)}[...f.attributes].some(a=>a.name.startsWith("set:"))&&i(f,c)})}function $(f){let c=f.target;if(!c||c.nodeType!==1)return;let l=t.appFor(c);if(!l)return;let a=wr(c,l.root);a&&x(a,l)}function _(f){let c=M(f),l=f.getAttribute("default");c.kind==="checkbox"?c.write(l===""||l==="true"):c.write(l??"")}function d(f,c,l){let a=r(f);if(!a)return;let m=a.$add(l);if(!m)return;let y=[];W(f,v=>{v.hasAttribute("bind")&&y.push(v)});for(let v of y){if(v.type==="radio"&&!v.checked)continue;let k=v.getAttribute("bind"),L=X(m.$el,k);L?M(L).write(M(v).read()):ot(m.$el,k)&&(m[k]=M(v).read())}y.forEach(_),y.length?typeof y[0].focus=="function"&&y[0].focus():E(m.$el)}function A(f){let c=f.target;if(!c||!c.hasAttribute||!c.hasAttribute("trigger-add"))return;let l=t.appFor(c);l&&(f.preventDefault(),o(c,l,()=>d(c,l,c.getAttribute("trigger-add"))))}function h(f){let c=f.target;if(!c||c.tagName!=="DIALOG"||!c.hasAttribute("detail"))return;if(c._sapEngineClose){c._sapEngineClose=!1;return}if(c.open)return;let l=/^[\w.]+\s+by\s+state\.(\w+)\s*$/.exec(c.getAttribute("detail")||""),a=t.appFor(c);if(!l||!a)return;let m=D(c.getAttribute("state")||"").find(v=>v.name===l[1]);if(m){if(!N(c,{transient:m.transient}))return;m.transient?ht(c,m,""):mt(c,m,""),t.schedule(a,"close");return}let y=r(c.parentElement);y&&y[l[1]]!==""&&(y[l[1]]="")}function w(f,c){let l=f.hasAttribute("bind")&&_t(f);if(!l&&f.hasAttribute("bind")&&Y(f)){let m=f.getAttribute("bind"),y=f._sapViewBind?e.writeTargetFor(f,m):null;return y&&(y[m]=M(f).read()),!0}let a=dt(f);if(a&&a._sapDetailRow&&f.hasAttribute("bind")&&!l){let m=a._sapDetailRow,y=f.getAttribute("bind"),v=X(m,y);if(v&&v!==f)return N(v)&&M(v).write(M(f).read()),!0;if(!v&&D(m.getAttribute("state")||"").some(k=>k.name===y))return e.writeField(m,c,y,M(f).read()),!0}return!1}function S(f=document){f.addEventListener("click",$),f.addEventListener("submit",A),f.addEventListener("close",h,!0)}return{install:S,routeInput:w}}function dn(t){let e=[];function r(b){let p=b.target;if(!p||p.nodeType!==1)return;let u=t.appFor(p);if(u){p.hasAttribute("persist")&&!Pt(p)&&N(p)&&at(p);for(let E of e)if(E(p,u))return;t.schedule(u,b.type+" "+(p.id||p.tagName.toLowerCase()))}}function n(b){let p=b.target,u=t.appFor(p);u&&[...p.querySelectorAll("[bind]")].every(E=>N(E))&&setTimeout(()=>{p.querySelectorAll("[bind]").forEach(E=>{E.dispatchEvent(new Event("input",{bubbles:!0})),E.dispatchEvent(new Event("change",{bubbles:!0}))}),t.schedule(u,"reset")},0)}function o(b){let p=t.appFor(b.target);p&&t.schedule(p,"toggle")}function i(b){let p=b.detail||{};for(let u of[p.from,p.to,b.target]){if(!u||u.nodeType!==1)continue;let E=t.appFor(u);E&&t.schedule(E,"sorted")}}function s(b){if(b.key!=="ArrowUp"&&b.key!=="ArrowDown")return;let p=b.target;if(!p||p.nodeType!==1||p.tagName!=="INPUT"||!p.hasAttribute("bind")||!p.hasAttribute("step"))return;let u=(p.getAttribute("type")||"text").toLowerCase();if(u!=="text"&&u!=="tel"&&u!=="search"||!t.appFor(p)||!N(p))return;b.preventDefault();let x=I(p.getAttribute("step"))||1,$=b.key==="ArrowUp"?1:-1,_=I(p.value)+x*(b.shiftKey?10:1)*$,d=p.getAttribute("min"),A=p.getAttribute("max");d!==null&&d!==""&&_<I(d)&&(_=I(d)),A!==null&&A!==""&&_>I(A)&&(_=I(A)),M(p).write(String(Number(_.toFixed(2))))}function g(b=document){b.addEventListener("reset",n),b.addEventListener("toggle",o,!0),b.addEventListener("input",r),b.addEventListener("change",r),b.addEventListener("clay:sorted",i),b.addEventListener("keydown",s)}return{install:g,addRouter:b=>e.push(b)}}function pn(t){let e=t.toLowerCase();return/^x-text$|^x-html$/.test(e)?'use text="state.x" (Sap paints text only)':/^x-show$|^v-show$|^v-if$/.test(e)?'use show="expr" (toggles native hidden)':/^x-model$|^v-model$/.test(e)?'use bind="field"':/^@|^x-on:|^v-on:|^on:/.test(e)?"use native onclick + Sap(this) (no event directive)":/^:|^x-bind:class$|^v-bind:class$/.test(e)?'use class:NAME="expr" or attr:NAME="expr"':/^x-for$|^v-for$/.test(e)?'use items="name" on the container and item template on the row':/^x-data$/.test(e)?"declare state with state= / bind / items (no JS state object)":/^x-init$/.test(e)?"use a <script> or onclick + Sap(this)":/^bind:/.test(e)?'use bind="field"; one-way paint is attr:NAME="expr"':/^x-/.test(e)||/^v-/.test(e)?"this is a foreign-dialect attribute; Sap has no x-/v- attributes":null}function mn(t){let e=[],r=n=>{for(let o of n.attributes){let i=o.name;(i.startsWith("calc:")||i==="text"||i.startsWith("text:")||i==="show"||i.startsWith("attr:")||i.startsWith("class:")||i.startsWith("css:")||i==="effect"||i==="invalid"||i.startsWith("set:")||i==="detail")&&e.push({el:n,attr:i,src:o.value})}};r(t);for(let n of t.querySelectorAll("*"))r(n);return e}function hn(t){function e(o){return o?typeof o=="string"?document.querySelector(o):o.nodeType===1?o:null:null}function r(o,i){let s=e(o);if(!s)return console.warn("sap why: element not found"),null;let g=[`sap why <${s.tagName.toLowerCase()}> \u2014 ${St(s)}`],b=[...s.attributes].filter(u=>/^(bind|text|show|effect|invalid|detail|calc:|text:|attr:|class:|css:|set:|state|items|scope)/.test(u.name));for(let u of b)g.push(` ${u.name}="${u.value}"`);let p=s;for(;p&&!p._sapScope;)p=p.parentElement;if(p&&p._sapScope){let u=p._sapScope,E=i?[i]:Object.keys(u);g.push(" reads:");for(let x of E){let $=u[x];typeof $!="function"&&g.push(` ${x} = ${JSON.stringify(Array.isArray($)?`[${$.length} rows]`:$)}`)}}return g.push(" serialization: textContent and value/checked attributes save with the file; reads live from properties"),console.log(g.join(`
|
|
10
|
+
`)),null}function n(){let o=[],i=0;for(let u of t.apps()){let E=u.root,x=qt(E);i++;let $=new tt(u.name);Bt(E,$);for(let w of $.errors)o.push({code:w.code,severity:"error",message:`${x}: ${w.code} ${w.slug} at ${w.el}`});for(let w of $.warnings)o.push({code:w.code,severity:"warn",message:`${x}: ${w.code} ${w.slug} at ${w.el}`});i++,ct(u,{trigger:"doctor-dryrun"});let _=u._stats?u._stats.writes:0;_>0&&o.push({code:"W30",severity:"warn",message:`${x}: dry recompute wrote ${_} cells on a quiet page; an element is stale or non-idempotent`}),i++;let d=mn(E).map(w=>w.src).join(" \0 "),A=[];for(let w of[E,...E.querySelectorAll("[state]")])for(let S of D(w.getAttribute("state")||""))A.push(S.name);for(let w of A)new RegExp(`(state|item)\\.${w}\\b`).test(d)||o.push({code:"I33",severity:"info",message:`${x}: field "${w}" is declared but read nowhere (dead state)`});i++;let h=new Map;for(let w of E.querySelectorAll("[id]"))h.set(w.id,(h.get(w.id)||0)+1);for(let[w,S]of h)S>1&&o.push({code:"W32",severity:"warn",message:`${x}: duplicate id "${w}" (${S} elements) \u2014 clone/edit collision`});i++;for(let w of mn(E))w.src.length>120&&o.push({code:"I33",severity:"info",message:`${x}: ${w.attr} expression is ${w.src.length} chars; consider a calc: field`});i++;for(let w of E.querySelectorAll("[text], [text\\:num]")){let S=w.textContent||"";/\.\d{5,}/.test(S)&&o.push({code:"I33",severity:"info",message:`${x}: ${St(w)} paints >4 decimals; consider text:FMT`})}}let s=o.filter(u=>u.severity==="error").length,g=o.filter(u=>u.severity==="warn").length,b=o.filter(u=>u.severity==="info").length;console.log(`sap doctor \xB7 ${t.apps().map(u=>qt(u.root)).join(", ")} \xB7 errors ${s} \xB7 warnings ${g} \xB7 info ${b} \xB7 ${i} checks \xB7 0ms`);for(let u of o)(u.severity==="error"?console.error:u.severity==="warn"?console.warn:console.info)(` ${u.severity==="error"?"\u2717":u.severity==="warn"?"\u26A0":"\xB7"} ${u.message}`);return o}return{why:r,doctor:n}}function yr(t,e){let r=String(t).split("."),n=i=>{for(let s of r){if(i==null)return;i=Array.isArray(i)?i.flatMap(g=>g&&g[s]!=null?g[s]:[]):i[s]}return i},o=n(e.state);return o===void 0?n(e.root):o}function Ar(t,e,r,n){e._sapScope=r;let o=e.getAttribute("detail")||"",i=/^([\w.]+)\s+by\s+(.+)$/.exec(o);if(!i){e.hidden=!0,e._sapDetailRow=null;return}let s=i[1],g=i[2].trim(),b=yr(s,n),p;try{p=J(C(g),{state:r,item:n.item,el:e,root:n.root})}catch{p=void 0}let u=Array.isArray(b)&&p!=null?b.find(x=>x&&typeof x=="object"&&x.$el&&String(x.$key)===String(p)):null;if(e._sapDetailRow=u?u.$el:null,e.tagName==="DIALOG"){let x=u?String(u.$key):null;if(x!==e._sapDetailKey&&(e._sapDetailKey=x,e._sapDismissed=!1),!u){e._sapOpenedFor=null,e.open&&typeof e.close=="function"&&(e._sapEngineClose=!0,e.close());return}e.open?e._sapOpenedFor=x:(e._sapOpenedFor===x&&(e._sapDismissed=!0),e._sapOpenedFor=null,!e._sapDismissed&&e.isConnected&&typeof e.showModal=="function"&&(e.hidden&&(e.hidden=!1),e.showModal(),e._sapOpenedFor=x))}else{if(!u){e.hidden||(e.hidden=!0);return}e.hidden&&(e.hidden=!1)}Ft();let E={root:n.root,state:r,item:u,ownerEl:u.$el,projection:!0};t.collectEl(e,V(e),E),t.walkScope(e,u,E)}var bn={name:"detail",begin(t){t.deferredDetails=[]},boundary:{detail(t,e,r,n,o){for(let i of D(e.getAttribute("state")||""))i.name in n||(n[i.name]=K(e,i)?e.hasAttribute(i.attr):t.resolveDefault(e,i));t.deferredDetails.push({el:e,parentObj:n,ctx:o})}},afterIntake(t){for(let e=0;e<t.deferredDetails.length;e++){let{el:r,parentObj:n,ctx:o}=t.deferredDetails[e];Ar(t,r,n,o)}}};function gn(t){let e=0,r=t;for(;r&&!(r.hasAttribute&&r.hasAttribute("sap"));)r=r.parentElement,e++;return e}var wn={name:"calc",begin(t){t.calcs=[]},collect(t,e,r,n){if(!r.calcs)return;let o=n.item||n.state;for(let i of r.calcs)t.calcs.push({owner:o,ownerEl:n.ownerEl,name:i.name,entry:i.entry,def:i,el:e,ctx:n})},compute(t){let e=t.app,r=new Map;for(let o of t.calcs){let i=r.get(o.owner);i||(i={ownerEl:o.ownerEl,list:[]},r.set(o.owner,i)),i.list.push(o)}let n=[...r.values()].sort((o,i)=>gn(i.ownerEl)-gn(o.ownerEl));for(let o of n){let i;try{i=ve(o.list)}catch(s){e.diag.error("E07",o.list[0].el,{problem:s.message}),i=o.list}for(let s of i)try{s.owner[s.name]=O(s.entry,s.ctx.state,s.ctx.item,s.el,s.ctx.root),nt(s.el)}catch(g){s.owner[s.name]=void 0,e.diag.error("E24",s.el,{attr:"calc:"+s.name,expr:s.entry.src,problem:String(g.message)}),B(s.el,g.sapCode||"E24")}}t.stats.calcs=t.calcs.length,t.stats.lists=r.size}};function vr(t,e,r){let n=r.nextSibling;if(e.isConnected&&t.moveBefore)try{t.moveBefore(e,n);return}catch{}t.insertBefore(e,n)}function Er(t,e,r){for(let n=e.parentElement;n;n=n.parentElement)if(n._sapScope===r&&!n.hasAttribute("detail")||n.hasAttribute("sap"))return n;return t}function xr(t,e,r){let n=t.app;e._sapDrawnEl=Er(t.root,e,r.state);let o=null;for(let d=e.firstElementChild;d;d=d.nextElementSibling)if(d.tagName==="TEMPLATE"){o=d;break}let i=o&&o.content.children.length===1?o.content.firstElementChild:null;if(!i)return n.diag.error("E42",e,{attr:"each",problem:"each needs one <template> child with exactly one element root"}),0;let s=e.getAttribute("each"),g;try{g=J(C(s),{state:r.state,item:r.item,el:e,root:r.root})}catch(d){return n.diag.error("E24",e,{attr:"each",expr:s,problem:String(d.message)}),0}if(!Array.isArray(g))return n.diag.error("E40",e,{attr:"each",expr:s,problem:"each must evaluate to an array; the list keeps its last good rows"}),0;let b=C(e.getAttribute("key")||"item.$key"),p=[],u=new Set;for(let d of g){let A;try{A=O(b,r.state,d,e,r.root)}catch{A=void 0}let h=A==null?"":String(A);if(h===""||u.has(h))return n.diag.error("E41",e,{attr:"key",expr:b.src,problem:h===""?"an item has no key; the list keeps its last good rows":`duplicate key "${h}"; the list keeps its last good rows`}),0;u.add(h),p.push(h)}let E=e._sapEach||new Map,x=new Map,$=0,_=o;p.forEach((d,A)=>{let h=E.get(d);if(!h||h.parentElement!==e){h=e.ownerDocument.importNode(i,!0);let w=(h.getAttribute("clay")||"").split(/\s+/).filter(Boolean);w.includes("editor-ui")||h.setAttribute("clay",[...w,"editor-ui"].join(" ")),h._sapEachRow=!0,$++}h.getAttribute("data-key")!==d&&h.setAttribute("data-key",d),_.nextElementSibling!==h&&(vr(e,h,_),$++),h._sapEachItem=g[A],x.set(d,h),_=h});for(let[d,A]of E)x.get(d)!==A&&A.parentElement===e&&(A.remove(),$++);return e._sapEach=x,Ft(),p.forEach((d,A)=>{let h=x.get(d),w={root:r.root,state:r.state,item:g[A],ownerEl:h,projection:!1,view:!0};t.collectEl(h,V(h),w),t.walkScope(h,{},w)}),$}var yn={name:"each",begin(t){t.eachList=[]},boundary:{each(t,e,r,n,o){t.collectEl(e,r,o),t.eachList.push({el:e,ctx:o})}},reconcile(t){let e=0;for(let r=0;r<t.eachList.length;r++)e+=xr(t,t.eachList[r].el,t.eachList[r].ctx);return e}};function Sr(t,e){try{O(t.def.entry,t.ctx.state,t.ctx.item,t.el,t.ctx.root),nt(t.el)}catch(r){e.diag.error("E24",t.el,{attr:"effect",expr:t.def.entry&&t.def.entry.src,problem:String(r.message)}),B(t.el,"E24")}}var An={name:"effect",begin(t){t.effects=[]},collect(t,e,r,n){if(r.effects)for(let o of r.effects)t.effects.push({def:o,el:e,ctx:n})},afterPaint(t){for(let e of t.effects)Sr(e,t.app)}};function kr(t){let e="";try{let r=O(t.def.entry,t.ctx.state,t.ctx.item,t.el,t.ctx.root);e=typeof r=="string"?r:""}catch{e=""}typeof t.el.setCustomValidity=="function"&&t.el.setCustomValidity(e)}var vn={name:"validation",begin(t){t.invalids=[]},collect(t,e,r,n){if(r.invalids)for(let o of r.invalids)t.invalids.push({def:o,el:e,ctx:n})},afterPaint(t){for(let e of t.invalids)kr(e)}};function En(t,e){if(t===t.ownerDocument.activeElement)return 0;if(t.type==="radio"){let i=e!=null&&String(t.value)===String(e);return t.checked===i?0:(t.checked=i,1)}let r=vt(t),n=It(t,r),o=e??"";return String(n)!==String(o)?(Ve(t,r,o),1):0}var xn={name:"projection",collect(t,e,r,n){if(!(r.bind!=null&&(n.view||n.projection)&&!_t(e)))return;let o=r.bind,i=t.paints;n.view?ot(ce(n.item),o)?(e._sapViewBind="item",i.push({def:{kind:"projection",field:o,from:"item"},el:e,ctx:n})):o in n.state||o in n.root?(e._sapViewBind="drawn",i.push({def:{kind:"projection",field:o,from:"drawn"},el:e,ctx:n})):(e._sapViewBind=null,t.app.diag.error("E43",e,{attr:"bind",expr:o,problem:`bind="${o}" inside an each row matches no field of the row's record or of the scope the row is drawn in`,fix:"bind a field the record owns (bind, state= or items= on the [item]), or declare it with state= where the list is drawn"})):i.push({def:{kind:"projection",field:o,from:null},el:e,ctx:n})},paintKinds:{projection(t){let e=t.def;if(e.from==="drawn"){let r=e.field in t.ctx.state?t.ctx.state:t.ctx.root;return En(t.el,r[e.field])}return En(t.el,t.ctx.item?t.ctx.item[e.field]:"")}}};function Sn(){for(let t of[bn,wn,yn,An,vn,xn])Ke(t)}Sn();Ze((t,e,r)=>{for(let n of t.attributes){let o=pn(n.name);o&&(e("E01",t,{attr:n.name,expr:n.value,problem:`"${n.name}" is a foreign-dialect attribute; Sap has no ${n.name.split(/[:=]/)[0]} directive`,fix:o+" \u2014 or wrap the subtree in sap-ignore if intentional"}),r(n.name))}});var{Sap:jt,mountAll:kn,mount:$r,runtime:_r}=an({createAccessor:fn,debugExtras:hn,installInput(t,e,r){let n=dn(t),o=ln(t,e);n.addRouter(o.routeInput),n.install(r),o.install(r)}}),Et=typeof window<"u"?window.Sap:null;Et&&Et!==jt&&Et.core&&typeof Et.unmount=="function"&&Et.unmount();un(kn);typeof window<"u"&&(window.Sap=jt);var Tr=jt;return Cn(Nr);})();
|
|
11
11
|
if (typeof window !== 'undefined' && Sap && Sap.default) window.Sap = Sap.default;
|
|
12
12
|
var sapDefault = Sap.default;
|
|
13
13
|
window.clay = window.clay || {};
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-ThinItalic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-ExtraLight.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-ExtraLightItalic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-Light.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-LightItalic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-Regular.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-Italic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-Medium.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-MediumItalic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-SemiBold.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-SemiBoldItalic.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-Bold.ttf: Copyright 2017 IBM Corp. All rights reserved. IBMPlexMono-BoldItalic.ttf: Copyright 2017 IBM Corp. All rights reserved.
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
Copyright 2019 IBM Corp. All rights reserved. IBMPlexSans-Italic[wdth,wght].ttf: Copyright 2019 IBM Corp. All rights reserved.
|
|
2
|
+
|
|
3
|
+
This Font Software is licensed under the SIL Open Font License, Version 1.1.
|
|
4
|
+
This license is copied below, and is also available with a FAQ at:
|
|
5
|
+
http://scripts.sil.org/OFL
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
-----------------------------------------------------------
|
|
9
|
+
SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007
|
|
10
|
+
-----------------------------------------------------------
|
|
11
|
+
|
|
12
|
+
PREAMBLE
|
|
13
|
+
The goals of the Open Font License (OFL) are to stimulate worldwide
|
|
14
|
+
development of collaborative font projects, to support the font creation
|
|
15
|
+
efforts of academic and linguistic communities, and to provide a free and
|
|
16
|
+
open framework in which fonts may be shared and improved in partnership
|
|
17
|
+
with others.
|
|
18
|
+
|
|
19
|
+
The OFL allows the licensed fonts to be used, studied, modified and
|
|
20
|
+
redistributed freely as long as they are not sold by themselves. The
|
|
21
|
+
fonts, including any derivative works, can be bundled, embedded,
|
|
22
|
+
redistributed and/or sold with any software provided that any reserved
|
|
23
|
+
names are not used by derivative works. The fonts and derivatives,
|
|
24
|
+
however, cannot be released under any other type of license. The
|
|
25
|
+
requirement for fonts to remain under this license does not apply
|
|
26
|
+
to any document created using the fonts or their derivatives.
|
|
27
|
+
|
|
28
|
+
DEFINITIONS
|
|
29
|
+
"Font Software" refers to the set of files released by the Copyright
|
|
30
|
+
Holder(s) under this license and clearly marked as such. This may
|
|
31
|
+
include source files, build scripts and documentation.
|
|
32
|
+
|
|
33
|
+
"Reserved Font Name" refers to any names specified as such after the
|
|
34
|
+
copyright statement(s).
|
|
35
|
+
|
|
36
|
+
"Original Version" refers to the collection of Font Software components as
|
|
37
|
+
distributed by the Copyright Holder(s).
|
|
38
|
+
|
|
39
|
+
"Modified Version" refers to any derivative made by adding to, deleting,
|
|
40
|
+
or substituting -- in part or in whole -- any of the components of the
|
|
41
|
+
Original Version, by changing formats or by porting the Font Software to a
|
|
42
|
+
new environment.
|
|
43
|
+
|
|
44
|
+
"Author" refers to any designer, engineer, programmer, technical
|
|
45
|
+
writer or other person who contributed to the Font Software.
|
|
46
|
+
|
|
47
|
+
PERMISSION & CONDITIONS
|
|
48
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
|
49
|
+
a copy of the Font Software, to use, study, copy, merge, embed, modify,
|
|
50
|
+
redistribute, and sell modified and unmodified copies of the Font
|
|
51
|
+
Software, subject to the following conditions:
|
|
52
|
+
|
|
53
|
+
1) Neither the Font Software nor any of its individual components,
|
|
54
|
+
in Original or Modified Versions, may be sold by itself.
|
|
55
|
+
|
|
56
|
+
2) Original or Modified Versions of the Font Software may be bundled,
|
|
57
|
+
redistributed and/or sold with any software, provided that each copy
|
|
58
|
+
contains the above copyright notice and this license. These can be
|
|
59
|
+
included either as stand-alone text files, human-readable headers or
|
|
60
|
+
in the appropriate machine-readable metadata fields within text or
|
|
61
|
+
binary files as long as those fields can be easily viewed by the user.
|
|
62
|
+
|
|
63
|
+
3) No Modified Version of the Font Software may use the Reserved Font
|
|
64
|
+
Name(s) unless explicit written permission is granted by the corresponding
|
|
65
|
+
Copyright Holder. This restriction only applies to the primary font name as
|
|
66
|
+
presented to the users.
|
|
67
|
+
|
|
68
|
+
4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font
|
|
69
|
+
Software shall not be used to promote, endorse or advertise any
|
|
70
|
+
Modified Version, except to acknowledge the contribution(s) of the
|
|
71
|
+
Copyright Holder(s) and the Author(s) or with their explicit written
|
|
72
|
+
permission.
|
|
73
|
+
|
|
74
|
+
5) The Font Software, modified or unmodified, in part or in whole,
|
|
75
|
+
must be distributed entirely under this license, and must not be
|
|
76
|
+
distributed under any other license. The requirement for fonts to
|
|
77
|
+
remain under this license does not apply to any document created
|
|
78
|
+
using the Font Software.
|
|
79
|
+
|
|
80
|
+
TERMINATION
|
|
81
|
+
This license becomes null and void if any of the above conditions are
|
|
82
|
+
not met.
|
|
83
|
+
|
|
84
|
+
DISCLAIMER
|
|
85
|
+
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
|
86
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
|
|
87
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
|
|
88
|
+
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
|
|
89
|
+
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
|
90
|
+
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
|
|
91
|
+
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
|
92
|
+
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
|
|
93
|
+
OTHER DEALINGS IN THE FONT SOFTWARE.
|