@buoy-gg/shared-ui 7.0.36 → 7.0.38

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 (284) hide show
  1. package/README.md +33 -26
  2. package/floating.d.ts +1 -0
  3. package/floating.js +2 -0
  4. package/lib/commonjs/JsModal.js +16 -1
  5. package/lib/commonjs/JsModal.web.js +16 -1
  6. package/lib/commonjs/dataViewer/CyberpunkInput.js +6 -1
  7. package/lib/commonjs/dataViewer/LiveExplorer.js +28 -16
  8. package/lib/commonjs/hooks/safe-area-impl.js +1 -1
  9. package/lib/commonjs/icons/ReactQueryIcon.js +9 -161
  10. package/lib/commonjs/icons/SentryBugIcon.js +9 -171
  11. package/lib/commonjs/index.js +57 -6
  12. package/lib/commonjs/license/AccountSetup.js +56 -0
  13. package/lib/commonjs/license/AccountSetup.web.js +81 -0
  14. package/lib/commonjs/license/FeatureGate.js +10 -43
  15. package/lib/commonjs/license/FreeAccountPrompt.js +35 -12
  16. package/lib/commonjs/license/index.js +0 -6
  17. package/lib/commonjs/license/licenseModule.js +56 -36
  18. package/lib/commonjs/license/tierLimits.js +12 -63
  19. package/lib/commonjs/storage/devToolsStorageKeys.js +8 -1
  20. package/lib/commonjs/stores/BaseEventStore.js +21 -5
  21. package/lib/commonjs/stores/createToolStore.js +21 -3
  22. package/lib/commonjs/stores/floatingToolStore.js +71 -0
  23. package/lib/commonjs/stores/floatingToolStore.test.js +112 -0
  24. package/lib/commonjs/sync/toolActionRegistry.js +85 -2
  25. package/lib/commonjs/ui/backgrounds/README.md +52 -0
  26. package/lib/commonjs/ui/backgrounds/ToolBackground.js +4 -2
  27. package/lib/commonjs/ui/backgrounds/index.js +8 -1
  28. package/lib/commonjs/ui/backgrounds/registry.js +8 -0
  29. package/lib/commonjs/ui/backgrounds/variants/wormhole/motion.js +48 -0
  30. package/lib/commonjs/ui/backgrounds/variants/wormhole/textures.js +3 -0
  31. package/lib/commonjs/ui/backgrounds/variants/wormhole.js +133 -0
  32. package/lib/commonjs/ui/components/ClipboardHintBanner.js +5 -6
  33. package/lib/commonjs/ui/components/CompactRow.js +94 -74
  34. package/lib/commonjs/ui/components/DraggableHeader.js +16 -1
  35. package/lib/commonjs/ui/components/HeaderSearchButton.js +17 -4
  36. package/lib/commonjs/ui/floating/FloatingTool.js +1010 -0
  37. package/lib/commonjs/ui/floating/FloatingTool.web.js +591 -0
  38. package/lib/commonjs/ui/floating/FloatingToolHost.js +32 -0
  39. package/lib/commonjs/ui/floating/FloatingToolHost.web.js +28 -0
  40. package/lib/commonjs/ui/floating/index.js +105 -0
  41. package/lib/commonjs/ui/floating/index.web.js +105 -0
  42. package/lib/commonjs/ui/floating/onboardingConstants.js +70 -0
  43. package/lib/commonjs/ui/floating/onboardingConstants.web.js +34 -0
  44. package/lib/commonjs/ui/gameUI/constants/gameUIColors.js +3 -1
  45. package/lib/commonjs/ui/index.js +118 -2
  46. package/lib/commonjs/ui/night/nightTheme.js +10 -0
  47. package/lib/commonjs/ui/night/primitives.js +22 -5
  48. package/lib/commonjs/ui/otto/OttoSceneView.js +69 -0
  49. package/lib/commonjs/ui/otto/index.js +22 -0
  50. package/lib/commonjs/ui/otto/ottoEngine.js +10 -7
  51. package/lib/commonjs/ui/otto/ottoScenes.js +949 -0
  52. package/lib/commonjs/utils/minimalSuperJSON.js +13 -3
  53. package/lib/module/JsModal.js +16 -1
  54. package/lib/module/JsModal.web.js +16 -1
  55. package/lib/module/dataViewer/CyberpunkInput.js +6 -1
  56. package/lib/module/dataViewer/LiveExplorer.js +28 -16
  57. package/lib/module/hooks/safe-area-impl.js +1 -1
  58. package/lib/module/icons/ReactQueryIcon.js +9 -161
  59. package/lib/module/icons/SentryBugIcon.js +9 -171
  60. package/lib/module/index.js +4 -1
  61. package/lib/module/license/AccountSetup.js +52 -0
  62. package/lib/module/license/AccountSetup.web.js +77 -0
  63. package/lib/module/license/FeatureGate.js +10 -43
  64. package/lib/module/license/FreeAccountPrompt.js +35 -12
  65. package/lib/module/license/index.js +1 -1
  66. package/lib/module/license/licenseModule.js +50 -35
  67. package/lib/module/license/tierLimits.js +13 -63
  68. package/lib/module/storage/devToolsStorageKeys.js +8 -1
  69. package/lib/module/stores/BaseEventStore.js +21 -5
  70. package/lib/module/stores/createToolStore.js +21 -3
  71. package/lib/module/stores/floatingToolStore.js +61 -0
  72. package/lib/module/stores/floatingToolStore.test.js +111 -0
  73. package/lib/module/sync/toolActionRegistry.js +84 -2
  74. package/lib/module/ui/backgrounds/README.md +52 -0
  75. package/lib/module/ui/backgrounds/ToolBackground.js +4 -2
  76. package/lib/module/ui/backgrounds/index.js +2 -1
  77. package/lib/module/ui/backgrounds/registry.js +8 -0
  78. package/lib/module/ui/backgrounds/variants/wormhole/motion.js +44 -0
  79. package/lib/module/ui/backgrounds/variants/wormhole/textures.js +3 -0
  80. package/lib/module/ui/backgrounds/variants/wormhole.js +129 -0
  81. package/lib/module/ui/components/ClipboardHintBanner.js +5 -6
  82. package/lib/module/ui/components/CompactRow.js +94 -74
  83. package/lib/module/ui/components/DraggableHeader.js +16 -1
  84. package/lib/module/ui/components/HeaderSearchButton.js +17 -4
  85. package/lib/module/ui/floating/FloatingTool.js +1003 -0
  86. package/lib/module/ui/floating/FloatingTool.web.js +590 -0
  87. package/lib/module/ui/floating/FloatingToolHost.js +29 -0
  88. package/lib/module/ui/floating/FloatingToolHost.web.js +25 -0
  89. package/lib/module/ui/floating/index.js +6 -0
  90. package/lib/module/ui/floating/index.web.js +6 -0
  91. package/lib/module/ui/floating/onboardingConstants.js +64 -0
  92. package/lib/module/ui/floating/onboardingConstants.web.js +27 -0
  93. package/lib/module/ui/gameUI/constants/gameUIColors.js +3 -1
  94. package/lib/module/ui/index.js +5 -1
  95. package/lib/module/ui/night/nightTheme.js +10 -0
  96. package/lib/module/ui/night/primitives.js +22 -5
  97. package/lib/module/ui/otto/OttoSceneView.js +64 -0
  98. package/lib/module/ui/otto/index.js +3 -1
  99. package/lib/module/ui/otto/ottoEngine.js +10 -7
  100. package/lib/module/ui/otto/ottoScenes.js +942 -0
  101. package/lib/module/utils/minimalSuperJSON.js +13 -3
  102. package/lib/typescript/commonjs/JsModal.d.ts +43 -2
  103. package/lib/typescript/commonjs/JsModal.d.ts.map +1 -1
  104. package/lib/typescript/commonjs/JsModal.web.d.ts +5 -2
  105. package/lib/typescript/commonjs/JsModal.web.d.ts.map +1 -1
  106. package/lib/typescript/commonjs/dataViewer/CyberpunkInput.d.ts.map +1 -1
  107. package/lib/typescript/commonjs/dataViewer/LiveExplorer.d.ts.map +1 -1
  108. package/lib/typescript/commonjs/hooks/safe-area-impl.d.ts +1 -1
  109. package/lib/typescript/commonjs/icons/ReactQueryIcon.d.ts +1 -2
  110. package/lib/typescript/commonjs/icons/ReactQueryIcon.d.ts.map +1 -1
  111. package/lib/typescript/commonjs/icons/SentryBugIcon.d.ts +1 -2
  112. package/lib/typescript/commonjs/icons/SentryBugIcon.d.ts.map +1 -1
  113. package/lib/typescript/commonjs/index.d.ts +4 -1
  114. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  115. package/lib/typescript/commonjs/license/AccountSetup.d.ts +4 -0
  116. package/lib/typescript/commonjs/license/AccountSetup.d.ts.map +1 -0
  117. package/lib/typescript/commonjs/license/AccountSetup.web.d.ts +2 -0
  118. package/lib/typescript/commonjs/license/AccountSetup.web.d.ts.map +1 -0
  119. package/lib/typescript/commonjs/license/FeatureGate.d.ts +3 -19
  120. package/lib/typescript/commonjs/license/FeatureGate.d.ts.map +1 -1
  121. package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts +8 -11
  122. package/lib/typescript/commonjs/license/FreeAccountPrompt.d.ts.map +1 -1
  123. package/lib/typescript/commonjs/license/index.d.ts +1 -1
  124. package/lib/typescript/commonjs/license/index.d.ts.map +1 -1
  125. package/lib/typescript/commonjs/license/licenseModule.d.ts +18 -31
  126. package/lib/typescript/commonjs/license/licenseModule.d.ts.map +1 -1
  127. package/lib/typescript/commonjs/license/tierLimits.d.ts +9 -52
  128. package/lib/typescript/commonjs/license/tierLimits.d.ts.map +1 -1
  129. package/lib/typescript/commonjs/storage/devToolsStorageKeys.d.ts +6 -0
  130. package/lib/typescript/commonjs/storage/devToolsStorageKeys.d.ts.map +1 -1
  131. package/lib/typescript/commonjs/stores/BaseEventStore.d.ts.map +1 -1
  132. package/lib/typescript/commonjs/stores/createToolStore.d.ts.map +1 -1
  133. package/lib/typescript/commonjs/stores/floatingToolStore.d.ts +27 -0
  134. package/lib/typescript/commonjs/stores/floatingToolStore.d.ts.map +1 -0
  135. package/lib/typescript/commonjs/stores/floatingToolStore.test.d.ts +2 -0
  136. package/lib/typescript/commonjs/stores/floatingToolStore.test.d.ts.map +1 -0
  137. package/lib/typescript/commonjs/sync/toolActionRegistry.d.ts +4 -32
  138. package/lib/typescript/commonjs/sync/toolActionRegistry.d.ts.map +1 -1
  139. package/lib/typescript/commonjs/ui/backgrounds/ToolBackground.d.ts +7 -1
  140. package/lib/typescript/commonjs/ui/backgrounds/ToolBackground.d.ts.map +1 -1
  141. package/lib/typescript/commonjs/ui/backgrounds/index.d.ts +2 -1
  142. package/lib/typescript/commonjs/ui/backgrounds/index.d.ts.map +1 -1
  143. package/lib/typescript/commonjs/ui/backgrounds/registry.d.ts.map +1 -1
  144. package/lib/typescript/commonjs/ui/backgrounds/types.d.ts +11 -1
  145. package/lib/typescript/commonjs/ui/backgrounds/types.d.ts.map +1 -1
  146. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/motion.d.ts +24 -0
  147. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/motion.d.ts.map +1 -0
  148. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/textures.d.ts +13 -0
  149. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole/textures.d.ts.map +1 -0
  150. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole.d.ts +3 -0
  151. package/lib/typescript/commonjs/ui/backgrounds/variants/wormhole.d.ts.map +1 -0
  152. package/lib/typescript/commonjs/ui/components/ClipboardHintBanner.d.ts.map +1 -1
  153. package/lib/typescript/commonjs/ui/components/CompactRow.d.ts +8 -1
  154. package/lib/typescript/commonjs/ui/components/CompactRow.d.ts.map +1 -1
  155. package/lib/typescript/commonjs/ui/components/DraggableHeader.d.ts +4 -1
  156. package/lib/typescript/commonjs/ui/components/DraggableHeader.d.ts.map +1 -1
  157. package/lib/typescript/commonjs/ui/components/HeaderSearchButton.d.ts +7 -1
  158. package/lib/typescript/commonjs/ui/components/HeaderSearchButton.d.ts.map +1 -1
  159. package/lib/typescript/commonjs/ui/floating/FloatingTool.d.ts +79 -0
  160. package/lib/typescript/commonjs/ui/floating/FloatingTool.d.ts.map +1 -0
  161. package/lib/typescript/commonjs/ui/floating/FloatingTool.web.d.ts +64 -0
  162. package/lib/typescript/commonjs/ui/floating/FloatingTool.web.d.ts.map +1 -0
  163. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.d.ts +3 -0
  164. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.d.ts.map +1 -0
  165. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.web.d.ts +3 -0
  166. package/lib/typescript/commonjs/ui/floating/FloatingToolHost.web.d.ts.map +1 -0
  167. package/lib/typescript/commonjs/ui/floating/index.d.ts +7 -0
  168. package/lib/typescript/commonjs/ui/floating/index.d.ts.map +1 -0
  169. package/lib/typescript/commonjs/ui/floating/index.web.d.ts +7 -0
  170. package/lib/typescript/commonjs/ui/floating/index.web.d.ts.map +1 -0
  171. package/lib/typescript/commonjs/ui/floating/onboardingConstants.d.ts +30 -0
  172. package/lib/typescript/commonjs/ui/floating/onboardingConstants.d.ts.map +1 -0
  173. package/lib/typescript/commonjs/ui/floating/onboardingConstants.web.d.ts +13 -0
  174. package/lib/typescript/commonjs/ui/floating/onboardingConstants.web.d.ts.map +1 -0
  175. package/lib/typescript/commonjs/ui/gameUI/constants/gameUIColors.d.ts +2 -0
  176. package/lib/typescript/commonjs/ui/gameUI/constants/gameUIColors.d.ts.map +1 -1
  177. package/lib/typescript/commonjs/ui/index.d.ts +6 -0
  178. package/lib/typescript/commonjs/ui/index.d.ts.map +1 -1
  179. package/lib/typescript/commonjs/ui/night/nightTheme.d.ts +10 -0
  180. package/lib/typescript/commonjs/ui/night/nightTheme.d.ts.map +1 -1
  181. package/lib/typescript/commonjs/ui/night/primitives.d.ts +10 -3
  182. package/lib/typescript/commonjs/ui/night/primitives.d.ts.map +1 -1
  183. package/lib/typescript/commonjs/ui/otto/OttoSceneView.d.ts +30 -0
  184. package/lib/typescript/commonjs/ui/otto/OttoSceneView.d.ts.map +1 -0
  185. package/lib/typescript/commonjs/ui/otto/index.d.ts +2 -0
  186. package/lib/typescript/commonjs/ui/otto/index.d.ts.map +1 -1
  187. package/lib/typescript/commonjs/ui/otto/ottoEngine.d.ts +1 -1
  188. package/lib/typescript/commonjs/ui/otto/ottoEngine.d.ts.map +1 -1
  189. package/lib/typescript/commonjs/ui/otto/ottoScenes.d.ts +75 -0
  190. package/lib/typescript/commonjs/ui/otto/ottoScenes.d.ts.map +1 -0
  191. package/lib/typescript/commonjs/utils/minimalSuperJSON.d.ts.map +1 -1
  192. package/lib/typescript/module/JsModal.d.ts +43 -2
  193. package/lib/typescript/module/JsModal.d.ts.map +1 -1
  194. package/lib/typescript/module/JsModal.web.d.ts +5 -2
  195. package/lib/typescript/module/JsModal.web.d.ts.map +1 -1
  196. package/lib/typescript/module/dataViewer/CyberpunkInput.d.ts.map +1 -1
  197. package/lib/typescript/module/dataViewer/LiveExplorer.d.ts.map +1 -1
  198. package/lib/typescript/module/hooks/safe-area-impl.d.ts +1 -1
  199. package/lib/typescript/module/icons/ReactQueryIcon.d.ts +1 -2
  200. package/lib/typescript/module/icons/ReactQueryIcon.d.ts.map +1 -1
  201. package/lib/typescript/module/icons/SentryBugIcon.d.ts +1 -2
  202. package/lib/typescript/module/icons/SentryBugIcon.d.ts.map +1 -1
  203. package/lib/typescript/module/index.d.ts +4 -1
  204. package/lib/typescript/module/index.d.ts.map +1 -1
  205. package/lib/typescript/module/license/AccountSetup.d.ts +4 -0
  206. package/lib/typescript/module/license/AccountSetup.d.ts.map +1 -0
  207. package/lib/typescript/module/license/AccountSetup.web.d.ts +2 -0
  208. package/lib/typescript/module/license/AccountSetup.web.d.ts.map +1 -0
  209. package/lib/typescript/module/license/FeatureGate.d.ts +3 -19
  210. package/lib/typescript/module/license/FeatureGate.d.ts.map +1 -1
  211. package/lib/typescript/module/license/FreeAccountPrompt.d.ts +8 -11
  212. package/lib/typescript/module/license/FreeAccountPrompt.d.ts.map +1 -1
  213. package/lib/typescript/module/license/index.d.ts +1 -1
  214. package/lib/typescript/module/license/index.d.ts.map +1 -1
  215. package/lib/typescript/module/license/licenseModule.d.ts +18 -31
  216. package/lib/typescript/module/license/licenseModule.d.ts.map +1 -1
  217. package/lib/typescript/module/license/tierLimits.d.ts +9 -52
  218. package/lib/typescript/module/license/tierLimits.d.ts.map +1 -1
  219. package/lib/typescript/module/storage/devToolsStorageKeys.d.ts +6 -0
  220. package/lib/typescript/module/storage/devToolsStorageKeys.d.ts.map +1 -1
  221. package/lib/typescript/module/stores/BaseEventStore.d.ts.map +1 -1
  222. package/lib/typescript/module/stores/createToolStore.d.ts.map +1 -1
  223. package/lib/typescript/module/stores/floatingToolStore.d.ts +27 -0
  224. package/lib/typescript/module/stores/floatingToolStore.d.ts.map +1 -0
  225. package/lib/typescript/module/stores/floatingToolStore.test.d.ts +2 -0
  226. package/lib/typescript/module/stores/floatingToolStore.test.d.ts.map +1 -0
  227. package/lib/typescript/module/sync/toolActionRegistry.d.ts +4 -32
  228. package/lib/typescript/module/sync/toolActionRegistry.d.ts.map +1 -1
  229. package/lib/typescript/module/ui/backgrounds/ToolBackground.d.ts +7 -1
  230. package/lib/typescript/module/ui/backgrounds/ToolBackground.d.ts.map +1 -1
  231. package/lib/typescript/module/ui/backgrounds/index.d.ts +2 -1
  232. package/lib/typescript/module/ui/backgrounds/index.d.ts.map +1 -1
  233. package/lib/typescript/module/ui/backgrounds/registry.d.ts.map +1 -1
  234. package/lib/typescript/module/ui/backgrounds/types.d.ts +11 -1
  235. package/lib/typescript/module/ui/backgrounds/types.d.ts.map +1 -1
  236. package/lib/typescript/module/ui/backgrounds/variants/wormhole/motion.d.ts +24 -0
  237. package/lib/typescript/module/ui/backgrounds/variants/wormhole/motion.d.ts.map +1 -0
  238. package/lib/typescript/module/ui/backgrounds/variants/wormhole/textures.d.ts +13 -0
  239. package/lib/typescript/module/ui/backgrounds/variants/wormhole/textures.d.ts.map +1 -0
  240. package/lib/typescript/module/ui/backgrounds/variants/wormhole.d.ts +3 -0
  241. package/lib/typescript/module/ui/backgrounds/variants/wormhole.d.ts.map +1 -0
  242. package/lib/typescript/module/ui/components/ClipboardHintBanner.d.ts.map +1 -1
  243. package/lib/typescript/module/ui/components/CompactRow.d.ts +8 -1
  244. package/lib/typescript/module/ui/components/CompactRow.d.ts.map +1 -1
  245. package/lib/typescript/module/ui/components/DraggableHeader.d.ts +4 -1
  246. package/lib/typescript/module/ui/components/DraggableHeader.d.ts.map +1 -1
  247. package/lib/typescript/module/ui/components/HeaderSearchButton.d.ts +7 -1
  248. package/lib/typescript/module/ui/components/HeaderSearchButton.d.ts.map +1 -1
  249. package/lib/typescript/module/ui/floating/FloatingTool.d.ts +79 -0
  250. package/lib/typescript/module/ui/floating/FloatingTool.d.ts.map +1 -0
  251. package/lib/typescript/module/ui/floating/FloatingTool.web.d.ts +64 -0
  252. package/lib/typescript/module/ui/floating/FloatingTool.web.d.ts.map +1 -0
  253. package/lib/typescript/module/ui/floating/FloatingToolHost.d.ts +3 -0
  254. package/lib/typescript/module/ui/floating/FloatingToolHost.d.ts.map +1 -0
  255. package/lib/typescript/module/ui/floating/FloatingToolHost.web.d.ts +3 -0
  256. package/lib/typescript/module/ui/floating/FloatingToolHost.web.d.ts.map +1 -0
  257. package/lib/typescript/module/ui/floating/index.d.ts +7 -0
  258. package/lib/typescript/module/ui/floating/index.d.ts.map +1 -0
  259. package/lib/typescript/module/ui/floating/index.web.d.ts +7 -0
  260. package/lib/typescript/module/ui/floating/index.web.d.ts.map +1 -0
  261. package/lib/typescript/module/ui/floating/onboardingConstants.d.ts +30 -0
  262. package/lib/typescript/module/ui/floating/onboardingConstants.d.ts.map +1 -0
  263. package/lib/typescript/module/ui/floating/onboardingConstants.web.d.ts +13 -0
  264. package/lib/typescript/module/ui/floating/onboardingConstants.web.d.ts.map +1 -0
  265. package/lib/typescript/module/ui/gameUI/constants/gameUIColors.d.ts +2 -0
  266. package/lib/typescript/module/ui/gameUI/constants/gameUIColors.d.ts.map +1 -1
  267. package/lib/typescript/module/ui/index.d.ts +6 -0
  268. package/lib/typescript/module/ui/index.d.ts.map +1 -1
  269. package/lib/typescript/module/ui/night/nightTheme.d.ts +10 -0
  270. package/lib/typescript/module/ui/night/nightTheme.d.ts.map +1 -1
  271. package/lib/typescript/module/ui/night/primitives.d.ts +10 -3
  272. package/lib/typescript/module/ui/night/primitives.d.ts.map +1 -1
  273. package/lib/typescript/module/ui/otto/OttoSceneView.d.ts +30 -0
  274. package/lib/typescript/module/ui/otto/OttoSceneView.d.ts.map +1 -0
  275. package/lib/typescript/module/ui/otto/index.d.ts +2 -0
  276. package/lib/typescript/module/ui/otto/index.d.ts.map +1 -1
  277. package/lib/typescript/module/ui/otto/ottoEngine.d.ts +1 -1
  278. package/lib/typescript/module/ui/otto/ottoEngine.d.ts.map +1 -1
  279. package/lib/typescript/module/ui/otto/ottoScenes.d.ts +75 -0
  280. package/lib/typescript/module/ui/otto/ottoScenes.d.ts.map +1 -0
  281. package/lib/typescript/module/utils/minimalSuperJSON.d.ts.map +1 -1
  282. package/package.json +25 -5
  283. package/scripts/generate-wormhole-textures.cjs +261 -0
  284. package/scripts/test-wormhole-motion.cjs +59 -0
