@atlaskit/forge-react-types 0.37.14 → 0.39.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.
Files changed (49) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/cjs/components/__generated__/BoxProps.codegen.js +2 -2
  3. package/dist/cjs/components/__generated__/PressableProps.codegen.js +183 -1
  4. package/dist/cjs/components/charts/BarChartProps.js +1 -5
  5. package/dist/cjs/components/charts/DonutChartProps.js +5 -0
  6. package/dist/cjs/components/charts/LineChartProps.js +1 -5
  7. package/dist/cjs/components/charts/PieChartProps.js +1 -5
  8. package/dist/es2019/components/__generated__/BoxProps.codegen.js +2 -2
  9. package/dist/es2019/components/__generated__/PressableProps.codegen.js +182 -0
  10. package/dist/es2019/components/charts/BarChartProps.js +0 -1
  11. package/dist/es2019/components/charts/DonutChartProps.js +1 -0
  12. package/dist/es2019/components/charts/LineChartProps.js +0 -1
  13. package/dist/es2019/components/charts/PieChartProps.js +0 -1
  14. package/dist/esm/components/__generated__/BoxProps.codegen.js +2 -2
  15. package/dist/esm/components/__generated__/PressableProps.codegen.js +182 -0
  16. package/dist/esm/components/charts/BarChartProps.js +0 -1
  17. package/dist/esm/components/charts/DonutChartProps.js +1 -0
  18. package/dist/esm/components/charts/LineChartProps.js +0 -1
  19. package/dist/esm/components/charts/PieChartProps.js +0 -1
  20. package/dist/types/components/__generated__/BoxProps.codegen.d.ts +3 -3
  21. package/dist/types/components/charts/BarChartProps.d.ts +0 -10
  22. package/dist/types/components/charts/DonutChartProps.d.ts +15 -0
  23. package/dist/types/components/charts/LineChartProps.d.ts +0 -7
  24. package/dist/types/components/charts/PieChartProps.d.ts +0 -14
  25. package/dist/types/components/charts/index.d.ts +1 -1
  26. package/dist/types/index.d.ts +1 -1
  27. package/dist/types-ts4.5/components/__generated__/BoxProps.codegen.d.ts +3 -3
  28. package/dist/types-ts4.5/components/charts/BarChartProps.d.ts +0 -10
  29. package/dist/types-ts4.5/components/charts/DonutChartProps.d.ts +15 -0
  30. package/dist/types-ts4.5/components/charts/LineChartProps.d.ts +0 -7
  31. package/dist/types-ts4.5/components/charts/PieChartProps.d.ts +0 -14
  32. package/dist/types-ts4.5/components/charts/index.d.ts +1 -1
  33. package/dist/types-ts4.5/index.d.ts +1 -1
  34. package/package.json +2 -2
  35. package/scripts/codegen/codeGenerator.ts +12 -3
  36. package/src/components/__generated__/BoxProps.codegen.tsx +3 -3
  37. package/src/components/__generated__/PressableProps.codegen.tsx +238 -63
  38. package/src/components/charts/BarChartProps.tsx +0 -11
  39. package/src/components/charts/DonutChartProps.tsx +17 -0
  40. package/src/components/charts/LineChartProps.tsx +0 -8
  41. package/src/components/charts/PieChartProps.tsx +0 -15
  42. package/src/components/charts/index.ts +1 -1
  43. package/src/index.ts +2 -2
  44. package/dist/cjs/components/charts/SingleValueChartProps.js +0 -1
  45. package/dist/es2019/components/charts/SingleValueChartProps.js +0 -0
  46. package/dist/esm/components/charts/SingleValueChartProps.js +0 -0
  47. package/dist/types/components/charts/SingleValueChartProps.d.ts +0 -33
  48. package/dist/types-ts4.5/components/charts/SingleValueChartProps.d.ts +0 -33
  49. package/src/components/charts/SingleValueChartProps.tsx +0 -34
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Extract component prop types from UIKit 2 components - BoxProps
5
5
  *
