@buoy-gg/shared-ui 7.0.40 → 7.0.42

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 (1126) hide show
  1. package/README.md +6 -0
  2. package/dataViewer.js +1 -9
  3. package/floating.js +1 -2
  4. package/history.js +1 -7
  5. package/hooks.js +1 -7
  6. package/lib/commonjs/JsModal.js +1 -1814
  7. package/lib/commonjs/JsModal.web.js +1 -1652
  8. package/lib/commonjs/clipboard/autoDetectClipboard.js +1 -67
  9. package/lib/commonjs/clipboard/clipboard-impl.js +1 -128
  10. package/lib/commonjs/clipboard/clipboard-impl.web.js +1 -0
  11. package/lib/commonjs/clipboard/copyToClipboard.js +1 -64
  12. package/lib/commonjs/clipboard/index.js +1 -25
  13. package/lib/commonjs/colors/index.js +1 -49
  14. package/lib/commonjs/context/HintsContext.js +1 -49
  15. package/lib/commonjs/context/index.js +1 -24
  16. package/lib/commonjs/dataViewer/CyberpunkInput.js +1 -388
  17. package/lib/commonjs/dataViewer/DataTreeActionBar.js +1 -390
  18. package/lib/commonjs/dataViewer/DataTreeActionDock.js +1 -226
  19. package/lib/commonjs/dataViewer/DataViewer.js +1 -158
  20. package/lib/commonjs/dataViewer/DiffSummary.js +1 -134
  21. package/lib/commonjs/dataViewer/IndentGuides.js +1 -128
  22. package/lib/commonjs/dataViewer/IndentGuidesOverlay.js +1 -104
  23. package/lib/commonjs/dataViewer/JsonStringNotice.js +1 -59
  24. package/lib/commonjs/dataViewer/LiveExplorer.js +1 -943
  25. package/lib/commonjs/dataViewer/SplitDiffViewer.js +1 -421
  26. package/lib/commonjs/dataViewer/ThemedSplitView.js +1 -642
  27. package/lib/commonjs/dataViewer/TimestampDeltaBar.js +1 -96
  28. package/lib/commonjs/dataViewer/TypeLegend.js +1 -111
  29. package/lib/commonjs/dataViewer/ValueEditModal.js +1 -386
  30. package/lib/commonjs/dataViewer/VirtualizedDataExplorer.js +1 -1270
  31. package/lib/commonjs/dataViewer/diffThemes.js +1 -113
  32. package/lib/commonjs/dataViewer/index.js +1 -320
  33. package/lib/commonjs/dataViewer/jsonOps.js +1 -320
  34. package/lib/commonjs/dataViewer/jsonStringValue.js +1 -94
  35. package/lib/commonjs/dataViewer/lineDiff.js +1 -568
  36. package/lib/commonjs/dataViewer/nestedPath.js +1 -115
  37. package/lib/commonjs/dataViewer/objectDiff.js +1 -304
  38. package/lib/commonjs/dataViewer/timestampDiff.js +1 -146
  39. package/lib/commonjs/dataViewer/tree/TreeDiffViewer.js +1 -913
  40. package/lib/commonjs/dataViewer/treeActions.js +1 -168
  41. package/lib/commonjs/dataViewer/useTreeDraft.js +1 -125
  42. package/lib/commonjs/dataViewer/useTreeEditor.js +1 -105
  43. package/lib/commonjs/env/EnvironmentIndicator.js +1 -129
  44. package/lib/commonjs/env/EnvironmentIndicator.web.js +1 -114
  45. package/lib/commonjs/env/EnvironmentSelector.js +1 -205
  46. package/lib/commonjs/env/EnvironmentSelectorInline.js +1 -299
  47. package/lib/commonjs/env/EnvironmentSelectorInline.web.js +1 -178
  48. package/lib/commonjs/history/HistoryProvider.js +1 -246
  49. package/lib/commonjs/history/components/HistoryEntryRow.js +1 -146
  50. package/lib/commonjs/history/components/HistoryList.js +1 -174
  51. package/lib/commonjs/history/components/index.js +1 -25
  52. package/lib/commonjs/history/index.js +1 -61
  53. package/lib/commonjs/history/types.js +1 -5
  54. package/lib/commonjs/hooks/index.js +1 -77
  55. package/lib/commonjs/hooks/safe-area-impl.js +1 -28
  56. package/lib/commonjs/hooks/useChangeLog.js +1 -55
  57. package/lib/commonjs/hooks/useDeviceInfo.js +1 -524
  58. package/lib/commonjs/hooks/useEventStoreEvents.js +1 -65
  59. package/lib/commonjs/hooks/useFilterManager.js +1 -136
  60. package/lib/commonjs/hooks/usePersistedState.js +1 -106
  61. package/lib/commonjs/hooks/useSafeAreaInsets.js +1 -250
  62. package/lib/commonjs/hooks/useSafeAreaInsets.web.js +1 -0
  63. package/lib/commonjs/icons/BenchmarkIcon.js +1 -109
  64. package/lib/commonjs/icons/EnvLaptopIcon.js +1 -204
  65. package/lib/commonjs/icons/IconBackground.js +1 -279
  66. package/lib/commonjs/icons/ReactQueryIcon.js +1 -17
  67. package/lib/commonjs/icons/RenderCountIcon.js +1 -147
  68. package/lib/commonjs/icons/RouteMapIcon.js +1 -250
  69. package/lib/commonjs/icons/SentryBugIcon.js +1 -19
  70. package/lib/commonjs/icons/StackPulseIcon.js +1 -158
  71. package/lib/commonjs/icons/StorageStackIcon.js +1 -156
  72. package/lib/commonjs/icons/WifiCircuitIcon.js +1 -169
  73. package/lib/commonjs/icons/index.js +1 -826
  74. package/lib/commonjs/icons/lucide-icons-original-full.js +1 -3248
  75. package/lib/commonjs/icons/lucide-icons.js +1 -2476
  76. package/lib/commonjs/icons/primitives/GlobeIcon.js +1 -66
  77. package/lib/commonjs/icons/primitives/icon-primitives.js +1 -169
  78. package/lib/commonjs/icons/primitives/index.js +1 -49
  79. package/lib/commonjs/index.js +1 -1098
  80. package/lib/commonjs/license/AccountSetup.js +1 -56
  81. package/lib/commonjs/license/AccountSetup.web.js +14 -81
  82. package/lib/commonjs/license/AccountSetupContent.js +1 -0
  83. package/lib/commonjs/license/FeatureGate.js +1 -788
  84. package/lib/commonjs/license/FreeAccountPrompt.js +1 -205
  85. package/lib/commonjs/license/LicenseEntryModal.js +2 -394
  86. package/lib/commonjs/license/accountRuntime.js +1 -0
  87. package/lib/commonjs/license/accountRuntime.web.js +1 -0
  88. package/lib/commonjs/license/index.js +1 -106
  89. package/lib/commonjs/license/licenseModule.js +1 -119
  90. package/lib/commonjs/license/openPricing.js +1 -36
  91. package/lib/commonjs/license/tierLimits.js +1 -128
  92. package/lib/commonjs/logger/index-sentry.js +1 -245
  93. package/lib/commonjs/logger/index.js +1 -62
  94. package/lib/commonjs/logger/logDump.js +1 -19
  95. package/lib/commonjs/logger/types.js +1 -38
  96. package/lib/commonjs/settings/components/BubbleSettingsSection.js +1 -384
  97. package/lib/commonjs/settings/index.js +1 -24
  98. package/lib/commonjs/storage/definePersistedSetting.js +1 -67
  99. package/lib/commonjs/storage/devToolsStorageKeys.js +1 -359
  100. package/lib/commonjs/storage/index.js +1 -25
  101. package/lib/commonjs/stores/BaseEventStore.js +1 -343
  102. package/lib/commonjs/stores/ChangeLog.js +1 -197
  103. package/lib/commonjs/stores/createToolStore.js +1 -193
  104. package/lib/commonjs/stores/floatingToolStore.js +1 -71
  105. package/lib/commonjs/stores/floatingToolStore.test.js +1 -112
  106. package/lib/commonjs/stores/ignoredPatternsCore.js +1 -75
  107. package/lib/commonjs/stores/ignoredPatternsStore.js +1 -205
  108. package/lib/commonjs/stores/ignoredPatternsStore.shared.js +1 -0
  109. package/lib/commonjs/stores/ignoredPatternsStore.web.js +1 -236
  110. package/lib/commonjs/stores/index.js +1 -51
  111. package/lib/commonjs/sync/keyedArrays.js +1 -209
  112. package/lib/commonjs/sync/toolActionRegistry.js +1 -249
  113. package/lib/commonjs/sync/toolAttention.test.js +1 -51
  114. package/lib/commonjs/sync/toolSyncAdapter.js +1 -63
  115. package/lib/commonjs/sync/toolUiBridge.js +1 -132
  116. package/lib/commonjs/sync/typedEdit.js +1 -228
  117. package/lib/commonjs/sync/valuePath.js +1 -337
  118. package/lib/commonjs/sync/valueShape.js +1 -161
  119. package/lib/commonjs/sync/wireBudget.js +1 -97
  120. package/lib/commonjs/sync/wireForm.js +1 -172
  121. package/lib/commonjs/tools/defineTool.js +1 -79
  122. package/lib/commonjs/types/types.d.js +1 -1
  123. package/lib/commonjs/types/types.js +1 -37
  124. package/lib/commonjs/ui/backgrounds/BackgroundSwitcher.js +1 -354
  125. package/lib/commonjs/ui/backgrounds/ToolBackground.js +1 -76
  126. package/lib/commonjs/ui/backgrounds/backgroundStore.js +1 -130
  127. package/lib/commonjs/ui/backgrounds/index.js +1 -167
  128. package/lib/commonjs/ui/backgrounds/primitives.js +1 -369
  129. package/lib/commonjs/ui/backgrounds/registry.js +1 -98
  130. package/lib/commonjs/ui/backgrounds/rng.js +1 -93
  131. package/lib/commonjs/ui/backgrounds/skyClock.js +1 -45
  132. package/lib/commonjs/ui/backgrounds/types.js +1 -1
  133. package/lib/commonjs/ui/backgrounds/variants/daylight.js +1 -453
  134. package/lib/commonjs/ui/backgrounds/variants/deepField.js +1 -381
  135. package/lib/commonjs/ui/backgrounds/variants/hyperspace.js +1 -218
  136. package/lib/commonjs/ui/backgrounds/variants/liveSky.js +1 -898
  137. package/lib/commonjs/ui/backgrounds/variants/meteors.js +1 -401
  138. package/lib/commonjs/ui/backgrounds/variants/moonlight.js +1 -472
  139. package/lib/commonjs/ui/backgrounds/variants/underwater.js +1 -757
  140. package/lib/commonjs/ui/backgrounds/variants/wormhole/motion.js +1 -48
  141. package/lib/commonjs/ui/backgrounds/variants/wormhole/textures.js +1 -3
  142. package/lib/commonjs/ui/backgrounds/variants/wormhole.js +1 -133
  143. package/lib/commonjs/ui/components/BackButton.js +1 -47
  144. package/lib/commonjs/ui/components/Badge.js +1 -226
  145. package/lib/commonjs/ui/components/ChangeRow.js +1 -111
  146. package/lib/commonjs/ui/components/ChipStrip.js +1 -94
  147. package/lib/commonjs/ui/components/ClipboardHintBanner.js +1 -149
  148. package/lib/commonjs/ui/components/CollapsibleSection.js +1 -170
  149. package/lib/commonjs/ui/components/CompactFilterChips.js +1 -114
  150. package/lib/commonjs/ui/components/CompactRow.js +1 -295
  151. package/lib/commonjs/ui/components/CopyButton.js +1 -307
  152. package/lib/commonjs/ui/components/DataInspector.js +1 -323
  153. package/lib/commonjs/ui/components/DetailView.js +1 -358
  154. package/lib/commonjs/ui/components/DetailViewToggle.js +1 -130
  155. package/lib/commonjs/ui/components/DevToolsCard.js +1 -126
  156. package/lib/commonjs/ui/components/DraggableHeader.js +1 -215
  157. package/lib/commonjs/ui/components/DynamicFilterView.js +1 -758
  158. package/lib/commonjs/ui/components/EmptyState.js +1 -151
  159. package/lib/commonjs/ui/components/EntityFilterView.js +1 -355
  160. package/lib/commonjs/ui/components/EventHistoryViewer/CompareBar.js +1 -211
  161. package/lib/commonjs/ui/components/EventHistoryViewer/DiffModeTabs.js +1 -99
  162. package/lib/commonjs/ui/components/EventHistoryViewer/EventHistoryViewer.js +1 -184
  163. package/lib/commonjs/ui/components/EventHistoryViewer/EventPickerModal.js +1 -208
  164. package/lib/commonjs/ui/components/EventHistoryViewer/ViewToggleCards.js +1 -137
  165. package/lib/commonjs/ui/components/EventHistoryViewer/index.js +1 -40
  166. package/lib/commonjs/ui/components/EventHistoryViewer/types.js +1 -5
  167. package/lib/commonjs/ui/components/EventListItem.js +1 -247
  168. package/lib/commonjs/ui/components/EventStepperFooter.js +1 -185
  169. package/lib/commonjs/ui/components/ExpandablePopover.js +1 -381
  170. package/lib/commonjs/ui/components/ExpandedInfoRow.js +1 -108
  171. package/lib/commonjs/ui/components/ExportPreview.js +1 -174
  172. package/lib/commonjs/ui/components/FilterComponents.js +1 -291
  173. package/lib/commonjs/ui/components/GripVerticalIcon.js +1 -65
  174. package/lib/commonjs/ui/components/HeaderSearchButton.js +1 -50
  175. package/lib/commonjs/ui/components/InfoRow.js +1 -91
  176. package/lib/commonjs/ui/components/ListItem.js +1 -173
  177. package/lib/commonjs/ui/components/ModalHeader.js +1 -305
  178. package/lib/commonjs/ui/components/ModalHintBanner.js +1 -147
  179. package/lib/commonjs/ui/components/Pill.js +1 -115
  180. package/lib/commonjs/ui/components/PowerToggleButton.js +1 -78
  181. package/lib/commonjs/ui/components/SearchBar.js +1 -165
  182. package/lib/commonjs/ui/components/SectionHeader.js +1 -129
  183. package/lib/commonjs/ui/components/StatsCard.js +1 -198
  184. package/lib/commonjs/ui/components/StatusIndicator.js +1 -231
  185. package/lib/commonjs/ui/components/StorageTypeBadge.js +1 -97
  186. package/lib/commonjs/ui/components/TabSelector.js +1 -102
  187. package/lib/commonjs/ui/components/TimeDisplay.js +1 -142
  188. package/lib/commonjs/ui/components/ToggleRow.js +1 -116
  189. package/lib/commonjs/ui/components/ToolButton.js +1 -93
  190. package/lib/commonjs/ui/components/ToolEmptyState.js +1 -154
  191. package/lib/commonjs/ui/components/ToolFooter.js +1 -205
  192. package/lib/commonjs/ui/components/ValueTypeBadge.js +1 -147
  193. package/lib/commonjs/ui/components/WindowControls.js +1 -387
  194. package/lib/commonjs/ui/components/index.js +1 -507
  195. package/lib/commonjs/ui/components/windowDrag.js +1 -45
  196. package/lib/commonjs/ui/console/CyberpunkButtonOutline.js +1 -261
  197. package/lib/commonjs/ui/console/CyberpunkIconContainer.js +1 -186
  198. package/lib/commonjs/ui/console/CyberpunkSectionButton.js +1 -123
  199. package/lib/commonjs/ui/floating/FloatingTool.js +1 -1010
  200. package/lib/commonjs/ui/floating/FloatingTool.web.js +1 -591
  201. package/lib/commonjs/ui/floating/FloatingToolHost.js +1 -32
  202. package/lib/commonjs/ui/floating/FloatingToolHost.web.js +1 -28
  203. package/lib/commonjs/ui/floating/index.js +1 -105
  204. package/lib/commonjs/ui/floating/index.web.js +1 -105
  205. package/lib/commonjs/ui/floating/onboardingConstants.js +1 -70
  206. package/lib/commonjs/ui/floating/onboardingConstants.web.js +1 -34
  207. package/lib/commonjs/ui/fonts.js +1 -12
  208. package/lib/commonjs/ui/gameUI/components/GameUICollapsibleSection.js +1 -121
  209. package/lib/commonjs/ui/gameUI/components/GameUICompactStats.js +1 -336
  210. package/lib/commonjs/ui/gameUI/components/GameUIIssuesList.js +1 -284
  211. package/lib/commonjs/ui/gameUI/components/GameUIStatusHeader.js +1 -145
  212. package/lib/commonjs/ui/gameUI/constants/gameUIColors.js +1 -224
  213. package/lib/commonjs/ui/gameUI/constants/macOSDesignSystemColors.js +1 -224
  214. package/lib/commonjs/ui/gameUI/hooks/useGameUIAlertState.js +1 -110
  215. package/lib/commonjs/ui/gameUI/index.js +1 -72
  216. package/lib/commonjs/ui/index.js +1 -217
  217. package/lib/commonjs/ui/listPresets.js +1 -43
  218. package/lib/commonjs/ui/night/nightTheme.js +1 -130
  219. package/lib/commonjs/ui/night/primitives.js +1 -517
  220. package/lib/commonjs/ui/otto/OttoSceneView.js +1 -69
  221. package/lib/commonjs/ui/otto/OttoSprite.js +1 -510
  222. package/lib/commonjs/ui/otto/index.js +1 -60
  223. package/lib/commonjs/ui/otto/ottoEngine.js +1 -2737
  224. package/lib/commonjs/ui/otto/ottoScenes.js +1 -949
  225. package/lib/commonjs/ui/otto/ottoSheet.js +1 -191
  226. package/lib/commonjs/ui/toolTheme.js +1 -97
  227. package/lib/commonjs/utils/absoluteFill.js +1 -28
  228. package/lib/commonjs/utils/browserAsyncStorage.js +1 -0
  229. package/lib/commonjs/utils/browserNavigation.js +1 -0
  230. package/lib/commonjs/utils/devServer.js +1 -62
  231. package/lib/commonjs/utils/devServer.web.js +1 -0
  232. package/lib/commonjs/utils/displayValue.js +1 -41
  233. package/lib/commonjs/utils/domRuntime.js +1 -0
  234. package/lib/commonjs/utils/expoRouterModule.js +1 -0
  235. package/lib/commonjs/utils/expoRouterModule.web.js +1 -0
  236. package/lib/commonjs/utils/formatting/dataFormatting.js +1 -102
  237. package/lib/commonjs/utils/formatting/httpFormatting.js +1 -147
  238. package/lib/commonjs/utils/formatting/index.js +1 -27
  239. package/lib/commonjs/utils/getSafeAreaInsets.js +1 -40
  240. package/lib/commonjs/utils/getSafeAreaInsets.web.js +1 -0
  241. package/lib/commonjs/utils/index.js +1 -309
  242. package/lib/commonjs/utils/loadOptionalModule.js +1 -94
  243. package/lib/commonjs/utils/loadToolModule.js +1 -0
  244. package/lib/commonjs/utils/loadToolModule.web.js +1 -0
  245. package/lib/commonjs/utils/minimalSuperJSON.js +1 -347
  246. package/lib/commonjs/utils/modalStorage.js +1 -0
  247. package/lib/commonjs/utils/nativeWeb.js +1 -0
  248. package/lib/commonjs/utils/persistentStorage.js +1 -609
  249. package/lib/commonjs/utils/persistentStorage.web.js +1 -0
  250. package/lib/commonjs/utils/realNow.js +1 -0
  251. package/lib/commonjs/utils/reloadApp.js +1 -144
  252. package/lib/commonjs/utils/reloadPlatform.js +1 -0
  253. package/lib/commonjs/utils/reloadPlatform.web.js +1 -0
  254. package/lib/commonjs/utils/renderCaptureRegistry.js +1 -59
  255. package/lib/commonjs/utils/safeExpoRouter.js +1 -250
  256. package/lib/commonjs/utils/safeExpoRouter.web.js +1 -0
  257. package/lib/commonjs/utils/safeStringify.js +1 -229
  258. package/lib/commonjs/utils/snapshotProviderKit.js +1 -167
  259. package/lib/commonjs/utils/stateSnapshotRegistry.js +1 -71
  260. package/lib/commonjs/utils/stateTools.js +1 -160
  261. package/lib/commonjs/utils/subscribable.js +1 -113
  262. package/lib/commonjs/utils/subscriberCountNotifier.js +1 -72
  263. package/lib/commonjs/utils/time/RelativeTime.js +1 -31
  264. package/lib/commonjs/utils/time/TickContext.js +1 -43
  265. package/lib/commonjs/utils/time/formatRelativeTime.js +1 -34
  266. package/lib/commonjs/utils/time/index.js +1 -39
  267. package/lib/commonjs/utils/time/useRelativeTime.js +1 -36
  268. package/lib/commonjs/utils/toolModules.js +1 -0
  269. package/lib/commonjs/utils/typeHelpers.js +1 -142
  270. package/lib/commonjs/utils/valueFormatting.js +1 -140
  271. package/lib/module/JsModal.js +1 -1810
  272. package/lib/module/JsModal.web.js +1 -1648
  273. package/lib/module/clipboard/autoDetectClipboard.js +1 -45
  274. package/lib/module/clipboard/clipboard-impl.js +1 -121
  275. package/lib/module/clipboard/clipboard-impl.web.js +1 -0
  276. package/lib/module/clipboard/copyToClipboard.js +1 -60
  277. package/lib/module/clipboard/index.js +1 -5
  278. package/lib/module/colors/index.js +1 -21
  279. package/lib/module/context/HintsContext.js +1 -43
  280. package/lib/module/context/index.js +1 -3
  281. package/lib/module/dataViewer/CyberpunkInput.js +1 -384
  282. package/lib/module/dataViewer/DataTreeActionBar.js +1 -385
  283. package/lib/module/dataViewer/DataTreeActionDock.js +1 -222
  284. package/lib/module/dataViewer/DataViewer.js +1 -153
  285. package/lib/module/dataViewer/DiffSummary.js +1 -129
  286. package/lib/module/dataViewer/IndentGuides.js +1 -124
  287. package/lib/module/dataViewer/IndentGuidesOverlay.js +1 -99
  288. package/lib/module/dataViewer/JsonStringNotice.js +1 -54
  289. package/lib/module/dataViewer/LiveExplorer.js +1 -937
  290. package/lib/module/dataViewer/SplitDiffViewer.js +1 -416
  291. package/lib/module/dataViewer/ThemedSplitView.js +1 -637
  292. package/lib/module/dataViewer/TimestampDeltaBar.js +1 -91
  293. package/lib/module/dataViewer/TypeLegend.js +1 -105
  294. package/lib/module/dataViewer/ValueEditModal.js +1 -382
  295. package/lib/module/dataViewer/VirtualizedDataExplorer.js +1 -1265
  296. package/lib/module/dataViewer/diffThemes.js +1 -109
  297. package/lib/module/dataViewer/index.js +1 -57
  298. package/lib/module/dataViewer/jsonOps.js +1 -311
  299. package/lib/module/dataViewer/jsonStringValue.js +1 -89
  300. package/lib/module/dataViewer/lineDiff.js +1 -564
  301. package/lib/module/dataViewer/nestedPath.js +1 -109
  302. package/lib/module/dataViewer/objectDiff.js +1 -297
  303. package/lib/module/dataViewer/timestampDiff.js +1 -139
  304. package/lib/module/dataViewer/tree/TreeDiffViewer.js +1 -907
  305. package/lib/module/dataViewer/treeActions.js +1 -162
  306. package/lib/module/dataViewer/useTreeDraft.js +1 -121
  307. package/lib/module/dataViewer/useTreeEditor.js +1 -101
  308. package/lib/module/env/EnvironmentIndicator.js +1 -125
  309. package/lib/module/env/EnvironmentIndicator.web.js +1 -108
  310. package/lib/module/env/EnvironmentSelector.js +1 -201
  311. package/lib/module/env/EnvironmentSelectorInline.js +1 -295
  312. package/lib/module/env/EnvironmentSelectorInline.web.js +1 -173
  313. package/lib/module/history/HistoryProvider.js +1 -237
  314. package/lib/module/history/components/HistoryEntryRow.js +1 -142
  315. package/lib/module/history/components/HistoryList.js +1 -169
  316. package/lib/module/history/components/index.js +1 -8
  317. package/lib/module/history/index.js +1 -15
  318. package/lib/module/history/types.js +1 -3
  319. package/lib/module/hooks/index.js +1 -9
  320. package/lib/module/hooks/safe-area-impl.js +1 -23
  321. package/lib/module/hooks/useChangeLog.js +1 -50
  322. package/lib/module/hooks/useDeviceInfo.js +1 -519
  323. package/lib/module/hooks/useEventStoreEvents.js +1 -61
  324. package/lib/module/hooks/useFilterManager.js +1 -132
  325. package/lib/module/hooks/usePersistedState.js +1 -102
  326. package/lib/module/hooks/useSafeAreaInsets.js +1 -245
  327. package/lib/module/hooks/useSafeAreaInsets.web.js +1 -0
  328. package/lib/module/icons/BenchmarkIcon.js +1 -104
  329. package/lib/module/icons/EnvLaptopIcon.js +1 -199
  330. package/lib/module/icons/IconBackground.js +1 -274
  331. package/lib/module/icons/ReactQueryIcon.js +1 -12
  332. package/lib/module/icons/RenderCountIcon.js +1 -142
  333. package/lib/module/icons/RouteMapIcon.js +1 -245
  334. package/lib/module/icons/SentryBugIcon.js +1 -14
  335. package/lib/module/icons/StackPulseIcon.js +1 -153
  336. package/lib/module/icons/StorageStackIcon.js +1 -151
  337. package/lib/module/icons/WifiCircuitIcon.js +1 -164
  338. package/lib/module/icons/index.js +1 -62
  339. package/lib/module/icons/lucide-icons-original-full.js +1 -3178
  340. package/lib/module/icons/lucide-icons.js +1 -2420
  341. package/lib/module/icons/primitives/GlobeIcon.js +1 -61
  342. package/lib/module/icons/primitives/icon-primitives.js +1 -161
  343. package/lib/module/icons/primitives/index.js +1 -15
  344. package/lib/module/index.js +1 -108
  345. package/lib/module/license/AccountSetup.js +1 -52
  346. package/lib/module/license/AccountSetup.web.js +14 -77
  347. package/lib/module/license/AccountSetupContent.js +1 -0
  348. package/lib/module/license/FeatureGate.js +1 -778
  349. package/lib/module/license/FreeAccountPrompt.js +1 -199
  350. package/lib/module/license/LicenseEntryModal.js +2 -388
  351. package/lib/module/license/accountRuntime.js +1 -0
  352. package/lib/module/license/accountRuntime.web.js +1 -0
  353. package/lib/module/license/index.js +1 -9
  354. package/lib/module/license/licenseModule.js +1 -107
  355. package/lib/module/license/openPricing.js +1 -31
  356. package/lib/module/license/tierLimits.js +1 -122
  357. package/lib/module/logger/index-sentry.js +1 -230
  358. package/lib/module/logger/index.js +1 -13
  359. package/lib/module/logger/logDump.js +1 -13
  360. package/lib/module/logger/types.js +1 -37
  361. package/lib/module/settings/components/BubbleSettingsSection.js +1 -378
  362. package/lib/module/settings/index.js +1 -3
  363. package/lib/module/storage/definePersistedSetting.js +1 -63
  364. package/lib/module/storage/devToolsStorageKeys.js +1 -352
  365. package/lib/module/storage/index.js +1 -4
  366. package/lib/module/stores/BaseEventStore.js +1 -339
  367. package/lib/module/stores/ChangeLog.js +1 -192
  368. package/lib/module/stores/createToolStore.js +1 -189
  369. package/lib/module/stores/floatingToolStore.js +1 -61
  370. package/lib/module/stores/floatingToolStore.test.js +1 -111
  371. package/lib/module/stores/ignoredPatternsCore.js +1 -69
  372. package/lib/module/stores/ignoredPatternsStore.js +1 -189
  373. package/lib/module/stores/ignoredPatternsStore.shared.js +1 -0
  374. package/lib/module/stores/ignoredPatternsStore.web.js +1 -221
  375. package/lib/module/stores/index.js +1 -10
  376. package/lib/module/sync/keyedArrays.js +1 -204
  377. package/lib/module/sync/toolActionRegistry.js +1 -236
  378. package/lib/module/sync/toolAttention.test.js +1 -50
  379. package/lib/module/sync/toolSyncAdapter.js +1 -58
  380. package/lib/module/sync/toolUiBridge.js +1 -123
  381. package/lib/module/sync/typedEdit.js +1 -220
  382. package/lib/module/sync/valuePath.js +1 -330
  383. package/lib/module/sync/valueShape.js +1 -153
  384. package/lib/module/sync/wireBudget.js +1 -92
  385. package/lib/module/sync/wireForm.js +1 -159
  386. package/lib/module/tools/defineTool.js +1 -74
  387. package/lib/module/types/types.d.js +1 -1
  388. package/lib/module/types/types.js +1 -32
  389. package/lib/module/ui/backgrounds/BackgroundSwitcher.js +1 -350
  390. package/lib/module/ui/backgrounds/ToolBackground.js +1 -72
  391. package/lib/module/ui/backgrounds/backgroundStore.js +1 -125
  392. package/lib/module/ui/backgrounds/index.js +1 -19
  393. package/lib/module/ui/backgrounds/primitives.js +1 -365
  394. package/lib/module/ui/backgrounds/registry.js +1 -91
  395. package/lib/module/ui/backgrounds/rng.js +1 -85
  396. package/lib/module/ui/backgrounds/skyClock.js +1 -39
  397. package/lib/module/ui/backgrounds/types.js +1 -1
  398. package/lib/module/ui/backgrounds/variants/daylight.js +1 -449
  399. package/lib/module/ui/backgrounds/variants/deepField.js +1 -378
  400. package/lib/module/ui/backgrounds/variants/hyperspace.js +1 -214
  401. package/lib/module/ui/backgrounds/variants/liveSky.js +1 -893
  402. package/lib/module/ui/backgrounds/variants/meteors.js +1 -397
  403. package/lib/module/ui/backgrounds/variants/moonlight.js +1 -468
  404. package/lib/module/ui/backgrounds/variants/underwater.js +1 -753
  405. package/lib/module/ui/backgrounds/variants/wormhole/motion.js +1 -44
  406. package/lib/module/ui/backgrounds/variants/wormhole/textures.js +1 -3
  407. package/lib/module/ui/backgrounds/variants/wormhole.js +1 -129
  408. package/lib/module/ui/components/BackButton.js +1 -43
  409. package/lib/module/ui/components/Badge.js +1 -218
  410. package/lib/module/ui/components/ChangeRow.js +1 -106
  411. package/lib/module/ui/components/ChipStrip.js +1 -91
  412. package/lib/module/ui/components/ClipboardHintBanner.js +1 -145
  413. package/lib/module/ui/components/CollapsibleSection.js +1 -166
  414. package/lib/module/ui/components/CompactFilterChips.js +1 -110
  415. package/lib/module/ui/components/CompactRow.js +1 -291
  416. package/lib/module/ui/components/CopyButton.js +1 -303
  417. package/lib/module/ui/components/DataInspector.js +1 -319
  418. package/lib/module/ui/components/DetailView.js +1 -354
  419. package/lib/module/ui/components/DetailViewToggle.js +1 -125
  420. package/lib/module/ui/components/DevToolsCard.js +1 -122
  421. package/lib/module/ui/components/DraggableHeader.js +1 -211
  422. package/lib/module/ui/components/DynamicFilterView.js +1 -754
  423. package/lib/module/ui/components/EmptyState.js +1 -144
  424. package/lib/module/ui/components/EntityFilterView.js +1 -351
  425. package/lib/module/ui/components/EventHistoryViewer/CompareBar.js +1 -206
  426. package/lib/module/ui/components/EventHistoryViewer/DiffModeTabs.js +1 -94
  427. package/lib/module/ui/components/EventHistoryViewer/EventHistoryViewer.js +1 -179
  428. package/lib/module/ui/components/EventHistoryViewer/EventPickerModal.js +1 -203
  429. package/lib/module/ui/components/EventHistoryViewer/ViewToggleCards.js +1 -132
  430. package/lib/module/ui/components/EventHistoryViewer/index.js +1 -19
  431. package/lib/module/ui/components/EventHistoryViewer/types.js +1 -3
  432. package/lib/module/ui/components/EventListItem.js +1 -243
  433. package/lib/module/ui/components/EventStepperFooter.js +1 -180
  434. package/lib/module/ui/components/ExpandablePopover.js +1 -378
  435. package/lib/module/ui/components/ExpandedInfoRow.js +1 -103
  436. package/lib/module/ui/components/ExportPreview.js +1 -169
  437. package/lib/module/ui/components/FilterComponents.js +1 -282
  438. package/lib/module/ui/components/GripVerticalIcon.js +1 -61
  439. package/lib/module/ui/components/HeaderSearchButton.js +1 -46
  440. package/lib/module/ui/components/InfoRow.js +1 -87
  441. package/lib/module/ui/components/ListItem.js +1 -169
  442. package/lib/module/ui/components/ModalHeader.js +1 -297
  443. package/lib/module/ui/components/ModalHintBanner.js +1 -143
  444. package/lib/module/ui/components/Pill.js +1 -111
  445. package/lib/module/ui/components/PowerToggleButton.js +1 -74
  446. package/lib/module/ui/components/SearchBar.js +1 -161
  447. package/lib/module/ui/components/SectionHeader.js +1 -125
  448. package/lib/module/ui/components/StatsCard.js +1 -194
  449. package/lib/module/ui/components/StatusIndicator.js +1 -227
  450. package/lib/module/ui/components/StorageTypeBadge.js +1 -93
  451. package/lib/module/ui/components/TabSelector.js +1 -98
  452. package/lib/module/ui/components/TimeDisplay.js +1 -138
  453. package/lib/module/ui/components/ToggleRow.js +1 -112
  454. package/lib/module/ui/components/ToolButton.js +1 -89
  455. package/lib/module/ui/components/ToolEmptyState.js +1 -149
  456. package/lib/module/ui/components/ToolFooter.js +1 -197
  457. package/lib/module/ui/components/ValueTypeBadge.js +1 -143
  458. package/lib/module/ui/components/WindowControls.js +1 -383
  459. package/lib/module/ui/components/index.js +1 -52
  460. package/lib/module/ui/components/windowDrag.js +1 -41
  461. package/lib/module/ui/console/CyberpunkButtonOutline.js +1 -257
  462. package/lib/module/ui/console/CyberpunkIconContainer.js +1 -182
  463. package/lib/module/ui/console/CyberpunkSectionButton.js +1 -119
  464. package/lib/module/ui/floating/FloatingTool.js +1 -1003
  465. package/lib/module/ui/floating/FloatingTool.web.js +1 -590
  466. package/lib/module/ui/floating/FloatingToolHost.js +1 -29
  467. package/lib/module/ui/floating/FloatingToolHost.web.js +1 -25
  468. package/lib/module/ui/floating/index.js +1 -6
  469. package/lib/module/ui/floating/index.web.js +1 -6
  470. package/lib/module/ui/floating/onboardingConstants.js +1 -64
  471. package/lib/module/ui/floating/onboardingConstants.web.js +1 -27
  472. package/lib/module/ui/fonts.js +1 -8
  473. package/lib/module/ui/gameUI/components/GameUICollapsibleSection.js +1 -117
  474. package/lib/module/ui/gameUI/components/GameUICompactStats.js +1 -332
  475. package/lib/module/ui/gameUI/components/GameUIIssuesList.js +1 -280
  476. package/lib/module/ui/gameUI/components/GameUIStatusHeader.js +1 -141
  477. package/lib/module/ui/gameUI/constants/gameUIColors.js +1 -220
  478. package/lib/module/ui/gameUI/constants/macOSDesignSystemColors.js +1 -219
  479. package/lib/module/ui/gameUI/hooks/useGameUIAlertState.js +1 -105
  480. package/lib/module/ui/gameUI/index.js +1 -19
  481. package/lib/module/ui/index.js +1 -31
  482. package/lib/module/ui/listPresets.js +1 -39
  483. package/lib/module/ui/night/nightTheme.js +1 -126
  484. package/lib/module/ui/night/primitives.js +1 -504
  485. package/lib/module/ui/otto/OttoSceneView.js +1 -64
  486. package/lib/module/ui/otto/OttoSprite.js +1 -496
  487. package/lib/module/ui/otto/index.js +1 -22
  488. package/lib/module/ui/otto/ottoEngine.js +1 -2729
  489. package/lib/module/ui/otto/ottoScenes.js +1 -942
  490. package/lib/module/ui/otto/ottoSheet.js +1 -180
  491. package/lib/module/ui/toolTheme.js +1 -93
  492. package/lib/module/utils/absoluteFill.js +1 -24
  493. package/lib/module/utils/browserAsyncStorage.js +1 -0
  494. package/lib/module/utils/browserNavigation.js +1 -0
  495. package/lib/module/utils/devServer.js +1 -58
  496. package/lib/module/utils/devServer.web.js +1 -0
  497. package/lib/module/utils/displayValue.js +1 -36
  498. package/lib/module/utils/domRuntime.js +1 -0
  499. package/lib/module/utils/expoRouterModule.js +1 -0
  500. package/lib/module/utils/expoRouterModule.web.js +1 -0
  501. package/lib/module/utils/formatting/dataFormatting.js +1 -93
  502. package/lib/module/utils/formatting/httpFormatting.js +1 -142
  503. package/lib/module/utils/formatting/index.js +1 -8
  504. package/lib/module/utils/getSafeAreaInsets.js +1 -36
  505. package/lib/module/utils/getSafeAreaInsets.web.js +1 -0
  506. package/lib/module/utils/index.js +1 -18
  507. package/lib/module/utils/loadOptionalModule.js +1 -89
  508. package/lib/module/utils/loadToolModule.js +1 -0
  509. package/lib/module/utils/loadToolModule.web.js +1 -0
  510. package/lib/module/utils/minimalSuperJSON.js +1 -342
  511. package/lib/module/utils/modalStorage.js +1 -0
  512. package/lib/module/utils/nativeWeb.js +1 -0
  513. package/lib/module/utils/persistentStorage.js +1 -603
  514. package/lib/module/utils/persistentStorage.web.js +1 -0
  515. package/lib/module/utils/realNow.js +1 -0
  516. package/lib/module/utils/reloadApp.js +1 -137
  517. package/lib/module/utils/reloadPlatform.js +1 -0
  518. package/lib/module/utils/reloadPlatform.web.js +1 -0
  519. package/lib/module/utils/renderCaptureRegistry.js +1 -54
  520. package/lib/module/utils/safeExpoRouter.js +1 -239
  521. package/lib/module/utils/safeExpoRouter.web.js +1 -0
  522. package/lib/module/utils/safeStringify.js +1 -225
  523. package/lib/module/utils/snapshotProviderKit.js +1 -156
  524. package/lib/module/utils/stateSnapshotRegistry.js +1 -64
  525. package/lib/module/utils/stateTools.js +1 -154
  526. package/lib/module/utils/subscribable.js +1 -108
  527. package/lib/module/utils/subscriberCountNotifier.js +1 -66
  528. package/lib/module/utils/time/RelativeTime.js +1 -28
  529. package/lib/module/utils/time/TickContext.js +1 -38
  530. package/lib/module/utils/time/formatRelativeTime.js +1 -30
  531. package/lib/module/utils/time/index.js +1 -6
  532. package/lib/module/utils/time/useRelativeTime.js +1 -33
  533. package/lib/module/utils/toolModules.js +1 -0
  534. package/lib/module/utils/typeHelpers.js +1 -130
  535. package/lib/module/utils/valueFormatting.js +1 -131
  536. package/lib/typescript/commonjs/JsModal.web.d.ts +7 -18
  537. package/lib/typescript/commonjs/clipboard/clipboard-impl.web.d.ts +5 -0
  538. package/lib/typescript/commonjs/hooks/safe-area-impl.d.ts +1 -1
  539. package/lib/typescript/commonjs/hooks/useSafeAreaInsets.web.d.ts +6 -0
  540. package/lib/typescript/commonjs/icons/index.d.ts +2 -0
  541. package/lib/typescript/commonjs/index.d.ts +3 -1
  542. package/lib/typescript/commonjs/license/AccountSetup.web.d.ts +1 -1
  543. package/lib/typescript/commonjs/license/AccountSetupContent.d.ts +11 -0
  544. package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts +3 -15
  545. package/lib/typescript/commonjs/license/accountRuntime.d.ts +2 -0
  546. package/lib/typescript/commonjs/license/accountRuntime.web.d.ts +2 -0
  547. package/lib/typescript/commonjs/license/licenseModule.d.ts +3 -1
  548. package/lib/typescript/commonjs/storage/devToolsStorageKeys.d.ts +8 -0
  549. package/lib/typescript/commonjs/stores/ignoredPatternsStore.d.ts +1 -59
  550. package/lib/typescript/commonjs/stores/ignoredPatternsStore.shared.d.ts +60 -0
  551. package/lib/typescript/commonjs/stores/ignoredPatternsStore.web.d.ts +1 -71
  552. package/lib/typescript/commonjs/ui/night/primitives.d.ts +9 -3
  553. package/lib/typescript/commonjs/ui/otto/ottoEngine.d.ts +1 -1
  554. package/lib/typescript/commonjs/utils/browserAsyncStorage.d.ts +25 -0
  555. package/lib/typescript/commonjs/utils/browserNavigation.d.ts +31 -0
  556. package/lib/typescript/commonjs/utils/devServer.web.d.ts +2 -0
  557. package/lib/typescript/commonjs/utils/domRuntime.d.ts +27 -0
  558. package/lib/typescript/commonjs/utils/expoRouterModule.d.ts +3 -0
  559. package/lib/typescript/commonjs/utils/expoRouterModule.web.d.ts +3 -0
  560. package/lib/typescript/commonjs/utils/getSafeAreaInsets.web.d.ts +8 -0
  561. package/lib/typescript/commonjs/utils/index.d.ts +6 -0
  562. package/lib/typescript/commonjs/utils/loadToolModule.d.ts +3 -0
  563. package/lib/typescript/commonjs/utils/loadToolModule.web.d.ts +2 -0
  564. package/lib/typescript/commonjs/utils/modalStorage.d.ts +21 -0
  565. package/lib/typescript/commonjs/utils/nativeWeb.d.ts +22 -0
  566. package/lib/typescript/commonjs/utils/persistentStorage.web.d.ts +6 -0
  567. package/lib/typescript/commonjs/utils/realNow.d.ts +11 -0
  568. package/lib/typescript/commonjs/utils/reloadApp.d.ts +7 -25
  569. package/lib/typescript/commonjs/utils/reloadPlatform.d.ts +8 -0
  570. package/lib/typescript/commonjs/utils/reloadPlatform.web.d.ts +4 -0
  571. package/lib/typescript/commonjs/utils/safeExpoRouter.web.d.ts +43 -0
  572. package/lib/typescript/commonjs/utils/toolModules.d.ts +5 -0
  573. package/lib/typescript/module/JsModal.web.d.ts +7 -18
  574. package/lib/typescript/module/clipboard/clipboard-impl.web.d.ts +5 -0
  575. package/lib/typescript/module/hooks/safe-area-impl.d.ts +1 -1
  576. package/lib/typescript/module/hooks/useSafeAreaInsets.web.d.ts +6 -0
  577. package/lib/typescript/module/icons/index.d.ts +2 -0
  578. package/lib/typescript/module/index.d.ts +3 -1
  579. package/lib/typescript/module/license/AccountSetup.web.d.ts +1 -1
  580. package/lib/typescript/module/license/AccountSetupContent.d.ts +11 -0
  581. package/lib/typescript/module/license/FreeAccountPrompt.d.ts +3 -15
  582. package/lib/typescript/module/license/accountRuntime.d.ts +2 -0
  583. package/lib/typescript/module/license/accountRuntime.web.d.ts +2 -0
  584. package/lib/typescript/module/license/licenseModule.d.ts +3 -1
  585. package/lib/typescript/module/storage/devToolsStorageKeys.d.ts +8 -0
  586. package/lib/typescript/module/stores/ignoredPatternsStore.d.ts +1 -59
  587. package/lib/typescript/module/stores/ignoredPatternsStore.shared.d.ts +60 -0
  588. package/lib/typescript/module/stores/ignoredPatternsStore.web.d.ts +1 -71
  589. package/lib/typescript/module/ui/night/primitives.d.ts +9 -3
  590. package/lib/typescript/module/ui/otto/ottoEngine.d.ts +1 -1
  591. package/lib/typescript/module/utils/browserAsyncStorage.d.ts +25 -0
  592. package/lib/typescript/module/utils/browserNavigation.d.ts +31 -0
  593. package/lib/typescript/module/utils/devServer.web.d.ts +2 -0
  594. package/lib/typescript/module/utils/domRuntime.d.ts +27 -0
  595. package/lib/typescript/module/utils/expoRouterModule.d.ts +3 -0
  596. package/lib/typescript/module/utils/expoRouterModule.web.d.ts +3 -0
  597. package/lib/typescript/module/utils/getSafeAreaInsets.web.d.ts +8 -0
  598. package/lib/typescript/module/utils/index.d.ts +6 -0
  599. package/lib/typescript/module/utils/loadToolModule.d.ts +3 -0
  600. package/lib/typescript/module/utils/loadToolModule.web.d.ts +2 -0
  601. package/lib/typescript/module/utils/modalStorage.d.ts +21 -0
  602. package/lib/typescript/module/utils/nativeWeb.d.ts +22 -0
  603. package/lib/typescript/module/utils/persistentStorage.web.d.ts +6 -0
  604. package/lib/typescript/module/utils/realNow.d.ts +11 -0
  605. package/lib/typescript/module/utils/reloadApp.d.ts +7 -25
  606. package/lib/typescript/module/utils/reloadPlatform.d.ts +8 -0
  607. package/lib/typescript/module/utils/reloadPlatform.web.d.ts +4 -0
  608. package/lib/typescript/module/utils/safeExpoRouter.web.d.ts +43 -0
  609. package/lib/typescript/module/utils/toolModules.d.ts +5 -0
  610. package/lib/web/asyncStorage.mjs +1 -0
  611. package/lib/web/chunks/chunk-26OV3QDY.mjs +1 -0
  612. package/lib/web/chunks/chunk-3UTMGIUG.mjs +1 -0
  613. package/lib/web/chunks/chunk-53J2FMUD.mjs +1 -0
  614. package/lib/web/chunks/chunk-5KWAGM5V.mjs +1 -0
  615. package/lib/web/chunks/chunk-5NZOQR6Q.mjs +1 -0
  616. package/lib/web/chunks/chunk-7PRKERDN.mjs +1 -0
  617. package/lib/web/chunks/chunk-CE5U3CSQ.mjs +1 -0
  618. package/lib/web/chunks/chunk-D4RXBAOO.mjs +15 -0
  619. package/lib/web/chunks/chunk-ER3T3IDI.mjs +1 -0
  620. package/lib/web/chunks/chunk-GF5C5DVX.mjs +1 -0
  621. package/lib/web/chunks/chunk-K7CGIEFU.mjs +1 -0
  622. package/lib/web/chunks/chunk-L3AFTHWX.mjs +14 -0
  623. package/lib/web/chunks/chunk-LZ7FZZ7R.mjs +1 -0
  624. package/lib/web/chunks/chunk-PTK5FO6C.mjs +1 -0
  625. package/lib/web/chunks/chunk-TJUBBXXK.mjs +1 -0
  626. package/lib/web/chunks/chunk-UKYVRCMZ.mjs +1 -0
  627. package/lib/web/chunks/chunk-XYUAUO57.mjs +1 -0
  628. package/lib/web/chunks/persistentStorage.web-6OAJAVRK.mjs +1 -0
  629. package/lib/web/colors.mjs +1 -0
  630. package/lib/web/dataViewer.mjs +2 -0
  631. package/lib/web/floating.mjs +1 -0
  632. package/lib/web/history.mjs +1 -0
  633. package/lib/web/hooks.mjs +1 -0
  634. package/lib/web/index.mjs +14 -0
  635. package/lib/web/native.mjs +1 -0
  636. package/lib/web/ui.mjs +1 -0
  637. package/lib/web/utils.mjs +1 -0
  638. package/package.json +121 -38
  639. package/scripts/detect-clipboard.js +5 -121
  640. package/scripts/detect-safe-area.js +3 -127
  641. package/ui.js +1 -7
  642. package/utils.js +1 -7
  643. package/lib/typescript/commonjs/JsModal.d.ts.map +0 -1
  644. package/lib/typescript/commonjs/JsModal.web.d.ts.map +0 -1
  645. package/lib/typescript/commonjs/clipboard/autoDetectClipboard.d.ts.map +0 -1
  646. package/lib/typescript/commonjs/clipboard/clipboard-impl.d.ts.map +0 -1
  647. package/lib/typescript/commonjs/clipboard/copyToClipboard.d.ts.map +0 -1
  648. package/lib/typescript/commonjs/clipboard/index.d.ts.map +0 -1
  649. package/lib/typescript/commonjs/colors/index.d.ts.map +0 -1
  650. package/lib/typescript/commonjs/context/HintsContext.d.ts.map +0 -1
  651. package/lib/typescript/commonjs/context/index.d.ts.map +0 -1
  652. package/lib/typescript/commonjs/dataViewer/CyberpunkInput.d.ts.map +0 -1
  653. package/lib/typescript/commonjs/dataViewer/DataTreeActionBar.d.ts.map +0 -1
  654. package/lib/typescript/commonjs/dataViewer/DataTreeActionDock.d.ts.map +0 -1
  655. package/lib/typescript/commonjs/dataViewer/DataViewer.d.ts.map +0 -1
  656. package/lib/typescript/commonjs/dataViewer/DiffSummary.d.ts.map +0 -1
  657. package/lib/typescript/commonjs/dataViewer/IndentGuides.d.ts.map +0 -1
  658. package/lib/typescript/commonjs/dataViewer/IndentGuidesOverlay.d.ts.map +0 -1
  659. package/lib/typescript/commonjs/dataViewer/JsonStringNotice.d.ts.map +0 -1
  660. package/lib/typescript/commonjs/dataViewer/LiveExplorer.d.ts.map +0 -1
  661. package/lib/typescript/commonjs/dataViewer/SplitDiffViewer.d.ts.map +0 -1
  662. package/lib/typescript/commonjs/dataViewer/ThemedSplitView.d.ts.map +0 -1
  663. package/lib/typescript/commonjs/dataViewer/TimestampDeltaBar.d.ts.map +0 -1
  664. package/lib/typescript/commonjs/dataViewer/TypeLegend.d.ts.map +0 -1
  665. package/lib/typescript/commonjs/dataViewer/ValueEditModal.d.ts.map +0 -1
  666. package/lib/typescript/commonjs/dataViewer/VirtualizedDataExplorer.d.ts.map +0 -1
  667. package/lib/typescript/commonjs/dataViewer/diffThemes.d.ts.map +0 -1
  668. package/lib/typescript/commonjs/dataViewer/index.d.ts.map +0 -1
  669. package/lib/typescript/commonjs/dataViewer/jsonOps.d.ts.map +0 -1
  670. package/lib/typescript/commonjs/dataViewer/jsonStringValue.d.ts.map +0 -1
  671. package/lib/typescript/commonjs/dataViewer/lineDiff.d.ts.map +0 -1
  672. package/lib/typescript/commonjs/dataViewer/nestedPath.d.ts.map +0 -1
  673. package/lib/typescript/commonjs/dataViewer/objectDiff.d.ts.map +0 -1
  674. package/lib/typescript/commonjs/dataViewer/timestampDiff.d.ts.map +0 -1
  675. package/lib/typescript/commonjs/dataViewer/tree/TreeDiffViewer.d.ts.map +0 -1
  676. package/lib/typescript/commonjs/dataViewer/treeActions.d.ts.map +0 -1
  677. package/lib/typescript/commonjs/dataViewer/useTreeDraft.d.ts.map +0 -1
  678. package/lib/typescript/commonjs/dataViewer/useTreeEditor.d.ts.map +0 -1
  679. package/lib/typescript/commonjs/env/EnvironmentIndicator.d.ts.map +0 -1
  680. package/lib/typescript/commonjs/env/EnvironmentIndicator.web.d.ts.map +0 -1
  681. package/lib/typescript/commonjs/env/EnvironmentSelector.d.ts.map +0 -1
  682. package/lib/typescript/commonjs/env/EnvironmentSelectorInline.d.ts.map +0 -1
  683. package/lib/typescript/commonjs/env/EnvironmentSelectorInline.web.d.ts.map +0 -1
  684. package/lib/typescript/commonjs/history/HistoryProvider.d.ts.map +0 -1
  685. package/lib/typescript/commonjs/history/components/HistoryEntryRow.d.ts.map +0 -1
  686. package/lib/typescript/commonjs/history/components/HistoryList.d.ts.map +0 -1
  687. package/lib/typescript/commonjs/history/components/index.d.ts.map +0 -1
  688. package/lib/typescript/commonjs/history/index.d.ts.map +0 -1
  689. package/lib/typescript/commonjs/history/types.d.ts.map +0 -1
  690. package/lib/typescript/commonjs/hooks/index.d.ts.map +0 -1
  691. package/lib/typescript/commonjs/hooks/safe-area-impl.d.ts.map +0 -1
  692. package/lib/typescript/commonjs/hooks/useChangeLog.d.ts.map +0 -1
  693. package/lib/typescript/commonjs/hooks/useDeviceInfo.d.ts.map +0 -1
  694. package/lib/typescript/commonjs/hooks/useEventStoreEvents.d.ts.map +0 -1
  695. package/lib/typescript/commonjs/hooks/useFilterManager.d.ts.map +0 -1
  696. package/lib/typescript/commonjs/hooks/usePersistedState.d.ts.map +0 -1
  697. package/lib/typescript/commonjs/hooks/useSafeAreaInsets.d.ts.map +0 -1
  698. package/lib/typescript/commonjs/icons/BenchmarkIcon.d.ts.map +0 -1
  699. package/lib/typescript/commonjs/icons/EnvLaptopIcon.d.ts.map +0 -1
  700. package/lib/typescript/commonjs/icons/IconBackground.d.ts.map +0 -1
  701. package/lib/typescript/commonjs/icons/ReactQueryIcon.d.ts.map +0 -1
  702. package/lib/typescript/commonjs/icons/RenderCountIcon.d.ts.map +0 -1
  703. package/lib/typescript/commonjs/icons/RouteMapIcon.d.ts.map +0 -1
  704. package/lib/typescript/commonjs/icons/SentryBugIcon.d.ts.map +0 -1
  705. package/lib/typescript/commonjs/icons/StackPulseIcon.d.ts.map +0 -1
  706. package/lib/typescript/commonjs/icons/StorageStackIcon.d.ts.map +0 -1
  707. package/lib/typescript/commonjs/icons/WifiCircuitIcon.d.ts.map +0 -1
  708. package/lib/typescript/commonjs/icons/index.d.ts.map +0 -1
  709. package/lib/typescript/commonjs/icons/lucide-icons-original-full.d.ts.map +0 -1
  710. package/lib/typescript/commonjs/icons/lucide-icons.d.ts.map +0 -1
  711. package/lib/typescript/commonjs/icons/primitives/GlobeIcon.d.ts.map +0 -1
  712. package/lib/typescript/commonjs/icons/primitives/icon-primitives.d.ts.map +0 -1
  713. package/lib/typescript/commonjs/icons/primitives/index.d.ts.map +0 -1
  714. package/lib/typescript/commonjs/index.d.ts.map +0 -1
  715. package/lib/typescript/commonjs/license/AccountSetup.d.ts.map +0 -1
  716. package/lib/typescript/commonjs/license/AccountSetup.web.d.ts.map +0 -1
  717. package/lib/typescript/commonjs/license/FeatureGate.d.ts.map +0 -1
  718. package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts.map +0 -1
  719. package/lib/typescript/commonjs/license/LicenseEntryModal.d.ts.map +0 -1
  720. package/lib/typescript/commonjs/license/index.d.ts.map +0 -1
  721. package/lib/typescript/commonjs/license/licenseModule.d.ts.map +0 -1
  722. package/lib/typescript/commonjs/license/openPricing.d.ts.map +0 -1
  723. package/lib/typescript/commonjs/license/tierLimits.d.ts.map +0 -1
  724. package/lib/typescript/commonjs/logger/index-sentry.d.ts.map +0 -1
  725. package/lib/typescript/commonjs/logger/index.d.ts.map +0 -1
  726. package/lib/typescript/commonjs/logger/logDump.d.ts.map +0 -1
  727. package/lib/typescript/commonjs/logger/types.d.ts.map +0 -1
  728. package/lib/typescript/commonjs/settings/components/BubbleSettingsSection.d.ts.map +0 -1
  729. package/lib/typescript/commonjs/settings/index.d.ts.map +0 -1
  730. package/lib/typescript/commonjs/storage/definePersistedSetting.d.ts.map +0 -1
  731. package/lib/typescript/commonjs/storage/devToolsStorageKeys.d.ts.map +0 -1
  732. package/lib/typescript/commonjs/storage/index.d.ts.map +0 -1
  733. package/lib/typescript/commonjs/stores/BaseEventStore.d.ts.map +0 -1
  734. package/lib/typescript/commonjs/stores/ChangeLog.d.ts.map +0 -1
  735. package/lib/typescript/commonjs/stores/createToolStore.d.ts.map +0 -1
  736. package/lib/typescript/commonjs/stores/floatingToolStore.d.ts.map +0 -1
  737. package/lib/typescript/commonjs/stores/floatingToolStore.test.d.ts.map +0 -1
  738. package/lib/typescript/commonjs/stores/ignoredPatternsCore.d.ts.map +0 -1
  739. package/lib/typescript/commonjs/stores/ignoredPatternsStore.d.ts.map +0 -1
  740. package/lib/typescript/commonjs/stores/ignoredPatternsStore.web.d.ts.map +0 -1
  741. package/lib/typescript/commonjs/stores/index.d.ts.map +0 -1
  742. package/lib/typescript/commonjs/sync/keyedArrays.d.ts.map +0 -1
  743. package/lib/typescript/commonjs/sync/toolActionRegistry.d.ts.map +0 -1
  744. package/lib/typescript/commonjs/sync/toolAttention.test.d.ts.map +0 -1
  745. package/lib/typescript/commonjs/sync/toolSyncAdapter.d.ts.map +0 -1
  746. package/lib/typescript/commonjs/sync/toolUiBridge.d.ts.map +0 -1
  747. package/lib/typescript/commonjs/sync/typedEdit.d.ts.map +0 -1
  748. package/lib/typescript/commonjs/sync/valuePath.d.ts.map +0 -1
  749. package/lib/typescript/commonjs/sync/valueShape.d.ts.map +0 -1
  750. package/lib/typescript/commonjs/sync/wireBudget.d.ts.map +0 -1
  751. package/lib/typescript/commonjs/sync/wireForm.d.ts.map +0 -1
  752. package/lib/typescript/commonjs/tools/defineTool.d.ts.map +0 -1
  753. package/lib/typescript/commonjs/types/types.d.ts.map +0 -1
  754. package/lib/typescript/commonjs/ui/backgrounds/BackgroundSwitcher.d.ts.map +0 -1
  755. package/lib/typescript/commonjs/ui/backgrounds/ToolBackground.d.ts.map +0 -1
  756. package/lib/typescript/commonjs/ui/backgrounds/backgroundStore.d.ts.map +0 -1
  757. package/lib/typescript/commonjs/ui/backgrounds/index.d.ts.map +0 -1
  758. package/lib/typescript/commonjs/ui/backgrounds/primitives.d.ts.map +0 -1
  759. package/lib/typescript/commonjs/ui/backgrounds/registry.d.ts.map +0 -1
  760. package/lib/typescript/commonjs/ui/backgrounds/rng.d.ts.map +0 -1
  761. package/lib/typescript/commonjs/ui/backgrounds/skyClock.d.ts.map +0 -1
  762. package/lib/typescript/commonjs/ui/backgrounds/types.d.ts.map +0 -1
  763. package/lib/typescript/commonjs/ui/backgrounds/variants/daylight.d.ts.map +0 -1
  764. package/lib/typescript/commonjs/ui/backgrounds/variants/deepField.d.ts.map +0 -1
  765. package/lib/typescript/commonjs/ui/backgrounds/variants/hyperspace.d.ts.map +0 -1
  766. package/lib/typescript/commonjs/ui/backgrounds/variants/liveSky.d.ts.map +0 -1
  767. package/lib/typescript/commonjs/ui/backgrounds/variants/meteors.d.ts.map +0 -1
  768. package/lib/typescript/commonjs/ui/backgrounds/variants/moonlight.d.ts.map +0 -1
  769. package/lib/typescript/commonjs/ui/backgrounds/variants/underwater.d.ts.map +0 -1
  770. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/motion.d.ts.map +0 -1
  771. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/textures.d.ts.map +0 -1
  772. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole.d.ts.map +0 -1
  773. package/lib/typescript/commonjs/ui/components/BackButton.d.ts.map +0 -1
  774. package/lib/typescript/commonjs/ui/components/Badge.d.ts.map +0 -1
  775. package/lib/typescript/commonjs/ui/components/ChangeRow.d.ts.map +0 -1
  776. package/lib/typescript/commonjs/ui/components/ChipStrip.d.ts.map +0 -1
  777. package/lib/typescript/commonjs/ui/components/ClipboardHintBanner.d.ts.map +0 -1
  778. package/lib/typescript/commonjs/ui/components/CollapsibleSection.d.ts.map +0 -1
  779. package/lib/typescript/commonjs/ui/components/CompactFilterChips.d.ts.map +0 -1
  780. package/lib/typescript/commonjs/ui/components/CompactRow.d.ts.map +0 -1
  781. package/lib/typescript/commonjs/ui/components/CopyButton.d.ts.map +0 -1
  782. package/lib/typescript/commonjs/ui/components/DataInspector.d.ts.map +0 -1
  783. package/lib/typescript/commonjs/ui/components/DetailView.d.ts.map +0 -1
  784. package/lib/typescript/commonjs/ui/components/DetailViewToggle.d.ts.map +0 -1
  785. package/lib/typescript/commonjs/ui/components/DevToolsCard.d.ts.map +0 -1
  786. package/lib/typescript/commonjs/ui/components/DraggableHeader.d.ts.map +0 -1
  787. package/lib/typescript/commonjs/ui/components/DynamicFilterView.d.ts.map +0 -1
  788. package/lib/typescript/commonjs/ui/components/EmptyState.d.ts.map +0 -1
  789. package/lib/typescript/commonjs/ui/components/EntityFilterView.d.ts.map +0 -1
  790. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/CompareBar.d.ts.map +0 -1
  791. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/DiffModeTabs.d.ts.map +0 -1
  792. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/EventHistoryViewer.d.ts.map +0 -1
  793. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/EventPickerModal.d.ts.map +0 -1
  794. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/ViewToggleCards.d.ts.map +0 -1
  795. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/index.d.ts.map +0 -1
  796. package/lib/typescript/commonjs/ui/components/EventHistoryViewer/types.d.ts.map +0 -1
  797. package/lib/typescript/commonjs/ui/components/EventListItem.d.ts.map +0 -1
  798. package/lib/typescript/commonjs/ui/components/EventStepperFooter.d.ts.map +0 -1
  799. package/lib/typescript/commonjs/ui/components/ExpandablePopover.d.ts.map +0 -1
  800. package/lib/typescript/commonjs/ui/components/ExpandedInfoRow.d.ts.map +0 -1
  801. package/lib/typescript/commonjs/ui/components/ExportPreview.d.ts.map +0 -1
  802. package/lib/typescript/commonjs/ui/components/FilterComponents.d.ts.map +0 -1
  803. package/lib/typescript/commonjs/ui/components/GripVerticalIcon.d.ts.map +0 -1
  804. package/lib/typescript/commonjs/ui/components/HeaderSearchButton.d.ts.map +0 -1
  805. package/lib/typescript/commonjs/ui/components/InfoRow.d.ts.map +0 -1
  806. package/lib/typescript/commonjs/ui/components/ListItem.d.ts.map +0 -1
  807. package/lib/typescript/commonjs/ui/components/ModalHeader.d.ts.map +0 -1
  808. package/lib/typescript/commonjs/ui/components/ModalHintBanner.d.ts.map +0 -1
  809. package/lib/typescript/commonjs/ui/components/Pill.d.ts.map +0 -1
  810. package/lib/typescript/commonjs/ui/components/PowerToggleButton.d.ts.map +0 -1
  811. package/lib/typescript/commonjs/ui/components/SearchBar.d.ts.map +0 -1
  812. package/lib/typescript/commonjs/ui/components/SectionHeader.d.ts.map +0 -1
  813. package/lib/typescript/commonjs/ui/components/StatsCard.d.ts.map +0 -1
  814. package/lib/typescript/commonjs/ui/components/StatusIndicator.d.ts.map +0 -1
  815. package/lib/typescript/commonjs/ui/components/StorageTypeBadge.d.ts.map +0 -1
  816. package/lib/typescript/commonjs/ui/components/TabSelector.d.ts.map +0 -1
  817. package/lib/typescript/commonjs/ui/components/TimeDisplay.d.ts.map +0 -1
  818. package/lib/typescript/commonjs/ui/components/ToggleRow.d.ts.map +0 -1
  819. package/lib/typescript/commonjs/ui/components/ToolButton.d.ts.map +0 -1
  820. package/lib/typescript/commonjs/ui/components/ToolEmptyState.d.ts.map +0 -1
  821. package/lib/typescript/commonjs/ui/components/ToolFooter.d.ts.map +0 -1
  822. package/lib/typescript/commonjs/ui/components/ValueTypeBadge.d.ts.map +0 -1
  823. package/lib/typescript/commonjs/ui/components/WindowControls.d.ts.map +0 -1
  824. package/lib/typescript/commonjs/ui/components/index.d.ts.map +0 -1
  825. package/lib/typescript/commonjs/ui/components/windowDrag.d.ts.map +0 -1
  826. package/lib/typescript/commonjs/ui/console/CyberpunkButtonOutline.d.ts.map +0 -1
  827. package/lib/typescript/commonjs/ui/console/CyberpunkIconContainer.d.ts.map +0 -1
  828. package/lib/typescript/commonjs/ui/console/CyberpunkSectionButton.d.ts.map +0 -1
  829. package/lib/typescript/commonjs/ui/floating/FloatingTool.d.ts.map +0 -1
  830. package/lib/typescript/commonjs/ui/floating/FloatingTool.web.d.ts.map +0 -1
  831. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.d.ts.map +0 -1
  832. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.web.d.ts.map +0 -1
  833. package/lib/typescript/commonjs/ui/floating/index.d.ts.map +0 -1
  834. package/lib/typescript/commonjs/ui/floating/index.web.d.ts.map +0 -1
  835. package/lib/typescript/commonjs/ui/floating/onboardingConstants.d.ts.map +0 -1
  836. package/lib/typescript/commonjs/ui/floating/onboardingConstants.web.d.ts.map +0 -1
  837. package/lib/typescript/commonjs/ui/fonts.d.ts.map +0 -1
  838. package/lib/typescript/commonjs/ui/gameUI/components/GameUICollapsibleSection.d.ts.map +0 -1
  839. package/lib/typescript/commonjs/ui/gameUI/components/GameUICompactStats.d.ts.map +0 -1
  840. package/lib/typescript/commonjs/ui/gameUI/components/GameUIIssuesList.d.ts.map +0 -1
  841. package/lib/typescript/commonjs/ui/gameUI/components/GameUIStatusHeader.d.ts.map +0 -1
  842. package/lib/typescript/commonjs/ui/gameUI/constants/gameUIColors.d.ts.map +0 -1
  843. package/lib/typescript/commonjs/ui/gameUI/constants/macOSDesignSystemColors.d.ts.map +0 -1
  844. package/lib/typescript/commonjs/ui/gameUI/hooks/useGameUIAlertState.d.ts.map +0 -1
  845. package/lib/typescript/commonjs/ui/gameUI/index.d.ts.map +0 -1
  846. package/lib/typescript/commonjs/ui/index.d.ts.map +0 -1
  847. package/lib/typescript/commonjs/ui/listPresets.d.ts.map +0 -1
  848. package/lib/typescript/commonjs/ui/night/nightTheme.d.ts.map +0 -1
  849. package/lib/typescript/commonjs/ui/night/primitives.d.ts.map +0 -1
  850. package/lib/typescript/commonjs/ui/otto/OttoSceneView.d.ts.map +0 -1
  851. package/lib/typescript/commonjs/ui/otto/OttoSprite.d.ts.map +0 -1
  852. package/lib/typescript/commonjs/ui/otto/index.d.ts.map +0 -1
  853. package/lib/typescript/commonjs/ui/otto/ottoEngine.d.ts.map +0 -1
  854. package/lib/typescript/commonjs/ui/otto/ottoScenes.d.ts.map +0 -1
  855. package/lib/typescript/commonjs/ui/otto/ottoSheet.d.ts.map +0 -1
  856. package/lib/typescript/commonjs/ui/toolTheme.d.ts.map +0 -1
  857. package/lib/typescript/commonjs/utils/absoluteFill.d.ts.map +0 -1
  858. package/lib/typescript/commonjs/utils/devServer.d.ts.map +0 -1
  859. package/lib/typescript/commonjs/utils/displayValue.d.ts.map +0 -1
  860. package/lib/typescript/commonjs/utils/formatting/dataFormatting.d.ts.map +0 -1
  861. package/lib/typescript/commonjs/utils/formatting/httpFormatting.d.ts.map +0 -1
  862. package/lib/typescript/commonjs/utils/formatting/index.d.ts.map +0 -1
  863. package/lib/typescript/commonjs/utils/getSafeAreaInsets.d.ts.map +0 -1
  864. package/lib/typescript/commonjs/utils/index.d.ts.map +0 -1
  865. package/lib/typescript/commonjs/utils/loadOptionalModule.d.ts.map +0 -1
  866. package/lib/typescript/commonjs/utils/minimalSuperJSON.d.ts.map +0 -1
  867. package/lib/typescript/commonjs/utils/persistentStorage.d.ts.map +0 -1
  868. package/lib/typescript/commonjs/utils/reloadApp.d.ts.map +0 -1
  869. package/lib/typescript/commonjs/utils/renderCaptureRegistry.d.ts.map +0 -1
  870. package/lib/typescript/commonjs/utils/safeExpoRouter.d.ts.map +0 -1
  871. package/lib/typescript/commonjs/utils/safeStringify.d.ts.map +0 -1
  872. package/lib/typescript/commonjs/utils/snapshotProviderKit.d.ts.map +0 -1
  873. package/lib/typescript/commonjs/utils/stateSnapshotRegistry.d.ts.map +0 -1
  874. package/lib/typescript/commonjs/utils/stateTools.d.ts.map +0 -1
  875. package/lib/typescript/commonjs/utils/subscribable.d.ts.map +0 -1
  876. package/lib/typescript/commonjs/utils/subscriberCountNotifier.d.ts.map +0 -1
  877. package/lib/typescript/commonjs/utils/time/RelativeTime.d.ts.map +0 -1
  878. package/lib/typescript/commonjs/utils/time/TickContext.d.ts.map +0 -1
  879. package/lib/typescript/commonjs/utils/time/formatRelativeTime.d.ts.map +0 -1
  880. package/lib/typescript/commonjs/utils/time/index.d.ts.map +0 -1
  881. package/lib/typescript/commonjs/utils/time/useRelativeTime.d.ts.map +0 -1
  882. package/lib/typescript/commonjs/utils/typeHelpers.d.ts.map +0 -1
  883. package/lib/typescript/commonjs/utils/valueFormatting.d.ts.map +0 -1
  884. package/lib/typescript/module/JsModal.d.ts.map +0 -1
  885. package/lib/typescript/module/JsModal.web.d.ts.map +0 -1
  886. package/lib/typescript/module/clipboard/autoDetectClipboard.d.ts.map +0 -1
  887. package/lib/typescript/module/clipboard/clipboard-impl.d.ts.map +0 -1
  888. package/lib/typescript/module/clipboard/copyToClipboard.d.ts.map +0 -1
  889. package/lib/typescript/module/clipboard/index.d.ts.map +0 -1
  890. package/lib/typescript/module/colors/index.d.ts.map +0 -1
  891. package/lib/typescript/module/context/HintsContext.d.ts.map +0 -1
  892. package/lib/typescript/module/context/index.d.ts.map +0 -1
  893. package/lib/typescript/module/dataViewer/CyberpunkInput.d.ts.map +0 -1
  894. package/lib/typescript/module/dataViewer/DataTreeActionBar.d.ts.map +0 -1
  895. package/lib/typescript/module/dataViewer/DataTreeActionDock.d.ts.map +0 -1
  896. package/lib/typescript/module/dataViewer/DataViewer.d.ts.map +0 -1
  897. package/lib/typescript/module/dataViewer/DiffSummary.d.ts.map +0 -1
  898. package/lib/typescript/module/dataViewer/IndentGuides.d.ts.map +0 -1
  899. package/lib/typescript/module/dataViewer/IndentGuidesOverlay.d.ts.map +0 -1
  900. package/lib/typescript/module/dataViewer/JsonStringNotice.d.ts.map +0 -1
  901. package/lib/typescript/module/dataViewer/LiveExplorer.d.ts.map +0 -1
  902. package/lib/typescript/module/dataViewer/SplitDiffViewer.d.ts.map +0 -1
  903. package/lib/typescript/module/dataViewer/ThemedSplitView.d.ts.map +0 -1
  904. package/lib/typescript/module/dataViewer/TimestampDeltaBar.d.ts.map +0 -1
  905. package/lib/typescript/module/dataViewer/TypeLegend.d.ts.map +0 -1
  906. package/lib/typescript/module/dataViewer/ValueEditModal.d.ts.map +0 -1
  907. package/lib/typescript/module/dataViewer/VirtualizedDataExplorer.d.ts.map +0 -1
  908. package/lib/typescript/module/dataViewer/diffThemes.d.ts.map +0 -1
  909. package/lib/typescript/module/dataViewer/index.d.ts.map +0 -1
  910. package/lib/typescript/module/dataViewer/jsonOps.d.ts.map +0 -1
  911. package/lib/typescript/module/dataViewer/jsonStringValue.d.ts.map +0 -1
  912. package/lib/typescript/module/dataViewer/lineDiff.d.ts.map +0 -1
  913. package/lib/typescript/module/dataViewer/nestedPath.d.ts.map +0 -1
  914. package/lib/typescript/module/dataViewer/objectDiff.d.ts.map +0 -1
  915. package/lib/typescript/module/dataViewer/timestampDiff.d.ts.map +0 -1
  916. package/lib/typescript/module/dataViewer/tree/TreeDiffViewer.d.ts.map +0 -1
  917. package/lib/typescript/module/dataViewer/treeActions.d.ts.map +0 -1
  918. package/lib/typescript/module/dataViewer/useTreeDraft.d.ts.map +0 -1
  919. package/lib/typescript/module/dataViewer/useTreeEditor.d.ts.map +0 -1
  920. package/lib/typescript/module/env/EnvironmentIndicator.d.ts.map +0 -1
  921. package/lib/typescript/module/env/EnvironmentIndicator.web.d.ts.map +0 -1
  922. package/lib/typescript/module/env/EnvironmentSelector.d.ts.map +0 -1
  923. package/lib/typescript/module/env/EnvironmentSelectorInline.d.ts.map +0 -1
  924. package/lib/typescript/module/env/EnvironmentSelectorInline.web.d.ts.map +0 -1
  925. package/lib/typescript/module/history/HistoryProvider.d.ts.map +0 -1
  926. package/lib/typescript/module/history/components/HistoryEntryRow.d.ts.map +0 -1
  927. package/lib/typescript/module/history/components/HistoryList.d.ts.map +0 -1
  928. package/lib/typescript/module/history/components/index.d.ts.map +0 -1
  929. package/lib/typescript/module/history/index.d.ts.map +0 -1
  930. package/lib/typescript/module/history/types.d.ts.map +0 -1
  931. package/lib/typescript/module/hooks/index.d.ts.map +0 -1
  932. package/lib/typescript/module/hooks/safe-area-impl.d.ts.map +0 -1
  933. package/lib/typescript/module/hooks/useChangeLog.d.ts.map +0 -1
  934. package/lib/typescript/module/hooks/useDeviceInfo.d.ts.map +0 -1
  935. package/lib/typescript/module/hooks/useEventStoreEvents.d.ts.map +0 -1
  936. package/lib/typescript/module/hooks/useFilterManager.d.ts.map +0 -1
  937. package/lib/typescript/module/hooks/usePersistedState.d.ts.map +0 -1
  938. package/lib/typescript/module/hooks/useSafeAreaInsets.d.ts.map +0 -1
  939. package/lib/typescript/module/icons/BenchmarkIcon.d.ts.map +0 -1
  940. package/lib/typescript/module/icons/EnvLaptopIcon.d.ts.map +0 -1
  941. package/lib/typescript/module/icons/IconBackground.d.ts.map +0 -1
  942. package/lib/typescript/module/icons/ReactQueryIcon.d.ts.map +0 -1
  943. package/lib/typescript/module/icons/RenderCountIcon.d.ts.map +0 -1
  944. package/lib/typescript/module/icons/RouteMapIcon.d.ts.map +0 -1
  945. package/lib/typescript/module/icons/SentryBugIcon.d.ts.map +0 -1
  946. package/lib/typescript/module/icons/StackPulseIcon.d.ts.map +0 -1
  947. package/lib/typescript/module/icons/StorageStackIcon.d.ts.map +0 -1
  948. package/lib/typescript/module/icons/WifiCircuitIcon.d.ts.map +0 -1
  949. package/lib/typescript/module/icons/index.d.ts.map +0 -1
  950. package/lib/typescript/module/icons/lucide-icons-original-full.d.ts.map +0 -1
  951. package/lib/typescript/module/icons/lucide-icons.d.ts.map +0 -1
  952. package/lib/typescript/module/icons/primitives/GlobeIcon.d.ts.map +0 -1
  953. package/lib/typescript/module/icons/primitives/icon-primitives.d.ts.map +0 -1
  954. package/lib/typescript/module/icons/primitives/index.d.ts.map +0 -1
  955. package/lib/typescript/module/index.d.ts.map +0 -1
  956. package/lib/typescript/module/license/AccountSetup.d.ts.map +0 -1
  957. package/lib/typescript/module/license/AccountSetup.web.d.ts.map +0 -1
  958. package/lib/typescript/module/license/FeatureGate.d.ts.map +0 -1
  959. package/lib/typescript/module/license/FreeAccountPrompt.d.ts.map +0 -1
  960. package/lib/typescript/module/license/LicenseEntryModal.d.ts.map +0 -1
  961. package/lib/typescript/module/license/index.d.ts.map +0 -1
  962. package/lib/typescript/module/license/licenseModule.d.ts.map +0 -1
  963. package/lib/typescript/module/license/openPricing.d.ts.map +0 -1
  964. package/lib/typescript/module/license/tierLimits.d.ts.map +0 -1
  965. package/lib/typescript/module/logger/index-sentry.d.ts.map +0 -1
  966. package/lib/typescript/module/logger/index.d.ts.map +0 -1
  967. package/lib/typescript/module/logger/logDump.d.ts.map +0 -1
  968. package/lib/typescript/module/logger/types.d.ts.map +0 -1
  969. package/lib/typescript/module/settings/components/BubbleSettingsSection.d.ts.map +0 -1
  970. package/lib/typescript/module/settings/index.d.ts.map +0 -1
  971. package/lib/typescript/module/storage/definePersistedSetting.d.ts.map +0 -1
  972. package/lib/typescript/module/storage/devToolsStorageKeys.d.ts.map +0 -1
  973. package/lib/typescript/module/storage/index.d.ts.map +0 -1
  974. package/lib/typescript/module/stores/BaseEventStore.d.ts.map +0 -1
  975. package/lib/typescript/module/stores/ChangeLog.d.ts.map +0 -1
  976. package/lib/typescript/module/stores/createToolStore.d.ts.map +0 -1
  977. package/lib/typescript/module/stores/floatingToolStore.d.ts.map +0 -1
  978. package/lib/typescript/module/stores/floatingToolStore.test.d.ts.map +0 -1
  979. package/lib/typescript/module/stores/ignoredPatternsCore.d.ts.map +0 -1
  980. package/lib/typescript/module/stores/ignoredPatternsStore.d.ts.map +0 -1
  981. package/lib/typescript/module/stores/ignoredPatternsStore.web.d.ts.map +0 -1
  982. package/lib/typescript/module/stores/index.d.ts.map +0 -1
  983. package/lib/typescript/module/sync/keyedArrays.d.ts.map +0 -1
  984. package/lib/typescript/module/sync/toolActionRegistry.d.ts.map +0 -1
  985. package/lib/typescript/module/sync/toolAttention.test.d.ts.map +0 -1
  986. package/lib/typescript/module/sync/toolSyncAdapter.d.ts.map +0 -1
  987. package/lib/typescript/module/sync/toolUiBridge.d.ts.map +0 -1
  988. package/lib/typescript/module/sync/typedEdit.d.ts.map +0 -1
  989. package/lib/typescript/module/sync/valuePath.d.ts.map +0 -1
  990. package/lib/typescript/module/sync/valueShape.d.ts.map +0 -1
  991. package/lib/typescript/module/sync/wireBudget.d.ts.map +0 -1
  992. package/lib/typescript/module/sync/wireForm.d.ts.map +0 -1
  993. package/lib/typescript/module/tools/defineTool.d.ts.map +0 -1
  994. package/lib/typescript/module/types/types.d.ts.map +0 -1
  995. package/lib/typescript/module/ui/backgrounds/BackgroundSwitcher.d.ts.map +0 -1
  996. package/lib/typescript/module/ui/backgrounds/ToolBackground.d.ts.map +0 -1
  997. package/lib/typescript/module/ui/backgrounds/backgroundStore.d.ts.map +0 -1
  998. package/lib/typescript/module/ui/backgrounds/index.d.ts.map +0 -1
  999. package/lib/typescript/module/ui/backgrounds/primitives.d.ts.map +0 -1
  1000. package/lib/typescript/module/ui/backgrounds/registry.d.ts.map +0 -1
  1001. package/lib/typescript/module/ui/backgrounds/rng.d.ts.map +0 -1
  1002. package/lib/typescript/module/ui/backgrounds/skyClock.d.ts.map +0 -1
  1003. package/lib/typescript/module/ui/backgrounds/types.d.ts.map +0 -1
  1004. package/lib/typescript/module/ui/backgrounds/variants/daylight.d.ts.map +0 -1
  1005. package/lib/typescript/module/ui/backgrounds/variants/deepField.d.ts.map +0 -1
  1006. package/lib/typescript/module/ui/backgrounds/variants/hyperspace.d.ts.map +0 -1
  1007. package/lib/typescript/module/ui/backgrounds/variants/liveSky.d.ts.map +0 -1
  1008. package/lib/typescript/module/ui/backgrounds/variants/meteors.d.ts.map +0 -1
  1009. package/lib/typescript/module/ui/backgrounds/variants/moonlight.d.ts.map +0 -1
  1010. package/lib/typescript/module/ui/backgrounds/variants/underwater.d.ts.map +0 -1
  1011. package/lib/typescript/module/ui/backgrounds/variants/wormhole/motion.d.ts.map +0 -1
  1012. package/lib/typescript/module/ui/backgrounds/variants/wormhole/textures.d.ts.map +0 -1
  1013. package/lib/typescript/module/ui/backgrounds/variants/wormhole.d.ts.map +0 -1
  1014. package/lib/typescript/module/ui/components/BackButton.d.ts.map +0 -1
  1015. package/lib/typescript/module/ui/components/Badge.d.ts.map +0 -1
  1016. package/lib/typescript/module/ui/components/ChangeRow.d.ts.map +0 -1
  1017. package/lib/typescript/module/ui/components/ChipStrip.d.ts.map +0 -1
  1018. package/lib/typescript/module/ui/components/ClipboardHintBanner.d.ts.map +0 -1
  1019. package/lib/typescript/module/ui/components/CollapsibleSection.d.ts.map +0 -1
  1020. package/lib/typescript/module/ui/components/CompactFilterChips.d.ts.map +0 -1
  1021. package/lib/typescript/module/ui/components/CompactRow.d.ts.map +0 -1
  1022. package/lib/typescript/module/ui/components/CopyButton.d.ts.map +0 -1
  1023. package/lib/typescript/module/ui/components/DataInspector.d.ts.map +0 -1
  1024. package/lib/typescript/module/ui/components/DetailView.d.ts.map +0 -1
  1025. package/lib/typescript/module/ui/components/DetailViewToggle.d.ts.map +0 -1
  1026. package/lib/typescript/module/ui/components/DevToolsCard.d.ts.map +0 -1
  1027. package/lib/typescript/module/ui/components/DraggableHeader.d.ts.map +0 -1
  1028. package/lib/typescript/module/ui/components/DynamicFilterView.d.ts.map +0 -1
  1029. package/lib/typescript/module/ui/components/EmptyState.d.ts.map +0 -1
  1030. package/lib/typescript/module/ui/components/EntityFilterView.d.ts.map +0 -1
  1031. package/lib/typescript/module/ui/components/EventHistoryViewer/CompareBar.d.ts.map +0 -1
  1032. package/lib/typescript/module/ui/components/EventHistoryViewer/DiffModeTabs.d.ts.map +0 -1
  1033. package/lib/typescript/module/ui/components/EventHistoryViewer/EventHistoryViewer.d.ts.map +0 -1
  1034. package/lib/typescript/module/ui/components/EventHistoryViewer/EventPickerModal.d.ts.map +0 -1
  1035. package/lib/typescript/module/ui/components/EventHistoryViewer/ViewToggleCards.d.ts.map +0 -1
  1036. package/lib/typescript/module/ui/components/EventHistoryViewer/index.d.ts.map +0 -1
  1037. package/lib/typescript/module/ui/components/EventHistoryViewer/types.d.ts.map +0 -1
  1038. package/lib/typescript/module/ui/components/EventListItem.d.ts.map +0 -1
  1039. package/lib/typescript/module/ui/components/EventStepperFooter.d.ts.map +0 -1
  1040. package/lib/typescript/module/ui/components/ExpandablePopover.d.ts.map +0 -1
  1041. package/lib/typescript/module/ui/components/ExpandedInfoRow.d.ts.map +0 -1
  1042. package/lib/typescript/module/ui/components/ExportPreview.d.ts.map +0 -1
  1043. package/lib/typescript/module/ui/components/FilterComponents.d.ts.map +0 -1
  1044. package/lib/typescript/module/ui/components/GripVerticalIcon.d.ts.map +0 -1
  1045. package/lib/typescript/module/ui/components/HeaderSearchButton.d.ts.map +0 -1
  1046. package/lib/typescript/module/ui/components/InfoRow.d.ts.map +0 -1
  1047. package/lib/typescript/module/ui/components/ListItem.d.ts.map +0 -1
  1048. package/lib/typescript/module/ui/components/ModalHeader.d.ts.map +0 -1
  1049. package/lib/typescript/module/ui/components/ModalHintBanner.d.ts.map +0 -1
  1050. package/lib/typescript/module/ui/components/Pill.d.ts.map +0 -1
  1051. package/lib/typescript/module/ui/components/PowerToggleButton.d.ts.map +0 -1
  1052. package/lib/typescript/module/ui/components/SearchBar.d.ts.map +0 -1
  1053. package/lib/typescript/module/ui/components/SectionHeader.d.ts.map +0 -1
  1054. package/lib/typescript/module/ui/components/StatsCard.d.ts.map +0 -1
  1055. package/lib/typescript/module/ui/components/StatusIndicator.d.ts.map +0 -1
  1056. package/lib/typescript/module/ui/components/StorageTypeBadge.d.ts.map +0 -1
  1057. package/lib/typescript/module/ui/components/TabSelector.d.ts.map +0 -1
  1058. package/lib/typescript/module/ui/components/TimeDisplay.d.ts.map +0 -1
  1059. package/lib/typescript/module/ui/components/ToggleRow.d.ts.map +0 -1
  1060. package/lib/typescript/module/ui/components/ToolButton.d.ts.map +0 -1
  1061. package/lib/typescript/module/ui/components/ToolEmptyState.d.ts.map +0 -1
  1062. package/lib/typescript/module/ui/components/ToolFooter.d.ts.map +0 -1
  1063. package/lib/typescript/module/ui/components/ValueTypeBadge.d.ts.map +0 -1
  1064. package/lib/typescript/module/ui/components/WindowControls.d.ts.map +0 -1
  1065. package/lib/typescript/module/ui/components/index.d.ts.map +0 -1
  1066. package/lib/typescript/module/ui/components/windowDrag.d.ts.map +0 -1
  1067. package/lib/typescript/module/ui/console/CyberpunkButtonOutline.d.ts.map +0 -1
  1068. package/lib/typescript/module/ui/console/CyberpunkIconContainer.d.ts.map +0 -1
  1069. package/lib/typescript/module/ui/console/CyberpunkSectionButton.d.ts.map +0 -1
  1070. package/lib/typescript/module/ui/floating/FloatingTool.d.ts.map +0 -1
  1071. package/lib/typescript/module/ui/floating/FloatingTool.web.d.ts.map +0 -1
  1072. package/lib/typescript/module/ui/floating/FloatingToolHost.d.ts.map +0 -1
  1073. package/lib/typescript/module/ui/floating/FloatingToolHost.web.d.ts.map +0 -1
  1074. package/lib/typescript/module/ui/floating/index.d.ts.map +0 -1
  1075. package/lib/typescript/module/ui/floating/index.web.d.ts.map +0 -1
  1076. package/lib/typescript/module/ui/floating/onboardingConstants.d.ts.map +0 -1
  1077. package/lib/typescript/module/ui/floating/onboardingConstants.web.d.ts.map +0 -1
  1078. package/lib/typescript/module/ui/fonts.d.ts.map +0 -1
  1079. package/lib/typescript/module/ui/gameUI/components/GameUICollapsibleSection.d.ts.map +0 -1
  1080. package/lib/typescript/module/ui/gameUI/components/GameUICompactStats.d.ts.map +0 -1
  1081. package/lib/typescript/module/ui/gameUI/components/GameUIIssuesList.d.ts.map +0 -1
  1082. package/lib/typescript/module/ui/gameUI/components/GameUIStatusHeader.d.ts.map +0 -1
  1083. package/lib/typescript/module/ui/gameUI/constants/gameUIColors.d.ts.map +0 -1
  1084. package/lib/typescript/module/ui/gameUI/constants/macOSDesignSystemColors.d.ts.map +0 -1
  1085. package/lib/typescript/module/ui/gameUI/hooks/useGameUIAlertState.d.ts.map +0 -1
  1086. package/lib/typescript/module/ui/gameUI/index.d.ts.map +0 -1
  1087. package/lib/typescript/module/ui/index.d.ts.map +0 -1
  1088. package/lib/typescript/module/ui/listPresets.d.ts.map +0 -1
  1089. package/lib/typescript/module/ui/night/nightTheme.d.ts.map +0 -1
  1090. package/lib/typescript/module/ui/night/primitives.d.ts.map +0 -1
  1091. package/lib/typescript/module/ui/otto/OttoSceneView.d.ts.map +0 -1
  1092. package/lib/typescript/module/ui/otto/OttoSprite.d.ts.map +0 -1
  1093. package/lib/typescript/module/ui/otto/index.d.ts.map +0 -1
  1094. package/lib/typescript/module/ui/otto/ottoEngine.d.ts.map +0 -1
  1095. package/lib/typescript/module/ui/otto/ottoScenes.d.ts.map +0 -1
  1096. package/lib/typescript/module/ui/otto/ottoSheet.d.ts.map +0 -1
  1097. package/lib/typescript/module/ui/toolTheme.d.ts.map +0 -1
  1098. package/lib/typescript/module/utils/absoluteFill.d.ts.map +0 -1
  1099. package/lib/typescript/module/utils/devServer.d.ts.map +0 -1
  1100. package/lib/typescript/module/utils/displayValue.d.ts.map +0 -1
  1101. package/lib/typescript/module/utils/formatting/dataFormatting.d.ts.map +0 -1
  1102. package/lib/typescript/module/utils/formatting/httpFormatting.d.ts.map +0 -1
  1103. package/lib/typescript/module/utils/formatting/index.d.ts.map +0 -1
  1104. package/lib/typescript/module/utils/getSafeAreaInsets.d.ts.map +0 -1
  1105. package/lib/typescript/module/utils/index.d.ts.map +0 -1
  1106. package/lib/typescript/module/utils/loadOptionalModule.d.ts.map +0 -1
  1107. package/lib/typescript/module/utils/minimalSuperJSON.d.ts.map +0 -1
  1108. package/lib/typescript/module/utils/persistentStorage.d.ts.map +0 -1
  1109. package/lib/typescript/module/utils/reloadApp.d.ts.map +0 -1
  1110. package/lib/typescript/module/utils/renderCaptureRegistry.d.ts.map +0 -1
  1111. package/lib/typescript/module/utils/safeExpoRouter.d.ts.map +0 -1
  1112. package/lib/typescript/module/utils/safeStringify.d.ts.map +0 -1
  1113. package/lib/typescript/module/utils/snapshotProviderKit.d.ts.map +0 -1
  1114. package/lib/typescript/module/utils/stateSnapshotRegistry.d.ts.map +0 -1
  1115. package/lib/typescript/module/utils/stateTools.d.ts.map +0 -1
  1116. package/lib/typescript/module/utils/subscribable.d.ts.map +0 -1
  1117. package/lib/typescript/module/utils/subscriberCountNotifier.d.ts.map +0 -1
  1118. package/lib/typescript/module/utils/time/RelativeTime.d.ts.map +0 -1
  1119. package/lib/typescript/module/utils/time/TickContext.d.ts.map +0 -1
  1120. package/lib/typescript/module/utils/time/formatRelativeTime.d.ts.map +0 -1
  1121. package/lib/typescript/module/utils/time/index.d.ts.map +0 -1
  1122. package/lib/typescript/module/utils/time/useRelativeTime.d.ts.map +0 -1
  1123. package/lib/typescript/module/utils/typeHelpers.d.ts.map +0 -1
  1124. package/lib/typescript/module/utils/valueFormatting.d.ts.map +0 -1
  1125. package/scripts/generate-wormhole-textures.cjs +0 -261
  1126. package/scripts/test-wormhole-motion.cjs +0 -59
