@atlaskit/primitives 0.3.3 → 0.4.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 CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/primitives
2
2
 
3
+ ## 0.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`8e03331eb8b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8e03331eb8b) - Introduce 'as' prop to Inline and Stack so the resulting element can be controlled.
8
+
9
+ ## 0.4.0
10
+
11
+ ### Minor Changes
12
+
13
+ - [`003c381e37d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/003c381e37d) - Apply `width: 100%` to Inline and Stack when `grow` prop is set to `fill`.
14
+
3
15
  ## 0.3.3
4
16
 
5
17
  ### Patch Changes
@@ -14,16 +14,15 @@ var _excluded = ["as", "children", "color", "backgroundColor", "shadow", "border
14
14
  _excluded2 = ["style", "className"];
15
15
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
16
16
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
17
- // TODO: Fill in the component {description} and ensure links point to the correct {packageName} location.
18
- // Remove links that the component does not have (such as usage). If there are no links remove them all.
19
17
  /**
20
18
  * __Box__
21
19
  *
22
- * A box {description}.
20
+ * A Box is a primitive component that has the design decisions of the Atlassian Design System baked in.
21
+ * Renders a `div` by default.
23
22
  *
24
- * - [Examples](https://atlassian.design/components/{packageName}/examples)
25
- * - [Code](https://atlassian.design/components/{packageName}/code)
26
- * - [Usage](https://atlassian.design/components/{packageName}/usage)
23
+ * - [Examples](https://atlassian.design/components/primitives/box/examples)
24
+ * - [Code](https://atlassian.design/components/primitives/box/code)
25
+ * - [Usage](https://atlassian.design/components/primitives/box/usage)
27
26
  */
28
27
  var Box = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
29
28
  var as = _ref.as,
@@ -41,6 +41,7 @@ var flexGrowMap = {
41
41
  flexGrow: 0
42
42
  }),
43
43
  fill: (0, _react2.css)({
44
+ width: '100%',
44
45
  flexGrow: 1
45
46
  })
46
47
  };
@@ -183,7 +184,8 @@ var Separator = function Separator(_ref) {
183
184
  *
184
185
  */
185
186
  var Inline = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(function (_ref2, ref) {
186
- var alignInline = _ref2.alignInline,
187
+ var as = _ref2.as,
188
+ alignInline = _ref2.alignInline,
187
189
  alignItems = _ref2.alignBlock,
188
190
  _ref2$shouldWrap = _ref2.shouldWrap,
189
191
  shouldWrap = _ref2$shouldWrap === void 0 ? false : _ref2$shouldWrap,
@@ -194,6 +196,7 @@ var Inline = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(
194
196
  separator = _ref2.separator,
195
197
  testId = _ref2.testId,
196
198
  rawChildren = _ref2.children;
199
+ var Component = as || 'div';
197
200
  var separatorComponent = typeof separator === 'string' ? (0, _react2.jsx)(Separator, null, separator) : separator;
198
201
  var children = separatorComponent ? _react.Children.toArray(rawChildren).filter(Boolean).map(function (child, index) {
199
202
  return (0, _react2.jsx)(_react.Fragment, {
@@ -201,7 +204,7 @@ var Inline = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(
201
204
  }, separator && index > 0 ? separatorComponent : null, child);
202
205
  }) : rawChildren;
203
206
  var justifyContent = spread || alignInline;
204
- return (0, _react2.jsx)("div", {
207
+ return (0, _react2.jsx)(Component, {
205
208
  css: [baseStyles, space && spaceMap[space], justifyContent && justifyContentMap[justifyContent], grow && flexGrowMap[grow], alignItems && alignItemsMap[alignItems], shouldWrap && flexWrapStyles, rowSpace && rowSpaceMap[rowSpace]],
206
209
  "data-testid": testId,
207
210
  ref: ref
@@ -38,6 +38,7 @@ var flexGrowMap = {
38
38
  flexGrow: 0
39
39
  }),
40
40
  fill: (0, _react2.css)({
41
+ width: '100%',
41
42
  flexGrow: 1
42
43
  })
43
44
  };
@@ -119,15 +120,17 @@ var baseStyles = (0, _react2.css)({
119
120
  *
120
121
  */
121
122
  var Stack = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
122
- var alignItems = _ref.alignInline,
123
+ var as = _ref.as,
124
+ alignItems = _ref.alignInline,
123
125
  alignBlock = _ref.alignBlock,
124
126
  spread = _ref.spread,
125
127
  grow = _ref.grow,
126
128
  space = _ref.space,
127
129
  children = _ref.children,
128
130
  testId = _ref.testId;
131
+ var Component = as || 'div';
129
132
  var justifyContent = spread || alignBlock;
130
- return (0, _react2.jsx)("div", {
133
+ return (0, _react2.jsx)(Component, {
131
134
  css: [baseStyles, space && spaceMap[space], alignItems && alignItemsMap[alignItems], grow && flexGrowMap[grow], justifyContent && justifyContentMap[justifyContent]],
132
135
  "data-testid": testId,
133
136
  ref: ref
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/primitives",
3
- "version": "0.3.3",
3
+ "version": "0.4.1",
4
4
  "sideEffects": false
5
5
  }
@@ -1,16 +1,15 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import React, { forwardRef } from 'react';
3
3
  import { BaseBox } from './internal/base-box.partial';
4
- // TODO: Fill in the component {description} and ensure links point to the correct {packageName} location.
5
- // Remove links that the component does not have (such as usage). If there are no links remove them all.
6
4
  /**
7
5
  * __Box__
8
6
  *
9
- * A box {description}.
7
+ * A Box is a primitive component that has the design decisions of the Atlassian Design System baked in.
8
+ * Renders a `div` by default.
10
9
  *
11
- * - [Examples](https://atlassian.design/components/{packageName}/examples)
12
- * - [Code](https://atlassian.design/components/{packageName}/code)
13
- * - [Usage](https://atlassian.design/components/{packageName}/usage)
10
+ * - [Examples](https://atlassian.design/components/primitives/box/examples)
11
+ * - [Code](https://atlassian.design/components/primitives/box/code)
12
+ * - [Usage](https://atlassian.design/components/primitives/box/usage)
14
13
  */
15
14
  const Box = /*#__PURE__*/forwardRef(({
16
15
  as,
@@ -34,6 +34,7 @@ const flexGrowMap = {
34
34
  flexGrow: 0
35
35
  }),
36
36
  fill: css({
37
+ width: '100%',
37
38
  flexGrow: 1
38
39
  })
39
40
  };
@@ -175,6 +176,7 @@ const Separator = ({
175
176
  *
176
177
  */
177
178
  const Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
179
+ as,
178
180
  alignInline,
179
181
  alignBlock: alignItems,
180
182
  shouldWrap = false,
@@ -186,6 +188,7 @@ const Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
186
188
  testId,
187
189
  children: rawChildren
188
190
  }, ref) => {
191
+ const Component = as || 'div';
189
192
  const separatorComponent = typeof separator === 'string' ? jsx(Separator, null, separator) : separator;
190
193
  const children = separatorComponent ? Children.toArray(rawChildren).filter(Boolean).map((child, index) => {
191
194
  return jsx(Fragment, {
@@ -193,7 +196,7 @@ const Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
193
196
  }, separator && index > 0 ? separatorComponent : null, child);
194
197
  }) : rawChildren;
195
198
  const justifyContent = spread || alignInline;
196
- return jsx("div", {
199
+ return jsx(Component, {
197
200
  css: [baseStyles, space && spaceMap[space], justifyContent && justifyContentMap[justifyContent], grow && flexGrowMap[grow], alignItems && alignItemsMap[alignItems], shouldWrap && flexWrapStyles, rowSpace && rowSpaceMap[rowSpace]],
198
201
  "data-testid": testId,
199
202
  ref: ref
@@ -31,6 +31,7 @@ const flexGrowMap = {
31
31
  flexGrow: 0
32
32
  }),
33
33
  fill: css({
34
+ width: '100%',
34
35
  flexGrow: 1
35
36
  })
36
37
  };
@@ -112,6 +113,7 @@ const baseStyles = css({
112
113
  *
113
114
  */
114
115
  const Stack = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
116
+ as,
115
117
  alignInline: alignItems,
116
118
  alignBlock,
117
119
  spread,
@@ -120,8 +122,9 @@ const Stack = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(({
120
122
  children,
121
123
  testId
122
124
  }, ref) => {
125
+ const Component = as || 'div';
123
126
  const justifyContent = spread || alignBlock;
124
- return jsx("div", {
127
+ return jsx(Component, {
125
128
  css: [baseStyles, space && spaceMap[space], alignItems && alignItemsMap[alignItems], grow && flexGrowMap[grow], justifyContent && justifyContentMap[justifyContent]],
126
129
  "data-testid": testId,
127
130
  ref: ref
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/primitives",
3
- "version": "0.3.3",
3
+ "version": "0.4.1",
4
4
  "sideEffects": false
5
5
  }
@@ -4,16 +4,15 @@ var _excluded = ["as", "children", "color", "backgroundColor", "shadow", "border
4
4
  _excluded2 = ["style", "className"];
5
5
  import React, { forwardRef } from 'react';
6
6
  import { BaseBox } from './internal/base-box.partial';
7
- // TODO: Fill in the component {description} and ensure links point to the correct {packageName} location.
8
- // Remove links that the component does not have (such as usage). If there are no links remove them all.
9
7
  /**
10
8
  * __Box__
11
9
  *
12
- * A box {description}.
10
+ * A Box is a primitive component that has the design decisions of the Atlassian Design System baked in.
11
+ * Renders a `div` by default.
13
12
  *
14
- * - [Examples](https://atlassian.design/components/{packageName}/examples)
15
- * - [Code](https://atlassian.design/components/{packageName}/code)
16
- * - [Usage](https://atlassian.design/components/{packageName}/usage)
13
+ * - [Examples](https://atlassian.design/components/primitives/box/examples)
14
+ * - [Code](https://atlassian.design/components/primitives/box/code)
15
+ * - [Usage](https://atlassian.design/components/primitives/box/usage)
17
16
  */
18
17
  var Box = /*#__PURE__*/forwardRef(function (_ref, ref) {
19
18
  var as = _ref.as,
@@ -34,6 +34,7 @@ var flexGrowMap = {
34
34
  flexGrow: 0
35
35
  }),
36
36
  fill: css({
37
+ width: '100%',
37
38
  flexGrow: 1
38
39
  })
39
40
  };
@@ -176,7 +177,8 @@ var Separator = function Separator(_ref) {
176
177
  *
177
178
  */
178
179
  var Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function (_ref2, ref) {
179
- var alignInline = _ref2.alignInline,
180
+ var as = _ref2.as,
181
+ alignInline = _ref2.alignInline,
180
182
  alignItems = _ref2.alignBlock,
181
183
  _ref2$shouldWrap = _ref2.shouldWrap,
182
184
  shouldWrap = _ref2$shouldWrap === void 0 ? false : _ref2$shouldWrap,
@@ -187,6 +189,7 @@ var Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function (_ref2, ref) {
187
189
  separator = _ref2.separator,
188
190
  testId = _ref2.testId,
189
191
  rawChildren = _ref2.children;
192
+ var Component = as || 'div';
190
193
  var separatorComponent = typeof separator === 'string' ? jsx(Separator, null, separator) : separator;
191
194
  var children = separatorComponent ? Children.toArray(rawChildren).filter(Boolean).map(function (child, index) {
192
195
  return jsx(Fragment, {
@@ -194,7 +197,7 @@ var Inline = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function (_ref2, ref) {
194
197
  }, separator && index > 0 ? separatorComponent : null, child);
195
198
  }) : rawChildren;
196
199
  var justifyContent = spread || alignInline;
197
- return jsx("div", {
200
+ return jsx(Component, {
198
201
  css: [baseStyles, space && spaceMap[space], justifyContent && justifyContentMap[justifyContent], grow && flexGrowMap[grow], alignItems && alignItemsMap[alignItems], shouldWrap && flexWrapStyles, rowSpace && rowSpaceMap[rowSpace]],
199
202
  "data-testid": testId,
200
203
  ref: ref
@@ -31,6 +31,7 @@ var flexGrowMap = {
31
31
  flexGrow: 0
32
32
  }),
33
33
  fill: css({
34
+ width: '100%',
34
35
  flexGrow: 1
35
36
  })
36
37
  };
@@ -112,15 +113,17 @@ var baseStyles = css({
112
113
  *
113
114
  */
114
115
  var Stack = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function (_ref, ref) {
115
- var alignItems = _ref.alignInline,
116
+ var as = _ref.as,
117
+ alignItems = _ref.alignInline,
116
118
  alignBlock = _ref.alignBlock,
117
119
  spread = _ref.spread,
118
120
  grow = _ref.grow,
119
121
  space = _ref.space,
120
122
  children = _ref.children,
121
123
  testId = _ref.testId;
124
+ var Component = as || 'div';
122
125
  var justifyContent = spread || alignBlock;
123
- return jsx("div", {
126
+ return jsx(Component, {
124
127
  css: [baseStyles, space && spaceMap[space], alignItems && alignItemsMap[alignItems], grow && flexGrowMap[grow], justifyContent && justifyContentMap[justifyContent]],
125
128
  "data-testid": testId,
126
129
  ref: ref
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/primitives",
3
- "version": "0.3.3",
3
+ "version": "0.4.1",
4
4
  "sideEffects": false
5
5
  }
@@ -7,11 +7,12 @@ declare type BoxComponent<T extends ElementType = 'div'> = (<T extends ElementTy
7
7
  /**
8
8
  * __Box__
9
9
  *
10
- * A box {description}.
10
+ * A Box is a primitive component that has the design decisions of the Atlassian Design System baked in.
11
+ * Renders a `div` by default.
11
12
  *
12
- * - [Examples](https://atlassian.design/components/{packageName}/examples)
13
- * - [Code](https://atlassian.design/components/{packageName}/code)
14
- * - [Usage](https://atlassian.design/components/{packageName}/usage)
13
+ * - [Examples](https://atlassian.design/components/primitives/box/examples)
14
+ * - [Code](https://atlassian.design/components/primitives/box/code)
15
+ * - [Usage](https://atlassian.design/components/primitives/box/usage)
15
16
  */
16
17
  declare const Box: BoxComponent;
17
18
  export default Box;
@@ -1,6 +1,10 @@
1
1
  /** @jsx jsx */
2
- import { ReactNode } from 'react';
3
- export interface InlineProps {
2
+ import { ComponentPropsWithRef, ElementType, ReactNode } from 'react';
3
+ export interface InlineProps<T extends ElementType = 'div'> {
4
+ /**
5
+ * The DOM element to render as the Inline. Defaults to `div`.
6
+ */
7
+ as?: 'div' | 'span' | 'ul' | 'ol';
4
8
  /**
5
9
  * Used to align children along the main axis.
6
10
  */
@@ -42,6 +46,7 @@ export interface InlineProps {
42
46
  * Elements to be rendered inside the Stack.
43
47
  */
44
48
  children: ReactNode;
49
+ ref?: ComponentPropsWithRef<T>['ref'];
45
50
  }
46
51
  export declare type AlignInline = 'start' | 'center' | 'end';
47
52
  export declare type AlignBlock = 'start' | 'center' | 'end' | 'baseline';
@@ -104,5 +109,5 @@ export declare type RowSpace = keyof typeof rowSpaceMap;
104
109
  * ```
105
110
  *
106
111
  */
107
- declare const Inline: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<InlineProps & import("react").RefAttributes<HTMLDivElement>>>;
112
+ declare const Inline: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Pick<InlineProps<ElementType<any>>, "space" | "separator" | "as" | "children" | "testId" | "alignInline" | "alignBlock" | "shouldWrap" | "spread" | "grow" | "rowSpace"> & import("react").RefAttributes<any>>>;
108
113
  export default Inline;
@@ -8,7 +8,7 @@ declare type BaseBoxPropsFoundation<T extends ElementType> = {
8
8
  /**
9
9
  * The DOM element to render as the Box. Defaults to `div`.
10
10
  */
11
- as?: 'div' | 'span';
11
+ as?: 'div' | 'span' | 'li';
12
12
  /**
13
13
  * The HTML className attribute.
14
14
  *
@@ -1,6 +1,10 @@
1
1
  /** @jsx jsx */
2
- import { ReactNode } from 'react';
3
- export interface StackProps {
2
+ import { ComponentPropsWithRef, ElementType, ReactNode } from 'react';
3
+ export interface StackProps<T extends ElementType = 'div'> {
4
+ /**
5
+ * The DOM element to render as the Stack. Defaults to `div`.
6
+ */
7
+ as?: 'div' | 'span' | 'ul' | 'ol';
4
8
  /**
5
9
  * Used to align children along the main axis.
6
10
  */
@@ -29,6 +33,7 @@ export interface StackProps {
29
33
  * Elements to be rendered inside the Stack.
30
34
  */
31
35
  children: ReactNode;
36
+ ref?: ComponentPropsWithRef<T>['ref'];
32
37
  }
33
38
  export declare type AlignInline = 'start' | 'center' | 'end';
34
39
  export declare type AlignBlock = 'start' | 'center' | 'end';
@@ -73,5 +78,5 @@ export declare type Space = keyof typeof spaceMap;
73
78
  * ```
74
79
  *
75
80
  */
76
- declare const Stack: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<StackProps & import("react").RefAttributes<HTMLDivElement>>>;
81
+ declare const Stack: import("react").MemoExoticComponent<import("react").ForwardRefExoticComponent<Pick<StackProps<ElementType<any>>, "space" | "as" | "children" | "testId" | "alignInline" | "alignBlock" | "spread" | "grow"> & import("react").RefAttributes<any>>>;
77
82
  export default Stack;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/primitives",
3
- "version": "0.3.3",
3
+ "version": "0.4.1",
4
4
  "description": "Primitives are token-backed low-level building blocks.",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
package/report.api.md CHANGED
@@ -130,7 +130,7 @@ type BaseBoxProps<T extends ElementType = 'div'> = Omit<
130
130
 
131
131
  // @public (undocumented)
132
132
  type BaseBoxPropsFoundation<T extends ElementType> = {
133
- as?: 'div' | 'span';
133
+ as?: 'div' | 'li' | 'span';
134
134
  className?: string;
135
135
  children?: ReactNode;
136
136
  color?: TextColor;
@@ -356,15 +356,34 @@ const heightMap: {
356
356
 
357
357
  // @public
358
358
  export const Inline: MemoExoticComponent<
359
- ForwardRefExoticComponent<InlineProps & RefAttributes<HTMLDivElement>>
359
+ ForwardRefExoticComponent<
360
+ Pick<
361
+ InlineProps<ElementType<any>>,
362
+ | 'alignBlock'
363
+ | 'alignInline'
364
+ | 'as'
365
+ | 'children'
366
+ | 'grow'
367
+ | 'rowSpace'
368
+ | 'separator'
369
+ | 'shouldWrap'
370
+ | 'space'
371
+ | 'spread'
372
+ | 'testId'
373
+ > &
374
+ RefAttributes<any>
375
+ >
360
376
  >;
361
377
 
362
378
  // @public (undocumented)
363
- export interface InlineProps {
379
+ export interface InlineProps<T extends ElementType = 'div'> {
364
380
  alignBlock?: AlignBlock;
365
381
  alignInline?: AlignInline;
382
+ as?: 'div' | 'ol' | 'span' | 'ul';
366
383
  children: ReactNode;
367
384
  grow?: Grow;
385
+ // (undocumented)
386
+ ref?: ComponentPropsWithRef<T>['ref'];
368
387
  rowSpace?: RowSpace;
369
388
  separator?: string;
370
389
  shouldWrap?: boolean;
@@ -566,15 +585,31 @@ type Spread_2 = 'space-between';
566
585
 
567
586
  // @public
568
587
  export const Stack: MemoExoticComponent<
569
- ForwardRefExoticComponent<StackProps & RefAttributes<HTMLDivElement>>
588
+ ForwardRefExoticComponent<
589
+ Pick<
590
+ StackProps<ElementType<any>>,
591
+ | 'alignBlock'
592
+ | 'alignInline'
593
+ | 'as'
594
+ | 'children'
595
+ | 'grow'
596
+ | 'space'
597
+ | 'spread'
598
+ | 'testId'
599
+ > &
600
+ RefAttributes<any>
601
+ >
570
602
  >;
571
603
 
572
604
  // @public (undocumented)
573
- export interface StackProps {
605
+ export interface StackProps<T extends ElementType = 'div'> {
574
606
  alignBlock?: AlignBlock_2;
575
607
  alignInline?: AlignInline_2;
608
+ as?: 'div' | 'ol' | 'span' | 'ul';
576
609
  children: ReactNode;
577
610
  grow?: Grow_2;
611
+ // (undocumented)
612
+ ref?: ComponentPropsWithRef<T>['ref'];
578
613
  space?: Space_2;
579
614
  spread?: Spread_2;
580
615
  testId?: string;
@@ -114,7 +114,7 @@ type BaseBoxProps<T extends ElementType = 'div'> = Omit<ComponentPropsWithoutRef
114
114
 
115
115
  // @public (undocumented)
116
116
  type BaseBoxPropsFoundation<T extends ElementType> = {
117
- as?: 'div' | 'span';
117
+ as?: 'div' | 'li' | 'span';
118
118
  className?: string;
119
119
  children?: ReactNode;
120
120
  color?: TextColor;
@@ -293,14 +293,17 @@ const heightMap: {
293
293
  };
294
294
 
295
295
  // @public
296
- export const Inline: MemoExoticComponent<ForwardRefExoticComponent<InlineProps & RefAttributes<HTMLDivElement>>>;
296
+ export const Inline: MemoExoticComponent<ForwardRefExoticComponent<Pick<InlineProps<ElementType<any>>, "alignBlock" | "alignInline" | "as" | "children" | "grow" | "rowSpace" | "separator" | "shouldWrap" | "space" | "spread" | "testId"> & RefAttributes<any>>>;
297
297
 
298
298
  // @public (undocumented)
299
- export interface InlineProps {
299
+ export interface InlineProps<T extends ElementType = 'div'> {
300
300
  alignBlock?: AlignBlock;
301
301
  alignInline?: AlignInline;
302
+ as?: 'div' | 'ol' | 'span' | 'ul';
302
303
  children: ReactNode;
303
304
  grow?: Grow;
305
+ // (undocumented)
306
+ ref?: ComponentPropsWithRef<T>['ref'];
304
307
  rowSpace?: RowSpace;
305
308
  separator?: string;
306
309
  shouldWrap?: boolean;
@@ -501,14 +504,17 @@ type Spread = 'space-between';
501
504
  type Spread_2 = 'space-between';
502
505
 
503
506
  // @public
504
- export const Stack: MemoExoticComponent<ForwardRefExoticComponent<StackProps & RefAttributes<HTMLDivElement>>>;
507
+ export const Stack: MemoExoticComponent<ForwardRefExoticComponent<Pick<StackProps<ElementType<any>>, "alignBlock" | "alignInline" | "as" | "children" | "grow" | "space" | "spread" | "testId"> & RefAttributes<any>>>;
505
508
 
506
509
  // @public (undocumented)
507
- export interface StackProps {
510
+ export interface StackProps<T extends ElementType = 'div'> {
508
511
  alignBlock?: AlignBlock_2;
509
512
  alignInline?: AlignInline_2;
513
+ as?: 'div' | 'ol' | 'span' | 'ul';
510
514
  children: ReactNode;
511
515
  grow?: Grow_2;
516
+ // (undocumented)
517
+ ref?: ComponentPropsWithRef<T>['ref'];
512
518
  space?: Space_2;
513
519
  spread?: Spread_2;
514
520
  testId?: string;