forgebook 0.1.3 → 0.1.5

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 (379) hide show
  1. package/README.md +99 -6
  2. package/dist/bin/forgebook/agentClient.d.ts +17 -0
  3. package/dist/bin/forgebook/agentClient.d.ts.map +1 -1
  4. package/dist/bin/forgebook/agentClient.js +21 -0
  5. package/dist/bin/forgebook/agentClient.js.map +1 -1
  6. package/dist/bin/forgebook/agentLoopCommands.d.mts +9 -0
  7. package/dist/bin/forgebook/agentLoopCommands.d.mts.map +1 -0
  8. package/dist/bin/forgebook/agentLoopCommands.mjs +217 -0
  9. package/dist/bin/forgebook/agentLoopCommands.mjs.map +1 -0
  10. package/dist/bin/forgebook/agentText.d.ts +37 -1
  11. package/dist/bin/forgebook/agentText.d.ts.map +1 -1
  12. package/dist/bin/forgebook/agentText.js +49 -2
  13. package/dist/bin/forgebook/agentText.js.map +1 -1
  14. package/dist/bin/forgebook/agents.md +51 -0
  15. package/dist/bin/forgebook/agentsText.d.ts +29 -0
  16. package/dist/bin/forgebook/agentsText.d.ts.map +1 -0
  17. package/dist/bin/forgebook/agentsText.js +48 -0
  18. package/dist/bin/forgebook/agentsText.js.map +1 -0
  19. package/dist/bin/forgebook/catalogueCommands.d.ts +51 -0
  20. package/dist/bin/forgebook/catalogueCommands.d.ts.map +1 -0
  21. package/dist/bin/forgebook/catalogueCommands.js +90 -0
  22. package/dist/bin/forgebook/catalogueCommands.js.map +1 -0
  23. package/dist/bin/forgebook/errorsRun.d.ts +27 -0
  24. package/dist/bin/forgebook/errorsRun.d.ts.map +1 -0
  25. package/dist/bin/forgebook/errorsRun.js +60 -0
  26. package/dist/bin/forgebook/errorsRun.js.map +1 -0
  27. package/dist/bin/forgebook/forgebook.mjs +121 -86
  28. package/dist/bin/forgebook/forgebook.mjs.map +1 -1
  29. package/dist/bin/forgebook/importers/storybook.d.ts +53 -0
  30. package/dist/bin/forgebook/importers/storybook.d.ts.map +1 -0
  31. package/dist/bin/forgebook/importers/storybook.js +318 -0
  32. package/dist/bin/forgebook/importers/storybook.js.map +1 -0
  33. package/dist/bin/forgebook/initCommands.d.mts +9 -0
  34. package/dist/bin/forgebook/initCommands.d.mts.map +1 -0
  35. package/dist/bin/forgebook/initCommands.mjs +86 -0
  36. package/dist/bin/forgebook/initCommands.mjs.map +1 -0
  37. package/dist/bin/forgebook/initConfig.d.ts +22 -0
  38. package/dist/bin/forgebook/initConfig.d.ts.map +1 -0
  39. package/dist/bin/forgebook/initConfig.js +51 -0
  40. package/dist/bin/forgebook/initConfig.js.map +1 -0
  41. package/dist/bin/forgebook/mcpTools.d.ts +29 -3
  42. package/dist/bin/forgebook/mcpTools.d.ts.map +1 -1
  43. package/dist/bin/forgebook/mcpTools.js +130 -7
  44. package/dist/bin/forgebook/mcpTools.js.map +1 -1
  45. package/dist/bin/forgebook/newStories.d.ts +27 -0
  46. package/dist/bin/forgebook/newStories.d.ts.map +1 -0
  47. package/dist/bin/forgebook/newStories.js +109 -0
  48. package/dist/bin/forgebook/newStories.js.map +1 -0
  49. package/dist/bin/forgebook/newStoriesFile.d.ts +18 -0
  50. package/dist/bin/forgebook/newStoriesFile.d.ts.map +1 -0
  51. package/dist/bin/forgebook/newStoriesFile.js +58 -0
  52. package/dist/bin/forgebook/newStoriesFile.js.map +1 -0
  53. package/dist/bin/forgebook/storyCheckRun.d.ts +49 -0
  54. package/dist/bin/forgebook/storyCheckRun.d.ts.map +1 -0
  55. package/dist/bin/forgebook/storyCheckRun.js +178 -0
  56. package/dist/bin/forgebook/storyCheckRun.js.map +1 -0
  57. package/dist/bin/forgebook/touchWindowRun.d.ts +17 -0
  58. package/dist/bin/forgebook/touchWindowRun.d.ts.map +1 -0
  59. package/dist/bin/forgebook/touchWindowRun.js +21 -0
  60. package/dist/bin/forgebook/touchWindowRun.js.map +1 -0
  61. package/dist/bin/forgebook-docs/catalogueDocs.d.ts +24 -0
  62. package/dist/bin/forgebook-docs/catalogueDocs.d.ts.map +1 -0
  63. package/dist/bin/forgebook-docs/catalogueDocs.js +71 -0
  64. package/dist/bin/forgebook-docs/catalogueDocs.js.map +1 -0
  65. package/dist/bin/forgebook-docs/catalogueDocs.types.d.ts +8 -0
  66. package/dist/bin/forgebook-docs/catalogueDocs.types.d.ts.map +1 -1
  67. package/dist/bin/forgebook-docs/catalogueMarkdown.d.ts +3 -1
  68. package/dist/bin/forgebook-docs/catalogueMarkdown.d.ts.map +1 -1
  69. package/dist/bin/forgebook-docs/catalogueMarkdown.js +62 -42
  70. package/dist/bin/forgebook-docs/catalogueMarkdown.js.map +1 -1
  71. package/dist/bin/forgebook-docs/catalogueOptions.d.ts +39 -0
  72. package/dist/bin/forgebook-docs/catalogueOptions.d.ts.map +1 -0
  73. package/dist/bin/forgebook-docs/catalogueOptions.js +76 -0
  74. package/dist/bin/forgebook-docs/catalogueOptions.js.map +1 -0
  75. package/dist/bin/forgebook-docs/collectDocs.d.ts +3 -1
  76. package/dist/bin/forgebook-docs/collectDocs.d.ts.map +1 -1
  77. package/dist/bin/forgebook-docs/collectDocs.js +37 -13
  78. package/dist/bin/forgebook-docs/collectDocs.js.map +1 -1
  79. package/dist/bin/forgebook-docs/forgebook-docs.mjs +17 -80
  80. package/dist/bin/forgebook-docs/forgebook-docs.mjs.map +1 -1
  81. package/dist/bin/forgebook-docs/llmsText.d.ts +24 -0
  82. package/dist/bin/forgebook-docs/llmsText.d.ts.map +1 -0
  83. package/dist/bin/forgebook-docs/llmsText.js +33 -0
  84. package/dist/bin/forgebook-docs/llmsText.js.map +1 -0
  85. package/dist/bin/forgebook-docs/sourceId.d.ts +9 -0
  86. package/dist/bin/forgebook-docs/sourceId.d.ts.map +1 -0
  87. package/dist/bin/forgebook-docs/sourceId.js +45 -0
  88. package/dist/bin/forgebook-docs/sourceId.js.map +1 -0
  89. package/dist/bin/frameworkDocs.d.ts +10 -0
  90. package/dist/bin/frameworkDocs.d.ts.map +1 -0
  91. package/dist/bin/frameworkDocs.js +43 -0
  92. package/dist/bin/frameworkDocs.js.map +1 -0
  93. package/dist/src/argTypes.d.ts +23 -0
  94. package/dist/src/argTypes.d.ts.map +1 -1
  95. package/dist/src/argTypes.js +27 -0
  96. package/dist/src/argTypes.js.map +1 -1
  97. package/dist/src/catalogue.d.ts +70 -3
  98. package/dist/src/catalogue.d.ts.map +1 -1
  99. package/dist/src/catalogue.js +85 -3
  100. package/dist/src/catalogue.js.map +1 -1
  101. package/dist/src/controlKeys.d.ts +85 -0
  102. package/dist/src/controlKeys.d.ts.map +1 -0
  103. package/dist/src/controlKeys.js +118 -0
  104. package/dist/src/controlKeys.js.map +1 -0
  105. package/dist/src/frame/frame.css +33 -2
  106. package/dist/src/frame/frameView.d.ts +2 -2
  107. package/dist/src/frame/frameView.d.ts.map +1 -1
  108. package/dist/src/frame/frameView.js +7 -3
  109. package/dist/src/frame/frameView.js.map +1 -1
  110. package/dist/src/frame/mountFrame.d.ts.map +1 -1
  111. package/dist/src/frame/mountFrame.js +30 -2
  112. package/dist/src/frame/mountFrame.js.map +1 -1
  113. package/dist/src/frame/spillOutline.d.ts +10 -0
  114. package/dist/src/frame/spillOutline.d.ts.map +1 -0
  115. package/dist/src/frame/spillOutline.js +80 -0
  116. package/dist/src/frame/spillOutline.js.map +1 -0
  117. package/dist/src/frame/touchDots.d.ts +32 -0
  118. package/dist/src/frame/touchDots.d.ts.map +1 -0
  119. package/dist/src/frame/touchDots.js +52 -0
  120. package/dist/src/frame/touchDots.js.map +1 -0
  121. package/dist/src/frame/touchEvents.d.ts +66 -0
  122. package/dist/src/frame/touchEvents.d.ts.map +1 -0
  123. package/dist/src/frame/touchEvents.js +152 -0
  124. package/dist/src/frame/touchEvents.js.map +1 -0
  125. package/dist/src/frame/touchGesture.d.ts +80 -0
  126. package/dist/src/frame/touchGesture.d.ts.map +1 -0
  127. package/dist/src/frame/touchGesture.js +87 -0
  128. package/dist/src/frame/touchGesture.js.map +1 -0
  129. package/dist/src/frame/touchLayer.d.ts +7 -0
  130. package/dist/src/frame/touchLayer.d.ts.map +1 -0
  131. package/dist/src/frame/touchLayer.js +399 -0
  132. package/dist/src/frame/touchLayer.js.map +1 -0
  133. package/dist/src/frame/touchScroll.d.ts +51 -0
  134. package/dist/src/frame/touchScroll.d.ts.map +1 -0
  135. package/dist/src/frame/touchScroll.js +137 -0
  136. package/dist/src/frame/touchScroll.js.map +1 -0
  137. package/dist/src/liveErrors.d.ts +57 -0
  138. package/dist/src/liveErrors.d.ts.map +1 -0
  139. package/dist/src/liveErrors.js +52 -0
  140. package/dist/src/liveErrors.js.map +1 -0
  141. package/dist/src/messages.d.ts +12 -0
  142. package/dist/src/messages.d.ts.map +1 -1
  143. package/dist/src/messages.js +4 -0
  144. package/dist/src/messages.js.map +1 -1
  145. package/dist/src/namedViews.d.ts +80 -0
  146. package/dist/src/namedViews.d.ts.map +1 -0
  147. package/dist/src/namedViews.js +88 -0
  148. package/dist/src/namedViews.js.map +1 -0
  149. package/dist/src/realTouch.d.ts +21 -0
  150. package/dist/src/realTouch.d.ts.map +1 -0
  151. package/dist/src/realTouch.js +16 -0
  152. package/dist/src/realTouch.js.map +1 -0
  153. package/dist/src/shell/AppearanceMenu.d.ts +15 -0
  154. package/dist/src/shell/AppearanceMenu.d.ts.map +1 -0
  155. package/dist/src/shell/AppearanceMenu.js +28 -0
  156. package/dist/src/shell/AppearanceMenu.js.map +1 -0
  157. package/dist/src/shell/BoxWidth.d.ts +40 -0
  158. package/dist/src/shell/BoxWidth.d.ts.map +1 -0
  159. package/dist/src/shell/BoxWidth.js +56 -0
  160. package/dist/src/shell/BoxWidth.js.map +1 -0
  161. package/dist/src/shell/ComponentPage.d.ts +17 -1
  162. package/dist/src/shell/ComponentPage.d.ts.map +1 -1
  163. package/dist/src/shell/ComponentPage.js +19 -54
  164. package/dist/src/shell/ComponentPage.js.map +1 -1
  165. package/dist/src/shell/ControlKeyField.d.ts +21 -0
  166. package/dist/src/shell/ControlKeyField.d.ts.map +1 -0
  167. package/dist/src/shell/ControlKeyField.js +46 -0
  168. package/dist/src/shell/ControlKeyField.js.map +1 -0
  169. package/dist/src/shell/ControlRow.d.ts +31 -0
  170. package/dist/src/shell/ControlRow.d.ts.map +1 -0
  171. package/dist/src/shell/ControlRow.js +30 -0
  172. package/dist/src/shell/ControlRow.js.map +1 -0
  173. package/dist/src/shell/Example.d.ts +58 -0
  174. package/dist/src/shell/Example.d.ts.map +1 -0
  175. package/dist/src/shell/Example.js +89 -0
  176. package/dist/src/shell/Example.js.map +1 -0
  177. package/dist/src/shell/InfoTip.d.ts +23 -0
  178. package/dist/src/shell/InfoTip.d.ts.map +1 -0
  179. package/dist/src/shell/InfoTip.js +51 -0
  180. package/dist/src/shell/InfoTip.js.map +1 -0
  181. package/dist/src/shell/NamedViews.d.ts +23 -0
  182. package/dist/src/shell/NamedViews.d.ts.map +1 -0
  183. package/dist/src/shell/NamedViews.js +49 -0
  184. package/dist/src/shell/NamedViews.js.map +1 -0
  185. package/dist/src/shell/PinnedControl.d.ts +25 -0
  186. package/dist/src/shell/PinnedControl.d.ts.map +1 -0
  187. package/dist/src/shell/PinnedControl.js +82 -0
  188. package/dist/src/shell/PinnedControl.js.map +1 -0
  189. package/dist/src/shell/PropsTab.d.ts +5 -2
  190. package/dist/src/shell/PropsTab.d.ts.map +1 -1
  191. package/dist/src/shell/PropsTab.js +12 -15
  192. package/dist/src/shell/PropsTab.js.map +1 -1
  193. package/dist/src/shell/Shell.d.ts.map +1 -1
  194. package/dist/src/shell/Shell.js +27 -2
  195. package/dist/src/shell/Shell.js.map +1 -1
  196. package/dist/src/shell/Sidebar.d.ts +11 -9
  197. package/dist/src/shell/Sidebar.d.ts.map +1 -1
  198. package/dist/src/shell/Sidebar.js +48 -42
  199. package/dist/src/shell/Sidebar.js.map +1 -1
  200. package/dist/src/shell/SidebarEntries.d.ts +50 -0
  201. package/dist/src/shell/SidebarEntries.d.ts.map +1 -0
  202. package/dist/src/shell/SidebarEntries.js +51 -0
  203. package/dist/src/shell/SidebarEntries.js.map +1 -0
  204. package/dist/src/shell/Stage.d.ts.map +1 -1
  205. package/dist/src/shell/Stage.js +19 -2
  206. package/dist/src/shell/Stage.js.map +1 -1
  207. package/dist/src/shell/Toolbar.d.ts +7 -3
  208. package/dist/src/shell/Toolbar.d.ts.map +1 -1
  209. package/dist/src/shell/Toolbar.js +38 -68
  210. package/dist/src/shell/Toolbar.js.map +1 -1
  211. package/dist/src/shell/ToolbarControl.d.ts +47 -0
  212. package/dist/src/shell/ToolbarControl.d.ts.map +1 -0
  213. package/dist/src/shell/ToolbarControl.js +150 -0
  214. package/dist/src/shell/ToolbarControl.js.map +1 -0
  215. package/dist/src/shell/UsedIn.d.ts +38 -0
  216. package/dist/src/shell/UsedIn.d.ts.map +1 -0
  217. package/dist/src/shell/UsedIn.js +77 -0
  218. package/dist/src/shell/UsedIn.js.map +1 -0
  219. package/dist/src/shell/ViewMenu.d.ts +37 -0
  220. package/dist/src/shell/ViewMenu.d.ts.map +1 -0
  221. package/dist/src/shell/ViewMenu.js +219 -0
  222. package/dist/src/shell/ViewMenu.js.map +1 -0
  223. package/dist/src/shell/controlCycle.d.ts +28 -0
  224. package/dist/src/shell/controlCycle.d.ts.map +1 -0
  225. package/dist/src/shell/controlCycle.js +51 -0
  226. package/dist/src/shell/controlCycle.js.map +1 -0
  227. package/dist/src/shell/dockTabs.d.ts +3 -0
  228. package/dist/src/shell/dockTabs.d.ts.map +1 -1
  229. package/dist/src/shell/dockTabs.js +1 -1
  230. package/dist/src/shell/dockTabs.js.map +1 -1
  231. package/dist/src/shell/icons.d.ts +7 -0
  232. package/dist/src/shell/icons.d.ts.map +1 -1
  233. package/dist/src/shell/icons.js +8 -1
  234. package/dist/src/shell/icons.js.map +1 -1
  235. package/dist/src/shell/keyboard.d.ts +2 -1
  236. package/dist/src/shell/keyboard.d.ts.map +1 -1
  237. package/dist/src/shell/keyboard.js +5 -2
  238. package/dist/src/shell/keyboard.js.map +1 -1
  239. package/dist/src/shell/shell.css +876 -244
  240. package/dist/src/shell/strings.d.ts +46 -0
  241. package/dist/src/shell/strings.d.ts.map +1 -1
  242. package/dist/src/shell/strings.js +46 -0
  243. package/dist/src/shell/strings.js.map +1 -1
  244. package/dist/src/shell/useAppearance.d.ts +17 -0
  245. package/dist/src/shell/useAppearance.d.ts.map +1 -0
  246. package/dist/src/shell/useAppearance.js +36 -0
  247. package/dist/src/shell/useAppearance.js.map +1 -0
  248. package/dist/src/shell/useControlKeys.d.ts +23 -0
  249. package/dist/src/shell/useControlKeys.d.ts.map +1 -0
  250. package/dist/src/shell/useControlKeys.js +44 -0
  251. package/dist/src/shell/useControlKeys.js.map +1 -0
  252. package/dist/src/shell/useFold.d.ts +27 -0
  253. package/dist/src/shell/useFold.d.ts.map +1 -0
  254. package/dist/src/shell/useFold.js +87 -0
  255. package/dist/src/shell/useFold.js.map +1 -0
  256. package/dist/src/shell/useFrameMessages.d.ts +2 -0
  257. package/dist/src/shell/useFrameMessages.d.ts.map +1 -1
  258. package/dist/src/shell/useFrameMessages.js +3 -0
  259. package/dist/src/shell/useFrameMessages.js.map +1 -1
  260. package/dist/src/shell/useFullPage.d.ts +45 -0
  261. package/dist/src/shell/useFullPage.d.ts.map +1 -0
  262. package/dist/src/shell/useFullPage.js +149 -0
  263. package/dist/src/shell/useFullPage.js.map +1 -0
  264. package/dist/src/shell/usePopover.d.ts +17 -3
  265. package/dist/src/shell/usePopover.d.ts.map +1 -1
  266. package/dist/src/shell/usePopover.js +65 -4
  267. package/dist/src/shell/usePopover.js.map +1 -1
  268. package/dist/src/shell/useStored.d.ts +13 -2
  269. package/dist/src/shell/useStored.d.ts.map +1 -1
  270. package/dist/src/shell/useStored.js +1 -1
  271. package/dist/src/shell/useStored.js.map +1 -1
  272. package/dist/src/shell/useToolbarLayout.d.ts +39 -0
  273. package/dist/src/shell/useToolbarLayout.d.ts.map +1 -0
  274. package/dist/src/shell/useToolbarLayout.js +58 -0
  275. package/dist/src/shell/useToolbarLayout.js.map +1 -0
  276. package/dist/src/shell/useToolbarOverflow.d.ts +31 -0
  277. package/dist/src/shell/useToolbarOverflow.d.ts.map +1 -0
  278. package/dist/src/shell/useToolbarOverflow.js +62 -0
  279. package/dist/src/shell/useToolbarOverflow.js.map +1 -0
  280. package/dist/src/shell/useWorstCase.d.ts +46 -0
  281. package/dist/src/shell/useWorstCase.d.ts.map +1 -0
  282. package/dist/src/shell/useWorstCase.js +42 -0
  283. package/dist/src/shell/useWorstCase.js.map +1 -0
  284. package/dist/src/shell/worstArgs.d.ts +42 -0
  285. package/dist/src/shell/worstArgs.d.ts.map +1 -0
  286. package/dist/src/shell/worstArgs.js +47 -0
  287. package/dist/src/shell/worstArgs.js.map +1 -0
  288. package/dist/src/spills.d.ts +31 -0
  289. package/dist/src/spills.d.ts.map +1 -0
  290. package/dist/src/spills.js +65 -0
  291. package/dist/src/spills.js.map +1 -0
  292. package/dist/src/storyCheck.d.ts +105 -0
  293. package/dist/src/storyCheck.d.ts.map +1 -0
  294. package/dist/src/storyCheck.js +63 -0
  295. package/dist/src/storyCheck.js.map +1 -0
  296. package/dist/src/switches.d.ts +26 -4
  297. package/dist/src/switches.d.ts.map +1 -1
  298. package/dist/src/switches.js +50 -5
  299. package/dist/src/switches.js.map +1 -1
  300. package/dist/src/toolbarLayout.d.ts +119 -0
  301. package/dist/src/toolbarLayout.d.ts.map +1 -0
  302. package/dist/src/toolbarLayout.js +155 -0
  303. package/dist/src/toolbarLayout.js.map +1 -0
  304. package/dist/src/usedIn.d.ts +60 -0
  305. package/dist/src/usedIn.d.ts.map +1 -0
  306. package/dist/src/usedIn.js +92 -0
  307. package/dist/src/usedIn.js.map +1 -0
  308. package/dist/src/viewState.d.ts +9 -11
  309. package/dist/src/viewState.d.ts.map +1 -1
  310. package/dist/src/viewState.js +24 -20
  311. package/dist/src/viewState.js.map +1 -1
  312. package/dist/src/viewWords.d.ts +26 -0
  313. package/dist/src/viewWords.d.ts.map +1 -0
  314. package/dist/src/viewWords.js +29 -0
  315. package/dist/src/viewWords.js.map +1 -0
  316. package/dist/src/vite/adapter.d.ts +13 -4
  317. package/dist/src/vite/adapter.d.ts.map +1 -1
  318. package/dist/src/vite/adapter.js +4 -2
  319. package/dist/src/vite/adapter.js.map +1 -1
  320. package/dist/src/vite/agent.types.d.ts +32 -2
  321. package/dist/src/vite/agent.types.d.ts.map +1 -1
  322. package/dist/src/vite/agentApi.d.ts +15 -3
  323. package/dist/src/vite/agentApi.d.ts.map +1 -1
  324. package/dist/src/vite/agentApi.js +63 -9
  325. package/dist/src/vite/agentApi.js.map +1 -1
  326. package/dist/src/vite/agentRoutes.d.ts +8 -3
  327. package/dist/src/vite/agentRoutes.d.ts.map +1 -1
  328. package/dist/src/vite/agentRoutes.js +84 -23
  329. package/dist/src/vite/agentRoutes.js.map +1 -1
  330. package/dist/src/vite/configFile.d.ts +2 -1
  331. package/dist/src/vite/configFile.d.ts.map +1 -1
  332. package/dist/src/vite/configFile.js +29 -11
  333. package/dist/src/vite/configFile.js.map +1 -1
  334. package/dist/src/vite/docsExtractor.d.ts +26 -2
  335. package/dist/src/vite/docsExtractor.d.ts.map +1 -1
  336. package/dist/src/vite/docsExtractor.js +12 -9
  337. package/dist/src/vite/docsExtractor.js.map +1 -1
  338. package/dist/src/vite/docsWorker.js +18 -2
  339. package/dist/src/vite/docsWorker.js.map +1 -1
  340. package/dist/src/vite/forcedStates.d.ts +6 -2
  341. package/dist/src/vite/forcedStates.d.ts.map +1 -1
  342. package/dist/src/vite/forcedStates.js +20 -4
  343. package/dist/src/vite/forcedStates.js.map +1 -1
  344. package/dist/src/vite/forgebookPlugin.d.ts.map +1 -1
  345. package/dist/src/vite/forgebookPlugin.js +104 -16
  346. package/dist/src/vite/forgebookPlugin.js.map +1 -1
  347. package/dist/src/vite/indexStoryFile.d.ts +14 -0
  348. package/dist/src/vite/indexStoryFile.d.ts.map +1 -1
  349. package/dist/src/vite/indexStoryFile.js +13 -4
  350. package/dist/src/vite/indexStoryFile.js.map +1 -1
  351. package/dist/src/vite/mcpProtocol.d.ts +9 -0
  352. package/dist/src/vite/mcpProtocol.d.ts.map +1 -1
  353. package/dist/src/vite/mcpProtocol.js +6 -3
  354. package/dist/src/vite/mcpProtocol.js.map +1 -1
  355. package/dist/src/vite/storyFilesModule.d.ts +44 -1
  356. package/dist/src/vite/storyFilesModule.d.ts.map +1 -1
  357. package/dist/src/vite/storyFilesModule.js +49 -14
  358. package/dist/src/vite/storyFilesModule.js.map +1 -1
  359. package/dist/src/vite/touchMedia.d.ts +35 -0
  360. package/dist/src/vite/touchMedia.d.ts.map +1 -0
  361. package/dist/src/vite/touchMedia.js +187 -0
  362. package/dist/src/vite/touchMedia.js.map +1 -0
  363. package/dist/src/vite/usageGraph.d.ts +45 -0
  364. package/dist/src/vite/usageGraph.d.ts.map +1 -0
  365. package/dist/src/vite/usageGraph.js +246 -0
  366. package/dist/src/vite/usageGraph.js.map +1 -0
  367. package/dist/src/vite/usageModule.d.ts +33 -0
  368. package/dist/src/vite/usageModule.d.ts.map +1 -0
  369. package/dist/src/vite/usageModule.js +135 -0
  370. package/dist/src/vite/usageModule.js.map +1 -0
  371. package/dist/src/worstCase.d.ts +16 -0
  372. package/dist/src/worstCase.d.ts.map +1 -0
  373. package/dist/src/worstCase.js +16 -0
  374. package/dist/src/worstCase.js.map +1 -0
  375. package/package.json +18 -2
  376. package/dist/src/shell/SchemeSwitches.d.ts +0 -24
  377. package/dist/src/shell/SchemeSwitches.d.ts.map +0 -1
  378. package/dist/src/shell/SchemeSwitches.js +0 -36
  379. package/dist/src/shell/SchemeSwitches.js.map +0 -1
