-
-
Notifications
You must be signed in to change notification settings - Fork 168
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
edc8a49
commit 7fa9cbb
Showing
5 changed files
with
30 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@zag-js/date-picker": minor | ||
--- | ||
|
||
- Add parse function to avoid installing additional `@internationalized/date` package | ||
- Export more date picker types |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { parseDate, type DateValue } from "@internationalized/date" | ||
|
||
export function parse(value: string): DateValue | ||
export function parse(value: string[]): DateValue[] | ||
export function parse(value: string | string[]) { | ||
if (Array.isArray(value)) { | ||
return value.map((v) => parseDate(v)) as DateValue[] | ||
} | ||
return parseDate(value) as DateValue | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,30 @@ | ||
export { anatomy } from "./date-picker.anatomy" | ||
export { connect } from "./date-picker.connect" | ||
export { machine } from "./date-picker.machine" | ||
export { parse } from "./date-picker.parse" | ||
export type { | ||
MachineApi as Api, | ||
Calendar, | ||
CalendarDate, | ||
CalendarDateTime, | ||
TableCellProps, | ||
TableCellState, | ||
UserDefinedContext as Context, | ||
DateDuration, | ||
DateFormatter, | ||
DateValue, | ||
DateValueOffset, | ||
DateView, | ||
DayTableCellProps, | ||
DayTableCellState, | ||
TableProps, | ||
DateValueOffset, | ||
MonthGridProps, | ||
SelectionMode, | ||
Send, | ||
State, | ||
TableCellProps, | ||
TableCellState, | ||
TableProps, | ||
ViewProps, | ||
VisibleRangeText, | ||
WeekDay, | ||
YearGridProps, | ||
ZonedDateTime, | ||
MachineApi as Api, | ||
} from "./date-picker.types" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
export { anatomy } from "./slider.anatomy" | ||
export { connect } from "./slider.connect" | ||
export { machine } from "./slider.machine" | ||
export type { UserDefinedContext as Context, MachineApi as Api } from "./slider.types" | ||
export type { UserDefinedContext as Context, MachineApi as Api, ThumbProps, MarkerProps } from "./slider.types" |
7fa9cbb
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
zag-nextjs – ./examples/next-ts
zag-nextjs-chakra-ui.vercel.app
zag-nextjs-git-main-chakra-ui.vercel.app
zag-two.vercel.app
7fa9cbb
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
zag-website – ./website
zag-website.vercel.app
zag-website-git-main-chakra-ui.vercel.app
zag-website-chakra-ui.vercel.app
zagjs.com
www.zagjs.com
7fa9cbb
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
zag-vue – ./examples/vue-ts
zag-vue.vercel.app
zag-vue-chakra-ui.vercel.app
zag-vue-git-main-chakra-ui.vercel.app