react-native-a11y-order 0.3.0 → 0.3.1

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 (46) hide show
  1. package/README.md +53 -71
  2. package/lib/commonjs/components/A11yGroup/A11yGroup.android.js +3 -4
  3. package/lib/commonjs/components/A11yGroup/A11yGroup.android.js.map +1 -1
  4. package/lib/commonjs/components/A11yIndex/A11yIndex.js +2 -2
  5. package/lib/commonjs/components/A11yIndex/A11yIndex.js.map +1 -1
  6. package/lib/commonjs/components/A11yIndex/A11yIndex.web.js +2 -2
  7. package/lib/commonjs/components/A11yIndex/A11yIndex.web.js.map +1 -1
  8. package/lib/commonjs/index.js +0 -7
  9. package/lib/commonjs/index.js.map +1 -1
  10. package/lib/commonjs/index.web.js +1 -43
  11. package/lib/commonjs/index.web.js.map +1 -1
  12. package/lib/module/components/A11yGroup/A11yGroup.android.js +2 -3
  13. package/lib/module/components/A11yGroup/A11yGroup.android.js.map +1 -1
  14. package/lib/module/components/A11yIndex/A11yIndex.js +2 -2
  15. package/lib/module/components/A11yIndex/A11yIndex.js.map +1 -1
  16. package/lib/module/components/A11yIndex/A11yIndex.web.js +2 -2
  17. package/lib/module/components/A11yIndex/A11yIndex.web.js.map +1 -1
  18. package/lib/module/index.js +0 -1
  19. package/lib/module/index.js.map +1 -1
  20. package/lib/module/index.web.js +0 -40
  21. package/lib/module/index.web.js.map +1 -1
  22. package/lib/typescript/components/A11yGroup/A11yGroup.android.d.ts.map +1 -1
  23. package/lib/typescript/index.d.ts +0 -2
  24. package/lib/typescript/index.d.ts.map +1 -1
  25. package/lib/typescript/index.web.d.ts +1 -39
  26. package/lib/typescript/index.web.d.ts.map +1 -1
  27. package/package.json +1 -1
  28. package/src/components/A11yGroup/A11yGroup.android.tsx +2 -3
  29. package/src/components/A11yIndex/A11yIndex.tsx +2 -2
  30. package/src/components/A11yIndex/A11yIndex.web.tsx +2 -2
  31. package/src/index.ts +0 -2
  32. package/src/index.web.ts +0 -43
  33. package/lib/commonjs/components/A11yOrder/A11yOrder.js +0 -38
  34. package/lib/commonjs/components/A11yOrder/A11yOrder.js.map +0 -1
  35. package/lib/commonjs/types/A11yOrder.types.js +0 -6
  36. package/lib/commonjs/types/A11yOrder.types.js.map +0 -1
  37. package/lib/module/components/A11yOrder/A11yOrder.js +0 -30
  38. package/lib/module/components/A11yOrder/A11yOrder.js.map +0 -1
  39. package/lib/module/types/A11yOrder.types.js +0 -2
  40. package/lib/module/types/A11yOrder.types.js.map +0 -1
  41. package/lib/typescript/components/A11yOrder/A11yOrder.d.ts +0 -8
  42. package/lib/typescript/components/A11yOrder/A11yOrder.d.ts.map +0 -1
  43. package/lib/typescript/types/A11yOrder.types.d.ts +0 -10
  44. package/lib/typescript/types/A11yOrder.types.d.ts.map +0 -1
  45. package/src/components/A11yOrder/A11yOrder.tsx +0 -38
  46. package/src/types/A11yOrder.types.ts +0 -9
package/README.md CHANGED
@@ -38,7 +38,7 @@ post_install do |installer|
38
38
  end
39
39
  ```
40
40
 
41
- You can also use version `react-native-a11y-order@0.2.3`. Version `0.3.0` is released solely to support React Native versions `0.79.x to 0.80.x`.
41
+ You can also use version `react-native-a11y-order@0.2.5`. Version `0.3.0` is released solely to support React Native versions `0.79.x to 0.80.x`.
42
42
 
43
43
 
44
44
  ## Usage
@@ -107,81 +107,57 @@ export default function App() {
107
107
  }
108
108
  ```
109
109
 
