react-native-windows 0.67.11 → 0.67.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.json CHANGED
@@ -1,6 +1,114 @@
1
1
  {
2
2
  "name": "react-native-windows",
3
3
  "entries": [
4
+ {
5
+ "date": "Mon, 25 Jul 2022 15:12:24 GMT",
6
+ "tag": "react-native-windows_v0.67.14",
7
+ "version": "0.67.14",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "author": "tatianakapos@microsoft.com",
12
+ "package": "react-native-windows",
13
+ "commit": "2dbb5b9f2e1d1f6b083fe3c5f24dad3fe1792378",
14
+ "comment": "Implement no-hide-accessibility"
15
+ }
16
+ ]
17
+ }
18
+ },
19
+ {
20
+ "date": "Mon, 11 Jul 2022 15:11:12 GMT",
21
+ "tag": "react-native-windows_v0.67.13",
22
+ "version": "0.67.13",
23
+ "comments": {
24
+ "patch": [
25
+ {
26
+ "author": "jthysell@microsoft.com",
27
+ "package": "react-native-windows",
28
+ "commit": "not available",
29
+ "comment": "[0.67] CG updates for 6/28/22"
30
+ }
31
+ ]
32
+ }
33
+ },
34
+ {
35
+ "date": "Mon, 11 Jul 2022 15:10:53 GMT",
36
+ "tag": "react-native-windows_v0.67.13",
37
+ "version": "0.67.13",
38
+ "comments": {
39
+ "patch": [
40
+ {
41
+ "author": "jthysell@microsoft.com",
42
+ "package": "react-native-windows",
43
+ "commit": "9d7ecd90a63f0707fc85fadde8ea31e4ebdb2557",
44
+ "comment": "[0.67] CG updates for 6/28/22"
45
+ }
46
+ ]
47
+ }
48
+ },
49
+ {
50
+ "date": "Mon, 27 Jun 2022 15:07:52 GMT",
51
+ "tag": "react-native-windows_v0.67.12",
52
+ "version": "0.67.12",
53
+ "comments": {
54
+ "patch": [
55
+ {
56
+ "author": "julio.rocha@microsoft.com",
57
+ "package": "react-native-windows",
58
+ "commit": "not available",
59
+ "comment": "Enable Blob module with runtime option"
60
+ },
61
+ {
62
+ "author": "hpratt@microsoft.com",
63
+ "package": "react-native-windows",
64
+ "commit": "not available",
65
+ "comment": "Stop compiling yoga.cpp with /fp:strict. Doing so caused layout issues if Yoga code ran with the processor's rounding mode set to round down, due to NAN being defined in math.h as: ``` (float)(INFINITY * 0.0f) ``` Which macro-expands to: ``` (float)(((float)(1e+300 * 1e+300)) * 0.0f) ``` Which evaluates as follows: ``` (float)(((float)(inf.double)) * 0.0f) (float)(FLT_MAX * 0.0f) // Casting an infinite double to a float yields // FLT_MAX! (float)0.0f ```"
66
+ }
67
+ ]
68
+ }
69
+ },
70
+ {
71
+ "date": "Mon, 27 Jun 2022 15:07:38 GMT",
72
+ "tag": "react-native-windows_v0.67.12",
73
+ "version": "0.67.12",
74
+ "comments": {
75
+ "patch": [
76
+ {
77
+ "author": "julio.rocha@microsoft.com",
78
+ "package": "react-native-windows",
79
+ "commit": "d5a8dff5f3fbb23b01338e22cbe313bc6f0fa2b8",
80
+ "comment": "Enable Blob module with runtime option"
81
+ },
82
+ {
83
+ "author": "hpratt@microsoft.com",
84
+ "package": "react-native-windows",
85
+ "commit": "d676dce0d3681fac1cdbd5e75a78be7667704193",
86
+ "comment": "Stop compiling yoga.cpp with /fp:strict. Doing so caused layout issues if Yoga code ran with the processor's rounding mode set to round down, due to NAN being defined in math.h as: ``` (float)(INFINITY * 0.0f) ``` Which macro-expands to: ``` (float)(((float)(1e+300 * 1e+300)) * 0.0f) ``` Which evaluates as follows: ``` (float)(((float)(inf.double)) * 0.0f) (float)(FLT_MAX * 0.0f) // Casting an infinite double to a float yields // FLT_MAX! (float)0.0f ```"
87
+ }
88
+ ]
89
+ }
90
+ },
91
+ {
92
+ "date": "Mon, 20 Jun 2022 15:08:18 GMT",
93
+ "tag": "react-native-windows_v0.67.11",
94
+ "version": "0.67.11",
95
+ "comments": {
96
+ "patch": [
97
+ {
98
+ "author": "vmorozov@microsoft.com",
99
+ "package": "react-native-windows",
100
+ "commit": "not available",
101
+ "comment": "Fix use of [[maybe_unused]] attribute"
102
+ },
103
+ {
104
+ "author": "vmorozov@microsoft.com",
105
+ "package": "react-native-windows",
106
+ "commit": "not available",
107
+ "comment": "Fix ExecuteJsi on instance shutdown"
108
+ }
109
+ ]
110
+ }
111
+ },
4
112
  {
5
113
  "date": "Mon, 20 Jun 2022 15:08:04 GMT",
6
114
  "tag": "react-native-windows_v0.67.11",
package/CHANGELOG.md CHANGED
@@ -1,18 +1,69 @@
1
1
  # Change Log - react-native-windows
2
2
 
3
- This log was last generated on Mon, 20 Jun 2022 15:08:04 GMT and should not be manually modified.
3
+ This log was last generated on Mon, 25 Jul 2022 15:12:24 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
- ## 0.67.11
7
+ ## 0.67.14
8
8
 
9
- Mon, 20 Jun 2022 15:08:04 GMT
9
+ Mon, 25 Jul 2022 15:12:24 GMT
10
10
 
11
11
  ### Patches
12
12
 
13
- - Fix use of [[maybe_unused]] attribute (vmorozov@microsoft.com)
14
- - Fix ExecuteJsi on instance shutdown (vmorozov@microsoft.com)
13
+ - Implement no-hide-accessibility (tatianakapos@microsoft.com)
15
14
 
15
+ ## 0.67.13
16
+
17
+ Mon, 11 Jul 2022 15:11:12 GMT
18
+
19
+ ### Patches
20
+
21
+ - [0.67] CG updates for 6/28/22 (jthysell@microsoft.com)
22
+
23
+ ## 0.67.13
24
+
25
+ Mon, 11 Jul 2022 15:10:53 GMT
26
+
27
+ ### Patches
28
+
29
+ - [0.67] CG updates for 6/28/22 (jthysell@microsoft.com)
30
+
31
+ ## 0.67.12
32
+
33
+ Mon, 27 Jun 2022 15:07:52 GMT
34
+
35
+ ### Patches
36
+
37
+ - Enable Blob module with runtime option (julio.rocha@microsoft.com)
38
+ - Stop compiling yoga.cpp with /fp:strict. Doing so caused layout issues if Yoga code ran with the processor's rounding mode set to round down, due to NAN being defined in math.h as: ``` (float)(INFINITY * 0.0f) ``` Which macro-expands to: ``` (float)(((float)(1e+300 * 1e+300)) * 0.0f) ``` Which evaluates as follows: ``` (float)(((float)(inf.double)) * 0.0f) (float)(FLT_MAX * 0.0f) // Casting an infinite double to a float yields // FLT_MAX! (float)0.0f ``` (hpratt@microsoft.com)
39
+
40
+ ## 0.67.12
41
+
42
+ Mon, 27 Jun 2022 15:07:38 GMT
43
+
44
+ ### Patches
45
+
46
+ - Enable Blob module with runtime option (julio.rocha@microsoft.com)
47
+ - Stop compiling yoga.cpp with /fp:strict. Doing so caused layout issues if Yoga code ran with the processor's rounding mode set to round down, due to NAN being defined in math.h as: ``` (float)(INFINITY * 0.0f) ``` Which macro-expands to: ``` (float)(((float)(1e+300 * 1e+300)) * 0.0f) ``` Which evaluates as follows: ``` (float)(((float)(inf.double)) * 0.0f) (float)(FLT_MAX * 0.0f) // Casting an infinite double to a float yields // FLT_MAX! (float)0.0f ``` (hpratt@microsoft.com)
48
+
49
+ ## 0.67.11
50
+
51
+ Mon, 20 Jun 2022 15:08:18 GMT
52
+
53
+ ### Patches
54
+
55
+ - Fix use of [[maybe_unused]] attribute (vmorozov@microsoft.com)
56
+ - Fix ExecuteJsi on instance shutdown (vmorozov@microsoft.com)
57
+
58
+ ## 0.67.11
59
+
60
+ Mon, 20 Jun 2022 15:08:04 GMT
61
+
62
+ ### Patches
63
+
64
+ - Fix use of [[maybe_unused]] attribute (vmorozov@microsoft.com)
65
+ - Fix ExecuteJsi on instance shutdown (vmorozov@microsoft.com)
66
+
16
67
  ## 0.67.10
17
68
 
18
69
  Mon, 30 May 2022 15:09:46 GMT
@@ -75,6 +75,26 @@ const View: React.AbstractComponent<
75
75
  props.onKeyUpCapture && props.onKeyUpCapture(event);
76
76
  };
