@vinena/knobs 0.0.0-stage → 0.5.1
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/CHANGELOG.md +228 -0
- package/LICENSE +21 -0
- package/README.md +110 -2
- package/THIRD_PARTY_NOTICES.md +429 -0
- package/dist/bezels/duo-fold/fold-000.webp +0 -0
- package/dist/bezels/duo-fold/fold-001.webp +0 -0
- package/dist/bezels/duo-fold/fold-002.webp +0 -0
- package/dist/bezels/duo-fold/fold-003.webp +0 -0
- package/dist/bezels/duo-fold/fold-004.webp +0 -0
- package/dist/bezels/duo-fold/fold-005.webp +0 -0
- package/dist/bezels/duo-fold/fold-006.webp +0 -0
- package/dist/bezels/duo-fold/fold-007.webp +0 -0
- package/dist/bezels/duo-fold/fold-008.webp +0 -0
- package/dist/bezels/duo-fold/fold-009.webp +0 -0
- package/dist/bezels/duo-fold/fold-010.webp +0 -0
- package/dist/bezels/duo-fold/fold-011.webp +0 -0
- package/dist/bezels/duo-fold/fold-012.webp +0 -0
- package/dist/bezels/duo-fold/fold-013.webp +0 -0
- package/dist/bezels/duo-fold/fold-014.webp +0 -0
- package/dist/bezels/duo-fold/fold-015.webp +0 -0
- package/dist/bezels/duo-fold/fold-016.webp +0 -0
- package/dist/bezels/duo-fold/fold-017.webp +0 -0
- package/dist/bezels/duo-fold/fold-018.webp +0 -0
- package/dist/bezels/duo-fold/fold-019.webp +0 -0
- package/dist/bezels/duo-fold/fold-020.webp +0 -0
- package/dist/bezels/duo-fold/fold-021.webp +0 -0
- package/dist/bezels/duo-fold/fold-022.webp +0 -0
- package/dist/bezels/duo-fold/fold-023.webp +0 -0
- package/dist/bezels/duo-fold/fold-024.webp +0 -0
- package/dist/bezels/duo-fold/fold-025.webp +0 -0
- package/dist/bezels/duo-fold/fold-026.webp +0 -0
- package/dist/bezels/duo-fold/fold-027.webp +0 -0
- package/dist/bezels/duo-fold/fold-028.webp +0 -0
- package/dist/bezels/duo-fold/fold-029.webp +0 -0
- package/dist/bezels/duo-fold/fold-030.webp +0 -0
- package/dist/bezels/duo-fold/fold-031.webp +0 -0
- package/dist/bezels/duo-fold/fold-032.webp +0 -0
- package/dist/bezels/duo-fold/fold-033.webp +0 -0
- package/dist/bezels/duo-fold/fold-034.webp +0 -0
- package/dist/bezels/duo-fold/fold-035.webp +0 -0
- package/dist/bezels/duo-fold/fold-036.webp +0 -0
- package/dist/bezels/duo-fold/fold-037.webp +0 -0
- package/dist/bezels/duo-fold/fold-038.webp +0 -0
- package/dist/bezels/duo-fold/fold-039.webp +0 -0
- package/dist/bezels/duo-fold/fold-040.webp +0 -0
- package/dist/bezels/duo-fold/fold-041.webp +0 -0
- package/dist/bezels/duo-fold/fold-042.webp +0 -0
- package/dist/bezels/duo-fold/fold-043.webp +0 -0
- package/dist/bezels/duo-fold/fold-044.webp +0 -0
- package/dist/bezels/duo-fold/fold-045.webp +0 -0
- package/dist/bezels/duo-fold/fold-046.webp +0 -0
- package/dist/bezels/duo-fold/fold-047.webp +0 -0
- package/dist/bezels/duo-fold/fold-048.webp +0 -0
- package/dist/bezels/duo-fold/fold-049.webp +0 -0
- package/dist/bezels/duo-fold/fold-050.webp +0 -0
- package/dist/bezels/duo-fold/fold-051.webp +0 -0
- package/dist/bezels/duo-fold/fold-052.webp +0 -0
- package/dist/bezels/duo-fold/fold-053.webp +0 -0
- package/dist/bezels/duo-fold/fold-054.webp +0 -0
- package/dist/bezels/duo-fold/fold-055.webp +0 -0
- package/dist/bezels/duo-fold/fold-056.webp +0 -0
- package/dist/bezels/duo-fold/fold-057.webp +0 -0
- package/dist/bezels/duo-fold/fold-058.webp +0 -0
- package/dist/bezels/duo-fold/fold-059.webp +0 -0
- package/dist/bezels/duo-fold/fold-060.webp +0 -0
- package/dist/bezels/duo-fold/fold-061.webp +0 -0
- package/dist/bezels/duo-fold/fold-062.webp +0 -0
- package/dist/bezels/duo-fold/fold-063.webp +0 -0
- package/dist/bezels/duo-fold/fold-064.webp +0 -0
- package/dist/bezels/duo-fold/fold-065.webp +0 -0
- package/dist/bezels/duo-fold/fold-066.webp +0 -0
- package/dist/bezels/duo-fold/fold-067.webp +0 -0
- package/dist/bezels/duo-fold/fold-068.webp +0 -0
- package/dist/bezels/duo-fold/fold-069.webp +0 -0
- package/dist/bezels/duo-fold/fold-070.webp +0 -0
- package/dist/bezels/duo-fold/fold-071.webp +0 -0
- package/dist/bezels/duo-fold/fold-072.webp +0 -0
- package/dist/bezels/duo-fold/fold-073.webp +0 -0
- package/dist/bezels/duo-fold/fold-074.webp +0 -0
- package/dist/bezels/duo-fold/fold-075.webp +0 -0
- package/dist/bezels/duo-fold/fold-076.webp +0 -0
- package/dist/bezels/duo-fold/fold-077.webp +0 -0
- package/dist/bezels/duo-fold/fold-078.webp +0 -0
- package/dist/bezels/duo-fold/fold-079.webp +0 -0
- package/dist/bezels/duo-fold/fold-080.webp +0 -0
- package/dist/bezels/duo-fold/fold-081.webp +0 -0
- package/dist/bezels/duo-fold/fold-082.webp +0 -0
- package/dist/bezels/duo-fold/fold-083.webp +0 -0
- package/dist/bezels/duo-fold/fold-084.webp +0 -0
- package/dist/bezels/duo-fold/fold-085.webp +0 -0
- package/dist/bezels/duo-fold/fold-086.webp +0 -0
- package/dist/bezels/duo-fold/fold-087.webp +0 -0
- package/dist/bezels/duo-fold/fold-088.webp +0 -0
- package/dist/bezels/duo-fold/fold-089.webp +0 -0
- package/dist/bezels/duo-fold/fold-090.webp +0 -0
- package/dist/bezels/duo-fold/fold-091.webp +0 -0
- package/dist/bezels/duo-fold/fold-092.webp +0 -0
- package/dist/bezels/duo-fold/fold-093.webp +0 -0
- package/dist/bezels/duo-fold/fold-094.webp +0 -0
- package/dist/bezels/duo-fold/fold-095.webp +0 -0
- package/dist/bezels/duo-fold/fold-096.webp +0 -0
- package/dist/bezels/duo-fold/fold-097.webp +0 -0
- package/dist/bezels/duo-fold/fold-098.webp +0 -0
- package/dist/bezels/duo-fold/fold-099.webp +0 -0
- package/dist/bezels/duo-fold/fold-100.webp +0 -0
- package/dist/bezels/duo-fold/fold-101.webp +0 -0
- package/dist/bezels/duo-fold/fold-102.webp +0 -0
- package/dist/bezels/duo-fold/fold-103.webp +0 -0
- package/dist/bezels/duo-fold/fold-104.webp +0 -0
- package/dist/bezels/duo-fold/fold-105.webp +0 -0
- package/dist/bezels/duo-fold/fold-106.webp +0 -0
- package/dist/bezels/duo-fold/fold-107.webp +0 -0
- package/dist/bezels/duo-fold/fold-108.webp +0 -0
- package/dist/bezels/duo-fold/fold-109.webp +0 -0
- package/dist/bezels/duo-fold/fold-110.webp +0 -0
- package/dist/bezels/duo-fold/fold-111.webp +0 -0
- package/dist/bezels/duo-fold/fold-112.webp +0 -0
- package/dist/bezels/duo-fold/fold-113.webp +0 -0
- package/dist/bezels/duo-fold/fold-114.webp +0 -0
- package/dist/bezels/duo-fold/fold-115.webp +0 -0
- package/dist/bezels/duo-fold/fold-116.webp +0 -0
- package/dist/bezels/duo-fold/fold-117.webp +0 -0
- package/dist/bezels/duo-fold/fold-118.webp +0 -0
- package/dist/bezels/duo-fold/fold-119.webp +0 -0
- package/dist/bezels/duo-fold/fold-120.webp +0 -0
- package/dist/bezels/duo-fold/fold-121.webp +0 -0
- package/dist/bezels/duo-fold/fold-122.webp +0 -0
- package/dist/bezels/duo-fold/fold-123.webp +0 -0
- package/dist/bezels/duo-fold/fold-124.webp +0 -0
- package/dist/bezels/duo-fold/fold-125.webp +0 -0
- package/dist/bezels/duo-fold/fold-126.webp +0 -0
- package/dist/bezels/duo-fold/fold-127.webp +0 -0
- package/dist/bezels/duo-fold/fold-128.webp +0 -0
- package/dist/bezels/duo-fold/fold-129.webp +0 -0
- package/dist/bezels/duo-fold/fold-130.webp +0 -0
- package/dist/bezels/duo-fold/fold-131.webp +0 -0
- package/dist/bezels/duo-fold/fold-132.webp +0 -0
- package/dist/bezels/duo-fold/fold-133.webp +0 -0
- package/dist/bezels/duo-fold/fold-134.webp +0 -0
- package/dist/bezels/duo-fold/fold-135.webp +0 -0
- package/dist/bezels/duo-fold/fold-136.webp +0 -0
- package/dist/bezels/duo-fold/fold-137.webp +0 -0
- package/dist/bezels/duo-fold/fold-138.webp +0 -0
- package/dist/bezels/duo-fold/fold-139.webp +0 -0
- package/dist/bezels/duo-fold/fold-140.webp +0 -0
- package/dist/bezels/duo-fold/fold-141.webp +0 -0
- package/dist/bezels/duo-fold/fold-142.webp +0 -0
- package/dist/bezels/duo-fold/fold-143.webp +0 -0
- package/dist/bezels/duo-fold/fold-144.webp +0 -0
- package/dist/bezels/duo-fold/fold-145.webp +0 -0
- package/dist/bezels/duo-fold/fold-146.webp +0 -0
- package/dist/bezels/duo-fold/fold-147.webp +0 -0
- package/dist/bezels/duo-fold/fold-148.webp +0 -0
- package/dist/bezels/duo-fold/fold-149.webp +0 -0
- package/dist/bezels/duo-fold/fold-150.webp +0 -0
- package/dist/bezels/duo-fold/fold-151.webp +0 -0
- package/dist/bezels/duo-fold/fold-152.webp +0 -0
- package/dist/bezels/duo-fold/fold-153.webp +0 -0
- package/dist/bezels/duo-fold/fold-154.webp +0 -0
- package/dist/bezels/duo-fold/fold-155.webp +0 -0
- package/dist/bezels/duo-fold/fold-156.webp +0 -0
- package/dist/bezels/duo-fold/fold-157.webp +0 -0
- package/dist/bezels/duo-fold/fold-158.webp +0 -0
- package/dist/bezels/duo-fold/fold-159.webp +0 -0
- package/dist/bezels/duo-fold/fold-160.webp +0 -0
- package/dist/bezels/duo-fold/fold-161.webp +0 -0
- package/dist/bezels/duo-fold/fold-162.webp +0 -0
- package/dist/bezels/duo-fold/fold-163.webp +0 -0
- package/dist/bezels/duo-fold/fold-164.webp +0 -0
- package/dist/bezels/duo-fold/fold-165.webp +0 -0
- package/dist/bezels/duo-fold/fold-166.webp +0 -0
- package/dist/bezels/duo-fold/fold-167.webp +0 -0
- package/dist/bezels/duo-fold/fold-168.webp +0 -0
- package/dist/bezels/duo-fold/fold-169.webp +0 -0
- package/dist/bezels/duo-fold/fold-170.webp +0 -0
- package/dist/bezels/duo-fold/fold-171.webp +0 -0
- package/dist/bezels/duo-fold/fold-172.webp +0 -0
- package/dist/bezels/duo-fold/fold-173.webp +0 -0
- package/dist/bezels/duo-fold/fold-174.webp +0 -0
- package/dist/bezels/duo-fold/fold-175.webp +0 -0
- package/dist/bezels/duo-fold/fold-176.webp +0 -0
- package/dist/bezels/duo-fold/fold-177.webp +0 -0
- package/dist/bezels/duo-fold/fold-178.webp +0 -0
- package/dist/bezels/duo-fold/fold-179.webp +0 -0
- package/dist/bezels/duo-fold/fold-180.webp +0 -0
- package/dist/bezels/duo-fold/still-000.webp +0 -0
- package/dist/bezels/duo-fold/still-161.webp +0 -0
- package/dist/bezels/duo-fold/still-162.webp +0 -0
- package/dist/bezels/duo-fold/still-163.webp +0 -0
- package/dist/bezels/duo-fold/still-164.webp +0 -0
- package/dist/bezels/duo-fold/still-165.webp +0 -0
- package/dist/bezels/duo-fold/still-166.webp +0 -0
- package/dist/bezels/duo-fold/still-167.webp +0 -0
- package/dist/bezels/duo-fold/still-168.webp +0 -0
- package/dist/bezels/duo-fold/still-169.webp +0 -0
- package/dist/bezels/duo-fold/still-170.webp +0 -0
- package/dist/bezels/duo-fold/still-171.webp +0 -0
- package/dist/bezels/duo-fold/still-172.webp +0 -0
- package/dist/bezels/duo-fold/still-173.webp +0 -0
- package/dist/bezels/duo-fold/still-174.webp +0 -0
- package/dist/bezels/duo-fold/still-175.webp +0 -0
- package/dist/bezels/duo-fold/still-176.webp +0 -0
- package/dist/bezels/duo-fold/still-177.webp +0 -0
- package/dist/bezels/duo-fold/still-178.webp +0 -0
- package/dist/bezels/duo-fold/still-179.webp +0 -0
- package/dist/bezels/duo-fold/still-180.webp +0 -0
- package/dist/bezels/iphone-16-plus.webp +0 -0
- package/dist/bezels/iphone-16-pro-max.webp +0 -0
- package/dist/bezels/iphone-16-pro.webp +0 -0
- package/dist/bezels/iphone-16.webp +0 -0
- package/dist/bezels/iphone-17-pro-max.webp +0 -0
- package/dist/bezels/iphone-17-pro.webp +0 -0
- package/dist/bezels/iphone-17.webp +0 -0
- package/dist/bezels/iphone-18-pro-max.webp +0 -0
- package/dist/bezels/iphone-18-pro.webp +0 -0
- package/dist/bezels/iphone-air.webp +0 -0
- package/dist/bezels/iphone-duo-inner-open-landscape.webp +0 -0
- package/dist/bezels/iphone-duo-inner-open-portrait.webp +0 -0
- package/dist/bezels/iphone-duo-outer-closed.webp +0 -0
- package/dist/bezels/iphone-se.webp +0 -0
- package/dist/bezels/pixel-10-pro-xl.webp +0 -0
- package/dist/bezels/pixel-10-pro.webp +0 -0
- package/dist/bezels/pixel-10.webp +0 -0
- package/dist/bezels/pixel-10a.webp +0 -0
- package/dist/bezels/pixel-9-pro-xl.webp +0 -0
- package/dist/bezels/pixel-9-pro.webp +0 -0
- package/dist/bezels/pixel-9.webp +0 -0
- package/dist/early.d.ts +1 -0
- package/dist/early.global.js +8 -0
- package/dist/elementsview-jnkbhzkj.js +2873 -0
- package/dist/elementsview-tf4qzmtw.js +2874 -0
- package/dist/engine/address.d.ts +31 -0
- package/dist/engine/animations.d.ts +13 -0
- package/dist/engine/barshot.d.ts +48 -0
- package/dist/engine/bezels.d.ts +140 -0
- package/dist/engine/bezelurls.d.ts +5 -0
- package/dist/engine/browserdraw.d.ts +57 -0
- package/dist/engine/browserkit.d.ts +59 -0
- package/dist/engine/browserui.d.ts +177 -0
- package/dist/engine/check.d.ts +8 -0
- package/dist/engine/chromedraw.d.ts +17 -0
- package/dist/engine/clock.d.ts +91 -0
- package/dist/engine/color.d.ts +37 -0
- package/dist/engine/describe.d.ts +49 -0
- package/dist/engine/devices.d.ts +96 -0
- package/dist/engine/dock.d.ts +53 -0
- package/dist/engine/endroom.d.ts +21 -0
- package/dist/engine/fit.d.ts +75 -0
- package/dist/engine/fold.d.ts +562 -0
- package/dist/engine/foldframes.d.ts +98 -0
- package/dist/engine/foldgl.d.ts +151 -0
- package/dist/engine/foldhand.d.ts +23 -0
- package/dist/engine/foldlook.d.ts +49 -0
- package/dist/engine/foldpage.d.ts +167 -0
- package/dist/engine/foldrun.d.ts +98 -0
- package/dist/engine/frame.d.ts +142 -0
- package/dist/engine/frameglide.d.ts +71 -0
- package/dist/engine/framekit.d.ts +7 -0
- package/dist/engine/frames.d.ts +42 -0
- package/dist/engine/fresh.d.ts +59 -0
- package/dist/engine/geo.d.ts +58 -0
- package/dist/engine/header.d.ts +16 -0
- package/dist/engine/identity.d.ts +27 -0
- package/dist/engine/index.d.ts +58 -0
- package/dist/engine/intl.d.ts +23 -0
- package/dist/engine/locale.d.ts +86 -0
- package/dist/engine/mat.d.ts +64 -0
- package/dist/engine/matchmedia.d.ts +25 -0
- package/dist/engine/matcolors.d.ts +45 -0
- package/dist/engine/matsplash.d.ts +81 -0
- package/dist/engine/media.d.ts +55 -0
- package/dist/engine/mock.d.ts +65 -0
- package/dist/engine/mockdata.d.ts +42 -0
- package/dist/engine/mockdraw.d.ts +21 -0
- package/dist/engine/morph.d.ts +214 -0
- package/dist/engine/morphrun.d.ts +49 -0
- package/dist/engine/native.d.ts +129 -0
- package/dist/engine/network.d.ts +8 -0
- package/dist/engine/notice.d.ts +15 -0
- package/dist/engine/objectfit.d.ts +35 -0
- package/dist/engine/outlines.d.ts +2 -0
- package/dist/engine/overflow.d.ts +11 -0
- package/dist/engine/owninline.d.ts +16 -0
- package/dist/engine/pagefonts.d.ts +21 -0
- package/dist/engine/pageshot.d.ts +127 -0
- package/dist/engine/placeholder.d.ts +89 -0
- package/dist/engine/pseudo.d.ts +15 -0
- package/dist/engine/ready.d.ts +9 -0
- package/dist/engine/reload.d.ts +35 -0
- package/dist/engine/remount.d.ts +30 -0
- package/dist/engine/replay.d.ts +7 -0
- package/dist/engine/safaridraw.d.ts +22 -0
- package/dist/engine/scrollbars.d.ts +17 -0
- package/dist/engine/scrollkeep.d.ts +124 -0
- package/dist/engine/spacing.d.ts +2 -0
- package/dist/engine/speed.d.ts +11 -0
- package/dist/engine/store.d.ts +68 -0
- package/dist/engine/stored.d.ts +17 -0
- package/dist/engine/style.d.ts +27 -0
- package/dist/engine/system.d.ts +15 -0
- package/dist/engine/text.d.ts +53 -0
- package/dist/engine/time.d.ts +32 -0
- package/dist/engine/touch.d.ts +20 -0
- package/dist/engine/touchdot.d.ts +71 -0
- package/dist/engine/touchmark.d.ts +27 -0
- package/dist/engine/touchpointer.d.ts +113 -0
- package/dist/engine/tree.d.ts +9 -0
- package/dist/engine/turnrun.d.ts +74 -0
- package/dist/engine/ua.d.ts +55 -0
- package/dist/engine/underneath.d.ts +7 -0
- package/dist/engine/viewportcss.d.ts +7 -0
- package/dist/engine/vision.d.ts +3 -0
- package/dist/engine/width.d.ts +56 -0
- package/dist/engine/zoom.d.ts +33 -0
- package/dist/framekit-3n7p79ht.js +8839 -0
- package/dist/framekit-g96t6nmq.js +8838 -0
- package/dist/global.d.ts +1 -0
- package/dist/grab/boxmodel.d.ts +109 -0
- package/dist/grab/boxtext.d.ts +17 -0
- package/dist/grab/card.d.ts +45 -0
- package/dist/grab/cardread.d.ts +22 -0
- package/dist/grab/cardview.d.ts +18 -0
- package/dist/grab/clipboard.d.ts +8 -0
- package/dist/grab/colors.d.ts +31 -0
- package/dist/grab/colorvalue.d.ts +40 -0
- package/dist/grab/context.d.ts +25 -0
- package/dist/grab/control.d.ts +37 -0
- package/dist/grab/copy.d.ts +7 -0
- package/dist/grab/dwell.d.ts +29 -0
- package/dist/grab/fiber.d.ts +17 -0
- package/dist/grab/fontused.d.ts +23 -0
- package/dist/grab/hit.d.ts +19 -0
- package/dist/grab/hook.d.ts +7 -0
- package/dist/grab/index.d.ts +9 -0
- package/dist/grab/inspect.d.ts +31 -0
- package/dist/grab/keys.d.ts +84 -0
- package/dist/grab/locate.d.ts +63 -0
- package/dist/grab/mode.d.ts +56 -0
- package/dist/grab/navigate.d.ts +21 -0
- package/dist/grab/outline.d.ts +16 -0
- package/dist/grab/overlay.d.ts +135 -0
- package/dist/grab/paint.d.ts +7 -0
- package/dist/grab/paths.d.ts +27 -0
- package/dist/grab/picks.d.ts +9 -0
- package/dist/grab/place.d.ts +25 -0
- package/dist/grab/preview.d.ts +12 -0
- package/dist/grab/selector.d.ts +15 -0
- package/dist/grab/source.d.ts +68 -0
- package/dist/grab/stack.d.ts +49 -0
- package/dist/grab/theme.d.ts +85 -0
- package/dist/grab/types.d.ts +52 -0
- package/dist/host.d.ts +7 -0
- package/dist/index-0casarhy.js +324 -0
- package/dist/index-2d6wvs8h.js +528 -0
- package/dist/index-33x9hxe3.js +4563 -0
- package/dist/index-5baxvd3v.js +4424 -0
- package/dist/index-78r0f8pw.js +27 -0
- package/dist/index-d0cjxjsm.js +21 -0
- package/dist/index-dvr4x91q.js +4800 -0
- package/dist/index-k015tb6c.js +357 -0
- package/dist/index-ke6v7919.js +4801 -0
- package/dist/index-peh33xjv.js +346 -0
- package/dist/index-ztnjefrh.js +23 -0
- package/dist/index-zvze25nf.js +686 -0
- package/dist/index.d.ts +116 -0
- package/dist/index.global.js +2655 -0
- package/dist/index.js +9262 -0
- package/dist/instance.d.ts +29 -0
- package/dist/react-65tgdbs8.js +22 -0
- package/dist/react-71a9ypex.js +529 -0
- package/dist/react-adky72h9.js +29 -0
- package/dist/react-carf84xv.js +4420 -0
- package/dist/react-eygws6cx.js +358 -0
- package/dist/react-h9w04skh.js +25 -0
- package/dist/react-pdvseef0.js +325 -0
- package/dist/react-qv0nykcv.js +4564 -0
- package/dist/react-sq9pkw4k.js +687 -0
- package/dist/react-xxfpfddf.js +347 -0
- package/dist/react.d.ts +6 -0
- package/dist/react.js +9255 -0
- package/dist/requests/body.d.ts +44 -0
- package/dist/requests/eventsource.d.ts +14 -0
- package/dist/requests/fetch.d.ts +14 -0
- package/dist/requests/index.d.ts +35 -0
- package/dist/requests/patch.d.ts +17 -0
- package/dist/requests/quiet.d.ts +12 -0
- package/dist/requests/record.d.ts +40 -0
- package/dist/requests/resource.d.ts +28 -0
- package/dist/requests/shared.d.ts +34 -0
- package/dist/requests/stack.d.ts +7 -0
- package/dist/requests/store.d.ts +37 -0
- package/dist/requests/types.d.ts +140 -0
- package/dist/requests/xhr.d.ts +16 -0
- package/dist/storage/cache.d.ts +32 -0
- package/dist/storage/clear.d.ts +35 -0
- package/dist/storage/cookies.d.ts +71 -0
- package/dist/storage/format.d.ts +53 -0
- package/dist/storage/idb.d.ts +62 -0
- package/dist/storage/onload.d.ts +47 -0
- package/dist/storage/presets.d.ts +79 -0
- package/dist/storage/site.d.ts +51 -0
- package/dist/storage/web.d.ts +57 -0
- package/dist/storageview-sb23henh.js +2729 -0
- package/dist/storageview-vf8v8q8j.js +2728 -0
- package/dist/styles/cascade.d.ts +59 -0
- package/dist/styles/collect.d.ts +73 -0
- package/dist/styles/declarations.d.ts +30 -0
- package/dist/styles/index.d.ts +20 -0
- package/dist/styles/inherited.d.ts +5 -0
- package/dist/styles/match.d.ts +41 -0
- package/dist/styles/selector.d.ts +36 -0
- package/dist/styles/tree.d.ts +14 -0
- package/dist/styles/types.d.ts +117 -0
- package/dist/styles/varrefs.d.ts +35 -0
- package/dist/types.d.ts +221 -0
- package/dist/ui/actions.d.ts +26 -0
- package/dist/ui/bindings.d.ts +89 -0
- package/dist/ui/boxdiagram.d.ts +50 -0
- package/dist/ui/catalog.d.ts +195 -0
- package/dist/ui/colors.d.ts +51 -0
- package/dist/ui/column.d.ts +22 -0
- package/dist/ui/copytext.d.ts +6 -0
- package/dist/ui/deviceknobs.d.ts +20 -0
- package/dist/ui/dockslide.d.ts +100 -0
- package/dist/ui/dom.d.ts +68 -0
- package/dist/ui/domtree.d.ts +143 -0
- package/dist/ui/drag.d.ts +34 -0
- package/dist/ui/editors.d.ts +30 -0
- package/dist/ui/elementsview.d.ts +32 -0
- package/dist/ui/foldslider.d.ts +48 -0
- package/dist/ui/footer.d.ts +51 -0
- package/dist/ui/hold.d.ts +20 -0
- package/dist/ui/icons.d.ts +145 -0
- package/dist/ui/inspector.d.ts +59 -0
- package/dist/ui/keys.d.ts +180 -0
- package/dist/ui/kit.d.ts +336 -0
- package/dist/ui/knobs.d.ts +41 -0
- package/dist/ui/list.d.ts +68 -0
- package/dist/ui/palette.d.ts +59 -0
- package/dist/ui/pane.d.ts +151 -0
- package/dist/ui/panel.d.ts +56 -0
- package/dist/ui/pin.d.ts +28 -0
- package/dist/ui/place.d.ts +136 -0
- package/dist/ui/prefs.d.ts +53 -0
- package/dist/ui/radio.d.ts +37 -0
- package/dist/ui/requestdetail.d.ts +56 -0
- package/dist/ui/requestformat.d.ts +142 -0
- package/dist/ui/requestparts.d.ts +312 -0
- package/dist/ui/requests.d.ts +48 -0
- package/dist/ui/rows.d.ts +72 -0
- package/dist/ui/search.d.ts +29 -0
- package/dist/ui/settings.d.ts +69 -0
- package/dist/ui/size.d.ts +105 -0
- package/dist/ui/slide.d.ts +46 -0
- package/dist/ui/stage.d.ts +24 -0
- package/dist/ui/storageaction.d.ts +22 -0
- package/dist/ui/storagecookies.d.ts +5 -0
- package/dist/ui/storagedeep.d.ts +18 -0
- package/dist/ui/storageparts.d.ts +131 -0
- package/dist/ui/storagepresets.d.ts +19 -0
- package/dist/ui/storageview.d.ts +45 -0
- package/dist/ui/storageweb.d.ts +11 -0
- package/dist/ui/styles.d.ts +1 -0
- package/dist/ui/stylesapplied.d.ts +46 -0
- package/dist/ui/stylesformat.d.ts +78 -0
- package/dist/ui/stylesview.d.ts +118 -0
- package/dist/ui/swatches.d.ts +26 -0
- package/dist/ui/syntax.d.ts +34 -0
- package/dist/ui/tooltip.d.ts +64 -0
- package/package.json +60 -4
- package/skills/devknobs/SKILL.md +214 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import type { BarsValue, BrowserValue, ClockMode, ConnectionValue, ContrastValue, DevknobsState, DevknobsStatePatch, DirValue, EdgeValue, GeoErrorValue, CustomColor, GrabColorValue, MotionValue, OnlineValue, OrientationValue, PanelValue, SaveDataValue, SchemeValue, SideValue, TransparencyValue, VisionValue } from "../types";
|
|
2
|
+
export declare const STORAGE_KEY = "devknobs";
|
|
3
|
+
/** The version of the state `STORAGE_KEY` keeps. Bump it with a change of shape, see stored.ts. */
|
|
4
|
+
export declare const STATE_VERSION = 2;
|
|
5
|
+
/**
|
|
6
|
+
* Where the panel's place is kept beside the session, in `localStorage`, so
|
|
7
|
+
* a new tab or session starts with the panel where the user last put it.
|
|
8
|
+
*/
|
|
9
|
+
export declare const PLACE_KEY = "devknobs:place";
|
|
10
|
+
/** The version of the place `PLACE_KEY` keeps. Bump it with a change of shape, see stored.ts. */
|
|
11
|
+
export declare const PLACE_VERSION = 2;
|
|
12
|
+
/** What of the panel outlives the session: its side, where it sits on it, and whether it is pinned there. */
|
|
13
|
+
export type PanelPlace = Pick<PanelValue, "side" | "y" | "top" | "edge" | "tab" | "docked">;
|
|
14
|
+
/**
|
|
15
|
+
* The rows a fresh panel lists, in the order they stand: the device, the
|
|
16
|
+
* scheme, the text size and the locale.
|
|
17
|
+
*/
|
|
18
|
+
export declare const DEFAULT_PINNED: readonly string[];
|
|
19
|
+
/**
|
|
20
|
+
* How far below the top of the viewport a fresh panel's handle sits, in px,
|
|
21
|
+
* and the panel's top with it.
|
|
22
|
+
*/
|
|
23
|
+
export declare const PANEL_START = 128;
|
|
24
|
+
export declare const DEFAULT_STATE: DevknobsState;
|
|
25
|
+
export declare const SCHEMES: SchemeValue[];
|
|
26
|
+
export declare const MOTIONS: MotionValue[];
|
|
27
|
+
export declare const CONTRASTS: ContrastValue[];
|
|
28
|
+
export declare const TRANSPARENCIES: TransparencyValue[];
|
|
29
|
+
export declare const DIRS: DirValue[];
|
|
30
|
+
export declare const GEO_ERRORS: GeoErrorValue[];
|
|
31
|
+
export declare const CLOCK_MODES: ClockMode[];
|
|
32
|
+
export declare const ONLINES: OnlineValue[];
|
|
33
|
+
export declare const CONNECTIONS: ConnectionValue[];
|
|
34
|
+
export declare const SAVE_DATAS: SaveDataValue[];
|
|
35
|
+
export declare const BARS: BarsValue[];
|
|
36
|
+
export declare const BROWSERS: BrowserValue[];
|
|
37
|
+
export declare const ORIENTATIONS: OrientationValue[];
|
|
38
|
+
export declare const EDGES: EdgeValue[];
|
|
39
|
+
export declare const SIDES: SideValue[];
|
|
40
|
+
export declare const VISIONS: VisionValue[];
|
|
41
|
+
export declare const GRAB_COLORS: Exclude<GrabColorValue, CustomColor>[];
|
|
42
|
+
/** The place of a state's panel, as `PLACE_KEY` keeps it. */
|
|
43
|
+
export declare function placeText(state: DevknobsState): string;
|
|
44
|
+
/**
|
|
45
|
+
* Read a stored state, falling back to the defaults field by field. The
|
|
46
|
+
* panel's place falls back to `place`, the one kept across sessions, before
|
|
47
|
+
* the defaults, so the session's own place wins where it has one.
|
|
48
|
+
*/
|
|
49
|
+
export declare function parse(json: string | null | undefined, place?: string | null): DevknobsState;
|
|
50
|
+
/**
|
|
51
|
+
* What reset all leaves: every knob at its default and the default rows
|
|
52
|
+
* listed, with the panel where it is, pinned or not.
|
|
53
|
+
*/
|
|
54
|
+
export declare function resetState(state: DevknobsState): DevknobsState;
|
|
55
|
+
/**
|
|
56
|
+
* Merge a patch into a state, one level deep for the object knobs. The clock
|
|
57
|
+
* takes a new anchor when it moves. A device brings its size, and the device
|
|
58
|
+
* fields follow the size the frame ends up with.
|
|
59
|
+
*/
|
|
60
|
+
export declare function merge(state: DevknobsState, patch: DevknobsStatePatch): DevknobsState;
|
|
61
|
+
export declare function load(): DevknobsState;
|
|
62
|
+
export declare function save(state: DevknobsState): void;
|
|
63
|
+
/**
|
|
64
|
+
* Keep the panel's place across sessions. Only a move the user makes writes
|
|
65
|
+
* it, so a tab that merely lays the panel out again leaves the place another
|
|
66
|
+
* tab put there alone.
|
|
67
|
+
*/
|
|
68
|
+
export declare function keepPlace(state: DevknobsState): void;
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Every item devknobs keeps in web storage is json with its version in a
|
|
3
|
+
* top-level `v`, and each key has its version as a constant beside it. One
|
|
4
|
+
* kept before items had a version reads as version 0, and its reader takes it
|
|
5
|
+
* up as the current one, so nothing kept is lost. One from a newer devknobs
|
|
6
|
+
* reads as nothing kept, and the next write here replaces it. To change an
|
|
7
|
+
* item's shape, bump its constant and have its reader take the older
|
|
8
|
+
* versions up.
|
|
9
|
+
*/
|
|
10
|
+
/** The version a stored value was kept at: its `v`, or 0 for one kept before items had one. */
|
|
11
|
+
export declare function versionOf(value: unknown): number;
|
|
12
|
+
/** Whether a stored value is from a newer devknobs than one at `current`. */
|
|
13
|
+
export declare function newer(value: unknown, current: number): boolean;
|
|
14
|
+
/** `value` as kept at version `v`. */
|
|
15
|
+
export declare function stamped<T extends object>(value: T, v: number): {
|
|
16
|
+
v: number;
|
|
17
|
+
} & T;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A stylesheet of devknobs'. Where the browser adopts constructed sheets it is
|
|
3
|
+
* one of those, which a page's Content Security Policy does not block, as it
|
|
4
|
+
* blocks a `<style>` without `'unsafe-inline'`; elsewhere it is a `<style>`.
|
|
5
|
+
*/
|
|
6
|
+
export interface OwnStyle {
|
|
7
|
+
textContent: string | null;
|
|
8
|
+
readonly sheet: CSSStyleSheet | null;
|
|
9
|
+
remove(): void;
|
|
10
|
+
}
|
|
11
|
+
type Root = Document | ShadowRoot;
|
|
12
|
+
/** The `<style>` a sheet is, or null for a constructed one. */
|
|
13
|
+
export declare function styleNode(style: OwnStyle): HTMLStyleElement | null;
|
|
14
|
+
/** Is `sheet` one devknobs constructed? */
|
|
15
|
+
export declare function isOwnSheet(sheet: CSSStyleSheet): boolean;
|
|
16
|
+
/**
|
|
17
|
+
* Style `root` with `css`: the document, or a shadow root of devknobs'. A
|
|
18
|
+
* `<style>` in its place goes at the end of the document's head or of the
|
|
19
|
+
* shadow root, before what the shadow root gets next.
|
|
20
|
+
*/
|
|
21
|
+
export declare function addStyle(root: Root, css: string): OwnStyle;
|
|
22
|
+
/** The sheet devknobs keeps on the page under `name`, if it has one. */
|
|
23
|
+
export declare function findStyle(name: string, doc?: Document): OwnStyle | null;
|
|
24
|
+
/** Every node devknobs adds to the page carries `data-devknobs`. */
|
|
25
|
+
export declare function ensureStyle(name: string, doc?: Document): OwnStyle;
|
|
26
|
+
export declare function removeStyle(name: string, doc?: Document): void;
|
|
27
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The user's own scheme and motion, for devknobs' own surfaces. A host that
|
|
3
|
+
* sets the prefers knobs for real, in the browser, hides them from every
|
|
4
|
+
* media query in the tab, the panel's included, so it reads them where the
|
|
5
|
+
* knobs do not reach and hands them here.
|
|
6
|
+
*/
|
|
7
|
+
export interface SystemMedia {
|
|
8
|
+
scheme: "light" | "dark";
|
|
9
|
+
motion: "reduce" | "no-preference";
|
|
10
|
+
}
|
|
11
|
+
/** What the host handed, or null where devknobs' own media queries tell. */
|
|
12
|
+
export declare function systemMedia(): SystemMedia | null;
|
|
13
|
+
export declare function setSystemMedia(media: SystemMedia | null): void;
|
|
14
|
+
/** Calls `listener` now and on each change. Returns the way to stop. */
|
|
15
|
+
export declare function watchSystemMedia(listener: (media: SystemMedia | null) => void): () => void;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import type { TextValue } from "../types";
|
|
2
|
+
/**
|
|
3
|
+
* The browser's default font size setting, emulated. That setting is the size
|
|
4
|
+
* `medium` resolves to, so it moves everything that leans on the initial font
|
|
5
|
+
* size: a root `font-size` in %, em, rem or a keyword (or none at all), every
|
|
6
|
+
* rem through it, and em and rem in media queries. A root size in px ignores
|
|
7
|
+
* it, and so does this knob.
|
|
8
|
+
*/
|
|
9
|
+
/** The smallest and the largest root font size the knob takes, in px. */
|
|
10
|
+
export declare const TEXT_MIN = 6;
|
|
11
|
+
export declare const TEXT_MAX = 72;
|
|
12
|
+
/**
|
|
13
|
+
* The root `font-size` a browser set to `size` would use for the author's
|
|
14
|
+
* value: each %, em, rem and keyword taken against `size` instead of 16px.
|
|
15
|
+
* Null when nothing in it leans on the setting, a px size say.
|
|
16
|
+
*/
|
|
17
|
+
export declare function emulatedFontSize(value: string, size: number): string | null;
|
|
18
|
+
/** A media query list with each em and rem taken against `size`, the way the setting moves them. */
|
|
19
|
+
export declare function emulateMediaText(text: string, size: number): string;
|
|
20
|
+
/** The value with every `var()` read through `lookup`. Null when one cannot be. */
|
|
21
|
+
export declare function substituteVars(value: string, lookup: (name: string) => string): string | null;
|
|
22
|
+
/** Split a selector list on its top-level commas. */
|
|
23
|
+
export declare function splitSelectors(text: string): string[];
|
|
24
|
+
/**
|
|
25
|
+
* A rough specificity, ids, then classes, attributes and pseudo-classes, then
|
|
26
|
+
* types, as one comparable number. Rough is enough for the few selectors that
|
|
27
|
+
* reach `<html>`.
|
|
28
|
+
*/
|
|
29
|
+
export declare function specificity(selector: string): number;
|
|
30
|
+
/** One `font-size` declaration that reaches `<html>`, with what the cascade sorts it by. */
|
|
31
|
+
export interface Declaration {
|
|
32
|
+
value: string;
|
|
33
|
+
important: boolean;
|
|
34
|
+
/** From the `style` attribute. */
|
|
35
|
+
inline: boolean;
|
|
36
|
+
/** Inside a cascade layer. */
|
|
37
|
+
layered: boolean;
|
|
38
|
+
specificity: number;
|
|
39
|
+
order: number;
|
|
40
|
+
}
|
|
41
|
+
/** The declaration the cascade picks, or null when there is none. */
|
|
42
|
+
export declare function cascade(declarations: Declaration[]): Declaration | null;
|
|
43
|
+
type MediaBearingRule = CSSRule & {
|
|
44
|
+
media: MediaList;
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* A rule's media text before text size took its em and rem to px, while that
|
|
48
|
+
* rewrite is still the one there. The prefers knobs take it as the author's.
|
|
49
|
+
*/
|
|
50
|
+
export declare function authoredMedia(rule: MediaBearingRule): string | undefined;
|
|
51
|
+
export declare function apply(value: TextValue): void;
|
|
52
|
+
export declare function reset(): void;
|
|
53
|
+
export {};
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { ClockValue, GeoValue, TimeZoneValue } from "../types";
|
|
2
|
+
/** Zones the panel offers. Kolkata, Kathmandu and Lord Howe cover the odd offsets. */
|
|
3
|
+
export declare const TIME_ZONE_PRESETS: readonly ["UTC", "America/Los_Angeles", "America/New_York", "Europe/London", "Europe/Istanbul", "Asia/Kolkata", "Asia/Kathmandu", "Asia/Tokyo", "Australia/Lord_Howe"];
|
|
4
|
+
/** The engine's own spelling of a zone, or null when it does not know the zone. */
|
|
5
|
+
export declare function canonicalZone(zone: string): string | null;
|
|
6
|
+
/** The zone to emulate, or null to leave the host zone alone. */
|
|
7
|
+
export declare function resolveTimeZone(value: TimeZoneValue, geo: GeoValue): string | null;
|
|
8
|
+
/**
|
|
9
|
+
* How far the zone's wall clock runs ahead of UTC at an instant, in ms:
|
|
10
|
+
* Europe/Istanbul is +3 h, America/New_York in winter is -5 h. An unknown
|
|
11
|
+
* zone reads as UTC.
|
|
12
|
+
*/
|
|
13
|
+
export declare function zoneOffset(time: number, zone: string): number;
|
|
14
|
+
/**
|
|
15
|
+
* Minutes to add to local time to get UTC, the way `getTimezoneOffset` reports
|
|
16
|
+
* it: Europe/Istanbul is -180, America/New_York in winter is 300.
|
|
17
|
+
*/
|
|
18
|
+
export declare function offsetMinutesFor(date: Date, timeZone: string): number;
|
|
19
|
+
/**
|
|
20
|
+
* The instant a wall clock reading names in a zone, picked the way browsers
|
|
21
|
+
* pick it for `new Date(y, m, d, ...)`: in an overlap the earlier of the two
|
|
22
|
+
* instants, in a gap the offset from before the jump, which moves the reading
|
|
23
|
+
* forward by the size of the gap. `wall` is the reading as if it were UTC.
|
|
24
|
+
*/
|
|
25
|
+
export declare function fromWall(wall: number, zone: string): number;
|
|
26
|
+
/**
|
|
27
|
+
* Emulate an IANA zone, or hand the host zone back for null, and set the
|
|
28
|
+
* clock, the real one when left out. The two share one set of patches, which
|
|
29
|
+
* go once both are off, in whichever order they went off.
|
|
30
|
+
*/
|
|
31
|
+
export declare function apply(value: string | null, clock?: ClockValue): void;
|
|
32
|
+
export declare function reset(): void;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A device's touch screen, as scripts look for one: `'ontouchstart' in
|
|
3
|
+
* window`, and `navigator.maxTouchPoints` unless the ua knob reports it. The
|
|
4
|
+
* pointer and hover media queries go through the media knobs, and the touch
|
|
5
|
+
* pointer makes the mouse act as a finger.
|
|
6
|
+
*/
|
|
7
|
+
export interface TouchValue {
|
|
8
|
+
on: boolean;
|
|
9
|
+
/** Report the touch points in `navigator.maxTouchPoints` too. */
|
|
10
|
+
points: boolean;
|
|
11
|
+
}
|
|
12
|
+
export declare function apply(value: TouchValue): void;
|
|
13
|
+
/**
|
|
14
|
+
* Give another window on this origin a touch screen, from the page above its
|
|
15
|
+
* frame before the window's own scripts run. A copy of devknobs there then
|
|
16
|
+
* finds `ontouchstart` in place and leaves it be. The window keeps it until
|
|
17
|
+
* its next load.
|
|
18
|
+
*/
|
|
19
|
+
export declare function equip(view: Window, points: boolean): void;
|
|
20
|
+
export declare function reset(): void;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import type { Rect } from "./mock";
|
|
2
|
+
import type { Point } from "./zoom";
|
|
3
|
+
/**
|
|
4
|
+
* The touch cursor over a device's whole screen, drawn by the page above the
|
|
5
|
+
* frame. The screen is the page in the frame and the browser's bars and
|
|
6
|
+
* status bar around and over it, and nothing in a frame can paint over what
|
|
7
|
+
* the page above draws on it. So the one cursor lives here, in a layer over
|
|
8
|
+
* the page and the bars, in the screen's own px: it is scaled, moved and
|
|
9
|
+
* turned with the screen, and needs no sum for any of that. Over the page the
|
|
10
|
+
* frame's copy says where the pointer is, and over the bars the pointer's own
|
|
11
|
+
* events here do. The mouse cursor is hidden on all of the screen meanwhile.
|
|
12
|
+
*/
|
|
13
|
+
export declare const TOUCH_DOT_CSS = "\n/* Over the page, the bars and the mock's island, clipped to the screen. */\n.touchdot {\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1;\n overflow: hidden;\n transform-origin: 0 0;\n pointer-events: none;\n}\n.touchdot[hidden] { display: none; }\n.touchdot .dot { position: absolute; }\n\n.dot {\n left: 0;\n top: 0;\n width: 22px;\n height: 22px;\n margin: -11px 0 0 -11px;\n pointer-events: none;\n will-change: transform;\n}\n.dot[hidden] { display: none; }\n.dot::after {\n content: \"\";\n position: absolute;\n inset: 0;\n box-sizing: border-box;\n border-radius: 50%;\n background: rgb(0 0 0 / 0.28);\n border: 1.5px solid rgb(255 255 255 / 0.85);\n box-shadow: 0 0 0 1px rgb(0 0 0 / 0.25);\n transition: transform 80ms ease-out, background-color 80ms ease-out;\n}\n.dot.pressed::after {\n transform: scale(0.82);\n background: rgb(0 0 0 / 0.45);\n}\n@media (prefers-reduced-motion: reduce) {\n .dot::after { transition: none; }\n}\n\n/* The screen is touched, not pointed at: the bars and their buttons show no mouse cursor. */\n.glass[data-touch], .glass[data-touch] * { cursor: none !important; }\n";
|
|
14
|
+
/** Who says where the pointer is: the frame's copy over the page, the page above over the bars. */
|
|
15
|
+
export type Side = "page" | "bars";
|
|
16
|
+
/** The cursor on the screen: who shows it, or null while it is hidden, and where, in css px of the screen. */
|
|
17
|
+
export interface Dot {
|
|
18
|
+
by: Side | null;
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
pressed: boolean;
|
|
22
|
+
}
|
|
23
|
+
export declare const NO_DOT: Dot;
|
|
24
|
+
/** One side's word on the pointer: where it is on the screen, or null as it leaves that side. */
|
|
25
|
+
export interface Cue {
|
|
26
|
+
from: Side;
|
|
27
|
+
at: Point | null;
|
|
28
|
+
pressed: boolean;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* The cursor after a cue. Either side takes it by showing it. Only the side
|
|
32
|
+
* that shows it can hide it: as the pointer crosses between the page and the
|
|
33
|
+
* bars, one side's goodbye and the other's hello come in no set order, and a
|
|
34
|
+
* late goodbye must not hide the cursor the other side just took.
|
|
35
|
+
*/
|
|
36
|
+
export declare function dotStep(dot: Dot, cue: Cue): Dot;
|
|
37
|
+
/** A point of the frame's page on the screen, whose corner the page starts at `origin`. */
|
|
38
|
+
export declare function fromPage(point: Point, origin: Point): Point;
|
|
39
|
+
/**
|
|
40
|
+
* A point of the window on the screen, in the screen's own px, through the
|
|
41
|
+
* box the screen is drawn in now. Right for a screen that is scaled or moved,
|
|
42
|
+
* each axis by its own, and not for one mid turn, whose box is not its shape.
|
|
43
|
+
* Null while the screen is drawn with no size.
|
|
44
|
+
*/
|
|
45
|
+
export declare function fromWindow(point: Point, drawn: Rect, size: {
|
|
46
|
+
width: number;
|
|
47
|
+
height: number;
|
|
48
|
+
}): Point | null;
|
|
49
|
+
/** What the cursor asks of the frame. */
|
|
50
|
+
export interface TouchScene {
|
|
51
|
+
/** The device's screen: holds the page and the bars. */
|
|
52
|
+
glass: HTMLElement;
|
|
53
|
+
frame: HTMLIFrameElement;
|
|
54
|
+
/** Where the page's corner is on the screen now, in css px of the screen. */
|
|
55
|
+
origin(): Point;
|
|
56
|
+
/** Is the device turning or folding? No cursor shows on a screen in motion. */
|
|
57
|
+
moving(): boolean;
|
|
58
|
+
}
|
|
59
|
+
export interface TouchDot {
|
|
60
|
+
/** The device has a touch screen and the touch pointer is on, or not. */
|
|
61
|
+
apply(on: boolean): void;
|
|
62
|
+
/** The screen's size in its own css px, and the zoom it is drawn at. */
|
|
63
|
+
fit(size: {
|
|
64
|
+
width: number;
|
|
65
|
+
height: number;
|
|
66
|
+
}, zoom: number): void;
|
|
67
|
+
/** Hide the cursor until the pointer moves again. */
|
|
68
|
+
rest(): void;
|
|
69
|
+
remove(): void;
|
|
70
|
+
}
|
|
71
|
+
export declare function createTouchDot(scene: TouchScene): TouchDot;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* What the touch cursor's two places share. The touch pointer runs in the
|
|
3
|
+
* frame's copy of the page, but the device's screen is more than that page:
|
|
4
|
+
* the browser's bars and the status bar are drawn over and around the frame
|
|
5
|
+
* by the page above. So the copy hands its cursor up as a mark, and the page
|
|
6
|
+
* above draws it over the whole screen. Where no page above takes the mark,
|
|
7
|
+
* the copy draws the cursor itself.
|
|
8
|
+
*/
|
|
9
|
+
/** Half the touch cursor, in css px. */
|
|
10
|
+
export declare const RADIUS = 11;
|
|
11
|
+
/** The cursor's look, the same wherever it is drawn. Its place and layer are the drawer's. */
|
|
12
|
+
export declare const DOT_LOOK = "\n.dot {\n left: 0;\n top: 0;\n width: 22px;\n height: 22px;\n margin: -11px 0 0 -11px;\n pointer-events: none;\n will-change: transform;\n}\n.dot[hidden] { display: none; }\n.dot::after {\n content: \"\";\n position: absolute;\n inset: 0;\n box-sizing: border-box;\n border-radius: 50%;\n background: rgb(0 0 0 / 0.28);\n border: 1.5px solid rgb(255 255 255 / 0.85);\n box-shadow: 0 0 0 1px rgb(0 0 0 / 0.25);\n transition: transform 80ms ease-out, background-color 80ms ease-out;\n}\n.dot.pressed::after {\n transform: scale(0.82);\n background: rgb(0 0 0 / 0.45);\n}\n@media (prefers-reduced-motion: reduce) {\n .dot::after { transition: none; }\n}\n";
|
|
13
|
+
/** The event the frame's copy sends on its own frame element, which the page above hears at once. */
|
|
14
|
+
export declare const MARK_EVENT = "devknobs-touch-mark";
|
|
15
|
+
/** The cursor as the frame's copy has it. */
|
|
16
|
+
export interface Mark {
|
|
17
|
+
/** Where it is, in css px of the frame's page, or null while the pointer is not on that page. */
|
|
18
|
+
at: {
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
} | null;
|
|
22
|
+
pressed: boolean;
|
|
23
|
+
/** The touch pointer is off or paused there, so the mouse is a mouse on the whole screen. */
|
|
24
|
+
held: boolean;
|
|
25
|
+
}
|
|
26
|
+
/** Read a mark that came from another window. Anything in another shape is null. */
|
|
27
|
+
export declare function readMark(detail: unknown): Mark | null;
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The mouse as a finger, the way the device toolbar in chrome devtools has it:
|
|
3
|
+
* a round touch cursor, touch events and `pointerType: "touch"` from the
|
|
4
|
+
* mouse, no hover, a drag that scrolls and flings, and a press that stays put
|
|
5
|
+
* as a tap. It runs in the page the device lives in, the frame's copy while
|
|
6
|
+
* the frame is up. A press on devknobs itself, a range slider, editable text,
|
|
7
|
+
* a scrollbar or with a button other than the main one is left to the
|
|
8
|
+
* browser, its moves and `pointerType` with it, until the button is up, and
|
|
9
|
+
* grab pauses it while it picks. The cursor goes up to the page above the
|
|
10
|
+
* frame, which draws it over the browser's bars too, and is drawn here only
|
|
11
|
+
* where no page above takes it.
|
|
12
|
+
*/
|
|
13
|
+
/** How far a press moves before it is a drag and no longer a tap, in css px. */
|
|
14
|
+
export declare const SLOP = 10;
|
|
15
|
+
/** Which ways a `touch-action` lets a finger pan. */
|
|
16
|
+
export interface Pan {
|
|
17
|
+
x: boolean;
|
|
18
|
+
y: boolean;
|
|
19
|
+
}
|
|
20
|
+
export declare function panOf(touchAction: string): Pan;
|
|
21
|
+
/** An element on the way up from the pressed one, as the pick of a scroller sees it. */
|
|
22
|
+
export interface ScrollNode {
|
|
23
|
+
touchAction: string;
|
|
24
|
+
/** Room to scroll its content each way. */
|
|
25
|
+
left: boolean;
|
|
26
|
+
right: boolean;
|
|
27
|
+
up: boolean;
|
|
28
|
+
down: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** The scroller a drag moves, by its place on the way up, and the axes it scrolls on. */
|
|
31
|
+
export interface ScrollPick {
|
|
32
|
+
index: number;
|
|
33
|
+
x: boolean;
|
|
34
|
+
y: boolean;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* The nearest element, from the pressed one up, that a drag can scroll the
|
|
38
|
+
* way `move` goes (the content's way, against the finger's), through the
|
|
39
|
+
* `touch-action` of every element on the way. An axis counts where the move
|
|
40
|
+
* goes along it at least half as far as along the other. Null where the drag
|
|
41
|
+
* scrolls nothing.
|
|
42
|
+
*/
|
|
43
|
+
export declare function pickScroller(chain: readonly ScrollNode[], move: {
|
|
44
|
+
x: number;
|
|
45
|
+
y: number;
|
|
46
|
+
}): ScrollPick | null;
|
|
47
|
+
/** Has a press moved far enough from where it went down to be a drag? */
|
|
48
|
+
export declare function passedSlop(dx: number, dy: number, slop?: number): boolean;
|
|
49
|
+
/** Where the finger was, and when, in ms. */
|
|
50
|
+
export interface Sample {
|
|
51
|
+
t: number;
|
|
52
|
+
x: number;
|
|
53
|
+
y: number;
|
|
54
|
+
}
|
|
55
|
+
/**
|
|
56
|
+
* The finger's speed at `now` in px per ms, over its last 100 ms. A finger
|
|
57
|
+
* that rested before it let go has none.
|
|
58
|
+
*/
|
|
59
|
+
export declare function velocityOf(samples: readonly Sample[], now: number): {
|
|
60
|
+
x: number;
|
|
61
|
+
y: number;
|
|
62
|
+
};
|
|
63
|
+
/** Is a release fast enough to fling? */
|
|
64
|
+
export declare function flings(velocity: {
|
|
65
|
+
x: number;
|
|
66
|
+
y: number;
|
|
67
|
+
}): boolean;
|
|
68
|
+
/**
|
|
69
|
+
* One step of a fling: how far it goes in `dt` ms at a speed that decays
|
|
70
|
+
* exponentially, the speed after, and whether it has as good as stopped.
|
|
71
|
+
*/
|
|
72
|
+
export declare function inertiaStep(velocity: {
|
|
73
|
+
x: number;
|
|
74
|
+
y: number;
|
|
75
|
+
}, dt: number): {
|
|
76
|
+
move: {
|
|
77
|
+
x: number;
|
|
78
|
+
y: number;
|
|
79
|
+
};
|
|
80
|
+
velocity: {
|
|
81
|
+
x: number;
|
|
82
|
+
y: number;
|
|
83
|
+
};
|
|
84
|
+
done: boolean;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* Does a `toggle` or `beforetoggle` event tell of something that joins the
|
|
88
|
+
* top layer, where the last to come in paints over the rest? A popover or a
|
|
89
|
+
* dialog that opens does. The cursor's own host and a `details` do not.
|
|
90
|
+
*/
|
|
91
|
+
export declare function raises(change: {
|
|
92
|
+
newState: unknown;
|
|
93
|
+
tag: string;
|
|
94
|
+
own: boolean;
|
|
95
|
+
}): boolean;
|
|
96
|
+
/** Did a change of an `open` attribute open a dialog? For browsers whose dialogs send no `toggle`. */
|
|
97
|
+
export declare function dialogOpened(change: {
|
|
98
|
+
tag: string;
|
|
99
|
+
was: string | null;
|
|
100
|
+
open: boolean;
|
|
101
|
+
}): boolean;
|
|
102
|
+
/**
|
|
103
|
+
* The first thing on an event's path, from the target out, that is in the top
|
|
104
|
+
* layer. The path goes through shadow roots, where no `toggle` comes out of.
|
|
105
|
+
*/
|
|
106
|
+
export declare function topLayerOf<T>(path: readonly unknown[], inTopLayer: (node: unknown) => node is T): T | null;
|
|
107
|
+
export declare function apply(on: boolean): void;
|
|
108
|
+
export declare function reset(): void;
|
|
109
|
+
/**
|
|
110
|
+
* Hold the touch pointer while grab picks: the mouse is a mouse again, so
|
|
111
|
+
* grab sees it hover, and no drag scrolls or touch goes out until it ends.
|
|
112
|
+
*/
|
|
113
|
+
export declare function pause(on: boolean): void;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/** Is this node devknobs' own, or inside one of its shadow roots? */
|
|
2
|
+
export declare function isOwn(node: Node | null): boolean;
|
|
3
|
+
/**
|
|
4
|
+
* Visit every element of the page: the document's, then those inside every open
|
|
5
|
+
* shadow root, nested ones too. devknobs' own hosts and their roots are skipped.
|
|
6
|
+
*/
|
|
7
|
+
export declare function walk(visit: (element: Element) => void): void;
|
|
8
|
+
/** Every open shadow root on the page, devknobs' own left out. */
|
|
9
|
+
export declare function shadowRoots(): ShadowRoot[];
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import type { Rect } from "./mock";
|
|
2
|
+
import { type Pose } from "./morph";
|
|
3
|
+
import type { ViewportValue } from "./width";
|
|
4
|
+
/**
|
|
5
|
+
* Turns a device in view, case and page as one, and darkens the page on its
|
|
6
|
+
* screen while it is laid out the other way, as the phone fades through black.
|
|
7
|
+
* A black cover over the page, not a filter on it, so the page stays as cheap
|
|
8
|
+
* to draw as ever. What it needs of the frame comes in a `TurnScene`, so it
|
|
9
|
+
* holds no node of its own.
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* What a device turning moves: the element that holds the case and the
|
|
13
|
+
* screen, its top left in the letterbox and the scale it is drawn at there,
|
|
14
|
+
* where the screen stood as the turn started, and the cover over its page.
|
|
15
|
+
*/
|
|
16
|
+
export interface Spin {
|
|
17
|
+
unit: HTMLElement;
|
|
18
|
+
corner: {
|
|
19
|
+
x: number;
|
|
20
|
+
y: number;
|
|
21
|
+
};
|
|
22
|
+
base: number;
|
|
23
|
+
start: Rect;
|
|
24
|
+
cover: HTMLElement;
|
|
25
|
+
}
|
|
26
|
+
/** What a device turning asks of the frame, as it starts. */
|
|
27
|
+
export interface TurnScene {
|
|
28
|
+
/** The element that holds the case and the screen. */
|
|
29
|
+
unit: HTMLElement;
|
|
30
|
+
/** The mat around the frame, which the turn is measured in. */
|
|
31
|
+
letterbox: HTMLElement;
|
|
32
|
+
/** Holds the page and the bars, which the cover goes over. */
|
|
33
|
+
glass: HTMLElement;
|
|
34
|
+
/** The frame the page is in. */
|
|
35
|
+
frame: HTMLIFrameElement;
|
|
36
|
+
/** Darkens the page on the screen while it is laid out the other way, or as a foldable folds. */
|
|
37
|
+
cover: HTMLElement;
|
|
38
|
+
/** The scale the unit is drawn at. */
|
|
39
|
+
base: number;
|
|
40
|
+
/** The page's color. */
|
|
41
|
+
background(): string;
|
|
42
|
+
/** Where the screen is drawn now, in the letterbox. */
|
|
43
|
+
screenRect(): Rect;
|
|
44
|
+
}
|
|
45
|
+
/** Is a device turning? */
|
|
46
|
+
export declare function turning(): boolean;
|
|
47
|
+
/** Darken the page under the cover `share` of the way to black, none of it at rest. */
|
|
48
|
+
export declare function darken(node: HTMLElement, share: number): void;
|
|
49
|
+
/** Darken the page under the cover `share` of the way, and stop it where it was going. */
|
|
50
|
+
export declare function coverTo(node: HTMLElement, share: number): void;
|
|
51
|
+
/**
|
|
52
|
+
* Turn the device to `to` a frame at a time, from where a turn on its way got
|
|
53
|
+
* to, or from where it stands, in view all along. In its last part the page
|
|
54
|
+
* goes dark, `done` draws the device the way it ends up, in the same frame as
|
|
55
|
+
* the turn's last, and the page laid out the other way comes out of the dark.
|
|
56
|
+
* A turn back to the way the page is laid out lightens it as it goes. A quarter turn takes
|
|
57
|
+
* the whole time.
|
|
58
|
+
*/
|
|
59
|
+
export declare function turnTo(turn: Spin, to: Pose, done: () => void): void;
|
|
60
|
+
/**
|
|
61
|
+
* Turn the device a quarter by `angle` onto the screen at `to`, in view all
|
|
62
|
+
* along, case and page as one, and `draw` the knobs once it is there. A turn
|
|
63
|
+
* back while it turns goes back from where it got to. Without a scene or a
|
|
64
|
+
* place to go, the knobs are drawn at once.
|
|
65
|
+
*/
|
|
66
|
+
export declare function turnDevice(value: ViewportValue, angle: number, to: Rect | null, scene: TurnScene | null, draw: (value: ViewportValue) => void): void;
|
|
67
|
+
/** The turn goes on, and the frame takes these knobs once it is there. */
|
|
68
|
+
export declare function holdTurn(value: ViewportValue): void;
|
|
69
|
+
/** Land a device turning where it goes, at once, the page lit. */
|
|
70
|
+
export declare function finishTurn(): void;
|
|
71
|
+
/** Stop a device turning where it is, the page lit. */
|
|
72
|
+
export declare function stopTurn(): void;
|
|
73
|
+
/** The frame is gone, and the knobs a turn would draw with it. */
|
|
74
|
+
export declare function forgetTurn(): void;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { UaValue } from "../types";
|
|
2
|
+
/** A brand of the UA client hints, with its version. */
|
|
3
|
+
export interface UaBrand {
|
|
4
|
+
brand: string;
|
|
5
|
+
version: string;
|
|
6
|
+
}
|
|
7
|
+
/** What `getHighEntropyValues` adds to the brands, `mobile` and `platform`. */
|
|
8
|
+
export interface UaHints {
|
|
9
|
+
platformVersion: string;
|
|
10
|
+
model: string;
|
|
11
|
+
architecture: string;
|
|
12
|
+
bitness: string;
|
|
13
|
+
/** The brands again, each with its full version. */
|
|
14
|
+
fullVersionList: readonly UaBrand[];
|
|
15
|
+
uaFullVersion: string;
|
|
16
|
+
}
|
|
17
|
+
export interface UaPreset {
|
|
18
|
+
id: string;
|
|
19
|
+
label: string;
|
|
20
|
+
userAgent: string;
|
|
21
|
+
platform: string;
|
|
22
|
+
vendor: string;
|
|
23
|
+
mobile: boolean;
|
|
24
|
+
/** The UA client hint brands, major versions only. Empty where the browser has no `userAgentData`. */
|
|
25
|
+
brands: readonly UaBrand[];
|
|
26
|
+
/** The UA client hint platform, such as `Android` or `macOS`. */
|
|
27
|
+
uaPlatform: string;
|
|
28
|
+
maxTouchPoints: number;
|
|
29
|
+
/** `navigator.appVersion`. Left out, it is the user agent after `Mozilla/`. */
|
|
30
|
+
appVersion?: string;
|
|
31
|
+
/** Left out where there is no `userAgentData` to ask. */
|
|
32
|
+
hints?: UaHints;
|
|
33
|
+
}
|
|
34
|
+
export declare const UA_PRESETS: readonly UaPreset[];
|
|
35
|
+
export declare function uaPreset(id: string): UaPreset | undefined;
|
|
36
|
+
/** The user agent the knob sets, or an empty string while it leaves the browser's own. */
|
|
37
|
+
export declare function userAgentOf(value: UaValue): string;
|
|
38
|
+
/** `navigator.appVersion` for a user agent, as Chromium and Safari derive it. */
|
|
39
|
+
export declare function appVersionOf(userAgent: string): string;
|
|
40
|
+
/**
|
|
41
|
+
* Put a browser's user agent on `navigator`: the string, `appVersion`,
|
|
42
|
+
* `platform`, `vendor`, `maxTouchPoints` and `userAgentData`, all of them
|
|
43
|
+
* from the same browser. Safari and Firefox have no `userAgentData`, so their
|
|
44
|
+
* presets take it away. A custom string sets the string alone, as Chrome
|
|
45
|
+
* DevTools does: the rest stays the browser's own, and a `userAgentData` the
|
|
46
|
+
* browser has reports no brands. `scope` is the window to patch, another one
|
|
47
|
+
* on this origin too.
|
|
48
|
+
*/
|
|
49
|
+
export declare function apply(value: UaValue, scope?: object): void;
|
|
50
|
+
/** The browser's own `navigator.platform`, whatever preset is on. */
|
|
51
|
+
export declare function realPlatform(): string;
|
|
52
|
+
/** Whether the browser runs on an Apple platform, where shortcuts read `⌘` and `⇧`. */
|
|
53
|
+
export declare function isMac(): boolean;
|
|
54
|
+
/** Hand every field back to the browser. */
|
|
55
|
+
export declare function reset(scope?: object): void;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Hide the page under the frame, what it adds to the body later too, and give
|
|
3
|
+
* it plain dialogs, until `uncover`.
|
|
4
|
+
*/
|
|
5
|
+
export declare function cover(body: HTMLElement): void;
|
|
6
|
+
/** Give the page under the frame back exactly as it was. */
|
|
7
|
+
export declare function uncover(): void;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The letterbox around the frame. It lives in a shadow root like the panel,
|
|
3
|
+
* so page css cannot reach it. A dark cutting mat reads as chrome in light and
|
|
4
|
+
* dark, under a white page and a near black mock alike. Its grid and rulers
|
|
5
|
+
* stay put from the top left as the frame is fitted or zoomed.
|
|
6
|
+
*/
|
|
7
|
+
export declare const VIEWPORT_CSS: string;
|