From 149e6db8ea04f6a110f998a3db1ef39e5303125d Mon Sep 17 00:00:00 2001 From: Junior Garcia Date: Tue, 18 Feb 2025 18:29:20 -0300 Subject: [PATCH 01/10] chore: theme generator credits --- apps/docs/content/blog/v2.7.0.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/docs/content/blog/v2.7.0.mdx b/apps/docs/content/blog/v2.7.0.mdx index 5f638110c..adc8a2709 100644 --- a/apps/docs/content/blog/v2.7.0.mdx +++ b/apps/docs/content/blog/v2.7.0.mdx @@ -31,7 +31,7 @@ HeroUI version **v2.7.0** introduces the highly anticipated Toast component, alo ## What's New in v2.7.0? - [Toast Component](#toast-component) - A new toast notification system with rich features -- [NumberInput Component](#numberinput-component) - A new input component specifically designed for numerical values +- [NumberInput Component](#numbaerinput-component) - A new input component specifically designed for numerical values - [New Spinner Variants](#new-spinner-variants) - Enhanced spinner component with new design variants - [Theme Generator](#theme-generator) - A powerful web-based tool for creating and customizing your themes - [Table Virtualization](#table-virtualization) - Performance improvements for large datasets in Table component @@ -152,7 +152,7 @@ For more examples and detailed documentation about the Spinner component, visit ## Theme Generator -The new Theme Generator is a powerful web-based tool that allows you to create and customize your themes visually. Simply visit our [Theme Generator](/themes) to: +The new Theme Generator is a powerful web-based tool that allows you to create and customize your themes visually. Based on the amazing work by [xylish7](https://github.com/xylish7) in the [nextui-theme-generator](https://github.com/xylish7/nextui-theme-generator) project (huge thanks!), our Theme Generator provides a seamless experience for theme customization. Simply visit our [Theme Generator](/themes) to: - Create custom color schemes - Preview components with your theme in real-time From 943dfdbd66d16c72fb5c4c3d57421d5418bef096 Mon Sep 17 00:00:00 2001 From: Junior Garcia Date: Tue, 18 Feb 2025 18:47:40 -0300 Subject: [PATCH 02/10] fix: blog date and spinner default variant --- apps/docs/content/blog/v2.7.0.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/docs/content/blog/v2.7.0.mdx b/apps/docs/content/blog/v2.7.0.mdx index adc8a2709..823fff23a 100644 --- a/apps/docs/content/blog/v2.7.0.mdx +++ b/apps/docs/content/blog/v2.7.0.mdx @@ -1,7 +1,7 @@ --- title: "HeroUI v2.7.0" description: "New Toast component, NumberInput, Theme Generator, and lots of bug fixes and improvements." -date: "2025-02-19" +date: "2025-02-18" image: "/blog/v2.7.0.jpg" tags: ["heroui", "v2.7.0", "release", "toast", "improvements", "theme"] author: @@ -232,7 +232,7 @@ import {HeroUIProvider} from "@heroui/react"; function App() { return ( - {/* All components will use the dots spinner variant by default */} + {/* All components will use the "simple" spinner variant by default */} ); } From 99d1674793d9e9709872db40cefc37e1c67963bc Mon Sep 17 00:00:00 2001 From: Maharshi Alpesh Date: Wed, 19 Feb 2025 16:20:27 +0530 Subject: [PATCH 03/10] chore: fixing the placement option in toast docs (#4857) --- apps/docs/app/providers.tsx | 3 +-- .../components/toast/placement.raw.jsx | 25 +++++++++++++------ apps/docs/content/docs/components/toast.mdx | 2 +- 3 files changed, 20 insertions(+), 10 deletions(-) diff --git a/apps/docs/app/providers.tsx b/apps/docs/app/providers.tsx index fd981ace4..f31a0fd05 100644 --- a/apps/docs/app/providers.tsx +++ b/apps/docs/app/providers.tsx @@ -1,7 +1,7 @@ "use client"; import * as React from "react"; -import {HeroUIProvider, ToastProvider} from "@heroui/react"; +import {HeroUIProvider} from "@heroui/react"; import {ThemeProvider as NextThemesProvider} from "next-themes"; import {ThemeProviderProps} from "next-themes"; import {useRouter} from "next/navigation"; @@ -44,7 +44,6 @@ export function Providers({children, themeProps}: ProvidersProps) { return ( - {children} diff --git a/apps/docs/content/components/toast/placement.raw.jsx b/apps/docs/content/components/toast/placement.raw.jsx index af5b3b706..6b861869a 100644 --- a/apps/docs/content/components/toast/placement.raw.jsx +++ b/apps/docs/content/components/toast/placement.raw.jsx @@ -1,15 +1,26 @@ -import {addToast, Button} from "@heroui/react"; +import {addToast, ToastProvider, Button} from "@heroui/react"; import React from "react"; export default function App() { + const [placement, setPlacement] = React.useState("bottom-right"); + return ( -
- {["top-left", "top-center", "top-right", "bottom-left", "bottom-center", "bottom-right"].map( - (position) => ( + <> + +
+ {[ + "top-left", + "top-center", + "top-right", + "bottom-left", + "bottom-center", + "bottom-right", + ].map((position) => ( - ), - )} -
+ ))} +
+ ); } diff --git a/apps/docs/content/docs/components/toast.mdx b/apps/docs/content/docs/components/toast.mdx index 116e6d29c..cbad3d825 100644 --- a/apps/docs/content/docs/components/toast.mdx +++ b/apps/docs/content/docs/components/toast.mdx @@ -303,7 +303,7 @@ Toast has the following slots: }, { attribute: "placement", - type: "bottom-right" | "bottom-left" | "bottom-center" | "top-right" | "top-left" | "top-center", + type: "bottom-right | bottom-left | bottom-center | top-right | top-left | top-center", description: "The placement of the toast.", default: "bottom-right" }, From 8052b54a81287bf48c2e36ee1968a2728af54690 Mon Sep 17 00:00:00 2001 From: Maharshi Alpesh Date: Thu, 20 Feb 2025 19:59:14 +0530 Subject: [PATCH 04/10] chore: refactoring the toast docs (#4883) --- .../content/components/toast/color.raw.jsx | 6 +++--- .../content/components/toast/placement.raw.jsx | 18 +++++++++--------- .../content/components/toast/radius.raw.jsx | 16 +++++++++++----- .../content/components/toast/variants.raw.jsx | 8 ++++---- apps/docs/content/docs/components/toast.mdx | 2 +- 5 files changed, 28 insertions(+), 22 deletions(-) diff --git a/apps/docs/content/components/toast/color.raw.jsx b/apps/docs/content/components/toast/color.raw.jsx index 32c6c8dda..5679cc246 100644 --- a/apps/docs/content/components/toast/color.raw.jsx +++ b/apps/docs/content/components/toast/color.raw.jsx @@ -3,16 +3,16 @@ import {addToast, Button} from "@heroui/react"; export default function App() { return (
- {["default", "primary", "secondary", "success", "warning", "danger"].map((color) => ( + {["Default", "Primary", "Secondary", "Success", "Warning", "Danger"].map((color) => ( ))}
diff --git a/apps/docs/content/components/toast/radius.raw.jsx b/apps/docs/content/components/toast/radius.raw.jsx index 1414cfb23..f29722be1 100644 --- a/apps/docs/content/components/toast/radius.raw.jsx +++ b/apps/docs/content/components/toast/radius.raw.jsx @@ -3,20 +3,26 @@ import {addToast, Button} from "@heroui/react"; export default function App() { return (
- {["none", "sm", "md", "lg", "full"].map((radius) => ( + {[ + ["None", "none"], + ["Small", "sm"], + ["Medium", "md"], + ["Large", "lg"], + ["Full", "full"], + ].map((radius) => ( ))}
diff --git a/apps/docs/content/components/toast/variants.raw.jsx b/apps/docs/content/components/toast/variants.raw.jsx index 7d4d5b9d8..fe51cb259 100644 --- a/apps/docs/content/components/toast/variants.raw.jsx +++ b/apps/docs/content/components/toast/variants.raw.jsx @@ -4,9 +4,9 @@ export default function App() { return (
{[ - ["solid", "solid"], - ["bordered", "bordered"], - ["flat", "faded"], + ["Solid", "solid"], + ["Bordered", "bordered"], + ["Flat", "faded"], ].map((variant) => (