@oxyhq/bloom 1.0.6 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (220) hide show
  1. package/docs/level-picker.mdx +105 -0
  2. package/docs/media-flight.mdx +272 -0
  3. package/docs/migrating-the-media-gallery.mdx +103 -0
  4. package/docs/migrating-to-1.0.mdx +1 -1
  5. package/docs/slider.mdx +3 -1
  6. package/docs/zoomable-media-gallery.mdx +116 -0
  7. package/lib/commonjs/floating/index.js.map +1 -1
  8. package/lib/commonjs/image-aspect-ratio-cache/aspect-ratio-cache.js +1 -1
  9. package/lib/commonjs/index.js +8 -0
  10. package/lib/commonjs/index.js.map +1 -1
  11. package/lib/commonjs/index.web.js +33 -25
  12. package/lib/commonjs/index.web.js.map +1 -1
  13. package/lib/commonjs/level-picker/LevelPicker.js +349 -0
  14. package/lib/commonjs/level-picker/LevelPicker.js.map +1 -0
  15. package/lib/commonjs/level-picker/LevelPicker.web.js +346 -0
  16. package/lib/commonjs/level-picker/LevelPicker.web.js.map +1 -0
  17. package/lib/commonjs/level-picker/constants.js +137 -0
  18. package/lib/commonjs/level-picker/constants.js.map +1 -0
  19. package/lib/commonjs/level-picker/index.js +13 -0
  20. package/lib/commonjs/level-picker/index.js.map +1 -0
  21. package/lib/commonjs/level-picker/index.web.js +13 -0
  22. package/lib/commonjs/level-picker/index.web.js.map +1 -0
  23. package/lib/commonjs/level-picker/types.js +6 -0
  24. package/lib/commonjs/level-picker/types.js.map +1 -0
  25. package/lib/commonjs/media-flight/MediaFlightLayer.js +151 -0
  26. package/lib/commonjs/media-flight/MediaFlightLayer.js.map +1 -0
  27. package/lib/commonjs/media-flight/MediaSurface.js +188 -0
  28. package/lib/commonjs/media-flight/MediaSurface.js.map +1 -0
  29. package/lib/commonjs/media-flight/constants.js +39 -0
  30. package/lib/commonjs/media-flight/constants.js.map +1 -0
  31. package/lib/commonjs/media-flight/expo-video-module.js +148 -0
  32. package/lib/commonjs/media-flight/expo-video-module.js.map +1 -0
  33. package/lib/commonjs/media-flight/index.js +102 -0
  34. package/lib/commonjs/media-flight/index.js.map +1 -0
  35. package/lib/commonjs/media-flight/store.js +457 -0
  36. package/lib/commonjs/media-flight/store.js.map +1 -0
  37. package/lib/commonjs/media-flight/types.js +6 -0
  38. package/lib/commonjs/media-flight/types.js.map +1 -0
  39. package/lib/commonjs/media-flight/use-media-flight.js +41 -0
  40. package/lib/commonjs/media-flight/use-media-flight.js.map +1 -0
  41. package/lib/commonjs/tab-bar/TabBarBase.js +1 -1
  42. package/lib/commonjs/{zoomable-image-gallery/ZoomableImageGallery.js → zoomable-media-gallery/ZoomableMediaGallery.js} +185 -131
  43. package/lib/commonjs/zoomable-media-gallery/ZoomableMediaGallery.js.map +1 -0
  44. package/lib/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/constants.js.map +1 -1
  45. package/lib/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/index.js +5 -5
  46. package/lib/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/index.js.map +1 -1
  47. package/lib/commonjs/zoomable-media-gallery/types.js +6 -0
  48. package/lib/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/types.js.map +1 -1
  49. package/lib/module/floating/index.js +5 -0
  50. package/lib/module/floating/index.js.map +1 -1
  51. package/lib/module/image-aspect-ratio-cache/aspect-ratio-cache.js +1 -1
  52. package/lib/module/index.js +3 -1
  53. package/lib/module/index.js.map +1 -1
  54. package/lib/module/index.web.js +3 -1
  55. package/lib/module/index.web.js.map +1 -1
  56. package/lib/module/level-picker/LevelPicker.js +343 -0
  57. package/lib/module/level-picker/LevelPicker.js.map +1 -0
  58. package/lib/module/level-picker/LevelPicker.web.js +340 -0
  59. package/lib/module/level-picker/LevelPicker.web.js.map +1 -0
  60. package/lib/module/level-picker/constants.js +131 -0
  61. package/lib/module/level-picker/constants.js.map +1 -0
  62. package/lib/module/level-picker/index.js +4 -0
  63. package/lib/module/level-picker/index.js.map +1 -0
  64. package/lib/module/level-picker/index.web.js +4 -0
  65. package/lib/module/level-picker/index.web.js.map +1 -0
  66. package/lib/module/level-picker/types.js +4 -0
  67. package/lib/module/level-picker/types.js.map +1 -0
  68. package/lib/module/media-flight/MediaFlightLayer.js +146 -0
  69. package/lib/module/media-flight/MediaFlightLayer.js.map +1 -0
  70. package/lib/module/media-flight/MediaSurface.js +180 -0
  71. package/lib/module/media-flight/MediaSurface.js.map +1 -0
  72. package/lib/module/media-flight/constants.js +35 -0
  73. package/lib/module/media-flight/constants.js.map +1 -0
  74. package/lib/module/media-flight/expo-video-module.js +142 -0
  75. package/lib/module/media-flight/expo-video-module.js.map +1 -0
  76. package/lib/module/media-flight/index.js +9 -0
  77. package/lib/module/media-flight/index.js.map +1 -0
  78. package/lib/module/media-flight/store.js +439 -0
  79. package/lib/module/media-flight/store.js.map +1 -0
  80. package/lib/module/media-flight/types.js +4 -0
  81. package/lib/module/media-flight/types.js.map +1 -0
  82. package/lib/module/media-flight/use-media-flight.js +36 -0
  83. package/lib/module/media-flight/use-media-flight.js.map +1 -0
  84. package/lib/module/tab-bar/TabBarBase.js +1 -1
  85. package/lib/module/{zoomable-image-gallery/ZoomableImageGallery.js → zoomable-media-gallery/ZoomableMediaGallery.js} +184 -130
  86. package/lib/module/zoomable-media-gallery/ZoomableMediaGallery.js.map +1 -0
  87. package/lib/module/{zoomable-image-gallery → zoomable-media-gallery}/constants.js.map +1 -1
  88. package/lib/module/zoomable-media-gallery/index.js +5 -0
  89. package/lib/module/zoomable-media-gallery/index.js.map +1 -0
  90. package/lib/module/zoomable-media-gallery/types.js +4 -0
  91. package/lib/module/{zoomable-image-gallery → zoomable-media-gallery}/types.js.map +1 -1
  92. package/lib/typescript/commonjs/floating/index.d.ts +5 -0
  93. package/lib/typescript/commonjs/floating/index.d.ts.map +1 -1
  94. package/lib/typescript/commonjs/index.d.ts +2 -0
  95. package/lib/typescript/commonjs/index.d.ts.map +1 -1
  96. package/lib/typescript/commonjs/index.web.d.ts +2 -0
  97. package/lib/typescript/commonjs/index.web.d.ts.map +1 -1
  98. package/lib/typescript/commonjs/level-picker/LevelPicker.d.ts +6 -0
  99. package/lib/typescript/commonjs/level-picker/LevelPicker.d.ts.map +1 -0
  100. package/lib/typescript/commonjs/level-picker/LevelPicker.web.d.ts +6 -0
  101. package/lib/typescript/commonjs/level-picker/LevelPicker.web.d.ts.map +1 -0
  102. package/lib/typescript/commonjs/level-picker/constants.d.ts +93 -0
  103. package/lib/typescript/commonjs/level-picker/constants.d.ts.map +1 -0
  104. package/lib/typescript/commonjs/level-picker/index.d.ts +3 -0
  105. package/lib/typescript/commonjs/level-picker/index.d.ts.map +1 -0
  106. package/lib/typescript/commonjs/level-picker/index.web.d.ts +3 -0
  107. package/lib/typescript/commonjs/level-picker/index.web.d.ts.map +1 -0
  108. package/lib/typescript/commonjs/level-picker/types.d.ts +63 -0
  109. package/lib/typescript/commonjs/level-picker/types.d.ts.map +1 -0
  110. package/lib/typescript/commonjs/media-flight/MediaFlightLayer.d.ts +11 -0
  111. package/lib/typescript/commonjs/media-flight/MediaFlightLayer.d.ts.map +1 -0
  112. package/lib/typescript/commonjs/media-flight/MediaSurface.d.ts +106 -0
  113. package/lib/typescript/commonjs/media-flight/MediaSurface.d.ts.map +1 -0
  114. package/lib/typescript/commonjs/media-flight/constants.d.ts +18 -0
  115. package/lib/typescript/commonjs/media-flight/constants.d.ts.map +1 -0
  116. package/lib/typescript/commonjs/media-flight/expo-video-module.d.ts +103 -0
  117. package/lib/typescript/commonjs/media-flight/expo-video-module.d.ts.map +1 -0
  118. package/lib/typescript/commonjs/media-flight/index.d.ts +9 -0
  119. package/lib/typescript/commonjs/media-flight/index.d.ts.map +1 -0
  120. package/lib/typescript/commonjs/media-flight/store.d.ts +132 -0
  121. package/lib/typescript/commonjs/media-flight/store.d.ts.map +1 -0
  122. package/lib/typescript/commonjs/media-flight/types.d.ts +195 -0
  123. package/lib/typescript/commonjs/media-flight/types.d.ts.map +1 -0
  124. package/lib/typescript/commonjs/media-flight/use-media-flight.d.ts +4 -0
  125. package/lib/typescript/commonjs/media-flight/use-media-flight.d.ts.map +1 -0
  126. package/lib/typescript/commonjs/zoomable-media-gallery/ZoomableMediaGallery.d.ts +5 -0
  127. package/lib/typescript/commonjs/zoomable-media-gallery/ZoomableMediaGallery.d.ts.map +1 -0
  128. package/lib/typescript/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/constants.d.ts.map +1 -1
  129. package/lib/typescript/commonjs/zoomable-media-gallery/index.d.ts +4 -0
  130. package/lib/typescript/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/index.d.ts.map +1 -1
  131. package/lib/typescript/commonjs/zoomable-media-gallery/types.d.ts +90 -0
  132. package/lib/typescript/commonjs/zoomable-media-gallery/types.d.ts.map +1 -0
  133. package/lib/typescript/module/floating/index.d.ts +5 -0
  134. package/lib/typescript/module/floating/index.d.ts.map +1 -1
  135. package/lib/typescript/module/index.d.ts +2 -0
  136. package/lib/typescript/module/index.d.ts.map +1 -1
  137. package/lib/typescript/module/index.web.d.ts +2 -0
  138. package/lib/typescript/module/index.web.d.ts.map +1 -1
  139. package/lib/typescript/module/level-picker/LevelPicker.d.ts +6 -0
  140. package/lib/typescript/module/level-picker/LevelPicker.d.ts.map +1 -0
  141. package/lib/typescript/module/level-picker/LevelPicker.web.d.ts +6 -0
  142. package/lib/typescript/module/level-picker/LevelPicker.web.d.ts.map +1 -0
  143. package/lib/typescript/module/level-picker/constants.d.ts +93 -0
  144. package/lib/typescript/module/level-picker/constants.d.ts.map +1 -0
  145. package/lib/typescript/module/level-picker/index.d.ts +3 -0
  146. package/lib/typescript/module/level-picker/index.d.ts.map +1 -0
  147. package/lib/typescript/module/level-picker/index.web.d.ts +3 -0
  148. package/lib/typescript/module/level-picker/index.web.d.ts.map +1 -0
  149. package/lib/typescript/module/level-picker/types.d.ts +63 -0
  150. package/lib/typescript/module/level-picker/types.d.ts.map +1 -0
  151. package/lib/typescript/module/media-flight/MediaFlightLayer.d.ts +11 -0
  152. package/lib/typescript/module/media-flight/MediaFlightLayer.d.ts.map +1 -0
  153. package/lib/typescript/module/media-flight/MediaSurface.d.ts +106 -0
  154. package/lib/typescript/module/media-flight/MediaSurface.d.ts.map +1 -0
  155. package/lib/typescript/module/media-flight/constants.d.ts +18 -0
  156. package/lib/typescript/module/media-flight/constants.d.ts.map +1 -0
  157. package/lib/typescript/module/media-flight/expo-video-module.d.ts +103 -0
  158. package/lib/typescript/module/media-flight/expo-video-module.d.ts.map +1 -0
  159. package/lib/typescript/module/media-flight/index.d.ts +9 -0
  160. package/lib/typescript/module/media-flight/index.d.ts.map +1 -0
  161. package/lib/typescript/module/media-flight/store.d.ts +132 -0
  162. package/lib/typescript/module/media-flight/store.d.ts.map +1 -0
  163. package/lib/typescript/module/media-flight/types.d.ts +195 -0
  164. package/lib/typescript/module/media-flight/types.d.ts.map +1 -0
  165. package/lib/typescript/module/media-flight/use-media-flight.d.ts +4 -0
  166. package/lib/typescript/module/media-flight/use-media-flight.d.ts.map +1 -0
  167. package/lib/typescript/module/zoomable-media-gallery/ZoomableMediaGallery.d.ts +5 -0
  168. package/lib/typescript/module/zoomable-media-gallery/ZoomableMediaGallery.d.ts.map +1 -0
  169. package/lib/typescript/module/{zoomable-image-gallery → zoomable-media-gallery}/constants.d.ts.map +1 -1
  170. package/lib/typescript/module/zoomable-media-gallery/index.d.ts +4 -0
  171. package/lib/typescript/module/{zoomable-image-gallery → zoomable-media-gallery}/index.d.ts.map +1 -1
  172. package/lib/typescript/module/zoomable-media-gallery/types.d.ts +90 -0
  173. package/lib/typescript/module/zoomable-media-gallery/types.d.ts.map +1 -0
  174. package/package.json +61 -8
  175. package/src/floating/index.ts +5 -0
  176. package/src/image-aspect-ratio-cache/aspect-ratio-cache.ts +1 -1
  177. package/src/index.ts +4 -1
  178. package/src/index.web.ts +4 -1
  179. package/src/level-picker/LevelPicker.tsx +365 -0
  180. package/src/level-picker/LevelPicker.web.tsx +374 -0
  181. package/src/level-picker/constants.ts +131 -0
  182. package/src/level-picker/index.ts +2 -0
  183. package/src/level-picker/index.web.ts +2 -0
  184. package/src/level-picker/types.ts +63 -0
  185. package/src/media-flight/MediaFlightLayer.tsx +144 -0
  186. package/src/media-flight/MediaSurface.tsx +233 -0
  187. package/src/media-flight/constants.ts +32 -0
  188. package/src/media-flight/expo-video-module.ts +181 -0
  189. package/src/media-flight/index.ts +33 -0
  190. package/src/media-flight/store.ts +497 -0
  191. package/src/media-flight/types.ts +210 -0
  192. package/src/media-flight/use-media-flight.ts +42 -0
  193. package/src/tab-bar/TabBarBase.tsx +1 -1
  194. package/src/{zoomable-image-gallery/ZoomableImageGallery.tsx → zoomable-media-gallery/ZoomableMediaGallery.tsx} +192 -117
  195. package/src/zoomable-media-gallery/index.ts +11 -0
  196. package/src/zoomable-media-gallery/types.ts +100 -0
  197. package/docs/zoomable-image-gallery.mdx +0 -66
  198. package/lib/commonjs/zoomable-image-gallery/ZoomableImageGallery.js.map +0 -1
  199. package/lib/commonjs/zoomable-image-gallery/types.js +0 -2
  200. package/lib/module/zoomable-image-gallery/ZoomableImageGallery.js.map +0 -1
  201. package/lib/module/zoomable-image-gallery/index.js +0 -5
  202. package/lib/module/zoomable-image-gallery/index.js.map +0 -1
  203. package/lib/module/zoomable-image-gallery/types.js +0 -2
  204. package/lib/typescript/commonjs/zoomable-image-gallery/ZoomableImageGallery.d.ts +0 -5
  205. package/lib/typescript/commonjs/zoomable-image-gallery/ZoomableImageGallery.d.ts.map +0 -1
  206. package/lib/typescript/commonjs/zoomable-image-gallery/index.d.ts +0 -4
  207. package/lib/typescript/commonjs/zoomable-image-gallery/types.d.ts +0 -56
  208. package/lib/typescript/commonjs/zoomable-image-gallery/types.d.ts.map +0 -1
  209. package/lib/typescript/module/zoomable-image-gallery/ZoomableImageGallery.d.ts +0 -5
  210. package/lib/typescript/module/zoomable-image-gallery/ZoomableImageGallery.d.ts.map +0 -1
  211. package/lib/typescript/module/zoomable-image-gallery/index.d.ts +0 -4
  212. package/lib/typescript/module/zoomable-image-gallery/types.d.ts +0 -56
  213. package/lib/typescript/module/zoomable-image-gallery/types.d.ts.map +0 -1
  214. package/src/zoomable-image-gallery/index.ts +0 -9
  215. package/src/zoomable-image-gallery/types.ts +0 -59
  216. /package/lib/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/constants.js +0 -0
  217. /package/lib/module/{zoomable-image-gallery → zoomable-media-gallery}/constants.js +0 -0
  218. /package/lib/typescript/commonjs/{zoomable-image-gallery → zoomable-media-gallery}/constants.d.ts +0 -0
  219. /package/lib/typescript/module/{zoomable-image-gallery → zoomable-media-gallery}/constants.d.ts +0 -0
  220. /package/src/{zoomable-image-gallery → zoomable-media-gallery}/constants.ts +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_constants","_shared","_useControllableState","_Chevron","_styledPrimitives","_tokens","_useTheme","_constants2","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","AnimatedStyledView","Animated","createAnimatedComponent","StyledView","useRevealProgress","on","progress","useRef","Value","current","useEffect","spring","toValue","useNativeDriver","animation","gentle","start","ADJUST_ACTIONS","name","LevelPicker","levels","value","onValueChange","accessibilityLabel","minLabel","maxLabel","detailsLabel","expanded","defaultExpanded","onExpandedChange","children","className","style","testID","theme","useTheme","isExpanded","setExpanded","useControllableState","defaultValue","onChange","trackWidth","setTrackWidth","useState","detailsHeight","setDetailsHeight","dragging","setDragging","reveal","active","stateRef","count","length","onValueChangeRef","grantOffsetRef","commitOffset","useCallback","offsetX","width","next","levelFromOffset","step","delta","Math","max","min","panResponder","useMemo","PanResponder","create","onStartShouldSetPanResponder","onMoveShouldSetPanResponder","onPanResponderGrant","event","nativeEvent","locationX","onPanResponderMove","_event","gesture","dx","onPanResponderRelease","onPanResponderTerminate","onTrackLayout","layout","prev","abs","onDetailsLayout","height","onAccessibilityAction","actionName","offsetOf","index","percent","offset","levelStopPosition","hasCaptions","undefined","childTestId","part","jsxs","cx","jsx","pointerEvents","overflow","opacity","interpolate","inputRange","outputRange","maxHeight","LEVEL_SLIDER_ROW_HEIGHT","justifyContent","paddingHorizontal","LEVEL_ROW_INSET","accessibilityRole","accessibilityActions","onLayout","LEVEL_TRACK_CLASS","LEVEL_TRACK_HEIGHT","panHandlers","Fragment","LEVEL_FILL_CLASS","top","bottom","map","label","LEVEL_STOP_REACHED_CLASS","LEVEL_STOP_CLASS","LEVEL_STOP_SIZE","left","LEVEL_THUMB_CLASS","LEVEL_THUMB_SIZE","MenuRowShell","role","disabled","title","trailing","MenuRowChevron","transform","rotate","ChevronRight_Stroke2_Corner0_Rounded","ROW_ICON_SIZE","fill","colors","textSecondary","onPress","SUB_TRIGGER_CLASS","position","right","flexDirection","alignItems","StyledText","LEVEL_CAPTION_CLASS","LEVEL_SEPARATOR_CLASS","marginHorizontal","marginBottom","displayName"],"sourceRoot":"../../../src","sources":["level-picker/LevelPicker.tsx"],"mappings":";;;;;;AAwBA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AASA,IAAAE,UAAA,GAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AACA,IAAAI,qBAAA,GAAAJ,OAAA;AACA,IAAAK,QAAA,GAAAL,OAAA;AACA,IAAAM,iBAAA,GAAAN,OAAA;AACA,IAAAO,OAAA,GAAAP,OAAA;AACA,IAAAQ,SAAA,GAAAR,OAAA;AACA,IAAAS,WAAA,GAAAT,OAAA;AAeqB,IAAAU,WAAA,GAAAV,OAAA;AAAA,SAAAD,wBAAAY,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAd,uBAAA,YAAAA,CAAAY,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAA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,QAAA,gBACpC,IAAAlD,WAAA,CAAAyH,GAAA,EAAC7H,iBAAA,CAAA2B,UAAU;UACT4B,SAAS,EAAEyH,iCAAsB;UACjCxH,KAAK,EAAE;YAAEyH,gBAAgB,EAAEzC,2BAAe;YAAE0C,YAAY,EAAE;UAAE;QAAE,CAC/D,CAAC,EACD5H,QAAQ;MAAA,CACC;IAAC,CACK,CAAC;EAAA,CACX,CAAC;AAEjB;AAEAX,WAAW,CAACwI,WAAW,GAAG,aAAa","ignoreList":[]}
