@hozo/primitives 0.2.0 → 0.4.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 (187) hide show
  1. package/CHANGELOG.md +71 -0
  2. package/README.md +18 -1
  3. package/dist/button-host-attributes.d.ts +20 -0
  4. package/dist/button-host-attributes.d.ts.map +1 -0
  5. package/dist/button-host-attributes.js +47 -0
  6. package/dist/button-host-attributes.js.map +1 -0
  7. package/dist/button-host-props.native.d.ts +8 -0
  8. package/dist/button-host-props.native.d.ts.map +1 -0
  9. package/dist/button-host-props.native.js +20 -0
  10. package/dist/button-host-props.native.js.map +1 -0
  11. package/dist/foundation.d.ts +27 -6
  12. package/dist/foundation.d.ts.map +1 -1
  13. package/dist/foundation.js +72 -19
  14. package/dist/foundation.js.map +1 -1
  15. package/dist/foundation.native.d.ts +27 -7
  16. package/dist/foundation.native.d.ts.map +1 -1
  17. package/dist/foundation.native.js +18 -3
  18. package/dist/foundation.native.js.map +1 -1
  19. package/dist/generated/button-dom-props.d.ts +11 -0
  20. package/dist/generated/button-dom-props.d.ts.map +1 -0
  21. package/dist/generated/button-dom-props.js +132 -0
  22. package/dist/generated/button-dom-props.js.map +1 -0
  23. package/dist/generated/button-props.d.ts +3 -0
  24. package/dist/generated/button-props.d.ts.map +1 -0
  25. package/dist/generated/button-props.js +5 -0
  26. package/dist/generated/button-props.js.map +1 -0
  27. package/dist/generated/button-props.native.d.ts +2 -0
  28. package/dist/generated/button-props.native.d.ts.map +1 -0
  29. package/dist/generated/button-props.native.js +2 -0
  30. package/dist/generated/button-props.native.js.map +1 -0
  31. package/dist/generated/inherited-label.d.ts +2 -0
  32. package/dist/generated/inherited-label.d.ts.map +1 -0
  33. package/dist/generated/inherited-label.js +3 -0
  34. package/dist/generated/inherited-label.js.map +1 -0
  35. package/dist/generated/inherited-pressable.d.ts +2 -0
  36. package/dist/generated/inherited-pressable.d.ts.map +1 -0
  37. package/dist/generated/inherited-pressable.js +3 -0
  38. package/dist/generated/inherited-pressable.js.map +1 -0
  39. package/dist/generated/inherited-relative-text.d.ts +2 -0
  40. package/dist/generated/inherited-relative-text.d.ts.map +1 -0
  41. package/dist/generated/inherited-relative-text.js +3 -0
  42. package/dist/generated/inherited-relative-text.js.map +1 -0
  43. package/dist/generated/inherited-text.d.ts +2 -0
  44. package/dist/generated/inherited-text.d.ts.map +1 -0
  45. package/dist/generated/inherited-text.js +3 -0
  46. package/dist/generated/inherited-text.js.map +1 -0
  47. package/dist/generated/inherited-view.d.ts +2 -0
  48. package/dist/generated/inherited-view.d.ts.map +1 -0
  49. package/dist/generated/inherited-view.js +3 -0
  50. package/dist/generated/inherited-view.js.map +1 -0
  51. package/dist/generated/native-disabled.d.ts +2 -0
  52. package/dist/generated/native-disabled.d.ts.map +1 -0
  53. package/dist/generated/native-disabled.js +2 -0
  54. package/dist/generated/native-disabled.js.map +1 -0
  55. package/dist/generated/text-input-dom-props.d.ts +7 -0
  56. package/dist/generated/text-input-dom-props.d.ts.map +1 -0
  57. package/dist/generated/text-input-dom-props.js +130 -0
  58. package/dist/generated/text-input-dom-props.js.map +1 -0
  59. package/dist/generated/text-input.native.d.ts +1 -1
  60. package/dist/generated/text-input.native.d.ts.map +1 -1
  61. package/dist/generated/text-input.native.js +1 -1
  62. package/dist/generated/text-input.native.js.map +1 -1
  63. package/dist/generated/view-dom-props.d.ts +8 -0
  64. package/dist/generated/view-dom-props.d.ts.map +1 -0
  65. package/dist/generated/view-dom-props.js +241 -0
  66. package/dist/generated/view-dom-props.js.map +1 -0
  67. package/dist/inherited-label.native.d.ts +8 -0
  68. package/dist/inherited-label.native.d.ts.map +1 -0
  69. package/dist/inherited-label.native.js +12 -0
  70. package/dist/inherited-label.native.js.map +1 -0
  71. package/dist/inherited-pressable.native.d.ts +11 -0
  72. package/dist/inherited-pressable.native.d.ts.map +1 -0
  73. package/dist/inherited-pressable.native.js +75 -0
  74. package/dist/inherited-pressable.native.js.map +1 -0
  75. package/dist/inherited-relative-text.native.d.ts +13 -0
  76. package/dist/inherited-relative-text.native.d.ts.map +1 -0
  77. package/dist/inherited-relative-text.native.js +16 -0
  78. package/dist/inherited-relative-text.native.js.map +1 -0
  79. package/dist/inherited-text-scope.d.ts +8 -0
  80. package/dist/inherited-text-scope.d.ts.map +1 -0
  81. package/dist/inherited-text-scope.js +10 -0
  82. package/dist/inherited-text-scope.js.map +1 -0
  83. package/dist/inherited-text-style.native.d.ts +5 -0
  84. package/dist/inherited-text-style.native.d.ts.map +1 -0
  85. package/dist/inherited-text-style.native.js +30 -0
  86. package/dist/inherited-text-style.native.js.map +1 -0
  87. package/dist/inherited-text.native.d.ts +5 -0
  88. package/dist/inherited-text.native.d.ts.map +1 -0
  89. package/dist/inherited-text.native.js +18 -0
  90. package/dist/inherited-text.native.js.map +1 -0
  91. package/dist/inherited-view.native.d.ts +9 -0
  92. package/dist/inherited-view.native.d.ts.map +1 -0
  93. package/dist/inherited-view.native.js +17 -0
  94. package/dist/inherited-view.native.js.map +1 -0
  95. package/dist/link.d.ts +4 -3
  96. package/dist/link.d.ts.map +1 -1
  97. package/dist/link.js +9 -1
  98. package/dist/link.js.map +1 -1
  99. package/dist/link.native.d.ts +16 -7
  100. package/dist/link.native.d.ts.map +1 -1
  101. package/dist/link.native.js +15 -5
  102. package/dist/link.native.js.map +1 -1
  103. package/dist/native-disabled.d.ts +13 -0
  104. package/dist/native-disabled.d.ts.map +1 -0
  105. package/dist/native-disabled.js +13 -0
  106. package/dist/native-disabled.js.map +1 -0
  107. package/dist/presence.native.d.ts.map +1 -1
  108. package/dist/presence.native.js +1 -1
  109. package/dist/presence.native.js.map +1 -1
  110. package/dist/pressable.d.ts +1 -1
  111. package/dist/pressable.d.ts.map +1 -1
  112. package/dist/pressable.js +15 -5
  113. package/dist/pressable.js.map +1 -1
  114. package/dist/pressable.native.d.ts +10 -1
  115. package/dist/pressable.native.d.ts.map +1 -1
  116. package/dist/pressable.native.js +206 -221
  117. package/dist/pressable.native.js.map +1 -1
  118. package/dist/runtime-container.native.d.ts +11 -9
  119. package/dist/runtime-container.native.d.ts.map +1 -1
  120. package/dist/runtime-container.native.js +8 -6
  121. package/dist/runtime-container.native.js.map +1 -1
  122. package/dist/text-color-transition.native.d.ts +12 -0
  123. package/dist/text-color-transition.native.d.ts.map +1 -0
  124. package/dist/text-color-transition.native.js +87 -0
  125. package/dist/text-color-transition.native.js.map +1 -0
  126. package/dist/text-input-props.native.d.ts +10 -0
  127. package/dist/text-input-props.native.d.ts.map +1 -0
  128. package/dist/text-input-props.native.js +15 -0
  129. package/dist/text-input-props.native.js.map +1 -0
  130. package/dist/text-input.native.d.ts +19 -0
  131. package/dist/text-input.native.d.ts.map +1 -0
  132. package/dist/text-input.native.js +32 -0
  133. package/dist/text-input.native.js.map +1 -0
  134. package/dist/view.d.ts +1 -285
  135. package/dist/view.d.ts.map +1 -1
  136. package/dist/view.js +5 -4
  137. package/dist/view.js.map +1 -1
  138. package/package.json +51 -7
  139. package/src/button-host-attributes.ts +56 -0
  140. package/src/button-host-props.native.ts +22 -0
  141. package/src/foundation.native.tsx +45 -6
  142. package/src/foundation.tsx +139 -28
  143. package/src/generated/button-dom-props.ts +127 -0
  144. package/src/generated/button-props.native.ts +1 -0
  145. package/src/generated/button-props.ts +4 -0
  146. package/src/generated/inherited-label.ts +2 -0
  147. package/src/generated/inherited-pressable.ts +2 -0
  148. package/src/generated/inherited-relative-text.ts +2 -0
  149. package/src/generated/inherited-text.ts +2 -0
  150. package/src/generated/inherited-view.ts +2 -0
  151. package/src/generated/native-disabled.ts +1 -0
  152. package/src/generated/text-input-dom-props.ts +128 -0
  153. package/src/generated/text-input.native.ts +1 -4
  154. package/src/generated/view-dom-props.ts +267 -0
  155. package/src/inherited-label.native.tsx +28 -0
  156. package/src/inherited-pressable.native.tsx +152 -0
  157. package/src/inherited-relative-text.native.tsx +22 -0
  158. package/src/inherited-text-scope.tsx +27 -0
  159. package/src/inherited-text-style.native.ts +35 -0
  160. package/src/inherited-text.native.tsx +32 -0
  161. package/src/inherited-view.native.tsx +37 -0
  162. package/src/link.native.tsx +43 -28
  163. package/src/link.ts +12 -0
  164. package/src/native-disabled.ts +23 -0
  165. package/src/presence.native.tsx +1 -1
  166. package/src/pressable.native.tsx +298 -262
  167. package/src/pressable.ts +34 -17
  168. package/src/runtime-container.native.tsx +30 -15
  169. package/src/text-color-transition.native.ts +96 -0
  170. package/src/text-input-props.native.ts +26 -0
  171. package/src/text-input.native.tsx +57 -0
  172. package/src/view.ts +34 -25
  173. package/dist/generated/animated.d.ts +0 -2
  174. package/dist/generated/animated.d.ts.map +0 -1
  175. package/dist/generated/animated.js +0 -3
  176. package/dist/generated/animated.js.map +0 -1
  177. package/dist/presence-context.d.ts +0 -15
  178. package/dist/presence-context.d.ts.map +0 -1
  179. package/dist/presence-context.js +0 -11
  180. package/dist/presence-context.js.map +0 -1
  181. package/dist/runtime-transition.native.d.ts +0 -30
  182. package/dist/runtime-transition.native.d.ts.map +0 -1
  183. package/dist/runtime-transition.native.js +0 -183
  184. package/dist/runtime-transition.native.js.map +0 -1
  185. package/src/generated/animated.ts +0 -6
  186. package/src/presence-context.ts +0 -27
  187. package/src/runtime-transition.native.tsx +0 -244
