@react-navigation/drawer 7.3.8 → 7.3.10

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 (49) hide show
  1. package/lib/module/views/DrawerItem.js +3 -5
  2. package/lib/module/views/DrawerItem.js.map +1 -1
  3. package/lib/typescript/src/utils/addCancelListener.d.ts.map +1 -1
  4. package/lib/typescript/src/utils/addCancelListener.native.d.ts.map +1 -1
  5. package/lib/typescript/src/views/ScreenFallback.d.ts.map +1 -1
  6. package/package.json +25 -22
  7. package/src/views/DrawerItem.tsx +3 -3
  8. package/lib/commonjs/index.js +0 -89
  9. package/lib/commonjs/index.js.map +0 -1
  10. package/lib/commonjs/navigators/createDrawerNavigator.js +0 -53
  11. package/lib/commonjs/navigators/createDrawerNavigator.js.map +0 -1
  12. package/lib/commonjs/package.json +0 -1
  13. package/lib/commonjs/types.js +0 -6
  14. package/lib/commonjs/types.js.map +0 -1
  15. package/lib/commonjs/utils/DrawerPositionContext.js +0 -11
  16. package/lib/commonjs/utils/DrawerPositionContext.js.map +0 -1
  17. package/lib/commonjs/utils/DrawerStatusContext.js +0 -11
  18. package/lib/commonjs/utils/DrawerStatusContext.js.map +0 -1
  19. package/lib/commonjs/utils/addCancelListener.js +0 -19
  20. package/lib/commonjs/utils/addCancelListener.js.map +0 -1
  21. package/lib/commonjs/utils/addCancelListener.native.js +0 -15
  22. package/lib/commonjs/utils/addCancelListener.native.js.map +0 -1
  23. package/lib/commonjs/utils/getDrawerStatusFromState.js +0 -14
  24. package/lib/commonjs/utils/getDrawerStatusFromState.js.map +0 -1
  25. package/lib/commonjs/utils/useDrawerStatus.js +0 -22
  26. package/lib/commonjs/utils/useDrawerStatus.js.map +0 -1
  27. package/lib/commonjs/views/DrawerContent.js +0 -33
  28. package/lib/commonjs/views/DrawerContent.js.map +0 -1
  29. package/lib/commonjs/views/DrawerContentScrollView.js +0 -47
  30. package/lib/commonjs/views/DrawerContentScrollView.js.map +0 -1
  31. package/lib/commonjs/views/DrawerItem.js +0 -121
  32. package/lib/commonjs/views/DrawerItem.js.map +0 -1
  33. package/lib/commonjs/views/DrawerItemList.js +0 -73
  34. package/lib/commonjs/views/DrawerItemList.js.map +0 -1
  35. package/lib/commonjs/views/DrawerToggleButton.js +0 -41
  36. package/lib/commonjs/views/DrawerToggleButton.js.map +0 -1
  37. package/lib/commonjs/views/DrawerView.js +0 -290
  38. package/lib/commonjs/views/DrawerView.js.map +0 -1
  39. package/lib/commonjs/views/ScreenFallback.js +0 -53
  40. package/lib/commonjs/views/ScreenFallback.js.map +0 -1
  41. package/lib/commonjs/views/assets/toggle-drawer-icon.png +0 -0
  42. package/lib/commonjs/views/assets/toggle-drawer-icon@1x.android.png +0 -0
  43. package/lib/commonjs/views/assets/toggle-drawer-icon@1x.ios.png +0 -0
  44. package/lib/commonjs/views/assets/toggle-drawer-icon@2x.android.png +0 -0
  45. package/lib/commonjs/views/assets/toggle-drawer-icon@2x.ios.png +0 -0
  46. package/lib/commonjs/views/assets/toggle-drawer-icon@3x.android.png +0 -0
  47. package/lib/commonjs/views/assets/toggle-drawer-icon@3x.ios.png +0 -0
  48. package/lib/commonjs/views/assets/toggle-drawer-icon@4x.android.png +0 -0
  49. package/lib/commonjs/views/assets/toggle-drawer-icon@4x.ios.png +0 -0