@@ -0,0 +1,77 @@
1
+ "use strict";
2
+
3
+ import { useState } from "react";
4
+ import { useAccountAccess, LicenseManager } from "@buoy-gg/license";
5
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
6
+ export function AccountSetup() {
7
+ const access = useAccountAccess();
8
+ const [open, setOpen] = useState(false);
9
+ return /*#__PURE__*/_jsxs("div", {
10
+ style: {
11
+ position: "fixed",
12
+ right: 16,
13
+ bottom: 30,
14
+ zIndex: 99999,
15
+ color: "#e2e8f0",
16
+ fontFamily: "system-ui"
17
+ },
18
+ children: [/*#__PURE__*/_jsx("button", {
19
+ onClick: () => setOpen(!open),
20
+ style: {
21
+ background: "#080a0b",
22
+ color: "#20C997",
23
+ border: "1px solid #20C997",
24
+ borderRadius: 24,
25
+ padding: "12px 16px"
26
+ },
27
+ children: access.status === "initializing" ? "BUOY · Checking…" : "BUOY · Sign in"
28
+ }), open && /*#__PURE__*/_jsxs("section", {
29
+ "aria-label": "Buoy account setup",
30
+ style: {
31
+ position: "absolute",
32
+ right: 0,
33
+ bottom: 55,
34
+ width: 300,
35
+ maxWidth: "85vw",
36
+ background: "#080a0b",
37
+ border: "1px solid #20C997",
38
+ borderRadius: 12,
39
+ padding: 20
40
+ },
41
+ children: [/*#__PURE__*/_jsx("h3", {
42
+ children: "Sign in to use Buoy"
43
+ }), /*#__PURE__*/_jsx("p", {
44
+ children: "A Free or Pro account is required. Run this command in your project, then reload the app."
45
+ }), /*#__PURE__*/_jsx("pre", {
46
+ children: "npx buoy login"
47
+ }), LicenseManager.getState().error && /*#__PURE__*/_jsx("p", {
48
+ role: "status",
49
+ children: LicenseManager.getState().error
50
+ }), /*#__PURE__*/_jsx("button", {
51
+ onClick: () => {
52
+ const key = LicenseManager.getState().licenseKey;
53
+ if (key) void LicenseManager.setLicenseKey(key, {
54
+ force: true
55
+ });
56
+ },
57
+ children: "Retry verification"
58
+ }), /*#__PURE__*/_jsx("p", {
59
+ children: /*#__PURE__*/_jsx("a", {
60
+ style: {
61
+ color: "#20C997"
62
+ },
63
+ href: "https://github.com/Buoy-gg/buoy/issues/new/choose",
64
+ target: "_blank",
65
+ rel: "noreferrer",
66
+ children: "Contact support on GitHub"
67
+ })
68
+ }), /*#__PURE__*/_jsx("a", {
69
+ style: {
70
+ color: "#20C997"
71
+ },
72
+ href: "mailto:support@buoy.gg",
73
+ children: "support@buoy.gg"
74
+ })]
75
+ })]
76
+ });
77
+ }
@@ -12,9 +12,6 @@ import { gameUIColors, buoyColors } from "../ui/gameUI/constants/gameUIColors.js
12
12
  import { LockIcon, X, Zap, Shield, Clock, Check } from "../icons/lucide-icons.js";
