Skip to content

Commit

Permalink
更新依赖
Browse files Browse the repository at this point in the history
  • Loading branch information
qiuxiang committed Feb 13, 2023
1 parent a031e86 commit 92b0cb8
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 50 deletions.
2 changes: 1 addition & 1 deletion example/home.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { useNavigation, useTheme } from "@react-navigation/native";
import * as React from "react";
import {
Constructor,
Platform,
ScrollView,
StyleSheet,
Expand All @@ -11,6 +10,7 @@ import {
View,
} from "react-native";
import { AMapSdk } from "react-native-amap3d";
import { Constructor } from "react-native/private/Utilities";
import screens from "./screens";
import { NavigationProps, ScreenName } from "./types";

Expand Down
5 changes: 3 additions & 2 deletions example/screens/animated.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import * as React from "react";
import { Dimensions, StyleSheet, Text, TouchableOpacity, View } from "react-native";
import { Dimensions, PixelRatio, StyleSheet, Text, TouchableOpacity, View } from "react-native";
import { MapView } from "react-native-amap3d";

let mapView: MapView;
Expand All @@ -11,6 +11,7 @@ export default () => (
<View style={style.button}>
<TouchableOpacity
onPress={() => {
console.log(Dimensions.get("window").width);
mapView?.moveCamera(
{
tilt: 45,
Expand Down Expand Up @@ -49,7 +50,7 @@ export default () => (
const style = StyleSheet.create({
body: { flex: 1 },
buttons: {
width: Dimensions.get("window").width,
width: "100%",
position: "absolute",
flexDirection: "row",
justifyContent: "center",
Expand Down
20 changes: 5 additions & 15 deletions lib/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ def getExt(prop, fallback) {
}

buildscript {
ext.kotlin_version = '1.5.31'
ext.kotlin_version = '1.7.21'

repositories {
mavenCentral()
Expand All @@ -18,27 +18,17 @@ buildscript {
}

android {
compileSdkVersion getExt('compileSdkVersion', 30)
buildToolsVersion getExt('buildToolsVersion', '30.0.2')
compileSdkVersion getExt('compileSdkVersion', 33)
buildToolsVersion getExt('buildToolsVersion', '33.0.0')

defaultConfig {
minSdkVersion getExt('minSdkVersion', 21)
targetSdkVersion getExt('targetSdkVersion', 30)
}

compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}

kotlinOptions {
jvmTarget = '1.8'
targetSdkVersion getExt('targetSdkVersion', 33)
}
}

dependencies {
api 'com.facebook.react:react-native:+'
compileOnly 'com.facebook.react:react-native:+'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'com.amap.api:3dmap:9.6.0'
implementation 'com.amap.api:location:6.1.0'
}
20 changes: 0 additions & 20 deletions lib/ios/react-native-amap3d.podspec

This file was deleted.

2 changes: 1 addition & 1 deletion license
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2022 7c00 <[email protected]>
Copyright (c) 2023 7c00 <[email protected]>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,15 @@
"supercluster": "^7.1.4"
},
"devDependencies": {
"@react-native-picker/picker": "^2.1.0",
"@react-navigation/native": "^6.0.6",
"@react-navigation/native-stack": "^6.0.11",
"@types/react-native": "^0.65.8",
"@types/supercluster": "^5.0.3",
"react": "17.0.2",
"react-native": "^0.66.3",
"react-native-safe-area-context": "^3.3.2",
"react-native-screens": "^3.8.0"
"@react-native-picker/picker": "^2.4.8",
"@react-navigation/native": "^6.1.3",
"@react-navigation/native-stack": "^6.9.9",
"@types/react-native": "^0.71.2",
"@types/supercluster": "^7.1.0",
"react": "18.2.0",
"react-native": "^0.71.2",
"react-native-safe-area-context": "^4.5.0",
"react-native-screens": "^3.19.0"
},
"prettier": {
"printWidth": 100
Expand Down
2 changes: 1 addition & 1 deletion react-native-amap3d.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@ Pod::Spec.new do |s|
s.source_files = "lib/ios/**/*.{h,m,mm,swift}"

s.dependency "React-Core"
s.dependency 'AMap3DMap', "~> 9.2.1"
s.dependency 'AMap3DMap', "~> 9.5.0"
end
1 change: 0 additions & 1 deletion react-native.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ module.exports = {
"react-native-amap3d": {
root: __dirname,
platforms: {
ios: { podspecPath: __dirname + "/lib/ios/react-native-amap3d.podspec" },
android: {
sourceDir: __dirname + "/lib/android",
packageImportPath: "import qiuxiang.amap3d.AMap3DPackage;",
Expand Down

0 comments on commit 92b0cb8

Please sign in to comment.