@hzblj/kara-components 0.10.0 → 0.11.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 (185) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/lib/module/atoms/activity-indicator/activity-indicator.android.js +6 -1
  3. package/lib/module/atoms/activity-indicator/activity-indicator.android.js.map +1 -1
  4. package/lib/module/atoms/activity-indicator/activity-indicator.ios.js +2 -0
  5. package/lib/module/atoms/activity-indicator/activity-indicator.ios.js.map +1 -1
  6. package/lib/module/atoms/avatar/avatar.js +5 -0
  7. package/lib/module/atoms/avatar/avatar.js.map +1 -1
  8. package/lib/module/atoms/button/button-tokens.js +2 -2
  9. package/lib/module/atoms/button/button-tokens.js.map +1 -1
  10. package/lib/module/atoms/button/button.android.js +6 -2
  11. package/lib/module/atoms/button/button.android.js.map +1 -1
  12. package/lib/module/atoms/button/button.ios.js +7 -2
  13. package/lib/module/atoms/button/button.ios.js.map +1 -1
  14. package/lib/module/atoms/card/card.android.js +5 -3
  15. package/lib/module/atoms/card/card.android.js.map +1 -1
  16. package/lib/module/atoms/card/card.ios.js +7 -3
  17. package/lib/module/atoms/card/card.ios.js.map +1 -1
  18. package/lib/module/atoms/checkbox/checkbox.android.js +1 -1
  19. package/lib/module/atoms/checkbox/checkbox.android.js.map +1 -1
  20. package/lib/module/atoms/fab/fab.android.js +9 -1
  21. package/lib/module/atoms/fab/fab.android.js.map +1 -1
  22. package/lib/module/atoms/fab/fab.ios.js +9 -3
  23. package/lib/module/atoms/fab/fab.ios.js.map +1 -1
  24. package/lib/module/atoms/glass-view/glass-view.android.js +1 -1
  25. package/lib/module/atoms/glass-view/glass-view.android.js.map +1 -1
  26. package/lib/module/atoms/h-stack/h-stack.ios.js +5 -3
  27. package/lib/module/atoms/h-stack/h-stack.ios.js.map +1 -1
  28. package/lib/module/atoms/icon-button/icon-button.android.js +9 -0
  29. package/lib/module/atoms/icon-button/icon-button.android.js.map +1 -1
  30. package/lib/module/atoms/icon-button/icon-button.ios.js +9 -2
  31. package/lib/module/atoms/icon-button/icon-button.ios.js.map +1 -1
  32. package/lib/module/atoms/image/image.js +4 -4
  33. package/lib/module/atoms/image/image.js.map +1 -1
  34. package/lib/module/atoms/pressable/pressable.js +26 -25
  35. package/lib/module/atoms/pressable/pressable.js.map +1 -1
  36. package/lib/module/atoms/progress/progress.android.js +7 -0
  37. package/lib/module/atoms/progress/progress.android.js.map +1 -1
  38. package/lib/module/atoms/progress/progress.ios.js +6 -1
  39. package/lib/module/atoms/progress/progress.ios.js.map +1 -1
  40. package/lib/module/atoms/segmented-control/segmented-control.android.js +1 -1
  41. package/lib/module/atoms/segmented-control/segmented-control.android.js.map +1 -1
  42. package/lib/module/atoms/segmented-control/segmented-control.ios.js +1 -1
  43. package/lib/module/atoms/segmented-control/segmented-control.ios.js.map +1 -1
  44. package/lib/module/atoms/skeleton/skeleton.js +20 -6
  45. package/lib/module/atoms/skeleton/skeleton.js.map +1 -1
  46. package/lib/module/atoms/surface/surface.android.js +5 -3
  47. package/lib/module/atoms/surface/surface.android.js.map +1 -1
  48. package/lib/module/atoms/surface/surface.ios.js +7 -3
  49. package/lib/module/atoms/surface/surface.ios.js.map +1 -1
  50. package/lib/module/atoms/switch/switch.android.js +1 -1
  51. package/lib/module/atoms/switch/switch.android.js.map +1 -1
  52. package/lib/module/atoms/text/text.android.js +5 -3
  53. package/lib/module/atoms/text/text.android.js.map +1 -1
  54. package/lib/module/atoms/text/text.ios.js +6 -4
  55. package/lib/module/atoms/text/text.ios.js.map +1 -1
  56. package/lib/module/atoms/v-stack/v-stack.ios.js +5 -3
  57. package/lib/module/atoms/v-stack/v-stack.ios.js.map +1 -1
  58. package/lib/module/atoms/z-stack/z-stack.ios.js +5 -3
  59. package/lib/module/atoms/z-stack/z-stack.ios.js.map +1 -1
  60. package/lib/module/glyph/glyph.android.js +2 -0
  61. package/lib/module/glyph/glyph.android.js.map +1 -1
  62. package/lib/module/glyph/glyph.ios.js +5 -2
  63. package/lib/module/glyph/glyph.ios.js.map +1 -1
  64. package/lib/module/molecules/collapsible/collapsible.android.js +18 -8
  65. package/lib/module/molecules/collapsible/collapsible.android.js.map +1 -1
  66. package/lib/module/molecules/labeled-content/labeled-content.js +4 -1
  67. package/lib/module/molecules/labeled-content/labeled-content.js.map +1 -1
  68. package/lib/module/molecules/link/link.js +4 -1
  69. package/lib/module/molecules/link/link.js.map +1 -1
  70. package/lib/module/molecules/list-item/list-item.js +4 -1
  71. package/lib/module/molecules/list-item/list-item.js.map +1 -1
  72. package/lib/module/molecules/navigation-bar/navigation-bar.android.js +1 -1
  73. package/lib/module/molecules/navigation-bar/navigation-bar.android.js.map +1 -1
  74. package/lib/module/molecules/navigation-bar/navigation-bar.ios.js +1 -1
  75. package/lib/module/molecules/navigation-bar/navigation-bar.ios.js.map +1 -1
  76. package/lib/module/molecules/rn-list-item/rn-list-item.js +10 -2
  77. package/lib/module/molecules/rn-list-item/rn-list-item.js.map +1 -1
  78. package/lib/module/molecules/scroll-edge-container/scroll-edge-container.android.js +3 -4
  79. package/lib/module/molecules/scroll-edge-container/scroll-edge-container.android.js.map +1 -1
  80. package/lib/module/molecules/stepper/stepper.ios.js +6 -2
  81. package/lib/module/molecules/stepper/stepper.ios.js.map +1 -1
  82. package/lib/module/motion.js +19 -0
  83. package/lib/module/motion.js.map +1 -0
  84. package/lib/module/organisms/fab-menu/fab-menu.android.js +8 -5
  85. package/lib/module/organisms/fab-menu/fab-menu.android.js.map +1 -1
  86. package/lib/module/organisms/fab-menu/fab-menu.ios.js +5 -2
  87. package/lib/module/organisms/fab-menu/fab-menu.ios.js.map +1 -1
  88. package/lib/module/organisms/snackbar/snackbar.js +142 -17
  89. package/lib/module/organisms/snackbar/snackbar.js.map +1 -1
  90. package/lib/module/organisms/swipe-actions/swipe-actions.android.js +1 -1
  91. package/lib/module/organisms/swipe-actions/swipe-actions.android.js.map +1 -1
  92. package/lib/module/use-stack-modifiers.js +10 -8
  93. package/lib/module/use-stack-modifiers.js.map +1 -1
  94. package/lib/typescript/atoms/activity-indicator/activity-indicator.types.d.ts +2 -0
  95. package/lib/typescript/atoms/avatar/avatar.types.d.ts +5 -0
  96. package/lib/typescript/atoms/button/button-tokens.d.ts +1 -1
  97. package/lib/typescript/atoms/button/button.types.d.ts +2 -0
  98. package/lib/typescript/atoms/card/card.types.d.ts +2 -2
  99. package/lib/typescript/atoms/fab/fab.types.d.ts +8 -1
  100. package/lib/typescript/atoms/h-stack/h-stack.types.d.ts +6 -3
  101. package/lib/typescript/atoms/icon-button/icon-button.types.d.ts +7 -0
  102. package/lib/typescript/atoms/image/image.d.ts +2 -2
  103. package/lib/typescript/atoms/pressable/pressable.types.d.ts +9 -9
  104. package/lib/typescript/atoms/progress/progress.types.d.ts +2 -0
  105. package/lib/typescript/atoms/skeleton/skeleton.types.d.ts +3 -2
  106. package/lib/typescript/atoms/surface/surface.types.d.ts +2 -2
  107. package/lib/typescript/atoms/text/text.types.d.ts +2 -2
  108. package/lib/typescript/atoms/v-stack/v-stack.types.d.ts +3 -3
  109. package/lib/typescript/atoms/z-stack/z-stack.types.d.ts +3 -3
  110. package/lib/typescript/glyph/glyph.types.d.ts +2 -0
  111. package/lib/typescript/molecules/labeled-content/labeled-content.types.d.ts +4 -2
  112. package/lib/typescript/molecules/link/link.types.d.ts +2 -1
  113. package/lib/typescript/molecules/list-item/list-item.types.d.ts +5 -3
  114. package/lib/typescript/molecules/stepper/stepper.ios.d.ts +1 -1
  115. package/lib/typescript/motion.d.ts +8 -0
  116. package/lib/typescript/organisms/fab-menu/fab-menu.types.d.ts +5 -0
  117. package/lib/typescript/organisms/snackbar/snackbar.types.d.ts +38 -5
  118. package/lib/typescript/use-stack-modifiers.d.ts +6 -5
  119. package/package.json +4 -4
  120. package/src/atoms/activity-indicator/activity-indicator.android.tsx +7 -1
  121. package/src/atoms/activity-indicator/activity-indicator.ios.tsx +9 -1
  122. package/src/atoms/activity-indicator/activity-indicator.types.ts +2 -0
  123. package/src/atoms/avatar/avatar.tsx +5 -1
  124. package/src/atoms/avatar/avatar.types.ts +5 -0
  125. package/src/atoms/button/button-tokens.ts +2 -2
  126. package/src/atoms/button/button.android.tsx +5 -3
  127. package/src/atoms/button/button.ios.tsx +10 -2
  128. package/src/atoms/button/button.types.ts +2 -0
  129. package/src/atoms/card/card.android.tsx +6 -4
  130. package/src/atoms/card/card.ios.tsx +7 -3
  131. package/src/atoms/card/card.types.ts +8 -7
  132. package/src/atoms/checkbox/checkbox.android.tsx +1 -1
  133. package/src/atoms/fab/fab.android.tsx +5 -3
  134. package/src/atoms/fab/fab.ios.tsx +8 -4
  135. package/src/atoms/fab/fab.types.ts +8 -1
  136. package/src/atoms/glass-view/glass-view.android.tsx +1 -1
  137. package/src/atoms/h-stack/h-stack.ios.tsx +6 -4
  138. package/src/atoms/h-stack/h-stack.types.ts +17 -13
  139. package/src/atoms/icon-button/icon-button.android.tsx +16 -3
  140. package/src/atoms/icon-button/icon-button.ios.tsx +13 -4
  141. package/src/atoms/icon-button/icon-button.types.ts +7 -0
  142. package/src/atoms/image/image.tsx +3 -3
  143. package/src/atoms/pressable/pressable.tsx +26 -18
  144. package/src/atoms/pressable/pressable.types.ts +30 -29
  145. package/src/atoms/progress/progress.android.tsx +5 -3
  146. package/src/atoms/progress/progress.ios.tsx +5 -2
  147. package/src/atoms/progress/progress.types.ts +2 -0
  148. package/src/atoms/segmented-control/segmented-control.android.tsx +1 -1
  149. package/src/atoms/segmented-control/segmented-control.ios.tsx +1 -1
  150. package/src/atoms/skeleton/skeleton.tsx +18 -4
  151. package/src/atoms/skeleton/skeleton.types.ts +3 -2
  152. package/src/atoms/surface/surface.android.tsx +6 -4
  153. package/src/atoms/surface/surface.ios.tsx +7 -3
  154. package/src/atoms/surface/surface.types.ts +10 -9
  155. package/src/atoms/switch/switch.android.tsx +1 -1
  156. package/src/atoms/text/text.android.tsx +6 -4
  157. package/src/atoms/text/text.ios.tsx +6 -4
  158. package/src/atoms/text/text.types.ts +23 -22
  159. package/src/atoms/v-stack/v-stack.ios.tsx +6 -4
  160. package/src/atoms/v-stack/v-stack.types.ts +17 -16
  161. package/src/atoms/z-stack/z-stack.ios.tsx +6 -4
  162. package/src/atoms/z-stack/z-stack.types.ts +15 -14
  163. package/src/glyph/glyph.android.tsx +14 -2
  164. package/src/glyph/glyph.ios.tsx +13 -3
  165. package/src/glyph/glyph.types.ts +2 -0
  166. package/src/molecules/collapsible/collapsible.android.tsx +27 -7
  167. package/src/molecules/labeled-content/labeled-content.tsx +12 -1
  168. package/src/molecules/labeled-content/labeled-content.types.ts +4 -2
  169. package/src/molecules/link/link.tsx +2 -1
  170. package/src/molecules/link/link.types.ts +2 -1
  171. package/src/molecules/list-item/list-item.tsx +20 -2
  172. package/src/molecules/list-item/list-item.types.ts +5 -3
  173. package/src/molecules/navigation-bar/navigation-bar.android.tsx +1 -1
  174. package/src/molecules/navigation-bar/navigation-bar.ios.tsx +1 -1
  175. package/src/molecules/rn-list-item/rn-list-item.tsx +18 -3
  176. package/src/molecules/scroll-edge-container/scroll-edge-container.android.tsx +3 -2
  177. package/src/molecules/stepper/stepper.ios.tsx +8 -2
  178. package/src/motion.ts +13 -0
  179. package/src/organisms/fab-menu/fab-menu.android.tsx +9 -5
  180. package/src/organisms/fab-menu/fab-menu.ios.tsx +6 -2
  181. package/src/organisms/fab-menu/fab-menu.types.ts +5 -0
  182. package/src/organisms/snackbar/snackbar.tsx +143 -19
  183. package/src/organisms/snackbar/snackbar.types.ts +41 -5
  184. package/src/organisms/swipe-actions/swipe-actions.android.tsx +1 -1
  185. package/src/use-stack-modifiers.ts +20 -7
