-
-
Notifications
You must be signed in to change notification settings - Fork 530
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat!: remove native components from public API (#2412)
## Description This PR removes native components from our API. The motivation is that those shouldn't be available directly, only through our interface. ## Checklist - [x] Ensured that CI passes
- Loading branch information
1 parent
5ff656e
commit d2f7c21
Showing
11 changed files
with
24 additions
and
67 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import { View } from 'react-native'; | ||
|
||
export const NativeScreenContainer = View; | ||
export const NativeScreenNavigationContainer = View; | ||
const ScreenContainer = View; | ||
|
||
export default View; | ||
export default ScreenContainer; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,9 @@ | ||
import React from 'react'; | ||
import { Platform, View, ViewProps } from 'react-native'; | ||
import { ViewProps } from 'react-native'; | ||
import ScreenContentWrapperNativeComponent from '../fabric/ScreenContentWrapperNativeComponent'; | ||
|
||
export const NativeScreenContentWrapper: React.ComponentType<ViewProps> = | ||
Platform.OS !== 'web' ? (ScreenContentWrapperNativeComponent as any) : View; | ||
|
||
function ScreenContentWrapper(props: ViewProps) { | ||
return <NativeScreenContentWrapper collapsable={false} {...props} />; | ||
return <ScreenContentWrapperNativeComponent collapsable={false} {...props} />; | ||
} | ||
|
||
export default ScreenContentWrapper; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import { View } from 'react-native'; | ||
|
||
export const NativeScreenContentWrapper = View; | ||
|
||
const ScreenContentWrapper = View; | ||
|
||
export default ScreenContentWrapper; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,12 @@ | ||
import React from 'react'; | ||
import { Platform, View, ViewProps } from 'react-native'; | ||
import { ViewProps } from 'react-native'; | ||
import ScreenFooterNativeComponent from '../fabric/ScreenFooterNativeComponent'; | ||
|
||
/** | ||
* Unstable API | ||
*/ | ||
export const NativeScreenFooter: React.ComponentType<ViewProps> = | ||
Platform.OS !== 'web' ? (ScreenFooterNativeComponent as any) : View; | ||
|
||
/** | ||
* Unstable API | ||
*/ | ||
function ScreenFooter(props: ViewProps) { | ||
return <NativeScreenFooter {...props} />; | ||
return <ScreenFooterNativeComponent {...props} />; | ||
} | ||
|
||
export default ScreenFooter; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import { View } from 'react-native'; | ||
|
||
export const NativeScreenFooter = View; | ||
|
||
const ScreenFooter = View; | ||
|
||
export default ScreenFooter; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
import { View } from 'react-native'; | ||
|
||
export default View; | ||
const ScreenStack = View; | ||
|
||
export default ScreenStack; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
import { View } from 'react-native'; | ||
|
||
export const NativeSearchBar = View; | ||
export const NativeSearchBarCommands = View; | ||
const SearchBar = View; | ||
|
||
export default View; | ||
export default SearchBar; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters