@fluentui-react-native/focus-zone 0.10.23 → 0.10.25

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
@@ -2,7 +2,43 @@
2
2
  "name": "@fluentui-react-native/focus-zone",
3
3
  "entries": [
4
4
  {
5
- "date": "Mon, 17 Oct 2022 17:50:04 GMT",
5
+ "date": "Thu, 20 Oct 2022 18:28:41 GMT",
6
+ "tag": "@fluentui-react-native/focus-zone_v0.10.25",
7
+ "version": "0.10.25",
8
+ "comments": {
9
+ "patch": [
10
+ {
11
+ "author": "sanajmi@microsoft.com",
12
+ "package": "@fluentui-react-native/focus-zone",
13
+ "commit": "860fa561d4887cee5f1eb2aa88ce7064620bcae1",
14
+ "comment": "FocusZone (macOS): Calculate distance from origin"
15
+ },
16
+ {
17
+ "author": "beachball",
18
+ "package": "@fluentui-react-native/focus-zone",
19
+ "comment": "Bump @fluentui-react-native/interactive-hooks to v0.19.1",
20
+ "commit": "34dd5c82030fc890c2133c9190d17bdcba6e173e"
21
+ }
22
+ ]
23
+ }
24
+ },
25
+ {
26
+ "date": "Tue, 18 Oct 2022 04:06:27 GMT",
27
+ "tag": "@fluentui-react-native/focus-zone_v0.10.24",
28
+ "version": "0.10.24",
29
+ "comments": {
30
+ "patch": [
31
+ {
32
+ "author": "beachball",
33
+ "package": "@fluentui-react-native/focus-zone",
34
+ "comment": "Bump @fluentui-react-native/interactive-hooks to v0.19.0",
35
+ "commit": "9e7902b05f12947fdb475cdd0fc6fc7d7db774a5"
36
+ }
37
+ ]
38
+ }
39
+ },
40
+ {
41
+ "date": "Mon, 17 Oct 2022 17:52:49 GMT",
6
42
  "tag": "@fluentui-react-native/focus-zone_v0.10.23",
7
43
  "version": "0.10.23",
8
44
  "comments": {
package/CHANGELOG.md CHANGED
@@ -1,12 +1,29 @@
1
1
  # Change Log - @fluentui-react-native/focus-zone
2
2
 
3
- This log was last generated on Mon, 17 Oct 2022 17:50:04 GMT and should not be manually modified.
3
+ This log was last generated on Thu, 20 Oct 2022 18:28:41 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## 0.10.25
8
+
9
+ Thu, 20 Oct 2022 18:28:41 GMT
10
+
11
+ ### Patches
12
+
13
+ - FocusZone (macOS): Calculate distance from origin (sanajmi@microsoft.com)
14
+ - Bump @fluentui-react-native/interactive-hooks to v0.19.1
15
+
16
+ ## 0.10.24
17
+
18
+ Tue, 18 Oct 2022 04:06:27 GMT
19
+
20
+ ### Patches
21
+
22
+ - Bump @fluentui-react-native/interactive-hooks to v0.19.0
23
+
7
24
  ## 0.10.23
8
25
 
9
- Mon, 17 Oct 2022 17:50:04 GMT
26
+ Mon, 17 Oct 2022 17:52:49 GMT
10
27
 
11
28
  ### Patches
12
29
 
@@ -25,14 +25,9 @@ static inline CGFloat GetDistanceBetweenPoints(NSPoint point1, NSPoint point2)
25
25
  return sqrt(delta.x * delta.x + delta.y * delta.y);
26
26
  }
27
27
 
28
- static inline NSPoint GetCenterOfRect(NSRect rect)
28
+ static inline CGFloat GetDistanceBetweenOriginsOfRects(NSRect rect1, NSRect rect2)
29
29
  {
30
- return NSMakePoint(NSMidX(rect), NSMidY(rect));
31
- }
32
-
33
- static inline CGFloat GetDistanceBetweenCentersOfRects(NSRect rect1, NSRect rect2)
34
- {
35
- return GetDistanceBetweenPoints(GetCenterOfRect(rect1), GetCenterOfRect(rect2));
30
+ return GetDistanceBetweenPoints(rect1.origin, rect2.origin);
36
31
  }
37
32
 
38
33
  static inline CGFloat GetMinDistanceBetweenRectVerticesAndPoint(NSRect rect, NSPoint point)
@@ -275,7 +270,7 @@ static BOOL ShouldSkipFocusZone(NSView *view)
275
270
 
276
271
  if (!skip)
277
272
  {
278
- CGFloat distance = GetDistanceBetweenCentersOfRects(firstResponderRect, candidateRect);
273
+ CGFloat distance = GetDistanceBetweenOriginsOfRects(firstResponderRect, candidateRect);
279
274
 
280
275
  // If there are other candidate views inside the same ScrollView as the firstResponder,
281
276
  // prefer those views over other views outside the scrollview, even if they are closer.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluentui-react-native/focus-zone",
3
- "version": "0.10.23",
3
+ "version": "0.10.25",
4
4
  "description": "A cross-platform FocusZone component using the Fluent Design System",
5
5
  "main": "lib-commonjs/index.js",
6
6
  "module": "lib/index.js",
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "dependencies": {
25
25
  "@fluentui-react-native/component-cache": "^1.4.2",
26
- "@fluentui-react-native/interactive-hooks": ">=0.18.15 <1.0.0",
26
+ "@fluentui-react-native/interactive-hooks": ">=0.19.1 <1.0.0",
27
27
  "@uifabricshared/foundation-composable": ">=0.11.1 <1.0.0",
28
28
  "@uifabricshared/foundation-settings": ">=0.12.1 <1.0.0"
29
29
  },