├── .eslintrc.js ├── .gitattributes ├── .github └── workflows │ └── coverage.yml ├── .gitignore ├── .npmignore ├── .prettierrc.js ├── LICENSE ├── README.md ├── babel.config.js ├── demo ├── badge-button.gif ├── badge.png ├── default.png ├── gravatar.png ├── hero.gif ├── initials.png ├── shape.png └── status.png ├── example ├── .bundle │ └── config ├── .gitignore ├── .watchmanconfig ├── App.tsx ├── App2.tsx ├── Gemfile ├── android │ ├── app │ │ ├── build.gradle │ │ ├── debug.keystore │ │ ├── proguard-rules.pro │ │ └── src │ │ │ ├── debug │ │ │ └── AndroidManifest.xml │ │ │ └── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ ├── MainActivity.kt │ │ │ │ └── MainApplication.kt │ │ │ └── res │ │ │ ├── drawable │ │ │ └── rn_edit_text_material.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── strings.xml │ │ │ └── styles.xml │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ ├── gradle-wrapper.jar │ │ │ └── gradle-wrapper.properties │ ├── gradlew │ ├── gradlew.bat │ └── settings.gradle ├── app.json ├── assets │ ├── custom.png │ ├── custom@2x.png │ └── custom@3x.png ├── babel.config.js ├── index.js ├── ios │ ├── .xcode.env │ ├── Podfile │ ├── Podfile.lock │ ├── example.xcodeproj │ │ ├── project.pbxproj │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── example.xcscheme │ ├── example.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ ├── example │ │ ├── AppDelegate.h │ │ ├── AppDelegate.mm │ │ ├── Images.xcassets │ │ │ ├── AppIcon.appiconset │ │ │ │ └── Contents.json │ │ │ └── Contents.json │ │ ├── Info.plist │ │ ├── LaunchScreen.storyboard │ │ ├── PrivacyInfo.xcprivacy │ │ └── main.m │ └── exampleTests │ │ ├── Info.plist │ │ └── exampleTests.m ├── metro.config.js ├── package.json └── yarn.lock ├── jest.config.js ├── package.json ├── src ├── Avatar.tsx ├── Badge.tsx ├── Initials.tsx ├── __tests__ │ ├── Avatar.tsx │ ├── Badge.tsx │ └── __snapshots__ │ │ ├── Avatar.tsx.snap │ │ └── Badge.tsx.snap ├── assets │ ├── custom.png │ ├── custom@2x.png │ ├── custom@3x.png │ ├── default.png │ ├── default@2x.png │ └── default@3x.png ├── helpers.ts └── index.tsx ├── tsconfig.json └── yarn.lock /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | root: true, 3 | extends: '@react-native', 4 | ignorePatterns: ['/coverage/*'], 5 | }; 6 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | # specific for windows script files 3 | *.bat text eol=crlf -------------------------------------------------------------------------------- /.github/workflows/coverage.yml: -------------------------------------------------------------------------------- 1 | name: 'coverage' 2 | on: 3 | pull_request: 4 | branches: 5 | - main 6 | jobs: 7 | coverage: 8 | permissions: 9 | checks: write 10 | pull-requests: write 11 | contents: write 12 | runs-on: ubuntu-latest 13 | steps: 14 | - uses: actions/checkout@v3 15 | - uses: actions/setup-node@v3 16 | with: 17 | node-version: 18 18 | - uses: ArtiomTr/jest-coverage-report-action@v2 19 | with: 20 | package-manager: yarn 21 | test-script: yarn validate-ci 22 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # OSX 2 | # 3 | .DS_Store 4 | 5 | # node.js 6 | # 7 | node_modules/ 8 | npm-debug.log 9 | yarn-debug.log 10 | yarn-error.log 11 | 12 | # testing 13 | /coverage 14 | -------------------------------------------------------------------------------- /.npmignore: -------------------------------------------------------------------------------- 1 | coverage/ 2 | example/ 3 | demo/ 4 | -------------------------------------------------------------------------------- /.prettierrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | semi: true, 3 | tabWidth: 2, 4 | useTabs: false, 5 | printWidth: 100, 6 | singleQuote: true, 7 | bracketSpacing: true, 8 | bracketSameLine: false, 9 | trailingComma: "all" 10 | }; 11 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Nick Seryakov 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # React Native Avatar 2 | 3 | 4 | 5 | 8 | 11 | 12 |
6 | 7 | 9 | The ultimate React Native component for displaying user avatars written in TypeScript with a strong focus on performance. This fully featured and highly customizable component allows you to show Gravatar images by providing an email address, fallback to user's initials, fine-tune the shape and size of avatars, add badges and custom statuses to the avatar image. 10 |
13 | 14 | --- 15 | 16 | 17 | 18 | **Control the shape of the avatars** 19 | The default circular shape can be changed by specifying a custom border radius. The `style` prop enables you to override the default styles. 20 | 21 | --- 22 | 23 | 24 | 25 | **Custom fallback image or emoji** 26 | For users without an image, you have the option to display the default avatar icon, provide a custom fallback image, or even show an emoji. 27 | 28 | --- 29 | 30 | 31 | 32 | **Fallback to user's initials** 33 | Another option for users without an image is to display their initials. By enabling the `colorize` option, unique color can be generated based on the user's name. 34 | 35 | --- 36 | 37 | 38 | 39 | **Gravatar support** 40 | Include the user's email address to display their Gravatar image. This can be combined with your own avatar image to provide a fallback option. 41 | 42 | --- 43 | 44 | 45 | 46 | **Numeric badges** 47 | You can add a badge to display the count of unread messages or the online/offline status of the user. The position of the badge can also be customized. 48 | 49 | --- 50 | 51 | 52 | 53 | **Custom badges** 54 | Another option for utilizing avatar badges is to display a custom status icon, such as an emoji, for example. 55 | 56 | --- 57 | 58 | ## Installation 59 | 60 | ### yarn 61 | ```sh 62 | yarn add @kolking/react-native-avatar 63 | ``` 64 | ### npm 65 | ```sh 66 | npm install @kolking/react-native-avatar 67 | ``` 68 | 69 | ## Basic Example 70 | 71 | ```jsx 72 | import React from 'react'; 73 | import { View, StyleSheet } from 'react-native'; 74 | import { Avatar } from '@kolking/react-native-avatar'; 75 | 76 | const MyComponent = ({ userImage, userEmail }) => ( 77 | 78 | 79 | 80 | ); 81 | 82 | const styles = StyleSheet.create({ 83 | wrapper: { 84 | flex: 1, 85 | alignItems: 'center', 86 | justifyContent: 'center', 87 | }, 88 | }); 89 | 90 | export default MyComponent; 91 | ``` 92 | 93 | ## Advanced Example 94 | 95 | ```jsx 96 | import React from 'react'; 97 | import { View, StyleSheet } from 'react-native'; 98 | import { Avatar } from '@kolking/react-native-avatar'; 99 | 100 | const defaultImage = require('./assets/defaultAvatar.png'); 101 | const badgeProps = { 102 | size: 24, 103 | radius: 5, 104 | position: 'top-left', 105 | } 106 | 107 | const MyComponent = ({ userImage, userEmail, userName, unreadCount }) => ( 108 | 109 | 121 | 122 | ); 123 | 124 | const styles = StyleSheet.create({ 125 | wrapper: { 126 | flex: 1, 127 | alignItems: 'center', 128 | justifyContent: 'center', 129 | }, 130 | }); 131 | 132 | export default MyComponent; 133 | ``` 134 | 135 | ## Props 136 | 137 | Prop | Type | Default | Description 138 | ---|---|---|--- 139 | `size` | number | `50` | Width and height of the avatar 140 | `name` | string | | User name for showing initials 141 | `email` | string | | User email for showing Gravatar image 142 | `source` | ImageSourcePropType | | The avatar image source (either a remote URL or a local file resource) 143 | `defaultSource` | ImageSourcePropType | | The fallback image source 144 | `color` | string | `#aeaeb2` | Background color of the avatar 145 | `radius` | number | `size / 2` | Border radius of the avatar 146 | `colorize` | boolean | `false` | To generate a unique background color when displaying initials 147 | `style` | ViewStyle | | Style object applied to the image or initials container 148 | `textStyle` | TextStyle | | Style object applied to the initials text 149 | `badge` | number \| string \| boolean | | A number or string value to show in the badge, or `true` to display a color dot 150 | `badgeColor` | string | | Background color of the badge 151 | `badgeProps` | BadgeProps | | [Badge props](#badge-props) excluding `value`, `color`, and `parentRadius` 152 | 153 | ## Badge Component 154 | 155 | 156 | 157 | The badge can be used as a standalone component. The font size of the badge text value is calculated based on the `size` prop, so you normally don't have to specify it. By default, the badge appears with a spring animation, which can be disabled using the `animate` prop. To position the badge absolutely over its parent, use the `position` prop along with the `parentRadius` prop. 158 | 159 |
160 | 161 | ```jsx 162 | import React, { useState } from 'react'; 163 | import { StyleSheet, Text, TouchableHighlight, View } from 'react-native'; 164 | import { Badge } from '@kolking/react-native-avatar'; 165 | 166 | const MyComponent = () => { 167 | const [badge, setBadge] = useState(0); 168 | 169 | return ( 170 | 171 | setBadge(badge + 1)} 175 | > 176 | <> 177 | Press me 178 | 179 | 180 | 181 | 182 | ); 183 | }; 184 | 185 | const styles = StyleSheet.create({ 186 | wrapper: { 187 | flex: 1, 188 | alignItems: 'center', 189 | justifyContent: 'center', 190 | }, 191 | button: { 192 | width: 200, 193 | height: 44, 194 | marginTop: 20, 195 | borderRadius: 22, 196 | alignSelf: 'center', 197 | alignItems: 'center', 198 | justifyContent: 'center', 199 | backgroundColor: '#2FAFC7', 200 | }, 201 | buttonText: { 202 | color: '#fff', 203 | fontSize: 17, 204 | fontWeight: '600', 205 | }, 206 | }); 207 | 208 | export default MyComponent; 209 | ``` 210 | 211 | ## Badge Props 212 | 213 | Prop | Type | Default | Description 214 | ---|---|---|--- 215 | `size` | number | `20` | Height and min width of the badge 216 | `color` | string | `#ff3b30` | Background color of the badge 217 | `radius` | number | `size / 2` | Border radius of the badge 218 | `animate` | boolean | `true` | To animate appearance with a spring animation 219 | `value` | number \| boolean \| string | | A number or string value to show in the badge, or `true` to display a color dot 220 | `limit` | number | `99` | To display "99+" when the `value` exceeds the limit, set `0` to disable 221 | `parentRadius` | number | `0` | Border radius of the parent container, used to position the badge more precisely 222 | `position` | BadgePositions | | To position the badge absolutely over its parent, the allowed options are `top-left`, `top-right`, `bottom-left`, and `bottom-right` 223 | `style` | ViewStyle | | Style object applied to the container 224 | `textStyle` | TextStyle | | Style object applied to the text 225 | 226 | ## Feedback 227 | 228 | I appreciate your feedback, so please star the repository if you like it. This is the best motivation for me to maintain the package and add new features. If you have any feature requests, found a bug, or have ideas for improvement, feel free to [open an issue](https://github.com/kolking/react-native-avatar/issues). 229 | 230 | Also, please check out my other React Native components that might be a good fit for your project: 231 | 232 | - [React Native Rating](https://github.com/kolking/react-native-rating) - An interactive rating component. 233 | - [React Native Page Indicator](https://github.com/kolking/react-native-page-indicator) - Show the current page of a swiper, slideshow, carousel, etc. 234 | - [React Native Parallax Swiper](https://github.com/kolking/react-native-parallax-swiper) - Build a horizontal scroll swiper with a parallax effect. 235 | - [React Native Crossfade Image](https://github.com/kolking/react-native-crossfade-image) - Update image source with crossfade transition effect. 236 | 237 | ## License 238 | 239 | Licensed under the MIT license. 240 | -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['module:@react-native/babel-preset'], 3 | }; 4 | -------------------------------------------------------------------------------- /demo/badge-button.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/badge-button.gif -------------------------------------------------------------------------------- /demo/badge.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/badge.png -------------------------------------------------------------------------------- /demo/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/default.png -------------------------------------------------------------------------------- /demo/gravatar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/gravatar.png -------------------------------------------------------------------------------- /demo/hero.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/hero.gif -------------------------------------------------------------------------------- /demo/initials.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/initials.png -------------------------------------------------------------------------------- /demo/shape.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/shape.png -------------------------------------------------------------------------------- /demo/status.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/demo/status.png -------------------------------------------------------------------------------- /example/.bundle/config: -------------------------------------------------------------------------------- 1 | BUNDLE_PATH: "vendor/bundle" 2 | BUNDLE_FORCE_RUBY_PLATFORM: 1 3 | -------------------------------------------------------------------------------- /example/.gitignore: -------------------------------------------------------------------------------- 1 | # OSX 2 | # 3 | .DS_Store 4 | 5 | # Xcode 6 | # 7 | build/ 8 | *.pbxuser 9 | !default.pbxuser 10 | *.mode1v3 11 | !default.mode1v3 12 | *.mode2v3 13 | !default.mode2v3 14 | *.perspectivev3 15 | !default.perspectivev3 16 | xcuserdata 17 | *.xccheckout 18 | *.moved-aside 19 | DerivedData 20 | *.hmap 21 | *.ipa 22 | *.xcuserstate 23 | **/.xcode.env.local 24 | 25 | # Android/IntelliJ 26 | # 27 | build/ 28 | .idea 29 | .gradle 30 | local.properties 31 | *.iml 32 | *.hprof 33 | .cxx/ 34 | *.keystore 35 | !debug.keystore 36 | 37 | # node.js 38 | # 39 | node_modules/ 40 | npm-debug.log 41 | yarn-error.log 42 | 43 | # fastlane 44 | # 45 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the 46 | # screenshots whenever they are needed. 47 | # For more information about the recommended setup visit: 48 | # https://docs.fastlane.tools/best-practices/source-control/ 49 | 50 | **/fastlane/report.xml 51 | **/fastlane/Preview.html 52 | **/fastlane/screenshots 53 | **/fastlane/test_output 54 | 55 | # Bundle artifact 56 | *.jsbundle 57 | 58 | # Ruby / CocoaPods 59 | **/Pods/ 60 | /vendor/bundle/ 61 | 62 | # Temporary files created by Metro to check the health of the file watcher 63 | .metro-health-check* 64 | 65 | # testing 66 | /coverage 67 | 68 | # Yarn 69 | .yarn/* 70 | !.yarn/patches 71 | !.yarn/plugins 72 | !.yarn/releases 73 | !.yarn/sdks 74 | !.yarn/versions 75 | -------------------------------------------------------------------------------- /example/.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} 2 | -------------------------------------------------------------------------------- /example/App.tsx: -------------------------------------------------------------------------------- 1 | import React, { useCallback, useState } from 'react'; 2 | import { 3 | Appearance, 4 | ImageSourcePropType, 5 | StatusBar, 6 | StyleSheet, 7 | Text, 8 | TouchableHighlight, 9 | View, 10 | } from 'react-native'; 11 | import { Badge, Avatar, AvatarProps } from '@kolking/react-native-avatar'; 12 | 13 | StatusBar.setBarStyle('light-content'); 14 | 15 | function colorScheme(lightColor: string, darkColor: string) { 16 | return Appearance.getColorScheme() === 'dark' ? darkColor : lightColor; 17 | } 18 | 19 | const IMAGES = [ 20 | { uri: 'https://example.com/image.png' }, 21 | { uri: 'https://xsgames.co/randomusers/assets/avatars/female/44.jpg' }, 22 | { uri: 'https://xsgames.co/randomusers/assets/avatars/male/42.jpg' }, 23 | { uri: 'https://xsgames.co/randomusers/assets/avatars/female/38.jpg' }, 24 | { uri: 'https://xsgames.co/randomusers/assets/avatars/male/73.jpg' }, 25 | { uri: 'https://xsgames.co/randomusers/assets/avatars/female/2.jpg' }, 26 | { uri: 'https://xsgames.co/randomusers/assets/avatars/male/46.jpg' }, 27 | ]; 28 | 29 | const App = () => { 30 | const [badge, setBadge] = useState(0); 31 | const [image, setImage] = useState(1); 32 | const [badImage, setBadImage] = useState(); 33 | 34 | const toggleBadge = useCallback(() => { 35 | console.log('-- STATE UPDATED --'); 36 | setBadge(badge === 5 ? 0 : badge + 1); 37 | }, [badge]); 38 | 39 | const toggleImage = useCallback(() => { 40 | console.log('-- STATE UPDATED --'); 41 | setImage(image + 1 === IMAGES.length ? 0 : image + 1); 42 | }, [image]); 43 | 44 | const toggleBadImage = useCallback(() => { 45 | console.log('-- STATE UPDATED --'); 46 | setBadImage(badImage ? undefined : IMAGES[0]); 47 | }, [badImage]); 48 | 49 | return ( 50 | 51 | 52 | Shape 53 | 54 | 55 | 56 | 57 | 58 | 59 | No image 60 | 61 | 62 | 63 | 64 | 65 | 66 | Initials 67 | 68 | 69 | 70 | 71 | 72 | 73 | Image 74 | 75 | 76 | 77 | 78 | 79 | 80 | Gravatar 81 | 82 | 83 | 84 | 85 | 86 | 87 | Badge 88 | 89 | 90 | 91 | 96 | 97 | 98 | Status 99 | 100 | 101 | 102 | 103 | 104 | Size 105 | 106 | 107 | 108 | 109 | 115 | <> 116 | Press me 117 | 118 | 119 | 120 | 121 | ); 122 | }; 123 | 124 | const styles = StyleSheet.create({ 125 | container: { 126 | flex: 1, 127 | padding: 30, 128 | justifyContent: 'center', 129 | backgroundColor: colorScheme('#fff', '#212124'), 130 | }, 131 | row: { 132 | marginVertical: 10, 133 | flexDirection: 'row', 134 | alignItems: 'center', 135 | justifyContent: 'space-between', 136 | }, 137 | label: { 138 | fontSize: 15, 139 | flexBasis: '35%', 140 | fontWeight: '700', 141 | color: colorScheme('#000', '#fff'), 142 | }, 143 | badgeStyle: { 144 | elevation: 0, 145 | shadowOpacity: 0, 146 | backgroundColor: colorScheme('#fff', '#212124'), 147 | }, 148 | badgeTextStyle: { 149 | marginHorizontal: 0, 150 | }, 151 | button: { 152 | width: 150, 153 | height: 44, 154 | marginTop: 20, 155 | borderRadius: 22, 156 | alignSelf: 'center', 157 | alignItems: 'center', 158 | justifyContent: 'center', 159 | backgroundColor: '#2FAFC7', 160 | }, 161 | buttonText: { 162 | color: '#fff', 163 | fontSize: 17, 164 | fontWeight: '600', 165 | }, 166 | }); 167 | 168 | const statusBadgeProps: AvatarProps['badgeProps'] = { 169 | size: 22, 170 | position: 'bottom-right', 171 | style: styles.badgeStyle, 172 | textStyle: styles.badgeTextStyle, 173 | }; 174 | 175 | export default App; 176 | -------------------------------------------------------------------------------- /example/App2.tsx: -------------------------------------------------------------------------------- 1 | import React, { useCallback, useState } from 'react'; 2 | import { Pressable, StyleSheet, View } from 'react-native'; 3 | import { Avatar, AvatarProps } from '@kolking/react-native-avatar'; 4 | 5 | const badgeProps: AvatarProps[] = [ 6 | { 7 | defaultSource: require('./assets/custom.png'), 8 | }, 9 | { 10 | name: '👩🏼', 11 | }, 12 | { 13 | name: 'React Native', 14 | colorize: true, 15 | }, 16 | { 17 | badge: 0, 18 | badgeProps: { size: 30 }, 19 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/44.jpg' }, 20 | }, 21 | { 22 | badge: 3, 23 | badgeProps: { size: 30 }, 24 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/44.jpg' }, 25 | }, 26 | { 27 | badge: 4, 28 | badgeProps: { size: 30 }, 29 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/44.jpg' }, 30 | radius: 40, 31 | }, 32 | { 33 | badge: 5, 34 | badgeProps: { size: 30 }, 35 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/44.jpg' }, 36 | radius: 30, 37 | }, 38 | { 39 | badge: false, 40 | badgeProps: { size: 30 }, 41 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/male/73.jpg' }, 42 | }, 43 | { 44 | badge: true, 45 | badgeColor: '#34c759', 46 | badgeProps: { size: 30 }, 47 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/male/73.jpg' }, 48 | }, 49 | { 50 | badge: '', 51 | badgeProps: { size: 30 }, 52 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/38.jpg' }, 53 | }, 54 | { 55 | badge: '👋', 56 | badgeProps: { 57 | size: 30, 58 | position: 'bottom-right', 59 | style: { 60 | elevation: 0, 61 | shadowOpacity: 0, 62 | backgroundColor: '#212124', 63 | }, 64 | textStyle: { 65 | marginHorizontal: 0, 66 | }, 67 | }, 68 | source: { uri: 'https://xsgames.co/randomusers/assets/avatars/female/38.jpg' }, 69 | }, 70 | ]; 71 | 72 | const App = () => { 73 | const [props, setProps] = useState(0); 74 | 75 | const toggleProps = useCallback(() => { 76 | setProps(props + 1 === badgeProps.length ? 0 : props + 1); 77 | }, [props]); 78 | 79 | return ( 80 | 81 | 82 | 83 | 84 | 85 | ); 86 | }; 87 | 88 | const styles = StyleSheet.create({ 89 | wrapper: { 90 | flex: 1, 91 | alignItems: 'center', 92 | justifyContent: 'center', 93 | backgroundColor: '#212124', 94 | }, 95 | button: { 96 | width: 200, 97 | height: 44, 98 | marginTop: 20, 99 | borderRadius: 22, 100 | alignSelf: 'center', 101 | alignItems: 'center', 102 | justifyContent: 'center', 103 | backgroundColor: '#2FAFC7', 104 | }, 105 | buttonText: { 106 | color: '#fff', 107 | fontSize: 17, 108 | fontWeight: '600', 109 | }, 110 | }); 111 | 112 | export default App; 113 | -------------------------------------------------------------------------------- /example/Gemfile: -------------------------------------------------------------------------------- 1 | source 'https://rubygems.org' 2 | 3 | # You may use http://rbenv.org/ or https://rvm.io/ to install and use this version 4 | ruby ">= 2.6.10" 5 | 6 | # Cocoapods 1.15 introduced a bug which break the build. We will remove the upper 7 | # bound in the template on Cocoapods with next React Native release. 8 | gem 'cocoapods', '>= 1.13', '< 1.15' 9 | gem 'activesupport', '>= 6.1.7.5', '< 7.1.0' 10 | -------------------------------------------------------------------------------- /example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | apply plugin: "org.jetbrains.kotlin.android" 3 | apply plugin: "com.facebook.react" 4 | 5 | /** 6 | * This is the configuration block to customize your React Native Android app. 7 | * By default you don't need to apply any configuration, just uncomment the lines you need. 8 | */ 9 | react { 10 | /* Folders */ 11 | // The root of your project, i.e. where "package.json" lives. Default is '..' 12 | // root = file("../") 13 | // The folder where the react-native NPM package is. Default is ../node_modules/react-native 14 | // reactNativeDir = file("../node_modules/react-native") 15 | // The folder where the react-native Codegen package is. Default is ../node_modules/@react-native/codegen 16 | // codegenDir = file("../node_modules/@react-native/codegen") 17 | // The cli.js file which is the React Native CLI entrypoint. Default is ../node_modules/react-native/cli.js 18 | // cliFile = file("../node_modules/react-native/cli.js") 19 | 20 | /* Variants */ 21 | // The list of variants to that are debuggable. For those we're going to 22 | // skip the bundling of the JS bundle and the assets. By default is just 'debug'. 23 | // If you add flavors like lite, prod, etc. you'll have to list your debuggableVariants. 24 | // debuggableVariants = ["liteDebug", "prodDebug"] 25 | 26 | /* Bundling */ 27 | // A list containing the node command and its flags. Default is just 'node'. 28 | // nodeExecutableAndArgs = ["node"] 29 | // 30 | // The command to run when bundling. By default is 'bundle' 31 | // bundleCommand = "ram-bundle" 32 | // 33 | // The path to the CLI configuration file. Default is empty. 34 | // bundleConfig = file(../rn-cli.config.js) 35 | // 36 | // The name of the generated asset file containing your JS bundle 37 | // bundleAssetName = "MyApplication.android.bundle" 38 | // 39 | // The entry file for bundle generation. Default is 'index.android.js' or 'index.js' 40 | // entryFile = file("../js/MyApplication.android.js") 41 | // 42 | // A list of extra flags to pass to the 'bundle' commands. 43 | // See https://github.com/react-native-community/cli/blob/main/docs/commands.md#bundle 44 | // extraPackagerArgs = [] 45 | 46 | /* Hermes Commands */ 47 | // The hermes compiler command to run. By default it is 'hermesc' 48 | // hermesCommand = "$rootDir/my-custom-hermesc/bin/hermesc" 49 | // 50 | // The list of flags to pass to the Hermes compiler. By default is "-O", "-output-source-map" 51 | // hermesFlags = ["-O", "-output-source-map"] 52 | } 53 | 54 | /** 55 | * Set this to true to Run Proguard on Release builds to minify the Java bytecode. 56 | */ 57 | def enableProguardInReleaseBuilds = false 58 | 59 | /** 60 | * The preferred build flavor of JavaScriptCore (JSC) 61 | * 62 | * For example, to use the international variant, you can use: 63 | * `def jscFlavor = 'org.webkit:android-jsc-intl:+'` 64 | * 65 | * The international variant includes ICU i18n library and necessary data 66 | * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that 67 | * give correct results when using with locales other than en-US. Note that 68 | * this variant is about 6MiB larger per architecture than default. 69 | */ 70 | def jscFlavor = 'org.webkit:android-jsc:+' 71 | 72 | android { 73 | ndkVersion rootProject.ext.ndkVersion 74 | buildToolsVersion rootProject.ext.buildToolsVersion 75 | compileSdk rootProject.ext.compileSdkVersion 76 | 77 | namespace "com.example" 78 | defaultConfig { 79 | applicationId "com.example" 80 | minSdkVersion rootProject.ext.minSdkVersion 81 | targetSdkVersion rootProject.ext.targetSdkVersion 82 | versionCode 1 83 | versionName "1.0" 84 | } 85 | signingConfigs { 86 | debug { 87 | storeFile file('debug.keystore') 88 | storePassword 'android' 89 | keyAlias 'androiddebugkey' 90 | keyPassword 'android' 91 | } 92 | } 93 | buildTypes { 94 | debug { 95 | signingConfig signingConfigs.debug 96 | } 97 | release { 98 | // Caution! In production, you need to generate your own keystore file. 99 | // see https://reactnative.dev/docs/signed-apk-android. 100 | signingConfig signingConfigs.debug 101 | minifyEnabled enableProguardInReleaseBuilds 102 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 103 | } 104 | } 105 | } 106 | 107 | dependencies { 108 | // The version of react-native is set by the React Native Gradle Plugin 109 | implementation("com.facebook.react:react-android") 110 | 111 | if (hermesEnabled.toBoolean()) { 112 | implementation("com.facebook.react:hermes-android") 113 | } else { 114 | implementation jscFlavor 115 | } 116 | } 117 | 118 | apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project) 119 | -------------------------------------------------------------------------------- /example/android/app/debug.keystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/debug.keystore -------------------------------------------------------------------------------- /example/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | -------------------------------------------------------------------------------- /example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 9 | 10 | -------------------------------------------------------------------------------- /example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 12 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.example 2 | 3 | import com.facebook.react.ReactActivity 4 | import com.facebook.react.ReactActivityDelegate 5 | import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.fabricEnabled 6 | import com.facebook.react.defaults.DefaultReactActivityDelegate 7 | 8 | class MainActivity : ReactActivity() { 9 | 10 | /** 11 | * Returns the name of the main component registered from JavaScript. This is used to schedule 12 | * rendering of the component. 13 | */ 14 | override fun getMainComponentName(): String = "example" 15 | 16 | /** 17 | * Returns the instance of the [ReactActivityDelegate]. We use [DefaultReactActivityDelegate] 18 | * which allows you to enable New Architecture with a single boolean flags [fabricEnabled] 19 | */ 20 | override fun createReactActivityDelegate(): ReactActivityDelegate = 21 | DefaultReactActivityDelegate(this, mainComponentName, fabricEnabled) 22 | } 23 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/example/MainApplication.kt: -------------------------------------------------------------------------------- 1 | package com.example 2 | 3 | import android.app.Application 4 | import com.facebook.react.PackageList 5 | import com.facebook.react.ReactApplication 6 | import com.facebook.react.ReactHost 7 | import com.facebook.react.ReactNativeHost 8 | import com.facebook.react.ReactPackage 9 | import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.load 10 | import com.facebook.react.defaults.DefaultReactHost.getDefaultReactHost 11 | import com.facebook.react.defaults.DefaultReactNativeHost 12 | import com.facebook.soloader.SoLoader 13 | 14 | class MainApplication : Application(), ReactApplication { 15 | 16 | override val reactNativeHost: ReactNativeHost = 17 | object : DefaultReactNativeHost(this) { 18 | override fun getPackages(): List = 19 | PackageList(this).packages.apply { 20 | // Packages that cannot be autolinked yet can be added manually here, for example: 21 | // add(MyReactNativePackage()) 22 | } 23 | 24 | override fun getJSMainModuleName(): String = "index" 25 | 26 | override fun getUseDeveloperSupport(): Boolean = BuildConfig.DEBUG 27 | 28 | override val isNewArchEnabled: Boolean = BuildConfig.IS_NEW_ARCHITECTURE_ENABLED 29 | override val isHermesEnabled: Boolean = BuildConfig.IS_HERMES_ENABLED 30 | } 31 | 32 | override val reactHost: ReactHost 33 | get() = getDefaultReactHost(applicationContext, reactNativeHost) 34 | 35 | override fun onCreate() { 36 | super.onCreate() 37 | SoLoader.init(this, false) 38 | if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) { 39 | // If you opted-in for the New Architecture, we load the native entry point for this app. 40 | load() 41 | } 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/drawable/rn_edit_text_material.xml: -------------------------------------------------------------------------------- 1 | 2 | 16 | 22 | 23 | 24 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | example 3 | 4 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /example/android/build.gradle: -------------------------------------------------------------------------------- 1 | buildscript { 2 | ext { 3 | buildToolsVersion = "34.0.0" 4 | minSdkVersion = 23 5 | compileSdkVersion = 34 6 | targetSdkVersion = 34 7 | ndkVersion = "26.1.10909125" 8 | kotlinVersion = "1.9.22" 9 | } 10 | repositories { 11 | google() 12 | mavenCentral() 13 | } 14 | dependencies { 15 | classpath("com.android.tools.build:gradle") 16 | classpath("com.facebook.react:react-native-gradle-plugin") 17 | classpath("org.jetbrains.kotlin:kotlin-gradle-plugin") 18 | } 19 | } 20 | 21 | apply plugin: "com.facebook.react.rootproject" 22 | -------------------------------------------------------------------------------- /example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx512m -XX:MaxMetaspaceSize=256m 13 | org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | # AndroidX package structure to make it clearer which packages are bundled with the 21 | # Android operating system, and which are packaged with your app's APK 22 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 23 | android.useAndroidX=true 24 | # Automatically convert third-party libraries to use AndroidX 25 | android.enableJetifier=true 26 | 27 | # Use this property to specify which architecture you want to build. 28 | # You can also override it from the CLI using 29 | # ./gradlew -PreactNativeArchitectures=x86_64 30 | reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64 31 | 32 | # Use this property to enable support to the new architecture. 33 | # This will allow you to use TurboModules and the Fabric render in 34 | # your application. You should enable this flag either if you want 35 | # to write custom TurboModules/Fabric components OR use libraries that 36 | # are providing them. 37 | newArchEnabled=false 38 | 39 | # Use this property to enable or disable the Hermes JS engine. 40 | # If set to false, you will be using JSC instead. 41 | hermesEnabled=true 42 | -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.6-all.zip 4 | networkTimeout=10000 5 | validateDistributionUrl=true 6 | zipStoreBase=GRADLE_USER_HOME 7 | zipStorePath=wrapper/dists 8 | -------------------------------------------------------------------------------- /example/android/gradlew: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # 4 | # Copyright © 2015-2021 the original authors. 5 | # 6 | # Licensed under the Apache License, Version 2.0 (the "License"); 7 | # you may not use this file except in compliance with the License. 8 | # You may obtain a copy of the License at 9 | # 10 | # https://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | 19 | ############################################################################## 20 | # 21 | # Gradle start up script for POSIX generated by Gradle. 22 | # 23 | # Important for running: 24 | # 25 | # (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is 26 | # noncompliant, but you have some other compliant shell such as ksh or 27 | # bash, then to run this script, type that shell name before the whole 28 | # command line, like: 29 | # 30 | # ksh Gradle 31 | # 32 | # Busybox and similar reduced shells will NOT work, because this script 33 | # requires all of these POSIX shell features: 34 | # * functions; 35 | # * expansions «$var», «${var}», «${var:-default}», «${var+SET}», 36 | # «${var#prefix}», «${var%suffix}», and «$( cmd )»; 37 | # * compound commands having a testable exit status, especially «case»; 38 | # * various built-in commands including «command», «set», and «ulimit». 39 | # 40 | # Important for patching: 41 | # 42 | # (2) This script targets any POSIX shell, so it avoids extensions provided 43 | # by Bash, Ksh, etc; in particular arrays are avoided. 44 | # 45 | # The "traditional" practice of packing multiple parameters into a 46 | # space-separated string is a well documented source of bugs and security 47 | # problems, so this is (mostly) avoided, by progressively accumulating 48 | # options in "$@", and eventually passing that to Java. 49 | # 50 | # Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, 51 | # and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; 52 | # see the in-line comments for details. 53 | # 54 | # There are tweaks for specific operating systems such as AIX, CygWin, 55 | # Darwin, MinGW, and NonStop. 56 | # 57 | # (3) This script is generated from the Groovy template 58 | # https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt 59 | # within the Gradle project. 60 | # 61 | # You can find Gradle at https://github.com/gradle/gradle/. 62 | # 63 | ############################################################################## 64 | 65 | # Attempt to set APP_HOME 66 | 67 | # Resolve links: $0 may be a link 68 | app_path=$0 69 | 70 | # Need this for daisy-chained symlinks. 71 | while 72 | APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path 73 | [ -h "$app_path" ] 74 | do 75 | ls=$( ls -ld "$app_path" ) 76 | link=${ls#*' -> '} 77 | case $link in #( 78 | /*) app_path=$link ;; #( 79 | *) app_path=$APP_HOME$link ;; 80 | esac 81 | done 82 | 83 | # This is normally unused 84 | # shellcheck disable=SC2034 85 | APP_BASE_NAME=${0##*/} 86 | # Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036) 87 | APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit 88 | 89 | # Use the maximum available, or set MAX_FD != -1 to use that value. 90 | MAX_FD=maximum 91 | 92 | warn () { 93 | echo "$*" 94 | } >&2 95 | 96 | die () { 97 | echo 98 | echo "$*" 99 | echo 100 | exit 1 101 | } >&2 102 | 103 | # OS specific support (must be 'true' or 'false'). 104 | cygwin=false 105 | msys=false 106 | darwin=false 107 | nonstop=false 108 | case "$( uname )" in #( 109 | CYGWIN* ) cygwin=true ;; #( 110 | Darwin* ) darwin=true ;; #( 111 | MSYS* | MINGW* ) msys=true ;; #( 112 | NONSTOP* ) nonstop=true ;; 113 | esac 114 | 115 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 116 | 117 | 118 | # Determine the Java command to use to start the JVM. 119 | if [ -n "$JAVA_HOME" ] ; then 120 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 121 | # IBM's JDK on AIX uses strange locations for the executables 122 | JAVACMD=$JAVA_HOME/jre/sh/java 123 | else 124 | JAVACMD=$JAVA_HOME/bin/java 125 | fi 126 | if [ ! -x "$JAVACMD" ] ; then 127 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 128 | 129 | Please set the JAVA_HOME variable in your environment to match the 130 | location of your Java installation." 131 | fi 132 | else 133 | JAVACMD=java 134 | if ! command -v java >/dev/null 2>&1 135 | then 136 | die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 137 | 138 | Please set the JAVA_HOME variable in your environment to match the 139 | location of your Java installation." 140 | fi 141 | fi 142 | 143 | # Increase the maximum file descriptors if we can. 144 | if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then 145 | case $MAX_FD in #( 146 | max*) 147 | # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. 148 | # shellcheck disable=SC2039,SC3045 149 | MAX_FD=$( ulimit -H -n ) || 150 | warn "Could not query maximum file descriptor limit" 151 | esac 152 | case $MAX_FD in #( 153 | '' | soft) :;; #( 154 | *) 155 | # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. 156 | # shellcheck disable=SC2039,SC3045 157 | ulimit -n "$MAX_FD" || 158 | warn "Could not set maximum file descriptor limit to $MAX_FD" 159 | esac 160 | fi 161 | 162 | # Collect all arguments for the java command, stacking in reverse order: 163 | # * args from the command line 164 | # * the main class name 165 | # * -classpath 166 | # * -D...appname settings 167 | # * --module-path (only if needed) 168 | # * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. 169 | 170 | # For Cygwin or MSYS, switch paths to Windows format before running java 171 | if "$cygwin" || "$msys" ; then 172 | APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) 173 | CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) 174 | 175 | JAVACMD=$( cygpath --unix "$JAVACMD" ) 176 | 177 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 178 | for arg do 179 | if 180 | case $arg in #( 181 | -*) false ;; # don't mess with options #( 182 | /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath 183 | [ -e "$t" ] ;; #( 184 | *) false ;; 185 | esac 186 | then 187 | arg=$( cygpath --path --ignore --mixed "$arg" ) 188 | fi 189 | # Roll the args list around exactly as many times as the number of 190 | # args, so each arg winds up back in the position where it started, but 191 | # possibly modified. 192 | # 193 | # NB: a `for` loop captures its iteration list before it begins, so 194 | # changing the positional parameters here affects neither the number of 195 | # iterations, nor the values presented in `arg`. 196 | shift # remove old arg 197 | set -- "$@" "$arg" # push replacement arg 198 | done 199 | fi 200 | 201 | 202 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 203 | DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' 204 | 205 | # Collect all arguments for the java command: 206 | # * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments, 207 | # and any embedded shellness will be escaped. 208 | # * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be 209 | # treated as '${Hostname}' itself on the command line. 210 | 211 | set -- \ 212 | "-Dorg.gradle.appname=$APP_BASE_NAME" \ 213 | -classpath "$CLASSPATH" \ 214 | org.gradle.wrapper.GradleWrapperMain \ 215 | "$@" 216 | 217 | # Stop when "xargs" is not available. 218 | if ! command -v xargs >/dev/null 2>&1 219 | then 220 | die "xargs is not available" 221 | fi 222 | 223 | # Use "xargs" to parse quoted args. 224 | # 225 | # With -n1 it outputs one arg per line, with the quotes and backslashes removed. 226 | # 227 | # In Bash we could simply go: 228 | # 229 | # readarray ARGS < <( xargs -n1 <<<"$var" ) && 230 | # set -- "${ARGS[@]}" "$@" 231 | # 232 | # but POSIX shell has neither arrays nor command substitution, so instead we 233 | # post-process each arg (as a line of input to sed) to backslash-escape any 234 | # character that might be a shell metacharacter, then use eval to reverse 235 | # that process (while maintaining the separation between arguments), and wrap 236 | # the whole thing up as a single "set" statement. 237 | # 238 | # This will of course break if any of these variables contains a newline or 239 | # an unmatched quote. 240 | # 241 | 242 | eval "set -- $( 243 | printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | 244 | xargs -n1 | 245 | sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | 246 | tr '\n' ' ' 247 | )" '"$@"' 248 | 249 | exec "$JAVACMD" "$@" 250 | -------------------------------------------------------------------------------- /example/android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem https://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | 17 | @if "%DEBUG%"=="" @echo off 18 | @rem ########################################################################## 19 | @rem 20 | @rem Gradle startup script for Windows 21 | @rem 22 | @rem ########################################################################## 23 | 24 | @rem Set local scope for the variables with windows NT shell 25 | if "%OS%"=="Windows_NT" setlocal 26 | 27 | set DIRNAME=%~dp0 28 | if "%DIRNAME%"=="" set DIRNAME=. 29 | @rem This is normally unused 30 | set APP_BASE_NAME=%~n0 31 | set APP_HOME=%DIRNAME% 32 | 33 | @rem Resolve any "." and ".." in APP_HOME to make it shorter. 34 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi 35 | 36 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 37 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 38 | 39 | @rem Find java.exe 40 | if defined JAVA_HOME goto findJavaFromJavaHome 41 | 42 | set JAVA_EXE=java.exe 43 | %JAVA_EXE% -version >NUL 2>&1 44 | if %ERRORLEVEL% equ 0 goto execute 45 | 46 | echo. 1>&2 47 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2 48 | echo. 1>&2 49 | echo Please set the JAVA_HOME variable in your environment to match the 1>&2 50 | echo location of your Java installation. 1>&2 51 | 52 | goto fail 53 | 54 | :findJavaFromJavaHome 55 | set JAVA_HOME=%JAVA_HOME:"=% 56 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 57 | 58 | if exist "%JAVA_EXE%" goto execute 59 | 60 | echo. 1>&2 61 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2 62 | echo. 1>&2 63 | echo Please set the JAVA_HOME variable in your environment to match the 1>&2 64 | echo location of your Java installation. 1>&2 65 | 66 | goto fail 67 | 68 | :execute 69 | @rem Setup the command line 70 | 71 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 72 | 73 | 74 | @rem Execute Gradle 75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* 76 | 77 | :end 78 | @rem End local scope for the variables with windows NT shell 79 | if %ERRORLEVEL% equ 0 goto mainEnd 80 | 81 | :fail 82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 83 | rem the _cmd.exe /c_ return code! 84 | set EXIT_CODE=%ERRORLEVEL% 85 | if %EXIT_CODE% equ 0 set EXIT_CODE=1 86 | if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% 87 | exit /b %EXIT_CODE% 88 | 89 | :mainEnd 90 | if "%OS%"=="Windows_NT" endlocal 91 | 92 | :omega 93 | -------------------------------------------------------------------------------- /example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'example' 2 | apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) 3 | include ':app' 4 | includeBuild('../node_modules/@react-native/gradle-plugin') 5 | -------------------------------------------------------------------------------- /example/app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example", 3 | "displayName": "example" 4 | } 5 | -------------------------------------------------------------------------------- /example/assets/custom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/assets/custom.png -------------------------------------------------------------------------------- /example/assets/custom@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/assets/custom@2x.png -------------------------------------------------------------------------------- /example/assets/custom@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/example/assets/custom@3x.png -------------------------------------------------------------------------------- /example/babel.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const pak = require('../package.json'); 3 | 4 | module.exports = { 5 | presets: ['module:@react-native/babel-preset'], 6 | plugins: [ 7 | [ 8 | 'module-resolver', 9 | { 10 | extensions: ['.tsx', '.ts', '.js', '.json'], 11 | alias: { 12 | [pak.name]: path.join(__dirname, '..', pak.source), 13 | }, 14 | }, 15 | ], 16 | ], 17 | }; 18 | -------------------------------------------------------------------------------- /example/index.js: -------------------------------------------------------------------------------- 1 | import { AppRegistry } from 'react-native'; 2 | import App from './App'; 3 | import { name as appName } from './app.json'; 4 | 5 | AppRegistry.registerComponent(appName, () => App); 6 | -------------------------------------------------------------------------------- /example/ios/.xcode.env: -------------------------------------------------------------------------------- 1 | # This `.xcode.env` file is versioned and is used to source the environment 2 | # used when running script phases inside Xcode. 3 | # To customize your local environment, you can create an `.xcode.env.local` 4 | # file that is not versioned. 5 | 6 | # NODE_BINARY variable contains the PATH to the node executable. 7 | # 8 | # Customize the NODE_BINARY variable here. 9 | # For example, to use nvm with brew, add the following line 10 | # . "$(brew --prefix nvm)/nvm.sh" --no-use 11 | export NODE_BINARY=$(command -v node) 12 | -------------------------------------------------------------------------------- /example/ios/Podfile: -------------------------------------------------------------------------------- 1 | # Resolve react_native_pods.rb with node to allow for hoisting 2 | require Pod::Executable.execute_command('node', ['-p', 3 | 'require.resolve( 4 | "react-native/scripts/react_native_pods.rb", 5 | {paths: [process.argv[1]]}, 6 | )', __dir__]).strip 7 | 8 | platform :ios, min_ios_version_supported 9 | prepare_react_native_project! 10 | 11 | linkage = ENV['USE_FRAMEWORKS'] 12 | if linkage != nil 13 | Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green 14 | use_frameworks! :linkage => linkage.to_sym 15 | end 16 | 17 | target 'example' do 18 | config = use_native_modules! 19 | 20 | use_react_native!( 21 | :path => config[:reactNativePath], 22 | # An absolute path to your application root. 23 | :app_path => "#{Pod::Config.instance.installation_root}/.." 24 | ) 25 | 26 | target 'exampleTests' do 27 | inherit! :complete 28 | # Pods for testing 29 | end 30 | 31 | post_install do |installer| 32 | # https://github.com/facebook/react-native/blob/main/packages/react-native/scripts/react_native_pods.rb#L197-L202 33 | react_native_post_install( 34 | installer, 35 | config[:reactNativePath], 36 | :mac_catalyst_enabled => false, 37 | # :ccache_enabled => true 38 | ) 39 | end 40 | end 41 | -------------------------------------------------------------------------------- /example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - boost (1.83.0) 3 | - DoubleConversion (1.1.6) 4 | - FBLazyVector (0.74.4) 5 | - fmt (9.1.0) 6 | - glog (0.3.5) 7 | - hermes-engine (0.74.4): 8 | - hermes-engine/Pre-built (= 0.74.4) 9 | - hermes-engine/Pre-built (0.74.4) 10 | - RCT-Folly (2024.01.01.00): 11 | - boost 12 | - DoubleConversion 13 | - fmt (= 9.1.0) 14 | - glog 15 | - RCT-Folly/Default (= 2024.01.01.00) 16 | - RCT-Folly/Default (2024.01.01.00): 17 | - boost 18 | - DoubleConversion 19 | - fmt (= 9.1.0) 20 | - glog 21 | - RCT-Folly/Fabric (2024.01.01.00): 22 | - boost 23 | - DoubleConversion 24 | - fmt (= 9.1.0) 25 | - glog 26 | - RCTDeprecation (0.74.4) 27 | - RCTRequired (0.74.4) 28 | - RCTTypeSafety (0.74.4): 29 | - FBLazyVector (= 0.74.4) 30 | - RCTRequired (= 0.74.4) 31 | - React-Core (= 0.74.4) 32 | - React (0.74.4): 33 | - React-Core (= 0.74.4) 34 | - React-Core/DevSupport (= 0.74.4) 35 | - React-Core/RCTWebSocket (= 0.74.4) 36 | - React-RCTActionSheet (= 0.74.4) 37 | - React-RCTAnimation (= 0.74.4) 38 | - React-RCTBlob (= 0.74.4) 39 | - React-RCTImage (= 0.74.4) 40 | - React-RCTLinking (= 0.74.4) 41 | - React-RCTNetwork (= 0.74.4) 42 | - React-RCTSettings (= 0.74.4) 43 | - React-RCTText (= 0.74.4) 44 | - React-RCTVibration (= 0.74.4) 45 | - React-callinvoker (0.74.4) 46 | - React-Codegen (0.74.4): 47 | - DoubleConversion 48 | - glog 49 | - hermes-engine 50 | - RCT-Folly 51 | - RCTRequired 52 | - RCTTypeSafety 53 | - React-Core 54 | - React-debug 55 | - React-Fabric 56 | - React-FabricImage 57 | - React-featureflags 58 | - React-graphics 59 | - React-jsi 60 | - React-jsiexecutor 61 | - React-NativeModulesApple 62 | - React-rendererdebug 63 | - React-utils 64 | - ReactCommon/turbomodule/bridging 65 | - ReactCommon/turbomodule/core 66 | - React-Core (0.74.4): 67 | - glog 68 | - hermes-engine 69 | - RCT-Folly (= 2024.01.01.00) 70 | - RCTDeprecation 71 | - React-Core/Default (= 0.74.4) 72 | - React-cxxreact 73 | - React-featureflags 74 | - React-hermes 75 | - React-jsi 76 | - React-jsiexecutor 77 | - React-jsinspector 78 | - React-perflogger 79 | - React-runtimescheduler 80 | - React-utils 81 | - SocketRocket (= 0.7.0) 82 | - Yoga 83 | - React-Core/CoreModulesHeaders (0.74.4): 84 | - glog 85 | - hermes-engine 86 | - RCT-Folly (= 2024.01.01.00) 87 | - RCTDeprecation 88 | - React-Core/Default 89 | - React-cxxreact 90 | - React-featureflags 91 | - React-hermes 92 | - React-jsi 93 | - React-jsiexecutor 94 | - React-jsinspector 95 | - React-perflogger 96 | - React-runtimescheduler 97 | - React-utils 98 | - SocketRocket (= 0.7.0) 99 | - Yoga 100 | - React-Core/Default (0.74.4): 101 | - glog 102 | - hermes-engine 103 | - RCT-Folly (= 2024.01.01.00) 104 | - RCTDeprecation 105 | - React-cxxreact 106 | - React-featureflags 107 | - React-hermes 108 | - React-jsi 109 | - React-jsiexecutor 110 | - React-jsinspector 111 | - React-perflogger 112 | - React-runtimescheduler 113 | - React-utils 114 | - SocketRocket (= 0.7.0) 115 | - Yoga 116 | - React-Core/DevSupport (0.74.4): 117 | - glog 118 | - hermes-engine 119 | - RCT-Folly (= 2024.01.01.00) 120 | - RCTDeprecation 121 | - React-Core/Default (= 0.74.4) 122 | - React-Core/RCTWebSocket (= 0.74.4) 123 | - React-cxxreact 124 | - React-featureflags 125 | - React-hermes 126 | - React-jsi 127 | - React-jsiexecutor 128 | - React-jsinspector 129 | - React-perflogger 130 | - React-runtimescheduler 131 | - React-utils 132 | - SocketRocket (= 0.7.0) 133 | - Yoga 134 | - React-Core/RCTActionSheetHeaders (0.74.4): 135 | - glog 136 | - hermes-engine 137 | - RCT-Folly (= 2024.01.01.00) 138 | - RCTDeprecation 139 | - React-Core/Default 140 | - React-cxxreact 141 | - React-featureflags 142 | - React-hermes 143 | - React-jsi 144 | - React-jsiexecutor 145 | - React-jsinspector 146 | - React-perflogger 147 | - React-runtimescheduler 148 | - React-utils 149 | - SocketRocket (= 0.7.0) 150 | - Yoga 151 | - React-Core/RCTAnimationHeaders (0.74.4): 152 | - glog 153 | - hermes-engine 154 | - RCT-Folly (= 2024.01.01.00) 155 | - RCTDeprecation 156 | - React-Core/Default 157 | - React-cxxreact 158 | - React-featureflags 159 | - React-hermes 160 | - React-jsi 161 | - React-jsiexecutor 162 | - React-jsinspector 163 | - React-perflogger 164 | - React-runtimescheduler 165 | - React-utils 166 | - SocketRocket (= 0.7.0) 167 | - Yoga 168 | - React-Core/RCTBlobHeaders (0.74.4): 169 | - glog 170 | - hermes-engine 171 | - RCT-Folly (= 2024.01.01.00) 172 | - RCTDeprecation 173 | - React-Core/Default 174 | - React-cxxreact 175 | - React-featureflags 176 | - React-hermes 177 | - React-jsi 178 | - React-jsiexecutor 179 | - React-jsinspector 180 | - React-perflogger 181 | - React-runtimescheduler 182 | - React-utils 183 | - SocketRocket (= 0.7.0) 184 | - Yoga 185 | - React-Core/RCTImageHeaders (0.74.4): 186 | - glog 187 | - hermes-engine 188 | - RCT-Folly (= 2024.01.01.00) 189 | - RCTDeprecation 190 | - React-Core/Default 191 | - React-cxxreact 192 | - React-featureflags 193 | - React-hermes 194 | - React-jsi 195 | - React-jsiexecutor 196 | - React-jsinspector 197 | - React-perflogger 198 | - React-runtimescheduler 199 | - React-utils 200 | - SocketRocket (= 0.7.0) 201 | - Yoga 202 | - React-Core/RCTLinkingHeaders (0.74.4): 203 | - glog 204 | - hermes-engine 205 | - RCT-Folly (= 2024.01.01.00) 206 | - RCTDeprecation 207 | - React-Core/Default 208 | - React-cxxreact 209 | - React-featureflags 210 | - React-hermes 211 | - React-jsi 212 | - React-jsiexecutor 213 | - React-jsinspector 214 | - React-perflogger 215 | - React-runtimescheduler 216 | - React-utils 217 | - SocketRocket (= 0.7.0) 218 | - Yoga 219 | - React-Core/RCTNetworkHeaders (0.74.4): 220 | - glog 221 | - hermes-engine 222 | - RCT-Folly (= 2024.01.01.00) 223 | - RCTDeprecation 224 | - React-Core/Default 225 | - React-cxxreact 226 | - React-featureflags 227 | - React-hermes 228 | - React-jsi 229 | - React-jsiexecutor 230 | - React-jsinspector 231 | - React-perflogger 232 | - React-runtimescheduler 233 | - React-utils 234 | - SocketRocket (= 0.7.0) 235 | - Yoga 236 | - React-Core/RCTSettingsHeaders (0.74.4): 237 | - glog 238 | - hermes-engine 239 | - RCT-Folly (= 2024.01.01.00) 240 | - RCTDeprecation 241 | - React-Core/Default 242 | - React-cxxreact 243 | - React-featureflags 244 | - React-hermes 245 | - React-jsi 246 | - React-jsiexecutor 247 | - React-jsinspector 248 | - React-perflogger 249 | - React-runtimescheduler 250 | - React-utils 251 | - SocketRocket (= 0.7.0) 252 | - Yoga 253 | - React-Core/RCTTextHeaders (0.74.4): 254 | - glog 255 | - hermes-engine 256 | - RCT-Folly (= 2024.01.01.00) 257 | - RCTDeprecation 258 | - React-Core/Default 259 | - React-cxxreact 260 | - React-featureflags 261 | - React-hermes 262 | - React-jsi 263 | - React-jsiexecutor 264 | - React-jsinspector 265 | - React-perflogger 266 | - React-runtimescheduler 267 | - React-utils 268 | - SocketRocket (= 0.7.0) 269 | - Yoga 270 | - React-Core/RCTVibrationHeaders (0.74.4): 271 | - glog 272 | - hermes-engine 273 | - RCT-Folly (= 2024.01.01.00) 274 | - RCTDeprecation 275 | - React-Core/Default 276 | - React-cxxreact 277 | - React-featureflags 278 | - React-hermes 279 | - React-jsi 280 | - React-jsiexecutor 281 | - React-jsinspector 282 | - React-perflogger 283 | - React-runtimescheduler 284 | - React-utils 285 | - SocketRocket (= 0.7.0) 286 | - Yoga 287 | - React-Core/RCTWebSocket (0.74.4): 288 | - glog 289 | - hermes-engine 290 | - RCT-Folly (= 2024.01.01.00) 291 | - RCTDeprecation 292 | - React-Core/Default (= 0.74.4) 293 | - React-cxxreact 294 | - React-featureflags 295 | - React-hermes 296 | - React-jsi 297 | - React-jsiexecutor 298 | - React-jsinspector 299 | - React-perflogger 300 | - React-runtimescheduler 301 | - React-utils 302 | - SocketRocket (= 0.7.0) 303 | - Yoga 304 | - React-CoreModules (0.74.4): 305 | - DoubleConversion 306 | - fmt (= 9.1.0) 307 | - RCT-Folly (= 2024.01.01.00) 308 | - RCTTypeSafety (= 0.74.4) 309 | - React-Codegen 310 | - React-Core/CoreModulesHeaders (= 0.74.4) 311 | - React-jsi (= 0.74.4) 312 | - React-jsinspector 313 | - React-NativeModulesApple 314 | - React-RCTBlob 315 | - React-RCTImage (= 0.74.4) 316 | - ReactCommon 317 | - SocketRocket (= 0.7.0) 318 | - React-cxxreact (0.74.4): 319 | - boost (= 1.83.0) 320 | - DoubleConversion 321 | - fmt (= 9.1.0) 322 | - glog 323 | - hermes-engine 324 | - RCT-Folly (= 2024.01.01.00) 325 | - React-callinvoker (= 0.74.4) 326 | - React-debug (= 0.74.4) 327 | - React-jsi (= 0.74.4) 328 | - React-jsinspector 329 | - React-logger (= 0.74.4) 330 | - React-perflogger (= 0.74.4) 331 | - React-runtimeexecutor (= 0.74.4) 332 | - React-debug (0.74.4) 333 | - React-Fabric (0.74.4): 334 | - DoubleConversion 335 | - fmt (= 9.1.0) 336 | - glog 337 | - hermes-engine 338 | - RCT-Folly/Fabric (= 2024.01.01.00) 339 | - RCTRequired 340 | - RCTTypeSafety 341 | - React-Core 342 | - React-cxxreact 343 | - React-debug 344 | - React-Fabric/animations (= 0.74.4) 345 | - React-Fabric/attributedstring (= 0.74.4) 346 | - React-Fabric/componentregistry (= 0.74.4) 347 | - React-Fabric/componentregistrynative (= 0.74.4) 348 | - React-Fabric/components (= 0.74.4) 349 | - React-Fabric/core (= 0.74.4) 350 | - React-Fabric/imagemanager (= 0.74.4) 351 | - React-Fabric/leakchecker (= 0.74.4) 352 | - React-Fabric/mounting (= 0.74.4) 353 | - React-Fabric/scheduler (= 0.74.4) 354 | - React-Fabric/telemetry (= 0.74.4) 355 | - React-Fabric/templateprocessor (= 0.74.4) 356 | - React-Fabric/textlayoutmanager (= 0.74.4) 357 | - React-Fabric/uimanager (= 0.74.4) 358 | - React-graphics 359 | - React-jsi 360 | - React-jsiexecutor 361 | - React-logger 362 | - React-rendererdebug 363 | - React-runtimescheduler 364 | - React-utils 365 | - ReactCommon/turbomodule/core 366 | - React-Fabric/animations (0.74.4): 367 | - DoubleConversion 368 | - fmt (= 9.1.0) 369 | - glog 370 | - hermes-engine 371 | - RCT-Folly/Fabric (= 2024.01.01.00) 372 | - RCTRequired 373 | - RCTTypeSafety 374 | - React-Core 375 | - React-cxxreact 376 | - React-debug 377 | - React-graphics 378 | - React-jsi 379 | - React-jsiexecutor 380 | - React-logger 381 | - React-rendererdebug 382 | - React-runtimescheduler 383 | - React-utils 384 | - ReactCommon/turbomodule/core 385 | - React-Fabric/attributedstring (0.74.4): 386 | - DoubleConversion 387 | - fmt (= 9.1.0) 388 | - glog 389 | - hermes-engine 390 | - RCT-Folly/Fabric (= 2024.01.01.00) 391 | - RCTRequired 392 | - RCTTypeSafety 393 | - React-Core 394 | - React-cxxreact 395 | - React-debug 396 | - React-graphics 397 | - React-jsi 398 | - React-jsiexecutor 399 | - React-logger 400 | - React-rendererdebug 401 | - React-runtimescheduler 402 | - React-utils 403 | - ReactCommon/turbomodule/core 404 | - React-Fabric/componentregistry (0.74.4): 405 | - DoubleConversion 406 | - fmt (= 9.1.0) 407 | - glog 408 | - hermes-engine 409 | - RCT-Folly/Fabric (= 2024.01.01.00) 410 | - RCTRequired 411 | - RCTTypeSafety 412 | - React-Core 413 | - React-cxxreact 414 | - React-debug 415 | - React-graphics 416 | - React-jsi 417 | - React-jsiexecutor 418 | - React-logger 419 | - React-rendererdebug 420 | - React-runtimescheduler 421 | - React-utils 422 | - ReactCommon/turbomodule/core 423 | - React-Fabric/componentregistrynative (0.74.4): 424 | - DoubleConversion 425 | - fmt (= 9.1.0) 426 | - glog 427 | - hermes-engine 428 | - RCT-Folly/Fabric (= 2024.01.01.00) 429 | - RCTRequired 430 | - RCTTypeSafety 431 | - React-Core 432 | - React-cxxreact 433 | - React-debug 434 | - React-graphics 435 | - React-jsi 436 | - React-jsiexecutor 437 | - React-logger 438 | - React-rendererdebug 439 | - React-runtimescheduler 440 | - React-utils 441 | - ReactCommon/turbomodule/core 442 | - React-Fabric/components (0.74.4): 443 | - DoubleConversion 444 | - fmt (= 9.1.0) 445 | - glog 446 | - hermes-engine 447 | - RCT-Folly/Fabric (= 2024.01.01.00) 448 | - RCTRequired 449 | - RCTTypeSafety 450 | - React-Core 451 | - React-cxxreact 452 | - React-debug 453 | - React-Fabric/components/inputaccessory (= 0.74.4) 454 | - React-Fabric/components/legacyviewmanagerinterop (= 0.74.4) 455 | - React-Fabric/components/modal (= 0.74.4) 456 | - React-Fabric/components/rncore (= 0.74.4) 457 | - React-Fabric/components/root (= 0.74.4) 458 | - React-Fabric/components/safeareaview (= 0.74.4) 459 | - React-Fabric/components/scrollview (= 0.74.4) 460 | - React-Fabric/components/text (= 0.74.4) 461 | - React-Fabric/components/textinput (= 0.74.4) 462 | - React-Fabric/components/unimplementedview (= 0.74.4) 463 | - React-Fabric/components/view (= 0.74.4) 464 | - React-graphics 465 | - React-jsi 466 | - React-jsiexecutor 467 | - React-logger 468 | - React-rendererdebug 469 | - React-runtimescheduler 470 | - React-utils 471 | - ReactCommon/turbomodule/core 472 | - React-Fabric/components/inputaccessory (0.74.4): 473 | - DoubleConversion 474 | - fmt (= 9.1.0) 475 | - glog 476 | - hermes-engine 477 | - RCT-Folly/Fabric (= 2024.01.01.00) 478 | - RCTRequired 479 | - RCTTypeSafety 480 | - React-Core 481 | - React-cxxreact 482 | - React-debug 483 | - React-graphics 484 | - React-jsi 485 | - React-jsiexecutor 486 | - React-logger 487 | - React-rendererdebug 488 | - React-runtimescheduler 489 | - React-utils 490 | - ReactCommon/turbomodule/core 491 | - React-Fabric/components/legacyviewmanagerinterop (0.74.4): 492 | - DoubleConversion 493 | - fmt (= 9.1.0) 494 | - glog 495 | - hermes-engine 496 | - RCT-Folly/Fabric (= 2024.01.01.00) 497 | - RCTRequired 498 | - RCTTypeSafety 499 | - React-Core 500 | - React-cxxreact 501 | - React-debug 502 | - React-graphics 503 | - React-jsi 504 | - React-jsiexecutor 505 | - React-logger 506 | - React-rendererdebug 507 | - React-runtimescheduler 508 | - React-utils 509 | - ReactCommon/turbomodule/core 510 | - React-Fabric/components/modal (0.74.4): 511 | - DoubleConversion 512 | - fmt (= 9.1.0) 513 | - glog 514 | - hermes-engine 515 | - RCT-Folly/Fabric (= 2024.01.01.00) 516 | - RCTRequired 517 | - RCTTypeSafety 518 | - React-Core 519 | - React-cxxreact 520 | - React-debug 521 | - React-graphics 522 | - React-jsi 523 | - React-jsiexecutor 524 | - React-logger 525 | - React-rendererdebug 526 | - React-runtimescheduler 527 | - React-utils 528 | - ReactCommon/turbomodule/core 529 | - React-Fabric/components/rncore (0.74.4): 530 | - DoubleConversion 531 | - fmt (= 9.1.0) 532 | - glog 533 | - hermes-engine 534 | - RCT-Folly/Fabric (= 2024.01.01.00) 535 | - RCTRequired 536 | - RCTTypeSafety 537 | - React-Core 538 | - React-cxxreact 539 | - React-debug 540 | - React-graphics 541 | - React-jsi 542 | - React-jsiexecutor 543 | - React-logger 544 | - React-rendererdebug 545 | - React-runtimescheduler 546 | - React-utils 547 | - ReactCommon/turbomodule/core 548 | - React-Fabric/components/root (0.74.4): 549 | - DoubleConversion 550 | - fmt (= 9.1.0) 551 | - glog 552 | - hermes-engine 553 | - RCT-Folly/Fabric (= 2024.01.01.00) 554 | - RCTRequired 555 | - RCTTypeSafety 556 | - React-Core 557 | - React-cxxreact 558 | - React-debug 559 | - React-graphics 560 | - React-jsi 561 | - React-jsiexecutor 562 | - React-logger 563 | - React-rendererdebug 564 | - React-runtimescheduler 565 | - React-utils 566 | - ReactCommon/turbomodule/core 567 | - React-Fabric/components/safeareaview (0.74.4): 568 | - DoubleConversion 569 | - fmt (= 9.1.0) 570 | - glog 571 | - hermes-engine 572 | - RCT-Folly/Fabric (= 2024.01.01.00) 573 | - RCTRequired 574 | - RCTTypeSafety 575 | - React-Core 576 | - React-cxxreact 577 | - React-debug 578 | - React-graphics 579 | - React-jsi 580 | - React-jsiexecutor 581 | - React-logger 582 | - React-rendererdebug 583 | - React-runtimescheduler 584 | - React-utils 585 | - ReactCommon/turbomodule/core 586 | - React-Fabric/components/scrollview (0.74.4): 587 | - DoubleConversion 588 | - fmt (= 9.1.0) 589 | - glog 590 | - hermes-engine 591 | - RCT-Folly/Fabric (= 2024.01.01.00) 592 | - RCTRequired 593 | - RCTTypeSafety 594 | - React-Core 595 | - React-cxxreact 596 | - React-debug 597 | - React-graphics 598 | - React-jsi 599 | - React-jsiexecutor 600 | - React-logger 601 | - React-rendererdebug 602 | - React-runtimescheduler 603 | - React-utils 604 | - ReactCommon/turbomodule/core 605 | - React-Fabric/components/text (0.74.4): 606 | - DoubleConversion 607 | - fmt (= 9.1.0) 608 | - glog 609 | - hermes-engine 610 | - RCT-Folly/Fabric (= 2024.01.01.00) 611 | - RCTRequired 612 | - RCTTypeSafety 613 | - React-Core 614 | - React-cxxreact 615 | - React-debug 616 | - React-graphics 617 | - React-jsi 618 | - React-jsiexecutor 619 | - React-logger 620 | - React-rendererdebug 621 | - React-runtimescheduler 622 | - React-utils 623 | - ReactCommon/turbomodule/core 624 | - React-Fabric/components/textinput (0.74.4): 625 | - DoubleConversion 626 | - fmt (= 9.1.0) 627 | - glog 628 | - hermes-engine 629 | - RCT-Folly/Fabric (= 2024.01.01.00) 630 | - RCTRequired 631 | - RCTTypeSafety 632 | - React-Core 633 | - React-cxxreact 634 | - React-debug 635 | - React-graphics 636 | - React-jsi 637 | - React-jsiexecutor 638 | - React-logger 639 | - React-rendererdebug 640 | - React-runtimescheduler 641 | - React-utils 642 | - ReactCommon/turbomodule/core 643 | - React-Fabric/components/unimplementedview (0.74.4): 644 | - DoubleConversion 645 | - fmt (= 9.1.0) 646 | - glog 647 | - hermes-engine 648 | - RCT-Folly/Fabric (= 2024.01.01.00) 649 | - RCTRequired 650 | - RCTTypeSafety 651 | - React-Core 652 | - React-cxxreact 653 | - React-debug 654 | - React-graphics 655 | - React-jsi 656 | - React-jsiexecutor 657 | - React-logger 658 | - React-rendererdebug 659 | - React-runtimescheduler 660 | - React-utils 661 | - ReactCommon/turbomodule/core 662 | - React-Fabric/components/view (0.74.4): 663 | - DoubleConversion 664 | - fmt (= 9.1.0) 665 | - glog 666 | - hermes-engine 667 | - RCT-Folly/Fabric (= 2024.01.01.00) 668 | - RCTRequired 669 | - RCTTypeSafety 670 | - React-Core 671 | - React-cxxreact 672 | - React-debug 673 | - React-graphics 674 | - React-jsi 675 | - React-jsiexecutor 676 | - React-logger 677 | - React-rendererdebug 678 | - React-runtimescheduler 679 | - React-utils 680 | - ReactCommon/turbomodule/core 681 | - Yoga 682 | - React-Fabric/core (0.74.4): 683 | - DoubleConversion 684 | - fmt (= 9.1.0) 685 | - glog 686 | - hermes-engine 687 | - RCT-Folly/Fabric (= 2024.01.01.00) 688 | - RCTRequired 689 | - RCTTypeSafety 690 | - React-Core 691 | - React-cxxreact 692 | - React-debug 693 | - React-graphics 694 | - React-jsi 695 | - React-jsiexecutor 696 | - React-logger 697 | - React-rendererdebug 698 | - React-runtimescheduler 699 | - React-utils 700 | - ReactCommon/turbomodule/core 701 | - React-Fabric/imagemanager (0.74.4): 702 | - DoubleConversion 703 | - fmt (= 9.1.0) 704 | - glog 705 | - hermes-engine 706 | - RCT-Folly/Fabric (= 2024.01.01.00) 707 | - RCTRequired 708 | - RCTTypeSafety 709 | - React-Core 710 | - React-cxxreact 711 | - React-debug 712 | - React-graphics 713 | - React-jsi 714 | - React-jsiexecutor 715 | - React-logger 716 | - React-rendererdebug 717 | - React-runtimescheduler 718 | - React-utils 719 | - ReactCommon/turbomodule/core 720 | - React-Fabric/leakchecker (0.74.4): 721 | - DoubleConversion 722 | - fmt (= 9.1.0) 723 | - glog 724 | - hermes-engine 725 | - RCT-Folly/Fabric (= 2024.01.01.00) 726 | - RCTRequired 727 | - RCTTypeSafety 728 | - React-Core 729 | - React-cxxreact 730 | - React-debug 731 | - React-graphics 732 | - React-jsi 733 | - React-jsiexecutor 734 | - React-logger 735 | - React-rendererdebug 736 | - React-runtimescheduler 737 | - React-utils 738 | - ReactCommon/turbomodule/core 739 | - React-Fabric/mounting (0.74.4): 740 | - DoubleConversion 741 | - fmt (= 9.1.0) 742 | - glog 743 | - hermes-engine 744 | - RCT-Folly/Fabric (= 2024.01.01.00) 745 | - RCTRequired 746 | - RCTTypeSafety 747 | - React-Core 748 | - React-cxxreact 749 | - React-debug 750 | - React-graphics 751 | - React-jsi 752 | - React-jsiexecutor 753 | - React-logger 754 | - React-rendererdebug 755 | - React-runtimescheduler 756 | - React-utils 757 | - ReactCommon/turbomodule/core 758 | - React-Fabric/scheduler (0.74.4): 759 | - DoubleConversion 760 | - fmt (= 9.1.0) 761 | - glog 762 | - hermes-engine 763 | - RCT-Folly/Fabric (= 2024.01.01.00) 764 | - RCTRequired 765 | - RCTTypeSafety 766 | - React-Core 767 | - React-cxxreact 768 | - React-debug 769 | - React-graphics 770 | - React-jsi 771 | - React-jsiexecutor 772 | - React-logger 773 | - React-rendererdebug 774 | - React-runtimescheduler 775 | - React-utils 776 | - ReactCommon/turbomodule/core 777 | - React-Fabric/telemetry (0.74.4): 778 | - DoubleConversion 779 | - fmt (= 9.1.0) 780 | - glog 781 | - hermes-engine 782 | - RCT-Folly/Fabric (= 2024.01.01.00) 783 | - RCTRequired 784 | - RCTTypeSafety 785 | - React-Core 786 | - React-cxxreact 787 | - React-debug 788 | - React-graphics 789 | - React-jsi 790 | - React-jsiexecutor 791 | - React-logger 792 | - React-rendererdebug 793 | - React-runtimescheduler 794 | - React-utils 795 | - ReactCommon/turbomodule/core 796 | - React-Fabric/templateprocessor (0.74.4): 797 | - DoubleConversion 798 | - fmt (= 9.1.0) 799 | - glog 800 | - hermes-engine 801 | - RCT-Folly/Fabric (= 2024.01.01.00) 802 | - RCTRequired 803 | - RCTTypeSafety 804 | - React-Core 805 | - React-cxxreact 806 | - React-debug 807 | - React-graphics 808 | - React-jsi 809 | - React-jsiexecutor 810 | - React-logger 811 | - React-rendererdebug 812 | - React-runtimescheduler 813 | - React-utils 814 | - ReactCommon/turbomodule/core 815 | - React-Fabric/textlayoutmanager (0.74.4): 816 | - DoubleConversion 817 | - fmt (= 9.1.0) 818 | - glog 819 | - hermes-engine 820 | - RCT-Folly/Fabric (= 2024.01.01.00) 821 | - RCTRequired 822 | - RCTTypeSafety 823 | - React-Core 824 | - React-cxxreact 825 | - React-debug 826 | - React-Fabric/uimanager 827 | - React-graphics 828 | - React-jsi 829 | - React-jsiexecutor 830 | - React-logger 831 | - React-rendererdebug 832 | - React-runtimescheduler 833 | - React-utils 834 | - ReactCommon/turbomodule/core 835 | - React-Fabric/uimanager (0.74.4): 836 | - DoubleConversion 837 | - fmt (= 9.1.0) 838 | - glog 839 | - hermes-engine 840 | - RCT-Folly/Fabric (= 2024.01.01.00) 841 | - RCTRequired 842 | - RCTTypeSafety 843 | - React-Core 844 | - React-cxxreact 845 | - React-debug 846 | - React-graphics 847 | - React-jsi 848 | - React-jsiexecutor 849 | - React-logger 850 | - React-rendererdebug 851 | - React-runtimescheduler 852 | - React-utils 853 | - ReactCommon/turbomodule/core 854 | - React-FabricImage (0.74.4): 855 | - DoubleConversion 856 | - fmt (= 9.1.0) 857 | - glog 858 | - hermes-engine 859 | - RCT-Folly/Fabric (= 2024.01.01.00) 860 | - RCTRequired (= 0.74.4) 861 | - RCTTypeSafety (= 0.74.4) 862 | - React-Fabric 863 | - React-graphics 864 | - React-ImageManager 865 | - React-jsi 866 | - React-jsiexecutor (= 0.74.4) 867 | - React-logger 868 | - React-rendererdebug 869 | - React-utils 870 | - ReactCommon 871 | - Yoga 872 | - React-featureflags (0.74.4) 873 | - React-graphics (0.74.4): 874 | - DoubleConversion 875 | - fmt (= 9.1.0) 876 | - glog 877 | - RCT-Folly/Fabric (= 2024.01.01.00) 878 | - React-Core/Default (= 0.74.4) 879 | - React-utils 880 | - React-hermes (0.74.4): 881 | - DoubleConversion 882 | - fmt (= 9.1.0) 883 | - glog 884 | - hermes-engine 885 | - RCT-Folly (= 2024.01.01.00) 886 | - React-cxxreact (= 0.74.4) 887 | - React-jsi 888 | - React-jsiexecutor (= 0.74.4) 889 | - React-jsinspector 890 | - React-perflogger (= 0.74.4) 891 | - React-runtimeexecutor 892 | - React-ImageManager (0.74.4): 893 | - glog 894 | - RCT-Folly/Fabric 895 | - React-Core/Default 896 | - React-debug 897 | - React-Fabric 898 | - React-graphics 899 | - React-rendererdebug 900 | - React-utils 901 | - React-jserrorhandler (0.74.4): 902 | - RCT-Folly/Fabric (= 2024.01.01.00) 903 | - React-debug 904 | - React-jsi 905 | - React-Mapbuffer 906 | - React-jsi (0.74.4): 907 | - boost (= 1.83.0) 908 | - DoubleConversion 909 | - fmt (= 9.1.0) 910 | - glog 911 | - hermes-engine 912 | - RCT-Folly (= 2024.01.01.00) 913 | - React-jsiexecutor (0.74.4): 914 | - DoubleConversion 915 | - fmt (= 9.1.0) 916 | - glog 917 | - hermes-engine 918 | - RCT-Folly (= 2024.01.01.00) 919 | - React-cxxreact (= 0.74.4) 920 | - React-jsi (= 0.74.4) 921 | - React-jsinspector 922 | - React-perflogger (= 0.74.4) 923 | - React-jsinspector (0.74.4): 924 | - DoubleConversion 925 | - glog 926 | - hermes-engine 927 | - RCT-Folly (= 2024.01.01.00) 928 | - React-featureflags 929 | - React-jsi 930 | - React-runtimeexecutor (= 0.74.4) 931 | - React-jsitracing (0.74.4): 932 | - React-jsi 933 | - React-logger (0.74.4): 934 | - glog 935 | - React-Mapbuffer (0.74.4): 936 | - glog 937 | - React-debug 938 | - React-nativeconfig (0.74.4) 939 | - React-NativeModulesApple (0.74.4): 940 | - glog 941 | - hermes-engine 942 | - React-callinvoker 943 | - React-Core 944 | - React-cxxreact 945 | - React-jsi 946 | - React-jsinspector 947 | - React-runtimeexecutor 948 | - ReactCommon/turbomodule/bridging 949 | - ReactCommon/turbomodule/core 950 | - React-perflogger (0.74.4) 951 | - React-RCTActionSheet (0.74.4): 952 | - React-Core/RCTActionSheetHeaders (= 0.74.4) 953 | - React-RCTAnimation (0.74.4): 954 | - RCT-Folly (= 2024.01.01.00) 955 | - RCTTypeSafety 956 | - React-Codegen 957 | - React-Core/RCTAnimationHeaders 958 | - React-jsi 959 | - React-NativeModulesApple 960 | - ReactCommon 961 | - React-RCTAppDelegate (0.74.4): 962 | - RCT-Folly (= 2024.01.01.00) 963 | - RCTRequired 964 | - RCTTypeSafety 965 | - React-Codegen 966 | - React-Core 967 | - React-CoreModules 968 | - React-debug 969 | - React-Fabric 970 | - React-featureflags 971 | - React-graphics 972 | - React-hermes 973 | - React-nativeconfig 974 | - React-NativeModulesApple 975 | - React-RCTFabric 976 | - React-RCTImage 977 | - React-RCTNetwork 978 | - React-rendererdebug 979 | - React-RuntimeApple 980 | - React-RuntimeCore 981 | - React-RuntimeHermes 982 | - React-runtimescheduler 983 | - React-utils 984 | - ReactCommon 985 | - React-RCTBlob (0.74.4): 986 | - DoubleConversion 987 | - fmt (= 9.1.0) 988 | - hermes-engine 989 | - RCT-Folly (= 2024.01.01.00) 990 | - React-Codegen 991 | - React-Core/RCTBlobHeaders 992 | - React-Core/RCTWebSocket 993 | - React-jsi 994 | - React-jsinspector 995 | - React-NativeModulesApple 996 | - React-RCTNetwork 997 | - ReactCommon 998 | - React-RCTFabric (0.74.4): 999 | - glog 1000 | - hermes-engine 1001 | - RCT-Folly/Fabric (= 2024.01.01.00) 1002 | - React-Core 1003 | - React-debug 1004 | - React-Fabric 1005 | - React-FabricImage 1006 | - React-featureflags 1007 | - React-graphics 1008 | - React-ImageManager 1009 | - React-jsi 1010 | - React-jsinspector 1011 | - React-nativeconfig 1012 | - React-RCTImage 1013 | - React-RCTText 1014 | - React-rendererdebug 1015 | - React-runtimescheduler 1016 | - React-utils 1017 | - Yoga 1018 | - React-RCTImage (0.74.4): 1019 | - RCT-Folly (= 2024.01.01.00) 1020 | - RCTTypeSafety 1021 | - React-Codegen 1022 | - React-Core/RCTImageHeaders 1023 | - React-jsi 1024 | - React-NativeModulesApple 1025 | - React-RCTNetwork 1026 | - ReactCommon 1027 | - React-RCTLinking (0.74.4): 1028 | - React-Codegen 1029 | - React-Core/RCTLinkingHeaders (= 0.74.4) 1030 | - React-jsi (= 0.74.4) 1031 | - React-NativeModulesApple 1032 | - ReactCommon 1033 | - ReactCommon/turbomodule/core (= 0.74.4) 1034 | - React-RCTNetwork (0.74.4): 1035 | - RCT-Folly (= 2024.01.01.00) 1036 | - RCTTypeSafety 1037 | - React-Codegen 1038 | - React-Core/RCTNetworkHeaders 1039 | - React-jsi 1040 | - React-NativeModulesApple 1041 | - ReactCommon 1042 | - React-RCTSettings (0.74.4): 1043 | - RCT-Folly (= 2024.01.01.00) 1044 | - RCTTypeSafety 1045 | - React-Codegen 1046 | - React-Core/RCTSettingsHeaders 1047 | - React-jsi 1048 | - React-NativeModulesApple 1049 | - ReactCommon 1050 | - React-RCTText (0.74.4): 1051 | - React-Core/RCTTextHeaders (= 0.74.4) 1052 | - Yoga 1053 | - React-RCTVibration (0.74.4): 1054 | - RCT-Folly (= 2024.01.01.00) 1055 | - React-Codegen 1056 | - React-Core/RCTVibrationHeaders 1057 | - React-jsi 1058 | - React-NativeModulesApple 1059 | - ReactCommon 1060 | - React-rendererdebug (0.74.4): 1061 | - DoubleConversion 1062 | - fmt (= 9.1.0) 1063 | - RCT-Folly (= 2024.01.01.00) 1064 | - React-debug 1065 | - React-rncore (0.74.4) 1066 | - React-RuntimeApple (0.74.4): 1067 | - hermes-engine 1068 | - RCT-Folly/Fabric (= 2024.01.01.00) 1069 | - React-callinvoker 1070 | - React-Core/Default 1071 | - React-CoreModules 1072 | - React-cxxreact 1073 | - React-jserrorhandler 1074 | - React-jsi 1075 | - React-jsiexecutor 1076 | - React-jsinspector 1077 | - React-Mapbuffer 1078 | - React-NativeModulesApple 1079 | - React-RCTFabric 1080 | - React-RuntimeCore 1081 | - React-runtimeexecutor 1082 | - React-RuntimeHermes 1083 | - React-utils 1084 | - React-RuntimeCore (0.74.4): 1085 | - glog 1086 | - hermes-engine 1087 | - RCT-Folly/Fabric (= 2024.01.01.00) 1088 | - React-cxxreact 1089 | - React-featureflags 1090 | - React-jserrorhandler 1091 | - React-jsi 1092 | - React-jsiexecutor 1093 | - React-jsinspector 1094 | - React-runtimeexecutor 1095 | - React-runtimescheduler 1096 | - React-utils 1097 | - React-runtimeexecutor (0.74.4): 1098 | - React-jsi (= 0.74.4) 1099 | - React-RuntimeHermes (0.74.4): 1100 | - hermes-engine 1101 | - RCT-Folly/Fabric (= 2024.01.01.00) 1102 | - React-featureflags 1103 | - React-hermes 1104 | - React-jsi 1105 | - React-jsinspector 1106 | - React-jsitracing 1107 | - React-nativeconfig 1108 | - React-RuntimeCore 1109 | - React-utils 1110 | - React-runtimescheduler (0.74.4): 1111 | - glog 1112 | - hermes-engine 1113 | - RCT-Folly (= 2024.01.01.00) 1114 | - React-callinvoker 1115 | - React-cxxreact 1116 | - React-debug 1117 | - React-featureflags 1118 | - React-jsi 1119 | - React-rendererdebug 1120 | - React-runtimeexecutor 1121 | - React-utils 1122 | - React-utils (0.74.4): 1123 | - glog 1124 | - hermes-engine 1125 | - RCT-Folly (= 2024.01.01.00) 1126 | - React-debug 1127 | - React-jsi (= 0.74.4) 1128 | - ReactCommon (0.74.4): 1129 | - ReactCommon/turbomodule (= 0.74.4) 1130 | - ReactCommon/turbomodule (0.74.4): 1131 | - DoubleConversion 1132 | - fmt (= 9.1.0) 1133 | - glog 1134 | - hermes-engine 1135 | - RCT-Folly (= 2024.01.01.00) 1136 | - React-callinvoker (= 0.74.4) 1137 | - React-cxxreact (= 0.74.4) 1138 | - React-jsi (= 0.74.4) 1139 | - React-logger (= 0.74.4) 1140 | - React-perflogger (= 0.74.4) 1141 | - ReactCommon/turbomodule/bridging (= 0.74.4) 1142 | - ReactCommon/turbomodule/core (= 0.74.4) 1143 | - ReactCommon/turbomodule/bridging (0.74.4): 1144 | - DoubleConversion 1145 | - fmt (= 9.1.0) 1146 | - glog 1147 | - hermes-engine 1148 | - RCT-Folly (= 2024.01.01.00) 1149 | - React-callinvoker (= 0.74.4) 1150 | - React-cxxreact (= 0.74.4) 1151 | - React-jsi (= 0.74.4) 1152 | - React-logger (= 0.74.4) 1153 | - React-perflogger (= 0.74.4) 1154 | - ReactCommon/turbomodule/core (0.74.4): 1155 | - DoubleConversion 1156 | - fmt (= 9.1.0) 1157 | - glog 1158 | - hermes-engine 1159 | - RCT-Folly (= 2024.01.01.00) 1160 | - React-callinvoker (= 0.74.4) 1161 | - React-cxxreact (= 0.74.4) 1162 | - React-debug (= 0.74.4) 1163 | - React-jsi (= 0.74.4) 1164 | - React-logger (= 0.74.4) 1165 | - React-perflogger (= 0.74.4) 1166 | - React-utils (= 0.74.4) 1167 | - SocketRocket (0.7.0) 1168 | - Yoga (0.0.0) 1169 | 1170 | DEPENDENCIES: 1171 | - boost (from `../node_modules/react-native/third-party-podspecs/boost.podspec`) 1172 | - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`) 1173 | - FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`) 1174 | - fmt (from `../node_modules/react-native/third-party-podspecs/fmt.podspec`) 1175 | - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) 1176 | - hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`) 1177 | - RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`) 1178 | - RCT-Folly/Fabric (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`) 1179 | - RCTDeprecation (from `../node_modules/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation`) 1180 | - RCTRequired (from `../node_modules/react-native/Libraries/Required`) 1181 | - RCTTypeSafety (from `../node_modules/react-native/Libraries/TypeSafety`) 1182 | - React (from `../node_modules/react-native/`) 1183 | - React-callinvoker (from `../node_modules/react-native/ReactCommon/callinvoker`) 1184 | - React-Codegen (from `build/generated/ios`) 1185 | - React-Core (from `../node_modules/react-native/`) 1186 | - React-Core/RCTWebSocket (from `../node_modules/react-native/`) 1187 | - React-CoreModules (from `../node_modules/react-native/React/CoreModules`) 1188 | - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`) 1189 | - React-debug (from `../node_modules/react-native/ReactCommon/react/debug`) 1190 | - React-Fabric (from `../node_modules/react-native/ReactCommon`) 1191 | - React-FabricImage (from `../node_modules/react-native/ReactCommon`) 1192 | - React-featureflags (from `../node_modules/react-native/ReactCommon/react/featureflags`) 1193 | - React-graphics (from `../node_modules/react-native/ReactCommon/react/renderer/graphics`) 1194 | - React-hermes (from `../node_modules/react-native/ReactCommon/hermes`) 1195 | - React-ImageManager (from `../node_modules/react-native/ReactCommon/react/renderer/imagemanager/platform/ios`) 1196 | - React-jserrorhandler (from `../node_modules/react-native/ReactCommon/jserrorhandler`) 1197 | - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`) 1198 | - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`) 1199 | - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector-modern`) 1200 | - React-jsitracing (from `../node_modules/react-native/ReactCommon/hermes/executor/`) 1201 | - React-logger (from `../node_modules/react-native/ReactCommon/logger`) 1202 | - React-Mapbuffer (from `../node_modules/react-native/ReactCommon`) 1203 | - React-nativeconfig (from `../node_modules/react-native/ReactCommon`) 1204 | - React-NativeModulesApple (from `../node_modules/react-native/ReactCommon/react/nativemodule/core/platform/ios`) 1205 | - React-perflogger (from `../node_modules/react-native/ReactCommon/reactperflogger`) 1206 | - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`) 1207 | - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`) 1208 | - React-RCTAppDelegate (from `../node_modules/react-native/Libraries/AppDelegate`) 1209 | - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`) 1210 | - React-RCTFabric (from `../node_modules/react-native/React`) 1211 | - React-RCTImage (from `../node_modules/react-native/Libraries/Image`) 1212 | - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`) 1213 | - React-RCTNetwork (from `../node_modules/react-native/Libraries/Network`) 1214 | - React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`) 1215 | - React-RCTText (from `../node_modules/react-native/Libraries/Text`) 1216 | - React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`) 1217 | - React-rendererdebug (from `../node_modules/react-native/ReactCommon/react/renderer/debug`) 1218 | - React-rncore (from `../node_modules/react-native/ReactCommon`) 1219 | - React-RuntimeApple (from `../node_modules/react-native/ReactCommon/react/runtime/platform/ios`) 1220 | - React-RuntimeCore (from `../node_modules/react-native/ReactCommon/react/runtime`) 1221 | - React-runtimeexecutor (from `../node_modules/react-native/ReactCommon/runtimeexecutor`) 1222 | - React-RuntimeHermes (from `../node_modules/react-native/ReactCommon/react/runtime`) 1223 | - React-runtimescheduler (from `../node_modules/react-native/ReactCommon/react/renderer/runtimescheduler`) 1224 | - React-utils (from `../node_modules/react-native/ReactCommon/react/utils`) 1225 | - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`) 1226 | - Yoga (from `../node_modules/react-native/ReactCommon/yoga`) 1227 | 1228 | SPEC REPOS: 1229 | trunk: 1230 | - SocketRocket 1231 | 1232 | EXTERNAL SOURCES: 1233 | boost: 1234 | :podspec: "../node_modules/react-native/third-party-podspecs/boost.podspec" 1235 | DoubleConversion: 1236 | :podspec: "../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec" 1237 | FBLazyVector: 1238 | :path: "../node_modules/react-native/Libraries/FBLazyVector" 1239 | fmt: 1240 | :podspec: "../node_modules/react-native/third-party-podspecs/fmt.podspec" 1241 | glog: 1242 | :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec" 1243 | hermes-engine: 1244 | :podspec: "../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec" 1245 | :tag: hermes-2024-06-28-RNv0.74.3-7bda0c267e76d11b68a585f84cfdd65000babf85 1246 | RCT-Folly: 1247 | :podspec: "../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec" 1248 | RCTDeprecation: 1249 | :path: "../node_modules/react-native/ReactApple/Libraries/RCTFoundation/RCTDeprecation" 1250 | RCTRequired: 1251 | :path: "../node_modules/react-native/Libraries/Required" 1252 | RCTTypeSafety: 1253 | :path: "../node_modules/react-native/Libraries/TypeSafety" 1254 | React: 1255 | :path: "../node_modules/react-native/" 1256 | React-callinvoker: 1257 | :path: "../node_modules/react-native/ReactCommon/callinvoker" 1258 | React-Codegen: 1259 | :path: build/generated/ios 1260 | React-Core: 1261 | :path: "../node_modules/react-native/" 1262 | React-CoreModules: 1263 | :path: "../node_modules/react-native/React/CoreModules" 1264 | React-cxxreact: 1265 | :path: "../node_modules/react-native/ReactCommon/cxxreact" 1266 | React-debug: 1267 | :path: "../node_modules/react-native/ReactCommon/react/debug" 1268 | React-Fabric: 1269 | :path: "../node_modules/react-native/ReactCommon" 1270 | React-FabricImage: 1271 | :path: "../node_modules/react-native/ReactCommon" 1272 | React-featureflags: 1273 | :path: "../node_modules/react-native/ReactCommon/react/featureflags" 1274 | React-graphics: 1275 | :path: "../node_modules/react-native/ReactCommon/react/renderer/graphics" 1276 | React-hermes: 1277 | :path: "../node_modules/react-native/ReactCommon/hermes" 1278 | React-ImageManager: 1279 | :path: "../node_modules/react-native/ReactCommon/react/renderer/imagemanager/platform/ios" 1280 | React-jserrorhandler: 1281 | :path: "../node_modules/react-native/ReactCommon/jserrorhandler" 1282 | React-jsi: 1283 | :path: "../node_modules/react-native/ReactCommon/jsi" 1284 | React-jsiexecutor: 1285 | :path: "../node_modules/react-native/ReactCommon/jsiexecutor" 1286 | React-jsinspector: 1287 | :path: "../node_modules/react-native/ReactCommon/jsinspector-modern" 1288 | React-jsitracing: 1289 | :path: "../node_modules/react-native/ReactCommon/hermes/executor/" 1290 | React-logger: 1291 | :path: "../node_modules/react-native/ReactCommon/logger" 1292 | React-Mapbuffer: 1293 | :path: "../node_modules/react-native/ReactCommon" 1294 | React-nativeconfig: 1295 | :path: "../node_modules/react-native/ReactCommon" 1296 | React-NativeModulesApple: 1297 | :path: "../node_modules/react-native/ReactCommon/react/nativemodule/core/platform/ios" 1298 | React-perflogger: 1299 | :path: "../node_modules/react-native/ReactCommon/reactperflogger" 1300 | React-RCTActionSheet: 1301 | :path: "../node_modules/react-native/Libraries/ActionSheetIOS" 1302 | React-RCTAnimation: 1303 | :path: "../node_modules/react-native/Libraries/NativeAnimation" 1304 | React-RCTAppDelegate: 1305 | :path: "../node_modules/react-native/Libraries/AppDelegate" 1306 | React-RCTBlob: 1307 | :path: "../node_modules/react-native/Libraries/Blob" 1308 | React-RCTFabric: 1309 | :path: "../node_modules/react-native/React" 1310 | React-RCTImage: 1311 | :path: "../node_modules/react-native/Libraries/Image" 1312 | React-RCTLinking: 1313 | :path: "../node_modules/react-native/Libraries/LinkingIOS" 1314 | React-RCTNetwork: 1315 | :path: "../node_modules/react-native/Libraries/Network" 1316 | React-RCTSettings: 1317 | :path: "../node_modules/react-native/Libraries/Settings" 1318 | React-RCTText: 1319 | :path: "../node_modules/react-native/Libraries/Text" 1320 | React-RCTVibration: 1321 | :path: "../node_modules/react-native/Libraries/Vibration" 1322 | React-rendererdebug: 1323 | :path: "../node_modules/react-native/ReactCommon/react/renderer/debug" 1324 | React-rncore: 1325 | :path: "../node_modules/react-native/ReactCommon" 1326 | React-RuntimeApple: 1327 | :path: "../node_modules/react-native/ReactCommon/react/runtime/platform/ios" 1328 | React-RuntimeCore: 1329 | :path: "../node_modules/react-native/ReactCommon/react/runtime" 1330 | React-runtimeexecutor: 1331 | :path: "../node_modules/react-native/ReactCommon/runtimeexecutor" 1332 | React-RuntimeHermes: 1333 | :path: "../node_modules/react-native/ReactCommon/react/runtime" 1334 | React-runtimescheduler: 1335 | :path: "../node_modules/react-native/ReactCommon/react/renderer/runtimescheduler" 1336 | React-utils: 1337 | :path: "../node_modules/react-native/ReactCommon/react/utils" 1338 | ReactCommon: 1339 | :path: "../node_modules/react-native/ReactCommon" 1340 | Yoga: 1341 | :path: "../node_modules/react-native/ReactCommon/yoga" 1342 | 1343 | SPEC CHECKSUMS: 1344 | boost: d3f49c53809116a5d38da093a8aa78bf551aed09 1345 | DoubleConversion: 76ab83afb40bddeeee456813d9c04f67f78771b5 1346 | FBLazyVector: 4c674c2d53de79c145d6a723910543d7b57ed74c 1347 | fmt: 4c2741a687cc09f0634a2e2c72a838b99f1ff120 1348 | glog: fdfdfe5479092de0c4bdbebedd9056951f092c4f 1349 | hermes-engine: 6312f669c895e05f0f6029554061593711770ea6 1350 | RCT-Folly: 02617c592a293bd6d418e0a88ff4ee1f88329b47 1351 | RCTDeprecation: d83da85890d5bb18efd2809a733865c1c5c11487 1352 | RCTRequired: e109419eacfb10fbb79a3ecb57ebcad198593d8a 1353 | RCTTypeSafety: 9d0307c2738867b9850f096914a15294124b2439 1354 | React: 40ad59420ae403a6d2d49f2787f0bfaabaed4fdf 1355 | React-callinvoker: a5fb605689272d6f5640738311aa510d3f59869f 1356 | React-Codegen: 3267a426718c8a0a979d0cd0495ba793cfdba7ca 1357 | React-Core: b1eeb2b94117f6ef5b4b0ed38f2f8d482ce915ce 1358 | React-CoreModules: e60a158a4e1b109ccdd781fb649f36691eb954d7 1359 | React-cxxreact: 3749b5548f8b66a304729e159dfaf3cfd7196c3a 1360 | React-debug: 8e15e6d6456f9b8521958deb40157eeeaac2914d 1361 | React-Fabric: 52cf1f94d5c6b05fe6057ba07796a633daf93735 1362 | React-FabricImage: 6e0f28a6ec040be4b5bd1a6e5eeda7263639a24c 1363 | React-featureflags: 81279a0d43736e9867cf0b736c868257af04c827 1364 | React-graphics: 37c161d8e634526897f12837f3e62a2895dede95 1365 | React-hermes: 3cfa4668970c810db0f6b43bd5c32f5927fd0500 1366 | React-ImageManager: 276987aeb4008fe8abe10bfc53d7160c96c31052 1367 | React-jserrorhandler: 0cdb976ee0e2ed4b93f501491e84954f80bf5f34 1368 | React-jsi: 18011ef308cc43e2fb21a1de0b61eabd9f899887 1369 | React-jsiexecutor: 156298b2ddebed0f6bcc526edd3deb4d240437bc 1370 | React-jsinspector: ed6c5a768dea8e344f07242bd9946b666b78228e 1371 | React-jsitracing: 4e9c99e73a6269b27b0d4cbab277dd90df3e5ac0 1372 | React-logger: fbfb50e2a2b1b46ee087f0a52739fadecc5e81a4 1373 | React-Mapbuffer: d39610dff659d8cf1fea485abae08bbf6f9c8279 1374 | React-nativeconfig: 2be4363c2c4ac2b42419577774e83e4e4fd2af9f 1375 | React-NativeModulesApple: 453ada38f826a508e48872c7a7877c431af48bba 1376 | React-perflogger: 9745f800ab4d12ec4325bde7bd090eafb87c5570 1377 | React-RCTActionSheet: 4225e883c5feaffc072c86128cc42cb070097010 1378 | React-RCTAnimation: 6b318e7e475ea574abf6a65e58e4989dd19d9ec4 1379 | React-RCTAppDelegate: 00d29b205df54386bc4e9c8929c500ed00ee1d57 1380 | React-RCTBlob: cf152386cc829be9323b2845fd9ec25122a986c3 1381 | React-RCTFabric: 071b326a331bd1ccb59e5886c0cd38e414ec9c9f 1382 | React-RCTImage: d3d5e0f0740fbd53705f7e9acc067bafe395026c 1383 | React-RCTLinking: 3ed7d222d3534287b408855b9d378d6576b7661b 1384 | React-RCTNetwork: 33a6bb615c1f7678538298aed9f27ecd69d512f3 1385 | React-RCTSettings: bbadd0bedde8fc5f4ef337534b1368d61e104e76 1386 | React-RCTText: 1a41cd4ce814366745b6107e6f15eb0ada7ff240 1387 | React-RCTVibration: 8275c91f707e03ead0a010e9fbeda53a645335ca 1388 | React-rendererdebug: 6ba24e1d975c89a6e92440be4f246ba8bed432c6 1389 | React-rncore: 65fe0264f5c93ccb65bd6cae6201c80d34e625c0 1390 | React-RuntimeApple: 93e7c4c6a0be2eb3ce8dc31fdddea5708cd2ad2b 1391 | React-RuntimeCore: 1a2f2dfcba853d01c083db2b7d96f32f9768a677 1392 | React-runtimeexecutor: 6abf418f2d0038fb3fef15444d9c691db198771c 1393 | React-RuntimeHermes: fb6f76a5cd4212a0af4789794d4a9f5147e2f1aa 1394 | React-runtimescheduler: 3f312d33f475467a59864e0c5ab8708461387d1c 1395 | React-utils: e8b0eac797c81c574b24f6515fec4015599b643c 1396 | ReactCommon: eebffb37a90138c6db6eb8b2d952e7e5c6bc083c 1397 | SocketRocket: abac6f5de4d4d62d24e11868d7a2f427e0ef940d 1398 | Yoga: 0efb3e1bd40ba59b009f01badea863281101de78 1399 | 1400 | PODFILE CHECKSUM: 71a689932e49f453bd6454dd189b45915dda66a0 1401 | 1402 | COCOAPODS: 1.15.2 1403 | -------------------------------------------------------------------------------- /example/ios/example.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 54; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* exampleTests.m */; }; 11 | 0C80B921A6F3F58F76C31292 /* libPods-example.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-example.a */; }; 12 | 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.mm */; }; 13 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 14 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 15 | 7699B88040F8A987B510C191 /* libPods-example-exampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 19F6CBCC0A4E27FBF8BF4A61 /* libPods-example-exampleTests.a */; }; 16 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; 17 | FFCC34E7D0E38112E5400661 /* PrivacyInfo.xcprivacy in Resources */ = {isa = PBXBuildFile; fileRef = 228C9F5036157DEF0B704DBF /* PrivacyInfo.xcprivacy */; }; 18 | /* End PBXBuildFile section */ 19 | 20 | /* Begin PBXContainerItemProxy section */ 21 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = { 22 | isa = PBXContainerItemProxy; 23 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 24 | proxyType = 1; 25 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A; 26 | remoteInfo = example; 27 | }; 28 | /* End PBXContainerItemProxy section */ 29 | 30 | /* Begin PBXFileReference section */ 31 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = exampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 32 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 33 | 00E356F21AD99517003FC87E /* exampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = exampleTests.m; sourceTree = ""; }; 34 | 13B07F961A680F5B00A75B9A /* example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = example.app; sourceTree = BUILT_PRODUCTS_DIR; }; 35 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = example/AppDelegate.h; sourceTree = ""; }; 36 | 13B07FB01A68108700A75B9A /* AppDelegate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = AppDelegate.mm; path = example/AppDelegate.mm; sourceTree = ""; }; 37 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = example/Images.xcassets; sourceTree = ""; }; 38 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = example/Info.plist; sourceTree = ""; }; 39 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = example/main.m; sourceTree = ""; }; 40 | 13B07FB81A68108700A75B9A /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = PrivacyInfo.xcprivacy; path = example/PrivacyInfo.xcprivacy; sourceTree = ""; }; 41 | 19F6CBCC0A4E27FBF8BF4A61 /* libPods-example-exampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-example-exampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 42 | 228C9F5036157DEF0B704DBF /* PrivacyInfo.xcprivacy */ = {isa = PBXFileReference; includeInIndex = 1; name = PrivacyInfo.xcprivacy; path = example/PrivacyInfo.xcprivacy; sourceTree = ""; }; 43 | 3B4392A12AC88292D35C810B /* Pods-example.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example.debug.xcconfig"; path = "Target Support Files/Pods-example/Pods-example.debug.xcconfig"; sourceTree = ""; }; 44 | 5709B34CF0A7D63546082F79 /* Pods-example.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example.release.xcconfig"; path = "Target Support Files/Pods-example/Pods-example.release.xcconfig"; sourceTree = ""; }; 45 | 5B7EB9410499542E8C5724F5 /* Pods-example-exampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example-exampleTests.debug.xcconfig"; path = "Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests.debug.xcconfig"; sourceTree = ""; }; 46 | 5DCACB8F33CDC322A6C60F78 /* libPods-example.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-example.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 47 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = example/LaunchScreen.storyboard; sourceTree = ""; }; 48 | 89C6BE57DB24E9ADA2F236DE /* Pods-example-exampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-example-exampleTests.release.xcconfig"; path = "Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests.release.xcconfig"; sourceTree = ""; }; 49 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; 50 | /* End PBXFileReference section */ 51 | 52 | /* Begin PBXFrameworksBuildPhase section */ 53 | 00E356EB1AD99517003FC87E /* Frameworks */ = { 54 | isa = PBXFrameworksBuildPhase; 55 | buildActionMask = 2147483647; 56 | files = ( 57 | 7699B88040F8A987B510C191 /* libPods-example-exampleTests.a in Frameworks */, 58 | ); 59 | runOnlyForDeploymentPostprocessing = 0; 60 | }; 61 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = { 62 | isa = PBXFrameworksBuildPhase; 63 | buildActionMask = 2147483647; 64 | files = ( 65 | 0C80B921A6F3F58F76C31292 /* libPods-example.a in Frameworks */, 66 | ); 67 | runOnlyForDeploymentPostprocessing = 0; 68 | }; 69 | /* End PBXFrameworksBuildPhase section */ 70 | 71 | /* Begin PBXGroup section */ 72 | 00E356EF1AD99517003FC87E /* exampleTests */ = { 73 | isa = PBXGroup; 74 | children = ( 75 | 00E356F21AD99517003FC87E /* exampleTests.m */, 76 | 00E356F01AD99517003FC87E /* Supporting Files */, 77 | ); 78 | path = exampleTests; 79 | sourceTree = ""; 80 | }; 81 | 00E356F01AD99517003FC87E /* Supporting Files */ = { 82 | isa = PBXGroup; 83 | children = ( 84 | 00E356F11AD99517003FC87E /* Info.plist */, 85 | ); 86 | name = "Supporting Files"; 87 | sourceTree = ""; 88 | }; 89 | 13B07FAE1A68108700A75B9A /* example */ = { 90 | isa = PBXGroup; 91 | children = ( 92 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */, 93 | 13B07FB01A68108700A75B9A /* AppDelegate.mm */, 94 | 13B07FB51A68108700A75B9A /* Images.xcassets */, 95 | 13B07FB61A68108700A75B9A /* Info.plist */, 96 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */, 97 | 13B07FB71A68108700A75B9A /* main.m */, 98 | 13B07FB81A68108700A75B9A /* PrivacyInfo.xcprivacy */, 99 | 228C9F5036157DEF0B704DBF /* PrivacyInfo.xcprivacy */, 100 | ); 101 | name = example; 102 | sourceTree = ""; 103 | }; 104 | 2D16E6871FA4F8E400B85C8A /* Frameworks */ = { 105 | isa = PBXGroup; 106 | children = ( 107 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */, 108 | 5DCACB8F33CDC322A6C60F78 /* libPods-example.a */, 109 | 19F6CBCC0A4E27FBF8BF4A61 /* libPods-example-exampleTests.a */, 110 | ); 111 | name = Frameworks; 112 | sourceTree = ""; 113 | }; 114 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = { 115 | isa = PBXGroup; 116 | children = ( 117 | ); 118 | name = Libraries; 119 | sourceTree = ""; 120 | }; 121 | 83CBB9F61A601CBA00E9B192 = { 122 | isa = PBXGroup; 123 | children = ( 124 | 13B07FAE1A68108700A75B9A /* example */, 125 | 832341AE1AAA6A7D00B99B32 /* Libraries */, 126 | 00E356EF1AD99517003FC87E /* exampleTests */, 127 | 83CBBA001A601CBA00E9B192 /* Products */, 128 | 2D16E6871FA4F8E400B85C8A /* Frameworks */, 129 | BBD78D7AC51CEA395F1C20DB /* Pods */, 130 | ); 131 | indentWidth = 2; 132 | sourceTree = ""; 133 | tabWidth = 2; 134 | usesTabs = 0; 135 | }; 136 | 83CBBA001A601CBA00E9B192 /* Products */ = { 137 | isa = PBXGroup; 138 | children = ( 139 | 13B07F961A680F5B00A75B9A /* example.app */, 140 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */, 141 | ); 142 | name = Products; 143 | sourceTree = ""; 144 | }; 145 | BBD78D7AC51CEA395F1C20DB /* Pods */ = { 146 | isa = PBXGroup; 147 | children = ( 148 | 3B4392A12AC88292D35C810B /* Pods-example.debug.xcconfig */, 149 | 5709B34CF0A7D63546082F79 /* Pods-example.release.xcconfig */, 150 | 5B7EB9410499542E8C5724F5 /* Pods-example-exampleTests.debug.xcconfig */, 151 | 89C6BE57DB24E9ADA2F236DE /* Pods-example-exampleTests.release.xcconfig */, 152 | ); 153 | path = Pods; 154 | sourceTree = ""; 155 | }; 156 | /* End PBXGroup section */ 157 | 158 | /* Begin PBXNativeTarget section */ 159 | 00E356ED1AD99517003FC87E /* exampleTests */ = { 160 | isa = PBXNativeTarget; 161 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */; 162 | buildPhases = ( 163 | A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */, 164 | 00E356EA1AD99517003FC87E /* Sources */, 165 | 00E356EB1AD99517003FC87E /* Frameworks */, 166 | 00E356EC1AD99517003FC87E /* Resources */, 167 | C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */, 168 | F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */, 169 | ); 170 | buildRules = ( 171 | ); 172 | dependencies = ( 173 | 00E356F51AD99517003FC87E /* PBXTargetDependency */, 174 | ); 175 | name = exampleTests; 176 | productName = exampleTests; 177 | productReference = 00E356EE1AD99517003FC87E /* exampleTests.xctest */; 178 | productType = "com.apple.product-type.bundle.unit-test"; 179 | }; 180 | 13B07F861A680F5B00A75B9A /* example */ = { 181 | isa = PBXNativeTarget; 182 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */; 183 | buildPhases = ( 184 | C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */, 185 | 13B07F871A680F5B00A75B9A /* Sources */, 186 | 13B07F8C1A680F5B00A75B9A /* Frameworks */, 187 | 13B07F8E1A680F5B00A75B9A /* Resources */, 188 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, 189 | 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */, 190 | E235C05ADACE081382539298 /* [CP] Copy Pods Resources */, 191 | ); 192 | buildRules = ( 193 | ); 194 | dependencies = ( 195 | ); 196 | name = example; 197 | productName = example; 198 | productReference = 13B07F961A680F5B00A75B9A /* example.app */; 199 | productType = "com.apple.product-type.application"; 200 | }; 201 | /* End PBXNativeTarget section */ 202 | 203 | /* Begin PBXProject section */ 204 | 83CBB9F71A601CBA00E9B192 /* Project object */ = { 205 | isa = PBXProject; 206 | attributes = { 207 | LastUpgradeCheck = 1210; 208 | TargetAttributes = { 209 | 00E356ED1AD99517003FC87E = { 210 | CreatedOnToolsVersion = 6.2; 211 | TestTargetID = 13B07F861A680F5B00A75B9A; 212 | }; 213 | 13B07F861A680F5B00A75B9A = { 214 | LastSwiftMigration = 1120; 215 | }; 216 | }; 217 | }; 218 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */; 219 | compatibilityVersion = "Xcode 12.0"; 220 | developmentRegion = en; 221 | hasScannedForEncodings = 0; 222 | knownRegions = ( 223 | en, 224 | Base, 225 | ); 226 | mainGroup = 83CBB9F61A601CBA00E9B192; 227 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */; 228 | projectDirPath = ""; 229 | projectRoot = ""; 230 | targets = ( 231 | 13B07F861A680F5B00A75B9A /* example */, 232 | 00E356ED1AD99517003FC87E /* exampleTests */, 233 | ); 234 | }; 235 | /* End PBXProject section */ 236 | 237 | /* Begin PBXResourcesBuildPhase section */ 238 | 00E356EC1AD99517003FC87E /* Resources */ = { 239 | isa = PBXResourcesBuildPhase; 240 | buildActionMask = 2147483647; 241 | files = ( 242 | ); 243 | runOnlyForDeploymentPostprocessing = 0; 244 | }; 245 | 13B07F8E1A680F5B00A75B9A /* Resources */ = { 246 | isa = PBXResourcesBuildPhase; 247 | buildActionMask = 2147483647; 248 | files = ( 249 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */, 250 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */, 251 | FFCC34E7D0E38112E5400661 /* PrivacyInfo.xcprivacy in Resources */, 252 | ); 253 | runOnlyForDeploymentPostprocessing = 0; 254 | }; 255 | /* End PBXResourcesBuildPhase section */ 256 | 257 | /* Begin PBXShellScriptBuildPhase section */ 258 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = { 259 | isa = PBXShellScriptBuildPhase; 260 | buildActionMask = 2147483647; 261 | files = ( 262 | ); 263 | inputPaths = ( 264 | "$(SRCROOT)/.xcode.env.local", 265 | "$(SRCROOT)/.xcode.env", 266 | ); 267 | name = "Bundle React Native code and images"; 268 | outputPaths = ( 269 | ); 270 | runOnlyForDeploymentPostprocessing = 0; 271 | shellPath = /bin/sh; 272 | shellScript = "set -e\n\nWITH_ENVIRONMENT=\"$REACT_NATIVE_PATH/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"$REACT_NATIVE_PATH/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n"; 273 | }; 274 | 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */ = { 275 | isa = PBXShellScriptBuildPhase; 276 | buildActionMask = 2147483647; 277 | files = ( 278 | ); 279 | inputFileListPaths = ( 280 | "${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-frameworks-${CONFIGURATION}-input-files.xcfilelist", 281 | ); 282 | name = "[CP] Embed Pods Frameworks"; 283 | outputFileListPaths = ( 284 | "${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-frameworks-${CONFIGURATION}-output-files.xcfilelist", 285 | ); 286 | runOnlyForDeploymentPostprocessing = 0; 287 | shellPath = /bin/sh; 288 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-frameworks.sh\"\n"; 289 | showEnvVarsInLog = 0; 290 | }; 291 | A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */ = { 292 | isa = PBXShellScriptBuildPhase; 293 | buildActionMask = 2147483647; 294 | files = ( 295 | ); 296 | inputFileListPaths = ( 297 | ); 298 | inputPaths = ( 299 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 300 | "${PODS_ROOT}/Manifest.lock", 301 | ); 302 | name = "[CP] Check Pods Manifest.lock"; 303 | outputFileListPaths = ( 304 | ); 305 | outputPaths = ( 306 | "$(DERIVED_FILE_DIR)/Pods-example-exampleTests-checkManifestLockResult.txt", 307 | ); 308 | runOnlyForDeploymentPostprocessing = 0; 309 | shellPath = /bin/sh; 310 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 311 | showEnvVarsInLog = 0; 312 | }; 313 | C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */ = { 314 | isa = PBXShellScriptBuildPhase; 315 | buildActionMask = 2147483647; 316 | files = ( 317 | ); 318 | inputFileListPaths = ( 319 | ); 320 | inputPaths = ( 321 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 322 | "${PODS_ROOT}/Manifest.lock", 323 | ); 324 | name = "[CP] Check Pods Manifest.lock"; 325 | outputFileListPaths = ( 326 | ); 327 | outputPaths = ( 328 | "$(DERIVED_FILE_DIR)/Pods-example-checkManifestLockResult.txt", 329 | ); 330 | runOnlyForDeploymentPostprocessing = 0; 331 | shellPath = /bin/sh; 332 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 333 | showEnvVarsInLog = 0; 334 | }; 335 | C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */ = { 336 | isa = PBXShellScriptBuildPhase; 337 | buildActionMask = 2147483647; 338 | files = ( 339 | ); 340 | inputFileListPaths = ( 341 | "${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", 342 | ); 343 | name = "[CP] Embed Pods Frameworks"; 344 | outputFileListPaths = ( 345 | "${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", 346 | ); 347 | runOnlyForDeploymentPostprocessing = 0; 348 | shellPath = /bin/sh; 349 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-frameworks.sh\"\n"; 350 | showEnvVarsInLog = 0; 351 | }; 352 | E235C05ADACE081382539298 /* [CP] Copy Pods Resources */ = { 353 | isa = PBXShellScriptBuildPhase; 354 | buildActionMask = 2147483647; 355 | files = ( 356 | ); 357 | inputFileListPaths = ( 358 | "${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-resources-${CONFIGURATION}-input-files.xcfilelist", 359 | ); 360 | name = "[CP] Copy Pods Resources"; 361 | outputFileListPaths = ( 362 | "${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-resources-${CONFIGURATION}-output-files.xcfilelist", 363 | ); 364 | runOnlyForDeploymentPostprocessing = 0; 365 | shellPath = /bin/sh; 366 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-example/Pods-example-resources.sh\"\n"; 367 | showEnvVarsInLog = 0; 368 | }; 369 | F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */ = { 370 | isa = PBXShellScriptBuildPhase; 371 | buildActionMask = 2147483647; 372 | files = ( 373 | ); 374 | inputFileListPaths = ( 375 | "${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", 376 | ); 377 | name = "[CP] Copy Pods Resources"; 378 | outputFileListPaths = ( 379 | "${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", 380 | ); 381 | runOnlyForDeploymentPostprocessing = 0; 382 | shellPath = /bin/sh; 383 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-example-exampleTests/Pods-example-exampleTests-resources.sh\"\n"; 384 | showEnvVarsInLog = 0; 385 | }; 386 | /* End PBXShellScriptBuildPhase section */ 387 | 388 | /* Begin PBXSourcesBuildPhase section */ 389 | 00E356EA1AD99517003FC87E /* Sources */ = { 390 | isa = PBXSourcesBuildPhase; 391 | buildActionMask = 2147483647; 392 | files = ( 393 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */, 394 | ); 395 | runOnlyForDeploymentPostprocessing = 0; 396 | }; 397 | 13B07F871A680F5B00A75B9A /* Sources */ = { 398 | isa = PBXSourcesBuildPhase; 399 | buildActionMask = 2147483647; 400 | files = ( 401 | 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */, 402 | 13B07FC11A68108700A75B9A /* main.m in Sources */, 403 | ); 404 | runOnlyForDeploymentPostprocessing = 0; 405 | }; 406 | /* End PBXSourcesBuildPhase section */ 407 | 408 | /* Begin PBXTargetDependency section */ 409 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = { 410 | isa = PBXTargetDependency; 411 | target = 13B07F861A680F5B00A75B9A /* example */; 412 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */; 413 | }; 414 | /* End PBXTargetDependency section */ 415 | 416 | /* Begin XCBuildConfiguration section */ 417 | 00E356F61AD99517003FC87E /* Debug */ = { 418 | isa = XCBuildConfiguration; 419 | baseConfigurationReference = 5B7EB9410499542E8C5724F5 /* Pods-example-exampleTests.debug.xcconfig */; 420 | buildSettings = { 421 | BUNDLE_LOADER = "$(TEST_HOST)"; 422 | GCC_PREPROCESSOR_DEFINITIONS = ( 423 | "DEBUG=1", 424 | "$(inherited)", 425 | ); 426 | INFOPLIST_FILE = exampleTests/Info.plist; 427 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 428 | LD_RUNPATH_SEARCH_PATHS = ( 429 | "$(inherited)", 430 | "@executable_path/Frameworks", 431 | "@loader_path/Frameworks", 432 | ); 433 | OTHER_LDFLAGS = ( 434 | "-ObjC", 435 | "-lc++", 436 | "$(inherited)", 437 | ); 438 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 439 | PRODUCT_NAME = "$(TARGET_NAME)"; 440 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example"; 441 | }; 442 | name = Debug; 443 | }; 444 | 00E356F71AD99517003FC87E /* Release */ = { 445 | isa = XCBuildConfiguration; 446 | baseConfigurationReference = 89C6BE57DB24E9ADA2F236DE /* Pods-example-exampleTests.release.xcconfig */; 447 | buildSettings = { 448 | BUNDLE_LOADER = "$(TEST_HOST)"; 449 | COPY_PHASE_STRIP = NO; 450 | INFOPLIST_FILE = exampleTests/Info.plist; 451 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 452 | LD_RUNPATH_SEARCH_PATHS = ( 453 | "$(inherited)", 454 | "@executable_path/Frameworks", 455 | "@loader_path/Frameworks", 456 | ); 457 | OTHER_LDFLAGS = ( 458 | "-ObjC", 459 | "-lc++", 460 | "$(inherited)", 461 | ); 462 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 463 | PRODUCT_NAME = "$(TARGET_NAME)"; 464 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example"; 465 | }; 466 | name = Release; 467 | }; 468 | 13B07F941A680F5B00A75B9A /* Debug */ = { 469 | isa = XCBuildConfiguration; 470 | baseConfigurationReference = 3B4392A12AC88292D35C810B /* Pods-example.debug.xcconfig */; 471 | buildSettings = { 472 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 473 | CLANG_ENABLE_MODULES = YES; 474 | CURRENT_PROJECT_VERSION = 1; 475 | ENABLE_BITCODE = NO; 476 | INFOPLIST_FILE = example/Info.plist; 477 | LD_RUNPATH_SEARCH_PATHS = ( 478 | "$(inherited)", 479 | "@executable_path/Frameworks", 480 | ); 481 | MARKETING_VERSION = 1.0; 482 | OTHER_LDFLAGS = ( 483 | "$(inherited)", 484 | "-ObjC", 485 | "-lc++", 486 | ); 487 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 488 | PRODUCT_NAME = example; 489 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 490 | SWIFT_VERSION = 5.0; 491 | VERSIONING_SYSTEM = "apple-generic"; 492 | }; 493 | name = Debug; 494 | }; 495 | 13B07F951A680F5B00A75B9A /* Release */ = { 496 | isa = XCBuildConfiguration; 497 | baseConfigurationReference = 5709B34CF0A7D63546082F79 /* Pods-example.release.xcconfig */; 498 | buildSettings = { 499 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 500 | CLANG_ENABLE_MODULES = YES; 501 | CURRENT_PROJECT_VERSION = 1; 502 | INFOPLIST_FILE = example/Info.plist; 503 | LD_RUNPATH_SEARCH_PATHS = ( 504 | "$(inherited)", 505 | "@executable_path/Frameworks", 506 | ); 507 | MARKETING_VERSION = 1.0; 508 | OTHER_LDFLAGS = ( 509 | "$(inherited)", 510 | "-ObjC", 511 | "-lc++", 512 | ); 513 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 514 | PRODUCT_NAME = example; 515 | SWIFT_VERSION = 5.0; 516 | VERSIONING_SYSTEM = "apple-generic"; 517 | }; 518 | name = Release; 519 | }; 520 | 83CBBA201A601CBA00E9B192 /* Debug */ = { 521 | isa = XCBuildConfiguration; 522 | buildSettings = { 523 | ALWAYS_SEARCH_USER_PATHS = NO; 524 | CC = ""; 525 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 526 | CLANG_CXX_LANGUAGE_STANDARD = "c++20"; 527 | CLANG_CXX_LIBRARY = "libc++"; 528 | CLANG_ENABLE_MODULES = YES; 529 | CLANG_ENABLE_OBJC_ARC = YES; 530 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 531 | CLANG_WARN_BOOL_CONVERSION = YES; 532 | CLANG_WARN_COMMA = YES; 533 | CLANG_WARN_CONSTANT_CONVERSION = YES; 534 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 535 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 536 | CLANG_WARN_EMPTY_BODY = YES; 537 | CLANG_WARN_ENUM_CONVERSION = YES; 538 | CLANG_WARN_INFINITE_RECURSION = YES; 539 | CLANG_WARN_INT_CONVERSION = YES; 540 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 541 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 542 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 543 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 544 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 545 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 546 | CLANG_WARN_STRICT_PROTOTYPES = YES; 547 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 548 | CLANG_WARN_UNREACHABLE_CODE = YES; 549 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 550 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 551 | COPY_PHASE_STRIP = NO; 552 | CXX = ""; 553 | ENABLE_STRICT_OBJC_MSGSEND = YES; 554 | ENABLE_TESTABILITY = YES; 555 | "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = ""; 556 | GCC_C_LANGUAGE_STANDARD = gnu99; 557 | GCC_DYNAMIC_NO_PIC = NO; 558 | GCC_NO_COMMON_BLOCKS = YES; 559 | GCC_OPTIMIZATION_LEVEL = 0; 560 | GCC_PREPROCESSOR_DEFINITIONS = ( 561 | "DEBUG=1", 562 | "$(inherited)", 563 | ); 564 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 565 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 566 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 567 | GCC_WARN_UNDECLARED_SELECTOR = YES; 568 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 569 | GCC_WARN_UNUSED_FUNCTION = YES; 570 | GCC_WARN_UNUSED_VARIABLE = YES; 571 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 572 | LD = ""; 573 | LDPLUSPLUS = ""; 574 | LD_RUNPATH_SEARCH_PATHS = ( 575 | /usr/lib/swift, 576 | "$(inherited)", 577 | ); 578 | LIBRARY_SEARCH_PATHS = ( 579 | "\"$(SDKROOT)/usr/lib/swift\"", 580 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 581 | "\"$(inherited)\"", 582 | ); 583 | MTL_ENABLE_DEBUG_INFO = YES; 584 | ONLY_ACTIVE_ARCH = YES; 585 | OTHER_CPLUSPLUSFLAGS = ( 586 | "$(OTHER_CFLAGS)", 587 | "-DFOLLY_NO_CONFIG", 588 | "-DFOLLY_MOBILE=1", 589 | "-DFOLLY_USE_LIBCPP=1", 590 | "-DFOLLY_CFG_NO_COROUTINES=1", 591 | "-DFOLLY_HAVE_CLOCK_GETTIME=1", 592 | ); 593 | OTHER_LDFLAGS = ( 594 | "$(inherited)", 595 | " ", 596 | ); 597 | REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; 598 | SDKROOT = iphoneos; 599 | USE_HERMES = true; 600 | }; 601 | name = Debug; 602 | }; 603 | 83CBBA211A601CBA00E9B192 /* Release */ = { 604 | isa = XCBuildConfiguration; 605 | buildSettings = { 606 | ALWAYS_SEARCH_USER_PATHS = NO; 607 | CC = ""; 608 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 609 | CLANG_CXX_LANGUAGE_STANDARD = "c++20"; 610 | CLANG_CXX_LIBRARY = "libc++"; 611 | CLANG_ENABLE_MODULES = YES; 612 | CLANG_ENABLE_OBJC_ARC = YES; 613 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 614 | CLANG_WARN_BOOL_CONVERSION = YES; 615 | CLANG_WARN_COMMA = YES; 616 | CLANG_WARN_CONSTANT_CONVERSION = YES; 617 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 618 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 619 | CLANG_WARN_EMPTY_BODY = YES; 620 | CLANG_WARN_ENUM_CONVERSION = YES; 621 | CLANG_WARN_INFINITE_RECURSION = YES; 622 | CLANG_WARN_INT_CONVERSION = YES; 623 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 624 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 625 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 626 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 627 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 628 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 629 | CLANG_WARN_STRICT_PROTOTYPES = YES; 630 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 631 | CLANG_WARN_UNREACHABLE_CODE = YES; 632 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 633 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 634 | COPY_PHASE_STRIP = YES; 635 | CXX = ""; 636 | ENABLE_NS_ASSERTIONS = NO; 637 | ENABLE_STRICT_OBJC_MSGSEND = YES; 638 | "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = ""; 639 | GCC_C_LANGUAGE_STANDARD = gnu99; 640 | GCC_NO_COMMON_BLOCKS = YES; 641 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 642 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 643 | GCC_WARN_UNDECLARED_SELECTOR = YES; 644 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 645 | GCC_WARN_UNUSED_FUNCTION = YES; 646 | GCC_WARN_UNUSED_VARIABLE = YES; 647 | IPHONEOS_DEPLOYMENT_TARGET = 13.4; 648 | LD = ""; 649 | LDPLUSPLUS = ""; 650 | LD_RUNPATH_SEARCH_PATHS = ( 651 | /usr/lib/swift, 652 | "$(inherited)", 653 | ); 654 | LIBRARY_SEARCH_PATHS = ( 655 | "\"$(SDKROOT)/usr/lib/swift\"", 656 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 657 | "\"$(inherited)\"", 658 | ); 659 | MTL_ENABLE_DEBUG_INFO = NO; 660 | OTHER_CPLUSPLUSFLAGS = ( 661 | "$(OTHER_CFLAGS)", 662 | "-DFOLLY_NO_CONFIG", 663 | "-DFOLLY_MOBILE=1", 664 | "-DFOLLY_USE_LIBCPP=1", 665 | "-DFOLLY_CFG_NO_COROUTINES=1", 666 | "-DFOLLY_HAVE_CLOCK_GETTIME=1", 667 | ); 668 | OTHER_LDFLAGS = ( 669 | "$(inherited)", 670 | " ", 671 | ); 672 | REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; 673 | SDKROOT = iphoneos; 674 | USE_HERMES = true; 675 | VALIDATE_PRODUCT = YES; 676 | }; 677 | name = Release; 678 | }; 679 | /* End XCBuildConfiguration section */ 680 | 681 | /* Begin XCConfigurationList section */ 682 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */ = { 683 | isa = XCConfigurationList; 684 | buildConfigurations = ( 685 | 00E356F61AD99517003FC87E /* Debug */, 686 | 00E356F71AD99517003FC87E /* Release */, 687 | ); 688 | defaultConfigurationIsVisible = 0; 689 | defaultConfigurationName = Release; 690 | }; 691 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */ = { 692 | isa = XCConfigurationList; 693 | buildConfigurations = ( 694 | 13B07F941A680F5B00A75B9A /* Debug */, 695 | 13B07F951A680F5B00A75B9A /* Release */, 696 | ); 697 | defaultConfigurationIsVisible = 0; 698 | defaultConfigurationName = Release; 699 | }; 700 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */ = { 701 | isa = XCConfigurationList; 702 | buildConfigurations = ( 703 | 83CBBA201A601CBA00E9B192 /* Debug */, 704 | 83CBBA211A601CBA00E9B192 /* Release */, 705 | ); 706 | defaultConfigurationIsVisible = 0; 707 | defaultConfigurationName = Release; 708 | }; 709 | /* End XCConfigurationList section */ 710 | }; 711 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */; 712 | } 713 | -------------------------------------------------------------------------------- /example/ios/example.xcodeproj/xcshareddata/xcschemes/example.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 33 | 39 | 40 | 41 | 42 | 43 | 53 | 55 | 61 | 62 | 63 | 64 | 70 | 72 | 78 | 79 | 80 | 81 | 83 | 84 | 87 | 88 | 89 | -------------------------------------------------------------------------------- /example/ios/example.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /example/ios/example.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/example/AppDelegate.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface AppDelegate : RCTAppDelegate 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /example/ios/example/AppDelegate.mm: -------------------------------------------------------------------------------- 1 | #import "AppDelegate.h" 2 | 3 | #import 4 | 5 | @implementation AppDelegate 6 | 7 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 8 | { 9 | self.moduleName = @"example"; 10 | // You can add your custom initial props in the dictionary below. 11 | // They will be passed down to the ViewController used by React Native. 12 | self.initialProps = @{}; 13 | 14 | return [super application:application didFinishLaunchingWithOptions:launchOptions]; 15 | } 16 | 17 | - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge 18 | { 19 | return [self bundleURL]; 20 | } 21 | 22 | - (NSURL *)bundleURL 23 | { 24 | #if DEBUG 25 | return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index"]; 26 | #else 27 | return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"]; 28 | #endif 29 | } 30 | 31 | @end 32 | -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ios-marketing", 45 | "scale" : "1x", 46 | "size" : "1024x1024" 47 | } 48 | ], 49 | "info" : { 50 | "author" : "xcode", 51 | "version" : 1 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /example/ios/example/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /example/ios/example/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | example 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(MARKETING_VERSION) 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | $(CURRENT_PROJECT_VERSION) 25 | LSRequiresIPhoneOS 26 | 27 | NSAppTransportSecurity 28 | 29 | 30 | NSAllowsArbitraryLoads 31 | 32 | NSAllowsLocalNetworking 33 | 34 | 35 | NSLocationWhenInUseUsageDescription 36 | 37 | UILaunchStoryboardName 38 | LaunchScreen 39 | UIRequiredDeviceCapabilities 40 | 41 | arm64 42 | 43 | UISupportedInterfaceOrientations 44 | 45 | UIInterfaceOrientationPortrait 46 | UIInterfaceOrientationLandscapeLeft 47 | UIInterfaceOrientationLandscapeRight 48 | 49 | UIViewControllerBasedStatusBarAppearance 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /example/ios/example/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 24 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /example/ios/example/PrivacyInfo.xcprivacy: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | NSPrivacyAccessedAPITypes 6 | 7 | 8 | NSPrivacyAccessedAPIType 9 | NSPrivacyAccessedAPICategoryFileTimestamp 10 | NSPrivacyAccessedAPITypeReasons 11 | 12 | C617.1 13 | 14 | 15 | 16 | NSPrivacyAccessedAPIType 17 | NSPrivacyAccessedAPICategoryUserDefaults 18 | NSPrivacyAccessedAPITypeReasons 19 | 20 | CA92.1 21 | 22 | 23 | 24 | NSPrivacyAccessedAPIType 25 | NSPrivacyAccessedAPICategorySystemBootTime 26 | NSPrivacyAccessedAPITypeReasons 27 | 28 | 35F9.1 29 | 30 | 31 | 32 | NSPrivacyCollectedDataTypes 33 | 34 | NSPrivacyTracking 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /example/ios/example/main.m: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "AppDelegate.h" 4 | 5 | int main(int argc, char *argv[]) 6 | { 7 | @autoreleasepool { 8 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /example/ios/exampleTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /example/ios/exampleTests/exampleTests.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | #import 5 | #import 6 | 7 | #define TIMEOUT_SECONDS 600 8 | #define TEXT_TO_LOOK_FOR @"Welcome to React" 9 | 10 | @interface exampleTests : XCTestCase 11 | 12 | @end 13 | 14 | @implementation exampleTests 15 | 16 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL (^)(UIView *view))test 17 | { 18 | if (test(view)) { 19 | return YES; 20 | } 21 | for (UIView *subview in [view subviews]) { 22 | if ([self findSubviewInView:subview matching:test]) { 23 | return YES; 24 | } 25 | } 26 | return NO; 27 | } 28 | 29 | - (void)testRendersWelcomeScreen 30 | { 31 | UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController]; 32 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS]; 33 | BOOL foundElement = NO; 34 | 35 | __block NSString *redboxError = nil; 36 | #ifdef DEBUG 37 | RCTSetLogFunction( 38 | ^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) { 39 | if (level >= RCTLogLevelError) { 40 | redboxError = message; 41 | } 42 | }); 43 | #endif 44 | 45 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) { 46 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 47 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 48 | 49 | foundElement = [self findSubviewInView:vc.view 50 | matching:^BOOL(UIView *view) { 51 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) { 52 | return YES; 53 | } 54 | return NO; 55 | }]; 56 | } 57 | 58 | #ifdef DEBUG 59 | RCTSetLogFunction(RCTDefaultLogFunction); 60 | #endif 61 | 62 | XCTAssertNil(redboxError, @"RedBox error: %@", redboxError); 63 | XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS); 64 | } 65 | 66 | @end 67 | -------------------------------------------------------------------------------- /example/metro.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const blacklist = require('metro-config/src/defaults/exclusionList'); 3 | const escape = require('escape-string-regexp'); 4 | const pak = require('../package.json'); 5 | const { getDefaultConfig, mergeConfig } = require('@react-native/metro-config'); 6 | 7 | const root = path.resolve(__dirname, '..'); 8 | 9 | const modules = Object.keys({ 10 | ...pak.peerDependencies, 11 | }); 12 | 13 | /** 14 | * Metro configuration 15 | * https://reactnative.dev/docs/metro 16 | * 17 | * @type {import('metro-config').MetroConfig} 18 | */ 19 | const config = { 20 | projectRoot: __dirname, 21 | watchFolders: [root], 22 | 23 | // We need to make sure that only one version is loaded for peerDependencies 24 | // So we blacklist them at the root, and alias them to the versions in example's node_modules 25 | resolver: { 26 | blacklistRE: blacklist( 27 | modules.map((m) => new RegExp(`^${escape(path.join(root, 'node_modules', m))}\\/.*$`)), 28 | ), 29 | 30 | extraNodeModules: modules.reduce((acc, name) => { 31 | acc[name] = path.join(__dirname, 'node_modules', name); 32 | return acc; 33 | }, {}), 34 | }, 35 | }; 36 | 37 | module.exports = mergeConfig(getDefaultConfig(__dirname), config); 38 | -------------------------------------------------------------------------------- /example/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "example", 3 | "version": "0.0.1", 4 | "private": true, 5 | "scripts": { 6 | "android": "react-native run-android", 7 | "ios": "react-native run-ios", 8 | "start": "react-native start", 9 | "test": "jest", 10 | "lint": "eslint ." 11 | }, 12 | "dependencies": { 13 | "react": "18.2.0", 14 | "react-native": "0.74.4" 15 | }, 16 | "devDependencies": { 17 | "@babel/core": "^7.20.0", 18 | "@babel/preset-env": "^7.20.0", 19 | "@babel/runtime": "^7.26.10", 20 | "@react-native/babel-preset": "0.74.86", 21 | "@react-native/eslint-config": "0.74.86", 22 | "@react-native/metro-config": "0.74.86", 23 | "@react-native/typescript-config": "0.74.86", 24 | "@types/react": "^18.2.6", 25 | "@types/react-test-renderer": "^18.0.0", 26 | "babel-jest": "^29.6.3", 27 | "babel-plugin-module-resolver": "^5.0.2", 28 | "eslint": "^8.19.0", 29 | "jest": "^29.6.3", 30 | "prettier": "2.8.8", 31 | "react-test-renderer": "18.2.0", 32 | "typescript": "5.0.4" 33 | }, 34 | "engines": { 35 | "node": ">=18" 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /jest.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | preset: 'react-native', 3 | }; 4 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "@kolking/react-native-avatar", 3 | "version": "2.1.5", 4 | "description": "Display user avatars in React Native like a pro with support for Gravatar, user initials, unique colors, badges, statuses, and more.", 5 | "author": "Nick Seryakov (https://github.com/kolking)", 6 | "license": "MIT", 7 | "homepage": "https://github.com/kolking/react-native-avatar#readme", 8 | "repository": { 9 | "type": "git", 10 | "url": "git+https://kolking@github.com/kolking/react-native-avatar.git" 11 | }, 12 | "bugs": { 13 | "url": "https://github.com/kolking/react-native-avatar/issues" 14 | }, 15 | "keywords": [ 16 | "react-native", 17 | "ios", 18 | "android", 19 | "userpic", 20 | "avatar", 21 | "gravatar", 22 | "avatar image", 23 | "user picture", 24 | "user image", 25 | "user avatar", 26 | "initials", 27 | "badge" 28 | ], 29 | "main": "src/index", 30 | "react-native": "src/index", 31 | "source": "src/index", 32 | "scripts": { 33 | "start": "cd example && yarn start", 34 | "test": "jest --passWithNoTests", 35 | "coverage": "yarn test --coverage", 36 | "lint": "eslint --ext .js,.jsx,.ts,.tsx ./", 37 | "validate": "yarn tsc && yarn lint --fix && yarn test -u", 38 | "validate-ci": "yarn tsc && yarn lint && yarn coverage", 39 | "install-all": "yarn && cd example && yarn && npx pod-install" 40 | }, 41 | "dependencies": { 42 | "js-md5": "^0.8.3" 43 | }, 44 | "devDependencies": { 45 | "@babel/core": "^7.20.0", 46 | "@babel/preset-env": "^7.20.0", 47 | "@babel/runtime": "^7.20.0", 48 | "@react-native/babel-preset": "0.74.86", 49 | "@react-native/eslint-config": "0.74.86", 50 | "@react-native/metro-config": "0.74.86", 51 | "@react-native/typescript-config": "0.74.86", 52 | "@types/jest": "^29.5.12", 53 | "@types/js-md5": "^0.7.2", 54 | "@types/react": "^18.2.6", 55 | "@types/react-test-renderer": "^18.0.0", 56 | "babel-jest": "^29.6.3", 57 | "eslint": "^8.19.0", 58 | "jest": "^29.6.3", 59 | "prettier": "2.8.8", 60 | "react": "18.2.0", 61 | "react-native": "0.74.4", 62 | "react-test-renderer": "18.2.0", 63 | "typescript": "5.0.4" 64 | }, 65 | "engines": { 66 | "node": ">=18" 67 | }, 68 | "peerDependencies": { 69 | "react": "*", 70 | "react-native": "*" 71 | }, 72 | "publishConfig": { 73 | "registry": "https://registry.npmjs.org/", 74 | "access": "public" 75 | } 76 | } 77 | -------------------------------------------------------------------------------- /src/Avatar.tsx: -------------------------------------------------------------------------------- 1 | import React, { useCallback, useLayoutEffect, useMemo, useState } from 'react'; 2 | import { 3 | Image, 4 | ImageStyle, 5 | ImageSourcePropType, 6 | StyleSheet, 7 | StyleProp, 8 | TextStyle, 9 | View, 10 | ViewProps, 11 | ViewStyle, 12 | } from 'react-native'; 13 | 14 | import Initials from './Initials'; 15 | import Badge, { Props as BadgeProps } from './Badge'; 16 | import { clamp, colorScheme, getGravatarSource } from './helpers'; 17 | 18 | const DEFAULT_COLOR = colorScheme('#aeaeb2', '#636366'); 19 | const DEFAULT_SOURCE: ImageSourcePropType = require('./assets/default.png'); 20 | 21 | export interface Props extends ViewProps { 22 | size?: number; 23 | name?: string; 24 | email?: string; 25 | source?: ImageSourcePropType; 26 | defaultSource?: ImageSourcePropType; 27 | color?: string; 28 | radius?: number; 29 | colorize?: boolean; 30 | style?: StyleProp; 31 | textStyle?: StyleProp; 32 | badge?: BadgeProps['value']; 33 | badgeColor?: BadgeProps['color']; 34 | badgeProps?: Omit; 35 | } 36 | 37 | const Avatar = ({ 38 | size = 50, 39 | name, 40 | email, 41 | source, 42 | defaultSource = DEFAULT_SOURCE, 43 | color = DEFAULT_COLOR, 44 | radius = size / 2, 45 | colorize = false, 46 | style, 47 | textStyle, 48 | badge, 49 | badgeColor, 50 | badgeProps, 51 | ...props 52 | }: Props) => { 53 | const avatarSource = useMemo(() => { 54 | return source || (email ? getGravatarSource(size, email) : defaultSource); 55 | }, [source, size, email, defaultSource]); 56 | 57 | const [imageSource, setImageSource] = useState(avatarSource); 58 | const borderRadius = clamp(radius, 0, size / 2); 59 | 60 | useLayoutEffect(() => { 61 | setImageSource(avatarSource); 62 | }, [avatarSource]); 63 | 64 | const onImageError = useCallback(() => { 65 | setImageSource(defaultSource); 66 | }, [defaultSource]); 67 | 68 | // debug('RENDER ', name || email || imageSource); 69 | 70 | return ( 71 | 72 | {name?.trim() && imageSource === defaultSource ? ( 73 | 82 | ) : ( 83 | 88 | )} 89 | {badge !== undefined && ( 90 | 97 | )} 98 | 99 | ); 100 | }; 101 | 102 | const styles = StyleSheet.create({ 103 | root: { 104 | alignSelf: 'center', 105 | }, 106 | image: { 107 | width: '100%', 108 | height: '100%', 109 | }, 110 | }); 111 | 112 | export default React.memo(Avatar); 113 | -------------------------------------------------------------------------------- /src/Badge.tsx: -------------------------------------------------------------------------------- 1 | import React, { useEffect, useMemo, useRef } from 'react'; 2 | import { 3 | Animated, 4 | PixelRatio, 5 | StyleProp, 6 | StyleSheet, 7 | Text, 8 | TextStyle, 9 | ViewProps, 10 | ViewStyle, 11 | } from 'react-native'; 12 | 13 | import { clamp, getBadgeValue } from './helpers'; 14 | 15 | const MIN_SIZE = 15; 16 | const MAX_SIZE = 45; 17 | 18 | export enum BadgePositions { 19 | TOP_LEFT = 'top-left', 20 | TOP_RIGHT = 'top-right', 21 | BOTTOM_LEFT = 'bottom-left', 22 | BOTTOM_RIGHT = 'bottom-right', 23 | } 24 | 25 | export interface Props extends ViewProps { 26 | size?: number; 27 | color?: string; 28 | radius?: number; 29 | animate?: boolean; 30 | value?: number | string | boolean; 31 | limit?: number; 32 | parentRadius?: number; 33 | position?: `${BadgePositions}`; 34 | style?: StyleProp; 35 | textStyle?: StyleProp; 36 | } 37 | 38 | const Badge = ({ 39 | size = 20, 40 | color = '#ff3b30', 41 | radius, 42 | animate = true, 43 | value, 44 | limit = 99, 45 | parentRadius = 0, 46 | position, 47 | style, 48 | textStyle, 49 | ...props 50 | }: Props) => { 51 | const toValue = value ? 1 : 0; 52 | const animatedValue = useRef(new Animated.Value(toValue)).current; 53 | const hasContent = typeof value === 'number' || typeof value === 'string'; 54 | const minHeight = clamp(size, MIN_SIZE, MAX_SIZE) / 2; 55 | const height = hasContent ? clamp(size, MIN_SIZE, MAX_SIZE) : minHeight; 56 | 57 | useEffect(() => { 58 | if (animate) { 59 | if (toValue === 1) { 60 | Animated.spring(animatedValue, { 61 | toValue, 62 | tension: 50, 63 | friction: 6, 64 | useNativeDriver: true, 65 | }).start(); 66 | } else { 67 | animatedValue.setValue(0); 68 | } 69 | } 70 | }, [animate, animatedValue, toValue]); 71 | 72 | const offset = useMemo(() => { 73 | // We want to place the badge at the point with polar coordinates (r,45°) 74 | // thus we need to find the distance from the containing square top right corner 75 | // which can be calculated as x = r - r × sin(45°) 76 | // Self offset is how much we’ll shift the badge from the edge point, 77 | // its value ranges from height / 4 (square) to height / 2 (circle) 78 | const edgeOffset = parentRadius * (1 - Math.sin((45 * Math.PI) / 180)); 79 | const selfOffset = (1 + clamp(parentRadius / height, 0, 1)) * (height / 4); 80 | 81 | return PixelRatio.roundToNearestPixel(edgeOffset - selfOffset); 82 | }, [height, parentRadius]); 83 | 84 | if (!value) { 85 | return null; 86 | } 87 | 88 | let content = null; 89 | 90 | if (hasContent) { 91 | const fontSize = PixelRatio.roundToNearestPixel(height * 0.6); 92 | const textStyles = { 93 | ...styles.text, 94 | fontSize, 95 | marginHorizontal: fontSize / 2, 96 | }; 97 | 98 | content = ( 99 | 100 | {getBadgeValue(value, limit)} 101 | 102 | ); 103 | } 104 | 105 | const rootStyles: Animated.AnimatedProps = [ 106 | { 107 | ...styles.root, 108 | height, 109 | minWidth: height, 110 | backgroundColor: color, 111 | borderRadius: radius ?? height / 2, 112 | transform: [{ scale: animatedValue }], 113 | }, 114 | ]; 115 | 116 | if (position) { 117 | const [badgeY, badgeX] = position.split('-'); 118 | rootStyles.push({ 119 | ...styles.position, 120 | [badgeY]: offset, 121 | [badgeX]: offset, 122 | }); 123 | } 124 | 125 | // debug('RENDER ', value); 126 | 127 | return ( 128 | 129 | {content} 130 | 131 | ); 132 | }; 133 | 134 | const styles = StyleSheet.create({ 135 | root: { 136 | flexDirection: 'row', 137 | alignItems: 'center', 138 | justifyContent: 'center', 139 | }, 140 | position: { 141 | zIndex: 1, 142 | position: 'absolute', 143 | shadowColor: '#000', 144 | shadowOffset: { width: 0, height: 1 }, 145 | shadowOpacity: 0.2, 146 | shadowRadius: 1, 147 | elevation: 1, 148 | }, 149 | text: { 150 | color: '#fff', 151 | fontWeight: '400', 152 | fontFamily: 'System', 153 | includeFontPadding: false, 154 | textAlignVertical: 'center', 155 | backgroundColor: 'transparent', 156 | }, 157 | }); 158 | 159 | export default React.memo(Badge); 160 | -------------------------------------------------------------------------------- /src/Initials.tsx: -------------------------------------------------------------------------------- 1 | import React, { useMemo } from 'react'; 2 | import { PixelRatio, StyleSheet, StyleProp, Text, TextStyle, View, ViewProps } from 'react-native'; 3 | 4 | import { getInitials, getStringColor } from './helpers'; 5 | 6 | interface Props extends ViewProps { 7 | size: number; 8 | name: string; 9 | color: string; 10 | colorize: boolean; 11 | borderRadius: number; 12 | textStyle?: StyleProp; 13 | } 14 | 15 | const Initials = ({ size, name, color, colorize, borderRadius, style, textStyle }: Props) => { 16 | const fontSize = PixelRatio.roundToNearestPixel(size / 2.5); 17 | const [initials, backgroundColor] = useMemo( 18 | () => [getInitials(name), colorize ? getStringColor(name) : color], 19 | [name, color, colorize], 20 | ); 21 | 22 | return ( 23 | 24 | 25 | {initials} 26 | 27 | 28 | ); 29 | }; 30 | 31 | const styles = StyleSheet.create({ 32 | root: { 33 | width: '100%', 34 | height: '100%', 35 | alignItems: 'center', 36 | justifyContent: 'center', 37 | }, 38 | text: { 39 | color: '#fff', 40 | fontWeight: '700', 41 | fontFamily: 'System', 42 | includeFontPadding: false, 43 | textAlignVertical: 'center', 44 | backgroundColor: 'transparent', 45 | }, 46 | }); 47 | 48 | export default Initials; 49 | -------------------------------------------------------------------------------- /src/__tests__/Avatar.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { Image, PixelRatio, StyleSheet, Text, View } from 'react-native'; 3 | 4 | // Note: test renderer must be required after react-native. 5 | import TestRenderer, { act } from 'react-test-renderer'; 6 | 7 | /** 8 | * Under test 9 | */ 10 | import { Avatar, AvatarProps } from '../'; 11 | import { getGravatarSource, getInitials, getStringColor } from '../helpers'; 12 | 13 | const createElement = (props: Partial) => ; 14 | 15 | const createRenderer = (props: Partial) => TestRenderer.create(createElement(props)); 16 | 17 | it('should match snapshot', () => { 18 | expect(createRenderer({ badge: 35 })).toMatchSnapshot(); 19 | }); 20 | 21 | it('should render network image', () => { 22 | const source = { uri: 'image.png' }; 23 | const { root } = createRenderer({ source }); 24 | 25 | expect(root.findByType(Image).props.source).toStrictEqual(source); 26 | }); 27 | 28 | it('should render local image', () => { 29 | const source = require('../assets/custom.png'); 30 | const { root } = createRenderer({ source }); 31 | 32 | expect(root.findByType(Image).props.source).toStrictEqual(source); 33 | }); 34 | 35 | it('should update image source', () => { 36 | const source1 = { uri: 'image.png' }; 37 | const source2 = { uri: 'new-image.png' }; 38 | const tree = createRenderer({ source: source1 }); 39 | 40 | expect(tree.root.findByType(Image).props.source).toStrictEqual(source1); 41 | 42 | act(() => { 43 | tree.update(createElement({ source: source2 })); 44 | }); 45 | 46 | expect(tree.root.findByType(Image).props.source).toStrictEqual(source2); 47 | }); 48 | 49 | it('should render gravatar', () => { 50 | const size = 35; 51 | const email = 'user@email.com'; 52 | const source = getGravatarSource(size, email); 53 | const { root } = createRenderer({ size, email }); 54 | 55 | expect(root.findByType(Image).props.source).toStrictEqual(source); 56 | }); 57 | 58 | it('should render 2-letters initials', () => { 59 | const size = 35; 60 | const name = 'User Name'; 61 | const textStyle = { color: 'red' }; 62 | const { root } = createRenderer({ size, name, textStyle, colorize: true }); 63 | 64 | const text = root.findByType(Text); 65 | 66 | expect(text.props.children).toBe(getInitials(name)); 67 | expect(StyleSheet.flatten(text.props.style)).toEqual( 68 | expect.objectContaining({ 69 | ...textStyle, 70 | fontSize: PixelRatio.roundToNearestPixel(size / 2.5), 71 | }), 72 | ); 73 | expect(StyleSheet.flatten(text.parent?.props.style)).toEqual( 74 | expect.objectContaining({ 75 | backgroundColor: getStringColor(name), 76 | }), 77 | ); 78 | }); 79 | 80 | it('should render 1-letter initials', () => { 81 | const name = 'Username'; 82 | const color = 'blue'; 83 | const { root } = createRenderer({ name, color, colorize: false }); 84 | 85 | const text = root.findByType(Text); 86 | 87 | expect(text.props.children).toBe(getInitials(name)); 88 | expect(StyleSheet.flatten(text.parent?.props.style)).toEqual( 89 | expect.objectContaining({ 90 | backgroundColor: color, 91 | }), 92 | ); 93 | }); 94 | 95 | it('should render initials if source fails', () => { 96 | const name = 'User Name'; 97 | const source = { uri: 'image.png' }; 98 | const { root } = createRenderer({ name, source }); 99 | 100 | const image = root.findByType(Image); 101 | 102 | act(() => image.props.onError()); 103 | 104 | expect(root.findByType(Text).props.children).toBe(getInitials(name)); 105 | }); 106 | 107 | it('should render initials if gravatar fails', () => { 108 | const name = 'User Name'; 109 | const email = 'user@email.com'; 110 | const { root } = createRenderer({ name, email }); 111 | 112 | const image = root.findByType(Image); 113 | 114 | act(() => image.props.onError()); 115 | 116 | expect(root.findByType(Text).props.children).toBe(getInitials(name)); 117 | }); 118 | 119 | it('should render default image if source fails', () => { 120 | const source = { uri: 'image.png' }; 121 | const defaultSource = { uri: 'default.png' }; 122 | const { root } = createRenderer({ source, defaultSource }); 123 | 124 | const image = root.findByType(Image); 125 | 126 | act(() => image.props.onError()); 127 | 128 | expect(image.props.source).toStrictEqual(defaultSource); 129 | }); 130 | 131 | it('should render default image if gravatar fails', () => { 132 | const email = 'user@email.com'; 133 | const defaultSource = { uri: 'default.png' }; 134 | const { root } = createRenderer({ email, defaultSource }); 135 | 136 | const image = root.findByType(Image); 137 | 138 | act(() => image.props.onError()); 139 | 140 | expect(image.props.source).toStrictEqual(defaultSource); 141 | }); 142 | 143 | it('should render default image if name is empty', () => { 144 | const name = ''; 145 | const defaultSource = { uri: 'default.png' }; 146 | const { root } = createRenderer({ name, defaultSource }); 147 | 148 | const image = root.findByType(Image); 149 | 150 | expect(image.props.source).toStrictEqual(defaultSource); 151 | }); 152 | 153 | it('should render badge', () => { 154 | const badge = 35; 155 | const { root } = createRenderer({ badge }); 156 | 157 | expect(root.findByType(Text).props.children).toBe(badge); 158 | }); 159 | 160 | it('should render customized appearance', () => { 161 | const props = { 162 | size: 35, 163 | color: 'blue', 164 | radius: 15, 165 | style: { borderWidth: 3, borderColor: 'purple' }, 166 | }; 167 | const { root } = createRenderer(props); 168 | const wrapper = root.findByType(View); 169 | const image = root.findByType(Image); 170 | 171 | expect(StyleSheet.flatten(wrapper.props.style)).toEqual( 172 | expect.objectContaining({ 173 | width: props.size, 174 | height: props.size, 175 | }), 176 | ); 177 | 178 | expect(StyleSheet.flatten(image.props.style)).toEqual( 179 | expect.objectContaining({ 180 | ...props.style, 181 | backgroundColor: props.color, 182 | borderRadius: props.radius, 183 | }), 184 | ); 185 | }); 186 | -------------------------------------------------------------------------------- /src/__tests__/Badge.tsx: -------------------------------------------------------------------------------- 1 | import React from 'react'; 2 | import { Animated as RNAnimated, PixelRatio, StyleSheet, Text, View } from 'react-native'; 3 | 4 | // Note: test renderer must be required after react-native. 5 | import TestRenderer, { act } from 'react-test-renderer'; 6 | 7 | const Animated = jest.mocked(RNAnimated); 8 | 9 | /** 10 | * Under test 11 | */ 12 | import Badge, { Props as BadgeProps, BadgePositions } from '../Badge'; 13 | 14 | const createElement = (props: Partial) => ; 15 | 16 | const createRenderer = (props: Partial) => TestRenderer.create(createElement(props)); 17 | 18 | it('should match snapshot', () => { 19 | expect(createRenderer({ value: 12 })).toMatchSnapshot(); 20 | }); 21 | 22 | it('should render with a boolean value', () => { 23 | const { root } = createRenderer({ value: true }); 24 | expect(root.findAllByType(Text).length).toBe(0); 25 | }); 26 | 27 | it('should render when a value greather than limit', () => { 28 | const limit = 99; 29 | const { root } = createRenderer({ value: 100, limit }); 30 | expect(root.findByType(Text).props.children).toBe(`${limit}+`); 31 | }); 32 | 33 | it('should render customized appearance', () => { 34 | const props = { 35 | value: 12, 36 | size: 24, 37 | color: 'blue', 38 | radius: 3, 39 | style: { minHeight: 5 }, 40 | textStyle: { color: 'red' }, 41 | }; 42 | const { root } = createRenderer(props); 43 | const wrapper = root.findByType(View); 44 | const text = root.findByType(Text); 45 | 46 | const fontSize = PixelRatio.roundToNearestPixel(props.size * 0.6); 47 | 48 | expect(wrapper.props.style).toEqual( 49 | expect.objectContaining({ 50 | height: props.size, 51 | minWidth: props.size, 52 | minHeight: props.style.minHeight, 53 | backgroundColor: props.color, 54 | borderRadius: props.radius, 55 | }), 56 | ); 57 | 58 | expect(StyleSheet.flatten(text.props.style)).toEqual( 59 | expect.objectContaining({ 60 | fontSize, 61 | color: props.textStyle.color, 62 | marginHorizontal: fontSize / 2, 63 | }), 64 | ); 65 | }); 66 | 67 | Object.values(BadgePositions).map((position) => { 68 | it(`should render when position = ${position}`, () => { 69 | const props = { size: 25, value: 12, position, parentSize: 50, parentRadius: 20 }; 70 | const { root } = createRenderer(props); 71 | const wrapper = root.findByType(View); 72 | 73 | const edgeOffset = props.parentRadius * (1 - Math.sin((45 * Math.PI) / 180)); 74 | const selfOffset = props.size * (0.25 + props.parentRadius / (props.parentSize * 2)); 75 | const offset = PixelRatio.roundToNearestPixel(edgeOffset - selfOffset); 76 | const [badgeY, badgeX] = position.split('-'); 77 | 78 | expect(wrapper.props.style).toEqual( 79 | expect.objectContaining({ 80 | [badgeY]: offset, 81 | [badgeX]: offset, 82 | height: props.size, 83 | position: 'absolute', 84 | }), 85 | ); 86 | }); 87 | }); 88 | 89 | [0, '', false, undefined].map((value) => { 90 | it(`should not render when value = ${value}`, () => { 91 | const { root } = createRenderer({ value }); 92 | expect(root.children.length).toBe(0); 93 | }); 94 | }); 95 | 96 | describe('animation', () => { 97 | const start = jest.fn(); 98 | const config = { 99 | toValue: 1, 100 | friction: 6, 101 | tension: 50, 102 | useNativeDriver: true, 103 | }; 104 | 105 | jest.spyOn(Animated, 'spring').mockImplementation(() => ({ start })); 106 | 107 | beforeEach(() => { 108 | start.mockClear(); 109 | }); 110 | 111 | it('should not animate when turned off by the prop', () => { 112 | const tree = createRenderer({ value: 0, animate: false }); 113 | 114 | Animated.spring.mockClear(); 115 | 116 | act(() => { 117 | tree.update(createElement({ value: 1, animate: false })); 118 | }); 119 | 120 | expect(Animated.spring).not.toBeCalled(); 121 | }); 122 | 123 | it('should not animate when numeric value changes', () => { 124 | const tree = createRenderer({ value: 1 }); 125 | 126 | Animated.spring.mockClear(); 127 | 128 | act(() => { 129 | tree.update(createElement({ value: 2 })); 130 | }); 131 | 132 | expect(Animated.spring).toBeCalledWith(expect.objectContaining({ _value: 1 }), config); 133 | expect(Animated.spring).toBeCalledTimes(1); 134 | expect(start).toBeCalled(); 135 | }); 136 | 137 | it('should animate when zero value changes to number', () => { 138 | const tree = createRenderer({ value: 0 }); 139 | 140 | Animated.spring.mockClear(); 141 | 142 | act(() => { 143 | tree.update(createElement({ value: 1 })); 144 | }); 145 | 146 | expect(Animated.spring).toBeCalledWith(expect.objectContaining({ _value: 0 }), config); 147 | expect(Animated.spring).toBeCalledTimes(1); 148 | expect(start).toBeCalled(); 149 | }); 150 | 151 | it('should animate when empty value changes to string', () => { 152 | const tree = createRenderer({ value: '' }); 153 | 154 | Animated.spring.mockClear(); 155 | 156 | act(() => { 157 | tree.update(createElement({ value: '!' })); 158 | }); 159 | 160 | expect(Animated.spring).toBeCalledWith(expect.objectContaining({ _value: 0 }), config); 161 | expect(Animated.spring).toBeCalledTimes(1); 162 | expect(start).toBeCalled(); 163 | }); 164 | }); 165 | -------------------------------------------------------------------------------- /src/__tests__/__snapshots__/Avatar.tsx.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`should match snapshot 1`] = ` 4 | 17 | 38 | 69 | 88 | 35 89 | 90 | 91 | 92 | `; 93 | -------------------------------------------------------------------------------- /src/__tests__/__snapshots__/Badge.tsx.snap: -------------------------------------------------------------------------------- 1 | // Jest Snapshot v1, https://goo.gl/fbAQLP 2 | 3 | exports[`should match snapshot 1`] = ` 4 | 23 | 42 | 12 43 | 44 | 45 | `; 46 | -------------------------------------------------------------------------------- /src/assets/custom.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/custom.png -------------------------------------------------------------------------------- /src/assets/custom@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/custom@2x.png -------------------------------------------------------------------------------- /src/assets/custom@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/custom@3x.png -------------------------------------------------------------------------------- /src/assets/default.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/default.png -------------------------------------------------------------------------------- /src/assets/default@2x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/default@2x.png -------------------------------------------------------------------------------- /src/assets/default@3x.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/kolking/react-native-avatar/852bf83848c7cf67818ed7577d8fdbf0e2254820/src/assets/default@3x.png -------------------------------------------------------------------------------- /src/helpers.ts: -------------------------------------------------------------------------------- 1 | import { md5 } from 'js-md5'; 2 | import { Appearance, ImageSourcePropType, PixelRatio } from 'react-native'; 3 | 4 | /* istanbul ignore next */ 5 | export function debug(...args: any) { 6 | if (process.env.NODE_ENV === 'development') { 7 | console.log(...args); 8 | } 9 | } 10 | 11 | export function clamp(value: number, min: number, max: number): number { 12 | return Math.max(min, Math.min(value, max)); 13 | } 14 | 15 | export function colorScheme(lightColor: string, darkColor: string) { 16 | return Appearance.getColorScheme() === 'dark' ? darkColor : lightColor; 17 | } 18 | 19 | export function getGravatarSource(size: number, email: string): ImageSourcePropType { 20 | const emailHash = md5(email.toLowerCase().trim()); 21 | const pixelSize = PixelRatio.getPixelSizeForLayoutSize(size); 22 | 23 | return { 24 | uri: `https://www.gravatar.com/avatar/${emailHash}?s=${pixelSize}&d=404`, 25 | }; 26 | } 27 | 28 | export function getStringColor(string: string): string { 29 | let hash = 0; 30 | 31 | if (string.length > 0) { 32 | for (let i = 0; i < string.length; i += 1) { 33 | /* eslint-disable no-bitwise */ 34 | hash = string.charCodeAt(i) + ((hash << 5) - hash); 35 | hash &= hash; 36 | /* eslint-enable no-bitwise */ 37 | } 38 | } 39 | 40 | return `hsl(${hash % 360}, 75%, 50%)`; 41 | } 42 | 43 | export function getInitials(name: string): string { 44 | const initials = name.trim().split(/\s+/gu) || []; 45 | let output = [...(initials.shift() || '')][0]; 46 | 47 | if (initials.length > 0) { 48 | output += [...(initials.pop() || '')][0]; 49 | } 50 | 51 | return output.toUpperCase(); 52 | } 53 | 54 | export function getBadgeValue(value: number | string | boolean, limit: number) { 55 | return typeof value === 'number' && limit > 0 && value > limit ? `${limit}+` : value; 56 | } 57 | -------------------------------------------------------------------------------- /src/index.tsx: -------------------------------------------------------------------------------- 1 | export { default as Badge } from './Badge'; 2 | export { default as Avatar } from './Avatar'; 3 | export type { Props as BadgeProps } from './Badge'; 4 | export type { Props as AvatarProps } from './Avatar'; 5 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@react-native/typescript-config/tsconfig.json", 3 | "compilerOptions": { 4 | "baseUrl": "./", 5 | "paths": { 6 | "@kolking/react-native-avatar": ["./src/index"] 7 | } 8 | } 9 | } 10 | --------------------------------------------------------------------------------