@hps1978/react-native-web-tv 0.21.2-tv.0 → 0.21.2-tv.2
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 +19 -53
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
# React Native for
|
|
1
|
+
# React Native Web for TV
|
|
2
2
|
|
|
3
3
|
[![npm version][package-badge]][package-url] [![Build Status][ci-badge]][ci-url] [](https://reactjs.org/docs/how-to-contribute.html#your-first-pull-request)
|
|
4
4
|
|
|
5
|
-
"React Native for
|
|
5
|
+
"React Native Web for TV" makes it possible to run [React Native][react-native-url] components and APIs on the web based TVs using React Native Web.
|
|
6
|
+
|
|
7
|
+
It is derived from [React Native Web](https://github.com/necolas/react-native-web), and this fork remains intentionally close to that project while extending it for browser-based TV platforms. Thanks to the RNW project for the foundation this fork builds on 🙏.
|
|
6
8
|
|
|
7
9
|
## Documentation
|
|
8
10
|
|
|
9
|
-
The documentation site is hosted at
|
|
11
|
+
The documentation site is hosted at [https://hps1978.github.io/react-native-web-tv/](https://hps1978.github.io/react-native-web-tv/). Documentation source lives in `packages/react-native-web-docs` and can also be built locally from the monorepo.
|
|
10
12
|
|
|
11
13
|
## Versioning
|
|
12
14
|
|
|
@@ -18,35 +20,20 @@ This fork keeps the upstream React Native Web version as the base and appends a
|
|
|
18
20
|
|
|
19
21
|
For example, `0.21.2-tv.0` is the initial TV fork release built on upstream `0.21.2`.
|
|
20
22
|
|
|
21
|
-
##
|
|
23
|
+
## Examples in this fork
|
|
22
24
|
|
|
23
25
|
The examples app source lives in `packages/react-native-web-examples` and can be run locally from the monorepo.
|
|
24
26
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
<View style={styles.box}>
|
|
36
|
-
<Text style={styles.text}>Hello, world!</Text>
|
|
37
|
-
</View>
|
|
38
|
-
);
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
const styles = StyleSheet.create({
|
|
43
|
-
box: { padding: 10 },
|
|
44
|
-
text: { fontWeight: 'bold' }
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
AppRegistry.registerComponent('App', () => App);
|
|
48
|
-
AppRegistry.runApplication('App', { rootTag: document.getElementById('react-root') });
|
|
49
|
-
```
|
|
27
|
+
This fork keeps the broader React Native Web example surface and adds TV-specific examples on top of it.
|
|
28
|
+
|
|
29
|
+
Some inherited examples are still general RNW demos and are not yet adapted for LRUD or remote-focus behavior. The TV-focused routes, along with the examples already updated for focus handling, can be exercised directly in a browser for testing and debugging.
|
|
30
|
+
|
|
31
|
+
Useful TV-oriented routes include:
|
|
32
|
+
|
|
33
|
+
* `/tv-event-handler`
|
|
34
|
+
* `/tv-focus-guide-view`
|
|
35
|
+
* `/tv-text-scrollview`
|
|
36
|
+
* `/flatlist-tv-scroll`
|
|
50
37
|
|
|
51
38
|
## Web TV support in this fork
|
|
52
39
|
|
|
@@ -110,30 +97,9 @@ It works with SpatialManager key handling and supports page-style behavior throu
|
|
|
110
97
|
* `snapToStart`: when enabled, allows snapping to the start edge.
|
|
111
98
|
* `snapToEnd`: when enabled, allows snapping to the end edge.
|
|
112
99
|
|
|
113
|
-
Import:
|
|
114
|
-
|
|
115
|
-
```js
|
|
116
|
-
import { TVTextScrollView } from 'react-native';
|
|
117
|
-
```
|
|
118
|
-
|
|
119
|
-
## TV examples in this repo
|
|
120
|
-
|
|
121
|
-
Run examples from monorepo root:
|
|
122
|
-
|
|
123
|
-
```bash
|
|
124
|
-
npm run dev -w packages/react-native-web-examples
|
|
125
|
-
```
|
|
126
|
-
|
|
127
|
-
Try routes including:
|
|
128
|
-
|
|
129
|
-
* `/tv-event-handler`
|
|
130
|
-
* `/tv-focus-guide-view`
|
|
131
|
-
* `/tv-text-scrollview`
|
|
132
|
-
* `/flatlist-tv-scroll`
|
|
133
|
-
* `/rlv-flatlist-tv-scroll`
|
|
134
100
|
## Contributing
|
|
135
101
|
|
|
136
|
-
Development happens in the open on GitHub and we are grateful for contributions including bugfixes, improvements, and ideas. Read below to learn how you can take part in improving React Native for
|
|
102
|
+
Development happens in the open on GitHub and we are grateful for contributions including bugfixes, improvements, and ideas. Read below to learn how you can take part in improving React Native Web for TV.
|
|
137
103
|
|
|
138
104
|
### Code of conduct
|
|
139
105
|
|
|
@@ -141,7 +107,7 @@ This project expects all participants to adhere to Meta's OSS [Code of Conduct][
|
|
|
141
107
|
|
|
142
108
|
### Contributing guide
|
|
143
109
|
|
|
144
|
-
Read the [contributing guide][contributing-url] to learn about the development process, how to propose bugfixes and improvements, and how to build and test your changes to React Native for
|
|
110
|
+
Read the [contributing guide][contributing-url] to learn about the development process, how to propose bugfixes and improvements, and how to build and test your changes to React Native Web for TV.
|
|
145
111
|
|
|
146
112
|
### Good first issues
|
|
147
113
|
|
|
@@ -149,7 +115,7 @@ To help you get you familiar with the contribution process, there is a list of [
|
|
|
149
115
|
|
|
150
116
|
## License
|
|
151
117
|
|
|
152
|
-
React Native for
|
|
118
|
+
React Native Web for TV is [MIT licensed](./LICENSE). By contributing to React Native Web for TV, you agree that your contributions will be licensed under its MIT license.
|
|
153
119
|
|
|
154
120
|
This fork also depends on Apache-2.0 licensed TV navigation code via `@bbc/tv-lrud-spatial`.
|
|
155
121
|
See [THIRD_PARTY_NOTICES.md](./THIRD_PARTY_NOTICES.md) and [APACHE-2.0.txt](./APACHE-2.0.txt) for redistribution details.
|
package/package.json
CHANGED
|
@@ -4,8 +4,8 @@
|
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
6
|
"name": "@hps1978/react-native-web-tv",
|
|
7
|
-
"version": "0.21.2-tv.
|
|
8
|
-
"description": "React Native
|
|
7
|
+
"version": "0.21.2-tv.2",
|
|
8
|
+
"description": "React Native Web for TV",
|
|
9
9
|
"module": "dist/index.js",
|
|
10
10
|
"main": "dist/cjs/index.js",
|
|
11
11
|
"sideEffects": false,
|