@@ -16,17 +16,19 @@ import { jsx as _jsx } from "react/jsx-runtime";
16
16
  // `HozoContainerQuery` renders no element of its own. It exists to put a
17
17
  // component boundary between the provider and the read, and adding a View
18
18
  // to do that would change the layout the query is measuring.
19
- import { createContext, useContext, useMemo, useState } from 'react';
19
+ import { createContext, useContext, useMemo, useState, } from 'react';
20
20
  import { View } from 'react-native';
21
21
  import { keepIfSettled } from './runtime-measured.js';
22
22
  const HozoContainerContext = createContext({});
23
23
  /**
24
- * A View that measures itself and hands its width to its subtree.
24
+ * Measures the existing host and hands its width to its subtree.
25
25
  *
26
- * The compiler renders an element here instead of a View when its classes
27
- * declared it a container.
26
+ * A provider adds no layout node. The host keeps its own style/children
27
+ * callbacks, refs and events rather than asking a replacement View to
28
+ * approximate them. An ordinary container still defaults to View.
28
29
  */
29
- export function HozoContainer({ hozoContainerName, onLayout, children, ...rest }) {
30
+ export function HozoContainer({ hozoContainerComponent, hozoContainerName, onLayout, children, ...rest }) {
31
+ const Component = hozoContainerComponent ?? View;
30
32
  const [width, setWidth] = useState(undefined);
31
33
  const outer = useContext(HozoContainerContext);
32
34
  const widths = useMemo(() => ({
@@ -45,7 +47,7 @@ export function HozoContainer({ hozoContainerName, onLayout, children, ...rest }
45
47
  setWidth((current) => keepIfSettled(current, measured));
46
48
  onLayout?.(event);
47
49
  };
48
- return (_jsx(View, { ...rest, onLayout: measure, children: _jsx(HozoContainerContext.Provider, { value: widths, children: children }) }));
50
+ return (_jsx(HozoContainerContext.Provider, { value: widths, children: _jsx(Component, { ...rest, onLayout: measure, children: children }) }));
49
51
  }
50
52
  /**
51
53
  * Hands the widths in scope to the element that queries them.
@@ -1 +1 @@
1
- {"version":3,"file":"runtime-container.native.js","sourceRoot":"","sources":["../src/runtime-container.native.tsx"],"names":[],"mappings":";AAAA,qDAAqD;AACrD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,0EAA0E;AAC1E,yDAAyD;AACzD,EAAE;AACF,qEAAqE;AACrE,sEAAsE;AACtE,oEAAoE;AACpE,uEAAuE;AACvE,yEAAyE;AACzE,sEAAsE;AACtE,EAAE;AACF,yEAAyE;AACzE,0EAA0E;AAC1E,6DAA6D;AAE7D,OAAO,EAAE,aAAa,EAAkB,UAAU,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACpF,OAAO,EAA0B,IAAI,EAAkB,MAAM,cAAc,CAAA;AAE3E,OAAO,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAA;AAkBrD,MAAM,oBAAoB,GAAG,aAAa,CAAsB,EAAE,CAAC,CAAA;AAQnE;;;;;GAKG;AACH,MAAM,UAAU,aAAa,CAAC,EAC5B,iBAAiB,EACjB,QAAQ,EACR,QAAQ,EACR,GAAG,IAAI,EACY;IACnB,MAAM,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,mEAAmE;QACnE,+BAA+B;QAC/B,QAAQ,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,aAAa,CAAC,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAA;QACvD,QAAQ,EAAE,CAAC,KAAK,CAAC,CAAA;IACnB,CAAC,CAAA;IAED,OAAO,CACL,KAAC,oBAAoB,CAAC,QAAQ,IAAC,KAAK,EAAE,MAAM,YAC1C,KAAC,SAAS,OAAK,IAAI,EAAE,QAAQ,EAAE,OAAO,YACnC,QAAQ,GACC,GACkB,CACjC,CAAA;AACH,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,kBAAkB,CAAC,EACjC,QAAQ,GAGT;IACC,OAAO,QAAQ,CAAC,UAAU,CAAC,oBAAoB,CAAC,CAAC,CAAA;AACnD,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { Animated } from 'react-native';
2
+ import type { HozoTransition } from './pressable.native.tsx';
3
+ type Spec = Pick<HozoTransition, 'duration' | 'delay' | 'easing'>;
4
+ /**
5
+ * One colour timeline, reusable by a leaf or an inherited label owner.
6
+ * Progress is not reset when retargeting: the new interpolation starts at the
7
+ * observed position. Resetting a live value to zero would briefly send the
8
+ * previous interpolation back to its old starting colour.
9
+ */
10
+ export declare function useHozoTextColorTransition(target: string | undefined, revision: string, spec: Spec): Animated.Interpolation<string> | undefined;
11
+ export {};
12
+ //# sourceMappingURL=text-color-transition.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-color-transition.native.d.ts","sourceRoot":"","sources":["../src/text-color-transition.native.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,QAAQ,EAAU,MAAM,cAAc,CAAA;AAC/C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAE5D,KAAK,IAAI,GAAG,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,OAAO,GAAG,QAAQ,CAAC,CAAA;AAejE;;;;;GAKG;AACH,wBAAgB,0BAA0B,CACxC,MAAM,EAAE,MAAM,GAAG,SAAS,EAC1B,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,IAAI,8CAkEX"}
@@ -0,0 +1,87 @@
1
+ import { blendColor } from '@hozo/engine';
2
+ import { useLayoutEffect, useMemo, useRef, useState } from 'react';
3
+ import { Animated, Easing } from 'react-native';
4
+ function easingFor(name) {
5
+ switch (name) {
6
+ case 'linear':
7
+ return Easing.linear;
8
+ case 'ease-in':
9
+ return Easing.in(Easing.ease);
10
+ case 'ease-out':
11
+ return Easing.out(Easing.ease);
12
+ case 'ease-in-out':
13
+ return Easing.inOut(Easing.ease);
14
+ }
15
+ }
16
+ /**
17
+ * One colour timeline, reusable by a leaf or an inherited label owner.
18
+ * Progress is not reset when retargeting: the new interpolation starts at the
19
+ * observed position. Resetting a live value to zero would briefly send the
20
+ * previous interpolation back to its old starting colour.
21
+ */
22
+ export function useHozoTextColorTransition(target, revision, spec) {
23
+ const [progress] = useState(() => new Animated.Value(0));
24
+ const position = useRef(0);
25
+ const animation = useRef(null);
26
+ const [range, setRange] = useState(() => ({
27
+ from: target ?? '',
28
+ to: target ?? '',
29
+ target,
30
+ revision,
31
+ start: 0,
32
+ animate: false,
33
+ }));
34
+ useLayoutEffect(() => {
35
+ const listener = progress.addListener(({ value }) => {
36
+ position.current = value;
37
+ });
38
+ return () => {
39
+ progress.removeListener(listener);
40
+ animation.current?.stop();
41
+ };
42
+ }, [progress]);
43
+ useLayoutEffect(() => {
44
+ if (range.target === target && range.revision === revision)
45
+ return;
46
+ animation.current?.stop();
47
+ const start = position.current;
48
+ const fraction = Math.max(0, Math.min(1, start - range.start));
49
+ const current = range.from ? blendColor(range.from, range.to, fraction) : (target ?? '');
50
+ // Only committed inputs may replace the range. An abandoned Suspense
51
+ // render must not consume the target or mutate the visible timeline.
52
+ setRange({
53
+ from: target ? current : '',
54
+ to: target ?? '',
55
+ target,
56
+ revision,
57
+ start,
58
+ animate: Boolean(target),
59
+ });
60
+ }, [range, target, revision]);
61
+ const { duration, delay = 0, easing } = spec;
62
+ useLayoutEffect(() => {
63
+ if (!range.animate)
64
+ return;
65
+ const next = Animated.timing(progress, {
66
+ toValue: range.start + 1,
67
+ duration,
68
+ delay,
69
+ easing: easingFor(easing),
70
+ useNativeDriver: false,
71
+ });
72
+ animation.current = next;
73
+ next.start();
74
+ return () => {
75
+ next.stop();
76
+ if (animation.current === next)
77
+ animation.current = null;
78
+ };
79
+ }, [progress, range, duration, delay, easing]);
80
+ return useMemo(() => range.from
81
+ ? progress.interpolate({
82
+ inputRange: [range.start, range.start + 1],
83
+ outputRange: [range.from, range.to],
84
+ })
85
+ : undefined, [progress, range]);
86
+ }
87
+ //# sourceMappingURL=text-color-transition.native.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-color-transition.native.js","sourceRoot":"","sources":["../src/text-color-transition.native.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AACzC,OAAO,EAAE,eAAe,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,cAAc,CAAA;AAK/C,SAAS,SAAS,CAAC,IAAoB;IACrC,QAAQ,IAAI,EAAE,CAAC;QACb,KAAK,QAAQ;YACX,OAAO,MAAM,CAAC,MAAM,CAAA;QACtB,KAAK,SAAS;YACZ,OAAO,MAAM,CAAC,EAAE,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;QAC/B,KAAK,UAAU;YACb,OAAO,MAAM,CAAC,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;QAChC,KAAK,aAAa;YAChB,OAAO,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,IAAI,CAAC,CAAA;IACpC,CAAC;AACH,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,0BAA0B,CACxC,MAA0B,EAC1B,QAAgB,EAChB,IAAU;IAEV,MAAM,CAAC,QAAQ,CAAC,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,CACH,KAAK,CAAC,IAAI;QACR,CAAC,CAAC,QAAQ,CAAC,WAAW,CAAC;YACnB,UAAU,EAAE,CAAC,KAAK,CAAC,KAAK,EAAE,KAAK,CAAC,KAAK,GAAG,CAAC,CAAC;YAC1C,WAAW,EAAE,CAAC,KAAK,CAAC,IAAI,EAAE,KAAK,CAAC,EAAE,CAAC;SACpC,CAAC;QACJ,CAAC,CAAC,SAAS,EACf,CAAC,QAAQ,EAAE,KAAK,CAAC,CAClB,CAAA;AACH,CAAC"}
@@ -0,0 +1,10 @@
1
+ import type { TextInputProps as RNTextInputProps } from 'react-native';
2
+ /** Canonical disabled is distinct from an editable/read-only field. */
3
+ export interface NativeTextInputProps extends RNTextInputProps {
4
+ disabled?: boolean;
5
+ className?: string;
6
+ 'aria-invalid'?: boolean | 'false' | 'true' | 'grammar' | 'spelling';
7
+ }
8
+ /** Shared by value-level and generated hosts; RN has no disabled input prop. */
9
+ export declare function nativeTextInputProps({ disabled, 'aria-invalid': _invalid, ...props }: NativeTextInputProps): RNTextInputProps;
10
+ //# sourceMappingURL=text-input-props.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-input-props.native.d.ts","sourceRoot":"","sources":["../src/text-input-props.native.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,IAAI,gBAAgB,EAAE,MAAM,cAAc,CAAA;AAEtE,uEAAuE;AACvE,MAAM,WAAW,oBAAqB,SAAQ,gBAAgB;IAC5D,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,cAAc,CAAC,EAAE,OAAO,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,UAAU,CAAA;CACrE;AAED,gFAAgF;AAChF,wBAAgB,oBAAoB,CAAC,EACnC,QAAQ,EACR,cAAc,EAAE,QAAQ,EACxB,GAAG,KAAK,EACT,EAAE,oBAAoB,GAAG,gBAAgB,CAWzC"}
@@ -0,0 +1,15 @@
1
+ /** Shared by value-level and generated hosts; RN has no disabled input prop. */
2
+ export function nativeTextInputProps({ disabled, 'aria-invalid': _invalid, ...props }) {
3
+ if (!disabled)
4
+ return props;
5
+ // Both RN spellings must prevent editing even if the caller authored
6
+ // readOnly=false. Do not turn ordinary read-only fields into disabled ones.
7
+ return {
8
+ ...props,
9
+ editable: false,
10
+ readOnly: true,
11
+ accessibilityState: { ...props.accessibilityState, disabled: true },
12
+ 'aria-disabled': true,
13
+ };
14
+ }
15
+ //# sourceMappingURL=text-input-props.native.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-input-props.native.js","sourceRoot":"","sources":["../src/text-input-props.native.ts"],"names":[],"mappings":"AASA,gFAAgF;AAChF,MAAM,UAAU,oBAAoB,CAAC,EACnC,QAAQ,EACR,cAAc,EAAE,QAAQ,EACxB,GAAG,KAAK,EACa;IACrB,IAAI,CAAC,QAAQ;QAAE,OAAO,KAAK,CAAA;IAC3B,qEAAqE;IACrE,4EAA4E;IAC5E,OAAO;QACL,GAAG,KAAK;QACR,QAAQ,EAAE,KAAK;QACf,QAAQ,EAAE,IAAI;QACd,kBAAkB,EAAE,EAAE,GAAG,KAAK,CAAC,kBAAkB,EAAE,QAAQ,EAAE,IAAI,EAAE;QACnE,eAAe,EAAE,IAAI;KACtB,CAAA;AACH,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { type HozoPressableInteractionState } from '@hozo/behaviors/pressable-interaction';
2
+ import type { ComponentRef, Ref } from 'react';
3
+ import { TextInput, type TextInputProps } from 'react-native';
4
+ import { type NativeTextInputProps } from './text-input-props.native.ts';
5
+ export interface HozoTextInputProps extends NativeTextInputProps {
6
+ ref?: Ref<ComponentRef<typeof TextInput>>;
7
+ /** Compiler-only style evaluation on this input, not an ancestor Pressable. */
8
+ hozoStyle?: (state: HozoPressableInteractionState) => TextInputProps['style'];
9
+ }
10
+ /**
11
+ * Generated-code host when static or dynamic classes need input focus. Ordinary
12
+ * compiled inputs stay RN TextInput. No extra box, context, animation or
13
+ * subscriptions; the same native field keeps its ref, events and semantics.
14
+ *
15
+ * A keyboard-input field indicates focus even after a pointer/touch focuses
16
+ * it (Selectors 4 §9.4). A button's pointer modality is not its policy.
17
+ */
18
+ export declare function HozoTextInput(props: HozoTextInputProps): import("react").JSX.Element;
19
+ //# sourceMappingURL=text-input.native.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-input.native.d.ts","sourceRoot":"","sources":["../src/text-input.native.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,6BAA6B,EAEnC,MAAM,uCAAuC,CAAA;AAC9C,OAAO,KAAK,EAAE,YAAY,EAAE,GAAG,EAAE,MAAM,OAAO,CAAA;AAC9C,OAAO,EAAE,SAAS,EAAE,KAAK,cAAc,EAAE,MAAM,cAAc,CAAA;AAC7D,OAAO,EAAE,KAAK,oBAAoB,EAAwB,MAAM,8BAA8B,CAAA;AAE9F,MAAM,WAAW,kBAAmB,SAAQ,oBAAoB;IAC9D,GAAG,CAAC,EAAE,GAAG,CAAC,YAAY,CAAC,OAAO,SAAS,CAAC,CAAC,CAAA;IACzC,+EAA+E;IAC/E,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,6BAA6B,KAAK,cAAc,CAAC,OAAO,CAAC,CAAA;CAC9E;AAED;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,kBAAkB,+BAQtD"}
@@ -0,0 +1,32 @@
1
+ import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { usePressableInteraction, } from '@hozo/behaviors/pressable-interaction';
3
+ import { TextInput } from 'react-native';
4
+ import { nativeTextInputProps } from './text-input-props.native.js';
5
+ /**
6
+ * Generated-code host when static or dynamic classes need input focus. Ordinary
7
+ * compiled inputs stay RN TextInput. No extra box, context, animation or
8
+ * subscriptions; the same native field keeps its ref, events and semantics.
9
+ *
10
+ * A keyboard-input field indicates focus even after a pointer/touch focuses
11
+ * it (Selectors 4 §9.4). A button's pointer modality is not its policy.
12
+ */
13
+ export function HozoTextInput(props) {
14
+ // A prop-only adapter needs no state subscription. The focus child exists
15
+ // only for a compiler callback and still renders exactly one RN field.
16
+ if (!props.hozoStyle) {
17
+ const { hozoStyle: _hozoStyle, ref, ...hostProps } = props;
18
+ return _jsx(TextInput, { ...nativeTextInputProps(hostProps), ref: ref });
19
+ }
20
+ return _jsx(FocusedTextInput, { ...props });
21
+ }
22
+ function FocusedTextInput({ ref, hozoStyle, style, onFocus, onBlur, ...props }) {
23
+ const { state, handlers } = usePressableInteraction({ focusVisible: 'keyboard-input' });
24
+ return (_jsx(TextInput, { ...nativeTextInputProps(props), ref: ref, style: [hozoStyle?.(state), style], onFocus: (event) => {
25
+ handlers.focus();
26
+ onFocus?.(event);
27
+ }, onBlur: (event) => {
28
+ handlers.blur();
29
+ onBlur?.(event);
30
+ } }));
31
+ }
32
+ //# sourceMappingURL=text-input.native.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text-input.native.js","sourceRoot":"","sources":["../src/text-input.native.tsx"],"names":[],"mappings":";AAAA,OAAO,EAEL,uBAAuB,GACxB,MAAM,uCAAuC,CAAA;AAE9C,OAAO,EAAE,SAAS,EAAuB,MAAM,cAAc,CAAA;AAC7D,OAAO,EAA6B,oBAAoB,EAAE,MAAM,8BAA8B,CAAA;AAQ9F;;;;;;;GAOG;AACH,MAAM,UAAU,aAAa,CAAC,KAAyB;IACrD,0EAA0E;IAC1E,uEAAuE;IACvE,IAAI,CAAC,KAAK,CAAC,SAAS,EAAE,CAAC;QACrB,MAAM,EAAE,SAAS,EAAE,UAAU,EAAE,GAAG,EAAE,GAAG,SAAS,EAAE,GAAG,KAAK,CAAA;QAC1D,OAAO,KAAC,SAAS,OAAK,oBAAoB,CAAC,SAAS,CAAC,EAAE,GAAG,EAAE,GAAG,GAAI,CAAA;IACrE,CAAC;IACD,OAAO,KAAC,gBAAgB,OAAK,KAAK,GAAI,CAAA;AACxC,CAAC;AAED,SAAS,gBAAgB,CAAC,EACxB,GAAG,EACH,SAAS,EACT,KAAK,EACL,OAAO,EACP,MAAM,EACN,GAAG,KAAK,EACW;IACnB,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,GAAG,uBAAuB,CAAC,EAAE,YAAY,EAAE,gBAAgB,EAAE,CAAC,CAAA;IACvF,OAAO,CACL,KAAC,SAAS,OACJ,oBAAoB,CAAC,KAAK,CAAC,EAC/B,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,CAAC,SAAS,EAAE,CAAC,KAAK,CAAC,EAAE,KAAK,CAAC,EAClC,OAAO,EAAE,CAAC,KAAK,EAAE,EAAE;YACjB,QAAQ,CAAC,KAAK,EAAE,CAAA;YAChB,OAAO,EAAE,CAAC,KAAK,CAAC,CAAA;QAClB,CAAC,EACD,MAAM,EAAE,CAAC,KAAK,EAAE,EAAE;YAChB,QAAQ,CAAC,IAAI,EAAE,CAAA;YACf,MAAM,EAAE,CAAC,KAAK,CAAC,CAAA;QACjB,CAAC,GACD,CACH,CAAA;AACH,CAAC"}
package/dist/view.d.ts CHANGED
@@ -47,289 +47,5 @@ export interface HozoViewProps extends Omit<HTMLAttributes<HTMLDivElement>, 'chi
47
47
  ref?: Ref<HTMLDivElement>;
48
48
  }
49
49
  /** A measured/responder-aware View for the Web paths that cannot be a plain div. */
50
- export declare function HozoView({ ref: forwardedRef, children, style, testID, nativeID, pointerEvents, accessibilityLabel, accessibilityHint, accessibilityRole, accessibilityState, accessibilityValue, accessibilityLiveRegion, onLayout, collapsable: _collapsable, role, 'aria-disabled': ariaDisabled, 'data-hozo-disabled': dataHozoDisabled, onStartShouldSetResponder, onStartShouldSetResponderCapture, onMoveShouldSetResponder, onMoveShouldSetResponderCapture, onResponderGrant, onResponderStart, onResponderMove, onResponderEnd, onResponderRelease, onResponderReject, onResponderTerminate, onResponderTerminationRequest, ...props }: HozoViewProps): import("react").DetailedReactHTMLElement<{
51
- dangerouslySetInnerHTML?: {
52
- __html: string | TrustedHTML;
53
- } | undefined;
54
- onCopy?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
55
- onCopyCapture?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
56
- onCut?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
57
- onCutCapture?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
58
- onPaste?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
59
- onPasteCapture?: import("react").ClipboardEventHandler<HTMLDivElement> | undefined;
60
- onCompositionEnd?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
61
- onCompositionEndCapture?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
62
- onCompositionStart?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
63
- onCompositionStartCapture?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
64
- onCompositionUpdate?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
65
- onCompositionUpdateCapture?: import("react").CompositionEventHandler<HTMLDivElement> | undefined;
66
- onFocus?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
67
- onFocusCapture?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
68
- onBlur?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
69
- onBlurCapture?: import("react").FocusEventHandler<HTMLDivElement> | undefined;
70
- onChange?: import("react").ChangeEventHandler<HTMLDivElement, Element> | undefined;
71
- onChangeCapture?: import("react").ChangeEventHandler<HTMLDivElement, Element> | undefined;
72
- onBeforeInput?: import("react").InputEventHandler<HTMLDivElement> | undefined;
73
- onBeforeInputCapture?: import("react").InputEventHandler<HTMLDivElement> | undefined;
74
- onInput?: import("react").InputEventHandler<HTMLDivElement> | undefined;
75
- onInputCapture?: import("react").InputEventHandler<HTMLDivElement> | undefined;
76
- onReset?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
77
- onResetCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
78
- onSubmit?: import("react").SubmitEventHandler<HTMLDivElement> | undefined;
79
- onSubmitCapture?: import("react").SubmitEventHandler<HTMLDivElement> | undefined;
80
- onInvalid?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
81
- onInvalidCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
82
- onLoad?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
83
- onLoadCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
84
- onError?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
85
- onErrorCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
86
- onKeyDown?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
87
- onKeyDownCapture?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
88
- onKeyPress?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
89
- onKeyPressCapture?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
90
- onKeyUp?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
91
- onKeyUpCapture?: import("react").KeyboardEventHandler<HTMLDivElement> | undefined;
92
- onAbort?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
93
- onAbortCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
94
- onCanPlay?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
95
- onCanPlayCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
96
- onCanPlayThrough?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
97
- onCanPlayThroughCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
98
- onDurationChange?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
99
- onDurationChangeCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
100
- onEmptied?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
101
- onEmptiedCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
102
- onEncrypted?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
103
- onEncryptedCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
104
- onEnded?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
105
- onEndedCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
106
- onLoadedData?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
107
- onLoadedDataCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
108
- onLoadedMetadata?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
109
- onLoadedMetadataCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
110
- onLoadStart?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
111
- onLoadStartCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
112
- onPause?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
113
- onPauseCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
114
- onPlay?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
115
- onPlayCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
116
- onPlaying?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
117
- onPlayingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
118
- onProgress?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
119
- onProgressCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
120
- onRateChange?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
121
- onRateChangeCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
122
- onSeeked?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
123
- onSeekedCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
124
- onSeeking?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
125
- onSeekingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
126
- onStalled?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
127
- onStalledCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
128
- onSuspend?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
129
- onSuspendCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
130
- onTimeUpdate?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
131
- onTimeUpdateCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
132
- onVolumeChange?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
133
- onVolumeChangeCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
134
- onWaiting?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
135
- onWaitingCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
136
- onAuxClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
137
- onAuxClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
138
- onClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
139
- onClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
140
- onContextMenu?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
141
- onContextMenuCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
142
- onDoubleClick?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
143
- onDoubleClickCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
144
- onDrag?: import("react").DragEventHandler<HTMLDivElement> | undefined;
145
- onDragCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
146
- onDragEnd?: import("react").DragEventHandler<HTMLDivElement> | undefined;
147
- onDragEndCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
148
- onDragEnter?: import("react").DragEventHandler<HTMLDivElement> | undefined;
149
- onDragEnterCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
150
- onDragExit?: import("react").DragEventHandler<HTMLDivElement> | undefined;
151
- onDragExitCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
152
- onDragLeave?: import("react").DragEventHandler<HTMLDivElement> | undefined;
153
- onDragLeaveCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
154
- onDragOver?: import("react").DragEventHandler<HTMLDivElement> | undefined;
155
- onDragOverCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
156
- onDragStart?: import("react").DragEventHandler<HTMLDivElement> | undefined;
157
- onDragStartCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
158
- onDrop?: import("react").DragEventHandler<HTMLDivElement> | undefined;
159
- onDropCapture?: import("react").DragEventHandler<HTMLDivElement> | undefined;
160
- onMouseDown?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
161
- onMouseDownCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
162
- onMouseEnter?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
163
- onMouseLeave?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
164
- onMouseMove?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
165
- onMouseMoveCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
166
- onMouseOut?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
167
- onMouseOutCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
168
- onMouseOver?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
169
- onMouseOverCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
170
- onMouseUp?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
171
- onMouseUpCapture?: import("react").MouseEventHandler<HTMLDivElement> | undefined;
172
- onSelect?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
173
- onSelectCapture?: import("react").ReactEventHandler<HTMLDivElement> | undefined;
174
- onTouchCancel?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
175
- onTouchCancelCapture?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
176
- onTouchEnd?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
177
- onTouchEndCapture?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
178
- onTouchMove?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
179
- onTouchMoveCapture?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
180
- onTouchStart?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
181
- onTouchStartCapture?: import("react").TouchEventHandler<HTMLDivElement> | undefined;
182
- onPointerDown?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
183
- onPointerDownCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
184
- onPointerMove?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
185
- onPointerMoveCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
186
- onPointerUp?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
187
- onPointerUpCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
188
- onPointerCancel?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
189
- onPointerCancelCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
190
- onPointerEnter?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
191
- onPointerLeave?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
192
- onPointerOver?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
193
- onPointerOverCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
194
- onPointerOut?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
195
- onPointerOutCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
196
- onGotPointerCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
197
- onGotPointerCaptureCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
198
- onLostPointerCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
199
- onLostPointerCaptureCapture?: import("react").PointerEventHandler<HTMLDivElement> | undefined;
200
- onScroll?: import("react").UIEventHandler<HTMLDivElement> | undefined;
201
- onScrollCapture?: import("react").UIEventHandler<HTMLDivElement> | undefined;
202
- onScrollEnd?: import("react").UIEventHandler<HTMLDivElement> | undefined;
203
- onScrollEndCapture?: import("react").UIEventHandler<HTMLDivElement> | undefined;
204
- onWheel?: import("react").WheelEventHandler<HTMLDivElement> | undefined;
205
- onWheelCapture?: import("react").WheelEventHandler<HTMLDivElement> | undefined;
206
- onAnimationStart?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
207
- onAnimationStartCapture?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
208
- onAnimationEnd?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
209
- onAnimationEndCapture?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
210
- onAnimationIteration?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
211
- onAnimationIterationCapture?: import("react").AnimationEventHandler<HTMLDivElement> | undefined;
212
- onToggle?: import("react").ToggleEventHandler<HTMLDivElement> | undefined;
213
- onBeforeToggle?: import("react").ToggleEventHandler<HTMLDivElement> | undefined;
214
- onTransitionCancel?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
215
- onTransitionCancelCapture?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
216
- onTransitionEnd?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
217
- onTransitionEndCapture?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
218
- onTransitionRun?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
219
- onTransitionRunCapture?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
220
- onTransitionStart?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
221
- onTransitionStartCapture?: import("react").TransitionEventHandler<HTMLDivElement> | undefined;
222
- "aria-activedescendant"?: string | undefined;
223
- "aria-atomic"?: ("false" | "true" | boolean) | undefined;
224
- "aria-autocomplete"?: "none" | "inline" | "list" | "both" | undefined;
225
- "aria-braillelabel"?: string | undefined;
226
- "aria-brailleroledescription"?: string | undefined;
227
- "aria-colcount"?: number | undefined;
228
- "aria-colindex"?: number | undefined;
229
- "aria-colindextext"?: string | undefined;
230
- "aria-colspan"?: number | undefined;
231
- "aria-controls"?: string | undefined;
232
- "aria-current"?: boolean | "false" | "true" | "page" | "step" | "location" | "date" | "time" | undefined;
233
- "aria-describedby"?: string | undefined;
234
- "aria-details"?: string | undefined;
235
- "aria-dropeffect"?: "none" | "copy" | "execute" | "link" | "move" | "popup" | undefined;
236
- "aria-errormessage"?: string | undefined;
237
- "aria-flowto"?: string | undefined;
238
- "aria-grabbed"?: ("false" | "true" | boolean) | undefined;
239
- "aria-haspopup"?: boolean | "false" | "true" | "menu" | "listbox" | "tree" | "grid" | "dialog" | undefined;
240
- "aria-hidden"?: ("false" | "true" | boolean) | undefined;
241
- "aria-invalid"?: boolean | "false" | "true" | "grammar" | "spelling" | undefined;
242
- "aria-keyshortcuts"?: string | undefined;
243
- "aria-labelledby"?: string | undefined;
244
- "aria-level"?: number | undefined;
245
- "aria-modal"?: ("false" | "true" | boolean) | undefined;
246
- "aria-multiline"?: ("false" | "true" | boolean) | undefined;
247
- "aria-multiselectable"?: ("false" | "true" | boolean) | undefined;
248
- "aria-orientation"?: "horizontal" | "vertical" | undefined;
249
- "aria-owns"?: string | undefined;
250
- "aria-placeholder"?: string | undefined;
251
- "aria-posinset"?: number | undefined;
252
- "aria-pressed"?: boolean | "false" | "mixed" | "true" | undefined;
253
- "aria-readonly"?: ("false" | "true" | boolean) | undefined;
254
- "aria-relevant"?: "additions" | "additions removals" | "additions text" | "all" | "removals" | "removals additions" | "removals text" | "text" | "text additions" | "text removals" | undefined;
255
- "aria-required"?: ("false" | "true" | boolean) | undefined;
256
- "aria-roledescription"?: string | undefined;
257
- "aria-rowcount"?: number | undefined;
258
- "aria-rowindex"?: number | undefined;
259
- "aria-rowindextext"?: string | undefined;
260
- "aria-rowspan"?: number | undefined;
261
- "aria-setsize"?: number | undefined;
262
- "aria-sort"?: "none" | "ascending" | "descending" | "other" | undefined;
263
- defaultChecked?: boolean | undefined;
264
- defaultValue?: string | number | readonly string[] | undefined;
265
- suppressContentEditableWarning?: boolean | undefined;
266
- suppressHydrationWarning?: boolean | undefined;
267
- accessKey?: string | undefined;
268
- autoCapitalize?: "off" | "none" | "on" | "sentences" | "words" | "characters" | undefined | (string & {});
269
- autoFocus?: boolean | undefined;
270
- className?: string | undefined;
271
- contentEditable?: ("false" | "true" | boolean) | "inherit" | "plaintext-only" | undefined;
272
- contextMenu?: string | undefined;
273
- dir?: string | undefined;
274
- draggable?: ("false" | "true" | boolean) | undefined;
275
- enterKeyHint?: "enter" | "done" | "go" | "next" | "previous" | "search" | "send" | undefined;
276
- hidden?: boolean | undefined;
277
- lang?: string | undefined;
278
- nonce?: string | undefined;
279
- slot?: string | undefined;
280
- spellCheck?: ("false" | "true" | boolean) | undefined;
281
- tabIndex?: number | undefined;
282
- title?: string | undefined;
283
- translate?: "yes" | "no" | undefined;
284
- radioGroup?: string | undefined;
285
- about?: string | undefined;
286
- content?: string | undefined;
287
- datatype?: string | undefined;
288
- inlist?: any;
289
- prefix?: string | undefined;
290
- property?: string | undefined;
291
- rel?: string | undefined;
292
- resource?: string | undefined;
293
- rev?: string | undefined;
294
- typeof?: string | undefined;
295
- vocab?: string | undefined;
296
- autoCorrect?: string | undefined;
297
- autoSave?: string | undefined;
298
- color?: string | undefined;
299
- itemProp?: string | undefined;
300
- itemScope?: boolean | undefined;
301
- itemType?: string | undefined;
302
- itemID?: string | undefined;
303
- itemRef?: string | undefined;
304
- results?: number | undefined;
305
- security?: string | undefined;
306
- unselectable?: "on" | "off" | undefined;
307
- popover?: "" | "auto" | "manual" | "hint" | undefined;
308
- popoverTargetAction?: "toggle" | "show" | "hide" | undefined;
309
- popoverTarget?: string | undefined;
310
- inert?: boolean | undefined;
311
- inputMode?: "none" | "text" | "tel" | "url" | "email" | "numeric" | "decimal" | "search" | undefined;
312
- is?: string | undefined;
313
- exportparts?: string | undefined;
314
- part?: string | undefined;
315
- ref: (element: HTMLDivElement | null) => void;
316
- role: string | undefined;
317
- style: import("react").CSSProperties | undefined;
318
- 'data-testid': string | undefined;
319
- id: string | undefined;
320
- 'data-hozo-pointer-events': "auto" | "box-none" | "box-only" | "none" | undefined;
321
- 'data-hozo-disabled': string | undefined;
322
- 'aria-disabled': ("false" | "true" | boolean) | undefined;
323
- 'aria-selected': boolean | undefined;
324
- 'aria-checked': "mixed" | boolean | undefined;
325
- 'aria-busy': boolean | undefined;
326
- 'aria-expanded': boolean | undefined;
327
- 'aria-valuemin': number | undefined;
328
- 'aria-valuemax': number | undefined;
329
- 'aria-valuenow': number | undefined;
330
- 'aria-valuetext': string | undefined;
331
- 'aria-live': "assertive" | "polite" | undefined;
332
- 'aria-label': string | undefined;
333
- 'aria-description': string | undefined;
334
- }, HTMLDivElement>;
50
+ export declare function HozoView({ ref: forwardedRef, children, style, testID, nativeID, pointerEvents, accessibilityLabel, accessibilityHint, accessibilityRole, accessibilityState, accessibilityValue, accessibilityLiveRegion, onLayout, collapsable: _collapsable, role, 'aria-disabled': ariaDisabled, 'data-hozo-disabled': dataHozoDisabled, onStartShouldSetResponder, onStartShouldSetResponderCapture, onMoveShouldSetResponder, onMoveShouldSetResponderCapture, onResponderGrant, onResponderStart, onResponderMove, onResponderEnd, onResponderRelease, onResponderReject, onResponderTerminate, onResponderTerminationRequest, ...props }: HozoViewProps): import("react").FunctionComponentElement<import("react").FragmentProps>;
335
51
  //# sourceMappingURL=view.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"view.d.ts","sourceRoot":"","sources":["../src/view.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EAEjB,KAAK,cAAc,EAEpB,MAAM,cAAc,CAAA;AACrB,OAAO,EAEL,KAAK,cAAc,EACnB,KAAK,SAAS,EACd,KAAK,GAAG,EAIT,MAAM,OAAO,CAAA;AAEd,MAAM,WAAW,eAAe;IAC9B,WAAW,EAAE;QAAE,MAAM,EAAE;YAAE,CAAC,EAAE,MAAM,CAAC;YAAC,CAAC,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,CAAC;YAAC,MAAM,EAAE,MAAM,CAAA;SAAE,CAAA;KAAE,CAAA;CACjF;AAED,MAAM,WAAW,aACf,SAAQ,IAAI,CAAC,cAAc,CAAC,cAAc,CAAC,EAAE,UAAU,GAAG,OAAO,CAAC,EAChE,cAAc;IAChB,QAAQ,CAAC,EAAE,SAAS,CAAA;IACpB,KAAK,CAAC,EAAE,YAAY,CAAA;I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IAAI,EACJ,eAAe,EAAE,YAAY,EAC7B,oBAAoB,EAAE,gBAAgB,EACtC,yBAAyB,EACzB,gCAAgC,EAChC,wBAAwB,EACxB,+BAA+B,EAC/B,gBAAgB,EAChB,gBAAgB,EAChB,eAAe,EACf,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,oBAAoB,EACpB,6BAA6B,EAC7B,GAAG,KAAK,EACT,EAAE,aAAa,2EAqFf"}
package/dist/view.js CHANGED
@@ -1,5 +1,5 @@
1
- import { hozoDomStyle, useResponderDomProps, } from '@hozo/engine';
2
- import { createElement, useCallback, useEffect, useRef, } from 'react';
1
+ import { hozoDomStyle, hozoViewBase, hozoViewClassName, useResponderDomProps, } from '@hozo/engine';
2
+ import { createElement, Fragment, useCallback, useEffect, useRef, } from 'react';
3
3
  function assignRef(ref, value) {
4
4
  if (typeof ref === 'function')
5
5
  ref(value);
@@ -57,8 +57,9 @@ export function HozoView({ ref: forwardedRef, children, style, testID, nativeID,
57
57
  }, []);
58
58
  const state = accessibilityState;
59
59
  const value = accessibilityValue;
60
- return createElement('div', {
60
+ return createElement(Fragment, null, hozoViewBase(), createElement('div', {
61
61
  ...props,
62
+ className: hozoViewClassName(props.className),
62
63
  ...responder,
63
64
  ref: setRef,
64
65
  role: accessibilityRole ?? role,
@@ -79,6 +80,6 @@ export function HozoView({ ref: forwardedRef, children, style, testID, nativeID,
79
80
  'aria-live': accessibilityLiveRegion === 'none' ? undefined : accessibilityLiveRegion,
80
81
  'aria-label': accessibilityLabel,
81
82
  'aria-description': accessibilityHint,
82
- }, children);
83
+ }, children));
83
84
  }
84
85
  //# sourceMappingURL=view.js.map
package/dist/view.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"view.js","sourceRoot":"","sources":["../src/view.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,YAAY,EAEZ,oBAAoB,GACrB,MAAM,cAAc,CAAA;AACrB,OAAO,EACL,aAAa,EAIb,WAAW,EACX,SAAS,EACT,MAA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