@@ -1,2737 +1 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.OTTO_USES = exports.OTTO_STATE_NAMES = exports.OTTO_STATES = exports.OTTO_REEL = exports.OTTO_PALETTE = exports.OTTO_NOTES = exports.OTTO_GROUPS = exports.OTTO_GRID = exports.OTTO_ANCHOR_SIZE = exports.OTTO_ANCHORS = void 0;
7
- exports.ottoReel = ottoReel;
8
- exports.ottoRuns = ottoRuns;
9
- exports.ottoWaterRows = ottoWaterRows;
10
- exports.renderOttoFrame = renderOttoFrame;
11
- /**
12
- * Otto — Buoy's pixel mascot, ported 1:1 from the Claude Design mockup
13
- * (`Otto.dc.html`, "Turn 6 — Otto, full state set").
14
- *
15
- * Everything here is pure: a pose is a parametric description (body rect,
16
- * lamp, eyes, legs, prop extras) baked onto a 16×16 grid, composed with a
17
- * keyline and water, then painted from the palette. No React, no timers —
18
- * `renderOttoFrame(state, t)` is the whole API, so it can be lifted into a
19
- * package unchanged. `OttoSprite.tsx` is the React Native renderer.
20
- */
21
-
22
- const OTTO_GRID = exports.OTTO_GRID = 16;
23
-
24
- /** Palette keys → colours. `.` is transparent. */
25
- const OTTO_PALETTE = exports.OTTO_PALETTE = {
26
- g: "#20C997",
27
- // body
28
- s: "#1BAB80",
29
- // body shade
30
- d: "#0D9668",
31
- // body deep (lamp base)
32
- h: "#3DD9A8",
33
- // body highlight (top row)
34
- k: "#000000",
35
- // keyline / eyes
36
- a: "#FFA94D",
37
- // lamp lit
38
- A: "#6B4520",
39
- // lamp dim
40
- r: "#FF3B30",
41
- // danger
42
- R: "#5A1712",
43
- // danger dim
44
- p: "#9B70E0",
45
- // purple props
46
- w: "#0A1A16",
47
- // water
48
- W: "#0F2A22",
49
- // water crest
50
- n: "#9BA1A6",
51
- // prop light grey
52
- m: "#636366",
53
- // prop mid grey
54
- l: "#ECEDEE",
55
- // prop white
56
- "1": "#2A2A2E" // prop dark
57
- };
58
-
59
- /** [x, y, paletteKey] */
60
-
61
- const BASE = {
62
- x0: 3,
63
- y0: 4,
64
- w: 10,
65
- h: 7,
66
- eyes: "open",
67
- lamp: "a",
68
- legs: [0, 0, 0]
69
- };
70
-
71
- /**
72
- * A keyboard, rows 10–12 from x=3: light top edge, a row of white key caps
73
- * on grey, grey base. Three rows, so the body stays readable at 16px — a
74
- * laptop screen at this size is a dark blob. See `typing`.
75
- */
76
- const TYPING_KEYBOARD = ["nnnnnnnnnn", "lmlmlmlmlm", "mmmmmmmmmm"];
77
-
78
- // Keys that count as "body" for the keyline pass. Props (n/m/l/p/1) get none.
79
- const BODY_KEYS = "gsdhaArRk";
80
- function walk(t) {
81
- return t % 2 ? [0, 1, 0] : [1, 0, 1];
82
- }
83
- function rect(x0, y0, x1, y1, c, out) {
84
- for (let y = y0; y <= y1; y++) for (let x = x0; x <= x1; x++) out.push([x, y, c]);
85
- return out;
86
- }
87
- function pt([x, y], c) {
88
- return [x, y, c];
89
- }
90
-
91
- /** A 4×5 loop at the top right, clockwise from the top left — spinners orbit it. */
92
- const RING = [[13, 0], [14, 0], [15, 1], [15, 2], [15, 3], [14, 4], [13, 4], [12, 3], [12, 2], [12, 1]];
93
-
94
- /** A 3-wide arrow pointing down, tip at `y + 3`; parts above row 0 are clipped. */
95
- function arrowDown(x, y, c, out) {
96
- out.push([x, y, c], [x, y + 1, c], [x - 1, y + 2, c], [x, y + 2, c], [x + 1, y + 2, c], [x, y + 3, c]);
97
- return out;
98
- }
99
-
100
- /** A 3-wide arrow pointing up, tip at `y`. */
101
- function arrowUp(x, y, c, out) {
102
- out.push([x, y, c], [x - 1, y + 1, c], [x, y + 1, c], [x + 1, y + 1, c], [x, y + 2, c], [x, y + 3, c]);
103
- return out;
104
- }
105
-
106
- /** Morse S-O-S, one tick per unit: dot 1, dash 3, gaps 1/2, word pause 6. */
107
- const SOS = [1, 0, 1, 0, 1, 0, 0, 0, 1, 1, 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0];
108
-
109
- /** A padlock at the right edge (x 13–15): orange body, grey shackle, keyhole. */
110
- function padlock(open, out) {
111
- rect(13, 4, 15, 6, "a", out);
112
- out.push([14, 5, "k"], [14, 6, "k"]);
113
- if (open) out.push([13, 1, "n"], [14, 1, "n"], [15, 1, "n"], [13, 2, "n"], [13, 3, "n"]);else out.push([13, 2, "n"], [14, 2, "n"], [15, 2, "n"], [13, 3, "n"], [15, 3, "n"]);
114
- return out;
115
- }
116
-
117
- /** Bake a pose onto the grid as palette keys (`.` = empty). */
118
- function draw(p) {
119
- const W = OTTO_GRID;
120
- const H = OTTO_GRID;
121
- const g = Array.from({
122
- length: H
123
- }, () => Array(W).fill("."));
124
- const dx = p.dx || 0;
125
- const put = (x, y, c) => {
126
- x += dx;
127
- if (x >= 0 && x < W && y >= 0 && y < H) g[y][x] = c;
128
- };
129
- const {
130
- x0,
131
- y0,
132
- w,
133
- h
134
- } = p;
135
- const x1 = x0 + w - 1;
136
- const y1 = y0 + h - 1;
137
- for (let y = y0; y <= y1; y++) {
138
- for (let x = x0; x <= x1; x++) {
139
- if ((x === x0 || x === x1) && (y === y0 || y === y1)) continue;
140
- put(x, y, y === y0 ? "h" : y === y1 || x === x1 ? "s" : "g");
141
- }
142
- }
143
- if (p.lamp) {
144
- const cx = x0 + Math.floor(w / 2) - 1;
145
- put(cx, y0 - 2, p.lamp);
146
- put(cx + 1, y0 - 2, p.lamp);
147
- for (let x = cx - 1; x <= cx + 2; x++) put(x, y0 - 1, "d");
148
- }
149
- const ex = p.ex || 0;
150
- const ey = y0 + 2 + (p.ey || 0);
151
- for (const e of [x0 + 2 + ex, x1 - 3 + ex]) {
152
- if (p.eyes === "open") {
153
- put(e, ey, "k");
154
- put(e + 1, ey, "k");
155
- put(e, ey + 1, "k");
156
- put(e + 1, ey + 1, "k");
157
- } else if (p.eyes === "closed") {
158
- put(e, ey + 1, "k");
159
- put(e + 1, ey + 1, "k");
160
- } else if (p.eyes === "happy") {
161
- put(e, ey + 1, "k");
162
- put(e + 1, ey, "k");
163
- put(e + 2, ey + 1, "k");
164
- } else if (p.eyes === "x") {
165
- put(e, ey, "k");
166
- put(e + 2, ey, "k");
167
- put(e + 1, ey + 1, "k");
168
- put(e, ey + 2, "k");
169
- put(e + 2, ey + 2, "k");
170
- } else if (p.eyes === "big") {
171
- for (let yy = 0; yy < 3; yy++) for (let xx = 0; xx < 3; xx++) put(e + xx, ey + yy, "k");
172
- }
173
- }
174
- if (p.legs) {
175
- const start = x0 + Math.floor((w - 8) / 2);
176
- p.legs.forEach((o, i) => {
177
- const lx = start + i * 3;
178
- put(lx, y1 + 1, o ? "s" : "g");
179
- put(lx + 1, y1 + 1, o ? "s" : "g");
180
- if (!o) {
181
- put(lx, y1 + 2, "s");
182
- put(lx + 1, y1 + 2, "s");
183
- }
184
- });
185
- }
186
- (p.extras || []).forEach(([x, y, c]) => put(x, y, c));
187
- return g;
188
- }
189
- function wave(x, y, t) {
190
- return ((x - Math.floor(t / 2) + y * 5) % 7 + 7) % 7 < 2 ? "W" : "w";
191
- }
192
-
193
- /** The water on its own: rows 13–15 as palette keys at tick `t`. Period 7 in floor(t/2). */
194
- function ottoWaterRows(t) {
195
- const rows = [];
196
- for (let y = 13; y < OTTO_GRID; y++) {
197
- const row = [];
198
- for (let x = 0; x < OTTO_GRID; x++) row.push(wave(x, y, t));
199
- rows.push(row);
200
- }
201
- return rows;
202
- }
203
- const NEIGHBOURS = [[0, 1], [0, -1], [1, 0], [-1, 0]];
204
- /** Keyline around the body, water in the bottom three rows. */
205
- function compose(g, t, o) {
206
- const W = OTTO_GRID;
207
- const H = OTTO_GRID;
208
- const out = g.map(r => r.slice());
209
- for (let y = 0; y < H; y++) {
210
- for (let x = 0; x < W; x++) {
211
- const under = y >= 13;
212
- if (under && o.submerged) {
213
- out[y][x] = o.water ? wave(x, y, t) : ".";
214
- continue;
215
- }
216
- if (g[y][x] !== ".") continue;
217
- const nb = o.keyline && NEIGHBOURS.some(([dy, ddx]) => {
218
- const yy = y + dy;
219
- const xx = x + ddx;
220
- return yy >= 0 && yy < H && xx >= 0 && xx < W && BODY_KEYS.includes(g[yy][xx]);
221
- });
222
- if (nb) out[y][x] = "k";else if (under && o.water) out[y][x] = wave(x, y, t);
223
- }
224
- }
225
- return out;
226
- }
227
- const OTTO_STATES = exports.OTTO_STATES = {
228
- idle: t => {
229
- const c = t % 48;
230
- const bob = c % 8 >= 4 ? 1 : 0;
231
- const blink = c % 16 === 13 || c === 47;
232
- const ex = c >= 20 && c <= 26 ? -1 : c >= 32 && c <= 38 ? 1 : 0;
233
- return {
234
- ...BASE,
235
- y0: 4 + bob,
236
- eyes: blink ? "closed" : "open",
237
- ex,
238
- legs: walk(Math.floor(t / 2))
239
- };
240
- },
241
- thinking: t => {
242
- const c = t % 10;
243
- const e = [];
244
- if (c >= 1) e.push([13, 5, "n"]);
245
- if (c >= 2) e.push([14, 3, "n"]);
246
- if (c >= 3) {
247
- rect(11, 0, 14, 0, "l", e);
248
- rect(10, 1, 15, 1, "l", e);
249
- rect(11, 2, 14, 2, "l", e);
250
- }
251
- for (let i = 0; i < Math.min(3, Math.max(0, c - 4)); i++) e.push([11 + i * 2, 1, "m"]);
252
- return {
253
- ...BASE,
254
- ex: 1,
255
- ey: -1,
256
- lamp: t % 4 < 2 ? "a" : "A",
257
- extras: e
258
- };
259
- },
260
- happy: t => {
261
- const c = t % 12;
262
- const hop = [0, 1, 2, 2, 1, 0, 0, 0, 0, 0, 0, 0][c];
263
- let p = {
264
- ...BASE,
265
- eyes: "happy",
266
- legs: walk(t),
267
- y0: 4 - hop
268
- };
269
- if (c === 1) p = {
270
- ...p,
271
- x0: 4,
272
- w: 8,
273
- h: 8,
274
- y0: 2
275
- };
276
- if (c === 5 || c === 6) p = {
277
- ...p,
278
- x0: 2,
279
- w: 12,
280
- h: 6,
281
- y0: 5
282
- };
283
- return p;
284
- },
285
- error: t => ({
286
- ...BASE,
287
- lamp: t % 2 ? "r" : "R",
288
- dx: [0, 1, 0, -1][t % 4],
289
- eyes: "closed"
290
- }),
291
- sleep: t => {
292
- const ph = Math.floor(t / 3) % 4;
293
- const z = (x, y) => [[x, y], [x + 1, y], [x + 2, y], [x + 3, y], [x + 2, y + 1], [x + 1, y + 2], [x, y + 3], [x + 1, y + 3], [x + 2, y + 3], [x + 3, y + 3]].map(([a, b]) => [a, b, "n"]);
294
- return {
295
- ...BASE,
296
- y0: 5 + Math.floor(t / 8) % 2,
297
- eyes: "closed",
298
- lamp: "A",
299
- extras: z(12, 6 - ph * 2)
300
- };
301
- },
302
- peek: t => ({
303
- ...BASE,
304
- submerged: true,
305
- y0: 9 + Math.floor(t / 4) % 2,
306
- ex: [-1, 0, 1, 0][Math.floor(t / 6) % 4],
307
- legs: null
308
- }),
309
- typing: t => {
310
- const e = [];
311
- TYPING_KEYBOARD.forEach((row, dy) => {
312
- for (let dx = 0; dx < row.length; dx++) e.push([3 + dx, 10 + dy, row[dx]]);
313
- });
314
- const tap = t % 2;
315
- e.push([2, 10 + tap, "g"], [13, 11 - tap, "g"]);
316
- return {
317
- ...BASE,
318
- eyes: t % 12 === 11 ? "closed" : "open",
319
- legs: null,
320
- extras: e
321
- };
322
- },
323
- debugging: t => {
324
- const gx = Math.floor(t / 4) % 2 ? 0 : -1;
325
- const e = [];
326
- [[10, 3], [11, 3], [12, 3], [9, 4], [13, 4], [9, 5], [13, 5], [9, 6], [13, 6], [10, 7], [11, 7], [12, 7]].forEach(([x, y]) => e.push([x + gx, y, "n"]));
327
- rect(10 + gx, 4, 12 + gx, 4, "l", e);
328
- rect(10 + gx, 5, 12 + gx, 6, "k", e);
329
- e.push([14 + gx, 7, "m"], [15 + gx, 8, "m"]);
330
- return {
331
- ...BASE,
332
- extras: e
333
- };
334
- },
335
- building: t => {
336
- const e = [];
337
- rect(5, 1, 10, 1, "a", e);
338
- rect(4, 2, 11, 2, "a", e);
339
- rect(2, 3, 13, 3, "A", e);
340
- rect(13, 11, 15, 12, "m", e);
341
- if (t % 4 < 2) e.push([13, 6, "g"], [14, 5, "m"], [14, 4, "m"], [13, 2, "n"], [14, 2, "n"], [15, 2, "n"]);else e.push([13, 8, "g"], [14, 9, "m"], [15, 8, "n"], [15, 9, "n"], [15, 10, "n"], [12, 10, "a"]);
342
- return {
343
- ...BASE,
344
- lamp: null,
345
- eyes: t % 10 === 9 ? "closed" : "open",
346
- extras: e
347
- };
348
- },
349
- carrying: t => {
350
- const b = t % 4 < 2 ? 0 : 1;
351
- const e = [];
352
- rect(5, b, 10, b, "n", e);
353
- rect(5, 3 + b, 10, 3 + b, "n", e);
354
- rect(5, 1 + b, 5, 2 + b, "n", e);
355
- rect(10, 1 + b, 10, 2 + b, "n", e);
356
- rect(6, 1 + b, 9, 2 + b, "g", e);
357
- rect(4, 2 + b, 4, 3 + b, "g", e);
358
- rect(11, 2 + b, 11, 3 + b, "g", e);
359
- return {
360
- ...BASE,
361
- y0: 4 + b,
362
- lamp: null,
363
- ey: -1,
364
- legs: walk(t),
365
- extras: e
366
- };
367
- },
368
- pushing: t => {
369
- const e = [];
370
- for (let y = 5; y <= 12; y++) {
371
- for (let x = 11; x <= 15; x++) {
372
- e.push([x, y, y === 5 || y === 12 || x === 11 || x === 15 ? "n" : x === 13 ? "l" : "m"]);
373
- }
374
- }
375
- e.push([10, 7, "g"], [10, 8, "g"]);
376
- return {
377
- ...BASE,
378
- x0: 0,
379
- dx: t % 4 < 2 ? 0 : 1,
380
- ex: 1,
381
- legs: walk(t),
382
- extras: e
383
- };
384
- },
385
- sweeping: t => {
386
- const s = t % 4 < 2 ? 0 : 1;
387
- const e = [];
388
- rect(13, 3, 13, 10, "m", e);
389
- rect(12 + s, 11, 15 + s, 12, "a", e);
390
- e.push([13, 6, "g"]);
391
- if (s) e.push([15, 10, "m"], [11, 12, "m"]);
392
- return {
393
- ...BASE,
394
- ex: 1,
395
- eyes: t % 12 === 11 ? "closed" : "open",
396
- extras: e
397
- };
398
- },
399
- juggling: t => {
400
- const e = [];
401
- [[2, "r"], [7, "a"], [12, "p"]].forEach(([x, c], i) => {
402
- const h = [0, 1, 2, 2, 1, 0][(t + i * 2) % 6];
403
- const y = 2 - h;
404
- rect(x, y, x + 1, y + 1, c, e);
405
- });
406
- e.push([2, 4 + t % 2, "g"], [13, 5 - t % 2, "g"]);
407
- return {
408
- ...BASE,
409
- lamp: null,
410
- ey: -1,
411
- ex: [-1, 0, 1, 0][Math.floor(t / 2) % 4],
412
- extras: e
413
- };
414
- },
415
- wizard: t => {
416
- const e = [];
417
- rect(7, 0, 8, 0, "p", e);
418
- rect(6, 1, 9, 1, "p", e);
419
- rect(5, 2, 10, 2, "p", e);
420
- rect(3, 3, 12, 3, "p", e);
421
- e.push([8, 1, "a"]);
422
- e.push([13, 5, "g"], [14, 4, "m"], [15, 3, "m"]);
423
- const sp = t % 4;
424
- if (sp === 1) e.push([15, 1, "a"]);
425
- if (sp === 2) e.push([14, 1, "a"], [15, 0, "a"], [15, 2, "a"]);
426
- if (sp === 3) e.push([13, 0, "a"]);
427
- return {
428
- ...BASE,
429
- lamp: null,
430
- eyes: t % 12 === 11 ? "closed" : "open",
431
- extras: e
432
- };
433
- },
434
- conducting: t => {
435
- const u = t % 2;
436
- const n = Math.floor(t / 2) % 4;
437
- const e = [[1, 4 + u * 3, "g"], [2, 4 + u * 3, "g"], [13, 7 - u * 3, "g"], [14, 7 - u * 3, "g"], [15, 6 - u * 3, "m"], [2, 3 - n, "n"], [3, 2 - n, "n"]];
438
- return {
439
- ...BASE,
440
- eyes: "happy",
441
- extras: e
442
- };
443
- },
444
- beacon: t => {
445
- const f = t % 6;
446
- const rings = [[], [[5, 3], [10, 3], [5, 2], [10, 2]], [[3, 3], [12, 3], [3, 2], [12, 2], [4, 1], [11, 1], [5, 0], [10, 0]], [[1, 2], [14, 2], [1, 1], [14, 1], [2, 0], [13, 0]], [], []];
447
- return {
448
- ...BASE,
449
- lamp: f < 4 ? "a" : "A",
450
- ey: -1,
451
- extras: rings[f].map(([x, y]) => [x, y, "a"])
452
- };
453
- },
454
- notification: t => {
455
- const c = t % 16;
456
- const hop = [0, 0, 0, 0, 1, 2, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0][c];
457
- const show = c >= 3 && c <= 10;
458
- const e = show ? [...rect(14, 0, 15, 2, "a", []), [14, 4, "a"], [15, 4, "a"]] : [];
459
- return {
460
- ...BASE,
461
- y0: 4 - hop,
462
- lamp: show && c % 2 ? "A" : "a",
463
- legs: hop ? [1, 1, 1] : [0, 0, 0],
464
- extras: e
465
- };
466
- },
467
- disconnected: t => {
468
- const on = t % 4 < 2;
469
- const e = [];
470
- for (let y = 0; y <= 4; y++) {
471
- e.push([12, y, "n"], [14, y, "n"], [13, y, y === 0 || y === 4 ? "n" : on ? "r" : "1"]);
472
- }
473
- return {
474
- ...BASE,
475
- y0: 5,
476
- lamp: "A",
477
- ex: 1,
478
- ey: -1,
479
- extras: e
480
- };
481
- },
482
- dizzy: t => {
483
- const pos = [[1, 2], [4, 0], [11, 0], [14, 2]];
484
- const s = [pos[t % 4], pos[(t + 2) % 4]].map(([x, y]) => [x, y, "a"]);
485
- return {
486
- ...BASE,
487
- eyes: "x",
488
- lamp: "A",
489
- dx: [0, 1, 0, -1][t % 4],
490
- extras: s
491
- };
492
- },
493
- overheated: t => {
494
- const k = [0, 0, 0, 1, 2, 3, 3, 3, 3, 2, 1, 0][t % 12];
495
- const shapes = [{
496
- x0: 3,
497
- y0: 4,
498
- w: 10,
499
- h: 7,
500
- ey: 0,
501
- legs: [0, 0, 0]
502
- }, {
503
- x0: 3,
504
- y0: 6,
505
- w: 10,
506
- h: 5,
507
- ey: 0,
508
- legs: [0, 0, 0]
509
- }, {
510
- x0: 2,
511
- y0: 8,
512
- w: 12,
513
- h: 3,
514
- ey: -1,
515
- legs: null
516
- }, {
517
- x0: 1,
518
- y0: 10,
519
- w: 14,
520
- h: 2,
521
- ey: -2,
522
- legs: null
523
- }];
524
- return {
525
- ...BASE,
526
- ...shapes[k],
527
- eyes: k >= 2 ? "closed" : "open",
528
- lamp: k >= 2 ? "A" : t % 2 ? "a" : "A",
529
- extras: k >= 1 ? [[14, 2 + t % 3, "l"]] : []
530
- };
531
- },
532
- confused: t => {
533
- const c = t % 18;
534
- const e = c >= 4 ? [[12, 0, "n"], [13, 0, "n"], [14, 0, "n"], [14, 1, "n"], [13, 2, "n"], [14, 2, "n"], [13, 4, "n"]] : [];
535
- return {
536
- ...BASE,
537
- ex: [1, 1, 0, -1, -1, 0][Math.floor(c / 3) % 6],
538
- ey: -1,
539
- dx: c >= 9 ? -1 : 0,
540
- extras: e
541
- };
542
- },
543
- stare: t => ({
544
- ...BASE,
545
- eyes: t % 20 === 19 ? "closed" : "big",
546
- ex: [0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, -1, -1, 0, 0, 0, 0, 0, 0][t % 20]
547
- }),
548
- walking: t => {
549
- const c = t % 16;
550
- const pos = c < 8 ? c - 4 : 11 - c;
551
- return {
552
- ...BASE,
553
- dx: pos,
554
- ex: c < 8 ? 1 : -1,
555
- legs: walk(t)
556
- };
557
- },
558
- goingaway: t => ({
559
- ...BASE,
560
- dx: t % 26 - 6,
561
- ex: 1,
562
- legs: walk(t)
563
- }),
564
- eureka: t => {
565
- const c = t % 24;
566
- const e = [];
567
- if (c >= 3 && c < 20) {
568
- const on = c >= 6;
569
- rect(12, 0, 13, 0, on ? "a" : "A", e);
570
- rect(11, 1, 14, 2, on ? "a" : "A", e);
571
- rect(12, 3, 13, 3, "m", e);
572
- rect(12, 4, 13, 4, "n", e);
573
- if (on) e.push([12, 1, "l"]);
574
- if (on && c < 14 && c % 2 === 0) e.push([10, 0, "l"], [15, 0, "l"], [10, 4, "l"], [15, 4, "l"]);
575
- e.push([13, 6, "g"], [14, 5, "g"]);
576
- }
577
- return {
578
- ...BASE,
579
- lamp: c >= 6 && c < 20 ? "a" : "A",
580
- eyes: c >= 8 && c < 20 ? "happy" : c === 22 ? "closed" : "open",
581
- ex: c >= 3 && c < 8 ? 1 : 0,
582
- ey: c >= 3 && c < 8 ? -1 : 0,
583
- y0: c >= 8 && c < 20 && c % 4 < 2 ? 3 : 4,
584
- extras: e
585
- };
586
- },
587
- grooving: t => {
588
- const b = t % 4;
589
- const lean = [0, 1, 0, -1][b];
590
- const e = [];
591
- rect(4, 1, 11, 1, "p", e);
592
- rect(3, 2, 3, 3, "p", e);
593
- rect(12, 2, 12, 3, "p", e);
594
- rect(1, 6, 2, 8, "p", e);
595
- rect(13, 6, 14, 8, "p", e);
596
- e.push([2, 7, "1"], [13, 7, "1"]);
597
- if (b === 1) e.push([0, 3, "a"], [1, 2, "a"], [1, 3, "a"]);
598
- if (b === 3) e.push([15, 3, "a"], [14, 2, "a"], [14, 3, "a"]);
599
- return {
600
- ...BASE,
601
- lamp: null,
602
- dx: lean,
603
- eyes: "happy",
604
- legs: b % 2 ? [1, 0, 1] : [0, 1, 0],
605
- y0: b % 2 ? 4 : 5,
606
- extras: e
607
- };
608
- },
609
- hatmishap: t => {
610
- const c = t % 32;
611
- const e = [];
612
- const drop = c >= 10 && c < 20 ? 2 : c >= 20 && c < 22 ? 1 : 0;
613
- const ox = c >= 10 && c < 20 ? 1 : 0;
614
- const hy = drop;
615
- const hat = (x, y, col) => e.push([x + ox, y + hy, col]);
616
- hat(7, 0, "p");
617
- hat(8, 0, "p");
618
- for (let x = 6; x <= 9; x++) hat(x, 1, "p");
619
- for (let x = 5; x <= 10; x++) hat(x, 2, "p");
620
- for (let x = 3; x <= 12; x++) hat(x, 3, "p");
621
- hat(8, 1, "a");
622
- hat(6, 2, "a");
623
- hat(10, 3, "a");
624
- if (drop === 2) for (let x = 4; x <= 11; x++) hat(x, 4, "p");
625
- if (c >= 14 && c < 22) {
626
- e.push([13, 5, "g"], [14, 4, "g"], [14, 3, "g"]);
627
- if (c % 2) e.push([15, 1, "a"], [14, 0, "l"]);
628
- }
629
- return {
630
- ...BASE,
631
- lamp: null,
632
- eyes: drop === 2 ? "closed" : c >= 22 && c < 24 ? "happy" : "open",
633
- ex: c < 10 ? 1 : 0,
634
- legs: c < 8 ? walk(t) : [0, 0, 0],
635
- dx: c < 8 ? c < 4 ? c - 2 : 5 - c : 0,
636
- extras: e
637
- };
638
- },
639
- lowbattery: t => {
640
- const e = [];
641
- rect(12, 1, 15, 1, "r", e);
642
- rect(12, 6, 15, 6, "r", e);
643
- e.push([12, 2, "r"], [12, 3, "r"], [12, 4, "r"], [12, 5, "r"], [15, 2, "r"], [15, 3, "r"], [15, 4, "r"], [15, 5, "r"], [13, 0, "r"], [14, 0, "r"]);
644
- if (t % 6 < 3) rect(13, 5, 14, 5, "r", e);
645
- const open = t % 24 >= 18 && t % 24 < 21;
646
- return {
647
- ...BASE,
648
- y0: 6,
649
- h: 6,
650
- x0: 2,
651
- w: 12,
652
- lamp: "A",
653
- eyes: open ? "open" : "closed",
654
- ey: open ? 1 : 0,
655
- legs: null,
656
- extras: e
657
- };
658
- },
659
- wake: t => {
660
- const c = t % 30;
661
- if (c < 8) return {
662
- ...BASE,
663
- x0: 2,
664
- w: 12,
665
- y0: 7,
666
- h: 5,
667
- lamp: "A",
668
- eyes: c >= 6 ? "big" : "closed",
669
- ey: 0,
670
- legs: null
671
- };
672
- if (c < 10) return {
673
- ...BASE,
674
- x0: 4,
675
- w: 8,
676
- y0: 0,
677
- h: 9,
678
- lamp: null,
679
- eyes: "big",
680
- ey: 1,
681
- legs: [1, 1, 1]
682
- };
683
- if (c < 12) return {
684
- ...BASE,
685
- y0: 2,
686
- eyes: "big",
687
- lamp: "a",
688
- legs: [1, 1, 1]
689
- };
690
- if (c < 14) return {
691
- ...BASE,
692
- x0: 2,
693
- w: 12,
694
- y0: 5,
695
- h: 6,
696
- eyes: "open",
697
- lamp: "a"
698
- };
699
- return {
700
- ...BASE,
701
- eyes: c === 20 || c === 21 ? "closed" : "open",
702
- legs: [0, 0, 0]
703
- };
704
- },
705
- builder: t => {
706
- const s = [0, 1, 0, -1][Math.floor(t / 2) % 4];
707
- const e = [];
708
- rect(5, 2, 10, 3, "n", e);
709
- e.push([5, 3, "m"], [10, 3, "m"]);
710
- rect(4 + s, 0, 9 + s, 1, "p", e);
711
- e.push([4 + s, 1, "1"]);
712
- if (Math.floor(t / 2) % 4 === 3 && t % 2) e.push([1, 5, "l"], [0, 4, "l"]);
713
- const arms = s ? [[1, 5, "g"], [14, 7, "g"]] : [[1, 6, "g"], [14, 6, "g"]];
714
- return {
715
- ...BASE,
716
- lamp: null,
717
- ex: s,
718
- ey: -1,
719
- legs: walk(t),
720
- extras: [...e, ...arms]
721
- };
722
- },
723
- mini: t => {
724
- const c = t % 32;
725
- const ex = c < 8 ? 0 : c < 16 ? -1 : c < 24 ? 1 : 0;
726
- const ey = c >= 24 && c < 28 ? -1 : 0;
727
- return {
728
- ...BASE,
729
- x0: 4,
730
- w: 8,
731
- y0: 6 + Math.floor(t / 4) % 2,
732
- h: 5,
733
- lamp: "a",
734
- eyes: "big",
735
- ex,
736
- ey,
737
- legs: [Math.floor(t / 2) % 2, 0, (Math.floor(t / 2) + 1) % 2],
738
- extras: [[2, 8 + t % 2, "g"], [13, 8 + (t + 1) % 2, "g"]]
739
- };
740
- },
741
- minityping: t => {
742
- const e = [[2, 8 + t % 2, "g"], [13, 8 + (t + 1) % 2, "g"]];
743
- const dy = t % 6;
744
- e.push([7 + t % 3, 5 - dy, "p"]);
745
- return {
746
- ...BASE,
747
- x0: 4,
748
- w: 8,
749
- y0: 7 - t % 2,
750
- h: 5,
751
- lamp: null,
752
- legs: [0, 0, 0],
753
- extras: e
754
- };
755
- },
756
- happydance: t => {
757
- const c = t % 4;
758
- const e = [[1, 5 + [0, 1, 2, 1][c], "g"], [14, 5 + [2, 1, 0, 1][c], "g"]];
759
- return {
760
- ...BASE,
761
- eyes: c % 2 ? "happy" : "open",
762
- legs: c % 2 ? [1, 0, 1] : [0, 1, 0],
763
- extras: e
764
- };
765
- },
766
- jumping: t => {
767
- const c = t % 8;
768
- const y = [0, 1, -1, -3, -4, -2, 0, 0][c];
769
- const armY = [6, 7, 6, 4, 3, 4, 6, 6][c];
770
- return {
771
- ...BASE,
772
- y0: 4 + y,
773
- eyes: c === 1 ? "closed" : "open",
774
- legs: c >= 2 && c <= 5 ? [1, 1, 1] : [0, 0, 0],
775
- extras: [[1, armY + y, "g"], [14, armY + y, "g"]]
776
- };
777
- },
778
- // ── Loading & progress ──────────────────────────────────────────────────
779
- loading: t => {
780
- // Three dots chase around a ring at the top right; eyes follow the head.
781
- const e = [];
782
- const n = RING.length;
783
- const head = t % n;
784
- e.push(pt(RING[head], "l"), pt(RING[(head + n - 1) % n], "n"), pt(RING[(head + n - 2) % n], "m"));
785
- return {
786
- ...BASE,
787
- ex: 1,
788
- ey: -1,
789
- extras: e
790
- };
791
- },
792
- progress: t => {
793
- // A bar fills across the top, two ticks per pixel; a hop when it lands.
794
- const c = t % 32;
795
- const fill = Math.min(12, Math.floor(c / 2));
796
- const done = c >= 24;
797
- const e = [];
798
- // Lamp colours — a dim track that lights up — so the keyline wraps the whole bar.
799
- rect(2, 0, 13, 1, "A", e);
800
- if (fill > 0) rect(2, 0, 1 + fill, 1, "a", e);
801
- const hop = done && (c === 25 || c === 26) ? 1 : 0;
802
- return {
803
- ...BASE,
804
- y0: 4 - hop,
805
- eyes: done ? "happy" : "open",
806
- ex: done ? 0 : fill < 4 ? -1 : fill < 9 ? 0 : 1,
807
- ey: done ? 0 : -1,
808
- lamp: done && c % 2 ? "A" : "a",
809
- legs: hop ? [1, 1, 1] : [0, 0, 0],
810
- extras: e
811
- };
812
- },
813
- hourglass: t => {
814
- // Sand runs top to bottom, then the glass lifts and flips.
815
- const c = t % 20;
816
- const lift = c >= 16 ? -1 : 0;
817
- const e = [];
818
- const y = 3 + lift;
819
- rect(13, y, 15, y, "n", e);
820
- rect(13, y + 4, 15, y + 4, "n", e);
821
- e.push([13, y + 1, "n"], [15, y + 1, "n"], [14, y + 2, "n"], [13, y + 3, "n"], [15, y + 3, "n"]);
822
- const topFull = c < 8 || c >= 16;
823
- e.push([14, y + 1, topFull ? "a" : "1"], [14, y + 3, topFull ? "1" : "a"]);
824
- if (c >= 4 && c < 12 && c % 2) e.push([14, y + 2, "a"]);
825
- e.push([13, 8 + lift, "g"]);
826
- return {
827
- ...BASE,
828
- ex: 1,
829
- eyes: c === 17 ? "closed" : "open",
830
- extras: e
831
- };
832
- },
833
- waiting: t => {
834
- // Foot taps, checks the wristwatch, dots pile up.
835
- const c = t % 16;
836
- const e = [];
837
- // Wall clock, top left: a ring with one hand ticking round the face.
838
- e.push([1, 0, "n"], [2, 0, "n"], [0, 1, "n"], [3, 1, "n"], [0, 2, "n"], [3, 2, "n"], [1, 3, "n"], [2, 3, "n"]);
839
- rect(1, 1, 2, 2, "l", e);
840
- e.push(pt([[2, 1], [2, 2], [1, 2], [1, 1]][Math.floor(c / 2) % 4], "k"));
841
- const dots = Math.min(3, Math.floor(c / 4));
842
- for (let i = 0; i < dots; i++) e.push([13 + i, 1, "n"]);
843
- const look = c >= 6 && c < 11;
844
- return {
845
- ...BASE,
846
- ex: look ? -1 : 0,
847
- ey: look ? -1 : 0,
848
- legs: [0, 0, c % 2],
849
- extras: e
850
- };
851
- },
852
- syncing: t => {
853
- // Two arcs chase each other around the ring; the lamp pulses in step.
854
- const e = [];
855
- const n = RING.length;
856
- const p = t % n;
857
- for (const off of [0, 1, 2]) {
858
- e.push(pt(RING[(p + off) % n], off === 2 ? "l" : "n"));
859
- e.push(pt(RING[(p + off + 5) % n], off === 2 ? "l" : "n"));
860
- }
861
- return {
862
- ...BASE,
863
- ex: 1,
864
- ey: -1,
865
- lamp: t % 4 < 2 ? "a" : "A",
866
- extras: e
867
- };
868
- },
869
- downloading: t => {
870
- // An arrow drops into a tray; the parcel lands, then the tray clears.
871
- const c = t % 12;
872
- const e = [[13, 5, "n"], [15, 5, "n"], [13, 6, "n"], [14, 6, "n"], [15, 6, "n"]];
873
- if (c < 6) {
874
- const y = Math.floor(c / 2);
875
- arrowDown(14, y, "l", e);
876
- } else if (c === 6) {
877
- rect(13, 6, 15, 6, "l", e);
878
- } else if (c < 10) {
879
- e.push([14, 5, "a"]);
880
- }
881
- return {
882
- ...BASE,
883
- ex: 1,
884
- ey: c < 2 ? -1 : c < 6 ? 0 : 1,
885
- extras: e
886
- };
887
- },
888
- uploading: t => {
889
- // The parcel lifts off the tray and climbs out of frame.
890
- const c = t % 12;
891
- const e = [[13, 5, "n"], [15, 5, "n"], [13, 6, "n"], [14, 6, "n"], [15, 6, "n"]];
892
- if (c < 2) e.push([14, 5, "a"]);else if (c < 10) arrowUp(14, 2 - Math.floor((c - 2) / 2), "l", e);
893
- return {
894
- ...BASE,
895
- ex: 1,
896
- ey: c < 4 ? 1 : c < 8 ? 0 : -1,
897
- extras: e
898
- };
899
- },
900
- connecting: t => {
901
- // Signal bars fill one at a time, then all four blink: connected.
902
- const c = t % 14;
903
- const bars = c < 8 ? Math.floor(c / 2) : c % 2 ? 4 : 0;
904
- const e = [];
905
- for (let i = 0; i < 4; i++) {
906
- const x = 12 + i;
907
- const lit = i < bars;
908
- for (let y = 4 - i; y <= 4; y++) e.push([x, y, lit ? "g" : "1"]);
909
- }
910
- return {
911
- ...BASE,
912
- ex: 1,
913
- ey: -1,
914
- eyes: c >= 8 ? "happy" : "open",
915
- extras: e
916
- };
917
- },
918
- scanning: t => {
919
- // A bright line sweeps down the body with a faint trail.
920
- const c = t % 14;
921
- const e = [];
922
- if (c < 9) {
923
- const y = 4 + c;
924
- if (c > 0) rect(1, y - 1, 14, y - 1, "n", e);
925
- rect(1, y, 14, y, "l", e);
926
- }
927
- return {
928
- ...BASE,
929
- eyes: "big",
930
- legs: [0, 0, 0],
931
- extras: e
932
- };
933
- },
934
- searching: t => {
935
- // Binoculars up, slow sweep left and right.
936
- const e = [];
937
- for (const x of [4, 9]) {
938
- rect(x, 5, x + 2, 5, "n", e);
939
- rect(x, 7, x + 2, 7, "n", e);
940
- e.push([x, 6, "n"], [x + 2, 6, "n"], [x + 1, 6, "k"]);
941
- }
942
- e.push([7, 6, "n"], [8, 6, "n"]);
943
- const s = Math.floor(t / 3) % 4;
944
- const dx = [-1, 0, 1, 0][s];
945
- return {
946
- ...BASE,
947
- dx,
948
- legs: s % 2 ? walk(t) : [0, 0, 0],
949
- extras: e
950
- };
951
- },
952
- // ── Empty & nothing ─────────────────────────────────────────────────────
953
- empty: t => {
954
- // Peers into an open box, finds nothing, looks back at you.
955
- const c = t % 16;
956
- const e = [];
957
- rect(13, 7, 13, 10, "n", e);
958
- rect(15, 7, 15, 10, "n", e);
959
- rect(14, 10, 14, 10, "n", e);
960
- rect(14, 8, 14, 9, "1", e);
961
- const dots = c >= 9 ? Math.min(3, c - 8) : 0;
962
- for (let i = 0; i < dots; i++) e.push([12 + i, 1, "n"]);
963
- const peer = c < 8;
964
- return {
965
- ...BASE,
966
- ex: peer ? 1 : 0,
967
- ey: peer ? 1 : 0,
968
- eyes: c === 8 ? "closed" : "open",
969
- extras: e
970
- };
971
- },
972
- shrug: t => {
973
- // Arms up, looks left, looks right, arms down.
974
- const c = t % 16;
975
- const up = c >= 4 && c < 12;
976
- const e = up ? [[2, 5, "g"], [1, 4, "g"], [13, 5, "g"], [14, 4, "g"]] : [];
977
- return {
978
- ...BASE,
979
- ex: c < 4 ? 0 : c < 8 ? -1 : c < 12 ? 1 : 0,
980
- ey: up ? -1 : 0,
981
- extras: e
982
- };
983
- },
984
- fishing: t => {
985
- // Rod out, bobber bobbing; one tug, one splash, back to waiting.
986
- const c = t % 32;
987
- const e = [[13, 6, "g"], [14, 6, "g"], [14, 5, "m"], [15, 4, "m"]];
988
- const tug = c >= 20 && c < 24;
989
- const pop = c >= 24 && c < 27;
990
- const by = tug ? 14 : pop ? 11 : 12 + Math.floor(c / 4) % 2;
991
- rect(15, 5, 15, by - 1, "n", e);
992
- e.push([15, by, "r"], [15, by + 1, "l"]);
993
- if (pop) e.push([14, 12, "l"], [13, 13, "l"]);
994
- return {
995
- ...BASE,
996
- ex: 1,
997
- eyes: tug ? "big" : c === 15 ? "closed" : "open",
998
- extras: e
999
- };
1000
- },
1001
- listening: t => {
1002
- // Shifted left; a hand cupped at the side, sound arcs arriving from the right.
1003
- const c = Math.floor(t / 2) % 4;
1004
- const e = [[13, 5, "g"], [14, 5, "g"], [14, 6, "g"]];
1005
- const inner = [[15, 4, "n"], [16, 5, "n"], [16, 6, "n"], [15, 7, "n"]];
1006
- const outer = [[16, 3, "l"], [17, 4, "l"], [17, 5, "l"], [17, 6, "l"], [17, 7, "l"], [16, 8, "l"]];
1007
- if (c === 0 || c === 1) e.push(...inner);
1008
- if (c === 1 || c === 2) e.push(...outer);
1009
- return {
1010
- ...BASE,
1011
- dx: -2,
1012
- eyes: "closed",
1013
- extras: e
1014
- };
1015
- },
1016
- tumbleweed: t => {
1017
- // A tumbleweed rolls past in the foreground; eyes follow it off the edge.
1018
- const c = t % 28;
1019
- const e = [];
1020
- const wx = 15 - c;
1021
- if (c < 20) {
1022
- if (c % 2) e.push([wx, 11, "A"], [wx + 2, 11, "A"], [wx + 1, 12, "A"], [wx, 13, "A"], [wx + 2, 13, "A"]);else e.push([wx + 1, 11, "A"], [wx, 12, "A"], [wx + 2, 12, "A"], [wx + 1, 13, "A"]);
1023
- }
1024
- const ex = c >= 20 ? 0 : wx > 8 ? 1 : wx > 3 ? 0 : -1;
1025
- return {
1026
- ...BASE,
1027
- ex,
1028
- ey: c < 20 ? 1 : 0,
1029
- extras: e
1030
- };
1031
- },
1032
- // ── Errors & trouble ────────────────────────────────────────────────────
1033
- warning: t => {
1034
- // Shifted left; a warning sign held up on the right, lamp blinking.
1035
- const e = [];
1036
- e.push([15, 0, "a"]);
1037
- rect(14, 1, 16, 2, "a", e);
1038
- rect(13, 3, 17, 4, "a", e);
1039
- e.push([15, 1, "k"], [15, 2, "k"], [15, 4, "k"]);
1040
- e.push([13, 5, "g"], [14, 5, "g"]);
1041
- return {
1042
- ...BASE,
1043
- dx: -2,
1044
- eyes: "big",
1045
- ex: 1,
1046
- ey: -1,
1047
- lamp: t % 4 < 2 ? "a" : "A",
1048
- extras: e
1049
- };
1050
- },
1051
- crash: t => {
1052
- // Burst, smoke, then dazed.
1053
- const c = t % 20;
1054
- const e = [];
1055
- if (c < 3) {
1056
- const rays = c % 2 ? [[1, 2], [14, 2], [0, 7], [15, 7], [4, 0], [11, 0], [1, 11], [14, 11]] : [[2, 1], [13, 1], [0, 5], [15, 5], [6, 0], [9, 0], [0, 9], [15, 9]];
1057
- rays.forEach(r => e.push(pt(r, c === 0 ? "l" : "a")));
1058
- } else if (c < 10) {
1059
- const y = 2 - Math.floor((c - 3) / 2);
1060
- if (y >= 0) e.push([2, y, "n"], [13, y, "n"], [1, y + 1, "n"], [14, y + 1, "n"]);
1061
- }
1062
- return {
1063
- ...BASE,
1064
- eyes: "x",
1065
- lamp: c < 3 ? "r" : "R",
1066
- dx: c < 3 ? [0, 1, -1][c] : c >= 10 ? [0, 1, 0, -1][c % 4] : 0,
1067
- legs: c < 10 ? [1, 1, 1] : [0, 0, 0],
1068
- extras: e
1069
- };
1070
- },
1071
- panic: t => {
1072
- // Arms flail, sweat flies, lamp strobes.
1073
- const u = t % 2;
1074
- const e = u ? [[2, 5, "g"], [1, 4, "g"], [13, 5, "g"], [14, 4, "g"], [14, 2, "l"]] : [[2, 7, "g"], [1, 8, "g"], [13, 7, "g"], [14, 8, "g"], [1, 3, "l"]];
1075
- return {
1076
- ...BASE,
1077
- eyes: "big",
1078
- lamp: u ? "r" : "a",
1079
- dx: [0, 1, 0, -1][t % 4],
1080
- legs: walk(t),
1081
- extras: e
1082
- };
1083
- },
1084
- sos: t => {
1085
- // The lamp flashes S-O-S in morse; arms wave between letters.
1086
- const c = t % SOS.length;
1087
- const on = SOS[c] === 1;
1088
- const u = Math.floor(t / 2) % 2;
1089
- const e = [[1, 4 + u * 2, "g"], [2, 5 + u * 2, "g"], [13, 5 + u * 2, "g"], [14, 4 + u * 2, "g"]];
1090
- return {
1091
- ...BASE,
1092
- eyes: "big",
1093
- lamp: on ? "r" : "R",
1094
- extras: e
1095
- };
1096
- },
1097
- offline: t => {
1098
- // A struck-through cloud; slumped, lamp dim, one glance up.
1099
- const c = t % 16;
1100
- const e = [];
1101
- rect(11, 0, 14, 0, "n", e);
1102
- rect(10, 1, 15, 1, "n", e);
1103
- rect(11, 2, 14, 2, "n", e);
1104
- if (c % 4 < 2) e.push([10, 3, "r"], [11, 2, "r"], [12, 1, "r"], [13, 0, "r"]);
1105
- const glance = c >= 10 && c < 14;
1106
- return {
1107
- ...BASE,
1108
- y0: 5,
1109
- lamp: "A",
1110
- eyes: glance ? "open" : "closed",
1111
- ex: 1,
1112
- ey: glance ? -1 : 0,
1113
- extras: e
1114
- };
1115
- },
1116
- timeout: t => {
1117
- // A clock ticks round, then turns red; Otto shakes.
1118
- const c = t % 16;
1119
- const late = c >= 12;
1120
- const e = [];
1121
- const ring = late ? "r" : "n";
1122
- e.push([13, 1, ring], [14, 1, ring], [12, 2, ring], [15, 2, ring], [12, 3, ring], [15, 3, ring], [13, 4, ring], [14, 4, ring]);
1123
- rect(13, 2, 14, 3, "l", e);
1124
- e.push(pt([[14, 2], [14, 3], [13, 3], [13, 2]][late ? 0 : Math.floor(c / 3) % 4], "k"));
1125
- return {
1126
- ...BASE,
1127
- ex: 1,
1128
- ey: -1,
1129
- eyes: late ? "closed" : "open",
1130
- lamp: late && c % 2 ? "r" : "a",
1131
- dx: late ? [0, 1, 0, -1][c % 4] : 0,
1132
- extras: e
1133
- };
1134
- },
1135
- locked: t => {
1136
- // A padlock on the right: look, strain at it, give up with a shrug.
1137
- const c = t % 20;
1138
- const e = [];
1139
- padlock(false, e);
1140
- const strain = c >= 6 && c < 12;
1141
- const give = c >= 12;
1142
- if (strain) e.push([13, 7, "g"], [14, 7, "g"]);
1143
- if (give) e.push([2, 5, "g"], [1, 4, "g"]);
1144
- return {
1145
- ...BASE,
1146
- ex: give ? 0 : 1,
1147
- ey: give ? 0 : -1,
1148
- eyes: strain ? "closed" : "open",
1149
- dx: strain && c % 2 ? -1 : 0,
1150
- extras: e
1151
- };
1152
- },
1153
- unlocked: t => {
1154
- // The shackle pops open; sparkles, a hop, a happy Otto.
1155
- const c = t % 20;
1156
- const open = c >= 4;
1157
- const e = [];
1158
- padlock(open, e);
1159
- if (c >= 4 && c < 10) {
1160
- const sp = c % 2 ? [[11, 0], [15, 5], [12, 6]] : [[12, 0], [11, 4], [15, 6]];
1161
- sp.forEach(s => e.push(pt(s, "l")));
1162
- }
1163
- const hop = c === 5 || c === 6 ? 1 : 0;
1164
- return {
1165
- ...BASE,
1166
- y0: 4 - hop,
1167
- ex: open ? 0 : 1,
1168
- ey: open ? 0 : -1,
1169
- eyes: open ? "happy" : "open",
1170
- lamp: open && c % 2 ? "A" : "a",
1171
- legs: hop ? [1, 1, 1] : [0, 0, 0],
1172
- extras: e
1173
- };
1174
- },
1175
- denied: t => {
1176
- // Shifted left; a red no-entry sign, head shaking.
1177
- const e = [];
1178
- rect(13, 0, 15, 0, "r", e);
1179
- rect(13, 4, 15, 4, "r", e);
1180
- for (let y = 1; y <= 3; y++) e.push([12, y, "r"], [16, y, "r"]);
1181
- e.push([13, 3, "r"], [14, 2, "r"], [15, 1, "r"]);
1182
- return {
1183
- ...BASE,
1184
- dx: -1,
1185
- ex: [-1, 0, 1, 0][Math.floor(t / 2) % 4],
1186
- ey: -1,
1187
- extras: e
1188
- };
1189
- },
1190
- broken: t => {
1191
- // A crack down the middle; a band-aid goes on.
1192
- const c = t % 24;
1193
- const e = [[8, 4, "k"], [7, 5, "k"], [8, 6, "k"], [7, 7, "k"], [8, 8, "k"], [7, 9, "k"], [8, 10, "k"]];
1194
- if (c >= 8) {
1195
- rect(6, 8, 9, 9, "n", e);
1196
- rect(7, 8, 8, 9, "l", e);
1197
- }
1198
- return {
1199
- ...BASE,
1200
- eyes: c < 8 ? "closed" : c === 20 ? "closed" : "open",
1201
- lamp: c < 8 && c % 2 ? "A" : "a",
1202
- dx: c < 4 ? [0, 1, 0, -1][c] : 0,
1203
- extras: e
1204
- };
1205
- },
1206
- sad: t => {
1207
- // Sunk a row, lamp dim, a tear rolls down and drops in.
1208
- const c = t % 16;
1209
- const ty = c >= 2 && c < 10 ? 8 + Math.floor((c - 2) / 2) : c >= 10 && c < 12 ? 12 : -1;
1210
- const e = ty >= 0 ? [[5, ty, "l"]] : [];
1211
- return {
1212
- ...BASE,
1213
- y0: 5,
1214
- lamp: "A",
1215
- eyes: "closed",
1216
- extras: e
1217
- };
1218
- },
1219
- rain: t => {
1220
- // A rain cloud overhead, drops falling; lamp dim, eyes shut.
1221
- const c = t % 12;
1222
- const e = [];
1223
- rect(5, 0, 10, 0, "n", e);
1224
- rect(4, 1, 11, 1, "m", e);
1225
- [1, 4, 8, 11, 14].forEach((x, i) => {
1226
- const y = 2 + (c + i * 3) % 11;
1227
- e.push([x, y, "l"]);
1228
- });
1229
- return {
1230
- ...BASE,
1231
- y0: 5,
1232
- lamp: "A",
1233
- eyes: "closed",
1234
- extras: e
1235
- };
1236
- },
1237
- sick: t => {
1238
- // A thermometer climbs; wobbling, sweating, eyes shut.
1239
- const c = t % 12;
1240
- const e = [];
1241
- rect(14, 2, 14, 7, "l", e);
1242
- e.push([14, 8, "r"], [15, 3, "n"], [15, 5, "n"]);
1243
- const level = Math.min(4, Math.floor(c / 2));
1244
- if (level > 0) rect(14, 8 - level, 14, 7, "r", e);
1245
- e.push(c % 2 ? [2, 4, "l"] : [1, 5, "l"]);
1246
- return {
1247
- ...BASE,
1248
- eyes: "closed",
1249
- lamp: "A",
1250
- dx: [0, 1, 0, -1][Math.floor(c / 3) % 4],
1251
- extras: e
1252
- };
1253
- },
1254
- flood: t => {
1255
- // In over the eyes, arms flailing, bubbles rising, lamp strobing.
1256
- const c = t % 8;
1257
- const e = [[1, 7 + c % 2, "g"], [2, 8 + c % 2, "g"], [13, 8 - c % 2, "g"], [14, 7 - c % 2, "g"], [0, 11 - c % 4, "l"], [15, 12 - (c + 2) % 4, "l"]];
1258
- return {
1259
- ...BASE,
1260
- submerged: true,
1261
- y0: 9,
1262
- eyes: "big",
1263
- lamp: c % 2 ? "a" : "A",
1264
- legs: null,
1265
- extras: e
1266
- };
1267
- },
1268
- bug: t => {
1269
- // A beetle crawls across the body; eyes track it; it flies off.
1270
- const c = t % 24;
1271
- const e = [];
1272
- let ex = 0;
1273
- let ey = 1;
1274
- if (c < 20) {
1275
- const bx = 3 + Math.floor(c / 2);
1276
- rect(bx, 8, bx + 1, 9, "1", e);
1277
- e.push([bx - 1, 9 - c % 2, "k"], [bx + 2, 8 + c % 2, "k"]);
1278
- ex = bx < 6 ? -1 : bx > 9 ? 1 : 0;
1279
- } else {
1280
- const f = c - 20;
1281
- e.push([12 + f, 7 - f, "1"], [13 + f, 7 - f, "1"], [12 + f, 6 - f, "n"], [14 + f, 6 - f, "n"]);
1282
- ex = 1;
1283
- ey = -1;
1284
- }
1285
- return {
1286
- ...BASE,
1287
- ex,
1288
- ey,
1289
- eyes: c >= 18 ? "big" : "open",
1290
- extras: e
1291
- };
1292
- },
1293
- alarm: t => {
1294
- // The lamp becomes a siren: red strobe, light rays sweeping.
1295
- const u = t % 2;
1296
- const e = u ? [[4, 2, "l"], [11, 2, "l"], [6, 0, "l"], [9, 0, "l"]] : [[3, 1, "l"], [12, 1, "l"], [7, 0, "l"], [8, 0, "l"]];
1297
- return {
1298
- ...BASE,
1299
- eyes: "big",
1300
- lamp: u ? "r" : "R",
1301
- extras: e
1302
- };
1303
- },
1304
- frozen: t => {
1305
- // Iced over: icicles for legs, snow falling, shivering.
1306
- const c = t % 12;
1307
- const e = [[4, 11, "l"], [4, 12, "l"], [7, 11, "l"], [10, 11, "l"], [10, 12, "l"], [3, 3, "l"], [12, 3, "l"]];
1308
- [1, 14, 5, 10].forEach((x, i) => e.push([x, (c * 2 + i * 3) % 12, "l"]));
1309
- return {
1310
- ...BASE,
1311
- lamp: "A",
1312
- legs: null,
1313
- dx: t % 2,
1314
- extras: e
1315
- };
1316
- },
1317
- snail: t => {
1318
- // A snail crosses the foreground at one pixel per six ticks.
1319
- const c = t % 36;
1320
- const e = [];
1321
- const sx = Math.floor(c / 6) - 3;
1322
- rect(sx, 9, sx + 2, 11, "A", e);
1323
- e.push([sx + 1, 10, "a"], [sx + 3, 11, "n"], [sx + 4, 11, "n"], [sx + 4, 10, "n"], [sx + 4, 9, "k"]);
1324
- return {
1325
- ...BASE,
1326
- ex: -1,
1327
- ey: 1,
1328
- eyes: c % 12 === 11 ? "closed" : "open",
1329
- extras: e
1330
- };
1331
- },
1332
- angry: t => {
1333
- // Brows down, lamp red, steam off the top, stomping.
1334
- const e = [[4, 5, "k"], [5, 5, "k"], [6, 6, "k"], [9, 6, "k"], [10, 5, "k"], [11, 5, "k"]];
1335
- if (t % 2) e.push([4, 1, "n"], [11, 1, "n"]);else e.push([3, 0, "n"], [12, 0, "n"]);
1336
- return {
1337
- ...BASE,
1338
- ey: 1,
1339
- lamp: t % 4 < 2 ? "r" : "R",
1340
- legs: walk(t),
1341
- extras: e
1342
- };
1343
- },
1344
- ghost: t => {
1345
- // Grey, translucent, no legs, floating; white eyes.
1346
- const c = t % 8;
1347
- const e = [];
1348
- const y0 = 4 - (c < 4 ? 0 : 1);
1349
- rect(4, y0, 11, y0 + 6, "m", e);
1350
- rect(3, y0 + 1, 3, y0 + 5, "m", e);
1351
- rect(12, y0 + 1, 12, y0 + 5, "m", e);
1352
- [4, 7, 10].forEach(x => e.push([x, y0 + 7, "m"]));
1353
- rect(5, y0 + 2, 6, y0 + 3, "l", e);
1354
- rect(9, y0 + 2, 10, y0 + 3, "l", e);
1355
- return {
1356
- ...BASE,
1357
- y0,
1358
- lamp: "A",
1359
- legs: null,
1360
- extras: e
1361
- };
1362
- },
1363
- nervous: t => {
1364
- // Eyes darting, sweat, feet fidgeting, lamp flickering.
1365
- const e = [t % 2 ? [13, 3, "l"] : [2, 3, "l"]];
1366
- return {
1367
- ...BASE,
1368
- ex: t % 2 ? 1 : -1,
1369
- lamp: t % 3 ? "a" : "A",
1370
- legs: t % 2 ? [1, 0, 0] : [0, 0, 1],
1371
- extras: e
1372
- };
1373
- },
1374
- // ── Questions & investigation ───────────────────────────────────────────
1375
- puzzled: t => {
1376
- // A tentacle curls up to scratch the head; eyes wander.
1377
- const c = t % 16;
1378
- const scratch = c >= 4 && c < 12;
1379
- const e = scratch ? [[13, 6, "g"], [14, 5, "g"], [14, 4, "g"], [13, 3 - c % 2, "g"]] : [];
1380
- return {
1381
- ...BASE,
1382
- ex: c < 4 ? 0 : c < 8 ? -1 : c < 12 ? 1 : 0,
1383
- ey: scratch ? -1 : 0,
1384
- eyes: c === 14 ? "closed" : "open",
1385
- extras: e
1386
- };
1387
- },
1388
- detective: t => {
1389
- // Deerstalker hat, magnifying glass held out and moving; eyes track it.
1390
- const c = t % 16;
1391
- const e = [];
1392
- rect(3, 3, 12, 3, "A", e);
1393
- rect(5, 1, 10, 2, "A", e);
1394
- rect(5, 2, 10, 2, "a", e);
1395
- const gy = Math.floor(c / 4) % 2 ? 4 : 5;
1396
- e.push([0, gy, "n"], [1, gy, "n"], [2, gy, "n"], [0, gy + 1, "n"], [2, gy + 1, "n"], [0, gy + 2, "n"], [1, gy + 2, "n"], [2, gy + 2, "n"]);
1397
- e.push([1, gy + 1, "l"], [2, gy + 3, "g"], [1, gy + 3, "g"]);
1398
- return {
1399
- ...BASE,
1400
- lamp: null,
1401
- ex: -1,
1402
- ey: gy === 4 ? -1 : 0,
1403
- eyes: c === 15 ? "closed" : "open",
1404
- extras: e
1405
- };
1406
- },
1407
- reading: t => {
1408
- // An open book held up; eyes run along the lines; a page turns.
1409
- const c = t % 24;
1410
- const e = [];
1411
- rect(3, 8, 12, 11, "l", e);
1412
- rect(7, 8, 8, 11, "n", e);
1413
- const flip = c >= 20 && c < 22;
1414
- if (flip) rect(9, 8, 12, 11, "n", e);
1415
- for (const y of [9, 10]) {
1416
- rect(4, y, 6, y, "k", e);
1417
- if (!flip) rect(9, y, 11, y, "k", e);
1418
- }
1419
- e.push([2, 9, "g"], [13, 9, "g"]);
1420
- return {
1421
- ...BASE,
1422
- ey: 1,
1423
- ex: c < 20 ? [-1, 0, 1][Math.floor(c / 2) % 3] : 0,
1424
- eyes: c === 22 ? "closed" : "open",
1425
- legs: null,
1426
- extras: e
1427
- };
1428
- },
1429
- // ── Success & celebration ───────────────────────────────────────────────
1430
- success: t => {
1431
- // A check mark lands on the right; sparkles, a hop, the lamp blinks.
1432
- const c = t % 16;
1433
- const e = [];
1434
- if (c >= 2) e.push([11, 2, "g"], [12, 3, "g"], [13, 2, "g"], [14, 1, "g"], [15, 0, "g"]);
1435
- if (c >= 3 && c < 7) {
1436
- const sp = c % 2 ? [[10, 0], [15, 3], [13, 5]] : [[11, 0], [14, 4], [9, 1]];
1437
- sp.forEach(s => e.push(pt(s, "l")));
1438
- }
1439
- const hop = c === 3 || c === 4 ? 1 : 0;
1440
- return {
1441
- ...BASE,
1442
- y0: 4 - hop,
1443
- eyes: c >= 2 ? "happy" : "open",
1444
- ex: c >= 2 ? 0 : 1,
1445
- ey: c >= 2 ? 0 : -1,
1446
- lamp: c >= 2 && c < 8 && c % 2 ? "A" : "a",
1447
- legs: hop ? [1, 1, 1] : [0, 0, 0],
1448
- extras: e
1449
- };
1450
- },
1451
- celebrate: t => {
1452
- // Confetti falls, arms up, bouncing.
1453
- const c = t % 12;
1454
- const e = [];
1455
- const cols = [0, 15, 2, 13, 5, 10, 1, 14];
1456
- const tint = ["p", "l", "a", "p", "l", "p", "a", "l"];
1457
- cols.forEach((x, i) => e.push([x, (c * 2 + i * 5) % 13, tint[i]]));
1458
- const up = c % 4 < 2;
1459
- e.push([2, 5, "g"], [1, 4, "g"], [13, 5, "g"], [14, 4, "g"]);
1460
- return {
1461
- ...BASE,
1462
- y0: up ? 3 : 4,
1463
- eyes: "happy",
1464
- legs: up ? [1, 1, 1] : [0, 0, 0],
1465
- extras: e
1466
- };
1467
- },
1468
- thumbsup: t => {
1469
- // A fist rises with the thumb out; then a wink.
1470
- const c = t % 12;
1471
- const lift = c < 4 ? 2 : 0;
1472
- const e = [];
1473
- rect(13, 6 + lift, 14, 7 + lift, "g", e);
1474
- e.push([14, 4 + lift, "g"], [14, 5 + lift, "g"]);
1475
- const wink = c >= 6 && c < 10;
1476
- if (wink) e.push([5, 6, "g"], [6, 6, "g"]);
1477
- return {
1478
- ...BASE,
1479
- eyes: c >= 4 && !wink ? "happy" : "open",
1480
- extras: e
1481
- };
1482
- },
1483
- party: t => {
1484
- // Party hat in place of the lamp, confetti, a side-to-side dance.
1485
- const c = t % 16;
1486
- const e = [];
1487
- e.push([7, 0, "a"], [8, 0, "a"]);
1488
- rect(6, 1, 9, 1, "p", e);
1489
- rect(5, 2, 10, 2, "a", e);
1490
- rect(4, 3, 11, 3, "p", e);
1491
- [0, 15, 2, 13].forEach((x, i) => e.push([x, (c * 2 + i * 4) % 12, i % 2 ? "l" : "p"]));
1492
- const u = Math.floor(c / 2) % 2;
1493
- e.push([1, 5 + u, "g"], [2, 6 - u, "g"], [13, 6 - u, "g"], [14, 5 + u, "g"]);
1494
- return {
1495
- ...BASE,
1496
- lamp: null,
1497
- eyes: "happy",
1498
- dx: [0, 1, 0, -1][Math.floor(c / 2) % 4],
1499
- legs: walk(Math.floor(c / 2)),
1500
- extras: e
1501
- };
1502
- },
1503
- trophy: t => {
1504
- // A cup held overhead, arms raised, sparkles, a hop every so often.
1505
- const c = t % 16;
1506
- const e = [];
1507
- rect(5, 0, 10, 0, "a", e);
1508
- rect(6, 1, 9, 1, "a", e);
1509
- rect(7, 2, 8, 2, "A", e);
1510
- rect(6, 3, 9, 3, "A", e);
1511
- e.push([2, 5, "g"], [1, 4, "g"], [13, 5, "g"], [14, 4, "g"]);
1512
- if (c % 2) e.push([3, 0, "l"], [12, 1, "l"]);else e.push([4, 1, "l"], [11, 0, "l"]);
1513
- const hop = c === 8 || c === 9 ? 1 : 0;
1514
- return {
1515
- ...BASE,
1516
- y0: 4 - hop,
1517
- lamp: null,
1518
- eyes: "happy",
1519
- legs: hop ? [1, 1, 1] : [0, 0, 0],
1520
- extras: e
1521
- };
1522
- },
1523
- starred: t => {
1524
- // A star pops in at the top right and twinkles.
1525
- const c = t % 12;
1526
- const e = [];
1527
- if (c >= 1) {
1528
- e.push([13, 0, "a"]);
1529
- rect(11, 1, 15, 1, "a", e);
1530
- rect(12, 2, 14, 2, "a", e);
1531
- e.push([12, 3, "a"], [14, 3, "a"], [11, 4, "a"], [15, 4, "a"]);
1532
- if (c % 3 === 0) e.push([13, 2, "l"]);
1533
- }
1534
- return {
1535
- ...BASE,
1536
- ex: 1,
1537
- ey: -1,
1538
- eyes: c >= 4 ? "happy" : "open",
1539
- extras: e
1540
- };
1541
- },
1542
- love: t => {
1543
- // Hearts float up either side; the body bobs.
1544
- const c = t % 16;
1545
- const e = [];
1546
- const heart = (x, y) => {
1547
- if (y < -2) return;
1548
- e.push([x, y, "r"], [x + 2, y, "r"], [x, y + 1, "r"], [x + 1, y + 1, "r"], [x + 2, y + 1, "r"], [x + 1, y + 2, "r"]);
1549
- };
1550
- heart(0, 8 - Math.floor(c / 2) * 2);
1551
- heart(13, 8 - Math.floor((c + 8) % 16 / 2) * 2);
1552
- return {
1553
- ...BASE,
1554
- y0: 4 + Math.floor(c / 4) % 2,
1555
- eyes: "happy",
1556
- extras: e
1557
- };
1558
- },
1559
- wave: t => {
1560
- // One arm up, hand swinging side to side; a smile at the end.
1561
- const c = t % 12;
1562
- const e = [[13, 5, "g"], [14, 4, "g"], [c % 2 ? 15 : 14, 3, "g"]];
1563
- return {
1564
- ...BASE,
1565
- eyes: c >= 8 ? "happy" : "open",
1566
- extras: e
1567
- };
1568
- },
1569
- bow: t => {
1570
- // A slow bow: squash forward, eyes shut, back up.
1571
- const c = t % 16;
1572
- const down = c >= 4 && c < 12;
1573
- return down ? {
1574
- ...BASE,
1575
- y0: 6,
1576
- h: 5,
1577
- eyes: "closed"
1578
- } : {
1579
- ...BASE
1580
- };
1581
- },
1582
- cool: t => {
1583
- // Sunglasses drop into place; a little sway.
1584
- const c = t % 16;
1585
- const y = Math.min(6, 3 + c);
1586
- const e = [];
1587
- rect(4, y, 6, y + 1, "k", e);
1588
- rect(9, y, 11, y + 1, "k", e);
1589
- e.push([7, y, "k"], [8, y, "k"]);
1590
- const on = y === 6;
1591
- return {
1592
- ...BASE,
1593
- dx: on ? [0, 0, 1, 0, 0, -1][Math.floor(c / 2) % 6] : 0,
1594
- extras: e
1595
- };
1596
- },
1597
- flexing: t => {
1598
- // Both arms up in a flex; the biceps pop every other beat.
1599
- const c = t % 8;
1600
- const e = [[2, 6, "g"], [1, 6, "g"], [1, 5, "g"], [1, 4, "g"], [13, 6, "g"], [14, 6, "g"], [14, 5, "g"], [14, 4, "g"]];
1601
- if (c < 4) e.push([0, 5, "g"], [15, 5, "g"]);
1602
- return {
1603
- ...BASE,
1604
- eyes: c < 4 ? "open" : "happy",
1605
- extras: e
1606
- };
1607
- },
1608
- zen: t => {
1609
- // Floating above the water, eyes shut, slow bob, a sparkle or two.
1610
- const c = t % 16;
1611
- const e = c < 8 ? [[1, 5, "l"], [14, 9, "l"]] : [[2, 10, "l"], [13, 4, "l"]];
1612
- return {
1613
- ...BASE,
1614
- y0: 3 + Math.floor(c / 8) % 2,
1615
- lamp: "a",
1616
- eyes: "closed",
1617
- legs: null,
1618
- extras: e
1619
- };
1620
- },
1621
- // ── Tool moments ────────────────────────────────────────────────────────
1622
- recording: t => {
1623
- // A red REC dot blinks at the top right; eyes slowly sweep the room.
1624
- const c = t % 16;
1625
- const e = c % 4 < 2 ? [...rect(13, 0, 14, 1, "r", [])] : [];
1626
- return {
1627
- ...BASE,
1628
- ex: [-1, -1, 0, 0, 1, 1, 0, 0][Math.floor(c / 2)],
1629
- extras: e
1630
- };
1631
- },
1632
- paused: t => {
1633
- // Pause bars overhead; resting with the lamp dim, one peek.
1634
- const c = t % 16;
1635
- const e = [];
1636
- rect(13, 0, 13, 3, "n", e);
1637
- rect(15, 0, 15, 3, "n", e);
1638
- const peek = c >= 8 && c < 10;
1639
- return {
1640
- ...BASE,
1641
- y0: 5,
1642
- lamp: "A",
1643
- eyes: peek ? "open" : "closed",
1644
- ex: 1,
1645
- ey: peek ? -1 : 0,
1646
- extras: e
1647
- };
1648
- },
1649
- filtering: t => {
1650
- // A funnel on the right: mixed bits go in the top, only orange comes out.
1651
- const c = t % 12;
1652
- const e = [];
1653
- rect(12, 0, 15, 0, "n", e);
1654
- e.push([12, 1, "n"], [15, 1, "n"], [13, 2, "n"], [14, 2, "n"], [14, 3, "n"], [14, 4, "n"]);
1655
- const mix = ["p", "l", "a", "l", "p", "a"];
1656
- e.push([13, 1, mix[c % 6]], [14, 1, mix[(c + 3) % 6]]);
1657
- e.push([14, 5 + c % 4, "a"]);
1658
- return {
1659
- ...BASE,
1660
- ex: 1,
1661
- ey: c % 8 < 4 ? -1 : 1,
1662
- extras: e
1663
- };
1664
- },
1665
- pinned: t => {
1666
- // A pushpin drops in from above and lands with a blink.
1667
- const c = t % 12;
1668
- const dy = c < 3 ? c - 3 : 0;
1669
- const e = [];
1670
- rect(13, 1 + dy, 14, 2 + dy, "r", e);
1671
- e.push([13, 3 + dy, "n"], [14, 3 + dy, "n"], [13, 4 + dy, "n"], [13, 5 + dy, "n"]);
1672
- if (c === 4 || c === 5) e.push([15, 0, "l"], [12, 6, "l"]);
1673
- return {
1674
- ...BASE,
1675
- ex: 1,
1676
- ey: -1,
1677
- eyes: c === 3 ? "closed" : "open",
1678
- extras: e
1679
- };
1680
- },
1681
- rewind: t => {
1682
- // Moonwalks left while a clock runs backwards beside it.
1683
- const c = t % 16;
1684
- const e = [];
1685
- e.push([1, 0, "n"], [2, 0, "n"], [0, 1, "n"], [3, 1, "n"], [0, 2, "n"], [3, 2, "n"], [1, 3, "n"], [2, 3, "n"]);
1686
- rect(1, 1, 2, 2, "l", e);
1687
- e.push(pt([[1, 1], [1, 2], [2, 2], [2, 1]][c % 4], "k"));
1688
- return {
1689
- ...BASE,
1690
- dx: 3 - Math.floor(c / 2),
1691
- ex: 1,
1692
- legs: walk(t),
1693
- extras: e
1694
- };
1695
- },
1696
- storing: t => {
1697
- // Crates stack up on the right, one lowered into place every six ticks.
1698
- const c = t % 24;
1699
- const e = [];
1700
- const placed = Math.floor(c / 6);
1701
- for (let i = 0; i < Math.min(3, placed); i++) {
1702
- const y = 11 - i * 2;
1703
- rect(13, y, 14, y + 1, "A", e);
1704
- e.push([13, y, "a"]);
1705
- }
1706
- if (placed < 3) {
1707
- const y = 4 + (c % 6 < 3 ? 0 : 1);
1708
- rect(13, y, 14, y + 1, "A", e);
1709
- e.push([13, y, "a"], [13, y + 2, "g"], [14, y + 2, "g"]);
1710
- }
1711
- return {
1712
- ...BASE,
1713
- ex: 1,
1714
- ey: placed < 3 ? 0 : 1,
1715
- eyes: placed === 3 && c % 6 === 5 ? "happy" : "open",
1716
- extras: e
1717
- };
1718
- },
1719
- printing: t => {
1720
- // A little printer spools out a strip of log lines.
1721
- const c = t % 16;
1722
- const e = [];
1723
- rect(13, 3, 15, 5, "n", e);
1724
- e.push([14, 4, "1"]);
1725
- const len = Math.min(6, c);
1726
- if (len > 0) {
1727
- rect(13, 6, 15, 5 + len, "l", e);
1728
- for (let y = 6; y <= 5 + len; y += 2) e.push([14, y, "k"]);
1729
- }
1730
- return {
1731
- ...BASE,
1732
- ex: 1,
1733
- ey: 1,
1734
- extras: e
1735
- };
1736
- },
1737
- stopwatch: t => {
1738
- // A stopwatch with a fast hand; speed lines off the far side.
1739
- const e = [];
1740
- e.push([13, 0, "n"], [13, 1, "n"], [14, 1, "n"], [12, 2, "n"], [15, 2, "n"], [12, 3, "n"], [15, 3, "n"], [13, 4, "n"], [14, 4, "n"]);
1741
- rect(13, 2, 14, 3, "l", e);
1742
- e.push(pt([[14, 2], [14, 3], [13, 3], [13, 2]][t % 4], "k"));
1743
- if (t % 2) e.push([0, 6, "n"], [1, 6, "n"], [0, 9, "n"]);else e.push([0, 7, "n"], [1, 8, "n"], [0, 8, "n"]);
1744
- return {
1745
- ...BASE,
1746
- eyes: "big",
1747
- ex: 1,
1748
- ey: -1,
1749
- extras: e
1750
- };
1751
- },
1752
- spotlight: t => {
1753
- // The lamp throws a beam that sweeps left, up, right.
1754
- const c = t % 12;
1755
- const e = [];
1756
- if (c < 4) {
1757
- rect(4, 1, 7, 1, "a", e);
1758
- rect(2, 0, 6, 0, "a", e);
1759
- } else if (c < 8) {
1760
- rect(6, 1, 9, 1, "a", e);
1761
- rect(5, 0, 10, 0, "a", e);
1762
- } else {
1763
- rect(8, 1, 11, 1, "a", e);
1764
- rect(9, 0, 13, 0, "a", e);
1765
- }
1766
- return {
1767
- ...BASE,
1768
- ex: c < 4 ? -1 : c < 8 ? 0 : 1,
1769
- ey: -1,
1770
- extras: e
1771
- };
1772
- },
1773
- keys: t => {
1774
- // A keyring held out; the keys jingle.
1775
- const c = t % 8;
1776
- const e = [[13, 5, "g"], [14, 5, "g"]];
1777
- e.push([13, 6, "n"], [14, 6, "n"], [15, 6, "n"], [13, 7, "n"], [15, 7, "n"], [13, 8, "n"], [14, 8, "n"], [15, 8, "n"]);
1778
- const k2 = c < 4 ? 15 : 14;
1779
- e.push([13, 9, "a"], [13, 10, "a"], [k2, 9, "a"], [k2, 10, "a"]);
1780
- return {
1781
- ...BASE,
1782
- ex: 1,
1783
- ey: 1,
1784
- eyes: c === 7 ? "closed" : "open",
1785
- extras: e
1786
- };
1787
- },
1788
- map: t => {
1789
- // A folded map held up: dotted route, red pin; looks around for the way.
1790
- const c = t % 16;
1791
- const e = [];
1792
- rect(3, 8, 12, 11, "l", e);
1793
- e.push([4, 10, "m"], [5, 9, "m"], [6, 9, "m"], [7, 10, "m"], [8, 10, "m"], [9, 9, "m"], [10, 9, "m"]);
1794
- e.push([11, 8, "r"], [11, 9, "r"]);
1795
- e.push([2, 9, "g"], [13, 9, "g"]);
1796
- const look = c >= 8;
1797
- return {
1798
- ...BASE,
1799
- ex: look ? c < 12 ? -1 : 1 : 0,
1800
- ey: look ? -1 : 1,
1801
- legs: null,
1802
- extras: e
1803
- };
1804
- },
1805
- photo: t => {
1806
- // A camera held up; flash; a print pops out the side.
1807
- const c = t % 16;
1808
- const e = [];
1809
- rect(5, 8, 10, 10, "n", e);
1810
- rect(7, 9, 8, 9, "k", e);
1811
- e.push([7, 9, "l"], [10, 8, "1"]);
1812
- e.push([2, 9, "g"], [13, 9, "g"]);
1813
- if (c === 6) {
1814
- rect(0, 0, 15, 1, "l", e);
1815
- e.push([3, 2, "l"], [12, 2, "l"]);
1816
- }
1817
- if (c >= 8) {
1818
- rect(13, 6, 15, 8, "n", e);
1819
- e.push([14, 7, "g"]);
1820
- }
1821
- return {
1822
- ...BASE,
1823
- lamp: c === 6 ? "a" : "A",
1824
- eyes: c === 6 ? "closed" : "open",
1825
- legs: null,
1826
- extras: e
1827
- };
1828
- },
1829
- painting: t => {
1830
- // A canvas on the right; strokes appear as the brush works.
1831
- const c = t % 16;
1832
- const e = [];
1833
- rect(13, 2, 15, 7, "l", e);
1834
- if (c >= 2) e.push([13, 3, "p"], [14, 3, "p"]);
1835
- if (c >= 6) e.push([14, 5, "a"], [15, 5, "a"]);
1836
- if (c >= 10) e.push([13, 6, "r"]);
1837
- e.push([13, 8, "g"], [14, 8, "g"], [15, 8 - c % 2, "m"]);
1838
- return {
1839
- ...BASE,
1840
- ex: 1,
1841
- ey: c % 8 < 4 ? -1 : 0,
1842
- extras: e
1843
- };
1844
- },
1845
- disguise: t => {
1846
- // Groucho glasses, nose and moustache; sly glances.
1847
- const e = [];
1848
- for (const x of [4, 8]) {
1849
- rect(x, 5, x + 3, 5, "n", e);
1850
- rect(x, 8, x + 3, 8, "n", e);
1851
- e.push([x, 6, "n"], [x, 7, "n"], [x + 3, 6, "n"], [x + 3, 7, "n"]);
1852
- }
1853
- e.push([7, 8, "a"], [8, 8, "a"]);
1854
- rect(5, 9, 10, 9, "k", e);
1855
- e.push([5, 10, "k"], [10, 10, "k"]);
1856
- return {
1857
- ...BASE,
1858
- ex: [-1, -1, -1, 0, 1, 1, 1, 0][Math.floor(t / 3) % 8],
1859
- extras: e
1860
- };
1861
- },
1862
- pro: t => {
1863
- // A crown in place of the lamp, jewels, sparkles.
1864
- const c = t % 12;
1865
- const e = [];
1866
- rect(5, 2, 10, 3, "a", e);
1867
- e.push([5, 1, "a"], [7, 1, "a"], [8, 1, "a"], [10, 1, "a"], [6, 2, "p"], [9, 2, "p"]);
1868
- e.push(c % 2 ? [3, 1, "l"] : [12, 0, "l"]);
1869
- return {
1870
- ...BASE,
1871
- lamp: null,
1872
- eyes: c >= 6 ? "happy" : "open",
1873
- extras: e
1874
- };
1875
- },
1876
- talking: t => {
1877
- // A speech bubble with typing dots; the lamp pulses as it speaks.
1878
- const c = t % 12;
1879
- const e = [];
1880
- rect(9, 0, 15, 2, "l", e);
1881
- e.push([10, 3, "l"]);
1882
- [10, 12, 14].forEach((x, i) => e.push([x, 1, (c + i) % 3 === 0 ? "k" : "m"]));
1883
- return {
1884
- ...BASE,
1885
- ex: 1,
1886
- ey: -1,
1887
- lamp: c % 4 < 2 ? "a" : "A",
1888
- extras: e
1889
- };
1890
- },
1891
- handshake: t => {
1892
- // A hand arrives from the right; Otto meets it; they shake.
1893
- const c = t % 16;
1894
- const hx = 16 - Math.min(2, c);
1895
- const dy = c >= 4 && c < 12 ? Math.floor(c / 2) % 2 : 0;
1896
- const e = [];
1897
- rect(hx, 6 + dy, hx + 1, 7 + dy, "n", e);
1898
- if (c >= 2) e.push([13, 7 + dy, "g"]);
1899
- return {
1900
- ...BASE,
1901
- ex: 1,
1902
- eyes: c >= 4 ? "happy" : "open",
1903
- extras: e
1904
- };
1905
- },
1906
- robot: t => {
1907
- // A small robot friend on the right: antenna blinking, eyes flickering.
1908
- const c = t % 16;
1909
- const e = [];
1910
- e.push([14, 3, c % 4 < 2 ? "r" : "n"], [14, 4, "n"]);
1911
- rect(13, 5, 15, 7, "n", e);
1912
- const eye = c % 8 < 2 ? "r" : "k";
1913
- e.push([13, 6, eye], [15, 6, eye]);
1914
- rect(13, 8, 15, 10, "m", e);
1915
- e.push([14, 9, "l"], [13, 11, "n"], [15, 11, "n"]);
1916
- return {
1917
- ...BASE,
1918
- ex: 1,
1919
- ey: 1,
1920
- eyes: c >= 8 && c < 12 ? "happy" : "open",
1921
- extras: e
1922
- };
1923
- },
1924
- plug: t => {
1925
- // A plug slides in from the right and connects; the lamp comes on.
1926
- const c = t % 16;
1927
- const px = 16 - Math.min(3, c);
1928
- const e = [];
1929
- rect(px, 6, px + 1, 7, "n", e);
1930
- e.push([px - 1, 6, "l"], [px - 1, 7, "l"], [px + 2, 7, "n"], [px + 3, 7, "n"]);
1931
- if (c >= 4 && c < 7) e.push(c % 2 ? [11, 2, "l"] : [15, 4, "l"]);
1932
- return {
1933
- ...BASE,
1934
- lamp: c >= 3 ? "a" : "A",
1935
- ex: 1,
1936
- eyes: c >= 5 ? "happy" : "open",
1937
- extras: e
1938
- };
1939
- },
1940
- gift: t => {
1941
- // A wrapped gift bounces; the lid lifts with a sparkle.
1942
- const c = t % 16;
1943
- const open = c >= 12;
1944
- const dy = !open && c % 4 === 2 ? -1 : 0;
1945
- const e = [];
1946
- rect(13, 7 + dy, 15, 10 + dy, "p", e);
1947
- rect(14, 7 + dy, 14, 10 + dy, "a", e);
1948
- const by = open ? 4 : 6 + dy;
1949
- rect(13, by, 15, by, "a", e);
1950
- if (open) e.push([14, 3, "l"], [12, 5, "l"]);
1951
- return {
1952
- ...BASE,
1953
- ex: 1,
1954
- ey: 1,
1955
- eyes: open ? "happy" : "big",
1956
- extras: e
1957
- };
1958
- },
1959
- action: t => {
1960
- // A clapperboard on the right claps shut.
1961
- const c = t % 16;
1962
- const closed = c === 4 || c === 5;
1963
- const e = [];
1964
- rect(13, 4, 15, 7, "n", e);
1965
- e.push([14, 5, "k"], [14, 6, "k"]);
1966
- const by = closed ? 3 : 2;
1967
- e.push([13, by, "l"], [14, by, "k"], [15, by, "l"]);
1968
- if (c === 4) e.push([12, 2, "l"]);
1969
- return {
1970
- ...BASE,
1971
- ex: 1,
1972
- ey: -1,
1973
- eyes: c === 4 ? "closed" : "open",
1974
- extras: e
1975
- };
1976
- },
1977
- guard: t => {
1978
- // A shield up; a red bolt comes in, sparks off it and bounces away.
1979
- const c = t % 16;
1980
- const e = [];
1981
- rect(13, 5, 15, 7, "n", e);
1982
- e.push([14, 8, "n"], [14, 6, "g"]);
1983
- if (c % 6 === 0) e.push([13, 5, "l"]);
1984
- if (c >= 2 && c < 6) e.push([15, c - 2, "r"]);
1985
- if (c === 6) e.push([15, 4, "l"], [14, 4, "l"]);
1986
- if (c >= 7 && c < 10) e.push([15, 9 - c, "R"]);
1987
- return {
1988
- ...BASE,
1989
- ex: 1,
1990
- ey: -1,
1991
- eyes: c === 5 || c === 6 ? "big" : "open",
1992
- extras: e
1993
- };
1994
- },
1995
- coffee: t => {
1996
- // A mug with steam; lifts it for a sip, eyes shut, then content.
1997
- const c = t % 16;
1998
- const sip = c >= 8 && c < 12;
1999
- const dy = sip ? -2 : 0;
2000
- const e = [];
2001
- rect(13, 6 + dy, 14, 8 + dy, "l", e);
2002
- e.push([15, 7 + dy, "n"], [13, 6 + dy, "A"], [14, 6 + dy, "A"], [13, 9 + dy, "g"], [14, 9 + dy, "g"]);
2003
- if (!sip) e.push(...(c % 2 ? [[13, 4, "n"], [14, 3, "n"]] : [[14, 4, "n"], [13, 3, "n"]]));
2004
- return {
2005
- ...BASE,
2006
- ex: sip ? 0 : 1,
2007
- ey: sip ? 0 : 1,
2008
- eyes: sip ? "closed" : c >= 12 && c < 14 ? "happy" : "open",
2009
- extras: e
2010
- };
2011
- },
2012
- swimming: t => {
2013
- // In the water to the shoulders, alternating strokes with splashes.
2014
- const c = t % 8;
2015
- const left = c < 4;
2016
- const e = left ? [[1, 8, "g"], [2, 9, "g"], [0, 12, "l"], [13, 11, "g"], [14, 12, "g"]] : [[14, 8, "g"], [13, 9, "g"], [15, 12, "l"], [2, 11, "g"], [1, 12, "g"]];
2017
- return {
2018
- ...BASE,
2019
- submerged: true,
2020
- y0: 8,
2021
- ex: left ? -1 : 1,
2022
- legs: null,
2023
- extras: e
2024
- };
2025
- },
2026
- diving: t => {
2027
- // Sinks out of sight, bubbles rise, then comes back up dripping.
2028
- const c = t % 24;
2029
- const e = [];
2030
- let y0 = 4;
2031
- if (c >= 4 && c < 10) y0 = 4 + (c - 3) * 2;else if (c >= 10 && c < 16) y0 = 16;else if (c >= 16 && c < 20) y0 = 14 - (c - 15) * 2;
2032
- if (c >= 8 && c < 16) e.push([7, 12 - c * 2 % 6, "l"], [9, 12 - (c * 2 + 3) % 6, "l"]);
2033
- if (c === 20 || c === 21) e.push([3, 3, "l"], [12, 3, "l"]);
2034
- return {
2035
- ...BASE,
2036
- submerged: y0 > 4,
2037
- y0,
2038
- ey: c < 4 ? 1 : 0,
2039
- eyes: c >= 20 && c < 23 ? "happy" : "open",
2040
- legs: y0 > 4 ? null : [0, 0, 0],
2041
- extras: e
2042
- };
2043
- },
2044
- balloon: t => {
2045
- // A balloon lifts Otto clear of the water; a splash when it lets go.
2046
- const c = t % 24;
2047
- const y0 = c < 8 ? 4 : c < 20 ? 4 - Math.min(3, Math.floor((c - 8) / 2)) : 4;
2048
- const e = [];
2049
- rect(13, 0, 15, 2, "r", e);
2050
- e.push([14, 3, "R"]);
2051
- rect(14, 4, 14, y0 + 2, "n", e);
2052
- e.push([13, y0 + 2, "g"]);
2053
- if (c === 20) e.push([2, 12, "l"], [12, 12, "l"]);
2054
- const lifted = y0 < 4;
2055
- return {
2056
- ...BASE,
2057
- y0,
2058
- ex: lifted ? 0 : 1,
2059
- ey: lifted ? 0 : -1,
2060
- eyes: lifted ? "happy" : "open",
2061
- legs: lifted ? c % 2 ? [1, 0, 1] : [0, 1, 0] : [0, 0, 0],
2062
- extras: e
2063
- };
2064
- },
2065
- landing: t => {
2066
- // Drops in from above, lands with a squash and a splash, settles.
2067
- const c = t % 16;
2068
- if (c < 4) return {
2069
- ...BASE,
2070
- y0: -8 + c * 3,
2071
- eyes: "big",
2072
- legs: [1, 1, 1]
2073
- };
2074
- if (c === 4) return {
2075
- ...BASE,
2076
- x0: 2,
2077
- w: 12,
2078
- y0: 6,
2079
- h: 5,
2080
- eyes: "closed",
2081
- extras: [[1, 12, "l"], [14, 12, "l"], [0, 11, "l"], [15, 11, "l"]]
2082
- };
2083
- if (c === 5) return {
2084
- ...BASE,
2085
- eyes: "closed"
2086
- };
2087
- return {
2088
- ...BASE,
2089
- eyes: c >= 8 && c < 12 ? "happy" : "open"
2090
- };
2091
- },
2092
- spinning: t => {
2093
- // A full turn: front, three-quarter, side, back and round again.
2094
- const c = t % 16;
2095
- const ph = Math.floor(c / 2);
2096
- const [w, ex] = [[10, 0], [8, 1], [6, 0], [4, 0], [6, 0], [8, -1], [10, 0], [10, 0]][ph];
2097
- const x0 = 3 + (10 - w) / 2;
2098
- const e = [];
2099
- if (w <= 6) {
2100
- const x1 = x0 + w - 1;
2101
- e.push([x0 + 1, 11, "s"], [x0 + 1, 12, "s"], [x1 - 1, 11, "s"], [x1 - 1, 12, "s"]);
2102
- }
2103
- if (w === 4) rect(x0, 6, x0 + 3, 7, "g", e);
2104
- return {
2105
- ...BASE,
2106
- x0,
2107
- w,
2108
- ex,
2109
- legs: w <= 6 ? null : [0, 0, 0],
2110
- extras: e
2111
- };
2112
- },
2113
- bubbles: t => {
2114
- // Blows through a bubble wand; bubbles drift up and away.
2115
- const c = t % 12;
2116
- const blow = c < 4;
2117
- const e = [[13, 6, "g"], [14, 6, "g"], [15, 6, "m"], [15, 5, "m"], [15, 4, "n"]];
2118
- for (let i = 0; i < 3; i++) {
2119
- const y = 3 - (c + i * 4) % 12;
2120
- if (y >= 0) e.push([13 + i % 2, y, "l"]);
2121
- }
2122
- return {
2123
- ...BASE,
2124
- ex: blow ? 1 : 1,
2125
- ey: blow ? 0 : -1,
2126
- eyes: blow ? "closed" : "open",
2127
- extras: e
2128
- };
2129
- },
2130
- trash: t => {
2131
- // Bits fly into a bin, the lid flaps, a puff when it's done.
2132
- const c = t % 16;
2133
- const e = [];
2134
- rect(13, 7, 15, 11, "n", e);
2135
- rect(14, 8, 14, 10, "1", e);
2136
- const open = c >= 2 && c < 10;
2137
- rect(13, open ? 5 : 6, 15, open ? 5 : 6, "n", e);
2138
- if (c >= 3 && c < 9) e.push([7 + (c - 3), 5 - c % 2, c % 2 ? "p" : "a"]);
2139
- if (c === 9 || c === 10) e.push([14, 4, "l"], [13, 3, "l"], [15, 3, "l"]);
2140
- return {
2141
- ...BASE,
2142
- ex: 1,
2143
- ey: -1,
2144
- eyes: c >= 11 && c < 14 ? "happy" : "open",
2145
- extras: e
2146
- };
2147
- },
2148
- saved: t => {
2149
- // A floppy disk pops in; a hop and a sparkle.
2150
- const c = t % 12;
2151
- const dy = c === 1 ? -1 : 0;
2152
- const e = [];
2153
- if (c >= 1) {
2154
- rect(13, 2 + dy, 15, 5 + dy, "1", e);
2155
- e.push([13, 2 + dy, "n"], [14, 2 + dy, "n"]);
2156
- rect(13, 4 + dy, 15, 5 + dy, "l", e);
2157
- }
2158
- if (c === 3 || c === 4) e.push([12, 0, "l"], [15, 7, "l"]);
2159
- const hop = c === 2 ? 1 : 0;
2160
- return {
2161
- ...BASE,
2162
- y0: 4 - hop,
2163
- ex: 1,
2164
- ey: -1,
2165
- eyes: c >= 3 ? "happy" : "open",
2166
- legs: hop ? [1, 1, 1] : [0, 0, 0],
2167
- extras: e
2168
- };
2169
- },
2170
- copied: t => {
2171
- // One sheet slides out from behind another; a sparkle.
2172
- const c = t % 12;
2173
- const off = c < 2 ? 0 : 1;
2174
- const e = [];
2175
- rect(12, 1, 14, 3, "n", e);
2176
- e.push([13, 2, "1"]);
2177
- rect(12 + off, 2 + off, 14 + off, 4 + off, "l", e);
2178
- e.push([13 + off, 3 + off, "m"]);
2179
- if (c === 4 || c === 5) e.push([15, 0, "l"], [11, 6, "l"]);
2180
- return {
2181
- ...BASE,
2182
- ex: 1,
2183
- ey: -1,
2184
- eyes: c >= 4 ? "happy" : "open",
2185
- extras: e
2186
- };
2187
- },
2188
- charting: t => {
2189
- // Three bars grow on the right; pleased when they land.
2190
- const c = t % 16;
2191
- const e = [];
2192
- rect(13, 12, 15, 12, "n", e);
2193
- [3, 5, 4].forEach((target, i) => {
2194
- const h = Math.min(target, Math.floor(c / 2));
2195
- if (h > 0) rect(13 + i, 12 - h, 13 + i, 11, "g", e);
2196
- });
2197
- return {
2198
- ...BASE,
2199
- ex: 1,
2200
- ey: c < 6 ? 1 : 0,
2201
- eyes: c >= 12 ? "happy" : "open",
2202
- extras: e
2203
- };
2204
- },
2205
- // ── Pairing poses ───────────────────────────────────────────────────────
2206
- // Built to hold something that is NOT in the grid — a tool's icon tile,
2207
- // drawn by the scene at OTTO_ANCHORS[state](t). The right-hand prop zone is
2208
- // kept clear on purpose.
2209
- present: t => {
2210
- // A flat hand held out; the object floats above the palm and bobs.
2211
- const c = t % 16;
2212
- const e = [[13, 7, "g"], [14, 7, "g"], [15, 7, "g"], [15, 6, "g"]];
2213
- return {
2214
- ...BASE,
2215
- ex: 1,
2216
- ey: -1,
2217
- eyes: c === 13 ? "closed" : c >= 8 && c < 12 ? "happy" : "open",
2218
- extras: e
2219
- };
2220
- },
2221
- lift: t => {
2222
- // Both arms up; the object rides above the head; a hop every eight ticks.
2223
- const c = t % 16;
2224
- const hop = c % 8 === 2 || c % 8 === 3 ? 1 : 0;
2225
- const e = [[2, 5 - hop, "g"], [1, 4 - hop, "g"], [1, 3 - hop, "g"], [13, 5 - hop, "g"], [14, 4 - hop, "g"], [14, 3 - hop, "g"]];
2226
- return {
2227
- ...BASE,
2228
- y0: 4 - hop,
2229
- eyes: "happy",
2230
- legs: hop ? [1, 1, 1] : [0, 0, 0],
2231
- extras: e
2232
- };
2233
- },
2234
- carry: t => {
2235
- // Arms up, marching; the object rides overhead with the step.
2236
- const b = Math.floor(t / 2) % 2;
2237
- const e = [[2, 5 + b, "g"], [1, 4 + b, "g"], [1, 3 + b, "g"], [13, 5 + b, "g"], [14, 4 + b, "g"], [14, 3 + b, "g"]];
2238
- return {
2239
- ...BASE,
2240
- y0: 4 + b,
2241
- ex: t % 16 < 8 ? 0 : 1,
2242
- legs: walk(t),
2243
- extras: e
2244
- };
2245
- },
2246
- hug: t => {
2247
- // Arms wrapped round the object held against the body; eyes peep over it.
2248
- const c = t % 16;
2249
- const b = Math.floor(c / 8) % 2;
2250
- const e = [[1, 7 + b, "g"], [2, 8 + b, "g"], [14, 7 + b, "g"], [13, 8 + b, "g"]];
2251
- return {
2252
- ...BASE,
2253
- y0: 4 + b,
2254
- ey: -1,
2255
- eyes: c >= 4 && c < 12 ? "happy" : "closed",
2256
- extras: e
2257
- };
2258
- },
2259
- lean: t => {
2260
- // One arm resting on the object standing beside Otto; relaxed.
2261
- const c = t % 24;
2262
- const e = [[13, 5, "g"], [14, 5, "g"], [15, 5, "g"]];
2263
- return {
2264
- ...BASE,
2265
- ex: c < 16 ? 1 : 0,
2266
- eyes: c >= 8 && c < 12 ? "closed" : "open",
2267
- legs: [0, 1, 0],
2268
- extras: e
2269
- };
2270
- },
2271
- point: t => {
2272
- // Arm up and out; the object hangs up-right, bobbing; a hop of delight.
2273
- const c = t % 16;
2274
- const hop = c === 6 || c === 7 ? 1 : 0;
2275
- const e = [[13, 5 - hop, "g"], [14, 4 - hop, "g"], [15, 3 - hop, "g"]];
2276
- return {
2277
- ...BASE,
2278
- y0: 4 - hop,
2279
- ex: 1,
2280
- ey: -1,
2281
- eyes: c >= 6 && c < 10 ? "happy" : "open",
2282
- legs: hop ? [1, 1, 1] : [0, 0, 0],
2283
- extras: e
2284
- };
2285
- },
2286
- static: () => ({
2287
- ...BASE
2288
- })
2289
- };
2290
-
2291
- /** Where a held object sits, in grid cells (may run past the 16×16 grid). */
2292
-
2293
- /**
2294
- * The pairing poses' object anchors at tick `t`, for a 7×7-cell object — a
2295
- * tool icon tile. Bobs follow the pose so the object moves with the hands.
2296
- */
2297
- const OTTO_ANCHORS = exports.OTTO_ANCHORS = {
2298
- present: t => ({
2299
- x: 14,
2300
- y: -1 + Math.floor(t % 16 / 4) % 2,
2301
- over: false
2302
- }),
2303
- lift: t => {
2304
- const c = t % 16;
2305
- const hop = c % 8 === 2 || c % 8 === 3 ? 1 : 0;
2306
- return {
2307
- x: 4,
2308
- y: -5 - hop,
2309
- over: false
2310
- };
2311
- },
2312
- carry: t => ({
2313
- x: 4,
2314
- y: -5 + Math.floor(t / 2) % 2,
2315
- over: false
2316
- }),
2317
- hug: t => ({
2318
- x: 4,
2319
- y: 7 + Math.floor(t % 16 / 8) % 2,
2320
- over: true
2321
- }),
2322
- lean: () => ({
2323
- x: 14,
2324
- y: 6,
2325
- over: false
2326
- }),
2327
- point: t => {
2328
- const c = t % 16;
2329
- const hop = c === 6 || c === 7 ? 1 : 0;
2330
- return {
2331
- x: 15,
2332
- y: -5 - hop + Math.floor(c / 4) % 2,
2333
- over: false
2334
- };
2335
- }
2336
- };
2337
-
2338
- /** The object size OTTO_ANCHORS is drawn for, in cells. */
2339
- const OTTO_ANCHOR_SIZE = exports.OTTO_ANCHOR_SIZE = 7;
2340
- const OTTO_NOTES = exports.OTTO_NOTES = {
2341
- idle: "Bobs one pixel, blinks, glances left and right.",
2342
- thinking: "Looks up; a thought cloud fills with dots.",
2343
- happy: "Two-pixel hop: stretch on takeoff, squash on landing.",
2344
- error: "Lamp goes red, eyes shut, body shakes.",
2345
- sleep: "Sinks a row, lamp dims, z’s drift up.",
2346
- peek: "Submerged to the eyes, scanning.",
2347
- typing: "Laptop with a Buoy screen; tentacles tap.",
2348
- debugging: "Magnifier over one eye, scanning left and right.",
2349
- building: "Hard hat, hammer swings, spark on the hit.",
2350
- carrying: "Phone overhead, marching.",
2351
- pushing: "Shoves a crate, one pixel per heave.",
2352
- sweeping: "Broom, dust puff on each stroke.",
2353
- juggling: "Three blocks: red, orange, purple.",
2354
- wizard: "Purple hat, wand sparkles.",
2355
- conducting: "Arms swing in antiphase, notes rise.",
2356
- beacon: "Lamp emits three expanding rings.",
2357
- notification: "Hop with a blinking exclamation.",
2358
- disconnected: "Lamp dim, looks up at a phone blinking red.",
2359
- dizzy: "X eyes, two stars orbit, body wobbles.",
2360
- overheated: "Melts into a puddle and reforms.",
2361
- confused: "Question mark, head tilt, eyes wander.",
2362
- stare: "Big square eyes. Rare blink.",
2363
- walking: "Crab-walks left and right, eyes lead.",
2364
- goingaway: "Walks off the right edge, returns from the left.",
2365
- eureka: "Bulb appears, lights up with sparks, tiny hops.",
2366
- grooving: "Headphones on, sways with the beat, notes pop.",
2367
- hatmishap: "Wizard hat slips over the eyes; a wave of the wand fixes it.",
2368
- lowbattery: "Slumped, lamp off, red battery blinks. Eyes barely open.",
2369
- wake: "Puddle, wide eyes, springs up, squashes, settles.",
2370
- builder: "Balances a stack of blocks; sweat drop when it wobbles.",
2371
- mini: "Half-size Otto. Big eyes, waving arms, kicking feet.",
2372
- minityping: "Mini Otto typing, data bits float up.",
2373
- happydance: "Arms pump in antiphase, feet shuffle.",
2374
- jumping: "Crouch, four-pixel leap, arms up, land.",
2375
- loading: "Three dots chase around a ring; eyes follow the lead.",
2376
- progress: "A bar fills across the top; a hop when it completes.",
2377
- hourglass: "Sand runs through, the glass lifts and flips.",
2378
- waiting: "Foot taps, checks the wristwatch, dots pile up.",
2379
- syncing: "Two arcs chase each other; lamp pulses in step.",
2380
- downloading: "An arrow drops into the tray, the parcel lands.",
2381
- uploading: "The parcel lifts off the tray and climbs out.",
2382
- connecting: "Signal bars fill one by one, then blink: connected.",
2383
- scanning: "A bright line sweeps down the body with a trail.",
2384
- searching: "Binoculars up, slow sweep left and right.",
2385
- empty: "Peers into an open box, finds nothing, looks back at you.",
2386
- shrug: "Arms up, looks left, looks right, arms down.",
2387
- fishing: "Rod out, bobber bobbing; one tug, one splash.",
2388
- listening: "Hand cupped, sound arcs arriving from the side.",
2389
- tumbleweed: "A tumbleweed rolls past; eyes follow it off the edge.",
2390
- warning: "Holds up a warning sign, lamp blinking.",
2391
- crash: "Burst, smoke, then dazed with X eyes.",
2392
- panic: "Arms flail, sweat flies, lamp strobes.",
2393
- sos: "The lamp flashes S-O-S in morse; arms wave.",
2394
- offline: "A struck-through cloud; slumped, lamp dim.",
2395
- timeout: "A clock ticks round, turns red; a shake.",
2396
- locked: "A padlock: look, strain at it, give up.",
2397
- unlocked: "The shackle pops open; sparkles and a hop.",
2398
- denied: "A red no-entry sign; head shaking.",
2399
- broken: "A crack down the middle; a band-aid goes on.",
2400
- sad: "Sunk a row, lamp dim, a tear drops in.",
2401
- rain: "A rain cloud overhead, drops falling.",
2402
- sick: "A thermometer climbs; wobbling and sweating.",
2403
- flood: "In over the eyes, arms flailing, bubbles rising.",
2404
- bug: "A beetle crawls across the body, then flies off.",
2405
- alarm: "The lamp is a siren: red strobe, sweeping rays.",
2406
- frozen: "Iced over: icicles for legs, snow, shivering.",
2407
- snail: "A snail crosses the foreground, very slowly.",
2408
- angry: "Brows down, lamp red, steam, stomping.",
2409
- ghost: "Grey and translucent, floating, white eyes.",
2410
- nervous: "Eyes darting, sweat, fidgeting feet.",
2411
- puzzled: "A tentacle scratches the head; eyes wander.",
2412
- detective: "Deerstalker hat, magnifying glass on the move.",
2413
- reading: "An open book; eyes run the lines; a page turns.",
2414
- success: "A check mark lands; sparkles, a hop, lamp blinks.",
2415
- celebrate: "Confetti falls, arms up, bouncing.",
2416
- thumbsup: "A fist rises, thumb out; then a wink.",
2417
- party: "Party hat, confetti, a side-to-side dance.",
2418
- trophy: "A cup held overhead, sparkles, a hop.",
2419
- starred: "A star pops in at the top right and twinkles.",
2420
- love: "Hearts float up either side; the body bobs.",
2421
- wave: "One arm up, hand swinging; a smile at the end.",
2422
- bow: "A slow bow: squash forward, eyes shut, back up.",
2423
- cool: "Sunglasses drop into place; a little sway.",
2424
- flexing: "Both arms up in a flex; the biceps pop.",
2425
- zen: "Floating above the water, eyes shut, slow bob.",
2426
- recording: "A red REC dot blinks; eyes slowly sweep the room.",
2427
- paused: "Pause bars overhead; resting, lamp dim, one peek.",
2428
- filtering: "A funnel: mixed bits go in, only orange comes out.",
2429
- pinned: "A pushpin drops in from above and lands.",
2430
- rewind: "Moonwalks left while a clock runs backwards.",
2431
- storing: "Crates stack up on the right, one at a time.",
2432
- printing: "A little printer spools out a strip of log lines.",
2433
- stopwatch: "A stopwatch with a fast hand; speed lines.",
2434
- spotlight: "The lamp throws a beam that sweeps left, up, right.",
2435
- keys: "A keyring held out; the keys jingle.",
2436
- map: "A folded map: dotted route, red pin; looks around.",
2437
- photo: "A camera held up; flash; a print pops out.",
2438
- painting: "A canvas on the right; strokes appear.",
2439
- disguise: "Groucho glasses, nose and moustache; sly glances.",
2440
- pro: "A crown in place of the lamp, jewels, sparkles.",
2441
- talking: "A speech bubble with typing dots; lamp pulses.",
2442
- handshake: "A hand arrives from the right; they shake.",
2443
- robot: "A small robot friend: antenna blinking, eyes flickering.",
2444
- plug: "A plug slides in and connects; the lamp comes on.",
2445
- gift: "A wrapped gift bounces; the lid lifts with a sparkle.",
2446
- action: "A clapperboard claps shut.",
2447
- guard: "A shield up; a red bolt sparks off it and bounces away.",
2448
- coffee: "A mug with steam; a sip with eyes shut.",
2449
- swimming: "In to the shoulders, alternating strokes with splashes.",
2450
- diving: "Sinks out of sight, bubbles rise, comes back dripping.",
2451
- balloon: "A balloon lifts Otto clear of the water; a splash on release.",
2452
- landing: "Drops in from above, lands with a squash and a splash.",
2453
- spinning: "A full turn: front, three-quarter, side, back and round.",
2454
- bubbles: "Blows through a bubble wand; bubbles drift up.",
2455
- trash: "Bits fly into a bin, the lid flaps, a puff when done.",
2456
- saved: "A floppy disk pops in; a hop and a sparkle.",
2457
- copied: "One sheet slides out from behind another.",
2458
- charting: "Three bars grow on the right; pleased when they land.",
2459
- present: "A flat hand held out; the object floats above the palm.",
2460
- lift: "Both arms up; the object rides overhead; a hop.",
2461
- carry: "Arms up, marching; the object rides with the step.",
2462
- hug: "Arms wrapped round the object; eyes peep over it.",
2463
- lean: "One arm resting on the object beside Otto; relaxed.",
2464
- point: "Arm up and out; the object hangs up-right, bobbing.",
2465
- static: "Base pose, no motion. For favicons and stills."
2466
- };
2467
-
2468
- /** Every animated state, in the mockup's order (`static` excluded). */
2469
- const OTTO_STATE_NAMES = exports.OTTO_STATE_NAMES = Object.keys(OTTO_STATES).filter(n => n !== "static");
2470
- /**
2471
- * The states by job. Every animated state is in exactly one group; a tool
2472
- * picks from the group that matches the moment (an empty list shows an
2473
- * `empty` group state, a failed request a `trouble` one, and so on).
2474
- */
2475
- const OTTO_GROUPS = exports.OTTO_GROUPS = [{
2476
- id: "loading",
2477
- title: "Loading & progress",
2478
- blurb: "Something is on its way. Spinners, bars, connecting, scanning, waiting.",
2479
- states: ["loading", "progress", "hourglass", "waiting", "syncing", "downloading", "uploading", "connecting", "scanning", "searching", "fishing"]
2480
- }, {
2481
- id: "empty",
2482
- title: "Empty & unknown",
2483
- blurb: "Nothing here yet, nothing found, or no idea what this is.",
2484
- states: ["empty", "shrug", "tumbleweed", "confused", "puzzled"]
2485
- }, {
2486
- id: "trouble",
2487
- title: "Errors & trouble",
2488
- blurb: "Failures, warnings, disconnects, limits — from a blip to a crash.",
2489
- states: ["error", "warning", "crash", "panic", "sos", "alarm", "offline", "disconnected", "timeout", "locked", "denied", "broken", "sad", "rain", "sick", "overheated", "dizzy", "flood", "bug", "frozen", "snail", "angry", "ghost", "nervous", "lowbattery"]
2490
- }, {
2491
- id: "success",
2492
- title: "Success & celebration",
2493
- blurb: "It worked. Confirmations, unlocks, milestones, thanks.",
2494
- states: ["happy", "eureka", "success", "celebrate", "thumbsup", "party", "trophy", "starred", "love", "unlocked", "notification", "beacon", "cool", "flexing", "pro", "gift"]
2495
- }, {
2496
- id: "working",
2497
- title: "Working & tool moments",
2498
- blurb: "Busy doing the job: capturing, filtering, saving, inspecting, talking.",
2499
- states: ["thinking", "typing", "debugging", "building", "carrying", "pushing", "sweeping", "detective", "reading", "map", "painting", "photo", "printing", "storing", "charting", "stopwatch", "spotlight", "keys", "filtering", "talking", "listening", "recording", "paused", "rewind", "trash", "disguise", "guard", "action", "robot", "plug", "handshake", "saved", "copied", "pinned"]
2500
- }, {
2501
- id: "personality",
2502
- title: "Idle, moves & personality",
2503
- blurb: "Otto being Otto: idling, wandering, swimming, dancing, showing off.",
2504
- states: ["idle", "stare", "mini", "minityping", "walking", "goingaway", "peek", "sleep", "wake", "jumping", "spinning", "swimming", "diving", "balloon", "landing", "bubbles", "zen", "bow", "wave", "coffee", "grooving", "conducting", "juggling", "wizard", "hatmishap", "builder", "happydance"]
2505
- }, {
2506
- id: "pairing",
2507
- title: "Pairing poses",
2508
- blurb: "Built to hold a tool's icon tile — the object is drawn by the scene at OTTO_ANCHORS.",
2509
- states: ["present", "lift", "carry", "hug", "lean", "point"]
2510
- }];
2511
-
2512
- /** When to reach for each state — the moment in a tool it was drawn for. */
2513
- const OTTO_USES = exports.OTTO_USES = {
2514
- idle: "Default resting state; nothing to report.",
2515
- thinking: "Working something out; Ask Buoy composing.",
2516
- happy: "A quick positive beat after any action.",
2517
- error: "A request or action failed.",
2518
- sleep: "Tool idle for a long time; capture off overnight.",
2519
- peek: "Minimized or collapsed; still watching.",
2520
- typing: "Ask Buoy typing a reply; code being written.",
2521
- debugging: "Inspecting a detail view; stepping through.",
2522
- building: "Bundling, compiling, a build in progress.",
2523
- carrying: "Moving data between tools; exporting.",
2524
- pushing: "A heavy job: large payload, slow migration.",
2525
- sweeping: "Clearing a list; cache cleanup done.",
2526
- juggling: "Several stores or queries updating at once.",
2527
- wizard: "A setup wizard; magic done on your behalf.",
2528
- conducting: "Orchestrating a flow or scenario.",
2529
- beacon: "Broadcasting: broker up, dashboard discoverable.",
2530
- notification: "A new item arrived; badge count went up.",
2531
- disconnected: "Device or dashboard connection dropped.",
2532
- dizzy: "Too many re-renders; a render storm.",
2533
- overheated: "CPU or thermal pressure; perf meltdown.",
2534
- confused: "Unknown or unparseable data.",
2535
- stare: "Watching for a specific event; recording armed.",
2536
- walking: "Navigating between routes.",
2537
- goingaway: "Leaving a screen; a tool closing.",
2538
- eureka: "Root cause found; a diff that explains it.",
2539
- grooving: "Everything healthy; nothing to do but vibe.",
2540
- hatmishap: "A small recoverable slip; retry worked.",
2541
- lowbattery: "Device battery low; power-saving mode.",
2542
- wake: "Tool re-opened; capture resumed.",
2543
- builder: "Assembling a state tree or fixture.",
2544
- mini: "Compact or inline placements.",
2545
- minityping: "A compact typing indicator.",
2546
- happydance: "A milestone: all tests green, release done.",
2547
- jumping: "Jump to a route, a log line, a snapshot.",
2548
- loading: "Generic indeterminate loading.",
2549
- progress: "Determinate progress: download, batch, upload.",
2550
- hourglass: "Waiting on a timer; a scheduled retry.",
2551
- waiting: "Waiting for a device, the first event, a reply.",
2552
- syncing: "Syncing with the desktop dashboard or broker.",
2553
- downloading: "Pulling a snapshot, an update, a payload.",
2554
- uploading: "Sending a report, a snapshot, feedback.",
2555
- connecting: "Connecting to a device or broker.",
2556
- scanning: "Scanning for targets, keys, assets, fibers.",
2557
- searching: "A search running; filtering a long list.",
2558
- fishing: "Capture on, nothing captured yet.",
2559
- empty: "An empty list: no requests, no logs, no keys.",
2560
- shrug: "No result and no explanation available.",
2561
- tumbleweed: "Deliberately empty; nothing happened for a while.",
2562
- puzzled: "Unexpected shape; needs a second look.",
2563
- warning: "A warning: deprecated, risky, near a limit.",
2564
- crash: "The app crashed; a fatal was captured.",
2565
- panic: "Many errors at once; an error cascade.",
2566
- sos: "Critical: the app cannot continue.",
2567
- alarm: "An alert rule fired; attention now.",
2568
- offline: "No network; device offline.",
2569
- timeout: "A request or connection timed out.",
2570
- locked: "A Pro feature; a locked setting.",
2571
- denied: "Permission denied; blocked by policy.",
2572
- broken: "Corrupted data; a broken persisted value.",
2573
- sad: "Nothing matched; a failed search.",
2574
- rain: "A bad run: errors piling up.",
2575
- sick: "Unhealthy config; env check failing.",
2576
- flood: "Buffer full; too many events to keep up.",
2577
- bug: "A bug was found (or is being reported).",
2578
- frozen: "The UI thread froze; a hung frame.",
2579
- snail: "Slow: a long request, a slow render.",
2580
- angry: "Rate limited, rejected, forbidden.",
2581
- ghost: "Stale or detached: an unmounted component, an old snapshot.",
2582
- nervous: "A risky action pending confirmation.",
2583
- detective: "Investigating; root-cause analysis.",
2584
- reading: "Reading docs or a long log.",
2585
- success: "Action completed; a rule saved, a replay done.",
2586
- celebrate: "A big success: first capture, setup complete.",
2587
- thumbsup: "Approved; looks good; confirmation received.",
2588
- party: "Release shipped; a version milestone.",
2589
- trophy: "Best benchmark yet; a personal record.",
2590
- starred: "Pinned, favourited, starred.",
2591
- love: "Thanks and delight; feedback sent.",
2592
- unlocked: "Pro unlocked; license activated.",
2593
- cool: "Perfect score; zero warnings.",
2594
- flexing: "Fast: a great perf result.",
2595
- zen: "All quiet; nothing needs attention.",
2596
- pro: "Pro plan active.",
2597
- gift: "New version or feature available.",
2598
- map: "Route inspector; where am I in the navigator.",
2599
- photo: "Screenshot taken; image captured.",
2600
- painting: "Assets and design overlays; theming.",
2601
- printing: "Console streaming; logs arriving.",
2602
- storing: "Saving to storage; persisting.",
2603
- charting: "Metrics building up; perf charts.",
2604
- stopwatch: "Benchmark running; timing a request.",
2605
- spotlight: "Highlighting renders; spotlight on a component.",
2606
- keys: "Environment variables and secrets.",
2607
- filtering: "Filters active; a subset shown.",
2608
- talking: "Ask Buoy answering; a message in flight.",
2609
- listening: "Listening for events; waiting for input.",
2610
- recording: "Capture on; recording a session.",
2611
- paused: "Capture paused.",
2612
- rewind: "Time Machine: stepping back through snapshots.",
2613
- trash: "Cleared: list emptied, cache purged.",
2614
- disguise: "Impersonating another user.",
2615
- guard: "Sentry or a guard rail caught something.",
2616
- action: "A scenario or flow started.",
2617
- robot: "The MCP agent is driving the tools.",
2618
- plug: "Device connected; plugin installed.",
2619
- handshake: "Paired with the desktop dashboard.",
2620
- saved: "Saved: request, snapshot, rule.",
2621
- copied: "Copied to clipboard.",
2622
- pinned: "Item pinned; survives clears.",
2623
- spinning: "Refreshing; reloading the app.",
2624
- swimming: "Making progress through a long job.",
2625
- diving: "Drilling into a detail or nested value.",
2626
- balloon: "Upgrading; a plan change in progress.",
2627
- landing: "Tool mounted; first open.",
2628
- bubbles: "A light idle for empty side panels.",
2629
- bow: "Thank you; a graceful exit.",
2630
- wave: "Welcome; onboarding; first run.",
2631
- coffee: "A long build; take a break.",
2632
- present: "Presenting a tool: onboarding, a tool's intro card.",
2633
- lift: "Showing off a tool: a feature announcement.",
2634
- carry: "Bringing a tool along: install, add-to-dial.",
2635
- hug: "A favourite tool: pinned, most used.",
2636
- lean: "A tool at rest: its idle or settings screen.",
2637
- point: "Pointing at a tool: a hint, a next step.",
2638
- static: "Favicons, stills, icons."
2639
- };
2640
-
2641
- /** Cycle lengths that differ from the 16-tick default (used by the reel). */
2642
- const OTTO_CYCLE = {
2643
- progress: 32,
2644
- hourglass: 20,
2645
- fishing: 32,
2646
- tumbleweed: 28,
2647
- crash: 20,
2648
- sos: 34,
2649
- locked: 20,
2650
- unlocked: 20,
2651
- broken: 24,
2652
- snail: 36,
2653
- reading: 24,
2654
- storing: 24,
2655
- diving: 24,
2656
- balloon: 24,
2657
- swimming: 8,
2658
- scanning: 14,
2659
- connecting: 14,
2660
- loading: 10,
2661
- syncing: 10,
2662
- downloading: 12,
2663
- uploading: 12,
2664
- alarm: 8,
2665
- flood: 8,
2666
- panic: 8,
2667
- nervous: 8,
2668
- keys: 8,
2669
- flexing: 8
2670
- };
2671
-
2672
- /** The demo reel: [state, frames]. */
2673
- const OTTO_REEL = exports.OTTO_REEL = [["idle", 30], ["thinking", 20], ["typing", 20], ["happy", 14], ["debugging", 18], ["idle", 14], ["building", 16], ["carrying", 14], ["pushing", 14], ["sweeping", 14], ["juggling", 16], ["wizard", 14], ["conducting", 14], ["beacon", 14], ["notification", 16], ["error", 12], ["disconnected", 14], ["dizzy", 14], ["overheated", 24], ["confused", 18], ["stare", 20], ["walking", 32], ["eureka", 24], ["grooving", 16], ["hatmishap", 32], ["builder", 16], ["happydance", 12], ["jumping", 16], ["mini", 16], ["minityping", 12], ["lowbattery", 24], ["sleep", 24], ["wake", 30], ["peek", 18], ["goingaway", 26],
2674
- // Everything after the original set, one full cycle each.
2675
- ...["loading", "progress", "hourglass", "waiting", "syncing", "downloading", "uploading", "connecting", "scanning", "searching", "fishing", "empty", "shrug", "tumbleweed", "puzzled", "warning", "crash", "panic", "sos", "alarm", "offline", "timeout", "locked", "unlocked", "denied", "broken", "sad", "rain", "sick", "flood", "bug", "frozen", "snail", "angry", "ghost", "nervous", "detective", "reading", "success", "celebrate", "thumbsup", "party", "trophy", "starred", "love", "wave", "bow", "cool", "flexing", "zen", "recording", "paused", "filtering", "pinned", "rewind", "storing", "printing", "stopwatch", "spotlight", "keys", "map", "photo", "painting", "disguise", "pro", "talking", "handshake", "robot", "plug", "gift", "action", "guard", "coffee", "swimming", "diving", "balloon", "landing", "spinning", "bubbles", "trash", "saved", "copied", "charting", "present", "lift", "carry", "hug", "lean", "point"].map(s => [s, OTTO_CYCLE[s] ?? 16])];
2676
- const REEL_LENGTH = OTTO_REEL.reduce((a, s) => a + s[1], 0);
2677
-
2678
- /** Which reel state plays at tick `t`, and how far into it we are. */
2679
- function ottoReel(t) {
2680
- let c = (t % REEL_LENGTH + REEL_LENGTH) % REEL_LENGTH;
2681
- for (const [state, len] of OTTO_REEL) {
2682
- if (c < len) return {
2683
- state,
2684
- local: c
2685
- };
2686
- c -= len;
2687
- }
2688
- return {
2689
- state: "idle",
2690
- local: 0
2691
- };
2692
- }
2693
-
2694
- /**
2695
- * One frame of one state as a 16×16 grid of palette keys (`.` = transparent).
2696
- * Look colours up in `OTTO_PALETTE`.
2697
- */
2698
- function renderOttoFrame(state, t, opts = {}) {
2699
- const local = Math.max(0, Math.floor(t));
2700
- const pose = OTTO_STATES[state](local);
2701
- return compose(draw(pose), local, {
2702
- water: opts.water ?? true,
2703
- keyline: opts.keyline ?? true,
2704
- submerged: !!pose.submerged
2705
- });
2706
- }
2707
-
2708
- /** A horizontal run of one colour — what the renderer actually draws. */
2709
-
2710
- /**
2711
- * Run-length encode a frame into coloured spans, skipping transparency. A
2712
- * 16×16 frame is ~256 cells but only ~40–70 runs, which is what keeps a
2713
- * screen full of animating sprites cheap on Fabric.
2714
- */
2715
- function ottoRuns(grid) {
2716
- const runs = [];
2717
- for (let y = 0; y < grid.length; y++) {
2718
- const row = grid[y];
2719
- let x = 0;
2720
- while (x < row.length) {
2721
- const key = row[x];
2722
- let w = 1;
2723
- while (x + w < row.length && row[x + w] === key) w++;
2724
- if (key !== ".") {
2725
- const color = OTTO_PALETTE[key];
2726
- if (color) runs.push({
2727
- x,
2728
- y,
2729
- w,
2730
- color
2731
- });
2732
- }
2733
- x += w;
2734
- }
2735
- }
2736
- return runs;
2737
- }
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.OTTO_USES=exports.OTTO_STATE_NAMES=exports.OTTO_STATES=exports.OTTO_REEL=exports.OTTO_PALETTE=exports.OTTO_NOTES=exports.OTTO_GROUPS=exports.OTTO_GRID=exports.OTTO_ANCHOR_SIZE=exports.OTTO_ANCHORS=void 0;exports.ottoReel=ottoReel;exports.ottoRuns=ottoRuns;exports.ottoWaterRows=ottoWaterRows;exports.renderOttoFrame=renderOttoFrame;const OTTO_GRID=exports.OTTO_GRID=16;const OTTO_PALETTE=exports.OTTO_PALETTE={g:"#20C997",s:"#1BAB80",d:"#0D9668",h:"#3DD9A8",k:"#000000",a:"#FFA94D",A:"#6B4520",r:"#FF3B30",R:"#5A1712",p:"#9B70E0",w:"#0A1A16",W:"#0F2A22",n:"#9BA1A6",m:"#636366",l:"#ECEDEE","1":"#2A2A2E"};const BASE={x0:3,y0:4,w:10,h:7,eyes:"open",lamp:"a",legs:[0,0,0]};const TYPING_KEYBOARD=["nnnnnnnnnn","lmlmlmlmlm","mmmmmmmmmm"];const BODY_KEYS="gsdhaArRk";function walk(t){return t%2?[0,1,0]:[1,0,1]}function rect(t,e,n,s,o,r){for(let a=e;a<=s;a++)for(let i=t;i<=n;i++)r.push([i,a,o]);return r}function pt([t,e],n){return[t,e,n]}const RING=[[13,0],[14,0],[15,1],[15,2],[15,3],[14,4],[13,4],[12,3],[12,2],[12,1]];function arrowDown(t,e,n,s){s.push([t,e,n],[t,e+1,n],[t-1,e+2,n],[t,e+2,n],[t+1,e+2,n],[t,e+3,n]);return s}function arrowUp(t,e,n,s){s.push([t,e,n],[t-1,e+1,n],[t,e+1,n],[t+1,e+1,n],[t,e+2,n],[t,e+3,n]);return s}const SOS=[1,0,1,0,1,0,0,0,1,1,1,0,1,1,1,0,1,1,1,0,0,0,1,0,1,0,1,0,0,0,0,0,0,0];function padlock(t,e){rect(13,4,15,6,"a",e);e.push([14,5,"k"],[14,6,"k"]);if(t)e.push([13,1,"n"],[14,1,"n"],[15,1,"n"],[13,2,"n"],[13,3,"n"]);else e.push([13,2,"n"],[14,2,"n"],[15,2,"n"],[13,3,"n"],[15,3,"n"]);return e}function draw(t){const e=OTTO_GRID;const n=OTTO_GRID;const s=Array.from({length:n},()=>Array(e).fill("."));const o=t.dx||0;const r=(l,c,h)=>{l+=o;if(l>=0&&l<e&&c>=0&&c<n)s[c][l]=h};const{x0:a,y0:i,w:u,h:y}=t;const d=a+u-1;const g=i+y-1;for(let l=i;l<=g;l++){for(let c=a;c<=d;c++){if((c===a||c===d)&&(l===i||l===g))continue;r(c,l,l===i?"h":l===g||c===d?"s":"g")}}if(t.lamp){const l=a+Math.floor(u/2)-1;r(l,i-2,t.lamp);r(l+1,i-2,t.lamp);for(let c=l-1;c<=l+2;c++)r(c,i-1,"d")}const f=t.ex||0;const p=i+2+(t.ey||0);for(const l of[a+2+f,d-3+f]){if(t.eyes==="open"){r(l,p,"k");r(l+1,p,"k");r(l,p+1,"k");r(l+1,p+1,"k")}else if(t.eyes==="closed"){r(l,p+1,"k");r(l+1,p+1,"k")}else if(t.eyes==="happy"){r(l,p+1,"k");r(l+1,p,"k");r(l+2,p+1,"k")}else if(t.eyes==="x"){r(l,p,"k");r(l+2,p,"k");r(l+1,p+1,"k");r(l,p+2,"k");r(l+2,p+2,"k")}else if(t.eyes==="big"){for(let c=0;c<3;c++)for(let h=0;h<3;h++)r(l+h,p+c,"k")}}if(t.legs){const l=a+Math.floor((u-8)/2);t.legs.forEach((c,h)=>{const m=l+h*3;r(m,g+1,c?"s":"g");r(m+1,g+1,c?"s":"g");if(!c){r(m,g+2,"s");r(m+1,g+2,"s")}})}(t.extras||[]).forEach(([l,c,h])=>r(l,c,h));return s}function wave(t,e,n){return((t-Math.floor(n/2)+e*5)%7+7)%7<2?"W":"w"}function ottoWaterRows(t){const e=[];for(let n=13;n<OTTO_GRID;n++){const s=[];for(let o=0;o<OTTO_GRID;o++)s.push(wave(o,n,t));e.push(s)}return e}const NEIGHBOURS=[[0,1],[0,-1],[1,0],[-1,0]];function compose(t,e,n){const s=OTTO_GRID;const o=OTTO_GRID;const r=t.map(a=>a.slice());for(let a=0;a<o;a++){for(let i=0;i<s;i++){const u=a>=13;if(u&&n.submerged){r[a][i]=n.water?wave(i,a,e):".";continue}if(t[a][i]!==".")continue;const y=n.keyline&&NEIGHBOURS.some(([d,g])=>{const f=a+d;const p=i+g;return f>=0&&f<o&&p>=0&&p<s&&BODY_KEYS.includes(t[f][p])});if(y)r[a][i]="k";else if(u&&n.water)r[a][i]=wave(i,a,e)}}return r}const OTTO_STATES=exports.OTTO_STATES={idle:t=>{const e=t%48;const n=e%8>=4?1:0;const s=e%16===13||e===47;const o=e>=20&&e<=26?-1:e>=32&&e<=38?1:0;return{...BASE,y0:4+n,eyes:s?"closed":"open",ex:o,legs:walk(Math.floor(t/2))}},thinking:t=>{const e=t%10;const n=[];if(e>=1)n.push([13,5,"n"]);if(e>=2)n.push([14,3,"n"]);if(e>=3){rect(11,0,14,0,"l",n);rect(10,1,15,1,"l",n);rect(11,2,14,2,"l",n)}for(let s=0;s<Math.min(3,Math.max(0,e-4));s++)n.push([11+s*2,1,"m"]);return{...BASE,ex:1,ey:-1,lamp:t%4<2?"a":"A",extras:n}},happy:t=>{const e=t%12;const n=[0,1,2,2,1,0,0,0,0,0,0,0][e];let s={...BASE,eyes:"happy",legs:walk(t),y0:4-n};if(e===1)s={...s,x0:4,w:8,h:8,y0:2};if(e===5||e===6)s={...s,x0:2,w:12,h:6,y0:5};return s},error:t=>({...BASE,lamp:t%2?"r":"R",dx:[0,1,0,-1][t%4],eyes:"closed"}),sleep:t=>{const e=Math.floor(t/3)%4;const n=(s,o)=>[[s,o],[s+1,o],[s+2,o],[s+3,o],[s+2,o+1],[s+1,o+2],[s,o+3],[s+1,o+3],[s+2,o+3],[s+3,o+3]].map(([r,a])=>[r,a,"n"]);return{...BASE,y0:5+Math.floor(t/8)%2,eyes:"closed",lamp:"A",extras:n(12,6-e*2)}},peek:t=>({...BASE,submerged:true,y0:9+Math.floor(t/4)%2,ex:[-1,0,1,0][Math.floor(t/6)%4],legs:null}),typing:t=>{const e=[];TYPING_KEYBOARD.forEach((s,o)=>{for(let r=0;r<s.length;r++)e.push([3+r,10+o,s[r]])});const n=t%2;e.push([2,10+n,"g"],[13,11-n,"g"]);return{...BASE,eyes:t%12===11?"closed":"open",legs:null,extras:e}},debugging:t=>{const e=Math.floor(t/4)%2?0:-1;const n=[];[[10,3],[11,3],[12,3],[9,4],[13,4],[9,5],[13,5],[9,6],[13,6],[10,7],[11,7],[12,7]].forEach(([s,o])=>n.push([s+e,o,"n"]));rect(10+e,4,12+e,4,"l",n);rect(10+e,5,12+e,6,"k",n);n.push([14+e,7,"m"],[15+e,8,"m"]);return{...BASE,extras:n}},building:t=>{const e=[];rect(5,1,10,1,"a",e);rect(4,2,11,2,"a",e);rect(2,3,13,3,"A",e);rect(13,11,15,12,"m",e);if(t%4<2)e.push([13,6,"g"],[14,5,"m"],[14,4,"m"],[13,2,"n"],[14,2,"n"],[15,2,"n"]);else e.push([13,8,"g"],[14,9,"m"],[15,8,"n"],[15,9,"n"],[15,10,"n"],[12,10,"a"]);return{...BASE,lamp:null,eyes:t%10===9?"closed":"open",extras:e}},carrying:t=>{const e=t%4<2?0:1;const n=[];rect(5,e,10,e,"n",n);rect(5,3+e,10,3+e,"n",n);rect(5,1+e,5,2+e,"n",n);rect(10,1+e,10,2+e,"n",n);rect(6,1+e,9,2+e,"g",n);rect(4,2+e,4,3+e,"g",n);rect(11,2+e,11,3+e,"g",n);return{...BASE,y0:4+e,lamp:null,ey:-1,legs:walk(t),extras:n}},pushing:t=>{const e=[];for(let n=5;n<=12;n++){for(let s=11;s<=15;s++){e.push([s,n,n===5||n===12||s===11||s===15?"n":s===13?"l":"m"])}}e.push([10,7,"g"],[10,8,"g"]);return{...BASE,x0:0,dx:t%4<2?0:1,ex:1,legs:walk(t),extras:e}},sweeping:t=>{const e=t%4<2?0:1;const n=[];rect(13,3,13,10,"m",n);rect(12+e,11,15+e,12,"a",n);n.push([13,6,"g"]);if(e)n.push([15,10,"m"],[11,12,"m"]);return{...BASE,ex:1,eyes:t%12===11?"closed":"open",extras:n}},juggling:t=>{const e=[];[[2,"r"],[7,"a"],[12,"p"]].forEach(([n,s],o)=>{const r=[0,1,2,2,1,0][(t+o*2)%6];const a=2-r;rect(n,a,n+1,a+1,s,e)});e.push([2,4+t%2,"g"],[13,5-t%2,"g"]);return{...BASE,lamp:null,ey:-1,ex:[-1,0,1,0][Math.floor(t/2)%4],extras:e}},wizard:t=>{const e=[];rect(7,0,8,0,"p",e);rect(6,1,9,1,"p",e);rect(5,2,10,2,"p",e);rect(3,3,12,3,"p",e);e.push([8,1,"a"]);e.push([13,5,"g"],[14,4,"m"],[15,3,"m"]);const n=t%4;if(n===1)e.push([15,1,"a"]);if(n===2)e.push([14,1,"a"],[15,0,"a"],[15,2,"a"]);if(n===3)e.push([13,0,"a"]);return{...BASE,lamp:null,eyes:t%12===11?"closed":"open",extras:e}},conducting:t=>{const e=t%2;const n=Math.floor(t/2)%4;const s=[[1,4+e*3,"g"],[2,4+e*3,"g"],[13,7-e*3,"g"],[14,7-e*3,"g"],[15,6-e*3,"m"],[2,3-n,"n"],[3,2-n,"n"]];return{...BASE,eyes:"happy",extras:s}},beacon:t=>{const e=t%6;const n=[[],[[5,3],[10,3],[5,2],[10,2]],[[3,3],[12,3],[3,2],[12,2],[4,1],[11,1],[5,0],[10,0]],[[1,2],[14,2],[1,1],[14,1],[2,0],[13,0]],[],[]];return{...BASE,lamp:e<4?"a":"A",ey:-1,extras:n[e].map(([s,o])=>[s,o,"a"])}},notification:t=>{const e=t%16;const n=[0,0,0,0,1,2,2,1,0,0,0,0,0,0,0,0][e];const s=e>=3&&e<=10;const o=s?[...rect(14,0,15,2,"a",[]),[14,4,"a"],[15,4,"a"]]:[];return{...BASE,y0:4-n,lamp:s&&e%2?"A":"a",legs:n?[1,1,1]:[0,0,0],extras:o}},disconnected:t=>{const e=t%4<2;const n=[];for(let s=0;s<=4;s++){n.push([12,s,"n"],[14,s,"n"],[13,s,s===0||s===4?"n":e?"r":"1"])}return{...BASE,y0:5,lamp:"A",ex:1,ey:-1,extras:n}},dizzy:t=>{const e=[[1,2],[4,0],[11,0],[14,2]];const n=[e[t%4],e[(t+2)%4]].map(([s,o])=>[s,o,"a"]);return{...BASE,eyes:"x",lamp:"A",dx:[0,1,0,-1][t%4],extras:n}},overheated:t=>{const e=[0,0,0,1,2,3,3,3,3,2,1,0][t%12];const n=[{x0:3,y0:4,w:10,h:7,ey:0,legs:[0,0,0]},{x0:3,y0:6,w:10,h:5,ey:0,legs:[0,0,0]},{x0:2,y0:8,w:12,h:3,ey:-1,legs:null},{x0:1,y0:10,w:14,h:2,ey:-2,legs:null}];return{...BASE,...n[e],eyes:e>=2?"closed":"open",lamp:e>=2?"A":t%2?"a":"A",extras:e>=1?[[14,2+t%3,"l"]]:[]}},confused:t=>{const e=t%18;const n=e>=4?[[12,0,"n"],[13,0,"n"],[14,0,"n"],[14,1,"n"],[13,2,"n"],[14,2,"n"],[13,4,"n"]]:[];return{...BASE,ex:[1,1,0,-1,-1,0][Math.floor(e/3)%6],ey:-1,dx:e>=9?-1:0,extras:n}},stare:t=>({...BASE,eyes:t%20===19?"closed":"big",ex:[0,0,0,0,0,0,0,1,1,0,0,0,-1,-1,0,0,0,0,0,0][t%20]}),walking:t=>{const e=t%16;const n=e<8?e-4:11-e;return{...BASE,dx:n,ex:e<8?1:-1,legs:walk(t)}},goingaway:t=>({...BASE,dx:t%26-6,ex:1,legs:walk(t)}),eureka:t=>{const e=t%24;const n=[];if(e>=3&&e<20){const s=e>=6;rect(12,0,13,0,s?"a":"A",n);rect(11,1,14,2,s?"a":"A",n);rect(12,3,13,3,"m",n);rect(12,4,13,4,"n",n);if(s)n.push([12,1,"l"]);if(s&&e<14&&e%2===0)n.push([10,0,"l"],[15,0,"l"],[10,4,"l"],[15,4,"l"]);n.push([13,6,"g"],[14,5,"g"])}return{...BASE,lamp:e>=6&&e<20?"a":"A",eyes:e>=8&&e<20?"happy":e===22?"closed":"open",ex:e>=3&&e<8?1:0,ey:e>=3&&e<8?-1:0,y0:e>=8&&e<20&&e%4<2?3:4,extras:n}},grooving:t=>{const e=t%4;const n=[0,1,0,-1][e];const s=[];rect(4,1,11,1,"p",s);rect(3,2,3,3,"p",s);rect(12,2,12,3,"p",s);rect(1,6,2,8,"p",s);rect(13,6,14,8,"p",s);s.push([2,7,"1"],[13,7,"1"]);if(e===1)s.push([0,3,"a"],[1,2,"a"],[1,3,"a"]);if(e===3)s.push([15,3,"a"],[14,2,"a"],[14,3,"a"]);return{...BASE,lamp:null,dx:n,eyes:"happy",legs:e%2?[1,0,1]:[0,1,0],y0:e%2?4:5,extras:s}},hatmishap:t=>{const e=t%32;const n=[];const s=e>=10&&e<20?2:e>=20&&e<22?1:0;const o=e>=10&&e<20?1:0;const r=s;const a=(i,u,y)=>n.push([i+o,u+r,y]);a(7,0,"p");a(8,0,"p");for(let i=6;i<=9;i++)a(i,1,"p");for(let i=5;i<=10;i++)a(i,2,"p");for(let i=3;i<=12;i++)a(i,3,"p");a(8,1,"a");a(6,2,"a");a(10,3,"a");if(s===2)for(let i=4;i<=11;i++)a(i,4,"p");if(e>=14&&e<22){n.push([13,5,"g"],[14,4,"g"],[14,3,"g"]);if(e%2)n.push([15,1,"a"],[14,0,"l"])}return{...BASE,lamp:null,eyes:s===2?"closed":e>=22&&e<24?"happy":"open",ex:e<10?1:0,legs:e<8?walk(t):[0,0,0],dx:e<8?e<4?e-2:5-e:0,extras:n}},lowbattery:t=>{const e=[];rect(12,1,15,1,"r",e);rect(12,6,15,6,"r",e);e.push([12,2,"r"],[12,3,"r"],[12,4,"r"],[12,5,"r"],[15,2,"r"],[15,3,"r"],[15,4,"r"],[15,5,"r"],[13,0,"r"],[14,0,"r"]);if(t%6<3)rect(13,5,14,5,"r",e);const n=t%24>=18&&t%24<21;return{...BASE,y0:6,h:6,x0:2,w:12,lamp:"A",eyes:n?"open":"closed",ey:n?1:0,legs:null,extras:e}},wake:t=>{const e=t%30;if(e<8)return{...BASE,x0:2,w:12,y0:7,h:5,lamp:"A",eyes:e>=6?"big":"closed",ey:0,legs:null};if(e<10)return{...BASE,x0:4,w:8,y0:0,h:9,lamp:null,eyes:"big",ey:1,legs:[1,1,1]};if(e<12)return{...BASE,y0:2,eyes:"big",lamp:"a",legs:[1,1,1]};if(e<14)return{...BASE,x0:2,w:12,y0:5,h:6,eyes:"open",lamp:"a"};return{...BASE,eyes:e===20||e===21?"closed":"open",legs:[0,0,0]}},builder:t=>{const e=[0,1,0,-1][Math.floor(t/2)%4];const n=[];rect(5,2,10,3,"n",n);n.push([5,3,"m"],[10,3,"m"]);rect(4+e,0,9+e,1,"p",n);n.push([4+e,1,"1"]);if(Math.floor(t/2)%4===3&&t%2)n.push([1,5,"l"],[0,4,"l"]);const s=e?[[1,5,"g"],[14,7,"g"]]:[[1,6,"g"],[14,6,"g"]];return{...BASE,lamp:null,ex:e,ey:-1,legs:walk(t),extras:[...n,...s]}},mini:t=>{const e=t%32;const n=e<8?0:e<16?-1:e<24?1:0;const s=e>=24&&e<28?-1:0;return{...BASE,x0:4,w:8,y0:6+Math.floor(t/4)%2,h:5,lamp:"a",eyes:"big",ex:n,ey:s,legs:[Math.floor(t/2)%2,0,(Math.floor(t/2)+1)%2],extras:[[2,8+t%2,"g"],[13,8+(t+1)%2,"g"]]}},minityping:t=>{const e=[[2,8+t%2,"g"],[13,8+(t+1)%2,"g"]];const n=t%6;e.push([7+t%3,5-n,"p"]);return{...BASE,x0:4,w:8,y0:7-t%2,h:5,lamp:null,legs:[0,0,0],extras:e}},happydance:t=>{const e=t%4;const n=[[1,5+[0,1,2,1][e],"g"],[14,5+[2,1,0,1][e],"g"]];return{...BASE,eyes:e%2?"happy":"open",legs:e%2?[1,0,1]:[0,1,0],extras:n}},jumping:t=>{const e=t%8;const n=[0,1,-1,-3,-4,-2,0,0][e];const s=[6,7,6,4,3,4,6,6][e];return{...BASE,y0:4+n,eyes:e===1?"closed":"open",legs:e>=2&&e<=5?[1,1,1]:[0,0,0],extras:[[1,s+n,"g"],[14,s+n,"g"]]}},loading:t=>{const e=[];const n=RING.length;const s=t%n;e.push(pt(RING[s],"l"),pt(RING[(s+n-1)%n],"n"),pt(RING[(s+n-2)%n],"m"));return{...BASE,ex:1,ey:-1,extras:e}},progress:t=>{const e=t%32;const n=Math.min(12,Math.floor(e/2));const s=e>=24;const o=[];rect(2,0,13,1,"A",o);if(n>0)rect(2,0,1+n,1,"a",o);const r=s&&(e===25||e===26)?1:0;return{...BASE,y0:4-r,eyes:s?"happy":"open",ex:s?0:n<4?-1:n<9?0:1,ey:s?0:-1,lamp:s&&e%2?"A":"a",legs:r?[1,1,1]:[0,0,0],extras:o}},hourglass:t=>{const e=t%20;const n=e>=16?-1:0;const s=[];const o=3+n;rect(13,o,15,o,"n",s);rect(13,o+4,15,o+4,"n",s);s.push([13,o+1,"n"],[15,o+1,"n"],[14,o+2,"n"],[13,o+3,"n"],[15,o+3,"n"]);const r=e<8||e>=16;s.push([14,o+1,r?"a":"1"],[14,o+3,r?"1":"a"]);if(e>=4&&e<12&&e%2)s.push([14,o+2,"a"]);s.push([13,8+n,"g"]);return{...BASE,ex:1,eyes:e===17?"closed":"open",extras:s}},waiting:t=>{const e=t%16;const n=[];n.push([1,0,"n"],[2,0,"n"],[0,1,"n"],[3,1,"n"],[0,2,"n"],[3,2,"n"],[1,3,"n"],[2,3,"n"]);rect(1,1,2,2,"l",n);n.push(pt([[2,1],[2,2],[1,2],[1,1]][Math.floor(e/2)%4],"k"));const s=Math.min(3,Math.floor(e/4));for(let r=0;r<s;r++)n.push([13+r,1,"n"]);const o=e>=6&&e<11;return{...BASE,ex:o?-1:0,ey:o?-1:0,legs:[0,0,e%2],extras:n}},syncing:t=>{const e=[];const n=RING.length;const s=t%n;for(const o of[0,1,2]){e.push(pt(RING[(s+o)%n],o===2?"l":"n"));e.push(pt(RING[(s+o+5)%n],o===2?"l":"n"))}return{...BASE,ex:1,ey:-1,lamp:t%4<2?"a":"A",extras:e}},downloading:t=>{const e=t%12;const n=[[13,5,"n"],[15,5,"n"],[13,6,"n"],[14,6,"n"],[15,6,"n"]];if(e<6){const s=Math.floor(e/2);arrowDown(14,s,"l",n)}else if(e===6){rect(13,6,15,6,"l",n)}else if(e<10){n.push([14,5,"a"])}return{...BASE,ex:1,ey:e<2?-1:e<6?0:1,extras:n}},uploading:t=>{const e=t%12;const n=[[13,5,"n"],[15,5,"n"],[13,6,"n"],[14,6,"n"],[15,6,"n"]];if(e<2)n.push([14,5,"a"]);else if(e<10)arrowUp(14,2-Math.floor((e-2)/2),"l",n);return{...BASE,ex:1,ey:e<4?1:e<8?0:-1,extras:n}},connecting:t=>{const e=t%14;const n=e<8?Math.floor(e/2):e%2?4:0;const s=[];for(let o=0;o<4;o++){const r=12+o;const a=o<n;for(let i=4-o;i<=4;i++)s.push([r,i,a?"g":"1"])}return{...BASE,ex:1,ey:-1,eyes:e>=8?"happy":"open",extras:s}},scanning:t=>{const e=t%14;const n=[];if(e<9){const s=4+e;if(e>0)rect(1,s-1,14,s-1,"n",n);rect(1,s,14,s,"l",n)}return{...BASE,eyes:"big",legs:[0,0,0],extras:n}},searching:t=>{const e=[];for(const o of[4,9]){rect(o,5,o+2,5,"n",e);rect(o,7,o+2,7,"n",e);e.push([o,6,"n"],[o+2,6,"n"],[o+1,6,"k"])}e.push([7,6,"n"],[8,6,"n"]);const n=Math.floor(t/3)%4;const s=[-1,0,1,0][n];return{...BASE,dx:s,legs:n%2?walk(t):[0,0,0],extras:e}},empty:t=>{const e=t%16;const n=[];rect(13,7,13,10,"n",n);rect(15,7,15,10,"n",n);rect(14,10,14,10,"n",n);rect(14,8,14,9,"1",n);const s=e>=9?Math.min(3,e-8):0;for(let r=0;r<s;r++)n.push([12+r,1,"n"]);const o=e<8;return{...BASE,ex:o?1:0,ey:o?1:0,eyes:e===8?"closed":"open",extras:n}},shrug:t=>{const e=t%16;const n=e>=4&&e<12;const s=n?[[2,5,"g"],[1,4,"g"],[13,5,"g"],[14,4,"g"]]:[];return{...BASE,ex:e<4?0:e<8?-1:e<12?1:0,ey:n?-1:0,extras:s}},fishing:t=>{const e=t%32;const n=[[13,6,"g"],[14,6,"g"],[14,5,"m"],[15,4,"m"]];const s=e>=20&&e<24;const o=e>=24&&e<27;const r=s?14:o?11:12+Math.floor(e/4)%2;rect(15,5,15,r-1,"n",n);n.push([15,r,"r"],[15,r+1,"l"]);if(o)n.push([14,12,"l"],[13,13,"l"]);return{...BASE,ex:1,eyes:s?"big":e===15?"closed":"open",extras:n}},listening:t=>{const e=Math.floor(t/2)%4;const n=[[13,5,"g"],[14,5,"g"],[14,6,"g"]];const s=[[15,4,"n"],[16,5,"n"],[16,6,"n"],[15,7,"n"]];const o=[[16,3,"l"],[17,4,"l"],[17,5,"l"],[17,6,"l"],[17,7,"l"],[16,8,"l"]];if(e===0||e===1)n.push(...s);if(e===1||e===2)n.push(...o);return{...BASE,dx:-2,eyes:"closed",extras:n}},tumbleweed:t=>{const e=t%28;const n=[];const s=15-e;if(e<20){if(e%2)n.push([s,11,"A"],[s+2,11,"A"],[s+1,12,"A"],[s,13,"A"],[s+2,13,"A"]);else n.push([s+1,11,"A"],[s,12,"A"],[s+2,12,"A"],[s+1,13,"A"])}const o=e>=20?0:s>8?1:s>3?0:-1;return{...BASE,ex:o,ey:e<20?1:0,extras:n}},warning:t=>{const e=[];e.push([15,0,"a"]);rect(14,1,16,2,"a",e);rect(13,3,17,4,"a",e);e.push([15,1,"k"],[15,2,"k"],[15,4,"k"]);e.push([13,5,"g"],[14,5,"g"]);return{...BASE,dx:-2,eyes:"big",ex:1,ey:-1,lamp:t%4<2?"a":"A",extras:e}},crash:t=>{const e=t%20;const n=[];if(e<3){const s=e%2?[[1,2],[14,2],[0,7],[15,7],[4,0],[11,0],[1,11],[14,11]]:[[2,1],[13,1],[0,5],[15,5],[6,0],[9,0],[0,9],[15,9]];s.forEach(o=>n.push(pt(o,e===0?"l":"a")))}else if(e<10){const s=2-Math.floor((e-3)/2);if(s>=0)n.push([2,s,"n"],[13,s,"n"],[1,s+1,"n"],[14,s+1,"n"])}return{...BASE,eyes:"x",lamp:e<3?"r":"R",dx:e<3?[0,1,-1][e]:e>=10?[0,1,0,-1][e%4]:0,legs:e<10?[1,1,1]:[0,0,0],extras:n}},panic:t=>{const e=t%2;const n=e?[[2,5,"g"],[1,4,"g"],[13,5,"g"],[14,4,"g"],[14,2,"l"]]:[[2,7,"g"],[1,8,"g"],[13,7,"g"],[14,8,"g"],[1,3,"l"]];return{...BASE,eyes:"big",lamp:e?"r":"a",dx:[0,1,0,-1][t%4],legs:walk(t),extras:n}},sos:t=>{const e=t%SOS.length;const n=SOS[e]===1;const s=Math.floor(t/2)%2;const o=[[1,4+s*2,"g"],[2,5+s*2,"g"],[13,5+s*2,"g"],[14,4+s*2,"g"]];return{...BASE,eyes:"big",lamp:n?"r":"R",extras:o}},offline:t=>{const e=t%16;const n=[];rect(11,0,14,0,"n",n);rect(10,1,15,1,"n",n);rect(11,2,14,2,"n",n);if(e%4<2)n.push([10,3,"r"],[11,2,"r"],[12,1,"r"],[13,0,"r"]);const s=e>=10&&e<14;return{...BASE,y0:5,lamp:"A",eyes:s?"open":"closed",ex:1,ey:s?-1:0,extras:n}},timeout:t=>{const e=t%16;const n=e>=12;const s=[];const o=n?"r":"n";s.push([13,1,o],[14,1,o],[12,2,o],[15,2,o],[12,3,o],[15,3,o],[13,4,o],[14,4,o]);rect(13,2,14,3,"l",s);s.push(pt([[14,2],[14,3],[13,3],[13,2]][n?0:Math.floor(e/3)%4],"k"));return{...BASE,ex:1,ey:-1,eyes:n?"closed":"open",lamp:n&&e%2?"r":"a",dx:n?[0,1,0,-1][e%4]:0,extras:s}},locked:t=>{const e=t%20;const n=[];padlock(false,n);const s=e>=6&&e<12;const o=e>=12;if(s)n.push([13,7,"g"],[14,7,"g"]);if(o)n.push([2,5,"g"],[1,4,"g"]);return{...BASE,ex:o?0:1,ey:o?0:-1,eyes:s?"closed":"open",dx:s&&e%2?-1:0,extras:n}},unlocked:t=>{const e=t%20;const n=e>=4;const s=[];padlock(n,s);if(e>=4&&e<10){const r=e%2?[[11,0],[15,5],[12,6]]:[[12,0],[11,4],[15,6]];r.forEach(a=>s.push(pt(a,"l")))}const o=e===5||e===6?1:0;return{...BASE,y0:4-o,ex:n?0:1,ey:n?0:-1,eyes:n?"happy":"open",lamp:n&&e%2?"A":"a",legs:o?[1,1,1]:[0,0,0],extras:s}},denied:t=>{const e=[];rect(13,0,15,0,"r",e);rect(13,4,15,4,"r",e);for(let n=1;n<=3;n++)e.push([12,n,"r"],[16,n,"r"]);e.push([13,3,"r"],[14,2,"r"],[15,1,"r"]);return{...BASE,dx:-1,ex:[-1,0,1,0][Math.floor(t/2)%4],ey:-1,extras:e}},broken:t=>{const e=t%24;const n=[[8,4,"k"],[7,5,"k"],[8,6,"k"],[7,7,"k"],[8,8,"k"],[7,9,"k"],[8,10,"k"]];if(e>=8){rect(6,8,9,9,"n",n);rect(7,8,8,9,"l",n)}return{...BASE,eyes:e<8?"closed":e===20?"closed":"open",lamp:e<8&&e%2?"A":"a",dx:e<4?[0,1,0,-1][e]:0,extras:n}},sad:t=>{const e=t%16;const n=e>=2&&e<10?8+Math.floor((e-2)/2):e>=10&&e<12?12:-1;const s=n>=0?[[5,n,"l"]]:[];return{...BASE,y0:5,lamp:"A",eyes:"closed",extras:s}},rain:t=>{const e=t%12;const n=[];rect(5,0,10,0,"n",n);rect(4,1,11,1,"m",n);[1,4,8,11,14].forEach((s,o)=>{const r=2+(e+o*3)%11;n.push([s,r,"l"])});return{...BASE,y0:5,lamp:"A",eyes:"closed",extras:n}},sick:t=>{const e=t%12;const n=[];rect(14,2,14,7,"l",n);n.push([14,8,"r"],[15,3,"n"],[15,5,"n"]);const s=Math.min(4,Math.floor(e/2));if(s>0)rect(14,8-s,14,7,"r",n);n.push(e%2?[2,4,"l"]:[1,5,"l"]);return{...BASE,eyes:"closed",lamp:"A",dx:[0,1,0,-1][Math.floor(e/3)%4],extras:n}},flood:t=>{const e=t%8;const n=[[1,7+e%2,"g"],[2,8+e%2,"g"],[13,8-e%2,"g"],[14,7-e%2,"g"],[0,11-e%4,"l"],[15,12-(e+2)%4,"l"]];return{...BASE,submerged:true,y0:9,eyes:"big",lamp:e%2?"a":"A",legs:null,extras:n}},bug:t=>{const e=t%24;const n=[];let s=0;let o=1;if(e<20){const r=3+Math.floor(e/2);rect(r,8,r+1,9,"1",n);n.push([r-1,9-e%2,"k"],[r+2,8+e%2,"k"]);s=r<6?-1:r>9?1:0}else{const r=e-20;n.push([12+r,7-r,"1"],[13+r,7-r,"1"],[12+r,6-r,"n"],[14+r,6-r,"n"]);s=1;o=-1}return{...BASE,ex:s,ey:o,eyes:e>=18?"big":"open",extras:n}},alarm:t=>{const e=t%2;const n=e?[[4,2,"l"],[11,2,"l"],[6,0,"l"],[9,0,"l"]]:[[3,1,"l"],[12,1,"l"],[7,0,"l"],[8,0,"l"]];return{...BASE,eyes:"big",lamp:e?"r":"R",extras:n}},frozen:t=>{const e=t%12;const n=[[4,11,"l"],[4,12,"l"],[7,11,"l"],[10,11,"l"],[10,12,"l"],[3,3,"l"],[12,3,"l"]];[1,14,5,10].forEach((s,o)=>n.push([s,(e*2+o*3)%12,"l"]));return{...BASE,lamp:"A",legs:null,dx:t%2,extras:n}},snail:t=>{const e=t%36;const n=[];const s=Math.floor(e/6)-3;rect(s,9,s+2,11,"A",n);n.push([s+1,10,"a"],[s+3,11,"n"],[s+4,11,"n"],[s+4,10,"n"],[s+4,9,"k"]);return{...BASE,ex:-1,ey:1,eyes:e%12===11?"closed":"open",extras:n}},angry:t=>{const e=[[4,5,"k"],[5,5,"k"],[6,6,"k"],[9,6,"k"],[10,5,"k"],[11,5,"k"]];if(t%2)e.push([4,1,"n"],[11,1,"n"]);else e.push([3,0,"n"],[12,0,"n"]);return{...BASE,ey:1,lamp:t%4<2?"r":"R",legs:walk(t),extras:e}},ghost:t=>{const e=t%8;const n=[];const s=4-(e<4?0:1);rect(4,s,11,s+6,"m",n);rect(3,s+1,3,s+5,"m",n);rect(12,s+1,12,s+5,"m",n);[4,7,10].forEach(o=>n.push([o,s+7,"m"]));rect(5,s+2,6,s+3,"l",n);rect(9,s+2,10,s+3,"l",n);return{...BASE,y0:s,lamp:"A",legs:null,extras:n}},nervous:t=>{const e=[t%2?[13,3,"l"]:[2,3,"l"]];return{...BASE,ex:t%2?1:-1,lamp:t%3?"a":"A",legs:t%2?[1,0,0]:[0,0,1],extras:e}},puzzled:t=>{const e=t%16;const n=e>=4&&e<12;const s=n?[[13,6,"g"],[14,5,"g"],[14,4,"g"],[13,3-e%2,"g"]]:[];return{...BASE,ex:e<4?0:e<8?-1:e<12?1:0,ey:n?-1:0,eyes:e===14?"closed":"open",extras:s}},detective:t=>{const e=t%16;const n=[];rect(3,3,12,3,"A",n);rect(5,1,10,2,"A",n);rect(5,2,10,2,"a",n);const s=Math.floor(e/4)%2?4:5;n.push([0,s,"n"],[1,s,"n"],[2,s,"n"],[0,s+1,"n"],[2,s+1,"n"],[0,s+2,"n"],[1,s+2,"n"],[2,s+2,"n"]);n.push([1,s+1,"l"],[2,s+3,"g"],[1,s+3,"g"]);return{...BASE,lamp:null,ex:-1,ey:s===4?-1:0,eyes:e===15?"closed":"open",extras:n}},reading:t=>{const e=t%24;const n=[];rect(3,8,12,11,"l",n);rect(7,8,8,11,"n",n);const s=e>=20&&e<22;if(s)rect(9,8,12,11,"n",n);for(const o of[9,10]){rect(4,o,6,o,"k",n);if(!s)rect(9,o,11,o,"k",n)}n.push([2,9,"g"],[13,9,"g"]);return{...BASE,ey:1,ex:e<20?[-1,0,1][Math.floor(e/2)%3]:0,eyes:e===22?"closed":"open",legs:null,extras:n}},success:t=>{const e=t%16;const n=[];if(e>=2)n.push([11,2,"g"],[12,3,"g"],[13,2,"g"],[14,1,"g"],[15,0,"g"]);if(e>=3&&e<7){const o=e%2?[[10,0],[15,3],[13,5]]:[[11,0],[14,4],[9,1]];o.forEach(r=>n.push(pt(r,"l")))}const s=e===3||e===4?1:0;return{...BASE,y0:4-s,eyes:e>=2?"happy":"open",ex:e>=2?0:1,ey:e>=2?0:-1,lamp:e>=2&&e<8&&e%2?"A":"a",legs:s?[1,1,1]:[0,0,0],extras:n}},celebrate:t=>{const e=t%12;const n=[];const s=[0,15,2,13,5,10,1,14];const o=["p","l","a","p","l","p","a","l"];s.forEach((a,i)=>n.push([a,(e*2+i*5)%13,o[i]]));const r=e%4<2;n.push([2,5,"g"],[1,4,"g"],[13,5,"g"],[14,4,"g"]);return{...BASE,y0:r?3:4,eyes:"happy",legs:r?[1,1,1]:[0,0,0],extras:n}},thumbsup:t=>{const e=t%12;const n=e<4?2:0;const s=[];rect(13,6+n,14,7+n,"g",s);s.push([14,4+n,"g"],[14,5+n,"g"]);const o=e>=6&&e<10;if(o)s.push([5,6,"g"],[6,6,"g"]);return{...BASE,eyes:e>=4&&!o?"happy":"open",extras:s}},party:t=>{const e=t%16;const n=[];n.push([7,0,"a"],[8,0,"a"]);rect(6,1,9,1,"p",n);rect(5,2,10,2,"a",n);rect(4,3,11,3,"p",n);[0,15,2,13].forEach((o,r)=>n.push([o,(e*2+r*4)%12,r%2?"l":"p"]));const s=Math.floor(e/2)%2;n.push([1,5+s,"g"],[2,6-s,"g"],[13,6-s,"g"],[14,5+s,"g"]);return{...BASE,lamp:null,eyes:"happy",dx:[0,1,0,-1][Math.floor(e/2)%4],legs:walk(Math.floor(e/2)),extras:n}},trophy:t=>{const e=t%16;const n=[];rect(5,0,10,0,"a",n);rect(6,1,9,1,"a",n);rect(7,2,8,2,"A",n);rect(6,3,9,3,"A",n);n.push([2,5,"g"],[1,4,"g"],[13,5,"g"],[14,4,"g"]);if(e%2)n.push([3,0,"l"],[12,1,"l"]);else n.push([4,1,"l"],[11,0,"l"]);const s=e===8||e===9?1:0;return{...BASE,y0:4-s,lamp:null,eyes:"happy",legs:s?[1,1,1]:[0,0,0],extras:n}},starred:t=>{const e=t%12;const n=[];if(e>=1){n.push([13,0,"a"]);rect(11,1,15,1,"a",n);rect(12,2,14,2,"a",n);n.push([12,3,"a"],[14,3,"a"],[11,4,"a"],[15,4,"a"]);if(e%3===0)n.push([13,2,"l"])}return{...BASE,ex:1,ey:-1,eyes:e>=4?"happy":"open",extras:n}},love:t=>{const e=t%16;const n=[];const s=(o,r)=>{if(r<-2)return;n.push([o,r,"r"],[o+2,r,"r"],[o,r+1,"r"],[o+1,r+1,"r"],[o+2,r+1,"r"],[o+1,r+2,"r"])};s(0,8-Math.floor(e/2)*2);s(13,8-Math.floor((e+8)%16/2)*2);return{...BASE,y0:4+Math.floor(e/4)%2,eyes:"happy",extras:n}},wave:t=>{const e=t%12;const n=[[13,5,"g"],[14,4,"g"],[e%2?15:14,3,"g"]];return{...BASE,eyes:e>=8?"happy":"open",extras:n}},bow:t=>{const e=t%16;const n=e>=4&&e<12;return n?{...BASE,y0:6,h:5,eyes:"closed"}:{...BASE}},cool:t=>{const e=t%16;const n=Math.min(6,3+e);const s=[];rect(4,n,6,n+1,"k",s);rect(9,n,11,n+1,"k",s);s.push([7,n,"k"],[8,n,"k"]);const o=n===6;return{...BASE,dx:o?[0,0,1,0,0,-1][Math.floor(e/2)%6]:0,extras:s}},flexing:t=>{const e=t%8;const n=[[2,6,"g"],[1,6,"g"],[1,5,"g"],[1,4,"g"],[13,6,"g"],[14,6,"g"],[14,5,"g"],[14,4,"g"]];if(e<4)n.push([0,5,"g"],[15,5,"g"]);return{...BASE,eyes:e<4?"open":"happy",extras:n}},zen:t=>{const e=t%16;const n=e<8?[[1,5,"l"],[14,9,"l"]]:[[2,10,"l"],[13,4,"l"]];return{...BASE,y0:3+Math.floor(e/8)%2,lamp:"a",eyes:"closed",legs:null,extras:n}},recording:t=>{const e=t%16;const n=e%4<2?[...rect(13,0,14,1,"r",[])]:[];return{...BASE,ex:[-1,-1,0,0,1,1,0,0][Math.floor(e/2)],extras:n}},paused:t=>{const e=t%16;const n=[];rect(13,0,13,3,"n",n);rect(15,0,15,3,"n",n);const s=e>=8&&e<10;return{...BASE,y0:5,lamp:"A",eyes:s?"open":"closed",ex:1,ey:s?-1:0,extras:n}},filtering:t=>{const e=t%12;const n=[];rect(12,0,15,0,"n",n);n.push([12,1,"n"],[15,1,"n"],[13,2,"n"],[14,2,"n"],[14,3,"n"],[14,4,"n"]);const s=["p","l","a","l","p","a"];n.push([13,1,s[e%6]],[14,1,s[(e+3)%6]]);n.push([14,5+e%4,"a"]);return{...BASE,ex:1,ey:e%8<4?-1:1,extras:n}},pinned:t=>{const e=t%12;const n=e<3?e-3:0;const s=[];rect(13,1+n,14,2+n,"r",s);s.push([13,3+n,"n"],[14,3+n,"n"],[13,4+n,"n"],[13,5+n,"n"]);if(e===4||e===5)s.push([15,0,"l"],[12,6,"l"]);return{...BASE,ex:1,ey:-1,eyes:e===3?"closed":"open",extras:s}},rewind:t=>{const e=t%16;const n=[];n.push([1,0,"n"],[2,0,"n"],[0,1,"n"],[3,1,"n"],[0,2,"n"],[3,2,"n"],[1,3,"n"],[2,3,"n"]);rect(1,1,2,2,"l",n);n.push(pt([[1,1],[1,2],[2,2],[2,1]][e%4],"k"));return{...BASE,dx:3-Math.floor(e/2),ex:1,legs:walk(t),extras:n}},storing:t=>{const e=t%24;const n=[];const s=Math.floor(e/6);for(let o=0;o<Math.min(3,s);o++){const r=11-o*2;rect(13,r,14,r+1,"A",n);n.push([13,r,"a"])}if(s<3){const o=4+(e%6<3?0:1);rect(13,o,14,o+1,"A",n);n.push([13,o,"a"],[13,o+2,"g"],[14,o+2,"g"])}return{...BASE,ex:1,ey:s<3?0:1,eyes:s===3&&e%6===5?"happy":"open",extras:n}},printing:t=>{const e=t%16;const n=[];rect(13,3,15,5,"n",n);n.push([14,4,"1"]);const s=Math.min(6,e);if(s>0){rect(13,6,15,5+s,"l",n);for(let o=6;o<=5+s;o+=2)n.push([14,o,"k"])}return{...BASE,ex:1,ey:1,extras:n}},stopwatch:t=>{const e=[];e.push([13,0,"n"],[13,1,"n"],[14,1,"n"],[12,2,"n"],[15,2,"n"],[12,3,"n"],[15,3,"n"],[13,4,"n"],[14,4,"n"]);rect(13,2,14,3,"l",e);e.push(pt([[14,2],[14,3],[13,3],[13,2]][t%4],"k"));if(t%2)e.push([0,6,"n"],[1,6,"n"],[0,9,"n"]);else e.push([0,7,"n"],[1,8,"n"],[0,8,"n"]);return{...BASE,eyes:"big",ex:1,ey:-1,extras:e}},spotlight:t=>{const e=t%12;const n=[];if(e<4){rect(4,1,7,1,"a",n);rect(2,0,6,0,"a",n)}else if(e<8){rect(6,1,9,1,"a",n);rect(5,0,10,0,"a",n)}else{rect(8,1,11,1,"a",n);rect(9,0,13,0,"a",n)}return{...BASE,ex:e<4?-1:e<8?0:1,ey:-1,extras:n}},keys:t=>{const e=t%8;const n=[[13,5,"g"],[14,5,"g"]];n.push([13,6,"n"],[14,6,"n"],[15,6,"n"],[13,7,"n"],[15,7,"n"],[13,8,"n"],[14,8,"n"],[15,8,"n"]);const s=e<4?15:14;n.push([13,9,"a"],[13,10,"a"],[s,9,"a"],[s,10,"a"]);return{...BASE,ex:1,ey:1,eyes:e===7?"closed":"open",extras:n}},map:t=>{const e=t%16;const n=[];rect(3,8,12,11,"l",n);n.push([4,10,"m"],[5,9,"m"],[6,9,"m"],[7,10,"m"],[8,10,"m"],[9,9,"m"],[10,9,"m"]);n.push([11,8,"r"],[11,9,"r"]);n.push([2,9,"g"],[13,9,"g"]);const s=e>=8;return{...BASE,ex:s?e<12?-1:1:0,ey:s?-1:1,legs:null,extras:n}},photo:t=>{const e=t%16;const n=[];rect(5,8,10,10,"n",n);rect(7,9,8,9,"k",n);n.push([7,9,"l"],[10,8,"1"]);n.push([2,9,"g"],[13,9,"g"]);if(e===6){rect(0,0,15,1,"l",n);n.push([3,2,"l"],[12,2,"l"])}if(e>=8){rect(13,6,15,8,"n",n);n.push([14,7,"g"])}return{...BASE,lamp:e===6?"a":"A",eyes:e===6?"closed":"open",legs:null,extras:n}},painting:t=>{const e=t%16;const n=[];rect(13,2,15,7,"l",n);if(e>=2)n.push([13,3,"p"],[14,3,"p"]);if(e>=6)n.push([14,5,"a"],[15,5,"a"]);if(e>=10)n.push([13,6,"r"]);n.push([13,8,"g"],[14,8,"g"],[15,8-e%2,"m"]);return{...BASE,ex:1,ey:e%8<4?-1:0,extras:n}},disguise:t=>{const e=[];for(const n of[4,8]){rect(n,5,n+3,5,"n",e);rect(n,8,n+3,8,"n",e);e.push([n,6,"n"],[n,7,"n"],[n+3,6,"n"],[n+3,7,"n"])}e.push([7,8,"a"],[8,8,"a"]);rect(5,9,10,9,"k",e);e.push([5,10,"k"],[10,10,"k"]);return{...BASE,ex:[-1,-1,-1,0,1,1,1,0][Math.floor(t/3)%8],extras:e}},pro:t=>{const e=t%12;const n=[];rect(5,2,10,3,"a",n);n.push([5,1,"a"],[7,1,"a"],[8,1,"a"],[10,1,"a"],[6,2,"p"],[9,2,"p"]);n.push(e%2?[3,1,"l"]:[12,0,"l"]);return{...BASE,lamp:null,eyes:e>=6?"happy":"open",extras:n}},talking:t=>{const e=t%12;const n=[];rect(9,0,15,2,"l",n);n.push([10,3,"l"]);[10,12,14].forEach((s,o)=>n.push([s,1,(e+o)%3===0?"k":"m"]));return{...BASE,ex:1,ey:-1,lamp:e%4<2?"a":"A",extras:n}},handshake:t=>{const e=t%16;const n=16-Math.min(2,e);const s=e>=4&&e<12?Math.floor(e/2)%2:0;const o=[];rect(n,6+s,n+1,7+s,"n",o);if(e>=2)o.push([13,7+s,"g"]);return{...BASE,ex:1,eyes:e>=4?"happy":"open",extras:o}},robot:t=>{const e=t%16;const n=[];n.push([14,3,e%4<2?"r":"n"],[14,4,"n"]);rect(13,5,15,7,"n",n);const s=e%8<2?"r":"k";n.push([13,6,s],[15,6,s]);rect(13,8,15,10,"m",n);n.push([14,9,"l"],[13,11,"n"],[15,11,"n"]);return{...BASE,ex:1,ey:1,eyes:e>=8&&e<12?"happy":"open",extras:n}},plug:t=>{const e=t%16;const n=16-Math.min(3,e);const s=[];rect(n,6,n+1,7,"n",s);s.push([n-1,6,"l"],[n-1,7,"l"],[n+2,7,"n"],[n+3,7,"n"]);if(e>=4&&e<7)s.push(e%2?[11,2,"l"]:[15,4,"l"]);return{...BASE,lamp:e>=3?"a":"A",ex:1,eyes:e>=5?"happy":"open",extras:s}},gift:t=>{const e=t%16;const n=e>=12;const s=!n&&e%4===2?-1:0;const o=[];rect(13,7+s,15,10+s,"p",o);rect(14,7+s,14,10+s,"a",o);const r=n?4:6+s;rect(13,r,15,r,"a",o);if(n)o.push([14,3,"l"],[12,5,"l"]);return{...BASE,ex:1,ey:1,eyes:n?"happy":"big",extras:o}},action:t=>{const e=t%16;const n=e===4||e===5;const s=[];rect(13,4,15,7,"n",s);s.push([14,5,"k"],[14,6,"k"]);const o=n?3:2;s.push([13,o,"l"],[14,o,"k"],[15,o,"l"]);if(e===4)s.push([12,2,"l"]);return{...BASE,ex:1,ey:-1,eyes:e===4?"closed":"open",extras:s}},guard:t=>{const e=t%16;const n=[];rect(13,5,15,7,"n",n);n.push([14,8,"n"],[14,6,"g"]);if(e%6===0)n.push([13,5,"l"]);if(e>=2&&e<6)n.push([15,e-2,"r"]);if(e===6)n.push([15,4,"l"],[14,4,"l"]);if(e>=7&&e<10)n.push([15,9-e,"R"]);return{...BASE,ex:1,ey:-1,eyes:e===5||e===6?"big":"open",extras:n}},coffee:t=>{const e=t%16;const n=e>=8&&e<12;const s=n?-2:0;const o=[];rect(13,6+s,14,8+s,"l",o);o.push([15,7+s,"n"],[13,6+s,"A"],[14,6+s,"A"],[13,9+s,"g"],[14,9+s,"g"]);if(!n)o.push(...e%2?[[13,4,"n"],[14,3,"n"]]:[[14,4,"n"],[13,3,"n"]]);return{...BASE,ex:n?0:1,ey:n?0:1,eyes:n?"closed":e>=12&&e<14?"happy":"open",extras:o}},swimming:t=>{const e=t%8;const n=e<4;const s=n?[[1,8,"g"],[2,9,"g"],[0,12,"l"],[13,11,"g"],[14,12,"g"]]:[[14,8,"g"],[13,9,"g"],[15,12,"l"],[2,11,"g"],[1,12,"g"]];return{...BASE,submerged:true,y0:8,ex:n?-1:1,legs:null,extras:s}},diving:t=>{const e=t%24;const n=[];let s=4;if(e>=4&&e<10)s=4+(e-3)*2;else if(e>=10&&e<16)s=16;else if(e>=16&&e<20)s=14-(e-15)*2;if(e>=8&&e<16)n.push([7,12-e*2%6,"l"],[9,12-(e*2+3)%6,"l"]);if(e===20||e===21)n.push([3,3,"l"],[12,3,"l"]);return{...BASE,submerged:s>4,y0:s,ey:e<4?1:0,eyes:e>=20&&e<23?"happy":"open",legs:s>4?null:[0,0,0],extras:n}},balloon:t=>{const e=t%24;const n=e<8?4:e<20?4-Math.min(3,Math.floor((e-8)/2)):4;const s=[];rect(13,0,15,2,"r",s);s.push([14,3,"R"]);rect(14,4,14,n+2,"n",s);s.push([13,n+2,"g"]);if(e===20)s.push([2,12,"l"],[12,12,"l"]);const o=n<4;return{...BASE,y0:n,ex:o?0:1,ey:o?0:-1,eyes:o?"happy":"open",legs:o?e%2?[1,0,1]:[0,1,0]:[0,0,0],extras:s}},landing:t=>{const e=t%16;if(e<4)return{...BASE,y0:-8+e*3,eyes:"big",legs:[1,1,1]};if(e===4)return{...BASE,x0:2,w:12,y0:6,h:5,eyes:"closed",extras:[[1,12,"l"],[14,12,"l"],[0,11,"l"],[15,11,"l"]]};if(e===5)return{...BASE,eyes:"closed"};return{...BASE,eyes:e>=8&&e<12?"happy":"open"}},spinning:t=>{const e=t%16;const n=Math.floor(e/2);const[s,o]=[[10,0],[8,1],[6,0],[4,0],[6,0],[8,-1],[10,0],[10,0]][n];const r=3+(10-s)/2;const a=[];if(s<=6){const i=r+s-1;a.push([r+1,11,"s"],[r+1,12,"s"],[i-1,11,"s"],[i-1,12,"s"])}if(s===4)rect(r,6,r+3,7,"g",a);return{...BASE,x0:r,w:s,ex:o,legs:s<=6?null:[0,0,0],extras:a}},bubbles:t=>{const e=t%12;const n=e<4;const s=[[13,6,"g"],[14,6,"g"],[15,6,"m"],[15,5,"m"],[15,4,"n"]];for(let o=0;o<3;o++){const r=3-(e+o*4)%12;if(r>=0)s.push([13+o%2,r,"l"])}return{...BASE,ex:n?1:1,ey:n?0:-1,eyes:n?"closed":"open",extras:s}},trash:t=>{const e=t%16;const n=[];rect(13,7,15,11,"n",n);rect(14,8,14,10,"1",n);const s=e>=2&&e<10;rect(13,s?5:6,15,s?5:6,"n",n);if(e>=3&&e<9)n.push([7+(e-3),5-e%2,e%2?"p":"a"]);if(e===9||e===10)n.push([14,4,"l"],[13,3,"l"],[15,3,"l"]);return{...BASE,ex:1,ey:-1,eyes:e>=11&&e<14?"happy":"open",extras:n}},saved:t=>{const e=t%12;const n=e===1?-1:0;const s=[];if(e>=1){rect(13,2+n,15,5+n,"1",s);s.push([13,2+n,"n"],[14,2+n,"n"]);rect(13,4+n,15,5+n,"l",s)}if(e===3||e===4)s.push([12,0,"l"],[15,7,"l"]);const o=e===2?1:0;return{...BASE,y0:4-o,ex:1,ey:-1,eyes:e>=3?"happy":"open",legs:o?[1,1,1]:[0,0,0],extras:s}},copied:t=>{const e=t%12;const n=e<2?0:1;const s=[];rect(12,1,14,3,"n",s);s.push([13,2,"1"]);rect(12+n,2+n,14+n,4+n,"l",s);s.push([13+n,3+n,"m"]);if(e===4||e===5)s.push([15,0,"l"],[11,6,"l"]);return{...BASE,ex:1,ey:-1,eyes:e>=4?"happy":"open",extras:s}},charting:t=>{const e=t%16;const n=[];rect(13,12,15,12,"n",n);[3,5,4].forEach((s,o)=>{const r=Math.min(s,Math.floor(e/2));if(r>0)rect(13+o,12-r,13+o,11,"g",n)});return{...BASE,ex:1,ey:e<6?1:0,eyes:e>=12?"happy":"open",extras:n}},present:t=>{const e=t%16;const n=[[13,7,"g"],[14,7,"g"],[15,7,"g"],[15,6,"g"]];return{...BASE,ex:1,ey:-1,eyes:e===13?"closed":e>=8&&e<12?"happy":"open",extras:n}},lift:t=>{const e=t%16;const n=e%8===2||e%8===3?1:0;const s=[[2,5-n,"g"],[1,4-n,"g"],[1,3-n,"g"],[13,5-n,"g"],[14,4-n,"g"],[14,3-n,"g"]];return{...BASE,y0:4-n,eyes:"happy",legs:n?[1,1,1]:[0,0,0],extras:s}},carry:t=>{const e=Math.floor(t/2)%2;const n=[[2,5+e,"g"],[1,4+e,"g"],[1,3+e,"g"],[13,5+e,"g"],[14,4+e,"g"],[14,3+e,"g"]];return{...BASE,y0:4+e,ex:t%16<8?0:1,legs:walk(t),extras:n}},hug:t=>{const e=t%16;const n=Math.floor(e/8)%2;const s=[[1,7+n,"g"],[2,8+n,"g"],[14,7+n,"g"],[13,8+n,"g"]];return{...BASE,y0:4+n,ey:-1,eyes:e>=4&&e<12?"happy":"closed",extras:s}},lean:t=>{const e=t%24;const n=[[13,5,"g"],[14,5,"g"],[15,5,"g"]];return{...BASE,ex:e<16?1:0,eyes:e>=8&&e<12?"closed":"open",legs:[0,1,0],extras:n}},point:t=>{const e=t%16;const n=e===6||e===7?1:0;const s=[[13,5-n,"g"],[14,4-n,"g"],[15,3-n,"g"]];return{...BASE,y0:4-n,ex:1,ey:-1,eyes:e>=6&&e<10?"happy":"open",legs:n?[1,1,1]:[0,0,0],extras:s}},static:()=>({...BASE})};const OTTO_ANCHORS=exports.OTTO_ANCHORS={present:t=>({x:14,y:-1+Math.floor(t%16/4)%2,over:false}),lift:t=>{const e=t%16;const n=e%8===2||e%8===3?1:0;return{x:4,y:-5-n,over:false}},carry:t=>({x:4,y:-5+Math.floor(t/2)%2,over:false}),hug:t=>({x:4,y:7+Math.floor(t%16/8)%2,over:true}),lean:()=>({x:14,y:6,over:false}),point:t=>{const e=t%16;const n=e===6||e===7?1:0;return{x:15,y:-5-n+Math.floor(e/4)%2,over:false}}};const OTTO_ANCHOR_SIZE=exports.OTTO_ANCHOR_SIZE=7;const OTTO_NOTES=exports.OTTO_NOTES={idle:"Bobs one pixel, blinks, glances left and right.",thinking:"Looks up; a thought cloud fills with dots.",happy:"Two-pixel hop: stretch on takeoff, squash on landing.",error:"Lamp goes red, eyes shut, body shakes.",sleep:"Sinks a row, lamp dims, z\u2019s drift up.",peek:"Submerged to the eyes, scanning.",typing:"Laptop with a Buoy screen; tentacles tap.",debugging:"Magnifier over one eye, scanning left and right.",building:"Hard hat, hammer swings, spark on the hit.",carrying:"Phone overhead, marching.",pushing:"Shoves a crate, one pixel per heave.",sweeping:"Broom, dust puff on each stroke.",juggling:"Three blocks: red, orange, purple.",wizard:"Purple hat, wand sparkles.",conducting:"Arms swing in antiphase, notes rise.",beacon:"Lamp emits three expanding rings.",notification:"Hop with a blinking exclamation.",disconnected:"Lamp dim, looks up at a phone blinking red.",dizzy:"X eyes, two stars orbit, body wobbles.",overheated:"Melts into a puddle and reforms.",confused:"Question mark, head tilt, eyes wander.",stare:"Big square eyes. Rare blink.",walking:"Crab-walks left and right, eyes lead.",goingaway:"Walks off the right edge, returns from the left.",eureka:"Bulb appears, lights up with sparks, tiny hops.",grooving:"Headphones on, sways with the beat, notes pop.",hatmishap:"Wizard hat slips over the eyes; a wave of the wand fixes it.",lowbattery:"Slumped, lamp off, red battery blinks. Eyes barely open.",wake:"Puddle, wide eyes, springs up, squashes, settles.",builder:"Balances a stack of blocks; sweat drop when it wobbles.",mini:"Half-size Otto. Big eyes, waving arms, kicking feet.",minityping:"Mini Otto typing, data bits float up.",happydance:"Arms pump in antiphase, feet shuffle.",jumping:"Crouch, four-pixel leap, arms up, land.",loading:"Three dots chase around a ring; eyes follow the lead.",progress:"A bar fills across the top; a hop when it completes.",hourglass:"Sand runs through, the glass lifts and flips.",waiting:"Foot taps, checks the wristwatch, dots pile up.",syncing:"Two arcs chase each other; lamp pulses in step.",downloading:"An arrow drops into the tray, the parcel lands.",uploading:"The parcel lifts off the tray and climbs out.",connecting:"Signal bars fill one by one, then blink: connected.",scanning:"A bright line sweeps down the body with a trail.",searching:"Binoculars up, slow sweep left and right.",empty:"Peers into an open box, finds nothing, looks back at you.",shrug:"Arms up, looks left, looks right, arms down.",fishing:"Rod out, bobber bobbing; one tug, one splash.",listening:"Hand cupped, sound arcs arriving from the side.",tumbleweed:"A tumbleweed rolls past; eyes follow it off the edge.",warning:"Holds up a warning sign, lamp blinking.",crash:"Burst, smoke, then dazed with X eyes.",panic:"Arms flail, sweat flies, lamp strobes.",sos:"The lamp flashes S-O-S in morse; arms wave.",offline:"A struck-through cloud; slumped, lamp dim.",timeout:"A clock ticks round, turns red; a shake.",locked:"A padlock: look, strain at it, give up.",unlocked:"The shackle pops open; sparkles and a hop.",denied:"A red no-entry sign; head shaking.",broken:"A crack down the middle; a band-aid goes on.",sad:"Sunk a row, lamp dim, a tear drops in.",rain:"A rain cloud overhead, drops falling.",sick:"A thermometer climbs; wobbling and sweating.",flood:"In over the eyes, arms flailing, bubbles rising.",bug:"A beetle crawls across the body, then flies off.",alarm:"The lamp is a siren: red strobe, sweeping rays.",frozen:"Iced over: icicles for legs, snow, shivering.",snail:"A snail crosses the foreground, very slowly.",angry:"Brows down, lamp red, steam, stomping.",ghost:"Grey and translucent, floating, white eyes.",nervous:"Eyes darting, sweat, fidgeting feet.",puzzled:"A tentacle scratches the head; eyes wander.",detective:"Deerstalker hat, magnifying glass on the move.",reading:"An open book; eyes run the lines; a page turns.",success:"A check mark lands; sparkles, a hop, lamp blinks.",celebrate:"Confetti falls, arms up, bouncing.",thumbsup:"A fist rises, thumb out; then a wink.",party:"Party hat, confetti, a side-to-side dance.",trophy:"A cup held overhead, sparkles, a hop.",starred:"A star pops in at the top right and twinkles.",love:"Hearts float up either side; the body bobs.",wave:"One arm up, hand swinging; a smile at the end.",bow:"A slow bow: squash forward, eyes shut, back up.",cool:"Sunglasses drop into place; a little sway.",flexing:"Both arms up in a flex; the biceps pop.",zen:"Floating above the water, eyes shut, slow bob.",recording:"A red REC dot blinks; eyes slowly sweep the room.",paused:"Pause bars overhead; resting, lamp dim, one peek.",filtering:"A funnel: mixed bits go in, only orange comes out.",pinned:"A pushpin drops in from above and lands.",rewind:"Moonwalks left while a clock runs backwards.",storing:"Crates stack up on the right, one at a time.",printing:"A little printer spools out a strip of log lines.",stopwatch:"A stopwatch with a fast hand; speed lines.",spotlight:"The lamp throws a beam that sweeps left, up, right.",keys:"A keyring held out; the keys jingle.",map:"A folded map: dotted route, red pin; looks around.",photo:"A camera held up; flash; a print pops out.",painting:"A canvas on the right; strokes appear.",disguise:"Groucho glasses, nose and moustache; sly glances.",pro:"A crown in place of the lamp, jewels, sparkles.",talking:"A speech bubble with typing dots; lamp pulses.",handshake:"A hand arrives from the right; they shake.",robot:"A small robot friend: antenna blinking, eyes flickering.",plug:"A plug slides in and connects; the lamp comes on.",gift:"A wrapped gift bounces; the lid lifts with a sparkle.",action:"A clapperboard claps shut.",guard:"A shield up; a red bolt sparks off it and bounces away.",coffee:"A mug with steam; a sip with eyes shut.",swimming:"In to the shoulders, alternating strokes with splashes.",diving:"Sinks out of sight, bubbles rise, comes back dripping.",balloon:"A balloon lifts Otto clear of the water; a splash on release.",landing:"Drops in from above, lands with a squash and a splash.",spinning:"A full turn: front, three-quarter, side, back and round.",bubbles:"Blows through a bubble wand; bubbles drift up.",trash:"Bits fly into a bin, the lid flaps, a puff when done.",saved:"A floppy disk pops in; a hop and a sparkle.",copied:"One sheet slides out from behind another.",charting:"Three bars grow on the right; pleased when they land.",present:"A flat hand held out; the object floats above the palm.",lift:"Both arms up; the object rides overhead; a hop.",carry:"Arms up, marching; the object rides with the step.",hug:"Arms wrapped round the object; eyes peep over it.",lean:"One arm resting on the object beside Otto; relaxed.",point:"Arm up and out; the object hangs up-right, bobbing.",static:"Base pose, no motion. For favicons and stills."};const OTTO_STATE_NAMES=exports.OTTO_STATE_NAMES=Object.keys(OTTO_STATES).filter(t=>t!=="static");const OTTO_GROUPS=exports.OTTO_GROUPS=[{id:"loading",title:"Loading & progress",blurb:"Something is on its way. Spinners, bars, connecting, scanning, waiting.",states:["loading","progress","hourglass","waiting","syncing","downloading","uploading","connecting","scanning","searching","fishing"]},{id:"empty",title:"Empty & unknown",blurb:"Nothing here yet, nothing found, or no idea what this is.",states:["empty","shrug","tumbleweed","confused","puzzled"]},{id:"trouble",title:"Errors & trouble",blurb:"Failures, warnings, disconnects, limits \u2014 from a blip to a crash.",states:["error","warning","crash","panic","sos","alarm","offline","disconnected","timeout","locked","denied","broken","sad","rain","sick","overheated","dizzy","flood","bug","frozen","snail","angry","ghost","nervous","lowbattery"]},{id:"success",title:"Success & celebration",blurb:"It worked. Confirmations, unlocks, milestones, thanks.",states:["happy","eureka","success","celebrate","thumbsup","party","trophy","starred","love","unlocked","notification","beacon","cool","flexing","pro","gift"]},{id:"working",title:"Working & tool moments",blurb:"Busy doing the job: capturing, filtering, saving, inspecting, talking.",states:["thinking","typing","debugging","building","carrying","pushing","sweeping","detective","reading","map","painting","photo","printing","storing","charting","stopwatch","spotlight","keys","filtering","talking","listening","recording","paused","rewind","trash","disguise","guard","action","robot","plug","handshake","saved","copied","pinned"]},{id:"personality",title:"Idle, moves & personality",blurb:"Otto being Otto: idling, wandering, swimming, dancing, showing off.",states:["idle","stare","mini","minityping","walking","goingaway","peek","sleep","wake","jumping","spinning","swimming","diving","balloon","landing","bubbles","zen","bow","wave","coffee","grooving","conducting","juggling","wizard","hatmishap","builder","happydance"]},{id:"pairing",title:"Pairing poses",blurb:"Built to hold a tool's icon tile \u2014 the object is drawn by the scene at OTTO_ANCHORS.",states:["present","lift","carry","hug","lean","point"]}];const OTTO_USES=exports.OTTO_USES={idle:"Default resting state; nothing to report.",thinking:"Working something out; Ask Buoy composing.",happy:"A quick positive beat after any action.",error:"A request or action failed.",sleep:"Tool idle for a long time; capture off overnight.",peek:"Minimized or collapsed; still watching.",typing:"Ask Buoy typing a reply; code being written.",debugging:"Inspecting a detail view; stepping through.",building:"Bundling, compiling, a build in progress.",carrying:"Moving data between tools; exporting.",pushing:"A heavy job: large payload, slow migration.",sweeping:"Clearing a list; cache cleanup done.",juggling:"Several stores or queries updating at once.",wizard:"A setup wizard; magic done on your behalf.",conducting:"Orchestrating a flow or scenario.",beacon:"Broadcasting: broker up, dashboard discoverable.",notification:"A new item arrived; badge count went up.",disconnected:"Device or dashboard connection dropped.",dizzy:"Too many re-renders; a render storm.",overheated:"CPU or thermal pressure; perf meltdown.",confused:"Unknown or unparseable data.",stare:"Watching for a specific event; recording armed.",walking:"Navigating between routes.",goingaway:"Leaving a screen; a tool closing.",eureka:"Root cause found; a diff that explains it.",grooving:"Everything healthy; nothing to do but vibe.",hatmishap:"A small recoverable slip; retry worked.",lowbattery:"Device battery low; power-saving mode.",wake:"Tool re-opened; capture resumed.",builder:"Assembling a state tree or fixture.",mini:"Compact or inline placements.",minityping:"A compact typing indicator.",happydance:"A milestone: all tests green, release done.",jumping:"Jump to a route, a log line, a snapshot.",loading:"Generic indeterminate loading.",progress:"Determinate progress: download, batch, upload.",hourglass:"Waiting on a timer; a scheduled retry.",waiting:"Waiting for a device, the first event, a reply.",syncing:"Syncing with the desktop dashboard or broker.",downloading:"Pulling a snapshot, an update, a payload.",uploading:"Sending a report, a snapshot, feedback.",connecting:"Connecting to a device or broker.",scanning:"Scanning for targets, keys, assets, fibers.",searching:"A search running; filtering a long list.",fishing:"Capture on, nothing captured yet.",empty:"An empty list: no requests, no logs, no keys.",shrug:"No result and no explanation available.",tumbleweed:"Deliberately empty; nothing happened for a while.",puzzled:"Unexpected shape; needs a second look.",warning:"A warning: deprecated, risky, near a limit.",crash:"The app crashed; a fatal was captured.",panic:"Many errors at once; an error cascade.",sos:"Critical: the app cannot continue.",alarm:"An alert rule fired; attention now.",offline:"No network; device offline.",timeout:"A request or connection timed out.",locked:"A Pro feature; a locked setting.",denied:"Permission denied; blocked by policy.",broken:"Corrupted data; a broken persisted value.",sad:"Nothing matched; a failed search.",rain:"A bad run: errors piling up.",sick:"Unhealthy config; env check failing.",flood:"Buffer full; too many events to keep up.",bug:"A bug was found (or is being reported).",frozen:"The UI thread froze; a hung frame.",snail:"Slow: a long request, a slow render.",angry:"Rate limited, rejected, forbidden.",ghost:"Stale or detached: an unmounted component, an old snapshot.",nervous:"A risky action pending confirmation.",detective:"Investigating; root-cause analysis.",reading:"Reading docs or a long log.",success:"Action completed; a rule saved, a replay done.",celebrate:"A big success: first capture, setup complete.",thumbsup:"Approved; looks good; confirmation received.",party:"Release shipped; a version milestone.",trophy:"Best benchmark yet; a personal record.",starred:"Pinned, favourited, starred.",love:"Thanks and delight; feedback sent.",unlocked:"Pro unlocked; license activated.",cool:"Perfect score; zero warnings.",flexing:"Fast: a great perf result.",zen:"All quiet; nothing needs attention.",pro:"Pro plan active.",gift:"New version or feature available.",map:"Route inspector; where am I in the navigator.",photo:"Screenshot taken; image captured.",painting:"Assets and design overlays; theming.",printing:"Console streaming; logs arriving.",storing:"Saving to storage; persisting.",charting:"Metrics building up; perf charts.",stopwatch:"Benchmark running; timing a request.",spotlight:"Highlighting renders; spotlight on a component.",keys:"Environment variables and secrets.",filtering:"Filters active; a subset shown.",talking:"Ask Buoy answering; a message in flight.",listening:"Listening for events; waiting for input.",recording:"Capture on; recording a session.",paused:"Capture paused.",rewind:"Time Machine: stepping back through snapshots.",trash:"Cleared: list emptied, cache purged.",disguise:"Impersonating another user.",guard:"Sentry or a guard rail caught something.",action:"A scenario or flow started.",robot:"The MCP agent is driving the tools.",plug:"Device connected; plugin installed.",handshake:"Paired with the desktop dashboard.",saved:"Saved: request, snapshot, rule.",copied:"Copied to clipboard.",pinned:"Item pinned; survives clears.",spinning:"Refreshing; reloading the app.",swimming:"Making progress through a long job.",diving:"Drilling into a detail or nested value.",balloon:"Upgrading; a plan change in progress.",landing:"Tool mounted; first open.",bubbles:"A light idle for empty side panels.",bow:"Thank you; a graceful exit.",wave:"Welcome; onboarding; first run.",coffee:"A long build; take a break.",present:"Presenting a tool: onboarding, a tool's intro card.",lift:"Showing off a tool: a feature announcement.",carry:"Bringing a tool along: install, add-to-dial.",hug:"A favourite tool: pinned, most used.",lean:"A tool at rest: its idle or settings screen.",point:"Pointing at a tool: a hint, a next step.",static:"Favicons, stills, icons."};const OTTO_CYCLE={progress:32,hourglass:20,fishing:32,tumbleweed:28,crash:20,sos:34,locked:20,unlocked:20,broken:24,snail:36,reading:24,storing:24,diving:24,balloon:24,swimming:8,scanning:14,connecting:14,loading:10,syncing:10,downloading:12,uploading:12,alarm:8,flood:8,panic:8,nervous:8,keys:8,flexing:8};const OTTO_REEL=exports.OTTO_REEL=[["idle",30],["thinking",20],["typing",20],["happy",14],["debugging",18],["idle",14],["building",16],["carrying",14],["pushing",14],["sweeping",14],["juggling",16],["wizard",14],["conducting",14],["beacon",14],["notification",16],["error",12],["disconnected",14],["dizzy",14],["overheated",24],["confused",18],["stare",20],["walking",32],["eureka",24],["grooving",16],["hatmishap",32],["builder",16],["happydance",12],["jumping",16],["mini",16],["minityping",12],["lowbattery",24],["sleep",24],["wake",30],["peek",18],["goingaway",26],...["loading","progress","hourglass","waiting","syncing","downloading","uploading","connecting","scanning","searching","fishing","empty","shrug","tumbleweed","puzzled","warning","crash","panic","sos","alarm","offline","timeout","locked","unlocked","denied","broken","sad","rain","sick","flood","bug","frozen","snail","angry","ghost","nervous","detective","reading","success","celebrate","thumbsup","party","trophy","starred","love","wave","bow","cool","flexing","zen","recording","paused","filtering","pinned","rewind","storing","printing","stopwatch","spotlight","keys","map","photo","painting","disguise","pro","talking","handshake","robot","plug","gift","action","guard","coffee","swimming","diving","balloon","landing","spinning","bubbles","trash","saved","copied","charting","present","lift","carry","hug","lean","point"].map(t=>[t,OTTO_CYCLE[t]??16])];const REEL_LENGTH=OTTO_REEL.reduce((t,e)=>t+e[1],0);function ottoReel(t){let e=(t%REEL_LENGTH+REEL_LENGTH)%REEL_LENGTH;for(const[n,s]of OTTO_REEL){if(e<s)return{state:n,local:e};e-=s}return{state:"idle",local:0}}function renderOttoFrame(t,e,n={}){const s=Math.max(0,Math.floor(e));const o=OTTO_STATES[t](s);return compose(draw(o),s,{water:n.water??true,keyline:n.keyline??true,submerged:!!o.submerged})}function ottoRuns(t){const e=[];for(let n=0;n<t.length;n++){const s=t[n];let o=0;while(o<s.length){const r=s[o];let a=1;while(o+a<s.length&&s[o+a]===r)a++;if(r!=="."){const i=OTTO_PALETTE[r];if(i)e.push({x:o,y:n,w:a,color:i})}o+=a}}return e}