@despia-native/kernel 0.0.0-stage → 0.3.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/LICENSE +202 -0
- package/NOTICE +1414 -0
- package/README.md +17 -2
- package/dist/.dsx-build-stamp.json +7 -0
- package/dist/api-cohort.d.ts +27 -0
- package/dist/api-cohort.d.ts.map +1 -0
- package/dist/api-cohort.js +94 -0
- package/dist/api-cohort.js.map +1 -0
- package/dist/api.d.ts +454 -0
- package/dist/api.d.ts.map +1 -0
- package/dist/api.js +2442 -0
- package/dist/api.js.map +1 -0
- package/dist/app-consts.d.ts +10 -0
- package/dist/app-consts.d.ts.map +1 -0
- package/dist/app-consts.js +39 -0
- package/dist/app-consts.js.map +1 -0
- package/dist/app-update.d.ts +12 -0
- package/dist/app-update.d.ts.map +1 -0
- package/dist/app-update.js +32 -0
- package/dist/app-update.js.map +1 -0
- package/dist/aria.d.ts +152 -0
- package/dist/aria.d.ts.map +1 -0
- package/dist/aria.js +524 -0
- package/dist/aria.js.map +1 -0
- package/dist/audio-core.d.ts +260 -0
- package/dist/audio-core.d.ts.map +1 -0
- package/dist/audio-core.js +1440 -0
- package/dist/audio-core.js.map +1 -0
- package/dist/audio-edit.d.ts +100 -0
- package/dist/audio-edit.d.ts.map +1 -0
- package/dist/audio-edit.js +489 -0
- package/dist/audio-edit.js.map +1 -0
- package/dist/audio-mix.d.ts +84 -0
- package/dist/audio-mix.d.ts.map +1 -0
- package/dist/audio-mix.js +393 -0
- package/dist/audio-mix.js.map +1 -0
- package/dist/auth-proof.d.ts +145 -0
- package/dist/auth-proof.d.ts.map +1 -0
- package/dist/auth-proof.js +644 -0
- package/dist/auth-proof.js.map +1 -0
- package/dist/availability-explain.d.ts +3 -0
- package/dist/availability-explain.d.ts.map +1 -0
- package/dist/availability-explain.js +322 -0
- package/dist/availability-explain.js.map +1 -0
- package/dist/availability.d.ts +246 -0
- package/dist/availability.d.ts.map +1 -0
- package/dist/availability.js +615 -0
- package/dist/availability.js.map +1 -0
- package/dist/background.d.ts +116 -0
- package/dist/background.d.ts.map +1 -0
- package/dist/background.js +235 -0
- package/dist/background.js.map +1 -0
- package/dist/boot-tables-flag.d.ts +2 -0
- package/dist/boot-tables-flag.d.ts.map +1 -0
- package/dist/boot-tables-flag.js +16 -0
- package/dist/boot-tables-flag.js.map +1 -0
- package/dist/boot-tables.d.ts +40 -0
- package/dist/boot-tables.d.ts.map +1 -0
- package/dist/boot-tables.js +102 -0
- package/dist/boot-tables.js.map +1 -0
- package/dist/border-edges.d.ts +5 -0
- package/dist/border-edges.d.ts.map +1 -0
- package/dist/border-edges.js +47 -0
- package/dist/border-edges.js.map +1 -0
- package/dist/bus.d.ts +1203 -0
- package/dist/bus.d.ts.map +1 -0
- package/dist/bus.js +2647 -0
- package/dist/bus.js.map +1 -0
- package/dist/calendar-core.d.ts +143 -0
- package/dist/calendar-core.d.ts.map +1 -0
- package/dist/calendar-core.js +372 -0
- package/dist/calendar-core.js.map +1 -0
- package/dist/call-value.d.ts +16 -0
- package/dist/call-value.d.ts.map +1 -0
- package/dist/call-value.js +54 -0
- package/dist/call-value.js.map +1 -0
- package/dist/camera-core.d.ts +222 -0
- package/dist/camera-core.d.ts.map +1 -0
- package/dist/camera-core.js +980 -0
- package/dist/camera-core.js.map +1 -0
- package/dist/canvas-core.d.ts +404 -0
- package/dist/canvas-core.d.ts.map +1 -0
- package/dist/canvas-core.js +2186 -0
- package/dist/canvas-core.js.map +1 -0
- package/dist/capture-core.d.ts +74 -0
- package/dist/capture-core.d.ts.map +1 -0
- package/dist/capture-core.js +158 -0
- package/dist/capture-core.js.map +1 -0
- package/dist/compile/codegen.d.ts +146 -0
- package/dist/compile/codegen.d.ts.map +1 -0
- package/dist/compile/codegen.js +1949 -0
- package/dist/compile/codegen.js.map +1 -0
- package/dist/compile/jstier.d.ts +44 -0
- package/dist/compile/jstier.d.ts.map +1 -0
- package/dist/compile/jstier.js +181 -0
- package/dist/compile/jstier.js.map +1 -0
- package/dist/compile/tier-door.d.ts +41 -0
- package/dist/compile/tier-door.d.ts.map +1 -0
- package/dist/compile/tier-door.js +167 -0
- package/dist/compile/tier-door.js.map +1 -0
- package/dist/compile/tier-realm.d.ts +49 -0
- package/dist/compile/tier-realm.d.ts.map +1 -0
- package/dist/compile/tier-realm.js +368 -0
- package/dist/compile/tier-realm.js.map +1 -0
- package/dist/compile/tier.d.ts +23 -0
- package/dist/compile/tier.d.ts.map +1 -0
- package/dist/compile/tier.js +157 -0
- package/dist/compile/tier.js.map +1 -0
- package/dist/compose-core.d.ts +86 -0
- package/dist/compose-core.d.ts.map +1 -0
- package/dist/compose-core.js +112 -0
- package/dist/compose-core.js.map +1 -0
- package/dist/config-validate.d.ts +31 -0
- package/dist/config-validate.d.ts.map +1 -0
- package/dist/config-validate.js +147 -0
- package/dist/config-validate.js.map +1 -0
- package/dist/config-values.d.ts +106 -0
- package/dist/config-values.d.ts.map +1 -0
- package/dist/config-values.js +340 -0
- package/dist/config-values.js.map +1 -0
- package/dist/contacts-core.d.ts +127 -0
- package/dist/contacts-core.d.ts.map +1 -0
- package/dist/contacts-core.js +211 -0
- package/dist/contacts-core.js.map +1 -0
- package/dist/content-transition.d.ts +58 -0
- package/dist/content-transition.d.ts.map +1 -0
- package/dist/content-transition.js +94 -0
- package/dist/content-transition.js.map +1 -0
- package/dist/controls-core.d.ts +227 -0
- package/dist/controls-core.d.ts.map +1 -0
- package/dist/controls-core.js +652 -0
- package/dist/controls-core.js.map +1 -0
- package/dist/cookies.d.ts +78 -0
- package/dist/cookies.d.ts.map +1 -0
- package/dist/cookies.js +265 -0
- package/dist/cookies.js.map +1 -0
- package/dist/corner-shape-core.d.ts +69 -0
- package/dist/corner-shape-core.d.ts.map +1 -0
- package/dist/corner-shape-core.js +261 -0
- package/dist/corner-shape-core.js.map +1 -0
- package/dist/crypto-core.d.ts +57 -0
- package/dist/crypto-core.d.ts.map +1 -0
- package/dist/crypto-core.js +128 -0
- package/dist/crypto-core.js.map +1 -0
- package/dist/dataviz.d.ts +436 -0
- package/dist/dataviz.d.ts.map +1 -0
- package/dist/dataviz.js +956 -0
- package/dist/dataviz.js.map +1 -0
- package/dist/debug.d.ts +293 -0
- package/dist/debug.d.ts.map +1 -0
- package/dist/debug.js +767 -0
- package/dist/debug.js.map +1 -0
- package/dist/device-ownership.d.ts +50 -0
- package/dist/device-ownership.d.ts.map +1 -0
- package/dist/device-ownership.js +105 -0
- package/dist/device-ownership.js.map +1 -0
- package/dist/effects.d.ts +86 -0
- package/dist/effects.d.ts.map +1 -0
- package/dist/effects.js +98 -0
- package/dist/effects.js.map +1 -0
- package/dist/element.d.ts +108 -0
- package/dist/element.d.ts.map +1 -0
- package/dist/element.js +63 -0
- package/dist/element.js.map +1 -0
- package/dist/file-watch.d.ts +16 -0
- package/dist/file-watch.d.ts.map +1 -0
- package/dist/file-watch.js +49 -0
- package/dist/file-watch.js.map +1 -0
- package/dist/filepaths.d.ts +72 -0
- package/dist/filepaths.d.ts.map +1 -0
- package/dist/filepaths.js +271 -0
- package/dist/filepaths.js.map +1 -0
- package/dist/film.d.ts +264 -0
- package/dist/film.d.ts.map +1 -0
- package/dist/film.js +313 -0
- package/dist/film.js.map +1 -0
- package/dist/fonts.d.ts +66 -0
- package/dist/fonts.d.ts.map +1 -0
- package/dist/fonts.js +135 -0
- package/dist/fonts.js.map +1 -0
- package/dist/forms.d.ts +191 -0
- package/dist/forms.d.ts.map +1 -0
- package/dist/forms.js +663 -0
- package/dist/forms.js.map +1 -0
- package/dist/geo.d.ts +289 -0
- package/dist/geo.d.ts.map +1 -0
- package/dist/geo.js +460 -0
- package/dist/geo.js.map +1 -0
- package/dist/handler-announce.d.ts +46 -0
- package/dist/handler-announce.d.ts.map +1 -0
- package/dist/handler-announce.js +96 -0
- package/dist/handler-announce.js.map +1 -0
- package/dist/handoff.d.ts +71 -0
- package/dist/handoff.d.ts.map +1 -0
- package/dist/handoff.js +250 -0
- package/dist/handoff.js.map +1 -0
- package/dist/identity-durability.d.ts +76 -0
- package/dist/identity-durability.d.ts.map +1 -0
- package/dist/identity-durability.js +150 -0
- package/dist/identity-durability.js.map +1 -0
- package/dist/image-core.d.ts +240 -0
- package/dist/image-core.d.ts.map +1 -0
- package/dist/image-core.js +618 -0
- package/dist/image-core.js.map +1 -0
- package/dist/image-schemes.d.ts +10 -0
- package/dist/image-schemes.d.ts.map +1 -0
- package/dist/image-schemes.js +28 -0
- package/dist/image-schemes.js.map +1 -0
- package/dist/index.d.ts +143 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +299 -0
- package/dist/index.js.map +1 -0
- package/dist/ink-core.d.ts +53 -0
- package/dist/ink-core.d.ts.map +1 -0
- package/dist/ink-core.js +119 -0
- package/dist/ink-core.js.map +1 -0
- package/dist/input.d.ts +148 -0
- package/dist/input.d.ts.map +1 -0
- package/dist/input.js +358 -0
- package/dist/input.js.map +1 -0
- package/dist/integrity.d.ts +63 -0
- package/dist/integrity.d.ts.map +1 -0
- package/dist/integrity.js +150 -0
- package/dist/integrity.js.map +1 -0
- package/dist/intents.d.ts +95 -0
- package/dist/intents.d.ts.map +1 -0
- package/dist/intents.js +282 -0
- package/dist/intents.js.map +1 -0
- package/dist/interpolate-core.d.ts +37 -0
- package/dist/interpolate-core.d.ts.map +1 -0
- package/dist/interpolate-core.js +443 -0
- package/dist/interpolate-core.js.map +1 -0
- package/dist/jse/color.d.ts +12 -0
- package/dist/jse/color.d.ts.map +1 -0
- package/dist/jse/color.js +196 -0
- package/dist/jse/color.js.map +1 -0
- package/dist/jse/core.d.ts +54 -0
- package/dist/jse/core.d.ts.map +1 -0
- package/dist/jse/core.js +1519 -0
- package/dist/jse/core.js.map +1 -0
- package/dist/jse/dispatch.d.ts +28 -0
- package/dist/jse/dispatch.d.ts.map +1 -0
- package/dist/jse/dispatch.js +116 -0
- package/dist/jse/dispatch.js.map +1 -0
- package/dist/jse/highlight-grammar.d.ts +15 -0
- package/dist/jse/highlight-grammar.d.ts.map +1 -0
- package/dist/jse/highlight-grammar.js +161 -0
- package/dist/jse/highlight-grammar.js.map +1 -0
- package/dist/jse/highlight-grammars.generated.d.ts +2 -0
- package/dist/jse/highlight-grammars.generated.d.ts.map +1 -0
- package/dist/jse/highlight-grammars.generated.js +4 -0
- package/dist/jse/highlight-grammars.generated.js.map +1 -0
- package/dist/jse/highlight.d.ts +37 -0
- package/dist/jse/highlight.d.ts.map +1 -0
- package/dist/jse/highlight.js +323 -0
- package/dist/jse/highlight.js.map +1 -0
- package/dist/jse/jse.d.ts +674 -0
- package/dist/jse/jse.d.ts.map +1 -0
- package/dist/jse/jse.js +5841 -0
- package/dist/jse/jse.js.map +1 -0
- package/dist/jse/pathmatch.d.ts +10 -0
- package/dist/jse/pathmatch.d.ts.map +1 -0
- package/dist/jse/pathmatch.js +73 -0
- package/dist/jse/pathmatch.js.map +1 -0
- package/dist/jse/regex.d.ts +33 -0
- package/dist/jse/regex.d.ts.map +1 -0
- package/dist/jse/regex.js +375 -0
- package/dist/jse/regex.js.map +1 -0
- package/dist/jse/stdlib.d.ts +8 -0
- package/dist/jse/stdlib.d.ts.map +1 -0
- package/dist/jse/stdlib.js +765 -0
- package/dist/jse/stdlib.js.map +1 -0
- package/dist/jse/tokens.d.ts +102 -0
- package/dist/jse/tokens.d.ts.map +1 -0
- package/dist/jse/tokens.js +982 -0
- package/dist/jse/tokens.js.map +1 -0
- package/dist/jse/values.d.ts +206 -0
- package/dist/jse/values.d.ts.map +1 -0
- package/dist/jse/values.js +846 -0
- package/dist/jse/values.js.map +1 -0
- package/dist/keyboard.d.ts +196 -0
- package/dist/keyboard.d.ts.map +1 -0
- package/dist/keyboard.js +186 -0
- package/dist/keyboard.js.map +1 -0
- package/dist/label-choices.d.ts +3 -0
- package/dist/label-choices.d.ts.map +1 -0
- package/dist/label-choices.js +168 -0
- package/dist/label-choices.js.map +1 -0
- package/dist/language.d.ts +33 -0
- package/dist/language.d.ts.map +1 -0
- package/dist/language.js +50 -0
- package/dist/language.js.map +1 -0
- package/dist/length-units.d.ts +30 -0
- package/dist/length-units.d.ts.map +1 -0
- package/dist/length-units.js +83 -0
- package/dist/length-units.js.map +1 -0
- package/dist/lightsensor.d.ts +48 -0
- package/dist/lightsensor.d.ts.map +1 -0
- package/dist/lightsensor.js +97 -0
- package/dist/lightsensor.js.map +1 -0
- package/dist/link-refresh.d.ts +27 -0
- package/dist/link-refresh.d.ts.map +1 -0
- package/dist/link-refresh.js +166 -0
- package/dist/link-refresh.js.map +1 -0
- package/dist/link.d.ts +57 -0
- package/dist/link.d.ts.map +1 -0
- package/dist/link.js +333 -0
- package/dist/link.js.map +1 -0
- package/dist/linkpreview.d.ts +114 -0
- package/dist/linkpreview.d.ts.map +1 -0
- package/dist/linkpreview.js +439 -0
- package/dist/linkpreview.js.map +1 -0
- package/dist/list-presence.d.ts +32 -0
- package/dist/list-presence.d.ts.map +1 -0
- package/dist/list-presence.js +48 -0
- package/dist/list-presence.js.map +1 -0
- package/dist/live-stream.d.ts +27 -0
- package/dist/live-stream.d.ts.map +1 -0
- package/dist/live-stream.js +274 -0
- package/dist/live-stream.js.map +1 -0
- package/dist/livelogs.d.ts +134 -0
- package/dist/livelogs.d.ts.map +1 -0
- package/dist/livelogs.js +409 -0
- package/dist/livelogs.js.map +1 -0
- package/dist/logs.d.ts +80 -0
- package/dist/logs.d.ts.map +1 -0
- package/dist/logs.js +206 -0
- package/dist/logs.js.map +1 -0
- package/dist/mcp/apps.d.ts +82 -0
- package/dist/mcp/apps.d.ts.map +1 -0
- package/dist/mcp/apps.js +219 -0
- package/dist/mcp/apps.js.map +1 -0
- package/dist/mcp/entities.d.ts +25 -0
- package/dist/mcp/entities.d.ts.map +1 -0
- package/dist/mcp/entities.js +71 -0
- package/dist/mcp/entities.js.map +1 -0
- package/dist/mcp/result.d.ts +73 -0
- package/dist/mcp/result.d.ts.map +1 -0
- package/dist/mcp/result.js +119 -0
- package/dist/mcp/result.js.map +1 -0
- package/dist/mcp/webmcp.d.ts +162 -0
- package/dist/mcp/webmcp.d.ts.map +1 -0
- package/dist/mcp/webmcp.js +214 -0
- package/dist/mcp/webmcp.js.map +1 -0
- package/dist/mcp.d.ts +5 -0
- package/dist/mcp.d.ts.map +1 -0
- package/dist/mcp.js +14 -0
- package/dist/mcp.js.map +1 -0
- package/dist/media-core.d.ts +191 -0
- package/dist/media-core.d.ts.map +1 -0
- package/dist/media-core.js +446 -0
- package/dist/media-core.js.map +1 -0
- package/dist/media-timeline-core.d.ts +94 -0
- package/dist/media-timeline-core.d.ts.map +1 -0
- package/dist/media-timeline-core.js +620 -0
- package/dist/media-timeline-core.js.map +1 -0
- package/dist/message.d.ts +42 -0
- package/dist/message.d.ts.map +1 -0
- package/dist/message.js +582 -0
- package/dist/message.js.map +1 -0
- package/dist/missing-element.d.ts +29 -0
- package/dist/missing-element.d.ts.map +1 -0
- package/dist/missing-element.js +76 -0
- package/dist/missing-element.js.map +1 -0
- package/dist/motion-core.d.ts +160 -0
- package/dist/motion-core.d.ts.map +1 -0
- package/dist/motion-core.js +752 -0
- package/dist/motion-core.js.map +1 -0
- package/dist/motion-pose.d.ts +65 -0
- package/dist/motion-pose.d.ts.map +1 -0
- package/dist/motion-pose.js +143 -0
- package/dist/motion-pose.js.map +1 -0
- package/dist/motion.d.ts +132 -0
- package/dist/motion.d.ts.map +1 -0
- package/dist/motion.js +260 -0
- package/dist/motion.js.map +1 -0
- package/dist/mount-core.d.ts +203 -0
- package/dist/mount-core.d.ts.map +1 -0
- package/dist/mount-core.js +437 -0
- package/dist/mount-core.js.map +1 -0
- package/dist/net-core.d.ts +110 -0
- package/dist/net-core.d.ts.map +1 -0
- package/dist/net-core.js +225 -0
- package/dist/net-core.js.map +1 -0
- package/dist/notify.d.ts +399 -0
- package/dist/notify.d.ts.map +1 -0
- package/dist/notify.js +964 -0
- package/dist/notify.js.map +1 -0
- package/dist/orientation-binding.d.ts +39 -0
- package/dist/orientation-binding.d.ts.map +1 -0
- package/dist/orientation-binding.js +64 -0
- package/dist/orientation-binding.js.map +1 -0
- package/dist/orientation.d.ts +55 -0
- package/dist/orientation.d.ts.map +1 -0
- package/dist/orientation.js +89 -0
- package/dist/orientation.js.map +1 -0
- package/dist/ota.d.ts +52 -0
- package/dist/ota.d.ts.map +1 -0
- package/dist/ota.js +122 -0
- package/dist/ota.js.map +1 -0
- package/dist/passkeys.d.ts +91 -0
- package/dist/passkeys.d.ts.map +1 -0
- package/dist/passkeys.js +307 -0
- package/dist/passkeys.js.map +1 -0
- package/dist/payment.d.ts +85 -0
- package/dist/payment.d.ts.map +1 -0
- package/dist/payment.js +270 -0
- package/dist/payment.js.map +1 -0
- package/dist/pending-presenter.d.ts +31 -0
- package/dist/pending-presenter.d.ts.map +1 -0
- package/dist/pending-presenter.js +119 -0
- package/dist/pending-presenter.js.map +1 -0
- package/dist/permission-core.d.ts +59 -0
- package/dist/permission-core.d.ts.map +1 -0
- package/dist/permission-core.js +102 -0
- package/dist/permission-core.js.map +1 -0
- package/dist/persist.d.ts +169 -0
- package/dist/persist.d.ts.map +1 -0
- package/dist/persist.js +361 -0
- package/dist/persist.js.map +1 -0
- package/dist/phase-plan.d.ts +114 -0
- package/dist/phase-plan.d.ts.map +1 -0
- package/dist/phase-plan.js +837 -0
- package/dist/phase-plan.js.map +1 -0
- package/dist/playback-core.d.ts +64 -0
- package/dist/playback-core.d.ts.map +1 -0
- package/dist/playback-core.js +176 -0
- package/dist/playback-core.js.map +1 -0
- package/dist/player-sources.d.ts +12 -0
- package/dist/player-sources.d.ts.map +1 -0
- package/dist/player-sources.js +44 -0
- package/dist/player-sources.js.map +1 -0
- package/dist/proxy-denylist.d.ts +11 -0
- package/dist/proxy-denylist.d.ts.map +1 -0
- package/dist/proxy-denylist.js +44 -0
- package/dist/proxy-denylist.js.map +1 -0
- package/dist/public-config.d.ts +20 -0
- package/dist/public-config.d.ts.map +1 -0
- package/dist/public-config.js +109 -0
- package/dist/public-config.js.map +1 -0
- package/dist/qoe-core.d.ts +72 -0
- package/dist/qoe-core.d.ts.map +1 -0
- package/dist/qoe-core.js +113 -0
- package/dist/qoe-core.js.map +1 -0
- package/dist/reactive-request.d.ts +80 -0
- package/dist/reactive-request.d.ts.map +1 -0
- package/dist/reactive-request.js +192 -0
- package/dist/reactive-request.js.map +1 -0
- package/dist/read-cache.d.ts +129 -0
- package/dist/read-cache.d.ts.map +1 -0
- package/dist/read-cache.js +566 -0
- package/dist/read-cache.js.map +1 -0
- package/dist/recorder-core.d.ts +57 -0
- package/dist/recorder-core.d.ts.map +1 -0
- package/dist/recorder-core.js +136 -0
- package/dist/recorder-core.js.map +1 -0
- package/dist/ref.d.ts +41 -0
- package/dist/ref.d.ts.map +1 -0
- package/dist/ref.js +98 -0
- package/dist/ref.js.map +1 -0
- package/dist/refusal.d.ts +82 -0
- package/dist/refusal.d.ts.map +1 -0
- package/dist/refusal.js +218 -0
- package/dist/refusal.js.map +1 -0
- package/dist/region-insets.d.ts +61 -0
- package/dist/region-insets.d.ts.map +1 -0
- package/dist/region-insets.js +67 -0
- package/dist/region-insets.js.map +1 -0
- package/dist/rive-core.d.ts +323 -0
- package/dist/rive-core.d.ts.map +1 -0
- package/dist/rive-core.js +677 -0
- package/dist/rive-core.js.map +1 -0
- package/dist/runner.d.ts +595 -0
- package/dist/runner.d.ts.map +1 -0
- package/dist/runner.js +4094 -0
- package/dist/runner.js.map +1 -0
- package/dist/scene/a11y.d.ts +11 -0
- package/dist/scene/a11y.d.ts.map +1 -0
- package/dist/scene/a11y.js +67 -0
- package/dist/scene/a11y.js.map +1 -0
- package/dist/scene/anim.d.ts +149 -0
- package/dist/scene/anim.d.ts.map +1 -0
- package/dist/scene/anim.js +396 -0
- package/dist/scene/anim.js.map +1 -0
- package/dist/scene/bind.d.ts +33 -0
- package/dist/scene/bind.d.ts.map +1 -0
- package/dist/scene/bind.js +66 -0
- package/dist/scene/bind.js.map +1 -0
- package/dist/scene/collide.d.ts +56 -0
- package/dist/scene/collide.d.ts.map +1 -0
- package/dist/scene/collide.js +146 -0
- package/dist/scene/collide.js.map +1 -0
- package/dist/scene/frame.d.ts +22 -0
- package/dist/scene/frame.d.ts.map +1 -0
- package/dist/scene/frame.js +57 -0
- package/dist/scene/frame.js.map +1 -0
- package/dist/scene/gltf.d.ts +79 -0
- package/dist/scene/gltf.d.ts.map +1 -0
- package/dist/scene/gltf.js +409 -0
- package/dist/scene/gltf.js.map +1 -0
- package/dist/scene/ir.d.ts +293 -0
- package/dist/scene/ir.d.ts.map +1 -0
- package/dist/scene/ir.js +692 -0
- package/dist/scene/ir.js.map +1 -0
- package/dist/scene/math.d.ts +50 -0
- package/dist/scene/math.d.ts.map +1 -0
- package/dist/scene/math.js +180 -0
- package/dist/scene/math.js.map +1 -0
- package/dist/scene/orbit.d.ts +19 -0
- package/dist/scene/orbit.d.ts.map +1 -0
- package/dist/scene/orbit.js +60 -0
- package/dist/scene/orbit.js.map +1 -0
- package/dist/scene/physics.d.ts +228 -0
- package/dist/scene/physics.d.ts.map +1 -0
- package/dist/scene/physics.js +1500 -0
- package/dist/scene/physics.js.map +1 -0
- package/dist/scene/registry.d.ts +85 -0
- package/dist/scene/registry.d.ts.map +1 -0
- package/dist/scene/registry.js +75 -0
- package/dist/scene/registry.js.map +1 -0
- package/dist/scene/skin.d.ts +82 -0
- package/dist/scene/skin.d.ts.map +1 -0
- package/dist/scene/skin.js +351 -0
- package/dist/scene/skin.js.map +1 -0
- package/dist/scene/sprite.d.ts +36 -0
- package/dist/scene/sprite.d.ts.map +1 -0
- package/dist/scene/sprite.js +107 -0
- package/dist/scene/sprite.js.map +1 -0
- package/dist/scene/viewer.d.ts +96 -0
- package/dist/scene/viewer.d.ts.map +1 -0
- package/dist/scene/viewer.js +235 -0
- package/dist/scene/viewer.js.map +1 -0
- package/dist/scoped-slots.d.ts +9 -0
- package/dist/scoped-slots.d.ts.map +1 -0
- package/dist/scoped-slots.js +42 -0
- package/dist/scoped-slots.js.map +1 -0
- package/dist/screen.d.ts +109 -0
- package/dist/screen.d.ts.map +1 -0
- package/dist/screen.js +309 -0
- package/dist/screen.js.map +1 -0
- package/dist/scroll.d.ts +525 -0
- package/dist/scroll.d.ts.map +1 -0
- package/dist/scroll.js +1226 -0
- package/dist/scroll.js.map +1 -0
- package/dist/settings-plane.d.ts +58 -0
- package/dist/settings-plane.d.ts.map +1 -0
- package/dist/settings-plane.js +86 -0
- package/dist/settings-plane.js.map +1 -0
- package/dist/share-inbox.d.ts +56 -0
- package/dist/share-inbox.d.ts.map +1 -0
- package/dist/share-inbox.js +114 -0
- package/dist/share-inbox.js.map +1 -0
- package/dist/shared-transition.d.ts +152 -0
- package/dist/shared-transition.d.ts.map +1 -0
- package/dist/shared-transition.js +257 -0
- package/dist/shared-transition.js.map +1 -0
- package/dist/sheet-content-padding.d.ts +24 -0
- package/dist/sheet-content-padding.d.ts.map +1 -0
- package/dist/sheet-content-padding.js +32 -0
- package/dist/sheet-content-padding.js.map +1 -0
- package/dist/shot-devices.d.ts +36 -0
- package/dist/shot-devices.d.ts.map +1 -0
- package/dist/shot-devices.js +90 -0
- package/dist/shot-devices.js.map +1 -0
- package/dist/shot-guards.d.ts +100 -0
- package/dist/shot-guards.d.ts.map +1 -0
- package/dist/shot-guards.js +260 -0
- package/dist/shot-guards.js.map +1 -0
- package/dist/shot-scope.d.ts +140 -0
- package/dist/shot-scope.d.ts.map +1 -0
- package/dist/shot-scope.js +302 -0
- package/dist/shot-scope.js.map +1 -0
- package/dist/slot-partition.d.ts +9 -0
- package/dist/slot-partition.d.ts.map +1 -0
- package/dist/slot-partition.js +38 -0
- package/dist/slot-partition.js.map +1 -0
- package/dist/snackbar.d.ts +165 -0
- package/dist/snackbar.d.ts.map +1 -0
- package/dist/snackbar.js +220 -0
- package/dist/snackbar.js.map +1 -0
- package/dist/socket.d.ts +96 -0
- package/dist/socket.d.ts.map +1 -0
- package/dist/socket.js +370 -0
- package/dist/socket.js.map +1 -0
- package/dist/spotlight.d.ts +77 -0
- package/dist/spotlight.d.ts.map +1 -0
- package/dist/spotlight.js +174 -0
- package/dist/spotlight.js.map +1 -0
- package/dist/state-primitive.d.ts +37 -0
- package/dist/state-primitive.d.ts.map +1 -0
- package/dist/state-primitive.js +91 -0
- package/dist/state-primitive.js.map +1 -0
- package/dist/store-query.d.ts +25 -0
- package/dist/store-query.d.ts.map +1 -0
- package/dist/store-query.js +88 -0
- package/dist/store-query.js.map +1 -0
- package/dist/store-value.d.ts +48 -0
- package/dist/store-value.d.ts.map +1 -0
- package/dist/store-value.js +264 -0
- package/dist/store-value.js.map +1 -0
- package/dist/store-versioning.d.ts +70 -0
- package/dist/store-versioning.d.ts.map +1 -0
- package/dist/store-versioning.js +188 -0
- package/dist/store-versioning.js.map +1 -0
- package/dist/store.d.ts +282 -0
- package/dist/store.d.ts.map +1 -0
- package/dist/store.js +1144 -0
- package/dist/store.js.map +1 -0
- package/dist/strings.d.ts +141 -0
- package/dist/strings.d.ts.map +1 -0
- package/dist/strings.js +581 -0
- package/dist/strings.js.map +1 -0
- package/dist/telemetry.d.ts +95 -0
- package/dist/telemetry.d.ts.map +1 -0
- package/dist/telemetry.js +255 -0
- package/dist/telemetry.js.map +1 -0
- package/dist/transform-core.d.ts +228 -0
- package/dist/transform-core.d.ts.map +1 -0
- package/dist/transform-core.js +921 -0
- package/dist/transform-core.js.map +1 -0
- package/dist/transition-core.d.ts +58 -0
- package/dist/transition-core.d.ts.map +1 -0
- package/dist/transition-core.js +352 -0
- package/dist/transition-core.js.map +1 -0
- package/dist/trim-trailing.d.ts +3 -0
- package/dist/trim-trailing.d.ts.map +1 -0
- package/dist/trim-trailing.js +14 -0
- package/dist/trim-trailing.js.map +1 -0
- package/dist/upload.d.ts +51 -0
- package/dist/upload.d.ts.map +1 -0
- package/dist/upload.js +68 -0
- package/dist/upload.js.map +1 -0
- package/dist/vendor-face.d.ts +44 -0
- package/dist/vendor-face.d.ts.map +1 -0
- package/dist/vendor-face.js +80 -0
- package/dist/vendor-face.js.map +1 -0
- package/dist/vendor-session.d.ts +166 -0
- package/dist/vendor-session.d.ts.map +1 -0
- package/dist/vendor-session.js +423 -0
- package/dist/vendor-session.js.map +1 -0
- package/dist/vendor-surface.d.ts +290 -0
- package/dist/vendor-surface.d.ts.map +1 -0
- package/dist/vendor-surface.js +439 -0
- package/dist/vendor-surface.js.map +1 -0
- package/dist/version-rules.generated.d.ts +17 -0
- package/dist/version-rules.generated.d.ts.map +1 -0
- package/dist/version-rules.generated.js +99 -0
- package/dist/version-rules.generated.js.map +1 -0
- package/dist/view-transition-core.d.ts +99 -0
- package/dist/view-transition-core.d.ts.map +1 -0
- package/dist/view-transition-core.js +127 -0
- package/dist/view-transition-core.js.map +1 -0
- package/dist/view-transition-door.d.ts +26 -0
- package/dist/view-transition-door.d.ts.map +1 -0
- package/dist/view-transition-door.js +88 -0
- package/dist/view-transition-door.js.map +1 -0
- package/dist/window-identity.d.ts +3 -0
- package/dist/window-identity.d.ts.map +1 -0
- package/dist/window-identity.js +27 -0
- package/dist/window-identity.js.map +1 -0
- package/package.json +139 -4
|
@@ -0,0 +1,674 @@
|
|
|
1
|
+
import { NSNull, isNSNull, isDict, isLambda, number, string, truthy, jseEquals, compare, arith, typeofString, asArray, asRows, index as indexOp, member as memberOp, watchKey, type Dict, type StackLambda, type LambdaParam, type StackFormula } from "./values.ts";
|
|
2
|
+
import { type Token } from "./tokens.ts";
|
|
3
|
+
/** ONE RESOLVED CONTEXT READ (PROPOSED, proposals/context.md). The consumer's
|
|
4
|
+
* `<context from="session" use="user"/>` becomes one entry per used name, keyed by the
|
|
5
|
+
* spelling that follows `dsx.context.` - `"user"` for the flat form, `"board.picked"` when
|
|
6
|
+
* the row carries `as="board"` - and pointing at the PROVIDER's evaluator store plus the
|
|
7
|
+
* name the declaration has THERE. The renderer resolves WHO the provider is by walking the
|
|
8
|
+
* mount chain and fills this map in the head fold; the evaluator only reads it, which is
|
|
9
|
+
* what keeps the walk out of the hot path (once per consumer instance, never per read). */
|
|
10
|
+
export type StackContextBinding = {
|
|
11
|
+
store: StackStore;
|
|
12
|
+
name: string;
|
|
13
|
+
/** THE PROVIDER FRAME, when the renderer minted one. A consumer holds the FRAME and not
|
|
14
|
+
* the provider's store, so a provider that unmounts under a consumer the mount chain does
|
|
15
|
+
* not own - which a slot can do - leaves an INVALIDATED frame rather than a frozen
|
|
16
|
+
* snapshot of its last value. Absent on a binding stamped without a mount (a kernel test,
|
|
17
|
+
* a host that owns the lifetime itself), and then `store` IS the frame and never dies. */
|
|
18
|
+
frame?: StackContextFrame;
|
|
19
|
+
/** The two halves of the invalidated-read sentence and its once-only ledger, minted per
|
|
20
|
+
* consumer `<context>` row by the renderer. Absent = the line is not this lane's to print. */
|
|
21
|
+
absence?: StackContextAbsence;
|
|
22
|
+
};
|
|
23
|
+
/** ONE PROVIDER INSTANCE, as every consumer of it sees it (proposals/context.md, the lifetime
|
|
24
|
+
* rules: "a consumer holds its provider frame weakly, on the shape of RouteVarsInheritors;
|
|
25
|
+
* provider disposal invalidates the frame; a read through an invalidated frame returns the
|
|
26
|
+
* typed absence and logs once"). `store` is NULLED by the provider's disposer, which is this
|
|
27
|
+
* lane's spelling of Swift's weak `storeRef` and Kotlin's sidecar: a garbage-collected
|
|
28
|
+
* reference cannot be observed synchronously in a test or a binding, and what the law needs is
|
|
29
|
+
* not collection but INVALIDATION at a known instant — the provider's unmount. */
|
|
30
|
+
export type StackContextFrame = {
|
|
31
|
+
/** The provider's evaluator store, or null once the provider unmounted. */
|
|
32
|
+
store: StackStore | null;
|
|
33
|
+
/** The provider's component name, for the sentence and for nothing else. */
|
|
34
|
+
component: string;
|
|
35
|
+
};
|
|
36
|
+
/** The once-only ledger for an invalidated read, one per consumer `<context>` row: a consumer
|
|
37
|
+
* inside a list would otherwise print one line per row per read. */
|
|
38
|
+
export type StackContextAbsence = {
|
|
39
|
+
consumer: string;
|
|
40
|
+
key: string;
|
|
41
|
+
logged: boolean;
|
|
42
|
+
};
|
|
43
|
+
/** The evaluator-visible subset of the surface's reactive store. The reactive/UI
|
|
44
|
+
* members (signals, handlers, watches) live in store.ts; JSE reads exactly these. */
|
|
45
|
+
export declare const JSEPresentation: {
|
|
46
|
+
active: boolean;
|
|
47
|
+
};
|
|
48
|
+
export declare function presentationRead<T>(work: () => T): T;
|
|
49
|
+
export declare class StackStore {
|
|
50
|
+
readonly actionEntries: Map<string, number>;
|
|
51
|
+
readonly apiNames: Set<string>;
|
|
52
|
+
presentedRead: ((key: string, value: unknown) => unknown) | null;
|
|
53
|
+
vars: Map<string, unknown>;
|
|
54
|
+
computed: Map<string, string>;
|
|
55
|
+
computedDepth: number;
|
|
56
|
+
initials: Map<string, unknown>;
|
|
57
|
+
formulas: Map<string, StackFormula>;
|
|
58
|
+
functions: Map<string, unknown>;
|
|
59
|
+
fnDepth: number;
|
|
60
|
+
evalDepth: number;
|
|
61
|
+
attrDefaults: Map<string, string>;
|
|
62
|
+
attrNumbers: Set<string>;
|
|
63
|
+
budget: JSEBudget;
|
|
64
|
+
/** signal read hook — store.ts wires this so `lookup` reads track dependencies. */
|
|
65
|
+
onVarRead: ((name: string) => void) | null;
|
|
66
|
+
/** the HOST BINDING of the evaluation in flight (see JSEHostBinding). Null outside a
|
|
67
|
+
* bound evaluation, which is every ordinary surface: the seam costs a null check. */
|
|
68
|
+
host: JSEHostBinding | null;
|
|
69
|
+
/** THE ACTION BODY A LAMBDA IS CALLED FROM (reference/jse.md).
|
|
70
|
+
* Set by the runner for the length of one action-body evaluation; every pure door (eval,
|
|
71
|
+
* evalBlock, the compiled doors) clears it for its own length, so a lambda called from a
|
|
72
|
+
* formula, a binding or any other pure context never sees it. */
|
|
73
|
+
actionLambda?: ActionLambdaCtx | null;
|
|
74
|
+
/** `dsx.context.<name>` → the provider declaration it resolved to, or NULL on the
|
|
75
|
+
* overwhelming majority of surfaces, which declare no context at all and pay one null
|
|
76
|
+
* field for the plane (see StackContextBinding). */
|
|
77
|
+
contexts: Map<string, StackContextBinding> | null;
|
|
78
|
+
/** `dsx.ref.<name>` → this instance's element handle for `ref="name"`, or null (ADR 0025 D3). Installed by a
|
|
79
|
+
* renderer that mints handles (dom/src/element.ts) on the stores of documents that read one; null on every
|
|
80
|
+
* other store, which pays one null field for the plane. */
|
|
81
|
+
refs: ((name: string) => unknown) | null;
|
|
82
|
+
}
|
|
83
|
+
/** The answer that means "the host owns no such name", distinct from null, which is a
|
|
84
|
+
* value a host may own. A frozen singleton so an identity check is the whole test. */
|
|
85
|
+
/** THE SCOPED SLOT SCOPE KEY (PROPOSED, proposals/component-slot-composition.md Part B, ADR 0020): the
|
|
86
|
+
* renderer hangs `binding -> field -> live read` on slotted content's scope object under this symbol,
|
|
87
|
+
* so no enumeration, spread or `dsx.this` read can see it. */
|
|
88
|
+
export declare const SLOT_SCOPE: unique symbol;
|
|
89
|
+
export type SlotScope = Map<string, Map<string, () => unknown>>;
|
|
90
|
+
/** A handler or action scope is a SPREAD of its row and payload, and a spread drops a symbol key's
|
|
91
|
+
* non-enumerable property, so the scoped slot bindings are carried across explicitly (the later
|
|
92
|
+
* scope wins, as its spread does). */
|
|
93
|
+
export declare function carrySlotScope(to: Dict, ...from: Item[]): void;
|
|
94
|
+
export declare const JSE_HOST_MISS: unique symbol;
|
|
95
|
+
/** The host's side of one evaluation. Implemented by the embedder, never by the kernel. */
|
|
96
|
+
export interface JSEHostBinding {
|
|
97
|
+
/** The value at `path` (a dotted path, then its bare root). JSE_HOST_MISS = not mine. */
|
|
98
|
+
read(path: string): unknown;
|
|
99
|
+
/** Write `value` at root `name` walked by `parts` (already evaluated to keys).
|
|
100
|
+
* True when the host took the write; false leaves the statement to the evaluator. */
|
|
101
|
+
write(name: string, parts: readonly unknown[], value: unknown): boolean;
|
|
102
|
+
}
|
|
103
|
+
/** Bind `host` for the evaluation about to run; answers the binding to restore. Callers
|
|
104
|
+
* go through JSE.eval / JSE.evalBlock's optional argument instead of calling this. */
|
|
105
|
+
export declare function bindHost(store: StackStore, host: JSEHostBinding | null): JSEHostBinding | null;
|
|
106
|
+
/** The step budget of ONE top level evaluation: loop iterations plus user function calls.
|
|
107
|
+
* Same number as the loop law it replaces (corpus core-004), now counted across calls. */
|
|
108
|
+
export declare const JSE_STEP_BUDGET = 10000;
|
|
109
|
+
/** The wall clock ceiling of ONE top level evaluation, in milliseconds. A step that costs
|
|
110
|
+
* no step count (a huge string join, a pathological regex) still cannot run past this. */
|
|
111
|
+
export declare const JSE_WALL_CLOCK_MS = 2000;
|
|
112
|
+
/** The ONE typed refusal shape, identical on web, Kotlin and Swift. It is the `budget` class of
|
|
113
|
+
* the refusal vocabulary (OpenSource/Conformance/refusal/refusal.json), which is why the code
|
|
114
|
+
* is read from there rather than spelled again here: a budget exhaustion used to be the one
|
|
115
|
+
* failure class that produced no envelope at all on any lane, only a console line whose own
|
|
116
|
+
* wording differed between the three (web and Kotlin said "the expression returns null", Swift
|
|
117
|
+
* said "returns nil"). */
|
|
118
|
+
export declare const JSE_BUDGET_REFUSED = "jse_budget_exhausted";
|
|
119
|
+
/** The ledger of one evaluation. Lives on the store so a call cannot escape it. */
|
|
120
|
+
export declare class JSEBudget {
|
|
121
|
+
depth: number;
|
|
122
|
+
used: number;
|
|
123
|
+
deadline: number;
|
|
124
|
+
instant: number;
|
|
125
|
+
subject: string;
|
|
126
|
+
refusal: string | null;
|
|
127
|
+
refusalJSON: string | null;
|
|
128
|
+
}
|
|
129
|
+
/** Open an evaluation door. True when THIS frame owns the ledger (the outermost door). */
|
|
130
|
+
export declare function beginEvaluation(store: StackStore): boolean;
|
|
131
|
+
/** Close an evaluation door. Answers the refusal of the evaluation, null when it was total. */
|
|
132
|
+
export declare function endEvaluation(store: StackStore, owned: boolean): string | null;
|
|
133
|
+
/** File an await-position refusal on THIS evaluation's ledger. Same contract as the member
|
|
134
|
+
* denial: the FIRST refusal of an evaluation wins, and `endEvaluation` makes the whole
|
|
135
|
+
* evaluation answer null rather than the plausible partial value it used to answer. */
|
|
136
|
+
export declare function reportAwaitPosition(store: StackStore, word: string): void;
|
|
137
|
+
/** One declaration a store judges its writes against, as the head wrote it. `subject` is how
|
|
138
|
+
* the line names it (`dsx.variable.<as>`). `judge` is compiled on the first write that reaches
|
|
139
|
+
* it and kept; null once it is known unreadable. */
|
|
140
|
+
export type DeclaredShapeRow = {
|
|
141
|
+
subject: string;
|
|
142
|
+
type: string;
|
|
143
|
+
moves: string | undefined;
|
|
144
|
+
judge?: ((value: unknown, previous: unknown) => string | null) | null;
|
|
145
|
+
};
|
|
146
|
+
export declare function judgeDeclaredShape(row: DeclaredShapeRow, value: unknown, previous: unknown): void;
|
|
147
|
+
/** Reset the once-per-subject ledger. A test seam, and the dev server's own reload hook: a
|
|
148
|
+
* reload is a new document and the reader has to be told again. */
|
|
149
|
+
export declare function resetBudgetReports(): void;
|
|
150
|
+
/** Spend one evaluation step. False means the evaluation is refused: every loop stops and
|
|
151
|
+
* every call answers null from here on, so the unwind is bounded by fnDepth alone. */
|
|
152
|
+
export declare function evaluationStep(store: StackStore): boolean;
|
|
153
|
+
/** THE SIZE CEILING (nested-data stress S6). A builder asked for more than this many elements
|
|
154
|
+
* (`Array.from({ length })`, `range`, `repeat`, `padStart`/`padEnd`) used to answer a SHORTER
|
|
155
|
+
* value, clamped to the ceiling with no word, so an author who built 20,000 rows silently got
|
|
156
|
+
* 10,000. Over the ceiling the evaluation is refused now, with the budget envelope naming the
|
|
157
|
+
* `elements` limit: loud, never a plausible wrong answer. The ceiling is the step budget's
|
|
158
|
+
* number, so building N elements never costs more than walking them. Twins: Jse.kt and JSE.swift
|
|
159
|
+
* `withinSizeCeiling`; corpus jse/budget-001.json. */
|
|
160
|
+
export declare const JSE_SIZE_CEILING = 10000;
|
|
161
|
+
export declare function withinSizeCeiling(store: StackStore | undefined, requested: number): boolean;
|
|
162
|
+
export type Item = Dict | null;
|
|
163
|
+
/** the availability answer's field words (availability.md v2 + v2.1): a read path ends its member
|
|
164
|
+
* address at the first of these */
|
|
165
|
+
export declare const AVAILABILITY_FIELDS: ReadonlySet<string>;
|
|
166
|
+
/** The compiled executor's answer for a source it does not run (beyond the subset, or a compile failure): the
|
|
167
|
+
* interpreter takes that source instead. */
|
|
168
|
+
export declare const JSE_NOT_COMPILED: unique symbol;
|
|
169
|
+
export declare const JSESeams: {
|
|
170
|
+
/** THE COMPILED EXECUTOR AS THE RUNTIME PATH. When bound (installCompiledEval in compile/codegen.ts), every
|
|
171
|
+
* `JSE.eval` / `JSE.evalBlock` runs the source's cached closure instead of parsing it again on each call; a source the
|
|
172
|
+
* compiler does not take answers JSE_NOT_COMPILED and runs through the interpreter. Both executors share the evaluation
|
|
173
|
+
* door (budget ledger, host binding, recursion cap), which stays here, and the conformance corpus gates both. */
|
|
174
|
+
compiledEval: ((expr: string, store: StackStore, item: Item) => unknown) | null;
|
|
175
|
+
compiledBlock: ((body: string, store: StackStore, item: Item) => unknown) | null;
|
|
176
|
+
/** DSX.state.vars — the app-wide reactive store (`global.*` / `route.*` / `env`). */
|
|
177
|
+
stateVars: () => Dict;
|
|
178
|
+
/** the live cookie jar (`cookie.*`). */
|
|
179
|
+
cookieJar: () => Dict;
|
|
180
|
+
/** An authored `dsx.cookie.*` read happened (the server's private-render floor listens). */
|
|
181
|
+
onCookieRead: (() => void) | null;
|
|
182
|
+
/** environment channel — detection fails CLOSED to "appstore". */
|
|
183
|
+
appEnvironment: () => string;
|
|
184
|
+
/** `dsx.config.<chain>.<key>` (public-config.ts): the segments after `config`. The bus binds it to the
|
|
185
|
+
* public config table; unbound, every read is null. */
|
|
186
|
+
configRead: (_path: readonly string[]) => unknown;
|
|
187
|
+
/** ModuleRegistry availability — the `has(scheme)` capability check. */
|
|
188
|
+
moduleAvailable: (_scheme: string, _args?: Dict) => boolean;
|
|
189
|
+
/** The `dsx.module.<chain>.availability[.<member>]` plane (proposals/availability.md): the
|
|
190
|
+
* verdict of one member (null = the module as a whole). Fail-open: available. */
|
|
191
|
+
moduleAvailability: (_chain: string, _member: string | null, _args?: Dict) => {
|
|
192
|
+
available: boolean;
|
|
193
|
+
reason: string | null;
|
|
194
|
+
via: {
|
|
195
|
+
member: string;
|
|
196
|
+
reason: string | null;
|
|
197
|
+
}[];
|
|
198
|
+
} & Record<string, unknown>;
|
|
199
|
+
/** DSXStrings.localize: the `localize(s)` builtin. A SEAM rather than an import, because
|
|
200
|
+
* strings.ts already imports from jse/values.ts and the direct edge would close the
|
|
201
|
+
* module cycle. Identity by default, which is also the fail-open floor. */
|
|
202
|
+
localize: (s: string) => string;
|
|
203
|
+
/** THE REMOTE TABLE TIER (localization-and-caching.md L11): an `<api strings=…>` reaches the
|
|
204
|
+
* string tables through these, and strings.ts binds them, so the api layer never imports the
|
|
205
|
+
* localization plane and an embed that spells no `strings=` ships none of it. */
|
|
206
|
+
remoteTableInstall: (_tag: string, _data: unknown) => void;
|
|
207
|
+
remoteTableFailed: (_tag: string) => void;
|
|
208
|
+
remoteTableBlocks: (_delta: number) => void;
|
|
209
|
+
/** `dsx.cache.invalidate(resource)` (C4): the api layer binds it; nothing to invalidate by default. */
|
|
210
|
+
cacheInvalidate: (_resource: unknown) => void;
|
|
211
|
+
/** `localize(s, locale)`, the named-locale form (L10). Identity by default, like `localize`. */
|
|
212
|
+
localizeIn: (s: string, _locale: unknown) => string;
|
|
213
|
+
/** next-tick hop for reactive author logic (the render-safe invariant). */
|
|
214
|
+
afterRenderDispatch: (work: () => void) => void;
|
|
215
|
+
/** `os` / `platform` resolve to "web" on this renderer BY DESIGN — the same markup
|
|
216
|
+
* reads "ios" / "android" / "macos" / "windows" / "linux" on the native kernels
|
|
217
|
+
* (/web/14; desktop-platforms.md). */
|
|
218
|
+
platformOS: string;
|
|
219
|
+
/** The native host a web document runs inside ("ios" | "android"), from the host's own identity
|
|
220
|
+
* global and never the user agent; null in a browser. `dsx.platform.os` reports it (hostedOS). */
|
|
221
|
+
platformHost: string | null;
|
|
222
|
+
/** third-party web-component embed vs in-app surface (/web/14). */
|
|
223
|
+
platformEmbed: boolean;
|
|
224
|
+
/** dependency tracking for `global.*` / `route.*` / `env` reads (store.ts wires it). */
|
|
225
|
+
onGlobalRead: ((key: string) => void) | null;
|
|
226
|
+
/** `dsx.css.supports(...)` OFF A BROWSER, which is the server render lane and nothing else.
|
|
227
|
+
* In a browser the browser answers and this seam is never consulted; the kernel has no support
|
|
228
|
+
* ledger of its own on purpose, because the ledger is generated into the COMPILER package and a
|
|
229
|
+
* runtime kernel that imported the compiler would ship the compiler. The render lane installs
|
|
230
|
+
* it (packages/dom), and an uninstalled seam returns undefined, which the door reports as false
|
|
231
|
+
* rather than as a yes: an engine that cannot answer has not said the feature is there. */
|
|
232
|
+
cssSupports: ((prelude: string) => boolean | undefined) | null;
|
|
233
|
+
/** `element(<tag>)` inside a feature query (availability.md section 6.2): is this tag one the
|
|
234
|
+
* runtime renders, a builtin from the element registry and a package tag exactly as `dsx.has`
|
|
235
|
+
* answers it. A browser has never heard of a DSX element, so its own `CSS.supports` would say
|
|
236
|
+
* false with confidence; the door asks THIS seam first and hands the browser a prelude with the
|
|
237
|
+
* verdict already folded in. Installed by the dom boot and the render lane; uninstalled is
|
|
238
|
+
* false, as for every other feature this engine cannot answer. */
|
|
239
|
+
elementSupports: ((tag: string) => boolean) | null;
|
|
240
|
+
/** DEV MODE. False in every shipped app, and the one thing that turns the loud budget line
|
|
241
|
+
* below on: a production console gets the typed refusal envelope and nothing else, because
|
|
242
|
+
* a diagnostic that costs a string build per abort is a diagnostic that costs a shipped app
|
|
243
|
+
* something. The render lane sets it from the dev server's own flag. */
|
|
244
|
+
dev: boolean;
|
|
245
|
+
/** WHAT THE HOST IS EVALUATING, for the budget diagnostic and for nothing else. A host that
|
|
246
|
+
* knows the name of the declaration it is about to evaluate installs this; one that does not
|
|
247
|
+
* leaves it null and the diagnostic says "an expression" rather than lying about a name.
|
|
248
|
+
*
|
|
249
|
+
* THE WEB HOST'S HALF IS PENDING BY NAME. `packages/dom/src/mount.ts` and
|
|
250
|
+
* `packages/kernel/src/store.ts` are where a computed variable's evaluation is opened, and
|
|
251
|
+
* wiring this there is their landing, not this one's. Until it lands the diagnostic is
|
|
252
|
+
* loud about the cost and honest about not knowing the name. */
|
|
253
|
+
evaluationSubject: (() => string) | null;
|
|
254
|
+
/** THE CLOCK, as an input. `beginEvaluation` reads this once per evaluation and latches it
|
|
255
|
+
* on the budget, so the whole of an evaluation sees one instant. The default is the host
|
|
256
|
+
* wall clock; the server render lane installs the REQUEST's clock, a replay installs the
|
|
257
|
+
* instant the recorder wrote down, and a test installs whatever it is testing. A formula
|
|
258
|
+
* that reads the wall clock is not a formula, so this is the one door through which time
|
|
259
|
+
* enters the expression language, and it is an input rather than a reach. */
|
|
260
|
+
clockNow: () => number;
|
|
261
|
+
/** THE JUDGE OF A DECLARED SHAPE, for the dev diagnostic and for nothing else
|
|
262
|
+
* (proposals/types-on-declarations.md Decision 6, union-typed-variables.md Decision 4). The
|
|
263
|
+
* kernel reads no shape grammar - the parser is the compiler's (compiler/shape.ts) - so the
|
|
264
|
+
* lane that owns it installs this, and only in dev: `packages/dom/src/dev-shape.ts`, loaded
|
|
265
|
+
* by boot.ts when the dev server's flag is on. Given a declaration's `type=` and `moves=` as
|
|
266
|
+
* written, it answers a judge of one write, or null for a shape it cannot read. Null here is
|
|
267
|
+
* every shipped app, where a declared shape is inert. */
|
|
268
|
+
declaredShape: ((type: string, moves: string | undefined) => ((value: unknown, previous: unknown) => string | null) | null) | null;
|
|
269
|
+
};
|
|
270
|
+
/**
|
|
271
|
+
* The three shapes `dsx.css.supports` accepts, folded to ONE `@supports` prelude:
|
|
272
|
+
*
|
|
273
|
+
* dsx.css.supports("backdrop-filter: blur(20px)") a bare declaration
|
|
274
|
+
* dsx.css.supports("backdrop-filter", "blur(20px)") the property and the value apart
|
|
275
|
+
* dsx.css.supports("not (backdrop-filter: blur(1px))") any condition text
|
|
276
|
+
*
|
|
277
|
+
* The bare declaration is the shape an author reaches for first and the one a browser's own
|
|
278
|
+
* `CSS.supports` refuses in its single argument form, so it is PARENTHESISED here rather than
|
|
279
|
+
* passed through to fail. Twin: the compiler package's css-supports.ts `supportsPrelude`, which
|
|
280
|
+
* the native runners and the render lane seam read; the two are the same eight lines because this
|
|
281
|
+
* package must not import a build time one.
|
|
282
|
+
*/
|
|
283
|
+
export declare function supportsPrelude(first: string, second?: string): string;
|
|
284
|
+
/**
|
|
285
|
+
* THE WEB GUARD for `element()`. A prelude that names `element(` is answered by the DSX registry
|
|
286
|
+
* BEFORE the browser is asked: each `element(<tag>)` term is replaced by a declaration whose
|
|
287
|
+
* truth every engine knows (`(display: block)` is true, a property no engine has is false), so
|
|
288
|
+
* the browser still judges `not`, `and`, `or` and the other terms, and the DSX registry judges
|
|
289
|
+
* the one term a browser cannot. This is a scan for the function name with the parens balanced,
|
|
290
|
+
* not a parser.
|
|
291
|
+
*/
|
|
292
|
+
export declare function foldElementTerms(prelude: string, has: (tag: string) => boolean): string;
|
|
293
|
+
/** The desktop OS set behind `dsx.platform.desktop` (desktop-platforms.md; the law is
|
|
294
|
+
* the platform corpus). Derived, never an os value of its own — `os` stays exact. */
|
|
295
|
+
export declare const DESKTOP_OSES: readonly string[];
|
|
296
|
+
export declare function isDesktopOS(os: string): boolean;
|
|
297
|
+
/** `dsx.platform.os` for a renderer, given the native host it may run inside (corpus
|
|
298
|
+
* platform/platform.json `hosted`): a web document inside the iOS or Android host is that
|
|
299
|
+
* platform's app; a native renderer, and an unknown host, keep the renderer's own identity. */
|
|
300
|
+
export declare function hostedOS(renderer: string, host: string | null): string;
|
|
301
|
+
/** The iterable coercion shared by spread (`[...x]`) and `for…of`: arrays as-is,
|
|
302
|
+
* strings → graphemes, Set → its values, Map → its entry pairs, anything else empty. */
|
|
303
|
+
export declare function spreadValues(v: unknown): unknown[];
|
|
304
|
+
/** The `for…in` key coercion (wave 3): a dict's OWN keys (insertion order, "__"-internal
|
|
305
|
+
* keys skipped — so Set/Map/Date value objects iterate empty), an array's indices
|
|
306
|
+
* 0..n-1 (as numbers); anything else contributes nothing. */
|
|
307
|
+
export declare function forInKeys(v: unknown): unknown[];
|
|
308
|
+
/** JS `in` — dict key / array index membership (relational precedence, like the twins). */
|
|
309
|
+
export declare function inOp(l: unknown, r: unknown): boolean;
|
|
310
|
+
export type DeclPattern = {
|
|
311
|
+
kind: "ident";
|
|
312
|
+
name: string;
|
|
313
|
+
} | {
|
|
314
|
+
kind: "object";
|
|
315
|
+
entries: {
|
|
316
|
+
key: string;
|
|
317
|
+
value: DeclPattern;
|
|
318
|
+
def?: Token[];
|
|
319
|
+
}[];
|
|
320
|
+
rest?: string;
|
|
321
|
+
} | {
|
|
322
|
+
kind: "array";
|
|
323
|
+
items: ({
|
|
324
|
+
value: DeclPattern;
|
|
325
|
+
def?: Token[];
|
|
326
|
+
} | null)[];
|
|
327
|
+
rest?: string;
|
|
328
|
+
};
|
|
329
|
+
export type Declarator = {
|
|
330
|
+
pattern: DeclPattern;
|
|
331
|
+
expr: Token[];
|
|
332
|
+
};
|
|
333
|
+
/**
|
|
334
|
+
* Parse `pattern [= expr] (, pattern [= expr])*` from the token slice AFTER the
|
|
335
|
+
* `const`/`let`/`var` keyword (already captured to the statement end).
|
|
336
|
+
*
|
|
337
|
+
* Patterns NEST, and each position takes an optional `= default` and a trailing `...rest`.
|
|
338
|
+
* They used to be flat by design, which made three everyday shapes unwritable:
|
|
339
|
+
* `const { a: { b } } = row` (reading into a nested payload), `const { a = 5 } = opts`
|
|
340
|
+
* (an option with a fallback) and `const { id, ...rest } = row` (the standard way to omit a
|
|
341
|
+
* field). None had a workaround that was not several lines of manual copying, and all three
|
|
342
|
+
* are data-shaping rather than exotic syntax.
|
|
343
|
+
*/
|
|
344
|
+
export declare function parseDeclarators(toks: Token[]): Declarator[];
|
|
345
|
+
/**
|
|
346
|
+
* THE ONE ARROW-PARAM SCANNER, shared by the interpreter and the compiler.
|
|
347
|
+
*
|
|
348
|
+
* It exists because the two tiers each had their own copy of this loop, and a copy is a place
|
|
349
|
+
* to fall behind: when destructured params landed, the interpreter learned them and the
|
|
350
|
+
* compiler did not, so the same body meant two different things depending on which tier ran
|
|
351
|
+
* it. The corpus caught it — every case runs on both tiers — but a gate that catches drift is
|
|
352
|
+
* a worse instrument than a structure that cannot drift.
|
|
353
|
+
*
|
|
354
|
+
* Returns the params plus each one's default TOKENS. The interpreter keeps the tokens and
|
|
355
|
+
* evaluates them at call time; the compiler compiles them. Neither re-reads the shapes.
|
|
356
|
+
*/
|
|
357
|
+
export declare function parseArrowParams(toks: Token[], start: number): {
|
|
358
|
+
params: LambdaParam[];
|
|
359
|
+
defaults: (Token[] | null)[];
|
|
360
|
+
next: number;
|
|
361
|
+
};
|
|
362
|
+
/**
|
|
363
|
+
* Bind one declarator's VALUE through its pattern.
|
|
364
|
+
*
|
|
365
|
+
* `evalDefault` evaluates a `= default` when the position is MISSING — which in JSE means
|
|
366
|
+
* null, since null is its one absent value. Callers that cannot evaluate (the compile path)
|
|
367
|
+
* omit it and simply bind the missing value, exactly as before defaults existed.
|
|
368
|
+
*/
|
|
369
|
+
export declare function bindPattern(p: DeclPattern, value: unknown, bind: (name: string, v: unknown) => void, evalDefault?: (toks: Token[]) => unknown): void;
|
|
370
|
+
/** What an author meant by one `name="…"` attribute. The corpus is
|
|
371
|
+
* `OpenSource/Conformance/composition/attribute-binding.json`; the Kotlin and Swift twins
|
|
372
|
+
* are both `JSE.attributeBinding`. */
|
|
373
|
+
export type AttributeBinding = {
|
|
374
|
+
kind: "static";
|
|
375
|
+
} | {
|
|
376
|
+
kind: "value";
|
|
377
|
+
expr: string;
|
|
378
|
+
} | {
|
|
379
|
+
kind: "text";
|
|
380
|
+
};
|
|
381
|
+
/** The attribute-binding FOLD - pure syntax, no store, no evaluation.
|
|
382
|
+
*
|
|
383
|
+
* A sole `{{ … }}` carries the expression's VALUE; anything mixed carries the
|
|
384
|
+
* string. Without the distinction every consumer prop arrives interpolated, which is
|
|
385
|
+
* invisible for a label and fatal for structure: a component that renders its own
|
|
386
|
+
* children cannot hand them down, so a tree, an outliner or a comment thread is
|
|
387
|
+
* unbuildable. The facet path had already made this call privately, so the two kinds of
|
|
388
|
+
* component disagreed about what a prop is; this is that decision, shared.
|
|
389
|
+
*
|
|
390
|
+
* A hole ends at the FIRST `}}`, matching `interpolate`'s own scan exactly. The two must
|
|
391
|
+
* never disagree about where an expression stops - that disagreement is a silent type
|
|
392
|
+
* change, and one shared wrong answer is repairable where a split one is not. */
|
|
393
|
+
export declare function attributeBinding(template: string): AttributeBinding;
|
|
394
|
+
export declare const JSE_RUNTIME_SCOPE_NAMES: readonly string[];
|
|
395
|
+
/** Is this word a bare name `JSE.lookup` answers itself (so a scope key of that word is
|
|
396
|
+
* unreachable through its bare spelling)? */
|
|
397
|
+
export declare function isRuntimeScopeName(name: string): boolean;
|
|
398
|
+
/** The scope key an action's bound inputs are published under, so `dsx.input.<name>` can read
|
|
399
|
+
* one by NAME. A string key cannot be shadowed by an identifier, which is the whole point:
|
|
400
|
+
* `item.__element` is the same trick for the element handle. */
|
|
401
|
+
export declare const JSE_SCOPE_INPUTS = "__inputs";
|
|
402
|
+
/**
|
|
403
|
+
* THE AUTHORED LOCALS LEDGER, and why it lives here rather than in the runner.
|
|
404
|
+
*
|
|
405
|
+
* "A bare identifier in any JSE site is a block local, and nothing else" (S3 cut plan,
|
|
406
|
+
* section 0). The evaluator is what answers a bare identifier, so the evaluator is what has
|
|
407
|
+
* to know which names the block declared - and until this cut the ledger was module private
|
|
408
|
+
* to `runner.ts`, so `lookup` could only ask the weaker question "does the scope dict happen
|
|
409
|
+
* to carry this key", which an entry payload key and a row field answer as readily as a
|
|
410
|
+
* `const` does. That is the shadow the cut removes, and it cannot be removed from a file
|
|
411
|
+
* that cannot see the ledger.
|
|
412
|
+
*
|
|
413
|
+
* A SYMBOL, not the natives' NUL string key. The natives mark the scope dict itself and
|
|
414
|
+
* their dict copies carry the mark; on web a scope is built by spreading
|
|
415
|
+
* (`{ ...env.item, ...item, ...args }` in `callAction`), and an enumerable key would ride
|
|
416
|
+
* that spread into the callee, which would make a bare name in the CALLEE resolve against
|
|
417
|
+
* the CALLER's locals. A callee's locals are its own on every lane: the three runners strip
|
|
418
|
+
* the mark when they build a call scope, and a non-enumerable Symbol makes the web lane's
|
|
419
|
+
* spread do it for free.
|
|
420
|
+
*/
|
|
421
|
+
export declare const JSE_SCOPE_LOCALS: unique symbol;
|
|
422
|
+
export declare function captureScope(item: Item): Dict;
|
|
423
|
+
/** Event callbacks explicitly bind their payload as the current scope. */
|
|
424
|
+
export declare function bindScopeThis(scope: Dict, item: Item): Dict;
|
|
425
|
+
declare const EVENT_ELEMENT_MEMBERS: readonly ["target", "currentTarget", "eventPhase"];
|
|
426
|
+
/** The element members a renderer lays for an element event (ADR 0025 D2), as `dsx.event` reads them. */
|
|
427
|
+
export type ScopeEventMembers = {
|
|
428
|
+
readonly [K in typeof EVENT_ELEMENT_MEMBERS[number]]?: unknown;
|
|
429
|
+
};
|
|
430
|
+
/** Bind the event a handler or a callback runs for: its name, its flat payload as `data`, and the
|
|
431
|
+
* element members where a renderer dispatched it over elements. */
|
|
432
|
+
export declare function bindScopeEvent(scope: Dict, name: string, data: Dict, members?: ScopeEventMembers | null): Dict;
|
|
433
|
+
/** A copy of a handler's item with the event bound: the item's slot scope rides along, so a handler that reads
|
|
434
|
+
* `dsx.slot.*` reads it as before. */
|
|
435
|
+
export declare function eventItem(item: Item, name: string, data: Dict): Dict;
|
|
436
|
+
/** Bind an action call's declared arguments, read as `dsx.action.argument("<name>")`: each declared name's bound value. */
|
|
437
|
+
export declare function bindScopeActionInputs(scope: Dict, declared: Iterable<string>): Dict;
|
|
438
|
+
/** Is `callee` an argument read rather than a call of a declared action? */
|
|
439
|
+
export declare function isArgumentRead(callee: string): boolean;
|
|
440
|
+
/** `dsx.<owner>.arguments()` reads the block's whole set, `dsx.<owner>.argument("<name>")` one of them; outside
|
|
441
|
+
* its block, or for a name the block does not declare, the read is the typed absence. */
|
|
442
|
+
export declare function argumentRead(callee: string, args: readonly unknown[], item: Item): unknown;
|
|
443
|
+
/** Mark `name` as a name this block itself declared. */
|
|
444
|
+
export declare function declareLocal(scope: Dict, name: string): void;
|
|
445
|
+
/** Did this block declare `name`? A scope with no ledger declared nothing. */
|
|
446
|
+
export declare function isLocal(scope: Item, name: string): boolean;
|
|
447
|
+
/** The ledger itself, for a reader that wants the whole set (a debugger's frame, a call
|
|
448
|
+
* scope that must NOT inherit it). Never a writer: only a binder declares a local. */
|
|
449
|
+
export declare function localsOf(scope: Item): ReadonlySet<string> | undefined;
|
|
450
|
+
/** BLOCK SCOPE AND BINDINGS WITH IDENTITY (logic parity sweep 6,
|
|
451
|
+
* ). An action body keeps ONE scope object, and a
|
|
452
|
+
* block is a FRAME over it: a declaration inside the block records what the name held before
|
|
453
|
+
* (absent, or its value, local mark and binding) and the frame restores that at the block's end,
|
|
454
|
+
* so `let`/`const` are block scoped as in JavaScript. Every declaration also mints a BINDING id,
|
|
455
|
+
* and a lambda keeps the ids of the names it captured: a caller's live local of the same name is
|
|
456
|
+
* the lambda's binding only while the ids agree, which is what gives a `for (let …)` closure its
|
|
457
|
+
* own iteration's value. Both ledgers ride under non-enumerable symbols, like the locals ledger,
|
|
458
|
+
* so a spread into a callee scope never carries them.
|
|
459
|
+
*
|
|
460
|
+
* THE BLOCK SCOPE FOLD (`__DSX_OPTIONAL_BLOCK_SCOPE__`, cli embed entry.ts registryUsesBlockScope).
|
|
461
|
+
* A frame records only what a declaration puts in it, and a binding id is minted only by a
|
|
462
|
+
* declaration, so a slice that declares nothing (no `let`, `const`, `var`, catch binding or loop
|
|
463
|
+
* head anywhere) opens and closes empty frames and captures no ids: every helper below answers as
|
|
464
|
+
* if the machinery were absent, and folding it away changes nothing. The guard is inline in each
|
|
465
|
+
* helper, because a hoisted flag does not tree-shake. An app build defines no fold. */
|
|
466
|
+
export declare const JSE_SCOPE_BINDINGS: unique symbol;
|
|
467
|
+
export declare function bindingsOf(scope: Item): Map<string, number> | undefined;
|
|
468
|
+
/** Open a block frame over `scope`. */
|
|
469
|
+
export declare function openBlock(scope: Dict): void;
|
|
470
|
+
/** Declare `name` in the innermost open block (or the body when none is open): the frame
|
|
471
|
+
* remembers the prior state once, and the name gets a fresh binding. The caller binds the value
|
|
472
|
+
* and the local mark as it always did. */
|
|
473
|
+
export declare function newBinding(scope: Dict, name: string): void;
|
|
474
|
+
/** A fresh binding for a name already declared in this frame (a loop head, per iteration). */
|
|
475
|
+
export declare function rebind(scope: Dict, name: string): void;
|
|
476
|
+
/** The names the innermost frame declared. */
|
|
477
|
+
export declare function blockNames(scope: Dict): string[];
|
|
478
|
+
/** Close the innermost frame: every name it declared goes back to what it was. */
|
|
479
|
+
export declare function closeBlock(scope: Dict): void;
|
|
480
|
+
/** A declared attribute type the runtime acts on: `type="number"` (or `number?`) makes the
|
|
481
|
+
* attribute's text read as the number it spells (corpus components/component-attribute-plane.json,
|
|
482
|
+
* the typed rows). Every other type stays a claim for the readers ADR 0015 names. */
|
|
483
|
+
export declare function declareAttributeType(store: StackStore, as: string, type: string): void;
|
|
484
|
+
/** A number-typed attribute's value: a text that reads as a finite number (JavaScript's
|
|
485
|
+
* StringToNumber, blank excluded) is that number; anything else is kept as given, so a text
|
|
486
|
+
* that is not a number stays visible to the author rather than turning into NaN. */
|
|
487
|
+
export declare function typedAttributeValue(v: unknown): unknown;
|
|
488
|
+
/** HTML dataset's dash followed by lowercase ASCII rule. */
|
|
489
|
+
export declare function componentAttributeName(name: string): string;
|
|
490
|
+
export declare function componentAttributes(attributes: Dict): Dict;
|
|
491
|
+
/** Markup inputs cross to JS once; API dictionaries already use JS names. */
|
|
492
|
+
declare function markupComponentAttributes(attributes: Dict): Dict;
|
|
493
|
+
export declare const JSE: {
|
|
494
|
+
attributeBinding: typeof attributeBinding;
|
|
495
|
+
componentAttributeName: typeof componentAttributeName;
|
|
496
|
+
componentAttributes: typeof componentAttributes;
|
|
497
|
+
markupComponentAttributes: typeof markupComponentAttributes;
|
|
498
|
+
/** The markup spelling of an API event. Inverse of the component attribute boundary. */
|
|
499
|
+
markupEventName(name: string): string;
|
|
500
|
+
/** Resolve one consumer attribute to the value it should carry: typed when the template
|
|
501
|
+
* is a sole hole, its own text when it has none, the interpolated sentence otherwise. */
|
|
502
|
+
bindAttribute(template: string, store: StackStore, item: Item): unknown;
|
|
503
|
+
interpolate(s: string, store: StackStore, item: Item): string;
|
|
504
|
+
/** `host` binds a JSEHostBinding for the length of THIS evaluation and everything it
|
|
505
|
+
* calls; omitting it leaves whatever binding the enclosing door set, so a nested door
|
|
506
|
+
* inherits its evaluation's host rather than silently dropping it. */
|
|
507
|
+
eval(raw: string, store: StackStore, item: Item, host?: JSEHostBinding | null): unknown;
|
|
508
|
+
/** Evaluate a `<variable>`/function body as a VALUE — a **bounded-JS** block.
|
|
509
|
+
* PURE: `const`/`let`/`x = e` write a throwaway local scope, never the store.
|
|
510
|
+
* The full statement grammar incl. BUDGETED loops (10000 iterations per evaluation,
|
|
511
|
+
* corpus core-004) — so it always terminates. */
|
|
512
|
+
evalBlock(body: string, store: StackStore, item: Item, host?: JSEHostBinding | null): unknown;
|
|
513
|
+
validSyntax(source: string): boolean;
|
|
514
|
+
/** Register every top-level `function name(params) { … }` in `body` as a callable
|
|
515
|
+
* user function — positional args, depth-capped at 32. String-scanned. */
|
|
516
|
+
registerFunctions(body: string, store: StackStore): void;
|
|
517
|
+
/** Register `body`'s top-level functions into the APP-WIDE table — the global function
|
|
518
|
+
* library (js-core.md "Shared logic"): validation/pricing/formatting written ONCE,
|
|
519
|
+
* callable from every surface. Same scanner, same shapes as registerFunctions; global
|
|
520
|
+
* registration does NOT capture scope (free names resolve against the CALLING
|
|
521
|
+
* surface's live store, exactly like top-level surface functions). Lookup order at a
|
|
522
|
+
* named call: scope lambda → the surface's `store.functions` (a local name SHADOWS
|
|
523
|
+
* the global) → this table → builtins; same fnDepth 32 guard. Boot/modules call this
|
|
524
|
+
* once at startup; re-registration replaces (last write wins). */
|
|
525
|
+
registerGlobalFunctions(body: string): void;
|
|
526
|
+
/** Drop every globally registered function (tests; a full app reload). */
|
|
527
|
+
clearGlobalFunctions(): void;
|
|
528
|
+
/** The app-wide table's read side — the executors' shared lookup seam (Parser +
|
|
529
|
+
* compiled `$.call` resolve through this after the surface table misses). */
|
|
530
|
+
globalFunction(name: string): unknown;
|
|
531
|
+
/** Invoke a lambda / user function: bind args to params (destructuring `{a,b}`,
|
|
532
|
+
* call-time defaults, a trailing rest array), then evaluate the body.
|
|
533
|
+
* Scope = caller `base` ⊕ captured creation scope ⊕ params — base fills UNDER the
|
|
534
|
+
* captured snapshot (capture semantics hold), which is what lets a stored lambda call
|
|
535
|
+
* ITSELF (`const f = n => … f(n - 1)`: f is not in its own creation snapshot, so the
|
|
536
|
+
* caller's live scope supplies it). */
|
|
537
|
+
callLambda(f: StackLambda, args: unknown[], store: StackStore, base?: Dict | null): unknown;
|
|
538
|
+
/** Pure built-in functions for `{{ … }}`: no side effects, no I/O.
|
|
539
|
+
* AN OPTIONAL PLANE (STDLIB_FNS above): the switch is reachable only through a spelled
|
|
540
|
+
* `name(` call, so a closed slice that spells none of them folds the whole library out. */
|
|
541
|
+
apply: (name: string, a: unknown[], store: StackStore) => unknown;
|
|
542
|
+
/** JS array/string methods called method-style: the same plane, entered through a `.`
|
|
543
|
+
* (STDLIB_METHODS above). An unknown name answered null before the fold and answers null
|
|
544
|
+
* after it, which is what makes the folded build the same language on a smaller roster. */
|
|
545
|
+
applyMethod: (m: string, base: unknown, a: unknown[], store?: StackStore) => unknown;
|
|
546
|
+
/** Bounded higher-order collection functions — total, one pass, arrow-fn callbacks. */
|
|
547
|
+
higherOrder(id: string, coll: unknown, fn: StackLambda | null, store: StackStore, initial?: unknown, hasInitial?: boolean): unknown;
|
|
548
|
+
/** JS Array.prototype.sort semantics — returns a sorted COPY (value semantics). */
|
|
549
|
+
sortedArray(arr: unknown[], comparator: unknown, store: StackStore): unknown[];
|
|
550
|
+
/** Normalize an explicit `dsx.`-namespace prefix to its canonical scope path.
|
|
551
|
+
*
|
|
552
|
+
* THE NAMESPACE IS CLOSED. The head list below is the whole read surface of `dsx.`, and a
|
|
553
|
+
* word that is not on it normalizes to NO PATH AT ALL - the empty string, which `lookup`
|
|
554
|
+
* reads as the typed absence and `writePath` refuses. It used to fall through to the body,
|
|
555
|
+
* so `dsx.typo.x` silently read the surface variable `typo.x` on all three runners: the
|
|
556
|
+
* right type, no diagnostic, and `nav` and `module` worked only because of that hole. They
|
|
557
|
+
* have their own cases now, so nothing is left that needs it. The linter's
|
|
558
|
+
* `dsx-unknown-plane` says the same thing before the build. */
|
|
559
|
+
normalizeScope(path: string): string;
|
|
560
|
+
lookup(rawPath: string, store: StackStore, item: Item): unknown;
|
|
561
|
+
number: typeof number;
|
|
562
|
+
string: typeof string;
|
|
563
|
+
truthy: typeof truthy;
|
|
564
|
+
equals: typeof jseEquals;
|
|
565
|
+
compare: typeof compare;
|
|
566
|
+
arith: typeof arith;
|
|
567
|
+
typeofString: typeof typeofString;
|
|
568
|
+
watchKey: typeof watchKey;
|
|
569
|
+
asArray: typeof asArray;
|
|
570
|
+
asRows: typeof asRows;
|
|
571
|
+
index: typeof indexOp;
|
|
572
|
+
member: typeof memberOp;
|
|
573
|
+
higherOrderFns: ReadonlySet<string>;
|
|
574
|
+
methodFns: ReadonlySet<string>;
|
|
575
|
+
dsxLibCall: RegExp;
|
|
576
|
+
afterRender(work: () => void): void;
|
|
577
|
+
};
|
|
578
|
+
/** THE ARRAY MUTATORS OF AN ACTION BODY (reference/jse.md). In an action body
|
|
579
|
+
* `P.verb(args)` on a writable dotted path mutates and answers JavaScript's value; everywhere
|
|
580
|
+
* else the evaluator keeps the pure reading. Twins: JSE.arrayMutators in JSE.swift and Jse.kt. */
|
|
581
|
+
export declare const ARRAY_MUTATORS: ReadonlySet<string>;
|
|
582
|
+
/** What a runner installs on a Parser for an action body. `accepts` runs BEFORE the arguments
|
|
583
|
+
* (a refusal leaves the pure reading untouched, arguments evaluated once); `apply` runs after
|
|
584
|
+
* them, reads the receiver, writes the new array and answers the JS value. */
|
|
585
|
+
/** The action body a lambda is called from, as the lambda needs it: the runner's hook, and its
|
|
586
|
+
* authored locals by name (a captured local that is the action's reads its current value and
|
|
587
|
+
* writes through to it, the JavaScript closure law). Twins: Jse.kt, JSE.swift `ActionLambdaCtx`. */
|
|
588
|
+
export type ActionLambdaCtx = {
|
|
589
|
+
hook: ArrayMutationHook;
|
|
590
|
+
isLocal(name: string): boolean;
|
|
591
|
+
read(name: string): unknown;
|
|
592
|
+
/** The calling body's current binding id of `name` (sweep 6 block scope), when it has one. */
|
|
593
|
+
binding?(name: string): number | undefined;
|
|
594
|
+
applyLocal(path: string, verb: string, args: unknown[]): unknown;
|
|
595
|
+
/** The action's write door (the runner's writePath): a captured local of the action, or a
|
|
596
|
+
* `dsx.` path, written from inside a lambda the action called (JSE-VS-JS item 12). */
|
|
597
|
+
write?(path: string, value: unknown): void;
|
|
598
|
+
};
|
|
599
|
+
/** ONE ARRAY VERB, PURE: the array after it and the value JavaScript answers, or null for a verb
|
|
600
|
+
* that is not a mutator. The runner writes the array through its door; a lambda's own local
|
|
601
|
+
* lands in the lambda's scope. Twins: Jse.kt `JSE.arrayVerb`, JSE.swift `JSE.arrayVerb`. */
|
|
602
|
+
export declare function arrayVerb(base: unknown, verb: string, args: unknown[], store: StackStore): {
|
|
603
|
+
array: unknown[];
|
|
604
|
+
value: unknown;
|
|
605
|
+
} | null;
|
|
606
|
+
export type ArrayMutationHook = {
|
|
607
|
+
accepts(path: string, item: Item): boolean;
|
|
608
|
+
apply(path: string, verb: string, args: unknown[], item: Item): unknown;
|
|
609
|
+
};
|
|
610
|
+
/** THE INCREMENT TARGET (JSE-VS-JS item 11). The end (exclusive) of an assignable path that
|
|
611
|
+
* starts at `from`: one identifier (a dotted run is ONE token) followed by any `.name` and
|
|
612
|
+
* `[expr]` links, and nothing else, so a call, an optional link or a literal is never a
|
|
613
|
+
* target. -1 when `from` does not start one. The same shape the statement form's `mutation`
|
|
614
|
+
* walks, which is what lets `i++` in an expression land exactly where `i++;` lands. */
|
|
615
|
+
export declare function incrementTargetEnd(toks: Token[], from: number): number;
|
|
616
|
+
/** `++` / `--` count as a NUMBER (JavaScript's ToNumeric): '5' is 5, null is 0, and what has
|
|
617
|
+
* no number is NaN. Answers the old and the new value; the caller picks by position. */
|
|
618
|
+
export declare function bumpNumbers(old: unknown, op: string): {
|
|
619
|
+
old: number;
|
|
620
|
+
next: number;
|
|
621
|
+
};
|
|
622
|
+
/** The write an expression-position `++` / `--` lands, bound by the evaluator that owns a
|
|
623
|
+
* place to write (a block's scope, an action body's runner); null in a pure expression. */
|
|
624
|
+
export type IncrementHook = (target: Token[], op: string, prefix: boolean) => unknown;
|
|
625
|
+
export declare class Parser {
|
|
626
|
+
#private;
|
|
627
|
+
pos: number;
|
|
628
|
+
depth: number;
|
|
629
|
+
skipping: number;
|
|
630
|
+
awaitPos: string;
|
|
631
|
+
readonly tokens: Token[];
|
|
632
|
+
readonly store: StackStore;
|
|
633
|
+
readonly item: Item;
|
|
634
|
+
/** The action body's array mutation hook; null in every pure context. */
|
|
635
|
+
mutate: ArrayMutationHook | null;
|
|
636
|
+
/** The expression-position increment's write (JSE-VS-JS item 11); null in a pure context,
|
|
637
|
+
* where `n++` answers its value and writes nothing (an expression never mutates). */
|
|
638
|
+
bump: IncrementHook | null;
|
|
639
|
+
constructor(tokens: Token[], store: StackStore, item: Item);
|
|
640
|
+
peek(): Token | null;
|
|
641
|
+
advance(): void;
|
|
642
|
+
op(s: string): boolean;
|
|
643
|
+
expression(): unknown;
|
|
644
|
+
unevaluated(parse: () => unknown): void;
|
|
645
|
+
shift(): unknown;
|
|
646
|
+
/** One increment: nothing runs in a lazy operand; a bound hook writes; a pure parse reads. */
|
|
647
|
+
increment(target: Token[], op: string, prefix: boolean): unknown;
|
|
648
|
+
/** `(params) => body` (the free `tryArrow` below; null when the slice folds lambdas). */
|
|
649
|
+
tryArrow(): unknown;
|
|
650
|
+
/** One balanced group, brackets included (the free `balancedGroup` below). */
|
|
651
|
+
balancedGroup(): Token[];
|
|
652
|
+
/** One arrow-param default's tokens (the free `defaultTokens` below). */
|
|
653
|
+
defaultTokens(): Token[];
|
|
654
|
+
/** After `=>`: the body as a lambda value (the free `arrowBody` below). */
|
|
655
|
+
arrowBody(params: LambdaParam[]): unknown;
|
|
656
|
+
}
|
|
657
|
+
/** Rebuild `container` with `parts` set to `value` — BY COPY at every level (value
|
|
658
|
+
* semantics: a block-scope path write never aliases another binding). A numeric part
|
|
659
|
+
* indexes an array: in bounds it replaces, past the end it GROWS the array and fills the gap
|
|
660
|
+
* with null (JSE-VS-JS #18, jse/array-grow-001.json), under ARRAY_WRITE_LIMITS; a negative or
|
|
661
|
+
* fractional index names no element and writes nothing. Anything else keys a dict; a missing
|
|
662
|
+
* nest is created as a dict — total, never a throw. Corpus core-003. */
|
|
663
|
+
declare function setInLocal(container: unknown, parts: unknown[], value: unknown): unknown;
|
|
664
|
+
/** `xs.length = n`: the copy truncated to n, or grown to n with null, as far as the indexed-write
|
|
665
|
+
* ceiling allows; a length that is not a non-negative integer, or past the ceiling, keeps the
|
|
666
|
+
* array unchanged. */
|
|
667
|
+
export declare function arrayWithLength(container: unknown[], value: unknown): unknown[];
|
|
668
|
+
/** Walk `parts` into `container`, the read twin of setInLocal; missing is null. A dict answers
|
|
669
|
+
* its OWN key only (JSE-PROTO): this door read `(cur as Dict)[key]` and so walked the host
|
|
670
|
+
* prototype for every inherited name, exactly as `member()` did. */
|
|
671
|
+
declare function getInLocal(container: unknown, parts: unknown[]): unknown;
|
|
672
|
+
export { NSNull, isNSNull, isDict, isLambda, watchKey, setInLocal, getInLocal };
|
|
673
|
+
export type { Dict, StackLambda };
|
|
674
|
+
//# sourceMappingURL=jse.d.ts.map
|