77
77
 
78
+ // [Windows
79
+ const childrenWithImportantForAccessibility = children => {
80
+ return React.Children.map(children, child => {
81
+ if (React.isValidElement(child)) {
82
+ if (child.props.children) {
83
+ return React.cloneElement(child, {
84
+ accessible: false,
85
+ children: childrenWithImportantForAccessibility(
86
+ child.props.children,
87
+ ),
88
+ });
89
+ } else {
90
+ return React.cloneElement(child, {accessible: false});
91
+ }
92
+ }
93
+ return child;
94
+ });
95
+ };
96
+ // Windows]
97
+
78
98
  return (
79
99
  // [Windows
80
100
  // In core this is a TextAncestor.Provider value={false} See
@@ -94,6 +114,18 @@ const View: React.AbstractComponent<
94
114
  onKeyDownCapture={_keyDownCapture}
95
115
  onKeyUp={_keyUp}
96
116
  onKeyUpCapture={_keyUpCapture}
117
+ // [Windows
118
+ accessible={
119
+ props.importantForAccessibility === 'no-hide-descendants'
120
+ ? false
121
+ : props.accessible
122
+ }
123
+ children={
124
+ props.importantForAccessibility === 'no-hide-descendants'
125
+ ? childrenWithImportantForAccessibility(props.children)
126
+ : props.children
127
+ }
128
+ // Windows]
97
129
  />
98
130
  );
