-
-
Notifications
You must be signed in to change notification settings - Fork 51
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
Showing
39 changed files
with
370 additions
and
33 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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
import { Textarea } from "ui" | ||
|
||
export default function TextareaAnatomy() { | ||
return <Textarea label="Address" /> | ||
return <Textarea label="Address" description="Please enter your address" /> | ||
} |
15 changes: 15 additions & 0 deletions
15
components/docs/forms/checkbox/checkbox-group-uncontrolled-demo.tsx
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,15 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Checkbox, CheckboxGroup } from "ui" | ||
|
||
export default function CheckboxGroupUncontrolledDemo() { | ||
return ( | ||
<CheckboxGroup defaultValue={["sound", "wifi"]} label="Options"> | ||
<Checkbox value="sound">Sound</Checkbox> | ||
<Checkbox value="wifi">Wi-Fi</Checkbox> | ||
<Checkbox value="sync">Sync</Checkbox> | ||
</CheckboxGroup> | ||
) | ||
} |
13 changes: 13 additions & 0 deletions
13
components/docs/forms/checkbox/checkbox-uncontrolled-demo.tsx
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,13 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Checkbox } from "ui" | ||
|
||
export default function CheckboxUncontrolledDemo() { | ||
return ( | ||
<Checkbox defaultSelected value="updates"> | ||
Receive Updates | ||
</Checkbox> | ||
) | ||
} |
9 changes: 9 additions & 0 deletions
9
components/docs/forms/number-field/number-field-uncontrolled-demo.tsx
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,9 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { NumberField } from "ui" | ||
|
||
export default function NumberFieldUncontrolledDemo() { | ||
return <NumberField label="Width" defaultValue={1997} /> | ||
} |
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
16 changes: 16 additions & 0 deletions
16
components/docs/forms/radio-group/radio-group-uncontrolled-demo.tsx
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,16 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Radio, RadioGroup } from "ui" | ||
|
||
export default function RadioGroupUncontrolledDemo() { | ||
return ( | ||
<RadioGroup label="Features" defaultValue="theme"> | ||
<Radio value="language">Language</Radio> | ||
<Radio value="timezone">Timezone</Radio> | ||
<Radio value="notifications">Notifications</Radio> | ||
<Radio value="privacy">Privacy</Radio> | ||
</RadioGroup> | ||
) | ||
} |
7 changes: 7 additions & 0 deletions
7
components/docs/forms/search-field/search-field-description-demo.tsx
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,7 @@ | ||
"use client" | ||
|
||
import { SearchField } from "ui" | ||
|
||
export default function SearchFieldDescriptionDemo() { | ||
return <SearchField aria-label="Search" placeholder="Search" description="Search for a product" /> | ||
} |
7 changes: 7 additions & 0 deletions
7
components/docs/forms/search-field/search-field-readonly-demo.tsx
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,7 @@ | ||
"use client" | ||
|
||
import { SearchField } from "ui" | ||
|
||
export default function SearchFieldDescriptionDemo() { | ||
return <SearchField aria-label="Search" isReadOnly placeholder="Search" /> | ||
} |
9 changes: 9 additions & 0 deletions
9
components/docs/forms/search-field/search-field-uncontrolled-demo.tsx
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,9 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { SearchField } from "ui" | ||
|
||
export default function SearchFieldControlledDemo() { | ||
return <SearchField defaultValue="Laravel" /> | ||
} |
7 changes: 7 additions & 0 deletions
7
components/docs/forms/text-field/text-field-description-demo.tsx
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,7 @@ | ||
"use client" | ||
|
||
import { TextField } from "ui" | ||
|
||
export default function TextFieldDescriptionDemo() { | ||
return <TextField label="Name" description="Please enter your legal name." /> | ||
} |
9 changes: 9 additions & 0 deletions
9
components/docs/forms/text-field/text-field-uncontrolled-demo.tsx
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,9 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { TextField } from "ui" | ||
|
||
export default function TextFieldUncontrolledDemo() { | ||
return <TextField defaultValue="Irsyad" label="Name" className="mb-2" /> | ||
} |
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,9 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Textarea } from "ui" | ||
|
||
export default function TextareaDescriptionDemo() { | ||
return <Textarea label="Address" description="Please enter your address" /> | ||
} |
9 changes: 9 additions & 0 deletions
9
components/docs/forms/textarea/textarea-uncontrolled-demo.tsx
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,9 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Textarea } from "ui" | ||
|
||
export default function TextareaUncontrolledDemo() { | ||
return <Textarea defaultValue="Brooklyn New York, USA" label="Address" className="mb-2" /> | ||
} |
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
28 changes: 28 additions & 0 deletions
28
components/docs/pickers/select/select-uncontrolled-demo.tsx
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,28 @@ | ||
"use client" | ||
|
||
import React from "react" | ||
|
||
import { Select } from "ui" | ||
|
||
export const movies = [ | ||
{ id: 1, title: "Inception" }, | ||
{ id: 2, title: "The Dark Knight" }, | ||
{ id: 3, title: "Interstellar" }, | ||
{ id: 4, title: "The Matrix" }, | ||
{ id: 5, title: "Pulp Fiction" } | ||
] | ||
|
||
export default function SelectUncontrolledDemo() { | ||
return ( | ||
<Select defaultSelectedKey={2} label="Movies" placeholder="Select a movie"> | ||
<Select.Trigger /> | ||
<Select.List items={movies}> | ||
{(item) => ( | ||
<Select.Option id={item.id} textValue={item.title}> | ||
{item.title} | ||
</Select.Option> | ||
)} | ||
</Select.List> | ||
</Select> | ||
) | ||
} |
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
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
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
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
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
Oops, something went wrong.