125 lines
36 KiB
Diff
125 lines
36 KiB
Diff
# HOTFIX - https://github.com/satya164/react-native-tab-view/issues/1104
|
|
|
|
diff --git a/node_modules/react-native-pager-view/lib/commonjs/PagerView.js b/node_modules/react-native-pager-view/lib/commonjs/PagerView.js
|
|
index 40afb41..850c151 100644
|
|
--- a/node_modules/react-native-pager-view/lib/commonjs/PagerView.js
|
|
+++ b/node_modules/react-native-pager-view/lib/commonjs/PagerView.js
|
|
@@ -131,17 +131,20 @@ class PagerView extends _react.default.Component {
|
|
}
|
|
|
|
render() {
|
|
- return /*#__PURE__*/_react.default.createElement(_PagerViewNative.PagerViewViewManager, _extends({}, this.props, {
|
|
- ref: this.PagerView
|
|
- /** TODO: Fix ref type */
|
|
- ,
|
|
+ const {
|
|
+ children,
|
|
+ forwardedRef,
|
|
+ ...rest
|
|
+ } = this.props;
|
|
+ return /*#__PURE__*/_react.default.createElement(_PagerViewNative.PagerViewViewManager, _extends({}, rest, {
|
|
+ // ref={this.PagerView as any /** TODO: Fix ref type */}
|
|
style: this.props.style,
|
|
layoutDirection: this.deducedLayoutDirection,
|
|
onPageScroll: this._onPageScroll,
|
|
onPageScrollStateChanged: this._onPageScrollStateChanged,
|
|
onPageSelected: this._onPageSelected,
|
|
onMoveShouldSetResponderCapture: this._onMoveShouldSetResponderCapture,
|
|
- children: (0, _utils.childrenWithOverriddenStyle)(this.props.children)
|
|
+ children: (0, _utils.childrenWithOverriddenStyle)(children)
|
|
}));
|
|
}
|
|
|
|
diff --git a/node_modules/react-native-pager-view/lib/commonjs/PagerView.js.map b/node_modules/react-native-pager-view/lib/commonjs/PagerView.js.map
|
|
index ce9ff7f..c55d898 100644
|
|
--- a/node_modules/react-native-pager-view/lib/commonjs/PagerView.js.map
|
|
+++ b/node_modules/react-native-pager-view/lib/commonjs/PagerView.js.map
|
|
@@ -1 +1 @@
|
|
-{"version":3,"sources":["PagerView.tsx"],"names":["PagerView","React","Component","createRef","current","getInnerViewNode","e","props","onPageScroll","Platform","OS","keyboardDismissMode","Keyboard","dismiss","onPageScrollStateChanged","isScrolling","nativeEvent","pageScrollState","onPageSelected","selectedPage","UIManager","dispatchViewManagerCommand","ReactNative","findNodeHandle","Commands","setPage","setPageWithoutAnimation","scrollEnabled","setScrollEnabled","deducedLayoutDirection","shouldUseDeviceRtlSetup","layoutDirection","I18nManager","isRTL","render","style","_onPageScroll","_onPageScrollStateChanged","_onPageSelected","_onMoveShouldSetResponderCapture","children"],"mappings":";;;;;;;AAAA;;AACA;;AASA;;AACA;;;;;;;;;;;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEO,MAAMA,SAAN,SAAwBC,eAAMC,SAA9B,CAAwD;AAAA;AAAA;;AAAA,yCACvC,KADuC;;AAAA,oDAEzCD,eAAME,SAAN,EAFyC;;AAAA,8CAInC,MAAoB;AAC5C,aAAO,KAAKH,SAAL,CAAeI,OAAf,CAAwBC,gBAAxB,EAAP;AACD,KAN4D;;AAAA,2CAQpCC,CAAD,IAAmC;AACzD,UAAI,KAAKC,KAAL,CAAWC,YAAf,EAA6B;AAC3B,aAAKD,KAAL,CAAWC,YAAX,CAAwBF,CAAxB;AACD,OAHwD,CAIzD;;;AACA,UAAIG,sBAASC,EAAT,KAAgB,SAApB,EAA+B;AAC7B,YAAI,KAAKH,KAAL,CAAWI,mBAAX,KAAmC,SAAvC,EAAkD;AAChDC,gCAASC,OAAT;AACD;AACF;AACF,KAlB4D;;AAAA,uDAqB3DP,CADkC,IAE/B;AACH,UAAI,KAAKC,KAAL,CAAWO,wBAAf,EAAyC;AACvC,aAAKP,KAAL,CAAWO,wBAAX,CAAoCR,CAApC;AACD;;AACD,WAAKS,WAAL,GAAmBT,CAAC,CAACU,WAAF,CAAcC,eAAd,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;AAIE,MAAA,eAAe,EAAE,KAAKN,sBAJxB;AAKE,MAAA,YAAY,EAAE,KAAKO,aALrB;AAME,MAAA,wBAAwB,EAAE,KAAKC,yBANjC;AAOE,MAAA,cAAc,EAAE,KAAKC,eAPvB;AAQE,MAAA,+BAA+B,EAAE,KAAKC,gCARxC;AASE,MAAA,QAAQ,EAAE,wCAA4B,KAAKhC,KAAL,CAAWiC,QAAvC;AATZ,OADF;AAaD;;AArG4D","sourcesContent":["import React, { ReactElement } from 'react';\nimport { Platform, UIManager, Keyboard } from 'react-native';\nimport ReactNative, { I18nManager } from 'react-native';\nimport type {\n PagerViewOnPageScrollEvent,\n PagerViewOnPageSelectedEvent,\n PageScrollStateChangedNativeEvent,\n PagerViewProps,\n} from './types';\n\nimport { childrenWithOverriddenStyle } from './utils';\nimport { getViewManagerConfig, PagerViewViewManager } from './PagerViewNative';\n\n/**\n * Container that allows to flip left and right between child views. Each\n * child view of the `PagerView` will be treated as a separate page\n * and will be stretched to fill the `PagerView`.\n *\n * It is important all children are `<View>`s and not composite components.\n * You can set style properties like `padding` or `backgroundColor` for each\n * child. It is also important that each child have a `key` prop.\n *\n * Example:\n *\n * ```\n * render: function() {\n * return (\n * <PagerView\n * style={styles.PagerView}\n * initialPage={0}>\n * <View style={styles.pageStyle} key=\"1\">\n * <Text>First page</Text>\n * </View>\n * <View style={styles.pageStyle} key=\"2\">\n * <Text>Second page</Text>\n * </View>\n * </PagerView>\n * );\n * }\n *\n * ...\n *\n * var styles = {\n * ...\n * PagerView: {\n * flex: 1\n * },\n * pageStyle: {\n * alignItems: 'center',\n * padding: 20,\n * }\n * }\n * ```\n */\n\nexport class PagerView extends React.Component<PagerViewProps> {\n private isScrolling = false;\n private PagerView = React.createRef<typeof PagerViewViewManager>();\n\n public getInnerViewNode = (): ReactElement => {\n return this.PagerView.current!.getInnerViewNode();\n };\n\n private _onPageScroll = (e: PagerViewOnPageScrollEvent) => {\n if (this.props.onPageScroll) {\n this.props.onPageScroll(e);\n }\n // Not implemented on iOS yet\n if (Platform.OS === 'android') {\n if (this.props.keyboardDismissMode === 'on-drag') {\n Keyboard.dismiss();\n }\n }\n };\n\n private _onPageScrollStateChanged = (\n e: PageScrollStateChangedNativeEvent\n ) => {\n if (this.props.onPageScrollStateChanged) {\n this.props.onPageScrollStateChanged(e);\n }\n this.isScrolling = e.nativeEvent.pageScrollState === 'dragging';\n };\n\n private _onPageSelected = (e: PagerViewOnPageSelectedEvent) => {\n if (this.props.onPageSelected) {\n this.props.onPageSelected(e);\n }\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will be animated.\n */\n public setPage = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPage,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will *not* be animated.\n */\n public setPageWithoutAnimation = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPageWithoutAnimation,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to enable/disable scroll imperatively\n * The recommended way is using the scrollEnabled prop, however, there might be a case where a\n * imperative solution is more useful (e.g. for not blocking an animation)\n */\n public setScrollEnabled = (scrollEnabled: boolean) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setScrollEnabled,\n [scrollEnabled]\n );\n };\n\n private _onMoveShouldSetResponderCapture = () => {\n return this.isScrolling;\n };\n\n private get deducedLayoutDirection() {\n const shouldUseDeviceRtlSetup =\n !this.props.layoutDirection || this.props.layoutDirection === 'locale';\n\n if (shouldUseDeviceRtlSetup) {\n return I18nManager.isRTL ? 'rtl' : 'ltr';\n } else {\n return this.props.layoutDirection;\n }\n }\n\n render() {\n return (\n <PagerViewViewManager\n {...this.props}\n ref={this.PagerView as any /** TODO: Fix ref type */}\n style={this.props.style}\n layoutDirection={this.deducedLayoutDirection}\n onPageScroll={this._onPageScroll}\n onPageScrollStateChanged={this._onPageScrollStateChanged}\n onPageSelected={this._onPageSelected}\n onMoveShouldSetResponderCapture={this._onMoveShouldSetResponderCapture}\n children={childrenWithOverriddenStyle(this.props.children)}\n />\n );\n }\n}\n"]}
|
|
\ No newline at end of file
|
|
+{"version":3,"sources":["PagerView.tsx"],"names":["PagerView","React","Component","createRef","current","getInnerViewNode","e","props","onPageScroll","Platform","OS","keyboardDismissMode","Keyboard","dismiss","onPageScrollStateChanged","isScrolling","nativeEvent","pageScrollState","onPageSelected","selectedPage","UIManager","dispatchViewManagerCommand","ReactNative","findNodeHandle","Commands","setPage","setPageWithoutAnimation","scrollEnabled","setScrollEnabled","deducedLayoutDirection","shouldUseDeviceRtlSetup","layoutDirection","I18nManager","isRTL","render","children","forwardedRef","rest","style","_onPageScroll","_onPageScrollStateChanged","_onPageSelected","_onMoveShouldSetResponderCapture"],"mappings":";;;;;;;AAAA;;AACA;;AASA;;AACA;;;;;;;;;;;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAEO,MAAMA,SAAN,SAAwBC,eAAMC,SAA9B,CAAgF;AAAA;AAAA;;AAAA,yCAC/D,KAD+D;;AAAA,oDAEjED,eAAME,SAAN,EAFiE;;AAAA,8CAI3D,MAAoB;AAC5C,aAAO,KAAKH,SAAL,CAAeI,OAAf,CAAwBC,gBAAxB,EAAP;AACD,KANoF;;AAAA,2CAQ5DC,CAAD,IAAmC;AACzD,UAAI,KAAKC,KAAL,CAAWC,YAAf,EAA6B;AAC3B,aAAKD,KAAL,CAAWC,YAAX,CAAwBF,CAAxB;AACD,OAHwD,CAIzD;;;AACA,UAAIG,sBAASC,EAAT,KAAgB,SAApB,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,EAA6B;AAC3B,aAAOE,yBAAYC,KAAZ,GAAoB,KAApB,GAA4B,KAAnC;AACD,KAFD,MAEO;AACL,aAAO,KAAK1B,KAAL,CAAWwB,eAAlB;AACD;AACF;;AAEDG,EAAAA,MAAM,GAAG;AACP,UAAM;AAAEC,MAAAA,QAAF;AAAYC,MAAAA,YAAZ;AAA0B,SAAGC;AAA7B,QAAsC,KAAK9B,KAAjD;AAEA,wBACE,6BAAC,qCAAD,eACM8B,IADN;AAEE;AACA,MAAA,KAAK,EAAE,KAAK9B,KAAL,CAAW+B,KAHpB;AAIE,MAAA,eAAe,EAAE,KAAKT,sBAJxB;AAKE,MAAA,YAAY,EAAE,KAAKU,aALrB;AAME,MAAA,wBAAwB,EAAE,KAAKC,yBANjC;AAOE,MAAA,cAAc,EAAE,KAAKC,eAPvB;AAQE,MAAA,+BAA+B,EAAE,KAAKC,gCARxC;AASE,MAAA,QAAQ,EAAE,wCAA4BP,QAA5B;AATZ,OADF;AAaD;;AAvGoF","sourcesContent":["import React, { ReactElement } from 'react';\nimport { Platform, UIManager, Keyboard } from 'react-native';\nimport ReactNative, { I18nManager } from 'react-native';\nimport type {\n PagerViewOnPageScrollEvent,\n PagerViewOnPageSelectedEvent,\n PageScrollStateChangedNativeEvent,\n PagerViewProps,\n} from './types';\n\nimport { childrenWithOverriddenStyle } from './utils';\nimport { getViewManagerConfig, PagerViewViewManager } from './PagerViewNative';\n\n/**\n * Container that allows to flip left and right between child views. Each\n * child view of the `PagerView` will be treated as a separate page\n * and will be stretched to fill the `PagerView`.\n *\n * It is important all children are `<View>`s and not composite components.\n * You can set style properties like `padding` or `backgroundColor` for each\n * child. It is also important that each child have a `key` prop.\n *\n * Example:\n *\n * ```\n * render: function() {\n * return (\n * <PagerView\n * style={styles.PagerView}\n * initialPage={0}>\n * <View style={styles.pageStyle} key=\"1\">\n * <Text>First page</Text>\n * </View>\n * <View style={styles.pageStyle} key=\"2\">\n * <Text>Second page</Text>\n * </View>\n * </PagerView>\n * );\n * }\n *\n * ...\n *\n * var styles = {\n * ...\n * PagerView: {\n * flex: 1\n * },\n * pageStyle: {\n * alignItems: 'center',\n * padding: 20,\n * }\n * }\n * ```\n */\n\nexport class PagerView extends React.Component<PagerViewProps, { forwardedRef?: any }> {\n private isScrolling = false;\n private PagerView = React.createRef<typeof PagerViewViewManager>();\n\n public getInnerViewNode = (): ReactElement => {\n return this.PagerView.current!.getInnerViewNode();\n };\n\n private _onPageScroll = (e: PagerViewOnPageScrollEvent) => {\n if (this.props.onPageScroll) {\n this.props.onPageScroll(e);\n }\n // Not implemented on iOS yet\n if (Platform.OS === 'android') {\n if (this.props.keyboardDismissMode === 'on-drag') {\n Keyboard.dismiss();\n }\n }\n };\n\n private _onPageScrollStateChanged = (\n e: PageScrollStateChangedNativeEvent\n ) => {\n if (this.props.onPageScrollStateChanged) {\n this.props.onPageScrollStateChanged(e);\n }\n this.isScrolling = e.nativeEvent.pageScrollState === 'dragging';\n };\n\n private _onPageSelected = (e: PagerViewOnPageSelectedEvent) => {\n if (this.props.onPageSelected) {\n this.props.onPageSelected(e);\n }\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will be animated.\n */\n public setPage = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPage,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will *not* be animated.\n */\n public setPageWithoutAnimation = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPageWithoutAnimation,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to enable/disable scroll imperatively\n * The recommended way is using the scrollEnabled prop, however, there might be a case where a\n * imperative solution is more useful (e.g. for not blocking an animation)\n */\n public setScrollEnabled = (scrollEnabled: boolean) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setScrollEnabled,\n [scrollEnabled]\n );\n };\n\n private _onMoveShouldSetResponderCapture = () => {\n return this.isScrolling;\n };\n\n private get deducedLayoutDirection() {\n const shouldUseDeviceRtlSetup =\n !this.props.layoutDirection || this.props.layoutDirection === 'locale';\n\n if (shouldUseDeviceRtlSetup) {\n return I18nManager.isRTL ? 'rtl' : 'ltr';\n } else {\n return this.props.layoutDirection;\n }\n }\n\n render() {\n const { children, forwardedRef, ...rest } = this.props;\n\n return (\n <PagerViewViewManager\n {...rest}\n // ref={this.PagerView as any /** TODO: Fix ref type */}\n style={this.props.style}\n layoutDirection={this.deducedLayoutDirection}\n onPageScroll={this._onPageScroll}\n onPageScrollStateChanged={this._onPageScrollStateChanged}\n onPageSelected={this._onPageSelected}\n onMoveShouldSetResponderCapture={this._onMoveShouldSetResponderCapture}\n children={childrenWithOverriddenStyle(children)}\n />\n );\n }\n}\n"]}
|
|
\ No newline at end of file
|
|
diff --git a/node_modules/react-native-pager-view/lib/module/PagerView.js b/node_modules/react-native-pager-view/lib/module/PagerView.js
|
|
index dc1ddc5..f95b242 100644
|
|
--- a/node_modules/react-native-pager-view/lib/module/PagerView.js
|
|
+++ b/node_modules/react-native-pager-view/lib/module/PagerView.js
|
|
@@ -116,17 +116,20 @@ export class PagerView extends React.Component {
|
|
}
|
|
|
|
render() {
|
|
- return /*#__PURE__*/React.createElement(PagerViewViewManager, _extends({}, this.props, {
|
|
- ref: this.PagerView
|
|
- /** TODO: Fix ref type */
|
|
- ,
|
|
+ const {
|
|
+ children,
|
|
+ forwardedRef,
|
|
+ ...rest
|
|
+ } = this.props;
|
|
+ return /*#__PURE__*/React.createElement(PagerViewViewManager, _extends({}, rest, {
|
|
+ // ref={this.PagerView as any /** TODO: Fix ref type */}
|
|
style: this.props.style,
|
|
layoutDirection: this.deducedLayoutDirection,
|
|
onPageScroll: this._onPageScroll,
|
|
onPageScrollStateChanged: this._onPageScrollStateChanged,
|
|
onPageSelected: this._onPageSelected,
|
|
onMoveShouldSetResponderCapture: this._onMoveShouldSetResponderCapture,
|
|
- children: childrenWithOverriddenStyle(this.props.children)
|
|
+ children: childrenWithOverriddenStyle(children)
|
|
}));
|
|
}
|
|
|
|
diff --git a/node_modules/react-native-pager-view/lib/module/PagerView.js.map b/node_modules/react-native-pager-view/lib/module/PagerView.js.map
|
|
index 6c26c01..ea08ccc 100644
|
|
--- a/node_modules/react-native-pager-view/lib/module/PagerView.js.map
|
|
+++ b/node_modules/react-native-pager-view/lib/module/PagerView.js.map
|
|
@@ -1 +1 @@
|
|
-{"version":3,"sources":["PagerView.tsx"],"names":["React","Platform","UIManager","Keyboard","ReactNative","I18nManager","childrenWithOverriddenStyle","getViewManagerConfig","PagerViewViewManager","PagerView","Component","createRef","current","getInnerViewNode","e","props","onPageScroll","OS","keyboardDismissMode","dismiss","onPageScrollStateChanged","isScrolling","nativeEvent","pageScrollState","onPageSelected","selectedPage","dispatchViewManagerCommand","findNodeHandle","Commands","setPage","setPageWithoutAnimation","scrollEnabled","setScrollEnabled","deducedLayoutDirection","shouldUseDeviceRtlSetup","layoutDirection","isRTL","render","style","_onPageScroll","_onPageScrollStateChanged","_onPageSelected","_onMoveShouldSetResponderCapture","children"],"mappings":";;;;AAAA,OAAOA,KAAP,MAAoC,OAApC;AACA,SAASC,QAAT,EAAmBC,SAAnB,EAA8BC,QAA9B,QAA8C,cAA9C;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,cAAzC;AAQA,SAASC,2BAAT,QAA4C,SAA5C;AACA,SAASC,oBAAT,EAA+BC,oBAA/B,QAA2D,mBAA3D;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMC,SAAN,SAAwBT,KAAK,CAACU,SAA9B,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CAACL,YAAD,CAHF;AAKD,KAzD4D;;AAAA,8CAgElCM,aAAD,IAA4B;AACpD7B,MAAAA,SAAS,CAACwB,0BAAV,CACEtB,WAAW,CAACuB,cAAZ,CAA2B,IAA3B,CADF,EAEEpB,oBAAoB,GAAGqB,QAAvB,CAAgCI,gBAFlC,EAGE,CAACD,aAAD,CAHF;AAKD,KAtE4D;;AAAA,8DAwElB,MAAM;AAC/C,aAAO,KAAKV,WAAZ;AACD,KA1E4D;AAAA;;AA4E3B,MAAtBY,sBAAsB,GAAG;AACnC,UAAMC,uBAAuB,GAC3B,CAAC,KAAKnB,KAAL,CAAWoB,eAAZ,IAA+B,KAAKpB,KAAL,CAAWoB,eAAX,KAA+B,QADhE;;AAGA,QAAID,uBAAJ,EAA6B;AAC3B,aAAO7B,WAAW,CAAC+B,KAAZ,GAAoB,KAApB,GAA4B,KAAnC;AACD,KAFD,MAEO;AACL,aAAO,KAAKrB,KAAL,CAAWoB,eAAlB;AACD;AACF;;AAEDE,EAAAA,MAAM,GAAG;AACP,wBACE,oBAAC,oBAAD,eACM,KAAKtB,KADX;AAEE,MAAA,GAAG,EAAE,KAAKN;AAAiB;AAF7B;AAGE,MAAA,KAAK,EAAE,KAAKM,KAAL,CAAWuB,KAHpB;AAIE,MAAA,eAAe,EAAE,KAAKL,sBAJxB;AAKE,MAAA,YAAY,EAAE,KAAKM,aALrB;AAME,MAAA,wBAAwB,EAAE,KAAKC,yBANjC;AAOE,MAAA,cAAc,EAAE,KAAKC,eAPvB;AAQE,MAAA,+BAA+B,EAAE,KAAKC,gCARxC;AASE,MAAA,QAAQ,EAAEpC,2BAA2B,CAAC,KAAKS,KAAL,CAAW4B,QAAZ;AATvC,OADF;AAaD;;AArG4D","sourcesContent":["import React, { ReactElement } from 'react';\nimport { Platform, UIManager, Keyboard } from 'react-native';\nimport ReactNative, { I18nManager } from 'react-native';\nimport type {\n PagerViewOnPageScrollEvent,\n PagerViewOnPageSelectedEvent,\n PageScrollStateChangedNativeEvent,\n PagerViewProps,\n} from './types';\n\nimport { childrenWithOverriddenStyle } from './utils';\nimport { getViewManagerConfig, PagerViewViewManager } from './PagerViewNative';\n\n/**\n * Container that allows to flip left and right between child views. Each\n * child view of the `PagerView` will be treated as a separate page\n * and will be stretched to fill the `PagerView`.\n *\n * It is important all children are `<View>`s and not composite components.\n * You can set style properties like `padding` or `backgroundColor` for each\n * child. It is also important that each child have a `key` prop.\n *\n * Example:\n *\n * ```\n * render: function() {\n * return (\n * <PagerView\n * style={styles.PagerView}\n * initialPage={0}>\n * <View style={styles.pageStyle} key=\"1\">\n * <Text>First page</Text>\n * </View>\n * <View style={styles.pageStyle} key=\"2\">\n * <Text>Second page</Text>\n * </View>\n * </PagerView>\n * );\n * }\n *\n * ...\n *\n * var styles = {\n * ...\n * PagerView: {\n * flex: 1\n * },\n * pageStyle: {\n * alignItems: 'center',\n * padding: 20,\n * }\n * }\n * ```\n */\n\nexport class PagerView extends React.Component<PagerViewProps> {\n private isScrolling = false;\n private PagerView = React.createRef<typeof PagerViewViewManager>();\n\n public getInnerViewNode = (): ReactElement => {\n return this.PagerView.current!.getInnerViewNode();\n };\n\n private _onPageScroll = (e: PagerViewOnPageScrollEvent) => {\n if (this.props.onPageScroll) {\n this.props.onPageScroll(e);\n }\n // Not implemented on iOS yet\n if (Platform.OS === 'android') {\n if (this.props.keyboardDismissMode === 'on-drag') {\n Keyboard.dismiss();\n }\n }\n };\n\n private _onPageScrollStateChanged = (\n e: PageScrollStateChangedNativeEvent\n ) => {\n if (this.props.onPageScrollStateChanged) {\n this.props.onPageScrollStateChanged(e);\n }\n this.isScrolling = e.nativeEvent.pageScrollState === 'dragging';\n };\n\n private _onPageSelected = (e: PagerViewOnPageSelectedEvent) => {\n if (this.props.onPageSelected) {\n this.props.onPageSelected(e);\n }\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will be animated.\n */\n public setPage = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPage,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will *not* be animated.\n */\n public setPageWithoutAnimation = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPageWithoutAnimation,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to enable/disable scroll imperatively\n * The recommended way is using the scrollEnabled prop, however, there might be a case where a\n * imperative solution is more useful (e.g. for not blocking an animation)\n */\n public setScrollEnabled = (scrollEnabled: boolean) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setScrollEnabled,\n [scrollEnabled]\n );\n };\n\n private _onMoveShouldSetResponderCapture = () => {\n return this.isScrolling;\n };\n\n private get deducedLayoutDirection() {\n const shouldUseDeviceRtlSetup =\n !this.props.layoutDirection || this.props.layoutDirection === 'locale';\n\n if (shouldUseDeviceRtlSetup) {\n return I18nManager.isRTL ? 'rtl' : 'ltr';\n } else {\n return this.props.layoutDirection;\n }\n }\n\n render() {\n return (\n <PagerViewViewManager\n {...this.props}\n ref={this.PagerView as any /** TODO: Fix ref type */}\n style={this.props.style}\n layoutDirection={this.deducedLayoutDirection}\n onPageScroll={this._onPageScroll}\n onPageScrollStateChanged={this._onPageScrollStateChanged}\n onPageSelected={this._onPageSelected}\n onMoveShouldSetResponderCapture={this._onMoveShouldSetResponderCapture}\n children={childrenWithOverriddenStyle(this.props.children)}\n />\n );\n }\n}\n"]}
|
|
\ No newline at end of file
|
|
+{"version":3,"sources":["PagerView.tsx"],"names":["React","Platform","UIManager","Keyboard","ReactNative","I18nManager","childrenWithOverriddenStyle","getViewManagerConfig","PagerViewViewManager","PagerView","Component","createRef","current","getInnerViewNode","e","props","onPageScroll","OS","keyboardDismissMode","dismiss","onPageScrollStateChanged","isScrolling","nativeEvent","pageScrollState","onPageSelected","selectedPage","dispatchViewManagerCommand","findNodeHandle","Commands","setPage","setPageWithoutAnimation","scrollEnabled","setScrollEnabled","deducedLayoutDirection","shouldUseDeviceRtlSetup","layoutDirection","isRTL","render","children","forwardedRef","rest","style","_onPageScroll","_onPageScrollStateChanged","_onPageSelected","_onMoveShouldSetResponderCapture"],"mappings":";;;;AAAA,OAAOA,KAAP,MAAoC,OAApC;AACA,SAASC,QAAT,EAAmBC,SAAnB,EAA8BC,QAA9B,QAA8C,cAA9C;AACA,OAAOC,WAAP,IAAsBC,WAAtB,QAAyC,cAAzC;AAQA,SAASC,2BAAT,QAA4C,SAA5C;AACA,SAASC,oBAAT,EAA+BC,oBAA/B,QAA2D,mBAA3D;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMC,SAAN,SAAwBT,KAAK,CAACU,SAA9B,CAAgF;AAAA;AAAA;;AAAA,yCAC/D,KAD+D;;AAAA,oDAEjEV,KAAK,CAACW,SAAN,EAFiE;;AAAA,8CAI3D,MAAoB;AAC5C,aAAO,KAAKF,SAAL,CAAeG,OAAf,CAAwBC,gBAAxB,EAAP;AACD,KANoF;;AAAA,2CAQ5DC,CAAD,IAAmC;AACzD,UAAI,KAAKC,KAAL,CAAWC,YAAf,EAA6B;AAC3B,aAAKD,KAAL,CAAWC,YAAX,CAAwBF,CAAxB;AACD,OAHwD,CAIzD;;;AACA,UAAIb,QAAQ,CAACgB,EAAT,KAAgB,SAApB,EAA+B;AAC7B,YAAI,KAAKF,KAAL,CAAWG,mBAAX,KAAmC,SAAvC,EAAkD;AAChDf,UAAAA,QAAQ,CAACgB,OAAT;AACD;AACF;AACF,KAlBoF;;AAAA,uDAqBnFL,CADkC,IAE/B;AACH,UAAI,KAAKC,KAAL,CAAWK,wB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ACL,aAAO,KAAKrB,KAAL,CAAWoB,eAAlB;AACD;AACF;;AAEDE,EAAAA,MAAM,GAAG;AACP,UAAM;AAAEC,MAAAA,QAAF;AAAYC,MAAAA,YAAZ;AAA0B,SAAGC;AAA7B,QAAsC,KAAKzB,KAAjD;AAEA,wBACE,oBAAC,oBAAD,eACMyB,IADN;AAEE;AACA,MAAA,KAAK,EAAE,KAAKzB,KAAL,CAAW0B,KAHpB;AAIE,MAAA,eAAe,EAAE,KAAKR,sBAJxB;AAKE,MAAA,YAAY,EAAE,KAAKS,aALrB;AAME,MAAA,wBAAwB,EAAE,KAAKC,yBANjC;AAOE,MAAA,cAAc,EAAE,KAAKC,eAPvB;AAQE,MAAA,+BAA+B,EAAE,KAAKC,gCARxC;AASE,MAAA,QAAQ,EAAEvC,2BAA2B,CAACgC,QAAD;AATvC,OADF;AAaD;;AAvGoF","sourcesContent":["import React, { ReactElement } from 'react';\nimport { Platform, UIManager, Keyboard } from 'react-native';\nimport ReactNative, { I18nManager } from 'react-native';\nimport type {\n PagerViewOnPageScrollEvent,\n PagerViewOnPageSelectedEvent,\n PageScrollStateChangedNativeEvent,\n PagerViewProps,\n} from './types';\n\nimport { childrenWithOverriddenStyle } from './utils';\nimport { getViewManagerConfig, PagerViewViewManager } from './PagerViewNative';\n\n/**\n * Container that allows to flip left and right between child views. Each\n * child view of the `PagerView` will be treated as a separate page\n * and will be stretched to fill the `PagerView`.\n *\n * It is important all children are `<View>`s and not composite components.\n * You can set style properties like `padding` or `backgroundColor` for each\n * child. It is also important that each child have a `key` prop.\n *\n * Example:\n *\n * ```\n * render: function() {\n * return (\n * <PagerView\n * style={styles.PagerView}\n * initialPage={0}>\n * <View style={styles.pageStyle} key=\"1\">\n * <Text>First page</Text>\n * </View>\n * <View style={styles.pageStyle} key=\"2\">\n * <Text>Second page</Text>\n * </View>\n * </PagerView>\n * );\n * }\n *\n * ...\n *\n * var styles = {\n * ...\n * PagerView: {\n * flex: 1\n * },\n * pageStyle: {\n * alignItems: 'center',\n * padding: 20,\n * }\n * }\n * ```\n */\n\nexport class PagerView extends React.Component<PagerViewProps, { forwardedRef?: any }> {\n private isScrolling = false;\n private PagerView = React.createRef<typeof PagerViewViewManager>();\n\n public getInnerViewNode = (): ReactElement => {\n return this.PagerView.current!.getInnerViewNode();\n };\n\n private _onPageScroll = (e: PagerViewOnPageScrollEvent) => {\n if (this.props.onPageScroll) {\n this.props.onPageScroll(e);\n }\n // Not implemented on iOS yet\n if (Platform.OS === 'android') {\n if (this.props.keyboardDismissMode === 'on-drag') {\n Keyboard.dismiss();\n }\n }\n };\n\n private _onPageScrollStateChanged = (\n e: PageScrollStateChangedNativeEvent\n ) => {\n if (this.props.onPageScrollStateChanged) {\n this.props.onPageScrollStateChanged(e);\n }\n this.isScrolling = e.nativeEvent.pageScrollState === 'dragging';\n };\n\n private _onPageSelected = (e: PagerViewOnPageSelectedEvent) => {\n if (this.props.onPageSelected) {\n this.props.onPageSelected(e);\n }\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will be animated.\n */\n public setPage = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPage,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to scroll to a specific page in the PagerView.\n * The transition between pages will *not* be animated.\n */\n public setPageWithoutAnimation = (selectedPage: number) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setPageWithoutAnimation,\n [selectedPage]\n );\n };\n\n /**\n * A helper function to enable/disable scroll imperatively\n * The recommended way is using the scrollEnabled prop, however, there might be a case where a\n * imperative solution is more useful (e.g. for not blocking an animation)\n */\n public setScrollEnabled = (scrollEnabled: boolean) => {\n UIManager.dispatchViewManagerCommand(\n ReactNative.findNodeHandle(this),\n getViewManagerConfig().Commands.setScrollEnabled,\n [scrollEnabled]\n );\n };\n\n private _onMoveShouldSetResponderCapture = () => {\n return this.isScrolling;\n };\n\n private get deducedLayoutDirection() {\n const shouldUseDeviceRtlSetup =\n !this.props.layoutDirection || this.props.layoutDirection === 'locale';\n\n if (shouldUseDeviceRtlSetup) {\n return I18nManager.isRTL ? 'rtl' : 'ltr';\n } else {\n return this.props.layoutDirection;\n }\n }\n\n render() {\n const { children, forwardedRef, ...rest } = this.props;\n\n return (\n <PagerViewViewManager\n {...rest}\n // ref={this.PagerView as any /** TODO: Fix ref type */}\n style={this.props.style}\n layoutDirection={this.deducedLayoutDirection}\n onPageScroll={this._onPageScroll}\n onPageScrollStateChanged={this._onPageScrollStateChanged}\n onPageSelected={this._onPageSelected}\n onMoveShouldSetResponderCapture={this._onMoveShouldSetResponderCapture}\n children={childrenWithOverriddenStyle(children)}\n />\n );\n }\n}\n"]}
|
|
\ No newline at end of file
|
|
diff --git a/node_modules/react-native-pager-view/lib/typescript/PagerView.d.ts b/node_modules/react-native-pager-view/lib/typescript/PagerView.d.ts
|
|
index f70d3bc..5610963 100644
|
|
--- a/node_modules/react-native-pager-view/lib/typescript/PagerView.d.ts
|
|
+++ b/node_modules/react-native-pager-view/lib/typescript/PagerView.d.ts
|
|
@@ -41,7 +41,9 @@ import type { PagerViewProps } from './types';
|
|
* }
|
|
* ```
|
|
*/
|
|
-export declare class PagerView extends React.Component<PagerViewProps> {
|
|
+export declare class PagerView extends React.Component<PagerViewProps, {
|
|
+ forwardedRef?: any;
|
|
+}> {
|
|
private isScrolling;
|
|
private PagerView;
|
|
getInnerViewNode: () => ReactElement;
|
|
diff --git a/node_modules/react-native-pager-view/lib/typescript/__tests__/index.test.d.ts b/node_modules/react-native-pager-view/lib/typescript/__tests__/index.test.d.ts
|
|
new file mode 100644
|
|
index 0000000..e69de29
|
|
diff --git a/node_modules/react-native-pager-view/src/PagerView.tsx b/node_modules/react-native-pager-view/src/PagerView.tsx
|
|
index f7585d5..ee9843b 100644
|
|
--- a/node_modules/react-native-pager-view/src/PagerView.tsx
|
|
+++ b/node_modules/react-native-pager-view/src/PagerView.tsx
|
|
@@ -141,17 +141,19 @@ export class PagerView extends React.Component<PagerViewProps> {
|
|
}
|
|
|
|
render() {
|
|
+ const {children, forwardedRef, ...rest} = this.props;
|
|
+
|
|
return (
|
|
<PagerViewViewManager
|
|
- {...this.props}
|
|
- ref={this.PagerView as any /** TODO: Fix ref type */}
|
|
+ {...rest}
|
|
+ // ref={this.PagerView as any /** TODO: Fix ref type */}
|
|
style={this.props.style}
|
|
layoutDirection={this.deducedLayoutDirection}
|
|
onPageScroll={this._onPageScroll}
|
|
onPageScrollStateChanged={this._onPageScrollStateChanged}
|
|
onPageSelected={this._onPageSelected}
|
|
onMoveShouldSetResponderCapture={this._onMoveShouldSetResponderCapture}
|
|
- children={childrenWithOverriddenStyle(this.props.children)}
|
|
+ children={childrenWithOverriddenStyle(children)}
|
|
/>
|
|
);
|
|
}
|