Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions packages/javascript/src/models/flow-meta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,17 @@ export interface FlowMetaThemeColorScheme {
palette: FlowMetaThemeColors;
}

/**
* Size configuration in the v2 theme.
*
* @experimental This API may change in future versions
*/
export interface FlowMetaThemeSize {
small?: string;
medium?: string;
large?: string;
}

/**
* Shape / geometry configuration in the v2 theme.
*
Expand Down Expand Up @@ -215,6 +226,17 @@ export interface FlowMetaTheme {

/** Typography configuration for the theme */
typography?: FlowMetaThemeTypography;

/** Border configuration for the theme */
border?: {width: string; color: string; style: string};

/** Shadow configuration for the theme */
shadows?: FlowMetaThemeSize;

/** Spacing configuration for the theme */
spacing?: {unit: number};

borderRadius?: FlowMetaThemeSize;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

borderRadius is already a part of shape. Is there a reason for having a first class property?

}

/**
Expand Down
1 change: 1 addition & 0 deletions packages/react/src/utils/buildThemeConfigFromFlowMeta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ const buildThemeConfigFromFlowMeta = (
}

return {
...flowMetaTheme,
...(flowMetaTheme.direction ? {direction: flowMetaTheme.direction} : {}),
...(borderRadiusStr
? {
Expand Down
1 change: 1 addition & 0 deletions packages/vue/src/utils/buildThemeConfigFromFlowMeta.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ const buildThemeConfigFromFlowMeta = (
}

return {
...flowMetaTheme,
...(flowMetaTheme.direction ? {direction: flowMetaTheme.direction} : {}),
...(borderRadiusStr
? {
Expand Down
Loading