@vinena/knobs 0.6.5 → 0.7.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.
Files changed (48) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/README.md +11 -5
  3. package/THIRD_PARTY_NOTICES.md +3 -3
  4. package/dist/cli.d.ts +95 -0
  5. package/dist/cli.js +527 -0
  6. package/dist/{context-amfyasb5.js → context-eawqn680.js} +1 -1
  7. package/dist/{context-svtr7vwt.js → context-vd2xep5t.js} +1 -1
  8. package/dist/edit/keep.d.ts +1 -1
  9. package/dist/{elementsview-s5vj51vh.js → elementsview-jg4edt86.js} +7 -7
  10. package/dist/{elementsview-swft4xar.js → elementsview-m33ejs4r.js} +7 -7
  11. package/dist/engine/pageshot.d.ts +25 -0
  12. package/dist/{framekit-q97zeg1d.js → framekit-40pzennw.js} +48 -26
  13. package/dist/{framekit-rjk9fs3v.js → framekit-r16k97n7.js} +48 -26
  14. package/dist/grab/fiber.d.ts +2 -0
  15. package/dist/{index-s252g4k2.js → index-0qkj2mgb.js} +4 -4
  16. package/dist/{index-whehz74d.js → index-2jc9dnta.js} +21 -1
  17. package/dist/{index-whbpf3kg.js → index-3nwycv3p.js} +4 -4
  18. package/dist/{index-pwqfmbqm.js → index-8d1yk9d2.js} +8 -8
  19. package/dist/{index-ajs4na3f.js → index-cb91vcka.js} +1 -1
  20. package/dist/{index-20bc9yrj.js → index-fjrrgd9h.js} +1 -1
  21. package/dist/{index-df35z48z.js → index-q53j8wg5.js} +2 -2
  22. package/dist/{index-yc2m7nce.js → index-s6fya8pm.js} +4 -4
  23. package/dist/{index-dxga6h10.js → index-tqq2ygpj.js} +2 -2
  24. package/dist/{index-69fvtkcm.js → index-v2v4rmpe.js} +3 -3
  25. package/dist/{index-1mstjadm.js → index-xs29b55n.js} +4 -1
  26. package/dist/{index-sy63y6r7.js → index-xxbb8y41.js} +4 -4
  27. package/dist/index.global.js +135 -118
  28. package/dist/index.js +63 -23
  29. package/dist/{react-msn10fjb.js → react-0gxs9aef.js} +3 -3
  30. package/dist/{react-2b7725je.js → react-3ev6rwqz.js} +2 -2
  31. package/dist/{react-k4pkm1p5.js → react-6ngtb6p9.js} +1 -1
  32. package/dist/{react-5ekfj7g3.js → react-8nmtt0ge.js} +2 -2
  33. package/dist/{react-y9gr8yt2.js → react-actmnkwp.js} +1 -1
  34. package/dist/{react-p1m2eadn.js → react-fq4551ks.js} +4 -4
  35. package/dist/{react-vbk58f9m.js → react-meve34wp.js} +21 -1
  36. package/dist/{react-nc8fzgmc.js → react-vvc4x9kq.js} +4 -4
  37. package/dist/{react-3mfz1x2a.js → react-yx3g9k55.js} +4 -1
  38. package/dist/{react-smtqyzx0.js → react-zp7fdw8e.js} +8 -8
  39. package/dist/react.js +63 -23
  40. package/dist/{replay-461gcdh1.js → replay-m5g8km9y.js} +4 -4
  41. package/dist/{replay-ehgxp9py.js → replay-pmesjfa3.js} +4 -4
  42. package/dist/{storageview-vtvt76ze.js → storageview-9a6zm47z.js} +8 -8
  43. package/dist/{storageview-yyd57vzw.js → storageview-x62v1c3j.js} +8 -8
  44. package/dist/ui/icons.d.ts +5 -2
  45. package/dist/ui/panel.d.ts +2 -0
  46. package/dist/ui/settings.d.ts +11 -1
  47. package/package.json +5 -2
  48. package/skills/{devknobs → knobs}/SKILL.md +18 -18
@@ -116,6 +116,31 @@ export declare function svgUrl(svg: string): string;
116
116
  * size in % or em would be taken against it too. So both get the size in px.
117
117
  */
118
118
  export declare function rootSize(doc: Document, view: Window): string;
