Skip to content

Commit

Permalink
remove danger style from ToggleButton
Browse files Browse the repository at this point in the history
  • Loading branch information
mkernohanbc committed Jan 21, 2025
1 parent 5ca03e6 commit 6bd0d64
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,3 @@
color: var(--typography-color-disabled);
cursor: not-allowed;
}

/* Danger */
.bcds-react-aria-ToggleButton.danger {
color: var(--typography-color-danger);
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,20 +8,16 @@ import "./ToggleButton.css";
export interface ToggleButtonProps extends ReactAriaToggleButtonProps {
size?: "small" | "medium";
isIconButton?: boolean;
danger?: boolean;
}

export default function ToggleButton({
size = "medium",
danger = false,
children,
...props
}: ToggleButtonProps) {
return (
<ReactAriaToggleButton
className={`bcds-react-aria-ToggleButton ${size} ${
danger ? "danger" : null
}`}
className={`bcds-react-aria-ToggleButton ${size}`}
{...props}
>
{children}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@ const meta = {
options: ["small", "medium"],
description: "Sets button size",
},
danger: {
control: { type: "boolean" },
description: "Applies a red colourway",
},
isDisabled: {
control: { type: "boolean" },
description: "Whether a button is disabled",
Expand Down Expand Up @@ -74,11 +70,6 @@ export const ToggleButtonWithIcon: Story = {
},
};

export const DangerToggleButton: Story = {
...ToggleButtonTemplate,
args: { children: ["Danger colourway"], danger: true },
};

export const DefaultSelectedToggleButton: Story = {
...ToggleButtonTemplate,
args: {
Expand Down

0 comments on commit 6bd0d64

Please sign in to comment.