6
- * @codegen <<SignedSource::8ab6a67fa03d077a43a19a7e31c78146>>
6
+ * @codegen <<SignedSource::c3ad3413cf478b4f6da470a99c029688>>
7
7
  * @codegenCommand yarn workspace @atlaskit/forge-react-types codegen
8
- * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::898e2c561f956fd22d43ade8ef60ca57>>
8
+ * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::cd2255d6156809f22f110b9eb0936c9d>>
9
9
  */
10
10
  import React from 'react';
11
11
  import { Box as PlatformBox } from '@atlaskit/primitives';
@@ -2358,8 +2358,8 @@ declare const xcssValidator: (styleObj: SafeCSSObject<keyof CSSProperties, keyof
2358
2358
  at?: boolean | undefined;
2359
2359
  } | undefined;
2360
2360
  }>;
2361
- type PlatformBoxProps = React.ComponentProps<typeof PlatformBox>;
2362
2361
  type XCSSProp = ReturnType<typeof xcssValidator>;
2362
+ type PlatformBoxProps = React.ComponentProps<typeof PlatformBox>;
2363
2363
  export type BoxProps = Pick<PlatformBoxProps, 'children' | 'ref' | 'testId'> & {
2364
2364
  /**
2365
2365
  * A shorthand for `paddingBlock` and `paddingInline` together.
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type BarChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,10 +13,6 @@ export type BarChartProps = {
14
13
  * 2. An [array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/bar-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- /**
18
- * Boolean to display the chart border. Defaults to `false`.
19
- */
20
- showBorder?: boolean;
21
16
  /**
22
17
  * Accessor to define the x-axis values. This can be a numerical or string index.
23
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/bar-chart/#data).
@@ -39,11 +34,6 @@ export type BarChartProps = {
39
34
  * A string value that represents the subtitle of the chart. This appears below the title.
40
35
  */
41
36
  subtitle?: string;
42
- /**
43
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
44
- * This is utilized to render each bar with the specified colors, based on the color grouping given by colorAccessor.
45
- */
46
- colors?: ChartColorTokens[];
47
37
  };
48
38
  type StackChartProps = BarChartProps & {
49
39
  /**
@@ -0,0 +1,15 @@
1
+ import { type PieChartProps } from './PieChartProps';
2
+ export type DonutChartProps = PieChartProps & {
3
+ /**
4
+ * The radius of the inner circle of the donut chart in pixels. If this is not specified, the radius is responsive.
5
+ */
6
+ innerRadius?: number;
7
+ /**
8
+ * The radius of the outer circle of the donut chart in pixels. If this is not specified, the radius is responsive.
9
+ */
10
+ outerRadius?: number;
11
+ };
12
+ /**
13
+ * A visual representation of data proportions in a donut format.
14
+ */
15
+ export type TDonutChart<T> = (props: DonutChartProps) => T;
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type LineChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,7 +13,6 @@ export type LineChartProps = {
14
13
  * 2. An [array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/line-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- showBorder?: boolean;
18
16
  /**
19
17
  * Accessor to define the x-axis values. This can be a numerical or string index.
20
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/line-chart/#data).
@@ -36,11 +34,6 @@ export type LineChartProps = {
36
34
  * A string value that represents the subtitle of the chart. This appears below the title.
37
35
  */
38
36
  subtitle?: string;
39
- /**
40
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
41
- * This is utilized to render each line with the specified colors, based on the color grouping given by colorAccessor.
42
- */
43
- colors?: ChartColorTokens[];
44
37
  };
45
38
  /**
46
39
  * A visual representation of data showing trends.
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type PieChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,10 +13,6 @@ export type PieChartProps = {
14
13
  * 2. [Array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/pie-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- /**
18
- * Boolean to display the chart border. Defaults to `false`.
19
- */
20
- showBorder?: boolean;
21
16
  /**
22
17
  * Accessor to define the color grouping. This can be a numerical or string index.
23
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/pie-chart/#data).
@@ -39,19 +34,10 @@ export type PieChartProps = {
39
34
  * A string value that represents the subtitle of the chart. This appears below the title.
40
35
  */
41
36
  subtitle?: string;
42
- /**
43
- * Boolean to render the pie as the donut variation. Defaults to `false`.
44
- */
45
- isDonut?: boolean;
46
37
  /**
47
38
  * Boolean to display labels on top of each slice. Defaults to `false`.
48
39
  */
49
40
  showMarkLabels?: boolean;
50
- /**
51
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
52
- * This is utilized to render each slice with the specified colors, based on the color grouping given by colorAccessor.
53
- */
54
- colors?: ChartColorTokens[];
55
41
  };