@@ -0,0 +1,346 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.LevelPicker = LevelPicker;
7
+ var _react = _interopRequireWildcard(require("react"));
8
+ var _constants = require("../floating/constants.js");
9
+ var _shared = require("../floating/shared.js");
10
+ var _useControllableState = require("../hooks/use-controllable-state.js");
11
+ var _useInteractionState = require("../hooks/use-interaction-state.js");
12
+ var _Chevron = require("../icons/Chevron.js");
13
+ var _flattenWebStyle = require("../styles/flatten-web-style.js");
14
+ var _useTheme = require("../theme/use-theme.js");
15
+ var _constants2 = require("./constants.js");
16
+ var _jsxRuntime = require("react/jsx-runtime");
17
+ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
18
+ /**
19
+ * `LevelPicker` — WEB. The same control as `LevelPicker.tsx`, built out of the
20
+ * three things a browser has and React Native does not, which is what makes
21
+ * this a fork rather than a branch:
22
+ *
23
+ * 1. **Pointer capture.** `setPointerCapture` keeps the drag on the rail once
24
+ * the pointer leaves it, so a user can slam left or right past the end of
25
+ * the track and still be steering. Nothing in the RN responder system is
26
+ * equivalent on the platform where a pointer exists at all.
27
+ * 2. **`inert` and a real focus model.** A collapsed region is `inert` — its
28
+ * rows leave the tab order and the accessibility tree together — and the
29
+ * rail is a focusable `role="slider"` with arrow, Home and End keys, which
30
+ * an `adjustable` on native exposes as increment/decrement ACTIONS instead.
31
+ * 3. **`calc()`.** A stop's position is a percentage of the rail plus a pixel
32
+ * inset, which CSS resolves per frame; the native fork has to measure the
33
+ * rail with `onLayout` and multiply. Both read {@link levelStopPosition}, so
34
+ * the formula is one thing rendered two ways rather than two formulas.
35
+ *
36
+ * The rows themselves are NOT forked: the summary row is `floating/shared`'s
37
+ * `MenuRowShell`, the same one the sub-menu triggers in the details region are
38
+ * built from, so the disclosure and the rows it reveals cannot disagree about a
39
+ * row's inset, highlight or height.
40
+ */
41
+
42
+ /**
43
+ * The menu's own motion, as CSS. `FloatingPanel` runs its enter and exit on the
44
+ * same duration and curve, so a picker changing shape inside a panel reads as
45
+ * one surface moving rather than two things animating at each other.
46
+ *
47
+ * Spelled inline from the constants rather than as `duration-200 ease-out`
48
+ * classes: a class would be a second copy of the number, free to drift from the
49
+ * one the panel uses.
50
+ */
51
+ const MOTION = {
52
+ transitionDuration: `${_constants.PANEL_MOTION_DURATION}ms`,
53
+ transitionTimingFunction: `cubic-bezier(${_constants.PANEL_MOTION_EASING.join(', ')})`
54
+ };
55
+
56
+ /** The rail's own chrome — everything about it that is not a colour role. */
57
+ const TRACK_CLASS = 'w-full touch-none cursor-pointer outline-none ' + 'focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-popover';
58
+ function LevelPicker({
59
+ levels,
60
+ value,
61
+ onValueChange,
62
+ accessibilityLabel,
63
+ minLabel,
64
+ maxLabel,
65
+ detailsLabel = 'Details',
66
+ expanded,
67
+ defaultExpanded = false,
68
+ onExpandedChange,
69
+ children,
70
+ className,
71
+ style,
72
+ testID
73
+ }) {
74
+ const theme = (0, _useTheme.useTheme)();
75
+ const [isExpanded, setExpanded] = (0, _useControllableState.useControllableState)({
76
+ value: expanded,
77
+ defaultValue: defaultExpanded,
78
+ onChange: onExpandedChange
79
+ });
80
+ const {
81
+ state: pointerOver,
82
+ onIn: enterPointer,
83
+ onOut: leavePointer
84
+ } = (0, _useInteractionState.useInteractionState)();
85
+ const {
86
+ state: focused,
87
+ onIn: focusTrack,
88
+ onOut: blurTrack
89
+ } = (0, _useInteractionState.useInteractionState)();
90
+ const [dragging, setDragging] = (0, _react.useState)(false);
91
+ const [detailsHeight, setDetailsHeight] = (0, _react.useState)(0);
92
+ const trackRef = (0, _react.useRef)(null);
93
+
94
+ /** The slider is being WORKED — hovered, focused or dragged. */
95
+ const active = pointerOver || focused || dragging;
96
+
97
+ /**
98
+ * The details region's natural height, observed rather than read once: a
99
+ * sub-menu row inside it can change size after the reveal has already run,
100
+ * and a height measured only on mount would clip it.
101
+ *
102
+ * `ResizeObserver` is guarded because this fork also runs where there is no
103
+ * layout to observe — an SSR pass, and jsdom under jest. There the region
104
+ * falls back to its natural height (`maxHeight: undefined` below), which is
105
+ * the safe direction: unclipped rather than collapsed.
106
+ */
107
+ const measureDetails = (0, _react.useCallback)(node => {
108
+ if (node === null) return;
109
+ const read = () => {
110
+ const next = node.offsetHeight;
111
+ setDetailsHeight(prev => Math.abs(prev - next) > 0.5 ? next : prev);
112
+ };
113
+ read();
114
+ if (typeof ResizeObserver === 'undefined') return;
115
+ const observer = new ResizeObserver(read);
116
+ observer.observe(node);
117
+ return () => observer.disconnect();
118
+ }, []);
119
+ const commitPointer = (0, _react.useCallback)(event => {
120
+ const rect = trackRef.current?.getBoundingClientRect();
121
+ if (rect === undefined) return;
122
+ const next = (0, _constants2.levelFromOffset)(event.clientX - rect.left, rect.width, levels.length);
123
+ if (next !== value) onValueChange(next);
124
+ }, [levels.length, onValueChange, value]);
125
+ const step = (0, _react.useCallback)(to => {
126
+ const next = Math.max(0, Math.min(levels.length - 1, to));
127
+ if (next !== value) onValueChange(next);
128
+ }, [levels.length, onValueChange, value]);
129
+ const onKeyDown = (0, _react.useCallback)(event => {
130
+ switch (event.key) {
131
+ case 'ArrowRight':
132
+ case 'ArrowUp':
133
+ event.preventDefault();
134
+ step(value + 1);
135
+ break;
136
+ case 'ArrowLeft':
137
+ case 'ArrowDown':
138
+ event.preventDefault();
139
+ step(value - 1);
140
+ break;
141
+ case 'Home':
142
+ event.preventDefault();
143
+ step(0);
144
+ break;
145
+ case 'End':
146
+ event.preventDefault();
147
+ step(levels.length - 1);
148
+ break;
149
+ default:
150
+ break;
151
+ }
152
+ }, [levels.length, step, value]);
153
+
154
+ /** A stop's centre: a share of the rail, plus the inset that keeps the knob on it. */
155
+ const positionOf = index => {
156
+ const {
157
+ percent,
158
+ offset
159
+ } = (0, _constants2.levelStopPosition)(index, levels.length);
160
+ return `calc(${percent}% + ${offset}px)`;
161
+ };
162
+ const hasCaptions = minLabel !== undefined || maxLabel !== undefined;
163
+ /**
164
+ * The row's fade, on the ROW rather than on a wrapper around it: an inline
165
+ * style outranks a class on web whatever the order, so this is the one place
166
+ * the opacity can live without competing with `MenuRowShell`'s own chrome —
167
+ * and it is one fewer node between the caller's layout and the row.
168
+ *
169
+ * `pointerEvents` follows the POINTER, not `active`, and the difference is not
170
+ * a nicety. A rail keeps focus after it is clicked, so a row that stopped
171
+ * taking clicks whenever `active` was true would be unclickable for as long as
172
+ * the rail was focused — measured: the click falls through to the container,
173
+ * which blurs the rail, and only the SECOND click reaches the row. Fading a
174
+ * row the pointer is nowhere near is worth it; swallowing its click is not.
175
+ */
176
+ const pointerEngaged = pointerOver || dragging;
177
+ const summaryStyle = {
178
+ ...MOTION,
179
+ transitionProperty: 'opacity',
180
+ opacity: active ? 0 : 1,
181
+ pointerEvents: pointerEngaged ? 'none' : 'auto'
182
+ };
183
+ const childTestId = part => testID === undefined ? undefined : `${testID}-${part}`;
184
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
185
+ className: (0, _shared.cx)('flex w-full flex-col', className),
186
+ style: (0, _flattenWebStyle.flattenWebStyle)(style),
187
+ "data-testid": testID,
188
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
189
+ inert: isExpanded,
190
+ "aria-hidden": isExpanded,
191
+ className: "overflow-hidden",
192
+ style: {
193
+ ...MOTION,
194
+ transitionProperty: 'max-height, opacity',
195
+ maxHeight: isExpanded ? 0 : _constants2.LEVEL_SLIDER_ROW_HEIGHT,
196
+ opacity: isExpanded ? 0 : 1
197
+ },
198
+ "data-testid": childTestId('slider'),
199
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
200
+ className: "flex items-center",
201
+ style: {
202
+ height: _constants2.LEVEL_SLIDER_ROW_HEIGHT,
203
+ paddingLeft: _constants2.LEVEL_ROW_INSET,
204
+ paddingRight: _constants2.LEVEL_ROW_INSET
205
+ },
206
+ children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
207
+ ref: trackRef,
208
+ role: "slider",
209
+ tabIndex: isExpanded ? -1 : 0,
210
+ "aria-label": accessibilityLabel,
211
+ "aria-valuemin": 0,
212
+ "aria-valuemax": levels.length - 1,
213
+ "aria-valuenow": value,
214
+ "aria-valuetext": levels[value],
215
+ onPointerEnter: enterPointer,
216
+ onPointerLeave: () => {
217
+ if (!dragging) leavePointer();
218
+ },
219
+ onPointerDown: event => {
220
+ event.currentTarget.setPointerCapture(event.pointerId);
221
+ setDragging(true);
222
+ enterPointer();
223
+ commitPointer(event);
224
+ },
225
+ onPointerMove: event => {
226
+ if (dragging) commitPointer(event);
227
+ },
228
+ onPointerUp: event => {
229
+ if (event.currentTarget.hasPointerCapture(event.pointerId)) {
230
+ event.currentTarget.releasePointerCapture(event.pointerId);
231
+ }
232
+ setDragging(false);
233
+ },
234
+ onPointerCancel: () => setDragging(false),
235
+ onFocus: focusTrack,
236
+ onBlur: blurTrack,
237
+ onKeyDown: onKeyDown,
238
+ className: (0, _shared.cx)(_constants2.LEVEL_TRACK_CLASS, TRACK_CLASS),
239
+ style: {
240
+ height: _constants2.LEVEL_TRACK_HEIGHT
241
+ },
242
+ "data-testid": childTestId('track'),
243
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
244
+ "aria-hidden": "true",
245
+ className: _constants2.LEVEL_FILL_CLASS,
246
+ style: {
247
+ top: 0,
248
+ bottom: 0,
249
+ width: positionOf(value)
250
+ }
251
+ }), levels.map((label, index) => /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
252
+ "aria-hidden": "true",
253
+ className: index <= value ? _constants2.LEVEL_STOP_REACHED_CLASS : _constants2.LEVEL_STOP_CLASS,
254
+ style: {
255
+ width: _constants2.LEVEL_STOP_SIZE,
256
+ height: _constants2.LEVEL_STOP_SIZE,
257
+ top: '50%',
258
+ left: positionOf(index),
259
+ transform: 'translate(-50%, -50%)'
260
+ }
261
+ }, label)), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
262
+ "aria-hidden": "true",
263
+ className: _constants2.LEVEL_THUMB_CLASS,
264
+ style: {
265
+ width: _constants2.LEVEL_THUMB_SIZE,
266
+ height: _constants2.LEVEL_THUMB_SIZE,
267
+ top: '50%',
268
+ left: positionOf(value),
269
+ transform: 'translate(-50%, -50%)'
270
+ },
271
+ "data-testid": childTestId('thumb')
272
+ })]
273
+ })
274
+ })
275
+ }), /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
276
+ className: "relative",
277
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_shared.MenuRowShell, {
278
+ role: "menuitem",
279
+ expanded: isExpanded,
280
+ disabled: false,
281
+ title: detailsLabel,
282
+ trailing: /*#__PURE__*/(0, _jsxRuntime.jsx)(_shared.MenuRowChevron, {
283
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
284
+ className: "flex items-center justify-center",
285
+ style: {
286
+ ...MOTION,
287
+ transitionProperty: 'transform',
288
+ transform: isExpanded ? 'rotate(90deg)' : 'rotate(0deg)'
289
+ },
290
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_Chevron.ChevronRight_Stroke2_Corner0_Rounded, {
291
+ width: _constants.ROW_ICON_SIZE,
292
+ height: _constants.ROW_ICON_SIZE,
293
+ fill: theme.colors.textSecondary
294
+ })
295
+ })
296
+ }),
297
+ onPress: () => setExpanded(!isExpanded),
298
+ className: _shared.SUB_TRIGGER_CLASS,
299
+ style: summaryStyle,
300
+ testID: childTestId('summary')
301
+ }), hasCaptions ? /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
302
+ "aria-hidden": "true",
303
+ className: "pointer-events-none absolute inset-0 flex flex-row items-center justify-between",
304
+ style: {
305
+ ...MOTION,
306
+ transitionProperty: 'opacity',
307
+ opacity: active ? 1 : 0,
308
+ paddingLeft: _constants2.LEVEL_ROW_INSET,
309
+ paddingRight: _constants2.LEVEL_ROW_INSET
310
+ },
311
+ "data-testid": childTestId('captions'),
312
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
313
+ className: _constants2.LEVEL_CAPTION_CLASS,
314
+ children: minLabel
315
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)("span", {
316
+ className: _constants2.LEVEL_CAPTION_CLASS,
317
+ children: maxLabel
318
+ })]
319
+ }) : null]
320
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
321
+ inert: !isExpanded,
322
+ "aria-hidden": !isExpanded,
323
+ className: "overflow-hidden",
324
+ style: {
325
+ ...MOTION,
326
+ transitionProperty: 'max-height, opacity',
327
+ maxHeight: isExpanded ? detailsHeight === 0 ? undefined : detailsHeight : 0,
328
+ opacity: isExpanded ? 1 : 0
329
+ },
330
+ "data-testid": childTestId('details'),
331
+ children: /*#__PURE__*/(0, _jsxRuntime.jsxs)("div", {
332
+ ref: measureDetails,
333
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)("div", {
334
+ className: _constants2.LEVEL_SEPARATOR_CLASS,
335
+ style: {
336
+ marginLeft: _constants2.LEVEL_ROW_INSET,
337
+ marginRight: _constants2.LEVEL_ROW_INSET,
338
+ marginBottom: 4
339
+ }
340
+ }), children]
341
+ })
342
+ })]
343
+ });
344
+ }
345
+ LevelPicker.displayName = 'LevelPicker';
346
+ //# sourceMappingURL=LevelPicker.web.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_constants","_shared","_useControllableState","_useInteractionState","_Chevron","_flattenWebStyle","_useTheme","_constants2","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","MOTION","transitionDuration","PANEL_MOTION_DURATION","transitionTimingFunction","PANEL_MOTION_EASING","join","TRACK_CLASS","LevelPicker","levels","value","onValueChange","accessibilityLabel","minLabel","maxLabel","detailsLabel","expanded","defaultExpanded","onExpandedChange","children","className","style","testID","theme","useTheme","isExpanded","setExpanded","useControllableState","defaultValue","onChange","state","pointerOver","onIn","enterPointer","onOut","leavePointer","useInteractionState","focused","focusTrack","blurTrack","dragging","setDragging","useState","detailsHeight","setDetailsHeight","trackRef","useRef","active","measureDetails","useCallback","node","read","next","offsetHeight","prev","Math","abs","ResizeObserver","observer","observe","disconnect","commitPointer","event","rect","current","getBoundingClientRect","undefined","levelFromOffset","clientX","left","width","length","step","to","max","min","onKeyDown","key","preventDefault","positionOf","index","percent","offset","levelStopPosition","hasCaptions","pointerEngaged","summaryStyle","transitionProperty","opacity","pointerEvents","childTestId","part","jsxs","cx","flattenWebStyle","jsx","inert","maxHeight","LEVEL_SLIDER_ROW_HEIGHT","height","paddingLeft","LEVEL_ROW_INSET","paddingRight","ref","role","tabIndex","onPointerEnter","onPointerLeave","onPointerDown","currentTarget","setPointerCapture","pointerId","onPointerMove","onPointerUp","hasPointerCapture","releasePointerCapture","onPointerCancel","onFocus","onBlur","LEVEL_TRACK_CLASS","LEVEL_TRACK_HEIGHT","LEVEL_FILL_CLASS","top","bottom","map","label","LEVEL_STOP_REACHED_CLASS","LEVEL_STOP_CLASS","LEVEL_STOP_SIZE","transform","LEVEL_THUMB_CLASS","LEVEL_THUMB_SIZE","MenuRowShell","disabled","title","trailing","MenuRowChevron","ChevronRight_Stroke2_Corner0_Rounded","ROW_ICON_SIZE","fill","colors","textSecondary","onPress","SUB_TRIGGER_CLASS","LEVEL_CAPTION_CLASS","LEVEL_SEPARATOR_CLASS","marginLeft","marginRight","marginBottom","displayName"],"sourceRoot":"../../../src","sources":["level-picker/LevelPicker.web.tsx"],"mappings":";;;;;;AAuBA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAEA,IAAAC,UAAA,GAAAD,OAAA;AACA,IAAAE,OAAA,GAAAF,OAAA;AACA,IAAAG,qBAAA,GAAAH,OAAA;AACA,IAAAI,oBAAA,GAAAJ,OAAA;AACA,IAAAK,QAAA,GAAAL,OAAA;AACA,IAAAM,gBAAA,GAAAN,OAAA;AAEA,IAAAO,SAAA,GAAAP,OAAA;AACA,IAAAQ,WAAA,GAAAR,OAAA;AAeqB,IAAAS,WAAA,GAAAT,OAAA;AAAA,SAAAD,wBAAAW,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAb,uBAAA,YAAAA,CAAAW,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAA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AAC,CACH,CAAC;EAAA,CACH,CAAC;AAEV;AAEAX,WAAW,CAAC6I,WAAW,GAAG,aAAa","ignoreList":[]}
@@ -0,0 +1,137 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.LEVEL_TRACK_HEIGHT = exports.LEVEL_TRACK_CLASS = exports.LEVEL_THUMB_SIZE = exports.LEVEL_THUMB_CLASS = exports.LEVEL_STOP_SIZE = exports.LEVEL_STOP_REACHED_CLASS = exports.LEVEL_STOP_INSET = exports.LEVEL_STOP_CLASS = exports.LEVEL_SLIDER_ROW_HEIGHT = exports.LEVEL_SEPARATOR_CLASS = exports.LEVEL_ROW_INSET = exports.LEVEL_FILL_CLASS = exports.LEVEL_CAPTION_CLASS = void 0;
7
+ exports.levelFromOffset = levelFromOffset;
8
+ exports.levelStopPosition = levelStopPosition;
9
+ /**
10
+ * The level picker's SPEC: the geometry both forks lay out from, the colour
11
+ * roles as Tailwind classes, and the two functions that map a stop to a
12
+ * position and a pointer back to a stop.
13
+ *
14
+ * ── WHY GEOMETRY IS NUMBERS HERE AND COLOUR IS CLASSES ───────────────────────
15
+ *
16
+ * `floating/constants.ts` states the menu vocabulary as class strings, so a
17
+ * consumer can restyle a row with a utility. That reasoning applies to the
18
+ * parts a consumer addresses — and none of these are: the rail, its stops and
19
+ * its knob are one control's internals, and the caller's `className` lands on
20
+ * the picker's ROOT.
21
+ *
22
+ * What it buys instead is the property that matters most for a two-fork
23
+ * component: the web fork positions a stop with `calc()` and the native fork
24
+ * with a measured pixel offset, and BOTH read the numbers below and call
25
+ * {@link levelStopPosition}. Two forks that agreed only by having the same
26
+ * literals typed into them is exactly the drift `MENU_SUB_SIDE_OFFSET` and
27
+ * `SUB_TRIGGER_CLASS` exist to prevent one level up.
28
+ *
29
+ * Colour stays in classes, because that is what the surrounding menu rows are
30
+ * painted with and because a token is never derived from — `bg-muted-foreground/25`
31
+ * is the opacity UTILITY (`color-mix`, resolved by the build), never an alpha
32
+ * appended to a resolved `rgb(...)`, which parses back opaque.
33
+ */
34
+
35
+ /* -------------------------------------------------------------------------- */
36
+ /* Geometry — numbers, because both forks compute with them */
37
+ /* -------------------------------------------------------------------------- */
38
+
39
+ /** The rail: a 24px pill, tall enough to read as a track rather than a line. */
40
+ const LEVEL_TRACK_HEIGHT = exports.LEVEL_TRACK_HEIGHT = 24;
41
+
42
+ /**
43
+ * The knob, LARGER than the rail on purpose (30 against 24), so it reads as a
44
+ * control riding the track rather than a dot inside it. It therefore overhangs
45
+ * the rail by 3px top and bottom, and by 2px past each end once
46
+ * {@link LEVEL_STOP_INSET} is applied — which is why nothing between the rail
47
+ * and the picker's root may clip.
48
+ */
49
+ const LEVEL_THUMB_SIZE = exports.LEVEL_THUMB_SIZE = 30;
50
+
51
+ /** A stop: a 4px dot, drawn under the knob. */
52
+ const LEVEL_STOP_SIZE = exports.LEVEL_STOP_SIZE = 4;
53
+
54
+ /**
55
+ * How far the FIRST and LAST stop sit in from the rail's ends.
56
+ *
57
+ * Not a cosmetic margin: it is what stops the knob from hanging half off the
58
+ * rail at either extreme, so it is also the value {@link levelFromOffset} has
59
+ * to subtract before it can read a fraction — a hit map that ignores it snaps
60
+ * to the wrong stop for the first and last {@link LEVEL_STOP_INSET} pixels,
61
+ * which is precisely where a user aiming for "least" or "most" clicks.
62
+ */
63
+ const LEVEL_STOP_INSET = exports.LEVEL_STOP_INSET = 13;
64
+
65
+ /** The row the rail sits in — one Bloom row taller than the rail itself. */
66
+ const LEVEL_SLIDER_ROW_HEIGHT = exports.LEVEL_SLIDER_ROW_HEIGHT = 40;
67
+
68
+ /**
69
+ * The horizontal inset of everything in the picker that is not a menu row,
70
+ * matching `floating/constants`' `ROW_CLASS` (`px-space-8`) so the rail and the
71
+ * end captions line up with the rows above and below them.
72
+ */
73
+ const LEVEL_ROW_INSET = exports.LEVEL_ROW_INSET = 8;
74
+
75
+ /* -------------------------------------------------------------------------- */
76
+ /* Colour roles — classes, as the surrounding menu rows are */
77
+ /* -------------------------------------------------------------------------- */
78
+
79
+ /** The unfilled rail. */
80
+ const LEVEL_TRACK_CLASS = exports.LEVEL_TRACK_CLASS = 'relative rounded-full bg-muted-foreground/25';
81
+
82
+ /** The filled part, which ends under the knob rather than at the rail's end. */
83
+ const LEVEL_FILL_CLASS = exports.LEVEL_FILL_CLASS = 'absolute left-0 rounded-full bg-primary';
84
+
85
+ /** A stop the level has NOT reached: a dot on the bare rail. */
86
+ const LEVEL_STOP_CLASS = exports.LEVEL_STOP_CLASS = 'absolute rounded-full bg-muted-foreground/65';
87
+
88
+ /** A stop the level HAS reached: the same dot, on the fill, in its on-colour. */
89
+ const LEVEL_STOP_REACHED_CLASS = exports.LEVEL_STOP_REACHED_CLASS = 'absolute rounded-full bg-primary-foreground/35';
90
+
91
+ /** The knob. `shadow-s` is Bloom's control-raise role, the same one `Slider` takes. */
92
+ const LEVEL_THUMB_CLASS = exports.LEVEL_THUMB_CLASS = 'absolute rounded-full bg-background shadow-s';
93
+
94
+ /** The two end captions, one de-emphasis step back, as a menu shortcut is. */
95
+ const LEVEL_CAPTION_CLASS = exports.LEVEL_CAPTION_CLASS = 'text-xs text-muted-foreground';
96
+
97
+ /** The hairline between the summary row and the details region. */
98
+ const LEVEL_SEPARATOR_CLASS = exports.LEVEL_SEPARATOR_CLASS = 'h-px bg-border';
99
+
100
+ /* -------------------------------------------------------------------------- */
101
+ /* The two mappings, written once for both forks */
102
+ /* -------------------------------------------------------------------------- */
103
+
104
+ /**
105
+ * Where a stop sits along the rail, as a PERCENTAGE of the rail plus a pixel
106
+ * OFFSET — the one form both forks can render from.
107
+ *
108
+ * The web fork spells it `calc(P% + Opx)` and never measures; the native fork
109
+ * multiplies the percentage by a laid-out width. Returning the pair rather than
110
+ * a finished value is what lets one formula serve both: a shared function that
111
+ * returned pixels would force the web fork to measure, and one that returned a
112
+ * CSS string would be unusable on native.
113
+ */
114
+ function levelStopPosition(index, count) {
115
+ const fraction = count <= 1 ? 0 : index / (count - 1);
116
+ return {
117
+ percent: fraction * 100,
118
+ offset: LEVEL_STOP_INSET - fraction * 2 * LEVEL_STOP_INSET
119
+ };
120
+ }
121
+
122
+ /**
123
+ * Which stop a pointer at `offsetX` from the rail's left edge is asking for.
124
+ *
125
+ * The inverse of {@link levelStopPosition}, and it undoes the inset for the
126
+ * reason spelled out there. `trackWidth` is the rail's own width — the caller
127
+ * measures it (`getBoundingClientRect().width` on web, `onLayout` on native),
128
+ * so this stays pure and testable.
129
+ */
130
+ function levelFromOffset(offsetX, trackWidth, count) {
131
+ if (count <= 1) return 0;
132
+ const usable = trackWidth - 2 * LEVEL_STOP_INSET;
133
+ const fraction = usable <= 0 ? 0 : (offsetX - LEVEL_STOP_INSET) / usable;
134
+ const index = Math.round(fraction * (count - 1));
135
+ return Math.max(0, Math.min(count - 1, index));
136
+ }
137
+ //# sourceMappingURL=constants.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["LEVEL_TRACK_HEIGHT","exports","LEVEL_THUMB_SIZE","LEVEL_STOP_SIZE","LEVEL_STOP_INSET","LEVEL_SLIDER_ROW_HEIGHT","LEVEL_ROW_INSET","LEVEL_TRACK_CLASS","LEVEL_FILL_CLASS","LEVEL_STOP_CLASS","LEVEL_STOP_REACHED_CLASS","LEVEL_THUMB_CLASS","LEVEL_CAPTION_CLASS","LEVEL_SEPARATOR_CLASS","levelStopPosition","index","count","fraction","percent","offset","levelFromOffset","offsetX","trackWidth","usable","Math","round","max","min"],"sourceRoot":"../../../src","sources":["level-picker/constants.ts"],"mappings":";;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACO,MAAMA,kBAAkB,GAAAC,OAAA,CAAAD,kBAAA,GAAG,EAAE;;AAEpC;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAME,gBAAgB,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AEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,SAASgB,eAAeA,CAACC,OAAe,EAAEC,UAAkB,EAAEN,KAAa,EAAU;EAC1F,IAAIA,KAAK,IAAI,CAAC,EAAE,OAAO,CAAC;EACxB,MAAMO,MAAM,GAAGD,UAAU,GAAG,CAAC,GAAGlB,gBAAgB;EAChD,MAAMa,QAAQ,GAAGM,MAAM,IAAI,CAAC,GAAG,CAAC,GAAG,CAACF,OAAO,GAAGjB,gBAAgB,IAAImB,MAAM;EACxE,MAAMR,KAAK,GAAGS,IAAI,CAACC,KAAK,CAACR,QAAQ,IAAID,KAAK,GAAG,CAAC,CAAC,CAAC;EAChD,OAAOQ,IAAI,CAACE,GAAG,CAAC,CAAC,EAAEF,IAAI,CAACG,GAAG,CAACX,KAAK,GAAG,CAAC,EAAED,KAAK,CAAC,CAAC;AAChD","ignoreList":[]}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "LevelPicker", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _LevelPicker.LevelPicker;
10
+ }
11
+ });
12
+ var _LevelPicker = require("./LevelPicker");
13
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_LevelPicker","require"],"sourceRoot":"../../../src","sources":["level-picker/index.ts"],"mappings":";;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA","ignoreList":[]}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "LevelPicker", {
7
+ enumerable: true,
8
+ get: function () {
9
+ return _LevelPickerWeb.LevelPicker;
10
+ }
11
+ });
12
+ var _LevelPickerWeb = require("./LevelPicker.web.js");
13
+ //# sourceMappingURL=index.web.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["_LevelPickerWeb","require"],"sourceRoot":"../../../src","sources":["level-picker/index.web.ts"],"mappings":";;;;;;;;;;;AAAA,IAAAA,eAAA,GAAAC,OAAA","ignoreList":[]}
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":[],"sourceRoot":"../../../src","sources":["level-picker/types.ts"],"mappings":"","ignoreList":[]}