@@ -17,16 +17,16 @@ const FabMenuRow = ({
17
17
  const onClick = useCallback(() => onSelect(action), [action, onSelect]);
18
18
  return /*#__PURE__*/_jsxs(FloatingActionButtonMenuItem, {
19
19
  containerColor: theme.color('fill.accent.primary'),
20
- contentColor: theme.color('content.on.bg'),
20
+ contentColor: theme.color('content.on.accent'),
21
21
  onClick: onClick,
22
22
  children: [action.icon ? /*#__PURE__*/_jsx(FloatingActionButtonMenuItem.Icon, {
23
23
  children: /*#__PURE__*/_jsx(Icon, {
24
- color: "content.on.bg",
24
+ color: "content.on.accent",
25
25
  name: action.icon
26
26
  })
27
27
  }) : null, /*#__PURE__*/_jsx(FloatingActionButtonMenuItem.Text, {
28
28
  children: /*#__PURE__*/_jsx(ComposeText, {
29
- color: theme.colorString('content.on.bg'),
29
+ color: theme.colorString('content.on.accent'),
30
30
  style: theme.typography.labelMedium,
31
31
  children: action.label
32
32
  })
@@ -40,6 +40,7 @@ const FabMenuRow = ({
40
40
  * unfolding rather than a second surface.
41
41
  */
42
42
  export const FabMenu = ({
43
+ accessibilityLabel,
43
44
  actions,
44
45
  icon
45
46
  }) => {
@@ -60,10 +61,12 @@ export const FabMenu = ({
60
61
  onCheckedChange: setExpanded,
61
62
  children: /*#__PURE__*/_jsx(ToggleFloatingActionButton.Icon, {
62
63
  children: icon ? /*#__PURE__*/_jsx(Icon, {
63
- color: "content.on.bg",
64
+ accessibilityLabel: accessibilityLabel,
65
+ color: "content.on.accent",
64
66
  name: icon
65
67
  }) : /*#__PURE__*/_jsx(Glyph, {
66
- color: "content.on.bg",
68
+ accessibilityLabel: accessibilityLabel,
69
+ color: "content.on.accent",
67
70
  name: "plus"
68
71
  })
69
72
  })
@@ -1 +1 @@
1
- {"version":3,"names":["Text","ComposeText","FloatingActionButtonMenu","FloatingActionButtonMenuItem","ToggleFloatingActionButton","useAppTheme","useCallback","useState","Icon","Glyph","useHostGuard","jsx","_jsx","jsxs","_jsxs","FabMenuRow","action","onSelect","theme","onClick","containerColor","color","contentColor","children","icon","name","colorString","style","typography","labelMedium","label","FabMenu","actions","expanded","setExpanded","onPress","horizontalAlignment","Button","checked","onCheckedChange","map"],"sourceRoot":"../../../../src","sources":["organisms/fab-menu/fab-menu.android.tsx"],"mappings":";;AAAA,SAAQA,IAAI,IAAIC,WAAW,QAAO,0BAA0B;AAC5D,SACEC,wBAAwB,EACx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u","FloatingActionButtonMenuItem","ToggleFloatingActionButton","useAppTheme","useCallback","useState","Icon","Glyph","useHostGuard","jsx","_jsx","jsxs","_jsxs","FabMenuRow","action","onSelect","theme","onClick","containerColor","color","contentColor","children","icon","name","colorString","style","typography","labelMedium","label","FabMenu","accessibilityLabel","actions","expanded","setExpanded","onPress","horizontalAlignment","Button","checked","onCheckedChange","map"],"sourceRoot":"../../../../src","sources":["organisms/fab-menu/fab-menu.android.tsx"],"mappings":";;AAAA,SAAQA,IAAI,IAAIC,WAAW,QAAO,0BAA0B;AAC5D,SACEC,wBAAwB,EACxBC,4BAA4B,EAC5BC,0BAA0B,QACrB,oCAAoC;AAC3C,SAAQC,WAAW,QAAO,mBAAmB;AAC7C,SAAQC,WAAW,EAAEC,QAAQ,QAAO,OAAO;AAC3C,SAAQC,IAAI,QAAO,2BAAkB;AACrC,SAAQC,KAAK,QAAO,sBAAa;AACjC,SAAQC,YAAY,QAAO,uBAAoB;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAS/C;AACA,MAAMC,UAAU,GAAGA,CAAC;EAACC,MAAM;EAAEC;AAAyB,CAAC,KAAK;EAC1D,MAAMC,KAAK,GAAGb,WAAW,CAAC,CAAC;EAC3B,MAAMc,OAAO,GAAGb,WAAW,CAAC,MAAMW,QAAQ,CAACD,MAAM,CAAC,EAAE,CAACA,MAAM,EAAEC,QAAQ,CAAC,CAAC;EAEvE,oBACEH,KAAA,CAACX,4BAA4B;IAC3BiB,cAAc,EAAEF,KAAK,CAACG,KAAK,CAAC,qBAAqB,CAAE;IACnDC,YAAY,EAAEJ,KAAK,CAACG,KAAK,CAAC,mBAAmB,CAAE;IAC/CF,OAAO,EAAEA,OAAQ;IAAAI,QAAA,GAEhBP,MAAM,CAACQ,IAAI,gBACVZ,IAAA,CAACT,4BAA4B,CAACK,IAAI;MAAAe,QAAA,eAChCX,IAAA,CAACJ,IAAI;QAACa,KAAK,EAAC,mBAAmB;QAACI,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X,KAAK,EAAC,mBAAmB;YAACI,IAAI,EAAED;UAAK,CAAE,CAAC,gBAEtFZ,IAAA,CAACH,KAAK;YAACuB,kBAAkB,EAAEA,kBAAmB;YAACX,KAAK,EAAC,mBAAmB;YAACI,IAAI,EAAC;UAAM,CAAE;QACvF,CAC8B;MAAC,CACR;IAAC,CACE,CAAC,EACjCQ,OAAO,CAACQ,GAAG,CAACzB,MAAM,iBACjBJ,IAAA,CAACG,UAAU;MAACC,MAAM,EAAEA,MAAO;MAAoBC,QAAQ,EAAEA;IAAS,GAAjCD,MAAM,CAACc,KAA4B,CACrE,CAAC;EAAA,CACsB,CAAC;AAE/B,CAAC","ignoreList":[]}
@@ -10,6 +10,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
10
10
  /** Matches `Fab`, so a screen can switch between the two without the button changing shape. */
11
11
  const FAB_SIZE = 56;
12
12
  export const FabMenu = ({
13
+ accessibilityLabel,
13
14
  actions,
14
15
  icon,
15
16
  testID
@@ -25,10 +26,12 @@ export const FabMenu = ({
25
26
  shadow: "btn.accent",
26
27
  w: FAB_SIZE,
27
28
  children: icon ? /*#__PURE__*/_jsx(Icon, {
28
- color: "content.on.bg",
29
+ accessibilityLabel: accessibilityLabel,
30
+ color: "content.on.accent",
29
31
  name: icon
30
32
  }) : /*#__PURE__*/_jsx(Glyph, {
31
- color: "content.on.bg",
33
+ accessibilityLabel: accessibilityLabel,
34
+ color: "content.on.accent",
32
35
  name: "plus"
33
36
  })
34
37
  }),
@@ -1 +1 @@
1
- {"version":3,"names":["Button","Image","Label","Menu","iconResourceName","Icon","VStack","Glyph","useHostGuard","jsx","_jsx","FAB_SIZE","FabMenu","actions","icon","testID","label","align","bg","borderRadius","h","p","shadow","w","children","color","name","map","action","onPress","role","destructive","assetName","undefined","title"],"sourceRoot":"../../../../src","sources":["organisms/fab-menu/fab-menu.ios.tsx"],"mappings":";;AAAA,SAAQA,MAAM,EAAEC,KAAK,EAAEC,KAAK,EAAEC,IAAI,QAAO,mB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B,SAAU;QACpFC,KAAK,EAAEN,MAAM,CAACZ;MAAM,CACrB;IAAC,GALSY,MAAM,CAACZ,KAMZ,CACT;EAAC,CACE,CAAC;AAEX,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["Button","Image","Label","Menu","iconResourceName","Icon","VStack","Glyph","useHostGuard","jsx","_jsx","FAB_SIZE","FabMenu","accessibilityLabel","actions","icon","testID","label","align","bg","borderRadius","h","p","shadow","w","children","color","name","map","action","onPress","role","destructive","assetName","undefined","title"],"sourceRoot":"../../../../src","sources":["organisms/fab-menu/fab-menu.ios.tsx"],"mappings":";;AAAA,SAAQA,MAAM,EAAEC,KAAK,EAAEC,KAAK,EAAEC,IAAI,QAAO,mBAAmB;AAC5D,SAAQC,gBAAgB,QAAO,oBAAoB;AAEnD,SAAQC,IAAI,QAAO,2BAAkB;AACrC,SAAQC,MAAM,QAAO,8BAAqB;AAC1C,SAAQC,KAAK,QAAO,sBAAa;AACjC,SAAQC,YAAY,QAAO,uBAAoB;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAG/C;AACA,MAAMC,QAAQ,GAAG,EAAE;AAEnB,OAAO,MAAMC,OAAyB,GAAGA,CAAC;EAACC,kBAAkB;EAAEC,OAAO;EAAEC,IAAI;EAAEC;AAAoB,CAAC,KAAK;EACtGR,YAAY,CAAC,SAAS,CAAC;EAEvB,oBACEE,IAAA,CAACP,IAAI;IACHc,KAAK,eACHP,IAAA,CAACJ,MAAM;MACLY,KAAK,EAAC,QAAQ;MACdC,EAAE,EAAC,qBAAqB;MACxBC,YAAY,EAAC,MAAM;MACnBC,CAAC,EAAEV,QAAS;MACZW,CAAC,EAAC,KAAK;MACPC,MAAM,EAAC,YAAY;MACnBC,CAAC,EAAEb,QAAS;MAAAc,QAAA,EAEXV,IAAI,gBACHL,IAAA,CAACL,IAAI;QAACQ,kBAAkB,EAAEA,kBAAmB;QAACa,KAAK,EAAC,mBAAmB;QAACC,IAAI,EAAEZ;MAAK,CAAE,CAAC,gBAEtFL,IAAA,CAACH,KAAK;QAACM,kBAAkB,EAAEA,kBAAmB;QAACa,KAAK,EAAC,mBAAmB;QAACC,IAAI,EAAC;MAAM,CAAE;IACvF,CACK,CACT;IACDX,MAAM,EAAEA,MAAO;IAAAS,QAAA,EAEdX,OAAO,CAACc,GAAG,CAACC,MAAM,iBACjBnB,IAAA,CAACV,MAAM;MAAoB8B,OAAO,EAAED,MAAM,CAACC,OAAQ;MAACC,IAAI,EAAEF,MAAM,CAACG,WAAW,GAAG,aAAa,GAAG,SAAU;MAAAP,QAAA,eAEvGf,IAAA,CAACR,KAAK;QACJa,IAAI,EAAEc,MAAM,CAACd,IAAI,gBAAGL,IAAA,CAACT,KAAK;UAACgC,SAAS,EAAE7B,gBAAgB,CAACyB,MAAM,CAACd,IAAI;QAAE,CAAE,CAAC,GAAGmB,SAAU;QACpFC,KAAK,EAAEN,MAAM,CAACZ;MAAM,CACrB;IAAC,GALSY,MAAM,CAACZ,KAMZ,CACT;EAAC,CACE,CAAC;AAEX,CAAC","ignoreList":[]}
@@ -1,45 +1,170 @@
1
1
  "use strict";
2
2
 
3
- import { FadeInDown, FadeOutDown } from 'react-native-reanimated';
4
- import { ABox } from "../../atoms/box/index.js";
3
+ import { duration as durations, easing, spacing, useReducedMotion } from '@hzblj/kara-theme';
4
+ import { useEffect, useRef } from 'react';
5
+ import { AccessibilityInfo, Platform } from 'react-native';
6
+ import { Easing, FadeIn, FadeInDown, FadeInUp, FadeOut, FadeOutDown, FadeOutUp, ReduceMotion, withTiming } from 'react-native-reanimated';
7
+ import { ABox, Box } from "../../atoms/box/index.js";
5
8
  import { Pressable } from "../../atoms/pressable/index.js";
6
9
  import { RnText } from "../../atoms/rn-text/index.js";
10
+ import { RnGlyph } from "../../glyph/index.js";
11
+ import { timing } from "../../motion.js";
7
12
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
+ /** Material's `SnackbarDuration.Short` and `Long`. */
14
+ const DURATIONS = {
15
+ long: 10_000,
16
+ short: 4_000
17
+ };
18
+ const PLATFORM_ANIMATION = Platform.OS === 'android' ? 'scale' : 'slide';
19
+
20
+ /** The close glyph at the label's height: an SF Symbol fills its box, Material's icon sits inside a padded one. */
21
+ const CLOSE_SIZE = Platform.OS === 'ios' ? 's12' : 's16';
22
+ const SMOOTH_OUT = Easing.bezier(...easing.smoothOut);
23
+ const GROW = timing('quick');
24
+
25
+ /** Material's snackbar enter: it fades in while it grows from 80 %, in 150 ms. */
26
+ const scaleIn = () => {
27
+ 'worklet';
28
+
29
+ return {
30
+ animations: {
31
+ opacity: withTiming(1, GROW),
32
+ transform: [{
33
+ scale: withTiming(1, GROW)
34
+ }]
35
+ },
36
+ initialValues: {
37
+ opacity: 0,
38
+ transform: [{
39
+ scale: 0.8
40
+ }]
41
+ }
42
+ };
43
+ };
44
+
45
+ /**
46
+ * The presets in and out: arriving in `fast`, leaving in `quick`, both on `smoothOut`. `ReduceMotion.Never`, because
47
+ * `useReducedMotion` has already picked the fade by then, and a fade is what should still run.
48
+ */
49
+ const TRANSITIONS = {
50
+ fade: {
51
+ entering: FadeIn.duration(durations.fast).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never),
52
+ exiting: FadeOut.duration(durations.quick).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never)
53
+ },
54
+ // Material's exit is a 75 ms fade: `micro`.
55
+ scale: {
56
+ entering: scaleIn,
57
+ exiting: FadeOut.duration(durations.micro).reduceMotion(ReduceMotion.Never)
58
+ },
59
+ // Slide: in from the edge it sits on, and back out toward it.
60
+ slideBottom: {
61
+ entering: FadeInDown.duration(durations.fast).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never),
62
+ exiting: FadeOutDown.duration(durations.quick).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never)
63
+ },
64
+ slideTop: {
65
+ entering: FadeInUp.duration(durations.fast).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never),
66
+ exiting: FadeOutUp.duration(durations.quick).easing(SMOOTH_OUT).reduceMotion(ReduceMotion.Never)
67
+ }
68
+ };
69
+ const transitionsFor = (animation, position) => {
70
+ if (animation === 'slide') {
71
+ return position === 'top' ? TRANSITIONS.slideTop : TRANSITIONS.slideBottom;
72
+ }
73
+ return TRANSITIONS[animation];
74
+ };
75
+ const millisecondsOf = duration => typeof duration === 'number' ? duration : duration === 'indefinite' ? undefined : DURATIONS[duration];
8
76
  export const Snackbar = ({
9
77
  actionLabel,
78
+ actionOnNewLine = false,
79
+ animation = PLATFORM_ANIMATION,
80
+ dismissible = false,
81
+ duration = 'indefinite',
82
+ entering,
83
+ exiting,
10
84
  message,
85
+ offset = 's24',
11
86
  onAction,
87
+ onDismiss,
88
+ position = 'bottom',
12
89
  visible
13
90
  }) => {
91
+ const reduced = useReducedMotion();
92
+ // A caller's inline `onDismiss` is a new function every render; the timer must not restart for it.
93
+ const dismiss = useRef(onDismiss);
94
+ dismiss.current = onDismiss;
95
+
96
+ // biome-ignore lint/correctness/useExhaustiveDependencies: a new `message` restarts the timer, as a new snackbar
97
+ useEffect(() => {
98
+ const milliseconds = millisecondsOf(duration);
99
+ if (!visible || milliseconds === undefined) {
100
+ return;
101
+ }
102
+ const timer = setTimeout(() => dismiss.current?.(), milliseconds);
103
+ return () => clearTimeout(timer);
104
+ }, [duration, message, visible]);
105
+
106
+ // Material's snackbar is announced; a React Native view is not unless asked.
107
+ useEffect(() => {
108
+ if (visible) {
109
+ AccessibilityInfo.announceForAccessibility(message);
110
+ }
111
+ }, [message, visible]);
14
112
  if (!visible) {
15
113
  return null;
16
114
  }
115
+ const edge = position === 'top' ? {
116
+ top: spacing[offset]
117
+ } : {
118
+ bottom: spacing[offset]
119
+ };
120
+ const hasTrailing = Boolean(actionLabel) || dismissible;
121
+ // With motion reduced it only fades: nothing slides or grows.
122
+ const preset = transitionsFor(reduced ? 'fade' : animation, position);
17
123
  return /*#__PURE__*/_jsxs(ABox, {
18
- align: "center",
124
+ align: actionOnNewLine ? 'stretch' : 'center',
19
125
  bg: "surface.high.contrast",
20
126
  borderRadius: "medium",
21
- bottom: 24,
22
- entering: FadeInDown,
23
- exiting: FadeOutDown,
24
- flexDirection: "row",
25
- gap: "s12",
26
- left: 16,
127
+ flexDirection: actionOnNewLine ? 'column' : 'row',
128
+ gap: actionOnNewLine ? 's8' : 's12',
129
+ left: spacing.s16,
27
130
  position: "absolute",
28
131
  px: "s16",
29
132
  py: "s12",
30
- right: 16,
133
+ right: spacing.s16,
31
134
  shadow: "snackbar",
135
+ ...edge,
136
+ entering: entering ?? preset.entering,
137
+ exiting: exiting ?? preset.exiting,
32
138
  children: [/*#__PURE__*/_jsx(RnText, {
33
139
  color: "content.on.high.contrast",
140
+ flex: actionOnNewLine ? undefined : 1,
34
141
  variant: "footnote",
35
142
  children: message
36
- }), actionLabel ? /*#__PURE__*/_jsx(Pressable, {
37
- onPress: onAction,
38
- children: /*#__PURE__*/_jsx(RnText, {
39
- color: "content.accent",
40
- variant: "footnoteMedium",
41
- children: actionLabel
42
- })
143
+ }), hasTrailing ? /*#__PURE__*/_jsxs(Box, {
144
+ align: "center",
145
+ alignSelf: actionOnNewLine ? 'flex-end' : undefined,
146
+ flexDirection: "row",
147
+ gap: "s16",
148
+ children: [actionLabel ? /*#__PURE__*/_jsx(Pressable, {
149
+ onPress: onAction,
150
+ pressEffect: "opacity",
151
+ ripple: false,
152
+ children: /*#__PURE__*/_jsx(RnText, {
153
+ color: "content.accent",
154
+ variant: "footnoteMedium",
155
+ children: actionLabel
156
+ })
157
+ }) : null, dismissible ? /*#__PURE__*/_jsx(Pressable, {
158
+ accessibilityLabel: "Dismiss",
159
+ onPress: onDismiss,
160
+ pressEffect: "opacity",
161
+ ripple: false,
162
+ children: /*#__PURE__*/_jsx(RnGlyph, {
163
+ color: "content.on.high.contrast",
164
+ name: "close",
165
+ size: CLOSE_SIZE
166
+ })
167
+ }) : null]
43
168
  }) : null]
44
169
  });
45
170
  };
@@ -1 +1 @@
1
- {"version":3,"names":["FadeInDown","FadeOutDown","ABox","Pressable","RnText","jsx","_jsx","jsxs","_jsxs","Snackbar","actionLabel","message","onAction","visible","align","bg","borderRadius","bottom","entering","exiting","flexDirection","gap","left","position","px","py","right","shadow","children","color","variant","onPress"],"sourceRoot":"../../../../src","sources":["organisms/snackbar/snackbar.tsx"],"mappings":";;AAAA,SAAQA,UAAU,EAAEC,WAAW,QAAO,yBAAyB;AAE/D,SAAQC,IAAI,QAAO,0BAAiB;AACpC,SAAQC,SAAS,QAAO,gCAAuB;AAC/C,SAAQC,MAAM,QAAO,8BAAqB;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAG1C,OAAO,MAAMC,QAA2B,GAAGA,CAAC;EAACC,WAAW;EAAEC,OAAO;EAAEC,QAAQ;EAAEC;AAAsB,CAAC,KAAK;EACvG,IAAI,CAACA,OAAO,EAAE;IACZ,OAAO,IAAI;EACb;EAEA,oBACEL,KAAA,CAACN,IAAI;IACHY,KAAK,EAAC,QAAQ;IACdC,EAAE,EAAC,uBAAuB;IAC1BC,YAAY,EAAC,QAAQ;IACrBC,MAAM,EAAE,EAAG;IACXC,QAAQ,EAAElB,UAAW;IACrBmB,OAAO,EAAElB,WAAY;IACrBmB,aAAa,EAAC,KAAK;IACnBC,GAAG,EAAC,KAAK;IACTC,IAAI,EAAE,EAAG;IACTC,QAAQ,EAAC,UAAU;IACnBC,EAAE,EAAC,KAAK;IACRC,EAAE,EAAC,KAAK;IACRC,KAAK,EAAE,EAAG;IACVC,MAAM,EAAC,UAAU;IAAAC,QAAA,gBAEjBtB,IAAA,CAACF,MAAM;MAACyB,KAAK,EAAC,0BAA0B;MAACC,OAAO,EAAC,UAAU;MAAAF,QAAA,EACxDjB;IAAO,CACF,CAAC,EACRD,WAAW,gBACVJ,IAAA,CAACH,SAAS;MAAC4B,OAAO,EAAEnB,QAAS;MAAAgB,QAAA,eAC3BtB,IAAA,CAACF,MAAM;QAACyB,KAAK,EAAC,gBAAgB;QAACC,OAAO,EAAC,gBAAgB;QAAAF,QAAA,EACpDlB;MAAW,CACN;IAAC,CACA,CAAC,GACV,IAAI;EAAA,CACJ,CAAC;AAEX,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["duration","durations","easing","spacing","useReducedMotion","useEffect","useRef","AccessibilityInfo","Platform","Easing","FadeIn","FadeInDown","FadeInUp","FadeOut","FadeOutDown","FadeOutUp","ReduceMotion","withTiming","ABox","Box","Pressable","RnText","RnGlyph","timing","jsx","_jsx","jsxs","_jsxs","DURATIONS","long","short","PLATFORM_ANIMATION","OS","CLOSE_SIZE","SMOOTH_OUT","bezier","smoothOut","GROW","scaleIn","animations","opacity","transform","scale","initialValues","TRANSITIONS","fade","entering","fast","reduceMotion","Never","exiting","quick","micro","slideBottom","slideTop","transitionsFor","animation","position","millisecondsOf","undefined","Snackbar","actionLabel","actionOnNewLine","dismissible","message","offset","onAction","onDismiss","visible","reduced","dismiss","current","milliseconds","timer","setTimeout","clearTimeout","announceForAccessibility","edge","top","bottom","hasTrailing","Boolean","preset","align","bg","borderRadius","flexDirection","gap","left","s16","px","py","right","shadow","children","color","flex","variant","alignSelf","onPress","pressEffect","ripple","accessibilityLabel","name","size"],"sourceRoot":"../../../../src","sources":["organisms/snackbar/snackbar.tsx"],"mappings":";;AAAA,SAAQA,QAAQ,IAAIC,SAAS,EAAEC,MAAM,EAAEC,OAAO,EAAEC,gBAAgB,QAAO,mBAAmB;AAC1F,SAAQC,SAAS,EAAEC,MAAM,QAAO,OAAO;AACvC,SAAQC,iBAAiB,EAAEC,QAAQ,QAAO,cAAc;AACxD,SACEC,MAAM,EAENC,MAAM,EACNC,UAAU,EACVC,QAAQ,EACRC,OAAO,EACPC,WAAW,EACXC,SAAS,EACTC,YAAY,EACZC,UAAU,QACL,yBAAyB;AAEhC,SAAQC,IAAI,EAAEC,GAAG,QAAO,0BAAiB;AACzC,SAAQC,SAAS,QAAO,gCAAuB;AAC/C,SAAQC,MAAM,QAAO,8BAAqB;AAC1C,SAAQC,O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A,eAChErE,IAAA,CAACJ,MAAM;UAAC0E,KAAK,EAAC,gBAAgB;UAACE,OAAO,EAAC,gBAAgB;UAAAH,QAAA,EACpDjC;QAAW,CACN;MAAC,CACA,CAAC,GACV,IAAI,EACPE,WAAW,gBACVtC,IAAA,CAACL,SAAS;QAACkF,kBAAkB,EAAC,SAAS;QAACH,OAAO,EAAEhC,SAAU;QAACiC,WAAW,EAAC,SAAS;QAACC,MAAM,EAAE,KAAM;QAAAP,QAAA,eAC9FrE,IAAA,CAACH,OAAO;UAACyE,KAAK,EAAC,0BAA0B;UAACQ,IAAI,EAAC,OAAO;UAACC,IAAI,EAAEvE;QAAW,CAAE;MAAC,CAClE,CAAC,GACV,IAAI;IAAA,CACL,CAAC,GACJ,IAAI;EAAA,CACJ,CAAC;AAEX,CAAC","ignoreList":[]}
@@ -42,7 +42,7 @@ const ActionButton = ({
42
42
  }) => {
43
43
  const theme = useAppTheme();
44
44
  const fill = action.tint ?? (action.destructive ? 'fill.destructive.primary' : 'fill.accent.primary');
45
- const content = !action.tint && action.destructive ? 'content.on.destructive' : 'content.on.bg';
45
+ const content = !action.tint && action.destructive ? 'content.on.destructive' : 'content.on.accent';
46
46
  const onClick = useCallback(() => {
47
47
  onDone();
48
48
  action.onPress();
@@ -1 +1 @@
1
- {"version":3,"names":["FilledIconButton","size","SwipeActionsBox","spacing","useAppTheme","useCallback","useEffect","useId","useState","useSyncExternalStore","HStack","Icon","Text","VStack","useHostGuard","jsx","_jsx","jsxs","_jsxs","BUTTON","openRow","listeners","Set","setOpenRow","row","listener","subscribe","add","delete","getOpenRow","ActionButton","action","onDone","theme","fill","tint","destructive","content","onClick","onPress","align","children","colors","containerColor","color","contentColor","modifiers","accessibilityLabel","label","name","icon","variant","Actions","actions","map","close","SwipeActions","leading","trailing","isOpenRow","edge","setEdge","onOpenChange","next","actionsSpacing","s12","openEdge","length","Leading","Trailing","reverse"],"sourceRoot":"../../../../src","sources":["organisms/swipe-actions/swipe-actions.android.tsx"],"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AAe,CAACkE,OAAO;MAAA3B,QAAA,eACtBzB,IAAA,CAACoC,OAAO;QAACC,OAAO,EAAEI,OAAQ;QAACzB,MAAM,EAAEuB;MAAM,CAAE;IAAC,CACrB,CAAC,GACxB,IAAI,EACPG,QAAQ,CAACS,MAAM,GAAG,CAAC,gBAClBnD,IAAA,CAACd,eAAe,CAACmE,QAAQ;MAAA5B,QAAA,eAEvBzB,IAAA,CAACoC,OAAO;QAACC,OAAO,EAAE,CAAC,GAAGK,QAAQ,CAAC,CAACY,OAAO,CAAC,CAAE;QAACtC,MAAM,EAAEuB;MAAM,CAAE;IAAC,CACpC,CAAC,GACzB,IAAI,EACPd,QAAQ;EAAA,CACM,CAAC;AAEtB,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["FilledIconButton","size","SwipeActionsBox","spacing","useAppTheme","useCallback","useEffect","useId","useState","useSyncExternalStore","HStack","Icon","Text","VStack","useHostGuard","jsx","_jsx","jsxs","_jsxs","BUTTON","openRow","listeners","Set","setOpenRow","row","listener","subscribe","add","delete","getOpenRow","ActionButton","action","onDone","theme","fill","tint","destructive","content","onClick","onPress","align","children","colors","containerColor","color","contentColor","modifiers","accessibilityLabel","label","name","icon","variant","Actions","actions","map","close","SwipeActions","leading","trailing","isOpenRow","edge","setEdge","onOpenChange","next","actionsSpacing","s12","openEdge","length","Leading","Trailing","reverse"],"sourceRoot":"../../../../src","sources":["organisms/swipe-actions/swipe-actions.android.tsx"],"mappings":";;AAAA,SAAQA,gBAAgB,QAAO,0BAA0B;AACzD,SAAQC,IAAI,QAAO,oCAAoC;AACvD,SAAQC,eAAe,QAAiC,oCAAoC;AAC5F,SAAQC,OAAO,EAAEC,WAAW,QAAO,mBAAmB;AACtD,SAAQC,WAAW,EAAEC,SAAS,EAAEC,KAAK,EAAEC,QAAQ,EAAEC,oBAAoB,QAAO,OAAO;AAEnF,SAAQC,MAAM,QAAO,8BAAqB;AAC1C,SAAQC,IAAI,QAAO,2BAAkB;AACrC,SAAQC,IAA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AC,CAAE;QAACtC,MAAM,EAAEuB;MAAM,CAAE;IAAC,CACpC,CAAC,GACzB,IAAI,EACPd,QAAQ;EAAA,CACM,CAAC;AAEtB,CAAC","ignoreList":[]}
@@ -1,16 +1,17 @@
1
1
  "use strict";
2
2
 
3
3
  import { clickable, testID as testIdModifier } from '@expo/ui/jetpack-compose/modifiers';
4
- import { useSxModifiers } from '@hzblj/kara-sx';
4
+ import { splitAccessibility, useAccessibilityModifiers, useSxModifiers } from '@hzblj/kara-sx';
5
5
  import { useMemo } from 'react';
6
6
 
7
7
  /**
8
- * A Compose stack's modifiers in the order a pressable one needs: its frame, shape and background, then the press,
9
- * then its padding. Compose clips a `clickable` to what comes after it, so with the padding first the ripple would stop
10
- * at the padding and a row pressed by its edge would light up only in the middle.
8
+ * A Compose stack's modifiers in the order a pressable one needs: its frame, shape and background, then the press, its
9
+ * semantics, then its padding. Compose clips a `clickable` to what comes after it, so with the padding first the ripple
10
+ * would stop at the padding and a row pressed by its edge would light up only in the middle. The semantics come after
11
+ * the click, because a label that replaces the children's clears whatever semantics are inside it.
11
12
  */
12
- export const useStackModifiers = (sx, onPress, testID) => {
13
- const {
13
+ export const useStackModifiers = (props, onPress, testID) => {
14
+ const [accessibility, {
14
15
  p,
15
16
  pb,
16
17
  pl,
@@ -19,7 +20,7 @@ export const useStackModifiers = (sx, onPress, testID) => {
19
20
  px,
20
21
  py,
21
22
  ...frame
22
- } = sx;
23
+ }] = splitAccessibility(props);
23
24
  const frameModifiers = useSxModifiers(frame);
24
25
  const paddingModifiers = useSxModifiers({
25
26
  p,
@@ -30,6 +31,7 @@ export const useStackModifiers = (sx, onPress, testID) => {
30
31
  px,
31
32
  py
32
33
  });
33
- return useMemo(() => [...frameModifiers, ...(testID ? [testIdModifier(testID)] : []), ...(onPress ? [clickable(onPress)] : []), ...paddingModifiers], [frameModifiers, onPress, paddingModifiers, testID]);
34
+ const accessibilityModifiers = useAccessibilityModifiers(accessibility, onPress !== undefined);
35
+ return useMemo(() => [...frameModifiers, ...(testID ? [testIdModifier(testID)] : []), ...(onPress ? [clickable(onPress)] : []), ...accessibilityModifiers, ...paddingModifiers], [accessibilityModifiers, frameModifiers, onPress, paddingModifiers, testID]);
34
36
  };
35
37
  //# sourceMappingURL=use-stack-modifiers.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["clickable","testID","testIdModifier","useSxModifiers","useMemo","useStackModifiers","sx","onPress","p","pb","pl","pr","pt","px","py","frame","frameModifiers","paddingModifiers"],"sourceRoot":"../../src","sources":["use-stack-modifiers.ts"],"mappings":";;AAAA,SAAQA,SAAS,EAAuBC,MAAM,IAAIC,cAAc,QAAO,oCAAoC;AAC3G,SAA2BC,cAAc,QAAO,gBAAgB;AAChE,SAAQC,OAAO,QAAO,OAAO;;AAE7B;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGA,CAACC,EAAgB,EAAEC,OAAoB,EAAEN,MAAe,KAAuB;EAC9G,MAAM;IAACO,CAAC;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAE,GAAGC;EAAK,CAAC,GAAGT,EAAE;EAChD,MAAMU,cAAc,GAAGb,cAAc,CAACY,KAAK,CAAC;EAC5C,MAAME,gBAAgB,GAAGd,cAAc,CAAC;IAACK,CAAC;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC;EAAE,CAAC,CAAC;EAEpE,OAAOV,OAAO,CACZ,MAAM,CACJ,GAAGY,cAAc,EACjB,IAAIf,MAAM,GAAG,CAACC,cAAc,CAACD,MAAM,CAAC,CAAC,GAAG,EAAE,CAAC,EAC3C,IAAIM,OAAO,GAAG,CAACP,SAAS,CAACO,OAAO,CAAC,CAAC,GAAG,EAAE,CAAC,EACxC,GAAGU,gBAAgB,CACpB,EACD,CAACD,cAAc,EAAET,OAAO,EAAEU,gBAAgB,EAAEhB,MAAM,CACpD,CAAC;AACH,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["clickable","testID","testIdModifier","splitAccessibility","useAccessibilityModifiers","useSxModifiers","useMemo","useStackModifiers","props","onPress","accessibility","p","pb","pl","pr","pt","px","py","frame","frameModifiers","paddingModifiers","accessibilityModifiers","undefined"],"sourceRoot":"../../src","sources":["use-stack-modifiers.ts"],"mappings":";;AAAA,SAAQA,SAAS,EAAuBC,MAAM,IAAIC,cAAc,QAAO,oCAAoC;AAC3G,SAGEC,kBAAkB,EAClBC,yBAAyB,EACzBC,cAAc,QACT,gBAAgB;AACvB,SAAQC,OAAO,QAAO,OAAO;;AAE7B;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,iBAAiB,GAAGA,CAC/BC,KAAwC,EACxCC,OAAoB,EACpBR,MAAe,KACM;EACrB,MAAM,CAACS,aAAa,EAAE;IAACC,CAAC;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAE,GAAGC;EAAK,CAAC,CAAC,GAAGf,kBAAkB,CAACK,KAAK,CAAC;EACxF,MAAMW,cAAc,GAAGd,cAAc,CAACa,KAAK,CAAC;EAC5C,MAAME,gBAAgB,GAAGf,cAAc,CAAC;IAACM,CAAC;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC,EAAE;IAAEC;EAAE,CAAC,CAAC;EACpE,MAAMI,sBAAsB,GAAGjB,yBAAyB,CAACM,aAAa,EAAED,OAAO,KAAKa,SAAS,CAAC;EAE9F,OAAOhB,OAAO,CACZ,MAAM,CACJ,GAAGa,cAAc,EACjB,IAAIlB,MAAM,GAAG,CAACC,cAAc,CAACD,MAAM,CAAC,CAAC,GAAG,EAAE,CAAC,EAC3C,IAAIQ,OAAO,GAAG,CAACT,SAAS,CAACS,OAAO,CAAC,CAAC,GAAG,EAAE,CAAC,EACxC,GAAGY,sBAAsB,EACzB,GAAGD,gBAAgB,CACpB,EACD,CAACC,sBAAsB,EAAEF,cAAc,EAAEV,OAAO,EAAEW,gBAAgB,EAAEnB,MAAM,CAC5E,CAAC;AACH,CAAC","ignoreList":[]}
@@ -7,6 +7,8 @@ export type ActivityIndicatorSize = 'large' | 'small';
7
7
  * Android, so it renders anywhere. For how far along something is, use `Progress`.
8
8
  */
9
9
  export type ActivityIndicatorProps = {
10
+ /** What is loading, for VoiceOver and TalkBack: "Loading photos". Unset, the platform's own word ("In progress"). */
11
+ accessibilityLabel?: string;
10
12
  /** Its colour. `fill.accent.primary` by default. */
11
13
  color?: ColorToken;
12
14
  /** `small` sits in a row or a button, `large` holds a screen that is loading. `small` by default. */
@@ -3,6 +3,11 @@ import type { ImageSourcePropType } from 'react-native';
3
3
  export type AvatarSize = 'lg' | 'md' | 'sm';
4
4
  /** A round avatar: the image in `source`, or `initials` without one. The React Native tier: it needs no host. */
5
5
  export type AvatarProps = {
6
+ /**
7
+ * Who it is, for VoiceOver and TalkBack: "Jan Blazej". Unset, the avatar is decorative and hidden from them, as one
8
+ * beside the person's name should be.
9
+ */
10
+ accessibilityLabel?: string;
6
11
  /** Shown in place of the image when there is no `source`. */
7
12
  initials?: string;
8
13
  /** The diameter: `sm` is `s24`, `md` `s40`, `lg` `s64`. `md` by default. */
@@ -1,7 +1,7 @@
1
1
  import type { ColorToken, Theme } from '@hzblj/kara-theme';
2
2
  import type { ButtonVariant } from './button.types';
3
3
  export declare const buttonTokens: (variant: ButtonVariant, disabled: boolean, theme: Theme) => {
4
- readonly content: 'content.on.bg';
4
+ readonly content: 'content.on.accent';
5
5
  readonly fill: 'fill.accent.primary';
6
6
  readonly shadow: 'btn.accent';
7
7
  } | {
@@ -13,6 +13,8 @@ export type ButtonStyleName = 'automatic' | 'bordered' | 'borderedProminent' | '
13
13
  export type ButtonControlSize = 'extraLarge' | 'large' | 'mini' | 'regular' | 'small';
14
14
  /** A text button: SwiftUI `Button` on iOS, Material's filled button (outlined for `glass`) on Android. */
15
15
  export type ButtonProps = {
16
+ /** What pressing it does, when the label alone does not say. See `AccessibilityProps`. */
17
+ accessibilityHint?: string;
16
18
  /**
17
19
  * Replaces the style the variant picks: `borderedProminent` for `accent` and `destructive`, `bordered` for
18
20
  * `secondary`, `glass` for `glass`. iOS only. Android ignores it.
@@ -1,10 +1,10 @@
1
- import type { ResponsiveSx } from '@hzblj/kara-sx';
1
+ import type { AccessibilityProps, ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { ReactNode } from 'react';
3
3
  /**
4
4
  * A raised container: SwiftUI `VStack` / Compose `Column` on `surface.primary`, with a large radius, `s16` padding and
5
5
  * the `card` shadow. Any `sx` prop overrides its default.
6
6
  */
7
- export type CardProps = ResponsiveSx & {
7
+ export type CardProps = ResponsiveSx & AccessibilityProps & {
8
8
  /** Native views, stacked vertically from the leading edge. */
9
9
  children?: ReactNode;
10
10
  /** Test identifier, forwarded to the native view. */
@@ -5,7 +5,14 @@ import type { IconName } from '../icon';
5
5
  * `Button`) on iOS. It renders inline; pinning it to a corner is up to the screen.
6
6
  */
7
7
  export type FabProps = {
8
- /** The icon, one of the app's, drawn in `content.on.bg`. */
8
+ /**
9
+ * What VoiceOver and TalkBack say for the button, since an icon has no words of its own: "Share", "Add to
10
+ * favourites". Required for that reason.
11
+ */
12
+ accessibilityLabel: string;
13
+ /** What pressing it does, when the label alone does not say. See `AccessibilityProps`. */
14
+ accessibilityHint?: string;
15
+ /** The icon, one of the app's, drawn in `content.on.accent`. */
9
16
  name: IconName;
10
17
  /** Called when the button is pressed. */
11
18
  onPress?: () => void;
@@ -1,14 +1,17 @@
1
- import type { ResponsiveSx } from '@hzblj/kara-sx';
1
+ import type { AccessibilityProps, ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { SpaceSize } from '@hzblj/kara-theme';
3
3
  import type { ReactNode } from 'react';
4
4
  export type HStackAlign = 'center' | 'end' | 'start';
5
5
  /** A horizontal stack: SwiftUI `HStack` / Compose `Row`. */
6
- export type HStackProps = ResponsiveSx & {
6
+ export type HStackProps = ResponsiveSx & AccessibilityProps & {
7
7
  /** How the children line up vertically: `start` is the top, `end` the bottom. `start` by default. */
8
8
  align?: HStackAlign;
9
9
  /** Native views, laid out from the leading edge. */
10
10
  children?: ReactNode;
11
- /** Makes the stack pressable: a tap gesture on iOS, a `clickable` with Material's ripple on Android. */
11
+ /**
12
+ * Makes the stack pressable: a tap gesture on iOS, a `clickable` with Material's ripple on Android. Screen readers
13
+ * then read the stack as one button.
14
+ */
12
15
  onPress?: () => void;
13
16
  /** The gap between children. Unset, SwiftUI puts its default spacing between them and Compose none. */
14
17
  spacing?: SpaceSize;
@@ -6,6 +6,13 @@ import type { IconName } from '../icon';
6
6
  * itself the same way on both.
7
7
  */
8
8
  export type IconButtonProps = {
9
+ /**
10
+ * What VoiceOver and TalkBack say for the button, since an icon has no words of its own: "Share", "Add to
11
+ * favourites". Required for that reason.
12
+ */
13
+ accessibilityLabel: string;
14
+ /** What pressing it does, when the label alone does not say. See `AccessibilityProps`. */
15
+ accessibilityHint?: string;
9
16
  /** Dims the icon (iOS's own disabled look, `btn.content.disabled` on Android) and stops the button responding. */
10
17
  disabled?: boolean;
11
18
  /** The icon, one of the app's. */
@@ -1,8 +1,8 @@
1
1
  import { Image as ExpoImage, type ImageProps as ExpoImageProps } from 'expo-image';
2
2
  import type { Ref } from 'react';
3
3
  /**
4
- * `expo-image` with the `sx` props, the way `Box` is a `View` with them, and the design system's 100 ms linear fade
5
- * already applied, so a loaded image never pops in. An explicit `transition` wins, and so does an explicit `style`.
4
+ * `expo-image` with the `sx` props, the way `Box` is a `View` with them, and the design system's fade (`quick`,
5
+ * eased out) already applied, so a loaded image never pops in. An explicit `transition` wins, and so does an explicit `style`.
6
6
  */
7
7
  export declare const Image: import("react").MemoExoticComponent<{
8
8
  ({ style, ...props }: import("@hzblj/kara-sx").SxProps<ExpoImageProps & {
@@ -1,17 +1,17 @@
1
- import type { ResponsiveViewSx } from '@hzblj/kara-sx';
1
+ import type { AccessibilityProps, ResponsiveViewSx } from '@hzblj/kara-sx';
2
2
  import type { OpacitySize } from '@hzblj/kara-theme';
3
3
  import type { ReactNode } from 'react';
4
4
  import type { Haptic } from '../../haptics';
5
- /** How the content answers a press: it springs down, it dims, or it stays still. */
5
+ /** How the content answers a press: it eases down, it dims, or it stays still. */
6
6
  export type PressEffect = 'none' | 'opacity' | 'scale';
7
7
  /**
8
8
  * React Native's `Pressable`, styled through `sx` like a `Box`, taking touches 8 points past its edges. Each platform
9
- * presses its own way by default: iOS springs the content down to 96%, Android draws Material's ripple over it,
9
+ * presses its own way by default: iOS eases the content down to 96%, Android draws Material's ripple over it,
10
10
  * clipped to the pressable's shape. `pressEffect` picks the same answer on both, and Android keeps its ripple on top
11
- * unless `ripple` is off. Give it the `borderRadius` of what it wraps (`full` around a `GlassView`). The React Native
12
- * tier: it needs no host.
11
+ * unless `ripple` is off. Give it the `borderRadius` of what it wraps (`full` around a `GlassView`). Screen readers read
12
+ * it as a button unless `accessibilityRole` names another role. The React Native tier: it needs no host.
13
13
  */
14
- export type PressableProps = ResponsiveViewSx & {
14
+ export type PressableProps = ResponsiveViewSx & AccessibilityProps & {
15
15
  /** The pressable content. */
16
16
  children?: ReactNode;
17
17
  /** Ignores presses: no `onPress`, no haptic, no press effect or ripple. */
@@ -21,14 +21,14 @@ export type PressableProps = ResponsiveViewSx & {
21
21
  /** Called when the press is released, after the `haptic` plays. */
22
22
  onPress?: () => void;
23
23
  /**
24
- * How the content answers while it is held. `scale` springs it down to `pressedScale`, `opacity` dims it to
24
+ * How the content answers while it is held. `scale` eases it down to `pressedScale`, `opacity` dims it to
25
25
  * `pressedOpacity`, `none` leaves it still. `scale` on iOS and `none` on Android by default, where the ripple is the
26
- * press.
26
+ * press. With motion reduced, `scale` dims instead: the press still shows, and nothing moves.
27
27
  */
28
28
  pressEffect?: PressEffect;
29
29
  /** What `opacity` dims to, an opacity token. `o60` by default. */
30
30
  pressedOpacity?: OpacitySize;
31
- /** What `scale` springs down to. `0.96` by default. */
31
+ /** What `scale` eases down to. `0.96` by default: lower reads as a squash, not a press. */
32
32
  pressedScale?: number;
33
33
  /** Android's ripple: Material's pressed state layer over the content, clipped to the shape. On by default. iOS has none. */
34
34
  ripple?: boolean;
@@ -4,6 +4,8 @@ import type { ReactNode } from 'react';
4
4
  * value, which `ProgressView` cannot draw on iOS) / Compose's `LinearProgressIndicator` and `CircularProgressIndicator`.
5
5
  */
6
6
  export type ProgressProps = {
7
+ /** What is in progress, for VoiceOver and TalkBack: "Uploading". They read how far along it is themselves. */
8
+ accessibilityLabel?: string;
7
9
  /** A circular indicator instead of a bar. Off by default. */
8
10
  circular?: boolean;
9
11
  /** Between `0` and `1`. Leave it unset for an indeterminate indicator. */
@@ -2,8 +2,9 @@ import type { SxDimension } from '@hzblj/kara-sx';
2
2
  import type { RadiiSize } from '@hzblj/kara-theme';
3
3
  import type { ReactNode } from 'react';
4
4
  /**
5
- * A loading placeholder that pulses in `fill.quaternary`. It is a React Native view, so it needs no host. Sized with
6
- * the `sx` names: `w`, `h`, `borderRadius`.
5
+ * A loading placeholder that pulses in `fill.quaternary`, and holds still with motion reduced. Hidden from screen
6
+ * readers: what is loading is for the screen to say. It is a React Native view, so it needs no host. Sized with the
7
+ * `sx` names: `w`, `h`, `borderRadius`.
7
8
  */
8
9
  export type SkeletonProps = {
9
10
  /** The corner radius. `small` by default. */
@@ -1,10 +1,10 @@
1
- import type { ResponsiveSx } from '@hzblj/kara-sx';
1
+ import type { AccessibilityProps, ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { ReactNode } from 'react';
3
3
  /**
4
4
  * A container on `surface.primary`, padded `s16` and rounded `large` unless told otherwise: a SwiftUI `VStack` on
5
5
  * iOS, Material's `Surface` around a `Column` on Android.
6
6
  */
7
- export type SurfaceProps = ResponsiveSx & {
7
+ export type SurfaceProps = ResponsiveSx & AccessibilityProps & {
8
8
  /** Stacked vertically, from the leading edge. */
9
9
  children?: ReactNode;
10
10
  /** iOS wraps the content in a `GlassEffectContainer`; Android raises it to a tonal elevation of `3`. */
@@ -1,4 +1,4 @@
1
- import type { ResponsiveSx } from '@hzblj/kara-sx';
1
+ import type { AccessibilityProps, ResponsiveSx } from '@hzblj/kara-sx';
2
2
  import type { ColorToken, TextVariant } from '@hzblj/kara-theme';
3
3
  import type { ReactNode } from 'react';
4
4
  export type TextAlign = 'center' | 'left' | 'right';
@@ -9,7 +9,7 @@ export type TextTransform = 'lowercase' | 'uppercase';
9
9
  * the native `sx` surface too: padding, a frame (`wide` lines it up by `align`), a background, and the `ios` bucket's
10
10
  * `contentTransition`, `animation` and `monospacedDigit` for a number that changes in place.
11
11
  */
12
- export type TextProps = ResponsiveSx & {
12
+ export type TextProps = ResponsiveSx & AccessibilityProps & {
13
13
  /**
14
14
  * How its lines align. iOS reads `left` and `right` as leading and trailing, so they flip in a right-to-left
15
15
  * layout; Android keeps them as they are.