56
42
  /**
57
43
  * A visual representation of data proportions in a circular format.
@@ -1,4 +1,4 @@
1
1
  export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, } from './BarChartProps';
2
2
  export type { LineChartProps, TLineChart } from './LineChartProps';
3
- export type { SingleValueChartProps, TSingleValueChart } from './SingleValueChartProps';
4
3
  export type { PieChartProps, TPieChart } from './PieChartProps';
4
+ export type { DonutChartProps, TDonutChart } from './DonutChartProps';
@@ -1,3 +1,3 @@
1
1
  export type { AdfRendererProps, BadgeProps, BleedProps, BoxProps, ButtonGroupProps, ButtonProps, CalendarProps, CheckboxProps, CheckboxGroupProps, CodeBlockProps, CodeProps, DatePickerProps, DynamicTableProps, EmptyStateProps, ErrorMessageProps, FlexProps, FormFooterProps, FormHeaderProps, FormProps, FormSectionProps, GridProps, HeadingProps, HelperMessageProps, IconProps, InlineProps, LabelProps, LinkButtonProps, ListProps, ListItemProps, LoadingButtonProps, LozengeProps, ModalBodyProps, ModalFooterProps, ModalHeaderProps, ModalProps, ModalTitleProps, ModalTransitionProps, ProgressBarProps, ProgressTrackerProps, RadioGroupProps, RadioProps, RangeProps, SectionMessageActionProps, SectionMessageProps, SelectProps, SpinnerProps, StackProps, TabListProps, TabPanelProps, TabProps, TabsProps, TagGroupProps, TagProps, TextProps, TextAreaProps, TextfieldProps, ToggleProps, TooltipProps, TimePickerProps, ValidMessageProps, PopupProps, InlineEditProps, TBadge, TBleed, TBox, TButtonGroup, TButton, TCalendar, TCheckbox, TCheckboxGroup, TCodeBlock, TCode, TDatePicker, TDynamicTable, TEmptyState, TErrorMessage, TFlex, TFormFooter, TFormHeader, TForm, TFormSection, TGrid, THeading, THelperMessage, TIcon, TInline, TInlineEdit, TLabel, TLinkButton, TList, TListItem, TLoadingButton, TLozenge, TModalBody, TModalFooter, TModalHeader, TModal, TModalTitle, TModalTransition, TProgressBar, TProgressTracker, TRadioGroup, TRadio, TRange, TSectionMessageAction, TSectionMessage, TSelect, TSpinner, TStack, TTabList, TTabPanel, TTab, TTabs, TTagGroup, TTag, TTextArea, TTextfield, TTimePicker, TToggle, TTooltip, TValidMessage, TPopup, TAdfRenderer, TText, } from './components/__generated__';
2
- export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, LineChartProps, SingleValueChartProps, PieChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, TLineChart, TSingleValueChart, TPieChart, } from './components/charts';
2
+ export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, LineChartProps, DonutChartProps, PieChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, TLineChart, TDonutChart, TPieChart, } from './components/charts';
3
3
  export type { ChartColorTokens } from './types';
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Extract component prop types from UIKit 2 components - BoxProps
5
5
  *
6
- * @codegen <<SignedSource::8ab6a67fa03d077a43a19a7e31c78146>>
6
+ * @codegen <<SignedSource::c3ad3413cf478b4f6da470a99c029688>>
7
7
  * @codegenCommand yarn workspace @atlaskit/forge-react-types codegen
8
- * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::898e2c561f956fd22d43ade8ef60ca57>>
8
+ * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::cd2255d6156809f22f110b9eb0936c9d>>
9
9
  */
10
10
  import React from 'react';
