@fluentui-react-native/separator 0.18.17 → 0.19.0
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.md +48 -1
- package/lib/Separator.d.ts +7 -2
- package/lib/Separator.d.ts.map +1 -1
- package/lib/Separator.js +11 -11
- package/lib/Separator.js.map +1 -1
- package/lib/Separator.styling.d.ts +1 -1
- package/lib/Separator.styling.js +17 -14
- package/lib/Separator.styling.js.map +1 -1
- package/lib/Separator.types.d.ts +30 -31
- package/lib/Separator.types.js +1 -1
- package/lib/SeparatorTokens.android.d.ts +1 -1
- package/lib/SeparatorTokens.android.js +4 -4
- package/lib/SeparatorTokens.android.js.map +1 -1
- package/lib/SeparatorTokens.d.ts +1 -1
- package/lib/SeparatorTokens.js +2 -2
- package/lib/SeparatorTokens.js.map +1 -1
- package/lib/__tests__/Separator.test.d.ts +1 -1
- package/lib/__tests__/Separator.test.js +14 -7
- package/lib/__tests__/Separator.test.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib-commonjs/Separator.d.ts +7 -2
- package/lib-commonjs/Separator.d.ts.map +1 -1
- package/lib-commonjs/Separator.js +16 -16
- package/lib-commonjs/Separator.js.map +1 -1
- package/lib-commonjs/Separator.styling.d.ts +1 -1
- package/lib-commonjs/Separator.styling.js +23 -20
- package/lib-commonjs/Separator.styling.js.map +1 -1
- package/lib-commonjs/Separator.types.d.ts +30 -31
- package/lib-commonjs/Separator.types.js +3 -3
- package/lib-commonjs/SeparatorTokens.android.d.ts +1 -1
- package/lib-commonjs/SeparatorTokens.android.js +7 -7
- package/lib-commonjs/SeparatorTokens.android.js.map +1 -1
- package/lib-commonjs/SeparatorTokens.d.ts +1 -1
- package/lib-commonjs/SeparatorTokens.js +5 -5
- package/lib-commonjs/SeparatorTokens.js.map +1 -1
- package/lib-commonjs/__tests__/Separator.test.d.ts +1 -1
- package/lib-commonjs/__tests__/Separator.test.js +68 -34
- package/lib-commonjs/__tests__/Separator.test.js.map +1 -1
- package/lib-commonjs/index.d.ts +1 -1
- package/lib-commonjs/index.js +17 -7
- package/lib-commonjs/index.js.map +1 -1
- package/package.json +60 -59
- package/src/Separator.tsx +2 -3
- package/src/__tests__/Separator.test.tsx +11 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,43 @@
|
|
|
1
1
|
# Change Log - @fluentui-react-native/separator
|
|
2
2
|
|
|
3
|
+
## 0.19.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- d7adbdd: # Migration from Beachball to Changesets
|
|
8
|
+
|
|
9
|
+
This changeset represents the migration from Beachball to Changesets for version management and consolidates all changes from 440+ beachball change files that were in the `change/` directory.
|
|
10
|
+
|
|
11
|
+
All 75 affected packages receive a minor version bump to acknowledge the accumulated changes from the beachball era.
|
|
12
|
+
|
|
13
|
+
## What Changed
|
|
14
|
+
|
|
15
|
+
Going forward, all version management uses Changesets via `yarn changeset`. The following beachball infrastructure has been removed:
|
|
16
|
+
|
|
17
|
+
- ❌ 440+ beachball change files from `change/` directory
|
|
18
|
+
- ❌ `beachball` package dependency
|
|
19
|
+
- ❌ Beachball scripts from `package.json`
|
|
20
|
+
- ❌ `beachball.config.js` configuration file
|
|
21
|
+
- ❌ Beachball publish steps from Azure Pipelines
|
|
22
|
+
|
|
23
|
+
## New Workflow
|
|
24
|
+
|
|
25
|
+
✅ **Create changes**: Run `yarn changeset` to document changes
|
|
26
|
+
✅ **Version bump PRs**: Automatically created by GitHub Actions
|
|
27
|
+
✅ **Publishing**: Handled by Azure Pipelines using `changeset publish`
|
|
28
|
+
✅ **Validation**: CI validates changesets and blocks major version bumps
|
|
29
|
+
|
|
30
|
+
For details, see `CHANGESETS_SETUP.md` and `CONTRIBUTING.md`.
|
|
31
|
+
|
|
32
|
+
### Patch Changes
|
|
33
|
+
|
|
34
|
+
- d1d8c26: We were pinning @types/react and react-native-macos via resolutions. This fixes that which uncovered a bunch of type inconsistencies that needed to be addressed.
|
|
35
|
+
- Updated dependencies [d7adbdd]
|
|
36
|
+
- Updated dependencies [d1d8c26]
|
|
37
|
+
- @fluentui-react-native/framework@0.15.0
|
|
38
|
+
- @fluentui-react-native/theme-tokens@0.28.0
|
|
39
|
+
- @fluentui-react-native/use-styling@0.14.0
|
|
40
|
+
|
|
3
41
|
<!-- This log was last generated on Tue, 05 Aug 2025 18:50:41 GMT and should not be manually modified. -->
|
|
4
42
|
|
|
5
43
|
<!-- Start content -->
|
|
@@ -942,7 +980,7 @@ Thu, 16 Dec 2021 19:10:26 GMT
|
|
|
942
980
|
|
|
943
981
|
### Patches
|
|
944
982
|
|
|
945
|
-
- Rename Jest snapshots to be platform agnostic
|
|
983
|
+
- Rename Jest snapshots to be platform agnostic (sanajmi@microsoft.com)
|
|
946
984
|
- Bump @fluentui-react-native/framework to v0.7.1
|
|
947
985
|
|
|
948
986
|
## 0.11.0
|
|
@@ -1434,30 +1472,39 @@ Thu, 16 Apr 2020 23:57:38 GMT
|
|
|
1434
1472
|
- publish with correct main/module references (jasonmo@microsoft.com)
|
|
1435
1473
|
|
|
1436
1474
|
## 0.2.10
|
|
1475
|
+
|
|
1437
1476
|
Thu, 09 Apr 2020 18:39:15 GMT
|
|
1438
1477
|
|
|
1439
1478
|
### Patches
|
|
1440
1479
|
|
|
1441
1480
|
- merge conflicts (ppatboyd@outlook.com)
|
|
1481
|
+
|
|
1442
1482
|
## 0.2.8
|
|
1483
|
+
|
|
1443
1484
|
Fri, 03 Apr 2020 20:40:51 GMT
|
|
1444
1485
|
|
|
1445
1486
|
### Patches
|
|
1446
1487
|
|
|
1447
1488
|
- switch the bin name from just-script to fluent-scripts to disambiguate names (jasonmo@microsoft.com)
|
|
1489
|
+
|
|
1448
1490
|
## 0.2.7
|
|
1491
|
+
|
|
1449
1492
|
Tue, 31 Mar 2020 18:01:09 GMT
|
|
1450
1493
|
|
|
1451
1494
|
### Patches
|
|
1452
1495
|
|
|
1453
1496
|
- Merge branch 'sammy/checkboxV1' of https://github.com/samuelfreiberg/fluentui-react-native into sammy/checkboxV1 (safreibe@microsoft.com)
|
|
1497
|
+
|
|
1454
1498
|
## 0.2.6
|
|
1499
|
+
|
|
1455
1500
|
Mon, 30 Mar 2020 16:27:00 GMT
|
|
1456
1501
|
|
|
1457
1502
|
### Patches
|
|
1458
1503
|
|
|
1459
1504
|
- Update main attribute to specify TypeScript index file. (kinhln@microsoft.com)
|
|
1505
|
+
|
|
1460
1506
|
## 0.2.0
|
|
1507
|
+
|
|
1461
1508
|
Mon, 16 Mar 2020 23:03:24 GMT
|
|
1462
1509
|
|
|
1463
1510
|
### Minor changes
|
package/lib/Separator.d.ts
CHANGED
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
import type { SeparatorProps } from './Separator.types';
|
|
2
|
-
export declare const Separator: import(
|
|
2
|
+
export declare const Separator: import('@fluentui-react-native/framework').ComposableComponent<
|
|
3
|
+
SeparatorProps,
|
|
4
|
+
import('./Separator.types').SeperatorSlotProps,
|
|
5
|
+
import('./Separator.types').SeparatorTokens,
|
|
6
|
+
import('@fluentui-react-native/framework-base').ObjectBase
|
|
7
|
+
>;
|
|
3
8
|
export default Separator;
|
|
4
|
-
//# sourceMappingURL=Separator.d.ts.map
|
|
9
|
+
//# sourceMappingURL=Separator.d.ts.map
|
package/lib/Separator.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.d.ts","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Separator.d.ts","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,mBAAmB,CAAC;AAKvE,eAAO,MAAM,SAAS,yOAQpB,CAAC;AAEH,eAAe,SAAS,CAAC"}
|
package/lib/Separator.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
/** @
|
|
1
|
+
import { jsx as _jsx } from '@fluentui-react-native/framework-base/jsx-runtime';
|
|
2
|
+
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
3
3
|
import { View } from 'react-native';
|
|
4
|
-
import { compose,
|
|
4
|
+
import { compose, mergeProps } from '@fluentui-react-native/framework';
|
|
5
5
|
import { stylingSettings } from './Separator.styling';
|
|
6
6
|
import { separatorName } from './Separator.types';
|
|
7
7
|
const propMask = { vertical: undefined };
|
|
8
8
|
export const Separator = compose({
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
9
|
+
displayName: separatorName,
|
|
10
|
+
...stylingSettings,
|
|
11
|
+
slots: { root: View },
|
|
12
|
+
useRender: (props, useSlots) => {
|
|
13
|
+
const Root = useSlots(props).root;
|
|
14
|
+
return (rest, children) => _jsx(Root, { ...mergeProps(props, rest, propMask), children: children });
|
|
15
|
+
},
|
|
16
16
|
});
|
|
17
17
|
export default Separator;
|
|
18
|
-
//# sourceMappingURL=Separator.js.map
|
|
18
|
+
//# sourceMappingURL=Separator.js.map
|
package/lib/Separator.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.js","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"Separator.js","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":";AAAA,6DAA6D;AAC7D,OAAO,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAGpC,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAEvE,OAAO,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAEtD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,MAAM,QAAQ,GAAG,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;AAEzC,MAAM,CAAC,MAAM,SAAS,GAAG,OAAO,CAAgB;IAC9C,WAAW,EAAE,aAAa;IAC1B,GAAG,eAAe;IAClB,KAAK,EAAE,EAAE,IAAI,EAAE,IAAI,EAAE;IACrB,SAAS,EAAE,CAAC,KAAqB,EAAE,QAAiC,EAAE,EAAE,CAAC;QACvE,MAAM,IAAI,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC;QAClC,OAAO,CAAC,IAAoB,EAAE,QAAyB,EAAE,EAAE,CAAC,KAAC,IAAI,OAAK,UAAU,CAAC,KAAK,EAAE,IAAI,EAAE,QAAQ,CAAC,YAAG,QAAQ,GAAQ,CAAC;IAAA,CAC5H;CACF,CAAC,CAAC;AAEH,eAAe,SAAS,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { UseStylingOptions } from '@fluentui-react-native/framework';
|
|
2
2
|
import type { SeparatorProps, SeparatorTokens, SeperatorSlotProps } from './Separator.types';
|
|
3
3
|
export declare const stylingSettings: UseStylingOptions<SeparatorProps, SeperatorSlotProps, SeparatorTokens>;
|
|
4
|
-
//# sourceMappingURL=Separator.styling.d.ts.map
|
|
4
|
+
//# sourceMappingURL=Separator.styling.d.ts.map
|
package/lib/Separator.styling.js
CHANGED
|
@@ -5,18 +5,21 @@ import { defaultSeparatorTokens } from './SeparatorTokens';
|
|
|
5
5
|
const isMobile = Platform.OS === 'android' || Platform.OS === 'ios';
|
|
6
6
|
const tokensThatAreAlsoProps = ['vertical', 'insetSpacing'];
|
|
7
7
|
export const stylingSettings = {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
}
|
|
20
|
-
|
|
8
|
+
tokens: [defaultSeparatorTokens, separatorName],
|
|
9
|
+
tokensThatAreAlsoProps,
|
|
10
|
+
slotProps: {
|
|
11
|
+
root: buildProps(
|
|
12
|
+
(tokens) => {
|
|
13
|
+
return {
|
|
14
|
+
style: {
|
|
15
|
+
...(tokens.vertical ? { borderLeftWidth: tokens.separatorWidth } : { borderTopWidth: tokens.separatorWidth }),
|
|
16
|
+
...(tokens.color && { borderColor: tokens.color }),
|
|
17
|
+
...(isMobile && { marginStart: tokens.insetSpacing }),
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
},
|
|
21
|
+
['color', 'vertical', 'separatorWidth', 'insetSpacing'],
|
|
22
|
+
),
|
|
23
|
+
},
|
|
21
24
|
};
|
|
22
|
-
//# sourceMappingURL=Separator.styling.js.map
|
|
25
|
+
//# sourceMappingURL=Separator.styling.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.styling.js","sourceRoot":"","sources":["../src/Separator.styling.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAGxC,OAAO,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAG9D,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAE3D,MAAM,QAAQ,GAAG,QAAQ,CAAC,EAAE,KAAK,SAAS,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,CAAC;AACpE,MAAM,sBAAsB,GAAkC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;AAC3F,MAAM,CAAC,MAAM,eAAe,GAA2E;IACrG,MAAM,EAAE,CAAC,sBAAsB,EAAE,aAAa,CAAC;IAC/C,sBAAsB;IACtB,SAAS,EAAE;QACT,IAAI,EAAE,UAAU,CACd,CAAC,MAAuB,EAAE,EAAE;
|
|
1
|
+
{"version":3,"file":"Separator.styling.js","sourceRoot":"","sources":["../src/Separator.styling.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAGxC,OAAO,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAC;AAG9D,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAC;AAE3D,MAAM,QAAQ,GAAG,QAAQ,CAAC,EAAE,KAAK,SAAS,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,CAAC;AACpE,MAAM,sBAAsB,GAAkC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;AAC3F,MAAM,CAAC,MAAM,eAAe,GAA2E;IACrG,MAAM,EAAE,CAAC,sBAAsB,EAAE,aAAa,CAAC;IAC/C,sBAAsB;IACtB,SAAS,EAAE;QACT,IAAI,EAAE,UAAU,CACd,CAAC,MAAuB,EAAE,EAAE,CAAC;YAC3B,OAAO;gBACL,KAAK,EAAE;oBACL,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,eAAe,EAAE,MAAM,CAAC,cAAc,EAAE,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,MAAM,CAAC,cAAc,EAAE,CAAC;oBAC7G,GAAG,CAAC,MAAM,CAAC,KAAK,IAAI,EAAE,WAAW,EAAE,MAAM,CAAC,KAAK,EAAE,CAAC;oBAClD,GAAG,CAAC,QAAQ,IAAI,EAAE,WAAW,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC;iBACtD;aACF,CAAC;QAAA,CACH,EACD,CAAC,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,cAAc,CAAC,CACxD;KACF;CACF,CAAC"}
|
package/lib/Separator.types.d.ts
CHANGED
|
@@ -1,42 +1,41 @@
|
|
|
1
1
|
import type { ViewProps, ColorValue } from 'react-native';
|
|
2
|
-
export declare const separatorName =
|
|
2
|
+
export declare const separatorName = 'Separator';
|
|
3
3
|
export declare const SeparatorInsetSpacings: readonly [0, 16, 56, 68, 72, 108];
|
|
4
4
|
export type SeparatorInsetSpacing = (typeof SeparatorInsetSpacings)[number];
|
|
5
5
|
export interface SeparatorPropTokens {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Specifies whether the separator is vertical or horizontal. If true, then it's vertical.
|
|
8
|
+
* @defaultValue 'false'
|
|
9
|
+
*/
|
|
10
|
+
vertical?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Inset Spacing in 'dp' (density-independent pixels) on Android and 'points' on iOS.
|
|
13
|
+
*
|
|
14
|
+
* Inset Spacing is restricted to a limited set of supported values recommended for most uses (see `SeparatorInsetSpacing`) and
|
|
15
|
+
* based on design guidelines for the Separator control.
|
|
16
|
+
* @platform Android iOS
|
|
17
|
+
* @defaultvalue 0
|
|
18
|
+
*/
|
|
19
|
+
insetSpacing?: SeparatorInsetSpacing;
|
|
20
20
|
}
|
|
21
21
|
export interface SeparatorTokens extends SeparatorPropTokens {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
}
|
|
32
|
-
export interface SeparatorProps extends ViewProps, SeparatorPropTokens {
|
|
22
|
+
/**
|
|
23
|
+
* Specifies the width of the separator. This will be interpreted as DIPs on Windows and Android, but as points on Mac and iOS.
|
|
24
|
+
* @defaultValue 1
|
|
25
|
+
*/
|
|
26
|
+
separatorWidth?: number;
|
|
27
|
+
/**
|
|
28
|
+
* Specifies the color of the separator
|
|
29
|
+
*/
|
|
30
|
+
color?: ColorValue;
|
|
33
31
|
}
|
|
32
|
+
export interface SeparatorProps extends ViewProps, SeparatorPropTokens {}
|
|
34
33
|
export interface SeperatorSlotProps {
|
|
35
|
-
|
|
34
|
+
root: ViewProps;
|
|
36
35
|
}
|
|
37
36
|
export interface SeparatorType {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
37
|
+
props: SeparatorProps;
|
|
38
|
+
slotProps: SeperatorSlotProps;
|
|
39
|
+
tokens: SeparatorTokens;
|
|
41
40
|
}
|
|
42
|
-
//# sourceMappingURL=Separator.types.d.ts.map
|
|
41
|
+
//# sourceMappingURL=Separator.types.d.ts.map
|
package/lib/Separator.types.js
CHANGED
|
@@ -2,4 +2,4 @@ import type { Theme } from '@fluentui-react-native/framework';
|
|
|
2
2
|
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
|
3
3
|
import type { SeparatorTokens } from './Separator.types';
|
|
4
4
|
export declare const defaultSeparatorTokens: TokenSettings<SeparatorTokens, Theme>;
|
|
5
|
-
//# sourceMappingURL=SeparatorTokens.android.d.ts.map
|
|
5
|
+
//# sourceMappingURL=SeparatorTokens.android.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { globalTokens } from '@fluentui-react-native/theme-tokens';
|
|
2
2
|
export const defaultSeparatorTokens = (t) => ({
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
color: t.colors.neutralStroke2,
|
|
4
|
+
separatorWidth: globalTokens.stroke.width10,
|
|
5
|
+
insetSpacing: 0,
|
|
6
6
|
});
|
|
7
|
-
//# sourceMappingURL=SeparatorTokens.android.js.map
|
|
7
|
+
//# sourceMappingURL=SeparatorTokens.android.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SeparatorTokens.android.js","sourceRoot":"","sources":["../src/SeparatorTokens.android.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAC;AAKnE,MAAM,CAAC,MAAM,sBAAsB,GAA0C,CAAC,CAAQ,EAAE,EAAE,
|
|
1
|
+
{"version":3,"file":"SeparatorTokens.android.js","sourceRoot":"","sources":["../src/SeparatorTokens.android.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAC;AAKnE,MAAM,CAAC,MAAM,sBAAsB,GAA0C,CAAC,CAAQ,EAAE,EAAE,EACvF;IACC,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,cAAc;IAC9B,cAAc,EAAE,YAAY,CAAC,MAAM,CAAC,OAAO;IAC3C,YAAY,EAAE,CAAC;CACI,CAAA,CAAC"}
|
package/lib/SeparatorTokens.d.ts
CHANGED
|
@@ -2,4 +2,4 @@ import type { Theme } from '@fluentui-react-native/framework';
|
|
|
2
2
|
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
|
3
3
|
import type { SeparatorTokens } from './Separator.types';
|
|
4
4
|
export declare const defaultSeparatorTokens: TokenSettings<SeparatorTokens, Theme>;
|
|
5
|
-
//# sourceMappingURL=SeparatorTokens.d.ts.map
|
|
5
|
+
//# sourceMappingURL=SeparatorTokens.d.ts.map
|
package/lib/SeparatorTokens.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { globalTokens } from '@fluentui-react-native/theme-tokens';
|
|
2
2
|
export const defaultSeparatorTokens = () => ({
|
|
3
|
-
|
|
3
|
+
separatorWidth: globalTokens.stroke.width10,
|
|
4
4
|
});
|
|
5
|
-
//# sourceMappingURL=SeparatorTokens.js.map
|
|
5
|
+
//# sourceMappingURL=SeparatorTokens.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SeparatorTokens.js","sourceRoot":"","sources":["../src/SeparatorTokens.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAC;AAKnE,MAAM,CAAC,MAAM,sBAAsB,GAA0C,GAAG,EAAE,
|
|
1
|
+
{"version":3,"file":"SeparatorTokens.js","sourceRoot":"","sources":["../src/SeparatorTokens.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,YAAY,EAAE,MAAM,qCAAqC,CAAC;AAKnE,MAAM,CAAC,MAAM,sBAAsB,GAA0C,GAAG,EAAE,EAC/E;IACC,cAAc,EAAE,YAAY,CAAC,MAAM,CAAC,OAAO;CACxB,CAAA,CAAC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export {};
|
|
2
|
-
//# sourceMappingURL=Separator.test.d.ts.map
|
|
2
|
+
//# sourceMappingURL=Separator.test.d.ts.map
|
|
@@ -1,13 +1,20 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { jsx as _jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { act } from 'react';
|
|
2
3
|
import * as renderer from 'react-test-renderer';
|
|
3
4
|
import { Separator } from '..';
|
|
4
5
|
it('Separator default', () => {
|
|
5
|
-
|
|
6
|
-
|
|
6
|
+
let component;
|
|
7
|
+
act(() => {
|
|
8
|
+
component = renderer.create(_jsx(Separator, {}));
|
|
9
|
+
});
|
|
10
|
+
expect(component.toJSON()).toMatchSnapshot();
|
|
7
11
|
});
|
|
8
12
|
it('Separator all props & tokens', () => {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
13
|
+
const CustomSeparator = Separator.customize({ separatorWidth: 15, color: 'red' });
|
|
14
|
+
let component;
|
|
15
|
+
act(() => {
|
|
16
|
+
component = renderer.create(_jsx(CustomSeparator, { vertical: true }));
|
|
17
|
+
});
|
|
18
|
+
expect(component.toJSON()).toMatchSnapshot();
|
|
12
19
|
});
|
|
13
|
-
//# sourceMappingURL=Separator.test.js.map
|
|
20
|
+
//# sourceMappingURL=Separator.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.test.js","sourceRoot":"","sources":["../../src/__tests__/Separator.test.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"Separator.test.js","sourceRoot":"","sources":["../../src/__tests__/Separator.test.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,OAAO,CAAC;AAE5B,OAAO,KAAK,QAAQ,MAAM,qBAAqB,CAAC;AAEhD,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,CAAC;AAE/B,EAAE,CAAC,mBAAmB,EAAE,GAAG,EAAE,CAAC;IAC5B,IAAI,SAAqC,CAAC;IAC1C,GAAG,CAAC,GAAG,EAAE,CAAC;QACR,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,KAAC,SAAS,KAAG,CAAC,CAAC;IAAA,CAC5C,CAAC,CAAC;IACH,MAAM,CAAC,SAAU,CAAC,MAAM,EAAE,CAAC,CAAC,eAAe,EAAE,CAAC;AAAA,CAC/C,CAAC,CAAC;AAEH,EAAE,CAAC,8BAA8B,EAAE,GAAG,EAAE,CAAC;IACvC,MAAM,eAAe,GAAG,SAAS,CAAC,SAAS,CAAC,EAAE,cAAc,EAAE,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;IAClF,IAAI,SAAqC,CAAC;IAC1C,GAAG,CAAC,GAAG,EAAE,CAAC;QACR,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,KAAC,eAAe,IAAC,QAAQ,SAAG,CAAC,CAAC;IAAA,CAC3D,CAAC,CAAC;IACH,MAAM,CAAC,SAAU,CAAC,MAAM,EAAE,CAAC,CAAC,eAAe,EAAE,CAAC;AAAA,CAC/C,CAAC,CAAC"}
|
package/lib/index.d.ts
CHANGED
package/lib/index.js
CHANGED
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
import type { SeparatorProps } from './Separator.types';
|
|
2
|
-
export declare const Separator: import(
|
|
2
|
+
export declare const Separator: import('@fluentui-react-native/framework').ComposableComponent<
|
|
3
|
+
SeparatorProps,
|
|
4
|
+
import('./Separator.types').SeperatorSlotProps,
|
|
5
|
+
import('./Separator.types').SeparatorTokens,
|
|
6
|
+
import('@fluentui-react-native/framework').ObjectBase
|
|
7
|
+
>;
|
|
3
8
|
export default Separator;
|
|
4
|
-
//# sourceMappingURL=Separator.d.ts.map
|
|
9
|
+
//# sourceMappingURL=Separator.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.d.ts","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Separator.d.ts","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,mBAAmB,CAAC;AAKvE,eAAO,MAAM,SAAS,oOAQpB,CAAC;AAEH,eAAe,SAAS,CAAC"}
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.Separator = void 0;
|
|
4
|
-
|
|
5
|
-
/** @
|
|
6
|
-
const react_native_1 = require(
|
|
7
|
-
const framework_1 = require(
|
|
8
|
-
const Separator_styling_1 = require(
|
|
9
|
-
const Separator_types_1 = require(
|
|
4
|
+
const jsx_runtime_1 = require('@fluentui-react-native/framework-base/jsx-runtime');
|
|
5
|
+
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
6
|
+
const react_native_1 = require('react-native');
|
|
7
|
+
const framework_1 = require('@fluentui-react-native/framework');
|
|
8
|
+
const Separator_styling_1 = require('./Separator.styling');
|
|
9
|
+
const Separator_types_1 = require('./Separator.types');
|
|
10
10
|
const propMask = { vertical: undefined };
|
|
11
11
|
exports.Separator = (0, framework_1.compose)({
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
12
|
+
displayName: Separator_types_1.separatorName,
|
|
13
|
+
...Separator_styling_1.stylingSettings,
|
|
14
|
+
slots: { root: react_native_1.View },
|
|
15
|
+
useRender: (props, useSlots) => {
|
|
16
|
+
const Root = useSlots(props).root;
|
|
17
|
+
return (rest, children) => jsx_runtime_1.jsx(Root, { ...(0, framework_1.mergeProps)(props, rest, propMask), children: children });
|
|
18
|
+
},
|
|
19
19
|
});
|
|
20
20
|
exports.default = exports.Separator;
|
|
21
|
-
//# sourceMappingURL=Separator.js.map
|
|
21
|
+
//# sourceMappingURL=Separator.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.js","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Separator.js","sourceRoot":"","sources":["../src/Separator.tsx"],"names":[],"mappings":";;;;AAAA,6DAA6D;AAC7D,+CAAoC;AAGpC,gEAAuE;AAEvE,2DAAsD;AAEtD,uDAAkD;AAElD,MAAM,QAAQ,GAAG,EAAE,QAAQ,EAAE,SAAS,EAAE,CAAC;AAE5B,QAAA,SAAS,GAAG,IAAA,mBAAO,EAAgB;IAC9C,WAAW,EAAE,+BAAa;IAC1B,GAAG,mCAAe;IAClB,KAAK,EAAE,EAAE,IAAI,EAAE,mBAAI,EAAE;IACrB,SAAS,EAAE,CAAC,KAAqB,EAAE,QAAiC,EAAE,EAAE,CAAC;QACvE,MAAM,IAAI,GAAG,QAAQ,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC;QAClC,OAAO,CAAC,IAAoB,EAAE,QAAyB,EAAE,EAAE,CAAC,kBAAC,IAAI,OAAK,IAAA,sBAAU,EAAC,KAAK,EAAE,IAAI,EAAE,QAAQ,CAAC,YAAG,QAAQ,GAAQ,CAAC;IAAA,CAC5H;CACF,CAAC,CAAC;kBAEY,QAAA,SAAS"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { UseStylingOptions } from '@fluentui-react-native/framework';
|
|
2
2
|
import type { SeparatorProps, SeparatorTokens, SeperatorSlotProps } from './Separator.types';
|
|
3
3
|
export declare const stylingSettings: UseStylingOptions<SeparatorProps, SeperatorSlotProps, SeparatorTokens>;
|
|
4
|
-
//# sourceMappingURL=Separator.styling.d.ts.map
|
|
4
|
+
//# sourceMappingURL=Separator.styling.d.ts.map
|
|
@@ -1,25 +1,28 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.stylingSettings = void 0;
|
|
4
|
-
const react_native_1 = require(
|
|
5
|
-
const framework_1 = require(
|
|
6
|
-
const Separator_types_1 = require(
|
|
7
|
-
const SeparatorTokens_1 = require(
|
|
4
|
+
const react_native_1 = require('react-native');
|
|
5
|
+
const framework_1 = require('@fluentui-react-native/framework');
|
|
6
|
+
const Separator_types_1 = require('./Separator.types');
|
|
7
|
+
const SeparatorTokens_1 = require('./SeparatorTokens');
|
|
8
8
|
const isMobile = react_native_1.Platform.OS === 'android' || react_native_1.Platform.OS === 'ios';
|
|
9
9
|
const tokensThatAreAlsoProps = ['vertical', 'insetSpacing'];
|
|
10
10
|
exports.stylingSettings = {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
23
|
-
|
|
11
|
+
tokens: [SeparatorTokens_1.defaultSeparatorTokens, Separator_types_1.separatorName],
|
|
12
|
+
tokensThatAreAlsoProps,
|
|
13
|
+
slotProps: {
|
|
14
|
+
root: (0, framework_1.buildProps)(
|
|
15
|
+
(tokens) => {
|
|
16
|
+
return {
|
|
17
|
+
style: {
|
|
18
|
+
...(tokens.vertical ? { borderLeftWidth: tokens.separatorWidth } : { borderTopWidth: tokens.separatorWidth }),
|
|
19
|
+
...(tokens.color && { borderColor: tokens.color }),
|
|
20
|
+
...(isMobile && { marginStart: tokens.insetSpacing }),
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
},
|
|
24
|
+
['color', 'vertical', 'separatorWidth', 'insetSpacing'],
|
|
25
|
+
),
|
|
26
|
+
},
|
|
24
27
|
};
|
|
25
|
-
//# sourceMappingURL=Separator.styling.js.map
|
|
28
|
+
//# sourceMappingURL=Separator.styling.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.styling.js","sourceRoot":"","sources":["../src/Separator.styling.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAGxC,gEAA8D;AAG9D,uDAAkD;AAClD,uDAA2D;AAE3D,MAAM,QAAQ,GAAG,uBAAQ,CAAC,EAAE,KAAK,SAAS,IAAI,uBAAQ,CAAC,EAAE,KAAK,KAAK,CAAC;AACpE,MAAM,sBAAsB,GAAkC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;AAC9E,QAAA,eAAe,GAA2E;IACrG,MAAM,EAAE,CAAC,wCAAsB,EAAE,+BAAa,CAAC;IAC/C,sBAAsB;IACtB,SAAS,EAAE;QACT,IAAI,EAAE,IAAA,sBAAU,EACd,CAAC,MAAuB,EAAE,EAAE;
|
|
1
|
+
{"version":3,"file":"Separator.styling.js","sourceRoot":"","sources":["../src/Separator.styling.tsx"],"names":[],"mappings":";;;AAAA,+CAAwC;AAGxC,gEAA8D;AAG9D,uDAAkD;AAClD,uDAA2D;AAE3D,MAAM,QAAQ,GAAG,uBAAQ,CAAC,EAAE,KAAK,SAAS,IAAI,uBAAQ,CAAC,EAAE,KAAK,KAAK,CAAC;AACpE,MAAM,sBAAsB,GAAkC,CAAC,UAAU,EAAE,cAAc,CAAC,CAAC;AAC9E,QAAA,eAAe,GAA2E;IACrG,MAAM,EAAE,CAAC,wCAAsB,EAAE,+BAAa,CAAC;IAC/C,sBAAsB;IACtB,SAAS,EAAE;QACT,IAAI,EAAE,IAAA,sBAAU,EACd,CAAC,MAAuB,EAAE,EAAE,CAAC;YAC3B,OAAO;gBACL,KAAK,EAAE;oBACL,GAAG,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,eAAe,EAAE,MAAM,CAAC,cAAc,EAAE,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,MAAM,CAAC,cAAc,EAAE,CAAC;oBAC7G,GAAG,CAAC,MAAM,CAAC,KAAK,IAAI,EAAE,WAAW,EAAE,MAAM,CAAC,KAAK,EAAE,CAAC;oBAClD,GAAG,CAAC,QAAQ,IAAI,EAAE,WAAW,EAAE,MAAM,CAAC,YAAY,EAAE,CAAC;iBACtD;aACF,CAAC;QAAA,CACH,EACD,CAAC,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,cAAc,CAAC,CACxD;KACF;CACF,CAAC"}
|
|
@@ -1,42 +1,41 @@
|
|
|
1
1
|
import type { ViewProps, ColorValue } from 'react-native';
|
|
2
|
-
export declare const separatorName =
|
|
2
|
+
export declare const separatorName = 'Separator';
|
|
3
3
|
export declare const SeparatorInsetSpacings: readonly [0, 16, 56, 68, 72, 108];
|
|
4
4
|
export type SeparatorInsetSpacing = (typeof SeparatorInsetSpacings)[number];
|
|
5
5
|
export interface SeparatorPropTokens {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Specifies whether the separator is vertical or horizontal. If true, then it's vertical.
|
|
8
|
+
* @defaultValue 'false'
|
|
9
|
+
*/
|
|
10
|
+
vertical?: boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Inset Spacing in 'dp' (density-independent pixels) on Android and 'points' on iOS.
|
|
13
|
+
*
|
|
14
|
+
* Inset Spacing is restricted to a limited set of supported values recommended for most uses (see `SeparatorInsetSpacing`) and
|
|
15
|
+
* based on design guidelines for the Separator control.
|
|
16
|
+
* @platform Android iOS
|
|
17
|
+
* @defaultvalue 0
|
|
18
|
+
*/
|
|
19
|
+
insetSpacing?: SeparatorInsetSpacing;
|
|
20
20
|
}
|
|
21
21
|
export interface SeparatorTokens extends SeparatorPropTokens {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
}
|
|
32
|
-
export interface SeparatorProps extends ViewProps, SeparatorPropTokens {
|
|
22
|
+
/**
|
|
23
|
+
* Specifies the width of the separator. This will be interpreted as DIPs on Windows and Android, but as points on Mac and iOS.
|
|
24
|
+
* @defaultValue 1
|
|
25
|
+
*/
|
|
26
|
+
separatorWidth?: number;
|
|
27
|
+
/**
|
|
28
|
+
* Specifies the color of the separator
|
|
29
|
+
*/
|
|
30
|
+
color?: ColorValue;
|
|
33
31
|
}
|
|
32
|
+
export interface SeparatorProps extends ViewProps, SeparatorPropTokens {}
|
|
34
33
|
export interface SeperatorSlotProps {
|
|
35
|
-
|
|
34
|
+
root: ViewProps;
|
|
36
35
|
}
|
|
37
36
|
export interface SeparatorType {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
37
|
+
props: SeparatorProps;
|
|
38
|
+
slotProps: SeperatorSlotProps;
|
|
39
|
+
tokens: SeparatorTokens;
|
|
41
40
|
}
|
|
42
|
-
//# sourceMappingURL=Separator.types.d.ts.map
|
|
41
|
+
//# sourceMappingURL=Separator.types.d.ts.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.SeparatorInsetSpacings = exports.separatorName = void 0;
|
|
4
4
|
exports.separatorName = 'Separator';
|
|
5
5
|
exports.SeparatorInsetSpacings = [0, 16, 56, 68, 72, 108];
|
|
6
|
-
//# sourceMappingURL=Separator.types.js.map
|
|
6
|
+
//# sourceMappingURL=Separator.types.js.map
|
|
@@ -2,4 +2,4 @@ import type { Theme } from '@fluentui-react-native/framework';
|
|
|
2
2
|
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
|
3
3
|
import type { SeparatorTokens } from './Separator.types';
|
|
4
4
|
export declare const defaultSeparatorTokens: TokenSettings<SeparatorTokens, Theme>;
|
|
5
|
-
//# sourceMappingURL=SeparatorTokens.android.d.ts.map
|
|
5
|
+
//# sourceMappingURL=SeparatorTokens.android.d.ts.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.defaultSeparatorTokens = void 0;
|
|
4
|
-
const theme_tokens_1 = require(
|
|
4
|
+
const theme_tokens_1 = require('@fluentui-react-native/theme-tokens');
|
|
5
5
|
const defaultSeparatorTokens = (t) => ({
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
6
|
+
color: t.colors.neutralStroke2,
|
|
7
|
+
separatorWidth: theme_tokens_1.globalTokens.stroke.width10,
|
|
8
|
+
insetSpacing: 0,
|
|
9
9
|
});
|
|
10
10
|
exports.defaultSeparatorTokens = defaultSeparatorTokens;
|
|
11
|
-
//# sourceMappingURL=SeparatorTokens.android.js.map
|
|
11
|
+
//# sourceMappingURL=SeparatorTokens.android.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SeparatorTokens.android.js","sourceRoot":"","sources":["../src/SeparatorTokens.android.tsx"],"names":[],"mappings":";;;AACA,sEAAmE;AAK5D,MAAM,sBAAsB,GAA0C,CAAC,CAAQ,EAAE,EAAE,
|
|
1
|
+
{"version":3,"file":"SeparatorTokens.android.js","sourceRoot":"","sources":["../src/SeparatorTokens.android.tsx"],"names":[],"mappings":";;;AACA,sEAAmE;AAK5D,MAAM,sBAAsB,GAA0C,CAAC,CAAQ,EAAE,EAAE,EACvF;IACC,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,cAAc;IAC9B,cAAc,EAAE,2BAAY,CAAC,MAAM,CAAC,OAAO;IAC3C,YAAY,EAAE,CAAC;CACI,CAAA,CAAC;AALX,QAAA,sBAAsB,GAAtB,sBAAsB,CAKX"}
|
|
@@ -2,4 +2,4 @@ import type { Theme } from '@fluentui-react-native/framework';
|
|
|
2
2
|
import type { TokenSettings } from '@fluentui-react-native/use-styling';
|
|
3
3
|
import type { SeparatorTokens } from './Separator.types';
|
|
4
4
|
export declare const defaultSeparatorTokens: TokenSettings<SeparatorTokens, Theme>;
|
|
5
|
-
//# sourceMappingURL=SeparatorTokens.d.ts.map
|
|
5
|
+
//# sourceMappingURL=SeparatorTokens.d.ts.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.defaultSeparatorTokens = void 0;
|
|
4
|
-
const theme_tokens_1 = require(
|
|
4
|
+
const theme_tokens_1 = require('@fluentui-react-native/theme-tokens');
|
|
5
5
|
const defaultSeparatorTokens = () => ({
|
|
6
|
-
|
|
6
|
+
separatorWidth: theme_tokens_1.globalTokens.stroke.width10,
|
|
7
7
|
});
|
|
8
8
|
exports.defaultSeparatorTokens = defaultSeparatorTokens;
|
|
9
|
-
//# sourceMappingURL=SeparatorTokens.js.map
|
|
9
|
+
//# sourceMappingURL=SeparatorTokens.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SeparatorTokens.js","sourceRoot":"","sources":["../src/SeparatorTokens.tsx"],"names":[],"mappings":";;;AACA,sEAAmE;AAK5D,MAAM,sBAAsB,GAA0C,GAAG,EAAE,
|
|
1
|
+
{"version":3,"file":"SeparatorTokens.js","sourceRoot":"","sources":["../src/SeparatorTokens.tsx"],"names":[],"mappings":";;;AACA,sEAAmE;AAK5D,MAAM,sBAAsB,GAA0C,GAAG,EAAE,EAC/E;IACC,cAAc,EAAE,2BAAY,CAAC,MAAM,CAAC,OAAO;CACxB,CAAA,CAAC;AAHX,QAAA,sBAAsB,GAAtB,sBAAsB,CAGX"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export {};
|
|
2
|
-
//# sourceMappingURL=Separator.test.d.ts.map
|
|
2
|
+
//# sourceMappingURL=Separator.test.d.ts.map
|
|
@@ -1,38 +1,72 @@
|
|
|
1
|
-
|
|
2
|
-
var __createBinding =
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
1
|
+
'use strict';
|
|
2
|
+
var __createBinding =
|
|
3
|
+
(this && this.__createBinding) ||
|
|
4
|
+
(Object.create
|
|
5
|
+
? function (o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ('get' in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = {
|
|
10
|
+
enumerable: true,
|
|
11
|
+
get: function () {
|
|
12
|
+
return m[k];
|
|
13
|
+
},
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
Object.defineProperty(o, k2, desc);
|
|
17
|
+
}
|
|
18
|
+
: function (o, m, k, k2) {
|
|
19
|
+
if (k2 === undefined) k2 = k;
|
|
20
|
+
o[k2] = m[k];
|
|
21
|
+
});
|
|
22
|
+
var __setModuleDefault =
|
|
23
|
+
(this && this.__setModuleDefault) ||
|
|
24
|
+
(Object.create
|
|
25
|
+
? function (o, v) {
|
|
26
|
+
Object.defineProperty(o, 'default', { enumerable: true, value: v });
|
|
27
|
+
}
|
|
28
|
+
: function (o, v) {
|
|
29
|
+
o['default'] = v;
|
|
30
|
+
});
|
|
31
|
+
var __importStar =
|
|
32
|
+
(this && this.__importStar) ||
|
|
33
|
+
(function () {
|
|
34
|
+
var ownKeys = function (o) {
|
|
35
|
+
ownKeys =
|
|
36
|
+
Object.getOwnPropertyNames ||
|
|
37
|
+
function (o) {
|
|
38
|
+
var ar = [];
|
|
39
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
40
|
+
return ar;
|
|
41
|
+
};
|
|
42
|
+
return ownKeys(o);
|
|
43
|
+
};
|
|
44
|
+
return function (mod) {
|
|
45
|
+
if (mod && mod.__esModule) return mod;
|
|
46
|
+
var result = {};
|
|
47
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== 'default') __createBinding(result, mod, k[i]);
|
|
48
|
+
__setModuleDefault(result, mod);
|
|
49
|
+
return result;
|
|
50
|
+
};
|
|
51
|
+
})();
|
|
52
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
53
|
+
const jsx_runtime_1 = require('react/jsx-runtime');
|
|
54
|
+
const react_1 = require('react');
|
|
55
|
+
const renderer = __importStar(require('react-test-renderer'));
|
|
56
|
+
const __1 = require('..');
|
|
29
57
|
it('Separator default', () => {
|
|
30
|
-
|
|
31
|
-
|
|
58
|
+
let component;
|
|
59
|
+
(0, react_1.act)(() => {
|
|
60
|
+
component = renderer.create(jsx_runtime_1.jsx(__1.Separator, {}));
|
|
61
|
+
});
|
|
62
|
+
expect(component.toJSON()).toMatchSnapshot();
|
|
32
63
|
});
|
|
33
64
|
it('Separator all props & tokens', () => {
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
65
|
+
const CustomSeparator = __1.Separator.customize({ separatorWidth: 15, color: 'red' });
|
|
66
|
+
let component;
|
|
67
|
+
(0, react_1.act)(() => {
|
|
68
|
+
component = renderer.create(jsx_runtime_1.jsx(CustomSeparator, { vertical: true }));
|
|
69
|
+
});
|
|
70
|
+
expect(component.toJSON()).toMatchSnapshot();
|
|
37
71
|
});
|
|
38
|
-
//# sourceMappingURL=Separator.test.js.map
|
|
72
|
+
//# sourceMappingURL=Separator.test.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Separator.test.js","sourceRoot":"","sources":["../../src/__tests__/Separator.test.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Separator.test.js","sourceRoot":"","sources":["../../src/__tests__/Separator.test.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iCAA4B;AAE5B,MAAY,QAAQ,gDAA4B;AAEhD,0BAA+B;AAE/B,EAAE,CAAC,mBAAmB,EAAE,GAAG,EAAE,CAAC;IAC5B,IAAI,SAAqC,CAAC;IAC1C,IAAA,WAAG,EAAC,GAAG,EAAE,CAAC;QACR,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,kBAAC,aAAS,KAAG,CAAC,CAAC;IAAA,CAC5C,CAAC,CAAC;IACH,MAAM,CAAC,SAAU,CAAC,MAAM,EAAE,CAAC,CAAC,eAAe,EAAE,CAAC;AAAA,CAC/C,CAAC,CAAC;AAEH,EAAE,CAAC,8BAA8B,EAAE,GAAG,EAAE,CAAC;IACvC,MAAM,eAAe,GAAG,aAAS,CAAC,SAAS,CAAC,EAAE,cAAc,EAAE,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;IAClF,IAAI,SAAqC,CAAC;IAC1C,IAAA,WAAG,EAAC,GAAG,EAAE,CAAC;QACR,SAAS,GAAG,QAAQ,CAAC,MAAM,CAAC,kBAAC,eAAe,IAAC,QAAQ,SAAG,CAAC,CAAC;IAAA,CAC3D,CAAC,CAAC;IACH,MAAM,CAAC,SAAU,CAAC,MAAM,EAAE,CAAC,CAAC,eAAe,EAAE,CAAC;AAAA,CAC/C,CAAC,CAAC"}
|
package/lib-commonjs/index.d.ts
CHANGED
package/lib-commonjs/index.js
CHANGED
|
@@ -1,8 +1,18 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
'use strict';
|
|
2
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
3
3
|
exports.Separator = exports.separatorName = void 0;
|
|
4
|
-
|
|
5
|
-
Object.defineProperty(exports,
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
const Separator_types_1 = require('./Separator.types');
|
|
5
|
+
Object.defineProperty(exports, 'separatorName', {
|
|
6
|
+
enumerable: true,
|
|
7
|
+
get: function () {
|
|
8
|
+
return Separator_types_1.separatorName;
|
|
9
|
+
},
|
|
10
|
+
});
|
|
11
|
+
const Separator_1 = require('./Separator');
|
|
12
|
+
Object.defineProperty(exports, 'Separator', {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () {
|
|
15
|
+
return Separator_1.Separator;
|
|
16
|
+
},
|
|
17
|
+
});
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AACA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;AACA,uDAAkD;AAAzC,gHAAA,aAAa,OAAA;AACtB,2CAAwC;AAA/B,sGAAA,SAAS,OAAA"}
|
package/package.json
CHANGED
|
@@ -1,79 +1,88 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui-react-native/separator",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.19.0",
|
|
4
4
|
"description": "A cross-platform Separator component using the Fluent Design System",
|
|
5
|
-
"
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "https://github.com/microsoft/fluentui-react-native.git",
|
|
8
|
+
"directory": "packages/components/Separator"
|
|
9
|
+
},
|
|
10
|
+
"license": "MIT",
|
|
11
|
+
"author": "",
|
|
8
12
|
"exports": {
|
|
9
13
|
".": {
|
|
14
|
+
"types": "./lib/index.d.ts",
|
|
10
15
|
"import": "./lib/index.js",
|
|
11
|
-
"require": "./lib-commonjs/index.js"
|
|
12
|
-
"types": "./lib/index.d.ts"
|
|
16
|
+
"require": "./lib-commonjs/index.js"
|
|
13
17
|
}
|
|
14
18
|
},
|
|
15
|
-
"
|
|
19
|
+
"main": "lib-commonjs/index.js",
|
|
20
|
+
"module": "lib/index.js",
|
|
21
|
+
"types": "lib/index.d.ts",
|
|
16
22
|
"scripts": {
|
|
17
23
|
"build": "fluentui-scripts build",
|
|
18
|
-
"
|
|
24
|
+
"build-cjs": "tsgo --outDir lib-commonjs",
|
|
25
|
+
"build-esm": "tsgo --outDir lib --module esnext --moduleResolution bundler",
|
|
19
26
|
"clean": "fluentui-scripts clean",
|
|
20
27
|
"depcheck": "fluentui-scripts depcheck",
|
|
21
28
|
"lint": "fluentui-scripts eslint",
|
|
22
|
-
"
|
|
23
|
-
"update-snapshots": "fluentui-scripts jest -u",
|
|
29
|
+
"lint-package": "fluentui-scripts lint-package",
|
|
24
30
|
"prettier": "fluentui-scripts prettier",
|
|
25
|
-
"
|
|
26
|
-
|
|
27
|
-
"repository": {
|
|
28
|
-
"type": "git",
|
|
29
|
-
"url": "https://github.com/microsoft/fluentui-react-native.git",
|
|
30
|
-
"directory": "packages/components/Separator"
|
|
31
|
+
"test": "fluentui-scripts jest",
|
|
32
|
+
"update-snapshots": "fluentui-scripts jest -u"
|
|
31
33
|
},
|
|
32
34
|
"dependencies": {
|
|
33
|
-
"@fluentui-react-native/framework": "0.
|
|
34
|
-
"@fluentui-react-native/theme-tokens": "0.
|
|
35
|
-
"@fluentui-react-native/use-styling": "0.
|
|
35
|
+
"@fluentui-react-native/framework": "0.15.0",
|
|
36
|
+
"@fluentui-react-native/theme-tokens": "0.28.0",
|
|
37
|
+
"@fluentui-react-native/use-styling": "0.14.0"
|
|
36
38
|
},
|
|
37
39
|
"devDependencies": {
|
|
38
40
|
"@babel/core": "^7.20.0",
|
|
39
41
|
"@fluentui-react-native/babel-config": "0.1.1",
|
|
40
42
|
"@fluentui-react-native/eslint-config-rules": "0.1.1",
|
|
43
|
+
"@fluentui-react-native/framework-base": "0.3.0",
|
|
41
44
|
"@fluentui-react-native/jest-config": "0.1.1",
|
|
42
|
-
"@fluentui-react-native/
|
|
45
|
+
"@fluentui-react-native/kit-config": "0.1.2",
|
|
46
|
+
"@fluentui-react-native/scripts": "0.1.2",
|
|
43
47
|
"@office-iss/react-native-win32": "^0.74.0",
|
|
44
|
-
"@react-native/
|
|
45
|
-
"@react-native/
|
|
46
|
-
"@
|
|
47
|
-
"@
|
|
48
|
-
"react": "
|
|
49
|
-
"react
|
|
50
|
-
"react-
|
|
51
|
-
"react
|
|
52
|
-
"react-
|
|
48
|
+
"@react-native-community/cli": "^20.0.0",
|
|
49
|
+
"@react-native-community/cli-platform-android": "^20.0.0",
|
|
50
|
+
"@react-native-community/cli-platform-ios": "^20.0.0",
|
|
51
|
+
"@react-native/babel-preset": "^0.81.0",
|
|
52
|
+
"@react-native/metro-config": "^0.81.0",
|
|
53
|
+
"@types/react": "~19.1.0",
|
|
54
|
+
"@types/react-test-renderer": "^19.1.0",
|
|
55
|
+
"react": "19.1.0",
|
|
56
|
+
"react-native": "^0.81.0",
|
|
57
|
+
"react-native-macos": "^0.81.0",
|
|
58
|
+
"react-native-windows": "^0.81.0",
|
|
59
|
+
"react-test-renderer": "19.1.0"
|
|
53
60
|
},
|
|
54
61
|
"peerDependencies": {
|
|
55
62
|
"@office-iss/react-native-win32": "^0.74.0",
|
|
56
|
-
"react": "18.2.0",
|
|
57
|
-
"react
|
|
58
|
-
"react-native
|
|
59
|
-
"react-native-
|
|
63
|
+
"@types/react": "~18.2.0 || ~19.0.0 || ~19.1.0",
|
|
64
|
+
"react": "18.2.0 || 19.0.0 || 19.1.0",
|
|
65
|
+
"react-native": "^0.73.0 || ^0.74.0 || ^0.78.0 || ^0.81.0",
|
|
66
|
+
"react-native-macos": "^0.73.0 || ^0.74.0 || ^0.78.0 || ^0.81.0",
|
|
67
|
+
"react-native-windows": "^0.73.0 || ^0.74.0 || ^0.78.0 || ^0.81.0"
|
|
68
|
+
},
|
|
69
|
+
"peerDependenciesMeta": {
|
|
70
|
+
"@office-iss/react-native-win32": {
|
|
71
|
+
"optional": true
|
|
72
|
+
},
|
|
73
|
+
"@types/react": {
|
|
74
|
+
"optional": true
|
|
75
|
+
},
|
|
76
|
+
"react-native-macos": {
|
|
77
|
+
"optional": true
|
|
78
|
+
},
|
|
79
|
+
"react-native-windows": {
|
|
80
|
+
"optional": true
|
|
81
|
+
}
|
|
60
82
|
},
|
|
61
|
-
"author": "",
|
|
62
|
-
"license": "MIT",
|
|
63
83
|
"rnx-kit": {
|
|
64
84
|
"kitType": "library",
|
|
65
85
|
"alignDeps": {
|
|
66
|
-
"presets": [
|
|
67
|
-
"microsoft/react-native"
|
|
68
|
-
],
|
|
69
|
-
"requirements": {
|
|
70
|
-
"development": [
|
|
71
|
-
"react-native@0.74"
|
|
72
|
-
],
|
|
73
|
-
"production": [
|
|
74
|
-
"react-native@0.73 || 0.74"
|
|
75
|
-
]
|
|
76
|
-
},
|
|
77
86
|
"capabilities": [
|
|
78
87
|
"babel-preset-react-native",
|
|
79
88
|
"core",
|
|
@@ -82,19 +91,11 @@
|
|
|
82
91
|
"core-macos",
|
|
83
92
|
"core-windows",
|
|
84
93
|
"react",
|
|
85
|
-
"react-test-renderer"
|
|
94
|
+
"react-test-renderer",
|
|
95
|
+
"tools-core",
|
|
96
|
+
"tools-jest"
|
|
86
97
|
]
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
"peerDependenciesMeta": {
|
|
90
|
-
"@office-iss/react-native-win32": {
|
|
91
|
-
"optional": true
|
|
92
98
|
},
|
|
93
|
-
"react-native-
|
|
94
|
-
"optional": true
|
|
95
|
-
},
|
|
96
|
-
"react-native-windows": {
|
|
97
|
-
"optional": true
|
|
98
|
-
}
|
|
99
|
+
"extends": "@fluentui-react-native/kit-config"
|
|
99
100
|
}
|
|
100
|
-
}
|
|
101
|
+
}
|
package/src/Separator.tsx
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
/** @
|
|
2
|
-
/** @jsx withSlots */
|
|
1
|
+
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
3
2
|
import { View } from 'react-native';
|
|
4
3
|
|
|
5
4
|
import type { UseSlots } from '@fluentui-react-native/framework';
|
|
6
|
-
import { compose,
|
|
5
|
+
import { compose, mergeProps } from '@fluentui-react-native/framework';
|
|
7
6
|
|
|
8
7
|
import { stylingSettings } from './Separator.styling';
|
|
9
8
|
import type { SeparatorProps, SeparatorType } from './Separator.types';
|
|
@@ -1,16 +1,22 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { act } from 'react';
|
|
2
2
|
|
|
3
3
|
import * as renderer from 'react-test-renderer';
|
|
4
4
|
|
|
5
5
|
import { Separator } from '..';
|
|
6
6
|
|
|
7
7
|
it('Separator default', () => {
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
let component: renderer.ReactTestRenderer;
|
|
9
|
+
act(() => {
|
|
10
|
+
component = renderer.create(<Separator />);
|
|
11
|
+
});
|
|
12
|
+
expect(component!.toJSON()).toMatchSnapshot();
|
|
10
13
|
});
|
|
11
14
|
|
|
12
15
|
it('Separator all props & tokens', () => {
|
|
13
16
|
const CustomSeparator = Separator.customize({ separatorWidth: 15, color: 'red' });
|
|
14
|
-
|
|
15
|
-
|
|
17
|
+
let component: renderer.ReactTestRenderer;
|
|
18
|
+
act(() => {
|
|
19
|
+
component = renderer.create(<CustomSeparator vertical />);
|
|
20
|
+
});
|
|
21
|
+
expect(component!.toJSON()).toMatchSnapshot();
|
|
16
22
|
});
|