13
13
  import { LicenseEntryModal } from "./LicenseEntryModal.js";
14
14
  import { openPricing, isWeb } from "./openPricing.js";
15
- import { FreeAccountPrompt } from "./FreeAccountPrompt.js";
16
- import { getUseTier } from "./licenseModule.js";
17
- import { freeKeyRaises } from "./tierLimits.js";
18
15
  import { useIsPro, useLicense, useProAccess } from "@buoy-gg/license";
19
16
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
20
17
  // Weekend Pass branding — a distinct violet so it never reads as the gold PRO.
@@ -52,19 +49,14 @@ export const ProBadge = ({
52
49
  export const ProUpgradeModal = ({
53
50
  visible,
54
51
  onClose,
55
- featureName = "This feature",
56
- limitKey
52
+ featureName = "This feature"
57
53
  }) => {
58
54
  // Simple wrapper around UpgradeModal with minimal description and no benefits
59
55
  return /*#__PURE__*/_jsx(UpgradeModal, {
60
56
  visible: visible,
61
57
  onClose: onClose,
62
- featureName: featureName
63
- // Only meaningful when this upsell is about a LIMIT; without it the
64
- // description below (which promises Pro) is the accurate message.
65
- ,
66
- limitKey: limitKey,
67
- description: limitKey ? undefined : `${featureName} requires a Pro subscription.`
58
+ featureName: featureName,
59
+ description: `${featureName} requires a Pro subscription.`
68
60
  });
69
61
  };
70
62
  /**
@@ -74,13 +66,9 @@ export const ProUpgradeModal = ({
74
66
  export const UpgradePrompt = ({
75
67
  featureName,
76
68
  onUpgradePress,
77
- compact = false,
78
- limitKey
69
+ compact = false
79
70
  }) => {
80
71
  const [showLicenseModal, setShowLicenseModal] = useState(false);
81
- // Only offer the free key when it would actually raise this limit — see
82
- // UpgradeModalProps.limitKey.
83
- const isAnonymous = getUseTier()() === "anonymous" && limitKey != null && freeKeyRaises(limitKey);
84
72
  const handlePress = useCallback(() => {
85
73
  if (onUpgradePress) {
86
74
  onUpgradePress();
@@ -108,11 +96,7 @@ export const UpgradePrompt = ({
108
96
  style: styles.compactText,
109
97
  children: "PRO"
110
98
  })]
111
- }), isAnonymous ? /*#__PURE__*/_jsx(FreeAccountPrompt, {
112
- visible: showLicenseModal,
113
- onClose: handleCloseModal,
114
- featureName: featureName
115
- }) : /*#__PURE__*/_jsx(LicenseEntryModal, {
99
+ }), /*#__PURE__*/_jsx(LicenseEntryModal, {
116
100
  visible: showLicenseModal,
117
101
  onClose: handleCloseModal
118
102
  })]
@@ -129,27 +113,23 @@ export const UpgradePrompt = ({
129
113
  })
130
114
  }), /*#__PURE__*/_jsx(Text, {
131
115
  style: styles.title,
132
- children: isAnonymous ? "Get a free key" : "Pro Feature"
116
+ children: "Pro Feature"
133
117
  }), featureName && /*#__PURE__*/_jsx(Text, {
134
118
  style: styles.featureName,
135
119
  children: featureName
136
120
  }), /*#__PURE__*/_jsx(Text, {
137
121
  style: styles.description,
138
- children: isAnonymous ? "Buoy works without an account, with a small slice of each tool. A free key opens it up." : "Upgrade to React Buoy Pro to unlock this feature and more."
122
+ children: "Upgrade to React Buoy Pro to unlock this feature and more."
139
123
  }), /*#__PURE__*/_jsx(TouchableOpacity, {
140
124
  style: styles.upgradeButton,
141
125
  onPress: handlePress,
142
126
  activeOpacity: 0.8,
143
127
  children: /*#__PURE__*/_jsx(Text, {
144
128
  style: styles.upgradeButtonText,
145
- children: isAnonymous ? "Get a free key" : "Upgrade to Pro"
129
+ children: "Upgrade to Pro"
146
130
  })
147
131
  })]