11
11
  import { Box as PlatformBox } from '@atlaskit/primitives';
@@ -2358,8 +2358,8 @@ declare const xcssValidator: (styleObj: SafeCSSObject<keyof CSSProperties, keyof
2358
2358
  at?: boolean | undefined;
2359
2359
  } | undefined;
2360
2360
  }>;
2361
- type PlatformBoxProps = React.ComponentProps<typeof PlatformBox>;
2362
2361
  type XCSSProp = ReturnType<typeof xcssValidator>;
2362
+ type PlatformBoxProps = React.ComponentProps<typeof PlatformBox>;
2363
2363
  export type BoxProps = Pick<PlatformBoxProps, 'children' | 'ref' | 'testId'> & {
2364
2364
  /**
2365
2365
  * A shorthand for `paddingBlock` and `paddingInline` together.
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type BarChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,10 +13,6 @@ export type BarChartProps = {
14
13
  * 2. An [array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/bar-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- /**
18
- * Boolean to display the chart border. Defaults to `false`.
19
- */
20
- showBorder?: boolean;
21
16
  /**
22
17
  * Accessor to define the x-axis values. This can be a numerical or string index.
23
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/bar-chart/#data).
@@ -39,11 +34,6 @@ export type BarChartProps = {
39
34
  * A string value that represents the subtitle of the chart. This appears below the title.
40
35
  */
41
36
  subtitle?: string;
42
- /**
43
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
44
- * This is utilized to render each bar with the specified colors, based on the color grouping given by colorAccessor.
45
- */
46
- colors?: ChartColorTokens[];
47
37
  };
48
38
  type StackChartProps = BarChartProps & {
49
39
  /**
@@ -0,0 +1,15 @@
1
+ import { type PieChartProps } from './PieChartProps';
2
+ export type DonutChartProps = PieChartProps & {
3
+ /**
4
+ * The radius of the inner circle of the donut chart in pixels. If this is not specified, the radius is responsive.
5
+ */
6
+ innerRadius?: number;
7
+ /**
8
+ * The radius of the outer circle of the donut chart in pixels. If this is not specified, the radius is responsive.
9
+ */
10
+ outerRadius?: number;
11
+ };
12
+ /**
13
+ * A visual representation of data proportions in a donut format.
14
+ */
15
+ export type TDonutChart<T> = (props: DonutChartProps) => T;
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type LineChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,7 +13,6 @@ export type LineChartProps = {
14
13
  * 2. An [array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/line-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- showBorder?: boolean;
18
16
  /**
19
17
  * Accessor to define the x-axis values. This can be a numerical or string index.
20
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/line-chart/#data).
@@ -36,11 +34,6 @@ export type LineChartProps = {
36
34
  * A string value that represents the subtitle of the chart. This appears below the title.
37
35
  */
38
36
  subtitle?: string;
39
- /**
40
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
41
- * This is utilized to render each line with the specified colors, based on the color grouping given by colorAccessor.
42
- */
43
- colors?: ChartColorTokens[];
44
37
  };
45
38
  /**
46
39
  * A visual representation of data showing trends.
@@ -1,4 +1,3 @@
1
- import type { ChartColorTokens } from '../../types';
2
1
  export type PieChartProps = {
3
2
  /**
4
3
  * The static width of the chart in pixels. If this is not specified, the width is responsive.
@@ -14,10 +13,6 @@ export type PieChartProps = {
14
13
  * 2. [Array of objects](https://developer.atlassian.com/platform/forge/ui-kit/components/pie-chart/#2--array-of-objects).
15
14
  */
16
15
  data: unknown[];
17
- /**
18
- * Boolean to display the chart border. Defaults to `false`.
19
- */
20
- showBorder?: boolean;
21
16
  /**
22
17
  * Accessor to define the color grouping. This can be a numerical or string index.
23
18
  * For more information on all accessors, see [Data](https://developer.atlassian.com/platform/forge/ui-kit/components/pie-chart/#data).
@@ -39,19 +34,10 @@ export type PieChartProps = {
39
34
  * A string value that represents the subtitle of the chart. This appears below the title.
40
35
  */
41
36
  subtitle?: string;
42
- /**
43
- * Boolean to render the pie as the donut variation. Defaults to `false`.
44
- */
45
- isDonut?: boolean;
46
37
  /**
47
38
  * Boolean to display labels on top of each slice. Defaults to `false`.
48
39
  */
49
40
  showMarkLabels?: boolean;
50
- /**
51
- * An array of [chart color tokens](https://atlassian.design/components/tokens/all-tokens#color-chart).
52
- * This is utilized to render each slice with the specified colors, based on the color grouping given by colorAccessor.
53
- */
54
- colors?: ChartColorTokens[];
55
41
  };
