foldkit 0.129.0 → 0.130.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/THIRD-PARTY-NOTICES.md +30 -0
- package/dist/brand/brand.d.ts +25 -0
- package/dist/brand/brand.d.ts.map +1 -0
- package/dist/brand/brand.js +50 -0
- package/dist/brand/index.d.ts +2 -0
- package/dist/brand/index.d.ts.map +1 -0
- package/dist/brand/index.js +1 -0
- package/dist/brand/public.d.ts +2 -0
- package/dist/brand/public.d.ts.map +1 -0
- package/dist/brand/public.js +1 -0
- package/dist/canvas/view.d.ts.map +1 -1
- package/dist/canvas/view.js +1 -1
- package/dist/devTools/protocol.d.ts +1 -1
- package/dist/devTools/protocol.d.ts.map +1 -1
- package/dist/devTools/protocol.js +1 -1
- package/dist/devTools/store.js +2 -2
- package/dist/devTools/webSocketBridge.d.ts +1 -1
- package/dist/devTools/webSocketBridge.js +1 -1
- package/dist/html/index.d.ts +18 -18
- package/dist/html/index.d.ts.map +1 -1
- package/dist/html/index.js +530 -460
- package/dist/html/lazy.d.ts +1 -1
- package/dist/html/lazy.d.ts.map +1 -1
- package/dist/html/lazy.js +11 -2
- package/dist/propsModule.d.ts +1 -1
- package/dist/propsModule.d.ts.map +1 -1
- package/dist/propsModule.js +6 -1
- package/dist/runtime/runtime.d.ts.map +1 -1
- package/dist/runtime/runtime.js +468 -278
- package/dist/snabbdom/attributes.d.ts +4 -0
- package/dist/snabbdom/attributes.d.ts.map +1 -0
- package/dist/snabbdom/attributes.js +63 -0
- package/dist/snabbdom/class.d.ts +4 -0
- package/dist/snabbdom/class.d.ts.map +1 -0
- package/dist/snabbdom/class.js +31 -0
- package/dist/snabbdom/dataset.d.ts +4 -0
- package/dist/snabbdom/dataset.d.ts.map +1 -0
- package/dist/snabbdom/dataset.js +42 -0
- package/dist/snabbdom/eventlisteners.d.ts +11 -0
- package/dist/snabbdom/eventlisteners.d.ts.map +1 -0
- package/dist/snabbdom/eventlisteners.js +85 -0
- package/dist/snabbdom/h.d.ts +11 -0
- package/dist/snabbdom/h.d.ts.map +1 -0
- package/dist/snabbdom/h.js +61 -0
- package/dist/snabbdom/hooks.d.ts +24 -0
- package/dist/snabbdom/hooks.d.ts.map +1 -0
- package/dist/snabbdom/hooks.js +1 -0
- package/dist/snabbdom/htmldomapi.d.ts +34 -0
- package/dist/snabbdom/htmldomapi.d.ts.map +1 -0
- package/dist/snabbdom/htmldomapi.js +111 -0
- package/dist/snabbdom/index.d.ts +15 -0
- package/dist/snabbdom/index.d.ts.map +1 -0
- package/dist/snabbdom/index.js +9 -0
- package/dist/snabbdom/init.d.ts +14 -0
- package/dist/snabbdom/init.d.ts.map +1 -0
- package/dist/snabbdom/init.js +486 -0
- package/dist/snabbdom/is.d.ts +3 -0
- package/dist/snabbdom/is.d.ts.map +1 -0
- package/dist/snabbdom/is.js +7 -0
- package/dist/snabbdom/module.d.ts +11 -0
- package/dist/snabbdom/module.d.ts.map +1 -0
- package/dist/snabbdom/module.js +1 -0
- package/dist/snabbdom/props.d.ts +2 -0
- package/dist/snabbdom/props.d.ts.map +1 -0
- package/dist/snabbdom/props.js +1 -0
- package/dist/snabbdom/style.d.ts +9 -0
- package/dist/snabbdom/style.d.ts.map +1 -0
- package/dist/snabbdom/style.js +123 -0
- package/dist/snabbdom/tovnode.d.ts +4 -0
- package/dist/snabbdom/tovnode.d.ts.map +1 -0
- package/dist/snabbdom/tovnode.js +69 -0
- package/dist/snabbdom/vnode.d.ts +46 -0
- package/dist/snabbdom/vnode.d.ts.map +1 -0
- package/dist/snabbdom/vnode.js +13 -0
- package/dist/vdom.d.ts +2 -2
- package/dist/vdom.d.ts.map +1 -1
- package/dist/vdom.js +1 -1
- package/package.json +7 -5
- package/dist/runtime/messagePriority.d.ts +0 -17
- package/dist/runtime/messagePriority.d.ts.map +0 -1
- package/dist/runtime/messagePriority.js +0 -33
- package/dist/runtime/renderLoop.d.ts +0 -27
- package/dist/runtime/renderLoop.d.ts.map +0 -1
- package/dist/runtime/renderLoop.js +0 -25
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Third-Party Notices
|
|
2
|
+
|
|
3
|
+
This package includes a vendored fork of snabbdom v3.6.3
|
|
4
|
+
(https://github.com/snabbdom/snabbdom), compiled into the published dist
|
|
5
|
+
output from `src/snabbdom/`. The fork and its changes are documented in
|
|
6
|
+
`src/snabbdom/README.md` in the repository. The original license follows.
|
|
7
|
+
|
|
8
|
+
## snabbdom
|
|
9
|
+
|
|
10
|
+
The MIT License (MIT)
|
|
11
|
+
|
|
12
|
+
Copyright (c) 2015 Simon Friis Vindum
|
|
13
|
+
|
|
14
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
15
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
16
|
+
in the Software without restriction, including without limitation the rights
|
|
17
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
18
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
19
|
+
furnished to do so, subject to the following conditions:
|
|
20
|
+
|
|
21
|
+
The above copyright notice and this permission notice shall be included in all
|
|
22
|
+
copies or substantial portions of the Software.
|
|
23
|
+
|
|
24
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
25
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
26
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
27
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
28
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
29
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
30
|
+
SOFTWARE.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Stamps a framework-managed identity onto a view result.
|
|
3
|
+
*
|
|
4
|
+
* Identity is the differ's second axis, independent of user-facing keys: it
|
|
5
|
+
* answers "which view arm produced this node" rather than "which sibling is
|
|
6
|
+
* this". Identity never enters the keyed index; it joins the differ's
|
|
7
|
+
* compatibility check exactly where the selector is consulted, so an identity
|
|
8
|
+
* mismatch replaces the node instead of patching it, and switching between
|
|
9
|
+
* conditional view arms tears down the old subtree even when both arms render
|
|
10
|
+
* the same tag.
|
|
11
|
+
*
|
|
12
|
+
* Stamping is set-if-absent and mutates the vnode in place: a vnode that
|
|
13
|
+
* already carries an identity (including a memoized vnode returned from a
|
|
14
|
+
* cache) is left untouched, so branding is idempotent and never breaks
|
|
15
|
+
* reference equality that the renderer relies on. Vnodes are stamped directly;
|
|
16
|
+
* for an array result each vnode element is stamped with the same identity.
|
|
17
|
+
* Any other value passes through unchanged.
|
|
18
|
+
*
|
|
19
|
+
* `@foldkit/vite-plugin` injects a call to this around every function return
|
|
20
|
+
* in application modules at build time, so identity attaches at view-function
|
|
21
|
+
* boundaries regardless of the branching syntax that selected the function.
|
|
22
|
+
* Application code does not call it by hand.
|
|
23
|
+
*/
|
|
24
|
+
export declare const brandViewResult: <A>(result: A, identity: string) => A;
|
|
25
|
+
//# sourceMappingURL=brand.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"brand.d.ts","sourceRoot":"","sources":["../../src/brand/brand.ts"],"names":[],"mappings":"AAmBA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,eAAO,MAAM,eAAe,GAAI,CAAC,EAAE,QAAQ,CAAC,EAAE,UAAU,MAAM,KAAG,CAWhE,CAAA"}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
const isVNode = (value) => typeof value === 'object' &&
|
|
2
|
+
value !== null &&
|
|
3
|
+
'sel' in value &&
|
|
4
|
+
typeof value.sel === 'string' &&
|
|
5
|
+
'data' in value &&
|
|
6
|
+
'children' in value &&
|
|
7
|
+
'text' in value &&
|
|
8
|
+
'elm' in value &&
|
|
9
|
+
'key' in value;
|
|
10
|
+
const stampIdentity = (target, identity) => {
|
|
11
|
+
if (target.identity === undefined) {
|
|
12
|
+
target.identity = identity;
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Stamps a framework-managed identity onto a view result.
|
|
17
|
+
*
|
|
18
|
+
* Identity is the differ's second axis, independent of user-facing keys: it
|
|
19
|
+
* answers "which view arm produced this node" rather than "which sibling is
|
|
20
|
+
* this". Identity never enters the keyed index; it joins the differ's
|
|
21
|
+
* compatibility check exactly where the selector is consulted, so an identity
|
|
22
|
+
* mismatch replaces the node instead of patching it, and switching between
|
|
23
|
+
* conditional view arms tears down the old subtree even when both arms render
|
|
24
|
+
* the same tag.
|
|
25
|
+
*
|
|
26
|
+
* Stamping is set-if-absent and mutates the vnode in place: a vnode that
|
|
27
|
+
* already carries an identity (including a memoized vnode returned from a
|
|
28
|
+
* cache) is left untouched, so branding is idempotent and never breaks
|
|
29
|
+
* reference equality that the renderer relies on. Vnodes are stamped directly;
|
|
30
|
+
* for an array result each vnode element is stamped with the same identity.
|
|
31
|
+
* Any other value passes through unchanged.
|
|
32
|
+
*
|
|
33
|
+
* `@foldkit/vite-plugin` injects a call to this around every function return
|
|
34
|
+
* in application modules at build time, so identity attaches at view-function
|
|
35
|
+
* boundaries regardless of the branching syntax that selected the function.
|
|
36
|
+
* Application code does not call it by hand.
|
|
37
|
+
*/
|
|
38
|
+
export const brandViewResult = (result, identity) => {
|
|
39
|
+
if (isVNode(result)) {
|
|
40
|
+
stampIdentity(result, identity);
|
|
41
|
+
}
|
|
42
|
+
else if (Array.isArray(result)) {
|
|
43
|
+
for (const element of result) {
|
|
44
|
+
if (isVNode(element)) {
|
|
45
|
+
stampIdentity(element, identity);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
return result;
|
|
50
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/brand/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './brand.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public.d.ts","sourceRoot":"","sources":["../../src/brand/public.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { brandViewResult } from './index.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../src/canvas/view.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../../src/canvas/view.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,IAAI,EAAqB,MAAM,kBAAkB,CAAA;AAI/D,OAAO,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,YAAY,CAAA;AAE9C;;;;;GAKG;AACH,MAAM,MAAM,UAAU,CAAC,OAAO,IAAI,QAAQ,CAAC;IACzC,KAAK,EAAE,MAAM,CAAA;IACb,MAAM,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,aAAa,CAAC,KAAK,CAAC,CAAA;IAC5B,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC9B,aAAa,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC,GAAG,SAAS,CAAA;IACvD,aAAa,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC,GAAG,SAAS,CAAA;IACvD,WAAW,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,KAAK,KAAK,OAAO,CAAC,GAAG,SAAS,CAAA;CACtD,CAAC,CAAA;AA8BF;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,IAAI,GAAI,OAAO,EAAE,QAAQ,UAAU,CAAC,OAAO,CAAC,KAAG,IAwE3D,CAAA"}
|
package/dist/canvas/view.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Array, Predicate, Record, String, pipe } from 'effect';
|
|
2
|
-
import { h } from 'snabbdom';
|
|
3
2
|
import { __requireDispatch } from '../html/index.js';
|
|
3
|
+
import { h } from '../snabbdom/index.js';
|
|
4
4
|
import { paintScene } from './paint.js';
|
|
5
5
|
/**
|
|
6
6
|
* Per-element 2D context cache. Keyed by the live `<canvas>` element so the
|
|
@@ -265,7 +265,7 @@ export declare const ResponseReplayed: import("../schema/index.js").CallableTagg
|
|
|
265
265
|
}>;
|
|
266
266
|
/** Response confirming the runtime resumed normal execution. */
|
|
267
267
|
export declare const ResponseResumed: import("../schema/index.js").CallableTaggedStruct<"ResponseResumed", {}>;
|
|
268
|
-
/** Response confirming a Message was dispatched. The `acceptedAtIndex` is the absolute history index where the entry is predicted to land. Computed from the runtime's history length at dispatch time. The
|
|
268
|
+
/** Response confirming a Message was dispatched. The `acceptedAtIndex` is the absolute history index where the entry is predicted to land. Computed from the runtime's history length at dispatch time. The runtime processes Messages in arrival order and the bridge is the only external dispatch source, so this index is reliable for correlation. */
|
|
269
269
|
export declare const ResponseDispatched: import("../schema/index.js").CallableTaggedStruct<"ResponseDispatched", {
|
|
270
270
|
acceptedAtIndex: S.Number;
|
|
271
271
|
}>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"protocol.d.ts","sourceRoot":"","sources":["../../src/devTools/protocol.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,MAAM,IAAI,CAAC,EAAE,MAAM,QAAQ,CAAA;AAM5C,0NAA0N;AAC1N,eAAO,MAAM,iBAAiB;;;EAG5B,CAAA;AACF,2EAA2E;AAC3E,MAAM,MAAM,iBAAiB,GAAG,OAAO,iBAAiB,CAAC,IAAI,CAAA;AAE7D,0MAA0M;AAC1M,eAAO,MA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Aa;;EAExB,CAAA;AAEF,wCAAwC;AACxC,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAenB,CAAA;AACF,wCAAwC;AACxC,MAAM,MAAM,QAAQ,GAAG,OAAO,QAAQ,CAAC,IAAI,CAAA;AAI3C,uCAAuC;AACvC,eAAO,MAAM,cAAc;;;;;;EAEzB,CAAA;AAEF,mDAAmD;AACnD,eAAO,MAAM,iBAAiB;;EAE5B,CAAA;AAEF,iIAAiI;AACjI,eAAO,MAAM,KAAK;;;;;;;;IAA+C,CAAA;AACjE,iCAAiC;AACjC,MAAM,MAAM,KAAK,GAAG,OAAO,KAAK,CAAC,IAAI,CAAA;AAIrC,0NAA0N;AAC1N,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAIvB,CAAA;AACF,2DAA2D;AAC3D,MAAM,MAAM,YAAY,GAAG,OAAO,YAAY,CAAC,IAAI,CAAA;AAEnD,uEAAuE;AACvE,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAGxB,CAAA;AACF,uEAAuE;AACvE,MAAM,MAAM,aAAa,GAAG,OAAO,aAAa,CAAC,IAAI,CAAA;AAErD,0FAA0F;AAC1F,eAAO,MAAM,UAAU;;;;;;;;;;;EAGrB,CAAA;AACF,uDAAuD;AACvD,MAAM,MAAM,UAAU,GAAG,OAAO,UAAU,CAAC,IAAI,CAAA"}
|
|
@@ -165,7 +165,7 @@ export const ResponseReplayed = ts('ResponseReplayed', {
|
|
|
165
165
|
});
|
|
166
166
|
/** Response confirming the runtime resumed normal execution. */
|
|
167
167
|
export const ResponseResumed = ts('ResponseResumed');
|
|
168
|
-
/** Response confirming a Message was dispatched. The `acceptedAtIndex` is the absolute history index where the entry is predicted to land. Computed from the runtime's history length at dispatch time. The
|
|
168
|
+
/** Response confirming a Message was dispatched. The `acceptedAtIndex` is the absolute history index where the entry is predicted to land. Computed from the runtime's history length at dispatch time. The runtime processes Messages in arrival order and the bridge is the only external dispatch source, so this index is reliable for correlation. */
|
|
169
169
|
export const ResponseDispatched = ts('ResponseDispatched', {
|
|
170
170
|
acceptedAtIndex: S.Number,
|
|
171
171
|
});
|
package/dist/devTools/store.js
CHANGED
|
@@ -160,8 +160,8 @@ export const createDevToolsStore = (bridge, options = {}) => Effect.gen(function
|
|
|
160
160
|
});
|
|
161
161
|
/** Attaches Mount lifecycle events from the most recent render to the
|
|
162
162
|
* history entry that triggered the render. Mount events fire during
|
|
163
|
-
* snabbdom's `patch
|
|
164
|
-
*
|
|
163
|
+
* snabbdom's `patch`, but render frames are scheduled through
|
|
164
|
+
* `requestAnimationFrame`, so a render may fire after the
|
|
165
165
|
* Message that dirtied it has already been recorded. The runtime drains
|
|
166
166
|
* its mount buffer after each render and calls this to associate the
|
|
167
167
|
* events with the correct entry. When called before any Message has been
|
|
@@ -11,7 +11,7 @@ type Hot = NonNullable<ImportMeta['hot']>;
|
|
|
11
11
|
* `EventDisconnected` on tab close or HMR module dispose so the relay can
|
|
12
12
|
* remove this runtime from its connected set.
|
|
13
13
|
*
|
|
14
|
-
* `dispatch`
|
|
14
|
+
* `dispatch` delivers a Message to the runtime; the bridge
|
|
15
15
|
* uses it to fulfill `RequestDispatchMessage` after decoding the payload
|
|
16
16
|
* against a JSON-canonical derivation of `maybeMessageSchema` (via
|
|
17
17
|
* `Schema.toCodecJson`). The derivation reconstructs runtime values like
|
|
@@ -29,7 +29,7 @@ const tryDeriveJsonSchemaDocument = (schema) => {
|
|
|
29
29
|
* `EventDisconnected` on tab close or HMR module dispose so the relay can
|
|
30
30
|
* remove this runtime from its connected set.
|
|
31
31
|
*
|
|
32
|
-
* `dispatch`
|
|
32
|
+
* `dispatch` delivers a Message to the runtime; the bridge
|
|
33
33
|
* uses it to fulfill `RequestDispatchMessage` after decoding the payload
|
|
34
34
|
* against a JSON-canonical derivation of `maybeMessageSchema` (via
|
|
35
35
|
* `Schema.toCodecJson`). The derivation reconstructs runtime values like
|
package/dist/html/index.d.ts
CHANGED
|
@@ -1070,7 +1070,7 @@ type ElementFunction<Message> = (attributes: ReadonlyArray<Attribute<Message> |
|
|
|
1070
1070
|
type VoidElementFunction<Message> = (attributes: ReadonlyArray<Attribute<Message> | ChildAttribute>) => Html;
|
|
1071
1071
|
declare const buildHtmlFactory: <Message>() => {
|
|
1072
1072
|
empty: null;
|
|
1073
|
-
keyed: (tagName: TagName) => (key:
|
|
1073
|
+
keyed: (tagName: TagName) => (key: PropertyKey, attributes?: readonly (Readonly<{
|
|
1074
1074
|
readonly attribute: unknown;
|
|
1075
1075
|
readonly dispatch: DispatchSync;
|
|
1076
1076
|
readonly resolveUnmount: (message: unknown) => () => void;
|
|
@@ -2154,23 +2154,23 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2154
2154
|
readonly _tag: "OnMouseMove";
|
|
2155
2155
|
readonly message: Message;
|
|
2156
2156
|
};
|
|
2157
|
-
OnPointerMove: (
|
|
2157
|
+
OnPointerMove: (toMaybeMessage: (screenX: number, screenY: number, pointerType: string) => Option.Option<Message>) => {
|
|
2158
2158
|
readonly _tag: "OnPointerMove";
|
|
2159
2159
|
readonly f: (screenX: number, screenY: number, pointerType: string) => Option.Option<Message>;
|
|
2160
2160
|
};
|
|
2161
|
-
OnPointerLeave: (
|
|
2161
|
+
OnPointerLeave: (toMaybeMessage: (pointerType: string) => Option.Option<Message>) => {
|
|
2162
2162
|
readonly _tag: "OnPointerLeave";
|
|
2163
2163
|
readonly f: (pointerType: string) => Option.Option<Message>;
|
|
2164
2164
|
};
|
|
2165
|
-
OnPointerDown: (
|
|
2165
|
+
OnPointerDown: (toMaybeMessage: (pointerType: string, button: number, screenX: number, screenY: number, timeStamp: number, clientX: number, clientY: number) => Option.Option<Message>) => {
|
|
2166
2166
|
readonly _tag: "OnPointerDown";
|
|
2167
2167
|
readonly f: (pointerType: string, button: number, screenX: number, screenY: number, timeStamp: number, clientX: number, clientY: number) => Option.Option<Message>;
|
|
2168
2168
|
};
|
|
2169
|
-
OnPointerUp: (
|
|
2169
|
+
OnPointerUp: (toMaybeMessage: (screenX: number, screenY: number, pointerType: string, timeStamp: number) => Option.Option<Message>) => {
|
|
2170
2170
|
readonly _tag: "OnPointerUp";
|
|
2171
2171
|
readonly f: (screenX: number, screenY: number, pointerType: string, timeStamp: number) => Option.Option<Message>;
|
|
2172
2172
|
};
|
|
2173
|
-
OnKeyDown: (
|
|
2173
|
+
OnKeyDown: (toMessage: (key: string, modifiers: Readonly<{
|
|
2174
2174
|
shiftKey: boolean;
|
|
2175
2175
|
ctrlKey: boolean;
|
|
2176
2176
|
altKey: boolean;
|
|
@@ -2184,7 +2184,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2184
2184
|
metaKey: boolean;
|
|
2185
2185
|
}>) => Message;
|
|
2186
2186
|
};
|
|
2187
|
-
OnKeyDownFocus: (
|
|
2187
|
+
OnKeyDownFocus: (toMaybeFocusAndMessage: (key: string, modifiers: Readonly<{
|
|
2188
2188
|
shiftKey: boolean;
|
|
2189
2189
|
ctrlKey: boolean;
|
|
2190
2190
|
altKey: boolean;
|
|
@@ -2204,7 +2204,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2204
2204
|
message: Message;
|
|
2205
2205
|
}>>;
|
|
2206
2206
|
};
|
|
2207
|
-
OnKeyDownPreventDefault: (
|
|
2207
|
+
OnKeyDownPreventDefault: (toMaybeMessage: (key: string, modifiers: Readonly<{
|
|
2208
2208
|
shiftKey: boolean;
|
|
2209
2209
|
ctrlKey: boolean;
|
|
2210
2210
|
altKey: boolean;
|
|
@@ -2218,7 +2218,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2218
2218
|
metaKey: boolean;
|
|
2219
2219
|
}>) => Option.Option<Message>;
|
|
2220
2220
|
};
|
|
2221
|
-
OnKeyUp: (
|
|
2221
|
+
OnKeyUp: (toMessage: (key: string, modifiers: Readonly<{
|
|
2222
2222
|
shiftKey: boolean;
|
|
2223
2223
|
ctrlKey: boolean;
|
|
2224
2224
|
altKey: boolean;
|
|
@@ -2232,7 +2232,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2232
2232
|
metaKey: boolean;
|
|
2233
2233
|
}>) => Message;
|
|
2234
2234
|
};
|
|
2235
|
-
OnKeyUpPreventDefault: (
|
|
2235
|
+
OnKeyUpPreventDefault: (toMaybeMessage: (key: string, modifiers: Readonly<{
|
|
2236
2236
|
shiftKey: boolean;
|
|
2237
2237
|
ctrlKey: boolean;
|
|
2238
2238
|
altKey: boolean;
|
|
@@ -2246,7 +2246,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2246
2246
|
metaKey: boolean;
|
|
2247
2247
|
}>) => Option.Option<Message>;
|
|
2248
2248
|
};
|
|
2249
|
-
OnKeyPress: (
|
|
2249
|
+
OnKeyPress: (toMessage: (key: string, modifiers: Readonly<{
|
|
2250
2250
|
shiftKey: boolean;
|
|
2251
2251
|
ctrlKey: boolean;
|
|
2252
2252
|
altKey: boolean;
|
|
@@ -2268,15 +2268,15 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2268
2268
|
readonly _tag: "OnBlur";
|
|
2269
2269
|
readonly message: Message;
|
|
2270
2270
|
};
|
|
2271
|
-
OnInput: (
|
|
2271
|
+
OnInput: (toMessage: (value: string) => Message) => {
|
|
2272
2272
|
readonly _tag: "OnInput";
|
|
2273
2273
|
readonly f: (value: string) => Message;
|
|
2274
2274
|
};
|
|
2275
|
-
OnChange: (
|
|
2275
|
+
OnChange: (toMessage: (value: string) => Message) => {
|
|
2276
2276
|
readonly _tag: "OnChange";
|
|
2277
2277
|
readonly f: (value: string) => Message;
|
|
2278
2278
|
};
|
|
2279
|
-
OnFileChange: (
|
|
2279
|
+
OnFileChange: (toMessage: (files: ReadonlyArray<File>) => Message) => {
|
|
2280
2280
|
readonly _tag: "OnFileChange";
|
|
2281
2281
|
readonly f: (files: ReadonlyArray<File>) => Message;
|
|
2282
2282
|
};
|
|
@@ -2288,7 +2288,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2288
2288
|
readonly _tag: "OnReset";
|
|
2289
2289
|
readonly message: Message;
|
|
2290
2290
|
};
|
|
2291
|
-
OnScroll: (
|
|
2291
|
+
OnScroll: (toMessage: (scrollTop: number) => Message) => {
|
|
2292
2292
|
readonly _tag: "OnScroll";
|
|
2293
2293
|
readonly f: (scrollTop: number) => Message;
|
|
2294
2294
|
};
|
|
@@ -2308,7 +2308,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2308
2308
|
readonly _tag: "OnPaste";
|
|
2309
2309
|
readonly message: Message;
|
|
2310
2310
|
};
|
|
2311
|
-
OnPastePreventDefault: (
|
|
2311
|
+
OnPastePreventDefault: (toMaybeMessage: (text: string) => Option.Option<Message>) => {
|
|
2312
2312
|
readonly _tag: "OnPastePreventDefault";
|
|
2313
2313
|
readonly f: (text: string) => Option.Option<Message>;
|
|
2314
2314
|
};
|
|
@@ -2325,7 +2325,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2325
2325
|
readonly _tag: "OnCancel";
|
|
2326
2326
|
readonly message: Message;
|
|
2327
2327
|
};
|
|
2328
|
-
OnToggle: (
|
|
2328
|
+
OnToggle: (toMessage: (isOpen: boolean) => Message) => {
|
|
2329
2329
|
readonly _tag: "OnToggle";
|
|
2330
2330
|
readonly f: (isOpen: boolean) => Message;
|
|
2331
2331
|
};
|
|
@@ -2364,7 +2364,7 @@ declare const buildHtmlFactory: <Message>() => {
|
|
|
2364
2364
|
readonly _tag: "OnDrop";
|
|
2365
2365
|
readonly message: Message;
|
|
2366
2366
|
};
|
|
2367
|
-
OnDropFiles: (
|
|
2367
|
+
OnDropFiles: (toMessage: (files: ReadonlyArray<File>) => Message) => {
|
|
2368
2368
|
readonly _tag: "OnDropFiles";
|
|
2369
2369
|
readonly f: (files: ReadonlyArray<File>) => Message;
|
|
2370
2370
|
};
|