119
+ /**
120
+ * The zoom the page in `view` is laid out at: its pixel ratio, or 1 where it
121
+ * has none. The browser lays the live page out with its pixel ratio as a
122
+ * zoom, and a drawing of its copy at 1. Text lines round apart at the two,
123
+ * more the further down the page, so the copy is laid out at the page's.
124
+ * Only Chromium lays the page out so. Safari and Firefox lay it out in css
125
+ * px, as the drawing at 1 is, so it stays 1 there. The browser is told by
126
+ * the host's own `userAgentData`, as a device frame may change the page's.
127
+ * An insecure origin has none either, and keeps 1.
128
+ */
129
+ export declare function layoutZoom(view: Window): number;
130
+ /** The zoom the page in `doc` sets on its own root, or 1 where it sets a bad one. */
131
+ export declare function ownZoom(doc: Document, view: Window): number;
132
+ /**
133
+ * The zoom for the root of a copy of the page in `doc`, laid out at `ratio`,
134
+ * as a style to add to it. A zoom the page sets on its own root comes on top of
135
+ * the ratio. Important, so a page rule with !important does not win over it.
136
+ */
137
+ export declare function rootZoom(doc: Document, view: Window, ratio: number): string;
138
+ /**
139
+ * A drawing of `markup`, a copy of the page, `width` by `height` css px, its
140
+ * root sized by `sized`. Its copy laid out at `zoom` is as many times as
141
+ * large, so the drawing views that much more of it in the same size.
142
+ */
143
+ export declare function drawing(markup: string, width: number, height: number, sized: string, zoom: number): string;
119
144
  /**
120
145
  * A picture of the page in `frame` as the browser draws it, from `copy`, laid
121
146
  * out and scrolled as the frame is now, on a canvas of the screen `glass`
@@ -24,7 +24,7 @@ import {
24
24
  turnOf,
25
25
  turnedPose,
26
26
  windowRect
27
- } from "./index-ajs4na3f.js";
27
+ } from "./index-cb91vcka.js";
28
28
  import {
29
29
  hush,
30
30
  hushOnce,
@@ -3269,7 +3269,7 @@ async function loadAll(files) {
3269
3269
  if (ok)
3270
3270
  return image;
3271
3271
  }
3272
- throw new Error(`devknobs: ${file} did not load`);
3272
+ throw new Error(`knobs: ${file} did not load`);
3273
3273
  };
3274
3274
  return Promise.all(files.map(loaded));
3275
3275
  }
@@ -5057,6 +5057,24 @@ function rootSize(doc, view) {
5057
5057
  const size = view.getComputedStyle(doc.documentElement).fontSize;
5058
5058
  return size ? `font-size:${size} !important` : "";
5059
5059
  }
5060
+ function layoutZoom(view) {
5061
+ if (!("userAgentData" in navigator))
5062
+ return 1;
5063
+ const ratio = view.devicePixelRatio;
5064
+ return Number.isFinite(ratio) && ratio > 0 ? ratio : 1;
5065
+ }
5066
+ function ownZoom(doc, view) {
5067
+ const own = Number(view.getComputedStyle(doc.documentElement).zoom);
5068
+ return Number.isFinite(own) && own > 0 ? own : 1;
5069
+ }
5070
+ function rootZoom(doc, view, ratio) {
5071
+ const own = ownZoom(doc, view);
5072
+ return ratio === 1 && own === 1 ? "" : `;zoom:${ratio * own} !important`;
5073
+ }
5074
+ function drawing(markup, width, height, sized, zoom) {
5075
+ const view = Number.isFinite(zoom) && zoom > 0 && zoom !== 1 ? ` viewBox="0 0 ${width * zoom} ${height * zoom}"` : "";
5076
+ return `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${height}"${view} style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5077
+ }
5060
5078
  async function paintPage(frame2, glass, size, color, copy) {
5061
5079
  const doc = frame2.contentDocument;
5062
5080
  const view = frame2.contentWindow;
@@ -5084,11 +5102,14 @@ async function paintPage(frame2, glass, size, color, copy) {
5084
5102
  } catch {}
5085
5103
  }
5086
5104
  const root = copy.cloneNode(true);
5087
- const scrolled = `position:relative;left:${-scrollX}px;top:${-scrollY}px`;
5105
+ const own = ownZoom(doc, view);
5106
+ const scrolled = `position:relative;left:${-scrollX / own}px;top:${-scrollY / own}px`;
5088
5107
  const sized = rootSize(doc, view);
5089
- root.setAttribute("style", `${root.getAttribute("style") ?? ""};${sized};${scrolled}`);
5108
+ const zoom = layoutZoom(view);
5109
+ const zoomed = rootZoom(doc, view, zoom);
5110
+ root.setAttribute("style", `${root.getAttribute("style") ?? ""};${sized};${scrolled}${zoomed}`);
5090
5111
  const markup = new XMLSerializer().serializeToString(root);
5091
- const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${height}" style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5112
+ const svg = drawing(markup, width, height, sized, zoom);
5092
5113
  const image = new Image;
5093
5114
  try {
5094
5115
  image.src = svgUrl(svg);
@@ -5168,12 +5189,13 @@ function pictureOf(frame2) {
5168
5189
  node.setAttribute("style", viewportUnits(node.getAttribute("style") ?? "", tall));
5169
5190
  }
5170
5191
  const full = Math.max(doc.documentElement.scrollHeight, tall);
5171
- const root = doc.documentElement.getBoundingClientRect().height;
5192
+ const root = doc.documentElement.getBoundingClientRect().height / ownZoom(doc, view);
5172
5193
  const sized = rootSize(doc, view);
5173
- copy.setAttribute("style", `${copy.getAttribute("style") ?? ""};${sized};height:${root}px !important`);
5194
+ const zoom = layoutZoom(view);
5195
+ const zoomed = rootZoom(doc, view, zoom);
5196
+ copy.setAttribute("style", `${copy.getAttribute("style") ?? ""};${sized};height:${root}px !important${zoomed}`);
5174
5197
  const markup = new XMLSerializer().serializeToString(copy);
5175
- const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${full}" style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5176
- return { src: svgUrl(svg), width, height: full };
5198
+ return { src: svgUrl(drawing(markup, width, full, sized, zoom)), width, height: full };
5177
5199
  }
5178
5200
  function createUnderbar(glass, frame2) {
5179
5201
  const band = el("div", "underbar");
@@ -6541,8 +6563,8 @@ function copyBars(shown2, value, size) {
6541
6563
  const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${size.width}" height="${size.height}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
6542
6564
  const image = new Image;
6543
6565
  image.src = svgUrl(svg);
6544
- const drawing = image.decode().then(() => image, () => null);
6545
- return { drawing, size, glass: bars ? glassOf(bars, host) : [] };
6566
+ const drawing2 = image.decode().then(() => image, () => null);
6567
+ return { drawing: drawing2, size, glass: bars ? glassOf(bars, host) : [] };
6546
6568
  }
6547
6569
  async function paintBars(shot, bars) {
6548
6570
  const image = await bars.drawing;
@@ -7204,10 +7226,10 @@ function leafOf(side, picture, turning2, across) {
7204
7226
  screen.style.boxShadow = `0 0 0 ${UNDER}px #000`;
7205
7227
  node.append(screen);
7206
7228
  if (body) {
7207
- const drawing = drawMock(body, size, href);
7208
- drawing.style.width = "100%";
7209
- drawing.style.height = "100%";
7210
- node.append(drawing);
7229
+ const drawing2 = drawMock(body, size, href);
7230
+ drawing2.style.width = "100%";
7231
+ drawing2.style.height = "100%";
7232
+ node.append(drawing2);
7211
7233
  }
7212
7234
  const opening = placeAt(div(""), rect);
7213
7235
  const dark = div("");
@@ -8800,7 +8822,7 @@ var veil = null;
8800
8822
  var mat = null;
8801
8823
  var matKey = "";
8802
8824
  var stage = null;
8803
- var drawing = null;
8825
+ var drawing2 = null;
8804
8826
  var screen = null;
8805
8827
  var glass = null;
8806
8828
  var pageBox = null;
@@ -9284,7 +9306,7 @@ function unwatchDensity() {
9284
9306
  densityRatio = 0;
9285
9307
  }
9286
9308
  function resize() {
9287
- if (!frame3 || !letterbox || !stage || !drawing || !screen || !readout || !caption)
9309
+ if (!frame3 || !letterbox || !stage || !drawing2 || !screen || !readout || !caption)
9288
9310
  return;
9289
9311
  if (released || turning() || folding())
9290
9312
  return;
@@ -9319,9 +9341,9 @@ function resize() {
9319
9341
  const radii = mock ? corners(mock.screenRadius).map((radius) => `${radius * place2.zoom}px`) : [];
9320
9342
  showBrowser(bars, page, place2, auto, radii.join(" "));
9321
9343
  touchDot?.fit(place2, place2.zoom);
9322
- drawing.style.width = `${place2.box.width}px`;
9323
- drawing.style.height = `${place2.box.height}px`;
9324
- const at = mock ? drawing.getBoundingClientRect() : null;
9344
+ drawing2.style.width = `${place2.box.width}px`;
9345
+ drawing2.style.height = `${place2.box.height}px`;
9346
+ const at = mock ? drawing2.getBoundingClientRect() : null;
9325
9347
  const ratio = window.devicePixelRatio;
9326
9348
  const nudge = at ? { x: snapShift(at.left + place2.left, ratio), y: snapShift(at.top + place2.top, ratio) } : null;
9327
9349
  screen.style.left = `${place2.left - (mock?.inset.left ?? 0) * place2.scale + (nudge?.x ?? 0)}px`;
@@ -9647,8 +9669,8 @@ function open(veiled, first) {
9647
9669
  readout.append(caption, picker);
9648
9670
  stage = document.createElement("div");
9649
9671
  stage.className = "stage";
9650
- drawing = document.createElement("div");
9651
- drawing.className = "drawing";
9672
+ drawing2 = document.createElement("div");
9673
+ drawing2.className = "drawing";
9652
9674
  screen = document.createElement("div");
9653
9675
  screen.className = "screen";
9654
9676
  glass = document.createElement("div");
@@ -9658,7 +9680,7 @@ function open(veiled, first) {
9658
9680
  if (fresh())
9659
9681
  frame3.setAttribute(FRESH_ATTRIBUTE, "");
9660
9682
  frame3.name = FRAME_NAME;
9661
- frame3.title = "devknobs viewport";
9683
+ frame3.title = "knobs viewport";
9662
9684
  frame3.setAttribute("sandbox", SANDBOX);
9663
9685
  frameUrl = window.location.href;
9664
9686
  follow3({ page: frameDocument, locate, refresh: () => browser?.refresh() });
@@ -9711,8 +9733,8 @@ function open(veiled, first) {
9711
9733
  turnCover.className = "screenblank";
9712
9734
  turnCover.hidden = true;
9713
9735
  screen.append(glass);
9714
- drawing.append(screen);
9715
- stage.append(drawing);
9736
+ drawing2.append(screen);
9737
+ stage.append(drawing2);
9716
9738
  letterbox.append(veil, back, readout, stage, notice);
9717
9739
  letterbox.addEventListener("wheel", onWheel, { passive: false });
9718
9740
  root.append(letterbox);
@@ -9777,7 +9799,7 @@ function teardown() {
9777
9799
  mat = null;
9778
9800
  matKey = "";
9779
9801
  stage = null;
9780
- drawing = null;
9802
+ drawing2 = null;
9781
9803
  screen = null;
9782
9804
  glass = null;
9783
9805
  pageBox = null;
@@ -25,7 +25,7 @@ import {
25
25
  turnOf,
26
26
  turnedPose,
27
27
  windowRect
28
- } from "./react-k4pkm1p5.js";
28
+ } from "./react-6ngtb6p9.js";
29
29
  import {
30
30
  hush,
31
31
  hushOnce,
@@ -3270,7 +3270,7 @@ async function loadAll(files) {
3270
3270
  if (ok)
3271
3271
  return image;
3272
3272
  }
3273
- throw new Error(`devknobs: ${file} did not load`);
3273
+ throw new Error(`knobs: ${file} did not load`);
3274
3274
  };
3275
3275
  return Promise.all(files.map(loaded));
3276
3276
  }
@@ -5058,6 +5058,24 @@ function rootSize(doc, view) {
5058
5058
  const size = view.getComputedStyle(doc.documentElement).fontSize;
5059
5059
  return size ? `font-size:${size} !important` : "";
5060
5060
  }
5061
+ function layoutZoom(view) {
5062
+ if (!("userAgentData" in navigator))
5063
+ return 1;
5064
+ const ratio = view.devicePixelRatio;
5065
+ return Number.isFinite(ratio) && ratio > 0 ? ratio : 1;
5066
+ }
5067
+ function ownZoom(doc, view) {
5068
+ const own = Number(view.getComputedStyle(doc.documentElement).zoom);
5069
+ return Number.isFinite(own) && own > 0 ? own : 1;
5070
+ }
5071
+ function rootZoom(doc, view, ratio) {
5072
+ const own = ownZoom(doc, view);
5073
+ return ratio === 1 && own === 1 ? "" : `;zoom:${ratio * own} !important`;
5074
+ }
5075
+ function drawing(markup, width, height, sized, zoom) {
5076
+ const view = Number.isFinite(zoom) && zoom > 0 && zoom !== 1 ? ` viewBox="0 0 ${width * zoom} ${height * zoom}"` : "";
5077
+ return `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${height}"${view} style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5078
+ }
5061
5079
  async function paintPage(frame2, glass, size, color, copy) {
5062
5080
  const doc = frame2.contentDocument;
5063
5081
  const view = frame2.contentWindow;
@@ -5085,11 +5103,14 @@ async function paintPage(frame2, glass, size, color, copy) {
5085
5103
  } catch {}
5086
5104
  }
5087
5105
  const root = copy.cloneNode(true);
5088
- const scrolled = `position:relative;left:${-scrollX}px;top:${-scrollY}px`;
5106
+ const own = ownZoom(doc, view);
5107
+ const scrolled = `position:relative;left:${-scrollX / own}px;top:${-scrollY / own}px`;
5089
5108
  const sized = rootSize(doc, view);
5090
- root.setAttribute("style", `${root.getAttribute("style") ?? ""};${sized};${scrolled}`);
5109
+ const zoom = layoutZoom(view);
5110
+ const zoomed = rootZoom(doc, view, zoom);
5111
+ root.setAttribute("style", `${root.getAttribute("style") ?? ""};${sized};${scrolled}${zoomed}`);
5091
5112
  const markup = new XMLSerializer().serializeToString(root);
5092
- const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${height}" style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5113
+ const svg = drawing(markup, width, height, sized, zoom);
5093
5114
  const image = new Image;
5094
5115
  try {
5095
5116
  image.src = svgUrl(svg);
@@ -5169,12 +5190,13 @@ function pictureOf(frame2) {
5169
5190
  node.setAttribute("style", viewportUnits(node.getAttribute("style") ?? "", tall));
5170
5191
  }
5171
5192
  const full = Math.max(doc.documentElement.scrollHeight, tall);
5172
- const root = doc.documentElement.getBoundingClientRect().height;
5193
+ const root = doc.documentElement.getBoundingClientRect().height / ownZoom(doc, view);
5173
5194
  const sized = rootSize(doc, view);
5174
- copy.setAttribute("style", `${copy.getAttribute("style") ?? ""};${sized};height:${root}px !important`);
5195
+ const zoom = layoutZoom(view);
5196
+ const zoomed = rootZoom(doc, view, zoom);
5197
+ copy.setAttribute("style", `${copy.getAttribute("style") ?? ""};${sized};height:${root}px !important${zoomed}`);
5175
5198
  const markup = new XMLSerializer().serializeToString(copy);
5176
- const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${width}" height="${full}" style="${sized}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
5177
- return { src: svgUrl(svg), width, height: full };
5199
+ return { src: svgUrl(drawing(markup, width, full, sized, zoom)), width, height: full };
5178
5200
  }
5179
5201
  function createUnderbar(glass, frame2) {
5180
5202
  const band = el("div", "underbar");
@@ -6542,8 +6564,8 @@ function copyBars(shown2, value, size) {
6542
6564
  const svg = `<svg xmlns="http://www.w3.org/2000/svg" width="${size.width}" height="${size.height}">` + `<foreignObject width="100%" height="100%">${markup}</foreignObject></svg>`;
6543
6565
  const image = new Image;
6544
6566
  image.src = svgUrl(svg);
6545
- const drawing = image.decode().then(() => image, () => null);
6546
- return { drawing, size, glass: bars ? glassOf(bars, host) : [] };
6567
+ const drawing2 = image.decode().then(() => image, () => null);
6568
+ return { drawing: drawing2, size, glass: bars ? glassOf(bars, host) : [] };
6547
6569
  }
6548
6570
  async function paintBars(shot, bars) {
6549
6571
  const image = await bars.drawing;
@@ -7205,10 +7227,10 @@ function leafOf(side, picture, turning2, across) {
7205
7227
  screen.style.boxShadow = `0 0 0 ${UNDER}px #000`;
7206
7228
  node.append(screen);
7207
7229
  if (body) {
7208
- const drawing = drawMock(body, size, href);
7209
- drawing.style.width = "100%";
7210
- drawing.style.height = "100%";
7211
- node.append(drawing);
7230
+ const drawing2 = drawMock(body, size, href);
7231
+ drawing2.style.width = "100%";
7232
+ drawing2.style.height = "100%";
7233
+ node.append(drawing2);
7212
7234
  }
7213
7235
  const opening = placeAt(div(""), rect);
7214
7236
  const dark = div("");
@@ -8801,7 +8823,7 @@ var veil = null;
8801
8823
  var mat = null;
8802
8824
  var matKey = "";
8803
8825
  var stage = null;
8804
- var drawing = null;
8826
+ var drawing2 = null;
8805
8827
  var screen = null;
8806
8828
  var glass = null;
8807
8829
  var pageBox = null;
@@ -9285,7 +9307,7 @@ function unwatchDensity() {
9285
9307
  densityRatio = 0;
9286
9308
  }
9287
9309
  function resize() {
9288
- if (!frame3 || !letterbox || !stage || !drawing || !screen || !readout || !caption)
9310
+ if (!frame3 || !letterbox || !stage || !drawing2 || !screen || !readout || !caption)
9289
9311
  return;
9290
9312
  if (released || turning() || folding())
9291
9313
  return;
@@ -9320,9 +9342,9 @@ function resize() {
9320
9342
  const radii = mock ? corners(mock.screenRadius).map((radius) => `${radius * place2.zoom}px`) : [];
9321
9343
  showBrowser(bars, page, place2, auto, radii.join(" "));
9322
9344
  touchDot?.fit(place2, place2.zoom);
9323
- drawing.style.width = `${place2.box.width}px`;
9324
- drawing.style.height = `${place2.box.height}px`;
9325
- const at = mock ? drawing.getBoundingClientRect() : null;
9345
+ drawing2.style.width = `${place2.box.width}px`;
9346
+ drawing2.style.height = `${place2.box.height}px`;
9347
+ const at = mock ? drawing2.getBoundingClientRect() : null;
9326
9348
  const ratio = window.devicePixelRatio;
9327
9349
  const nudge = at ? { x: snapShift(at.left + place2.left, ratio), y: snapShift(at.top + place2.top, ratio) } : null;
9328
9350
  screen.style.left = `${place2.left - (mock?.inset.left ?? 0) * place2.scale + (nudge?.x ?? 0)}px`;
@@ -9648,8 +9670,8 @@ function open(veiled, first) {
9648
9670
  readout.append(caption, picker);
9649
9671
  stage = document.createElement("div");
9650
9672
  stage.className = "stage";
9651
- drawing = document.createElement("div");
9652
- drawing.className = "drawing";
9673
+ drawing2 = document.createElement("div");
9674
+ drawing2.className = "drawing";
9653
9675
  screen = document.createElement("div");
9654
9676
  screen.className = "screen";
9655
9677
  glass = document.createElement("div");
@@ -9659,7 +9681,7 @@ function open(veiled, first) {
9659
9681
  if (fresh())
9660
9682
  frame3.setAttribute(FRESH_ATTRIBUTE, "");
9661
9683
  frame3.name = FRAME_NAME;
9662
- frame3.title = "devknobs viewport";
9684
+ frame3.title = "knobs viewport";
9663
9685
  frame3.setAttribute("sandbox", SANDBOX);
9664
9686
  frameUrl = window.location.href;
9665
9687
  follow3({ page: frameDocument, locate, refresh: () => browser?.refresh() });
@@ -9712,8 +9734,8 @@ function open(veiled, first) {
9712
9734
  turnCover.className = "screenblank";
9713
9735
  turnCover.hidden = true;
9714
9736
  screen.append(glass);
9715
- drawing.append(screen);
9716
- stage.append(drawing);
9737
+ drawing2.append(screen);
9738
+ stage.append(drawing2);
9717
9739
  letterbox.append(veil, back, readout, stage, notice);
9718
9740
  letterbox.addEventListener("wheel", onWheel, { passive: false });
9719
9741
  root.append(letterbox);
@@ -9778,7 +9800,7 @@ function teardown() {
9778
9800
  mat = null;
9779
9801
  matKey = "";
9780
9802
  stage = null;
9781
- drawing = null;
9803
+ drawing2 = null;
9782
9804
  screen = null;
9783
9805
  glass = null;
9784
9806
  pageBox = null;
@@ -13,5 +13,7 @@ export declare function isComposite(fiber: Fiber): boolean;
13
13
  * boundary at most, so a route's key far above never shows.
14
14
  */
