Skip to content

Commit

Permalink
docs: change class name calendar to root in the examples
Browse files Browse the repository at this point in the history
Fixes #2342
  • Loading branch information
gpbl committed Aug 4, 2024
1 parent fe49f38 commit 40edbcb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions website/docs/docs/styling.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ They are the value of the [`UI`](../api/enumerations/UI.md), [`DayFlag`](../api/
For example, to change the class name of the calendar container:

```tsx
<DayPicker classNames={{ calendar: "my-calendar" }} />
<DayPicker classNames={{ root: "my-calendar" }} />
```

Or the disabled days:
Expand Down Expand Up @@ -166,7 +166,7 @@ export function MyCalendar() {
classNames={{
today: `border-amber-500`, // Add a border to today's date
selected: `bg-amber-500 border-amber-500 text-white`, // Highlight the selected day
calendar: `${defaultClassNames.calendar} shadow-lg p-5` // Add a shadow to the calendar
root: `${defaultClassNames.root} shadow-lg p-5`, // Add a shadow to the root element
chevron: `${defaultClassNames.chevron} fill-amber-500` // Change the color of the chevron
}}
/>
Expand Down

0 comments on commit 40edbcb

Please sign in to comment.