99
131
  }}
@@ -10,10 +10,10 @@
10
10
  -->
11
11
  <Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
12
12
  <PropertyGroup>
13
- <ReactNativeWindowsVersion>0.67.11</ReactNativeWindowsVersion>
13
+ <ReactNativeWindowsVersion>0.67.14</ReactNativeWindowsVersion>
14
14
  <ReactNativeWindowsMajor>0</ReactNativeWindowsMajor>
15
15
  <ReactNativeWindowsMinor>67</ReactNativeWindowsMinor>
16
- <ReactNativeWindowsPatch>11</ReactNativeWindowsPatch>
16
+ <ReactNativeWindowsPatch>14</ReactNativeWindowsPatch>
17
17
  <ReactNativeWindowsCanary>false</ReactNativeWindowsCanary>
18
18
  </PropertyGroup>
19
19
  </Project>
@@ -72,10 +72,6 @@
72
72
  <DisableSpecificWarnings>4715;4251;4800;4804;4305;4722;%(DisableSpecificWarnings)</DisableSpecificWarnings>
73
73
  <PreprocessToFile>false</PreprocessToFile>
74
74
  <ForcedIncludeFiles>pch.h;%(ForcedIncludeFiles)</ForcedIncludeFiles>
75
- <!--
76
- Using Strict FloatingPointModel on x64 to workaround a compiler issue, See https://github.com/microsoft/react-native-windows/issues/4122
77
- -->
78
- <FloatingPointModel Condition="'$(Platform)' == 'x64'">Strict</FloatingPointModel>
79
75
  </ClCompile>
80
76
  <Link>
81
77
  <IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
