ui: transform number to px in basis utility prop

Signed-off-by: MT Lewis <mtlewis@users.noreply.github.com>
This commit is contained in:
MT Lewis
2026-04-17 17:52:23 +01:00
parent 68d1725113
commit 0912de3a25
2 changed files with 2 additions and 1 deletions
@@ -286,7 +286,7 @@ export const FlexItems = meta.story({
},
basis: {
control: 'radio',
options: [undefined, '0%', '25%', '50%', '100%', 'auto'],
options: [undefined, '0%', '25%', '50%', '100%', 100, '250px', 'auto'],
},
},
render: ({ component: Component, ...args }) => {
+1
View File
@@ -212,6 +212,7 @@ export const utilityClassMap = {
class: 'bui-basis',
cssVar: '--basis',
values: [],
transform: input => (typeof input === 'number' ? `${input}px` : input),
},
} as const satisfies Record<
string,