@fluentui-react-native/focus-zone 0.11.37 → 0.11.38
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 +16 -1
- package/CHANGELOG.md +10 -2
- package/package.json +2 -2
- package/lib/FocusZone.d.ts +0 -4
- package/lib/FocusZone.d.ts.map +0 -1
- package/lib/FocusZone.js +0 -54
- package/lib/FocusZone.js.map +0 -1
- package/lib/FocusZone.types.d.ts +0 -52
- package/lib/FocusZone.types.d.ts.map +0 -1
- package/lib/FocusZone.types.js +0 -2
- package/lib/FocusZone.types.js.map +0 -1
- package/lib/__tests__/FocusZone.test.d.ts +0 -2
- package/lib/__tests__/FocusZone.test.d.ts.map +0 -1
- package/lib/__tests__/FocusZone.test.js +0 -94
- package/lib/__tests__/FocusZone.test.js.map +0 -1
- package/lib/index.d.ts +0 -4
- package/lib/index.d.ts.map +0 -1
- package/lib/index.js +0 -3
- package/lib/index.js.map +0 -1
package/CHANGELOG.json
CHANGED
|
@@ -2,7 +2,22 @@
|
|
|
2
2
|
"name": "@fluentui-react-native/focus-zone",
|
|
3
3
|
"entries": [
|
|
4
4
|
{
|
|
5
|
-
"date": "
|
|
5
|
+
"date": "Sat, 18 Mar 2023 17:18:20 GMT",
|
|
6
|
+
"tag": "@fluentui-react-native/focus-zone_v0.11.38",
|
|
7
|
+
"version": "0.11.38",
|
|
8
|
+
"comments": {
|
|
9
|
+
"patch": [
|
|
10
|
+
{
|
|
11
|
+
"author": "beachball",
|
|
12
|
+
"package": "@fluentui-react-native/focus-zone",
|
|
13
|
+
"comment": "Bump @fluentui-react-native/interactive-hooks to v0.22.26",
|
|
14
|
+
"commit": "601309349ca2bc18780a3fb71c59337f7c26f9bf"
|
|
15
|
+
}
|
|
16
|
+
]
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
"date": "Tue, 14 Mar 2023 20:50:45 GMT",
|
|
6
21
|
"tag": "@fluentui-react-native/focus-zone_v0.11.37",
|
|
7
22
|
"version": "0.11.37",
|
|
8
23
|
"comments": {
|
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,20 @@
|
|
|
1
1
|
# Change Log - @fluentui-react-native/focus-zone
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Sat, 18 Mar 2023 17:18:20 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## 0.11.38
|
|
8
|
+
|
|
9
|
+
Sat, 18 Mar 2023 17:18:20 GMT
|
|
10
|
+
|
|
11
|
+
### Patches
|
|
12
|
+
|
|
13
|
+
- Bump @fluentui-react-native/interactive-hooks to v0.22.26
|
|
14
|
+
|
|
7
15
|
## 0.11.37
|
|
8
16
|
|
|
9
|
-
Tue, 14 Mar 2023 20:
|
|
17
|
+
Tue, 14 Mar 2023 20:50:45 GMT
|
|
10
18
|
|
|
11
19
|
### Patches
|
|
12
20
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui-react-native/focus-zone",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.38",
|
|
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.4",
|
|
26
|
-
"@fluentui-react-native/interactive-hooks": ">=0.22.
|
|
26
|
+
"@fluentui-react-native/interactive-hooks": ">=0.22.26 <1.0.0",
|
|
27
27
|
"@uifabricshared/foundation-composable": ">=0.11.3 <1.0.0",
|
|
28
28
|
"@uifabricshared/foundation-settings": ">=0.12.3 <1.0.0"
|
|
29
29
|
},
|
package/lib/FocusZone.d.ts
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import type { FocusZoneProps, FocusZoneSlotProps } from './FocusZone.types';
|
|
3
|
-
export declare const FocusZone: import("@uifabricshared/foundation-composable").IWithComposable<React.FunctionComponent<FocusZoneProps>, import("@uifabricshared/foundation-composable").IComposable<FocusZoneProps, FocusZoneSlotProps, import("./FocusZone.types").FocusZoneState>>;
|
|
4
|
-
//# sourceMappingURL=FocusZone.d.ts.map
|
package/lib/FocusZone.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.d.ts","sourceRoot":"","sources":["../src/FocusZone.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAS/B,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAiB,MAAM,mBAAmB,CAAC;AAM3F,eAAO,MAAM,SAAS,uPA6BpB,CAAC"}
|
package/lib/FocusZone.js
DELETED
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
var __assign = (this && this.__assign) || function () {
|
|
2
|
-
__assign = Object.assign || function(t) {
|
|
3
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
4
|
-
s = arguments[i];
|
|
5
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
6
|
-
t[p] = s[p];
|
|
7
|
-
}
|
|
8
|
-
return t;
|
|
9
|
-
};
|
|
10
|
-
return __assign.apply(this, arguments);
|
|
11
|
-
};
|
|
12
|
-
var __rest = (this && this.__rest) || function (s, e) {
|
|
13
|
-
var t = {};
|
|
14
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
15
|
-
t[p] = s[p];
|
|
16
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
17
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
18
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
19
|
-
t[p[i]] = s[p[i]];
|
|
20
|
-
}
|
|
21
|
-
return t;
|
|
22
|
-
};
|
|
23
|
-
import * as React from 'react';
|
|
24
|
-
import { findNodeHandle } from 'react-native';
|
|
25
|
-
import { ensureNativeComponent } from '@fluentui-react-native/component-cache';
|
|
26
|
-
import { useViewCommandFocus } from '@fluentui-react-native/interactive-hooks';
|
|
27
|
-
import { composable } from '@uifabricshared/foundation-composable';
|
|
28
|
-
import { mergeSettings } from '@uifabricshared/foundation-settings';
|
|
29
|
-
var RCTFocusZone = ensureNativeComponent('RCTFocusZone');
|
|
30
|
-
var filterOutComponentRef = function (propName) { return propName !== 'componentRef'; };
|
|
31
|
-
export var FocusZone = composable({
|
|
32
|
-
usePrepareProps: function (userProps, useStyling) {
|
|
33
|
-
var componentRef = userProps.componentRef, defaultTabbableElement = userProps.defaultTabbableElement, isCircularNavigation = userProps.isCircularNavigation, rest = __rest(userProps, ["componentRef", "defaultTabbableElement", "isCircularNavigation"]);
|
|
34
|
-
var ftzRef = useViewCommandFocus(componentRef);
|
|
35
|
-
var _a = React.useState(undefined), targetNativeTag = _a[0], setTargetNativeTag = _a[1];
|
|
36
|
-
React.useLayoutEffect(function () {
|
|
37
|
-
if (defaultTabbableElement === null || defaultTabbableElement === void 0 ? void 0 : defaultTabbableElement.current) {
|
|
38
|
-
setTargetNativeTag(findNodeHandle(defaultTabbableElement.current));
|
|
39
|
-
}
|
|
40
|
-
else {
|
|
41
|
-
setTargetNativeTag(undefined);
|
|
42
|
-
}
|
|
43
|
-
}, [defaultTabbableElement]);
|
|
44
|
-
return {
|
|
45
|
-
slotProps: mergeSettings(useStyling(userProps), {
|
|
46
|
-
root: __assign(__assign({}, rest), { defaultTabbableElement: targetNativeTag, ref: ftzRef, navigateAtEnd: isCircularNavigation ? 'NavigateWrap' : 'NavigateStopAtEnds' }),
|
|
47
|
-
}),
|
|
48
|
-
};
|
|
49
|
-
},
|
|
50
|
-
slots: {
|
|
51
|
-
root: { slotType: RCTFocusZone, filter: filterOutComponentRef },
|
|
52
|
-
},
|
|
53
|
-
});
|
|
54
|
-
//# sourceMappingURL=FocusZone.js.map
|
package/lib/FocusZone.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.js","sourceRoot":"","sources":["../src/FocusZone.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAE9C,OAAO,EAAE,qBAAqB,EAAE,MAAM,wCAAwC,CAAC;AAC/E,OAAO,EAAE,mBAAmB,EAAE,MAAM,0CAA0C,CAAC;AAE/E,OAAO,EAAE,UAAU,EAAE,MAAM,uCAAuC,CAAC;AACnE,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAIpE,IAAM,YAAY,GAAG,qBAAqB,CAAC,cAAc,CAAC,CAAC;AAE3D,IAAM,qBAAqB,GAAG,UAAC,QAAQ,IAAK,OAAA,QAAQ,KAAK,cAAc,EAA3B,CAA2B,CAAC;AAExE,MAAM,CAAC,IAAM,SAAS,GAAG,UAAU,CAAgB;IACjD,eAAe,EAAE,UAAC,SAAyB,EAAE,UAAsC;QACzE,IAAA,YAAY,GAA4D,SAAS,aAArE,EAAE,sBAAsB,GAAoC,SAAS,uBAA7C,EAAE,oBAAoB,GAAc,SAAS,qBAAvB,EAAK,IAAI,UAAK,SAAS,EAAnF,kEAAuE,CAAF,CAAe;QAE1F,IAAM,MAAM,GAAG,mBAAmB,CAAC,YAAY,CAAC,CAAC;QAE3C,IAAA,KAAwC,KAAK,CAAC,QAAQ,CAAS,SAAS,CAAC,EAAxE,eAAe,QAAA,EAAE,kBAAkB,QAAqC,CAAC;QAChF,KAAK,CAAC,eAAe,CAAC;YACpB,IAAI,sBAAsB,aAAtB,sBAAsB,uBAAtB,sBAAsB,CAAE,OAAO,EAAE;gBACnC,kBAAkB,CAAC,cAAc,CAAC,sBAAsB,CAAC,OAAO,CAAC,CAAC,CAAC;aACpE;iBAAM;gBACL,kBAAkB,CAAC,SAAS,CAAC,CAAC;aAC/B;QACH,CAAC,EAAE,CAAC,sBAAsB,CAAC,CAAC,CAAC;QAE7B,OAAO;YACL,SAAS,EAAE,aAAa,CAAqB,UAAU,CAAC,SAAS,CAAC,EAAE;gBAClE,IAAI,wBACC,IAAI,KACP,sBAAsB,EAAE,eAAe,EACvC,GAAG,EAAE,MAAM,EACX,aAAa,EAAE,oBAAoB,CAAC,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,oBAAoB,GAC5E;aACF,CAAC;SACH,CAAC;IACJ,CAAC;IACD,KAAK,EAAE;QACL,IAAI,EAAE,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,EAAE,qBAAqB,EAAE;KAChE;CACF,CAAC,CAAC"}
|
package/lib/FocusZone.types.d.ts
DELETED
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import type * as React from 'react';
|
|
2
|
-
import type { IFocusable } from '@fluentui-react-native/interactive-hooks';
|
|
3
|
-
import type { IRenderData } from '@uifabricshared/foundation-composable';
|
|
4
|
-
export declare const focusZoneName = "FocusZone";
|
|
5
|
-
export interface FocusZoneState {
|
|
6
|
-
}
|
|
7
|
-
export interface FocusZoneProps {
|
|
8
|
-
/**
|
|
9
|
-
* A RefObject to access the IFocusable interface. Use this to access the public methods and properties of the component.
|
|
10
|
-
*/
|
|
11
|
-
componentRef?: React.RefObject<IFocusable>;
|
|
12
|
-
/**
|
|
13
|
-
* Optionally defines the initial tabbable element inside the FocusZone
|
|
14
|
-
*/
|
|
15
|
-
defaultTabbableElement?: React.RefObject<React.Component>;
|
|
16
|
-
/**
|
|
17
|
-
** Defines which arrows to react to
|
|
18
|
-
*/
|
|
19
|
-
focusZoneDirection?: FocusZoneDirection;
|
|
20
|
-
/**
|
|
21
|
-
** If set, the FocusZone will not be tabbable and keyboard navigation will be disabled
|
|
22
|
-
*/
|
|
23
|
-
disabled?: boolean;
|
|
24
|
-
isCircularNavigation?: boolean;
|
|
25
|
-
/**
|
|
26
|
-
*Allows for 2D navigation. This navigation strategy takes into account the position of elements
|
|
27
|
-
on screen, and navigates in the direction the user selects to the nearest element.
|
|
28
|
-
*/
|
|
29
|
-
use2DNavigation?: boolean;
|
|
30
|
-
/**
|
|
31
|
-
* Callback called when “focus” event triggered in FocusZone
|
|
32
|
-
*/
|
|
33
|
-
onFocus?: (e?: any) => void;
|
|
34
|
-
}
|
|
35
|
-
export interface NativeProps extends Omit<FocusZoneProps, 'isCircularNavigation'> {
|
|
36
|
-
navigateAtEnd?: NavigateAtEnd;
|
|
37
|
-
}
|
|
38
|
-
export type FocusZoneDirection = 'bidirectional' /** React to all arrows. */ | 'vertical' /** Only react to up/down arrows. */ | 'horizontal' /** Only react to left/right arrows. */ | 'none'; /** Doesn't respond to any arrow keys. */
|
|
39
|
-
export type NavigateAtEnd = 'NavigateStopAtEnds' | 'NavigateWrap' | 'NavigateContinue';
|
|
40
|
-
export interface FocusZoneTokens {
|
|
41
|
-
}
|
|
42
|
-
export interface FocusZoneSlotProps {
|
|
43
|
-
root: NativeProps;
|
|
44
|
-
}
|
|
45
|
-
export type FocusZoneRenderData = IRenderData<FocusZoneSlotProps, FocusZoneState>;
|
|
46
|
-
export interface FocusZoneType {
|
|
47
|
-
props: FocusZoneProps;
|
|
48
|
-
tokens: FocusZoneTokens;
|
|
49
|
-
slotProps: FocusZoneSlotProps;
|
|
50
|
-
state: FocusZoneState;
|
|
51
|
-
}
|
|
52
|
-
//# sourceMappingURL=FocusZone.types.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.types.d.ts","sourceRoot":"","sources":["../src/FocusZone.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,KAAK,MAAM,OAAO,CAAC;AAEpC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,0CAA0C,CAAC;AAC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EAAE,cAAc,CAAC;CACvB"}
|
package/lib/FocusZone.types.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.types.js","sourceRoot":"","sources":["../src/FocusZone.types.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,IAAM,aAAa,GAAG,WAAW,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.test.d.ts","sourceRoot":"","sources":["../../src/__tests__/FocusZone.test.tsx"],"names":[],"mappings":""}
|
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { Button } from 'react-native';
|
|
3
|
-
import * as renderer from 'react-test-renderer';
|
|
4
|
-
import { FocusZone } from '..';
|
|
5
|
-
var onPress = function () {
|
|
6
|
-
return;
|
|
7
|
-
};
|
|
8
|
-
describe('FocusZone No Props', function () {
|
|
9
|
-
it('No children', function () {
|
|
10
|
-
var tree = renderer.create(React.createElement(FocusZone, null)).toJSON();
|
|
11
|
-
expect(tree).toMatchSnapshot();
|
|
12
|
-
});
|
|
13
|
-
it('One child', function () {
|
|
14
|
-
var tree = renderer
|
|
15
|
-
.create(React.createElement(FocusZone, null,
|
|
16
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
17
|
-
.toJSON();
|
|
18
|
-
expect(tree).toMatchSnapshot();
|
|
19
|
-
});
|
|
20
|
-
it('Two children', function () {
|
|
21
|
-
var tree = renderer
|
|
22
|
-
.create(React.createElement(FocusZone, null,
|
|
23
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
24
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
25
|
-
.toJSON();
|
|
26
|
-
expect(tree).toMatchSnapshot();
|
|
27
|
-
});
|
|
28
|
-
it('Three children', function () {
|
|
29
|
-
var tree = renderer
|
|
30
|
-
.create(React.createElement(FocusZone, null,
|
|
31
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
32
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
33
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
34
|
-
.toJSON();
|
|
35
|
-
expect(tree).toMatchSnapshot();
|
|
36
|
-
});
|
|
37
|
-
});
|
|
38
|
-
describe('FocusZone With Props', function () {
|
|
39
|
-
it('defaultTabbableElement Prop', function () {
|
|
40
|
-
var tree = renderer
|
|
41
|
-
.create(React.createElement(FocusZone, { defaultTabbableElement: null },
|
|
42
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
43
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
44
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
45
|
-
.toJSON();
|
|
46
|
-
expect(tree).toMatchSnapshot();
|
|
47
|
-
});
|
|
48
|
-
it('focusZoneDirection Prop', function () {
|
|
49
|
-
var tree = renderer
|
|
50
|
-
.create(React.createElement(FocusZone, { focusZoneDirection: "bidirectional" },
|
|
51
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
52
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
53
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
54
|
-
.toJSON();
|
|
55
|
-
expect(tree).toMatchSnapshot();
|
|
56
|
-
});
|
|
57
|
-
it('disabled Prop', function () {
|
|
58
|
-
var tree = renderer
|
|
59
|
-
.create(React.createElement(FocusZone, { disabled: true },
|
|
60
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
61
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
62
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
63
|
-
.toJSON();
|
|
64
|
-
expect(tree).toMatchSnapshot();
|
|
65
|
-
});
|
|
66
|
-
it('isCircularNavigation Prop', function () {
|
|
67
|
-
var tree = renderer
|
|
68
|
-
.create(React.createElement(FocusZone, { isCircularNavigation: true },
|
|
69
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
70
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
71
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
72
|
-
.toJSON();
|
|
73
|
-
expect(tree).toMatchSnapshot();
|
|
74
|
-
});
|
|
75
|
-
it('use2DNavigation Prop', function () {
|
|
76
|
-
var tree = renderer
|
|
77
|
-
.create(React.createElement(FocusZone, { use2DNavigation: true },
|
|
78
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
79
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
80
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
81
|
-
.toJSON();
|
|
82
|
-
expect(tree).toMatchSnapshot();
|
|
83
|
-
});
|
|
84
|
-
it('All Props', function () {
|
|
85
|
-
var tree = renderer
|
|
86
|
-
.create(React.createElement(FocusZone, { disabled: false, use2DNavigation: true, defaultTabbableElement: null, isCircularNavigation: false, focusZoneDirection: "vertical" },
|
|
87
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
88
|
-
React.createElement(Button, { title: "button", onPress: onPress }),
|
|
89
|
-
React.createElement(Button, { title: "button", onPress: onPress })))
|
|
90
|
-
.toJSON();
|
|
91
|
-
expect(tree).toMatchSnapshot();
|
|
92
|
-
});
|
|
93
|
-
});
|
|
94
|
-
//# sourceMappingURL=FocusZone.test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FocusZone.test.js","sourceRoot":"","sources":["../../src/__tests__/FocusZone.test.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAEtC,OAAO,KAAK,QAAQ,MAAM,qBAAqB,CAAC;AAEhD,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AAE/B,IAAM,OAAO,GAAG;IACd,OAAO;AACT,CAAC,CAAC;AAEF,QAAQ,CAAC,oBAAoB,EAAE;IAC7B,EAAE,CAAC,aAAa,EAAE;QAChB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f,eAAe,EAAE,IAAI,EACrB,sBAAsB,EAAE,IAAI,EAC5B,oBAAoB,EAAE,KAAK,EAC3B,kBAAkB,EAAC,UAAU;YAE7B,oBAAC,MAAM,IAAC,KAAK,EAAC,QAAQ,EAAC,OAAO,EAAE,OAAO,GAAI;YAC3C,oBAAC,MAAM,IAAC,KAAK,EAAC,QAAQ,EAAC,OAAO,EAAE,OAAO,GAAI;YAC3C,oBAAC,MAAM,IAAC,KAAK,EAAC,QAAQ,EAAC,OAAO,EAAE,OAAO,GAAI,CACjC,CACb;aACA,MAAM,EAAE,CAAC;QACZ,MAAM,CAAC,IAAI,CAAC,CAAC,eAAe,EAAE,CAAC;IACjC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
package/lib/index.d.ts
DELETED
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
export { focusZoneName } from './FocusZone.types';
|
|
2
|
-
export type { FocusZoneDirection, FocusZoneProps, FocusZoneRenderData, FocusZoneSlotProps, FocusZoneState, FocusZoneTokens, FocusZoneType, NativeProps, NavigateAtEnd, } from './FocusZone.types';
|
|
3
|
-
export { FocusZone } from './FocusZone';
|
|
4
|
-
//# sourceMappingURL=index.d.ts.map
|
package/lib/index.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,YAAY,EACV,kBAAkB,EAClB,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,cAAc,EACd,eAAe,EACf,aAAa,EACb,WAAW,EACX,aAAa,GACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|
package/lib/index.js
DELETED
package/lib/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAYlD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|