Skip to content

Commit

Permalink
fix(docs): imports missing in DatePicker (#2850)
Browse files Browse the repository at this point in the history
* fix(docs): imports missing in DatePicker

* fix(docs): imported cn in presets

* fix(docs): missing imports in Preset(TS)

---------

Co-authored-by: shrinidhi.upadhyaya <shrinidhiupadhyaya1195@gmail.com>
  • Loading branch information
ShrinidhiUpadhyaya authored Apr 24, 2024
1 parent dd39db2 commit 1ba2d02
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
12 changes: 6 additions & 6 deletions apps/docs/content/components/date-picker/preset.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const App = `import {DatePicker} from "@nextui-org/react";
import {now, useLocale, startOfWeek, startOfMonth, useDateFormatter, getLocalTimeZone} from "@internationalized/date";
import {I18nProvider} from "@react-aria/i18n";
const App = `import {DatePicker, RadioGroup, Radio, ButtonGroup, Button, cn} from "@nextui-org/react";
import {startOfWeek, startOfMonth, getLocalTimeZone, today} from "@internationalized/date";
import {useLocale, useDateFormatter} from "@react-aria/i18n";
export default function App() {
let defaultDate = today(getLocalTimeZone());
Expand Down Expand Up @@ -91,9 +91,9 @@ export default function App() {
);
}`;

const AppTs = `import {DatePicker} from "@nextui-org/react";
import {DateValue, now, useLocale, startOfWeek, startOfMonth, useDateFormatter, getLocalTimeZone} from "@internationalized/date";
import {I18nProvider} from "@react-aria/i18n";
const AppTs = `import {DatePicker, RadioGroup, Radio, ButtonGroup, Button, cn} from "@nextui-org/react";
import {DateValue, startOfWeek, startOfMonth, getLocalTimeZone, today} from "@internationalized/date";
import {useLocale, useDateFormatter} from "@react-aria/i18n";
export default function App() {
let defaultDate = today(getLocalTimeZone());
Expand Down
2 changes: 1 addition & 1 deletion apps/docs/content/components/date-picker/time-zones.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const AppTs = `import {DatePicker} from "@nextui-org/react";
import {parseZonedDateTime} from "@internationalized/date";
import {parseZonedDateTime, parseAbsoluteToLocal} from "@internationalized/date";
export default function App() {
return (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const App = `import {DatePicker} from "@nextui-org/react";
import {now, getLocalTimeZone} from "@internationalized/date";
export default function App() {
return (
Expand Down

0 comments on commit 1ba2d02

Please sign in to comment.