110
- > [!NOTE]
111
- > Because of its native nature, it is important to wrap all components inside `A11y.Order` with `A11y.Index`. Components not wrapped in `A11y.Index` may be skipped from the reading order on iOS, or read at the end on Android. If you need to manage many elements, try to group them with a view and then control them via the ordering system. You can find an example below.
112
-
113
-
114
- Don't:
115
-
116
- ```js
117
- export default function App() {
118
- return (
119
- <Viw style={styles.container}>
120
- <A11y.Order>
121
- <A11y.Index index={1}>
122
- <Text style={styles.font}>
123
- First
124
- </Text>
125
- </A11y.Index>
126
- <Text style={styles.font}>
127
- Third
128
- </Text> // <===== Do not leave components unwrapped
129
- <A11y.Index index={2}>
130
- <Text style={styles.font}>
131
- Second
132
- </Text>
133
- </A11y.Index>
134
- <Text style={styles.font}>Fourth</Text> // <===== This is also incorrect
135
- <Text style={styles.font}>Fifth</Text>
136
- </A11y.Order>
137
- <Text style={styles.font}>Sixth</Text> // <===== This is correct because it is outside of `A11y.Order`
138
- </View>
139
- );
140
- }
110
+ **Important:** Order between `elements` and order between `groups`
111
+ Android and iOS have different native implementations, which can result in varying behavior across platforms. This package was originally developed to define a logical order among individual accessible elements. However, there are situations where it's necessary to set an order for groups of elements. While this is relatively simple to achieve on iOS, it can be more complicated on Android.
112
+
113
+ To resolve this on Android, you can define a View with the accessible property and use the accessibleLabel attribute to describe the group.
114
+
115
+ For example:
116
+ ```tsx
117
+ <View style={{flex: 1, position: 'relative'}}>
118
+ <A11y.Order style={{flex: 1}}>
119
+ <A11y.Index index={1}>
120
+ <View
121
+ accessible={Platform.OS = 'android'} // It helps to create a group to maintain the correct order for Android.
122
+ accessibilityLabel="Header Group"
123
+ >
124
+ ...
125
+ </View>
126
+ </A11y.Index>
127
+ <A11y.Index
128
+ index={2} // For a single element, we don't need anything extra.
129
+ style={{ position: "absolute", right: 20, bottom: 50, zIndex: 1}}
130
+ >
131
+ <Button title="Chat" />
132
+ </A11y.Index>
133
+ <A11y.Index
134
+ index={3} // We don't need a group for ScrollView; it creates its own scope.
135
+ >
136
+ <ScrollView>
137
+ <View
138
+ accessible
139
+ accessibilityLabel="Mindaro"
140
+ style={{width: '100%', height: 200, backgroundColor: '#CEEC97'}}
141
+ />
142
+ <View
143
+ accessible
144
+ accessibilityLabel="Peach"
145
+ style={{width: '100%', height: 200, backgroundColor: '#F4B393'}}
146
+ />
147
+ </ScrollView>
148
+ </A11y.Index>
149
+ </A11y.Order>
150
+ </View>
141
151
  ```
142
152
 
143
- Do
153
+ Additionally, it would be better to wrap every component inside `A11y.Order` with `A11y.Index`; the order of unwrapped components is not predictable.
144
154
 
145
- ```js
146
- export default function App() {
147
- return (
148
- <Viw style={styles.container}>
149
- <A11y.Order>
150
- <A11y.Index index={1}>
151
- <Text style={styles.font}>
152
- First
153
- </Text>
154
- </A11y.Index>
155
- <A11y.Index index={3}>
156
- <Text style={styles.font}>
157
- Third
158
- </Text>
159
- </A11y.Index>
160
- <A11y.Index index={4}> // <===== attention here, we group four and five to manage correct order flow
161
- <View>
162
- <Text style={styles.font}>Four</Text>
163
- </View>
164
- <View>
165
- <Text style={styles.font}>Five</Text>
166
- </View>
167
- </A11y.Index>
168
- <A11y.Index index={2}>
169
- <Text style={styles.font}>
170
- Second
171
- </Text>
172
- </A11y.Index>
173
- </A11y.Order>
174
- <Text style={styles.font}>Six</Text>
175
- </View>
176
- );
177
- }
178
- ```
179
155
 
180
156
  A11y.Index Props:
181
157
 
182
158
  | Props | Description |
183
159
  | -------------- | ------------------------------------------------ |
184
- | ViewProps | Default View props includin style, testID, etc |
160
+ | ViewProps | Default View props including style, testID, etc |
185
161
  | index | `number`, position in order |
186
162
  | ref: focus | focus command for setting accessibility focus |
187
163
 
@@ -220,7 +196,7 @@ export default function App() {
220
196
  <Text>Title: 1</Text>
221
197
  </View>
222
198
  <View>
223
- <Text>Desctiption: 1</Text>
199
+ <Text>Description: 1</Text>
224
200
  </View>
225
201
  </A11y.Group>
226
202
  <A11y.Group style={styles.slide}>
@@ -228,7 +204,7 @@ export default function App() {
228
204
  <Text>Title: 2</Text>
229
205
  </View>
230
206
  <View>
231
- <Text>Desctiption: 2</Text>
207
+ <Text>Description: 2</Text>
232
208
  </View>
233
209
  </A11y.Group>
234
210
  </ScrollView>
@@ -239,7 +215,7 @@ export default function App() {
239
215
 
240
216
  | Props | Description |
241
217
  | -------------- | ------------------------------------------------ |
242
- | ViewProps | Default View props includin style, testID, etc |
218
+ | ViewProps | Default View props including style, testID, etc |
243
219
 
244
220
 
245
221
  ## Migration
@@ -289,6 +265,12 @@ The new approach is better: we no longer need to manage refs, worry about attach
289
265
 
290
266
  That's all. The index changes, removals, etc., should work out of the box.
291
267
 
268
+ ## Roadmap
269
+ * Add order links for better focus control
270
+ * Add preferred focus logic for focus "return" functionality
271
+ * Refactor and optimize performance
272
+ * Add documentation and descriptive examples
273
+
292
274
  ## Contributing
293
275
 
294
276
  See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow.
@@ -4,14 +4,13 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.A11yGroup = void 0;
7
- var _react = _interopRequireWildcard(require("react"));
7
+ var _react = _interopRequireDefault(require("react"));
8
8
  var _reactNative = require("react-native");
9
- function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
10
10
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
11
11
  const A11yGroup = props => {
12
- const id = (0, _react.useId)();
13
12
  return /*#__PURE__*/_react.default.createElement(_reactNative.View, _extends({
14
- nativeID: id
13
+ collapsable: false
15
14
  }, props));
16
15
  };
17
16
  exports.A11yGroup = A11yGroup;
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","A11yGroup","props","id","useId","createElement","View","nativeID","exports"],"sourceRoot":"../../../../src","sources":["components/A11yGroup/A11yGroup.android.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAAoC,SAAAD,wBAAAG,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAL,uBAAA,YAAAA,CAAAG,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,CAAA,KAAAR,CAAA,EAAAC,CAAA;AAAA,SAAAkB,SAAA,WAAAA,QAAA,GAAAH,MAAA,CAAAI,MAAA,GAAAJ,MAAA,CAAAI,MAAA,CAAAC,IAAA,eAAAjB,CAAA,aAAAJ,CAAA,MAAAA,CAAA,GAAAsB,SAAA,CAAAC,MAAA,EAAAvB,CAAA,UAAAC,CAAA,GAAAqB,SAAA,CAAAtB,CAAA,YAAAG,CAAA,IAAAF,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAd,CAAA,EAAAE,CAAA,MAAAC,CAAA,CAAAD,CAAA,IAAAF,CAAA,CAAAE,CAAA,aAAAC,CAAA,KAAAe,QAAA,CAAAK,KAAA,OAAAF,SAAA;AAI7B,MAAMG,SAAS,GAAIC,KAAqB,IAAK;EAClD,MAAMC,EAAE,GAAG,IAAAC,YAAK,EAAC,CAAC;EAClB,oBAAOhC,MAAA,CAAAc,OAAA,CAAAmB,aAAA,CAAC9B,YAAA,CAAA+B,IAAI,EAAAX,QAAA;IAACY,QAAQ,EAAEJ;EAAG,GAAKD,KAAK,CAAG,CAAC;AAC1C,CAAC;AAACM,OAAA,CAAAP,SAAA,GAAAA,SAAA","ignoreList":[]}
1
+ {"version":3,"names":["_react","_interopRequireDefault","require","_reactNative","e","__esModule","default","_extends","Object","assign","bind","n","arguments","length","t","r","hasOwnProperty","call","apply","A11yGroup","props","createElement","View","collapsable","exports"],"sourceRoot":"../../../../src","sources":["components/A11yGroup/A11yGroup.android.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAAoC,SAAAD,uBAAAG,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAAA,SAAAG,SAAA,WAAAA,QAAA,GAAAC,MAAA,CAAAC,MAAA,GAAAD,MAAA,CAAAC,MAAA,CAAAC,IAAA,eAAAC,CAAA,aAAAP,CAAA,MAAAA,CAAA,GAAAQ,SAAA,CAAAC,MAAA,EAAAT,CAAA,UAAAU,CAAA,GAAAF,SAAA,CAAAR,CAAA,YAAAW,CAAA,IAAAD,CAAA,OAAAE,cAAA,CAAAC,IAAA,CAAAH,CAAA,EAAAC,CAAA,MAAAJ,CAAA,CAAAI,CAAA,IAAAD,CAAA,CAAAC,CAAA,aAAAJ,CAAA,KAAAJ,QAAA,CAAAW,KAAA,OAAAN,SAAA;AAI7B,MAAMO,SAAS,GAAIC,KAAqB,IAAK;EAClD,oBAAOpB,MAAA,CAAAM,OAAA,CAAAe,aAAA,CAAClB,YAAA,CAAAmB,IAAI,EAAAf,QAAA;IAACgB,WAAW,EAAE;EAAM,GAAKH,KAAK,CAAG,CAAC;AAChD,CAAC;AAACI,OAAA,CAAAL,SAAA,GAAAA,SAAA","ignoreList":[]}
@@ -17,7 +17,7 @@ const A11yIndex = exports.A11yIndex = /*#__PURE__*/_react.default.memo(/*#__PURE
17
17
  }, ref) => {
18
18
  const orderKey = _react.default.useContext(_A11ySequenceOrderContext.A11ySequenceOrderContext);
19
19
  if (!orderKey) {
20
- throw new Error('A11ySequence.Index should be used inside of A11ySequence.Container');
20
+ throw new Error('<A11y.Index> element should be used inside of <A11y.Order> container');
21
21
  }
22
22
  const indexRef = (0, _react.useRef)(null);
23
23
  (0, _react.useImperativeHandle)(ref, () => ({
@@ -33,7 +33,7 @@ const A11yIndex = exports.A11yIndex = /*#__PURE__*/_react.default.memo(/*#__PURE
33
33
  orderIndex: index,
34
34
  orderKey: orderKey
35
35
  }, props), isSingleChild && children, !isSingleChild && /*#__PURE__*/_react.default.createElement(_reactNative.View, {
36
- nativeID: orderKey
36
+ collapsable: false
37
37
  }, children));
38
38
  }));
39
39
  //# sourceMappingURL=A11yIndex.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_A11ySequenceOrderContext","_A11yIndexNativeComponent","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","A11yIndex","exports","React","memo","forwardRef","children","index","props","ref","orderKey","useContext","A11ySequenceOrderContext","Error","indexRef","useRef","useImperativeHandle","focus","current","Commands","isSingleChild","Children","count","createElement","orderIndex","View","nativeID"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,yBAAA,GAAAF,OAAA;AACA,IAAAG,yBAAA,GAAAJ,uBAAA,CAAAC,OAAA;AAEoD,SAAAD,wBAAAK,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAP,uBAAA,YAAAA,CAAAK,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE,CAAA,EAAAP,CAAA,EAAAM,CAAA,IAAAC,CAAA,CAAAP,CAAA,IAAAD,CAAA,CAAAC,CAAA,WAAAO,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GAAG,EAAEK,QAAS;IACdU,UAAU,EAAEjB,KAAM;IAClBG,QAAQ,EAAEA;EAAS,GACfF,KAAK,GAERY,aAAa,IAAId,QAAQ,EACzB,CAACc,aAAa,iBAAIlD,MAAA,CAAAgB,OAAA,CAAAqC,aAAA,CAAClD,YAAA,CAAAoD,IAAI;IAACC,QAAQ,EAAEhB;EAAS,GAAEJ,QAAe,CAChD,CAAC;AAEpB,CACF,CACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_A11ySequenceOrderContext","_A11yIndexNativeComponent","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","A11yIndex","exports","React","memo","forwardRef","children","index","props","ref","orderKey","useContext","A11ySequenceOrderContext","Error","indexRef","useRef","useImperativeHandle","focus","current","Commands","isSingleChild","Children","count","createElement","orderIndex","View","collapsable"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,yBAAA,GAAAF,OAAA;AACA,IAAAG,yBAAA,GAAAJ,uBAAA,CAAAC,OAAA;AAEoD,SAAAD,wBAAAK,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAP,uBAAA,YAAAA,CAAAK,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,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AAQ,EAAE;IACb,MAAM,IAAIG,KAAK,CACb,sEACF,CAAC;EACH;EAEA,MAAMC,QAAQ,GAAG,IAAAC,aAAM,EAAwC,IAAI,CAAC;EAEpE,IAAAC,0BAAmB,EAACP,GAAG,EAAE,OAAO;IAC9BQ,KAAK,EAAEA,CAAA,KAAM;MACX,IAAIH,QAAQ,CAACI,OAAO,EAAE;QACpBC,kCAAQ,CAACF,KAAK,CAACH,QAAQ,CAACI,OAAO,CAAC;MAClC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,MAAME,aAAa,GAAGjB,cAAK,CAACkB,QAAQ,CAACC,KAAK,CAAChB,QAAQ,CAAC,KAAK,CAAC;EAE1D,oBACEpC,MAAA,CAAAgB,OAAA,CAAAqC,aAAA,CAAChD,yBAAA,CAAAW,OAAa,EAAAS,QAAA;IACZc,GAAG,EAAEK,QAAS;IACdU,UAAU,EAAEjB,KAAM;IAClBG,QAAQ,EAAEA;EAAS,GACfF,KAAK,GAERY,aAAa,IAAId,QAAQ,EACzB,CAACc,aAAa,iBAAIlD,MAAA,CAAAgB,OAAA,CAAAqC,aAAA,CAAClD,YAAA,CAAAoD,IAAI;IAACC,WAAW,EAAE;EAAM,GAAEpB,QAAe,CAChD,CAAC;AAEpB,CACF,CACF,CAAC","ignoreList":[]}
@@ -8,13 +8,13 @@ var _react = _interopRequireWildcard(require("react"));
8
8
  var _reactNative = require("react-native");
9
9
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
10
10
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
11
- const WebUiMeneger = _reactNative.UIManager;
11
+ const WebUiManager = _reactNative.UIManager;
12
12
  const A11yIndex = exports.A11yIndex = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
13
13
  const viewRef = (0, _react.useRef)(null);
14
14
  (0, _react.useImperativeHandle)(ref, () => ({
15
15
  focus: () => {
16
16
  if (viewRef.current) {
17
- WebUiMeneger.focus(viewRef.current);
17
+ WebUiManager.focus(viewRef.current);
18
18
  }
19
19
  }
20
20
  }));
@@ -1 +1 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","WebUiMeneger","UIManager","A11yIndex","exports","forwardRef","props","ref","viewRef","useRef","useImperativeHandle","focus","current","createElement","View"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.web.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAGA,IAAAC,YAAA,GAAAD,OAAA;AAAyC,SAAAD,wBAAAG,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAL,uBAAA,YAAAA,CAAAG,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CA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AA,KAAM;MACX,IAAIH,OAAO,CAACI,OAAO,EAAE;QACnBX,YAAY,CAACU,KAAK,CAACH,OAAO,CAACI,OAAO,CAAC;MACrC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,oBAAOxC,MAAA,CAAAc,OAAA,CAAA2B,aAAA,CAACtC,YAAA,CAAAuC,IAAI,EAAAnB,QAAA,KAAKW,KAAK;IAAEC,GAAG,EAAEC;EAAQ,EAAE,CAAC;AAC1C,CACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","WebUiManager","UIManager","A11yIndex","exports","forwardRef","props","ref","viewRef","useRef","useImperativeHandle","focus","current","createElement","View"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.web.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AAGA,IAAAC,YAAA,GAAAD,OAAA;AAAyC,SAAAD,wBAAAG,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAL,uBAAA,YAAAA,CAAAG,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gB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A,CAAAc,OAAA,CAAA2B,aAAA,CAACtC,YAAA,CAAAuC,IAAI,EAAAnB,QAAA,KAAKW,KAAK;IAAEC,GAAG,EAAEC;EAAQ,EAAE,CAAC;AAC1C,CACF,CAAC","ignoreList":[]}
@@ -4,16 +4,9 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.A11y = void 0;
7
- Object.defineProperty(exports, "A11yOrder", {
8
- enumerable: true,
9
- get: function () {
10
- return _A11yOrder.A11yOrder;
11
- }
12
- });
13
7
  var _A11yIndex = require("./components/A11yIndex/A11yIndex");
14
8
  var _A11ySequence = require("./components/A11ySequence/A11ySequence");
15
9
  var _A11yGroup = require("./components/A11yGroup/A11yGroup");
16
- var _A11yOrder = require("./components/A11yOrder/A11yOrder");
17
10
  const A11y = exports.A11y = {
18
11
  Order: _A11ySequence.A11yIndexSequence,
19
12
  Index: _A11yIndex.A11yIndex,
@@ -1 +1 @@
1
- {"version":3,"names":["_A11yIndex","require","_A11ySequence","_A11yGroup","_A11yOrder","A11y","exports","Order","A11yIndexSequence","Index","A11yIndex","Group","A11yGroup"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;;;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AACA,IAAAC,aAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AAEA,IAAAG,UAAA,GAAAH,OAAA;AAIO,MAAMI,IAAI,GAAAC,OAAA,CAAAD,IAAA,GAAG;EAClBE,KAAK,EAAEC,+BAAiB;EACxBC,KAAK,EAAEC,oBAAS;EAChBC,KAAK,EAAEC;AACT,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_A11yIndex","require","_A11ySequence","_A11yGroup","A11y","exports","Order","A11yIndexSequence","Index","A11yIndex","Group","A11yGroup"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;;;;;AAAA,IAAAA,UAAA,GAAAC,OAAA;AACA,IAAAC,aAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AAIO,MAAMG,IAAI,GAAAC,OAAA,CAAAD,IAAA,GAAG;EAClBE,KAAK,EAAEC,+BAAiB;EACxBC,KAAK,EAAEC,oBAAS;EAChBC,KAAK,EAAEC;AACT,CAAC","ignoreList":[]}
@@ -3,51 +3,9 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.useFocusOrder = exports.useDynamicFocusOrder = exports.useA11yOrderManager = exports.A11yOrder = exports.A11y = void 0;
7
- var _react = require("react");
6
+ exports.A11y = void 0;
8
7
  var _reactNative = require("react-native");
9
8
  var _A11yIndex = require("./components/A11yIndex/A11yIndex.web");
10
- /**
11
- * @deprecated The method should not be used
12
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
13
- */
14
- const useFocusOrder = () => ({
15
- a11yOrder: {
16
- ref: /*#__PURE__*/(0, _react.createRef)(),
17
- onLayout: () => {}
18
- },
19
- refs: [],
20
- reset: () => {},
21
- setOrder: () => {}
22
- });
23
-
24
- /**
25
- * @deprecated The method should not be used
26
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
27
- */
28
- exports.useFocusOrder = useFocusOrder;
29
- const useDynamicFocusOrder = () => ({
30
- a11yOrder: {
31
- ref: /*#__PURE__*/(0, _react.createRef)(),
32
- onLayout: () => {}
33
- },
34
- registerOrder: () => _react.createRef,
35
- reset: () => {},
36
- setOrder: () => {}
37
- });
38
- exports.useDynamicFocusOrder = useDynamicFocusOrder;
39
- const useA11yOrderManager = () => ({
40
- registerOrderRef: () => () => {},
41
- updateRefList: () => {},
42
- reset: () => {},
43
- setOrder: () => {}
44
- });
45
- exports.useA11yOrderManager = useA11yOrderManager;
46
- /**
47
- * @deprecated The method should not be used
48
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
49
- */
50
- const A11yOrder = exports.A11yOrder = _reactNative.View;
51
9
  const A11y = exports.A11y = {
52
10
  Order: _reactNative.View,
53
11
  Group: _reactNative.View,
@@ -1 +1 @@
1
- {"version":3,"names":["_react","require","_reactNative","_A11yIndex","useFocusOrder","a11yOrder","ref","createRef","onLayout","refs","reset","setOrder","exports","useDynamicFocusOrder","registerOrder","useA11yOrderManager","registerOrderRef","updateRefList","A11yOrder","View","A11y","Order","Group","Index","A11yIndex"],"sourceRoot":"../../src","sources":["index.web.ts"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,UAAA,GAAAF,OAAA;AAEA;AACA;AACA;AACA;AACO,MAAMG,aAAa,GAAGA,CAAA,MAAO;EAClCC,SAAS,EAAE;IACTC,GAAG,eAAE,IAAAC,gBAAS,EAAC,CAAC;IAChBC,QAAQ,EAAEA,CAAA,KAAM,CAAC;EACnB,CAAC;EACDC,IAAI,EAAE,EAAE;EACRC,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AAHAC,OAAA,CAAAR,aAAA,GAAAA,aAAA;AAIO,MAAMS,oBAAoB,GAAGA,CAAA,MAAO;EACzCR,SAAS,EAAE;IACTC,GAAG,eAAE,IAAAC,gBAAS,EAAC,CAAC;IAChBC,QAAQ,EAAEA,CAAA,KAAM,CAAC;EACnB,CAAC;EACDM,aAAa,EAAEA,CAAA,KAAMP,gBAAS;EAC9BG,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;AAACC,OAAA,CAAAC,oBAAA,GAAAA,oBAAA;AAEI,MAAME,mBAAmB,GAAGA,CAAA,MAAO;EACxCC,gBAAgB,EAAEA,CAAA,KAAM,MAAM,CAAC,CAAC;EAChCC,aAAa,EAAEA,CAAA,KAAM,CAAC,CAAC;EACvBP,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;AAACC,OAAA,CAAAG,mBAAA,GAAAA,mBAAA;AAKH;AACA;AACA;AACA;AACO,MAAMG,SAAS,GAAAN,OAAA,CAAAM,SAAA,GAAGC,iBAAI;AAEtB,MAAMC,IAAI,GAAAR,OAAA,CAAAQ,IAAA,GAAG;EAClBC,KAAK,EAAEF,iBAAI;EACXG,KAAK,EAAEH,iBAAI;EACXI,KAAK,EAAEC;AACT,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["_reactNative","require","_A11yIndex","A11y","exports","Order","View","Group","Index","A11yIndex"],"sourceRoot":"../../src","sources":["index.web.ts"],"mappings":";;;;;;AAAA,IAAAA,YAAA,GAAAC,OAAA;AACA,IAAAC,UAAA,GAAAD,OAAA;AAIO,MAAME,IAAI,GAAAC,OAAA,CAAAD,IAAA,GAAG;EAClBE,KAAK,EAAEC,iBAAI;EACXC,KAAK,EAAED,iBAAI;EACXE,KAAK,EAAEC;AACT,CAAC","ignoreList":[]}
@@ -1,10 +1,9 @@
1
1
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
2
- import React, { useId } from 'react';
2
+ import React from 'react';
3
3
  import { View } from 'react-native';
4
4
  export const A11yGroup = props => {
5
- const id = useId();
6
5
  return /*#__PURE__*/React.createElement(View, _extends({
7
- nativeID: id
6
+ collapsable: false
8
7
  }, props));
9
8
  };
10
9
  //# sourceMappingURL=A11yGroup.android.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","useId","View","A11yGroup","props","id","createElement","_extends","nativeID"],"sourceRoot":"../../../../src","sources":["components/A11yGroup/A11yGroup.android.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,KAAK,QAAQ,OAAO;AACpC,SAASC,IAAI,QAAQ,cAAc;AAInC,OAAO,MAAMC,SAAS,GAAIC,KAAqB,IAAK;EAClD,MAAMC,EAAE,GAAGJ,KAAK,CAAC,CAAC;EAClB,oBAAOD,KAAA,CAAAM,aAAA,CAACJ,IAAI,EAAAK,QAAA;IAACC,QAAQ,EAAEH;EAAG,GAAKD,KAAK,CAAG,CAAC;AAC1C,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","View","A11yGroup","props","createElement","_extends","collapsable"],"sourceRoot":"../../../../src","sources":["components/A11yGroup/A11yGroup.android.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,IAAI,QAAQ,cAAc;AAInC,OAAO,MAAMC,SAAS,GAAIC,KAAqB,IAAK;EAClD,oBAAOH,KAAA,CAAAI,aAAA,CAACH,IAAI,EAAAI,QAAA;IAACC,WAAW,EAAE;EAAM,GAAKH,KAAK,CAAG,CAAC;AAChD,CAAC","ignoreList":[]}
@@ -10,7 +10,7 @@ export const A11yIndex = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwardRef((
10
10
  }, ref) => {
11
11
  const orderKey = React.useContext(A11ySequenceOrderContext);
12
12
  if (!orderKey) {
13
- throw new Error('A11ySequence.Index should be used inside of A11ySequence.Container');
13
+ throw new Error('<A11y.Index> element should be used inside of <A11y.Order> container');
14
14
  }
15
15
  const indexRef = useRef(null);
16
16
  useImperativeHandle(ref, () => ({
@@ -26,7 +26,7 @@ export const A11yIndex = /*#__PURE__*/React.memo(/*#__PURE__*/React.forwardRef((
26
26
  orderIndex: index,
27
27
  orderKey: orderKey
28
28
  }, props), isSingleChild && children, !isSingleChild && /*#__PURE__*/React.createElement(View, {
29
- nativeID: orderKey
29
+ collapsable: false
30
30
  }, children));
31
31
  }));
32
32
  //# sourceMappingURL=A11yIndex.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["React","useImperativeHandle","useRef","View","A11ySequenceOrderContext","A11yIndexView","Commands","A11yIndex","memo","forwardRef","children","index","props","ref","orderKey","useContext","Error","indexRef","focus","current","isSingleChild","Children","count","createElement","_extends","orderIndex","nativeID"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,mBAAmB,EAAEC,MAAM,QAAQ,OAAO;AAC1D,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,wBAAwB,QAAQ,wCAAwC;AACjF,OAAOC,aAAa,IAClBC,QAAQ,QACH,4CAA4C;AAGnD,OAAO,MAAMC,SAAS,gBAAGP,KAAK,CAACQ,IAAI,cACjCR,KAAK,CAACS,UAAU,CACd,CAAC;EAAEC,QAAQ;EAAEC,KAAK;EAAE,GAAGC;AAAM,CAAC,EAAEC,GAAG,KAAK;EACtC,MAAMC,QAAQ,GAAGd,KAAK,CAACe,UAAU,CAACX,wBAAwB,CAAC;EAC3D,IAAI,CAACU,QAAQ,EAAE;IACb,MAAM,IAAIE,KAAK,CACb,oEACF,CAAC;EACH;EAEA,MAAMC,QAAQ,GAAGf,MAAM,CAAwC,IAAI,CAAC;EAEpED,mBAAmB,CAACY,GAAG,EAAE,OAAO;IAC9BK,KAAK,EAAEA,CAAA,KAAM;MACX,IAAID,QAAQ,CAACE,OAAO,EAAE;QACpBb,QAAQ,CAACY,KAAK,CAACD,QAAQ,CAACE,OAAO,CAAC;MAClC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,MAAMC,aAAa,GAAGpB,KAAK,CAACqB,QAAQ,CAACC,KAAK,CAACZ,QAAQ,CAAC,KAAK,CAAC;EAE1D,oBACEV,KAAA,CAAAuB,aAAA,CAAClB,aAAa,EAAAmB,QAAA;IACZX,GAAG,EAAEI,QAAS;IACdQ,UAAU,EAAEd,KAAM;IAClBG,QAAQ,EAAEA;EAAS,GACfF,KAAK,GAERQ,aAAa,IAAIV,QAAQ,EACzB,CAACU,aAAa,iBAAIpB,KAAA,CAAAuB,aAAA,CAACpB,IAAI;IAACuB,QAAQ,EAAEZ;EAAS,GAAEJ,QAAe,CAChD,CAAC;AAEpB,CACF,CACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","useImperativeHandle","useRef","View","A11ySequenceOrderContext","A11yIndexView","Commands","A11yIndex","memo","forwardRef","children","index","props","ref","orderKey","useContext","Error","indexRef","focus","current","isSingleChild","Children","count","createElement","_extends","orderIndex","collapsable"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,mBAAmB,EAAEC,MAAM,QAAQ,OAAO;AAC1D,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,wBAAwB,QAAQ,wCAAwC;AACjF,OAAOC,aAAa,IAClBC,QAAQ,QACH,4CAA4C;AAGnD,OAAO,MAAMC,SAAS,gBAAGP,KAAK,CAACQ,IAAI,cACjCR,KAAK,CAACS,UAAU,CACd,CAAC;EAAEC,QAAQ;EAAEC,KAAK;EAAE,GAAGC;AAAM,CAAC,EAAEC,GAAG,KAAK;EACtC,MAAMC,QAAQ,GAAGd,KAAK,CAACe,UAAU,CAACX,wBAAwB,CAAC;EAC3D,IAAI,CAACU,QAAQ,EAAE;IACb,MAAM,IAAIE,KAAK,CACb,sEACF,CAAC;EACH;EAEA,MAAMC,QAAQ,GAAGf,MAAM,CAAwC,IAAI,CAAC;EAEpED,mBAAmB,CAACY,GAAG,EAAE,OAAO;IAC9BK,KAAK,EAAEA,CAAA,KAAM;MACX,IAAID,QAAQ,CAACE,OAAO,EAAE;QACpBb,QAAQ,CAACY,KAAK,CAACD,QAAQ,CAACE,OAAO,CAAC;MAClC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,MAAMC,aAAa,GAAGpB,KAAK,CAACqB,QAAQ,CAACC,KAAK,CAACZ,QAAQ,CAAC,KAAK,CAAC;EAE1D,oBACEV,KAAA,CAAAuB,aAAA,CAAClB,aAAa,EAAAmB,QAAA;IACZX,GAAG,EAAEI,QAAS;IACdQ,UAAU,EAAEd,KAAM;IAClBG,QAAQ,EAAEA;EAAS,GACfF,KAAK,GAERQ,aAAa,IAAIV,QAAQ,EACzB,CAACU,aAAa,iBAAIpB,KAAA,CAAAuB,aAAA,CAACpB,IAAI;IAACuB,WAAW,EAAE;EAAM,GAAEhB,QAAe,CAChD,CAAC;AAEpB,CACF,CACF,CAAC","ignoreList":[]}
@@ -3,13 +3,13 @@ import React from 'react';
3
3
  import { forwardRef, useImperativeHandle, useRef } from 'react';
4
4
  import { UIManager } from 'react-native';
5
5
  import { View } from 'react-native';
6
- const WebUiMeneger = UIManager;
6
+ const WebUiManager = UIManager;
7
7
  export const A11yIndex = /*#__PURE__*/forwardRef((props, ref) => {
8
8
  const viewRef = useRef(null);
9
9
  useImperativeHandle(ref, () => ({
10
10
  focus: () => {
11
11
  if (viewRef.current) {
12
- WebUiMeneger.focus(viewRef.current);
12
+ WebUiManager.focus(viewRef.current);
13
13
  }
14
14
  }
15
15
  }));
@@ -1 +1 @@
1
- {"version":3,"names":["React","forwardRef","useImperativeHandle","useRef","UIManager","View","WebUiMeneger","A11yIndex","props","ref","viewRef","focus","current","createElement","_extends"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.web.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,mBAAmB,EAAEC,MAAM,QAAQ,OAAO;AAE/D,SAASC,SAAS,QAAQ,cAAc;AACxC,SAASC,IAAI,QAAQ,cAAc;AAEnC,MAAMC,YAAY,GAAGF,SAEpB;AAED,OAAO,MAAMG,SAAS,gBAAGN,UAAU,CACjC,CAACO,KAAK,EAAEC,GAAG,KAAK;EACd,MAAMC,OAAO,GAAGP,MAAM,CAAO,IAAI,CAAC;EAClCD,mBAAmB,CAACO,GAAG,EAAE,OAAO;IAC9BE,KAAK,EAAEA,CAAA,KAAM;MACX,IAAID,OAAO,CAACE,OAAO,EAAE;QACnBN,YAAY,CAACK,KAAK,CAACD,OAAO,CAACE,OAAO,CAAC;MACrC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,oBAAOZ,KAAA,CAAAa,aAAA,CAACR,IAAI,EAAAS,QAAA,KAAKN,KAAK;IAAEC,GAAG,EAAEC;EAAQ,EAAE,CAAC;AAC1C,CACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["React","forwardRef","useImperativeHandle","useRef","UIManager","View","WebUiManager","A11yIndex","props","ref","viewRef","focus","current","createElement","_extends"],"sourceRoot":"../../../../src","sources":["components/A11yIndex/A11yIndex.web.tsx"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,UAAU,EAAEC,mBAAmB,EAAEC,MAAM,QAAQ,OAAO;AAE/D,SAASC,SAAS,QAAQ,cAAc;AACxC,SAASC,IAAI,QAAQ,cAAc;AAEnC,MAAMC,YAAY,GAAGF,SAEpB;AAED,OAAO,MAAMG,SAAS,gBAAGN,UAAU,CACjC,CAACO,KAAK,EAAEC,GAAG,KAAK;EACd,MAAMC,OAAO,GAAGP,MAAM,CAAO,IAAI,CAAC;EAClCD,mBAAmB,CAACO,GAAG,EAAE,OAAO;IAC9BE,KAAK,EAAEA,CAAA,KAAM;MACX,IAAID,OAAO,CAACE,OAAO,EAAE;QACnBN,YAAY,CAACK,KAAK,CAACD,OAAO,CAACE,OAAO,CAAC;MACrC;IACF;EACF,CAAC,CAAC,CAAC;EAEH,oBAAOZ,KAAA,CAAAa,aAAA,CAACR,IAAI,EAAAS,QAAA,KAAKN,KAAK;IAAEC,GAAG,EAAEC;EAAQ,EAAE,CAAC;AAC1C,CACF,CAAC","ignoreList":[]}
@@ -1,7 +1,6 @@
1
1
  import { A11yIndex } from './components/A11yIndex/A11yIndex';
2
2
  import { A11yIndexSequence } from './components/A11ySequence/A11ySequence';
3
3
  import { A11yGroup } from './components/A11yGroup/A11yGroup';
4
- export { A11yOrder } from './components/A11yOrder/A11yOrder';
5
4
  export const A11y = {
6
5
  Order: A11yIndexSequence,
7
6
  Index: A11yIndex,
@@ -1 +1 @@
1
- {"version":3,"names":["A11yIndex","A11yIndexSequence","A11yGroup","A11yOrder","A11y","Order","Index","Group"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":"AAAA,SAASA,SAAS,QAAQ,kCAAkC;AAC5D,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SAASC,SAAS,QAAQ,kCAAkC;AAE5D,SAASC,SAAS,QAAQ,kCAAkC;AAI5D,OAAO,MAAMC,IAAI,GAAG;EAClBC,KAAK,EAAEJ,iBAAiB;EACxBK,KAAK,EAAEN,SAAS;EAChBO,KAAK,EAAEL;AACT,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["A11yIndex","A11yIndexSequence","A11yGroup","A11y","Order","Index","Group"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":"AAAA,SAASA,SAAS,QAAQ,kCAAkC;AAC5D,SAASC,iBAAiB,QAAQ,wCAAwC;AAC1E,SAASC,SAAS,QAAQ,kCAAkC;AAI5D,OAAO,MAAMC,IAAI,GAAG;EAClBC,KAAK,EAAEH,iBAAiB;EACxBI,KAAK,EAAEL,SAAS;EAChBM,KAAK,EAAEJ;AACT,CAAC","ignoreList":[]}
@@ -1,45 +1,5 @@
1
- import { createRef } from 'react';
2
1
  import { View } from 'react-native';
3
2
  import { A11yIndex } from './components/A11yIndex/A11yIndex.web';
4
-
5
- /**
6
- * @deprecated The method should not be used
7
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
8
- */
9
- export const useFocusOrder = () => ({
10
- a11yOrder: {
11
- ref: /*#__PURE__*/createRef(),
12
- onLayout: () => {}
13
- },
14
- refs: [],
15
- reset: () => {},
16
- setOrder: () => {}
17
- });
18
-
19
- /**
20
- * @deprecated The method should not be used
21
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
22
- */
23
- export const useDynamicFocusOrder = () => ({
24
- a11yOrder: {
25
- ref: /*#__PURE__*/createRef(),
26
- onLayout: () => {}
27
- },
28
- registerOrder: () => createRef,
29
- reset: () => {},
30
- setOrder: () => {}
31
- });
32
- export const useA11yOrderManager = () => ({
33
- registerOrderRef: () => () => {},
34
- updateRefList: () => {},
35
- reset: () => {},
36
- setOrder: () => {}
37
- });
38
- /**
39
- * @deprecated The method should not be used
40
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
41
- */
42
- export const A11yOrder = View;
43
3
  export const A11y = {
44
4
  Order: View,
45
5
  Group: View,
@@ -1 +1 @@
1
- {"version":3,"names":["createRef","View","A11yIndex","useFocusOrder","a11yOrder","ref","onLayout","refs","reset","setOrder","useDynamicFocusOrder","registerOrder","useA11yOrderManager","registerOrderRef","updateRefList","A11yOrder","A11y","Order","Group","Index"],"sourceRoot":"../../src","sources":["index.web.ts"],"mappings":"AAAA,SAASA,SAAS,QAAQ,OAAO;AACjC,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,SAAS,QAAQ,sCAAsC;;AAEhE;AACA;AACA;AACA;AACA,OAAO,MAAMC,aAAa,GAAGA,CAAA,MAAO;EAClCC,SAAS,EAAE;IACTC,GAAG,eAAEL,SAAS,CAAC,CAAC;IAChBM,QAAQ,EAAEA,CAAA,KAAM,CAAC;EACnB,CAAC;EACDC,IAAI,EAAE,EAAE;EACRC,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;;AAEF;AACA;AACA;AACA;AACA,OAAO,MAAMC,oBAAoB,GAAGA,CAAA,MAAO;EACzCN,SAAS,EAAE;IACTC,GAAG,eAAEL,SAAS,CAAC,CAAC;IAChBM,QAAQ,EAAEA,CAAA,KAAM,CAAC;EACnB,CAAC;EACDK,aAAa,EAAEA,CAAA,KAAMX,SAAS;EAC9BQ,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;AAEF,OAAO,MAAMG,mBAAmB,GAAGA,CAAA,MAAO;EACxCC,gBAAgB,EAAEA,CAAA,KAAM,MAAM,CAAC,CAAC;EAChCC,aAAa,EAAEA,CAAA,KAAM,CAAC,CAAC;EACvBN,KAAK,EAAEA,CAAA,KAAM,CAAC,CAAC;EACfC,QAAQ,EAAEA,CAAA,KAAM,CAAC;AACnB,CAAC,CAAC;AAKF;AACA;AACA;AACA;AACA,OAAO,MAAMM,SAAS,GAAGd,IAAI;AAE7B,OAAO,MAAMe,IAAI,GAAG;EAClBC,KAAK,EAAEhB,IAAI;EACXiB,KAAK,EAAEjB,IAAI;EACXkB,KAAK,EAAEjB;AACT,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["View","A11yIndex","A11y","Order","Group","Index"],"sourceRoot":"../../src","sources":["index.web.ts"],"mappings":"AAAA,SAASA,IAAI,QAAQ,cAAc;AACnC,SAASC,SAAS,QAAQ,sCAAsC;AAIhE,OAAO,MAAMC,IAAI,GAAG;EAClBC,KAAK,EAAEH,IAAI;EACXI,KAAK,EAAEJ,IAAI;EACXK,KAAK,EAAEJ;AACT,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"A11yGroup.android.d.ts","sourceRoot":"","sources":["../../../../src/components/A11yGroup/A11yGroup.android.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAgB,MAAM,OAAO,CAAC;AAGrC,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAE7D,eAAO,MAAM,SAAS,UAAW,cAAc,sBAG9C,CAAC"}
1
+ {"version":3,"file":"A11yGroup.android.d.ts","sourceRoot":"","sources":["../../../../src/components/A11yGroup/A11yGroup.android.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAE7D,eAAO,MAAM,SAAS,UAAW,cAAc,sBAE9C,CAAC"}
@@ -1,6 +1,4 @@
1
1
  /// <reference types="react" />
2
- export { A11yOrder } from './components/A11yOrder/A11yOrder';
3
- export type { A11yOrderProps } from './types/A11yOrder.types';
4
2
  export type { IndexCommands } from './types/A11yIndex.types';
5
3
  export declare const A11y: {
6
4
  Order: import("react").NamedExoticComponent<import("react-native").ViewProps>;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,kCAAkC,CAAC;AAC7D,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,YAAY,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D,eAAO,MAAM,IAAI;;;;;;;CAIhB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAIA,YAAY,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D,eAAO,MAAM,IAAI;;;;;;;CAIhB,CAAC"}
@@ -1,44 +1,6 @@
1
- import { createRef } from 'react';
1
+ /// <reference types="react" />
2
2
  import { View } from 'react-native';
3
- /**
4
- * @deprecated The method should not be used
5
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
6
- */
7
- export declare const useFocusOrder: () => {
8
- a11yOrder: {
9
- ref: import("react").RefObject<unknown>;
10
- onLayout: () => void;
11
- };
12
- refs: never[];
13
- reset: () => void;
14
- setOrder: () => void;
15
- };
16
- /**
17
- * @deprecated The method should not be used
18
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
19
- */
20
- export declare const useDynamicFocusOrder: () => {
21
- a11yOrder: {
22
- ref: import("react").RefObject<unknown>;
23
- onLayout: () => void;
24
- };
25
- registerOrder: () => typeof createRef;
26
- reset: () => void;
27
- setOrder: () => void;
28
- };
29
- export declare const useA11yOrderManager: () => {
30
- registerOrderRef: () => () => void;
31
- updateRefList: () => void;
32
- reset: () => void;
33
- setOrder: () => void;
34
- };
35
- export type { A11yOrderProps } from './types/A11yOrder.types';
36
3
  export type { IndexCommands } from './types/A11yIndex.types';
37
- /**
38
- * @deprecated The method should not be used
39
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
40
- */
41
- export declare const A11yOrder: typeof View;
42
4
  export declare const A11y: {
43
5
  Order: typeof View;
44
6
  Group: typeof View;
@@ -1 +1 @@
1
- {"version":3,"file":"index.web.d.ts","sourceRoot":"","sources":["../../src/index.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAClC,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAGpC;;;GAGG;AACH,eAAO,MAAM,aAAa;;;;;;;;CAQxB,CAAC;AAEH;;;GAGG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;CAQ/B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;CAK9B,CAAC;AAEH,YAAY,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAC9D,YAAY,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D;;;GAGG;AACH,eAAO,MAAM,SAAS,aAAO,CAAC;AAE9B,eAAO,MAAM,IAAI;;;;;;;CAIhB,CAAC"}
1
+ {"version":3,"file":"index.web.d.ts","sourceRoot":"","sources":["../../src/index.web.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAGpC,YAAY,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAE7D,eAAO,MAAM,IAAI;;;;;;;CAIhB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-a11y-order",
3
- "version": "0.3.0",
3
+ "version": "0.3.1",
4
4
  "description": "ReactNative library for managing screen reader focus ordering",
5
5
  "main": "lib/commonjs/index",
6
6
  "module": "lib/module/index",
@@ -1,9 +1,8 @@
1
- import React, { useId } from 'react';
1
+ import React from 'react';
2
2
  import { View } from 'react-native';
3
3
 
4
4
  import { A11yGroupProps } from '../../types/A11yGroup.types';
5
5
 
6
6
  export const A11yGroup = (props: A11yGroupProps) => {
7
- const id = useId();
8
- return <View nativeID={id} {...props} />;
7
+ return <View collapsable={false} {...props} />;
9
8
  };
@@ -12,7 +12,7 @@ export const A11yIndex = React.memo(
12
12
  const orderKey = React.useContext(A11ySequenceOrderContext);
13
13
  if (!orderKey) {
14
14
  throw new Error(
15
- 'A11ySequence.Index should be used inside of A11ySequence.Container'
15
+ '<A11y.Index> element should be used inside of <A11y.Order> container'
16
16
  );
17
17
  }
18
18
 
@@ -36,7 +36,7 @@ export const A11yIndex = React.memo(
36
36
  {...props}
37
37
  >
38
38
  {isSingleChild && children}
39
- {!isSingleChild && <View nativeID={orderKey}>{children}</View>}
39
+ {!isSingleChild && <View collapsable={false}>{children}</View>}
40
40
  </A11yIndexView>
41
41
  );
42
42
  }
@@ -4,7 +4,7 @@ import { IndexCommands, A11yIndexProps } from '../../types/A11yIndex.types';
4
4
  import { UIManager } from 'react-native';
5
5
  import { View } from 'react-native';
6
6
 
7
- const WebUiMeneger = UIManager as unknown as {
7
+ const WebUiManager = UIManager as unknown as {
8
8
  focus: (v: View) => void;
9
9
  };
10
10
 
@@ -14,7 +14,7 @@ export const A11yIndex = forwardRef<IndexCommands, A11yIndexProps>(
14
14
  useImperativeHandle(ref, () => ({
15
15
  focus: () => {
16
16
  if (viewRef.current) {
17
- WebUiMeneger.focus(viewRef.current);
17
+ WebUiManager.focus(viewRef.current);
18
18
  }
19
19
  },
20
20
  }));
package/src/index.ts CHANGED
@@ -2,8 +2,6 @@ import { A11yIndex } from './components/A11yIndex/A11yIndex';
2
2
  import { A11yIndexSequence } from './components/A11ySequence/A11ySequence';
3
3
  import { A11yGroup } from './components/A11yGroup/A11yGroup';
4
4
 
5
- export { A11yOrder } from './components/A11yOrder/A11yOrder';
6
- export type { A11yOrderProps } from './types/A11yOrder.types';
7
5
  export type { IndexCommands } from './types/A11yIndex.types';
8
6
 
9
7
  export const A11y = {
package/src/index.web.ts CHANGED
@@ -1,51 +1,8 @@
1
- import { createRef } from 'react';
2
1
  import { View } from 'react-native';
3
2
  import { A11yIndex } from './components/A11yIndex/A11yIndex.web';
4
3
 
5
- /**
6
- * @deprecated The method should not be used
7
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
8
- */
9
- export const useFocusOrder = () => ({
10
- a11yOrder: {
11
- ref: createRef(),
12
- onLayout: () => {},
13
- },
14
- refs: [],
15
- reset: () => {},
16
- setOrder: () => {},
17
- });
18
-
19
- /**
20
- * @deprecated The method should not be used
21
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
22
- */
23
- export const useDynamicFocusOrder = () => ({
24
- a11yOrder: {
25
- ref: createRef(),
26
- onLayout: () => {},
27
- },
28
- registerOrder: () => createRef,
29
- reset: () => {},
30
- setOrder: () => {},
31
- });
32
-
33
- export const useA11yOrderManager = () => ({
34
- registerOrderRef: () => () => {},
35
- updateRefList: () => {},
36
- reset: () => {},
37
- setOrder: () => {},
38
- });
39
-
40
- export type { A11yOrderProps } from './types/A11yOrder.types';
41
4
  export type { IndexCommands } from './types/A11yIndex.types';
42
5
 
43
- /**
44
- * @deprecated The method should not be used
45
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
46
- */
47
- export const A11yOrder = View;
48
-
49
6
  export const A11y = {
50
7
  Order: View,
51
8
  Group: View,
@@ -1,38 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.A11yOrder = void 0;
7
- var _react = _interopRequireWildcard(require("react"));
8
- var _reactNative = require("react-native");
9
- function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function (e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != typeof e && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (const t in e) "default" !== t && {}.hasOwnProperty.call(e, t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, t)) && (i.get || i.set) ? o(f, t, i) : f[t] = e[t]); return f; })(e, t); }
10
- function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
11
- /**
12
- * @deprecated The method should not be used
13
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
14
- */
15
- const A11yOrder = ({
16
- a11yOrder,
17
- onLayout,
18
- ignoreWarn,
19
- ...props
20
- }) => {
21
- if (!ignoreWarn) {
22
- console.warn('A11yOrder: This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration');
23
- }
24
- const onLayoutHandler = (0, _react.useCallback)(e => {
25
- onLayout === null || onLayout === void 0 || onLayout(e);
26
- a11yOrder.onLayout();
27
- }, [a11yOrder, onLayout]);
28
- const id = (_react.useId === null || _react.useId === void 0 ? void 0 : (0, _react.useId)()) || 'mock_id'; // ToDo: use native component with tag to nativeTag
29
-
30
- return /*#__PURE__*/_react.default.createElement(_reactNative.View, _extends({
31
- nativeID: id
32
- }, props, {
33
- onLayout: onLayoutHandler,
34
- ref: a11yOrder.ref
35
- }));
36
- };
37
- exports.A11yOrder = A11yOrder;
38
- //# sourceMappingURL=A11yOrder.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","_extends","assign","bind","arguments","length","apply","A11yOrder","a11yOrder","onLayout","ignoreWarn","props","console","warn","onLayoutHandler","useCallback","id","useId","createElement","View","nativeID","ref","exports"],"sourceRoot":"../../../../src","sources":["components/A11yOrder/A11yOrder.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AAAuD,SAAAD,wBAAAG,CAAA,EAAAC,CAAA,6BAAAC,OAAA,MAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAL,uBAAA,YAAAA,CAAAG,CAAA,EAAAC,CAAA,SAAAA,CAAA,IAAAD,CAAA,IAAAA,CAAA,CAAAK,UAAA,SAAAL,CAAA,MAAAM,CAAA,EAAAC,CAAA,EAAAC,CAAA,KAAAC,SAAA,QAAAC,OAAA,EAAAV,CAAA,iBAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,SAAAQ,CAAA,MAAAF,CAAA,GAAAL,CAAA,GAAAG,CAAA,GAAAD,CAAA,QAAAG,CAAA,CAAAK,GAAA,CAAAX,CAAA,UAAAM,CAAA,CAAAM,GAAA,CAAAZ,CAAA,GAAAM,CAAA,CAAAO,GAAA,CAAAb,CAAA,EAAAQ,CAAA,gBAAAP,CAAA,IAAAD,CAAA,gBAAAC,CAAA,OAAAa,cAAA,CAAAC,IAAA,CAAAf,CAAA,EAAAC,CAAA,OAAAM,CAAA,IAAAD,CAAA,GAAAU,MAAA,CAAAC,cAAA,KAAAD,MAAA,CAAAE,wBAAA,CAAAlB,CAAA,EAAAC,CAAA,OAAAM,CAAA,CAAAK,GAAA,IAAAL,CAAA,CAAAM,GAAA,IAAAP,CAAA,CAAAE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G,EAAEb,SAAS,CAACa;EAAI,EACpB,CAAC;AAEN,CAAC;AAACC,OAAA,CAAAf,SAAA,GAAAA,SAAA","ignoreList":[]}
@@ -1,6 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- //# sourceMappingURL=A11yOrder.types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/A11yOrder.types.ts"],"mappings":"","ignoreList":[]}
@@ -1,30 +0,0 @@
1
- function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
2
- import React, { useCallback, useId } from 'react';
3
- import { View } from 'react-native';
4
- /**
5
- * @deprecated The method should not be used
6
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
7
- */
8
- export const A11yOrder = ({
9
- a11yOrder,
10
- onLayout,
11
- ignoreWarn,
12
- ...props
13
- }) => {
14
- if (!ignoreWarn) {
15
- console.warn('A11yOrder: This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration');
16
- }
17
- const onLayoutHandler = useCallback(e => {
18
- onLayout === null || onLayout === void 0 || onLayout(e);
19
- a11yOrder.onLayout();
20
- }, [a11yOrder, onLayout]);
21
- const id = (useId === null || useId === void 0 ? void 0 : useId()) || 'mock_id'; // ToDo: use native component with tag to nativeTag
22
-
23
- return /*#__PURE__*/React.createElement(View, _extends({
24
- nativeID: id
25
- }, props, {
26
- onLayout: onLayoutHandler,
27
- ref: a11yOrder.ref
28
- }));
29
- };
30
- //# sourceMappingURL=A11yOrder.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["React","useCallback","useId","View","A11yOrder","a11yOrder","onLayout","ignoreWarn","props","console","warn","onLayoutHandler","e","id","createElement","_extends","nativeID","ref"],"sourceRoot":"../../../../src","sources":["components/A11yOrder/A11yOrder.tsx"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,WAAW,EAAEC,KAAK,QAAQ,OAAO;AACjD,SAASC,IAAI,QAA2B,cAAc;AAGtD;AACA;AACA;AACA;AACA,OAAO,MAAMC,SAAmC,GAAGA,CAAC;EAClDC,SAAS;EACTC,QAAQ;EACRC,UAAU;EACV,GAAGC;AACL,CAAC,KAAK;EACJ,IAAI,CAACD,UAAU,EAAE;IACfE,OAAO,CAACC,IAAI,CACV,6LACF,CAAC;EACH;EACA,MAAMC,eAAe,GAAGV,WAAW,CAChCW,CAAoB,IAAK;IACxBN,QAAQ,aAARA,QAAQ,eAARA,QAAQ,CAAGM,CAAC,CAAC;IACbP,SAAS,CAACC,QAAQ,CAAC,CAAC;EACtB,CAAC,EACD,CAACD,SAAS,EAAEC,QAAQ,CACtB,CAAC;EAED,MAAMO,EAAE,GAAG,CAAAX,KAAK,aAALA,KAAK,uBAALA,KAAK,CAAG,CAAC,KAAI,SAAS,CAAC,CAAC;;EAEnC,oBACEF,KAAA,CAAAc,aAAA,CAACX,IAAI,EAAAY,QAAA;IACHC,QAAQ,EAAEH;EAAG,GACTL,KAAK;IACTF,QAAQ,EAAEK,eAAgB;IAC1BM,GAAG,EAAEZ,SAAS,CAACY;EAAI,EACpB,CAAC;AAEN,CAAC","ignoreList":[]}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=A11yOrder.types.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":[],"sourceRoot":"../../../src","sources":["types/A11yOrder.types.ts"],"mappings":"","ignoreList":[]}
@@ -1,8 +0,0 @@
1
- import React from 'react';
2
- import type { A11yOrderProps } from '../../types/A11yOrder.types';
3
- /**
4
- * @deprecated The method should not be used
5
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
6
- */
7
- export declare const A11yOrder: React.FC<A11yOrderProps>;
8
- //# sourceMappingURL=A11yOrder.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"A11yOrder.d.ts","sourceRoot":"","sources":["../../../../src/components/A11yOrder/A11yOrder.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAElD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,6BAA6B,CAAC;AAElE;;;GAGG;AACH,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,cAAc,CA6B9C,CAAC"}
@@ -1,10 +0,0 @@
1
- /// <reference types="react" />
2
- import type { ViewProps, View } from 'react-native';
3
- export type A11yOrderProps = {
4
- a11yOrder: {
5
- ref: React.RefObject<View>;
6
- onLayout: () => void;
7
- };
8
- ignoreWarn?: boolean;
9
- } & ViewProps;
10
- //# sourceMappingURL=A11yOrder.types.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"A11yOrder.types.d.ts","sourceRoot":"","sources":["../../../src/types/A11yOrder.types.ts"],"names":[],"mappings":";AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAEpD,MAAM,MAAM,cAAc,GAAG;IAC3B,SAAS,EAAE;QACT,GAAG,EAAE,KAAK,CAAC,SAAS,CAAC,IAAI,CAAC,CAAC;QAC3B,QAAQ,EAAE,MAAM,IAAI,CAAC;KACtB,CAAC;IACF,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,GAAG,SAAS,CAAC"}
@@ -1,38 +0,0 @@
1
- import React, { useCallback, useId } from 'react';
2
- import { View, LayoutChangeEvent } from 'react-native';
3
- import type { A11yOrderProps } from '../../types/A11yOrder.types';
4
-
5
- /**
6
- * @deprecated The method should not be used
7
- * This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration
8
- */
9
- export const A11yOrder: React.FC<A11yOrderProps> = ({
10
- a11yOrder,
11
- onLayout,
12
- ignoreWarn,
13
- ...props
14
- }) => {
15
- if (!ignoreWarn) {
16
- console.warn(
17
- 'A11yOrder: This API is going to be removed in future releases, you can find migration instruction here: https://github.com/ArturKalach/react-native-a11y-order?tab=readme-ov-file#migration'
18
- );
19
- }
20
- const onLayoutHandler = useCallback(
21
- (e: LayoutChangeEvent) => {
22
- onLayout?.(e);
23
- a11yOrder.onLayout();
24
- },
25
- [a11yOrder, onLayout]
26
- );
27
-
28
- const id = useId?.() || 'mock_id'; // ToDo: use native component with tag to nativeTag
29
-
30
- return (
31
- <View
32
- nativeID={id}
33
- {...props}
34
- onLayout={onLayoutHandler}
35
- ref={a11yOrder.ref}
36
- />
37
- );
38
- };
@@ -1,9 +0,0 @@
1
- import type { ViewProps, View } from 'react-native';
2
-
3
- export type A11yOrderProps = {
4
- a11yOrder: {
5
- ref: React.RefObject<View>;
6
- onLayout: () => void;
7
- };
8
- ignoreWarn?: boolean;
9
- } & ViewProps;