@udixio/mcp 0.3.2 → 0.4.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. package/dist/LICENSE +202 -0
  2. package/dist/cli.mjs +3 -6
  3. package/dist/lib/loaders/components.d.ts.map +1 -1
  4. package/dist/lib/loaders/docs.d.ts.map +1 -1
  5. package/dist/lib/loaders/theme.d.ts.map +1 -1
  6. package/package.json +16 -12
  7. package/dist/bundled/components-index.json +0 -369
  8. package/dist/bundled/doc-src/components/Code.astro +0 -14
  9. package/dist/bundled/doc-src/components/ComponentPreview.astro +0 -218
  10. package/dist/bundled/doc-src/data/components/button.overview.mdx +0 -152
  11. package/dist/bundled/doc-src/data/components/card.overview.mdx +0 -91
  12. package/dist/bundled/doc-src/data/components/carousel.overview.mdx +0 -108
  13. package/dist/bundled/doc-src/data/components/checkbox.overview.mdx +0 -172
  14. package/dist/bundled/doc-src/data/components/chip.overview.mdx +0 -216
  15. package/dist/bundled/doc-src/data/components/date-picker.overview.mdx +0 -102
  16. package/dist/bundled/doc-src/data/components/divider.overview.mdx +0 -54
  17. package/dist/bundled/doc-src/data/components/fab-menu.overview.mdx +0 -69
  18. package/dist/bundled/doc-src/data/components/fab.overview.mdx +0 -80
  19. package/dist/bundled/doc-src/data/components/icon-button.overview.mdx +0 -155
  20. package/dist/bundled/doc-src/data/components/navigation-rail.overview.mdx +0 -142
  21. package/dist/bundled/doc-src/data/components/progress-indicator.overview.mdx +0 -49
  22. package/dist/bundled/doc-src/data/components/slider.overview.mdx +0 -64
  23. package/dist/bundled/doc-src/data/components/snackbar.overview.mdx +0 -37
  24. package/dist/bundled/doc-src/data/components/switch.overview.mdx +0 -41
  25. package/dist/bundled/doc-src/data/components/tabs.overview.mdx +0 -171
  26. package/dist/bundled/doc-src/data/components/temp.md +0 -506
  27. package/dist/bundled/doc-src/data/components/text-field.overview.mdx +0 -90
  28. package/dist/bundled/doc-src/data/components/tooltip.overview.mdx +0 -159
  29. package/dist/bundled/doc-src/data/pages/mcp.mdx +0 -92
  30. package/dist/bundled/doc-src/layouts/components.astro +0 -87
  31. package/dist/bundled/doc-src/layouts/layout.astro +0 -55
  32. package/dist/bundled/doc-src/pages/404.astro +0 -18
  33. package/dist/bundled/doc-src/pages/[...url].astro +0 -34
  34. package/dist/bundled/doc-src/pages/animations.astro +0 -322
  35. package/dist/bundled/doc-src/pages/components/[component]/api.astro +0 -89
  36. package/dist/bundled/doc-src/pages/components/[component]/index.astro +0 -5
  37. package/dist/bundled/doc-src/pages/components/[component]/overview.astro +0 -37
  38. package/dist/bundled/doc-src/pages/components/index.astro +0 -130
  39. package/dist/bundled/doc-src/pages/index.astro +0 -5
  40. package/dist/bundled/doc-src/pages/search.astro +0 -12
  41. package/dist/bundled/doc-src/pages/themes.astro +0 -86
  42. package/dist/bundled/theme.json +0 -359