56
42
  /**
57
43
  * A visual representation of data proportions in a circular format.
@@ -1,4 +1,4 @@
1
1
  export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, } from './BarChartProps';
2
2
  export type { LineChartProps, TLineChart } from './LineChartProps';
3
- export type { SingleValueChartProps, TSingleValueChart } from './SingleValueChartProps';
4
3
  export type { PieChartProps, TPieChart } from './PieChartProps';
4
+ export type { DonutChartProps, TDonutChart } from './DonutChartProps';
@@ -1,3 +1,3 @@
1
1
  export type { AdfRendererProps, BadgeProps, BleedProps, BoxProps, ButtonGroupProps, ButtonProps, CalendarProps, CheckboxProps, CheckboxGroupProps, CodeBlockProps, CodeProps, DatePickerProps, DynamicTableProps, EmptyStateProps, ErrorMessageProps, FlexProps, FormFooterProps, FormHeaderProps, FormProps, FormSectionProps, GridProps, HeadingProps, HelperMessageProps, IconProps, InlineProps, LabelProps, LinkButtonProps, ListProps, ListItemProps, LoadingButtonProps, LozengeProps, ModalBodyProps, ModalFooterProps, ModalHeaderProps, ModalProps, ModalTitleProps, ModalTransitionProps, ProgressBarProps, ProgressTrackerProps, RadioGroupProps, RadioProps, RangeProps, SectionMessageActionProps, SectionMessageProps, SelectProps, SpinnerProps, StackProps, TabListProps, TabPanelProps, TabProps, TabsProps, TagGroupProps, TagProps, TextProps, TextAreaProps, TextfieldProps, ToggleProps, TooltipProps, TimePickerProps, ValidMessageProps, PopupProps, InlineEditProps, TBadge, TBleed, TBox, TButtonGroup, TButton, TCalendar, TCheckbox, TCheckboxGroup, TCodeBlock, TCode, TDatePicker, TDynamicTable, TEmptyState, TErrorMessage, TFlex, TFormFooter, TFormHeader, TForm, TFormSection, TGrid, THeading, THelperMessage, TIcon, TInline, TInlineEdit, TLabel, TLinkButton, TList, TListItem, TLoadingButton, TLozenge, TModalBody, TModalFooter, TModalHeader, TModal, TModalTitle, TModalTransition, TProgressBar, TProgressTracker, TRadioGroup, TRadio, TRange, TSectionMessageAction, TSectionMessage, TSelect, TSpinner, TStack, TTabList, TTabPanel, TTab, TTabs, TTagGroup, TTag, TTextArea, TTextfield, TTimePicker, TToggle, TTooltip, TValidMessage, TPopup, TAdfRenderer, TText, } from './components/__generated__';
2
- export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, LineChartProps, SingleValueChartProps, PieChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, TLineChart, TSingleValueChart, TPieChart, } from './components/charts';
2
+ export type { BarChartProps, StackBarChartProps, HorizontalStackBarChartProps, HorizontalBarChartProps, LineChartProps, DonutChartProps, PieChartProps, TBarChart, TStackBarChart, THorizontalStackBarChart, THorizontalBarChart, TLineChart, TDonutChart, TPieChart, } from './components/charts';
3
3
  export type { ChartColorTokens } from './types';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/forge-react-types",
3
- "version": "0.37.14",
3
+ "version": "0.39.0",
4
4
  "description": "Component types for Forge UI Kit React components",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -37,7 +37,7 @@
37
37
  "@atlaskit/inline-edit": "^15.1.0",
38
38
  "@atlaskit/lozenge": "^12.2.0",
39
39
  "@atlaskit/modal-dialog": "^14.0.0",
40
- "@atlaskit/popup": "^2.0.0",
40
+ "@atlaskit/popup": "^3.0.0",
41
41
  "@atlaskit/primitives": "^14.2.0",
42
42
  "@atlaskit/progress-bar": "^4.0.0",
43
43
  "@atlaskit/progress-tracker": "^10.0.0",
@@ -502,7 +502,7 @@ const baseGenerateComponentPropTypeSourceCode = (
502
502
  });
503
503
  };
504
504
 
505
- const boxPropsCodeConsolidator: CodeConsolidator = ({
505
+ const handleXCSSProp: CodeConsolidator = ({
506
506
  sourceFile,
507
507
  importCode,
508
508
  externalTypesCode,
@@ -510,7 +510,14 @@ const boxPropsCodeConsolidator: CodeConsolidator = ({
510
510
  componentPropCode,
511
511
  componentTypeCode,
512
512
  }) => {
513
- const xcssValidator = sourceFile.getVariableDeclarationOrThrow('xcssValidator').getText();
513
+ const xcssValidatorfile = sourceFile
514
+ .getProject()
515
+ .addSourceFileAtPath(require.resolve('@atlassian/forge-ui/utils/xcssValidator'));
516
+ const xcssValidator = xcssValidatorfile.getVariableDeclarationOrThrow('xcssValidator').getText();
517
+ const XCSSPropType = xcssValidatorfile
518
+ .getTypeAliasOrThrow('XCSSProp')
519
+ .setIsExported(false)
520
+ .getText();
514
521
 
515
522
  const utilsFile = sourceFile
516
523
  .getProject()
@@ -522,6 +529,7 @@ const boxPropsCodeConsolidator: CodeConsolidator = ({
522
529
  const xcssValidatorVariableDeclarationCode = [
523
530
  xcssValidatorDeclarationCode,
524
531
  `const ${xcssValidator};`,
532
+ XCSSPropType,
525
533
  ].join('\n');
526
534
 
527
535
  return [
@@ -541,7 +549,8 @@ const boxPropsCodeConsolidator: CodeConsolidator = ({
541
549
  };
542
550
 
543
551
  const codeConsolidators: Record<string, CodeConsolidator> = {
544
- BoxProps: boxPropsCodeConsolidator,
552
+ BoxProps: handleXCSSProp,
553
+ PressableProps: handleXCSSProp,
545
554
  };
546
555
 
547
556
  const generateComponentPropTypeSourceCode = (
@@ -3,9 +3,9 @@
3
3
  *
4
4
  * Extract component prop types from UIKit 2 components - BoxProps
5
5
  *
6
- * @codegen <<SignedSource::8ab6a67fa03d077a43a19a7e31c78146>>
6
+ * @codegen <<SignedSource::c3ad3413cf478b4f6da470a99c029688>>
7
7
  * @codegenCommand yarn workspace @atlaskit/forge-react-types codegen
8
- * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::898e2c561f956fd22d43ade8ef60ca57>>
8
+ * @codegenDependency ../../../../forge-ui/src/components/UIKit/box/__generated__/index.partial.tsx <<SignedSource::cd2255d6156809f22f110b9eb0936c9d>>
9
9
  */
10
10
  /* eslint-disable @atlaskit/design-system/ensure-design-token-usage/preview */
11
11
 
@@ -186,9 +186,9 @@ const xcssValidator = makeXCSSValidator({
186
186
  supportedValues: ['relative', 'static'],
187
187
  },
188
188
  });
189
+ type XCSSProp = ReturnType<typeof xcssValidator>;
189
190
 
190
191
  type PlatformBoxProps = React.ComponentProps<typeof PlatformBox>;
191
- type XCSSProp = ReturnType<typeof xcssValidator>;
192
192
 
193
193
  export type BoxProps = Pick<PlatformBoxProps, 'children' | 'ref' | 'testId'> & {
194
194
  /**