use 'sm' instead of 'small'

This commit is contained in:
Bilux 2022-10-19 12:01:53 +01:00 committed by GitHub
commit 386cc983c9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 7 deletions

View file

@ -13,7 +13,7 @@
/**
* Specify the size of button
* @type {"default" | "field" | "small" | "lg" | "xl"}
* @type {"default" | "field" | "sm" | "lg" | "xl"}
*/
export let size = "default";
@ -97,14 +97,10 @@
class: [
"bx--btn",
expressive && "bx--btn--expressive",
((size === "small" && !expressive) ||
(size === "sm" && !expressive) ||
(size === "small" && !expressive)) &&
"bx--btn--sm",
(size === "field" && !expressive) ||
(size === "md" && !expressive && "bx--btn--md"),
size === "field" && "bx--btn--field",
size === "small" && "bx--btn--sm",
size === "sm" && "bx--btn--sm",
size === "lg" && "bx--btn--lg",
size === "xl" && "bx--btn--xl",
kind && `bx--btn--${kind}`,

View file

@ -24,7 +24,7 @@ export interface ButtonProps
* Specify the size of button
* @default "default"
*/
size?: "default" | "field" | "small" | "lg" | "xl";
size?: "default" | "field" | "sm" | "lg" | "xl";
/**
* Set to `true` to use Carbon's expressive typesetting