@@ -0,0 +1,204 @@
1
+ /*
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+
8
+ #pragma once
9
+
10
+ #ifdef __cplusplus
11
+
12
+ #ifdef __cpp_lib_bit_cast
13
+ #include <bit>
14
+ #endif
15
+ #include "YGValue.h"
16
+ #include "YGMacros.h"
17
+ #include <cmath>
18
+ #include <cstdint>
19
+ #include <limits>
20
+
21
+ static_assert(
22
+ std::numeric_limits<float>::is_iec559,
23
+ "facebook::yoga::detail::CompactValue only works with IEEE754 floats");
24
+
25
+ #ifdef YOGA_COMPACT_VALUE_TEST
26
+ #define VISIBLE_FOR_TESTING public:
27
+ #else
28
+ #define VISIBLE_FOR_TESTING private:
29
+ #endif
30
+
31
+ namespace facebook {
32
+ namespace yoga {
33
+ namespace detail {
34
+
35
+ // This class stores YGValue in 32 bits.
36
+ // - The value does not matter for Undefined and Auto. NaNs are used for their
37
+ // representation.
38
+ // - To differentiate between Point and Percent, one exponent bit is used.
39
+ // Supported the range [0x40, 0xbf] (0xbf is inclusive for point, but
40
+ // exclusive for percent).
41
+ // - Value ranges:
42
+ // points: 1.08420217e-19f to 36893485948395847680
43
+ // 0x00000000 0x3fffffff
44
+ // percent: 1.08420217e-19f to 18446742974197923840
45
+ // 0x40000000 0x7f7fffff
46
+ // - Zero is supported, negative zero is not
47
+ // - values outside of the representable range are clamped
48
+ class YOGA_EXPORT CompactValue {
49
+ friend constexpr bool operator==(CompactValue, CompactValue) noexcept;
50
+
51
+ public:
52
+ static constexpr auto LOWER_BOUND = 1.08420217e-19f;
53
+ static constexpr auto UPPER_BOUND_POINT = 36893485948395847680.0f;
54
+ static constexpr auto UPPER_BOUND_PERCENT = 18446742974197923840.0f;
55
+
56
+ template <YGUnit Unit>
57
+ static CompactValue of(float value) noexcept {
58
+ if (value == 0.0f || (value < LOWER_BOUND && value > -LOWER_BOUND)) {
59
+ constexpr auto zero =
60
+ Unit == YGUnitPercent ? ZERO_BITS_PERCENT : ZERO_BITS_POINT;
61
+ return {zero};
62
+ }
63
+
64
+ constexpr auto upperBound = Unit == YGUnitPercent ? UPPER_BOUND_PERCENT : UPPER_BOUND_POINT;
65
+ if (value > upperBound || value < -upperBound) {
66
+ value = copysignf(upperBound, value);
67
+ }
68
+
69
+ uint32_t unitBit = Unit == YGUnitPercent ? PERCENT_BIT : 0;
70
+ auto data = asU32(value);
71
+ data -= BIAS;
72
+ data |= unitBit;
73
+ return {data};
74
+ }
75
+
76
+ template <YGUnit Unit>
77
+ static CompactValue ofMaybe(float value) noexcept {
78
+ return std::isnan(value) || std::isinf(value) ? ofUndefined() : of<Unit>(value);
79
+ }
80
+
81
+ static constexpr CompactValue ofZero() noexcept {
82
+ return CompactValue{ZERO_BITS_POINT};
83
+ }
84
+
85
+ static constexpr CompactValue ofUndefined() noexcept {
86
+ return CompactValue{};
87
+ }
88
+
89
+ static constexpr CompactValue ofAuto() noexcept {
90
+ return CompactValue{AUTO_BITS};
91
+ }
92
+
93
+ constexpr CompactValue() noexcept : repr_(0x7FC00000) {}
94
+
95
+ CompactValue(const YGValue &x) noexcept : repr_(uint32_t{0}) {
96
+ switch (x.unit) {
97
+ case YGUnitUndefined:
98
+ *this = ofUndefined();
99
+ break;
100
+ case YGUnitAuto:
101
+ *this = ofAuto();
102
+ break;
103
+ case YGUnitPoint:
104
+ *this = of<YGUnitPoint>(x.value);
105
+ break;
106
+ case YGUnitPercent:
107
+ *this = of<YGUnitPercent>(x.value);
108
+ break;
109
+ }
110
+ }
111
+
112
+ operator YGValue() const noexcept {
113
+ switch (repr_) {
114
+ case AUTO_BITS:
115
+ return YGValueAuto;
116
+ case ZERO_BITS_POINT:
117
+ return YGValue{0.0f, YGUnitPoint};
118
+ case ZERO_BITS_PERCENT:
119
+ return YGValue{0.0f, YGUnitPercent};
120
+ }
121
+
122
+ if (std::isnan(asFloat(repr_))) {
123
+ return YGValueUndefined;
124
+ }
125
+
126
+ auto data = repr_;
127
+ data &= ~PERCENT_BIT;
128
+ data += BIAS;
129
+
130
+ return YGValue{asFloat(data), repr_ & 0x40000000 ? YGUnitPercent : YGUnitPoint};
131
+ }
132
+
133
+ bool isUndefined() const noexcept {
134
+ return (repr_ != AUTO_BITS && repr_ != ZERO_BITS_POINT && repr_ != ZERO_BITS_PERCENT && std::isnan(asFloat(repr_)));
135
+ }
136
+
137
+ bool isAuto() const noexcept {
138
+ return repr_ == AUTO_BITS;
139
+ }
140
+
141
+ private:
142
+ uint32_t repr_;
143
+
144
+ static constexpr uint32_t BIAS = 0x20000000;
145
+ static constexpr uint32_t PERCENT_BIT = 0x40000000;
146
+
147
+ // these are signaling NaNs with specific bit pattern as payload they will be
148
+ // silenced whenever going through an FPU operation on ARM + x86
149
+ static constexpr uint32_t AUTO_BITS = 0x7faaaaaa;
150
+ static constexpr uint32_t ZERO_BITS_POINT = 0x7f8f0f0f;
151
+ static constexpr uint32_t ZERO_BITS_PERCENT = 0x7f80f0f0;
152
+
153
+ constexpr CompactValue(uint32_t data) noexcept : repr_(data) {}
154
+
155
+ VISIBLE_FOR_TESTING uint32_t repr() {
156
+ return repr_;
157
+ }
158
+
159
+ static uint32_t asU32(float f) {
160
+ #ifdef __cpp_lib_bit_cast
161
+ return std::bit_cast<uint32_t>(f);
162
+ #else
163
+ uint32_t u;
164
+ static_assert(sizeof(u) == sizeof(f));
165
+ std::memcpy(&u, &f, sizeof(f));
166
+ return u;
167
+ #endif
168
+ }
169
+
170
+ static float asFloat(uint32_t u) {
171
+ #ifdef __cpp_lib_bit_cast
172
+ return std::bit_cast<float>(data);
173
+ #else
174
+ float f;
175
+ static_assert(sizeof(f) == sizeof(u));
176
+ std::memcpy(&f, &u, sizeof(u));
177
+ return f;
178
+ #endif
179
+ }
180
+ };
181
+
182
+
183
+ template <>
184
+ CompactValue CompactValue::of<YGUnitUndefined>(float) noexcept = delete;
185
+ template <>
186
+ CompactValue CompactValue::of<YGUnitAuto>(float) noexcept = delete;
187
+ template <>
188
+ CompactValue CompactValue::ofMaybe<YGUnitUndefined>(float) noexcept = delete;
189
+ template <>
190
+ CompactValue CompactValue::ofMaybe<YGUnitAuto>(float) noexcept = delete;
191
+
192
+ constexpr bool operator==(CompactValue a, CompactValue b) noexcept {
193
+ return a.repr_ == b.repr_;
194
+ }
195
+
196
+ constexpr bool operator!=(CompactValue a, CompactValue b) noexcept {
197
+ return !(a == b);
198
+ }
199
+
200
+ } // namespace detail
201
+ } // namespace yoga
202
+ } // namespace facebook
203
+
204
+ #endif
@@ -68,7 +68,7 @@ void WinRTHttpResource::SendRequest(
68
68
  bool withCredentials,
69
69
  std::function<void(int64_t)> &&callback) noexcept /*override*/ {
70
70
  // Enforce supported args
71
- assert(responseType == "text" || responseType == "base64" | responseType == "blob");
71
+ assert(responseType == "text" || responseType == "base64" || responseType == "blob");
72
72
 
73
73
  if (callback) {
74
74
  callback(requestId);
@@ -702,17 +702,20 @@ std::vector<std::unique_ptr<NativeModule>> InstanceImpl::GetDefaultNativeModules
702
702
  []() { return std::make_unique<StatusBarManagerModule>(); },
703
703
  nativeQueue));
