@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.
Files changed (50) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/lib/Stack.d.ts +7 -13
  3. package/lib/Stack.js +44 -44
  4. package/lib/Stack.settings.d.ts +1 -1
  5. package/lib/Stack.settings.js +51 -51
  6. package/lib/Stack.tokens.d.ts +3 -3
  7. package/lib/Stack.tokens.js +71 -70
  8. package/lib/Stack.types.d.ts +80 -79
  9. package/lib/Stack.types.js +1 -1
  10. package/lib/StackItem/StackItem.d.ts +1 -1
  11. package/lib/StackItem/StackItem.js +5 -5
  12. package/lib/StackItem/StackItem.settings.d.ts +1 -1
  13. package/lib/StackItem/StackItem.settings.js +8 -8
  14. package/lib/StackItem/StackItem.tokens.d.ts +2 -6
  15. package/lib/StackItem/StackItem.tokens.js +13 -13
  16. package/lib/StackItem/StackItem.types.d.ts +43 -43
  17. package/lib/StackItem/StackItem.types.js +1 -1
  18. package/lib/StackUtils.d.ts +4 -7
  19. package/lib/StackUtils.js +35 -33
  20. package/lib/StackUtils.test.win32.d.ts +1 -1
  21. package/lib/StackUtils.test.win32.js +50 -50
  22. package/lib/__tests__/Stack.test.d.ts +1 -1
  23. package/lib/__tests__/Stack.test.js +9 -14
  24. package/lib/index.d.ts +1 -1
  25. package/lib/index.js +1 -1
  26. package/lib-commonjs/Stack.d.ts +7 -13
  27. package/lib-commonjs/Stack.js +88 -107
  28. package/lib-commonjs/Stack.settings.d.ts +1 -1
  29. package/lib-commonjs/Stack.settings.js +54 -54
  30. package/lib-commonjs/Stack.tokens.d.ts +3 -3
  31. package/lib-commonjs/Stack.tokens.js +75 -74
  32. package/lib-commonjs/Stack.types.d.ts +80 -79
  33. package/lib-commonjs/Stack.types.js +3 -3
  34. package/lib-commonjs/StackItem/StackItem.d.ts +1 -1
  35. package/lib-commonjs/StackItem/StackItem.js +13 -13
  36. package/lib-commonjs/StackItem/StackItem.settings.d.ts +1 -1
  37. package/lib-commonjs/StackItem/StackItem.settings.js +11 -11
  38. package/lib-commonjs/StackItem/StackItem.tokens.d.ts +2 -6
  39. package/lib-commonjs/StackItem/StackItem.tokens.js +16 -16
  40. package/lib-commonjs/StackItem/StackItem.types.d.ts +43 -43
  41. package/lib-commonjs/StackItem/StackItem.types.js +3 -3
  42. package/lib-commonjs/StackUtils.d.ts +4 -7
  43. package/lib-commonjs/StackUtils.js +37 -35
  44. package/lib-commonjs/StackUtils.test.win32.d.ts +1 -1
  45. package/lib-commonjs/StackUtils.test.win32.js +53 -71
  46. package/lib-commonjs/__tests__/Stack.test.d.ts +1 -1
  47. package/lib-commonjs/__tests__/Stack.test.js +44 -70
  48. package/lib-commonjs/index.d.ts +1 -1
  49. package/lib-commonjs/index.js +11 -31
  50. package/package.json +22 -21
package/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # Change Log - @fluentui-react-native/stack
2
2
 
3
+ ## 0.11.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 0d6e9c1: chore: migrate to `oxfmt`
8
+ - ac6e7af: Ensure packages have a default export that references the typescript entrypoint and clean up build dependency ordering
9
+ - Updated dependencies [0d6e9c1]
10
+ - Updated dependencies [ac6e7af]
11
+ - @uifabricshared/foundation-composable@0.14.1
12
+ - @uifabricshared/foundation-settings@0.16.1
13
+ - @uifabricshared/foundation-compose@1.16.1
14
+ - @uifabricshared/foundation-tokens@0.16.1
15
+ - @fluentui-react-native/framework@0.15.1
16
+ - @fluentui-react-native/adapters@0.14.1
17
+ - @fluentui-react-native/tokens@0.24.1
18
+
3
19
  ## 0.11.0
