Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: expo-example add ExpoImageManipulator #216

Merged
merged 2 commits into from
Feb 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions README.MD
Original file line number Diff line number Diff line change
Expand Up @@ -112,16 +112,18 @@ npx expo install react-native-image-marker
# compile
npx expo prebuild

eas build

```

## Compatibility

| React Native Version | react-native-image-marker Version |
| ---------------------| --------------------------------- |
| < 0.60.0 | v0.5.2 or earlier |
| >= 0.60.0, ***iOS < 13, Android < N(API Level 24)*** | v1.0.x |
| 0.60.0 <= rn version < 0.73.0 | v1.1.x |
| >= 0.73.0, other cases | v1.2.0 or later |
| 0.60.0 <= rn version < 0.73.0 | v1.1.x |
| >= 0.60.0, ***iOS < 13, Android < N(API Level 24)*** | v1.0.x |
| < 0.60.0 | v0.5.2 or earlier |

> ***Note: This table is only applicable to major versions of react-native-image-marker. Patch versions should be backwards compatible.***

Expand Down
4 changes: 2 additions & 2 deletions example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -946,7 +946,7 @@ PODS:
- React-debug
- react-native-blob-util (0.19.6):
- React-Core
- react-native-image-marker (1.2.4-beta.4):
- react-native-image-marker (1.2.5):
- React-Core
- react-native-image-picker (5.7.0):
- React-Core
Expand Down Expand Up @@ -1360,7 +1360,7 @@ SPEC CHECKSUMS:
React-logger: e0c1e918d9588a9f39c9bc62d9d6bfe9ca238d9d
React-Mapbuffer: 9731a0a63ebaf8976014623c4d637744d7353a7c
react-native-blob-util: d8fa1a7f726867907a8e43163fdd8b441d4489ea
react-native-image-marker: 9aa793ce8195941aaed5482a23d926b51f6b5b9f
react-native-image-marker: a522385247e45a2e5cc8dfc8daeda5c833828b17
react-native-image-picker: 3269f75c251cdcd61ab51b911dd30d6fff8c6169
React-nativeconfig: 37aecd26d64b79327c3f10e43b2e9a6c425e0a60
React-NativeModulesApple: 9ca6d2eaa1dd5606588262195b46d0774bdec83a
Expand Down
9 changes: 8 additions & 1 deletion expo-example/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import {
import Toast from 'react-native-toast-message';
import * as FileSystem from 'expo-file-system';
import filesize from 'filesize';
import * as ImageManipulator from 'expo-image-manipulator';

const icon = require('./assets/icon.jpeg');
const icon1 = require('./assets/yahaha.jpeg');
Expand Down Expand Up @@ -121,7 +122,7 @@ const s = StyleSheet.create({
padding: 10,
},
shortTextInput: {
width: 30,
width: 40,
height: 30,
backgroundColor: '#ffA',
borderColor: '#00B96B5A',
Expand Down Expand Up @@ -587,6 +588,12 @@ function useViewModel() {
setShow(true);
const stat = await FileSystem.getInfoAsync(path);
setFileSize(filesize.filesize(stat.exists ? stat.size : 0));
const imRes = await ImageManipulator.manipulateAsync(path, [
{
rotate: 90,
},
]);
console.log(imRes);
} catch (err) {
console.log('====================================');
console.log(err, 'err');
Expand Down
11 changes: 9 additions & 2 deletions expo-example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ PODS:
- ExpoModulesCore
- ExpoFileSystem (16.0.5):
- ExpoModulesCore
- ExpoImageManipulator (11.8.0):
- EXImageLoader
- ExpoModulesCore
- ExpoImagePicker (14.7.1):
- ExpoModulesCore
- ExpoKeepAwake (12.8.2):
Expand Down Expand Up @@ -908,7 +911,7 @@ PODS:
- React-Mapbuffer (0.73.2):
- glog
- React-debug
- react-native-image-marker (1.2.4-beta.4):
- react-native-image-marker (1.2.5):
- React-Core
- React-nativeconfig (0.73.2)
- React-NativeModulesApple (0.73.2):
Expand Down Expand Up @@ -1088,6 +1091,7 @@ DEPENDENCIES:
- EXImageLoader (from `../node_modules/expo-image-loader/ios`)
- Expo (from `../node_modules/expo`)
- ExpoFileSystem (from `../node_modules/expo-file-system/ios`)
- ExpoImageManipulator (from `../node_modules/expo-image-manipulator/ios`)
- ExpoImagePicker (from `../node_modules/expo-image-picker/ios`)
- ExpoKeepAwake (from `../node_modules/expo-keep-awake/ios`)
- ExpoModulesCore (from `../node_modules/expo-modules-core`)
Expand Down Expand Up @@ -1163,6 +1167,8 @@ EXTERNAL SOURCES:
:path: "../node_modules/expo"
ExpoFileSystem:
:path: "../node_modules/expo-file-system/ios"
ExpoImageManipulator:
:path: "../node_modules/expo-image-manipulator/ios"
ExpoImagePicker:
:path: "../node_modules/expo-image-picker/ios"
ExpoKeepAwake:
Expand Down Expand Up @@ -1273,6 +1279,7 @@ SPEC CHECKSUMS:
EXImageLoader: 55080616b2fe9da19ef8c7f706afd9814e279b6b
Expo: 88b4aa68115bbb57c1a07cc30161c2352ab2fc25
ExpoFileSystem: 04795dd4d47e76eaf12e38c92091f77d794f9e7f
ExpoImageManipulator: c1d7cb865eacd620a35659f3da34c70531f10b59
ExpoImagePicker: 66970181d1c838f444e5e1f81b804ab2d5ff49bd
ExpoKeepAwake: 0f5cad99603a3268e50af9a6eb8b76d0d9ac956c
ExpoModulesCore: 96d1751929ad10622773bb729ab28a8423f0dd0c
Expand Down Expand Up @@ -1303,7 +1310,7 @@ SPEC CHECKSUMS:
React-jsinspector: 03644c063fc3621c9a4e8bf263a8150909129618
React-logger: 66b168e2b2bee57bd8ce9e69f739d805732a5570
React-Mapbuffer: 9ee041e1d7be96da6d76a251f92e72b711c651d6
react-native-image-marker: 9aa793ce8195941aaed5482a23d926b51f6b5b9f
react-native-image-marker: a522385247e45a2e5cc8dfc8daeda5c833828b17
React-nativeconfig: d753fbbc8cecc8ae413d615599ac378bbf6999bb
React-NativeModulesApple: 964f4eeab1b4325e8b6a799cf4444c3fd4eb0a9c
React-perflogger: 29efe63b7ef5fbaaa50ef6eaa92482f98a24b97e
Expand Down
5 changes: 3 additions & 2 deletions expo-example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,14 @@
"expo": "~50.0.3",
"expo-file-system": "~16.0.5",
"expo-font": "~11.10.2",
"expo-image-manipulator": "~11.8.0",
"expo-image-picker": "~14.7.1",
"expo-status-bar": "~1.11.1",
"filesize": "^10.1.0",
"react": "18.2.0",
"react-native": "0.73.2",
"react-native-toast-message": "^2.2.0",
"react-native-image-marker": "*"
"react-native-image-marker": "*",
"react-native-toast-message": "^2.2.0"
},
"devDependencies": {
"@babel/core": "^7.20.0",
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@
"bootstrap": "yarn example && yarn install && yarn example pods && yarn expo-example && yarn expo-example expo-install",
"bootstrap-m1": "yarn example && yarn install && yarn example m1-pods",
"clean": "del-cli android/build example/android/build example/android/app/build example/ios/build",
"docs": "typedoc --excludePrivate --tsconfig tsconfig.doc.json"
"docs": "typedoc --excludePrivate --tsconfig tsconfig.doc.json",
"expo-install": "yarn expo-example expo-install"
},
"keywords": [
"react-native",
Expand Down
Loading