react-native-readium 1.0.0-alpha.4 → 1.0.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -6
- package/android/build.gradle +10 -6
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -16,6 +16,11 @@ A react-native wrapper for https://readium.org/
|
|
|
16
16
|
|
|
17
17
|
## Installation
|
|
18
18
|
|
|
19
|
+
#### Prerequisites
|
|
20
|
+
|
|
21
|
+
1. **iOS**: Requires an iOS target >= `13.0` (see the iOS section for more details).
|
|
22
|
+
2. **Android**: Requires `compileSdkVersion` >= `31` (see the Android section for more details).
|
|
23
|
+
|
|
19
24
|
#### Install Module
|
|
20
25
|
|
|
21
26
|
**NPM**
|
|
@@ -32,17 +37,14 @@ yarn add react-native-readium
|
|
|
32
37
|
|
|
33
38
|
#### iOS
|
|
34
39
|
|
|
35
|
-
###### Requirements
|
|
36
|
-
|
|
37
|
-
This project requires an iOS target >= `13.0`.
|
|
38
|
-
|
|
39
|
-
###### Pod Install
|
|
40
|
-
|
|
41
40
|
Due to the current state of the `Readium` swift libraries you need to manually
|
|
42
41
|
update your `Podfile` ([see more on that here](https://github.com/readium/swift-toolkit/issues/38)).
|
|
43
42
|
|
|
44
43
|
```rb
|
|
45
44
|
# ./ios/Podfile
|
|
45
|
+
...
|
|
46
|
+
platform :ios, '13.0'
|
|
47
|
+
|
|
46
48
|
...
|
|
47
49
|
|
|
48
50
|
target 'ExampleApp' do
|
|
@@ -61,6 +63,21 @@ Finally, install the pods:
|
|
|
61
63
|
|
|
62
64
|
`pod install`
|
|
63
65
|
|
|
66
|
+
#### Android
|
|
67
|
+
|
|
68
|
+
If you're not using `compileSdkVersion` >= 31 you'll need to update that:
|
|
69
|
+
|
|
70
|
+
```groovy
|
|
71
|
+
// android/build.gradle
|
|
72
|
+
...
|
|
73
|
+
buildscript {
|
|
74
|
+
...
|
|
75
|
+
ext {
|
|
76
|
+
...
|
|
77
|
+
compileSdkVersion = 31
|
|
78
|
+
...
|
|
79
|
+
```
|
|
80
|
+
|
|
64
81
|
## Usage
|
|
65
82
|
|
|
66
83
|
```tsx
|
package/android/build.gradle
CHANGED
|
@@ -136,16 +136,20 @@ def kotlin_version = getExtOrDefault('kotlinVersion')
|
|
|
136
136
|
|
|
137
137
|
dependencies {
|
|
138
138
|
// noinspection GradleDynamicVersion
|
|
139
|
-
api
|
|
139
|
+
api "com.facebook.react:react-native:+"
|
|
140
140
|
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
|
|
141
141
|
|
|
142
142
|
// readium deps
|
|
143
143
|
implementation "com.github.readium.kotlin-toolkit:readium-shared:$readium_version"
|
|
144
144
|
implementation "com.github.readium.kotlin-toolkit:readium-streamer:$readium_version"
|
|
145
|
-
implementation "com.github.readium.kotlin-toolkit:readium-navigator:$readium_version"
|
|
145
|
+
implementation ("com.github.readium.kotlin-toolkit:readium-navigator:$readium_version") {
|
|
146
|
+
// this package doesn't provide audio playback, so remove exoplayer
|
|
147
|
+
// transitive deps to avoid potential collisions with other projects.
|
|
148
|
+
exclude group: "com.google.android.exoplayer"
|
|
149
|
+
}
|
|
146
150
|
|
|
147
151
|
// other deps
|
|
148
|
-
implementation
|
|
152
|
+
implementation "androidx.core:core-ktx:1.6.0"
|
|
149
153
|
implementation "androidx.activity:activity-ktx:1.3.1"
|
|
150
154
|
implementation "androidx.appcompat:appcompat:1.3.1"
|
|
151
155
|
implementation "androidx.browser:browser:1.3.0"
|
|
@@ -178,15 +182,15 @@ dependencies {
|
|
|
178
182
|
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.5.2"
|
|
179
183
|
// AM NOTE: needs to stay this version for now (June 24,2020)
|
|
180
184
|
//noinspection GradleDependency
|
|
181
|
-
implementation
|
|
185
|
+
implementation "org.jsoup:jsoup:1.13.1"
|
|
182
186
|
|
|
183
187
|
// Room database
|
|
184
|
-
final room_version =
|
|
188
|
+
final room_version = "2.4.0-beta01"
|
|
185
189
|
implementation "androidx.room:room-runtime:$room_version"
|
|
186
190
|
implementation "androidx.room:room-ktx:$room_version"
|
|
187
191
|
annotationProcessor "androidx.room:room-compiler:$room_version"
|
|
188
192
|
|
|
189
|
-
implementation
|
|
193
|
+
implementation "androidx.lifecycle:lifecycle-extensions:2.2.0"
|
|
190
194
|
//noinspection LifecycleAnnotationProcessorWithJava8
|
|
191
195
|
annotationProcessor "androidx.lifecycle:lifecycle-compiler:2.3.1"
|
|
192
196
|
|