Skip to content
Merged
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
6 changes: 3 additions & 3 deletions apps/docs/content/components/toast/color.raw.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@ import {addToast, Button} from "@heroui/react";
export default function App() {
return (
<div className="flex flex-wrap gap-2">
{["default", "primary", "secondary", "success", "warning", "danger"].map((color) => (
{["Default", "Primary", "Secondary", "Success", "Warning", "Danger"].map((color) => (
<Button
key={color}
color={color}
color={color.toLowerCase()}
variant={"flat"}
onPress={() =>
addToast({
title: "Toast title",
description: "Toast displayed successfully",
color: color,
color: color.toLowerCase(),
})
}
>
Expand Down
18 changes: 9 additions & 9 deletions apps/docs/content/components/toast/placement.raw.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,25 @@ export default function App() {
<ToastProvider placement={placement} toastOffset={placement.includes("top") ? 60 : 0} />
<div className="flex flex-wrap gap-2">
{[
"top-left",
"top-center",
"top-right",
"bottom-left",
"bottom-center",
"bottom-right",
["Top Left", "top-left"],
["Top Center", "top-center"],
["Top Right", "top-right"],
["Bottom Left", "bottom-left"],
["Bottom Center", "bottom-center"],
["Bottom Right", "bottom-right"],
].map((position) => (
<Button
key={position}
key={position[1]}
variant={"flat"}
onPress={() => {
setPlacement(position);
setPlacement(position[1]);
addToast({
title: "Toast title",
description: "Toast displayed successfully",
});
}}
>
{position}
{position[0]}
</Button>
))}
</div>
Expand Down
16 changes: 11 additions & 5 deletions apps/docs/content/components/toast/radius.raw.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,26 @@ import {addToast, Button} from "@heroui/react";
export default function App() {
return (
<div className="flex flex-wrap gap-2">
{["none", "sm", "md", "lg", "full"].map((radius) => (
{[
["None", "none"],
["Small", "sm"],
["Medium", "md"],
["Large", "lg"],
["Full", "full"],
].map((radius) => (
<Button
key={radius}
radius={radius}
key={radius[1]}
radius={radius[1]}
variant={"flat"}
onPress={() =>
addToast({
title: "Toast title",
description: "Toast displayed successfully",
radius: radius,
radius: radius[1],
})
}
>
{radius}
{radius[0]}
</Button>
))}
</div>
Expand Down
8 changes: 4 additions & 4 deletions apps/docs/content/components/toast/variants.raw.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ export default function App() {
return (
<div className="flex flex-wrap gap-2">
{[
["solid", "solid"],
["bordered", "bordered"],
["flat", "faded"],
["Solid", "solid"],
["Bordered", "bordered"],
["Flat", "faded"],
].map((variant) => (
<Button
key={variant[0]}
Expand All @@ -17,7 +17,7 @@ export default function App() {
title: "Toast title",
description: "Toast displayed successfully",
// @ts-ignore
variant: variant[0],
variant: variant[0].toLowerCase(),
Comment thread
macci001 marked this conversation as resolved.
color: "secondary",
})
}
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/docs/components/toast.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,7 @@ Toast has the following slots:
attribute: "maxVisibleToasts",
type: "number",
description: "Maximum toasts which will be visible",
default: "5"
default: "3"
},
{
attribute: "placement",
Expand Down