15
15
  export declare function listKey(fiber: Fiber | null): string | null;
16
+ /** A name a production build shortened, like `xf`: component names start uppercase. */
17
+ export declare function isMinifiedName(name: string): boolean;
16
18
  /** Names of the components above the fiber, nearest first, that `accept` lets through. */
17
19
  export declare function componentNames(fiber: Fiber | null, max: number, accept: (name: string) => boolean): string[];
@@ -4,13 +4,13 @@ import {
4
4
  lay,
5
5
  rowBox,
6
6
  rowButton
7
- } from "./index-20bc9yrj.js";
7
+ } from "./index-fjrrgd9h.js";
8
8
  import {
9
9
  getState
10
- } from "./index-pwqfmbqm.js";
10
+ } from "./index-8d1yk9d2.js";
11
11
  import {
12
12
  icon
13
- } from "./index-whehz74d.js";
13
+ } from "./index-2jc9dnta.js";
14
14
  import {
15
15
  isDevknobsFrame,
16
16
  newer,
@@ -324,7 +324,7 @@ function createPane(context) {
324
324
  // src/ui/storageaction.ts
325
325
  var STORAGE_VIEW = "storage";
326
326
  function load() {
327
- return import("./storageview-yyd57vzw.js").then((loaded) => loaded.storageView({
327
+ return import("./storageview-x62v1c3j.js").then((loaded) => loaded.storageView({
328
328
  visible: () => getState().panel.open && !document.hidden
329
329
  }));
330
330
  }
@@ -231,8 +231,28 @@ var BRANDS = {
231
231
  json: [
232
232
  "currentColor",
233
233
  "M12.043 23.968c.479-.004.953-.029 1.426-.094a11.805 11.805 0 003.146-.863 12.404 12.404 0 003.793-2.542 11.977 11.977 0 002.44-3.427 11.794 11.794 0 001.02-3.476c.149-1.16.135-2.346-.045-3.499a11.96 11.96 0 00-.793-2.788 11.197 11.197 0 00-.854-1.617c-1.168-1.837-2.861-3.314-4.81-4.3a12.835 12.835 0 00-2.172-.87h-.005c.119.063.24.132.345.201.12.074.239.146.351.225a8.93 8.93 0 011.559 1.33c1.063 1.145 1.797 2.548 2.218 4.041.284.982.434 1.998.495 3.017.044.743.044 1.491-.047 2.229-.149 1.27-.554 2.51-1.228 3.596a7.475 7.475 0 01-1.903 2.084c-1.244.928-2.877 1.482-4.436 1.114a3.916 3.916 0 01-.748-.258 4.692 4.692 0 01-.779-.45 6.08 6.08 0 01-1.244-1.105 6.507 6.507 0 01-1.049-1.747 7.366 7.366 0 01-.494-2.54c-.03-1.273.225-2.553.854-3.67a6.43 6.43 0 011.663-1.918c.225-.178.464-.333.704-.479l.016-.007a5.121 5.121 0 00-1.441-.12 4.963 4.963 0 00-1.228.24c-.359.12-.704.27-1.019.45a6.146 6.146 0 00-.733.494c-.211.18-.42.36-.615.555-1.123 1.153-1.768 2.682-2.022 4.256-.15.973-.15 1.96-.091 2.95.105 1.395.391 2.787.945 4.062a8.518 8.518 0 001.348 2.173 8.14 8.14 0 003.132 2.23 7.934 7.934 0 002.113.54c.074.015.149.015.209.015zm-2.934-.398a4.102 4.102 0 01-.45-.228 8.5 8.5 0 01-2.038-1.534c-1.094-1.137-1.827-2.566-2.247-4.08a15.184 15.184 0 01-.495-3.172 12.14 12.14 0 01.046-2.082c.135-1.257.495-2.501 1.124-3.58a6.889 6.889 0 011.783-2.053 6.23 6.23 0 011.633-.9 5.363 5.363 0 013.522-.045c.029 0 .029 0 .045.03.015.015.045.015.06.03.045.016.104.045.165.074.239.12.479.271.704.42a6.294 6.294 0 012.097 2.502c.42.914.615 1.934.631 2.938.014 1.079-.18 2.157-.645 3.146a6.42 6.42 0 01-2.638 2.832c.09.03.18.045.271.075.225.044.449.074.688.074 1.468.045 2.892-.66 3.94-1.647.195-.18.375-.375.54-.585.225-.27.435-.54.614-.823.239-.375.435-.75.614-1.154a8.112 8.112 0 00.509-1.664c.196-1.004.211-2.022.149-3.026-.135-2.022-.673-4.045-1.842-5.724a9.054 9.054 0 00-.555-.719 9.868 9.868 0 00-1.063-1.034 8.477 8.477 0 00-1.363-.915 9.927 9.927 0 00-1.692-.598l-.3-.06c-.209-.03-.42-.044-.634-.06a8.453 8.453 0 00-1.015.016c-.704.045-1.412.16-2.112.337C5.799 1.227 2.863 3.566 1.3 6.67A11.834 11.834 0 00.238 9.801a11.81 11.81 0 00-.104 3.775c.12 1.02.374 2.023.778 2.977.227.57.511 1.124.825 1.648 1.094 1.783 2.683 3.236 4.51 4.24.688.39 1.408.69 2.157.944.226.074.45.15.689.21z"
234
+ ],
235
+ github: [
236
+ "currentColor",
237
+ "M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"
234
238
  ]
235
239
  };
240
+ var VINENA = {
241
+ viewBox: "-3.1 0 537.6 100",
242
+ d: "M147.7 0L205.7 39.97C212.299 35.383 217.85 29.448 221.987 22.559C226.124 15.669 228.753 7.98 229.7 0C240.978 32.123 243.056 66.759 235.7 100L177.7 60.03C171.101 64.617 165.55 70.552 161.413 77.441C157.276 84.331 154.647 92.02 153.7 100C142.422 67.877 140.344 33.241 147.7 0ZM332.2 0L390.2 39.97C396.799 35.383 402.35 29.448 406.487 22.559C410.624 15.669 413.253 7.98 414.2 0C425.478 32.123 427.556 66.759 420.2 100L362.2 60.03C355.601 64.617 350.05 70.552 345.913 77.441C341.776 84.331 339.147 92.02 338.2 100C326.922 67.877 324.844 33.241 332.2 0ZM256.7 0L320.788 0C321.757 -0.025 322.728 -0.025 323.7 0C308.09 8.286 293.044 17.594 278.662 27.864C277.746 28.519 276.999 29.382 276.484 30.383C275.969 31.384 275.7 32.494 275.7 33.619C275.7 35.495 276.445 37.294 277.771 38.62C279.054 39.903 280.78 40.642 282.589 40.689C282.662 40.69 282.735 40.69 282.808 40.691C288.331 40.737 292.836 39.957 297.815 39.096C299.95 38.726 302.172 38.341 304.599 38C301.662 41.307 300.039 45.577 300.039 50C300.039 54.423 301.662 58.693 304.599 62C302.172 61.659 299.95 61.274 297.815 60.904C292.836 60.043 288.331 59.263 282.808 59.309C282.735 59.31 282.662 59.31 282.589 59.311C280.78 59.358 279.054 60.097 277.771 61.38C276.445 62.706 275.7 64.505 275.7 66.381C275.7 67.506 275.969 68.616 276.484 69.617C276.999 70.618 277.746 71.481 278.662 72.136C293.044 82.406 308.09 91.714 323.7 100C322.728 100.025 321.757 100.025 320.788 100L256.7 100C247.367 67.32 247.367 32.68 256.7 0ZM0 0C1.758 11.149 7.438 21.304 16.018 28.637C19.433 31.557 23.219 33.952 27.25 35.779C26.953 37.155 26.8 38.57 26.8 40C26.8 45.304 28.907 50.391 32.658 54.142C36.409 57.893 41.496 60 46.8 60C52.104 60 57.191 57.893 60.942 54.142C64.693 50.391 66.8 45.304 66.8 40C66.8 38.57 66.647 37.155 66.35 35.779C70.381 33.952 74.167 31.557 77.582 28.637C86.162 21.304 91.842 11.149 93.6 0C96.647 19.434 93.821 39.335 85.483 57.152C77.144 74.969 63.674 89.889 46.8 100C29.926 89.889 16.456 74.969 8.117 57.152C-0.221 39.335 -3.047 19.434 0 0ZM531.4 100C529.642 88.851 523.962 78.696 515.382 71.363C511.967 68.443 508.181 66.048 504.15 64.221C504.447 62.845 504.6 61.43 504.6 60C504.6 54.696 502.493 49.609 498.742 45.858C494.991 42.107 489.904 40 484.6 40C479.296 40 474.209 42.107 470.458 45.858C466.707 49.609 464.6 54.696 464.6 60C464.6 61.43 464.753 62.845 465.051 64.221C461.019 66.048 457.233 68.443 453.818 71.363C445.238 78.696 439.558 88.851 437.8 100C434.753 80.566 437.579 60.665 445.917 42.848C454.256 25.031 467.726 10.111 484.6 0C501.474 10.111 514.944 25.031 523.283 42.848C531.621 60.665 534.447 80.566 531.4 100ZM120.7 0C129.225 15.286 133.7 32.498 133.7 50C133.7 67.502 129.225 84.714 120.7 100C112.175 84.714 107.7 67.502 107.7 50C107.7 32.498 112.175 15.286 120.7 0Z"
243
+ };
244
+ function vinenaMark() {
245
+ const svg = document.createElementNS(SVG, "svg");
246
+ svg.setAttribute("class", "wordmark");
247
+ svg.setAttribute("viewBox", VINENA.viewBox);
248
+ svg.setAttribute("fill", "currentColor");
249
+ svg.setAttribute("role", "img");
250
+ svg.setAttribute("aria-label", "Vinena");
251
+ const shape = document.createElementNS(SVG, "path");
252
+ shape.setAttribute("d", VINENA.d);
253
+ svg.append(shape);
254
+ return svg;
255
+ }
236
256
  var ROW_ICONS = {
237
257
  scheme: "half-sun-moon",
238
258
  contrast: "contrast",
@@ -688,4 +708,4 @@ function grabTargetAt(root, x, y) {
688
708
  return isGrabbable(element) ? element : null;
689
709
  }
690
710
 
691
- export { composedParent, isDevknobs, isGrabbable, grabTargetAt, ROW_ICONS, rowIcon, BINDING_ICONS, icon, glyph, parseCombo, comboText, withShift, isFunctionKey, comboLabel, comboSpoken, defaultKeys, KEYS_FIELD, inField, typesInField, lowerKey, letterMatches, keyIs, keyAction, isSearchKey, typeAhead, zoomAction, escapeStep, highlightAt, paletteMove, radioMove, forwardKeys };
711
+ export { composedParent, isDevknobs, isGrabbable, grabTargetAt, vinenaMark, ROW_ICONS, rowIcon, BINDING_ICONS, icon, brand, glyph, parseCombo, comboText, withShift, isFunctionKey, comboLabel, comboSpoken, defaultKeys, KEYS_FIELD, inField, typesInField, lowerKey, letterMatches, keyIs, keyAction, isSearchKey, typeAhead, zoomAction, escapeStep, highlightAt, paletteMove, radioMove, forwardKeys };
@@ -7,7 +7,7 @@ import {
7
7
  grabColor,
8
8
  isCLike,
9
9
  isElement
10
- } from "./react-p1m2eadn.js";
10
+ } from "./react-fq4551ks.js";
11
11
  import {
12
12
  componentOf,
13
13
  escapeText,
@@ -15,7 +15,7 @@ import {
15
15
  grabEntry,
16
16
  joinEntries,
17
17
  quickEntry
18
- } from "./react-3mfz1x2a.js";
18
+ } from "./react-yx3g9k55.js";
19
19
  import"./react-1gqwa2yw.js";
20
20
  import {
21
21
  shorthand,
@@ -34,7 +34,7 @@ import {
34
34
  holdInTopLayer,
35
35
  pause,
36
36
  subscribe
37
- } from "./react-smtqyzx0.js";
37
+ } from "./react-zp7fdw8e.js";
38
38
  import"./react-5h7pxnax.js";
39
39
  import {
40
40
  composedParent,
@@ -42,7 +42,7 @@ import {
42
42
  icon,
43
43
  isDevknobs,
44
44
  isGrabbable
45
- } from "./react-vbk58f9m.js";
45
+ } from "./react-meve34wp.js";
46
46
  import {
47
47
  RINGS,
48
48
  addStyle,
@@ -26,7 +26,7 @@ import {
26
26
  import {
27
27
  composedParent,
28
28
  isDevknobs
29
- } from "./index-whehz74d.js";
29
+ } from "./index-2jc9dnta.js";
30
30
  import {
31
31
  DEFAULT_STATE,
32
32
  EXITED,
@@ -1132,7 +1132,7 @@ function holdInTopLayer(host, rank) {
1132
1132
 
1133
1133
  // src/engine/frames.ts
1134
1134
  var kit = null;
1135
- var load2 = () => import("./framekit-q97zeg1d.js");
1135
+ var load2 = () => import("./framekit-40pzennw.js");
1136
1136
  var loading = null;
1137
1137
  var down = false;
1138
1138
  var waiting = [];
@@ -1166,7 +1166,7 @@ function loadFrames() {
1166
1166
  return loading;
1167
1167
  }
1168
1168
  function failed(error) {
1169
- console.error("devknobs: the device frame could not load", error);
1169
+ console.error("knobs: the device frame could not load", error);
1170
1170
  down = true;
1171
1171
  before = null;
1172
1172
  latest = null;
@@ -2574,7 +2574,7 @@ function log(offenders, excess) {
2574
2574
  if (offenders.length === 0) {
2575
2575
  if (excess > 0 && !loggedUnfound) {
2576
2576
  loggedUnfound = true;
2577
- console.warn(`devknobs: the page scrolls ${excess}px past the ${width}px viewport, ` + "but no element box sticks out. a pseudo-element or a margin, maybe");
2577
+ console.warn(`knobs: the page scrolls ${excess}px past the ${width}px viewport, ` + "but no element box sticks out. a pseudo-element or a margin, maybe");
2578
2578
  }
2579
2579
  return;
2580
2580
  }
@@ -2586,7 +2586,7 @@ function log(offenders, excess) {
2586
2586
  }
2587
2587
  function warning(count2, width, excess) {
2588
2588
  const boxes = count2 === 1 ? "1 element sticks" : `${count2} elements stick`;
2589
- return `devknobs: ${boxes} out of the ${width}px viewport, the page scrolls ${excess}px sideways`;
2589
+ return `knobs: ${boxes} out of the ${width}px viewport, the page scrolls ${excess}px sideways`;
2590
2590
  }
2591
2591
  function draw(offenders) {
2592
2592
  if (!layer)
@@ -2889,7 +2889,7 @@ function reset14() {
2889
2889
  var READY_WAIT = 1e4;
2890
2890
  function whenSettled(settled, leaving2, value, mounted, wait = READY_WAIT) {
2891
2891
  return new Promise((resolve, reject) => {
2892
- const notMounted = () => new Error("devknobs: not mounted");
2892
+ const notMounted = () => new Error("knobs: not mounted");
2893
2893
  if (!mounted()) {
2894
2894
  reject(notMounted());
2895
2895
  return;
@@ -2923,7 +2923,7 @@ function whenSettled(settled, leaving2, value, mounted, wait = READY_WAIT) {
2923
2923
  else if (settled())
2924
2924
  resolve(value());
2925
2925
  else
2926
- reject(new Error("devknobs: not settled after 10 seconds"));
2926
+ reject(new Error("knobs: not settled after 10 seconds"));
2927
2927
  }, wait);
2928
2928
  frame2 = window.requestAnimationFrame(check);
2929
2929
  });
@@ -3191,7 +3191,7 @@ function createTabIcon(env) {
3191
3191
  const url = source ? env.render(source, iconSize(link)) : null;
3192
3192
  if (!url) {
3193
3193
  if (!told)
3194
- console.debug(`devknobs: the tab icon ${href} could not be read, so it shows no dev ribbon`);
3194
+ console.debug(`knobs: the tab icon ${href} could not be read, so it shows no dev ribbon`);
3195
3195
  told = true;
3196
3196
  return;
3197
3197
  }
@@ -287,7 +287,7 @@ function keepMounted(node, options = {}) {
287
287
  }
288
288
  if (!warned) {
289
289
  warned = true;
290
- console.warn("devknobs: the page keeps removing devknobs' elements; putting them back less often");
290
+ console.warn("knobs: the page keeps removing knobs' elements; putting them back less often");
291
291
  }
292
292
  timer = window.setTimeout(restore, wait);
293
293
  }
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  icon,
3
3
  radioMove
4
- } from "./index-whehz74d.js";
4
+ } from "./index-2jc9dnta.js";
5
5
 
6
6
  // src/ui/dom.ts
7
7
  function el(tag, className, text) {
@@ -188,7 +188,7 @@ var MAX_PAGES = 20;
188
188
  var FIELD_MAX = 64 * 1024;
189
189
  var KINDS = ["css-value", "css-toggle", "css-add", "css-rule", "text", "attr", "html", "hide", "delete", "move"];
190
190
  var REASONS = {
191
- invalid: "not an edit devknobs reads",
191
+ invalid: "not an edit knobs reads",
192
192
  missing: "not found on the page",
193
193
  rule: "its rule is not on the page",
194
194
  changed: "the page has another value now",
@@ -408,7 +408,7 @@ function settled(view, quiet = QUIET, longest = SETTLE_MAX) {
408
408
  }
409
409
  function createKeeper(options) {
410
410
  const { log, store, view } = options;
411
- const loadReplay = options.replay ?? (() => import("./replay-ehgxp9py.js").then(({ replayEdits }) => replayEdits));
411
+ const loadReplay = options.replay ?? (() => import("./replay-pmesjfa3.js").then(({ replayEdits }) => replayEdits));
412
412
  const wait = options.settled ?? (() => settled(view));
413
413
  const frame = options.frame ?? (() => null);
414
414
  const ours = new WeakMap;
@@ -4,14 +4,14 @@ import {
4
4
  import {
5
5
  frameWindow,
6
6
  subscribe
7
- } from "./index-pwqfmbqm.js";
7
+ } from "./index-8d1yk9d2.js";
8
8
  import {
9
9
  inField,
10
10
  isFunctionKey,
11
11
  keyIs,
12
12
  typesInField,
13
13
  withShift
14
- } from "./index-whehz74d.js";
14
+ } from "./index-2jc9dnta.js";
15
15
  import {
16
16
  addStyle,
17
17
  isDevknobsFrame,
@@ -164,7 +164,7 @@ function systemScheme() {
164
164
  host.remove();
165
165
  return dark ? "dark" : "light";
166
166
  }
167
- function createGrab(options = {}, loadMode = () => import("./index-sy63y6r7.js")) {
167
+ function createGrab(options = {}, loadMode = () => import("./index-xxbb8y41.js")) {
168
168
  const keyNow = options.key ?? defaultGrabKey;
169
169
  const { purpose } = options;
170
170
  const channel = purpose?.channel ?? "grab";
@@ -373,7 +373,7 @@ function held(view) {
373
373
  return null;
374
374
  }
375
375
  }
376
- function createInspect(options = {}, load = () => import("./index-sy63y6r7.js"), frameOf = frameWindow) {
376
+ function createInspect(options = {}, load = () => import("./index-xxbb8y41.js"), frameOf = frameWindow) {
377
377
  const inFrame = isDevknobsFrame();
378
378
  const listeners = new Set;
379
379
  let outliner = null;
@@ -5,7 +5,7 @@ import {
5
5
  import {
6
6
  resolveNesting,
7
7
  splitList
8
- } from "./index-df35z48z.js";
8
+ } from "./index-q53j8wg5.js";
9
9
  import {
10
10
  flatParent,
11
11
  isNewRuleSheet,
@@ -14,7 +14,7 @@ import {
14
14
  } from "./index-a8ffw5ft.js";
15
15
  import {
16
16
  isDevknobs
17
- } from "./index-whehz74d.js";
17
+ } from "./index-2jc9dnta.js";
18
18
  import {
19
19
  addStyle,
20
20
  ensureStyle,