@@ -1,121 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.DrawerItem = DrawerItem;
7
- var _elements = require("@react-navigation/elements");
8
- var _native = require("@react-navigation/native");
9
- var _color = _interopRequireDefault(require("color"));
10
- var React = _interopRequireWildcard(require("react"));
11
- var _reactNative = require("react-native");
12
- var _jsxRuntime = require("react/jsx-runtime");
13
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
14
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
15
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
16
- /**
17
- * A component used to show an action item with an icon and a label in a navigation drawer.
18
- */
19
- function DrawerItem(props) {
20
- const {
21
- colors,
22
- fonts
23
- } = (0, _native.useTheme)();
24
- const {
25
- href,
26
- icon,
27
- label,
28
- labelStyle,
29
- focused = false,
30
- allowFontScaling,
31
- activeTintColor = colors.primary,
32
- // eslint-disable-next-line @eslint-react/no-unstable-default-props
33
- inactiveTintColor = (0, _color.default)(colors.text).alpha(0.68).rgb().string(),
34
- // eslint-disable-next-line @eslint-react/no-unstable-default-props
35
- activeBackgroundColor = (0, _color.default)(activeTintColor).alpha(0.12).rgb().string(),
36
- inactiveBackgroundColor = 'transparent',
37
- style,
38
- onPress,
39
- pressColor,
40
- pressOpacity = 1,
41
- testID,
42
- accessibilityLabel,
43
- ...rest
44
- } = props;
45
- const {
46
- borderRadius = 56
47
- } = _reactNative.StyleSheet.flatten(style || {});
48
- const color = focused ? activeTintColor : inactiveTintColor;
49
- const backgroundColor = focused ? activeBackgroundColor : inactiveBackgroundColor;
50
- const iconNode = icon ? icon({
51
- size: 24,
52
- focused,
53
- color
54
- }) : null;
55
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
56
- collapsable: false,
57
- ...rest,
58
- style: [styles.container, {
59
- borderRadius,
60
- backgroundColor
61
- }, style],
62
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.PlatformPressable, {
63
- testID: testID,
64
- onPress: onPress,
65
- accessibilityLabel: accessibilityLabel,
66
- accessibilityRole: "button",
67
- accessibilityState: {
68
- selected: focused
69
- },
70
- pressColor: pressColor,
71
- pressOpacity: pressOpacity,
72
- hoverEffect: {
73
- color
74
- },
75
- href: href,
76
- children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
77
- style: [styles.wrapper, {
78
- borderRadius
79
- }],
80
- children: [iconNode, /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
81
- style: [styles.label, {
82
- marginStart: iconNode ? 12 : 0
83
- }],
84
- children: typeof label === 'string' ? /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.Text, {
85
- numberOfLines: 1,
86
- allowFontScaling: allowFontScaling,
87
- style: [styles.labelText, {
88
- color
89
- }, fonts.medium, labelStyle],
90
- children: label
91
- }) : label({
92
- color,
93
- focused
94
- })
95
- })]
96
- })
97
- })
98
- });
99
- }
100
- const styles = _reactNative.StyleSheet.create({
101
- container: {
102
- overflow: 'hidden'
103
- },
104
- wrapper: {
105
- flexDirection: 'row',
106
- alignItems: 'center',
107
- paddingVertical: 11,
108
- paddingStart: 16,
109
- paddingEnd: 24
110
- },
111
- label: {
112
- marginEnd: 12,
113
- marginVertical: 4,
114
- flex: 1
115
- },
116
- labelText: {
117
- lineHeight: 24,
118
- textAlignVertical: 'center'
119
- }
120
- });
121
- //# sourceMappingURL=DrawerItem.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_elements","require","_native","_color","_interopRequireDefault","React","_interopRequireWildcard","_reactNative","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","DrawerItem","props","colors","fonts","useTheme","href","icon","label","labelStyle","focused","allowFontScaling","activeTintColor","primary","inactiveTintColor","Color","text","alpha","rgb","string","activeBackgroundColor","inactiveBackgroundColor","style","onPress","pressColor","pressOpacity","testID","accessibilityLabel","rest","borderRadius","StyleSheet","flatten","color","backgroundColor","iconNode","size","jsx","View","collapsable","styles","container","children","PlatformPressable","accessibilityRole","accessibilityState","selected","hoverEffect","jsxs","wrapper","marginStart","Text","numberOfLines","labelText","medium","create","overflow","flexDirection","alignItems","paddingVertical","paddingStart","paddingEnd","marginEnd","marginVertical","flex","lineHeight","textAlignVertical"],"sourceRoot":"../../../src","sources":["views/DrawerItem.tsx"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAC,sBAAA,CAAAH,OAAA;AACA,IAAAI,KAAA,GAAAC,uBAAA,CAAAL,OAAA;AACA,IAAAM,YAAA,GAAAN,OAAA;AAMsB,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAQ,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAJ,wBAAAI,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,WAAAK,OAAA,EAAAL,CAAA,QAAAG,CAAA,GAAAJ,wBAAA,CAAAG,CAAA,OAAAC,CAAA,IAAAA,CAAA,CAAAG,GAAA,CAAAN,CAAA,UAAAG,CAAA,CAAAI,GAAA,CAAAP,CAAA,OAAAQ,CAAA,KAAAC,SAAA,UAAAC,CAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA,CAAAE,wBAAA,WAAAC,CAAA,IAAAd,CAAA,oBAAAc,CAAA,OAAAC,cAAA,CAAAC,IAAA,CAAAhB,CAAA,EAAAc,CAAA,SAAAG,CAAA,GAAAP,CAAA,GAAAC,MAAA,CAAAE,wBAAA,CAAAb,CAAA,EAAAc,CAAA,UAAAG,C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,OAAOjC,KAAK,KAAK,QAAQ,gBACxB,IAAA5B,WAAA,CAAAwD,GAAA,EAAChE,SAAA,CAAA8E,IAAI;YACHC,aAAa,EAAE,CAAE;YACjBxC,gBAAgB,EAAEA,gBAAiB;YACnCW,KAAK,EAAE,CAACiB,MAAM,CAACa,SAAS,EAAE;cAAEpB;YAAM,CAAC,EAAE5B,KAAK,CAACiD,MAAM,EAAE5C,UAAU,CAAE;YAAAgC,QAAA,EAE9DjC;UAAK,CACF,CAAC,GAEPA,KAAK,CAAC;YAAEwB,KAAK;YAAEtB;UAAQ,CAAC;QACzB,CACG,CAAC;MAAA,CACH;IAAC,CACU;EAAC,CAChB,CAAC;AAEX;AAEA,MAAM6B,MAAM,GAAGT,uBAAU,CAACwB,MAAM,CAAC;EAC/Bd,SAAS,EAAE;IACTe,QAAQ,EAAE;EACZ,CAAC;EACDP,OAAO,EAAE;IACPQ,aAAa,EAAE,KAAK;IACpBC,UAAU,EAAE,QAAQ;IACpBC,eAAe,EAAE,EAAE;IACnBC,YAAY,EAAE,EAAE;IAChBC,UAAU,EAAE;EACd,CAAC;EACDpD,KAAK,EAAE;IACLqD,SAAS,EAAE,EAAE;IACbC,cAAc,EAAE,CAAC;IACjBC,IAAI,EAAE;EACR,CAAC;EACDX,SAAS,EAAE;IACTY,UAAU,EAAE,EAAE;IACdC,iBAAiB,EAAE;EACrB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,73 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.DrawerItemList = DrawerItemList;
7
- var _native = require("@react-navigation/native");
8
- var React = _interopRequireWildcard(require("react"));
9
- var _DrawerItem = require("./DrawerItem.js");
10
- var _jsxRuntime = require("react/jsx-runtime");
11
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
12
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
13
- /**
14
- * Component that renders the navigation list in the drawer.
15
- */
16
- function DrawerItemList({
17
- state,
18
- navigation,
19
- descriptors
20
- }) {
21
- const {
22
- buildHref
23
- } = (0, _native.useLinkBuilder)();
24
- const focusedRoute = state.routes[state.index];
25
- const focusedDescriptor = descriptors[focusedRoute.key];
26
- const focusedOptions = focusedDescriptor.options;
27
- const {
28
- drawerActiveTintColor,
29
- drawerInactiveTintColor,
30
- drawerActiveBackgroundColor,
31
- drawerInactiveBackgroundColor
32
- } = focusedOptions;
33
- return state.routes.map((route, i) => {
34
- const focused = i === state.index;
35
- const onPress = () => {
36
- const event = navigation.emit({
37
- type: 'drawerItemPress',
38
- target: route.key,
39
- canPreventDefault: true
40
- });
41
- if (!event.defaultPrevented) {
42
- navigation.dispatch({
43
- ...(focused ? _native.DrawerActions.closeDrawer() : _native.CommonActions.navigate(route)),
44
- target: state.key
45
- });
46
- }
47
- };
48
- const {
49
- title,
50
- drawerLabel,
51
- drawerIcon,
52
- drawerLabelStyle,
53
- drawerItemStyle,
54
- drawerAllowFontScaling
55
- } = descriptors[route.key].options;
56
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerItem.DrawerItem, {
57
- route: route,
58
- href: buildHref(route.name, route.params),
59
- label: drawerLabel !== undefined ? drawerLabel : title !== undefined ? title : route.name,
60
- icon: drawerIcon,
61
- focused: focused,
62
- activeTintColor: drawerActiveTintColor,
63
- inactiveTintColor: drawerInactiveTintColor,
64
- activeBackgroundColor: drawerActiveBackgroundColor,
65
- inactiveBackgroundColor: drawerInactiveBackgroundColor,
66
- allowFontScaling: drawerAllowFontScaling,
67
- labelStyle: drawerLabelStyle,
68
- style: drawerItemStyle,
69
- onPress: onPress
70
- }, route.key);
71
- });
72
- }
73
- //# sourceMappingURL=DrawerItemList.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_native","require","React","_interopRequireWildcard","_DrawerItem","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","DrawerItemList","state","navigation","descriptors","buildHref","useLinkBuilder","focusedRoute","routes","index","focusedDescriptor","key","focusedOptions","options","drawerActiveTintColor","drawerInactiveTintColor","drawerActiveBackgroundColor","drawerInactiveBackgroundColor","map","route","focused","onPress","event","emit","type","target","canPreventDefault","defaultPrevented","dispatch","DrawerActions","closeDrawer","CommonActions","navigate","title","drawerLabel","drawerIcon","drawerLabelStyle","drawerItemStyle","drawerAllowFontScaling","jsx","DrawerItem","href","name","params","label","undefined","icon","activeTintColor","inactiveTintColor","activeBackgroundColor","inactiveBackgroundColor","allowFontScaling","labelStyle","style"],"sourceRoot":"../../../src","sources":["views/DrawerItemList.tsx"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAOA,IAAAC,KAAA,GAAAC,uBAAA,CAAAF,OAAA;AAGA,IAAAG,WAAA,GAAAH,OAAA;AAA0C,IAAAI,WAAA,GAAAJ,OAAA;AAAA,SAAAK,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAJ,wBAAAI,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAA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EAAEb,sBAAuB;MACzCc,UAAU,EAAEhB,gBAAiB;MAC7BiB,KAAK,EAAEhB,eAAgB;MACvBhB,OAAO,EAAEA;IAAQ,GAnBZF,KAAK,CAACR,GAoBZ,CAAC;EAEN,CAAC,CAAC;AACJ","ignoreList":[]}
@@ -1,41 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.DrawerToggleButton = DrawerToggleButton;
7
- var _elements = require("@react-navigation/elements");
8
- var _native = require("@react-navigation/native");
9
- var _reactNative = require("react-native");
10
- var _toggleDrawerIcon = _interopRequireDefault(require("./assets/toggle-drawer-icon.png"));
11
- var _jsxRuntime = require("react/jsx-runtime");
12
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
13
- function DrawerToggleButton({
14
- tintColor,
15
- accessibilityLabel = 'Show navigation menu',
16
- imageSource = _toggleDrawerIcon.default,
17
- ...rest
18
- }) {
19
- const navigation = (0, _native.useNavigation)();
20
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.HeaderButton, {
21
- ...rest,
22
- accessibilityLabel: accessibilityLabel,
23
- onPress: () => navigation.dispatch(_native.DrawerActions.toggleDrawer()),
24
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Image, {
25
- resizeMode: "contain",
26
- source: imageSource,
27
- fadeDuration: 0,
28
- tintColor: tintColor,
29
- style: styles.icon
30
- })
31
- });
32
- }
33
- const styles = _reactNative.StyleSheet.create({
34
- icon: {
35
- height: 24,
36
- width: 24,
37
- marginVertical: 8,
38
- marginHorizontal: 5
39
- }
40
- });
41
- //# sourceMappingURL=DrawerToggleButton.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_elements","require","_native","_reactNative","_toggleDrawerIcon","_interopRequireDefault","_jsxRuntime","e","__esModule","default","DrawerToggleButton","tintColor","accessibilityLabel","imageSource","toggleDrawerIcon","rest","navigation","useNavigation","jsx","HeaderButton","onPress","dispatch","DrawerActions","toggleDrawer","children","Image","resizeMode","source","fadeDuration","style","styles","icon","StyleSheet","create","height","width","marginVertical","marginHorizontal"],"sourceRoot":"../../../src","sources":["views/DrawerToggleButton.tsx"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,OAAA,GAAAD,OAAA;AAKA,IAAAE,YAAA,GAAAF,OAAA;AAGA,IAAAG,iBAAA,GAAAC,sBAAA,CAAAJ,OAAA;AAA+D,IAAAK,WAAA,GAAAL,OAAA;AAAA,SAAAI,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAUxD,SAASG,kBAAkBA,CAAC;EACjCC,SAAS;EACTC,kBAAkB,GAAG,sBAAsB;EAC3CC,WAAW,GAAGC,yBAAgB;EAC9B,GAAGC;AACE,CAAC,EAAE;EACR,MAAMC,UAAU,GAAG,IAAAC,qBAAa,EAAsC,CAAC;EAEvE,oBACE,IAAAX,WAAA,CAAAY,GAAA,EAAClB,SAAA,CAAAmB,YAAY;IAAA,GACPJ,IAAI;IACRH,kBAAkB,EAAEA,kBAAmB;IACvCQ,OAAO,EAAEA,CAAA,KAAMJ,UAAU,CAACK,QAAQ,CAACC,qBAAa,CAACC,YAAY,CAAC,CAAC,CAAE;IAAAC,QAAA,eAEjE,IAAAlB,WAAA,CAAAY,GAAA,EAACf,YAAA,CAAAsB,KAAK;MACJC,UAAU,EAAC,SAAS;MACpBC,MAAM,EAAEd,WAAY;MACpBe,YAAY,EAAE,CAAE;MAChBjB,SAAS,EAAEA,SAAU;MACrBkB,KAAK,EAAEC,MAAM,CAACC;IAAK,CACpB;EAAC,CACU,CAAC;AAEnB;AAEA,MAAMD,MAAM,GAAGE,uBAAU,CAACC,MAAM,CAAC;EAC/BF,IAAI,EAAE;IACJG,MAAM,EAAE,EAAE;IACVC,KAAK,EAAE,EAAE;IACTC,cAAc,EAAE,CAAC;IACjBC,gBAAgB,EAAE;EACpB;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,290 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.DrawerView = DrawerView;
7
- var _elements = require("@react-navigation/elements");
8
- var _native = require("@react-navigation/native");
9
- var React = _interopRequireWildcard(require("react"));
10
- var _reactNative = require("react-native");
11
- var _reactNativeDrawerLayout = require("react-native-drawer-layout");
12
- var _reactNativeSafeAreaContext = require("react-native-safe-area-context");
13
- var _useLatestCallback = _interopRequireDefault(require("use-latest-callback"));
14
- var _addCancelListener = require("../utils/addCancelListener");
15
- var _DrawerPositionContext = require("../utils/DrawerPositionContext.js");
16
- var _DrawerStatusContext = require("../utils/DrawerStatusContext.js");
17
- var _getDrawerStatusFromState = require("../utils/getDrawerStatusFromState.js");
18
- var _DrawerContent = require("./DrawerContent.js");
19
- var _DrawerToggleButton = require("./DrawerToggleButton.js");
20
- var _ScreenFallback = require("./ScreenFallback.js");
21
- var _jsxRuntime = require("react/jsx-runtime");
22
- function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
23
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
24
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
25
- const DRAWER_BORDER_RADIUS = 16;
26
- const renderDrawerContentDefault = props => /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerContent.DrawerContent, {
27
- ...props
28
- });
29
- function DrawerViewBase({
30
- state,
31
- navigation,
32
- descriptors,
33
- defaultStatus,
34
- drawerContent = renderDrawerContentDefault,
35
- detachInactiveScreens = _reactNative.Platform.OS === 'web' || _reactNative.Platform.OS === 'android' || _reactNative.Platform.OS === 'ios'
36
- }) {
37
- const {
38
- direction
39
- } = (0, _native.useLocale)();
40
- const focusedRouteKey = state.routes[state.index].key;
41
- const {
42
- drawerHideStatusBarOnOpen,
43
- drawerPosition = direction === 'rtl' ? 'right' : 'left',
44
- drawerStatusBarAnimation,
45
- drawerStyle,
46
- drawerType = _reactNative.Platform.select({
47
- ios: 'slide',
48
- default: 'front'
49
- }),
50
- configureGestureHandler,
51
- keyboardDismissMode,
52
- overlayColor = 'rgba(0, 0, 0, 0.5)',
53
- swipeEdgeWidth,
54
- swipeEnabled = _reactNative.Platform.OS !== 'web' && _reactNative.Platform.OS !== 'windows' && _reactNative.Platform.OS !== 'macos',
55
- swipeMinDistance,
56
- overlayAccessibilityLabel
57
- } = descriptors[focusedRouteKey].options;
58
- const [loaded, setLoaded] = React.useState([focusedRouteKey]);
59
- if (!loaded.includes(focusedRouteKey)) {
60
- setLoaded([...loaded, focusedRouteKey]);
61
- }
62
- const previousRouteKeyRef = React.useRef(focusedRouteKey);
63
- React.useEffect(() => {
64
- const previousRouteKey = previousRouteKeyRef.current;
65
- if (previousRouteKey !== focusedRouteKey && descriptors[previousRouteKey]?.options.popToTopOnBlur) {
66
- const prevRoute = state.routes.find(route => route.key === previousRouteKey);
67
- if (prevRoute?.state?.type === 'stack' && prevRoute.state.key) {
68
- navigation.dispatch({
69
- ..._native.StackActions.popToTop(),
70
- target: prevRoute.state.key
71
- });
72
- }
73
- }
74
- previousRouteKeyRef.current = focusedRouteKey;
75
- }, [descriptors, focusedRouteKey, navigation, state.routes]);
76
- const dimensions = (0, _reactNativeSafeAreaContext.useSafeAreaFrame)();
77
- const {
78
- colors
79
- } = (0, _native.useTheme)();
80
- const drawerStatus = (0, _getDrawerStatusFromState.getDrawerStatusFromState)(state);
81
- const handleDrawerOpen = (0, _useLatestCallback.default)(() => {
82
- navigation.dispatch({
83
- ..._native.DrawerActions.openDrawer(),
84
- target: state.key
85
- });
86
- });
87
- const handleDrawerClose = (0, _useLatestCallback.default)(() => {
88
- navigation.dispatch({
89
- ..._native.DrawerActions.closeDrawer(),
90
- target: state.key
91
- });
92
- });
93
- const handleGestureStart = (0, _useLatestCallback.default)(() => {
94
- navigation.emit({
95
- type: 'gestureStart',
96
- target: state.key
97
- });
98
- });
99
- const handleGestureEnd = (0, _useLatestCallback.default)(() => {
100
- navigation.emit({
101
- type: 'gestureEnd',
102
- target: state.key
103
- });
104
- });
105
- const handleGestureCancel = (0, _useLatestCallback.default)(() => {
106
- navigation.emit({
107
- type: 'gestureCancel',
108
- target: state.key
109
- });
110
- });
111
- const handleTransitionStart = (0, _useLatestCallback.default)(closing => {
112
- navigation.emit({
113
- type: 'transitionStart',
114
- data: {
115
- closing
116
- },
117
- target: state.key
118
- });
119
- });
120
- const handleTransitionEnd = (0, _useLatestCallback.default)(closing => {
121
- navigation.emit({
122
- type: 'transitionEnd',
123
- data: {
124
- closing
125
- },
126
- target: state.key
127
- });
128
- });
129
- React.useEffect(() => {
130
- if (drawerStatus === defaultStatus || drawerType === 'permanent') {
131
- return;
132
- }
133
- const handleHardwareBack = () => {
134
- // We shouldn't handle the back button if the parent screen isn't focused
135
- // This will avoid the drawer overriding event listeners from a focused screen
136
- if (!navigation.isFocused()) {
137
- return false;
138
- }
139
- if (defaultStatus === 'open') {
140
- handleDrawerOpen();
141
- } else {
142
- handleDrawerClose();
143
- }
144
- return true;
145
- };
146
-
147
- // We only add the listeners when drawer opens
148
- // This way we can make sure that the listener is added as late as possible
149
- // This will make sure that our handler will run first when back button is pressed
150
- return (0, _addCancelListener.addCancelListener)(handleHardwareBack);
151
- }, [defaultStatus, drawerStatus, drawerType, handleDrawerClose, handleDrawerOpen, navigation]);
152
- const renderDrawerContent = () => {
153
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerPositionContext.DrawerPositionContext.Provider, {
154
- value: drawerPosition,
155
- children: drawerContent({
156
- state: state,
157
- navigation: navigation,
158
- descriptors: descriptors
159
- })
160
- });
161
- };
162
- const renderSceneContent = () => {
163
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ScreenFallback.MaybeScreenContainer, {
164
- enabled: detachInactiveScreens,
165
- hasTwoStates: true,
166
- style: styles.content,
167
- children: state.routes.map((route, index) => {
168
- const descriptor = descriptors[route.key];
169
- const {
170
- lazy = true
171
- } = descriptor.options;
172
- const isFocused = state.index === index;
173
- const isPreloaded = state.preloadedRouteKeys.includes(route.key);
174
- if (lazy && !loaded.includes(route.key) && !isFocused && !isPreloaded) {
175
- // Don't render a lazy screen if we've never navigated to it or it wasn't preloaded
176
- return null;
177
- }
178
- const {
179
- freezeOnBlur,
180
- header = ({
181
- layout,
182
- options
183
- }) => /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.Header, {
184
- ...options,
185
- layout: layout,
186
- title: (0, _elements.getHeaderTitle)(options, route.name),
187
- headerLeft: drawerPosition === 'left' && options.headerLeft == null ? props => /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerToggleButton.DrawerToggleButton, {
188
- ...props
189
- }) : options.headerLeft,
190
- headerRight: drawerPosition === 'right' && options.headerRight == null ? props => /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerToggleButton.DrawerToggleButton, {
191
- ...props
192
- }) : options.headerRight
193
- }),
194
- headerShown,
195
- headerStatusBarHeight,
196
- headerTransparent,
197
- sceneStyle
198
- } = descriptor.options;
199
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_ScreenFallback.MaybeScreen, {
200
- style: [_reactNative.StyleSheet.absoluteFill, {
201
- zIndex: isFocused ? 0 : -1
202
- }],
203
- visible: isFocused,
204
- enabled: detachInactiveScreens,
205
- freezeOnBlur: freezeOnBlur,
206
- shouldFreeze: !isFocused && !isPreloaded,
207
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.Screen, {
208
- focused: isFocused,
209
- route: descriptor.route,
210
- navigation: descriptor.navigation,
211
- headerShown: headerShown,
212
- headerStatusBarHeight: headerStatusBarHeight,
213
- headerTransparent: headerTransparent,
214
- header: header({
215
- layout: dimensions,
216
- route: descriptor.route,
217
- navigation: descriptor.navigation,
218
- options: descriptor.options
219
- }),
220
- style: sceneStyle,
221
- children: descriptor.render()
222
- })
223
- }, route.key);
224
- })
225
- });
226
- };
227
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_DrawerStatusContext.DrawerStatusContext.Provider, {
228
- value: drawerStatus,
229
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNativeDrawerLayout.Drawer, {
230
- open: drawerStatus !== 'closed',
231
- onOpen: handleDrawerOpen,
232
- onClose: handleDrawerClose,
233
- onGestureStart: handleGestureStart,
234
- onGestureEnd: handleGestureEnd,
235
- onGestureCancel: handleGestureCancel,
236
- onTransitionStart: handleTransitionStart,
237
- onTransitionEnd: handleTransitionEnd,
238
- layout: dimensions,
239
- direction: direction,
240
- configureGestureHandler: configureGestureHandler,
241
- swipeEnabled: swipeEnabled,
242
- swipeEdgeWidth: swipeEdgeWidth,
243
- swipeMinDistance: swipeMinDistance,
244
- hideStatusBarOnOpen: drawerHideStatusBarOnOpen,
245
- statusBarAnimation: drawerStatusBarAnimation,
246
- keyboardDismissMode: keyboardDismissMode,
247
- drawerType: drawerType,
248
- overlayAccessibilityLabel: overlayAccessibilityLabel,
249
- drawerPosition: drawerPosition,
250
- drawerStyle: [{
251
- backgroundColor: colors.card,
252
- width: (0, _elements.getDefaultSidebarWidth)(dimensions)
253
- }, drawerType === 'permanent' && ((_reactNative.Platform.OS === 'web' ? drawerPosition === 'right' : direction === 'rtl' && drawerPosition !== 'right' || direction !== 'rtl' && drawerPosition === 'right') ? {
254
- borderLeftColor: colors.border,
255
- borderLeftWidth: _reactNative.StyleSheet.hairlineWidth
256
- } : {
257
- borderRightColor: colors.border,
258
- borderRightWidth: _reactNative.StyleSheet.hairlineWidth
259
- }), drawerType === 'front' && (drawerPosition === 'left' ? {
260
- borderTopRightRadius: DRAWER_BORDER_RADIUS,
261
- borderBottomRightRadius: DRAWER_BORDER_RADIUS
262
- } : {
263
- borderTopLeftRadius: DRAWER_BORDER_RADIUS,
264
- borderBottomLeftRadius: DRAWER_BORDER_RADIUS
265
- }), drawerStyle],
266
- overlayStyle: {
267
- backgroundColor: overlayColor
268
- },
269
- renderDrawerContent: renderDrawerContent,
270
- children: renderSceneContent()
271
- })
272
- });
273
- }
274
- function DrawerView({
275
- navigation,
276
- ...rest
277
- }) {
278
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.SafeAreaProviderCompat, {
279
- children: /*#__PURE__*/(0, _jsxRuntime.jsx)(DrawerViewBase, {
280
- navigation: navigation,
281
- ...rest
282
- })
283
- });
284
- }
285
- const styles = _reactNative.StyleSheet.create({
286
- content: {
287
- flex: 1
288
- }
289
- });
290
- //# sourceMappingURL=DrawerView.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_elements","require","_native","React","_interopRequireWildcard","_reactNative","_reactNativeDrawerLayout","_reactNativeSafeAreaContext","_useLatestCallback","_interopRequireDefault","_addCancelListener","_DrawerPositionContext","_DrawerStatusContext","_getDrawerStatusFromState","_DrawerContent","_DrawerToggleButton","_ScreenFallback","_jsxRuntime","e","__esModule","default","_getRequireWildcardCache","WeakMap","r","t","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","DRAWER_BORDER_RADIUS","renderDrawerContentDefault","props","jsx","DrawerContent","DrawerViewBase","state","navigation","descriptors","defaultStatus","drawerContent","detachInactiveScreens","Platform","OS","direction","useLocale","focusedRouteKey","routes","index","key","drawerHideStatusBarOnOpen","drawerPosition","drawerStatusBarAnimation","drawerStyle","drawerType","select","ios","configureGestureHandler","keyboardDismissMode","overlayColor","swipeEdgeWidth","swipeEnabled","swipeMinDistance","overlayAccessibilityLabel","options","loaded","setLoaded","useState","includes","previousRouteKeyRef","useRef","useEffect","previousRouteKey","current","popToTopOnBlur","prevRoute","find","route","type","dispatch","StackActions","popToTop","target","dimensions","useSafeAreaFrame","colors","useTheme","drawerStatus","getDrawerStatusFromState","handleDrawerOpen","useLatestCallback","DrawerActions","openDrawer","handleDrawerClose","closeDrawer","handleGestureStart","emit","handleGestureEnd","handleGestureCancel","handleTransitionStart","closing","data","handleTransitionEnd","handleHardwareBack","isFocused","addCancelListener","renderDrawerContent","DrawerPositionContext","Provider","value","children","renderSceneContent","MaybeScreenContainer","enabled","hasTwoStates","style","styles","content","map","descriptor","lazy","isPreloaded","preloadedRouteKeys","freezeOnBlur","header","layout","Header","title","getHeaderTitle","name","headerLeft","DrawerToggleButton","headerRight","headerShown","headerStatusBarHeight","headerTransparent","sceneStyle","MaybeScreen","StyleSheet","absoluteFill","zIndex","visible","shouldFreeze","Screen","focused","render","DrawerStatusContext","Drawer","open","onOpen","onClose","onGestureStart","onGestureEnd","onGestureCancel","onTransitionStart","onTransitionEnd","hideStatusBarOnOpen","statusBarAnimation","backgroundColor","card","width","getDefaultSidebarWidth","borderLeftColor","border","borderLeftWidth","hairlineWidth","borderRightColor","borderRightWidth","borderTopRightRadius","borderBottomRightRadius","borderTopLeftRadius","borderBottomLeftRadius","overlayStyle","DrawerView","rest","SafeAreaProviderCompat","create","flex"],"sourceRoot":"../../../src","sources":["views/DrawerView.tsx"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAOA,IAAAC,OAAA,GAAAD,OAAA;AASA,IAAAE,KAAA,GAAAC,uBAAA,CAAAH,OAAA;AACA,IAAAI,YAAA,GAAAJ,OAAA;AACA,IAAAK,wBAAA,GAAAL,OAAA;AACA,IAAAM,2BAAA,GAAAN,OAAA;AACA,IAAAO,kBAAA,GAAAC,sBAAA,CAAAR,OAAA;AAUA,IAAAS,kBAAA,GAAAT,OAAA;AACA,IAAAU,sBAAA,GAAAV,OAA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B,EAAE7B,uBAAU,CAAC2B;MAC/B,CAAC,CAAC,EAER/G,UAAU,KAAK,OAAO,KACnBH,cAAc,KAAK,MAAM,GACtB;QACEqH,oBAAoB,EAAE1I,oBAAoB;QAC1C2I,uBAAuB,EAAE3I;MAC3B,CAAC,GACD;QACE4I,mBAAmB,EAAE5I,oBAAoB;QACzC6I,sBAAsB,EAAE7I;MAC1B,CAAC,CAAC,EACRuB,WAAW,CACX;MACFuH,YAAY,EAAE;QAAEd,eAAe,EAAEnG;MAAa,CAAE;MAChD+C,mBAAmB,EAAEA,mBAAoB;MAAAI,QAAA,EAExCC,kBAAkB,CAAC;IAAC,CACf;EAAC,CACmB,CAAC;AAEnC;AAEO,SAAS8D,UAAUA,CAAC;EAAExI,UAAU;EAAE,GAAGyI;AAAY,CAAC,EAAE;EACzD,oBACE,IAAArK,WAAA,CAAAwB,GAAA,EAACzC,SAAA,CAAAuL,sBAAsB;IAAAjE,QAAA,eACrB,IAAArG,WAAA,CAAAwB,GAAA,EAACE,cAAc;MAACE,UAAU,EAAEA,UAAW;MAAA,GAAKyI;IAAI,CAAG;EAAC,CAC9B,CAAC;AAE7B;AAEA,MAAM1D,MAAM,GAAGsB,uBAAU,CAACsC,MAAM,CAAC;EAC/B3D,OAAO,EAAE;IACP4D,IAAI,EAAE;EACR;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,53 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.MaybeScreen = MaybeScreen;
7
- exports.MaybeScreenContainer = void 0;
8
- var _elements = require("@react-navigation/elements");
9
- var React = _interopRequireWildcard(require("react"));
10
- var _reactNative = require("react-native");
11
- var _jsxRuntime = require("react/jsx-runtime");
12
- function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
13
- function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
14
- let Screens;
15
- try {
16
- Screens = require('react-native-screens');
17
- } catch (e) {
18
- // Ignore
19
- }
20
- const MaybeScreenContainer = ({
21
- enabled,
22
- ...rest
23
- }) => {
24
- if (Screens?.screensEnabled?.()) {
25
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(Screens.ScreenContainer, {
26
- enabled: enabled,
27
- ...rest
28
- });
29
- }
30
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
31
- ...rest
32
- });
33
- };
34
- exports.MaybeScreenContainer = MaybeScreenContainer;
35
- function MaybeScreen({
36
- visible,
37
- children,
38
- ...rest
39
- }) {
40
- if (Screens?.screensEnabled?.()) {
41
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(Screens.Screen, {
42
- activityState: visible ? 2 : 0,
43
- ...rest,
44
- children: children
45
- });
46
- }
47
- return /*#__PURE__*/(0, _jsxRuntime.jsx)(_elements.ResourceSavingView, {
48
- visible: visible,
49
- ...rest,
50
- children: children
51
- });
52
- }
53
- //# sourceMappingURL=ScreenFallback.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["_elements","require","React","_interopRequireWildcard","_reactNative","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","Screens","MaybeScreenContainer","enabled","rest","screensEnabled","jsx","ScreenContainer","View","exports","MaybeScreen","visible","children","Screen","activityState","ResourceSavingView"],"sourceRoot":"../../../src","sources":["views/ScreenFallback.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