@fluentui/react-tabs 9.0.0-beta.8 → 9.0.0-beta.9
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 +108 -1
- package/CHANGELOG.md +24 -2
- package/dist/react-tabs.d.ts +48 -36
- package/lib/components/Tab/Tab.types.d.ts +14 -5
- package/lib/components/Tab/Tab.types.js.map +1 -1
- package/lib/components/Tab/index.d.ts +1 -0
- package/lib/components/Tab/index.js +1 -0
- package/lib/components/Tab/index.js.map +1 -1
- package/lib/components/Tab/renderTab.js +1 -2
- package/lib/components/Tab/renderTab.js.map +1 -1
- package/lib/components/Tab/useTab.js +25 -29
- package/lib/components/Tab/useTab.js.map +1 -1
- package/lib/components/Tab/useTabAnimatedIndicator.d.ts +5 -0
- package/lib/components/Tab/useTabAnimatedIndicator.js +134 -0
- package/lib/components/Tab/useTabAnimatedIndicator.js.map +1 -0
- package/lib/components/Tab/useTabStyles.d.ts +4 -2
- package/lib/components/Tab/useTabStyles.js +280 -84
- package/lib/components/Tab/useTabStyles.js.map +1 -1
- package/lib/components/TabList/TabList.types.d.ts +21 -16
- package/lib/components/TabList/TabList.types.js.map +1 -1
- package/lib/components/TabList/TabListContext.js +6 -0
- package/lib/components/TabList/TabListContext.js.map +1 -1
- package/lib/components/TabList/renderTabList.js +0 -1
- package/lib/components/TabList/renderTabList.js.map +1 -1
- package/lib/components/TabList/useTabList.js +26 -51
- package/lib/components/TabList/useTabList.js.map +1 -1
- package/lib/components/TabList/useTabListContextValues.js +4 -0
- package/lib/components/TabList/useTabListContextValues.js.map +1 -1
- package/lib/components/TabList/useTabListStyles.d.ts +4 -5
- package/lib/components/TabList/useTabListStyles.js +8 -90
- package/lib/components/TabList/useTabListStyles.js.map +1 -1
- package/lib/index.d.ts +4 -2
- package/lib/index.js +2 -2
- package/lib/index.js.map +1 -1
- package/lib/tab.constants.d.ts +59 -12
- package/lib/tab.constants.js +64 -13
- package/lib/tab.constants.js.map +1 -1
- package/lib-commonjs/components/Tab/Tab.types.d.ts +14 -5
- package/lib-commonjs/components/Tab/index.d.ts +1 -0
- package/lib-commonjs/components/Tab/index.js +2 -0
- package/lib-commonjs/components/Tab/index.js.map +1 -1
- package/lib-commonjs/components/Tab/renderTab.js +1 -2
- package/lib-commonjs/components/Tab/renderTab.js.map +1 -1
- package/lib-commonjs/components/Tab/useTab.js +25 -29
- package/lib-commonjs/components/Tab/useTab.js.map +1 -1
- package/lib-commonjs/components/Tab/useTabAnimatedIndicator.d.ts +5 -0
- package/lib-commonjs/components/Tab/useTabAnimatedIndicator.js +148 -0
- package/lib-commonjs/components/Tab/useTabAnimatedIndicator.js.map +1 -0
- package/lib-commonjs/components/Tab/useTabStyles.d.ts +4 -2
- package/lib-commonjs/components/Tab/useTabStyles.js +281 -84
- package/lib-commonjs/components/Tab/useTabStyles.js.map +1 -1
- package/lib-commonjs/components/TabList/TabList.types.d.ts +21 -16
- package/lib-commonjs/components/TabList/TabListContext.js +6 -0
- package/lib-commonjs/components/TabList/TabListContext.js.map +1 -1
- package/lib-commonjs/components/TabList/renderTabList.js +0 -1
- package/lib-commonjs/components/TabList/renderTabList.js.map +1 -1
- package/lib-commonjs/components/TabList/useTabList.js +25 -50
- package/lib-commonjs/components/TabList/useTabList.js.map +1 -1
- package/lib-commonjs/components/TabList/useTabListContextValues.js +4 -0
- package/lib-commonjs/components/TabList/useTabListContextValues.js.map +1 -1
- package/lib-commonjs/components/TabList/useTabListStyles.d.ts +4 -5
- package/lib-commonjs/components/TabList/useTabListStyles.js +7 -92
- package/lib-commonjs/components/TabList/useTabListStyles.js.map +1 -1
- package/lib-commonjs/index.d.ts +4 -2
- package/lib-commonjs/index.js +76 -3
- package/lib-commonjs/index.js.map +1 -1
- package/lib-commonjs/tab.constants.d.ts +59 -12
- package/lib-commonjs/tab.constants.js +66 -14
- package/lib-commonjs/tab.constants.js.map +1 -1
- package/package.json +9 -18
|
@@ -1,23 +1,75 @@
|
|
|
1
|
-
"use strict";
|
|
1
|
+
"use strict"; // TODO: Constants prefixed with pending should be replaced with design tokens
|
|
2
|
+
// These values were taken from the design token superset figma
|
|
2
3
|
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
|
-
exports.
|
|
7
|
+
exports.tabIndicatorStrokeWidths = exports.tabIndicatorPadding = exports.pendingAnimationEasingTokens = exports.pendingAnimationDurationTokens = exports.pendingSpacingTokens = exports.pendingContentSizeTokens = void 0;
|
|
7
8
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
small: '2px'
|
|
9
|
+
const react_theme_1 = /*#__PURE__*/require("@fluentui/react-theme");
|
|
10
|
+
|
|
11
|
+
exports.pendingContentSizeTokens = {
|
|
12
|
+
// Only body sizes are defined here currently
|
|
13
|
+
body1: {
|
|
14
|
+
fontSize: react_theme_1.tokens.fontSizeBase300,
|
|
15
|
+
fontWeight: react_theme_1.tokens.fontWeightRegular,
|
|
16
|
+
lineHeight: react_theme_1.tokens.lineHeightBase300
|
|
17
17
|
},
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
18
|
+
body1Strong: {
|
|
19
|
+
fontSize: react_theme_1.tokens.fontSizeBase300,
|
|
20
|
+
fontWeight: react_theme_1.tokens.fontWeightSemibold,
|
|
21
|
+
lineHeight: react_theme_1.tokens.lineHeightBase300
|
|
21
22
|
}
|
|
22
23
|
};
|
|
24
|
+
exports.pendingSpacingTokens = {
|
|
25
|
+
none: '0',
|
|
26
|
+
xxs: '2px',
|
|
27
|
+
xs: '4px',
|
|
28
|
+
sNudge: '6px',
|
|
29
|
+
s: '8px',
|
|
30
|
+
mNudge: '10px',
|
|
31
|
+
m: '12px',
|
|
32
|
+
l: '16px',
|
|
33
|
+
xl: '20px',
|
|
34
|
+
xxl: '24px',
|
|
35
|
+
xxxl: '32px'
|
|
36
|
+
};
|
|
37
|
+
exports.pendingAnimationDurationTokens = {
|
|
38
|
+
ultraFast: '50ms',
|
|
39
|
+
faster: '100ms',
|
|
40
|
+
fast: '150ms',
|
|
41
|
+
normal: '200ms',
|
|
42
|
+
slow: '300ms',
|
|
43
|
+
slower: '400ms',
|
|
44
|
+
ultraSlow: '500ms'
|
|
45
|
+
};
|
|
46
|
+
exports.pendingAnimationEasingTokens = {
|
|
47
|
+
accelerateMax: 'cubic-bezier(1,0,1,1)',
|
|
48
|
+
accelerateMid: 'cubic-bezier(0.7,0,1,0.5)',
|
|
49
|
+
accelerateMin: 'cubic-bezier(0.8,0,1,1)',
|
|
50
|
+
declerateMax: 'cubic-bezier(0,0,0,1)',
|
|
51
|
+
decelerateMid: 'cubic-bezier(0.1,0.9,0.2,1)',
|
|
52
|
+
decelarateMin: 'cubic-bezier(0.33,0,0.1,1)',
|
|
53
|
+
maxEasyEase: 'cubic-bezier(0.8,0,0.1,1)',
|
|
54
|
+
easyEase: 'cubic-bezier(0.33,0,0.67,1)',
|
|
55
|
+
linear: 'cubic-bezier(0,0,1,1)'
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* Provides shared values between tab style hooks
|
|
59
|
+
* useTabStyles
|
|
60
|
+
* useTabAnimatedIndicator
|
|
61
|
+
*/
|
|
62
|
+
|
|
63
|
+
exports.tabIndicatorPadding = {
|
|
64
|
+
mediumHorizontal: exports.pendingSpacingTokens.m,
|
|
65
|
+
mediumVertical: exports.pendingSpacingTokens.s,
|
|
66
|
+
smallHorizontal: exports.pendingSpacingTokens.sNudge,
|
|
67
|
+
smallVertical: exports.pendingSpacingTokens.xs
|
|
68
|
+
};
|
|
69
|
+
exports.tabIndicatorStrokeWidths = {
|
|
70
|
+
mediumHorizontal: react_theme_1.tokens.strokeWidthThicker,
|
|
71
|
+
mediumVertical: react_theme_1.tokens.strokeWidthThicker,
|
|
72
|
+
smallHorizontal: react_theme_1.tokens.strokeWidthThick,
|
|
73
|
+
smallVertical: react_theme_1.tokens.strokeWidthThicker
|
|
74
|
+
};
|
|
23
75
|
//# sourceMappingURL=tab.constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["tab.constants.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"sources":["tab.constants.ts"],"names":[],"mappings":"cAAA;AACA;;;;;;;AAEA,MAAA,aAAA,gBAAA,OAAA,CAAA,uBAAA,CAAA;;AAEa,OAAA,CAAA,wBAAA,GAA2B;AACtC;AACA,EAAA,KAAK,EAAE;AACL,IAAA,QAAQ,EAAE,aAAA,CAAA,MAAA,CAAO,eADZ;AAEL,IAAA,UAAU,EAAE,aAAA,CAAA,MAAA,CAAO,iBAFd;AAGL,IAAA,UAAU,EAAE,aAAA,CAAA,MAAA,CAAO;AAHd,GAF+B;AAOtC,EAAA,WAAW,EAAE;AACX,IAAA,QAAQ,EAAE,aAAA,CAAA,MAAA,CAAO,eADN;AAEX,IAAA,UAAU,EAAE,aAAA,CAAA,MAAA,CAAO,kBAFR;AAGX,IAAA,UAAU,EAAE,aAAA,CAAA,MAAA,CAAO;AAHR;AAPyB,CAA3B;AAcA,OAAA,CAAA,oBAAA,GAAuB;AAClC,EAAA,IAAI,EAAE,GAD4B;AAElC,EAAA,GAAG,EAAE,KAF6B;AAGlC,EAAA,EAAE,EAAE,KAH8B;AAIlC,EAAA,MAAM,EAAE,KAJ0B;AAKlC,EAAA,CAAC,EAAE,KAL+B;AAMlC,EAAA,MAAM,EAAE,MAN0B;AAOlC,EAAA,CAAC,EAAE,MAP+B;AAQlC,EAAA,CAAC,EAAE,MAR+B;AASlC,EAAA,EAAE,EAAE,MAT8B;AAUlC,EAAA,GAAG,EAAE,MAV6B;AAWlC,EAAA,IAAI,EAAE;AAX4B,CAAvB;AAcA,OAAA,CAAA,8BAAA,GAAiC;AAC5C,EAAA,SAAS,EAAE,MADiC;AAE5C,EAAA,MAAM,EAAE,OAFoC;AAG5C,EAAA,IAAI,EAAE,OAHsC;AAI5C,EAAA,MAAM,EAAE,OAJoC;AAK5C,EAAA,IAAI,EAAE,OALsC;AAM5C,EAAA,MAAM,EAAE,OANoC;AAO5C,EAAA,SAAS,EAAE;AAPiC,CAAjC;AAUA,OAAA,CAAA,4BAAA,GAA+B;AAC1C,EAAA,aAAa,EAAE,uBAD2B;AAE1C,EAAA,aAAa,EAAE,2BAF2B;AAG1C,EAAA,aAAa,EAAE,yBAH2B;AAI1C,EAAA,YAAY,EAAE,uBAJ4B;AAK1C,EAAA,aAAa,EAAE,6BAL2B;AAM1C,EAAA,aAAa,EAAE,4BAN2B;AAO1C,EAAA,WAAW,EAAE,2BAP6B;AAQ1C,EAAA,QAAQ,EAAE,6BARgC;AAS1C,EAAA,MAAM,EAAE;AATkC,CAA/B;AAYb;;;;AAIG;;AACU,OAAA,CAAA,mBAAA,GAAsB;AACjC,EAAA,gBAAgB,EAAE,OAAA,CAAA,oBAAA,CAAqB,CADN;AAEjC,EAAA,cAAc,EAAE,OAAA,CAAA,oBAAA,CAAqB,CAFJ;AAGjC,EAAA,eAAe,EAAE,OAAA,CAAA,oBAAA,CAAqB,MAHL;AAIjC,EAAA,aAAa,EAAE,OAAA,CAAA,oBAAA,CAAqB;AAJH,CAAtB;AAOA,OAAA,CAAA,wBAAA,GAA2B;AACtC,EAAA,gBAAgB,EAAE,aAAA,CAAA,MAAA,CAAO,kBADa;AAEtC,EAAA,cAAc,EAAE,aAAA,CAAA,MAAA,CAAO,kBAFe;AAGtC,EAAA,eAAe,EAAE,aAAA,CAAA,MAAA,CAAO,gBAHc;AAItC,EAAA,aAAa,EAAE,aAAA,CAAA,MAAA,CAAO;AAJgB,CAA3B","sourcesContent":["// TODO: Constants prefixed with pending should be replaced with design tokens\n// These values were taken from the design token superset figma\n\nimport { tokens } from '@fluentui/react-theme';\n\nexport const pendingContentSizeTokens = {\n // Only body sizes are defined here currently\n body1: {\n fontSize: tokens.fontSizeBase300,\n fontWeight: tokens.fontWeightRegular,\n lineHeight: tokens.lineHeightBase300,\n },\n body1Strong: {\n fontSize: tokens.fontSizeBase300,\n fontWeight: tokens.fontWeightSemibold,\n lineHeight: tokens.lineHeightBase300,\n },\n};\n\nexport const pendingSpacingTokens = {\n none: '0',\n xxs: '2px',\n xs: '4px',\n sNudge: '6px',\n s: '8px',\n mNudge: '10px',\n m: '12px',\n l: '16px',\n xl: '20px',\n xxl: '24px',\n xxxl: '32px',\n};\n\nexport const pendingAnimationDurationTokens = {\n ultraFast: '50ms',\n faster: '100ms',\n fast: '150ms',\n normal: '200ms',\n slow: '300ms',\n slower: '400ms',\n ultraSlow: '500ms',\n};\n\nexport const pendingAnimationEasingTokens = {\n accelerateMax: 'cubic-bezier(1,0,1,1)',\n accelerateMid: 'cubic-bezier(0.7,0,1,0.5)',\n accelerateMin: 'cubic-bezier(0.8,0,1,1)',\n declerateMax: 'cubic-bezier(0,0,0,1)',\n decelerateMid: 'cubic-bezier(0.1,0.9,0.2,1)',\n decelarateMin: 'cubic-bezier(0.33,0,0.1,1)',\n maxEasyEase: 'cubic-bezier(0.8,0,0.1,1)',\n easyEase: 'cubic-bezier(0.33,0,0.67,1)',\n linear: 'cubic-bezier(0,0,1,1)',\n};\n\n/**\n * Provides shared values between tab style hooks\n * useTabStyles\n * useTabAnimatedIndicator\n */\nexport const tabIndicatorPadding = {\n mediumHorizontal: pendingSpacingTokens.m,\n mediumVertical: pendingSpacingTokens.s,\n smallHorizontal: pendingSpacingTokens.sNudge,\n smallVertical: pendingSpacingTokens.xs,\n};\n\nexport const tabIndicatorStrokeWidths = {\n mediumHorizontal: tokens.strokeWidthThicker,\n mediumVertical: tokens.strokeWidthThicker,\n smallHorizontal: tokens.strokeWidthThick,\n smallVertical: tokens.strokeWidthThicker,\n};\n"],"sourceRoot":"../src/"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluentui/react-tabs",
|
|
3
|
-
"version": "9.0.0-beta.
|
|
3
|
+
"version": "9.0.0-beta.9",
|
|
4
4
|
"description": "Fluent UI React tabs components",
|
|
5
5
|
"main": "lib-commonjs/index.js",
|
|
6
6
|
"module": "lib/index.js",
|
|
@@ -27,25 +27,16 @@
|
|
|
27
27
|
"devDependencies": {
|
|
28
28
|
"@fluentui/eslint-plugin": "*",
|
|
29
29
|
"@fluentui/react-conformance": "*",
|
|
30
|
-
"@fluentui/react-conformance-griffel": "9.0.0-beta.
|
|
31
|
-
"@fluentui/react-context-selector": "9.0.0-rc.
|
|
32
|
-
"@fluentui/scripts": "^1.0.0"
|
|
33
|
-
"@types/enzyme": "3.10.3",
|
|
34
|
-
"@types/enzyme-adapter-react-16": "1.0.3",
|
|
35
|
-
"@types/react": "16.9.42",
|
|
36
|
-
"@types/react-dom": "16.9.10",
|
|
37
|
-
"@types/react-test-renderer": "^16.0.0",
|
|
38
|
-
"enzyme": "~3.10.0",
|
|
39
|
-
"enzyme-adapter-react-16": "^1.15.0",
|
|
40
|
-
"react": "16.8.6",
|
|
41
|
-
"react-dom": "16.8.6",
|
|
42
|
-
"react-test-renderer": "^16.3.0"
|
|
30
|
+
"@fluentui/react-conformance-griffel": "9.0.0-beta.4",
|
|
31
|
+
"@fluentui/react-context-selector": "9.0.0-rc.6",
|
|
32
|
+
"@fluentui/scripts": "^1.0.0"
|
|
43
33
|
},
|
|
44
34
|
"dependencies": {
|
|
45
|
-
"@griffel/react": "1.0.
|
|
46
|
-
"@fluentui/react-
|
|
47
|
-
"@fluentui/react-
|
|
48
|
-
"@fluentui/react-
|
|
35
|
+
"@griffel/react": "1.0.3",
|
|
36
|
+
"@fluentui/react-context-selector": "9.0.0-rc.6",
|
|
37
|
+
"@fluentui/react-tabster": "9.0.0-rc.6",
|
|
38
|
+
"@fluentui/react-theme": "9.0.0-rc.5",
|
|
39
|
+
"@fluentui/react-utilities": "9.0.0-rc.6",
|
|
49
40
|
"tslib": "^2.1.0"
|
|
50
41
|
},
|
|
51
42
|
"peerDependencies": {
|