@fluentui-react-native/stack 0.11.0 → 0.11.1
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 +16 -0
- package/lib/Stack.d.ts +7 -13
- package/lib/Stack.js +44 -44
- package/lib/Stack.settings.d.ts +1 -1
- package/lib/Stack.settings.js +51 -51
- package/lib/Stack.tokens.d.ts +3 -3
- package/lib/Stack.tokens.js +71 -70
- package/lib/Stack.types.d.ts +80 -79
- package/lib/Stack.types.js +1 -1
- package/lib/StackItem/StackItem.d.ts +1 -1
- package/lib/StackItem/StackItem.js +5 -5
- package/lib/StackItem/StackItem.settings.d.ts +1 -1
- package/lib/StackItem/StackItem.settings.js +8 -8
- package/lib/StackItem/StackItem.tokens.d.ts +2 -6
- package/lib/StackItem/StackItem.tokens.js +13 -13
- package/lib/StackItem/StackItem.types.d.ts +43 -43
- package/lib/StackItem/StackItem.types.js +1 -1
- package/lib/StackUtils.d.ts +4 -7
- package/lib/StackUtils.js +35 -33
- package/lib/StackUtils.test.win32.d.ts +1 -1
- package/lib/StackUtils.test.win32.js +50 -50
- package/lib/__tests__/Stack.test.d.ts +1 -1
- package/lib/__tests__/Stack.test.js +9 -14
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib-commonjs/Stack.d.ts +7 -13
- package/lib-commonjs/Stack.js +88 -107
- package/lib-commonjs/Stack.settings.d.ts +1 -1
- package/lib-commonjs/Stack.settings.js +54 -54
- package/lib-commonjs/Stack.tokens.d.ts +3 -3
- package/lib-commonjs/Stack.tokens.js +75 -74
- package/lib-commonjs/Stack.types.d.ts +80 -79
- package/lib-commonjs/Stack.types.js +3 -3
- package/lib-commonjs/StackItem/StackItem.d.ts +1 -1
- package/lib-commonjs/StackItem/StackItem.js +13 -13
- package/lib-commonjs/StackItem/StackItem.settings.d.ts +1 -1
- package/lib-commonjs/StackItem/StackItem.settings.js +11 -11
- package/lib-commonjs/StackItem/StackItem.tokens.d.ts +2 -6
- package/lib-commonjs/StackItem/StackItem.tokens.js +16 -16
- package/lib-commonjs/StackItem/StackItem.types.d.ts +43 -43
- package/lib-commonjs/StackItem/StackItem.types.js +3 -3
- package/lib-commonjs/StackUtils.d.ts +4 -7
- package/lib-commonjs/StackUtils.js +37 -35
- package/lib-commonjs/StackUtils.test.win32.d.ts +1 -1
- package/lib-commonjs/StackUtils.test.win32.js +53 -71
- package/lib-commonjs/__tests__/Stack.test.d.ts +1 -1
- package/lib-commonjs/__tests__/Stack.test.js +44 -70
- package/lib-commonjs/index.d.ts +1 -1
- package/lib-commonjs/index.js +11 -31
- package/package.json +22 -21
package/lib-commonjs/Stack.js
CHANGED
|
@@ -1,122 +1,103 @@
|
|
|
1
|
-
|
|
2
|
-
var __createBinding =
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
var
|
|
23
|
-
|
|
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;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
41
24
|
};
|
|
42
|
-
|
|
25
|
+
return ownKeys(o);
|
|
43
26
|
};
|
|
44
27
|
return function (mod) {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
50
33
|
};
|
|
51
|
-
|
|
52
|
-
var __importDefault =
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
};
|
|
57
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
34
|
+
})();
|
|
35
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
+
};
|
|
38
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
58
39
|
exports.Stack = void 0;
|
|
59
|
-
const jsx_runtime_1 = require(
|
|
40
|
+
const jsx_runtime_1 = require("@fluentui-react-native/framework-base/jsx-runtime");
|
|
60
41
|
/** @jsxImportSource @fluentui-react-native/framework-base */
|
|
61
|
-
const React = __importStar(require(
|
|
62
|
-
const react_native_1 = require(
|
|
63
|
-
const adapters_1 = require(
|
|
64
|
-
const tokens_1 = require(
|
|
65
|
-
const foundation_compose_1 = require(
|
|
66
|
-
const foundation_settings_1 = require(
|
|
67
|
-
const Stack_settings_1 = require(
|
|
68
|
-
const Stack_tokens_1 = require(
|
|
69
|
-
const Stack_types_1 = require(
|
|
70
|
-
const StackItem_1 = __importDefault(require(
|
|
42
|
+
const React = __importStar(require("react"));
|
|
43
|
+
const react_native_1 = require("react-native");
|
|
44
|
+
const adapters_1 = require("@fluentui-react-native/adapters");
|
|
45
|
+
const tokens_1 = require("@fluentui-react-native/tokens");
|
|
46
|
+
const foundation_compose_1 = require("@uifabricshared/foundation-compose");
|
|
47
|
+
const foundation_settings_1 = require("@uifabricshared/foundation-settings");
|
|
48
|
+
const Stack_settings_1 = require("./Stack.settings");
|
|
49
|
+
const Stack_tokens_1 = require("./Stack.tokens");
|
|
50
|
+
const Stack_types_1 = require("./Stack.types");
|
|
51
|
+
const StackItem_1 = __importDefault(require("./StackItem/StackItem"));
|
|
71
52
|
function _mixinStyle(style, mixin) {
|
|
72
|
-
|
|
53
|
+
return style ? [style, mixin] : mixin;
|
|
73
54
|
}
|
|
74
55
|
const _styleKey = 'style';
|
|
75
56
|
const render = (Slots, renderData, ...children) => {
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
57
|
+
const { gap, horizontal, wrap } = renderData.state;
|
|
58
|
+
if (gap && gap > 0 && children && globalThis.__jsiExecutorDescription !== 'ChakraRuntime') {
|
|
59
|
+
const extraStyle = horizontal ? { marginLeft: gap } : { marginTop: gap };
|
|
60
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
61
|
+
// @ts-ignore - TODO, fix typing error
|
|
62
|
+
children = React.Children.map(children, (child, index) => {
|
|
63
|
+
if (React.isValidElement(child) && index > 0) {
|
|
64
|
+
const childProps = child.props;
|
|
65
|
+
const extraProps = { style: _mixinStyle(childProps[_styleKey], extraStyle) };
|
|
66
|
+
return React.cloneElement(child, {
|
|
67
|
+
...childProps,
|
|
68
|
+
...extraProps,
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
return child;
|
|
88
72
|
});
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
return jsx_runtime_1.jsx(Slots.root, { children: jsx_runtime_1.jsx(Slots.inner, { children: children }) });
|
|
95
|
-
}
|
|
96
|
-
return jsx_runtime_1.jsx(Slots.root, { children: children });
|
|
73
|
+
}
|
|
74
|
+
if (wrap) {
|
|
75
|
+
return (jsx_runtime_1.jsx(Slots.root, { children: jsx_runtime_1.jsx(Slots.inner, { children: children }) }));
|
|
76
|
+
}
|
|
77
|
+
return jsx_runtime_1.jsx(Slots.root, { children: children });
|
|
97
78
|
};
|
|
98
79
|
exports.Stack = (0, foundation_compose_1.compose)({
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
80
|
+
displayName: Stack_types_1.stackName,
|
|
81
|
+
settings: Stack_settings_1.settings,
|
|
82
|
+
statics: {
|
|
83
|
+
Item: StackItem_1.default,
|
|
84
|
+
},
|
|
85
|
+
usePrepareProps: (props, useStyling) => {
|
|
86
|
+
const { gap, horizontal, wrap, ...rest } = props;
|
|
87
|
+
return {
|
|
88
|
+
slotProps: (0, foundation_settings_1.mergeSettings)(useStyling(props), { root: rest }),
|
|
89
|
+
state: { gap, horizontal, wrap },
|
|
90
|
+
};
|
|
91
|
+
},
|
|
92
|
+
render: render,
|
|
93
|
+
slots: {
|
|
94
|
+
root: { slotType: react_native_1.View, filter: adapters_1.filterViewProps },
|
|
95
|
+
inner: { slotType: react_native_1.View, filter: adapters_1.filterViewProps },
|
|
96
|
+
},
|
|
97
|
+
styles: {
|
|
98
|
+
root: [Stack_tokens_1.buildStackRootStyles, tokens_1.backgroundColorTokens, tokens_1.borderTokens],
|
|
99
|
+
inner: [Stack_tokens_1.buildStackInnerStyles],
|
|
100
|
+
},
|
|
120
101
|
});
|
|
121
102
|
exports.default = exports.Stack;
|
|
122
|
-
//# sourceMappingURL=Stack.js.map
|
|
103
|
+
//# sourceMappingURL=Stack.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { IComposeSettings } from '@uifabricshared/foundation-compose';
|
|
2
2
|
import type { IStackType } from './Stack.types';
|
|
3
3
|
export declare const settings: IComposeSettings<IStackType>;
|
|
4
|
-
//# sourceMappingURL=Stack.settings.d.ts.map
|
|
4
|
+
//# sourceMappingURL=Stack.settings.d.ts.map
|
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.settings = void 0;
|
|
4
|
-
const Stack_types_1 = require(
|
|
4
|
+
const Stack_types_1 = require("./Stack.types");
|
|
5
5
|
exports.settings = [
|
|
6
|
-
|
|
7
|
-
root: {
|
|
8
|
-
style: {
|
|
9
|
-
display: 'flex',
|
|
10
|
-
},
|
|
11
|
-
},
|
|
12
|
-
inner: {
|
|
13
|
-
style: {
|
|
14
|
-
display: 'flex',
|
|
15
|
-
flexWrap: 'wrap',
|
|
16
|
-
overflow: 'visible',
|
|
17
|
-
},
|
|
18
|
-
},
|
|
19
|
-
_overrides: {
|
|
20
|
-
horizontal: {
|
|
6
|
+
{
|
|
21
7
|
root: {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
_overrides: {
|
|
27
|
-
reversed: {
|
|
28
|
-
root: {
|
|
29
|
-
style: {
|
|
30
|
-
flexDirection: 'column-reverse',
|
|
31
|
-
},
|
|
8
|
+
style: {
|
|
9
|
+
display: 'flex',
|
|
32
10
|
},
|
|
33
|
-
},
|
|
34
11
|
},
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
},
|
|
42
|
-
},
|
|
43
|
-
verticalFill: {
|
|
44
|
-
root: {
|
|
45
|
-
style: {
|
|
46
|
-
height: '100%',
|
|
47
|
-
},
|
|
12
|
+
inner: {
|
|
13
|
+
style: {
|
|
14
|
+
display: 'flex',
|
|
15
|
+
flexWrap: 'wrap',
|
|
16
|
+
overflow: 'visible',
|
|
17
|
+
},
|
|
48
18
|
},
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
19
|
+
_overrides: {
|
|
20
|
+
horizontal: {
|
|
21
|
+
root: {
|
|
22
|
+
style: {
|
|
23
|
+
flexDirection: 'row',
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
_overrides: {
|
|
27
|
+
reversed: {
|
|
28
|
+
root: {
|
|
29
|
+
style: {
|
|
30
|
+
flexDirection: 'column-reverse',
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
},
|
|
36
|
+
reversed: {
|
|
37
|
+
root: {
|
|
38
|
+
style: {
|
|
39
|
+
flexDirection: 'row-reverse',
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
},
|
|
43
|
+
verticalFill: {
|
|
44
|
+
root: {
|
|
45
|
+
style: {
|
|
46
|
+
height: '100%',
|
|
47
|
+
},
|
|
48
|
+
},
|
|
49
|
+
},
|
|
50
|
+
wrap: {
|
|
51
|
+
root: {
|
|
52
|
+
style: {
|
|
53
|
+
flexWrap: 'wrap',
|
|
54
|
+
height: '100%',
|
|
55
|
+
overflow: 'visible',
|
|
56
|
+
},
|
|
57
|
+
},
|
|
58
|
+
},
|
|
57
59
|
},
|
|
58
|
-
},
|
|
59
60
|
},
|
|
60
|
-
|
|
61
|
-
Stack_types_1.stackName,
|
|
61
|
+
Stack_types_1.stackName,
|
|
62
62
|
];
|
|
63
|
-
//# sourceMappingURL=Stack.settings.js.map
|
|
63
|
+
//# sourceMappingURL=Stack.settings.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ViewProps } from 'react-native';
|
|
2
2
|
import type { Theme } from '@fluentui-react-native/framework';
|
|
3
3
|
import type { IStackTokens } from './Stack.types';
|
|
4
|
-
export declare const buildStackInnerStyles: import(
|
|
5
|
-
export declare const buildStackRootStyles: import(
|
|
6
|
-
//# sourceMappingURL=Stack.tokens.d.ts.map
|
|
4
|
+
export declare const buildStackInnerStyles: import("@fluentui-react-native/tokens").StyleFactoryFunction<ViewProps, IStackTokens, Theme>;
|
|
5
|
+
export declare const buildStackRootStyles: import("@fluentui-react-native/tokens").StyleFactoryFunction<ViewProps, IStackTokens, Theme>;
|
|
6
|
+
//# sourceMappingURL=Stack.tokens.d.ts.map
|
|
@@ -1,90 +1,91 @@
|
|
|
1
|
-
|
|
2
|
-
Object.defineProperty(exports,
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.buildStackRootStyles = exports.buildStackInnerStyles = void 0;
|
|
4
|
-
const foundation_tokens_1 = require(
|
|
5
|
-
const StackUtils_1 = require(
|
|
4
|
+
const foundation_tokens_1 = require("@uifabricshared/foundation-tokens");
|
|
5
|
+
const StackUtils_1 = require("./StackUtils");
|
|
6
6
|
const nameMap = {
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
start: 'flex-start',
|
|
8
|
+
end: 'flex-end',
|
|
9
9
|
};
|
|
10
10
|
function _mapAlignment(horizontal, horizontalAlign, verticalAlign, style) {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
11
|
+
const alignValue = horizontal ? verticalAlign : horizontalAlign;
|
|
12
|
+
if (alignValue) {
|
|
13
|
+
style.alignItems = (nameMap[alignValue] || alignValue);
|
|
14
|
+
}
|
|
15
|
+
const justifyValue = horizontal ? horizontalAlign : verticalAlign;
|
|
16
|
+
if (justifyValue) {
|
|
17
|
+
style.justifyContent = (nameMap[justifyValue] || justifyValue);
|
|
18
|
+
}
|
|
19
19
|
}
|
|
20
20
|
const _innerKeyProps = [
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
21
|
+
'horizontal',
|
|
22
|
+
// 'reversed',
|
|
23
|
+
'gap',
|
|
24
|
+
'horizontalAlign',
|
|
25
|
+
'verticalAlign',
|
|
26
|
+
// 'disableShrink',
|
|
27
|
+
'childrenGap',
|
|
28
|
+
'padding',
|
|
29
29
|
];
|
|
30
30
|
function _buildInnerStyles(tokenProps, theme) {
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
31
|
+
const { horizontal, wrap, horizontalAlign, verticalAlign, padding } = tokenProps;
|
|
32
|
+
let innerStyle = undefined;
|
|
33
|
+
const childrenGap = tokenProps.childrenGap || tokenProps.gap;
|
|
34
|
+
const { rowGap, columnGap } = (0, StackUtils_1.parseGap)(childrenGap, theme);
|
|
35
|
+
if (wrap) {
|
|
36
|
+
innerStyle = {
|
|
37
|
+
rowGap: rowGap,
|
|
38
|
+
columnGap: columnGap,
|
|
39
|
+
padding: (0, StackUtils_1.parsePadding)(padding, theme),
|
|
40
|
+
width: '100%',
|
|
41
|
+
};
|
|
42
|
+
_mapAlignment(!!horizontal, horizontalAlign, verticalAlign, innerStyle);
|
|
43
|
+
if (horizontal) {
|
|
44
|
+
innerStyle.height = '100%';
|
|
45
|
+
}
|
|
46
|
+
else {
|
|
47
|
+
innerStyle.maxHeight = '100%';
|
|
48
|
+
innerStyle.height = '100%';
|
|
49
|
+
}
|
|
48
50
|
}
|
|
49
|
-
|
|
50
|
-
return { style: innerStyle };
|
|
51
|
+
return { style: innerStyle };
|
|
51
52
|
}
|
|
52
53
|
exports.buildStackInnerStyles = (0, foundation_tokens_1.styleFunction)(_buildInnerStyles, _innerKeyProps);
|
|
53
54
|
function _buildRootStyles(tokenProps, theme) {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
55
|
+
const { grow, horizontal, horizontalAlign, verticalAlign, maxHeight, maxWidth, padding, wrap } = tokenProps;
|
|
56
|
+
// const childrenGap = tokenProps.childrenGap || tokenProps.gap;
|
|
57
|
+
// const { rowGap, columnGap } = parseGap(childrenGap, theme);
|
|
58
|
+
const rootStyle = {
|
|
59
|
+
maxHeight,
|
|
60
|
+
maxWidth,
|
|
61
|
+
};
|
|
62
|
+
_mapAlignment(!!horizontal, horizontalAlign, verticalAlign, rootStyle);
|
|
63
|
+
if (grow && !wrap) {
|
|
64
|
+
rootStyle.flexGrow = typeof grow === 'boolean' ? (grow ? 1 : 0) : grow;
|
|
65
|
+
rootStyle.overflow = 'hidden';
|
|
66
|
+
}
|
|
67
|
+
if (!wrap) {
|
|
68
|
+
rootStyle.padding = (0, StackUtils_1.parsePadding)(padding, theme);
|
|
69
|
+
}
|
|
70
|
+
return { style: rootStyle };
|
|
71
|
+
// verticalFill,
|
|
72
|
+
// reversed,
|
|
73
|
+
// disableShrink,
|
|
73
74
|
}
|
|
74
75
|
const _keyProps = [
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
76
|
+
// 'verticalFill',
|
|
77
|
+
'horizontal',
|
|
78
|
+
// 'reversed',
|
|
79
|
+
// 'gap',
|
|
80
|
+
'grow',
|
|
81
|
+
'wrap',
|
|
82
|
+
'horizontalAlign',
|
|
83
|
+
'verticalAlign',
|
|
84
|
+
// 'disableShrink',
|
|
85
|
+
// 'childrenGap',
|
|
86
|
+
'maxHeight',
|
|
87
|
+
'maxWidth',
|
|
88
|
+
'padding',
|
|
88
89
|
];
|
|
89
90
|
exports.buildStackRootStyles = (0, foundation_tokens_1.styleFunction)(_buildRootStyles, _keyProps);
|
|
90
|
-
//# sourceMappingURL=Stack.tokens.js.map
|
|
91
|
+
//# sourceMappingURL=Stack.tokens.js.map
|