704
704
 
705
- modules.push_back(std::make_unique<CxxNativeModule>(
706
- m_innerInstance,
707
- Microsoft::React::GetBlobModuleName(),
708
- [transitionalProps]() { return Microsoft::React::CreateBlobModule(transitionalProps); },
709
- nativeQueue));
705
+ // #10036 - Blob module not supported in UWP. Need to define property bag lifetime and onwership.
706
+ if (Microsoft::React::GetRuntimeOptionBool("Blob.EnableModule")) {
707
+ modules.push_back(std::make_unique<CxxNativeModule>(
708
+ m_innerInstance,
709
+ Microsoft::React::GetBlobModuleName(),
710
+ [transitionalProps]() { return Microsoft::React::CreateBlobModule(transitionalProps); },
711
+ nativeQueue));
710
712
 
711
- modules.push_back(std::make_unique<CxxNativeModule>(
712
- m_innerInstance,
713
- Microsoft::React::GetFileReaderModuleName(),
714
- [transitionalProps]() { return Microsoft::React::CreateFileReaderModule(transitionalProps); },
715
- nativeQueue));
713
+ modules.push_back(std::make_unique<CxxNativeModule>(
714
+ m_innerInstance,
715
+ Microsoft::React::GetFileReaderModuleName(),
716
+ [transitionalProps]() { return Microsoft::React::CreateFileReaderModule(transitionalProps); },
717
+ nativeQueue));
718
+ }
716
719
 
717
720
  return modules;
718
721
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-windows",
3
- "version": "0.67.11",
3
+ "version": "0.67.14",
4
4
  "license": "MIT",
5
5
  "repository": {
6
6
  "type": "git",