4
20
 
5
21
  ### Minor Changes
package/lib/Stack.d.ts CHANGED
@@ -1,21 +1,15 @@
1
1
  import type { IStackProps, IStackSlotProps } from './Stack.types';
2
2
  declare global {
3
- namespace NodeJS {
4
- interface Global {
5
- __jsiExecutorDescription: any;
3
+ namespace NodeJS {
4
+ interface Global {
5
+ __jsiExecutorDescription: any;
6
+ }
6
7
  }
7
- }
8
8
  }
9
- export declare const Stack: import('@uifabricshared/foundation-compose').IComposeReturnType<
10
- IStackProps,
11
- IStackSlotProps,
12
- import('./Stack.types').IStackTokens,
13
- {
9
+ export declare const Stack: import("@uifabricshared/foundation-compose").IComposeReturnType<IStackProps, IStackSlotProps, import("./Stack.types").IStackTokens, {
14
10
  gap: number;
15
11
  horizontal: boolean;
16
12
  wrap: boolean;
17
- },
18
- import('./Stack.types').IStackStatics
19
- >;
13
+ }, import("./Stack.types").IStackStatics>;
20
14
  export default Stack;
21
- //# sourceMappingURL=Stack.d.ts.map
15
+ //# sourceMappingURL=Stack.d.ts.map
package/lib/Stack.js CHANGED
@@ -1,4 +1,4 @@
1
- import { jsx as _jsx } from '@fluentui-react-native/framework-base/jsx-runtime';
1
+ import { jsx as _jsx } from "@fluentui-react-native/framework-base/jsx-runtime";
2
2
  /** @jsxImportSource @fluentui-react-native/framework-base */
3
3
  import * as React from 'react';
4
4
  import { View } from 'react-native';
@@ -11,54 +11,54 @@ import { buildStackRootStyles, buildStackInnerStyles } from './Stack.tokens';
11
11
  import { stackName } from './Stack.types';
12
12
  import StackItem from './StackItem/StackItem';
13
13
  function _mixinStyle(style, mixin) {
14
- return style ? [style, mixin] : mixin;
14
+ return style ? [style, mixin] : mixin;
15
15
  }
16
16
  const _styleKey = 'style';
17
17
  const render = (Slots, renderData, ...children) => {
18
- const { gap, horizontal, wrap } = renderData.state;
19
- if (gap && gap > 0 && children && globalThis.__jsiExecutorDescription !== 'ChakraRuntime') {
20
- const extraStyle = horizontal ? { marginLeft: gap } : { marginTop: gap };
21
- // eslint-disable-next-line @typescript-eslint/ban-ts-comment
22
- // @ts-ignore - TODO, fix typing error
23
- children = React.Children.map(children, (child, index) => {
24
- if (React.isValidElement(child) && index > 0) {
25
- const childProps = child.props;
26
- const extraProps = { style: _mixinStyle(childProps[_styleKey], extraStyle) };
27
- return React.cloneElement(child, {
28
- ...childProps,
29
- ...extraProps,
18
+ const { gap, horizontal, wrap } = renderData.state;
19
+ if (gap && gap > 0 && children && globalThis.__jsiExecutorDescription !== 'ChakraRuntime') {
20
+ const extraStyle = horizontal ? { marginLeft: gap } : { marginTop: gap };
21
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
22
+ // @ts-ignore - TODO, fix typing error
23
+ children = React.Children.map(children, (child, index) => {
24
+ if (React.isValidElement(child) && index > 0) {
25
+ const childProps = child.props;
26
+ const extraProps = { style: _mixinStyle(childProps[_styleKey], extraStyle) };
27
+ return React.cloneElement(child, {
28
+ ...childProps,
29
+ ...extraProps,
30
+ });
31
+ }
32
+ return child;
30
33
  });
31
- }
32
- return child;
33
- });
34
- }
35
- if (wrap) {
36
- return _jsx(Slots.root, { children: _jsx(Slots.inner, { children: children }) });
37
- }
38
- return _jsx(Slots.root, { children: children });
34
+ }
35
+ if (wrap) {
36
+ return (_jsx(Slots.root, { children: _jsx(Slots.inner, { children: children }) }));
37
+ }
38
+ return _jsx(Slots.root, { children: children });
39
39
  };
40
40
  export const Stack = compose({
41
- displayName: stackName,
42
- settings,
43
- statics: {
44
- Item: StackItem,
45
- },
46
- usePrepareProps: (props, useStyling) => {
47
- const { gap, horizontal, wrap, ...rest } = props;
48
- return {
49
- slotProps: mergeSettings(useStyling(props), { root: rest }),
50
- state: { gap, horizontal, wrap },
51
- };
52
- },
53
- render: render,
54
- slots: {
55
- root: { slotType: View, filter: filterViewProps },
56
- inner: { slotType: View, filter: filterViewProps },
57
- },
58
- styles: {
59
- root: [buildStackRootStyles, backgroundColorTokens, borderTokens],
60
- inner: [buildStackInnerStyles],
61
- },
41
+ displayName: stackName,
42
+ settings,
43
+ statics: {
44
+ Item: StackItem,
45
+ },
46
+ usePrepareProps: (props, useStyling) => {
47
+ const { gap, horizontal, wrap, ...rest } = props;
48
+ return {
49
+ slotProps: mergeSettings(useStyling(props), { root: rest }),
50
+ state: { gap, horizontal, wrap },
51
+ };
52
+ },
53
+ render: render,
54
+ slots: {
55
+ root: { slotType: View, filter: filterViewProps },
56
+ inner: { slotType: View, filter: filterViewProps },
57
+ },
58
+ styles: {
59
+ root: [buildStackRootStyles, backgroundColorTokens, borderTokens],
60
+ inner: [buildStackInnerStyles],
61
+ },
62
62
  });
63
63
  export default Stack;
64
- //# sourceMappingURL=Stack.js.map
64
+ //# 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,60 +1,60 @@
1
1
  import { stackName } from './Stack.types';
2
2
  export const settings = [
3
- {
4
- root: {
5
- style: {
6
- display: 'flex',
7
- },
8
- },
9
- inner: {
10
- style: {
11
- display: 'flex',
12
- flexWrap: 'wrap',
13
- overflow: 'visible',
14
- },
15
- },
16
- _overrides: {
17
- horizontal: {
3
+ {
18
4
  root: {
19
- style: {
20
- flexDirection: 'row',
21
- },
22
- },
23
- _overrides: {
24
- reversed: {
25
- root: {
26
- style: {
27
- flexDirection: 'column-reverse',
28
- },
5
+ style: {
6
+ display: 'flex',
29
7
  },
30
- },
31
8
  },
32
- },
33
- reversed: {
34
- root: {
35
- style: {
36
- flexDirection: 'row-reverse',
37
- },
38
- },
39
- },
40
- verticalFill: {
41
- root: {
42
- style: {
43
- height: '100%',
44
- },
9
+ inner: {
10
+ style: {
11
+ display: 'flex',
12
+ flexWrap: 'wrap',
13
+ overflow: 'visible',
14
+ },
45
15
  },
46
- },
47
- wrap: {
48
- root: {
49
- style: {
50
- flexWrap: 'wrap',
51
- height: '100%',
52
- overflow: 'visible',
53
- },
16
+ _overrides: {
17
+ horizontal: {
18
+ root: {
19
+ style: {
20
+ flexDirection: 'row',
21
+ },
22
+ },
23
+ _overrides: {
24
+ reversed: {
25
+ root: {
26
+ style: {
27
+ flexDirection: 'column-reverse',
28
+ },
29
+ },
30
+ },
31
+ },
32
+ },
33
+ reversed: {
34
+ root: {
35
+ style: {
36
+ flexDirection: 'row-reverse',
37
+ },
38
+ },
39
+ },
40
+ verticalFill: {
41
+ root: {
42
+ style: {
43
+ height: '100%',
44
+ },
45
+ },
46
+ },
47
+ wrap: {
48
+ root: {
49
+ style: {
50
+ flexWrap: 'wrap',
51
+ height: '100%',
52
+ overflow: 'visible',
53
+ },
54
+ },
55
+ },
54
56
  },
55
- },
56
57
  },
57
- },
58
- stackName,
58
+ stackName,
59
59
  ];
60
- //# sourceMappingURL=Stack.settings.js.map
60
+ //# 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('@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
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,87 +1,88 @@
1
1
  import { styleFunction } from '@uifabricshared/foundation-tokens';
2
2
  import { parseGap, parsePadding } from './StackUtils';
3
3
  const nameMap = {
4
- start: 'flex-start',
5
- end: 'flex-end',
4
+ start: 'flex-start',
5
+ end: 'flex-end',
6
6
  };
7
7
  function _mapAlignment(horizontal, horizontalAlign, verticalAlign, style) {
8
- const alignValue = horizontal ? verticalAlign : horizontalAlign;
9
- if (alignValue) {
10
- style.alignItems = nameMap[alignValue] || alignValue;
11
- }
12
- const justifyValue = horizontal ? horizontalAlign : verticalAlign;
13
- if (justifyValue) {
14
- style.justifyContent = nameMap[justifyValue] || justifyValue;
15
- }
8
+ const alignValue = horizontal ? verticalAlign : horizontalAlign;
9
+ if (alignValue) {
10
+ style.alignItems = (nameMap[alignValue] || alignValue);
11
+ }
12
+ const justifyValue = horizontal ? horizontalAlign : verticalAlign;
13
+ if (justifyValue) {
14
+ style.justifyContent = (nameMap[justifyValue] || justifyValue);
15
+ }
16
16
  }
17
17
  const _innerKeyProps = [
18
- 'horizontal',
19
- // 'reversed',
20
- 'gap',
21
- 'horizontalAlign',
22
- 'verticalAlign',
23
- // 'disableShrink',
24
- 'childrenGap',
25
- 'padding',
18
+ 'horizontal',
19
+ // 'reversed',
20
+ 'gap',
21
+ 'horizontalAlign',
22
+ 'verticalAlign',
23
+ // 'disableShrink',
24
+ 'childrenGap',
25
+ 'padding',
26
26
  ];
27
27
  function _buildInnerStyles(tokenProps, theme) {
28
- const { horizontal, wrap, horizontalAlign, verticalAlign, padding } = tokenProps;
29
- let innerStyle = undefined;
30
- const childrenGap = tokenProps.childrenGap || tokenProps.gap;
31
- const { rowGap, columnGap } = parseGap(childrenGap, theme);
32
- if (wrap) {
33
- innerStyle = {
34
- rowGap: rowGap,
35
- columnGap: columnGap,
36
- padding: parsePadding(padding, theme),
37
- width: '100%',
38
- };
39
- _mapAlignment(!!horizontal, horizontalAlign, verticalAlign, innerStyle);
40
- if (horizontal) {
41
- innerStyle.height = '100%';
42
- } else {
43
- innerStyle.maxHeight = '100%';
44
- innerStyle.height = '100%';
28
+ const { horizontal, wrap, horizontalAlign, verticalAlign, padding } = tokenProps;
29
+ let innerStyle = undefined;
30
+ const childrenGap = tokenProps.childrenGap || tokenProps.gap;
31
+ const { rowGap, columnGap } = parseGap(childrenGap, theme);
32
+ if (wrap) {
33
+ innerStyle = {
34
+ rowGap: rowGap,
35
+ columnGap: columnGap,
36
+ padding: parsePadding(padding, theme),
37
+ width: '100%',
38
+ };
39
+ _mapAlignment(!!horizontal, horizontalAlign, verticalAlign, innerStyle);
40
+ if (horizontal) {
41
+ innerStyle.height = '100%';
42
+ }
43
+ else {
44
+ innerStyle.maxHeight = '100%';
45
+ innerStyle.height = '100%';
46
+ }
45
47
  }
46
- }
47
- return { style: innerStyle };
48
+ return { style: innerStyle };
48
49
  }
49
50
  export const buildStackInnerStyles = styleFunction(_buildInnerStyles, _innerKeyProps);
50
51
  function _buildRootStyles(tokenProps, theme) {
51
- const { grow, horizontal, horizontalAlign, verticalAlign, maxHeight, maxWidth, padding, wrap } = tokenProps;
52
- // const childrenGap = tokenProps.childrenGap || tokenProps.gap;
53
- // const { rowGap, columnGap } = parseGap(childrenGap, theme);
54
- const rootStyle = {
55
- maxHeight,
56
- maxWidth,
57
- };
58
- _mapAlignment(!!horizontal, horizontalAlign, verticalAlign, rootStyle);
59
- if (grow && !wrap) {
60
- rootStyle.flexGrow = typeof grow === 'boolean' ? (grow ? 1 : 0) : grow;
61
- rootStyle.overflow = 'hidden';
62
- }
63
- if (!wrap) {
64
- rootStyle.padding = parsePadding(padding, theme);
65
- }
66
- return { style: rootStyle };
67
- // verticalFill,
68
- // reversed,
69
- // disableShrink,
52
+ const { grow, horizontal, horizontalAlign, verticalAlign, maxHeight, maxWidth, padding, wrap } = tokenProps;
53
+ // const childrenGap = tokenProps.childrenGap || tokenProps.gap;
54
+ // const { rowGap, columnGap } = parseGap(childrenGap, theme);
55
+ const rootStyle = {
56
+ maxHeight,
57
+ maxWidth,
58
+ };
59
+ _mapAlignment(!!horizontal, horizontalAlign, verticalAlign, rootStyle);
60
+ if (grow && !wrap) {
61
+ rootStyle.flexGrow = typeof grow === 'boolean' ? (grow ? 1 : 0) : grow;
62
+ rootStyle.overflow = 'hidden';
63
+ }
64
+ if (!wrap) {
65
+ rootStyle.padding = parsePadding(padding, theme);
66
+ }
67
+ return { style: rootStyle };
68
+ // verticalFill,
69
+ // reversed,
70
+ // disableShrink,
70
71
  }
71
72
  const _keyProps = [
72
- // 'verticalFill',
73
- 'horizontal',
74
- // 'reversed',
75
- // 'gap',
76
- 'grow',
77
- 'wrap',
78
- 'horizontalAlign',
79
- 'verticalAlign',
80
- // 'disableShrink',
81
- // 'childrenGap',
82
- 'maxHeight',
83
- 'maxWidth',
84
- 'padding',
73
+ // 'verticalFill',
74
+ 'horizontal',
75
+ // 'reversed',
76
+ // 'gap',
77
+ 'grow',
78
+ 'wrap',
79
+ 'horizontalAlign',
80
+ 'verticalAlign',
81
+ // 'disableShrink',
82
+ // 'childrenGap',
83
+ 'maxHeight',
84
+ 'maxWidth',
85
+ 'padding',
85
86
  ];
86
87
  export const buildStackRootStyles = styleFunction(_buildRootStyles, _keyProps);
87
- //# sourceMappingURL=Stack.tokens.js.map
88
+ //# sourceMappingURL=Stack.tokens.js.map
@@ -3,14 +3,14 @@ import type { Spacing } from '@fluentui-react-native/framework';
3
3
  import type { IBackgroundColorTokens, IBorderTokens, FontTokens } from '@fluentui-react-native/tokens';
4
4
  import type { IRenderData } from '@uifabricshared/foundation-composable';
5
5
  import type { IStackItemProps } from './StackItem/StackItem.types';
6
- export declare const stackName = 'RNFStack';
6
+ export declare const stackName = "RNFStack";
7
7
  /**
8
8
  * Defines a type made by the union of the different values that the align-items and justify-content flexbox
9
9
  * properties can take.
10
10
  */
11
11
  export type Alignment = ViewStyle['justifyContent'] | 'start' | 'end';
12
12
  export interface IStackStatics {
13
- Item: React.FunctionComponent<IStackItemProps>;
13
+ Item: React.FunctionComponent<IStackItemProps>;
14
14
  }
15
15
  type SpacingGapValue = `${number}px` | `${number}` | keyof Spacing;
16
16
  /**
@@ -18,90 +18,91 @@ type SpacingGapValue = `${number}px` | `${number}` | keyof Spacing;
18
18
  * the right approach
19
19
  */
20
20
  export interface IStackTokens extends FontTokens, IBackgroundColorTokens, IBorderTokens {
21
- /**
22
- * Defines the spacing between Stack children.
23
- * The property is specified as a value for 'row gap', followed optionally by a value for 'column gap'.
24
- * If 'column gap' is omitted, it's set to the same value as 'row gap'.
25
- */
26
- childrenGap?: number | SpacingGapValue | `${SpacingGapValue} ${SpacingGapValue}`;
27
- /**
28
- * Defines a maximum height for the Stack.
29
- */
30
- maxHeight?: DimensionValue;
31
- /**
32
- * Defines a maximum width for the Stack.
33
- */
34
- maxWidth?: DimensionValue;
35
- /**
36
- * Defines the padding to be applied to the Stack contents relative to its border.
37
- */
38
- padding?: number | `${number}px` | keyof Spacing;
39
- /**
40
- * Defines whether to render Stack children horizontally.
41
- * @defaultvalue false
42
- */
43
- horizontal?: boolean;
44
- /**
45
- * Defines whether to render Stack children in the opposite direction (bottom-to-top if it's a vertical Stack and
46
- * right-to-left if it's a horizontal Stack).
47
- * @defaultvalue false
48
- */
49
- reversed?: boolean;
50
- /**
51
- * Defines how to align Stack children horizontally (along the x-axis).
52
- */
53
- horizontalAlign?: Alignment;
54
- /**
55
- * Defines how to align Stack children vertically (along the y-axis).
56
- */
57
- verticalAlign?: Alignment;
58
- /**
59
- * Defines whether the Stack should take up 100% of the height of its parent.
60
- * This property is required to be set to true when using the `grow` flag on children in vertical oriented Stacks.
61
- * Stacks are rendered as block elements and grow horizontally to the container already.
62
- * @defaultvalue false
63
- */
64
- verticalFill?: boolean;
65
- /**
66
- * Defines whether Stack children should not shrink to fit the available space.
67
- * @defaultvalue false
68
- */
69
- disableShrink?: boolean;
70
- /**
71
- * Defines how much to grow the Stack in proportion to its siblings.
72
- */
73
- grow?: boolean | number;
74
- /**
75
- * Defines whether Stack children should wrap onto multiple rows or columns when they are about to overflow
76
- * the size of the Stack.
77
- * @defaultvalue false
78
- */
79
- wrap?: boolean;
80
- /**
81
- * Gap between items, multiplied by theme gap spacing
82
- * Does not work while running Chakra for reasons specific to that engine (refer to https://github.com/microsoft/fluentui-react-native/issues/767)
83
- */
84
- gap?: number;
21
+ /**
22
+ * Defines the spacing between Stack children.
23
+ * The property is specified as a value for 'row gap', followed optionally by a value for 'column gap'.
24
+ * If 'column gap' is omitted, it's set to the same value as 'row gap'.
25
+ */
26
+ childrenGap?: number | SpacingGapValue | `${SpacingGapValue} ${SpacingGapValue}`;
27
+ /**
28
+ * Defines a maximum height for the Stack.
29
+ */
30
+ maxHeight?: DimensionValue;
31
+ /**
32
+ * Defines a maximum width for the Stack.
33
+ */
34
+ maxWidth?: DimensionValue;
35
+ /**
36
+ * Defines the padding to be applied to the Stack contents relative to its border.
37
+ */
38
+ padding?: number | `${number}px` | keyof Spacing;
39
+ /**
40
+ * Defines whether to render Stack children horizontally.
41
+ * @defaultvalue false
42
+ */
43
+ horizontal?: boolean;
44
+ /**
45
+ * Defines whether to render Stack children in the opposite direction (bottom-to-top if it's a vertical Stack and
46
+ * right-to-left if it's a horizontal Stack).
47
+ * @defaultvalue false
48
+ */
49
+ reversed?: boolean;
50
+ /**
51
+ * Defines how to align Stack children horizontally (along the x-axis).
52
+ */
53
+ horizontalAlign?: Alignment;
54
+ /**
55
+ * Defines how to align Stack children vertically (along the y-axis).
56
+ */
57
+ verticalAlign?: Alignment;
58
+ /**
59
+ * Defines whether the Stack should take up 100% of the height of its parent.
60
+ * This property is required to be set to true when using the `grow` flag on children in vertical oriented Stacks.
61
+ * Stacks are rendered as block elements and grow horizontally to the container already.
62
+ * @defaultvalue false
63
+ */
64
+ verticalFill?: boolean;
65
+ /**
66
+ * Defines whether Stack children should not shrink to fit the available space.
67
+ * @defaultvalue false
68
+ */
69
+ disableShrink?: boolean;
70
+ /**
71
+ * Defines how much to grow the Stack in proportion to its siblings.
72
+ */
73
+ grow?: boolean | number;
74
+ /**
75
+ * Defines whether Stack children should wrap onto multiple rows or columns when they are about to overflow
76
+ * the size of the Stack.
77
+ * @defaultvalue false
78
+ */
79
+ wrap?: boolean;
80
+ /**
81
+ * Gap between items, multiplied by theme gap spacing
82
+ * Does not work while running Chakra for reasons specific to that engine (refer to https://github.com/microsoft/fluentui-react-native/issues/767)
83
+ */
84
+ gap?: number;
85
85
  }
86
86
  /**
87
87
  * Base property definitions, these generally match fabric
88
88
  */
89
- export interface IStackProps extends IStackTokens, ViewProps {}
89
+ export interface IStackProps extends IStackTokens, ViewProps {
90
+ }
90
91
  export type IStackSlotProps = {
91
- root: ViewProps;
92
- inner: ViewProps;
92
+ root: ViewProps;
93
+ inner: ViewProps;
93
94
  };
94
95
  export interface IStackType {
95
- props: IStackProps;
96
- tokens: IStackTokens;
97
- slotProps: IStackSlotProps;
98
- statics: IStackStatics;
99
- state: {
100
- gap: IStackProps['gap'];
101
- horizontal: IStackProps['horizontal'];
102
- wrap: IStackProps['wrap'];
103
- };
96
+ props: IStackProps;
97
+ tokens: IStackTokens;
98
+ slotProps: IStackSlotProps;
99
+ statics: IStackStatics;
100
+ state: {
101
+ gap: IStackProps['gap'];
102
+ horizontal: IStackProps['horizontal'];
103
+ wrap: IStackProps['wrap'];
104
+ };
104
105
  }
105
106
  export type IStackRenderData = IRenderData<IStackSlotProps, IStackType['state']>;
106
107
  export {};
107
- //# sourceMappingURL=Stack.types.d.ts.map
108
+ //# sourceMappingURL=Stack.types.d.ts.map
@@ -1,2 +1,2 @@
1
1
  export const stackName = 'RNFStack';
2
- //# sourceMappingURL=Stack.types.js.map
2
+ //# sourceMappingURL=Stack.types.js.map
@@ -2,4 +2,4 @@ import type * as React from 'react';
2
2
  import type { IStackItemProps } from './StackItem.types';
3
3
  export declare const StackItem: React.FunctionComponent<IStackItemProps>;
4
4
  export default StackItem;
5
- //# sourceMappingURL=StackItem.d.ts.map
5
+ //# sourceMappingURL=StackItem.d.ts.map
@@ -5,10 +5,10 @@ import { settings } from './StackItem.settings';
5
5
  import { stackItemTokenProcessor } from './StackItem.tokens';
6
6
  import { stackItemName } from './StackItem.types';
7
7
  export const StackItem = compose({
8
- displayName: stackItemName,
9
- settings: settings,
10
- slots: { root: { slotType: View, filter: filterViewProps } },
11
- styles: { root: [stackItemTokenProcessor] },
8
+ displayName: stackItemName,
9
+ settings: settings,
10
+ slots: { root: { slotType: View, filter: filterViewProps } },
11
+ styles: { root: [stackItemTokenProcessor] },
12
12
  });
13
13
  export default StackItem;
14
- //# sourceMappingURL=StackItem.js.map
14
+ //# sourceMappingURL=StackItem.js.map