@@ -0,0 +1,399 @@
1
+ /**
2
+ * The frame's simulated touch, on while the root has `data-forgebook-touch` (the Touch switch): the real mouse's
3
+ * events are caught before the story and sent again as a finger, or as two with Shift held.
4
+ *
5
+ * @remarks
6
+ * A press sends `pointerdown` (touch) and `touchstart`; a move sends `touchmove`, and `pointermove` until a drag
7
+ * starts scrolling, when the pointer is cancelled as the browser cancels it (`touchScroll.ts`); a lift sends
8
+ * `pointerup` and `touchend`. A tap then sends the mouse's compatibility events and its own click of the `touch` type
9
+ * in place of the real one, so a button, a link or a checkbox reacts as it would; a press held half a second sends `contextmenu`. A moving mouse with
10
+ * no button down sends nothing: a finger does not hover. Shift fixes a centre where the mouse is; a press then puts a
11
+ * second finger mirrored around it, so dragging pinches and rotates. The real cursor is hidden and the fingers are
12
+ * dots (`touchDots.ts`). While it is on, `navigator.maxTouchPoints` and `ontouchstart` say touch, and capturing a
13
+ * simulated pointer works. A simulation: the events are not trusted, so the browser's own scrolling, focus from a
14
+ * touch, a virtual keyboard and real Safari stay a device's (or `forgebook dev --touch`'s).
15
+ *
16
+ * @module
17
+ */
18
+ import { isRealTouchWindow } from "../realTouch.js";
19
+ import { touchDots } from "./touchDots.js";
20
+ import { sendClick, sendMouse, sendPointer, sendTouch } from "./touchEvents.js";
21
+ import { distance, dragAxis, isDragging, LONG_PRESS_MS, mirroredFinger } from "./touchGesture.js";
22
+ import { endPan, panBy, panOf } from "./touchScroll.js";
23
+ /** The root's attribute that turns the simulation on. */
24
+ const TOUCH_ATTRIBUTE = "data-forgebook-touch";
25
+ /** The simulated pointers' ids: apart from the real mouse's, so the browser never confuses them. */
26
+ const FINGER_IDS = [100, 101];
27
+ /** The least distance between two fingers, in CSS px: a centre right under the mouse moves aside by half of it. */
28
+ const LEAST_SPREAD_PX = 80;
29
+ /** The real events that never reach the story while touch is simulated (the hover a finger does not have). */
30
+ const SWALLOWED = ["mousedown", "mouseup", "mousemove", "mouseover", "mouseout", "mouseenter", "mouseleave"];
31
+ /** The real pointer events that never reach the story: the fingers send their own. */
32
+ const SWALLOWED_POINTER = ["pointerover", "pointerout", "pointerenter", "pointerleave"];
33
+ /**
34
+ * The two-finger centre for a press at a point: Shift's, moved aside when it is right under the mouse.
35
+ *
36
+ * @param center - where Shift fixed it.
37
+ * @param point - where the press is.
38
+ */
39
+ const spreadCenter = (center, point) => distance(center, point) * 2 >= LEAST_SPREAD_PX ? center : { x: point.x - LEAST_SPREAD_PX / 2, y: point.y };
40
+ /**
41
+ * The fingers' dots: the fingers of a press, or the mouse (and the second finger to come, with Shift) between presses.
42
+ *
43
+ * @param state - the simulation's state.
44
+ */
45
+ const drawDots = (state) => {
46
+ const { press, mouse, center } = state;
47
+ if (press !== undefined) {
48
+ state.dots.draw(press.fingers.map((finger) => ({ point: finger.point, isPressed: true })));
49
+ return;
50
+ }
51
+ if (mouse === undefined) {
52
+ state.dots.draw([]);
53
+ return;
54
+ }
55
+ // the second finger where a press will put it: the same centre the press takes, moved aside as it will be
56
+ const second = center === undefined
57
+ ? []
58
+ : [{ point: mirroredFinger(spreadCenter(center, mouse), mouse), isPressed: false }];
59
+ state.dots.draw([{ point: mouse, isPressed: false }, ...second]);
60
+ };
61
+ /**
62
+ * The second finger going down at a point.
63
+ *
64
+ * @param document - the frame's document.
65
+ * @param id - its id.
66
+ * @param point - where.
67
+ * @param fallback - the element when none is under the point.
68
+ */
69
+ const fingerAt = (document, id, point, fallback) => {
70
+ const target = document.elementFromPoint(point.x, point.y) ?? fallback;
71
+ return { id, isPrimary: false, point, startTarget: target, captureTarget: target };
72
+ };
73
+ /**
74
+ * A press begins: its fingers go down, each sending its pointer and touch events.
75
+ *
76
+ * @param state - the simulation's state.
77
+ * @param event - the real pointer's press.
78
+ */
79
+ const pressDown = (state, event) => {
80
+ state.stopFling();
81
+ const point = { x: event.clientX, y: event.clientY };
82
+ const target = event.target instanceof Element ? event.target : state.document.documentElement;
83
+ const shiftCenter = event.shiftKey ? (state.center ?? point) : undefined;
84
+ const center = shiftCenter === undefined ? undefined : spreadCenter(shiftCenter, point);
85
+ // the first finger goes down where the real press did, on the element the browser found under it
86
+ const fingers = [
87
+ { id: FINGER_IDS[0], isPrimary: true, point, startTarget: target, captureTarget: target }
88
+ ];
89
+ if (center !== undefined)
90
+ fingers.push(fingerAt(state.document, FINGER_IDS[1], mirroredFinger(center, point), target));
91
+ // the press is the layer's before its first event: a story that captures the pointer in its pointerdown finds it
92
+ const press = {
93
+ fingers,
94
+ start: point,
95
+ center,
96
+ isDrag: false,
97
+ isLongPress: false,
98
+ isDownCancelled: false,
99
+ isTouchCancelled: false,
100
+ pan: undefined,
101
+ last: { point, time: event.timeStamp },
102
+ speed: { x: 0, y: 0 },
103
+ timer: undefined
104
+ };
105
+ state.press = press;
106
+ for (const finger of fingers) {
107
+ sendPointer("pointerover", finger, true);
108
+ sendPointer("pointerenter", finger, true);
109
+ if (!sendPointer("pointerdown", finger, true))
110
+ press.isDownCancelled = true;
111
+ }
112
+ press.isTouchCancelled = !sendTouch("touchstart", fingers, fingers, true);
113
+ // a long press opens the story's menu, as on a phone
114
+ press.timer = window.setTimeout(() => {
115
+ if (press.isDrag || press.fingers.length > 1 || state.press !== press)
116
+ return;
117
+ press.isLongPress = true;
118
+ const [first] = press.fingers;
119
+ if (first !== undefined)
120
+ sendMouse("contextmenu", first);
121
+ }, LONG_PRESS_MS);
122
+ drawDots(state);
123
+ };
124
+ /**
125
+ * Starts the drag of a press, the first time its finger passes a tap's reach: a single finger whose move no handler
126
+ * cancelled scrolls what it can (the pointer is then cancelled, as the browser cancels it).
127
+ *
128
+ * @param press - the press.
129
+ * @param isMoveCancelled - whether a handler cancelled this `touchmove`.
130
+ */
131
+ const startDrag = (press, isMoveCancelled) => {
132
+ press.isDrag = true;
133
+ window.clearTimeout(press.timer);
134
+ const [first] = press.fingers;
135
+ if (isMoveCancelled || press.isTouchCancelled || press.fingers.length > 1 || first === undefined)
136
+ return;
137
+ press.pan = panOf(first.startTarget, dragAxis(press.start, first.point));
138
+ if (press.pan !== undefined)
139
+ sendPointer("pointercancel", first, false);
140
+ };
141
+ /**
142
+ * The fingers follow the mouse: touch events always, pointer events until the drag scrolls, the scroll otherwise.
143
+ *
144
+ * @param state - the simulation's state.
145
+ * @param press - the press.
146
+ * @param event - the real pointer's move.
147
+ */
148
+ const pressMove = (state, press, event) => {
149
+ const point = { x: event.clientX, y: event.clientY };
150
+ // the mouse goes with the finger: after the lift, its dot stays where the finger left the screen
151
+ state.mouse = point;
152
+ const [first, second] = press.fingers;
153
+ if (first === undefined)
154
+ return;
155
+ const from = first.point;
156
+ first.point = point;
157
+ if (second !== undefined && press.center !== undefined)
158
+ second.point = mirroredFinger(press.center, point);
159
+ const isMoveCancelled = !sendTouch("touchmove", press.fingers, press.fingers, press.pan === undefined);
160
+ if (!press.isDrag && isDragging(press.start, point))
161
+ startDrag(press, isMoveCancelled);
162
+ const ms = Math.max(1, event.timeStamp - press.last.time);
163
+ press.speed = { x: (point.x - press.last.point.x) / ms, y: (point.y - press.last.point.y) / ms };
164
+ press.last = { point, time: event.timeStamp };
165
+ if (press.pan !== undefined)
166
+ panBy(press.pan, from, point);
167
+ else
168
+ for (const finger of press.fingers)
169
+ sendPointer("pointermove", finger, true);
170
+ drawDots(state);
171
+ };
172
+ /**
173
+ * A press ends: the fingers lift, a scroll flings on, a tap sends the mouse's compatibility events and readies its
174
+ * click.
175
+ *
176
+ * @param state - the simulation's state.
177
+ * @param press - the press.
178
+ * @param isCancel - whether the browser cancelled the real pointer.
179
+ */
180
+ const pressUp = (state, press, isCancel) => {
181
+ window.clearTimeout(press.timer);
182
+ state.press = undefined;
183
+ if (press.pan === undefined) {
184
+ for (const finger of press.fingers) {
185
+ sendPointer(isCancel ? "pointercancel" : "pointerup", finger, false);
186
+ sendPointer("pointerout", finger, false);
187
+ sendPointer("pointerleave", finger, false);
188
+ }
189
+ }
190
+ const isEndCancelled = !sendTouch(isCancel ? "touchcancel" : "touchend", [], press.fingers, press.pan === undefined);
191
+ if (press.pan !== undefined)
192
+ state.stopFling = endPan(press.pan, press.speed);
193
+ const [first] = press.fingers;
194
+ const isTap = !isCancel && !press.isDrag && !press.isLongPress && press.fingers.length === 1;
195
+ const isClicking = isTap && !press.isTouchCancelled && !isEndCancelled;
196
+ state.tapper = isClicking ? first : undefined;
197
+ if (isClicking && !press.isDownCancelled && first !== undefined) {
198
+ sendMouse("mousedown", first);
199
+ sendMouse("mouseup", first);
200
+ }
201
+ drawDots(state);
202
+ };
203
+ /**
204
+ * A real event the story never receives in place of a finger's: the click (a tap's is sent again as a finger's, a
205
+ * drag's or a long press's is none), a text selection or an image dragged by the finger, the right button's menu.
206
+ *
207
+ * @param state - the simulation's state.
208
+ * @param event - the real event.
209
+ * @returns whether it was one of them.
210
+ */
211
+ const blockedDefault = (state, event) => {
212
+ if (event.type === "click") {
213
+ event.preventDefault();
214
+ event.stopImmediatePropagation();
215
+ const finger = state.tapper;
216
+ state.tapper = undefined;
217
+ // after the real click's dispatch: cancelling it undoes a checkbox's toggle at its end, a click sent inside it too
218
+ const { target } = event;
219
+ if (finger !== undefined && target !== null)
220
+ window.setTimeout(() => sendClick(target, finger), 0);
221
+ return true;
222
+ }
223
+ if (event.type !== "selectstart" && event.type !== "dragstart" && event.type !== "contextmenu")
224
+ return false;
225
+ event.preventDefault();
226
+ event.stopImmediatePropagation();
227
+ return true;
228
+ };
229
+ /**
230
+ * What the simulation does with one real pointer event: the press, the move and the lift of the fingers, the dots
231
+ * between presses.
232
+ *
233
+ * @param state - the simulation's state.
234
+ * @param event - the real pointer event.
235
+ */
236
+ const pointerInput = (state, event) => {
237
+ const { press } = state;
238
+ if (event.type === "pointerout" && event.relatedTarget === null && press === undefined) {
239
+ state.mouse = undefined;
240
+ drawDots(state);
241
+ }
242
+ else if (event.type === "pointerdown" && event.button === 0 && press === undefined)
243
+ pressDown(state, event);
244
+ else if (event.type === "pointermove" && press !== undefined)
245
+ pressMove(state, press, event);
246
+ else if (event.type === "pointermove") {
247
+ // Shift read from the pointer, which carries it even when the frame has no focus (the shell usually does): held,
248
+ // it fixes the two-finger centre where the mouse was
249
+ if (!event.shiftKey)
250
+ state.center = undefined;
251
+ else
252
+ state.center ??= state.mouse ?? { x: event.clientX, y: event.clientY };
253
+ state.mouse = { x: event.clientX, y: event.clientY };
254
+ drawDots(state);
255
+ }
256
+ else if ((event.type === "pointerup" || event.type === "pointercancel") && press !== undefined) {
257
+ state.mouse = { x: event.clientX, y: event.clientY };
258
+ pressUp(state, press, event.type === "pointercancel");
259
+ }
260
+ };
261
+ /**
262
+ * What the simulation does with one real event, before the story sees it: the story never sees a real one.
263
+ *
264
+ * @param state - the simulation's state.
265
+ * @param event - the real event (the story's own dispatched events are left alone).
266
+ */
267
+ const intercept = (state, event) => {
268
+ if (!event.isTrusted || blockedDefault(state, event))
269
+ return;
270
+ event.stopImmediatePropagation();
271
+ if (event instanceof PointerEvent)
272
+ pointerInput(state, event);
273
+ };
274
+ /**
275
+ * Makes the frame say it is a touch device, and lets the story capture a simulated pointer.
276
+ *
277
+ * @param state - the simulation's state.
278
+ * @returns what puts the frame back as it was.
279
+ */
280
+ const pretendTouch = (state) => {
281
+ const view = state.document.defaultView;
282
+ if (view === null)
283
+ return () => undefined;
284
+ Object.defineProperty(view.navigator, "maxTouchPoints", { configurable: true, get: () => 5 });
285
+ Object.defineProperty(view, "ontouchstart", { configurable: true, writable: true, value: null });
286
+ const proto = view.Element.prototype;
287
+ const native = {
288
+ set: proto.setPointerCapture,
289
+ release: proto.releasePointerCapture,
290
+ has: proto.hasPointerCapture
291
+ };
292
+ const fingerOf = (id) => state.press?.fingers.find((finger) => finger.id === id);
293
+ proto.setPointerCapture = function setPointerCapture(id) {
294
+ const finger = fingerOf(id);
295
+ if (finger === undefined) {
296
+ native.set.call(this, id);
297
+ return;
298
+ }
299
+ finger.captureTarget = this;
300
+ sendPointer("gotpointercapture", finger, true);
301
+ };
302
+ proto.releasePointerCapture = function releasePointerCapture(id) {
303
+ const finger = fingerOf(id);
304
+ if (finger === undefined) {
305
+ native.release.call(this, id);
306
+ return;
307
+ }
308
+ sendPointer("lostpointercapture", finger, true);
309
+ finger.captureTarget = finger.startTarget;
310
+ };
311
+ proto.hasPointerCapture = function hasPointerCapture(id) {
312
+ const finger = fingerOf(id);
313
+ return finger === undefined ? native.has.call(this, id) : finger.captureTarget === this;
314
+ };
315
+ return () => {
316
+ Reflect.deleteProperty(view.navigator, "maxTouchPoints");
317
+ Reflect.deleteProperty(view, "ontouchstart");
318
+ proto.setPointerCapture = native.set;
319
+ proto.releasePointerCapture = native.release;
320
+ proto.hasPointerCapture = native.has;
321
+ };
322
+ };
323
+ /** The events the simulation catches, on the window, before the story. */
324
+ const CAUGHT = [
325
+ "pointerdown",
326
+ "pointermove",
327
+ "pointerup",
328
+ "pointercancel",
329
+ ...SWALLOWED_POINTER,
330
+ ...SWALLOWED,
331
+ "click",
332
+ "contextmenu",
333
+ "selectstart",
334
+ "dragstart"
335
+ ];
336
+ /**
337
+ * Starts the simulation in a frame.
338
+ *
339
+ * @param document - the frame's document.
340
+ * @returns what stops it.
341
+ */
342
+ const startTouch = (document) => {
343
+ const state = {
344
+ document,
345
+ dots: touchDots(document),
346
+ mouse: undefined,
347
+ center: undefined,
348
+ press: undefined,
349
+ tapper: undefined,
350
+ stopFling: () => undefined
351
+ };
352
+ const restore = pretendTouch(state);
353
+ const onEvent = (event) => intercept(state, event);
354
+ // Shift fixes the two-finger centre where the mouse is, and shows where the second finger will be
355
+ const onKey = (event) => {
356
+ if (event.key !== "Shift" || state.press !== undefined)
357
+ return;
358
+ state.center = event.type === "keydown" ? state.mouse : undefined;
359
+ drawDots(state);
360
+ };
361
+ const view = document.defaultView;
362
+ for (const type of CAUGHT)
363
+ view?.addEventListener(type, onEvent, { capture: true });
364
+ view?.addEventListener("keydown", onKey);
365
+ view?.addEventListener("keyup", onKey);
366
+ return () => {
367
+ for (const type of CAUGHT)
368
+ view?.removeEventListener(type, onEvent, { capture: true });
369
+ view?.removeEventListener("keydown", onKey);
370
+ view?.removeEventListener("keyup", onKey);
371
+ state.stopFling();
372
+ restore();
373
+ state.dots.remove();
374
+ };
375
+ };
376
+ /**
377
+ * Follows the root's touch attribute from now on: the simulation runs while it is set.
378
+ *
379
+ * @param document - the frame's document.
380
+ */
381
+ export const followTouch = (document) => {
382
+ let stop;
383
+ // in Chromium's real touch window the pages see real touch: simulating it on top would send every touch twice
384
+ const view = document.defaultView;
385
+ if (view !== null && isRealTouchWindow(view))
386
+ return;
387
+ const update = () => {
388
+ const isOn = document.documentElement.hasAttribute(TOUCH_ATTRIBUTE);
389
+ if (isOn && stop === undefined)
390
+ stop = startTouch(document);
391
+ else if (!isOn && stop !== undefined) {
392
+ stop();
393
+ stop = undefined;
394
+ }
395
+ };
396
+ new MutationObserver(update).observe(document.documentElement, { attributeFilter: [TOUCH_ATTRIBUTE] });
397
+ update();
398
+ };
399
+ //# sourceMappingURL=touchLayer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"touchLayer.js","sourceRoot":"","sources":["../../../src/frame/touchLayer.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAkB,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,EAAe,SAAS,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AAC7F,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,UAAU,EAAE,aAAa,EAAE,cAAc,EAAc,MAAM,mBAAmB,CAAC;AAC9G,OAAO,EAAE,MAAM,EAAY,KAAK,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAElE,yDAAyD;AACzD,MAAM,eAAe,GAAG,sBAAsB,CAAC;AAE/C,oGAAoG;AACpG,MAAM,UAAU,GAAG,CAAC,GAAG,EAAE,GAAG,CAAU,CAAC;AAEvC,mHAAmH;AACnH,MAAM,eAAe,GAAG,EAAE,CAAC;AAE3B,8GAA8G;AAC9G,MAAM,SAAS,GAAG,CAAC,WAAW,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;AAE7G,sFAAsF;AACtF,MAAM,iBAAiB,GAAG,CAAC,aAAa,EAAE,YAAY,EAAE,cAAc,EAAE,cAAc,CAAC,CAAC;AA4CxF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E,CAAC;YACrC,IAAI,EAAE,CAAC;YACP,IAAI,GAAG,SAAS,CAAC;QACnB,CAAC;IACH,CAAC,CAAC;IACF,IAAI,gBAAgB,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,eAAe,EAAE,EAAE,eAAe,EAAE,CAAC,eAAe,CAAC,EAAE,CAAC,CAAC;IACvG,MAAM,EAAE,CAAC;AACX,CAAC,CAAC"}
@@ -0,0 +1,51 @@
1
+ /**
2
+ * A simulated finger's scrolling: the container a drag scrolls, on the axes the `touch-action` on the way allows, and
3
+ * the fling that carries on after the finger lifts.
4
+ *
5
+ * @remarks
6
+ * An approximation of the browser's own scrolling, which a page cannot start: no rubber band at the ends, the fling
7
+ * slows down at one fixed rate (`flungSpeed`), and a container that snaps snaps once the finger lifts. The scroll keeps to the drag's axis; the container is the nearest
8
+ * ancestor that scrolls on it, up to the document's own scrolling element.
9
+ *
10
+ * @module
11
+ */
12
+ import { type PanAxes, type Point } from "./touchGesture.ts";
13
+ /** A scroll a finger drives. */
14
+ export type Pan = {
15
+ /** The element it scrolls. */
16
+ readonly scroller: Element;
17
+ /** The axes it scrolls on. */
18
+ readonly axes: PanAxes;
19
+ /**
20
+ * For a container that snaps, its own `scroll-snap-type` (inline) while the drag pauses its snapping, put back when
21
+ * the finger lifts; none for one that does not snap.
22
+ */
23
+ readonly pausedSnap: string | undefined;
24
+ };
25
+ /**
26
+ * The scroll a drag drives along its axis, or none when the `touch-action` on the way forbids that axis (a horizontal
27
+ * swipe on a `pan-y` row stays the row's) or nothing on the way scrolls on it.
28
+ *
29
+ * @param target - the element the finger went down on.
30
+ * @param axis - the drag's axis.
31
+ */
32
+ export declare const panOf: (target: Element, axis: "x" | "y") => Pan | undefined;
33
+ /**
34
+ * Scrolls by a finger's move: the content follows the finger.
35
+ *
36
+ * @param pan - the scroll.
37
+ * @param from - where the finger was.
38
+ * @param to - where it is.
39
+ */
40
+ export declare const panBy: (pan: Pan, from: Point, to: Point) => void;
41
+ /**
42
+ * A drag's scroll ends as the finger lifts: a container that snaps snaps again, to the item nearest where the finger
43
+ * aimed (its place now plus its last speed, at most half the container ahead, so a flick goes to the next item and
44
+ * never past it), with the browser's smooth scroll; any other flings on. The returned function stops a fling (a new
45
+ * touch does).
46
+ *
47
+ * @param pan - the scroll.
48
+ * @param speed - the finger's last speed, in CSS px per ms, per axis.
49
+ */
50
+ export declare const endPan: (pan: Pan, speed: Point) => (() => void);
51
+ //# sourceMappingURL=touchScroll.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"touchScroll.d.ts","sourceRoot":"","sources":["../../../src/frame/touchScroll.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAA0B,KAAK,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAErF,gCAAgC;AAChC,MAAM,MAAM,GAAG,GAAG;IAChB,8BAA8B;IAC9B,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;IAC3B,8BAA8B;IAC9B,QAAQ,CAAC,IAAI,EAAE,OAAO,CAAC;IACvB;;;OAGG;IACH,QAAQ,CAAC,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;CACzC,CAAC;AAmCF;;;;;;GAMG;AACH,eAAO,MAAM,KAAK,GAAI,QAAQ,OAAO,EAAE,MAAM,GAAG,GAAG,GAAG,KAAG,GAAG,GAAG,SAQ9D,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,KAAK,GAAI,KAAK,GAAG,EAAE,MAAM,KAAK,EAAE,IAAI,KAAK,KAAG,IAKrD,CAAC;AA2CL;;;;;;;;GAQG;AACH,eAAO,MAAM,MAAM,GAAI,KAAK,GAAG,EAAE,OAAO,KAAK,KAAG,CAAC,MAAM,IAAI,CAgB1D,CAAC"}
@@ -0,0 +1,137 @@
1
+ /**
2
+ * A simulated finger's scrolling: the container a drag scrolls, on the axes the `touch-action` on the way allows, and
3
+ * the fling that carries on after the finger lifts.
4
+ *
5
+ * @remarks
6
+ * An approximation of the browser's own scrolling, which a page cannot start: no rubber band at the ends, the fling
7
+ * slows down at one fixed rate (`flungSpeed`), and a container that snaps snaps once the finger lifts. The scroll keeps to the drag's axis; the container is the nearest
8
+ * ancestor that scrolls on it, up to the document's own scrolling element.
9
+ *
10
+ * @module
11
+ */
12
+ import { allowedPan, flungSpeed } from "./touchGesture.js";
13
+ /** How far ahead a snapping container's fling is aimed, in ms of the finger's last speed. */
14
+ const SNAP_AIM_MS = 250;
15
+ /**
16
+ * Whether an element scrolls on an axis: it overflows there and its style lets it.
17
+ *
18
+ * @param element - the element.
19
+ * @param axis - the axis.
20
+ */
21
+ const scrollsOn = (element, axis) => {
22
+ const isDocument = element === element.ownerDocument.scrollingElement;
23
+ const overflow = getComputedStyle(element)[axis === "x" ? "overflowX" : "overflowY"];
24
+ const isScrollable = isDocument || overflow === "auto" || overflow === "scroll";
25
+ const size = axis === "x" ? element.scrollWidth - element.clientWidth : element.scrollHeight - element.clientHeight;
26
+ return isScrollable && size > 0;
27
+ };
28
+ /**
29
+ * A drag's scroll begins: a container that snaps stops snapping while the finger drags it, or every step of the drag
30
+ * would snap to a whole item.
31
+ *
32
+ * @param scroller - the container.
33
+ * @param axis - the drag's axis.
34
+ */
35
+ const startPan = (scroller, axis) => {
36
+ const isSnapping = getComputedStyle(scroller).scrollSnapType !== "none";
37
+ const style = scroller instanceof HTMLElement ? scroller.style : undefined;
38
+ const pausedSnap = isSnapping && style !== undefined ? style.scrollSnapType : undefined;
39
+ if (pausedSnap !== undefined && style !== undefined)
40
+ style.scrollSnapType = "none";
41
+ return { scroller, axes: { x: axis === "x", y: axis === "y" }, pausedSnap };
42
+ };
43
+ /**
44
+ * The scroll a drag drives along its axis, or none when the `touch-action` on the way forbids that axis (a horizontal
45
+ * swipe on a `pan-y` row stays the row's) or nothing on the way scrolls on it.
46
+ *
47
+ * @param target - the element the finger went down on.
48
+ * @param axis - the drag's axis.
49
+ */
50
+ export const panOf = (target, axis) => {
51
+ const touchActions = [];
52
+ for (let element = target; element !== null; element = element.parentElement) {
53
+ touchActions.push(getComputedStyle(element).touchAction);
54
+ if (!allowedPan(touchActions)[axis])
55
+ return undefined;
56
+ if (scrollsOn(element, axis))
57
+ return startPan(element, axis);
58
+ }
59
+ return undefined;
60
+ };
61
+ /**
62
+ * Scrolls by a finger's move: the content follows the finger.
63
+ *
64
+ * @param pan - the scroll.
65
+ * @param from - where the finger was.
66
+ * @param to - where it is.
67
+ */
68
+ export const panBy = (pan, from, to) => pan.scroller.scrollBy({
69
+ left: pan.axes.x ? from.x - to.x : 0,
70
+ top: pan.axes.y ? from.y - to.y : 0,
71
+ behavior: "instant"
72
+ });
73
+ /**
74
+ * Carries a scroll on after the finger lifts, slowing down; the returned function stops it (a new touch does).
75
+ *
76
+ * @param pan - the scroll.
77
+ * @param speed - the finger's last speed, in CSS px per ms, per axis.
78
+ */
79
+ const fling = (pan, speed) => {
80
+ const view = pan.scroller.ownerDocument.defaultView;
81
+ if (view === null)
82
+ return () => undefined;
83
+ let current = { x: pan.axes.x ? speed.x : 0, y: pan.axes.y ? speed.y : 0 };
84
+ let last = view.performance.now();
85
+ let frame = 0;
86
+ const step = (now) => {
87
+ const ms = now - last;
88
+ last = now;
89
+ pan.scroller.scrollBy({ left: -current.x * ms, top: -current.y * ms, behavior: "instant" });
90
+ current = { x: flungSpeed(current.x, ms), y: flungSpeed(current.y, ms) };
91
+ if (current.x !== 0 || current.y !== 0)
92
+ frame = view.requestAnimationFrame(step);
93
+ };
94
+ frame = view.requestAnimationFrame(step);
95
+ return () => view.cancelAnimationFrame(frame);
96
+ };
97
+ /**
98
+ * Where a snapping container's items start along an axis, in its scroll coordinates: its children that snap.
99
+ *
100
+ * @param scroller - the container.
101
+ * @param axis - the axis.
102
+ */
103
+ const snapPoints = (scroller, axis) => {
104
+ const box = scroller.getBoundingClientRect();
105
+ return [...scroller.children]
106
+ .filter((child) => getComputedStyle(child).scrollSnapAlign !== "none")
107
+ .map((child) => {
108
+ const childBox = child.getBoundingClientRect();
109
+ return axis === "x"
110
+ ? childBox.left - box.left + scroller.scrollLeft
111
+ : childBox.top - box.top + scroller.scrollTop;
112
+ });
113
+ };
114
+ /**
115
+ * A drag's scroll ends as the finger lifts: a container that snaps snaps again, to the item nearest where the finger
116
+ * aimed (its place now plus its last speed, at most half the container ahead, so a flick goes to the next item and
117
+ * never past it), with the browser's smooth scroll; any other flings on. The returned function stops a fling (a new
118
+ * touch does).
119
+ *
120
+ * @param pan - the scroll.
121
+ * @param speed - the finger's last speed, in CSS px per ms, per axis.
122
+ */
123
+ export const endPan = (pan, speed) => {
124
+ if (pan.pausedSnap === undefined || !(pan.scroller instanceof HTMLElement))
125
+ return fling(pan, speed);
126
+ const scroller = pan.scroller;
127
+ const axis = pan.axes.x ? "x" : "y";
128
+ const room = axis === "x" ? scroller.clientWidth : scroller.clientHeight;
129
+ const now = axis === "x" ? scroller.scrollLeft : scroller.scrollTop;
130
+ const aim = now + Math.max(-room / 2, Math.min(room / 2, -(axis === "x" ? speed.x : speed.y) * SNAP_AIM_MS));
131
+ const target = snapPoints(scroller, axis).reduce((best, point) => (Math.abs(point - aim) < Math.abs(best - aim) ? point : best), aim);
132
+ // snapping comes back only now: back on, it would snap the place the finger left before the target is read
133
+ scroller.style.scrollSnapType = pan.pausedSnap;
134
+ scroller.scrollTo({ [axis === "x" ? "left" : "top"]: target, behavior: "smooth" });
135
+ return () => undefined;
136
+ };
137
+ //# sourceMappingURL=touchScroll.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"touchScroll.js","sourceRoot":"","sources":["../../../src/frame/touchScroll.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EAAE,UAAU,EAAE,UAAU,EAA4B,MAAM,mBAAmB,CAAC;AAerF,6FAA6F;AAC7F,MAAM,WAAW,GAAG,GAAG,CAAC;AAExB;;;;;GAKG;AACH,MAAM,SAAS,GAAG,CAAC,OAAgB,EAAE,IAAe,EAAW,EAAE;I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