mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
aaff0d37e2 | ||
|
|
16a89816fc |
+2
-1
@@ -48,6 +48,7 @@ packages/react-native/flow/
|
||||
[options]
|
||||
enums=true
|
||||
experimental.pattern_matching=true
|
||||
experimental.pattern_matching.includes=<PROJECT_ROOT>/packages/react-native/src/private/components/virtualview/
|
||||
casting_syntax=both
|
||||
component_syntax=true
|
||||
|
||||
@@ -104,4 +105,4 @@ untyped-import
|
||||
untyped-type-import
|
||||
|
||||
[version]
|
||||
^0.274.2
|
||||
^0.274.0
|
||||
|
||||
@@ -129,7 +129,7 @@ runs:
|
||||
run: yarn build
|
||||
- name: Build types
|
||||
shell: bash
|
||||
run: yarn build-types --skip-snapshot
|
||||
run: yarn build-types
|
||||
# Continue with publish steps
|
||||
- name: Set npm credentials
|
||||
if: ${{ inputs.release-type == 'release' ||
|
||||
|
||||
@@ -1,23 +0,0 @@
|
||||
name: diff-js-api-breaking-changes
|
||||
description: Check for breaking changes in the public React Native JS API
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- name: Fetch snapshot from PR head
|
||||
shell: bash
|
||||
env:
|
||||
SCRATCH_DIR: ${{ runner.temp }}/diff-js-api-breaking-changes
|
||||
run: |
|
||||
mkdir $SCRATCH_DIR
|
||||
git fetch --depth=1 origin ${{ github.event.pull_request.head.sha }}
|
||||
git show ${{ github.event.pull_request.head.sha }}:packages/react-native/ReactNativeApi.d.ts > $SCRATCH_DIR/ReactNativeApi-after.d.ts \
|
||||
|| echo "" > $SCRATCH_DIR/ReactNativeApi.d.ts
|
||||
- name: Run breaking change detection
|
||||
shell: bash
|
||||
env:
|
||||
SCRATCH_DIR: ${{ runner.temp }}/diff-js-api-breaking-changes
|
||||
run: |
|
||||
node ./scripts/diff-api-snapshot \
|
||||
${{ github.workspace }}/packages/react-native/ReactNativeApi.d.ts \
|
||||
$SCRATCH_DIR/ReactNativeApi-after.d.ts \
|
||||
> $SCRATCH_DIR/output.json
|
||||
@@ -49,7 +49,7 @@ runs:
|
||||
run: yarn run lint-markdown
|
||||
- name: Build types
|
||||
shell: bash
|
||||
run: yarn build-types --skip-snapshot
|
||||
run: yarn build-types
|
||||
- name: Run typescript check of generated types
|
||||
shell: bash
|
||||
run: yarn test-generated-typescript
|
||||
|
||||
@@ -22,8 +22,6 @@ jobs:
|
||||
uses: ./.github/actions/setup-node
|
||||
- name: Run yarn install
|
||||
uses: ./.github/actions/yarn-install
|
||||
- name: Run diff-js-api-breaking-changes
|
||||
uses: ./.github/actions/diff-js-api-breaking-changes
|
||||
- name: Danger
|
||||
run: yarn danger ci --use-github-checks --failOnErrors
|
||||
working-directory: private/react-native-bots
|
||||
|
||||
@@ -21,7 +21,7 @@ jobs:
|
||||
- name: Build packages
|
||||
run: yarn build
|
||||
- name: Build types
|
||||
run: yarn build-types --skip-snapshot
|
||||
run: yarn build-types
|
||||
- name: Set NPM auth token
|
||||
run: echo "//registry.npmjs.org/:_authToken=$GHA_NPM_TOKEN" > ~/.npmrc
|
||||
- name: Find and publish all bumped packages
|
||||
|
||||
@@ -175,6 +175,3 @@ fix_*.patch
|
||||
|
||||
# [Experimental] Generated TS type definitions
|
||||
/packages/**/types_generated/
|
||||
|
||||
/packages/debugger-shell/build/
|
||||
/packages/*/dist/
|
||||
|
||||
@@ -1,11 +1,5 @@
|
||||
# Changelog (pre 0.80)
|
||||
|
||||
## v0.79.5
|
||||
|
||||
### Fixed
|
||||
|
||||
- **Flow:** Publish top-level Flow types for `react-native` ([fbbd20dd63](https://github.com/facebook/react-native/commit/fbbd20dd632acd72d2abe861dd4a0e6e98437cf2) by [@buschco](https://github.com/buschco))
|
||||
|
||||
## v0.79.4
|
||||
|
||||
### Fixed
|
||||
-892
@@ -1,21 +1,5 @@
|
||||
# Changelog
|
||||
|
||||
## v0.80.1
|
||||
|
||||
### Added
|
||||
|
||||
- **Flow:** Publish top-level Flow types for `react-native` ([fbbd20dd63](https://github.com/facebook/react-native/commit/fbbd20dd632acd72d2abe861dd4a0e6e98437cf2) by [@buschco](https://github.com/buschco))
|
||||
- **Flow:** Fix typo when publishing Flow types for `react-native` ([50667eceb1](https://github.com/facebook/react-native/commit/50667eceb1be4771375d6a3cc2f4e42d4d8aad3a) by [@aswinandro](https://github.com/aswinandro))
|
||||
|
||||
### Fixed
|
||||
|
||||
- **jest:** Fix missing RefreshControlMock source in Jest preset ([6044e01460](https://github.com/facebook/react-native/commit/6044e01460a065845d4178f0fdc54a601ce4c07e) by [@huntie](https://github.com/huntie))
|
||||
|
||||
#### Android specific
|
||||
|
||||
- **runtime:** Fix crash on ReactInstance due to null returned for getViewManagerNames ([f6b7bd93d8](https://github.com/facebook/react-native/commit/f6b7bd93d8d0d2095669144c8de438cf64d8e73f) by [@cortinico](https://github.com/cortinico))
|
||||
- **TurboModules:** Emitting event from turbo module crashes on 32bit android ([36ddf853c3](https://github.com/facebook/react-native/commit/36ddf853c381966645789bc814fc2f6bb4d74cd2) by [@vladimirivanoviliev](https://github.com/vladimirivanoviliev))
|
||||
|
||||
## v0.80.0
|
||||
|
||||
### Breaking
|
||||
@@ -333,879 +317,3 @@
|
||||
- **Text:** Correctly announce "link" on nested text if its the entire text element ([bffb414291](https://github.com/facebook/react-native/commit/bffb414291cfbd3d6e3e51448dd68b7bddddf658) by [@joevilches](https://github.com/joevilches))
|
||||
- **Text:** Selection range not respected when changing text or selection when selection is forced ([d32ea66e6a](https://github.com/facebook/react-native/commit/d32ea66e6a945dd84092532401b265b12d482668) by Olivier Bouillet)
|
||||
- **TextInput:** Fix TextInput `onContentSizeChange` event being dispatched only once on iOS on the new architecture ([5fd5188172](https://github.com/facebook/react-native/commit/5fd51881727b2d86f87abf04db032940ac0ec8c4) by [@j-piasecki](https://github.com/j-piasecki))
|
||||
|
||||
## v0.79.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0795)
|
||||
|
||||
## v0.79.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0794)
|
||||
|
||||
## v0.79.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0793)
|
||||
|
||||
## v0.79.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0792)
|
||||
|
||||
## v0.79.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0791)
|
||||
|
||||
## v0.79.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0790)
|
||||
|
||||
## v0.78.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0782)
|
||||
|
||||
## v0.78.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0781)
|
||||
|
||||
## v0.78.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0780)
|
||||
|
||||
## v0.77.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0772)
|
||||
|
||||
## v0.77.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0771)
|
||||
|
||||
## v0.77.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0770)
|
||||
|
||||
## v0.76.9
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0769)
|
||||
|
||||
## v0.76.8
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0768)
|
||||
|
||||
## v0.76.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0767)
|
||||
|
||||
## v0.76.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0766)
|
||||
|
||||
## v0.76.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0765)
|
||||
|
||||
## v0.76.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0764)
|
||||
|
||||
## v0.76.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0763)
|
||||
|
||||
## v0.76.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0762)
|
||||
|
||||
## v0.76.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0761)
|
||||
|
||||
## v0.76.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0760)
|
||||
|
||||
## v0.75.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0755)
|
||||
|
||||
## v0.75.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0754)
|
||||
|
||||
## v0.75.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0753)
|
||||
|
||||
## v0.75.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0752)
|
||||
|
||||
## v0.75.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0751)
|
||||
|
||||
## v0.75.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0750)
|
||||
|
||||
## v0.74.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0747)
|
||||
|
||||
## v0.74.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0746)
|
||||
|
||||
## v0.74.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0745)
|
||||
|
||||
## v0.74.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0744)
|
||||
|
||||
## v0.74.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0743)
|
||||
|
||||
## v0.74.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0742)
|
||||
|
||||
## v0.74.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0741)
|
||||
|
||||
## v0.74.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0740)
|
||||
|
||||
## v0.73.11
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07311)
|
||||
|
||||
## v0.73.10
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07310)
|
||||
|
||||
## v0.73.9
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0739)
|
||||
|
||||
## v0.73.8
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0738)
|
||||
|
||||
## v0.73.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0737)
|
||||
|
||||
## v0.73.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0736)
|
||||
|
||||
## v0.73.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0735)
|
||||
|
||||
## v0.73.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0734)
|
||||
|
||||
## v0.73.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0733)
|
||||
|
||||
## v0.73.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0732)
|
||||
|
||||
## v0.73.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0731)
|
||||
|
||||
## v0.73.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0730)
|
||||
|
||||
## v0.72.17
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07217)
|
||||
|
||||
## v0.72.16
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07216)
|
||||
|
||||
## v0.72.15
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07215)
|
||||
|
||||
## v0.72.14
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07214)
|
||||
|
||||
## v0.72.13
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07213)
|
||||
|
||||
## v0.72.12
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07212)
|
||||
|
||||
## v0.72.11
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07211)
|
||||
|
||||
## v0.72.10
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07210)
|
||||
|
||||
## v0.72.9
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0729)
|
||||
|
||||
## v0.72.8
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0728)
|
||||
|
||||
## v0.72.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0727)
|
||||
|
||||
## v0.72.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0726)
|
||||
|
||||
## v0.72.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0725)
|
||||
|
||||
## v0.72.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0724)
|
||||
|
||||
## v0.72.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0723)
|
||||
|
||||
## v0.72.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0722)
|
||||
|
||||
## v0.72.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0721)
|
||||
|
||||
## v0.72.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0720)
|
||||
|
||||
## v0.71.19
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07119)
|
||||
|
||||
## v0.71.18
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07118)
|
||||
|
||||
## v0.71.17
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07117)
|
||||
|
||||
## v0.71.16
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07116)
|
||||
|
||||
## v0.71.15
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07115)
|
||||
|
||||
## v0.71.14
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07114)
|
||||
|
||||
## v0.71.13
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07113)
|
||||
|
||||
## v0.71.12
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07112)
|
||||
|
||||
## v0.71.11
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07111)
|
||||
|
||||
## v0.71.10
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07110)
|
||||
|
||||
## v0.71.9
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0719)
|
||||
|
||||
## v0.71.8
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0718)
|
||||
|
||||
## v0.71.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0717)
|
||||
|
||||
## v0.71.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0716)
|
||||
|
||||
## v0.71.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0715)
|
||||
|
||||
## v0.71.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0714)
|
||||
|
||||
## v0.71.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0713)
|
||||
|
||||
## v0.71.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0712)
|
||||
|
||||
## v0.71.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0711)
|
||||
|
||||
## v0.71.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0710)
|
||||
|
||||
## v0.70.15
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07015)
|
||||
|
||||
## v0.70.14
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07014)
|
||||
|
||||
## v0.70.13
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07013)
|
||||
|
||||
## v0.70.12
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07012)
|
||||
|
||||
## v0.70.11
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07011)
|
||||
|
||||
## v0.70.10
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v07010)
|
||||
|
||||
## v0.70.9
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0709)
|
||||
|
||||
## v0.70.8
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0708)
|
||||
|
||||
## v0.70.7
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0707)
|
||||
|
||||
## v0.70.6
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0706)
|
||||
|
||||
## v0.70.5
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0705)
|
||||
|
||||
## v0.70.4
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0704)
|
||||
|
||||
## v0.70.3
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0703)
|
||||
|
||||
## v0.70.2
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0702)
|
||||
|
||||
## v0.70.1
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0701)
|
||||
|
||||
## v0.70.0
|
||||
|
||||
See [CHANGELOG-0.7x](./CHANGELOG-0.7x#v0700)
|
||||
|
||||
## v0.69.12
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v06912)
|
||||
|
||||
## v0.69.11
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v06911)
|
||||
|
||||
## v0.69.10
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v06910)
|
||||
|
||||
## v0.69.9
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0699)
|
||||
|
||||
## v0.69.8
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0698)
|
||||
|
||||
## v0.69.7
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0697)
|
||||
|
||||
## v0.69.6
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0696)
|
||||
|
||||
## v0.69.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0695)
|
||||
|
||||
## v0.69.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0694)
|
||||
|
||||
## v0.69.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0693)
|
||||
|
||||
## v0.69.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0692)
|
||||
|
||||
## v0.69.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0691)
|
||||
|
||||
## v0.69.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0690)
|
||||
|
||||
## v0.68.7
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0687)
|
||||
|
||||
## v0.68.6
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0686)
|
||||
|
||||
## v0.68.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0685)
|
||||
|
||||
## v0.68.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0684)
|
||||
|
||||
## v0.68.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0683)
|
||||
|
||||
## v0.68.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0682)
|
||||
|
||||
## v0.68.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0681)
|
||||
|
||||
## v0.68.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0680)
|
||||
|
||||
## v0.67.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0675)
|
||||
|
||||
## v0.67.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0674)
|
||||
|
||||
## v0.67.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0673)
|
||||
|
||||
## v0.67.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0672)
|
||||
|
||||
## v0.67.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0671)
|
||||
|
||||
## v0.67.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0670)
|
||||
|
||||
## v0.66.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0665)
|
||||
|
||||
## v0.66.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0664)
|
||||
|
||||
## v0.66.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0663)
|
||||
|
||||
## v0.66.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0662)
|
||||
|
||||
## v0.66.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0661)
|
||||
|
||||
## v0.66.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0660)
|
||||
|
||||
## v0.65.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0653)
|
||||
|
||||
## v0.65.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0652)
|
||||
|
||||
## v0.65.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0651)
|
||||
|
||||
## v0.65.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0650)
|
||||
|
||||
## v0.64.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0644)
|
||||
|
||||
## v0.64.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0643)
|
||||
|
||||
## v0.64.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0642)
|
||||
|
||||
## v0.64.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0641)
|
||||
|
||||
## v0.64.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0640)
|
||||
|
||||
## v0.63.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0635)
|
||||
|
||||
## v0.63.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0634)
|
||||
|
||||
## v0.63.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0633)
|
||||
|
||||
## v0.63.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0632)
|
||||
|
||||
## v0.63.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0631)
|
||||
|
||||
## v0.63.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0630)
|
||||
|
||||
## v0.62.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0623)
|
||||
|
||||
## v0.62.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0622)
|
||||
|
||||
## v0.62.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0621)
|
||||
|
||||
## v0.62.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0620)
|
||||
|
||||
## v0.61.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0615)
|
||||
|
||||
## v0.61.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0614)
|
||||
|
||||
## v0.61.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0613)
|
||||
|
||||
## v0.61.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0612)
|
||||
|
||||
## v0.61.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0611)
|
||||
|
||||
## v0.61.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0610)
|
||||
|
||||
## v0.60.6
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0606)
|
||||
|
||||
## v0.60.5
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0605)
|
||||
|
||||
## v0.60.4
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0604)
|
||||
|
||||
## v0.60.3
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0603)
|
||||
|
||||
## v0.60.2
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0602)
|
||||
|
||||
## v0.60.1
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0601)
|
||||
|
||||
## v0.60.0
|
||||
|
||||
See [CHANGELOG-0.6x](./CHANGELOG-0.6x#v0600)
|
||||
|
||||
## v0.59.10
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v05910)
|
||||
|
||||
## v0.59.9
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0599)
|
||||
|
||||
## v0.59.8
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0598)
|
||||
|
||||
## v0.59.5
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0595)
|
||||
|
||||
## v0.59.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0594)
|
||||
|
||||
## v0.59.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0593)
|
||||
|
||||
## v0.59.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0592)
|
||||
|
||||
## v0.59.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0591)
|
||||
|
||||
## v0.59.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0590)
|
||||
|
||||
## v0.58.6
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0586)
|
||||
|
||||
## v0.58.5
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0585)
|
||||
|
||||
## v0.58.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0584)
|
||||
|
||||
## v0.58.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0583)
|
||||
|
||||
## v0.58.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0582)
|
||||
|
||||
## v0.58.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0581)
|
||||
|
||||
## v0.58.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0580)
|
||||
|
||||
## v0.57.8
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0578)
|
||||
|
||||
## v0.57.7
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0577)
|
||||
|
||||
## v0.57.6
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0576)
|
||||
|
||||
## v0.57.5
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0575)
|
||||
|
||||
## v0.57.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0574)
|
||||
|
||||
## v0.57.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0573)
|
||||
|
||||
## v0.57.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0572)
|
||||
|
||||
## v0.57.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0571)
|
||||
|
||||
## v0.57.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0570)
|
||||
|
||||
## v0.56.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0561)
|
||||
|
||||
## v0.56.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0560)
|
||||
|
||||
## v0.55.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0554)
|
||||
|
||||
## v0.55.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0553)
|
||||
|
||||
## v0.55.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0552)
|
||||
|
||||
## v0.55.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0551)
|
||||
|
||||
## v0.55.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0550)
|
||||
|
||||
## v0.54.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0544)
|
||||
|
||||
## v0.54.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0543)
|
||||
|
||||
## v0.54.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0542)
|
||||
|
||||
## v0.54.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0541)
|
||||
|
||||
## v0.54.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0540)
|
||||
|
||||
## v0.53.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0533)
|
||||
|
||||
## v0.53.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0532)
|
||||
|
||||
## v0.53.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0531)
|
||||
|
||||
## v0.53.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0530)
|
||||
|
||||
## v0.52.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0523)
|
||||
|
||||
## v0.52.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0522)
|
||||
|
||||
## v0.52.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0521)
|
||||
|
||||
## v0.52.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0520)
|
||||
|
||||
## v0.51.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0511)
|
||||
|
||||
## v0.51.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0510)
|
||||
|
||||
## v0.50.4
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0504)
|
||||
|
||||
## v0.50.3
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0503)
|
||||
|
||||
## v0.50.2
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0502)
|
||||
|
||||
## v0.50.1
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0501)
|
||||
|
||||
## v0.50.0
|
||||
|
||||
See [CHANGELOG-0.5x](./CHANGELOG-0.5x#v0500)
|
||||
|
||||
-149
@@ -1,149 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
declare module '@electron/packager' {
|
||||
declare export type AsarOptions = $FlowFixMe;
|
||||
|
||||
declare export type ElectronDownloadRequestOptions = $FlowFixMe;
|
||||
|
||||
declare export type TargetDefinition = {
|
||||
arch: TargetArch,
|
||||
platform: TargetPlatform,
|
||||
};
|
||||
|
||||
declare export type FinalizePackageTargetsHookFunction = (
|
||||
targets: TargetDefinition[],
|
||||
callback: HookFunctionErrorCallback,
|
||||
) => void;
|
||||
|
||||
declare export type HookFunction = (
|
||||
buildPath: string,
|
||||
electronVersion: string,
|
||||
platform: TargetPlatform,
|
||||
arch: TargetArch,
|
||||
callback: HookFunctionErrorCallback,
|
||||
) => void;
|
||||
|
||||
declare export type IgnoreFunction = (path: string) => boolean;
|
||||
|
||||
declare export type HookFunctionErrorCallback = (err?: Error | null) => void;
|
||||
|
||||
declare export interface MacOSProtocol {
|
||||
name: string;
|
||||
schemes: string[];
|
||||
}
|
||||
|
||||
declare export type NotaryToolCredentials = $FlowFixMe;
|
||||
|
||||
declare export type OsxSignOptions = $FlowFixMe;
|
||||
|
||||
declare export type OsxUniversalOptions = $FlowFixMe;
|
||||
|
||||
declare export type Win32MetadataOptions = $ReadOnly<{
|
||||
CompanyName?: string,
|
||||
FileDescription?: string,
|
||||
OriginalFilename?: string,
|
||||
ProductName?: string,
|
||||
InternalName?: string,
|
||||
'requested-execution-level'?:
|
||||
| 'asInvoker'
|
||||
| 'highestAvailable'
|
||||
| 'requireAdministrator',
|
||||
'application-manifest'?: string,
|
||||
}>;
|
||||
|
||||
declare export type WindowsSignOptions = $FlowFixMe;
|
||||
|
||||
declare export type OfficialArch =
|
||||
| 'ia32'
|
||||
| 'x64'
|
||||
| 'armv7l'
|
||||
| 'arm64'
|
||||
| 'mips64el'
|
||||
| 'universal';
|
||||
|
||||
declare export type OfficialPlatform = 'linux' | 'win32' | 'darwin' | 'mas';
|
||||
|
||||
declare export type TargetArch = OfficialArch | string;
|
||||
|
||||
declare export type TargetPlatform = OfficialPlatform | string;
|
||||
|
||||
declare export type ArchOption = TargetArch | 'all';
|
||||
|
||||
declare export type PlatformOption = TargetPlatform | 'all';
|
||||
|
||||
declare export interface Options {
|
||||
dir: string;
|
||||
afterAsar?: HookFunction[];
|
||||
afterComplete?: HookFunction[];
|
||||
afterCopy?: HookFunction[];
|
||||
afterCopyExtraResources?: HookFunction[];
|
||||
afterExtract?: HookFunction[];
|
||||
afterFinalizePackageTargets?: FinalizePackageTargetsHookFunction[];
|
||||
afterInitialize?: HookFunction[];
|
||||
afterPrune?: HookFunction[];
|
||||
all?: boolean;
|
||||
appBundleId?: string;
|
||||
appCategoryType?: string;
|
||||
appCopyright?: string;
|
||||
appVersion?: string;
|
||||
arch?: ArchOption | ArchOption[];
|
||||
asar?: boolean | AsarOptions;
|
||||
beforeAsar?: HookFunction[];
|
||||
beforeCopy?: HookFunction[];
|
||||
beforeCopyExtraResources?: HookFunction[];
|
||||
buildVersion?: string;
|
||||
darwinDarkModeSupport?: boolean;
|
||||
derefSymlinks?: boolean;
|
||||
download?: ElectronDownloadRequestOptions;
|
||||
electronVersion?: string;
|
||||
electronZipDir?: string;
|
||||
executableName?: string;
|
||||
extendHelperInfo?:
|
||||
| string
|
||||
| {
|
||||
[property: string]: any,
|
||||
};
|
||||
extendInfo?:
|
||||
| string
|
||||
| {
|
||||
[property: string]: any,
|
||||
};
|
||||
extraResource?: string | string[];
|
||||
helperBundleId?: string;
|
||||
icon?: string;
|
||||
ignore?: RegExp | (string | RegExp)[] | IgnoreFunction;
|
||||
junk?: boolean;
|
||||
name?: string;
|
||||
osxNotarize?: NotaryToolCredentials;
|
||||
osxSign?: true | OsxSignOptions;
|
||||
osxUniversal?: OsxUniversalOptions;
|
||||
out?: string;
|
||||
overwrite?: boolean;
|
||||
platform?: TargetPlatform | 'all' | Array<TargetPlatform | 'all'>;
|
||||
prebuiltAsar?: string;
|
||||
protocols?: MacOSProtocol[];
|
||||
prune?: boolean;
|
||||
quiet?: boolean;
|
||||
tmpdir?: string | false;
|
||||
usageDescription?: {
|
||||
[property: string]: string,
|
||||
};
|
||||
win32metadata?: Win32MetadataOptions;
|
||||
windowsSign?: true | WindowsSignOptions;
|
||||
}
|
||||
|
||||
declare function packager(options: Options): Promise<string[]>;
|
||||
|
||||
declare module.exports: typeof packager & {
|
||||
packager: typeof packager,
|
||||
default: typeof packager,
|
||||
};
|
||||
}
|
||||
+9
-10
@@ -32,7 +32,7 @@
|
||||
"test-typescript": "tsc -p packages/react-native/types/tsconfig.json",
|
||||
"test-generated-typescript": "tsc -p packages/react-native/types_generated/tsconfig.test.json",
|
||||
"test": "jest",
|
||||
"fantom": "./scripts/fantom.sh",
|
||||
"fantom": "JS_DIR='..' yarn jest --config private/react-native-fantom/config/jest.config.js",
|
||||
"trigger-react-native-release": "node ./scripts/releases-local/trigger-react-native-release.js",
|
||||
"update-lock": "npx yarn-deduplicate"
|
||||
},
|
||||
@@ -49,17 +49,16 @@
|
||||
"@babel/plugin-transform-regenerator": "^7.24.7",
|
||||
"@babel/preset-env": "^7.25.3",
|
||||
"@babel/preset-flow": "^7.24.7",
|
||||
"@electron/packager": "^18.3.6",
|
||||
"@jest/create-cache-key-function": "^29.7.0",
|
||||
"@microsoft/api-extractor": "^7.52.2",
|
||||
"@react-native/metro-babel-transformer": "0.81.0-main",
|
||||
"@react-native/metro-config": "0.81.0-main",
|
||||
"@react-native/metro-babel-transformer": "0.80.0-main",
|
||||
"@react-native/metro-config": "0.80.0-main",
|
||||
"@tsconfig/node22": "22.0.2",
|
||||
"@types/react": "^19.1.0",
|
||||
"@typescript-eslint/parser": "^7.1.1",
|
||||
"ansi-styles": "^4.2.1",
|
||||
"babel-plugin-minify-dead-code-elimination": "^0.5.2",
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.1",
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.0",
|
||||
"babel-plugin-transform-define": "^2.1.4",
|
||||
"babel-plugin-transform-flow-enums": "^0.0.2",
|
||||
"clang-format": "^1.8.0",
|
||||
@@ -77,11 +76,11 @@
|
||||
"eslint-plugin-react-native": "^4.0.0",
|
||||
"eslint-plugin-redundant-undefined": "^0.4.0",
|
||||
"eslint-plugin-relay": "^1.8.3",
|
||||
"flow-api-translator": "0.29.1",
|
||||
"flow-bin": "^0.274.2",
|
||||
"flow-api-translator": "0.29.0",
|
||||
"flow-bin": "^0.274.0",
|
||||
"glob": "^7.1.1",
|
||||
"hermes-eslint": "0.29.1",
|
||||
"hermes-transform": "0.29.1",
|
||||
"hermes-eslint": "0.29.0",
|
||||
"hermes-transform": "0.29.0",
|
||||
"inquirer": "^7.1.0",
|
||||
"jest": "^29.7.0",
|
||||
"jest-config": "^29.7.0",
|
||||
@@ -97,7 +96,7 @@
|
||||
"node-fetch": "^2.2.0",
|
||||
"nullthrows": "^1.1.1",
|
||||
"prettier": "2.8.8",
|
||||
"prettier-plugin-hermes-parser": "0.29.1",
|
||||
"prettier-plugin-hermes-parser": "0.29.0",
|
||||
"react": "19.1.0",
|
||||
"react-test-renderer": "19.1.0",
|
||||
"rimraf": "^3.0.2",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/assets-registry",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Asset support code for React Native.",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/babel-plugin-codegen",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Babel plugin to generate native module and view manager code for React Native.",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -26,7 +26,7 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"@babel/traverse": "^7.25.3",
|
||||
"@react-native/codegen": "0.81.0-main"
|
||||
"@react-native/codegen": "0.80.0-main"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.25.2"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/community-cli-plugin",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Core CLI commands for React Native",
|
||||
"keywords": [
|
||||
"react-native",
|
||||
@@ -22,7 +22,7 @@
|
||||
"dist"
|
||||
],
|
||||
"dependencies": {
|
||||
"@react-native/dev-middleware": "0.81.0-main",
|
||||
"@react-native/dev-middleware": "0.80.0-main",
|
||||
"debug": "^4.4.0",
|
||||
"invariant": "^2.2.4",
|
||||
"metro": "^0.82.4",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/core-cli-utils",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "React Native CLI library for Frameworks to build on",
|
||||
"license": "MIT",
|
||||
"main": "./src/index.flow.js",
|
||||
|
||||
@@ -125,7 +125,7 @@ export const tasks = {
|
||||
}),
|
||||
),
|
||||
installDependencies: task(FIFTH, 'Install CocoaPods dependencies', () => {
|
||||
const env: {[string]: string | void} = {
|
||||
const env = {
|
||||
RCT_NEW_ARCH_ENABLED: options.newArchitecture ? '1' : '0',
|
||||
USE_FRAMEWORKS: options.frameworks,
|
||||
USE_HERMES: options.hermes ? '1' : '0',
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
@generated SignedSource<<634e06e29a06ec6a22c087e7f8b01796>>
|
||||
Git revision: 35c4630bd58bbcbc6f4c54c084b4e52994dc4940
|
||||
@generated SignedSource<<cf5be4596d1f07e220b710fc286d02fa>>
|
||||
Git revision: d95ac13bf0ab64a5e6c2eb18eb138587063b9c34
|
||||
Built with --nohooks: false
|
||||
Is local checkout: false
|
||||
Remote URL: https://github.com/facebook/react-native-devtools-frontend
|
||||
|
||||
File diff suppressed because one or more lines are too long
+1
-1
File diff suppressed because one or more lines are too long
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/debugger-frontend",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Debugger frontend for React Native based on Chrome DevTools",
|
||||
"keywords": [
|
||||
"react-native",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/debugger-shell",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Experimental debugger shell for React Native for use with @react-native/debugger-frontend",
|
||||
"keywords": [
|
||||
"react-native",
|
||||
@@ -8,7 +8,7 @@
|
||||
],
|
||||
"homepage": "https://github.com/facebook/react-native/tree/HEAD/packages/debugger-shell#readme",
|
||||
"bugs": "https://github.com/facebook/react-native/issues",
|
||||
"main": "./src/index.js",
|
||||
"main": "./src/node/index.js",
|
||||
"exports": {
|
||||
".": {
|
||||
"node": "./src/node/index.js",
|
||||
@@ -27,11 +27,11 @@
|
||||
"license": "MIT",
|
||||
"engines": {
|
||||
"node": ">= 22.14.0",
|
||||
"electron": ">=36.3.0"
|
||||
"electron": ">=36.2.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"cross-spawn": "^7.0.6",
|
||||
"electron": "36.3.0"
|
||||
"electron": "36.2.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"semver": "^7.1.3"
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
|
||||
// $FlowFixMe[unclear-type] We have no Flow types for the Electron API.
|
||||
const {BrowserWindow, app, shell, ipcMain} = require('electron') as any;
|
||||
const path = require('path');
|
||||
const util = require('util');
|
||||
|
||||
const windowMetadata = new WeakMap<
|
||||
@@ -69,8 +68,6 @@ function handleLaunchArgs(argv: string[]) {
|
||||
partition: 'persist:react-native-devtools',
|
||||
preload: require.resolve('./preload.js'),
|
||||
},
|
||||
// Icon for Linux
|
||||
icon: path.join(__dirname, 'resources', 'icon.png'),
|
||||
});
|
||||
|
||||
// Open links in the default browser instead of in new Electron windows.
|
||||
@@ -93,7 +90,7 @@ function handleLaunchArgs(argv: string[]) {
|
||||
}
|
||||
|
||||
app.whenReady().then(() => {
|
||||
handleLaunchArgs(process.argv.slice(app.isPackaged ? 1 : 2));
|
||||
handleLaunchArgs(process.argv.slice(2));
|
||||
|
||||
app.on(
|
||||
'second-instance',
|
||||
|
||||
Binary file not shown.
Binary file not shown.
|
Before Width: | Height: | Size: 134 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 118 KiB |
@@ -1,26 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
// As far as Flow is concerned, this package is Node-only.
|
||||
/*::
|
||||
export type * from './node';
|
||||
const Node = require('./node');
|
||||
declare module.exports: typeof Node;
|
||||
*/
|
||||
|
||||
// Because Electron doesn't support package.json `exports`, we need to
|
||||
// switch at runtime.
|
||||
if ('electron' in process.versions) {
|
||||
// $FlowIgnore[invalid-export]
|
||||
module.exports = require('./electron');
|
||||
} else {
|
||||
// $FlowIgnore[invalid-export]
|
||||
module.exports = require('./node');
|
||||
}
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/dev-middleware",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Dev server middleware for React Native",
|
||||
"keywords": [
|
||||
"react-native",
|
||||
@@ -23,7 +23,7 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"@isaacs/ttlcache": "^1.4.1",
|
||||
"@react-native/debugger-frontend": "0.81.0-main",
|
||||
"@react-native/debugger-frontend": "0.80.0-main",
|
||||
"chrome-launcher": "^0.15.2",
|
||||
"chromium-edge-launcher": "^0.2.0",
|
||||
"connect": "^3.6.5",
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
*/
|
||||
|
||||
import type {JsonPagesListResponse} from '../inspector-proxy/types';
|
||||
import type {BrowserLauncher} from '../types/BrowserLauncher';
|
||||
|
||||
import DefaultBrowserLauncher from '../utils/DefaultBrowserLauncher';
|
||||
import {fetchJson, requestLocal} from './FetchUtils';
|
||||
@@ -23,7 +22,7 @@ const PAGES_POLLING_DELAY = 2100;
|
||||
jest.useFakeTimers();
|
||||
|
||||
describe('enableStandaloneFuseboxShell experiment', () => {
|
||||
const BrowserLauncherWithFuseboxShell: BrowserLauncher = {
|
||||
const BrowserLauncherWithFuseboxShell = {
|
||||
...DefaultBrowserLauncher,
|
||||
unstable_showFuseboxShell: () => {
|
||||
throw new Error('Not implemented');
|
||||
|
||||
@@ -22,7 +22,6 @@ import type {
|
||||
import type {IncomingMessage, ServerResponse} from 'http';
|
||||
|
||||
import getBaseUrlFromRequest from '../utils/getBaseUrlFromRequest';
|
||||
import getDevToolsFrontendUrl from '../utils/getDevToolsFrontendUrl';
|
||||
import Device from './Device';
|
||||
import EventLoopPerfTracker from './EventLoopPerfTracker';
|
||||
import InspectorProxyHeartbeat from './InspectorProxyHeartbeat';
|
||||
@@ -250,15 +249,13 @@ export default class InspectorProxy implements InspectorProxyQueries {
|
||||
|
||||
const webSocketUrlWithoutProtocol = `${host}${WS_DEBUGGER_URL}?device=${deviceId}&page=${page.id}`;
|
||||
const webSocketDebuggerUrl = `${webSocketScheme}://${webSocketUrlWithoutProtocol}`;
|
||||
const devtoolsFrontendUrl = getDevToolsFrontendUrl(
|
||||
this.#experiments,
|
||||
webSocketDebuggerUrl,
|
||||
this.#serverBaseUrl.origin,
|
||||
{
|
||||
relative: true,
|
||||
useFuseboxEntryPoint: page.capabilities.prefersFuseboxFrontend,
|
||||
},
|
||||
);
|
||||
|
||||
// For now, `/json/list` returns the legacy built-in `devtools://` URL, to
|
||||
// preserve existing handling by Flipper. This may return a placeholder in
|
||||
// future -- please use the `/open-debugger` endpoint.
|
||||
const devtoolsFrontendUrl =
|
||||
`devtools://devtools/bundled/js_app.html?experiments=true&v8only=true&${webSocketScheme}=` +
|
||||
encodeURIComponent(webSocketUrlWithoutProtocol);
|
||||
|
||||
return {
|
||||
id: `${deviceId}-${page.id}`,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/eslint-config",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "ESLint config for React Native",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -22,7 +22,7 @@
|
||||
"dependencies": {
|
||||
"@babel/core": "^7.25.2",
|
||||
"@babel/eslint-parser": "^7.25.1",
|
||||
"@react-native/eslint-plugin": "0.81.0-main",
|
||||
"@react-native/eslint-plugin": "0.80.0-main",
|
||||
"@typescript-eslint/eslint-plugin": "^7.1.1",
|
||||
"@typescript-eslint/parser": "^7.1.1",
|
||||
"eslint-config-prettier": "^8.5.0",
|
||||
|
||||
@@ -31,8 +31,6 @@ eslintTester.run('../no-deep-imports', rule, {
|
||||
"import Foo from 'react/native/Foo';",
|
||||
"import 'react-native/Libraries/Core/InitializeCore';",
|
||||
"require('react-native/Libraries/Core/InitializeCore');",
|
||||
"import Foo from 'react-native/src/fb_internal/Foo'",
|
||||
"require('react-native/src/fb_internal/Foo')",
|
||||
],
|
||||
invalid: [
|
||||
{
|
||||
@@ -105,25 +103,5 @@ eslintTester.run('../no-deep-imports', rule, {
|
||||
],
|
||||
output: null,
|
||||
},
|
||||
{
|
||||
code: "import type {RootTag} from 'react-native/Libraries/Types/RootTagTypes';",
|
||||
errors: [
|
||||
{
|
||||
messageId: 'deepImport',
|
||||
data: {importPath: 'react-native/Libraries/Types/RootTagTypes'},
|
||||
},
|
||||
],
|
||||
output: "import type {RootTag} from 'react-native';",
|
||||
},
|
||||
{
|
||||
code: "import type {ModalBaseProps, Foo} from 'react-native/Libraries/Modal/Modal';",
|
||||
errors: [
|
||||
{
|
||||
messageId: 'deepImport',
|
||||
data: {importPath: 'react-native/Libraries/Modal/Modal'},
|
||||
},
|
||||
],
|
||||
output: null,
|
||||
},
|
||||
],
|
||||
});
|
||||
|
||||
@@ -31,8 +31,7 @@ module.exports = {
|
||||
ImportDeclaration(node) {
|
||||
if (
|
||||
!isDeepReactNativeImport(node.source) ||
|
||||
isInitializeCoreImport(node.source) ||
|
||||
isFbInternalImport(node.source)
|
||||
isInitializeCoreImport(node.source)
|
||||
) {
|
||||
return;
|
||||
}
|
||||
@@ -41,55 +40,25 @@ module.exports = {
|
||||
'react-native/'.length,
|
||||
);
|
||||
const publicAPIDefaultComponent = publicAPIMapping[reactNativeSource];
|
||||
if (publicAPIDefaultComponent && publicAPIDefaultComponent.default) {
|
||||
if (publicAPIDefaultComponent) {
|
||||
context.report({
|
||||
...getStandardReport(node.source),
|
||||
fix(fixer) {
|
||||
return fixer.replaceText(
|
||||
node,
|
||||
`import {${publicAPIDefaultComponent.default}} from 'react-native';`,
|
||||
`import {${publicAPIDefaultComponent}} from 'react-native';`,
|
||||
);
|
||||
},
|
||||
});
|
||||
} else {
|
||||
context.report(getStandardReport(node.source));
|
||||
}
|
||||
} else if (isTypeImport(node)) {
|
||||
const reactNativeSource = node.source.value.slice(
|
||||
'react-native/'.length,
|
||||
);
|
||||
const publicAPIDefaultComponent = publicAPIMapping[reactNativeSource];
|
||||
if (publicAPIDefaultComponent && publicAPIDefaultComponent.types) {
|
||||
const typeNames = [];
|
||||
for (const specifier of node.specifiers) {
|
||||
const importedName = specifier.imported.name;
|
||||
if (!publicAPIDefaultComponent.types.includes(importedName)) {
|
||||
context.report(getStandardReport(node.source));
|
||||
return;
|
||||
}
|
||||
typeNames.push(importedName);
|
||||
}
|
||||
|
||||
context.report({
|
||||
...getStandardReport(node.source),
|
||||
fix(fixer) {
|
||||
return fixer.replaceText(
|
||||
node,
|
||||
`import type {${typeNames.join(', ')}} from 'react-native';`,
|
||||
);
|
||||
},
|
||||
});
|
||||
}
|
||||
} else {
|
||||
context.report(getStandardReport(node.source));
|
||||
}
|
||||
},
|
||||
CallExpression(node) {
|
||||
if (
|
||||
!isDeepRequire(node) ||
|
||||
isInitializeCoreImport(node.arguments[0]) ||
|
||||
isFbInternalImport(node.arguments[0])
|
||||
) {
|
||||
if (!isDeepRequire(node) || isInitializeCoreImport(node.arguments[0])) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -102,13 +71,13 @@ module.exports = {
|
||||
) {
|
||||
const reactNativeSource = importPath.slice('react-native/'.length);
|
||||
const publicAPIDefaultComponent = publicAPIMapping[reactNativeSource];
|
||||
if (publicAPIDefaultComponent && publicAPIDefaultComponent.default) {
|
||||
if (publicAPIDefaultComponent) {
|
||||
context.report({
|
||||
...getStandardReport(node.arguments[0]),
|
||||
fix(fixer) {
|
||||
return fixer.replaceText(
|
||||
parent,
|
||||
`{${publicAPIDefaultComponent.default}} = require('react-native')`,
|
||||
`{${publicAPIDefaultComponent}} = require('react-native')`,
|
||||
);
|
||||
},
|
||||
});
|
||||
@@ -140,10 +109,6 @@ module.exports = {
|
||||
);
|
||||
}
|
||||
|
||||
function isTypeImport(node) {
|
||||
return node.type === 'ImportDeclaration' && node.importKind === 'type';
|
||||
}
|
||||
|
||||
function isDeepRequire(node) {
|
||||
return (
|
||||
node.callee.type === 'Identifier' &&
|
||||
@@ -172,13 +137,5 @@ module.exports = {
|
||||
|
||||
return source.value === 'react-native/Libraries/Core/InitializeCore';
|
||||
}
|
||||
|
||||
function isFbInternalImport(source) {
|
||||
if (source.type !== 'Literal' || typeof source.value !== 'string') {
|
||||
return false;
|
||||
}
|
||||
|
||||
return source.value.startsWith('react-native/src/fb_internal/');
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/eslint-plugin",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "ESLint rules for @react-native/eslint-config",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -18,8 +18,8 @@
|
||||
"bugs": "https://github.com/facebook/react-native/issues",
|
||||
"main": "index.js",
|
||||
"devDependencies": {
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.1",
|
||||
"hermes-eslint": "0.29.1"
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.0",
|
||||
"hermes-eslint": "0.29.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 22.14.0"
|
||||
|
||||
@@ -17,513 +17,92 @@
|
||||
* If the path is not matched, the auto-fix won't be suggested.
|
||||
*/
|
||||
const publicAPIMapping = {
|
||||
'Libraries/Components/AccessibilityInfo/AccessibilityInfo': {
|
||||
default: 'AccessibilityInfo',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/ActivityIndicator/ActivityIndicator': {
|
||||
default: 'ActivityIndicator',
|
||||
types: ['ActivityIndicatorProps'],
|
||||
},
|
||||
'Libraries/Components/Button': {
|
||||
default: 'Button',
|
||||
types: ['ButtonProps'],
|
||||
},
|
||||
'Libraries/Components/DrawerAndroid/DrawerLayoutAndroid': {
|
||||
default: 'DrawerLayoutAndroid',
|
||||
types: ['DrawerLayoutAndroidProps', 'DrawerSlideEvent'],
|
||||
},
|
||||
'Libraries/Components/LayoutConformance/LayoutConformance': {
|
||||
default: 'experimental_LayoutConformance',
|
||||
types: ['LayoutConformanceProps'],
|
||||
},
|
||||
'Libraries/Lists/FlatList': {
|
||||
default: 'FlatList',
|
||||
types: ['FlatListProps'],
|
||||
},
|
||||
'Libraries/Image/Image': {
|
||||
default: 'Image',
|
||||
types: [
|
||||
'ImageBackgroundProps',
|
||||
'ImageErrorEvent',
|
||||
'ImageLoadEvent',
|
||||
'ImageProgressEventIOS',
|
||||
'ImageProps',
|
||||
'ImagePropsAndroid',
|
||||
'ImagePropsBase',
|
||||
'ImagePropsIOS',
|
||||
'ImageResolvedAssetSource',
|
||||
'ImageSize',
|
||||
'ImageSourcePropType',
|
||||
],
|
||||
},
|
||||
'Libraries/Image/ImageSource': {
|
||||
default: null,
|
||||
types: ['ImageRequireSource', 'ImageSource', 'ImageURISource'],
|
||||
},
|
||||
'Libraries/Image/ImageBackground': {
|
||||
default: 'ImageBackground',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/TextInput/InputAccessoryView': {
|
||||
default: 'InputAccessoryView',
|
||||
types: ['InputAccessoryViewProps'],
|
||||
},
|
||||
'Libraries/Components/Keyboard/KeyboardAvoidingView': {
|
||||
default: 'KeyboardAvoidingView',
|
||||
types: ['KeyboardAvoidingViewProps'],
|
||||
},
|
||||
'Libraries/Modal/Modal': {
|
||||
default: 'Modal',
|
||||
types: [
|
||||
'ModalBaseProps',
|
||||
'ModalProps',
|
||||
'ModalPropsAndroid',
|
||||
'ModalPropsIOS',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/Pressable/Pressable': {
|
||||
default: 'Pressable',
|
||||
types: [
|
||||
'PressableAndroidRippleConfig',
|
||||
'PressableProps',
|
||||
'PressableStateCallbackType',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/ProgressBarAndroid/ProgressBarAndroid': {
|
||||
default: 'ProgressBarAndroid',
|
||||
types: ['ProgressBarAndroidProps'],
|
||||
},
|
||||
'Libraries/Components/RefreshControl/RefreshControl': {
|
||||
default: 'RefreshControl',
|
||||
types: [
|
||||
'RefreshControlProps',
|
||||
'RefreshControlPropsAndroid',
|
||||
'RefreshControlPropsIOS',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/SafeAreaView/SafeAreaView': {
|
||||
default: 'SafeAreaView',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/ScrollView/ScrollView': {
|
||||
default: 'ScrollView',
|
||||
types: [
|
||||
'ScrollResponderType',
|
||||
'ScrollViewProps',
|
||||
'ScrollViewPropsAndroid',
|
||||
'ScrollViewPropsIOS',
|
||||
'ScrollViewImperativeMethods',
|
||||
'ScrollViewScrollToOptions',
|
||||
],
|
||||
},
|
||||
'Libraries/Lists/SectionList': {
|
||||
default: 'SectionList',
|
||||
types: [
|
||||
'SectionListProps',
|
||||
'SectionListRenderItem',
|
||||
'SectionListRenderItemInfo',
|
||||
'SectionListData',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/StatusBar/StatusBar': {
|
||||
default: 'StatusBar',
|
||||
types: ['StatusBarAnimation', 'StatusBarProps', 'StatusBarStyle'],
|
||||
},
|
||||
'Libraries/Components/Switch/Switch': {
|
||||
default: 'Switch',
|
||||
types: ['SwitchChangeEvent', 'SwitchProps'],
|
||||
},
|
||||
'Libraries/Text/Text': {
|
||||
default: 'Text',
|
||||
types: ['TextProps'],
|
||||
},
|
||||
'Libraries/Components/TextInput/TextInput': {
|
||||
default: 'TextInput',
|
||||
types: [
|
||||
'AutoCapitalize',
|
||||
'EnterKeyHintTypeOptions',
|
||||
'KeyboardTypeOptions',
|
||||
'InputModeOptions',
|
||||
'TextContentType',
|
||||
'TextInputAndroidProps',
|
||||
'TextInputIOSProps',
|
||||
'TextInputProps',
|
||||
'TextInputChangeEvent',
|
||||
'TextInputContentSizeChangeEvent',
|
||||
'TextInputEndEditingEvent',
|
||||
'TextInputFocusEvent',
|
||||
'TextInputKeyPressEvent',
|
||||
'TextInputSelectionChangeEvent',
|
||||
'TextInputSubmitEditingEvent',
|
||||
'ReturnKeyTypeOptions',
|
||||
'SubmitBehavior',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/Touchable/Touchable': {
|
||||
default: 'Touchable',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/Touchable/TouchableHighlight': {
|
||||
default: 'TouchableHighlight',
|
||||
types: ['TouchableHighlightProps'],
|
||||
},
|
||||
'Libraries/Components/Touchable/TouchableNativeFeedback': {
|
||||
default: 'TouchableNativeFeedback',
|
||||
types: ['TouchableNativeFeedbackProps'],
|
||||
},
|
||||
'Libraries/Components/Touchable/TouchableOpacity': {
|
||||
default: 'TouchableOpacity',
|
||||
types: ['TouchableOpacityProps'],
|
||||
},
|
||||
'Libraries/Components/Touchable/TouchableWithoutFeedback': {
|
||||
default: 'TouchableWithoutFeedback',
|
||||
types: ['TouchableWithoutFeedbackProps'],
|
||||
},
|
||||
'Libraries/Components/View/View': {
|
||||
default: 'View',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/View/ViewAccessibility': {
|
||||
default: null,
|
||||
types: [
|
||||
'AccessibilityActionEvent',
|
||||
'AccessibilityProps',
|
||||
'AccessibilityRole',
|
||||
'AccessibilityState',
|
||||
'AccessibilityValue',
|
||||
'Role',
|
||||
],
|
||||
},
|
||||
'Libraries/Components/View/ViewPropTypes': {
|
||||
default: null,
|
||||
types: [
|
||||
'GestureResponderHandlers',
|
||||
'TVViewPropsIOS',
|
||||
'ViewProps',
|
||||
'ViewPropsAndroid',
|
||||
'ViewPropsIOS',
|
||||
],
|
||||
},
|
||||
'Libraries/Lists/VirtualizedList': {
|
||||
default: 'VirtualizedList',
|
||||
types: [
|
||||
'ListRenderItemInfo',
|
||||
'ListRenderItem',
|
||||
'Separators',
|
||||
'VirtualizedListProps',
|
||||
],
|
||||
},
|
||||
'Libraries/Lists/VirtualizedSectionList': {
|
||||
default: 'VirtualizedSectionList',
|
||||
types: [
|
||||
'ScrollToLocationParamsType',
|
||||
'SectionBase',
|
||||
'VirtualizedSectionListProps',
|
||||
],
|
||||
},
|
||||
'Libraries/ActionSheetIOS/ActionSheetIOS': {
|
||||
default: 'ActionSheetIOS',
|
||||
types: [
|
||||
'ActionSheetIOSOptions',
|
||||
'ShareActionSheetIOSOptions',
|
||||
'ShareActionSheetError',
|
||||
],
|
||||
},
|
||||
'Libraries/Alert/Alert': {
|
||||
default: 'Alert',
|
||||
types: ['AlertType', 'AlertButtonStyle', 'AlertButton', 'AlertOptions'],
|
||||
},
|
||||
'Libraries/Animated/Animated': {
|
||||
default: 'Animated',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/Appearance': {
|
||||
default: 'Appearance',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/ReactNative/AppRegistry': {
|
||||
default: 'AppRegistry',
|
||||
types: [
|
||||
'TaskProvider',
|
||||
'ComponentProvider',
|
||||
'ComponentProviderInstrumentationHook',
|
||||
'AppConfig',
|
||||
'Runnable',
|
||||
'Runnables',
|
||||
'Registry',
|
||||
'WrapperComponentProvider',
|
||||
'RootViewStyleProvider',
|
||||
],
|
||||
},
|
||||
'Libraries/AppState/AppState': {
|
||||
default: 'AppState',
|
||||
types: ['AppStateStatus', 'AppStateEvent'],
|
||||
},
|
||||
'Libraries/Utilities/BackHandler': {
|
||||
default: 'BackHandler',
|
||||
types: ['BackPressEventName'],
|
||||
},
|
||||
'Libraries/Components/Clipboard/Clipboard': {
|
||||
default: 'Clipboard',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/DeviceInfo': {
|
||||
default: 'DeviceInfo',
|
||||
types: ['DeviceInfoConstants'],
|
||||
},
|
||||
'src/private/devsupport/devmenu/DevMenu': {
|
||||
default: 'DevMenu',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/DevSettings': {
|
||||
default: 'DevSettings',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/Dimensions': {
|
||||
default: 'Dimensions',
|
||||
types: [
|
||||
'DimensionsPayload',
|
||||
'DisplayMetrics',
|
||||
'DisplayMetricsAndroid',
|
||||
'ScaledSize',
|
||||
],
|
||||
},
|
||||
'Libraries/Animated/Easing': {
|
||||
default: 'Easing',
|
||||
types: ['EasingFunction'],
|
||||
},
|
||||
'Libraries/ReactNative/I18nManager': {
|
||||
default: 'I18nManager',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Interaction/InteractionManager': {
|
||||
default: 'InteractionManager',
|
||||
types: ['Handle', 'PromiseTask', 'SimpleTask'],
|
||||
},
|
||||
'Libraries/Components/Keyboard/Keyboard': {
|
||||
default: 'Keyboard',
|
||||
types: [
|
||||
'AndroidKeyboardEvent',
|
||||
'IOSKeyboardEvent',
|
||||
'KeyboardEvent',
|
||||
'KeyboardEventEasing',
|
||||
'KeyboardEventName',
|
||||
'KeyboardMetrics',
|
||||
],
|
||||
},
|
||||
'Libraries/LayoutAnimation/LayoutAnimation': {
|
||||
default: 'LayoutAnimation',
|
||||
types: [
|
||||
'LayoutAnimationAnim',
|
||||
'LayoutAnimationConfig',
|
||||
'LayoutAnimationProperties',
|
||||
'LayoutAnimationProperty',
|
||||
'LayoutAnimationType',
|
||||
'LayoutAnimationTypes',
|
||||
],
|
||||
},
|
||||
'Libraries/Linking/Linking': {
|
||||
default: 'Linking',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/LogBox/LogBox': {
|
||||
default: 'LogBox',
|
||||
types: ['ExtendedExceptionData', 'IgnorePattern', 'LogData'],
|
||||
},
|
||||
'Libraries/NativeModules/specs/NativeDialogManagerAndroid': {
|
||||
default: 'NativeDialogManagerAndroid',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/EventEmitter/NativeEventEmitter': {
|
||||
default: 'NativeEventEmitter',
|
||||
types: [
|
||||
'EventSubscription',
|
||||
'EmitterSubscription',
|
||||
'NativeEventSubscription',
|
||||
],
|
||||
},
|
||||
'Libraries/Network/RCTNetworking': {
|
||||
default: 'Networking',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Interaction/PanResponder': {
|
||||
default: 'PanResponder',
|
||||
types: [
|
||||
'PanResponderCallbacks',
|
||||
'PanResponderGestureState',
|
||||
'PanResponderInstance',
|
||||
],
|
||||
},
|
||||
'Libraries/PermissionsAndroid/PermissionsAndroid': {
|
||||
default: 'PermissionsAndroid',
|
||||
types: ['Permission', 'PermissionStatus', 'Rationale'],
|
||||
},
|
||||
'Libraries/Utilities/PixelRatio': {
|
||||
default: 'PixelRatio',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/PushNotificationIOS/PushNotificationIOS': {
|
||||
default: 'PushNotificationIOS',
|
||||
types: ['PushNotificationEventName', 'PushNotificationPermissions'],
|
||||
},
|
||||
'Libraries/Settings/Settings': {
|
||||
default: 'Settings',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Share/Share': {
|
||||
default: 'Share',
|
||||
types: ['ShareAction', 'ShareContent', 'ShareOptions'],
|
||||
},
|
||||
'Libraries/StyleSheet/StyleSheet': {
|
||||
default: 'StyleSheet',
|
||||
types: [
|
||||
'ColorValue',
|
||||
'ImageStyle',
|
||||
'FilterFunction',
|
||||
'FontVariant',
|
||||
'NativeColorValue',
|
||||
'OpaqueColorValue',
|
||||
'StyleProp',
|
||||
'TextStyle',
|
||||
'TransformsStyle',
|
||||
'ViewStyle',
|
||||
],
|
||||
},
|
||||
'Libraries/StyleSheet/StyleSheetTypes': {
|
||||
default: null,
|
||||
types: [
|
||||
'BoxShadowValue',
|
||||
'CursorValue',
|
||||
'DimensionValue',
|
||||
'DropShadowValue',
|
||||
'EdgeInsetsValue',
|
||||
'PointValue',
|
||||
],
|
||||
},
|
||||
'Libraries/StyleSheet/Rect': {
|
||||
default: null,
|
||||
types: ['Insets'],
|
||||
},
|
||||
'Libraries/Performance/Systrace': {
|
||||
default: 'Systrace',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Components/ToastAndroid/ToastAndroid': {
|
||||
default: 'ToastAndroid',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/TurboModule/TurboModuleRegistry': {
|
||||
default: 'TurboModuleRegistry',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/TurboModule/RCTExport': {
|
||||
default: null,
|
||||
types: ['TurboModule'],
|
||||
},
|
||||
'Libraries/ReactNative/UIManager': {
|
||||
default: 'UIManager',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Animated/useAnimatedValue': {
|
||||
default: 'useAnimatedValue',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/useColorScheme': {
|
||||
default: 'useColorScheme',
|
||||
types: null,
|
||||
},
|
||||
'src/private/specs_DEPRECATED/modules/NativeAppearance': {
|
||||
default: null,
|
||||
types: ['ColorSchemeName'],
|
||||
},
|
||||
'Libraries/Utilities/useWindowDimensions': {
|
||||
default: 'useWindowDimensions',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/UTFSequence': {
|
||||
default: 'UTFSequence',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Vibration/Vibration': {
|
||||
default: 'Vibration',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/codegenNativeComponent': {
|
||||
default: 'codegenNativeComponent',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/codegenNativeCommands': {
|
||||
default: 'codegenNativeCommands',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/EventEmitter/RCTDeviceEventEmitter': {
|
||||
default: 'DeviceEventEmitter',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/StyleSheet/PlatformColorValueTypesIOS': {
|
||||
default: 'DynamicColorIOS',
|
||||
types: ['DynamicColorIOSTuple'],
|
||||
},
|
||||
'Libraries/EventEmitter/RCTNativeAppEventEmitter': {
|
||||
default: 'NativeAppEventEmitter',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/BatchedBridge/NativeModules': {
|
||||
default: 'NativeModules',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/Utilities/Platform': {
|
||||
default: 'Platform',
|
||||
types: null,
|
||||
},
|
||||
'./Libraries/Utilities/PlatformTypes': {
|
||||
default: null,
|
||||
types: ['PlatformOSType', 'PlatformSelectSpec'],
|
||||
},
|
||||
'Libraries/StyleSheet/PlatformColorValueTypes': {
|
||||
default: 'PlatformColor',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/StyleSheet/processColor': {
|
||||
default: 'processColor',
|
||||
types: ['ProcessedColorValue'],
|
||||
},
|
||||
'Libraries/ReactNative/requireNativeComponent': {
|
||||
default: 'requireNativeComponent',
|
||||
types: null,
|
||||
},
|
||||
'Libraries/ReactNative/RootTag': {
|
||||
default: 'RootTagContext',
|
||||
types: ['RootTag'],
|
||||
},
|
||||
'Libraries/Types/RootTagTypes': {
|
||||
default: null,
|
||||
types: ['RootTag'],
|
||||
},
|
||||
'src/private/types/HostInstance': {
|
||||
default: null,
|
||||
types: [
|
||||
'HostInstance',
|
||||
'NativeMethods',
|
||||
'NativeMethodsMixin',
|
||||
'MeasureInWindowOnSuccessCallback',
|
||||
'MeasureLayoutOnSuccessCallback',
|
||||
'MeasureOnSuccessCallback',
|
||||
],
|
||||
},
|
||||
'src/private/types/HostComponent': {
|
||||
default: null,
|
||||
types: ['HostComponent'],
|
||||
},
|
||||
'Libraries/vendor/core/ErrorUtils': {
|
||||
default: null,
|
||||
types: ['ErrorUtils'],
|
||||
},
|
||||
'Libraries/ReactPrivate/ReactNativePrivateInterface': {
|
||||
default: null,
|
||||
types: ['PublicRootInstance', 'PublicTextInstance'],
|
||||
},
|
||||
'Libraries/Components/AccessibilityInfo/AccessibilityInfo':
|
||||
'AccessibilityInfo',
|
||||
'Libraries/Components/ActivityIndicator/ActivityIndicator':
|
||||
'ActivityIndicator',
|
||||
'Libraries/Components/Button': 'Button',
|
||||
'Libraries/Components/DrawerAndroid/DrawerLayoutAndroid':
|
||||
'DrawerLayoutAndroid',
|
||||
'Libraries/Components/LayoutConformance/LayoutConformance':
|
||||
'experimental_LayoutConformance',
|
||||
'Libraries/Lists/FlatList': 'FlatList',
|
||||
'Libraries/Image/Image': 'Image',
|
||||
'Libraries/Image/ImageBackground': 'ImageBackground',
|
||||
'Libraries/Components/TextInput/InputAccessoryView': 'InputAccessoryView',
|
||||
'Libraries/Components/Keyboard/KeyboardAvoidingView': 'KeyboardAvoidingView',
|
||||
'Libraries/Modal/Modal': 'Modal',
|
||||
'Libraries/Components/Pressable/Pressable': 'Pressable',
|
||||
'Libraries/Components/ProgressBarAndroid/ProgressBarAndroid':
|
||||
'ProgressBarAndroid',
|
||||
'Libraries/Components/RefreshControl/RefreshControl': 'RefreshControl',
|
||||
'Libraries/Components/SafeAreaView/SafeAreaView': 'SafeAreaView',
|
||||
'Libraries/Components/ScrollView/ScrollView': 'ScrollView',
|
||||
'Libraries/Lists/SectionList': 'SectionList',
|
||||
'Libraries/Components/StatusBar/StatusBar': 'StatusBar',
|
||||
'Libraries/Components/Switch/Switch': 'Switch',
|
||||
'Libraries/Text/Text': 'Text',
|
||||
'Libraries/Components/TextInput/TextInput': 'TextInput',
|
||||
'Libraries/Components/Touchable/Touchable': 'Touchable',
|
||||
'Libraries/Components/Touchable/TouchableHighlight': 'TouchableHighlight',
|
||||
'Libraries/Components/Touchable/TouchableNativeFeedback':
|
||||
'TouchableNativeFeedback',
|
||||
'Libraries/Components/Touchable/TouchableOpacity': 'TouchableOpacity',
|
||||
'Libraries/Components/Touchable/TouchableWithoutFeedback':
|
||||
'TouchableWithoutFeedback',
|
||||
'Libraries/Components/View/View': 'View',
|
||||
'Libraries/Lists/VirtualizedList': 'VirtualizedList',
|
||||
'Libraries/Lists/VirtualizedSectionList': 'VirtualizedSectionList',
|
||||
'Libraries/ActionSheetIOS/ActionSheetIOS': 'ActionSheetIOS',
|
||||
'Libraries/Alert/Alert': 'Alert',
|
||||
'Libraries/Animated/Animated': 'Animated',
|
||||
'Libraries/Utilities/Appearance': 'Appearance',
|
||||
'Libraries/ReactNative/AppRegistry': 'AppRegistry',
|
||||
'Libraries/AppState/AppState': 'AppState',
|
||||
'Libraries/Utilities/BackHandler': 'BackHandler',
|
||||
'Libraries/Components/Clipboard/Clipboard': 'Clipboard',
|
||||
'Libraries/Utilities/DeviceInfo': 'DeviceInfo',
|
||||
'src/private/devsupport/devmenu/DevMenu': 'DevMenu',
|
||||
'Libraries/Utilities/DevSettings': 'DevSettings',
|
||||
'Libraries/Utilities/Dimensions': 'Dimensions',
|
||||
'Libraries/Animated/Easing': 'Easing',
|
||||
'Libraries/ReactNative/I18nManager': 'I18nManager',
|
||||
'Libraries/Interaction/InteractionManager': 'InteractionManager',
|
||||
'Libraries/Components/Keyboard/Keyboard': 'Keyboard',
|
||||
'Libraries/LayoutAnimation/LayoutAnimation': 'LayoutAnimation',
|
||||
'Libraries/Linking/Linking': 'Linking',
|
||||
'Libraries/LogBox/LogBox': 'LogBox',
|
||||
'Libraries/NativeModules/specs/NativeDialogManagerAndroid':
|
||||
'NativeDialogManagerAndroid',
|
||||
'Libraries/EventEmitter/NativeEventEmitter': 'NativeEventEmitter',
|
||||
'Libraries/Network/RCTNetworking': 'Networking',
|
||||
'Libraries/Interaction/PanResponder': 'PanResponder',
|
||||
'Libraries/PermissionsAndroid/PermissionsAndroid': 'PermissionsAndroid',
|
||||
'Libraries/Utilities/PixelRatio': 'PixelRatio',
|
||||
'Libraries/PushNotificationIOS/PushNotificationIOS': 'PushNotificationIOS',
|
||||
'Libraries/Settings/Settings': 'Settings',
|
||||
'Libraries/Share/Share': 'Share',
|
||||
'Libraries/StyleSheet/StyleSheet': 'StyleSheet',
|
||||
'Libraries/Performance/Systrace': 'Systrace',
|
||||
'Libraries/Components/ToastAndroid/ToastAndroid': 'ToastAndroid',
|
||||
'Libraries/TurboModule/TurboModuleRegistry': 'TurboModuleRegistry',
|
||||
'Libraries/ReactNative/UIManager': 'UIManager',
|
||||
'Libraries/Animated/useAnimatedValue': 'useAnimatedValue',
|
||||
'Libraries/Utilities/useColorScheme': 'useColorScheme',
|
||||
'Libraries/Utilities/useWindowDimensions': 'useWindowDimensions',
|
||||
'Libraries/UTFSequence': 'UTFSequence',
|
||||
'Libraries/Vibration/Vibration': 'Vibration',
|
||||
'Libraries/Utilities/codegenNativeComponent': 'codegenNativeComponent',
|
||||
'Libraries/Utilities/codegenNativeCommands': 'codegenNativeCommands',
|
||||
'Libraries/EventEmitter/RCTDeviceEventEmitter': 'DeviceEventEmitter',
|
||||
'Libraries/StyleSheet/PlatformColorValueTypesIOS': 'DynamicColorIOS',
|
||||
'Libraries/EventEmitter/RCTNativeAppEventEmitter': 'NativeAppEventEmitter',
|
||||
'Libraries/BatchedBridge/NativeModules': 'NativeModules',
|
||||
'Libraries/Utilities/Platform': 'Platform',
|
||||
'Libraries/StyleSheet/PlatformColorValueTypes': 'PlatformColor',
|
||||
'Libraries/StyleSheet/processColor': 'processColor',
|
||||
'Libraries/ReactNative/requireNativeComponent': 'requireNativeComponent',
|
||||
'Libraries/ReactNative/RootTag': 'RootTagContext',
|
||||
};
|
||||
|
||||
module.exports = {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/eslint-plugin-specs",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "ESLint rules to validate NativeModule and Component Specs",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -26,14 +26,14 @@
|
||||
"dependencies": {
|
||||
"@babel/core": "^7.25.2",
|
||||
"@babel/plugin-transform-flow-strip-types": "^7.25.2",
|
||||
"@react-native/codegen": "0.81.0-main",
|
||||
"@react-native/codegen": "0.80.0-main",
|
||||
"make-dir": "^2.1.0",
|
||||
"pirates": "^4.0.1",
|
||||
"source-map-support": "0.5.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.1",
|
||||
"hermes-eslint": "0.29.1"
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.0",
|
||||
"hermes-eslint": "0.29.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 22.14.0"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.2-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.1-bin.zip
|
||||
networkTimeout=10000
|
||||
validateDistributionUrl=true
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/gradle-plugin",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Gradle Plugin for React Native",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
-5
@@ -70,7 +70,6 @@ abstract class GenerateEntryPointTask : DefaultTask() {
|
||||
|
||||
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint;
|
||||
import com.facebook.react.common.annotations.internal.LegacyArchitectureLogger;
|
||||
import com.facebook.react.views.view.WindowUtilKt;
|
||||
import com.facebook.react.soloader.OpenSourceMergedSoMapping;
|
||||
import com.facebook.soloader.SoLoader;
|
||||
|
||||
@@ -94,10 +93,6 @@ abstract class GenerateEntryPointTask : DefaultTask() {
|
||||
if ({{packageName}}.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
|
||||
DefaultNewArchitectureEntryPoint.load();
|
||||
}
|
||||
|
||||
if ({{packageName}}.BuildConfig.IS_EDGE_TO_EDGE_ENABLED) {
|
||||
WindowUtilKt.setEdgeToEdgeFeatureFlagOn();
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
-3
@@ -11,7 +11,6 @@ import com.android.build.api.variant.ApplicationAndroidComponentsExtension
|
||||
import com.android.build.api.variant.LibraryAndroidComponentsExtension
|
||||
import com.android.build.gradle.LibraryExtension
|
||||
import com.facebook.react.ReactExtension
|
||||
import com.facebook.react.utils.ProjectUtils.isEdgeToEdgeEnabled
|
||||
import com.facebook.react.utils.ProjectUtils.isHermesEnabled
|
||||
import com.facebook.react.utils.ProjectUtils.isNewArchEnabled
|
||||
import java.io.File
|
||||
@@ -40,8 +39,6 @@ internal object AgpConfiguratorUtils {
|
||||
project.isNewArchEnabled(extension).toString())
|
||||
ext.defaultConfig.buildConfigField(
|
||||
"boolean", "IS_HERMES_ENABLED", project.isHermesEnabled.toString())
|
||||
ext.defaultConfig.buildConfigField(
|
||||
"boolean", "IS_EDGE_TO_EDGE_ENABLED", project.isEdgeToEdgeEnabled.toString())
|
||||
}
|
||||
}
|
||||
project.pluginManager.withPlugin("com.android.application", action)
|
||||
|
||||
-27
@@ -8,14 +8,12 @@
|
||||
package com.facebook.react.utils
|
||||
|
||||
import com.facebook.react.utils.PropertyUtils.DEFAULT_INTERNAL_PUBLISHING_GROUP
|
||||
import com.facebook.react.utils.PropertyUtils.EXCLUSIVE_ENTEPRISE_REPOSITORY
|
||||
import com.facebook.react.utils.PropertyUtils.INCLUDE_JITPACK_REPOSITORY
|
||||
import com.facebook.react.utils.PropertyUtils.INCLUDE_JITPACK_REPOSITORY_DEFAULT
|
||||
import com.facebook.react.utils.PropertyUtils.INTERNAL_PUBLISHING_GROUP
|
||||
import com.facebook.react.utils.PropertyUtils.INTERNAL_REACT_NATIVE_MAVEN_LOCAL_REPO
|
||||
import com.facebook.react.utils.PropertyUtils.INTERNAL_USE_HERMES_NIGHTLY
|
||||
import com.facebook.react.utils.PropertyUtils.INTERNAL_VERSION_NAME
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_EXCLUSIVE_ENTEPRISE_REPOSITORY
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_INCLUDE_JITPACK_REPOSITORY
|
||||
import java.io.File
|
||||
import java.net.URI
|
||||
@@ -30,12 +28,6 @@ internal object DependencyUtils {
|
||||
* party libraries which are auto-linked.
|
||||
*/
|
||||
fun configureRepositories(project: Project) {
|
||||
val exclusiveEnterpriseRepository = project.rootProject.exclusiveEnterpriseRepository()
|
||||
if (exclusiveEnterpriseRepository != null) {
|
||||
project.logger.lifecycle(
|
||||
"Replacing ALL Maven Repositories with: $exclusiveEnterpriseRepository")
|
||||
}
|
||||
|
||||
project.rootProject.allprojects { eachProject ->
|
||||
with(eachProject) {
|
||||
if (hasProperty(INTERNAL_REACT_NATIVE_MAVEN_LOCAL_REPO)) {
|
||||
@@ -44,16 +36,6 @@ internal object DependencyUtils {
|
||||
repo.content { it.excludeGroup("org.webkit") }
|
||||
}
|
||||
}
|
||||
|
||||
if (exclusiveEnterpriseRepository != null) {
|
||||
// We remove all previously set repositories and only configure the proxy provided by the
|
||||
// user.
|
||||
rootProject.repositories.clear()
|
||||
mavenRepoFromUrl(exclusiveEnterpriseRepository)
|
||||
// We return here as we don't want to configure other repositories as well.
|
||||
return@allprojects
|
||||
}
|
||||
|
||||
// We add the snapshot for users on nightlies.
|
||||
mavenRepoFromUrl("https://central.sonatype.com/repository/maven-snapshots/") { repo ->
|
||||
repo.content { it.excludeGroup("org.webkit") }
|
||||
@@ -199,13 +181,4 @@ internal object DependencyUtils {
|
||||
property(INCLUDE_JITPACK_REPOSITORY).toString().toBoolean()
|
||||
else -> INCLUDE_JITPACK_REPOSITORY_DEFAULT
|
||||
}
|
||||
|
||||
internal fun Project.exclusiveEnterpriseRepository() =
|
||||
when {
|
||||
hasProperty(SCOPED_EXCLUSIVE_ENTEPRISE_REPOSITORY) ->
|
||||
property(SCOPED_EXCLUSIVE_ENTEPRISE_REPOSITORY).toString()
|
||||
hasProperty(EXCLUSIVE_ENTEPRISE_REPOSITORY) ->
|
||||
property(EXCLUSIVE_ENTEPRISE_REPOSITORY).toString()
|
||||
else -> null
|
||||
}
|
||||
}
|
||||
|
||||
-9
@@ -11,11 +11,9 @@ import com.facebook.react.ReactExtension
|
||||
import com.facebook.react.model.ModelPackageJson
|
||||
import com.facebook.react.utils.KotlinStdlibCompatUtils.lowercaseCompat
|
||||
import com.facebook.react.utils.KotlinStdlibCompatUtils.toBooleanStrictOrNullCompat
|
||||
import com.facebook.react.utils.PropertyUtils.EDGE_TO_EDGE_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.HERMES_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.NEW_ARCH_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.REACT_NATIVE_ARCHITECTURES
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_EDGE_TO_EDGE_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_HERMES_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_NEW_ARCH_ENABLED
|
||||
import com.facebook.react.utils.PropertyUtils.SCOPED_REACT_NATIVE_ARCHITECTURES
|
||||
@@ -61,13 +59,6 @@ internal object ProjectUtils {
|
||||
HERMES_FALLBACK
|
||||
}
|
||||
|
||||
internal val Project.isEdgeToEdgeEnabled: Boolean
|
||||
get() =
|
||||
(project.hasProperty(EDGE_TO_EDGE_ENABLED) &&
|
||||
project.property(EDGE_TO_EDGE_ENABLED).toString().toBoolean()) ||
|
||||
(project.hasProperty(SCOPED_EDGE_TO_EDGE_ENABLED) &&
|
||||
project.property(SCOPED_EDGE_TO_EDGE_ENABLED).toString().toBoolean())
|
||||
|
||||
internal val Project.useThirdPartyJSC: Boolean
|
||||
get() =
|
||||
(project.hasProperty(USE_THIRD_PARTY_JSC) &&
|
||||
|
||||
+1
-11
@@ -14,14 +14,10 @@ object PropertyUtils {
|
||||
const val NEW_ARCH_ENABLED = "newArchEnabled"
|
||||
const val SCOPED_NEW_ARCH_ENABLED = "react.newArchEnabled"
|
||||
|
||||
/** Public property that toggles Hermes */
|
||||
/** Public property that toggles the New Architecture */
|
||||
const val HERMES_ENABLED = "hermesEnabled"
|
||||
const val SCOPED_HERMES_ENABLED = "react.hermesEnabled"
|
||||
|
||||
/** Public property that toggles edge-to-edge */
|
||||
const val EDGE_TO_EDGE_ENABLED = "edgeToEdgeEnabled"
|
||||
const val SCOPED_EDGE_TO_EDGE_ENABLED = "react.edgeToEdgeEnabled"
|
||||
|
||||
/** Public property that excludes jsctooling from core */
|
||||
const val USE_THIRD_PARTY_JSC = "useThirdPartyJSC"
|
||||
const val SCOPED_USE_THIRD_PARTY_JSC = "react.useThirdPartyJSC"
|
||||
@@ -34,12 +30,6 @@ object PropertyUtils {
|
||||
const val INCLUDE_JITPACK_REPOSITORY = "includeJitpackRepository"
|
||||
const val SCOPED_INCLUDE_JITPACK_REPOSITORY = "react.includeJitpackRepository"
|
||||
|
||||
/**
|
||||
* Public property that allows to configure an enterprise repository proxy as exclusive repository
|
||||
*/
|
||||
const val EXCLUSIVE_ENTEPRISE_REPOSITORY = "exclusiveEnterpriseRepository"
|
||||
const val SCOPED_EXCLUSIVE_ENTEPRISE_REPOSITORY = "react.exclusiveEnterpriseRepository"
|
||||
|
||||
/** By default we include JitPack to avoid breaking user builds */
|
||||
internal const val INCLUDE_JITPACK_REPOSITORY_DEFAULT = true
|
||||
|
||||
|
||||
-5
@@ -55,7 +55,6 @@ class GenerateEntryPointTaskTest {
|
||||
|
||||
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint;
|
||||
import com.facebook.react.common.annotations.internal.LegacyArchitectureLogger;
|
||||
import com.facebook.react.views.view.WindowUtilKt;
|
||||
import com.facebook.react.soloader.OpenSourceMergedSoMapping;
|
||||
import com.facebook.soloader.SoLoader;
|
||||
|
||||
@@ -79,10 +78,6 @@ class GenerateEntryPointTaskTest {
|
||||
if (com.facebook.react.BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) {
|
||||
DefaultNewArchitectureEntryPoint.load();
|
||||
}
|
||||
|
||||
if (com.facebook.react.BuildConfig.IS_EDGE_TO_EDGE_ENABLED) {
|
||||
WindowUtilKt.setEdgeToEdgeFeatureFlagOn();
|
||||
}
|
||||
}
|
||||
}
|
||||
"""
|
||||
|
||||
+1
-44
@@ -10,7 +10,6 @@ package com.facebook.react.utils
|
||||
import com.facebook.react.tests.createProject
|
||||
import com.facebook.react.utils.DependencyUtils.configureDependencies
|
||||
import com.facebook.react.utils.DependencyUtils.configureRepositories
|
||||
import com.facebook.react.utils.DependencyUtils.exclusiveEnterpriseRepository
|
||||
import com.facebook.react.utils.DependencyUtils.getDependencySubstitutions
|
||||
import com.facebook.react.utils.DependencyUtils.mavenRepoFromURI
|
||||
import com.facebook.react.utils.DependencyUtils.mavenRepoFromUrl
|
||||
@@ -100,24 +99,6 @@ class DependencyUtilsTest {
|
||||
.isNotNull()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun configureRepositories_withExclusiveEnterpriseRepository_replacesAllRepositories() {
|
||||
val repositoryURI = URI.create("https://maven.myfabolousorganization.it")
|
||||
|
||||
val project = createProject()
|
||||
project.rootProject.extensions.extraProperties.set(
|
||||
"exclusiveEnterpriseRepository", repositoryURI.toString())
|
||||
|
||||
configureRepositories(project)
|
||||
|
||||
assertThat(project.repositories).hasSize(1)
|
||||
assertThat(
|
||||
project.repositories.firstOrNull {
|
||||
it is MavenArtifactRepository && it.url == repositoryURI
|
||||
})
|
||||
.isNotNull()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun configureRepositories_withIncludeJitpackRepositoryFalse_doesNotContainJitPack() {
|
||||
val repositoryURI = URI.create("https://www.jitpack.io")
|
||||
@@ -489,7 +470,7 @@ class DependencyUtilsTest {
|
||||
@Test
|
||||
fun shouldAddJitPack_withUnscopedProperty() {
|
||||
val project = createProject(tempFolder.root)
|
||||
project.extensions.extraProperties.set("includeJitpackRepository", "false")
|
||||
project.extensions.extraProperties.set("react.includeJitpackRepository", "false")
|
||||
assertThat(project.shouldAddJitPack()).isFalse()
|
||||
}
|
||||
|
||||
@@ -498,28 +479,4 @@ class DependencyUtilsTest {
|
||||
val project = createProject(tempFolder.root)
|
||||
assertThat(project.shouldAddJitPack()).isTrue()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun exclusiveEnterpriseRepository_withScopedProperty() {
|
||||
val project = createProject(tempFolder.root)
|
||||
project.extensions.extraProperties.set(
|
||||
"react.exclusiveEnterpriseRepository", "https://maven.myfabolousorganization.it")
|
||||
assertThat(project.exclusiveEnterpriseRepository())
|
||||
.isEqualTo("https://maven.myfabolousorganization.it")
|
||||
}
|
||||
|
||||
@Test
|
||||
fun exclusiveEnterpriseRepository_withUnscopedProperty() {
|
||||
val project = createProject(tempFolder.root)
|
||||
project.extensions.extraProperties.set(
|
||||
"exclusiveEnterpriseRepository", "https://maven.myfabolousorganization.it")
|
||||
assertThat(project.exclusiveEnterpriseRepository())
|
||||
.isEqualTo("https://maven.myfabolousorganization.it")
|
||||
}
|
||||
|
||||
@Test
|
||||
fun exclusiveEnterpriseRepository_defaultIsTrue() {
|
||||
val project = createProject(tempFolder.root)
|
||||
assertThat(project.exclusiveEnterpriseRepository()).isNull()
|
||||
}
|
||||
}
|
||||
|
||||
+1
-28
@@ -12,7 +12,6 @@ import com.facebook.react.model.ModelCodegenConfig
|
||||
import com.facebook.react.model.ModelPackageJson
|
||||
import com.facebook.react.tests.createProject
|
||||
import com.facebook.react.utils.ProjectUtils.getReactNativeArchitectures
|
||||
import com.facebook.react.utils.ProjectUtils.isEdgeToEdgeEnabled
|
||||
import com.facebook.react.utils.ProjectUtils.isHermesEnabled
|
||||
import com.facebook.react.utils.ProjectUtils.isNewArchEnabled
|
||||
import com.facebook.react.utils.ProjectUtils.needsCodegenFromPackageJson
|
||||
@@ -99,7 +98,7 @@ class ProjectUtilsTest {
|
||||
}
|
||||
|
||||
@Test
|
||||
fun isHermesEnabled_withDisabledViaProperty_returnsFalse() {
|
||||
fun isNewArchEnabled_withDisabledViaProperty_returnsFalse() {
|
||||
val project = createProject()
|
||||
project.extensions.extraProperties.set("hermesEnabled", "false")
|
||||
assertThat(project.isHermesEnabled).isFalse()
|
||||
@@ -151,32 +150,6 @@ class ProjectUtilsTest {
|
||||
assertThat(project.isHermesEnabled).isTrue()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun isEdgeToEdgeEnabled_returnsFalseByDefault() {
|
||||
assertThat(createProject().isEdgeToEdgeEnabled).isFalse()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun isEdgeToEdgeEnabled_withDisabledViaProperty_returnsFalse() {
|
||||
val project = createProject()
|
||||
project.extensions.extraProperties.set("edgeToEdgeEnabled", "false")
|
||||
assertThat(project.isEdgeToEdgeEnabled).isFalse()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun isEdgeToEdgeEnabled_withEnabledViaProperty_returnsTrue() {
|
||||
val project = createProject()
|
||||
project.extensions.extraProperties.set("edgeToEdgeEnabled", "true")
|
||||
assertThat(project.isEdgeToEdgeEnabled).isTrue()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun isEdgeToEdgeEnabled_withInvalidViaProperty_returnsFalse() {
|
||||
val project = createProject()
|
||||
project.extensions.extraProperties.set("edgeToEdgeEnabled", "¯\\_(ツ)_/¯")
|
||||
assertThat(project.isEdgeToEdgeEnabled).isFalse()
|
||||
}
|
||||
|
||||
@Test
|
||||
fun needsCodegenFromPackageJson_withCodegenConfigInPackageJson_returnsTrue() {
|
||||
val project = createProject()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/metro-config",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Metro configuration for React Native.",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -26,8 +26,8 @@
|
||||
"dist"
|
||||
],
|
||||
"dependencies": {
|
||||
"@react-native/js-polyfills": "0.81.0-main",
|
||||
"@react-native/metro-babel-transformer": "0.81.0-main",
|
||||
"@react-native/js-polyfills": "0.80.0-main",
|
||||
"@react-native/metro-babel-transformer": "0.80.0-main",
|
||||
"metro-config": "^0.82.4",
|
||||
"metro-runtime": "^0.82.4"
|
||||
}
|
||||
|
||||
@@ -43,7 +43,7 @@ const INTERNAL_CALLSITES_REGEX = new RegExp(
|
||||
|
||||
export {mergeConfig} from 'metro-config';
|
||||
|
||||
let frameworkDefaults: InputConfigT = {};
|
||||
let frameworkDefaults = {};
|
||||
export function setFrameworkDefaults(config: InputConfigT) {
|
||||
frameworkDefaults = config;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/new-app-screen",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "NewAppScreen component for React Native",
|
||||
"keywords": [
|
||||
"react-native"
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/normalize-colors",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Color normalization for React Native.",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
@@ -0,0 +1,277 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
const LOG_LEVELS = {
|
||||
trace: 0,
|
||||
info: 1,
|
||||
warn: 2,
|
||||
error: 3,
|
||||
};
|
||||
|
||||
describe('console', () => {
|
||||
describe('.table(data, rows)', () => {
|
||||
let originalNativeLoggingHook;
|
||||
let logFn;
|
||||
|
||||
beforeEach(() => {
|
||||
originalNativeLoggingHook = global.nativeLoggingHook;
|
||||
logFn = global.nativeLoggingHook = jest.fn();
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
global.nativeLoggingHook = originalNativeLoggingHook;
|
||||
});
|
||||
|
||||
it('should print the passed array as a Markdown table', () => {
|
||||
console.table([
|
||||
{name: 'First', value: 500},
|
||||
{name: 'Second', value: 600},
|
||||
{name: 'Third', value: 700},
|
||||
{name: 'Fourth', value: 800, extraValue: true},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | extraValue |
|
||||
| ------- | -------- | ----- | ---------- |
|
||||
| 0 | 'First' | 500 | |
|
||||
| 1 | 'Second' | 600 | |
|
||||
| 2 | 'Third' | 700 | |
|
||||
| 3 | 'Fourth' | 800 | true |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print the passed dictionary as a Markdown table', () => {
|
||||
console.table({
|
||||
first: {name: 'First', value: 500},
|
||||
second: {name: 'Second', value: 600},
|
||||
third: {name: 'Third', value: 700},
|
||||
fourth: {name: 'Fourth', value: 800, extraValue: true},
|
||||
});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | extraValue |
|
||||
| ------- | -------- | ----- | ---------- |
|
||||
| first | 'First' | 500 | |
|
||||
| second | 'Second' | 600 | |
|
||||
| third | 'Third' | 700 | |
|
||||
| fourth | 'Fourth' | 800 | true |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should work with different types of values', () => {
|
||||
console.table([
|
||||
{
|
||||
string: '',
|
||||
number: 0,
|
||||
boolean: true,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'a',
|
||||
number: 1,
|
||||
boolean: true,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'aa',
|
||||
number: 2,
|
||||
boolean: false,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'aaa',
|
||||
number: 3,
|
||||
boolean: false,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | string | number | boolean | function | object | null | undefined |
|
||||
| ------- | ------ | ------ | ------- | -------- | ------ | ---- | --------- |
|
||||
| 0 | '' | 0 | true | ƒ | {…} | null | undefined |
|
||||
| 1 | 'a' | 1 | true | ƒ | {…} | null | undefined |
|
||||
| 2 | 'aa' | 2 | false | ƒ | {…} | null | undefined |
|
||||
| 3 | 'aaa' | 3 | false | ƒ | {…} | null | undefined |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print the keys in all the objects', () => {
|
||||
console.table([
|
||||
{name: 'foo'},
|
||||
{name: 'bar', value: 1},
|
||||
{value: 2, surname: 'baz'},
|
||||
{address: 'other'},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | surname | address |
|
||||
| ------- | ----- | ----- | ------- | ------- |
|
||||
| 0 | 'foo' | | | |
|
||||
| 1 | 'bar' | 1 | | |
|
||||
| 2 | | 2 | 'baz' | |
|
||||
| 3 | | | | 'other' |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print an empty string for empty arrays', () => {
|
||||
console.table([]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([``, LOG_LEVELS.info]);
|
||||
});
|
||||
|
||||
it('should print an empty string for empty dictionaries', () => {
|
||||
console.table({});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([``, LOG_LEVELS.info]);
|
||||
});
|
||||
|
||||
// This test is currently failing
|
||||
it('should print an indices table for an array of empty objects', () => {
|
||||
console.table([{}, {}, {}, {}]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) |
|
||||
| ------- |
|
||||
| 0 |
|
||||
| 1 |
|
||||
| 2 |
|
||||
| 3 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print an indices table for a dictionary of empty objects', () => {
|
||||
console.table({
|
||||
first: {},
|
||||
second: {},
|
||||
third: {},
|
||||
fourth: {},
|
||||
});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) |
|
||||
| ------- |
|
||||
| first |
|
||||
| second |
|
||||
| third |
|
||||
| fourth |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should not modify the logged value', () => {
|
||||
global.nativeLoggingHook = jest.fn();
|
||||
|
||||
const array = [
|
||||
{name: 'First', value: 500},
|
||||
{name: 'Second', value: 600},
|
||||
{name: 'Third', value: 700},
|
||||
{name: 'Fourth', value: 800, extraValue: true},
|
||||
];
|
||||
const originalArrayValue = JSON.parse(JSON.stringify(array));
|
||||
|
||||
console.table(array);
|
||||
|
||||
expect(array).toEqual(originalArrayValue);
|
||||
|
||||
const object = {
|
||||
first: {name: 'First', value: 500},
|
||||
second: {name: 'Second', value: 600},
|
||||
third: {name: 'Third', value: 700},
|
||||
fourth: {name: 'Fourth', value: 800, extraValue: true},
|
||||
};
|
||||
|
||||
const originalObjectValue = JSON.parse(JSON.stringify(object));
|
||||
|
||||
console.table(object);
|
||||
|
||||
expect(object).toEqual(originalObjectValue);
|
||||
});
|
||||
|
||||
it('should only print the selected columns, if specified (arrays)', () => {
|
||||
console.table(
|
||||
[
|
||||
{first: 1, second: 2, third: 3},
|
||||
{first: 4, second: 5},
|
||||
{third: 7, fourth: 8},
|
||||
{fifth: 9},
|
||||
],
|
||||
// $FlowExpectedError[extra-arg]
|
||||
['first', 'fifth'],
|
||||
);
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | first | fifth |
|
||||
| ------- | ----- | ----- |
|
||||
| 0 | 1 | |
|
||||
| 1 | 4 | |
|
||||
| 2 | | |
|
||||
| 3 | | 9 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should only print the selected columns, if specified (dictionaries)', () => {
|
||||
console.table(
|
||||
{
|
||||
a: {first: 1, second: 2, third: 3},
|
||||
b: {first: 4, second: 5},
|
||||
c: {third: 7, fourth: 8},
|
||||
d: {fifth: 9},
|
||||
},
|
||||
// $FlowExpectedError[extra-arg]
|
||||
['first', 'fifth'],
|
||||
);
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | first | fifth |
|
||||
| ------- | ----- | ----- |
|
||||
| a | 1 | |
|
||||
| b | 4 | |
|
||||
| c | | |
|
||||
| d | | 9 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -1,275 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
const LOG_LEVELS = {
|
||||
trace: 0,
|
||||
info: 1,
|
||||
warn: 2,
|
||||
error: 3,
|
||||
};
|
||||
|
||||
describe('console.table(data, rows)', () => {
|
||||
let originalNativeLoggingHook;
|
||||
let logFn;
|
||||
|
||||
beforeEach(() => {
|
||||
originalNativeLoggingHook = global.nativeLoggingHook;
|
||||
logFn = global.nativeLoggingHook = jest.fn();
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
global.nativeLoggingHook = originalNativeLoggingHook;
|
||||
});
|
||||
|
||||
it('should print the passed array as a Markdown table', () => {
|
||||
console.table([
|
||||
{name: 'First', value: 500},
|
||||
{name: 'Second', value: 600},
|
||||
{name: 'Third', value: 700},
|
||||
{name: 'Fourth', value: 800, extraValue: true},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | extraValue |
|
||||
| ------- | -------- | ----- | ---------- |
|
||||
| 0 | 'First' | 500 | |
|
||||
| 1 | 'Second' | 600 | |
|
||||
| 2 | 'Third' | 700 | |
|
||||
| 3 | 'Fourth' | 800 | true |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print the passed dictionary as a Markdown table', () => {
|
||||
console.table({
|
||||
first: {name: 'First', value: 500},
|
||||
second: {name: 'Second', value: 600},
|
||||
third: {name: 'Third', value: 700},
|
||||
fourth: {name: 'Fourth', value: 800, extraValue: true},
|
||||
});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | extraValue |
|
||||
| ------- | -------- | ----- | ---------- |
|
||||
| first | 'First' | 500 | |
|
||||
| second | 'Second' | 600 | |
|
||||
| third | 'Third' | 700 | |
|
||||
| fourth | 'Fourth' | 800 | true |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should work with different types of values', () => {
|
||||
console.table([
|
||||
{
|
||||
string: '',
|
||||
number: 0,
|
||||
boolean: true,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'a',
|
||||
number: 1,
|
||||
boolean: true,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'aa',
|
||||
number: 2,
|
||||
boolean: false,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
{
|
||||
string: 'aaa',
|
||||
number: 3,
|
||||
boolean: false,
|
||||
function: () => {},
|
||||
object: {a: 1, b: 2},
|
||||
null: null,
|
||||
undefined: undefined,
|
||||
},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | string | number | boolean | function | object | null | undefined |
|
||||
| ------- | ------ | ------ | ------- | -------- | ------ | ---- | --------- |
|
||||
| 0 | '' | 0 | true | ƒ | {…} | null | undefined |
|
||||
| 1 | 'a' | 1 | true | ƒ | {…} | null | undefined |
|
||||
| 2 | 'aa' | 2 | false | ƒ | {…} | null | undefined |
|
||||
| 3 | 'aaa' | 3 | false | ƒ | {…} | null | undefined |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print the keys in all the objects', () => {
|
||||
console.table([
|
||||
{name: 'foo'},
|
||||
{name: 'bar', value: 1},
|
||||
{value: 2, surname: 'baz'},
|
||||
{address: 'other'},
|
||||
]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | name | value | surname | address |
|
||||
| ------- | ----- | ----- | ------- | ------- |
|
||||
| 0 | 'foo' | | | |
|
||||
| 1 | 'bar' | 1 | | |
|
||||
| 2 | | 2 | 'baz' | |
|
||||
| 3 | | | | 'other' |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print an empty string for empty arrays', () => {
|
||||
console.table([]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([``, LOG_LEVELS.info]);
|
||||
});
|
||||
|
||||
it('should print an empty string for empty dictionaries', () => {
|
||||
console.table({});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([``, LOG_LEVELS.info]);
|
||||
});
|
||||
|
||||
// This test is currently failing
|
||||
it('should print an indices table for an array of empty objects', () => {
|
||||
console.table([{}, {}, {}, {}]);
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) |
|
||||
| ------- |
|
||||
| 0 |
|
||||
| 1 |
|
||||
| 2 |
|
||||
| 3 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should print an indices table for a dictionary of empty objects', () => {
|
||||
console.table({
|
||||
first: {},
|
||||
second: {},
|
||||
third: {},
|
||||
fourth: {},
|
||||
});
|
||||
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) |
|
||||
| ------- |
|
||||
| first |
|
||||
| second |
|
||||
| third |
|
||||
| fourth |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should not modify the logged value', () => {
|
||||
global.nativeLoggingHook = jest.fn();
|
||||
|
||||
const array = [
|
||||
{name: 'First', value: 500},
|
||||
{name: 'Second', value: 600},
|
||||
{name: 'Third', value: 700},
|
||||
{name: 'Fourth', value: 800, extraValue: true},
|
||||
];
|
||||
const originalArrayValue = JSON.parse(JSON.stringify(array));
|
||||
|
||||
console.table(array);
|
||||
|
||||
expect(array).toEqual(originalArrayValue);
|
||||
|
||||
const object = {
|
||||
first: {name: 'First', value: 500},
|
||||
second: {name: 'Second', value: 600},
|
||||
third: {name: 'Third', value: 700},
|
||||
fourth: {name: 'Fourth', value: 800, extraValue: true},
|
||||
};
|
||||
|
||||
const originalObjectValue = JSON.parse(JSON.stringify(object));
|
||||
|
||||
console.table(object);
|
||||
|
||||
expect(object).toEqual(originalObjectValue);
|
||||
});
|
||||
|
||||
it('should only print the selected columns, if specified (arrays)', () => {
|
||||
console.table(
|
||||
[
|
||||
{first: 1, second: 2, third: 3},
|
||||
{first: 4, second: 5},
|
||||
{third: 7, fourth: 8},
|
||||
{fifth: 9},
|
||||
],
|
||||
// $FlowExpectedError[extra-arg]
|
||||
['first', 'fifth'],
|
||||
);
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | first | fifth |
|
||||
| ------- | ----- | ----- |
|
||||
| 0 | 1 | |
|
||||
| 1 | 4 | |
|
||||
| 2 | | |
|
||||
| 3 | | 9 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
|
||||
it('should only print the selected columns, if specified (dictionaries)', () => {
|
||||
console.table(
|
||||
{
|
||||
a: {first: 1, second: 2, third: 3},
|
||||
b: {first: 4, second: 5},
|
||||
c: {third: 7, fourth: 8},
|
||||
d: {fifth: 9},
|
||||
},
|
||||
// $FlowExpectedError[extra-arg]
|
||||
['first', 'fifth'],
|
||||
);
|
||||
expect(logFn).toHaveBeenCalledTimes(1);
|
||||
expect(logFn.mock.lastCall).toEqual([
|
||||
`
|
||||
| (index) | first | fifth |
|
||||
| ------- | ----- | ----- |
|
||||
| a | 1 | |
|
||||
| b | 4 | |
|
||||
| c | | |
|
||||
| d | | 9 |`,
|
||||
LOG_LEVELS.info,
|
||||
]);
|
||||
});
|
||||
});
|
||||
@@ -1,41 +0,0 @@
|
||||
/**
|
||||
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
||||
*
|
||||
* This source code is licensed under the MIT license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
* @fantom_mode *
|
||||
* @fantom_flags fuseboxEnabledRelease:*
|
||||
*/
|
||||
|
||||
describe('console.timeStamp()', () => {
|
||||
it('installed', () => {
|
||||
expect(typeof console.timeStamp).toBe('function');
|
||||
});
|
||||
|
||||
it("doesn't throw when label is not specified", () => {
|
||||
expect(() => console.timeStamp()).not.toThrow();
|
||||
});
|
||||
|
||||
it("doesn't throw when label is specified", () => {
|
||||
expect(() => console.timeStamp('label')).not.toThrow();
|
||||
});
|
||||
|
||||
it("doesn't throw when additional arguments are specified", () => {
|
||||
expect(() =>
|
||||
// $FlowExpectedError[extra-arg]
|
||||
console.timeStamp('label', 100, 500, 'Track', 'Group', 'error'),
|
||||
).not.toThrow();
|
||||
});
|
||||
|
||||
it("doesn't throw when invalid arguments are specified", () => {
|
||||
// $FlowExpectedError[incompatible-call]
|
||||
expect(() => console.timeStamp({})).not.toThrow();
|
||||
expect(() =>
|
||||
// $FlowExpectedError[extra-arg]
|
||||
console.timeStamp('label', true, null, {}, [], () => {}),
|
||||
).not.toThrow();
|
||||
});
|
||||
});
|
||||
@@ -569,11 +569,6 @@ function consoleAssertPolyfill(expression, label) {
|
||||
}
|
||||
}
|
||||
|
||||
// https://developer.mozilla.org/en-US/docs/Web/API/console/timeStamp_static.
|
||||
// Non-standard API for recording markers on a timeline of the Performance instrumentation.
|
||||
// The actual logging is not provided by definition.
|
||||
function consoleTimeStampPolyfill() {}
|
||||
|
||||
if (global.nativeLoggingHook) {
|
||||
const originalConsole = global.console;
|
||||
// Preserve the original `console` as `originalConsole`
|
||||
@@ -585,7 +580,6 @@ if (global.nativeLoggingHook) {
|
||||
}
|
||||
|
||||
global.console = {
|
||||
timeStamp: consoleTimeStampPolyfill,
|
||||
...(originalConsole ?? {}),
|
||||
error: getNativeLogFunction(LOG_LEVELS.error),
|
||||
info: getNativeLogFunction(LOG_LEVELS.info),
|
||||
@@ -700,7 +694,6 @@ if (global.nativeLoggingHook) {
|
||||
profile: stub,
|
||||
profileEnd: stub,
|
||||
table: stub,
|
||||
timeStamp: stub,
|
||||
};
|
||||
|
||||
Object.defineProperty(console, '_isPolyfilled', {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/js-polyfills",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Polyfills for React Native.",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/babel-preset",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Babel preset for React Native applications",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -66,8 +66,8 @@
|
||||
"@babel/plugin-transform-typescript": "^7.25.2",
|
||||
"@babel/plugin-transform-unicode-regex": "^7.24.7",
|
||||
"@babel/template": "^7.25.0",
|
||||
"@react-native/babel-plugin-codegen": "0.81.0-main",
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.1",
|
||||
"@react-native/babel-plugin-codegen": "0.80.0-main",
|
||||
"babel-plugin-syntax-hermes-parser": "0.29.0",
|
||||
"babel-plugin-transform-flow-enums": "^0.0.2",
|
||||
"react-refresh": "^0.14.0"
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/metro-babel-transformer",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Babel transformer for React Native applications.",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -27,8 +27,8 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"@babel/core": "^7.25.2",
|
||||
"@react-native/babel-preset": "0.81.0-main",
|
||||
"hermes-parser": "0.29.1",
|
||||
"@react-native/babel-preset": "0.80.0-main",
|
||||
"hermes-parser": "0.29.0",
|
||||
"nullthrows": "^1.1.1"
|
||||
},
|
||||
"peerDependencies": {
|
||||
|
||||
+10
-136
@@ -40,10 +40,6 @@ ArrayPropsNativeComponentViewProps::ArrayPropsNativeComponentViewProps(
|
||||
arrayOfMixed(convertRawProp(context, rawProps, \\"arrayOfMixed\\", sourceProps.arrayOfMixed, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ArrayPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ArrayPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ArrayPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ArrayPropsNativeComponentViewProps();
|
||||
@@ -55,57 +51,18 @@ folly::dynamic ArrayPropsNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (names != oldProps->names) {
|
||||
result[\\"names\\"] = toDynamic(names);
|
||||
}
|
||||
|
||||
if (disableds != oldProps->disableds) {
|
||||
result[\\"disableds\\"] = toDynamic(disableds);
|
||||
}
|
||||
|
||||
if (progress != oldProps->progress) {
|
||||
result[\\"progress\\"] = toDynamic(progress);
|
||||
}
|
||||
|
||||
if (radii != oldProps->radii) {
|
||||
result[\\"radii\\"] = toDynamic(radii);
|
||||
}
|
||||
|
||||
if (colors != oldProps->colors) {
|
||||
result[\\"colors\\"] = toDynamic(colors);
|
||||
}
|
||||
|
||||
if (srcs != oldProps->srcs) {
|
||||
result[\\"srcs\\"] = toDynamic(srcs);
|
||||
}
|
||||
|
||||
if (points != oldProps->points) {
|
||||
result[\\"points\\"] = toDynamic(points);
|
||||
}
|
||||
|
||||
if (edgeInsets != oldProps->edgeInsets) {
|
||||
result[\\"edgeInsets\\"] = toDynamic(edgeInsets);
|
||||
}
|
||||
|
||||
if (dimensions != oldProps->dimensions) {
|
||||
result[\\"dimensions\\"] = toDynamic(dimensions);
|
||||
}
|
||||
|
||||
if (sizes != oldProps->sizes) {
|
||||
result[\\"sizes\\"] = toDynamic(sizes);
|
||||
}
|
||||
|
||||
if (object != oldProps->object) {
|
||||
result[\\"object\\"] = toDynamic(object);
|
||||
}
|
||||
|
||||
if (arrayOfObjects != oldProps->arrayOfObjects) {
|
||||
result[\\"arrayOfObjects\\"] = toDynamic(arrayOfObjects);
|
||||
}
|
||||
|
||||
if (arrayOfMixed != oldProps->arrayOfMixed) {
|
||||
result[\\"arrayOfMixed\\"] = toDynamic(arrayOfMixed);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -142,10 +99,6 @@ BooleanPropNativeComponentViewProps::BooleanPropNativeComponentViewProps(
|
||||
disabledNullable(convertRawProp(context, rawProps, \\"disabledNullable\\", sourceProps.disabledNullable, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName BooleanPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"BooleanPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic BooleanPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = BooleanPropNativeComponentViewProps();
|
||||
@@ -199,10 +152,6 @@ ColorPropNativeComponentViewProps::ColorPropNativeComponentViewProps(
|
||||
tintColor(convertRawProp(context, rawProps, \\"tintColor\\", sourceProps.tintColor, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ColorPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ColorPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ColorPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ColorPropNativeComponentViewProps();
|
||||
@@ -253,10 +202,6 @@ DimensionPropNativeComponentViewProps::DimensionPropNativeComponentViewProps(
|
||||
marginBack(convertRawProp(context, rawProps, \\"marginBack\\", sourceProps.marginBack, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName DimensionPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"DimensionPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic DimensionPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = DimensionPropNativeComponentViewProps();
|
||||
@@ -268,9 +213,6 @@ folly::dynamic DimensionPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (marginBack != oldProps->marginBack) {
|
||||
result[\\"marginBack\\"] = toDynamic(marginBack);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -306,10 +248,6 @@ EdgeInsetsPropNativeComponentViewProps::EdgeInsetsPropNativeComponentViewProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EdgeInsetsPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EdgeInsetsPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EdgeInsetsPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EdgeInsetsPropNativeComponentViewProps();
|
||||
@@ -357,10 +295,6 @@ EnumPropNativeComponentViewProps::EnumPropNativeComponentViewProps(
|
||||
intervals(convertRawProp(context, rawProps, \\"intervals\\", sourceProps.intervals, {EnumPropNativeComponentViewIntervals::Intervals0})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EnumPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EnumPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EnumPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EnumPropNativeComponentViewProps();
|
||||
@@ -372,13 +306,7 @@ folly::dynamic EnumPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (alignment != oldProps->alignment) {
|
||||
result[\\"alignment\\"] = toDynamic(alignment);
|
||||
}
|
||||
|
||||
if (intervals != oldProps->intervals) {
|
||||
result[\\"intervals\\"] = toDynamic(intervals);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -414,10 +342,6 @@ EventNestedObjectPropsNativeComponentViewProps::EventNestedObjectPropsNativeComp
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventNestedObjectPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventNestedObjectPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventNestedObjectPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventNestedObjectPropsNativeComponentViewProps();
|
||||
@@ -467,10 +391,6 @@ EventPropsNativeComponentViewProps::EventPropsNativeComponentViewProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventPropsNativeComponentViewProps();
|
||||
@@ -526,10 +446,6 @@ FloatPropsNativeComponentViewProps::FloatPropsNativeComponentViewProps(
|
||||
blurRadiusNullable(convertRawProp(context, rawProps, \\"blurRadiusNullable\\", sourceProps.blurRadiusNullable, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName FloatPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"FloatPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic FloatPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = FloatPropsNativeComponentViewProps();
|
||||
@@ -604,10 +520,6 @@ ImagePropNativeComponentViewProps::ImagePropNativeComponentViewProps(
|
||||
thumbImage(convertRawProp(context, rawProps, \\"thumbImage\\", sourceProps.thumbImage, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ImagePropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ImagePropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ImagePropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ImagePropNativeComponentViewProps();
|
||||
@@ -620,7 +532,7 @@ folly::dynamic ImagePropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -659,10 +571,6 @@ IntegerPropNativeComponentViewProps::IntegerPropNativeComponentViewProps(
|
||||
progress3(convertRawProp(context, rawProps, \\"progress3\\", sourceProps.progress3, {10})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName IntegerPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"IntegerPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic IntegerPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = IntegerPropNativeComponentViewProps();
|
||||
@@ -720,10 +628,6 @@ InterfaceOnlyNativeComponentViewProps::InterfaceOnlyNativeComponentViewProps(
|
||||
title(convertRawProp(context, rawProps, \\"title\\", sourceProps.title, {\\"\\"})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName InterfaceOnlyNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"InterfaceOnlyNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic InterfaceOnlyNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = InterfaceOnlyNativeComponentViewProps();
|
||||
@@ -774,10 +678,6 @@ MixedPropNativeComponentViewProps::MixedPropNativeComponentViewProps(
|
||||
mixedProp(convertRawProp(context, rawProps, \\"mixedProp\\", sourceProps.mixedProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MixedPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MixedPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic MixedPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MixedPropNativeComponentViewProps();
|
||||
@@ -789,9 +689,6 @@ folly::dynamic MixedPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (mixedProp != oldProps->mixedProp) {
|
||||
result[\\"mixedProp\\"] = mixedProp;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -831,10 +728,6 @@ MultiNativePropNativeComponentViewProps::MultiNativePropNativeComponentViewProps
|
||||
point(convertRawProp(context, rawProps, \\"point\\", sourceProps.point, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiNativePropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiNativePropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiNativePropNativeComponentViewProps();
|
||||
@@ -847,7 +740,7 @@ folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
|
||||
if (color != oldProps->color) {
|
||||
@@ -859,7 +752,10 @@ folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
|
||||
if (point != oldProps->point) {
|
||||
result[\\"point\\"] = toDynamic(point);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = point.x;
|
||||
pointResult[\\"y\\"] = point.y;
|
||||
result[\\"point\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -896,10 +792,6 @@ NoPropsNoEventsNativeComponentViewProps::NoPropsNoEventsNativeComponentViewProps
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName NoPropsNoEventsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"NoPropsNoEventsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic NoPropsNoEventsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = NoPropsNoEventsNativeComponentViewProps();
|
||||
@@ -949,10 +841,6 @@ ObjectPropsNativeComponentProps::ObjectPropsNativeComponentProps(
|
||||
objectPrimitiveRequiredProp(convertRawProp(context, rawProps, \\"objectPrimitiveRequiredProp\\", sourceProps.objectPrimitiveRequiredProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ObjectPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ObjectPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ObjectPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ObjectPropsNativeComponentProps();
|
||||
@@ -964,17 +852,8 @@ folly::dynamic ObjectPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (objectProp != oldProps->objectProp) {
|
||||
result[\\"objectProp\\"] = toDynamic(objectProp);
|
||||
}
|
||||
|
||||
if (objectArrayProp != oldProps->objectArrayProp) {
|
||||
result[\\"objectArrayProp\\"] = toDynamic(objectArrayProp);
|
||||
}
|
||||
|
||||
if (objectPrimitiveRequiredProp != oldProps->objectPrimitiveRequiredProp) {
|
||||
result[\\"objectPrimitiveRequiredProp\\"] = toDynamic(objectPrimitiveRequiredProp);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1010,10 +889,6 @@ PointPropNativeComponentViewProps::PointPropNativeComponentViewProps(
|
||||
startPoint(convertRawProp(context, rawProps, \\"startPoint\\", sourceProps.startPoint, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName PointPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"PointPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic PointPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = PointPropNativeComponentViewProps();
|
||||
@@ -1026,7 +901,10 @@ folly::dynamic PointPropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (startPoint != oldProps->startPoint) {
|
||||
result[\\"startPoint\\"] = toDynamic(startPoint);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = startPoint.x;
|
||||
pointResult[\\"y\\"] = startPoint.y;
|
||||
result[\\"startPoint\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1064,10 +942,6 @@ StringPropNativeComponentViewProps::StringPropNativeComponentViewProps(
|
||||
defaultValue(convertRawProp(context, rawProps, \\"defaultValue\\", sourceProps.defaultValue, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName StringPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"StringPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic StringPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = StringPropNativeComponentViewProps();
|
||||
|
||||
-158
@@ -16,7 +16,6 @@ Object {
|
||||
#include <cinttypes>
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <react/renderer/core/propsConversions.h>
|
||||
#include <react/renderer/graphics/Color.h>
|
||||
#include <react/renderer/graphics/Point.h>
|
||||
@@ -88,16 +87,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewSizesMaskW
|
||||
}
|
||||
struct ArrayPropsNativeComponentViewObjectStruct {
|
||||
std::string prop{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentViewObjectStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"prop\\"] = prop;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentViewObjectStruct &result) {
|
||||
@@ -113,12 +102,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewObjectStru
|
||||
return \\"[Object ArrayPropsNativeComponentViewObjectStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentViewObjectStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentViewObjectStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -132,17 +115,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
struct ArrayPropsNativeComponentViewArrayOfObjectsStruct {
|
||||
Float prop1{0.0};
|
||||
int prop2{0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentViewArrayOfObjectsStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"prop1\\"] = prop1;
|
||||
result[\\"prop2\\"] = prop2;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentViewArrayOfObjectsStruct &result) {
|
||||
@@ -162,12 +134,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewArrayOfObj
|
||||
return \\"[Object ArrayPropsNativeComponentViewArrayOfObjectsStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentViewArrayOfObjectsStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentViewArrayOfObjectsStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -199,8 +165,6 @@ class ArrayPropsNativeComponentViewProps final : public ViewProps {
|
||||
std::vector<folly::dynamic> arrayOfMixed{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -239,8 +203,6 @@ class BooleanPropNativeComponentViewProps final : public ViewProps {
|
||||
bool disabledNullable{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -279,8 +241,6 @@ class ColorPropNativeComponentViewProps final : public ViewProps {
|
||||
SharedColor tintColor{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -305,7 +265,6 @@ Object {
|
||||
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <yoga/Yoga.h>
|
||||
|
||||
namespace facebook::react {
|
||||
@@ -320,8 +279,6 @@ class DimensionPropNativeComponentViewProps final : public ViewProps {
|
||||
YGValue marginBack{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -359,8 +316,6 @@ class EdgeInsetsPropNativeComponentViewProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -405,12 +360,6 @@ static inline std::string toString(const EnumPropNativeComponentViewAlignment &v
|
||||
case EnumPropNativeComponentViewAlignment::BottomRight: return \\"bottom-right\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const EnumPropNativeComponentViewAlignment &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
enum class EnumPropNativeComponentViewIntervals { Intervals0 = 0, Intervals15 = 15, Intervals30 = 30, Intervals60 = 60 };
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, EnumPropNativeComponentViewIntervals &result) {
|
||||
@@ -442,17 +391,6 @@ static inline std::string toString(const EnumPropNativeComponentViewIntervals &v
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const EnumPropNativeComponentViewIntervals &value) {
|
||||
switch (value) {
|
||||
case EnumPropNativeComponentViewIntervals::Intervals0: return 0;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals15: return 15;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals30: return 30;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals60: return 60;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
class EnumPropNativeComponentViewProps final : public ViewProps {
|
||||
public:
|
||||
EnumPropNativeComponentViewProps() = default;
|
||||
@@ -464,8 +402,6 @@ class EnumPropNativeComponentViewProps final : public ViewProps {
|
||||
EnumPropNativeComponentViewIntervals intervals{EnumPropNativeComponentViewIntervals::Intervals0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -503,8 +439,6 @@ class EventNestedObjectPropsNativeComponentViewProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -542,8 +476,6 @@ class EventPropsNativeComponentViewProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -587,8 +519,6 @@ class FloatPropsNativeComponentViewProps final : public ViewProps {
|
||||
Float blurRadiusNullable{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -627,8 +557,6 @@ class ImagePropNativeComponentViewProps final : public ViewProps {
|
||||
ImageSource thumbImage{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -668,8 +596,6 @@ class IntegerPropNativeComponentViewProps final : public ViewProps {
|
||||
int progress3{10};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -707,8 +633,6 @@ class InterfaceOnlyNativeComponentViewProps final : public ViewProps {
|
||||
std::string title{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -746,8 +670,6 @@ class MixedPropNativeComponentViewProps final : public ViewProps {
|
||||
folly::dynamic mixedProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -791,8 +713,6 @@ class MultiNativePropNativeComponentViewProps final : public ViewProps {
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -830,8 +750,6 @@ class NoPropsNoEventsNativeComponentViewProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -880,12 +798,6 @@ static inline std::string toString(const ObjectPropsNativeComponentStringEnumPro
|
||||
case ObjectPropsNativeComponentStringEnumProp::Large: return \\"large\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentStringEnumProp &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
enum class ObjectPropsNativeComponentIntEnumProp { IntEnumProp0 = 0, IntEnumProp1 = 1 };
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentIntEnumProp &result) {
|
||||
@@ -908,15 +820,6 @@ static inline std::string toString(const ObjectPropsNativeComponentIntEnumProp &
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp1: return \\"1\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentIntEnumProp &value) {
|
||||
switch (value) {
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp0: return 0;
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp1: return 1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
struct ObjectPropsNativeComponentObjectPropStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
bool booleanProp{false};
|
||||
@@ -924,21 +827,6 @@ struct ObjectPropsNativeComponentObjectPropStruct {
|
||||
int intProp{0};
|
||||
ObjectPropsNativeComponentStringEnumProp stringEnumProp{ObjectPropsNativeComponentStringEnumProp::Small};
|
||||
ObjectPropsNativeComponentIntEnumProp intEnumProp{ObjectPropsNativeComponentIntEnumProp::IntEnumProp0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
result[\\"booleanProp\\"] = booleanProp;
|
||||
result[\\"floatProp\\"] = floatProp;
|
||||
result[\\"intProp\\"] = intProp;
|
||||
result[\\"stringEnumProp\\"] = ::facebook::react::toDynamic(stringEnumProp);
|
||||
result[\\"intEnumProp\\"] = ::facebook::react::toDynamic(intEnumProp);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectPropStruct &result) {
|
||||
@@ -974,24 +862,8 @@ static inline std::string toString(const ObjectPropsNativeComponentObjectPropStr
|
||||
return \\"[Object ObjectPropsNativeComponentObjectPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsNativeComponentObjectArrayPropStruct {
|
||||
std::vector<std::string> array{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectArrayPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"array\\"] = ::facebook::react::toDynamic(array);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectArrayPropStruct &result) {
|
||||
@@ -1007,28 +879,10 @@ static inline std::string toString(const ObjectPropsNativeComponentObjectArrayPr
|
||||
return \\"[Object ObjectPropsNativeComponentObjectArrayPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectArrayPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct {
|
||||
ImageSource image{};
|
||||
SharedColor color{};
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"image\\"] = ::facebook::react::toDynamic(image);
|
||||
result[\\"color\\"] = ::facebook::react::toDynamic(color);
|
||||
result[\\"point\\"] = ::facebook::react::toDynamic(point);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &result) {
|
||||
@@ -1051,12 +905,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
static inline std::string toString(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &value) {
|
||||
return \\"[Object ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
class ObjectPropsNativeComponentProps final : public ViewProps {
|
||||
public:
|
||||
ObjectPropsNativeComponentProps() = default;
|
||||
@@ -1069,8 +917,6 @@ class ObjectPropsNativeComponentProps final : public ViewProps {
|
||||
ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct objectPrimitiveRequiredProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1109,8 +955,6 @@ class PointPropNativeComponentViewProps final : public ViewProps {
|
||||
Point startPoint{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1149,8 +993,6 @@ class StringPropNativeComponentViewProps final : public ViewProps {
|
||||
std::string defaultValue{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
|
||||
+110
-98
@@ -2,7 +2,7 @@
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ArrayPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -11,26 +11,27 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ArrayPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setNames(view: T, value: ReadableArray?): Unit
|
||||
public fun setDisableds(view: T, value: ReadableArray?): Unit
|
||||
public fun setProgress(view: T, value: ReadableArray?): Unit
|
||||
public fun setRadii(view: T, value: ReadableArray?): Unit
|
||||
public fun setColors(view: T, value: ReadableArray?): Unit
|
||||
public fun setSrcs(view: T, value: ReadableArray?): Unit
|
||||
public fun setPoints(view: T, value: ReadableArray?): Unit
|
||||
public fun setEdgeInsets(view: T, value: ReadableArray?): Unit
|
||||
public fun setDimensions(view: T, value: ReadableArray?): Unit
|
||||
public fun setSizes(view: T, value: ReadableArray?): Unit
|
||||
public fun setObject(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfObjects(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfMixed(view: T, value: ReadableArray?): Unit
|
||||
public interface ArrayPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setNames(T view, @Nullable ReadableArray value);
|
||||
void setDisableds(T view, @Nullable ReadableArray value);
|
||||
void setProgress(T view, @Nullable ReadableArray value);
|
||||
void setRadii(T view, @Nullable ReadableArray value);
|
||||
void setColors(T view, @Nullable ReadableArray value);
|
||||
void setSrcs(T view, @Nullable ReadableArray value);
|
||||
void setPoints(T view, @Nullable ReadableArray value);
|
||||
void setEdgeInsets(T view, @Nullable ReadableArray value);
|
||||
void setDimensions(T view, @Nullable ReadableArray value);
|
||||
void setSizes(T view, @Nullable ReadableArray value);
|
||||
void setObject(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfObjects(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfMixed(T view, @Nullable ReadableArray value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -38,7 +39,7 @@ public interface ArrayPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'BooleanPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -47,14 +48,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface BooleanPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public fun setDisabledNullable(view: T, value: Boolean?): Unit
|
||||
public interface BooleanPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
void setDisabledNullable(T view, @Nullable Boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -62,7 +64,7 @@ public interface BooleanPropNativeComponentViewManagerInterface<T: View>: ViewMa
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ColorPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -71,13 +73,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ColorPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setTintColor(view: T, value: Int?): Unit
|
||||
public interface ColorPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setTintColor(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -85,7 +88,7 @@ public interface ColorPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'DimensionPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -94,14 +97,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
import com.facebook.yoga.YogaValue;
|
||||
|
||||
public interface DimensionPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMarginBack(view: T, value: YogaValue?): Unit
|
||||
public interface DimensionPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMarginBack(T view, @Nullable YogaValue value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -109,7 +113,7 @@ public interface DimensionPropNativeComponentViewManagerInterface<T: View>: View
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EdgeInsetsPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EdgeInsetsPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EdgeInsetsPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -118,12 +122,12 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EdgeInsetsPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface EdgeInsetsPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -132,7 +136,7 @@ public interface EdgeInsetsPropNativeComponentViewManagerInterface<T: View>: Vie
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EnumPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EnumPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EnumPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -141,14 +145,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EnumPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAlignment(view: T, value: String?): Unit
|
||||
public fun setIntervals(view: T, value: Int?): Unit
|
||||
public interface EnumPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAlignment(T view, @Nullable String value);
|
||||
void setIntervals(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -156,7 +161,7 @@ public interface EnumPropNativeComponentViewManagerInterface<T: View>: ViewManag
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EventNestedObjectPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EventNestedObjectPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EventNestedObjectPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -165,13 +170,13 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -179,7 +184,7 @@ public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EventPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EventPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EventPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -188,13 +193,13 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -202,7 +207,7 @@ public interface EventPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'FloatPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/FloatPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/FloatPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -211,19 +216,20 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface FloatPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setBlurRadius(view: T, value: Float): Unit
|
||||
public fun setBlurRadius2(view: T, value: Float): Unit
|
||||
public fun setBlurRadius3(view: T, value: Float): Unit
|
||||
public fun setBlurRadius4(view: T, value: Float): Unit
|
||||
public fun setBlurRadius5(view: T, value: Float): Unit
|
||||
public fun setBlurRadius6(view: T, value: Float): Unit
|
||||
public fun setBlurRadiusNullable(view: T, value: Float?): Unit
|
||||
public interface FloatPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setBlurRadius(T view, float value);
|
||||
void setBlurRadius2(T view, float value);
|
||||
void setBlurRadius3(T view, float value);
|
||||
void setBlurRadius4(T view, float value);
|
||||
void setBlurRadius5(T view, float value);
|
||||
void setBlurRadius6(T view, float value);
|
||||
void setBlurRadiusNullable(T view, @Nullable Float value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -231,7 +237,7 @@ public interface FloatPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ImagePropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -240,14 +246,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ImagePropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public interface ImagePropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -255,7 +262,7 @@ public interface ImagePropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'IntegerPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -264,15 +271,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface IntegerPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setProgress1(view: T, value: Int): Unit
|
||||
public fun setProgress2(view: T, value: Int): Unit
|
||||
public fun setProgress3(view: T, value: Int): Unit
|
||||
public interface IntegerPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setProgress1(T view, int value);
|
||||
void setProgress2(T view, int value);
|
||||
void setProgress3(T view, int value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -280,7 +287,7 @@ public interface IntegerPropNativeComponentViewManagerInterface<T: View>: ViewMa
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'InterfaceOnlyNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -289,13 +296,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface InterfaceOnlyNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setTitle(view: T, value: String?): Unit
|
||||
public interface InterfaceOnlyNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setTitle(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -303,7 +311,7 @@ public interface InterfaceOnlyNativeComponentViewManagerInterface<T: View>: View
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'MixedPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -312,14 +320,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.bridge.Dynamic;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MixedPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMixedProp(view: T, value: Dynamic): Unit
|
||||
public interface MixedPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMixedProp(T view, Dynamic value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -327,7 +335,7 @@ public interface MixedPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'MultiNativePropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/MultiNativePropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiNativePropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -336,17 +344,18 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiNativePropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public fun setColor(view: T, value: Int?): Unit
|
||||
public fun setThumbTintColor(view: T, value: Int?): Unit
|
||||
public fun setPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface MultiNativePropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
void setColor(T view, @Nullable Integer value);
|
||||
void setThumbTintColor(T view, @Nullable Integer value);
|
||||
void setPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -354,7 +363,7 @@ public interface MultiNativePropNativeComponentViewManagerInterface<T: View>: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'NoPropsNoEventsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -363,12 +372,12 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface NoPropsNoEventsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface NoPropsNoEventsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -377,7 +386,7 @@ public interface NoPropsNoEventsNativeComponentViewManagerInterface<T: View>: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ObjectPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsNativeComponentManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsNativeComponentManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -386,16 +395,17 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ObjectPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setObjectProp(view: T, value: ReadableMap?): Unit
|
||||
public fun setObjectArrayProp(view: T, value: ReadableMap?): Unit
|
||||
public fun setObjectPrimitiveRequiredProp(view: T, value: ReadableMap?): Unit
|
||||
public interface ObjectPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setObjectProp(T view, @Nullable ReadableMap value);
|
||||
void setObjectArrayProp(T view, @Nullable ReadableMap value);
|
||||
void setObjectPrimitiveRequiredProp(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -403,7 +413,7 @@ public interface ObjectPropsNativeComponentManagerInterface<T: View>: ViewManage
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'PointPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -412,14 +422,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface PointPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setStartPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface PointPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setStartPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -427,7 +438,7 @@ public interface PointPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'StringPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/StringPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/StringPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -436,14 +447,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface StringPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setPlaceholder(view: T, value: String?): Unit
|
||||
public fun setDefaultValue(view: T, value: String?): Unit
|
||||
public interface StringPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setPlaceholder(T view, @Nullable String value);
|
||||
void setDefaultValue(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
|
||||
+10
-136
@@ -40,10 +40,6 @@ ArrayPropsNativeComponentViewProps::ArrayPropsNativeComponentViewProps(
|
||||
arrayOfMixed(convertRawProp(context, rawProps, \\"arrayOfMixed\\", sourceProps.arrayOfMixed, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ArrayPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ArrayPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ArrayPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ArrayPropsNativeComponentViewProps();
|
||||
@@ -55,57 +51,18 @@ folly::dynamic ArrayPropsNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (names != oldProps->names) {
|
||||
result[\\"names\\"] = toDynamic(names);
|
||||
}
|
||||
|
||||
if (disableds != oldProps->disableds) {
|
||||
result[\\"disableds\\"] = toDynamic(disableds);
|
||||
}
|
||||
|
||||
if (progress != oldProps->progress) {
|
||||
result[\\"progress\\"] = toDynamic(progress);
|
||||
}
|
||||
|
||||
if (radii != oldProps->radii) {
|
||||
result[\\"radii\\"] = toDynamic(radii);
|
||||
}
|
||||
|
||||
if (colors != oldProps->colors) {
|
||||
result[\\"colors\\"] = toDynamic(colors);
|
||||
}
|
||||
|
||||
if (srcs != oldProps->srcs) {
|
||||
result[\\"srcs\\"] = toDynamic(srcs);
|
||||
}
|
||||
|
||||
if (points != oldProps->points) {
|
||||
result[\\"points\\"] = toDynamic(points);
|
||||
}
|
||||
|
||||
if (edgeInsets != oldProps->edgeInsets) {
|
||||
result[\\"edgeInsets\\"] = toDynamic(edgeInsets);
|
||||
}
|
||||
|
||||
if (dimensions != oldProps->dimensions) {
|
||||
result[\\"dimensions\\"] = toDynamic(dimensions);
|
||||
}
|
||||
|
||||
if (sizes != oldProps->sizes) {
|
||||
result[\\"sizes\\"] = toDynamic(sizes);
|
||||
}
|
||||
|
||||
if (object != oldProps->object) {
|
||||
result[\\"object\\"] = toDynamic(object);
|
||||
}
|
||||
|
||||
if (arrayOfObjects != oldProps->arrayOfObjects) {
|
||||
result[\\"arrayOfObjects\\"] = toDynamic(arrayOfObjects);
|
||||
}
|
||||
|
||||
if (arrayOfMixed != oldProps->arrayOfMixed) {
|
||||
result[\\"arrayOfMixed\\"] = toDynamic(arrayOfMixed);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -142,10 +99,6 @@ BooleanPropNativeComponentViewProps::BooleanPropNativeComponentViewProps(
|
||||
disabledNullable(convertRawProp(context, rawProps, \\"disabledNullable\\", sourceProps.disabledNullable, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName BooleanPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"BooleanPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic BooleanPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = BooleanPropNativeComponentViewProps();
|
||||
@@ -199,10 +152,6 @@ ColorPropNativeComponentViewProps::ColorPropNativeComponentViewProps(
|
||||
tintColor(convertRawProp(context, rawProps, \\"tintColor\\", sourceProps.tintColor, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ColorPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ColorPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ColorPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ColorPropNativeComponentViewProps();
|
||||
@@ -253,10 +202,6 @@ DimensionPropNativeComponentViewProps::DimensionPropNativeComponentViewProps(
|
||||
marginBack(convertRawProp(context, rawProps, \\"marginBack\\", sourceProps.marginBack, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName DimensionPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"DimensionPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic DimensionPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = DimensionPropNativeComponentViewProps();
|
||||
@@ -268,9 +213,6 @@ folly::dynamic DimensionPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (marginBack != oldProps->marginBack) {
|
||||
result[\\"marginBack\\"] = toDynamic(marginBack);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -306,10 +248,6 @@ EdgeInsetsPropNativeComponentViewProps::EdgeInsetsPropNativeComponentViewProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EdgeInsetsPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EdgeInsetsPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EdgeInsetsPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EdgeInsetsPropNativeComponentViewProps();
|
||||
@@ -357,10 +295,6 @@ EnumPropNativeComponentViewProps::EnumPropNativeComponentViewProps(
|
||||
intervals(convertRawProp(context, rawProps, \\"intervals\\", sourceProps.intervals, {EnumPropNativeComponentViewIntervals::Intervals0})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EnumPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EnumPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EnumPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EnumPropNativeComponentViewProps();
|
||||
@@ -372,13 +306,7 @@ folly::dynamic EnumPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (alignment != oldProps->alignment) {
|
||||
result[\\"alignment\\"] = toDynamic(alignment);
|
||||
}
|
||||
|
||||
if (intervals != oldProps->intervals) {
|
||||
result[\\"intervals\\"] = toDynamic(intervals);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -414,10 +342,6 @@ EventNestedObjectPropsNativeComponentViewProps::EventNestedObjectPropsNativeComp
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventNestedObjectPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventNestedObjectPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventNestedObjectPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventNestedObjectPropsNativeComponentViewProps();
|
||||
@@ -467,10 +391,6 @@ EventPropsNativeComponentViewProps::EventPropsNativeComponentViewProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventPropsNativeComponentViewProps();
|
||||
@@ -526,10 +446,6 @@ FloatPropsNativeComponentViewProps::FloatPropsNativeComponentViewProps(
|
||||
blurRadiusNullable(convertRawProp(context, rawProps, \\"blurRadiusNullable\\", sourceProps.blurRadiusNullable, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName FloatPropsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"FloatPropsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic FloatPropsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = FloatPropsNativeComponentViewProps();
|
||||
@@ -604,10 +520,6 @@ ImagePropNativeComponentViewProps::ImagePropNativeComponentViewProps(
|
||||
thumbImage(convertRawProp(context, rawProps, \\"thumbImage\\", sourceProps.thumbImage, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ImagePropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ImagePropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic ImagePropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ImagePropNativeComponentViewProps();
|
||||
@@ -620,7 +532,7 @@ folly::dynamic ImagePropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -659,10 +571,6 @@ IntegerPropNativeComponentViewProps::IntegerPropNativeComponentViewProps(
|
||||
progress3(convertRawProp(context, rawProps, \\"progress3\\", sourceProps.progress3, {10})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName IntegerPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"IntegerPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic IntegerPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = IntegerPropNativeComponentViewProps();
|
||||
@@ -720,10 +628,6 @@ InterfaceOnlyNativeComponentViewProps::InterfaceOnlyNativeComponentViewProps(
|
||||
title(convertRawProp(context, rawProps, \\"title\\", sourceProps.title, {\\"\\"})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName InterfaceOnlyNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"InterfaceOnlyNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic InterfaceOnlyNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = InterfaceOnlyNativeComponentViewProps();
|
||||
@@ -774,10 +678,6 @@ MixedPropNativeComponentViewProps::MixedPropNativeComponentViewProps(
|
||||
mixedProp(convertRawProp(context, rawProps, \\"mixedProp\\", sourceProps.mixedProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MixedPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MixedPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic MixedPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MixedPropNativeComponentViewProps();
|
||||
@@ -789,9 +689,6 @@ folly::dynamic MixedPropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (mixedProp != oldProps->mixedProp) {
|
||||
result[\\"mixedProp\\"] = mixedProp;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -831,10 +728,6 @@ MultiNativePropNativeComponentViewProps::MultiNativePropNativeComponentViewProps
|
||||
point(convertRawProp(context, rawProps, \\"point\\", sourceProps.point, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiNativePropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiNativePropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiNativePropNativeComponentViewProps();
|
||||
@@ -847,7 +740,7 @@ folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
|
||||
if (color != oldProps->color) {
|
||||
@@ -859,7 +752,10 @@ folly::dynamic MultiNativePropNativeComponentViewProps::getDiffProps(
|
||||
}
|
||||
|
||||
if (point != oldProps->point) {
|
||||
result[\\"point\\"] = toDynamic(point);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = point.x;
|
||||
pointResult[\\"y\\"] = point.y;
|
||||
result[\\"point\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -896,10 +792,6 @@ NoPropsNoEventsNativeComponentViewProps::NoPropsNoEventsNativeComponentViewProps
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName NoPropsNoEventsNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"NoPropsNoEventsNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic NoPropsNoEventsNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = NoPropsNoEventsNativeComponentViewProps();
|
||||
@@ -949,10 +841,6 @@ ObjectPropsNativeComponentProps::ObjectPropsNativeComponentProps(
|
||||
objectPrimitiveRequiredProp(convertRawProp(context, rawProps, \\"objectPrimitiveRequiredProp\\", sourceProps.objectPrimitiveRequiredProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ObjectPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ObjectPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ObjectPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ObjectPropsNativeComponentProps();
|
||||
@@ -964,17 +852,8 @@ folly::dynamic ObjectPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (objectProp != oldProps->objectProp) {
|
||||
result[\\"objectProp\\"] = toDynamic(objectProp);
|
||||
}
|
||||
|
||||
if (objectArrayProp != oldProps->objectArrayProp) {
|
||||
result[\\"objectArrayProp\\"] = toDynamic(objectArrayProp);
|
||||
}
|
||||
|
||||
if (objectPrimitiveRequiredProp != oldProps->objectPrimitiveRequiredProp) {
|
||||
result[\\"objectPrimitiveRequiredProp\\"] = toDynamic(objectPrimitiveRequiredProp);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1010,10 +889,6 @@ PointPropNativeComponentViewProps::PointPropNativeComponentViewProps(
|
||||
startPoint(convertRawProp(context, rawProps, \\"startPoint\\", sourceProps.startPoint, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName PointPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"PointPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic PointPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = PointPropNativeComponentViewProps();
|
||||
@@ -1026,7 +901,10 @@ folly::dynamic PointPropNativeComponentViewProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (startPoint != oldProps->startPoint) {
|
||||
result[\\"startPoint\\"] = toDynamic(startPoint);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = startPoint.x;
|
||||
pointResult[\\"y\\"] = startPoint.y;
|
||||
result[\\"startPoint\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1064,10 +942,6 @@ StringPropNativeComponentViewProps::StringPropNativeComponentViewProps(
|
||||
defaultValue(convertRawProp(context, rawProps, \\"defaultValue\\", sourceProps.defaultValue, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName StringPropNativeComponentViewProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"StringPropNativeComponentView\\";
|
||||
}
|
||||
|
||||
folly::dynamic StringPropNativeComponentViewProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = StringPropNativeComponentViewProps();
|
||||
|
||||
-158
@@ -16,7 +16,6 @@ Object {
|
||||
#include <cinttypes>
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <react/renderer/core/propsConversions.h>
|
||||
#include <react/renderer/graphics/Color.h>
|
||||
#include <react/renderer/graphics/Point.h>
|
||||
@@ -88,16 +87,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewSizesMaskW
|
||||
}
|
||||
struct ArrayPropsNativeComponentViewObjectStruct {
|
||||
std::string prop{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentViewObjectStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"prop\\"] = prop;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentViewObjectStruct &result) {
|
||||
@@ -113,12 +102,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewObjectStru
|
||||
return \\"[Object ArrayPropsNativeComponentViewObjectStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentViewObjectStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentViewObjectStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -132,17 +115,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
struct ArrayPropsNativeComponentViewArrayOfObjectsStruct {
|
||||
Float prop1{0.0};
|
||||
int prop2{0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentViewArrayOfObjectsStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"prop1\\"] = prop1;
|
||||
result[\\"prop2\\"] = prop2;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentViewArrayOfObjectsStruct &result) {
|
||||
@@ -162,12 +134,6 @@ static inline std::string toString(const ArrayPropsNativeComponentViewArrayOfObj
|
||||
return \\"[Object ArrayPropsNativeComponentViewArrayOfObjectsStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentViewArrayOfObjectsStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentViewArrayOfObjectsStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -199,8 +165,6 @@ class ArrayPropsNativeComponentViewProps final : public ViewProps {
|
||||
std::vector<folly::dynamic> arrayOfMixed{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -239,8 +203,6 @@ class BooleanPropNativeComponentViewProps final : public ViewProps {
|
||||
bool disabledNullable{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -279,8 +241,6 @@ class ColorPropNativeComponentViewProps final : public ViewProps {
|
||||
SharedColor tintColor{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -305,7 +265,6 @@ Object {
|
||||
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <yoga/Yoga.h>
|
||||
|
||||
namespace facebook::react {
|
||||
@@ -320,8 +279,6 @@ class DimensionPropNativeComponentViewProps final : public ViewProps {
|
||||
YGValue marginBack{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -359,8 +316,6 @@ class EdgeInsetsPropNativeComponentViewProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -405,12 +360,6 @@ static inline std::string toString(const EnumPropNativeComponentViewAlignment &v
|
||||
case EnumPropNativeComponentViewAlignment::BottomRight: return \\"bottom-right\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const EnumPropNativeComponentViewAlignment &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
enum class EnumPropNativeComponentViewIntervals { Intervals0 = 0, Intervals15 = 15, Intervals30 = 30, Intervals60 = 60 };
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, EnumPropNativeComponentViewIntervals &result) {
|
||||
@@ -442,17 +391,6 @@ static inline std::string toString(const EnumPropNativeComponentViewIntervals &v
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const EnumPropNativeComponentViewIntervals &value) {
|
||||
switch (value) {
|
||||
case EnumPropNativeComponentViewIntervals::Intervals0: return 0;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals15: return 15;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals30: return 30;
|
||||
case EnumPropNativeComponentViewIntervals::Intervals60: return 60;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
class EnumPropNativeComponentViewProps final : public ViewProps {
|
||||
public:
|
||||
EnumPropNativeComponentViewProps() = default;
|
||||
@@ -464,8 +402,6 @@ class EnumPropNativeComponentViewProps final : public ViewProps {
|
||||
EnumPropNativeComponentViewIntervals intervals{EnumPropNativeComponentViewIntervals::Intervals0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -503,8 +439,6 @@ class EventNestedObjectPropsNativeComponentViewProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -542,8 +476,6 @@ class EventPropsNativeComponentViewProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -587,8 +519,6 @@ class FloatPropsNativeComponentViewProps final : public ViewProps {
|
||||
Float blurRadiusNullable{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -627,8 +557,6 @@ class ImagePropNativeComponentViewProps final : public ViewProps {
|
||||
ImageSource thumbImage{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -668,8 +596,6 @@ class IntegerPropNativeComponentViewProps final : public ViewProps {
|
||||
int progress3{10};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -707,8 +633,6 @@ class InterfaceOnlyNativeComponentViewProps final : public ViewProps {
|
||||
std::string title{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -746,8 +670,6 @@ class MixedPropNativeComponentViewProps final : public ViewProps {
|
||||
folly::dynamic mixedProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -791,8 +713,6 @@ class MultiNativePropNativeComponentViewProps final : public ViewProps {
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -830,8 +750,6 @@ class NoPropsNoEventsNativeComponentViewProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -880,12 +798,6 @@ static inline std::string toString(const ObjectPropsNativeComponentStringEnumPro
|
||||
case ObjectPropsNativeComponentStringEnumProp::Large: return \\"large\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentStringEnumProp &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
enum class ObjectPropsNativeComponentIntEnumProp { IntEnumProp0 = 0, IntEnumProp1 = 1 };
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentIntEnumProp &result) {
|
||||
@@ -908,15 +820,6 @@ static inline std::string toString(const ObjectPropsNativeComponentIntEnumProp &
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp1: return \\"1\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentIntEnumProp &value) {
|
||||
switch (value) {
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp0: return 0;
|
||||
case ObjectPropsNativeComponentIntEnumProp::IntEnumProp1: return 1;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
struct ObjectPropsNativeComponentObjectPropStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
bool booleanProp{false};
|
||||
@@ -924,21 +827,6 @@ struct ObjectPropsNativeComponentObjectPropStruct {
|
||||
int intProp{0};
|
||||
ObjectPropsNativeComponentStringEnumProp stringEnumProp{ObjectPropsNativeComponentStringEnumProp::Small};
|
||||
ObjectPropsNativeComponentIntEnumProp intEnumProp{ObjectPropsNativeComponentIntEnumProp::IntEnumProp0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
result[\\"booleanProp\\"] = booleanProp;
|
||||
result[\\"floatProp\\"] = floatProp;
|
||||
result[\\"intProp\\"] = intProp;
|
||||
result[\\"stringEnumProp\\"] = ::facebook::react::toDynamic(stringEnumProp);
|
||||
result[\\"intEnumProp\\"] = ::facebook::react::toDynamic(intEnumProp);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectPropStruct &result) {
|
||||
@@ -974,24 +862,8 @@ static inline std::string toString(const ObjectPropsNativeComponentObjectPropStr
|
||||
return \\"[Object ObjectPropsNativeComponentObjectPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsNativeComponentObjectArrayPropStruct {
|
||||
std::vector<std::string> array{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectArrayPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"array\\"] = ::facebook::react::toDynamic(array);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectArrayPropStruct &result) {
|
||||
@@ -1007,28 +879,10 @@ static inline std::string toString(const ObjectPropsNativeComponentObjectArrayPr
|
||||
return \\"[Object ObjectPropsNativeComponentObjectArrayPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectArrayPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct {
|
||||
ImageSource image{};
|
||||
SharedColor color{};
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"image\\"] = ::facebook::react::toDynamic(image);
|
||||
result[\\"color\\"] = ::facebook::react::toDynamic(color);
|
||||
result[\\"point\\"] = ::facebook::react::toDynamic(point);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &result) {
|
||||
@@ -1051,12 +905,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
static inline std::string toString(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &value) {
|
||||
return \\"[Object ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
class ObjectPropsNativeComponentProps final : public ViewProps {
|
||||
public:
|
||||
ObjectPropsNativeComponentProps() = default;
|
||||
@@ -1069,8 +917,6 @@ class ObjectPropsNativeComponentProps final : public ViewProps {
|
||||
ObjectPropsNativeComponentObjectPrimitiveRequiredPropStruct objectPrimitiveRequiredProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1109,8 +955,6 @@ class PointPropNativeComponentViewProps final : public ViewProps {
|
||||
Point startPoint{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1149,8 +993,6 @@ class StringPropNativeComponentViewProps final : public ViewProps {
|
||||
std::string defaultValue{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
|
||||
+110
-98
@@ -2,7 +2,7 @@
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ArrayPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -11,26 +11,27 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ArrayPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setNames(view: T, value: ReadableArray?): Unit
|
||||
public fun setDisableds(view: T, value: ReadableArray?): Unit
|
||||
public fun setProgress(view: T, value: ReadableArray?): Unit
|
||||
public fun setRadii(view: T, value: ReadableArray?): Unit
|
||||
public fun setColors(view: T, value: ReadableArray?): Unit
|
||||
public fun setSrcs(view: T, value: ReadableArray?): Unit
|
||||
public fun setPoints(view: T, value: ReadableArray?): Unit
|
||||
public fun setEdgeInsets(view: T, value: ReadableArray?): Unit
|
||||
public fun setDimensions(view: T, value: ReadableArray?): Unit
|
||||
public fun setSizes(view: T, value: ReadableArray?): Unit
|
||||
public fun setObject(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfObjects(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfMixed(view: T, value: ReadableArray?): Unit
|
||||
public interface ArrayPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setNames(T view, @Nullable ReadableArray value);
|
||||
void setDisableds(T view, @Nullable ReadableArray value);
|
||||
void setProgress(T view, @Nullable ReadableArray value);
|
||||
void setRadii(T view, @Nullable ReadableArray value);
|
||||
void setColors(T view, @Nullable ReadableArray value);
|
||||
void setSrcs(T view, @Nullable ReadableArray value);
|
||||
void setPoints(T view, @Nullable ReadableArray value);
|
||||
void setEdgeInsets(T view, @Nullable ReadableArray value);
|
||||
void setDimensions(T view, @Nullable ReadableArray value);
|
||||
void setSizes(T view, @Nullable ReadableArray value);
|
||||
void setObject(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfObjects(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfMixed(T view, @Nullable ReadableArray value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -38,7 +39,7 @@ public interface ArrayPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'BooleanPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -47,14 +48,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface BooleanPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public fun setDisabledNullable(view: T, value: Boolean?): Unit
|
||||
public interface BooleanPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
void setDisabledNullable(T view, @Nullable Boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -62,7 +64,7 @@ public interface BooleanPropNativeComponentViewManagerInterface<T: View>: ViewMa
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ColorPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -71,13 +73,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ColorPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setTintColor(view: T, value: Int?): Unit
|
||||
public interface ColorPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setTintColor(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -85,7 +88,7 @@ public interface ColorPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'DimensionPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -94,14 +97,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
import com.facebook.yoga.YogaValue;
|
||||
|
||||
public interface DimensionPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMarginBack(view: T, value: YogaValue?): Unit
|
||||
public interface DimensionPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMarginBack(T view, @Nullable YogaValue value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -109,7 +113,7 @@ public interface DimensionPropNativeComponentViewManagerInterface<T: View>: View
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EdgeInsetsPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EdgeInsetsPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EdgeInsetsPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -118,12 +122,12 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EdgeInsetsPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface EdgeInsetsPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -132,7 +136,7 @@ public interface EdgeInsetsPropNativeComponentViewManagerInterface<T: View>: Vie
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EnumPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EnumPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EnumPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -141,14 +145,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EnumPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAlignment(view: T, value: String?): Unit
|
||||
public fun setIntervals(view: T, value: Int?): Unit
|
||||
public interface EnumPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAlignment(T view, @Nullable String value);
|
||||
void setIntervals(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -156,7 +161,7 @@ public interface EnumPropNativeComponentViewManagerInterface<T: View>: ViewManag
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EventNestedObjectPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EventNestedObjectPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EventNestedObjectPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -165,13 +170,13 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -179,7 +184,7 @@ public interface EventNestedObjectPropsNativeComponentViewManagerInterface<T: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'EventPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/EventPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/EventPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -188,13 +193,13 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -202,7 +207,7 @@ public interface EventPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'FloatPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/FloatPropsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/FloatPropsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -211,19 +216,20 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface FloatPropsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setBlurRadius(view: T, value: Float): Unit
|
||||
public fun setBlurRadius2(view: T, value: Float): Unit
|
||||
public fun setBlurRadius3(view: T, value: Float): Unit
|
||||
public fun setBlurRadius4(view: T, value: Float): Unit
|
||||
public fun setBlurRadius5(view: T, value: Float): Unit
|
||||
public fun setBlurRadius6(view: T, value: Float): Unit
|
||||
public fun setBlurRadiusNullable(view: T, value: Float?): Unit
|
||||
public interface FloatPropsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setBlurRadius(T view, float value);
|
||||
void setBlurRadius2(T view, float value);
|
||||
void setBlurRadius3(T view, float value);
|
||||
void setBlurRadius4(T view, float value);
|
||||
void setBlurRadius5(T view, float value);
|
||||
void setBlurRadius6(T view, float value);
|
||||
void setBlurRadiusNullable(T view, @Nullable Float value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -231,7 +237,7 @@ public interface FloatPropsNativeComponentViewManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ImagePropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -240,14 +246,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ImagePropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public interface ImagePropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -255,7 +262,7 @@ public interface ImagePropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'IntegerPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -264,15 +271,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface IntegerPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setProgress1(view: T, value: Int): Unit
|
||||
public fun setProgress2(view: T, value: Int): Unit
|
||||
public fun setProgress3(view: T, value: Int): Unit
|
||||
public interface IntegerPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setProgress1(T view, int value);
|
||||
void setProgress2(T view, int value);
|
||||
void setProgress3(T view, int value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -280,7 +287,7 @@ public interface IntegerPropNativeComponentViewManagerInterface<T: View>: ViewMa
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'InterfaceOnlyNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -289,13 +296,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface InterfaceOnlyNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setTitle(view: T, value: String?): Unit
|
||||
public interface InterfaceOnlyNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setTitle(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -303,7 +311,7 @@ public interface InterfaceOnlyNativeComponentViewManagerInterface<T: View>: View
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'MixedPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -312,14 +320,14 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.bridge.Dynamic;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MixedPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMixedProp(view: T, value: Dynamic): Unit
|
||||
public interface MixedPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMixedProp(T view, Dynamic value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -327,7 +335,7 @@ public interface MixedPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'MultiNativePropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/MultiNativePropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiNativePropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -336,17 +344,18 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiNativePropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public fun setColor(view: T, value: Int?): Unit
|
||||
public fun setThumbTintColor(view: T, value: Int?): Unit
|
||||
public fun setPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface MultiNativePropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
void setColor(T view, @Nullable Integer value);
|
||||
void setThumbTintColor(T view, @Nullable Integer value);
|
||||
void setPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -354,7 +363,7 @@ public interface MultiNativePropNativeComponentViewManagerInterface<T: View>: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'NoPropsNoEventsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -363,12 +372,12 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface NoPropsNoEventsNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface NoPropsNoEventsNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -377,7 +386,7 @@ public interface NoPropsNoEventsNativeComponentViewManagerInterface<T: View>: Vi
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'ObjectPropsNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsNativeComponentManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsNativeComponentManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -386,16 +395,17 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ObjectPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setObjectProp(view: T, value: ReadableMap?): Unit
|
||||
public fun setObjectArrayProp(view: T, value: ReadableMap?): Unit
|
||||
public fun setObjectPrimitiveRequiredProp(view: T, value: ReadableMap?): Unit
|
||||
public interface ObjectPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setObjectProp(T view, @Nullable ReadableMap value);
|
||||
void setObjectArrayProp(T view, @Nullable ReadableMap value);
|
||||
void setObjectPrimitiveRequiredProp(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -403,7 +413,7 @@ public interface ObjectPropsNativeComponentManagerInterface<T: View>: ViewManage
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'PointPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -412,14 +422,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface PointPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setStartPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface PointPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setStartPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -427,7 +438,7 @@ public interface PointPropNativeComponentViewManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate for 'StringPropNativeComponent.js' 1`] = `
|
||||
Object {
|
||||
"java/com/facebook/react/viewmanagers/StringPropNativeComponentViewManagerInterface.kt": "/**
|
||||
"java/com/facebook/react/viewmanagers/StringPropNativeComponentViewManagerInterface.java": "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -436,14 +447,15 @@ Object {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface StringPropNativeComponentViewManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setPlaceholder(view: T, value: String?): Unit
|
||||
public fun setDefaultValue(view: T, value: String?): Unit
|
||||
public interface StringPropNativeComponentViewManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setPlaceholder(T view, @Nullable String value);
|
||||
void setDefaultValue(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/codegen",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Code generation tools for React Native",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -30,7 +30,7 @@
|
||||
],
|
||||
"dependencies": {
|
||||
"glob": "^7.1.1",
|
||||
"hermes-parser": "0.29.1",
|
||||
"hermes-parser": "0.29.0",
|
||||
"invariant": "^2.2.4",
|
||||
"nullthrows": "^1.1.1",
|
||||
"yargs": "^17.6.2"
|
||||
@@ -43,7 +43,7 @@
|
||||
"@babel/plugin-transform-nullish-coalescing-operator": "^7.24.7",
|
||||
"@babel/plugin-transform-optional-chaining": "^7.24.8",
|
||||
"@babel/preset-env": "^7.25.3",
|
||||
"hermes-estree": "0.29.1",
|
||||
"hermes-estree": "0.29.0",
|
||||
"micromatch": "^4.0.4",
|
||||
"prettier": "2.8.8",
|
||||
"rimraf": "^3.0.2"
|
||||
|
||||
-1
@@ -245,7 +245,6 @@ function getLocalImports(
|
||||
return;
|
||||
case 'DimensionPrimitive':
|
||||
imports.add('#include <yoga/Yoga.h>');
|
||||
imports.add('#include <react/renderer/core/graphicsConversions.h>');
|
||||
return;
|
||||
default:
|
||||
(name: empty);
|
||||
|
||||
+7
-34
@@ -105,7 +105,7 @@ function generatePropsDiffString(
|
||||
case 'ImageSourcePrimitive':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
result["${prop.name}"] = ${prop.name}.toDynamic();
|
||||
}`;
|
||||
case 'ImageRequestPrimitive':
|
||||
// Shouldn't be used in props
|
||||
@@ -115,47 +115,24 @@ function generatePropsDiffString(
|
||||
case 'PointPrimitive':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult["x"] = ${prop.name}.x;
|
||||
pointResult["y"] = ${prop.name}.y;
|
||||
result["${prop.name}"] = pointResult;
|
||||
}`;
|
||||
case 'EdgeInsetsPrimitive':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
case 'DimensionPrimitive':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
// TODO: Implement diffProps for complex types
|
||||
return '';
|
||||
default:
|
||||
(typeAnnotation.name: empty);
|
||||
throw new Error('Received unknown ReservedPropTypeAnnotation');
|
||||
}
|
||||
case 'ArrayTypeAnnotation':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
case 'ObjectTypeAnnotation':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
case 'StringEnumTypeAnnotation':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
case 'Int32EnumTypeAnnotation':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = toDynamic(${prop.name});
|
||||
}`;
|
||||
case 'MixedTypeAnnotation':
|
||||
return `
|
||||
if (${prop.name} != oldProps->${prop.name}) {
|
||||
result["${prop.name}"] = ${prop.name};
|
||||
}`;
|
||||
default:
|
||||
// TODO: Implement diffProps for complex types
|
||||
return '';
|
||||
@@ -165,10 +142,6 @@ function generatePropsDiffString(
|
||||
|
||||
return `
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ${className}::getDiffPropsImplementationTarget() const {
|
||||
return "${componentName}";
|
||||
}
|
||||
|
||||
folly::dynamic ${className}::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ${className}();
|
||||
|
||||
@@ -85,8 +85,6 @@ class ${className} final${extendClasses} {
|
||||
${props}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -117,12 +115,6 @@ static inline std::string toString(const ${enumName} &value) {
|
||||
${toCases}
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ${enumName} &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
`.trim();
|
||||
|
||||
const IntEnumTemplate = ({
|
||||
@@ -130,13 +122,11 @@ const IntEnumTemplate = ({
|
||||
values,
|
||||
fromCases,
|
||||
toCases,
|
||||
toDynamicCases,
|
||||
}: {
|
||||
enumName: string,
|
||||
values: string,
|
||||
fromCases: string,
|
||||
toCases: string,
|
||||
toDynamicCases: string,
|
||||
}) =>
|
||||
`
|
||||
enum class ${enumName} { ${values} };
|
||||
@@ -154,39 +144,19 @@ static inline std::string toString(const ${enumName} &value) {
|
||||
${toCases}
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ${enumName} &value) {
|
||||
switch (value) {
|
||||
${toDynamicCases}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
`.trim();
|
||||
|
||||
const StructTemplate = ({
|
||||
structName,
|
||||
fields,
|
||||
fromCases,
|
||||
toDynamicCases,
|
||||
}: {
|
||||
structName: string,
|
||||
fields: string,
|
||||
fromCases: string,
|
||||
toDynamicCases: string,
|
||||
}) =>
|
||||
`struct ${structName} {
|
||||
${fields}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ${structName}&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
${toDynamicCases}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ${structName} &result) {
|
||||
@@ -198,12 +168,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
static inline std::string toString(const ${structName} &value) {
|
||||
return "[Object ${structName}]";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ${structName} &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
`.trim();
|
||||
|
||||
const ArrayConversionFunctionTemplate = ({
|
||||
@@ -437,16 +401,6 @@ function generateIntEnum(
|
||||
)
|
||||
.join('\n' + ' ');
|
||||
|
||||
const toDynamicCases = values
|
||||
.map(
|
||||
value =>
|
||||
`case ${enumName}::${toIntEnumValueName(
|
||||
prop.name,
|
||||
value,
|
||||
)}: return ${value};`,
|
||||
)
|
||||
.join('\n' + ' ');
|
||||
|
||||
const valueVariables = values
|
||||
.map(val => `${toIntEnumValueName(prop.name, val)} = ${val}`)
|
||||
.join(', ');
|
||||
@@ -456,7 +410,6 @@ function generateIntEnum(
|
||||
values: valueVariables,
|
||||
fromCases,
|
||||
toCases,
|
||||
toDynamicCases,
|
||||
});
|
||||
}
|
||||
|
||||
@@ -748,30 +701,12 @@ function generateStruct(
|
||||
})
|
||||
.join('\n ');
|
||||
|
||||
const toDynamicCases = properties
|
||||
.map((property: NamedShape<PropTypeAnnotation>) => {
|
||||
const name = property.name;
|
||||
switch (property.typeAnnotation.type) {
|
||||
case 'BooleanTypeAnnotation':
|
||||
case 'StringTypeAnnotation':
|
||||
case 'Int32TypeAnnotation':
|
||||
case 'DoubleTypeAnnotation':
|
||||
case 'FloatTypeAnnotation':
|
||||
case 'MixedTypeAnnotation':
|
||||
return `result["${name}"] = ${name};`;
|
||||
default:
|
||||
return `result["${name}"] = ::facebook::react::toDynamic(${name});`;
|
||||
}
|
||||
})
|
||||
.join('\n ');
|
||||
|
||||
structs.set(
|
||||
structName,
|
||||
StructTemplate({
|
||||
structName,
|
||||
fields,
|
||||
fromCases,
|
||||
toDynamicCases,
|
||||
}),
|
||||
);
|
||||
}
|
||||
|
||||
+49
-32
@@ -48,15 +48,19 @@ const FileTemplate = ({
|
||||
* ${'@'}generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package ${packageName}
|
||||
package ${packageName};
|
||||
|
||||
${imports}
|
||||
|
||||
public interface ${className}<T: ${extendClasses}>: ViewManagerWithGeneratedInterface {
|
||||
public interface ${className}<T extends ${extendClasses}> extends ViewManagerWithGeneratedInterface {
|
||||
${methods}
|
||||
}
|
||||
`;
|
||||
|
||||
function addNullable(imports: Set<string>) {
|
||||
imports.add('import androidx.annotation.Nullable;');
|
||||
}
|
||||
|
||||
function getJavaValueForProp(
|
||||
prop: NamedShape<PropTypeAnnotation>,
|
||||
imports: Set<string>,
|
||||
@@ -66,52 +70,65 @@ function getJavaValueForProp(
|
||||
switch (typeAnnotation.type) {
|
||||
case 'BooleanTypeAnnotation':
|
||||
if (typeAnnotation.default === null) {
|
||||
return 'value: Boolean?';
|
||||
addNullable(imports);
|
||||
return '@Nullable Boolean value';
|
||||
} else {
|
||||
return 'value: Boolean';
|
||||
return 'boolean value';
|
||||
}
|
||||
case 'StringTypeAnnotation':
|
||||
return 'value: String?';
|
||||
addNullable(imports);
|
||||
return '@Nullable String value';
|
||||
case 'Int32TypeAnnotation':
|
||||
return 'value: Int';
|
||||
return 'int value';
|
||||
case 'DoubleTypeAnnotation':
|
||||
return 'value: Double';
|
||||
return 'double value';
|
||||
case 'FloatTypeAnnotation':
|
||||
if (typeAnnotation.default === null) {
|
||||
return 'value: Float?';
|
||||
addNullable(imports);
|
||||
return '@Nullable Float value';
|
||||
} else {
|
||||
return 'value: Float';
|
||||
return 'float value';
|
||||
}
|
||||
case 'ReservedPropTypeAnnotation':
|
||||
switch (typeAnnotation.name) {
|
||||
case 'ColorPrimitive':
|
||||
return 'value: Int?';
|
||||
addNullable(imports);
|
||||
return '@Nullable Integer value';
|
||||
case 'ImageSourcePrimitive':
|
||||
return 'value: ReadableMap?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableMap value';
|
||||
case 'ImageRequestPrimitive':
|
||||
return 'value: ReadableMap?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableMap value';
|
||||
case 'PointPrimitive':
|
||||
return 'value: ReadableMap?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableMap value';
|
||||
case 'EdgeInsetsPrimitive':
|
||||
return 'value: ReadableMap?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableMap value';
|
||||
case 'DimensionPrimitive':
|
||||
return 'value: YogaValue?';
|
||||
addNullable(imports);
|
||||
return '@Nullable YogaValue value';
|
||||
default:
|
||||
(typeAnnotation.name: empty);
|
||||
throw new Error('Received unknown ReservedPropTypeAnnotation');
|
||||
}
|
||||
case 'ArrayTypeAnnotation': {
|
||||
return 'value: ReadableArray?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableArray value';
|
||||
}
|
||||
case 'ObjectTypeAnnotation': {
|
||||
return 'value: ReadableMap?';
|
||||
addNullable(imports);
|
||||
return '@Nullable ReadableMap value';
|
||||
}
|
||||
case 'StringEnumTypeAnnotation':
|
||||
return 'value: String?';
|
||||
addNullable(imports);
|
||||
return '@Nullable String value';
|
||||
case 'Int32EnumTypeAnnotation':
|
||||
return 'value: Int?';
|
||||
addNullable(imports);
|
||||
return '@Nullable Integer value';
|
||||
case 'MixedTypeAnnotation':
|
||||
return 'value: Dynamic';
|
||||
return 'Dynamic value';
|
||||
default:
|
||||
(typeAnnotation: empty);
|
||||
throw new Error('Received invalid typeAnnotation');
|
||||
@@ -125,9 +142,9 @@ function generatePropsString(component: ComponentShape, imports: Set<string>) {
|
||||
|
||||
return component.props
|
||||
.map(prop => {
|
||||
return `public fun set${toSafeJavaString(
|
||||
return `void set${toSafeJavaString(
|
||||
prop.name,
|
||||
)}(view: T, ${getJavaValueForProp(prop, imports)}): Unit`;
|
||||
)}(T view, ${getJavaValueForProp(prop, imports)});`;
|
||||
})
|
||||
.join('\n' + ' ');
|
||||
}
|
||||
@@ -139,19 +156,19 @@ function getCommandArgJavaType(param: NamedShape<CommandParamTypeAnnotation>) {
|
||||
case 'ReservedTypeAnnotation':
|
||||
switch (typeAnnotation.name) {
|
||||
case 'RootTag':
|
||||
return 'Double';
|
||||
return 'double';
|
||||
default:
|
||||
(typeAnnotation.name: empty);
|
||||
throw new Error(`Receieved invalid type: ${typeAnnotation.name}`);
|
||||
}
|
||||
case 'BooleanTypeAnnotation':
|
||||
return 'Boolean';
|
||||
return 'boolean';
|
||||
case 'DoubleTypeAnnotation':
|
||||
return 'Double';
|
||||
return 'double';
|
||||
case 'FloatTypeAnnotation':
|
||||
return 'Float';
|
||||
return 'float';
|
||||
case 'Int32TypeAnnotation':
|
||||
return 'Int';
|
||||
return 'int';
|
||||
case 'StringTypeAnnotation':
|
||||
return 'String';
|
||||
case 'ArrayTypeAnnotation':
|
||||
@@ -167,11 +184,11 @@ function getCommandArguments(
|
||||
componentName: string,
|
||||
): string {
|
||||
return [
|
||||
'view: T',
|
||||
'T view',
|
||||
...command.typeAnnotation.params.map(param => {
|
||||
const commandArgJavaType = getCommandArgJavaType(param);
|
||||
|
||||
return `${param.name}: ${commandArgJavaType}`;
|
||||
return `${commandArgJavaType} ${param.name}`;
|
||||
}),
|
||||
].join(', ');
|
||||
}
|
||||
@@ -184,10 +201,10 @@ function generateCommandsString(
|
||||
.map(command => {
|
||||
const safeJavaName = toSafeJavaString(command.name, false);
|
||||
|
||||
return `public fun ${safeJavaName}(${getCommandArguments(
|
||||
return `void ${safeJavaName}(${getCommandArguments(
|
||||
command,
|
||||
componentName,
|
||||
)}): Unit`;
|
||||
)});`;
|
||||
})
|
||||
.join('\n' + ' ');
|
||||
}
|
||||
@@ -270,7 +287,7 @@ module.exports = {
|
||||
.trimRight(),
|
||||
});
|
||||
|
||||
files.set(`${outputDir}/${className}.kt`, replacedTemplate);
|
||||
files.set(`${outputDir}/${className}.java`, replacedTemplate);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
@@ -81,8 +81,8 @@ TEST(${componentName}_${testName}, etc) {
|
||||
function getTestCasesForProp(
|
||||
propName: string,
|
||||
typeAnnotation: PropTypeAnnotation,
|
||||
): Array<TestCase> {
|
||||
const cases: Array<TestCase> = [];
|
||||
) {
|
||||
const cases = [];
|
||||
if (typeAnnotation.type === 'StringEnumTypeAnnotation') {
|
||||
typeAnnotation.options.forEach(option =>
|
||||
cases.push({
|
||||
|
||||
+10
-192
@@ -40,10 +40,6 @@ ArrayPropsNativeComponentProps::ArrayPropsNativeComponentProps(
|
||||
arrayOfMixed(convertRawProp(context, rawProps, \\"arrayOfMixed\\", sourceProps.arrayOfMixed, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ArrayPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ArrayPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ArrayPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ArrayPropsNativeComponentProps();
|
||||
@@ -55,57 +51,18 @@ folly::dynamic ArrayPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (names != oldProps->names) {
|
||||
result[\\"names\\"] = toDynamic(names);
|
||||
}
|
||||
|
||||
if (disableds != oldProps->disableds) {
|
||||
result[\\"disableds\\"] = toDynamic(disableds);
|
||||
}
|
||||
|
||||
if (progress != oldProps->progress) {
|
||||
result[\\"progress\\"] = toDynamic(progress);
|
||||
}
|
||||
|
||||
if (radii != oldProps->radii) {
|
||||
result[\\"radii\\"] = toDynamic(radii);
|
||||
}
|
||||
|
||||
if (colors != oldProps->colors) {
|
||||
result[\\"colors\\"] = toDynamic(colors);
|
||||
}
|
||||
|
||||
if (srcs != oldProps->srcs) {
|
||||
result[\\"srcs\\"] = toDynamic(srcs);
|
||||
}
|
||||
|
||||
if (points != oldProps->points) {
|
||||
result[\\"points\\"] = toDynamic(points);
|
||||
}
|
||||
|
||||
if (dimensions != oldProps->dimensions) {
|
||||
result[\\"dimensions\\"] = toDynamic(dimensions);
|
||||
}
|
||||
|
||||
if (sizes != oldProps->sizes) {
|
||||
result[\\"sizes\\"] = toDynamic(sizes);
|
||||
}
|
||||
|
||||
if (object != oldProps->object) {
|
||||
result[\\"object\\"] = toDynamic(object);
|
||||
}
|
||||
|
||||
if (array != oldProps->array) {
|
||||
result[\\"array\\"] = toDynamic(array);
|
||||
}
|
||||
|
||||
if (arrayOfArrayOfObject != oldProps->arrayOfArrayOfObject) {
|
||||
result[\\"arrayOfArrayOfObject\\"] = toDynamic(arrayOfArrayOfObject);
|
||||
}
|
||||
|
||||
if (arrayOfMixed != oldProps->arrayOfMixed) {
|
||||
result[\\"arrayOfMixed\\"] = toDynamic(arrayOfMixed);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -141,10 +98,6 @@ ArrayPropsNativeComponentProps::ArrayPropsNativeComponentProps(
|
||||
nativePrimitives(convertRawProp(context, rawProps, \\"nativePrimitives\\", sourceProps.nativePrimitives, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ArrayPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ArrayPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ArrayPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ArrayPropsNativeComponentProps();
|
||||
@@ -156,9 +109,6 @@ folly::dynamic ArrayPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (nativePrimitives != oldProps->nativePrimitives) {
|
||||
result[\\"nativePrimitives\\"] = toDynamic(nativePrimitives);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -194,10 +144,6 @@ BooleanPropNativeComponentProps::BooleanPropNativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName BooleanPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"BooleanPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic BooleanPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = BooleanPropNativeComponentProps();
|
||||
@@ -247,10 +193,6 @@ ColorPropNativeComponentProps::ColorPropNativeComponentProps(
|
||||
tintColor(convertRawProp(context, rawProps, \\"tintColor\\", sourceProps.tintColor, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ColorPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ColorPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ColorPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ColorPropNativeComponentProps();
|
||||
@@ -300,10 +242,6 @@ CommandNativeComponentProps::CommandNativeComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName CommandNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"CommandNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic CommandNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = CommandNativeComponentProps();
|
||||
@@ -350,10 +288,6 @@ CommandNativeComponentProps::CommandNativeComponentProps(
|
||||
accessibilityHint(convertRawProp(context, rawProps, \\"accessibilityHint\\", sourceProps.accessibilityHint, {\\"\\"})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName CommandNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"CommandNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic CommandNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = CommandNativeComponentProps();
|
||||
@@ -404,10 +338,6 @@ DimensionPropNativeComponentProps::DimensionPropNativeComponentProps(
|
||||
marginBack(convertRawProp(context, rawProps, \\"marginBack\\", sourceProps.marginBack, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName DimensionPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"DimensionPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic DimensionPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = DimensionPropNativeComponentProps();
|
||||
@@ -419,9 +349,6 @@ folly::dynamic DimensionPropNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (marginBack != oldProps->marginBack) {
|
||||
result[\\"marginBack\\"] = toDynamic(marginBack);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -462,10 +389,6 @@ DoublePropNativeComponentProps::DoublePropNativeComponentProps(
|
||||
blurRadius6(convertRawProp(context, rawProps, \\"blurRadius6\\", sourceProps.blurRadius6, {0.0})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName DoublePropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"DoublePropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic DoublePropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = DoublePropNativeComponentProps();
|
||||
@@ -535,10 +458,6 @@ EventsNestedObjectNativeComponentProps::EventsNestedObjectNativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventsNestedObjectNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventsNestedObjectNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventsNestedObjectNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventsNestedObjectNativeComponentProps();
|
||||
@@ -588,10 +507,6 @@ EventsNativeComponentProps::EventsNativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName EventsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"EventsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic EventsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = EventsNativeComponentProps();
|
||||
@@ -641,10 +556,6 @@ InterfaceOnlyComponentProps::InterfaceOnlyComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName InterfaceOnlyComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"InterfaceOnlyComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic InterfaceOnlyComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = InterfaceOnlyComponentProps();
|
||||
@@ -691,10 +602,6 @@ ExcludedAndroidComponentProps::ExcludedAndroidComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ExcludedAndroidComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ExcludedAndroidComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ExcludedAndroidComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ExcludedAndroidComponentProps();
|
||||
@@ -741,10 +648,6 @@ ExcludedAndroidIosComponentProps::ExcludedAndroidIosComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ExcludedAndroidIosComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ExcludedAndroidIosComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ExcludedAndroidIosComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ExcludedAndroidIosComponentProps();
|
||||
@@ -791,10 +694,6 @@ ExcludedIosComponentProps::ExcludedIosComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ExcludedIosComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ExcludedIosComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ExcludedIosComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ExcludedIosComponentProps();
|
||||
@@ -817,10 +716,6 @@ MultiFileIncludedNativeComponentProps::MultiFileIncludedNativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {true})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiFileIncludedNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiFileIncludedNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiFileIncludedNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiFileIncludedNativeComponentProps();
|
||||
@@ -875,10 +770,6 @@ FloatPropNativeComponentProps::FloatPropNativeComponentProps(
|
||||
blurRadius6(convertRawProp(context, rawProps, \\"blurRadius6\\", sourceProps.blurRadius6, {0.0})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName FloatPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"FloatPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic FloatPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = FloatPropNativeComponentProps();
|
||||
@@ -949,10 +840,6 @@ ImagePropNativeComponentProps::ImagePropNativeComponentProps(
|
||||
thumbImage(convertRawProp(context, rawProps, \\"thumbImage\\", sourceProps.thumbImage, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ImagePropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ImagePropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ImagePropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ImagePropNativeComponentProps();
|
||||
@@ -965,7 +852,7 @@ folly::dynamic ImagePropNativeComponentProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1002,10 +889,6 @@ InsetsPropNativeComponentProps::InsetsPropNativeComponentProps(
|
||||
contentInset(convertRawProp(context, rawProps, \\"contentInset\\", sourceProps.contentInset, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName InsetsPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"InsetsPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic InsetsPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = InsetsPropNativeComponentProps();
|
||||
@@ -1017,9 +900,6 @@ folly::dynamic InsetsPropNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (contentInset != oldProps->contentInset) {
|
||||
result[\\"contentInset\\"] = toDynamic(contentInset);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1055,10 +935,6 @@ Int32EnumPropsNativeComponentProps::Int32EnumPropsNativeComponentProps(
|
||||
maxInterval(convertRawProp(context, rawProps, \\"maxInterval\\", sourceProps.maxInterval, {Int32EnumPropsNativeComponentMaxInterval::MaxInterval0})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName Int32EnumPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"Int32EnumPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic Int32EnumPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = Int32EnumPropsNativeComponentProps();
|
||||
@@ -1070,9 +946,6 @@ folly::dynamic Int32EnumPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (maxInterval != oldProps->maxInterval) {
|
||||
result[\\"maxInterval\\"] = toDynamic(maxInterval);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1110,10 +983,6 @@ IntegerPropNativeComponentProps::IntegerPropNativeComponentProps(
|
||||
progress3(convertRawProp(context, rawProps, \\"progress3\\", sourceProps.progress3, {10})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName IntegerPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"IntegerPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic IntegerPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = IntegerPropNativeComponentProps();
|
||||
@@ -1171,10 +1040,6 @@ InterfaceOnlyComponentProps::InterfaceOnlyComponentProps(
|
||||
accessibilityHint(convertRawProp(context, rawProps, \\"accessibilityHint\\", sourceProps.accessibilityHint, {\\"\\"})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName InterfaceOnlyComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"InterfaceOnlyComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic InterfaceOnlyComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = InterfaceOnlyComponentProps();
|
||||
@@ -1225,10 +1090,6 @@ MixedPropNativeComponentProps::MixedPropNativeComponentProps(
|
||||
mixedProp(convertRawProp(context, rawProps, \\"mixedProp\\", sourceProps.mixedProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MixedPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MixedPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MixedPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MixedPropNativeComponentProps();
|
||||
@@ -1240,9 +1101,6 @@ folly::dynamic MixedPropNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (mixedProp != oldProps->mixedProp) {
|
||||
result[\\"mixedProp\\"] = mixedProp;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1282,10 +1140,6 @@ ImageColorPropNativeComponentProps::ImageColorPropNativeComponentProps(
|
||||
point(convertRawProp(context, rawProps, \\"point\\", sourceProps.point, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ImageColorPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ImageColorPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic ImageColorPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ImageColorPropNativeComponentProps();
|
||||
@@ -1298,7 +1152,7 @@ folly::dynamic ImageColorPropNativeComponentProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (thumbImage != oldProps->thumbImage) {
|
||||
result[\\"thumbImage\\"] = toDynamic(thumbImage);
|
||||
result[\\"thumbImage\\"] = thumbImage.toDynamic();
|
||||
}
|
||||
|
||||
if (color != oldProps->color) {
|
||||
@@ -1310,7 +1164,10 @@ folly::dynamic ImageColorPropNativeComponentProps::getDiffProps(
|
||||
}
|
||||
|
||||
if (point != oldProps->point) {
|
||||
result[\\"point\\"] = toDynamic(point);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = point.x;
|
||||
pointResult[\\"y\\"] = point.y;
|
||||
result[\\"point\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1347,10 +1204,6 @@ NoPropsNoEventsComponentProps::NoPropsNoEventsComponentProps(
|
||||
{}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName NoPropsNoEventsComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"NoPropsNoEventsComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic NoPropsNoEventsComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = NoPropsNoEventsComponentProps();
|
||||
@@ -1398,10 +1251,6 @@ ObjectPropsProps::ObjectPropsProps(
|
||||
objectProp(convertRawProp(context, rawProps, \\"objectProp\\", sourceProps.objectProp, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName ObjectPropsProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"ObjectProps\\";
|
||||
}
|
||||
|
||||
folly::dynamic ObjectPropsProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = ObjectPropsProps();
|
||||
@@ -1413,9 +1262,6 @@ folly::dynamic ObjectPropsProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (objectProp != oldProps->objectProp) {
|
||||
result[\\"objectProp\\"] = toDynamic(objectProp);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1451,10 +1297,6 @@ PointPropNativeComponentProps::PointPropNativeComponentProps(
|
||||
startPoint(convertRawProp(context, rawProps, \\"startPoint\\", sourceProps.startPoint, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName PointPropNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"PointPropNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic PointPropNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = PointPropNativeComponentProps();
|
||||
@@ -1467,7 +1309,10 @@ folly::dynamic PointPropNativeComponentProps::getDiffProps(
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (startPoint != oldProps->startPoint) {
|
||||
result[\\"startPoint\\"] = toDynamic(startPoint);
|
||||
folly::dynamic pointResult = folly::dynamic::object();
|
||||
pointResult[\\"x\\"] = startPoint.x;
|
||||
pointResult[\\"y\\"] = startPoint.y;
|
||||
result[\\"startPoint\\"] = pointResult;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -1504,10 +1349,6 @@ StringEnumPropsNativeComponentProps::StringEnumPropsNativeComponentProps(
|
||||
alignment(convertRawProp(context, rawProps, \\"alignment\\", sourceProps.alignment, {StringEnumPropsNativeComponentAlignment::Center})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName StringEnumPropsNativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"StringEnumPropsNativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic StringEnumPropsNativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = StringEnumPropsNativeComponentProps();
|
||||
@@ -1519,9 +1360,6 @@ folly::dynamic StringEnumPropsNativeComponentProps::getDiffProps(
|
||||
}
|
||||
folly::dynamic result = HostPlatformViewProps::getDiffProps(prevProps);
|
||||
|
||||
if (alignment != oldProps->alignment) {
|
||||
result[\\"alignment\\"] = toDynamic(alignment);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
@@ -1558,10 +1396,6 @@ StringPropComponentProps::StringPropComponentProps(
|
||||
accessibilityRole(convertRawProp(context, rawProps, \\"accessibilityRole\\", sourceProps.accessibilityRole, {})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName StringPropComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"StringPropComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic StringPropComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = StringPropComponentProps();
|
||||
@@ -1615,10 +1449,6 @@ MultiFile1NativeComponentProps::MultiFile1NativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiFile1NativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiFile1NativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiFile1NativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiFile1NativeComponentProps();
|
||||
@@ -1644,10 +1474,6 @@ MultiFile2NativeComponentProps::MultiFile2NativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {true})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiFile2NativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiFile2NativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiFile2NativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiFile2NativeComponentProps();
|
||||
@@ -1697,10 +1523,6 @@ MultiComponent1NativeComponentProps::MultiComponent1NativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {false})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiComponent1NativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiComponent1NativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiComponent1NativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiComponent1NativeComponentProps();
|
||||
@@ -1726,10 +1548,6 @@ MultiComponent2NativeComponentProps::MultiComponent2NativeComponentProps(
|
||||
disabled(convertRawProp(context, rawProps, \\"disabled\\", sourceProps.disabled, {true})) {}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName MultiComponent2NativeComponentProps::getDiffPropsImplementationTarget() const {
|
||||
return \\"MultiComponent2NativeComponent\\";
|
||||
}
|
||||
|
||||
folly::dynamic MultiComponent2NativeComponentProps::getDiffProps(
|
||||
const Props* prevProps) const {
|
||||
static const auto defaultProps = MultiComponent2NativeComponentProps();
|
||||
|
||||
-305
@@ -16,7 +16,6 @@ Map {
|
||||
#include <cinttypes>
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <react/renderer/core/propsConversions.h>
|
||||
#include <react/renderer/graphics/Color.h>
|
||||
#include <react/renderer/graphics/Point.h>
|
||||
@@ -87,16 +86,6 @@ static inline std::string toString(const ArrayPropsNativeComponentSizesMaskWrapp
|
||||
}
|
||||
struct ArrayPropsNativeComponentObjectStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentObjectStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentObjectStruct &result) {
|
||||
@@ -112,12 +101,6 @@ static inline std::string toString(const ArrayPropsNativeComponentObjectStruct &
|
||||
return \\"[Object ArrayPropsNativeComponentObjectStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentObjectStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentObjectStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -130,16 +113,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
|
||||
struct ArrayPropsNativeComponentArrayObjectStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentArrayObjectStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentArrayObjectStruct &result) {
|
||||
@@ -155,12 +128,6 @@ static inline std::string toString(const ArrayPropsNativeComponentArrayObjectStr
|
||||
return \\"[Object ArrayPropsNativeComponentArrayObjectStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentArrayObjectStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentArrayObjectStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -173,16 +140,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
|
||||
struct ArrayPropsNativeComponentArrayStruct {
|
||||
std::vector<ArrayPropsNativeComponentArrayObjectStruct> object{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentArrayStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"object\\"] = ::facebook::react::toDynamic(object);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentArrayStruct &result) {
|
||||
@@ -198,12 +155,6 @@ static inline std::string toString(const ArrayPropsNativeComponentArrayStruct &v
|
||||
return \\"[Object ArrayPropsNativeComponentArrayStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentArrayStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentArrayStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -216,16 +167,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
|
||||
struct ArrayPropsNativeComponentArrayOfArrayOfObjectStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentArrayOfArrayOfObjectStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentArrayOfArrayOfObjectStruct &result) {
|
||||
@@ -241,12 +182,6 @@ static inline std::string toString(const ArrayPropsNativeComponentArrayOfArrayOf
|
||||
return \\"[Object ArrayPropsNativeComponentArrayOfArrayOfObjectStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentArrayOfArrayOfObjectStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<std::vector<ArrayPropsNativeComponentArrayOfArrayOfObjectStruct>> &result) {
|
||||
auto items = (std::vector<std::vector<RawValue>>)value;
|
||||
for (const std::vector<RawValue> &item : items) {
|
||||
@@ -282,8 +217,6 @@ class ArrayPropsNativeComponentProps final : public ViewProps {
|
||||
std::vector<folly::dynamic> arrayOfMixed{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -321,18 +254,6 @@ struct ArrayPropsNativeComponentNativePrimitivesStruct {
|
||||
std::vector<SharedColor> colors{};
|
||||
std::vector<ImageSource> srcs{};
|
||||
std::vector<Point> points{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ArrayPropsNativeComponentNativePrimitivesStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"colors\\"] = ::facebook::react::toDynamic(colors);
|
||||
result[\\"srcs\\"] = ::facebook::react::toDynamic(srcs);
|
||||
result[\\"points\\"] = ::facebook::react::toDynamic(points);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ArrayPropsNativeComponentNativePrimitivesStruct &result) {
|
||||
@@ -356,12 +277,6 @@ static inline std::string toString(const ArrayPropsNativeComponentNativePrimitiv
|
||||
return \\"[Object ArrayPropsNativeComponentNativePrimitivesStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ArrayPropsNativeComponentNativePrimitivesStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ArrayPropsNativeComponentNativePrimitivesStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -381,8 +296,6 @@ class ArrayPropsNativeComponentProps final : public ViewProps {
|
||||
std::vector<ArrayPropsNativeComponentNativePrimitivesStruct> nativePrimitives{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -420,8 +333,6 @@ class BooleanPropNativeComponentProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -460,8 +371,6 @@ class ColorPropNativeComponentProps final : public ViewProps {
|
||||
SharedColor tintColor{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -499,8 +408,6 @@ class CommandNativeComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -538,8 +445,6 @@ class CommandNativeComponentProps final : public ViewProps {
|
||||
std::string accessibilityHint{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -564,7 +469,6 @@ Map {
|
||||
|
||||
#include <react/renderer/components/view/ViewProps.h>
|
||||
#include <react/renderer/core/PropsParserContext.h>
|
||||
#include <react/renderer/core/graphicsConversions.h>
|
||||
#include <yoga/Yoga.h>
|
||||
|
||||
namespace facebook::react {
|
||||
@@ -579,8 +483,6 @@ class DimensionPropNativeComponentProps final : public ViewProps {
|
||||
YGValue marginBack{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -623,8 +525,6 @@ class DoublePropNativeComponentProps final : public ViewProps {
|
||||
double blurRadius6{0.0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -662,8 +562,6 @@ class EventsNestedObjectNativeComponentProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -701,8 +599,6 @@ class EventsNativeComponentProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -740,8 +636,6 @@ class InterfaceOnlyComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -779,8 +673,6 @@ class ExcludedAndroidComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -818,8 +710,6 @@ class ExcludedAndroidIosComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -857,8 +747,6 @@ class ExcludedIosComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -873,8 +761,6 @@ class MultiFileIncludedNativeComponentProps final : public ViewProps {
|
||||
bool disabled{true};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -917,8 +803,6 @@ class FloatPropNativeComponentProps final : public ViewProps {
|
||||
Float blurRadius6{0.0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -957,8 +841,6 @@ class ImagePropNativeComponentProps final : public ViewProps {
|
||||
ImageSource thumbImage{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -997,8 +879,6 @@ class InsetsPropNativeComponentProps final : public ViewProps {
|
||||
EdgeInsets contentInset{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1053,16 +933,6 @@ static inline std::string toString(const Int32EnumPropsNativeComponentMaxInterva
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const Int32EnumPropsNativeComponentMaxInterval &value) {
|
||||
switch (value) {
|
||||
case Int32EnumPropsNativeComponentMaxInterval::MaxInterval0: return 0;
|
||||
case Int32EnumPropsNativeComponentMaxInterval::MaxInterval1: return 1;
|
||||
case Int32EnumPropsNativeComponentMaxInterval::MaxInterval2: return 2;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
class Int32EnumPropsNativeComponentProps final : public ViewProps {
|
||||
public:
|
||||
Int32EnumPropsNativeComponentProps() = default;
|
||||
@@ -1073,8 +943,6 @@ class Int32EnumPropsNativeComponentProps final : public ViewProps {
|
||||
Int32EnumPropsNativeComponentMaxInterval maxInterval{Int32EnumPropsNativeComponentMaxInterval::MaxInterval0};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1114,8 +982,6 @@ class IntegerPropNativeComponentProps final : public ViewProps {
|
||||
int progress3{10};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1153,8 +1019,6 @@ class InterfaceOnlyComponentProps final : public ViewProps {
|
||||
std::string accessibilityHint{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1192,8 +1056,6 @@ class MixedPropNativeComponentProps final : public ViewProps {
|
||||
folly::dynamic mixedProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1237,8 +1099,6 @@ class ImageColorPropNativeComponentProps final : public ViewProps {
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1276,8 +1136,6 @@ class NoPropsNoEventsComponentProps final : public ViewProps {
|
||||
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1324,12 +1182,6 @@ static inline std::string toString(const ObjectPropsStringEnumProp &value) {
|
||||
case ObjectPropsStringEnumProp::Option1: return \\"option1\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsStringEnumProp &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
enum class ObjectPropsIntEnumProp { IntEnumProp0 = 0 };
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsIntEnumProp &result) {
|
||||
@@ -1348,26 +1200,8 @@ static inline std::string toString(const ObjectPropsIntEnumProp &value) {
|
||||
case ObjectPropsIntEnumProp::IntEnumProp0: return \\"0\\";
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsIntEnumProp &value) {
|
||||
switch (value) {
|
||||
case ObjectPropsIntEnumProp::IntEnumProp0: return 0;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
struct ObjectPropsObjectPropObjectArrayPropStruct {
|
||||
std::vector<std::string> array{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropObjectArrayPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"array\\"] = ::facebook::react::toDynamic(array);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropObjectArrayPropStruct &result) {
|
||||
@@ -1383,28 +1217,10 @@ static inline std::string toString(const ObjectPropsObjectPropObjectArrayPropStr
|
||||
return \\"[Object ObjectPropsObjectPropObjectArrayPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropObjectArrayPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct {
|
||||
ImageSource image{};
|
||||
SharedColor color{};
|
||||
Point point{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"image\\"] = ::facebook::react::toDynamic(image);
|
||||
result[\\"color\\"] = ::facebook::react::toDynamic(color);
|
||||
result[\\"point\\"] = ::facebook::react::toDynamic(point);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct &result) {
|
||||
@@ -1428,24 +1244,8 @@ static inline std::string toString(const ObjectPropsObjectPropObjectPrimitiveReq
|
||||
return \\"[Object ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsObjectPropNestedPropANestedPropBStruct {
|
||||
std::string nestedPropC{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropNestedPropANestedPropBStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"nestedPropC\\"] = nestedPropC;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropNestedPropANestedPropBStruct &result) {
|
||||
@@ -1461,24 +1261,8 @@ static inline std::string toString(const ObjectPropsObjectPropNestedPropANestedP
|
||||
return \\"[Object ObjectPropsObjectPropNestedPropANestedPropBStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropNestedPropANestedPropBStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsObjectPropNestedPropAStruct {
|
||||
ObjectPropsObjectPropNestedPropANestedPropBStruct nestedPropB{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropNestedPropAStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"nestedPropB\\"] = ::facebook::react::toDynamic(nestedPropB);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropNestedPropAStruct &result) {
|
||||
@@ -1494,24 +1278,8 @@ static inline std::string toString(const ObjectPropsObjectPropNestedPropAStruct
|
||||
return \\"[Object ObjectPropsObjectPropNestedPropAStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropNestedPropAStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct &result) {
|
||||
@@ -1527,12 +1295,6 @@ static inline std::string toString(const ObjectPropsObjectPropNestedArrayAsPrope
|
||||
return \\"[Object ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, std::vector<ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct> &result) {
|
||||
auto items = (std::vector<RawValue>)value;
|
||||
for (const auto &item : items) {
|
||||
@@ -1545,16 +1307,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
|
||||
struct ObjectPropsObjectPropNestedArrayAsPropertyStruct {
|
||||
std::vector<ObjectPropsObjectPropNestedArrayAsPropertyArrayPropStruct> arrayProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropNestedArrayAsPropertyStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"arrayProp\\"] = ::facebook::react::toDynamic(arrayProp);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropNestedArrayAsPropertyStruct &result) {
|
||||
@@ -1570,12 +1322,6 @@ static inline std::string toString(const ObjectPropsObjectPropNestedArrayAsPrope
|
||||
return \\"[Object ObjectPropsObjectPropNestedArrayAsPropertyStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropNestedArrayAsPropertyStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
|
||||
struct ObjectPropsObjectPropStruct {
|
||||
std::string stringProp{\\"\\"};
|
||||
bool booleanProp{false};
|
||||
@@ -1591,29 +1337,6 @@ struct ObjectPropsObjectPropStruct {
|
||||
ObjectPropsObjectPropObjectPrimitiveRequiredPropStruct objectPrimitiveRequiredProp{};
|
||||
ObjectPropsObjectPropNestedPropAStruct nestedPropA{};
|
||||
ObjectPropsObjectPropNestedArrayAsPropertyStruct nestedArrayAsProperty{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
bool operator==(const ObjectPropsObjectPropStruct&) const = default;
|
||||
|
||||
folly::dynamic toDynamic() const {
|
||||
folly::dynamic result = folly::dynamic::object();
|
||||
result[\\"stringProp\\"] = stringProp;
|
||||
result[\\"booleanProp\\"] = booleanProp;
|
||||
result[\\"floatProp\\"] = floatProp;
|
||||
result[\\"intProp\\"] = intProp;
|
||||
result[\\"stringUserDefaultProp\\"] = stringUserDefaultProp;
|
||||
result[\\"booleanUserDefaultProp\\"] = booleanUserDefaultProp;
|
||||
result[\\"floatUserDefaultProp\\"] = floatUserDefaultProp;
|
||||
result[\\"intUserDefaultProp\\"] = intUserDefaultProp;
|
||||
result[\\"stringEnumProp\\"] = ::facebook::react::toDynamic(stringEnumProp);
|
||||
result[\\"intEnumProp\\"] = ::facebook::react::toDynamic(intEnumProp);
|
||||
result[\\"objectArrayProp\\"] = ::facebook::react::toDynamic(objectArrayProp);
|
||||
result[\\"objectPrimitiveRequiredProp\\"] = ::facebook::react::toDynamic(objectPrimitiveRequiredProp);
|
||||
result[\\"nestedPropA\\"] = ::facebook::react::toDynamic(nestedPropA);
|
||||
result[\\"nestedArrayAsProperty\\"] = ::facebook::react::toDynamic(nestedArrayAsProperty);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
};
|
||||
|
||||
static inline void fromRawValue(const PropsParserContext& context, const RawValue &value, ObjectPropsObjectPropStruct &result) {
|
||||
@@ -1680,12 +1403,6 @@ static inline void fromRawValue(const PropsParserContext& context, const RawValu
|
||||
static inline std::string toString(const ObjectPropsObjectPropStruct &value) {
|
||||
return \\"[Object ObjectPropsObjectPropStruct]\\";
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const ObjectPropsObjectPropStruct &value) {
|
||||
return value.toDynamic();
|
||||
}
|
||||
#endif
|
||||
class ObjectPropsProps final : public ViewProps {
|
||||
public:
|
||||
ObjectPropsProps() = default;
|
||||
@@ -1696,8 +1413,6 @@ class ObjectPropsProps final : public ViewProps {
|
||||
ObjectPropsObjectPropStruct objectProp{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1736,8 +1451,6 @@ class PointPropNativeComponentProps final : public ViewProps {
|
||||
Point startPoint{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1783,12 +1496,6 @@ static inline std::string toString(const StringEnumPropsNativeComponentAlignment
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
static inline folly::dynamic toDynamic(const StringEnumPropsNativeComponentAlignment &value) {
|
||||
return toString(value);
|
||||
}
|
||||
#endif
|
||||
|
||||
class StringEnumPropsNativeComponentProps final : public ViewProps {
|
||||
public:
|
||||
StringEnumPropsNativeComponentProps() = default;
|
||||
@@ -1799,8 +1506,6 @@ class StringEnumPropsNativeComponentProps final : public ViewProps {
|
||||
StringEnumPropsNativeComponentAlignment alignment{StringEnumPropsNativeComponentAlignment::Center};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1839,8 +1544,6 @@ class StringPropComponentProps final : public ViewProps {
|
||||
std::string accessibilityRole{};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1878,8 +1581,6 @@ class MultiFile1NativeComponentProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1894,8 +1595,6 @@ class MultiFile2NativeComponentProps final : public ViewProps {
|
||||
bool disabled{true};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1933,8 +1632,6 @@ class MultiComponent1NativeComponentProps final : public ViewProps {
|
||||
bool disabled{false};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
@@ -1949,8 +1646,6 @@ class MultiComponent2NativeComponentProps final : public ViewProps {
|
||||
bool disabled{true};
|
||||
|
||||
#ifdef RN_SERIALIZABLE_STATE
|
||||
ComponentName getDiffPropsImplementationTarget() const override;
|
||||
|
||||
folly::dynamic getDiffProps(const Props* prevProps) const override;
|
||||
#endif
|
||||
};
|
||||
|
||||
+163
-149
@@ -2,7 +2,7 @@
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture ARRAY_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -11,26 +11,27 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ArrayPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setNames(view: T, value: ReadableArray?): Unit
|
||||
public fun setDisableds(view: T, value: ReadableArray?): Unit
|
||||
public fun setProgress(view: T, value: ReadableArray?): Unit
|
||||
public fun setRadii(view: T, value: ReadableArray?): Unit
|
||||
public fun setColors(view: T, value: ReadableArray?): Unit
|
||||
public fun setSrcs(view: T, value: ReadableArray?): Unit
|
||||
public fun setPoints(view: T, value: ReadableArray?): Unit
|
||||
public fun setDimensions(view: T, value: ReadableArray?): Unit
|
||||
public fun setSizes(view: T, value: ReadableArray?): Unit
|
||||
public fun setObject(view: T, value: ReadableArray?): Unit
|
||||
public fun setArray(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfArrayOfObject(view: T, value: ReadableArray?): Unit
|
||||
public fun setArrayOfMixed(view: T, value: ReadableArray?): Unit
|
||||
public interface ArrayPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setNames(T view, @Nullable ReadableArray value);
|
||||
void setDisableds(T view, @Nullable ReadableArray value);
|
||||
void setProgress(T view, @Nullable ReadableArray value);
|
||||
void setRadii(T view, @Nullable ReadableArray value);
|
||||
void setColors(T view, @Nullable ReadableArray value);
|
||||
void setSrcs(T view, @Nullable ReadableArray value);
|
||||
void setPoints(T view, @Nullable ReadableArray value);
|
||||
void setDimensions(T view, @Nullable ReadableArray value);
|
||||
void setSizes(T view, @Nullable ReadableArray value);
|
||||
void setObject(T view, @Nullable ReadableArray value);
|
||||
void setArray(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfArrayOfObject(T view, @Nullable ReadableArray value);
|
||||
void setArrayOfMixed(T view, @Nullable ReadableArray value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -38,7 +39,7 @@ public interface ArrayPropsNativeComponentManagerInterface<T: View>: ViewManager
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture ARRAY_PROPS_WITH_NESTED_OBJECT 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ArrayPropsNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -47,14 +48,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ArrayPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setNativePrimitives(view: T, value: ReadableArray?): Unit
|
||||
public interface ArrayPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setNativePrimitives(T view, @Nullable ReadableArray value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -62,7 +64,7 @@ public interface ArrayPropsNativeComponentManagerInterface<T: View>: ViewManager
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture BOOLEAN_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/BooleanPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -71,13 +73,13 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface BooleanPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface BooleanPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -85,7 +87,7 @@ public interface BooleanPropNativeComponentManagerInterface<T: View>: ViewManage
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture COLOR_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ColorPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -94,13 +96,14 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ColorPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setTintColor(view: T, value: Int?): Unit
|
||||
public interface ColorPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setTintColor(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -108,7 +111,7 @@ public interface ColorPropNativeComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture COMMANDS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/CommandNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/CommandNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -117,16 +120,16 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface CommandNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface CommandNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
public fun flashScrollIndicators(view: T): Unit
|
||||
public fun allTypes(view: T, x: Int, y: Float, z: Double, message: String, animated: Boolean, locations: ReadableArray): Unit
|
||||
void flashScrollIndicators(T view);
|
||||
void allTypes(T view, int x, float y, double z, String message, boolean animated, ReadableArray locations);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -134,7 +137,7 @@ public interface CommandNativeComponentManagerInterface<T: View>: ViewManagerWit
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture COMMANDS_AND_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/CommandNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/CommandNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -143,17 +146,18 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableArray;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface CommandNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAccessibilityHint(view: T, value: String?): Unit
|
||||
public fun handleRootTag(view: T, rootTag: Double): Unit
|
||||
public fun hotspotUpdate(view: T, x: Int, y: Int): Unit
|
||||
public fun addItems(view: T, items: ReadableArray): Unit
|
||||
public interface CommandNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAccessibilityHint(T view, @Nullable String value);
|
||||
void handleRootTag(T view, double rootTag);
|
||||
void hotspotUpdate(T view, int x, int y);
|
||||
void addItems(T view, ReadableArray items);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -161,7 +165,7 @@ public interface CommandNativeComponentManagerInterface<T: View>: ViewManagerWit
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture DIMENSION_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/DimensionPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -170,14 +174,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
import com.facebook.yoga.YogaValue;
|
||||
|
||||
public interface DimensionPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMarginBack(view: T, value: YogaValue?): Unit
|
||||
public interface DimensionPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMarginBack(T view, @Nullable YogaValue value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -185,7 +190,7 @@ public interface DimensionPropNativeComponentManagerInterface<T: View>: ViewMana
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture DOUBLE_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/DoublePropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/DoublePropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -194,18 +199,18 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface DoublePropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setBlurRadius(view: T, value: Double): Unit
|
||||
public fun setBlurRadius2(view: T, value: Double): Unit
|
||||
public fun setBlurRadius3(view: T, value: Double): Unit
|
||||
public fun setBlurRadius4(view: T, value: Double): Unit
|
||||
public fun setBlurRadius5(view: T, value: Double): Unit
|
||||
public fun setBlurRadius6(view: T, value: Double): Unit
|
||||
public interface DoublePropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setBlurRadius(T view, double value);
|
||||
void setBlurRadius2(T view, double value);
|
||||
void setBlurRadius3(T view, double value);
|
||||
void setBlurRadius4(T view, double value);
|
||||
void setBlurRadius5(T view, double value);
|
||||
void setBlurRadius6(T view, double value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -213,7 +218,7 @@ public interface DoublePropNativeComponentManagerInterface<T: View>: ViewManager
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture EVENT_NESTED_OBJECT_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/EventsNestedObjectNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/EventsNestedObjectNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -222,13 +227,13 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventsNestedObjectNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventsNestedObjectNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -236,7 +241,7 @@ public interface EventsNestedObjectNativeComponentManagerInterface<T: View>: Vie
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture EVENT_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/EventsNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/EventsNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -245,13 +250,13 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface EventsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface EventsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -259,7 +264,7 @@ public interface EventsNativeComponentManagerInterface<T: View>: ViewManagerWith
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture EVENTS_WITH_PAPER_NAME 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -268,12 +273,12 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface InterfaceOnlyComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface InterfaceOnlyComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -286,7 +291,7 @@ exports[`GeneratePropsJavaInterface can generate fixture EXCLUDE_ANDROID_IOS 1`]
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture EXCLUDE_IOS_TWO_COMPONENTS_DIFFERENT_FILES 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ExcludedIosComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ExcludedIosComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -295,16 +300,16 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ExcludedIosComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface ExcludedIosComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
"java/com/facebook/react/viewmanagers/MultiFileIncludedNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiFileIncludedNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -313,13 +318,13 @@ public interface ExcludedIosComponentManagerInterface<T: View>: ViewManagerWithG
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiFileIncludedNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface MultiFileIncludedNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -327,7 +332,7 @@ public interface MultiFileIncludedNativeComponentManagerInterface<T: View>: View
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture FLOAT_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/FloatPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/FloatPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -336,18 +341,18 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface FloatPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setBlurRadius(view: T, value: Float): Unit
|
||||
public fun setBlurRadius2(view: T, value: Float): Unit
|
||||
public fun setBlurRadius3(view: T, value: Float): Unit
|
||||
public fun setBlurRadius4(view: T, value: Float): Unit
|
||||
public fun setBlurRadius5(view: T, value: Float): Unit
|
||||
public fun setBlurRadius6(view: T, value: Float): Unit
|
||||
public interface FloatPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setBlurRadius(T view, float value);
|
||||
void setBlurRadius2(T view, float value);
|
||||
void setBlurRadius3(T view, float value);
|
||||
void setBlurRadius4(T view, float value);
|
||||
void setBlurRadius5(T view, float value);
|
||||
void setBlurRadius6(T view, float value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -355,7 +360,7 @@ public interface FloatPropNativeComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture IMAGE_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ImagePropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -364,14 +369,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ImagePropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public interface ImagePropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -379,7 +385,7 @@ public interface ImagePropNativeComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture INSETS_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/InsetsPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/InsetsPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -388,14 +394,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface InsetsPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setContentInset(view: T, value: ReadableMap?): Unit
|
||||
public interface InsetsPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setContentInset(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -403,7 +410,7 @@ public interface InsetsPropNativeComponentManagerInterface<T: View>: ViewManager
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture INT32_ENUM_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/Int32EnumPropsNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/Int32EnumPropsNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -412,13 +419,14 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface Int32EnumPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMaxInterval(view: T, value: Int?): Unit
|
||||
public interface Int32EnumPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMaxInterval(T view, @Nullable Integer value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -426,7 +434,7 @@ public interface Int32EnumPropsNativeComponentManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture INTEGER_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/IntegerPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -435,15 +443,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface IntegerPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setProgress1(view: T, value: Int): Unit
|
||||
public fun setProgress2(view: T, value: Int): Unit
|
||||
public fun setProgress3(view: T, value: Int): Unit
|
||||
public interface IntegerPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setProgress1(T view, int value);
|
||||
void setProgress2(T view, int value);
|
||||
void setProgress3(T view, int value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -451,7 +459,7 @@ public interface IntegerPropNativeComponentManagerInterface<T: View>: ViewManage
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture INTERFACE_ONLY 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/InterfaceOnlyComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -460,13 +468,14 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface InterfaceOnlyComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAccessibilityHint(view: T, value: String?): Unit
|
||||
public interface InterfaceOnlyComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAccessibilityHint(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -474,7 +483,7 @@ public interface InterfaceOnlyComponentManagerInterface<T: View>: ViewManagerWit
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture MIXED_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MixedPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -483,14 +492,14 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.bridge.Dynamic;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MixedPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setMixedProp(view: T, value: Dynamic): Unit
|
||||
public interface MixedPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setMixedProp(T view, Dynamic value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -498,7 +507,7 @@ public interface MixedPropNativeComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture MULTI_NATIVE_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ImageColorPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ImageColorPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -507,17 +516,18 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ImageColorPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setThumbImage(view: T, value: ReadableMap?): Unit
|
||||
public fun setColor(view: T, value: Int?): Unit
|
||||
public fun setThumbTintColor(view: T, value: Int?): Unit
|
||||
public fun setPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface ImageColorPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setThumbImage(T view, @Nullable ReadableMap value);
|
||||
void setColor(T view, @Nullable Integer value);
|
||||
void setThumbTintColor(T view, @Nullable Integer value);
|
||||
void setPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -525,7 +535,7 @@ public interface ImageColorPropNativeComponentManagerInterface<T: View>: ViewMan
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture NO_PROPS_NO_EVENTS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/NoPropsNoEventsComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -534,12 +544,12 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface NoPropsNoEventsComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public interface NoPropsNoEventsComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
// No props
|
||||
}
|
||||
",
|
||||
@@ -548,7 +558,7 @@ public interface NoPropsNoEventsComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture OBJECT_PROPS 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/ObjectPropsManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -557,14 +567,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface ObjectPropsManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setObjectProp(view: T, value: ReadableMap?): Unit
|
||||
public interface ObjectPropsManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setObjectProp(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -572,7 +583,7 @@ public interface ObjectPropsManagerInterface<T: View>: ViewManagerWithGeneratedI
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture POINT_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/PointPropNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -581,14 +592,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.bridge.ReadableMap;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface PointPropNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setStartPoint(view: T, value: ReadableMap?): Unit
|
||||
public interface PointPropNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setStartPoint(T view, @Nullable ReadableMap value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -596,7 +608,7 @@ public interface PointPropNativeComponentManagerInterface<T: View>: ViewManagerW
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture STRING_ENUM_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/StringEnumPropsNativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/StringEnumPropsNativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -605,13 +617,14 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface StringEnumPropsNativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAlignment(view: T, value: String?): Unit
|
||||
public interface StringEnumPropsNativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAlignment(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -619,7 +632,7 @@ public interface StringEnumPropsNativeComponentManagerInterface<T: View>: ViewMa
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture STRING_PROP 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/StringPropComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/StringPropComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -628,14 +641,15 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import androidx.annotation.Nullable;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface StringPropComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setAccessibilityHint(view: T, value: String?): Unit
|
||||
public fun setAccessibilityRole(view: T, value: String?): Unit
|
||||
public interface StringPropComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setAccessibilityHint(T view, @Nullable String value);
|
||||
void setAccessibilityRole(T view, @Nullable String value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -643,7 +657,7 @@ public interface StringPropComponentManagerInterface<T: View>: ViewManagerWithGe
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture TWO_COMPONENTS_DIFFERENT_FILES 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/MultiFile1NativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiFile1NativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -652,16 +666,16 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiFile1NativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface MultiFile1NativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
"java/com/facebook/react/viewmanagers/MultiFile2NativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiFile2NativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -670,13 +684,13 @@ public interface MultiFile1NativeComponentManagerInterface<T: View>: ViewManager
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiFile2NativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface MultiFile2NativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
@@ -684,7 +698,7 @@ public interface MultiFile2NativeComponentManagerInterface<T: View>: ViewManager
|
||||
|
||||
exports[`GeneratePropsJavaInterface can generate fixture TWO_COMPONENTS_SAME_FILE 1`] = `
|
||||
Map {
|
||||
"java/com/facebook/react/viewmanagers/MultiComponent1NativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiComponent1NativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -693,16 +707,16 @@ Map {
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiComponent1NativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface MultiComponent1NativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
"java/com/facebook/react/viewmanagers/MultiComponent2NativeComponentManagerInterface.kt" => "/**
|
||||
"java/com/facebook/react/viewmanagers/MultiComponent2NativeComponentManagerInterface.java" => "/**
|
||||
* This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
|
||||
*
|
||||
* Do not edit this file as changes may cause incorrect behavior and will be lost
|
||||
@@ -711,13 +725,13 @@ public interface MultiComponent1NativeComponentManagerInterface<T: View>: ViewMa
|
||||
* @generated by codegen project: GeneratePropsJavaInterface.js
|
||||
*/
|
||||
|
||||
package com.facebook.react.viewmanagers
|
||||
package com.facebook.react.viewmanagers;
|
||||
|
||||
import android.view.View;
|
||||
import com.facebook.react.uimanager.ViewManagerWithGeneratedInterface;
|
||||
|
||||
public interface MultiComponent2NativeComponentManagerInterface<T: View>: ViewManagerWithGeneratedInterface {
|
||||
public fun setDisabled(view: T, value: Boolean): Unit
|
||||
public interface MultiComponent2NativeComponentManagerInterface<T extends View> extends ViewManagerWithGeneratedInterface {
|
||||
void setDisabled(T view, boolean value);
|
||||
}
|
||||
",
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/compatibility-check",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "Check a React Native app's boundary between JS and Native for incompatibilities",
|
||||
"license": "MIT",
|
||||
"repository": {
|
||||
@@ -29,7 +29,7 @@
|
||||
"dist"
|
||||
],
|
||||
"dependencies": {
|
||||
"@react-native/codegen": "0.81.0-main"
|
||||
"@react-native/codegen": "0.80.0-main"
|
||||
},
|
||||
"devDependencies": {
|
||||
"flow-remove-types": "^2.237.2",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/popup-menu-android",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"description": "PopupMenu for the Android platform",
|
||||
"main": "index.js",
|
||||
"files": [
|
||||
@@ -21,7 +21,7 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"devDependencies": {
|
||||
"@react-native/codegen": "0.81.0-main"
|
||||
"@react-native/codegen": "0.80.0-main"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@types/react": "^19.1.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@react-native/oss-library-example",
|
||||
"version": "0.81.0-main",
|
||||
"version": "0.80.0-main",
|
||||
"private": true,
|
||||
"description": "Package that includes native module exapmle, native component example, targets both the old and the new architecture. It should serve as an example of a real-world OSS library.",
|
||||
"license": "MIT",
|
||||
@@ -26,7 +26,7 @@
|
||||
],
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.25.2",
|
||||
"@react-native/babel-preset": "0.81.0-main",
|
||||
"@react-native/babel-preset": "0.80.0-main",
|
||||
"react-native": "1000.0.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
|
||||
@@ -12,7 +12,6 @@
|
||||
|
||||
import type {NativeSyntheticEvent} from '../Types/CoreEventTypes';
|
||||
import type {PlatformConfig} from './AnimatedPlatformConfig';
|
||||
import type {EventMapping} from './NativeAnimatedModule';
|
||||
|
||||
import NativeAnimatedHelper from '../../src/private/animated/NativeAnimatedHelper';
|
||||
import {findNodeHandle} from '../ReactNative/RendererProxy';
|
||||
@@ -38,7 +37,7 @@ export function attachNativeEventImpl(
|
||||
): {detach: () => void} {
|
||||
// Find animated values in `argMapping` and create an array representing their
|
||||
// key path inside the `nativeEvent` object. Ex.: ['contentOffset', 'x'].
|
||||
const eventMappings: Array<EventMapping> = [];
|
||||
const eventMappings = [];
|
||||
|
||||
const traverse = (value: mixed, path: Array<string>) => {
|
||||
if (value instanceof AnimatedValue) {
|
||||
|
||||
@@ -247,6 +247,10 @@ describe('Animated', () => {
|
||||
});
|
||||
|
||||
it('renders animated and primitive style correctly', () => {
|
||||
ReactNativeFeatureFlags.override({
|
||||
alwaysFlattenAnimatedStyles: () => true,
|
||||
});
|
||||
|
||||
const anim = new Animated.Value(0);
|
||||
const staticProps = {
|
||||
style: [
|
||||
@@ -372,7 +376,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.sequence([anim1, anim2]);
|
||||
|
||||
expect(anim1.start).not.toBeCalled();
|
||||
expect(anim2.start).not.toBeCalled();
|
||||
@@ -397,7 +402,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]).start(cb);
|
||||
// $FlowFixMe[prop-missing]
|
||||
Animated.sequence([anim1, anim2]).start(cb);
|
||||
|
||||
anim1.start.mock.calls[0][0]({finished: false});
|
||||
|
||||
@@ -411,7 +417,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.sequence([anim1, anim2]);
|
||||
seq.start(cb);
|
||||
seq.stop();
|
||||
|
||||
@@ -429,7 +436,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.sequence([anim1, anim2]);
|
||||
|
||||
seq.start(cb);
|
||||
|
||||
@@ -452,7 +460,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.sequence([anim1, anim2]);
|
||||
|
||||
seq.start(cb);
|
||||
anim1.start.mock.calls[0][0]({finished: true});
|
||||
@@ -478,7 +487,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation);
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -509,7 +519,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe, {iterations: -1});
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {iterations: -1});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -540,10 +551,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(
|
||||
animation as $FlowFixMe,
|
||||
{anotherKey: 'value'} as $FlowFixMe,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {anotherKey: 'value'});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -574,7 +583,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe, {iterations: 3});
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {iterations: 3});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -605,7 +615,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe, {iterations: 1});
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {iterations: 1});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -626,7 +637,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe, {iterations: 0});
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {iterations: 0});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -644,7 +656,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
Animated.loop(animation as $FlowFixMe).start(cb);
|
||||
// $FlowFixMe[prop-missing]
|
||||
Animated.loop(animation).start(cb);
|
||||
expect(animation.start).toBeCalled();
|
||||
expect(animation.reset).toHaveBeenCalledTimes(1);
|
||||
expect(cb).not.toBeCalled();
|
||||
@@ -667,7 +680,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(animation as $FlowFixMe);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation);
|
||||
loop.start(cb);
|
||||
loop.stop();
|
||||
|
||||
@@ -689,10 +703,8 @@ describe('Animated', () => {
|
||||
};
|
||||
const cb = jest.fn();
|
||||
|
||||
const loop = Animated.loop(
|
||||
animation as $FlowFixMe,
|
||||
{resetBeforeIteration: false} as $FlowFixMe,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(animation, {resetBeforeIteration: false});
|
||||
|
||||
expect(animation.start).not.toBeCalled();
|
||||
|
||||
@@ -718,7 +730,8 @@ describe('Animated', () => {
|
||||
it('restarts sequence normally in a loop if resetBeforeIteration is false', () => {
|
||||
const anim1 = {start: jest.fn(), stop: jest.fn()};
|
||||
const anim2 = {start: jest.fn(), stop: jest.fn()};
|
||||
const seq = Animated.sequence([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.sequence([anim1, anim2]);
|
||||
|
||||
// $FlowFixMe[prop-missing]
|
||||
const loop = Animated.loop(seq, {resetBeforeIteration: false});
|
||||
@@ -748,7 +761,9 @@ describe('Animated', () => {
|
||||
it('works with an empty element in array', () => {
|
||||
const anim1 = {start: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
Animated.parallel([null as $FlowFixMe, anim1 as $FlowFixMe]).start(cb);
|
||||
// $FlowFixMe[incompatible-call]
|
||||
// $FlowFixMe[prop-missing]
|
||||
Animated.parallel([null, anim1]).start(cb);
|
||||
|
||||
expect(anim1.start).toBeCalled();
|
||||
anim1.start.mock.calls[0][0]({finished: true});
|
||||
@@ -761,7 +776,9 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const par = Animated.parallel([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
// $FlowFixMe[prop-missing]
|
||||
const par = Animated.parallel([anim1, anim2]);
|
||||
|
||||
expect(anim1.start).not.toBeCalled();
|
||||
expect(anim2.start).not.toBeCalled();
|
||||
@@ -784,7 +801,8 @@ describe('Animated', () => {
|
||||
const anim2 = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.parallel([anim1 as $FlowFixMe, anim2 as $FlowFixMe]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.parallel([anim1, anim2]);
|
||||
seq.start(cb);
|
||||
seq.stop();
|
||||
|
||||
@@ -805,11 +823,8 @@ describe('Animated', () => {
|
||||
const anim3 = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
|
||||
const seq = Animated.parallel([
|
||||
anim1 as $FlowFixMe,
|
||||
anim2 as $FlowFixMe,
|
||||
anim3 as $FlowFixMe,
|
||||
]);
|
||||
// $FlowFixMe[prop-missing]
|
||||
const seq = Animated.parallel([anim1, anim2, anim3]);
|
||||
seq.start(cb);
|
||||
|
||||
anim1.start.mock.calls[0][0]({finished: false});
|
||||
@@ -836,7 +851,8 @@ describe('Animated', () => {
|
||||
it('should call anim after delay in sequence', () => {
|
||||
const anim = {start: jest.fn(), stop: jest.fn()};
|
||||
const cb = jest.fn();
|
||||
Animated.sequence([Animated.delay(1000), anim as $FlowFixMe]).start(cb);
|
||||
// $FlowFixMe[prop-missing]
|
||||
Animated.sequence([Animated.delay(1000), anim]).start(cb);
|
||||
jest.runAllTimers();
|
||||
expect(anim.start.mock.calls.length).toBe(1);
|
||||
expect(cb).not.toBeCalled();
|
||||
|
||||
@@ -13,6 +13,7 @@ import type {AnimatedNodeConfig} from './AnimatedNode';
|
||||
import type {AnimatedStyleAllowlist} from './AnimatedStyle';
|
||||
|
||||
import NativeAnimatedHelper from '../../../src/private/animated/NativeAnimatedHelper';
|
||||
import * as ReactNativeFeatureFlags from '../../../src/private/featureflags/ReactNativeFeatureFlags';
|
||||
import {findNodeHandle} from '../../ReactNative/RendererProxy';
|
||||
import flattenStyle from '../../StyleSheet/flattenStyle';
|
||||
import {AnimatedEvent} from '../AnimatedEvent';
|
||||
@@ -57,7 +58,9 @@ function createAnimatedProps(
|
||||
// we propagate the flattened `style` object to the `props` object.
|
||||
const flatStyle = flattenStyle(value as $FlowFixMe);
|
||||
node = AnimatedStyle.from(flatStyle, allowlist?.style, value);
|
||||
staticValue = flatStyle;
|
||||
if (ReactNativeFeatureFlags.alwaysFlattenAnimatedStyles()) {
|
||||
staticValue = flatStyle;
|
||||
}
|
||||
}
|
||||
} else if (value instanceof AnimatedNode) {
|
||||
node = value;
|
||||
@@ -161,7 +164,9 @@ export default class AnimatedProps extends AnimatedNode {
|
||||
maybeNode.__replaceAnimatedNodeWithValues(mutableStyle);
|
||||
props[key] = maybeNode.__getValueForStyle(mutableStyle);
|
||||
} else {
|
||||
props[key] = flatStaticStyle;
|
||||
if (ReactNativeFeatureFlags.alwaysFlattenAnimatedStyles()) {
|
||||
props[key] = flatStaticStyle;
|
||||
}
|
||||
}
|
||||
} else if (maybeNode instanceof AnimatedNode) {
|
||||
props[key] = maybeNode.__getValue();
|
||||
|
||||
@@ -678,9 +678,7 @@ export interface ScrollViewProps
|
||||
* It's implemented using onLayout handler attached to the content container which this ScrollView renders.
|
||||
*
|
||||
*/
|
||||
onContentSizeChange?:
|
||||
| ((contentWidth: number, contentHeight: number) => void)
|
||||
| undefined;
|
||||
onContentSizeChange?: ((w: number, h: number) => void) | undefined;
|
||||
|
||||
/**
|
||||
* Fires at most once per frame during scrolling.
|
||||
|
||||
@@ -673,7 +673,7 @@ type ScrollViewBaseProps = $ReadOnly<{
|
||||
}>;
|
||||
|
||||
export type ScrollViewProps = $ReadOnly<{
|
||||
...Omit<ViewProps, 'experimental_accessibilityOrder'>,
|
||||
...ViewProps,
|
||||
...ScrollViewPropsIOS,
|
||||
...ScrollViewPropsAndroid,
|
||||
...ScrollViewBaseProps,
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
|
||||
import type {ColorValue} from '../../StyleSheet/StyleSheet';
|
||||
import type {NativeSyntheticEvent} from '../../Types/CoreEventTypes';
|
||||
import type {AccessibilityState} from '../View/ViewAccessibility';
|
||||
import type {ViewProps} from '../View/ViewPropTypes';
|
||||
|
||||
import StyleSheet from '../../StyleSheet/StyleSheet';
|
||||
@@ -232,7 +231,7 @@ const Switch: component(
|
||||
const _disabled =
|
||||
disabled != null ? disabled : accessibilityState?.disabled;
|
||||
|
||||
const _accessibilityState: ?AccessibilityState =
|
||||
const _accessibilityState =
|
||||
_disabled !== accessibilityState?.disabled
|
||||
? {...accessibilityState, disabled: _disabled}
|
||||
: accessibilityState;
|
||||
|
||||
@@ -1031,7 +1031,7 @@ type TextInputBaseProps = $ReadOnly<{
|
||||
}>;
|
||||
|
||||
export type TextInputProps = $ReadOnly<{
|
||||
...Omit<ViewProps, 'style' | 'experimental_accessibilityOrder'>,
|
||||
...Omit<ViewProps, 'style'>,
|
||||
...TextInputIOSProps,
|
||||
...TextInputAndroidProps,
|
||||
...TextInputBaseProps,
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
*/
|
||||
|
||||
import type {ColorValue} from '../../StyleSheet/StyleSheet';
|
||||
import type {AccessibilityState} from '../View/ViewAccessibility';
|
||||
import type {TouchableWithoutFeedbackProps} from './TouchableWithoutFeedback';
|
||||
|
||||
import View from '../../Components/View/View';
|
||||
@@ -310,7 +309,7 @@ class TouchableHighlightImpl extends React.Component<
|
||||
const {onBlur, onFocus, ...eventHandlersWithoutBlurAndFocus} =
|
||||
this.state.pressability.getEventHandlers();
|
||||
|
||||
const accessibilityState: ?AccessibilityState =
|
||||
const accessibilityState =
|
||||
this.props.disabled != null
|
||||
? {
|
||||
...this.props.accessibilityState,
|
||||
|
||||
+2
-2
@@ -24,7 +24,7 @@ import invariant from 'invariant';
|
||||
import * as React from 'react';
|
||||
import {cloneElement} from 'react';
|
||||
|
||||
type TouchableNativeFeedbackTVProps = {
|
||||
type TVProps = {
|
||||
/**
|
||||
* *(Apple TV only)* TV preferred focus (see documentation for the View component).
|
||||
*
|
||||
@@ -71,7 +71,7 @@ type TouchableNativeFeedbackTVProps = {
|
||||
|
||||
export type TouchableNativeFeedbackProps = $ReadOnly<{
|
||||
...TouchableWithoutFeedbackProps,
|
||||
...TouchableNativeFeedbackTVProps,
|
||||
...TVProps,
|
||||
/**
|
||||
* Determines the type of background drawable that's going to be used to display feedback.
|
||||
* It takes an object with type property and extra data depending on the type.
|
||||
|
||||
@@ -21,7 +21,7 @@ import flattenStyle from '../../StyleSheet/flattenStyle';
|
||||
import Platform from '../../Utilities/Platform';
|
||||
import * as React from 'react';
|
||||
|
||||
export type TouchableOpacityTVProps = $ReadOnly<{
|
||||
export type TVProps = $ReadOnly<{
|
||||
/**
|
||||
* *(Apple TV only)* TV preferred focus (see documentation for the View component).
|
||||
*
|
||||
@@ -79,7 +79,7 @@ type TouchableOpacityBaseProps = $ReadOnly<{
|
||||
|
||||
export type TouchableOpacityProps = $ReadOnly<{
|
||||
...TouchableWithoutFeedbackProps,
|
||||
...TouchableOpacityTVProps,
|
||||
...TVProps,
|
||||
...TouchableOpacityBaseProps,
|
||||
}>;
|
||||
|
||||
|
||||
+15
-6
@@ -11,6 +11,7 @@
|
||||
import type {AnyAttributeType} from '../../Renderer/shims/ReactNativeTypes';
|
||||
|
||||
import * as ReactNativeFeatureFlags from '../../../src/private/featureflags/ReactNativeFeatureFlags';
|
||||
import NativeReactNativeFeatureFlags from '../../../src/private/featureflags/specs/NativeReactNativeFeatureFlags';
|
||||
import processAspectRatio from '../../StyleSheet/processAspectRatio';
|
||||
import processBackgroundImage from '../../StyleSheet/processBackgroundImage';
|
||||
import processBoxShadow from '../../StyleSheet/processBoxShadow';
|
||||
@@ -122,9 +123,13 @@ const ReactNativeStyleAttributes: {[string]: AnyAttributeType, ...} = {
|
||||
/**
|
||||
* Filter
|
||||
*/
|
||||
filter: ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? true
|
||||
: {process: processFilter},
|
||||
filter:
|
||||
NativeReactNativeFeatureFlags != null &&
|
||||
ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? true
|
||||
: {
|
||||
process: processFilter,
|
||||
},
|
||||
|
||||
/**
|
||||
* MixBlendMode
|
||||
@@ -139,9 +144,13 @@ const ReactNativeStyleAttributes: {[string]: AnyAttributeType, ...} = {
|
||||
/*
|
||||
* BoxShadow
|
||||
*/
|
||||
boxShadow: ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? true
|
||||
: {process: processBoxShadow},
|
||||
boxShadow:
|
||||
NativeReactNativeFeatureFlags != null &&
|
||||
ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? true
|
||||
: {
|
||||
process: processBoxShadow,
|
||||
},
|
||||
|
||||
/**
|
||||
* Linear Gradient
|
||||
|
||||
@@ -105,7 +105,7 @@ function reportException(
|
||||
// we feed back into console.error, to make sure any methods that are
|
||||
// monkey patched on top of console.error are called when coming from
|
||||
// handleException
|
||||
console.error(e);
|
||||
console.error(data.message);
|
||||
}
|
||||
|
||||
if (__DEV__) {
|
||||
|
||||
@@ -133,7 +133,7 @@ function runExceptionsManagerTests() {
|
||||
);
|
||||
expect(exceptionData.isFatal).toBe(false);
|
||||
expect(logToConsoleInReact).toBe(false);
|
||||
expect(console.error).toBeCalledWith(error);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('does not pop frames off the stack with framesToPop', () => {
|
||||
@@ -163,10 +163,16 @@ function runExceptionsManagerTests() {
|
||||
expect(nativeReportException).toBeCalledTimes(1);
|
||||
exceptionData = nativeReportException.mock.calls[0][0];
|
||||
}
|
||||
const formattedMessage =
|
||||
'Error: ' +
|
||||
error.message +
|
||||
'\n\n' +
|
||||
'This error is located at:' +
|
||||
capturedErrorDefaults.componentStack;
|
||||
expect(getLineFromFrame(exceptionData.stack[0])).toBe(
|
||||
"const error = new Error('Some error happened');",
|
||||
);
|
||||
expect(console.error).toBeCalledWith(error);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('wraps string in an Error and sends to handleException', () => {
|
||||
@@ -205,13 +211,7 @@ function runExceptionsManagerTests() {
|
||||
);
|
||||
expect(exceptionData.isFatal).toBe(false);
|
||||
expect(logToConsoleInReact).toBe(false);
|
||||
expect(console.error).toBeCalledTimes(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBeInstanceOf(
|
||||
ExceptionsManager.SyntheticError,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0].toString()).toBe(message);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('reports "Unspecified error" if error is null', () => {
|
||||
@@ -249,15 +249,7 @@ function runExceptionsManagerTests() {
|
||||
);
|
||||
expect(exceptionData.isFatal).toBe(false);
|
||||
expect(logToConsoleInReact).toBe(false);
|
||||
expect(console.error).toBeCalledTimes(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBeInstanceOf(
|
||||
ExceptionsManager.SyntheticError,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0].toString()).toBe(
|
||||
'Unspecified error',
|
||||
);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('works with a frozen error object', () => {
|
||||
@@ -288,7 +280,7 @@ function runExceptionsManagerTests() {
|
||||
// No component stack.
|
||||
const formattedMessage = 'Error: ' + error.message;
|
||||
expect(exceptionData.message).toBe(formattedMessage);
|
||||
expect(console.error).toBeCalledWith(error);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('does not mutate the message', () => {
|
||||
@@ -320,7 +312,7 @@ function runExceptionsManagerTests() {
|
||||
'This error is located at:' +
|
||||
capturedErrorDefaults.componentStack;
|
||||
expect(exceptionData.message).toBe(formattedMessage);
|
||||
expect(console.error).toBeCalledWith(error);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
});
|
||||
|
||||
test('can safely process the same error multiple times', () => {
|
||||
@@ -368,7 +360,7 @@ function runExceptionsManagerTests() {
|
||||
);
|
||||
expect(exceptionData.isFatal).toBe(false);
|
||||
expect(logToConsoleInReact).toBe(false);
|
||||
expect(console.error).toBeCalledWith(error);
|
||||
expect(console.error).toBeCalledWith(formattedMessage);
|
||||
}
|
||||
});
|
||||
});
|
||||
@@ -672,7 +664,7 @@ function runExceptionsManagerTests() {
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0]).toHaveLength(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBe(error);
|
||||
expect(console.error.mock.calls[0][0]).toBe(formattedMessage);
|
||||
});
|
||||
|
||||
test('handling a non-fatal Error', () => {
|
||||
@@ -705,7 +697,7 @@ function runExceptionsManagerTests() {
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0]).toHaveLength(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBe(error);
|
||||
expect(console.error.mock.calls[0][0]).toBe(formattedMessage);
|
||||
});
|
||||
|
||||
test('handling a thrown string', () => {
|
||||
@@ -734,11 +726,7 @@ function runExceptionsManagerTests() {
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0]).toHaveLength(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBeInstanceOf(
|
||||
ExceptionsManager.SyntheticError,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0].toString()).toBe(message);
|
||||
expect(console.error.mock.calls[0]).toEqual([message]);
|
||||
});
|
||||
|
||||
test('does not pop frames off the stack with framesToPop', () => {
|
||||
@@ -771,7 +759,9 @@ function runExceptionsManagerTests() {
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0]).toHaveLength(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBe(error);
|
||||
expect(console.error.mock.calls[0]).toEqual([
|
||||
'Error: ' + error.message,
|
||||
]);
|
||||
});
|
||||
|
||||
test('logs fatal "warn"-type errors', () => {
|
||||
@@ -793,17 +783,19 @@ function runExceptionsManagerTests() {
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0]).toHaveLength(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(console.error.mock.calls[0][0]).toBe(error);
|
||||
expect(console.error.mock.calls[0]).toEqual([
|
||||
'Error: ' + error.message,
|
||||
]);
|
||||
});
|
||||
});
|
||||
|
||||
describe('unstable_setExceptionDecorator', () => {
|
||||
let mockConsoleError;
|
||||
let mockError;
|
||||
beforeEach(() => {
|
||||
// NOTE: We initialise a fresh mock every time using spyOn, above.
|
||||
// We can't use `console._errorOriginal` for this, because that's a bound
|
||||
// (=wrapped) version of the mock and Jest does not approve.
|
||||
mockConsoleError = console.error;
|
||||
mockError = console.error;
|
||||
ExceptionsManager.installConsoleErrorReporter();
|
||||
});
|
||||
|
||||
@@ -869,11 +861,15 @@ function runExceptionsManagerTests() {
|
||||
...beforeDecorator,
|
||||
message: 'decorated: ' + beforeDecorator.message,
|
||||
});
|
||||
expect(mockConsoleError).toBeCalledTimes(2);
|
||||
expect(mockError).toBeCalledTimes(2);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0]).toBe(error);
|
||||
expect(mockError.mock.calls[0][0]).toEqual(
|
||||
'Error: Some error happened',
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[1][0]).toBe(error);
|
||||
expect(mockError.mock.calls[1][0]).toMatch(
|
||||
'decorated: Error: Some error happened',
|
||||
);
|
||||
});
|
||||
|
||||
test('clearing a decorator', () => {
|
||||
@@ -897,9 +893,11 @@ function runExceptionsManagerTests() {
|
||||
expect(logBoxAddException).not.toBeCalled();
|
||||
expect(nativeReportException).toBeCalledTimes(1);
|
||||
}
|
||||
expect(mockConsoleError).toBeCalledTimes(1);
|
||||
expect(mockError).toBeCalledTimes(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0]).toBe(error);
|
||||
expect(mockError.mock.calls[0][0]).toEqual(
|
||||
'Error: Some error happened',
|
||||
);
|
||||
});
|
||||
|
||||
test('prevents decorator recursion from error handler', () => {
|
||||
@@ -930,13 +928,15 @@ function runExceptionsManagerTests() {
|
||||
/decorated: .*Some error happened/,
|
||||
);
|
||||
}
|
||||
expect(mockConsoleError).toBeCalledTimes(2);
|
||||
expect(mockError).toBeCalledTimes(2);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0]).toMatch(
|
||||
expect(mockError.mock.calls[0][0]).toMatch(
|
||||
/Logging an error within the decorator/,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[1][0]).toBe(error);
|
||||
expect(mockError.mock.calls[1][0]).toMatch(
|
||||
/decorated: .*Some error happened/,
|
||||
);
|
||||
});
|
||||
|
||||
test('prevents decorator recursion from console.error', () => {
|
||||
@@ -974,14 +974,14 @@ function runExceptionsManagerTests() {
|
||||
/decorated: .*Some error happened/,
|
||||
);
|
||||
}
|
||||
expect(mockConsoleError).toBeCalledTimes(2);
|
||||
expect(mockError).toBeCalledTimes(2);
|
||||
// console.error calls are chained without exception pre-processing, so decorator doesn't apply
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0].toString()).toMatch(
|
||||
expect(mockError.mock.calls[0][0].toString()).toMatch(
|
||||
/Error: Some error happened/,
|
||||
);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[1][0]).toMatch(
|
||||
expect(mockError.mock.calls[1][0]).toMatch(
|
||||
/Logging an error within the decorator/,
|
||||
);
|
||||
});
|
||||
@@ -1012,9 +1012,11 @@ function runExceptionsManagerTests() {
|
||||
/Error: Some error happened/,
|
||||
);
|
||||
}
|
||||
expect(mockConsoleError).toBeCalledTimes(1);
|
||||
expect(mockError).toBeCalledTimes(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0]).toBe(error);
|
||||
expect(mockError.mock.calls[0][0]).toMatch(
|
||||
/Error: Some error happened/,
|
||||
);
|
||||
});
|
||||
|
||||
test('can handle throwing decorators recursion when exception is logged', () => {
|
||||
@@ -1042,9 +1044,9 @@ function runExceptionsManagerTests() {
|
||||
/Error: Some error happened/,
|
||||
);
|
||||
}
|
||||
expect(mockConsoleError).toBeCalledTimes(1);
|
||||
expect(mockError).toBeCalledTimes(1);
|
||||
// $FlowFixMe[prop-missing]
|
||||
expect(mockConsoleError.mock.calls[0][0].toString()).toMatch(
|
||||
expect(mockError.mock.calls[0][0].toString()).toMatch(
|
||||
/Error: Some error happened/,
|
||||
);
|
||||
});
|
||||
|
||||
+4
-21
@@ -143,7 +143,10 @@ if (__DEV__) {
|
||||
// Get hostname from development server (packager)
|
||||
const devServer = getDevServer();
|
||||
const host = devServer.bundleLoadedFromServer
|
||||
? guessHostFromDevServerUrl(devServer.url)
|
||||
? devServer.url
|
||||
.replace(/https?:\/\//, '')
|
||||
.replace(/\/$/, '')
|
||||
.split(':')[0]
|
||||
: 'localhost';
|
||||
|
||||
// Read the optional global variable for backward compatibility.
|
||||
@@ -256,23 +259,3 @@ function readReloadAndProfileConfig(
|
||||
onReloadAndProfileFlagsReset,
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* This is a bad, no good, broken hack to get the host from a dev server URL for the purposes
|
||||
* of connecting to the legacy React DevTools socket (for the standalone react-devtools package).
|
||||
* It has too many bugs to list. Please don't use it in new code.
|
||||
*
|
||||
* The correct implementation would just be `return new URL(url).host`, but React Native does not
|
||||
* ship with a spec-compliant `URL` class yet. Alternatively, this can be deleted when we delete
|
||||
* `connectToWSBasedReactDevToolsFrontend`.
|
||||
*/
|
||||
function guessHostFromDevServerUrl(url: string): string {
|
||||
const hopefullyHostAndPort = url
|
||||
.replace(/https?:\/\//, '')
|
||||
.replace(/\/$/, '');
|
||||
// IPv6 addresses contain colons, so the split(':') below will return garbage.
|
||||
if (hopefullyHostAndPort.includes(']')) {
|
||||
return hopefullyHostAndPort.split(']')[0] + ']';
|
||||
}
|
||||
return hopefullyHostAndPort.split(':')[0];
|
||||
}
|
||||
|
||||
@@ -21,12 +21,19 @@ static inline RCTResizeMode RCTResizeModeFromUIViewContentMode(UIViewContentMode
|
||||
switch (mode) {
|
||||
case UIViewContentModeScaleToFill:
|
||||
return RCTResizeModeStretch;
|
||||
break;
|
||||
case UIViewContentModeScaleAspectFit:
|
||||
return RCTResizeModeContain;
|
||||
break;
|
||||
case UIViewContentModeScaleAspectFill:
|
||||
return RCTResizeModeCover;
|
||||
break;
|
||||
case UIViewContentModeCenter:
|
||||
return RCTResizeModeCenter;
|
||||
break;
|
||||
case UIViewContentModeTopLeft:
|
||||
return RCTResizeModeNone;
|
||||
break;
|
||||
case UIViewContentModeRedraw:
|
||||
case UIViewContentModeTop:
|
||||
case UIViewContentModeBottom:
|
||||
@@ -36,9 +43,6 @@ static inline RCTResizeMode RCTResizeModeFromUIViewContentMode(UIViewContentMode
|
||||
case UIViewContentModeBottomLeft:
|
||||
case UIViewContentModeBottomRight:
|
||||
return RCTResizeModeRepeat;
|
||||
case UIViewContentModeCenter:
|
||||
default:
|
||||
return RCTResizeModeCenter;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
'use strict';
|
||||
|
||||
import type {
|
||||
LayoutAnimationConfig,
|
||||
LayoutAnimationConfig as LayoutAnimationConfig_,
|
||||
LayoutAnimationProperty,
|
||||
LayoutAnimationType,
|
||||
} from '../Renderer/shims/ReactNativeTypes';
|
||||
@@ -29,7 +29,7 @@ export type {
|
||||
} from '../Renderer/shims/ReactNativeTypes';
|
||||
|
||||
// Reexport type
|
||||
export type {LayoutAnimationConfig} from '../Renderer/shims/ReactNativeTypes';
|
||||
export type LayoutAnimationConfig = LayoutAnimationConfig_;
|
||||
|
||||
export type LayoutAnimationTypes = $ReadOnly<{
|
||||
[type in LayoutAnimationType]: type,
|
||||
|
||||
+4
-4
@@ -33,14 +33,14 @@ const invariant = require('invariant');
|
||||
const VirtualizedList = VirtualizedLists.VirtualizedList;
|
||||
const defaultKeyExtractor = VirtualizedLists.keyExtractor;
|
||||
|
||||
type RequiredFlatListProps<ItemT> = {
|
||||
type RequiredProps<ItemT> = {
|
||||
/**
|
||||
* An array (or array-like list) of items to render. Other data types can be
|
||||
* used by targeting VirtualizedList directly.
|
||||
*/
|
||||
data: ?$ReadOnly<$ArrayLike<ItemT>>,
|
||||
};
|
||||
type OptionalFlatListProps<ItemT> = {
|
||||
type OptionalProps<ItemT> = {
|
||||
/**
|
||||
* Takes an item from `data` and renders it into the list. Example usage:
|
||||
*
|
||||
@@ -178,8 +178,8 @@ function isArrayLike(data: mixed): boolean {
|
||||
}
|
||||
|
||||
type FlatListBaseProps<ItemT> = {
|
||||
...RequiredFlatListProps<ItemT>,
|
||||
...OptionalFlatListProps<ItemT>,
|
||||
...RequiredProps<ItemT>,
|
||||
...OptionalProps<ItemT>,
|
||||
};
|
||||
|
||||
export type FlatListProps<ItemT> = {
|
||||
|
||||
+4
-4
@@ -39,7 +39,7 @@ export type {
|
||||
ScrollToLocationParamsType as SectionListScrollParams,
|
||||
};
|
||||
|
||||
type RequiredSectionListProps<ItemT, SectionT = DefaultSectionT> = {
|
||||
type RequiredProps<ItemT, SectionT = DefaultSectionT> = {
|
||||
/**
|
||||
* The actual data to render, akin to the `data` prop in [`<FlatList>`](https://reactnative.dev/docs/flatlist).
|
||||
*
|
||||
@@ -64,7 +64,7 @@ export type SectionListRenderItem<ItemT, SectionT = DefaultSectionT> = (
|
||||
info: SectionListRenderItemInfo<ItemT, SectionT>,
|
||||
) => React.Node | null;
|
||||
|
||||
type OptionalSectionListProps<ItemT, SectionT = DefaultSectionT> = {
|
||||
type OptionalProps<ItemT, SectionT = DefaultSectionT> = {
|
||||
/**
|
||||
* Default renderer for every item in every section. Can be over-ridden on a per-section basis.
|
||||
*/
|
||||
@@ -110,8 +110,8 @@ export type SectionListProps<ItemT, SectionT = DefaultSectionT> = {
|
||||
VirtualizedSectionListProps<ItemT, SectionT>,
|
||||
'getItem' | 'getItemCount' | 'renderItem' | 'keyExtractor',
|
||||
>,
|
||||
...RequiredSectionListProps<ItemT, SectionT>,
|
||||
...OptionalSectionListProps<ItemT, SectionT>,
|
||||
...RequiredProps<ItemT, SectionT>,
|
||||
...OptionalProps<ItemT, SectionT>,
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@@ -13,8 +13,7 @@
|
||||
import VirtualizedLists from '@react-native/virtualized-lists';
|
||||
|
||||
type VirtualizedListType = typeof VirtualizedLists.VirtualizedList;
|
||||
const VirtualizedListComponent: VirtualizedListType =
|
||||
VirtualizedLists.VirtualizedList;
|
||||
const VirtualizedList: VirtualizedListType = VirtualizedLists.VirtualizedList;
|
||||
|
||||
export type {
|
||||
ListRenderItemInfo,
|
||||
@@ -22,4 +21,4 @@ export type {
|
||||
Separators,
|
||||
VirtualizedListProps,
|
||||
} from '@react-native/virtualized-lists';
|
||||
export default VirtualizedListComponent;
|
||||
export default VirtualizedList;
|
||||
|
||||
+6
-6
@@ -9,8 +9,8 @@
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
import type {StackFrame} from '../../../Core/NativeExceptionsManager';
|
||||
import type {ExtendedExceptionData} from '../parseLogBoxLog';
|
||||
|
||||
const {
|
||||
parseLogBoxException,
|
||||
@@ -296,7 +296,7 @@ describe('parseLogBoxLog', () => {
|
||||
});
|
||||
|
||||
it('parses a babel transform syntax error', () => {
|
||||
const error: ExtendedExceptionData = {
|
||||
const error = {
|
||||
message: `
|
||||
|
||||
197 | });
|
||||
@@ -344,7 +344,7 @@ describe('parseLogBoxLog', () => {
|
||||
});
|
||||
|
||||
it('parses an invalid require syntax error', () => {
|
||||
const error: ExtendedExceptionData = {
|
||||
const error = {
|
||||
message: `Unable to resolve module \`ListCellx\` from /path/to/file.js: ListCellx could not be found within the project.
|
||||
|
||||
If you are sure the module exists, try these steps:
|
||||
@@ -414,7 +414,7 @@ If you are sure the module exists, try these steps:
|
||||
});
|
||||
|
||||
it('parses a reference error', () => {
|
||||
const error: ExtendedExceptionData = {
|
||||
const error = {
|
||||
message: `
|
||||
|
||||
197 | });
|
||||
@@ -462,7 +462,7 @@ If you are sure the module exists, try these steps:
|
||||
});
|
||||
|
||||
it('parses a babel codeframe error', () => {
|
||||
const error: ExtendedExceptionData = {
|
||||
const error = {
|
||||
message: `TransformError RKJSModules/Apps/CrashReact/CrashReactApp.js: /path/to/RKJSModules/Apps/CrashReact/CrashReactApp.js: The first argument to \`fbRemoteAsset\` is "null_state_glyphs", but the requested asset is missing from the local metadata. Either the asset does not exist or the metadata is not up-to-date.
|
||||
|
||||
Please follow the instructions at: fburl.com/rn-remote-assets
|
||||
@@ -514,7 +514,7 @@ Please follow the instructions at: fburl.com/rn-remote-assets`,
|
||||
});
|
||||
|
||||
it('parses a babel codeframe error with ansi', () => {
|
||||
const error: ExtendedExceptionData = {
|
||||
const error = {
|
||||
message: `TransformError RKJSModules/Apps/CrashReact/CrashReactApp.js: /path/to/RKJSModules/Apps/CrashReact/CrashReactApp.js: The first argument to \`fbRemoteAsset\` is "null_state_glyphs", but the requested asset is missing from the local metadata. Either the asset does not exist or the metadata is not up-to-date.
|
||||
|
||||
Please follow the instructions at: fburl.com/rn-remote-assets
|
||||
|
||||
+12
-6
@@ -35,12 +35,18 @@ exports[`LogBoxInspectorSourceMapStatus should render for failed 1`] = `
|
||||
}
|
||||
}
|
||||
style={
|
||||
Object {
|
||||
"height": 14,
|
||||
"marginEnd": 4,
|
||||
"tintColor": "rgba(243, 83, 105, 1)",
|
||||
"width": 16,
|
||||
}
|
||||
Array [
|
||||
Object {
|
||||
"height": 14,
|
||||
"marginEnd": 4,
|
||||
"tintColor": "rgba(255, 255, 255, 0.4)",
|
||||
"width": 16,
|
||||
},
|
||||
Object {
|
||||
"tintColor": "rgba(243, 83, 105, 1)",
|
||||
},
|
||||
null,
|
||||
]
|
||||
}
|
||||
/>
|
||||
<Text
|
||||
|
||||
@@ -781,7 +781,7 @@ describe('LogBox', () => {
|
||||
'\n\nCheck the top-level render call using <TestComponent>. ' +
|
||||
'It was passed a child from TestComponent. ' +
|
||||
'See https://react.dev/link/warning-keys for more information.',
|
||||
componentStackFrames: ['<anonymous />', '<TestComponent />'],
|
||||
componentStackFrames: [],
|
||||
isDismissable: true,
|
||||
});
|
||||
});
|
||||
@@ -818,7 +818,7 @@ describe('LogBox', () => {
|
||||
title: 'Console Error',
|
||||
message:
|
||||
'Invalid prop `invalid` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.',
|
||||
componentStackFrames: ['<TestComponent />'],
|
||||
componentStackFrames: [],
|
||||
isDismissable: true,
|
||||
});
|
||||
});
|
||||
|
||||
@@ -117,7 +117,7 @@ function findLogBoxInspectorUI(node: ReadOnlyElement): InspectorUI {
|
||||
// anonymous
|
||||
// MockConsoleErrorForTesting <-- mockConsoleIndex
|
||||
// ManualConsoleError
|
||||
// react_stack_bottom_frame <-- react bottom frame
|
||||
// reactStackBottomFrame <-- react bottom frame
|
||||
// <root>
|
||||
//
|
||||
// Becomes:
|
||||
@@ -129,19 +129,9 @@ function getStackFrames(node: ReadOnlyElement): ?Array<string> {
|
||||
const mockConsoleIndex = text.includes('MockConsoleErrorForTesting')
|
||||
? text.indexOf('MockConsoleErrorForTesting') + 1
|
||||
: 0;
|
||||
let bottomFrameIndex = text.indexOf('react_stack_bottom_frame');
|
||||
if (bottomFrameIndex === -1) {
|
||||
// react@19.1.0 with @babel/plugin-transform-function-name
|
||||
bottomFrameIndex = text.indexOf('reactStackBottomFrame');
|
||||
}
|
||||
if (bottomFrameIndex === -1) {
|
||||
// react@19.1.0 without @babel/plugin-transform-function-name
|
||||
bottomFrameIndex = text.indexOf('react-stack-bottom-frame');
|
||||
}
|
||||
if (bottomFrameIndex === -1) {
|
||||
bottomFrameIndex = text.length;
|
||||
}
|
||||
|
||||
const bottomFrameIndex = text.includes('reactStackBottomFrame')
|
||||
? text.indexOf('reactStackBottomFrame')
|
||||
: text.length;
|
||||
return text.slice(mockConsoleIndex, bottomFrameIndex);
|
||||
}
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
import type {PartialViewConfigWithoutName} from './PlatformBaseViewConfig';
|
||||
|
||||
import * as ReactNativeFeatureFlags from '../../src/private/featureflags/ReactNativeFeatureFlags';
|
||||
import NativeReactNativeFeatureFlags from '../../src/private/featureflags/specs/NativeReactNativeFeatureFlags';
|
||||
import ReactNativeStyleAttributes from '../Components/View/ReactNativeStyleAttributes';
|
||||
import {DynamicallyInjectedByGestureHandler} from './ViewConfigIgnore';
|
||||
|
||||
@@ -182,12 +183,20 @@ const validAttributesForNonEventProps = {
|
||||
experimental_backgroundImage: {
|
||||
process: require('../StyleSheet/processBackgroundImage').default,
|
||||
},
|
||||
boxShadow: ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? (true as const)
|
||||
: {process: require('../StyleSheet/processBoxShadow').default},
|
||||
filter: ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? (true as const)
|
||||
: {process: require('../StyleSheet/processFilter').default},
|
||||
boxShadow:
|
||||
NativeReactNativeFeatureFlags != null &&
|
||||
ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? (true as const)
|
||||
: {
|
||||
process: require('../StyleSheet/processBoxShadow').default,
|
||||
},
|
||||
filter:
|
||||
NativeReactNativeFeatureFlags != null &&
|
||||
ReactNativeFeatureFlags.enableNativeCSSParsing()
|
||||
? (true as const)
|
||||
: {
|
||||
process: require('../StyleSheet/processFilter').default,
|
||||
},
|
||||
mixBlendMode: true,
|
||||
isolation: true,
|
||||
opacity: true,
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user