incajs 0.0.19 → 0.0.20

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.
@@ -1,4 +1,4 @@
1
- import { A as e, C as t, M as n, O as r, P as i, S as a, T as o, _ as s, a as c, b as l, g as u, h as d, k as f, l as p, o as m, v as h } from "./hooks-COUJ5IPe.js";
1
+ import { A as e, C as t, M as n, O as r, P as i, S as a, T as o, _ as s, a as c, b as l, g as u, h as d, k as f, l as p, o as m, v as h } from "./hooks-D1NFQN8Q.js";
2
2
  //#region src/element/eventHandlers.mts
3
3
  var g = [
4
4
  "auxclick",
@@ -124,12 +124,12 @@ function T(r, c, u) {
124
124
  parent: null,
125
125
  children: [],
126
126
  focus: (e) => {
127
- if (f(T)) return;
128
- let t = e?.preventScroll;
129
- t === void 0 ? o(r) : o(r, !!t);
127
+ f(T) || o(r, !!e?.preventScroll);
130
128
  },
131
129
  blur: () => a(r),
132
- click: () => t(r),
130
+ click: () => {
131
+ f(T) || t(r);
132
+ },
133
133
  contains: (t) => {
134
134
  if (t == null) return !1;
135
135
  if (!e(t)) throw TypeError("the value is not a node. pass an element, a text node or null");
@@ -112,7 +112,7 @@ function k(t) {
112
112
  e().click(t);
113
113
  }
114
114
  function A(t, n) {
115
- n === void 0 ? e().focusNode(t) : e().focusNode(t, n);
115
+ e().focusNode(t, n);
116
116
  }
117
117
  function j(t) {
118
118
  e().blurNode(t);
@@ -1,5 +1,5 @@
1
- import { C as e, D as t, E as n, N as r, P as i, S as a, T as o, _ as s, a as c, b as l, c as u, d, f, g as p, h as m, i as h, j as g, k as _, l as v, m as y, n as b, o as x, p as S, r as C, s as w, t as T, u as E, v as D, w as O, x as k, y as A } from "./hooks-COUJ5IPe.js";
2
- import { n as j } from "./handle-C_4KtGsE.js";
1
+ import { C as e, D as t, E as n, N as r, P as i, S as a, T as o, _ as s, a as c, b as l, c as u, d, f, g as p, h as m, i as h, j as g, k as _, l as v, m as y, n as b, o as x, p as S, r as C, s as w, t as T, u as E, v as D, w as O, x as k, y as A } from "./hooks-D1NFQN8Q.js";
2
+ import { n as j } from "./handle-DdYIkUcm.js";
3
3
  //#region \0rolldown/runtime.js
4
4
  var M = Object.defineProperty, N = (e, t) => {
5
5
  let n = {};
@@ -48,8 +48,9 @@ export interface IncaElement extends IncaEventTarget, EventHandlers {
48
48
  /** Unfocuses this node next frame, if it is the focused one. */
49
49
  blur(): void;
50
50
  /**
51
- * Fires an untrusted `click` at this node. A disabled `button`, a node whose
52
- * own click is still running and an unknown node ignore the call.
51
+ * Fires an untrusted `click` at this node. A disabled `button` and a node
52
+ * whose own click is still running ignore the call. After the node is
53
+ * removed, the call does nothing.
53
54
  */
54
55
  click(): void;
55
56
  /**
package/dist/events.d.mts CHANGED
@@ -46,10 +46,11 @@ export declare function removeEventListener(nodeId: NodeId, event: string, liste
46
46
  */
47
47
  export declare function dispatchEvent(nodeId: NodeId, event: EventLike): boolean;
48
48
  /**
49
- * Fires an untrusted `click` at `nodeId`. A disabled `button`, a node whose
50
- * own click is still running and an unknown node ignore the call.
49
+ * Fires an untrusted `click` at `nodeId`. A disabled `button` and a node whose
50
+ * own click is still running ignore the call.
51
51
  * @param nodeId - the node to click
52
52
  * @throws TypeError when `nodeId` is malformed
53
+ * @throws TypeError when `nodeId` names no node
53
54
  */
54
55
  export declare function click(nodeId: NodeId): void;
55
56
  /**
@@ -59,6 +60,8 @@ export declare function click(nodeId: NodeId): void;
59
60
  * is optional. The scroll containers around the node scroll it into view.
60
61
  * @param nodeId - the node to focus
61
62
  * @param preventScroll - `true` to leave the scroll containers in place; omitted or `false` scrolls the node into view
63
+ * @throws TypeError when `nodeId` is malformed
64
+ * @throws TypeError when `nodeId` names no node
62
65
  */
63
66
  export declare function focus(nodeId: NodeId, preventScroll?: boolean): void;
64
67
  /**
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- import { t as e } from "./chunks/hooks-COUJ5IPe.js";
2
- import { t } from "./chunks/handle-C_4KtGsE.js";
1
+ import { t as e } from "./chunks/hooks-D1NFQN8Q.js";
2
+ import { t } from "./chunks/handle-DdYIkUcm.js";
3
3
  export { t as activeElement, e as window };
@@ -1,4 +1,4 @@
1
- import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, u as c } from "./chunks/rendererCore-Bu6a8hAp.js";
2
- import { C as l, D as u, E as d, N as f, S as p, T as m, _ as h, a as g, b as _, c as v, d as y, f as b, g as x, h as S, i as C, k as w, l as T, m as E, n as D, o as O, p as k, r as A, s as j, t as M, u as N, v as P, w as F, x as I, y as L } from "./chunks/hooks-COUJ5IPe.js";
3
- import { n as R } from "./chunks/handle-C_4KtGsE.js";
1
+ import { a as e, c as t, i as n, l as r, n as i, o as a, r as o, s, u as c } from "./chunks/rendererCore-NnTAUL80.js";
2
+ import { C as l, D as u, E as d, N as f, S as p, T as m, _ as h, a as g, b as _, c as v, d as y, f as b, g as x, h as S, i as C, k as w, l as T, m as E, n as D, o as O, p as k, r as A, s as j, t as M, u as N, v as P, w as F, x as I, y as L } from "./chunks/hooks-D1NFQN8Q.js";
3
+ import { n as R } from "./chunks/handle-DdYIkUcm.js";
4
4
  export { I as addEventListener, D as appendChild, p as blur, l as click, i as createCommentNode, o as createElementNode, _ as createEventTarget, R as createIncaElement, A as createNode, n as createTextNode, C as destroyNode, F as dispatchEvent, m as focus, g as focusedNode, O as getAttribute, j as holdNode, e as insert, v as insertBefore, w as isDestroyed, d as latestEventId, T as layoutOf, a as nextSibling, s as parentNode, N as releaseNode, f as releaseWhenCollected, t as remove, y as removeAttribute, b as removeChild, u as removeEventListener, k as removeStyle, E as rootNodeId, S as scrollIntoViewNode, x as scrollNode, h as scrollOf, P as setAttribute, r as setElementText, L as setStyle, c as setText, M as window };
@@ -66,12 +66,13 @@ import { IncaCore, IncaElement } from '../rendererCore.mts';
66
66
  * ### Other props
67
67
  *
68
68
  * A string, number or boolean `nextValue` goes to `core.setAttribute` as it
69
- * is. A `disabled`, `hidden` or `inert` set to `false` goes to
70
- * `core.removeAttribute`, as does a `null` or `undefined` `nextValue`, which
71
- * includes a prop that is absent from the new vnode. Any other value (an
72
- * object, array, function or symbol) goes to `core.setAttribute` as
73
- * `String(nextValue)`. An `onUpdate:` key is a component event and sets
74
- * nothing.
69
+ * is. A `null` or `undefined` `nextValue` goes to `core.removeAttribute`,
70
+ * which includes a prop that is absent from the new vnode. So does any falsy
71
+ * value other than `""` for a boolean attribute: `disabled`, `hidden`,
72
+ * `inert`, and the names Vue treats as boolean attributes, such as
73
+ * `readonly`. Any other value (an object, array, function or symbol) goes to
74
+ * `core.setAttribute` as `String(nextValue)`. An `onUpdate:` key is a
75
+ * component event and sets nothing.
75
76
  *
76
77
  * @param core - the incajs bindings to drive the native tree through
77
78
  */
package/dist/vue.js CHANGED
@@ -1,6 +1,6 @@
1
- import { t as e } from "./chunks/rendererCore-Bu6a8hAp.js";
2
- import { m as t } from "./chunks/hooks-COUJ5IPe.js";
3
- import { n } from "./chunks/handle-C_4KtGsE.js";
1
+ import { t as e } from "./chunks/rendererCore-NnTAUL80.js";
2
+ import { m as t } from "./chunks/hooks-D1NFQN8Q.js";
3
+ import { n } from "./chunks/handle-DdYIkUcm.js";
4
4
  import { ErrorCodes as r, callWithAsyncErrorHandling as i, createRenderer as a, warn as o } from "@vue/runtime-core";
5
5
  //#region src/vue/nodeOps.mts
6
6
  function s(e) {
@@ -141,11 +141,18 @@ function E(e, t, n, r, i) {
141
141
  var D = /* @__PURE__ */ new Set([
142
142
  "disabled",
143
143
  "hidden",
144
- "inert"
144
+ "inert",
145
+ "allowfullscreen",
146
+ "formnovalidate",
147
+ "ismap",
148
+ "itemscope",
149
+ "nomodule",
150
+ "novalidate",
151
+ "readonly"
145
152
  ]);
146
153
  function O(e) {
147
154
  return (t, n, r, i, a, o) => {
148
- n.startsWith("onUpdate:") || (n === "style" ? v(e, t, i) : u(n) ? E(e, t, n, i, o ?? null) : d(n) && n in t ? typeof i == "string" ? (Reflect.set(t, n, null), e.setAttribute(t.__node_id, n, i)) : Reflect.set(t, n, i) : D.has(n) && i === !1 ? e.removeAttribute(t.__node_id, n) : typeof i == "string" || typeof i == "number" || typeof i == "boolean" ? e.setAttribute(t.__node_id, n, i) : i == null ? e.removeAttribute(t.__node_id, n) : e.setAttribute(t.__node_id, n, String(i)));
155
+ n.startsWith("onUpdate:") || (n === "style" ? v(e, t, i) : u(n) ? E(e, t, n, i, o ?? null) : d(n) && n in t ? typeof i == "string" ? (Reflect.set(t, n, null), e.setAttribute(t.__node_id, n, i)) : Reflect.set(t, n, i) : D.has(n) && !i && i !== "" ? e.removeAttribute(t.__node_id, n) : typeof i == "string" || typeof i == "number" || typeof i == "boolean" ? e.setAttribute(t.__node_id, n, i) : i == null ? e.removeAttribute(t.__node_id, n) : e.setAttribute(t.__node_id, n, String(i)));
149
156
  };
150
157
  }
151
158
  //#endregion
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "incajs",
3
- "version": "0.0.19",
3
+ "version": "0.0.20",
4
4
  "description": "A GPU-native, Webview-free desktop app framework built on GPUI and QuickJS.",
5
5
  "keywords": [
6
6
  "cross-platform",