✨(react) add danger color to Button
We adding do's and don't to the documentation I realized that the danger button was really important in some cases even if the style was not delivered by designers. Example: Delete buttons.
This commit is contained in:
@@ -13,6 +13,7 @@ The Cunningham Button behaves the same as the native html `<button>` element, bu
|
|||||||
<Story id="button--primary"/>
|
<Story id="button--primary"/>
|
||||||
<Story id="button--secondary"/>
|
<Story id="button--secondary"/>
|
||||||
<Story id="button--tertiary"/>
|
<Story id="button--tertiary"/>
|
||||||
|
<Story id="button--danger"/>
|
||||||
</Canvas>
|
</Canvas>
|
||||||
|
|
||||||
<Source
|
<Source
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import React, { ButtonHTMLAttributes, ReactNode } from "react";
|
import React, { ButtonHTMLAttributes, ReactNode } from "react";
|
||||||
|
|
||||||
interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
|
interface Props extends ButtonHTMLAttributes<HTMLButtonElement> {
|
||||||
color?: "primary" | "secondary" | "tertiary";
|
color?: "primary" | "secondary" | "tertiary" | "danger";
|
||||||
icon?: ReactNode;
|
icon?: ReactNode;
|
||||||
iconPosition?: "left" | "right";
|
iconPosition?: "left" | "right";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user