@vibecook/ice 0.15.0 → 0.16.0-portals.2
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/dist/{chunk-644DO6PN.js → chunk-K4SKRVLK.js} +2 -2
- package/dist/chunk-K4SKRVLK.js.map +1 -0
- package/dist/{chunk-A6PUTIL7.js → chunk-KV6RMWG4.js} +142 -8
- package/dist/chunk-KV6RMWG4.js.map +1 -0
- package/dist/{chunk-US7WJNR6.js → chunk-NB4ALBIY.js} +349 -66
- package/dist/chunk-NB4ALBIY.js.map +1 -0
- package/dist/{chunk-SPG45AVV.js → chunk-SHU3HVMF.js} +72 -12
- package/dist/chunk-SHU3HVMF.js.map +1 -0
- package/dist/desk-kit.js +14 -2
- package/dist/desk-objects.js +3 -3
- package/dist/desk.js +15 -3
- package/dist/devtools.js +1 -1
- package/dist/dom.js +2 -2
- package/dist/index.js +5 -3
- package/dist/react.js +20 -5
- package/dist/react.js.map +1 -1
- package/dist/types/packages/core/src/catalog/desk.d.ts +36 -1
- package/dist/types/packages/core/src/catalog/selection-presence.d.ts +0 -10
- package/dist/types/packages/core/src/systems/held.d.ts +10 -3
- package/dist/types/packages/core/src/systems/l4-cursor.d.ts +9 -2
- package/dist/types/packages/core/src/widget/define-widget.d.ts +16 -22
- package/dist/types/packages/desk/src/hold/told.d.ts +15 -0
- package/dist/types/packages/desk/src/index.d.ts +1 -1
- package/dist/types/packages/desk/src/kind.d.ts +5 -1
- package/dist/types/packages/desk/src/kinds/world.d.ts +93 -2
- package/dist/types/packages/desk/src/kit/editor.d.ts +9 -1
- package/dist/types/packages/desk/src/kit/index.d.ts +1 -0
- package/dist/types/packages/desk/src/kit/live.d.ts +260 -0
- package/dist/types/packages/desk/src/kit/mips.d.ts +11 -0
- package/dist/types/packages/desk/src/kit/wgsl.d.ts +5 -2
- package/dist/types/packages/desk/src/object.d.ts +1 -1
- package/dist/types/packages/desk/src/still.d.ts +3 -1
- package/dist/types/packages/dom/src/input-ownership.d.ts +5 -3
- package/dist/types/packages/dom/src/widget-focus.d.ts +2 -2
- package/dist/types/packages/objects/src/minimat/layout.d.ts +1 -1
- package/dist/types/packages/react/src/keymap.d.ts +9 -3
- package/package.json +1 -1
- package/dist/chunk-644DO6PN.js.map +0 -1
- package/dist/chunk-A6PUTIL7.js.map +0 -1
- package/dist/chunk-SPG45AVV.js.map +0 -1
- package/dist/chunk-US7WJNR6.js.map +0 -1
package/dist/desk-kit.js
CHANGED
|
@@ -14,6 +14,7 @@ import {
|
|
|
14
14
|
KIT_WGSL_FILES,
|
|
15
15
|
LAYER_COMPOSITE_FILE,
|
|
16
16
|
LAYER_IDLE_MS,
|
|
17
|
+
LIVE,
|
|
17
18
|
LayerArray,
|
|
18
19
|
LayeredKind,
|
|
19
20
|
Layers,
|
|
@@ -48,8 +49,10 @@ import {
|
|
|
48
49
|
chainBytes,
|
|
49
50
|
clip,
|
|
50
51
|
clipOf,
|
|
52
|
+
createLiveTexture,
|
|
51
53
|
createMemoryBlobStore,
|
|
52
54
|
createServices,
|
|
55
|
+
createSight,
|
|
53
56
|
decodePoints,
|
|
54
57
|
decodeSeeds,
|
|
55
58
|
decodeTimes,
|
|
@@ -86,10 +89,12 @@ import {
|
|
|
86
89
|
lineWeight,
|
|
87
90
|
linear,
|
|
88
91
|
litByOwn,
|
|
92
|
+
liveDepth,
|
|
89
93
|
lod,
|
|
90
94
|
matrixOf,
|
|
91
95
|
meanSpeed,
|
|
92
96
|
mipCount,
|
|
97
|
+
mipsInto,
|
|
93
98
|
outgoingCamera,
|
|
94
99
|
paperTexture,
|
|
95
100
|
plainFormat,
|
|
@@ -108,6 +113,7 @@ import {
|
|
|
108
113
|
settled,
|
|
109
114
|
shaderText,
|
|
110
115
|
spring,
|
|
116
|
+
stillLive,
|
|
111
117
|
strokeRow,
|
|
112
118
|
strokeSeed,
|
|
113
119
|
tailBase,
|
|
@@ -117,9 +123,9 @@ import {
|
|
|
117
123
|
visibleRect,
|
|
118
124
|
worldBounds,
|
|
119
125
|
writeChanged
|
|
120
|
-
} from "./chunk-
|
|
126
|
+
} from "./chunk-NB4ALBIY.js";
|
|
121
127
|
import "./chunk-RTBW5AIZ.js";
|
|
122
|
-
import "./chunk-
|
|
128
|
+
import "./chunk-SHU3HVMF.js";
|
|
123
129
|
import "./chunk-RE4GDHFJ.js";
|
|
124
130
|
export {
|
|
125
131
|
BLOB_STORE,
|
|
@@ -137,6 +143,7 @@ export {
|
|
|
137
143
|
KIT_WGSL_FILES,
|
|
138
144
|
LAYER_COMPOSITE_FILE,
|
|
139
145
|
LAYER_IDLE_MS,
|
|
146
|
+
LIVE,
|
|
140
147
|
LayerArray,
|
|
141
148
|
LayeredKind,
|
|
142
149
|
Layers,
|
|
@@ -171,8 +178,10 @@ export {
|
|
|
171
178
|
chainBytes,
|
|
172
179
|
clip,
|
|
173
180
|
clipOf,
|
|
181
|
+
createLiveTexture,
|
|
174
182
|
createMemoryBlobStore,
|
|
175
183
|
createServices,
|
|
184
|
+
createSight,
|
|
176
185
|
decodePoints,
|
|
177
186
|
decodeSeeds,
|
|
178
187
|
decodeTimes,
|
|
@@ -209,10 +218,12 @@ export {
|
|
|
209
218
|
lineWeight,
|
|
210
219
|
linear,
|
|
211
220
|
litByOwn,
|
|
221
|
+
liveDepth,
|
|
212
222
|
lod,
|
|
213
223
|
matrixOf,
|
|
214
224
|
meanSpeed,
|
|
215
225
|
mipCount,
|
|
226
|
+
mipsInto,
|
|
216
227
|
outgoingCamera,
|
|
217
228
|
paperTexture,
|
|
218
229
|
plainFormat,
|
|
@@ -231,6 +242,7 @@ export {
|
|
|
231
242
|
settled,
|
|
232
243
|
shaderText,
|
|
233
244
|
spring,
|
|
245
|
+
stillLive,
|
|
234
246
|
strokeRow,
|
|
235
247
|
strokeSeed,
|
|
236
248
|
tailBase,
|
package/dist/desk-objects.js
CHANGED
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
rasterPriority,
|
|
9
9
|
stringProp,
|
|
10
10
|
writable
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-KV6RMWG4.js";
|
|
12
12
|
import "./chunk-BKV4ZEU3.js";
|
|
13
13
|
import {
|
|
14
14
|
compile,
|
|
@@ -110,7 +110,7 @@ import {
|
|
|
110
110
|
unproject,
|
|
111
111
|
worldBounds,
|
|
112
112
|
writeChanged
|
|
113
|
-
} from "./chunk-
|
|
113
|
+
} from "./chunk-NB4ALBIY.js";
|
|
114
114
|
import {
|
|
115
115
|
bindGroup,
|
|
116
116
|
bindLayout,
|
|
@@ -170,7 +170,7 @@ import {
|
|
|
170
170
|
setWidgetProps,
|
|
171
171
|
tools,
|
|
172
172
|
trayOpen
|
|
173
|
-
} from "./chunk-
|
|
173
|
+
} from "./chunk-SHU3HVMF.js";
|
|
174
174
|
import {
|
|
175
175
|
clientToScreen
|
|
176
176
|
} from "./chunk-RE4GDHFJ.js";
|
package/dist/desk.js
CHANGED
|
@@ -99,7 +99,7 @@ import {
|
|
|
99
99
|
withKindActs,
|
|
100
100
|
withoutKind,
|
|
101
101
|
writable
|
|
102
|
-
} from "./chunk-
|
|
102
|
+
} from "./chunk-KV6RMWG4.js";
|
|
103
103
|
import "./chunk-ENIFIUEP.js";
|
|
104
104
|
import {
|
|
105
105
|
BLOB_STORE,
|
|
@@ -122,6 +122,7 @@ import {
|
|
|
122
122
|
KIT_WGSL_FILES,
|
|
123
123
|
LAYER_COMPOSITE_FILE,
|
|
124
124
|
LAYER_IDLE_MS,
|
|
125
|
+
LIVE,
|
|
125
126
|
LayerArray,
|
|
126
127
|
LayeredKind,
|
|
127
128
|
Layers,
|
|
@@ -168,8 +169,10 @@ import {
|
|
|
168
169
|
chainBytes,
|
|
169
170
|
clip,
|
|
170
171
|
clipOf,
|
|
172
|
+
createLiveTexture,
|
|
171
173
|
createMemoryBlobStore,
|
|
172
174
|
createServices,
|
|
175
|
+
createSight,
|
|
173
176
|
cssColor,
|
|
174
177
|
dayLuminance,
|
|
175
178
|
decodePoints,
|
|
@@ -214,10 +217,12 @@ import {
|
|
|
214
217
|
lineWeight,
|
|
215
218
|
linear,
|
|
216
219
|
litByOwn,
|
|
220
|
+
liveDepth,
|
|
217
221
|
lod,
|
|
218
222
|
matrixOf,
|
|
219
223
|
meanSpeed,
|
|
220
224
|
mipCount,
|
|
225
|
+
mipsInto,
|
|
221
226
|
nightLight,
|
|
222
227
|
outgoingCamera,
|
|
223
228
|
paperTexture,
|
|
@@ -238,6 +243,7 @@ import {
|
|
|
238
243
|
settled,
|
|
239
244
|
shaderText,
|
|
240
245
|
spring,
|
|
246
|
+
stillLive,
|
|
241
247
|
strokeRow,
|
|
242
248
|
strokeSeed,
|
|
243
249
|
tailBase,
|
|
@@ -248,9 +254,9 @@ import {
|
|
|
248
254
|
visibleRect,
|
|
249
255
|
worldBounds,
|
|
250
256
|
writeChanged
|
|
251
|
-
} from "./chunk-
|
|
257
|
+
} from "./chunk-NB4ALBIY.js";
|
|
252
258
|
import "./chunk-RTBW5AIZ.js";
|
|
253
|
-
import "./chunk-
|
|
259
|
+
import "./chunk-SHU3HVMF.js";
|
|
254
260
|
import "./chunk-RE4GDHFJ.js";
|
|
255
261
|
export {
|
|
256
262
|
AMBIENT_DEFAULTS,
|
|
@@ -284,6 +290,7 @@ export {
|
|
|
284
290
|
KIT_WGSL_FILES,
|
|
285
291
|
LAYER_COMPOSITE_FILE,
|
|
286
292
|
LAYER_IDLE_MS,
|
|
293
|
+
LIVE,
|
|
287
294
|
LayerArray,
|
|
288
295
|
LayeredKind,
|
|
289
296
|
Layers,
|
|
@@ -358,6 +365,7 @@ export {
|
|
|
358
365
|
createGpuProfiler,
|
|
359
366
|
createKindFaults,
|
|
360
367
|
createKindPasses,
|
|
368
|
+
createLiveTexture,
|
|
361
369
|
createMarksCollector,
|
|
362
370
|
createMemoryBlobStore,
|
|
363
371
|
createPickSource,
|
|
@@ -365,6 +373,7 @@ export {
|
|
|
365
373
|
createRasterQueue,
|
|
366
374
|
createRecordStore,
|
|
367
375
|
createServices,
|
|
376
|
+
createSight,
|
|
368
377
|
createSlotSet,
|
|
369
378
|
createStill,
|
|
370
379
|
cssColor,
|
|
@@ -433,12 +442,14 @@ export {
|
|
|
433
442
|
lineWeight,
|
|
434
443
|
linear,
|
|
435
444
|
litByOwn,
|
|
445
|
+
liveDepth,
|
|
436
446
|
lod,
|
|
437
447
|
marksShaders,
|
|
438
448
|
matrixOf,
|
|
439
449
|
meanSpeed,
|
|
440
450
|
menuSlots,
|
|
441
451
|
mipCount,
|
|
452
|
+
mipsInto,
|
|
442
453
|
missingFace,
|
|
443
454
|
nightLight,
|
|
444
455
|
numberProp,
|
|
@@ -477,6 +488,7 @@ export {
|
|
|
477
488
|
slideEase,
|
|
478
489
|
spanOf,
|
|
479
490
|
spring,
|
|
491
|
+
stillLive,
|
|
480
492
|
stringProp,
|
|
481
493
|
strokeRow,
|
|
482
494
|
strokeSeed,
|
package/dist/devtools.js
CHANGED
package/dist/dom.js
CHANGED
|
@@ -13,8 +13,8 @@ import {
|
|
|
13
13
|
keyboardClaimOf,
|
|
14
14
|
startRafLoop,
|
|
15
15
|
wheelCede
|
|
16
|
-
} from "./chunk-
|
|
17
|
-
import "./chunk-
|
|
16
|
+
} from "./chunk-K4SKRVLK.js";
|
|
17
|
+
import "./chunk-SHU3HVMF.js";
|
|
18
18
|
import "./chunk-RE4GDHFJ.js";
|
|
19
19
|
export {
|
|
20
20
|
CLAIM_OWNS_ESCAPE,
|
package/dist/index.js
CHANGED
|
@@ -80,12 +80,13 @@ import {
|
|
|
80
80
|
HeldMute,
|
|
81
81
|
HeldPointer,
|
|
82
82
|
HeldPress,
|
|
83
|
+
HeldPressMemo,
|
|
83
84
|
HeldTapMemo,
|
|
84
85
|
HeldTool,
|
|
85
86
|
HeldView,
|
|
87
|
+
HeldWheel,
|
|
86
88
|
InsertGhost,
|
|
87
89
|
Keyboard,
|
|
88
|
-
KeyboardExclusive,
|
|
89
90
|
LeavesCopy,
|
|
90
91
|
Local,
|
|
91
92
|
LocalPointer,
|
|
@@ -392,7 +393,7 @@ import {
|
|
|
392
393
|
widgetTypeFor,
|
|
393
394
|
widgets,
|
|
394
395
|
writeRuntimeResource
|
|
395
|
-
} from "./chunk-
|
|
396
|
+
} from "./chunk-SHU3HVMF.js";
|
|
396
397
|
import "./chunk-RE4GDHFJ.js";
|
|
397
398
|
export {
|
|
398
399
|
Accepts,
|
|
@@ -476,12 +477,13 @@ export {
|
|
|
476
477
|
HeldMute,
|
|
477
478
|
HeldPointer,
|
|
478
479
|
HeldPress,
|
|
480
|
+
HeldPressMemo,
|
|
479
481
|
HeldTapMemo,
|
|
480
482
|
HeldTool,
|
|
481
483
|
HeldView,
|
|
484
|
+
HeldWheel,
|
|
482
485
|
InsertGhost,
|
|
483
486
|
Keyboard,
|
|
484
|
-
KeyboardExclusive,
|
|
485
487
|
LeavesCopy,
|
|
486
488
|
Local,
|
|
487
489
|
LocalPointer,
|
package/dist/react.js
CHANGED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
createDeskHost,
|
|
3
3
|
isEditableTarget,
|
|
4
4
|
keyboardClaimOf
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-K4SKRVLK.js";
|
|
6
6
|
import {
|
|
7
7
|
ActiveTool,
|
|
8
8
|
Container,
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
tools,
|
|
29
29
|
trayOpen,
|
|
30
30
|
widgets
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-SHU3HVMF.js";
|
|
32
32
|
import "./chunk-RE4GDHFJ.js";
|
|
33
33
|
|
|
34
34
|
// ../react/src/hooks.ts
|
|
@@ -326,14 +326,21 @@ function openOrEnterSelected(engine) {
|
|
|
326
326
|
if (!world.hasTag(target, Container)) return;
|
|
327
327
|
engine.ops.enterContainer(target);
|
|
328
328
|
}
|
|
329
|
+
function heldEscape(engine) {
|
|
330
|
+
const held = heldEntity(engine.world);
|
|
331
|
+
if (held === void 0) return void 0;
|
|
332
|
+
const typeId = engine.world.get(held, PrefabId)?.id;
|
|
333
|
+
return typeof typeId === "string" ? engine.catalog.widget(typeId)?.heldEscape ?? "desk" : "desk";
|
|
334
|
+
}
|
|
329
335
|
function escapeOrExit(engine) {
|
|
330
336
|
const { world } = engine;
|
|
331
337
|
if (trayOpen(world)) {
|
|
332
338
|
closeTray(world);
|
|
333
339
|
return;
|
|
334
340
|
}
|
|
335
|
-
|
|
336
|
-
|
|
341
|
+
const hand = heldEscape(engine);
|
|
342
|
+
if (hand !== void 0) {
|
|
343
|
+
if (hand === "desk") engine.ops.putDown();
|
|
337
344
|
return;
|
|
338
345
|
}
|
|
339
346
|
const gestureLive = world.firstOf(gestureActiveQ) !== void 0;
|
|
@@ -439,9 +446,12 @@ function attachKeymap(engine, target, overrides = []) {
|
|
|
439
446
|
const claim = keyboardClaimOf(event.target);
|
|
440
447
|
if (claim.claimed) {
|
|
441
448
|
if (event.key === "Escape" && !claim.ownsEscape) {
|
|
449
|
+
const hand = heldEscape(engine);
|
|
450
|
+
if (hand === "kind") return;
|
|
442
451
|
event.preventDefault();
|
|
443
452
|
const t = event.target;
|
|
444
453
|
if (t instanceof HTMLElement || t instanceof SVGElement) t.blur();
|
|
454
|
+
if (hand === "desk") engine.ops.putDown();
|
|
445
455
|
}
|
|
446
456
|
return;
|
|
447
457
|
}
|
|
@@ -758,7 +768,7 @@ function SelectionMenu({ source, actions, engine: given }) {
|
|
|
758
768
|
t.id
|
|
759
769
|
);
|
|
760
770
|
};
|
|
761
|
-
const done = /* @__PURE__ */ jsxs("button", { type: "button", className: "ice-sm-text", "data-act": "done", "aria-label": "Done", title: "Done (Esc)", onClick: () => {
|
|
771
|
+
const done = /* @__PURE__ */ jsxs("button", { type: "button", className: "ice-sm-text", "data-act": "done", "aria-label": "Done", title: escapeOwned(engine) ? "Done" : "Done (Esc)", onClick: () => {
|
|
762
772
|
setOpen(false);
|
|
763
773
|
engine.ops.putDown();
|
|
764
774
|
}, children: [
|
|
@@ -810,6 +820,11 @@ function SelectionMenu({ source, actions, engine: given }) {
|
|
|
810
820
|
}
|
|
811
821
|
);
|
|
812
822
|
}
|
|
823
|
+
function escapeOwned(engine) {
|
|
824
|
+
const held = heldEntity(engine.world);
|
|
825
|
+
const typeId = held === void 0 ? void 0 : engine.world.get(held, PrefabId)?.id;
|
|
826
|
+
return typeof typeId === "string" && engine.catalog.widget(typeId)?.heldEscape === "kind";
|
|
827
|
+
}
|
|
813
828
|
function useOptionalEngine() {
|
|
814
829
|
try {
|
|
815
830
|
return useCanvasEngine();
|