148
- }), isAnonymous ? /*#__PURE__*/_jsx(FreeAccountPrompt, {
149
- visible: showLicenseModal,
150
- onClose: handleCloseModal,
151
- featureName: featureName
152
- }) : /*#__PURE__*/_jsx(LicenseEntryModal, {
132
+ }), /*#__PURE__*/_jsx(LicenseEntryModal, {
153
133
  visible: showLicenseModal,
154
134
  onClose: handleCloseModal
155
135
  })]
@@ -328,14 +308,8 @@ export const UpgradeModal = ({
328
308
  onClose,
329
309
  featureName = "This Feature",
330
310
  description,
331
- benefits,
332
- limitKey
311
+ benefits
333
312
  }) => {
334
- // Anonymous users get a different ask — but ONLY when a free key would
335
- // actually fix what they just hit. Everything else here is Pro-exclusive,
336
- // where a free key changes nothing and offering one would be dishonest.
337
- const tier = getUseTier()();
338
- const offerFreeKey = tier === "anonymous" && limitKey != null && freeKeyRaises(limitKey);
339
313
  const hasBenefits = benefits && benefits.length > 0;
340
314
  const [showLicenseModal, setShowLicenseModal] = useState(false);
341
315
  const license = useLicense();
@@ -358,13 +332,6 @@ export const UpgradeModal = ({
358
332
  onClose();
359
333
  }, [onClose]);
360
334
  if (!visible) return null;
361
- if (offerFreeKey) {
362
- return /*#__PURE__*/_jsx(FreeAccountPrompt, {
363
- visible: visible,
364
- onClose: onClose,
365
- featureName: featureName === "This Feature" ? undefined : featureName
366
- });
367
- }
368
335
  return /*#__PURE__*/_jsxs(_Fragment, {
369
336
  children: [/*#__PURE__*/_jsx(Modal, {
370
337
  visible: visible && !showLicenseModal,
@@ -1,16 +1,15 @@
1
1
  "use strict";
2
2
 
3
3
  /**
4
- * The upsell an ANONYMOUS user sees — someone with no key at all.
4
+ * The account setup sheet — what a locked manager shows instead of the tools.
5
5
  *
6
- * Deliberately not the Pro modal. Their next step is free and takes about
7
- * thirty seconds, so asking them for money would be asking the wrong question
8
- * at the wrong moment, and would suppress exactly the signup this exists to
9
- * produce. Pro is still offered, as a secondary action.
6
+ * Deliberately not the Pro modal. The next step is a free account and takes
7
+ * about thirty seconds, so asking for money here would be asking the wrong
8
+ * question at the wrong moment. Pro is still offered, as a secondary action.
10
9
  *
11
- * The command is shown inline and copyable rather than linked, because there is
12
- * no grace period: someone who just watched their limits shrink needs the fix
13
- * in front of them, not a link to a page that has a link to a command.
10
+ * The command is shown inline and copyable rather than linked, because
11
+ * someone who cannot open the tools needs the fix in front of them, not a link
12
+ * to a page that has a link to a command.
14
13
  */
15
14
 
16
15
  import React, { useCallback, useEffect, useRef, useState } from "react";
@@ -19,15 +18,16 @@ import { buoyColors } from "../ui/gameUI/constants/gameUIColors.js";
19
18
  import { Check, Copy, X } from "../icons/lucide-icons.js";
20
19
  import { copyToClipboard } from "../clipboard/index.js";
21
20
  import { openPricing } from "./openPricing.js";
21
+ import { getUseAccountAccess, retryAccountAccess } from "./licenseModule.js";
22
22
  import { monoFont } from "../ui/fonts.js";
23
23
  /** The one thing a reader has to be able to act on. */
24
24
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
25
25
  export const LOGIN_COMMAND = "npx buoy login";
26
26
  export const FreeAccountPrompt = ({
27
27
  visible,
28
- onClose,
29
- featureName
28
+ onClose
30
29
  }) => {
30
+ const access = getUseAccountAccess()();
31
31
  const [copied, setCopied] = useState(false);
32
32
  const resetTimer = useRef(null);
33
33
  useEffect(() => () => {
@@ -65,10 +65,10 @@ export const FreeAccountPrompt = ({
65
65
  })
66
66
  }), /*#__PURE__*/_jsx(Text, {
67
67
  style: styles.title,
68
- children: featureName ? `More ${featureName}` : "See more"
68
+ children: access.status === "initializing" ? "Checking your account…" : "Sign in to use Buoy"
69
69
  }), /*#__PURE__*/_jsx(Text, {
70
70
  style: styles.subtitle,
71
- children: "Buoy runs without an account \u2014 you just get a small slice of each tool. A free key opens it up."
71
+ children: "A Free or Pro account is required. Run this command in your project, then reload the app to use your account key."
72
72
  }), /*#__PURE__*/_jsxs(TouchableOpacity, {
73
73
  style: styles.command,
74
74
  onPress: handleCopy,
@@ -84,9 +84,32 @@ export const FreeAccountPrompt = ({
84
84
  size: 14,
85
85
  color: buoyColors.textMuted
86
86
  })]
87
+ }), access.status !== "admitted" && /*#__PURE__*/_jsx(TouchableOpacity, {
88
+ style: styles.secondary,
89
+ onPress: () => {
90
+ void retryAccountAccess();
91
+ },
92
+ children: /*#__PURE__*/_jsx(Text, {
93
+ style: styles.secondaryText,
94
+ children: "Retry verification"
95
+ })
87
96
  }), /*#__PURE__*/_jsx(Text, {
88
97
  style: styles.reassure,
89
98
  children: "Free forever. No card. About thirty seconds."
99
+ }), /*#__PURE__*/_jsx(TouchableOpacity, {
100
+ style: styles.secondary,
101
+ onPress: () => openPricing("https://github.com/Buoy-gg/buoy/issues/new/choose"),
102
+ children: /*#__PURE__*/_jsx(Text, {
103
+ style: styles.secondaryText,
104
+ children: "Contact support on GitHub"
105
+ })
106
+ }), /*#__PURE__*/_jsx(TouchableOpacity, {
107
+ style: styles.secondary,
108
+ onPress: () => openPricing("mailto:support@buoy.gg"),
109
+ children: /*#__PURE__*/_jsx(Text, {
110
+ style: styles.secondaryText,
111
+ children: "Email support@buoy.gg"
112
+ })
90
113
  }), /*#__PURE__*/_jsx(TouchableOpacity, {
91
114
  style: styles.secondary,
92
115
  onPress: () => openPricing(),
@@ -6,4 +6,4 @@ export { FreeAccountPrompt, LOGIN_COMMAND } from "./FreeAccountPrompt.js";
6
6
  // Lazy license-module access lives in ./licenseModule so tierLimits can use it
7
7
  // without an import cycle. Re-exported here to keep the existing surface.
8
8
  export { getUseIsPro, getUseLicense, getUseTier } from "./licenseModule.js";
9
- export { TIER_LIMITS, useLimit, resolveEffectiveTier, freeKeyRaises } from "./tierLimits.js";
9
+ export { TIER_LIMITS, useLimit, resolveEffectiveTier } from "./tierLimits.js";
@@ -1,30 +1,30 @@
1
1
  "use strict";
2
2
 
3
3
  /**
4
- * Centralized lazy loading of `@buoy-gg/license`.
4
+ * Centralized access of `@buoy-gg/license`.
5
5
  *
6
6
  * This is the SINGLE place any package resolves license hooks — tools must not
7
- * `require("@buoy-gg/license")` themselves. Lives in its own module (rather
7
+ * resolve the license module themselves. Lives in its own module (rather
8
8
  * than `./index`) so `tierLimits` can consume it without an import cycle.
9
9
  */
10
10
 
11
- /** Access tier. Mirrors BuoyTier in @buoy-gg/license. */
11
+ import * as licenseModule from "@buoy-gg/license";
12
+
13
+ /** Tier. Mirrors BuoyTier in @buoy-gg/license. */
12
14
 
13
15
  let _useIsPro = null;
14
16
  let _useLicense = null;
15
17
  let _useTier = null;
16
- let _anonymousTierEnabled = null;
17
18
  let _licenseLoadAttempted = false;
18
19
  function loadLicenseModuleCentral() {
19
20
  if (_licenseLoadAttempted) return;
20
21
  _licenseLoadAttempted = true;
21
22
  try {
22
- const mod = require("@buoy-gg/license");
23
+ const mod = licenseModule;
23
24
  if (mod) {
24
25
  _useIsPro = mod.useIsPro ?? null;
25
26
  _useLicense = mod.useLicense ?? null;
26
27
  _useTier = mod.useTier ?? null;
27
- _anonymousTierEnabled = typeof mod.ANONYMOUS_TIER_ENABLED === "boolean" ? mod.ANONYMOUS_TIER_ENABLED : null;
28
28
  }
29
29
  } catch {
30
30
  // License package not available - will use fallback
@@ -54,39 +54,54 @@ export function getUseLicense() {
54
54
  }
55
55
 
56
56
  /**
57
- * Get the useTier hook from @buoy-gg/license.
58
- *
59
- * Falls back to `"free"` — NOT `"anonymous"` — when the license package can't
60
- * be resolved. That deliberately matches the existing `getUseIsPro()` fallback,
61
- * which yields free-tier behavior today, and it picks the safer failure:
62
- *
63
- * - falling back to "anonymous" would let one bundler quirk silently cut every
64
- * legitimate user's limits by ~80%;
65
- * - falling back to "free" costs no revenue, because Pro still requires a key
66
- * that a live license server validated — this path can never grant Pro.
67
- *
68
- * Reaching it at all requires `@buoy-gg/license` to be missing, and it is a
69
- * hard dependency of `@buoy-gg/core`.
57
+ * Falls back to "free" without the license package. That grants nothing: a
58
+ * missing license module also means no account admission, and nothing is
59
+ * exposed without it.
70
60
  */
71
61
  export function getUseTier() {
72
62
  loadLicenseModuleCentral();
73
63
  return _useTier ?? (() => "free");
74
64
  }
65
+ const LOCKED = {
66
+ status: "locked",
67
+ reason: "account_required",
68
+ validUntil: null
69
+ };
75
70
 
76
- /**
77
- * Whether the anonymous tier is switched on.
78
- *
79
- * The switch itself lives in @buoy-gg/license (see its config.ts) because the
80
- * Weekend Pass change has to flip at the same moment as the reduced limits, and
81
- * those live in different packages. Read through the same lazy loader as the
82
- * hooks so a missing license package degrades gracefully rather than throwing
83
- * at module load.
84
- *
85
- * Falls back to `false` — the anonymous tier off, everyone on free limits —
86
- * which matches the `getUseTier()` fallback of "free". A build that cannot
87
- * resolve the license package must never take limits AWAY from someone.
88
- */
89
- export function isAnonymousTierEnabled() {
90
- loadLicenseModuleCentral();
91
- return _anonymousTierEnabled ?? false;
71
+ // Resolve at the boundary, after module initialization. Do not cache an absent
72
+ // manager during a circular import or grant access for older package versions.
73
+ function accountManager() {
74
+ try {
75
+ const manager = licenseModule.LicenseManager;
76
+ void manager?.initialize?.();
77
+ return manager;
78
+ } catch {
79
+ return null;
80
+ }
81
+ }
82
+ export function getAccountAccess() {
83
+ return accountManager()?.getAccountAccess?.() ?? LOCKED;
84
+ }
85
+ export function hasAccountAccess() {
86
+ return getAccountAccess().status === "admitted";
87
+ }
88
+ export function assertAccountAccess() {
89
+ if (!hasAccountAccess()) throw new Error("A verified Buoy account is required. Run npx buoy login, then reload your app.");
90
+ }
91
+ export function subscribeAccountAccess(listener) {
92
+ return accountManager()?.subscribe?.(listener) ?? (() => {});
93
+ }
94
+ export function getUseAccountAccess() {
95
+ try {
96
+ return licenseModule.useAccountAccess ?? (() => LOCKED);
97
+ } catch {
98
+ return () => LOCKED;
99
+ }
100
+ }
101
+ export async function retryAccountAccess() {
102
+ const manager = accountManager();
103
+ const key = manager?.getState?.().licenseKey;
104
+ if (key) await manager.setLicenseKey(key, {
105
+ force: true
106
+ });else await manager?.initialize?.();
92
107
  }
@@ -1,103 +1,84 @@
1
1
  "use strict";
2
2
 
3
3
  /**
4
- * Per-tier numeric limits — the ONLY thing that separates anonymous from free.
4
+ * Per-tier numeric limits — the ONLY thing that separates free from pro on a
5
+ * count.
5
6
  *
6
- * Every binary Pro gate (copy-to-clipboard, state editing, storage mutations,
7
- * navigation) is identical for both: locked. That keeps the tier split to one
8
- * table instead of scattered conditionals.
9
- *
10
- * The governing rule: **the free column never moves.** Anonymous is carved out
11
- * BELOW today's free tier — nothing is ever added to free in exchange for an
12
- * account, because that would come straight out of the Pro upgrade.
7
+ * Binary Pro gates (copy-to-clipboard, state editing, storage mutations,
8
+ * navigation) live in the tools themselves; this table is only for "how many".
9
+ * Whether the tools are usable at all is account admission, which is a
10
+ * separate question from the tier and is never expressed as a limit.
13
11
  */
14
12
 
15
- import { getUseIsPro, getUseTier, isAnonymousTierEnabled } from "./licenseModule.js";
13
+ import { getUseIsPro, getUseTier } from "./licenseModule.js";
16
14
  const LIMITS = {
17
15
  // ── network ───────────────────────────────────────────────────────────────
18
16
  "network.requests": {
19
- anonymous: 5,
20
17
  free: 25,
21
18
  pro: Infinity
22
19
  },
23
20
  "network.saved": {
24
- anonymous: 1,
25
21
  free: 5,
26
22
  pro: 50
27
23
  },
28
- // Already 1 for free, so 25% would be 0 — which deletes the feature rather
29
- // than trialling it. Raising the FREE value to make room is not an option.
30
24
  "network.overrideRules": {
31
- anonymous: 1,
32
25
  free: 1,
33
26
  pro: 50
34
27
  },
35
28
  // ── storage ───────────────────────────────────────────────────────────────
36
29
  "storage.events": {
37
- anonymous: 5,
38
30
  free: 25,
39
31
  pro: Infinity
40
32
  },
41
33
  "storage.keys": {
42
- anonymous: 5,
43
34
  free: 25,
44
35
  pro: Infinity
45
36
  },
46
- // Same floor-at-1 reasoning as network.overrideRules.
47
37
  "storage.mmkvInstances": {
48
- anonymous: 1,
49
38
  free: 1,
50
39
  pro: Infinity
51
40
  },
52
41
  // ── state tools ───────────────────────────────────────────────────────────
53
42
  "redux.actions": {
54
- anonymous: 5,
55
43
  free: 25,
56
44
  pro: Infinity
57
45
  },
58
46
  "zustand.changes": {
59
- anonymous: 5,
60
47
  free: 25,
61
48
  pro: Infinity
62
49
  },
63
50
  "jotai.changes": {
64
- anonymous: 5,
65
51
  free: 25,
66
52
  pro: Infinity
67
53
  },
68
54
  "events.entries": {
69
- anonymous: 5,
70
55
  free: 25,
71
56
  pro: Infinity
72
57
  },
73
58
  // ── render / navigation ───────────────────────────────────────────────────
74
59
  "highlightUpdates.components": {
75
- anonymous: 5,
76
60
  free: 25,
77
61
  pro: Infinity
78
62
  },
79
63
  "highlightUpdates.historyEvents": {
80
- anonymous: 1,
81
64
  free: 3,
82
65
  pro: Infinity
83
66
  },
84
67
  "highlightUpdates.detailEvents": {
85
- anonymous: 2,
86
68
  free: 5,
87
69
  pro: Infinity
88
70
  },
89
71
  "routeEvents.entries": {
90
- anonymous: 1,
91
72
  free: 3,
92
73
  pro: Infinity
93
74
  },
75
+ // One restore point at a time. The floating bar's safety slot is not one
76
+ // the user chose to keep, so it is not counted against this.
94
77
  "timeMachine.snapshots": {
95
- anonymous: 1,
96
- free: 2,
78
+ free: 1,
97
79
  pro: Infinity
98
80
  },
99
81
  "perfMonitor.automationCases": {
100
- anonymous: 1,
101
82
  free: 3,
102
83
  pro: Infinity
103
84
  },
@@ -106,12 +87,10 @@ const LIMITS = {
106
87
  // three-endpoint scenario either runs whole or refuses up front, and is never
107
88
  // silently trimmed to one rule mid-run. Enforcement is atomic in pre-flight.
108
89
  "scenarios.saved": {
109
- anonymous: 1,
110
90
  free: 3,
111
91
  pro: Infinity
112
92
  },
113
93
  "scenarios.active": {
114
- anonymous: 1,
115
94
  free: 1,
116
95
  pro: 3
117
96
  }
@@ -122,17 +101,11 @@ export const TIER_LIMITS = LIMITS;
122
101
  * The tier whose limits actually apply.
123
102
  *
124
103
  * `hasProAccess` is `useIsPro()`, which is true for a real Pro license OR the
125
- * free Weekend Pass. Routing the Weekend Pass through here is what keeps
126
- * today's behavior intact: weekend users get Pro limits, exactly as they do
127
- * now. When the Weekend Pass is later gated to key-holders, that change lands
128
- * here for free — no limit call site has to know about it.
104
+ * Weekend Pass. Routing the Weekend Pass through here is what gives weekend
105
+ * users Pro limits without any limit call site having to know about it.
129
106
  */
130
107
  export function resolveEffectiveTier(tier, hasProAccess) {
131
- if (hasProAccess) return "pro";
132
- // The switch lives in @buoy-gg/license so that this and the Weekend Pass
133
- // change flip together — see isAnonymousTierEnabled().
134
- if (!isAnonymousTierEnabled() && tier === "anonymous") return "free";
135
- return tier;
108
+ return hasProAccess ? "pro" : tier;
136
109
  }
137
110
 
138
111
  /**
@@ -146,27 +119,4 @@ export function useLimit(key) {
146
119
  const hasProAccess = getUseIsPro()();
147
120
  const tier = getUseTier()();
148
121
  return TIER_LIMITS[key][resolveEffectiveTier(tier, hasProAccess)];
149
- }
150
-
151
- /**
152
- * Whether claiming a FREE key would actually raise this limit right now.
153
- *
154
- * The anonymous upsell must never promise something a free key won't deliver.
155
- * Two ways it could lie, and this closes both:
156
- *
157
- * - **Pro-exclusive features.** Copy-to-clipboard, state editing, storage
158
- * mutations and navigation are locked for anonymous AND free alike. Telling
159
- * an anonymous user a free key opens them would be false.
160
- * - **Limits that are already equal.** Override rules and MMKV instances sit
161
- * at 1 for both tiers, so a key changes nothing there either.
162
- *
163
- * It also respects `ANONYMOUS_TIER_ENABLED`: while the anonymous tier is off,
164
- * an anonymous user is *already* getting the free limits, so there is nothing
165
- * to claim and this correctly returns false everywhere. That falls out of
166
- * asking `resolveEffectiveTier` rather than reading the table directly, so the
167
- * switch and the copy can never disagree.
168
- */
169
- export function freeKeyRaises(key) {
170
- const limits = TIER_LIMITS[key];
171
- return limits[resolveEffectiveTier("anonymous", false)] < limits[resolveEffectiveTier("free", false)];
172
122
  }
@@ -126,7 +126,14 @@ export const devToolsStorageKeys = {
126
126
  */
127
127
  timeMachine: {
128
128
  root: () => `${devToolsStorageKeys.base}_time_machine`,
129
- diffViewerMode: () => `${devToolsStorageKeys.timeMachine.root()}_diff_viewer_mode` // 'split' | 'tree'
129
+ diffViewerMode: () => `${devToolsStorageKeys.timeMachine.root()}_diff_viewer_mode`,
130
+ // 'split' | 'tree'
131
+ /** The restore point the floating restore bar restores on tap (snapshot id). */
132
+ armedPoint: () => `${devToolsStorageKeys.timeMachine.root()}_armed_point`,
133
+ /** "1" when the action bar restores in reload mode (storage, then a JS reload). */
134
+ barReloadMode: () => `${devToolsStorageKeys.timeMachine.root()}_bar_reload_mode`,
135
+ /** Source ids switched OFF in the Sources strip (JSON string array). */
136
+ disabledSources: () => `${devToolsStorageKeys.timeMachine.root()}_disabled_sources`
130
137
  },
131
138
  /**
132
139
  * Scenarios storage keys. The library (saved + draft scenarios) and the