@@ -1,155 +0,0 @@
1
- ---
2
- ---
3
-
4
-
5
-
6
-
7
-
8
-
9
-
10
-
11
-
12
-
13
-
14
-
15
-
16
- import { CodePreview } from '@/components/CodePreview.js';
17
- import { faPlus, faStar as fasStar } from '@fortawesome/free-solid-svg-icons';
18
- import { faStar as farStar } from '@fortawesome/free-regular-svg-icons';
19
-
20
- ## Usage
21
-
22
- Import IconButton from @udixio/ui-react when an action is best represented by an icon.
23
-
24
- ```bash
25
- import { IconButton } from "@udixio/ui-react"
26
- ```
27
-
28
- <CodePreview
29
- client:load
30
- code={`
31
- <div className="flex items-center gap-3">
32
- <IconButton label="Add item" icon={faPlus} onClick={() => console.log('add')} />
33
- </div>`}
34
- scope={{ faPlus }}
35
- />
36
-
37
- ## Variants
38
-
39
- <CodePreview
40
- client:load
41
- code={`
42
- <div className="flex items-center gap-3">
43
- <IconButton label="Standard" icon={faPlus} variant="standard" />
44
- <IconButton label="Filled" icon={faPlus} variant="filled" />
45
- <IconButton label="Tonal" icon={faPlus} variant="tonal" />
46
- <IconButton label="Outlined" icon={faPlus} variant="outlined" />
47
- </div>`}
48
- scope={{ faPlus }}
49
- />
50
-
51
- ## Sizes
52
-
53
- <CodePreview
54
- client:load
55
- code={`
56
- <div className="flex items-center gap-3">
57
- <IconButton variant="filled" label="XS" icon={faPlus} size="xSmall" />
58
- <IconButton variant="filled" label="S" icon={faPlus} size="small" />
59
- <IconButton variant="filled" label="M" icon={faPlus} size="medium" />
60
- <IconButton variant="filled" label="L" icon={faPlus} size="large" />
61
- <IconButton variant="filled" label="XL" icon={faPlus} size="xLarge" />
62
- </div>`}
63
- scope={{ faPlus }}
64
- />
65
-
66
- ## Shapes and widths
67
-
68
- Control the button outline with `shape` and surface padding with `width`.
69
-
70
- <CodePreview
71
- client:load
72
- code={`
73
- <>
74
- <div className="flex items-center gap-3">
75
- <IconButton variant="filled" label="Rounded" icon={faPlus} shape="rounded" width="narrow" />
76
- <IconButton variant="filled" label="Squared" icon={faPlus} shape="rounded" width="default" />
77
- <IconButton variant="filled" label="Narrow" icon={faPlus} shape="rounded" width="wide" />
78
-
79
- </div>
80
- <div className="flex items-center mt-8 gap-3">
81
- <IconButton variant="filled" label="Rounded" icon={faPlus} shape="squared" width="narrow" />
82
- <IconButton variant="filled" label="Squared" icon={faPlus} shape="squared" width="default" />
83
- <IconButton variant="filled" label="Narrow" icon={faPlus} shape="squared" width="wide" />
84
- </div>
85
- </>
86
- `}
87
- scope={{ faPlus }}
88
- />
89
-
90
- ## States
91
-
92
- Use `disabled` to prevent user interaction
93
-
94
- <CodePreview
95
- client:load
96
- code={`
97
- <div className="flex items-center gap-3">
98
- <IconButton variant="filled" label="Disabled" icon={faPlus} disabled />
99
- </div>`}
100
- scope={{ faPlus }}
101
- />
102
-
103
- ## Toggle state
104
-
105
- Use \`onToggle\` and \`iconSelected\` to turn it into a toggle button.
106
-
107
- <CodePreview
108
- client:load
109
- code={`
110
- <div className="flex items-center gap-3">
111
- <IconButton
112
- label="Standard"
113
- icon={farStar}
114
- iconSelected={fasStar}
115
- onToggle={(active) => console.log('active:', active)}
116
- />
117
- <IconButton
118
- variant="filled"
119
- label="Filled"
120
- icon={farStar}
121
- iconSelected={fasStar}
122
- onToggle={(active) => console.log('active:', active)}
123
- />
124
- <IconButton
125
- variant="tonal"
126
- label="Tonal"
127
- icon={farStar}
128
- iconSelected={fasStar}
129
- onToggle={(active) => console.log('active:', active)}
130
- />
131
- <IconButton
132
- variant="outlined"
133
- label="Outlined"
134
- icon={farStar}
135
- iconSelected={fasStar}
136
- onToggle={(active) => console.log('active:', active)}
137
- />
138
- </div>
139
- `}
140
- scope={{ farStar, fasStar }}
141
- />
142
-
143
- ## Link or action
144
-
145
- If the `href` prop is provided, it renders an anchor; otherwise it renders a button.
146
-
147
- <CodePreview
148
- client:load
149
- code={`
150
- <div className="flex items-center gap-3">
151
- <IconButton label="Go to Udixio" icon={faPlus} href="https://udixio.dev" />
152
- <IconButton label="Run action" icon={faPlus} onClick={() => console.log('clicked')} />
153
- </div>`}
154
- scope={{ faPlus }}
155
- />
@@ -1,142 +0,0 @@
1
- ---
2
- ---
3
-
4
-
5
- import { CodePreview } from '@/components/CodePreview.js';
6
- import {
7
- faBell,
8
- faCalendarDays,
9
- faChartLine,
10
- faClock,
11
- faHourglass,
12
- faMusic,
13
- faPlus,
14
- faStopwatch
15
- } from '@fortawesome/free-solid-svg-icons';
16
-
17
- ## Usage
18
-
19
- NavigationRail provides primary navigation for an app. Use NavigationRail with NavigationRailItem children. Optionally include a Fab and sections.
20
-
21
- ```bash
22
- import { NavigationRail, NavigationRailItem, NavigationRailSection, Fab } from "@udixio/ui-react"
23
- ```
24
-
25
- ```tsx
26
- <NavigationRail>
27
- <NavigationRailItem icon={faBell} iconSelected={faBell} selected>
28
- Alarm
29
- </NavigationRailItem>
30
- <NavigationRailItem icon={faClock} iconSelected={faClock}>
31
- Clock
32
- </NavigationRailItem>
33
- <NavigationRailItem icon={faHourglass} iconSelected={faHourglass}>
34
- Timer
35
- </NavigationRailItem>
36
- <NavigationRailItem icon={faStopwatch} iconSelected={faStopwatch}>
37
- Stopwatch
38
- </NavigationRailItem>
39
- </NavigationRail>
40
- ```
41
-
42
- ## Alignment
43
-
44
- alignment: "top" (default) | "middle"
45
-
46
- <CodePreview
47
- center={false}
48
- client:load
49
- code={`<div class="h-[750px] flex gap-8">
50
- <NavigationRail className="bg-surface-container-highest" alignment="top">
51
- <NavigationRailItem icon={faBell} iconSelected={faBell} selected >Alarm</NavigationRailItem>
52
- <NavigationRailItem icon={faClock} iconSelected={faClock} >Clock</NavigationRailItem>
53
- <NavigationRailItem icon={faHourglass} iconSelected={faHourglass} >Timer</NavigationRailItem>
54
- <NavigationRailItem icon={faStopwatch} iconSelected={faStopwatch} >Stopwatch</NavigationRailItem>
55
- </NavigationRail>
56
- <NavigationRail className="bg-surface-container-highest" alignment="middle">
57
- <NavigationRailItem icon={faBell} iconSelected={faBell} label="Alarm" selected />
58
- <NavigationRailItem icon={faClock} iconSelected={faClock} label="Clock" />
59
- <NavigationRailItem icon={faHourglass} iconSelected={faHourglass} label="Timer" />
60
- <NavigationRailItem icon={faStopwatch} iconSelected={faStopwatch} label="Stopwatch" />
61
- </NavigationRail>
62
- </div>
63
- `}
64
- scope={{ faBell, faClock, faHourglass, faStopwatch, faPlus }}
65
- />
66
-
67
- ## Extended rail
68
-
69
- Toggle the extended mode to reveal labels and optional sections. You can control it with the `extended` and `onExtendedChange` props.
70
-
71
- <CodePreview
72
- center={false}
73
- client:load
74
- code={`
75
- function Example() {
76
- const [extended, setExtended] = React.useState(true)
77
- return (
78
- <NavigationRail className="bg-surface-container-highest h-[750px]" extended={extended}
79
-
80
- onExtendedChange={setExtended}>
81
-
82
- <Fab label="Add Timer" icon={faPlus} />
83
- <NavigationRailItem icon={faBell} iconSelected={faBell} label="Alarm" />
84
- <NavigationRailItem icon={faClock} iconSelected={faClock} label="Clock" />
85
- <NavigationRailItem icon={faHourglass} iconSelected={faHourglass} label="Timer" />
86
- <NavigationRailItem icon={faStopwatch} iconSelected={faStopwatch} label="Stopwatch" />
87
- <NavigationRailSection label="Sleep well" />
88
- <NavigationRailItem label="Schedule" icon={faCalendarDays} iconSelected={faCalendarDays} />
89
- <NavigationRailItem label="Stats" icon={faChartLine} iconSelected={faChartLine} />
90
- <NavigationRailItem label="Sleep sound" icon={faMusic} iconSelected={faMusic} />
91
- </NavigationRail>
92
- )
93
- }
94
- `}
95
- scope={{
96
- faBell,
97
- faClock,
98
- faHourglass,
99
- faStopwatch,
100
- faPlus,
101
- faCalendarDays,
102
- faChartLine,
103
- faMusic,
104
- }}
105
- />
106
-
107
- ## Controlled selection
108
-
109
- Use `selectedItem` and `setSelectedItem` to control the selected item. `onItemSelected` notifies with index, label, and icon.
110
-
111
- <CodePreview
112
- client:load
113
- center={false}
114
- code={`
115
- function Example() {
116
- const [index, setIndex] = React.useState(0)
117
- return (
118
- <NavigationRail className="bg-surface-container-highest h-[750px]" selectedItem={index} setSelectedItem={setIndex}>
119
- <Fab label="Add Timer" icon={faPlus} />
120
- <NavigationRailItem icon={faBell} iconSelected={faBell} label="Alarm" />
121
- <NavigationRailItem icon={faClock} iconSelected={faClock} label="Clock" />
122
- <NavigationRailItem icon={faHourglass} iconSelected={faHourglass} label="Timer" />
123
- <NavigationRailItem icon={faStopwatch} iconSelected={faStopwatch} label="Stopwatch" />
124
- <NavigationRailSection label="Sleep well" />
125
- <NavigationRailItem label="Schedule" icon={faCalendarDays} iconSelected={faCalendarDays} />
126
- <NavigationRailItem label="Stats" icon={faChartLine} iconSelected={faChartLine} />
127
- <NavigationRailItem label="Sleep sound" icon={faMusic} iconSelected={faMusic} />
128
- </NavigationRail>
129
- )
130
- }
131
- `}
132
- scope={{
133
- faBell,
134
- faClock,
135
- faHourglass,
136
- faStopwatch,
137
- faPlus,
138
- faCalendarDays,
139
- faChartLine,
140
- faMusic,
141
- }}
142
- />
@@ -1,49 +0,0 @@
1
- ---
2
- ---
3
-
4
- ## Usage
5
-
6
- Import ProgressIndicator to show operation progress.
7
-
8
- ```bash
9
- import { ProgressIndicator } from "@udixio/ui-react"
10
- ```
11
-
12
- ```tsx
13
- <ProgressIndicator variant="linear-determinate" value={40} />
14
- ```
15
-
16
- ## Variants
17
-
18
- - linear-determinate
19
- - ~~linear-indeterminate~~
20
- - ~~circular-determinate~~
21
- - circular-indeterminate
22
-
23
- ```jsx
24
- () => {
25
- const [value, setValue] = React.useState(0);
26
- const [resetKey, setResetKey] = React.useState(0);
27
-
28
- React.useEffect(() => {
29
- const interval = setInterval(() => {
30
- setValue((prev) => {
31
- const newValue = prev >= 10 ? 0 : prev + 3;
32
- // Si la valeur retourne à 0, on incrémente la clé de réinitialisation
33
- if (newValue === 0 && prev > 0) {
34
- setResetKey(prevKey => prevKey + 1);
35
- }
36
- return newValue;
37
- });
38
- }, 1500);
39
-
40
- return () => clearInterval(interval);
41
- }, []);
42
-
43
- return <div className="flex items-center gap-6">
44
- <ProgressIndicator transitionDuration={300} key={resetKey} variant="linear-determinate" value={value * 10} className="w-48" />
45
- <ProgressIndicator variant="circular-indeterminate" />
46
- </div>
47
- }
48
-
49
- ```
@@ -1,64 +0,0 @@
1
- ---
2
- ---
3
-
4
- ## Usage
5
-
6
- Use Slider for selecting a value or range along a track.
7
-
8
- ```bash
9
- import { Slider } from "@udixio/ui-react"
10
- ```
11
-
12
- ```tsx
13
- <Slider name="volume" value={30} step={5} />
14
- ```
15
-
16
- ## Step and marks
17
-
18
- - Provide `step` for incremental movement.
19
- - Or use `marks` to snap to labeled positions; omit `step` to only allow marks.
20
-
21
- ```jsx
22
- <div className="space-y-6">
23
- <Slider name="percent" value={50} step={10} />
24
- <Slider
25
- name="percent"
26
- value={25}
27
- step={null}
28
- marks={[
29
- { value: 0, label: '0' },
30
- { value: 25, label: '25' },
31
- { value: 50, label: '50' },
32
- { value: 75, label: '75' },
33
- { value: 100, label: '100' },
34
- ]}
35
- />
36
- </div>
37
- ```
38
-
39
- ## Min and max
40
-
41
- The slider supports finite and infinite ends. Use -Infinity/Infinity to make the first/last marks open ended.
42
-
43
- ```jsx
44
- <Slider
45
- name="range"
46
- value={0}
47
- min={-Infinity}
48
- max={Infinity}
49
- marks={[
50
- { value: -Infinity, label: 'Min' },
51
- { value: 0, label: '0' },
52
- { value: 100, label: '100' },
53
- { value: Infinity, label: 'Max' },
54
- ]}
55
- />
56
- ```
57
-
58
- ## Keyboard and change events
59
-
60
- The slider is focusable and responds to ArrowLeft/ArrowRight. Listen to `onChange` for value updates.
61
-
62
- ```jsx
63
- <Slider name="brightness" value={70} step={10} onChange={(v) => console.log('value', v)} />
64
- ```
@@ -1,37 +0,0 @@
1
- ---
2
- ---
3
-
4
-
5
-
6
- import { faCheck } from '@fortawesome/free-solid-svg-icons';
7
- import { CodePreview } from '@/components/CodePreview.js';
8
-
9
- ## Usage
10
-
11
- Snackbars display brief messages about app processes. They appear above other elements and disappear automatically.
12
-
13
- ```bash
14
- import { Snackbar } from "@udixio/ui-react"
15
- ```
16
-
17
- ```tsx
18
- <Snackbar message="Message sent" />
19
- ```
20
-
21
- ## Auto dismiss
22
-
23
- Use `duration` (ms) to auto-close the snackbar; pass `onClose` to be notified.
24
-
25
- ```jsx
26
- <Snackbar message="Saved" duration={3000} onClose={() => console.log('closed')} />
27
- ```
28
-
29
- ## Custom close icon
30
-
31
- Provide a custom FontAwesome icon via `closeIcon`.
32
-
33
- <CodePreview client:load
34
- code={`
35
- <Snackbar message="Done" closeIcon={faCheck} />
36
- `} scope={{ faCheck }}
37
- />
@@ -1,41 +0,0 @@
1
- ---
2
- ---
3
-
4
-
5
-
6
-
7
-
8
- import { CodePreview } from '@/components/CodePreview.js';
9
- import { faMoon, faSun } from '@fortawesome/free-solid-svg-icons';
10
-
11
- ## Usage
12
-
13
- Switch toggles a single setting on or off.
14
-
15
- ```bash
16
- import { Switch } from "@udixio/ui-react"
17
- ```
18
-
19
- ```tsx
20
- <Switch selected={false} onChange={(v) => console.log('selected:', v)} />
21
- ```
22
-
23
- ## With icons
24
-
25
- Provide `activeIcon` and/or `inactiveIcon` to display inside the thumb.
26
-
27
- <CodePreview client:load
28
- code={`
29
- <div className="flex items-center gap-6">
30
- <Switch selected inactiveIcon={faMoon} activeIcon={faSun} />
31
- <Switch inactiveIcon={faMoon} activeIcon={faSun} />
32
- </div>
33
- `}
34
- scope={{ faMoon, faSun }}
35
- />
36
-
37
- ## Disabled
38
-
39
- ```jsx
40
- <Switch disabled selected />
41
- ```
@@ -1,171 +0,0 @@
1
- ---
2
- ---
3
-
4
-
5
-
6
-
7
-
8
- import { CodePreview } from '@/components/CodePreview.js';
9
- import { faGear, faHome, faUser } from '@fortawesome/free-solid-svg-icons';
10
-
11
- ## Usage
12
-
13
- Tabs organize content across different views. Use Tabs with Tab children.
14
-
15
- ```bash
16
- import { Tabs, Tab } from "@udixio/ui-react"
17
- ```
18
-
19
- <CodePreview client:load
20
- code={`
21
- <Tabs>
22
- <Tab label="Home" icon={faHome} selected />
23
- <Tab label="Settings" icon={faGear} />
24
- <Tab label="Profile" icon={faUser} />
25
- </Tabs>
26
- `}
27
- scope={{ faHome, faGear, faUser }}
28
- />
29
-
30
- ## Variants
31
-
32
- - primary (default)
33
- - secondary
34
-
35
- ```jsx
36
- <div class={"space-y-2"}>
37
- <Tabs variant="primary">
38
- <Tab label="One" selected />
39
- <Tab label="Two" />
40
- </Tabs>
41
- <Tabs variant="secondary">
42
- <Tab label="One" selected/>
43
- <Tab label="Two" />
44
- </Tabs>
45
- </div>
46
-
47
- ```
48
-
49
- ## Controlled selection and scrollable
50
-
51
- Use `selectedTab` and `setSelectedTab` for controlled state. Set `scrollable` to true to enable horizontal scroll with automatic centering of the selected tab.
52
-
53
- ```jsx
54
- function Example() {
55
- const [tab, setTab] = React.useState(0)
56
- return (
57
- <Tabs selectedTab={tab} setSelectedTab={setTab} scrollable>
58
- <Tab label="Overview" />
59
- <Tab label="Activity" />
60
- <Tab label="Settings" />
61
- <Tab label="Billing" />
62
- <Tab label="Advanced" />
63
- </Tabs>
64
- )
65
- }
66
- ```
67
-
68
- ## Tab panels with TabGroup
69
-
70
- Use `TabGroup` to connect `Tabs` with `TabPanels`. This provides flexibility to place panels anywhere and includes a slide animation.
71
-
72
- ```bash
73
- import { TabGroup, Tabs, Tab, TabPanels, TabPanel } from "@udixio/ui-react"
74
- ```
75
-
76
- ```jsx
77
- <TabGroup defaultTab={0}>
78
- <Tabs>
79
- <Tab>Profile</Tab>
80
- <Tab>Settings</Tab>
81
- <Tab>Notifications</Tab>
82
- </Tabs>
83
- <TabPanels>
84
- <TabPanel>
85
- <div className="p-4">
86
- <h3 className="text-title-medium">Profile Content</h3>
87
- <p>This is the profile panel content.</p>
88
- </div>
89
- </TabPanel>
90
- <TabPanel>
91
- <div className="p-4">
92
- <h3 className="text-title-medium">Settings Content</h3>
93
- <p>Configure your preferences here.</p>
94
- </div>
95
- </TabPanel>
96
- <TabPanel>
97
- <div className="p-4">
98
- <h3 className="text-title-medium">Notifications</h3>
99
- <p>Manage your notification settings.</p>
100
- </div>
101
- </TabPanel>
102
- </TabPanels>
103
- </TabGroup>
104
- ```
105
-
106
- ## Flexible layout with TabGroup
107
-
108
- Since `TabGroup` uses context, you can place `Tabs` and `TabPanels` anywhere within the group.
109
-
110
- ```jsx
111
- <TabGroup>
112
- <div className="flex gap-4">
113
- <Tabs>
114
- <Tab>One</Tab>
115
- <Tab>Two</Tab>
116
- </Tabs>
117
- <div className="flex-1">
118
- <TabPanels>
119
- <TabPanel>Content for tab one</TabPanel>
120
- <TabPanel>Content for tab two</TabPanel>
121
- </TabPanels>
122
- </div>
123
- </div>
124
- </TabGroup>
125
- ```
126
-
127
- ## Controlled TabGroup
128
-
129
- Control the selected tab externally via `selectedTab` and `setSelectedTab` props on `TabGroup`.
130
-
131
- ```jsx
132
- function Example() {
133
- const [tab, setTab] = React.useState(0)
134
- return (
135
- <TabGroup selectedTab={tab} setSelectedTab={setTab}>
136
- <Tabs>
137
- <Tab>First</Tab>
138
- <Tab>Second</Tab>
139
- </Tabs>
140
- <TabPanels>
141
- <TabPanel>First panel</TabPanel>
142
- <TabPanel>Second panel</TabPanel>
143
- </TabPanels>
144
- </TabGroup>
145
- )
146
- }
147
- ```
148
-
149
- ## Children as label
150
-
151
- You can use `children` as an alternative to the `label` prop when providing a string.
152
-
153
- ```jsx
154
- <Tabs>
155
- <Tab selected>Home</Tab>
156
- <Tab>Settings</Tab>
157
- <Tab>Profile</Tab>
158
- </Tabs>
159
- ```
160
-
161
- ## Link or action
162
-
163
- If the `href` prop is provided on a Tab, it renders an `<a>` link; otherwise it renders a `<button>`.
164
-
165
- ```jsx
166
- <Tabs>
167
- <Tab label="Dashboard" selected />
168
- <Tab label="Documentation" href="/docs" />
169
- <Tab label="External" href="https://udixio.dev" />
170
- </Tabs>
171
- ```