@sendbird/uikit-react-native-foundation 3.7.6 → 3.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/assets/bundle-icons.js.map +1 -1
- package/lib/commonjs/assets/icon/icon-thread.png +0 -0
- package/lib/commonjs/assets/icon/icon-thread@2x.png +0 -0
- package/lib/commonjs/assets/icon/icon-thread@3x.png +0 -0
- package/lib/commonjs/assets/icon/index.js +1 -2
- package/lib/commonjs/assets/icon/index.js.map +1 -1
- package/lib/commonjs/components/Box/index.js +8 -10
- package/lib/commonjs/components/Box/index.js.map +1 -1
- package/lib/commonjs/components/Divider/index.js +6 -8
- package/lib/commonjs/components/Divider/index.js.map +1 -1
- package/lib/commonjs/components/Icon/index.js +36 -18
- package/lib/commonjs/components/Icon/index.js.map +1 -1
- package/lib/commonjs/components/Image/FastImageInternal.js +1 -2
- package/lib/commonjs/components/Image/FastImageInternal.js.map +1 -1
- package/lib/commonjs/components/Image/Image.fastimage.js +14 -17
- package/lib/commonjs/components/Image/Image.fastimage.js.map +1 -1
- package/lib/commonjs/components/Image/Image.reactnative.js +10 -12
- package/lib/commonjs/components/Image/Image.reactnative.js.map +1 -1
- package/lib/commonjs/components/Image/index.js +1 -2
- package/lib/commonjs/components/Image/index.js.map +1 -1
- package/lib/commonjs/components/ImageWithPlaceholder/index.js +5 -7
- package/lib/commonjs/components/ImageWithPlaceholder/index.js.map +1 -1
- package/lib/commonjs/components/Modal/index.js +28 -37
- package/lib/commonjs/components/Modal/index.js.map +1 -1
- package/lib/commonjs/components/PressBox/index.js +17 -20
- package/lib/commonjs/components/PressBox/index.js.map +1 -1
- package/lib/commonjs/components/ProgressBar/index.js +24 -16
- package/lib/commonjs/components/ProgressBar/index.js.map +1 -1
- package/lib/commonjs/components/RegexText/index.js +11 -14
- package/lib/commonjs/components/RegexText/index.js.map +1 -1
- package/lib/commonjs/components/Switch/index.js +19 -19
- package/lib/commonjs/components/Switch/index.js.map +1 -1
- package/lib/commonjs/components/Text/index.js +46 -29
- package/lib/commonjs/components/Text/index.js.map +1 -1
- package/lib/commonjs/components/TextInput/index.js +38 -18
- package/lib/commonjs/components/TextInput/index.js.map +1 -1
- package/lib/commonjs/components/VideoThumbnail/index.js +11 -13
- package/lib/commonjs/components/VideoThumbnail/index.js.map +1 -1
- package/lib/commonjs/index.js +3 -3
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/styles/HeaderStyleContext.js +8 -10
- package/lib/commonjs/styles/HeaderStyleContext.js.map +1 -1
- package/lib/commonjs/styles/createScaleFactor.js +3 -6
- package/lib/commonjs/styles/createScaleFactor.js.map +1 -1
- package/lib/commonjs/styles/createSelectByColorScheme.js +1 -2
- package/lib/commonjs/styles/createSelectByColorScheme.js.map +1 -1
- package/lib/commonjs/styles/createStyleSheet.js +9 -4
- package/lib/commonjs/styles/createStyleSheet.js.map +1 -1
- package/lib/commonjs/styles/createTypography.js +2 -5
- package/lib/commonjs/styles/createTypography.js.map +1 -1
- package/lib/commonjs/styles/getDefaultHeaderHeight.js +1 -2
- package/lib/commonjs/styles/getDefaultHeaderHeight.js.map +1 -1
- package/lib/commonjs/styles/useHeaderStyle.js +1 -2
- package/lib/commonjs/styles/useHeaderStyle.js.map +1 -1
- package/lib/commonjs/theme/DarkUIKitTheme.js +2 -3
- package/lib/commonjs/theme/DarkUIKitTheme.js.map +1 -1
- package/lib/commonjs/theme/LightUIKitTheme.js +2 -3
- package/lib/commonjs/theme/LightUIKitTheme.js.map +1 -1
- package/lib/commonjs/theme/Palette.js +1 -2
- package/lib/commonjs/theme/Palette.js.map +1 -1
- package/lib/commonjs/theme/UIKitThemeContext.js +2 -3
- package/lib/commonjs/theme/UIKitThemeContext.js.map +1 -1
- package/lib/commonjs/theme/UIKitThemeProvider.js +6 -8
- package/lib/commonjs/theme/UIKitThemeProvider.js.map +1 -1
- package/lib/commonjs/theme/createTheme.js +11 -13
- package/lib/commonjs/theme/createTheme.js.map +1 -1
- package/lib/commonjs/theme/useUIKitTheme.js +2 -3
- package/lib/commonjs/theme/useUIKitTheme.js.map +1 -1
- package/lib/commonjs/types.js.map +1 -1
- package/lib/commonjs/ui/ActionMenu/index.js +17 -17
- package/lib/commonjs/ui/ActionMenu/index.js.map +1 -1
- package/lib/commonjs/ui/Alert/index.js +23 -29
- package/lib/commonjs/ui/Alert/index.js.map +1 -1
- package/lib/commonjs/ui/Avatar/AvatarGroup.js +13 -15
- package/lib/commonjs/ui/Avatar/AvatarGroup.js.map +1 -1
- package/lib/commonjs/ui/Avatar/AvatarIcon.js +8 -10
- package/lib/commonjs/ui/Avatar/AvatarIcon.js.map +1 -1
- package/lib/commonjs/ui/Avatar/AvatarStack.js +13 -15
- package/lib/commonjs/ui/Avatar/AvatarStack.js.map +1 -1
- package/lib/commonjs/ui/Avatar/index.js +14 -17
- package/lib/commonjs/ui/Avatar/index.js.map +1 -1
- package/lib/commonjs/ui/Badge/index.js +10 -12
- package/lib/commonjs/ui/Badge/index.js.map +1 -1
- package/lib/commonjs/ui/BottomSheet/index.js +30 -39
- package/lib/commonjs/ui/BottomSheet/index.js.map +1 -1
- package/lib/commonjs/ui/Button/index.js +19 -23
- package/lib/commonjs/ui/Button/index.js.map +1 -1
- package/lib/commonjs/ui/ChannelFrozenBanner/index.js +8 -10
- package/lib/commonjs/ui/ChannelFrozenBanner/index.js.map +1 -1
- package/lib/commonjs/ui/Dialog/DialogBox.js +6 -8
- package/lib/commonjs/ui/Dialog/DialogBox.js.map +1 -1
- package/lib/commonjs/ui/Dialog/DialogSheet.js +23 -22
- package/lib/commonjs/ui/Dialog/DialogSheet.js.map +1 -1
- package/lib/commonjs/ui/Dialog/index.js +11 -12
- package/lib/commonjs/ui/Dialog/index.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.admin.js +2 -3
- package/lib/commonjs/ui/GroupChannelMessage/Message.admin.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.image.js +2 -3
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.image.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.js +6 -8
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.video.js +2 -3
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.video.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.voice.js +8 -9
- package/lib/commonjs/ui/GroupChannelMessage/Message.file.voice.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.unknown.js +5 -7
- package/lib/commonjs/ui/GroupChannelMessage/Message.unknown.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.user.js +8 -12
- package/lib/commonjs/ui/GroupChannelMessage/Message.user.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/Message.user.og.js +16 -20
- package/lib/commonjs/ui/GroupChannelMessage/Message.user.og.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/MessageBubbleWithText.js +28 -24
- package/lib/commonjs/ui/GroupChannelMessage/MessageBubbleWithText.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/MessageContainer.js +29 -31
- package/lib/commonjs/ui/GroupChannelMessage/MessageContainer.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/MessageOpenGraph.js +38 -43
- package/lib/commonjs/ui/GroupChannelMessage/MessageOpenGraph.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelMessage/index.js +2 -3
- package/lib/commonjs/ui/GroupChannelMessage/index.js.map +1 -1
- package/lib/commonjs/ui/GroupChannelPreview/index.js +55 -61
- package/lib/commonjs/ui/GroupChannelPreview/index.js.map +1 -1
- package/lib/commonjs/ui/Header/index.js +45 -56
- package/lib/commonjs/ui/Header/index.js.map +1 -1
- package/lib/commonjs/ui/LoadingSpinner/index.js +14 -18
- package/lib/commonjs/ui/LoadingSpinner/index.js.map +1 -1
- package/lib/commonjs/ui/MenuBar/index.js +23 -21
- package/lib/commonjs/ui/MenuBar/index.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.admin.js +2 -3
- package/lib/commonjs/ui/OpenChannelMessage/Message.admin.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.image.js +2 -3
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.image.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.js +6 -8
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.video.js +2 -3
- package/lib/commonjs/ui/OpenChannelMessage/Message.file.video.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.unknown.js +6 -8
- package/lib/commonjs/ui/OpenChannelMessage/Message.unknown.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.user.js +28 -20
- package/lib/commonjs/ui/OpenChannelMessage/Message.user.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/Message.user.og.js +54 -49
- package/lib/commonjs/ui/OpenChannelMessage/Message.user.og.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/MessageContainer.js +16 -19
- package/lib/commonjs/ui/OpenChannelMessage/MessageContainer.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelMessage/index.js +2 -3
- package/lib/commonjs/ui/OpenChannelMessage/index.js.map +1 -1
- package/lib/commonjs/ui/OpenChannelPreview/index.js +25 -30
- package/lib/commonjs/ui/OpenChannelPreview/index.js.map +1 -1
- package/lib/commonjs/ui/OutlinedButton/index.js +7 -9
- package/lib/commonjs/ui/OutlinedButton/index.js.map +1 -1
- package/lib/commonjs/ui/Placeholder/index.js +9 -11
- package/lib/commonjs/ui/Placeholder/index.js.map +1 -1
- package/lib/commonjs/ui/ProfileCard/index.js +11 -12
- package/lib/commonjs/ui/ProfileCard/index.js.map +1 -1
- package/lib/commonjs/ui/Prompt/index.js +30 -37
- package/lib/commonjs/ui/Prompt/index.js.map +1 -1
- package/lib/commonjs/ui/Toast/index.js +21 -27
- package/lib/commonjs/ui/Toast/index.js.map +1 -1
- package/lib/commonjs/ui/TypingIndicatorBubble/index.js +25 -32
- package/lib/commonjs/ui/TypingIndicatorBubble/index.js.map +1 -1
- package/lib/module/assets/bundle-icons.js.map +1 -1
- package/lib/module/assets/icon/icon-thread.png +0 -0
- package/lib/module/assets/icon/icon-thread@2x.png +0 -0
- package/lib/module/assets/icon/icon-thread@3x.png +0 -0
- package/lib/module/assets/icon/index.js.map +1 -1
- package/lib/module/components/Box/index.js +6 -7
- package/lib/module/components/Box/index.js.map +1 -1
- package/lib/module/components/Divider/index.js +4 -5
- package/lib/module/components/Divider/index.js.map +1 -1
- package/lib/module/components/Icon/index.js +35 -16
- package/lib/module/components/Icon/index.js.map +1 -1
- package/lib/module/components/Image/FastImageInternal.js.map +1 -1
- package/lib/module/components/Image/Image.fastimage.js +12 -14
- package/lib/module/components/Image/Image.fastimage.js.map +1 -1
- package/lib/module/components/Image/Image.reactnative.js +8 -9
- package/lib/module/components/Image/Image.reactnative.js.map +1 -1
- package/lib/module/components/Image/index.js.map +1 -1
- package/lib/module/components/ImageWithPlaceholder/index.js +1 -2
- package/lib/module/components/ImageWithPlaceholder/index.js.map +1 -1
- package/lib/module/components/Modal/index.js +24 -32
- package/lib/module/components/Modal/index.js.map +1 -1
- package/lib/module/components/PressBox/index.js +10 -12
- package/lib/module/components/PressBox/index.js.map +1 -1
- package/lib/module/components/ProgressBar/index.js +21 -12
- package/lib/module/components/ProgressBar/index.js.map +1 -1
- package/lib/module/components/RegexText/index.js +9 -11
- package/lib/module/components/RegexText/index.js.map +1 -1
- package/lib/module/components/Switch/index.js +16 -15
- package/lib/module/components/Switch/index.js.map +1 -1
- package/lib/module/components/Text/index.js +45 -27
- package/lib/module/components/Text/index.js.map +1 -1
- package/lib/module/components/TextInput/index.js +37 -16
- package/lib/module/components/TextInput/index.js.map +1 -1
- package/lib/module/components/VideoThumbnail/index.js +8 -10
- package/lib/module/components/VideoThumbnail/index.js.map +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/styles/HeaderStyleContext.js +6 -7
- package/lib/module/styles/HeaderStyleContext.js.map +1 -1
- package/lib/module/styles/createScaleFactor.js +1 -2
- package/lib/module/styles/createScaleFactor.js.map +1 -1
- package/lib/module/styles/createSelectByColorScheme.js.map +1 -1
- package/lib/module/styles/createStyleSheet.js +8 -2
- package/lib/module/styles/createStyleSheet.js.map +1 -1
- package/lib/module/styles/createTypography.js +1 -3
- package/lib/module/styles/createTypography.js.map +1 -1
- package/lib/module/styles/getDefaultHeaderHeight.js.map +1 -1
- package/lib/module/styles/useHeaderStyle.js.map +1 -1
- package/lib/module/theme/DarkUIKitTheme.js.map +1 -1
- package/lib/module/theme/LightUIKitTheme.js.map +1 -1
- package/lib/module/theme/Palette.js.map +1 -1
- package/lib/module/theme/UIKitThemeContext.js.map +1 -1
- package/lib/module/theme/UIKitThemeProvider.js +4 -5
- package/lib/module/theme/UIKitThemeProvider.js.map +1 -1
- package/lib/module/theme/createTheme.js +9 -10
- package/lib/module/theme/createTheme.js.map +1 -1
- package/lib/module/theme/useUIKitTheme.js.map +1 -1
- package/lib/module/types.js.map +1 -1
- package/lib/module/ui/ActionMenu/index.js +13 -12
- package/lib/module/ui/ActionMenu/index.js.map +1 -1
- package/lib/module/ui/Alert/index.js +21 -26
- package/lib/module/ui/Alert/index.js.map +1 -1
- package/lib/module/ui/Avatar/AvatarGroup.js +11 -12
- package/lib/module/ui/Avatar/AvatarGroup.js.map +1 -1
- package/lib/module/ui/Avatar/AvatarIcon.js +6 -7
- package/lib/module/ui/Avatar/AvatarIcon.js.map +1 -1
- package/lib/module/ui/Avatar/AvatarStack.js +11 -12
- package/lib/module/ui/Avatar/AvatarStack.js.map +1 -1
- package/lib/module/ui/Avatar/index.js +10 -12
- package/lib/module/ui/Avatar/index.js.map +1 -1
- package/lib/module/ui/Badge/index.js +8 -9
- package/lib/module/ui/Badge/index.js.map +1 -1
- package/lib/module/ui/BottomSheet/index.js +28 -36
- package/lib/module/ui/BottomSheet/index.js.map +1 -1
- package/lib/module/ui/Button/index.js +17 -20
- package/lib/module/ui/Button/index.js.map +1 -1
- package/lib/module/ui/ChannelFrozenBanner/index.js +6 -7
- package/lib/module/ui/ChannelFrozenBanner/index.js.map +1 -1
- package/lib/module/ui/Dialog/DialogBox.js +4 -5
- package/lib/module/ui/Dialog/DialogBox.js.map +1 -1
- package/lib/module/ui/Dialog/DialogSheet.js +21 -19
- package/lib/module/ui/Dialog/DialogSheet.js.map +1 -1
- package/lib/module/ui/Dialog/index.js +8 -9
- package/lib/module/ui/Dialog/index.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.admin.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.file.image.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.file.js +4 -5
- package/lib/module/ui/GroupChannelMessage/Message.file.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.file.video.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.file.voice.js +4 -4
- package/lib/module/ui/GroupChannelMessage/Message.file.voice.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.unknown.js +3 -4
- package/lib/module/ui/GroupChannelMessage/Message.unknown.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.user.js +6 -9
- package/lib/module/ui/GroupChannelMessage/Message.user.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/Message.user.og.js +14 -17
- package/lib/module/ui/GroupChannelMessage/Message.user.og.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/MessageBubbleWithText.js +26 -21
- package/lib/module/ui/GroupChannelMessage/MessageBubbleWithText.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/MessageContainer.js +27 -28
- package/lib/module/ui/GroupChannelMessage/MessageContainer.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/MessageOpenGraph.js +36 -40
- package/lib/module/ui/GroupChannelMessage/MessageOpenGraph.js.map +1 -1
- package/lib/module/ui/GroupChannelMessage/index.js.map +1 -1
- package/lib/module/ui/GroupChannelPreview/index.js +53 -58
- package/lib/module/ui/GroupChannelPreview/index.js.map +1 -1
- package/lib/module/ui/Header/index.js +44 -54
- package/lib/module/ui/Header/index.js.map +1 -1
- package/lib/module/ui/LoadingSpinner/index.js +10 -13
- package/lib/module/ui/LoadingSpinner/index.js.map +1 -1
- package/lib/module/ui/MenuBar/index.js +21 -18
- package/lib/module/ui/MenuBar/index.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.admin.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.file.image.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.file.js +4 -5
- package/lib/module/ui/OpenChannelMessage/Message.file.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.file.video.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.unknown.js +4 -5
- package/lib/module/ui/OpenChannelMessage/Message.unknown.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.user.js +26 -17
- package/lib/module/ui/OpenChannelMessage/Message.user.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/Message.user.og.js +52 -46
- package/lib/module/ui/OpenChannelMessage/Message.user.og.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/MessageContainer.js +14 -16
- package/lib/module/ui/OpenChannelMessage/MessageContainer.js.map +1 -1
- package/lib/module/ui/OpenChannelMessage/index.js.map +1 -1
- package/lib/module/ui/OpenChannelPreview/index.js +23 -27
- package/lib/module/ui/OpenChannelPreview/index.js.map +1 -1
- package/lib/module/ui/OutlinedButton/index.js +5 -6
- package/lib/module/ui/OutlinedButton/index.js.map +1 -1
- package/lib/module/ui/Placeholder/index.js +7 -8
- package/lib/module/ui/Placeholder/index.js.map +1 -1
- package/lib/module/ui/ProfileCard/index.js +9 -9
- package/lib/module/ui/ProfileCard/index.js.map +1 -1
- package/lib/module/ui/Prompt/index.js +26 -32
- package/lib/module/ui/Prompt/index.js.map +1 -1
- package/lib/module/ui/Toast/index.js +17 -22
- package/lib/module/ui/Toast/index.js.map +1 -1
- package/lib/module/ui/TypingIndicatorBubble/index.js +21 -27
- package/lib/module/ui/TypingIndicatorBubble/index.js.map +1 -1
- package/lib/typescript/src/components/Box/index.d.ts +12 -2
- package/lib/typescript/src/components/Icon/index.d.ts +2 -1
- package/lib/typescript/src/components/Text/index.d.ts +14 -2
- package/lib/typescript/src/components/TextInput/index.d.ts +2 -1
- package/package.json +3 -3
- package/src/assets/icon/icon-thread.png +0 -0
- package/src/assets/icon/icon-thread@2x.png +0 -0
- package/src/assets/icon/icon-thread@3x.png +0 -0
- package/src/components/Box/index.tsx +16 -5
- package/src/components/Icon/index.tsx +35 -3
- package/src/components/ProgressBar/index.tsx +23 -12
- package/src/components/Switch/index.tsx +10 -6
- package/src/components/Text/index.tsx +48 -7
- package/src/components/TextInput/index.tsx +39 -12
- package/src/styles/createStyleSheet.ts +8 -2
- package/src/ui/ActionMenu/index.tsx +3 -1
- package/src/ui/Alert/index.tsx +4 -4
- package/src/ui/Avatar/AvatarGroup.tsx +6 -6
- package/src/ui/Avatar/AvatarStack.tsx +3 -3
- package/src/ui/BottomSheet/index.tsx +5 -4
- package/src/ui/Button/index.tsx +1 -1
- package/src/ui/Dialog/DialogSheet.tsx +15 -12
- package/src/ui/GroupChannelMessage/Message.file.tsx +1 -1
- package/src/ui/GroupChannelMessage/Message.file.voice.tsx +1 -1
- package/src/ui/GroupChannelMessage/MessageBubbleWithText.tsx +5 -2
- package/src/ui/GroupChannelMessage/MessageContainer.tsx +7 -7
- package/src/ui/GroupChannelPreview/index.tsx +46 -48
- package/src/ui/Header/index.tsx +4 -5
- package/src/ui/MenuBar/index.tsx +9 -6
- package/src/ui/OpenChannelMessage/Message.file.tsx +1 -1
- package/src/ui/OpenChannelMessage/Message.user.og.tsx +43 -29
- package/src/ui/OpenChannelMessage/Message.user.tsx +46 -29
- package/src/ui/OpenChannelMessage/MessageContainer.tsx +4 -4
- package/src/ui/OpenChannelPreview/index.tsx +9 -9
- package/src/ui/ProfileCard/index.tsx +1 -0
- package/src/ui/Prompt/index.tsx +4 -5
- package/src/ui/Toast/index.tsx +1 -1
- package/src/ui/TypingIndicatorBubble/index.tsx +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["fs","require","path","prettier","ignorePatterns","requireBasePath","iconPath","join","__dirname","icons","readdirSync","forEach","filename","match","ext","extname","name","replace","assetPath","serializedIcons","JSON","stringify","_","a","b","c","exportString","writeFileSync","format"],"sources":["bundle-icons.js"],"sourcesContent":["const fs = require('fs');\nconst path = require('path');\nconst prettier = require('prettier');\n\nconst ignorePatterns = /bundle-icons\\.js|\\.DS_Store|index\\.ts|@2x|@3x/;\nconst requireBasePath = './';\nconst iconPath = path.join(__dirname, 'icon');\nconst icons = {};\n\nfs.readdirSync(iconPath).forEach((filename) => {\n if (filename.match(ignorePatterns)) return;\n const ext = path.extname(filename);\n const name = filename.replace(ext, '').replace(/icon-|ic-/g, '');\n const assetPath = requireBasePath + filename;\n icons[name] = `require('${assetPath}')`;\n});\n\nconst serializedIcons = JSON.stringify(icons, null, 4).replace(\n /(\"require\\()('.+')(\\)\")/g,\n (_, a, b, c) => a.replace('\"', '') + b + c.replace('\"', ''),\n);\nconst exportString = `const IconAssets = ${serializedIcons}; export default IconAssets`;\n\nfs.writeFileSync(\n path.join(iconPath, 'index.ts'),\n prettier.format(exportString, {\n 'printWidth': 120,\n 'tabWidth': 2,\n 'useTabs': false,\n 'semi': true,\n 'singleQuote': true,\n 'quoteProps': 'preserve',\n 'trailingComma': 'all',\n 'bracketSpacing': true,\n 'arrowParens': 'always',\n }),\n);\n"],"mappings":"AAAA,MAAMA,EAAE,GAAGC,OAAO,CAAC,IAAI,CAAC;AACxB,MAAMC,IAAI,GAAGD,OAAO,CAAC,MAAM,CAAC;AAC5B,MAAME,QAAQ,GAAGF,OAAO,CAAC,UAAU,CAAC;AAEpC,MAAMG,cAAc,GAAG,+CAA+C;AACtE,MAAMC,eAAe,GAAG,IAAI;AAC5B,MAAMC,QAAQ,GAAGJ,IAAI,CAACK,IAAI,CAACC,SAAS,EAAE,MAAM,CAAC;AAC7C,MAAMC,KAAK,GAAG,CAAC,CAAC;AAEhBT,EAAE,CAACU,WAAW,CAACJ,QAAQ,CAAC,CAACK,OAAO,CAAEC,QAAQ,IAAK;EAC7C,IAAIA,QAAQ,CAACC,KAAK,CAACT,cAAc,CAAC,EAAE;EACpC,MAAMU,GAAG,GAAGZ,IAAI,CAACa,OAAO,CAACH,QAAQ,CAAC;EAClC,MAAMI,IAAI,GAAGJ,QAAQ,CAACK,OAAO,CAACH,GAAG,EAAE,EAAE,CAAC,CAACG,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC;EAChE,MAAMC,SAAS,GAAGb,eAAe,GAAGO,QAAQ;EAC5CH,KAAK,CAACO,IAAI,CAAC,
|
|
1
|
+
{"version":3,"names":["fs","require","path","prettier","ignorePatterns","requireBasePath","iconPath","join","__dirname","icons","readdirSync","forEach","filename","match","ext","extname","name","replace","assetPath","serializedIcons","JSON","stringify","_","a","b","c","exportString","writeFileSync","format"],"sources":["bundle-icons.js"],"sourcesContent":["const fs = require('fs');\nconst path = require('path');\nconst prettier = require('prettier');\n\nconst ignorePatterns = /bundle-icons\\.js|\\.DS_Store|index\\.ts|@2x|@3x/;\nconst requireBasePath = './';\nconst iconPath = path.join(__dirname, 'icon');\nconst icons = {};\n\nfs.readdirSync(iconPath).forEach((filename) => {\n if (filename.match(ignorePatterns)) return;\n const ext = path.extname(filename);\n const name = filename.replace(ext, '').replace(/icon-|ic-/g, '');\n const assetPath = requireBasePath + filename;\n icons[name] = `require('${assetPath}')`;\n});\n\nconst serializedIcons = JSON.stringify(icons, null, 4).replace(\n /(\"require\\()('.+')(\\)\")/g,\n (_, a, b, c) => a.replace('\"', '') + b + c.replace('\"', ''),\n);\nconst exportString = `const IconAssets = ${serializedIcons}; export default IconAssets`;\n\nfs.writeFileSync(\n path.join(iconPath, 'index.ts'),\n prettier.format(exportString, {\n 'printWidth': 120,\n 'tabWidth': 2,\n 'useTabs': false,\n 'semi': true,\n 'singleQuote': true,\n 'quoteProps': 'preserve',\n 'trailingComma': 'all',\n 'bracketSpacing': true,\n 'arrowParens': 'always',\n }),\n);\n"],"mappings":"AAAA,MAAMA,EAAE,GAAGC,OAAO,CAAC,IAAI,CAAC;AACxB,MAAMC,IAAI,GAAGD,OAAO,CAAC,MAAM,CAAC;AAC5B,MAAME,QAAQ,GAAGF,OAAO,CAAC,UAAU,CAAC;AAEpC,MAAMG,cAAc,GAAG,+CAA+C;AACtE,MAAMC,eAAe,GAAG,IAAI;AAC5B,MAAMC,QAAQ,GAAGJ,IAAI,CAACK,IAAI,CAACC,SAAS,EAAE,MAAM,CAAC;AAC7C,MAAMC,KAAK,GAAG,CAAC,CAAC;AAEhBT,EAAE,CAACU,WAAW,CAACJ,QAAQ,CAAC,CAACK,OAAO,CAAEC,QAAQ,IAAK;EAC7C,IAAIA,QAAQ,CAACC,KAAK,CAACT,cAAc,CAAC,EAAE;EACpC,MAAMU,GAAG,GAAGZ,IAAI,CAACa,OAAO,CAACH,QAAQ,CAAC;EAClC,MAAMI,IAAI,GAAGJ,QAAQ,CAACK,OAAO,CAACH,GAAG,EAAE,EAAE,CAAC,CAACG,OAAO,CAAC,YAAY,EAAE,EAAE,CAAC;EAChE,MAAMC,SAAS,GAAGb,eAAe,GAAGO,QAAQ;EAC5CH,KAAK,CAACO,IAAI,CAAC,GAAG,YAAYE,SAAS,IAAI;AACzC,CAAC,CAAC;AAEF,MAAMC,eAAe,GAAGC,IAAI,CAACC,SAAS,CAACZ,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC,CAACQ,OAAO,CAC5D,0BAA0B,EAC1B,CAACK,CAAC,EAAEC,CAAC,EAAEC,CAAC,EAAEC,CAAC,KAAKF,CAAC,CAACN,OAAO,CAAC,GAAG,EAAE,EAAE,CAAC,GAAGO,CAAC,GAAGC,CAAC,CAACR,OAAO,CAAC,GAAG,EAAE,EAAE,CAC5D,CAAC;AACD,MAAMS,YAAY,GAAG,sBAAsBP,eAAe,6BAA6B;AAEvFnB,EAAE,CAAC2B,aAAa,CACdzB,IAAI,CAACK,IAAI,CAACD,QAAQ,EAAE,UAAU,CAAC,EAC/BH,QAAQ,CAACyB,MAAM,CAACF,YAAY,EAAE;EAC5B,YAAY,EAAE,GAAG;EACjB,UAAU,EAAE,CAAC;EACb,SAAS,EAAE,KAAK;EAChB,MAAM,EAAE,IAAI;EACZ,aAAa,EAAE,IAAI;EACnB,YAAY,EAAE,UAAU;EACxB,eAAe,EAAE,KAAK;EACtB,gBAAgB,EAAE,IAAI;EACtB,aAAa,EAAE;AACjB,CAAC,CACH,CAAC","ignoreList":[]}
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["IconAssets","require"],"sources":["index.ts"],"sourcesContent":["const IconAssets = {\n 'chat-hide': require('./ic-chat-hide.png'),\n 'chat-show': require('./ic-chat-show.png'),\n 'add': require('./icon-add.png'),\n 'archive': require('./icon-archive.png'),\n 'arrow-left': require('./icon-arrow-left.png'),\n 'audio-off-filled': require('./icon-audio-off-filled.png'),\n 'audio-off': require('./icon-audio-off.png'),\n 'audio-on-filled': require('./icon-audio-on-filled.png'),\n 'audio-on': require('./icon-audio-on.png'),\n 'ban': require('./icon-ban.png'),\n 'broadcast': require('./icon-broadcast.png'),\n 'camera': require('./icon-camera.png'),\n 'channels': require('./icon-channels.png'),\n 'chat-filled': require('./icon-chat-filled.png'),\n 'chat': require('./icon-chat.png'),\n 'checkbox-off': require('./icon-checkbox-off.png'),\n 'checkbox-on': require('./icon-checkbox-on.png'),\n 'chevron-down': require('./icon-chevron-down.png'),\n 'chevron-right': require('./icon-chevron-right.png'),\n 'close': require('./icon-close.png'),\n 'copy': require('./icon-copy.png'),\n 'create': require('./icon-create.png'),\n 'delete': require('./icon-delete.png'),\n 'document': require('./icon-document.png'),\n 'done-all': require('./icon-done-all.png'),\n 'done': require('./icon-done.png'),\n 'download': require('./icon-download.png'),\n 'edit': require('./icon-edit.png'),\n 'emoji-more': require('./icon-emoji-more.png'),\n 'error': require('./icon-error.png'),\n 'file-audio': require('./icon-file-audio.png'),\n 'file-document': require('./icon-file-document.png'),\n 'freeze': require('./icon-freeze.png'),\n 'gif': require('./icon-gif.png'),\n 'info': require('./icon-info.png'),\n 'leave': require('./icon-leave.png'),\n 'members': require('./icon-members.png'),\n 'message': require('./icon-message.png'),\n 'moderation': require('./icon-moderation.png'),\n 'more': require('./icon-more.png'),\n 'mute': require('./icon-mute.png'),\n 'notifications-filled': require('./icon-notifications-filled.png'),\n 'notifications-off-filled': require('./icon-notifications-off-filled.png'),\n 'notifications': require('./icon-notifications.png'),\n 'operator': require('./icon-operator.png'),\n 'pause': require('./icon-pause.png'),\n 'photo': require('./icon-photo.png'),\n 'play': require('./icon-play.png'),\n 'plus': require('./icon-plus.png'),\n 'question': require('./icon-question.png'),\n 'radio-off': require('./icon-radio-off.png'),\n 'radio-on': require('./icon-radio-on.png'),\n 'recording': require('./icon-recording.png'),\n 'refresh': require('./icon-refresh.png'),\n 'remove': require('./icon-remove.png'),\n 'reply-filled': require('./icon-reply-filled.png'),\n 'reply': require('./icon-reply.png'),\n 'search': require('./icon-search.png'),\n 'send': require('./icon-send.png'),\n 'settings-filled': require('./icon-settings-filled.png'),\n 'spinner': require('./icon-spinner.png'),\n 'stop': require('./icon-stop.png'),\n 'streaming': require('./icon-streaming.png'),\n 'supergroup': require('./icon-supergroup.png'),\n 'theme': require('./icon-theme.png'),\n 'thread': require('./icon-thread.png'),\n 'thumbnail-none': require('./icon-thumbnail-none.png'),\n 'unarchive': require('./icon-unarchive.png'),\n 'user': require('./icon-user.png'),\n};\nexport default IconAssets;\n"],"mappings":"AAAA,MAAMA,UAAU,GAAG;EACjB,WAAW,EAAEC,OAAO,CAAC,oBAAoB,CAAC;EAC1C,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Q,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,cAAc,EAAEA,OAAO,CAAC,yBAAyB,CAAC;EAClD,OAAO,EAAEA,OAAO,CAAC,kBAAkB,CAAC;EACpC,QAAQ,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,MAAM,EAAEA,OAAO,CAAC,iBAAiB,CAAC;EAClC,iBAAiB,EAAEA,OAAO,CAAC,4BAA4B,CAAC;EACxD,SAAS,EAAEA,OAAO,CAAC,oBAAoB,CAAC;EACxC,MAAM,EAAEA,OAAO,CAAC,iBAAiB,CAAC;EAClC,WAAW,EAAEA,OAAO,CAAC,sBAAsB,CAAC;EAC5C,YAAY,EAAEA,OAAO,CAAC,uBAAuB,CAAC;EAC9C,OAAO,EAAEA,OAAO,CAAC,kBAAkB,CAAC;EACpC,QAAQ,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,gBAAgB,EAAEA,OAAO,CAAC,2BAA2B,CAAC;EACtD,WAAW,EAAEA,OAAO,CAAC,sBAAsB,CAAC;EAC5C,MAAM,EAAEA,OAAO,CAAC,iBAAiB;AACnC,CAAC;AACD,eAAeD,UAAU"}
|
|
1
|
+
{"version":3,"names":["IconAssets","require"],"sources":["index.ts"],"sourcesContent":["const IconAssets = {\n 'chat-hide': require('./ic-chat-hide.png'),\n 'chat-show': require('./ic-chat-show.png'),\n 'add': require('./icon-add.png'),\n 'archive': require('./icon-archive.png'),\n 'arrow-left': require('./icon-arrow-left.png'),\n 'audio-off-filled': require('./icon-audio-off-filled.png'),\n 'audio-off': require('./icon-audio-off.png'),\n 'audio-on-filled': require('./icon-audio-on-filled.png'),\n 'audio-on': require('./icon-audio-on.png'),\n 'ban': require('./icon-ban.png'),\n 'broadcast': require('./icon-broadcast.png'),\n 'camera': require('./icon-camera.png'),\n 'channels': require('./icon-channels.png'),\n 'chat-filled': require('./icon-chat-filled.png'),\n 'chat': require('./icon-chat.png'),\n 'checkbox-off': require('./icon-checkbox-off.png'),\n 'checkbox-on': require('./icon-checkbox-on.png'),\n 'chevron-down': require('./icon-chevron-down.png'),\n 'chevron-right': require('./icon-chevron-right.png'),\n 'close': require('./icon-close.png'),\n 'copy': require('./icon-copy.png'),\n 'create': require('./icon-create.png'),\n 'delete': require('./icon-delete.png'),\n 'document': require('./icon-document.png'),\n 'done-all': require('./icon-done-all.png'),\n 'done': require('./icon-done.png'),\n 'download': require('./icon-download.png'),\n 'edit': require('./icon-edit.png'),\n 'emoji-more': require('./icon-emoji-more.png'),\n 'error': require('./icon-error.png'),\n 'file-audio': require('./icon-file-audio.png'),\n 'file-document': require('./icon-file-document.png'),\n 'freeze': require('./icon-freeze.png'),\n 'gif': require('./icon-gif.png'),\n 'info': require('./icon-info.png'),\n 'leave': require('./icon-leave.png'),\n 'members': require('./icon-members.png'),\n 'message': require('./icon-message.png'),\n 'moderation': require('./icon-moderation.png'),\n 'more': require('./icon-more.png'),\n 'mute': require('./icon-mute.png'),\n 'notifications-filled': require('./icon-notifications-filled.png'),\n 'notifications-off-filled': require('./icon-notifications-off-filled.png'),\n 'notifications': require('./icon-notifications.png'),\n 'operator': require('./icon-operator.png'),\n 'pause': require('./icon-pause.png'),\n 'photo': require('./icon-photo.png'),\n 'play': require('./icon-play.png'),\n 'plus': require('./icon-plus.png'),\n 'question': require('./icon-question.png'),\n 'radio-off': require('./icon-radio-off.png'),\n 'radio-on': require('./icon-radio-on.png'),\n 'recording': require('./icon-recording.png'),\n 'refresh': require('./icon-refresh.png'),\n 'remove': require('./icon-remove.png'),\n 'reply-filled': require('./icon-reply-filled.png'),\n 'reply': require('./icon-reply.png'),\n 'search': require('./icon-search.png'),\n 'send': require('./icon-send.png'),\n 'settings-filled': require('./icon-settings-filled.png'),\n 'spinner': require('./icon-spinner.png'),\n 'stop': require('./icon-stop.png'),\n 'streaming': require('./icon-streaming.png'),\n 'supergroup': require('./icon-supergroup.png'),\n 'theme': require('./icon-theme.png'),\n 'thread': require('./icon-thread.png'),\n 'thumbnail-none': require('./icon-thumb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sBAAsB,CAAC;EAC5C,UAAU,EAAEA,OAAO,CAAC,qBAAqB,CAAC;EAC1C,WAAW,EAAEA,OAAO,CAAC,sBAAsB,CAAC;EAC5C,SAAS,EAAEA,OAAO,CAAC,oBAAoB,CAAC;EACxC,QAAQ,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,cAAc,EAAEA,OAAO,CAAC,yBAAyB,CAAC;EAClD,OAAO,EAAEA,OAAO,CAAC,kBAAkB,CAAC;EACpC,QAAQ,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,MAAM,EAAEA,OAAO,CAAC,iBAAiB,CAAC;EAClC,iBAAiB,EAAEA,OAAO,CAAC,4BAA4B,CAAC;EACxD,SAAS,EAAEA,OAAO,CAAC,oBAAoB,CAAC;EACxC,MAAM,EAAEA,OAAO,CAAC,iBAAiB,CAAC;EAClC,WAAW,EAAEA,OAAO,CAAC,sBAAsB,CAAC;EAC5C,YAAY,EAAEA,OAAO,CAAC,uBAAuB,CAAC;EAC9C,OAAO,EAAEA,OAAO,CAAC,kBAAkB,CAAC;EACpC,QAAQ,EAAEA,OAAO,CAAC,mBAAmB,CAAC;EACtC,gBAAgB,EAAEA,OAAO,CAAC,2BAA2B,CAAC;EACtD,WAAW,EAAEA,OAAO,CAAC,sBAAsB,CAAC;EAC5C,MAAM,EAAEA,OAAO,CAAC,iBAAiB;AACnC,CAAC;AACD,eAAeD,UAAU","ignoreList":[]}
|
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
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
2
|
import React from 'react';
|
|
3
3
|
import { View } from 'react-native';
|
|
4
4
|
import { isFunction } from '@sendbird/uikit-utils';
|
|
5
5
|
import useUIKitTheme from '../../theme/useUIKitTheme';
|
|
6
|
-
const Box =
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
} = _ref;
|
|
6
|
+
const Box = ({
|
|
7
|
+
style,
|
|
8
|
+
children,
|
|
9
|
+
...props
|
|
10
|
+
}) => {
|
|
12
11
|
const boxStyle = useBoxStyle(props);
|
|
13
12
|
return /*#__PURE__*/React.createElement(View, _extends({}, props, {
|
|
14
13
|
style: [boxStyle, style]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","isFunction","useUIKitTheme","Box","
|
|
1
|
+
{"version":3,"names":["React","View","isFunction","useUIKitTheme","Box","style","children","props","boxStyle","useBoxStyle","createElement","_extends","theme","backgroundColor","rest"],"sources":["index.tsx"],"sourcesContent":["import React from 'react';\nimport { StyleProp, View, ViewProps, ViewStyle } from 'react-native';\n\nimport { isFunction } from '@sendbird/uikit-utils';\n\nimport useUIKitTheme from '../../theme/useUIKitTheme';\nimport type { UIKitColors, UIKitPalette } from '../../types';\n\ntype DeprecatedBoxProps = {\n /** @deprecated Please use `paddingStart` instead **/\n paddingLeft?: ViewStyle['paddingLeft'];\n /** @deprecated Please use `paddingEnd` instead **/\n paddingRight?: ViewStyle['paddingRight'];\n /** @deprecated Please use `marginStart` instead **/\n marginLeft?: ViewStyle['marginLeft'];\n /** @deprecated Please use `marginEnd` instead **/\n marginRight?: ViewStyle['marginRight'];\n};\n\ntype BaseBoxProps = Pick<\n ViewStyle,\n | 'flex'\n | 'flexShrink'\n | 'flexGrow'\n | 'flexDirection'\n | 'alignItems'\n | 'justifyContent'\n | 'borderRadius'\n | 'borderWidth'\n | 'borderColor'\n | 'borderBottomColor'\n | 'borderBottomWidth'\n | 'margin'\n | 'marginHorizontal'\n | 'marginVertical'\n | 'marginStart'\n | 'marginEnd'\n | 'marginTop'\n | 'marginBottom'\n | 'padding'\n | 'paddingHorizontal'\n | 'paddingVertical'\n | 'paddingStart'\n | 'paddingEnd'\n | 'paddingTop'\n | 'paddingBottom'\n | 'overflow'\n | 'width'\n | 'height'\n> & {\n backgroundColor?: string | ((theme: { colors: UIKitColors; palette: UIKitPalette }) => string);\n};\n\ntype BoxProps = BaseBoxProps & DeprecatedBoxProps & ViewProps;\nconst Box = ({ style, children, ...props }: BoxProps) => {\n const boxStyle = useBoxStyle(props);\n\n return (\n <View {...props} style={[boxStyle, style]}>\n {children}\n </View>\n );\n};\n\nconst useBoxStyle = (props: BaseBoxProps): StyleProp<ViewStyle> => {\n const theme = useUIKitTheme();\n\n const { backgroundColor, ...rest } = props;\n\n return {\n backgroundColor: isFunction(backgroundColor) ? backgroundColor(theme) : backgroundColor,\n ...rest,\n };\n};\n\nexport default Box;\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAoBC,IAAI,QAA8B,cAAc;AAEpE,SAASC,UAAU,QAAQ,uBAAuB;AAElD,OAAOC,aAAa,MAAM,2BAA2B;AAiDrD,MAAMC,GAAG,GAAGA,CAAC;EAAEC,KAAK;EAAEC,QAAQ;EAAE,GAAGC;AAAgB,CAAC,KAAK;EACvD,MAAMC,QAAQ,GAAGC,WAAW,CAACF,KAAK,CAAC;EAEnC,oBACEP,KAAA,CAAAU,aAAA,CAACT,IAAI,EAAAU,QAAA,KAAKJ,KAAK;IAAEF,KAAK,EAAE,CAACG,QAAQ,EAAEH,KAAK;EAAE,IACvCC,QACG,CAAC;AAEX,CAAC;AAED,MAAMG,WAAW,GAAIF,KAAmB,IAA2B;EACjE,MAAMK,KAAK,GAAGT,aAAa,CAAC,CAAC;EAE7B,MAAM;IAAEU,eAAe;IAAE,GAAGC;EAAK,CAAC,GAAGP,KAAK;EAE1C,OAAO;IACLM,eAAe,EAAEX,UAAU,CAACW,eAAe,CAAC,GAAGA,eAAe,CAACD,KAAK,CAAC,GAAGC,eAAe;IACvF,GAAGC;EACL,CAAC;AACH,CAAC;AAED,eAAeV,GAAG","ignoreList":[]}
|
|
@@ -2,11 +2,10 @@ import React from 'react';
|
|
|
2
2
|
import { View } from 'react-native';
|
|
3
3
|
import createStyleSheet from '../../styles/createStyleSheet';
|
|
4
4
|
import useUIKitTheme from '../../theme/useUIKitTheme';
|
|
5
|
-
const Divider =
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
} = _ref;
|
|
5
|
+
const Divider = ({
|
|
6
|
+
style,
|
|
7
|
+
space
|
|
8
|
+
}) => {
|
|
10
9
|
const {
|
|
11
10
|
colors
|
|
12
11
|
} = useUIKitTheme();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","View","createStyleSheet","useUIKitTheme","Divider","
|
|
1
|
+
{"version":3,"names":["React","View","createStyleSheet","useUIKitTheme","Divider","style","space","colors","createElement","styles","divider","paddingHorizontal","inner","backgroundColor","onBackground04","width","height"],"sources":["index.tsx"],"sourcesContent":["import React from 'react';\nimport { StyleProp, View, ViewStyle } from 'react-native';\n\nimport createStyleSheet from '../../styles/createStyleSheet';\nimport useUIKitTheme from '../../theme/useUIKitTheme';\n\ntype Props = {\n style?: StyleProp<ViewStyle>;\n space?: number;\n};\n\nconst Divider = ({ style, space }: Props) => {\n const { colors } = useUIKitTheme();\n return (\n <View style={[style, styles.divider, { paddingHorizontal: space }]}>\n <View style={[styles.inner, { backgroundColor: colors.onBackground04 }]} />\n </View>\n );\n};\n\nconst styles = createStyleSheet({\n divider: {\n width: '100%',\n height: 1,\n },\n inner: {\n width: '100%',\n height: '100%',\n },\n});\n\nexport default Divider;\n"],"mappings":"AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAAoBC,IAAI,QAAmB,cAAc;AAEzD,OAAOC,gBAAgB,MAAM,+BAA+B;AAC5D,OAAOC,aAAa,MAAM,2BAA2B;AAOrD,MAAMC,OAAO,GAAGA,CAAC;EAAEC,KAAK;EAAEC;AAAa,CAAC,KAAK;EAC3C,MAAM;IAAEC;EAAO,CAAC,GAAGJ,aAAa,CAAC,CAAC;EAClC,oBACEH,KAAA,CAAAQ,aAAA,CAACP,IAAI;IAACI,KAAK,EAAE,CAACA,KAAK,EAAEI,MAAM,CAACC,OAAO,EAAE;MAAEC,iBAAiB,EAAEL;IAAM,CAAC;EAAE,gBACjEN,KAAA,CAAAQ,aAAA,CAACP,IAAI;IAACI,KAAK,EAAE,CAACI,MAAM,CAACG,KAAK,EAAE;MAAEC,eAAe,EAAEN,MAAM,CAACO;IAAe,CAAC;EAAE,CAAE,CACtE,CAAC;AAEX,CAAC;AAED,MAAML,MAAM,GAAGP,gBAAgB,CAAC;EAC9BQ,OAAO,EAAE;IACPK,KAAK,EAAE,MAAM;IACbC,MAAM,EAAE;EACV,CAAC;EACDJ,KAAK,EAAE;IACLG,KAAK,EAAE,MAAM;IACbC,MAAM,EAAE;EACV;AACF,CAAC,CAAC;AAEF,eAAeZ,OAAO","ignoreList":[]}
|
|
@@ -1,18 +1,33 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
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
2
|
import React from 'react';
|
|
3
|
-
import { Image, StyleSheet, View } from 'react-native';
|
|
3
|
+
import { I18nManager, Image, StyleSheet, View } from 'react-native';
|
|
4
4
|
import { convertFileTypeToMessageType, getFileIconFromMessageType } from '@sendbird/uikit-utils';
|
|
5
5
|
import IconAssets from '../../assets/icon';
|
|
6
6
|
import createStyleSheet from '../../styles/createStyleSheet';
|
|
7
7
|
import useUIKitTheme from '../../theme/useUIKitTheme';
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
8
|
+
const mirroredIcons = {
|
|
9
|
+
create: true,
|
|
10
|
+
send: true,
|
|
11
|
+
reply: true,
|
|
12
|
+
'reply-filled': true,
|
|
13
|
+
thread: true,
|
|
14
|
+
chat: true,
|
|
15
|
+
'chat-filled': true,
|
|
16
|
+
message: true,
|
|
17
|
+
broadcast: true,
|
|
18
|
+
'file-audio': true,
|
|
19
|
+
'arrow-left': true,
|
|
20
|
+
leave: true,
|
|
21
|
+
'chevron-right': true
|
|
22
|
+
};
|
|
23
|
+
const Icon = ({
|
|
24
|
+
icon,
|
|
25
|
+
color,
|
|
26
|
+
size = 24,
|
|
27
|
+
containerStyle,
|
|
28
|
+
style,
|
|
29
|
+
direction = I18nManager.isRTL ? 'rtl' : 'ltr'
|
|
30
|
+
}) => {
|
|
16
31
|
const sizeStyle = sizeStyles[size] ?? {
|
|
17
32
|
width: size,
|
|
18
33
|
height: size
|
|
@@ -20,6 +35,7 @@ const Icon = _ref => {
|
|
|
20
35
|
const {
|
|
21
36
|
colors
|
|
22
37
|
} = useUIKitTheme();
|
|
38
|
+
const shouldMirror = direction === 'rtl' && mirroredIcons[icon];
|
|
23
39
|
return /*#__PURE__*/React.createElement(View, {
|
|
24
40
|
style: [containerStyle, containerStyles.container]
|
|
25
41
|
}, /*#__PURE__*/React.createElement(Image, {
|
|
@@ -27,14 +43,17 @@ const Icon = _ref => {
|
|
|
27
43
|
source: IconAssets[icon],
|
|
28
44
|
style: [{
|
|
29
45
|
tintColor: color ?? colors.primary
|
|
30
|
-
}, sizeStyle,
|
|
46
|
+
}, sizeStyle, shouldMirror && {
|
|
47
|
+
transform: [{
|
|
48
|
+
scaleX: -1
|
|
49
|
+
}]
|
|
50
|
+
}, style]
|
|
31
51
|
}));
|
|
32
52
|
};
|
|
33
|
-
const FileIcon =
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
} = _ref2;
|
|
53
|
+
const FileIcon = ({
|
|
54
|
+
fileType,
|
|
55
|
+
...props
|
|
56
|
+
}) => {
|
|
38
57
|
return /*#__PURE__*/React.createElement(Icon, _extends({
|
|
39
58
|
icon: getFileIconFromMessageType(convertFileTypeToMessageType(fileType))
|
|
40
59
|
}, props));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Image","StyleSheet","View","convertFileTypeToMessageType","getFileIconFromMessageType","IconAssets","createStyleSheet","useUIKitTheme","
|
|
1
|
+
{"version":3,"names":["React","I18nManager","Image","StyleSheet","View","convertFileTypeToMessageType","getFileIconFromMessageType","IconAssets","createStyleSheet","useUIKitTheme","mirroredIcons","create","send","reply","thread","chat","message","broadcast","leave","Icon","icon","color","size","containerStyle","style","direction","isRTL","sizeStyle","sizeStyles","width","height","colors","shouldMirror","createElement","containerStyles","container","resizeMode","source","tintColor","primary","transform","scaleX","FileIcon","fileType","props","_extends","alignItems","justifyContent","Object","assign","Assets","File"],"sources":["index.tsx"],"sourcesContent":["import React from 'react';\nimport { I18nManager, Image, ImageStyle, StyleProp, StyleSheet, View, ViewStyle } from 'react-native';\n\nimport { FileType, convertFileTypeToMessageType, getFileIconFromMessageType } from '@sendbird/uikit-utils';\n\nimport IconAssets from '../../assets/icon';\nimport createStyleSheet from '../../styles/createStyleSheet';\nimport useUIKitTheme from '../../theme/useUIKitTheme';\n\ntype IconNames = keyof typeof IconAssets;\ntype SizeFactor = keyof typeof sizeStyles;\n\nconst mirroredIcons: Partial<Record<IconNames, boolean>> = {\n create: true,\n send: true,\n reply: true,\n 'reply-filled': true,\n thread: true,\n chat: true,\n 'chat-filled': true,\n message: true,\n broadcast: true,\n 'file-audio': true,\n 'arrow-left': true,\n leave: true,\n 'chevron-right': true,\n};\n\ntype Props = {\n icon: IconNames;\n color?: string;\n size?: number;\n style?: StyleProp<ImageStyle>;\n containerStyle?: StyleProp<ViewStyle>;\n direction?: 'ltr' | 'rtl';\n};\n\nconst Icon = ({\n icon,\n color,\n size = 24,\n containerStyle,\n style,\n direction = I18nManager.isRTL ? 'rtl' : 'ltr',\n}: Props) => {\n const sizeStyle = sizeStyles[size as SizeFactor] ?? { width: size, height: size };\n const { colors } = useUIKitTheme();\n\n const shouldMirror = direction === 'rtl' && mirroredIcons[icon];\n\n return (\n <View style={[containerStyle, containerStyles.container]}>\n <Image\n resizeMode={'contain'}\n source={IconAssets[icon]}\n style={[\n { tintColor: color ?? colors.primary },\n sizeStyle,\n shouldMirror && { transform: [{ scaleX: -1 }] },\n style,\n ]}\n />\n </View>\n );\n};\n\nconst FileIcon = ({ fileType, ...props }: Omit<Props, 'icon'> & { fileType: FileType }) => {\n return <Icon icon={getFileIconFromMessageType(convertFileTypeToMessageType(fileType))} {...props} />;\n};\n\nconst containerStyles = StyleSheet.create({\n container: {\n alignItems: 'center',\n justifyContent: 'center',\n },\n});\n\nconst sizeStyles = createStyleSheet({\n 16: {\n width: 16,\n height: 16,\n },\n 20: {\n width: 20,\n height: 20,\n },\n 24: {\n width: 24,\n height: 24,\n },\n 28: {\n width: 28,\n height: 28,\n },\n 32: {\n width: 32,\n height: 32,\n },\n});\n\nexport default Object.assign(Icon, {\n Assets: IconAssets,\n File: FileIcon,\n});\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,WAAW,EAAEC,KAAK,EAAyBC,UAAU,EAAEC,IAAI,QAAmB,cAAc;AAErG,SAAmBC,4BAA4B,EAAEC,0BAA0B,QAAQ,uBAAuB;AAE1G,OAAOC,UAAU,MAAM,mBAAmB;AAC1C,OAAOC,gBAAgB,MAAM,+BAA+B;AAC5D,OAAOC,aAAa,MAAM,2BAA2B;AAKrD,MAAMC,aAAkD,GAAG;EACzDC,MAAM,EAAE,IAAI;EACZC,IAAI,EAAE,IAAI;EACVC,KAAK,EAAE,IAAI;EACX,cAAc,EAAE,IAAI;EACpBC,MAAM,EAAE,IAAI;EACZC,IAAI,EAAE,IAAI;EACV,aAAa,EAAE,IAAI;EACnBC,OAAO,EAAE,IAAI;EACbC,SAAS,EAAE,IAAI;EACf,YAAY,EAAE,IAAI;EAClB,YAAY,EAAE,IAAI;EAClBC,KAAK,EAAE,IAAI;EACX,eAAe,EAAE;AACnB,CA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AAU,EAAE,QAAQ;IACpBC,cAAc,EAAE;EAClB;AACF,CAAC,CAAC;AAEF,MAAMnB,UAAU,GAAGpB,gBAAgB,CAAC;EAClC,EAAE,EAAE;IACFqB,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV,CAAC;EACD,EAAE,EAAE;IACFD,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV,CAAC;EACD,EAAE,EAAE;IACFD,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV,CAAC;EACD,EAAE,EAAE;IACFD,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV,CAAC;EACD,EAAE,EAAE;IACFD,KAAK,EAAE,EAAE;IACTC,MAAM,EAAE;EACV;AACF,CAAC,CAAC;AAEF,eAAekB,MAAM,CAACC,MAAM,CAAC9B,IAAI,EAAE;EACjC+B,MAAM,EAAE3C,UAAU;EAClB4C,IAAI,EAAET;AACR,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["FastImageInternal","require"],"sources":["FastImageInternal.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport type { FastImageProps } from 'react-native-fast-image';\n\nlet FastImageInternal: (props: FastImageProps) => ReactNode | null = () => null;\n\ntry {\n FastImageInternal = require('react-native-fast-image') as (props: FastImageProps) => ReactNode;\n} catch {}\n\nexport default FastImageInternal;\n"],"mappings":"AAGA,IAAIA,iBAA8D,GAAGA,CAAA,KAAM,IAAI;AAE/E,IAAI;EACFA,iBAAiB,GAAGC,OAAO,CAAC,yBAAyB,CAAyC;AAChG,CAAC,CAAC,MAAM,CAAC;AAET,eAAeD,iBAAiB"}
|
|
1
|
+
{"version":3,"names":["FastImageInternal","require"],"sources":["FastImageInternal.tsx"],"sourcesContent":["import type { ReactNode } from 'react';\nimport type { FastImageProps } from 'react-native-fast-image';\n\nlet FastImageInternal: (props: FastImageProps) => ReactNode | null = () => null;\n\ntry {\n FastImageInternal = require('react-native-fast-image') as (props: FastImageProps) => ReactNode;\n} catch {}\n\nexport default FastImageInternal;\n"],"mappings":"AAGA,IAAIA,iBAA8D,GAAGA,CAAA,KAAM,IAAI;AAE/E,IAAI;EACFA,iBAAiB,GAAGC,OAAO,CAAC,yBAAyB,CAAyC;AAChG,CAAC,CAAC,MAAM,CAAC;AAET,eAAeD,iBAAiB","ignoreList":[]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
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
2
|
import React from 'react';
|
|
3
3
|
import { Image } from 'react-native';
|
|
4
4
|
import FastImageInternal from './FastImageInternal';
|
|
@@ -24,7 +24,6 @@ function convertSource(source) {
|
|
|
24
24
|
cache: convertCache(source === null || source === void 0 ? void 0 : source.cache) //'immutable' | 'web' | 'cacheOnly'
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
|
-
|
|
28
27
|
function convertDefaultSource(source) {
|
|
29
28
|
if (typeof source === 'number') {
|
|
30
29
|
return source;
|
|
@@ -45,18 +44,17 @@ function convertResizeMode(mode) {
|
|
|
45
44
|
return undefined;
|
|
46
45
|
}
|
|
47
46
|
}
|
|
48
|
-
const Image_FastImage =
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
} = _ref;
|
|
47
|
+
const Image_FastImage = ({
|
|
48
|
+
source,
|
|
49
|
+
defaultSource,
|
|
50
|
+
resizeMode,
|
|
51
|
+
onLoad,
|
|
52
|
+
onError,
|
|
53
|
+
style,
|
|
54
|
+
tintColor,
|
|
55
|
+
disableFastImage = false,
|
|
56
|
+
...props
|
|
57
|
+
}) => {
|
|
60
58
|
if (disableFastImage) {
|
|
61
59
|
return /*#__PURE__*/React.createElement(Image, _extends({}, props, {
|
|
62
60
|
source: source,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Image","FastImageInternal","convertCache","cache","convertSource","source","Array","isArray","uri","headers","convertDefaultSource","undefined","convertResizeMode","mode","Image_FastImage","
|
|
1
|
+
{"version":3,"names":["React","Image","FastImageInternal","convertCache","cache","convertSource","source","Array","isArray","uri","headers","convertDefaultSource","undefined","convertResizeMode","mode","Image_FastImage","defaultSource","resizeMode","onLoad","onError","style","tintColor","disableFastImage","props","createElement","_extends","e","nativeEvent"],"sources":["Image.fastimage.tsx"],"sourcesContent":["import React from 'react';\nimport { Image } from 'react-native';\nimport type { FastImageProps, ResizeMode, Source } from 'react-native-fast-image';\n\nimport FastImageInternal from './FastImageInternal';\nimport type { SendbirdImageComponent, SendbirdImageProps } from './index';\n\nfunction convertCache(\n cache?: 'default' | 'reload' | 'force-cache' | 'only-if-cached' | undefined,\n): 'immutable' | 'web' | 'cacheOnly' {\n switch (cache) {\n case 'force-cache':\n case 'only-if-cached':\n return 'cacheOnly';\n default:\n return 'immutable';\n }\n}\n\nfunction convertSource(source: SendbirdImageProps['source']): Source | number {\n if (Array.isArray(source)) {\n return convertSource(source[0]);\n }\n\n if (typeof source === 'number') {\n return source;\n }\n\n return {\n uri: source?.uri,\n headers: source?.headers,\n cache: convertCache(source?.cache), //'immutable' | 'web' | 'cacheOnly'\n };\n}\nfunction convertDefaultSource(source?: SendbirdImageProps['defaultSource']): number | undefined {\n if (typeof source === 'number') {\n return source;\n }\n\n return undefined;\n}\n\nfunction convertResizeMode(mode?: SendbirdImageProps['resizeMode']): ResizeMode | undefined {\n switch (mode) {\n case 'center':\n return 'center';\n case 'contain':\n return 'contain';\n case 'cover':\n return 'cover';\n case 'stretch':\n return 'stretch';\n default:\n return undefined;\n }\n}\n\nconst Image_FastImage: SendbirdImageComponent = ({\n source,\n defaultSource,\n resizeMode,\n onLoad,\n onError,\n style,\n tintColor,\n disableFastImage = false,\n ...props\n}) => {\n if (disableFastImage) {\n return (\n <Image\n {...props}\n source={source}\n style={[style, { tintColor }]}\n onError={onError && ((e) => onError(e.nativeEvent))}\n onLoad={onLoad && ((e) => onLoad(e.nativeEvent.source))}\n />\n );\n }\n return (\n <FastImageInternal\n {...props}\n onLoad={onLoad && ((e) => onLoad(e.nativeEvent))}\n onError={onError && (() => onError({}))}\n style={style as FastImageProps['style']}\n source={convertSource(source)}\n defaultSource={convertDefaultSource(defaultSource)}\n resizeMode={convertResizeMode(resizeMode)}\n />\n );\n};\n\nexport default Image_FastImage;\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,QAAQ,cAAc;AAGpC,OAAOC,iBAAiB,MAAM,qBAAqB;AAGnD,SAASC,YAAYA,CACnBC,KAA2E,EACxC;EACnC,QAAQA,KAAK;IACX,KAAK,aAAa;IAClB,KAAK,gBAAgB;MACnB,OAAO,WAAW;IACpB;MACE,OAAO,WAAW;EACtB;AACF;AAEA,SAASC,aAAaA,CAACC,MAAoC,EAAmB;EAC5E,IAAIC,KAAK,CAACC,OAAO,CAACF,MAAM,CAAC,EAAE;IACzB,OAAOD,aAAa,CAACC,MAAM,CAAC,CAAC,CAAC,CAAC;EACjC;EAEA,IAAI,OAAOA,MAAM,KAAK,QAAQ,EAAE;IAC9B,OAAOA,MAAM;EACf;EAEA,OAAO;IACLG,GAAG,EAAEH,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAEG,GAAG;IAChBC,OAAO,EAAEJ,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAEI,OAAO;IACxBN,KAAK,EAAED,YAAY,CAACG,MAAM,aAANA,MAAM,uBAANA,MAAM,CAAEF,KAAK,CAAC,CAAE;EACtC,CAAC;AACH;AACA,SAASO,oBAAoBA,CAACL,MAA4C,EAAsB;EAC9F,IAAI,OAAOA,MAAM,KAAK,QAAQ,EAAE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ACnDC,UAAU,EAAEJ,iBAAiB,CAACI,UAAU;EAAE,EAC3C,CAAC;AAEN,CAAC;AAED,eAAeF,eAAe","ignoreList":[]}
|
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
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
2
|
import React from 'react';
|
|
3
3
|
import { Image } from 'react-native';
|
|
4
|
-
const Image_ReactNative =
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
} = _ref;
|
|
4
|
+
const Image_ReactNative = ({
|
|
5
|
+
onLoad,
|
|
6
|
+
onError,
|
|
7
|
+
style,
|
|
8
|
+
tintColor,
|
|
9
|
+
...props
|
|
10
|
+
}) => {
|
|
12
11
|
return /*#__PURE__*/React.createElement(Image, _extends({}, props, {
|
|
13
12
|
style: [style, {
|
|
14
13
|
tintColor
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","Image","Image_ReactNative","
|
|
1
|
+
{"version":3,"names":["React","Image","Image_ReactNative","onLoad","onError","style","tintColor","props","createElement","_extends","e","nativeEvent","source"],"sources":["Image.reactnative.tsx"],"sourcesContent":["import React from 'react';\nimport { Image } from 'react-native';\n\nimport type { SendbirdImageComponent } from './index';\n\nconst Image_ReactNative: SendbirdImageComponent = ({ onLoad, onError, style, tintColor, ...props }) => {\n return (\n <Image\n {...props}\n style={[style, { tintColor }]}\n onError={onError && ((e) => onError(e.nativeEvent))}\n onLoad={onLoad && ((e) => onLoad(e.nativeEvent.source))}\n />\n );\n};\n\nexport default Image_ReactNative;\n"],"mappings":";AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,KAAK,QAAQ,cAAc;AAIpC,MAAMC,iBAAyC,GAAGA,CAAC;EAAEC,MAAM;EAAEC,OAAO;EAAEC,KAAK;EAAEC,SAAS;EAAE,GAAGC;AAAM,CAAC,KAAK;EACrG,oBACEP,KAAA,CAAAQ,aAAA,CAACP,KAAK,EAAAQ,QAAA,KACAF,KAAK;IACTF,KAAK,EAAE,CAACA,KAAK,EAAE;MAAEC;IAAU,CAAC,CAAE;IAC9BF,OAAO,EAAEA,OAAO,KAAMM,CAAC,IAAKN,OAAO,CAACM,CAAC,CAACC,WAAW,CAAC,CAAE;IACpDR,MAAM,EAAEA,MAAM,KAAMO,CAAC,IAAKP,MAAM,CAACO,CAAC,CAACC,WAAW,CAACC,MAAM,CAAC;EAAE,EACzD,CAAC;AAEN,CAAC;AAED,eAAeV,iBAAiB","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["NativeModules","getImageModule","hasFastImage","Boolean","FastImageView","require","default","e","Image"],"sources":["index.ts"],"sourcesContent":["import { ComponentType } from 'react';\nimport type { ImageProps as NativeImageProps } from 'react-native';\nimport { NativeModules } from 'react-native';\n\nexport interface SendbirdImageProps extends Omit<NativeImageProps, 'onLoad' | 'onError'> {\n disableFastImage?: boolean;\n onLoad?: (event: { width: number; height: number }) => void;\n onError?: (event: { error?: unknown }) => void;\n tintColor?: string;\n}\n\nexport type SendbirdImageComponent = ComponentType<SendbirdImageProps>;\nfunction getImageModule(): SendbirdImageComponent {\n const hasFastImage = Boolean(NativeModules.FastImageView);\n if (hasFastImage) {\n try {\n return require('./Image.fastimage').default;\n } catch (e) {\n return require('./Image.reactnative').default;\n }\n } else {\n return require('./Image.reactnative').default;\n }\n}\n\nconst Image = getImageModule();\n\nexport default Image;\n"],"mappings":"AAEA,SAASA,aAAa,QAAQ,cAAc;AAU5C,SAASC,cAAcA,CAAA,EAA2B;EAChD,MAAMC,YAAY,GAAGC,OAAO,CAACH,aAAa,CAACI,aAAa,CAAC;EACzD,IAAIF,YAAY,EAAE;IAChB,IAAI;MACF,OAAOG,OAAO,CAAC,mBAAmB,CAAC,CAACC,OAAO;IAC7C,CAAC,CAAC,OAAOC,CAAC,EAAE;MACV,OAAOF,OAAO,CAAC,qBAAqB,CAAC,CAACC,OAAO;IAC/C;EACF,CAAC,MAAM;IACL,OAAOD,OAAO,CAAC,qBAAqB,CAAC,CAACC,OAAO;EAC/C;AACF;AAEA,MAAME,KAAK,GAAGP,cAAc,
|
|
1
|
+
{"version":3,"names":["NativeModules","getImageModule","hasFastImage","Boolean","FastImageView","require","default","e","Image"],"sources":["index.ts"],"sourcesContent":["import { ComponentType } from 'react';\nimport type { ImageProps as NativeImageProps } from 'react-native';\nimport { NativeModules } from 'react-native';\n\nexport interface SendbirdImageProps extends Omit<NativeImageProps, 'onLoad' | 'onError'> {\n disableFastImage?: boolean;\n onLoad?: (event: { width: number; height: number }) => void;\n onError?: (event: { error?: unknown }) => void;\n tintColor?: string;\n}\n\nexport type SendbirdImageComponent = ComponentType<SendbirdImageProps>;\nfunction getImageModule(): SendbirdImageComponent {\n const hasFastImage = Boolean(NativeModules.FastImageView);\n if (hasFastImage) {\n try {\n return require('./Image.fastimage').default;\n } catch (e) {\n return require('./Image.reactnative').default;\n }\n } else {\n return require('./Image.reactnative').default;\n }\n}\n\nconst Image = getImageModule();\n\nexport default Image;\n"],"mappings":"AAEA,SAASA,aAAa,QAAQ,cAAc;AAU5C,SAASC,cAAcA,CAAA,EAA2B;EAChD,MAAMC,YAAY,GAAGC,OAAO,CAACH,aAAa,CAACI,aAAa,CAAC;EACzD,IAAIF,YAAY,EAAE;IAChB,IAAI;MACF,OAAOG,OAAO,CAAC,mBAAmB,CAAC,CAACC,OAAO;IAC7C,CAAC,CAAC,OAAOC,CAAC,EAAE;MACV,OAAOF,OAAO,CAAC,qBAAqB,CAAC,CAACC,OAAO;IAC/C;EACF,CAAC,MAAM;IACL,OAAOD,OAAO,CAAC,qBAAqB,CAAC,CAACC,OAAO;EAC/C;AACF;AAEA,MAAME,KAAK,GAAGP,cAAc,CAAC,CAAC;AAE9B,eAAeO,KAAK","ignoreList":[]}
|
|
@@ -6,8 +6,7 @@ import useUIKitTheme from '../../theme/useUIKitTheme';
|
|
|
6
6
|
import Box from '../Box';
|
|
7
7
|
import Icon from '../Icon';
|
|
8
8
|
import Image from '../Image';
|
|
9
|
-
const useRetry =
|
|
10
|
-
let retryCount = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 5;
|
|
9
|
+
const useRetry = (hasError, retryCount = 5) => {
|
|
11
10
|
// NOTE: Glide(fast-image) will retry automatically on Android
|
|
12
11
|
if (Platform.OS === 'android') return '';
|
|
13
12
|
const forceUpdate = useForceUpdate();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useRef","useState","Platform","StyleSheet","useForceUpdate","createStyleSheet","useUIKitTheme","Box","Icon","Image","useRetry","hasError","retryCount","
|
|
1
|
+
{"version":3,"names":["React","useEffect","useRef","useState","Platform","StyleSheet","useForceUpdate","createStyleSheet","useUIKitTheme","Box","Icon","Image","useRetry","hasError","retryCount","OS","forceUpdate","retryCountRef","retryTimeoutRef","reloadReservation","current","setTimeout","clearTimeout","ImageWithPlaceholder","props","palette","select","colors","imageNotFound","setImageNotFound","key","createElement","style","overflow","width","height","backgroundColor","dark","background400","light","background100","source","absoluteFill","styles","hide","resizeMode","resizeMethod","onError","onLoad","containerStyle","icon","size","color","onBackground02","display"],"sources":["index.tsx"],"sourcesContent":["import React, { useEffect, useRef, useState } from 'react';\nimport { Platform, StyleProp, StyleSheet, ViewStyle } from 'react-native';\n\nimport { useForceUpdate } from '@sendbird/uikit-utils';\n\nimport createStyleSheet from '../../styles/createStyleSheet';\nimport useUIKitTheme from '../../theme/useUIKitTheme';\nimport Box from '../Box';\nimport Icon from '../Icon';\nimport Image from '../Image';\n\nconst useRetry = (hasError: boolean, retryCount = 5) => {\n // NOTE: Glide(fast-image) will retry automatically on Android\n if (Platform.OS === 'android') return '';\n\n const forceUpdate = useForceUpdate();\n const retryCountRef = useRef(1);\n const retryTimeoutRef = useRef<NodeJS.Timeout>();\n\n useEffect(() => {\n if (hasError) {\n const reloadReservation = () => {\n if (retryCountRef.current < retryCount) {\n retryTimeoutRef.current = setTimeout(() => {\n retryCountRef.current++;\n reloadReservation();\n forceUpdate();\n }, retryCountRef.current * 5000);\n }\n };\n\n return reloadReservation();\n } else {\n return clearTimeout(retryTimeoutRef.current);\n }\n }, [hasError]);\n\n return retryCountRef.current;\n};\n\ntype Props = {\n source: number | { uri: string };\n width?: number | `${number}%`;\n height?: number | `${number}%`;\n style?: StyleProp<ViewStyle>;\n};\nconst ImageWithPlaceholder = (props: Props) => {\n const { palette, select, colors } = useUIKitTheme();\n const [imageNotFound, setImageNotFound] = useState(false);\n\n const key = useRetry(imageNotFound);\n return (\n <Box\n style={[{ overflow: 'hidden', width: props.width, height: props.height }, props.style]}\n backgroundColor={select({ dark: palette.background400, light: palette.background100 })}\n >\n <Image\n key={key}\n source={props.source}\n style={[StyleSheet.absoluteFill, imageNotFound && styles.hide]}\n resizeMode={'cover'}\n resizeMethod={'resize'}\n onError={() => setImageNotFound(true)}\n onLoad={() => setImageNotFound(false)}\n />\n {imageNotFound && (\n <Icon\n containerStyle={StyleSheet.absoluteFill}\n icon={'thumbnail-none'}\n size={48}\n color={colors.onBackground02}\n />\n )}\n </Box>\n );\n};\n\nconst styles = createStyleSheet({\n hide: {\n display: 'none',\n },\n});\n\nexport default ImageWithPlaceholder;\n"],"mappings":"AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,SAASC,QAAQ,EAAaC,UAAU,QAAmB,cAAc;AAEzE,SAASC,cAAc,QAAQ,uBAAuB;AAEtD,OAAOC,gBAAgB,MAAM,+BAA+B;AAC5D,OAAOC,aAAa,MAAM,2BAA2B;AACrD,OAAOC,GAAG,MAAM,QAAQ;AACxB,OAAOC,IAAI,MAAM,SAAS;AAC1B,OAAOC,K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,KAAK,CAACU,KAAK;MAAEC,MAAM,EAAEX,KAAK,CAACW;IAAO,CAAC,EAAEX,KAAK,CAACQ,KAAK,CAAE;IACvFI,eAAe,EAAEV,MAAM,CAAC;MAAEW,IAAI,EAAEZ,OAAO,CAACa,aAAa;MAAEC,KAAK,EAAEd,OAAO,CAACe;IAAc,CAAC;EAAE,gBAEvFxC,KAAA,CAAA+B,aAAA,CAACpB,KAAK;IACJmB,GAAG,EAAEA,GAAI;IACTW,MAAM,EAAEjB,KAAK,CAACiB,MAAO;IACrBT,KAAK,EAAE,CAAC3B,UAAU,CAACqC,YAAY,EAAEd,aAAa,IAAIe,MAAM,CAACC,IAAI,CAAE;IAC/DC,UAAU,EAAE,OAAQ;IACpBC,YAAY,EAAE,QAAS;IACvBC,OAAO,EAAEA,CAAA,KAAMlB,gBAAgB,CAAC,IAAI,CAAE;IACtCmB,MAAM,EAAEA,CAAA,KAAMnB,gBAAgB,CAAC,KAAK;EAAE,CACvC,CAAC,EACDD,aAAa,iBACZ5B,KAAA,CAAA+B,aAAA,CAACrB,IAAI;IACHuC,cAAc,EAAE5C,UAAU,CAACqC,YAAa;IACxCQ,IAAI,EAAE,gBAAiB;IACvBC,IAAI,EAAE,EAAG;IACTC,KAAK,EAAEzB,MAAM,CAAC0B;EAAe,CAC9B,CAEA,CAAC;AAEV,CAAC;AAED,MAAMV,MAAM,GAAGpC,gBAAgB,CAAC;EAC9BqC,IAAI,EAAE;IACJU,OAAO,EAAE;EACX;AACF,CAAC,CAAC;AAEF,eAAe/B,oBAAoB","ignoreList":[]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (
|
|
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
2
|
import React, { useEffect, useRef, useState } from 'react';
|
|
3
3
|
import { Animated, Dimensions, KeyboardAvoidingView, PanResponder, Platform, Pressable, Modal as RNModal, StyleSheet, TouchableWithoutFeedback, useWindowDimensions } from 'react-native';
|
|
4
4
|
import createStyleSheet from '../../styles/createStyleSheet';
|
|
@@ -11,19 +11,18 @@ import useUIKitTheme from '../../theme/useUIKitTheme';
|
|
|
11
11
|
* Modal Close: Triggered by Modal.props.onClose() call
|
|
12
12
|
* - Modal.props.onClose() -> visible false -> animation start -> modalVisible false
|
|
13
13
|
* */
|
|
14
|
-
const Modal =
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
} = _ref;
|
|
14
|
+
const Modal = ({
|
|
15
|
+
children,
|
|
16
|
+
onClose,
|
|
17
|
+
backgroundStyle,
|
|
18
|
+
onDismiss,
|
|
19
|
+
type = 'fade',
|
|
20
|
+
visible = false,
|
|
21
|
+
disableBackgroundClose = false,
|
|
22
|
+
enableKeyboardAvoid = false,
|
|
23
|
+
statusBarTranslucent,
|
|
24
|
+
...props
|
|
25
|
+
}) => {
|
|
27
26
|
const {
|
|
28
27
|
palette
|
|
29
28
|
} = useUIKitTheme();
|
|
@@ -99,26 +98,19 @@ const useModalPanResponder = (type, translateY, show, hide) => {
|
|
|
99
98
|
panHandlers: {}
|
|
100
99
|
};
|
|
101
100
|
return React.useRef(PanResponder.create({
|
|
102
|
-
onMoveShouldSetPanResponderCapture: (_,
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
} = _ref2;
|
|
106
|
-
return dy > 8;
|
|
107
|
-
},
|
|
101
|
+
onMoveShouldSetPanResponderCapture: (_, {
|
|
102
|
+
dy
|
|
103
|
+
}) => dy > 8,
|
|
108
104
|
// @ts-ignore
|
|
109
105
|
onPanResponderGrant: () => translateY.setOffset(translateY.__getValue()),
|
|
110
|
-
onPanResponderMove: (_,
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
} = _ref3;
|
|
114
|
-
return dy >= 0 && translateY.setValue(dy);
|
|
115
|
-
},
|
|
106
|
+
onPanResponderMove: (_, {
|
|
107
|
+
dy
|
|
108
|
+
}) => dy >= 0 && translateY.setValue(dy),
|
|
116
109
|
// Animated.event([null, { dy: translateY }], { useNativeDriver: false }),
|
|
117
|
-
onPanResponderRelease: (_,
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
} = _ref4;
|
|
110
|
+
onPanResponderRelease: (_, {
|
|
111
|
+
dy,
|
|
112
|
+
vy
|
|
113
|
+
}) => {
|
|
122
114
|
if (isHideGesture(dy, vy)) hide();else show();
|
|
123
115
|
}
|
|
124
116
|
})).current;
|
|
@@ -166,7 +158,7 @@ const useOnDismiss = (visible, onDismiss) => {
|
|
|
166
158
|
const prevVisible = usePrevProp(visible);
|
|
167
159
|
useEffect(() => {
|
|
168
160
|
if (Platform.OS === 'ios') return;
|
|
169
|
-
if (prevVisible && !visible) onDismiss === null || onDismiss === void 0
|
|
161
|
+
if (prevVisible && !visible) onDismiss === null || onDismiss === void 0 || onDismiss();
|
|
170
162
|
}, [prevVisible, visible]);
|
|
171
163
|
};
|
|
172
164
|
const usePrevProp = prop => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","useEffect","useRef","useState","Animated","Dimensions","KeyboardAvoidingView","PanResponder","Platform","Pressable","Modal","RNModal","StyleSheet","TouchableWithoutFeedback","useWindowDimensions","createStyleSheet","useHeaderStyle","useUIKitTheme","_ref","children","onClose","backgroundStyle","onDismiss","type","visible","disableBackgroundClose","enableKeyboardAvoid","statusBarTranslucent","props","palette","content","backdrop","showTransition","hideTransition","useModalAnimation","panResponder","useModalPanResponder","translateY","topInset","modalVisible","setModalVisible","showAction","hideAction","width","height","useOnDismiss","createElement","_extends","transparent","hardwareAccelerated","onRequestClose","onShow","supportedOrientations","animationType","onPress","undefined","View","style","absoluteFill","opacity","backgroundColor","onBackgroundLight03","key","OS","enabled","styles","background","behavior","select","ios","default","pointerEvents","keyboardVerticalOffset","transform","panHandlers","isHideGesture","distanceY","velocityY","show","hide","create","onMoveShouldSetPanResponderCapture","_","_ref2","dy","onPanResponderGrant","setOffset","__getValue","onPanResponderMove","_ref3","setValue","onPanResponderRelease","_ref4","vy","current","initialY","get","baseAnimBackground","Value","baseAnimContent","interpolate","inputRange","outputRange","createTransition","toValue","config","duration","useNativeDriver","parallel","timing","start","prevVisible","usePrevProp","prop","prev","curr","flex"],"sources":["index.tsx"],"sourcesContent":["import React, { useEffect, useRef, useState } from 'react';\nimport {\n Animated,\n Dimensions,\n KeyboardAvoidingView,\n ModalProps,\n PanResponder,\n Platform,\n Pressable,\n Modal as RNModal,\n StyleProp,\n StyleSheet,\n TouchableWithoutFeedback,\n ViewStyle,\n useWindowDimensions,\n} from 'react-native';\n\nimport createStyleSheet from '../../styles/createStyleSheet';\nimport useHeaderStyle from '../../styles/useHeaderStyle';\nimport useUIKitTheme from '../../theme/useUIKitTheme';\n\ntype ModalAnimationType = 'slide' | 'slide-no-gesture' | 'fade';\ntype Props = {\n type?: ModalAnimationType;\n onClose: () => void;\n backgroundStyle?: StyleProp<ViewStyle>;\n disableBackgroundClose?: boolean;\n enableKeyboardAvoid?: boolean;\n} & Omit<ModalProps, 'animationType' | 'onRequestClose'>;\n\n/**\n * Modal Open: Triggered by Modal.props.visible state changed to true\n * - visible true -> modalVisible true -> animation start\n *\n * Modal Close: Triggered by Modal.props.onClose() call\n * - Modal.props.onClose() -> visible false -> animation start -> modalVisible false\n * */\nconst Modal = ({\n children,\n onClose,\n backgroundStyle,\n onDismiss,\n type = 'fade',\n visible = false,\n disableBackgroundClose = false,\n enableKeyboardAvoid = false,\n statusBarTranslucent,\n ...props\n}: Props) => {\n const { palette } = useUIKitTheme();\n const { content, backdrop, showTransition, hideTransition } = useModalAnimation(type);\n const panResponder = useModalPanResponder(type, content.translateY, showTransition, onClose);\n const { topInset } = useHeaderStyle();\n\n const [modalVisible, setModalVisible] = useState(false);\n const showAction = () => setModalVisible(true);\n const hideAction = () => hideTransition(() => setModalVisible(false));\n\n const { width, height } = useWindowDimensions();\n\n useEffect(() => {\n if (visible) showAction();\n else hideAction();\n }, [visible]);\n\n useOnDismiss(modalVisible, onDismiss);\n\n return (\n <RNModal\n statusBarTranslucent={statusBarTranslucent}\n transparent\n hardwareAccelerated\n visible={modalVisible}\n onRequestClose={onClose}\n onShow={() => showTransition()}\n onDismiss={onDismiss}\n supportedOrientations={['portrait', 'portrait-upside-down', 'landscape', 'landscape-left', 'landscape-right']}\n animationType={'none'}\n {...props}\n >\n <TouchableWithoutFeedback onPress={disableBackgroundClose ? undefined : onClose}>\n <Animated.View\n style={[StyleSheet.absoluteFill, { opacity: backdrop.opacity, backgroundColor: palette.onBackgroundLight03 }]}\n />\n </TouchableWithoutFeedback>\n <KeyboardAvoidingView\n // NOTE: This is trick for Android.\n // When orientation is changed on Android, the offset that to avoid soft-keyboard is not updated normally.\n key={Platform.OS === 'android' && enableKeyboardAvoid ? `${width}-${height}` : undefined}\n enabled={enableKeyboardAvoid}\n style={styles.background}\n behavior={Platform.select({ ios: 'padding', default: 'height' })}\n pointerEvents={'box-none'}\n keyboardVerticalOffset={enableKeyboardAvoid && statusBarTranslucent ? -topInset : 0}\n >\n <Animated.View\n style={[\n styles.background,\n backgroundStyle,\n { opacity: content.opacity, transform: [{ translateY: content.translateY }] },\n ]}\n pointerEvents={'box-none'}\n {...panResponder.panHandlers}\n >\n <Pressable\n // NOTE: https://github.com/facebook/react-native/issues/14295\n // Due to 'Pressable', the width of the children must be explicitly specified as a number.\n >\n {children}\n </Pressable>\n </Animated.View>\n </KeyboardAvoidingView>\n </RNModal>\n );\n};\n\nconst isHideGesture = (distanceY: number, velocityY: number) => {\n return distanceY > 125 || (distanceY > 0 && velocityY > 0.1);\n};\nconst useModalPanResponder = (\n type: ModalAnimationType,\n translateY: Animated.Value,\n show: () => void,\n hide: () => void,\n) => {\n if (type === 'fade' || type === 'slide-no-gesture') return { panHandlers: {} };\n return React.useRef(\n PanResponder.create({\n onMoveShouldSetPanResponderCapture: (_, { dy }) => dy > 8,\n // @ts-ignore\n onPanResponderGrant: () => translateY.setOffset(translateY.__getValue()),\n onPanResponderMove: (_, { dy }) => dy >= 0 && translateY.setValue(dy), // Animated.event([null, { dy: translateY }], { useNativeDriver: false }),\n onPanResponderRelease: (_, { dy, vy }) => {\n if (isHideGesture(dy, vy)) hide();\n else show();\n },\n }),\n ).current;\n};\n\nconst useModalAnimation = (type: ModalAnimationType) => {\n const initialY = type === 'fade' ? 0 : Dimensions.get('window').height;\n const baseAnimBackground = useRef(new Animated.Value(0)).current;\n const baseAnimContent = useRef(new Animated.Value(initialY)).current;\n\n const content = {\n opacity: baseAnimBackground.interpolate({\n inputRange: [0, 1],\n outputRange: [type === 'fade' ? 0 : 1, 1],\n }),\n translateY: baseAnimContent,\n };\n const backdrop = {\n opacity: baseAnimBackground.interpolate({\n inputRange: [0, 1],\n outputRange: [0, 1],\n }),\n };\n const createTransition = (toValue: 0 | 1) => {\n const config = { duration: 250, useNativeDriver: false };\n return Animated.parallel([\n Animated.timing(baseAnimBackground, { toValue, ...config }),\n Animated.timing(baseAnimContent, { toValue: toValue === 0 ? initialY : 0, ...config }),\n ]).start;\n };\n return {\n content,\n backdrop,\n showTransition: createTransition(1),\n hideTransition: createTransition(0),\n };\n};\n\n// NOTE: onDismiss is supports iOS only\nconst useOnDismiss = (visible: boolean, onDismiss?: () => void) => {\n const prevVisible = usePrevProp(visible);\n useEffect(() => {\n if (Platform.OS === 'ios') return;\n if (prevVisible && !visible) onDismiss?.();\n }, [prevVisible, visible]);\n};\n\nconst usePrevProp = <T,>(prop: T) => {\n const prev = useRef(prop);\n const curr = useRef(prop);\n useEffect(() => {\n prev.current = curr.current;\n curr.current = prop;\n });\n return prev.current;\n};\n\nconst styles = createStyleSheet({\n background: { flex: 1 },\n});\n\nexport default Modal;\n"],"mapp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,IAAI,CAACrB,OAAO,GAAGmB,IAAI;EACrB,CAAC,CAAC;EACF,OAAOC,IAAI,CAACpB,OAAO;AACrB,CAAC;AAED,MAAM7B,MAAM,GAAGlD,gBAAgB,CAAC;EAC9BmD,UAAU,EAAE;IAAEkD,IAAI,EAAE;EAAE;AACxB,CAAC,CAAC;AAEF,eAAe1G,KAAK"}
|
|
1
|
+
{"version":3,"names":["React","useEffect","useRef","useState","Animated","Dimensions","KeyboardAvoidingView","PanResponder","Platform","Pressable","Modal","RNModal","StyleSheet","TouchableWithoutFeedback","useWindowDimensions","createStyleSheet","useHeaderStyle","useUIKitTheme","children","onClose","backgroundStyle","onDismiss","type","visible","disableBackgroundClose","enableKeyboardAvoid","statusBarTranslucent","props","palette","content","backdrop","showTransition","hideTransition","useModalAnimation","panResponder","useModalPanResponder","translateY","topInset","modalVisible","setModalVisible","showAction","hideAction","width","height","useOnDismiss","createElement","_extends","transparent","hardwareAccelerated","onRequestClose","onShow","supportedOrientations","animationType","onPress","undefined","View","style","absoluteFill","opacity","backgroundColor","onBackgroundLight03","key","OS","enabled","styles","background","behavior","select","ios","default","pointerEvents","keyboardVerticalOffset","transform","panHandlers","isHideGesture","distanceY","velocityY","show","hide","create","onMoveShouldSetPanResponderCapture","_","dy","onPanResponderGrant","setOffset","__getValue","onPanResponderMove","setValue","onPanResponderRelease","vy","current","initialY","get","baseAnimBackground","Value","baseAnimContent","interpolate","inputRange","outputRange","createTransition","toValue","config","duration","useNativeDriver","parallel","timing","start","prevVisible","usePrevProp","prop","prev","curr","flex"],"sources":["index.tsx"],"sourcesContent":["import React, { useEffect, useRef, useState } from 'react';\nimport {\n Animated,\n Dimensions,\n KeyboardAvoidingView,\n ModalProps,\n PanResponder,\n Platform,\n Pressable,\n Modal as RNModal,\n StyleProp,\n StyleSheet,\n TouchableWithoutFeedback,\n ViewStyle,\n useWindowDimensions,\n} from 'react-native';\n\nimport createStyleSheet from '../../styles/createStyleSheet';\nimport useHeaderStyle from '../../styles/useHeaderStyle';\nimport useUIKitTheme from '../../theme/useUIKitTheme';\n\ntype ModalAnimationType = 'slide' | 'slide-no-gesture' | 'fade';\ntype Props = {\n type?: ModalAnimationType;\n onClose: () => void;\n backgroundStyle?: StyleProp<ViewStyle>;\n disableBackgroundClose?: boolean;\n enableKeyboardAvoid?: boolean;\n} & Omit<ModalProps, 'animationType' | 'onRequestClose'>;\n\n/**\n * Modal Open: Triggered by Modal.props.visible state changed to true\n * - visible true -> modalVisible true -> animation start\n *\n * Modal Close: Triggered by Modal.props.onClose() call\n * - Modal.props.onClose() -> visible false -> animation start -> modalVisible false\n * */\nconst Modal = ({\n children,\n onClose,\n backgroundStyle,\n onDismiss,\n type = 'fade',\n visible = false,\n disableBackgroundClose = false,\n enableKeyboardAvoid = false,\n statusBarTranslucent,\n ...props\n}: Props) => {\n const { palette } = useUIKitTheme();\n const { content, backdrop, showTransition, hideTransition } = useModalAnimation(type);\n const panResponder = useModalPanResponder(type, content.translateY, showTransition, onClose);\n const { topInset } = useHeaderStyle();\n\n const [modalVisible, setModalVisible] = useState(false);\n const showAction = () => setModalVisible(true);\n const hideAction = () => hideTransition(() => setModalVisible(false));\n\n const { width, height } = useWindowDimensions();\n\n useEffect(() => {\n if (visible) showAction();\n else hideAction();\n }, [visible]);\n\n useOnDismiss(modalVisible, onDismiss);\n\n return (\n <RNModal\n statusBarTranslucent={statusBarTranslucent}\n transparent\n hardwareAccelerated\n visible={modalVisible}\n onRequestClose={onClose}\n onShow={() => showTransition()}\n onDismiss={onDismiss}\n supportedOrientations={['portrait', 'portrait-upside-down', 'landscape', 'landscape-left', 'landscape-right']}\n animationType={'none'}\n {...props}\n >\n <TouchableWithoutFeedback onPress={disableBackgroundClose ? undefined : onClose}>\n <Animated.View\n style={[StyleSheet.absoluteFill, { opacity: backdrop.opacity, backgroundColor: palette.onBackgroundLight03 }]}\n />\n </TouchableWithoutFeedback>\n <KeyboardAvoidingView\n // NOTE: This is trick for Android.\n // When orientation is changed on Android, the offset that to avoid soft-keyboard is not updated normally.\n key={Platform.OS === 'android' && enableKeyboardAvoid ? `${width}-${height}` : undefined}\n enabled={enableKeyboardAvoid}\n style={styles.background}\n behavior={Platform.select({ ios: 'padding', default: 'height' })}\n pointerEvents={'box-none'}\n keyboardVerticalOffset={enableKeyboardAvoid && statusBarTranslucent ? -topInset : 0}\n >\n <Animated.View\n style={[\n styles.background,\n backgroundStyle,\n { opacity: content.opacity, transform: [{ translateY: content.translateY }] },\n ]}\n pointerEvents={'box-none'}\n {...panResponder.panHandlers}\n >\n <Pressable\n // NOTE: https://github.com/facebook/react-native/issues/14295\n // Due to 'Pressable', the width of the children must be explicitly specified as a number.\n >\n {children}\n </Pressable>\n </Animated.View>\n </KeyboardAvoidingView>\n </RNModal>\n );\n};\n\nconst isHideGesture = (distanceY: number, velocityY: number) => {\n return distanceY > 125 || (distanceY > 0 && velocityY > 0.1);\n};\nconst useModalPanResponder = (\n type: ModalAnimationType,\n translateY: Animated.Value,\n show: () => void,\n hide: () => void,\n) => {\n if (type === 'fade' || type === 'slide-no-gesture') return { panHandlers: {} };\n return React.useRef(\n PanResponder.create({\n onMoveShouldSetPanResponderCapture: (_, { dy }) => dy > 8,\n // @ts-ignore\n onPanResponderGrant: () => translateY.setOffset(translateY.__getValue()),\n onPanResponderMove: (_, { dy }) => dy >= 0 && translateY.setValue(dy), // Animated.event([null, { dy: translateY }], { useNativeDriver: false }),\n onPanResponderRelease: (_, { dy, vy }) => {\n if (isHideGesture(dy, vy)) hide();\n else show();\n },\n }),\n ).current;\n};\n\nconst useModalAnimation = (type: ModalAnimationType) => {\n const initialY = type === 'fade' ? 0 : Dimensions.get('window').height;\n const baseAnimBackground = useRef(new Animated.Value(0)).current;\n const baseAnimContent = useRef(new Animated.Value(initialY)).current;\n\n const content = {\n opacity: baseAnimBackground.interpolate({\n inputRange: [0, 1],\n outputRange: [type === 'fade' ? 0 : 1, 1],\n }),\n translateY: baseAnimContent,\n };\n const backdrop = {\n opacity: baseAnimBackground.interpolate({\n inputRange: [0, 1],\n outputRange: [0, 1],\n }),\n };\n const createTransition = (toValue: 0 | 1) => {\n const config = { duration: 250, useNativeDriver: false };\n return Animated.parallel([\n Animated.timing(baseAnimBackground, { toValue, ...config }),\n Animated.timing(baseAnimContent, { toValue: toValue === 0 ? initialY : 0, ...config }),\n ]).start;\n };\n return {\n content,\n backdrop,\n showTransition: createTransition(1),\n hideTransition: createTransition(0),\n };\n};\n\n// NOTE: onDismiss is supports iOS only\nconst useOnDismiss = (visible: boolean, onDismiss?: () => void) => {\n const prevVisible = usePrevProp(visible);\n useEffect(() => {\n if (Platform.OS === 'ios') return;\n if (prevVisible && !visible) onDismiss?.();\n }, [prevVisible, visible]);\n};\n\nconst usePrevProp = <T,>(prop: T) => {\n const prev = useRef(prop);\n const curr = useRef(prop);\n useEffect(() => {\n prev.current = curr.current;\n curr.current = prop;\n });\n return prev.current;\n};\n\nconst styles = createStyleSheet({\n background: { flex: 1 },\n});\n\nexport default Modal;\n"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAC1D,SACEC,QAAQ,EACRC,UAAU,EACVC,oBAAoB,EAEpBC,YAAY,EACZC,QAAQ,EACRC,SAAS,EACTC,KAAK,IAAIC,OAAO,EAEhBC,UAAU,EACVC,wBAAwB,EAExBC,mBAAmB,QACd,cAAc;AAErB,OAAOC,gBAAgB,MAAM,+BAA+B;AAC5D,OAAOC,cAAc,MAAM,6BAA6B;AACxD,OAAOC,aAAa,MAAM,2BAA2B;AAWrD;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMP,KAAK,GAAGA,CAAC;EACbQ,QAAQ;EACRC,OAAO;EACPC,eAAe;EACfC,SAAS;EACTC,IAAI,GAAG,MAAM;EACbC,OAAO,GAAG,KAAK;EACfC,sBAAsB,GAAG,KAAK;EAC9BC,mBAAmB,GAAG,KAAK;EAC3BC,oBAAoB;EACpB,GAAGC;AACE,CAAC,KAA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