flowbite-mcp 1.1.2 → 1.1.5

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 (72) hide show
  1. package/README.md +49 -74
  2. package/build/index.js +20 -36
  3. package/data/components/accordion.md +39 -53
  4. package/data/components/alerts.md +27 -44
  5. package/data/components/avatar.md +20 -33
  6. package/data/components/badge.md +34 -47
  7. package/data/components/banner.md +10 -29
  8. package/data/components/bottom-navigation.md +16 -29
  9. package/data/components/breadcrumb.md +12 -25
  10. package/data/components/button-group.md +26 -39
  11. package/data/components/buttons.md +41 -67
  12. package/data/components/card.md +34 -47
  13. package/data/components/carousel.md +25 -39
  14. package/data/components/chat-bubble.md +36 -50
  15. package/data/components/clipboard.md +256 -252
  16. package/data/components/datepicker.md +56 -70
  17. package/data/components/device-mockups.md +16 -29
  18. package/data/components/drawer.md +42 -56
  19. package/data/components/dropdowns.md +66 -80
  20. package/data/components/footer.md +16 -29
  21. package/data/components/forms.md +32 -50
  22. package/data/components/gallery.md +16 -33
  23. package/data/components/indicators.md +18 -31
  24. package/data/components/jumbotron.md +12 -25
  25. package/data/components/kbd.md +14 -27
  26. package/data/components/list-group.md +14 -27
  27. package/data/components/mega-menu.md +10 -24
  28. package/data/components/modal.md +37 -51
  29. package/data/components/navbar.md +41 -55
  30. package/data/components/pagination.md +22 -35
  31. package/data/components/popover.md +36 -51
  32. package/data/components/progress.md +10 -23
  33. package/data/components/qr-code.md +41 -133
  34. package/data/components/rating.md +16 -29
  35. package/data/components/sidebar.md +15 -30
  36. package/data/components/skeleton.md +16 -29
  37. package/data/components/speed-dial.md +40 -55
  38. package/data/components/spinner.md +14 -27
  39. package/data/components/stepper.md +14 -27
  40. package/data/components/tables.md +45 -64
  41. package/data/components/tabs.md +30 -45
  42. package/data/components/timeline.md +10 -23
  43. package/data/components/toast.md +25 -39
  44. package/data/components/tooltips.md +24 -39
  45. package/data/components/typography.md +22 -35
  46. package/data/components/video.md +14 -27
  47. package/data/forms/checkbox.md +27 -43
  48. package/data/forms/file-input.md +12 -26
  49. package/data/forms/floating-label.md +12 -25
  50. package/data/forms/input-field.md +17 -32
  51. package/data/forms/number-input.md +83 -93
  52. package/data/forms/phone-input.md +42 -54
  53. package/data/forms/radio.md +23 -39
  54. package/data/forms/range.md +12 -26
  55. package/data/forms/search-input.md +14 -31
  56. package/data/forms/select.md +15 -30
  57. package/data/forms/textarea.md +8 -21
  58. package/data/forms/timepicker.md +30 -42
  59. package/data/forms/toggle.md +18 -31
  60. package/data/plugins/charts.md +542 -526
  61. package/data/plugins/datatables.md +285 -286
  62. package/data/plugins/wysiwyg.md +658 -650
  63. package/data/quickstart.md +24 -24
  64. package/data/typography/blockquote.md +24 -37
  65. package/data/typography/headings.md +30 -43
  66. package/data/typography/hr.md +10 -23
  67. package/data/typography/images.md +32 -45
  68. package/data/typography/links.md +16 -29
  69. package/data/typography/lists.md +22 -35
  70. package/data/typography/paragraphs.md +30 -43
  71. package/data/typography/text.md +42 -55
  72. package/package.json +1 -1
@@ -1,17 +1,3 @@
1
- ---
2
- layout: docs
3
- title: Tailwind CSS Radio - Flowbite
4
- description: Get started with the radio component to let the user choose a single option from multiple options in the form of a circle based on multiple styles and colors
5
- group: forms
6
- toc: true
7
- requires_js: true
8
-
9
- previous: Checkbox
10
- previousLink: forms/checkbox/
11
- next: Toggle
12
- nextLink: forms/toggle/
13
- ---
14
-
15
1
  The radio component can be used to allow the user to choose a single option from one or more available options coded with the utility classes from Tailwind CSS and available in multiple styles, variants, and colors and support dark mode.
16
2
 
17
3
  Make sure that you have included Flowbite as a plugin inside your Tailwind CSS project to apply all the necessary styles for the radio component.
@@ -20,7 +6,7 @@ Make sure that you have included Flowbite as a plugin inside your Tailwind CSS p
20
6
 
21
7
  Use the default example of a radio component with the checked and unchecked state.
22
8
 
23
- {{< example github="forms/radio.md" show_dark=true >}}
9
+ ```html
24
10
  <div class="flex items-center mb-4">
25
11
  <input id="default-radio-1" type="radio" value="" name="default-radio" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
26
12
  <label for="default-radio-1" class="select-none ms-2 text-sm font-medium text-heading">Default radio</label>
@@ -29,13 +15,13 @@ Use the default example of a radio component with the checked and unchecked stat
29
15
  <input checked id="default-radio-2" type="radio" value="" name="default-radio" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
30
16
  <label for="default-radio-2" class="select-none ms-2 text-sm font-medium text-heading">Checked state</label>
31
17
  </div>
32
- {{< /example >}}
18
+ ```
33
19
 
34
20
  ## Disabled state
35
21
 
36
22
  Apply the `disabled` attribute to the radio component to disallow the selection for the user.
37
23
 
38
- {{< example github="forms/radio.md" show_dark=true >}}
24
+ ```html
39
25
  <div class="flex items-center mb-4">
40
26
  <input disabled id="disabled-radio-1" type="radio" value="" name="disabled-radio" class="w-4 h-4 text-neutral-primary border-light-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
41
27
  <label for="disabled-radio-1" class="select-none ms-2 text-sm font-medium text-fg-disabled">Disabled radio</label>
@@ -44,24 +30,24 @@ Apply the `disabled` attribute to the radio component to disallow the selection
44
30
  <input disabled checked id="disabled-radio-2" type="radio" value="" name="disabled-radio" class="w-4 h-4 text-neutral-primary border-light bg-neutral-secondary-medium rounded-full checked:border-default-medium focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
45
31
  <label for="disabled-radio-2" class="select-none ms-2 text-sm font-medium text-fg-disabled">Disabled checked</label>
46
32
  </div>
47
- {{< /example >}}
33
+ ```
48
34
 
49
35
  ## Radio link
50
36
 
51
37
  Use this example if you want to include an anchor tag inside the label of the radio component.
52
38
 
53
- {{< example github="forms/radio.md" show_dark=true >}}
39
+ ```html
54
40
  <div class="flex items-center">
55
41
  <input id="link-radio" type="radio" value="" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
56
42
  <label for="link-radio" class="select-none ms-2 text-sm font-medium text-heading">Radio button with a <a href="#" class="text-fg-brand hover:underline font-medium">link inside</a>.</label>
57
43
  </div>
58
- {{< /example >}}
44
+ ```
59
45
 
60
46
  ## Helper text
61
47
 
62
48
  Get started with this example if you want to add a secondary text to the label for the radio component.
63
49
 
64
- {{< example github="forms/radio.md" show_dark=true >}}
50
+ ```html
65
51
  <div class="flex">
66
52
  <div class="flex items-center h-5">
67
53
  <input id="helper-radio" aria-describedby="helper-radio-text" type="radio" value="" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
@@ -71,13 +57,13 @@ Get started with this example if you want to add a secondary text to the label f
71
57
  <p id="helper-radio-text" class="text-xs font-normal text-body">For orders shipped from $25 in books or $29 in other categories</p>
72
58
  </div>
73
59
  </div>
74
- {{< /example >}}
60
+ ```
75
61
 
76
62
  ## Bordered
77
63
 
78
64
  Use this example to show a radio input elements inside a card with border.
79
65
 
80
- {{< example class="grid gap-6 md:grid-cols-2" github="forms/radio.md" show_dark=true >}}
66
+ ```html
81
67
  <div class="flex items-center ps-4 border border-default bg-neutral-primary-soft rounded-base">
82
68
  <input id="bordered-radio-1" type="radio" value="" name="bordered-radio" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
83
69
  <label for="bordered-radio-1" class="w-full py-4 select-none ms-2 text-sm font-medium text-heading">Default radio</label>
@@ -86,13 +72,13 @@ Use this example to show a radio input elements inside a card with border.
86
72
  <input checked id="bordered-radio-2" type="radio" value="" name="bordered-radio" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
87
73
  <label for="bordered-radio-2" class="w-full py-4 select-none ms-2 text-sm font-medium text-heading">Checked state</label>
88
74
  </div>
89
- {{< /example >}}
75
+ ```
90
76
 
91
77
  ## Radio list group
92
78
 
93
79
  This example can be used to show a list of radio buttons inside a grouped list.
94
80
 
95
- {{< example github="components/radio.md" show_dark=true >}}
81
+ ```html
96
82
  <h3 class="mb-4 font-semibold text-heading">Identification</h3>
97
83
  <ul class="w-48 bg-neutral-primary-soft border border-default rounded-base">
98
84
  <li class="w-full border-b border-default">
@@ -120,13 +106,13 @@ This example can be used to show a list of radio buttons inside a grouped list.
120
106
  </div>
121
107
  </li>
122
108
  </ul>
123
- {{< /example >}}
109
+ ```
124
110
 
125
111
  ## Horizontal list group
126
112
 
127
113
  Use this example to group up radio button components inside a list.
128
114
 
129
- {{< example github="components/radio.md" show_dark=true >}}
115
+ ```html
130
116
  <h3 class="mb-4 font-semibold text-heading">Identification</h3>
131
117
  <ul class="items-center w-full text-sm font-medium text-heading bg-neutral-primary-soft border border-default rounded-lg sm:flex">
132
118
  <li class="w-full border-b border-default sm:border-b-0 sm:border-r">
@@ -154,17 +140,15 @@ Use this example to group up radio button components inside a list.
154
140
  </div>
155
141
  </li>
156
142
  </ul>
157
- {{< /example >}}
143
+ ```
144
+
158
145
 
159
- <div class="mt-8 -mb-5">
160
- {{< requires_js >}}
161
- </div>
162
146
 
163
147
  ## Radio in dropdown
164
148
 
165
149
  Here's an example of a list group that you can use right away.
166
150
 
167
- {{< example class="flex justify-center" github="components/radio.md" show_dark=true iframeHeight="370" >}}
151
+ ```html
168
152
  <button id="dropdownHelperRadioButton" data-dropdown-toggle="dropdownHelperRadio" class="inline-flex items-center justify-center text-white bg-brand box-border border border-transparent hover:bg-brand-strong focus:ring-4 focus:ring-brand-medium shadow-xs font-medium leading-5 rounded-base text-sm px-4 py-2.5 focus:outline-none" type="button">
169
153
  Dropdown button
170
154
  <svg class="w-4 h-4 ms-1.5 -me-0.5" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m19 9-7 7-7-7"/></svg>
@@ -214,13 +198,13 @@ Here's an example of a list group that you can use right away.
214
198
  </li>
215
199
  </ul>
216
200
  </div>
217
- {{< /example >}}
201
+ ```
218
202
 
219
203
  ## Inline layout
220
204
 
221
205
  Use the `flex` class for a wrapper element to horizontally align the radio elements.
222
206
 
223
- {{< example github="forms/radio.md" show_dark=true >}}
207
+ ```html
224
208
  <div class="flex">
225
209
  <div class="flex items-center me-4">
226
210
  <input id="inline-radio" type="radio" value="" name="inline-radio-group" class="w-4 h-4 text-neutral-primary border-default-medium bg-neutral-secondary-medium rounded-full checked:border-brand focus:ring-2 focus:outline-none focus:ring-brand-subtle border border-default appearance-none">
@@ -239,13 +223,13 @@ Use the `flex` class for a wrapper element to horizontally align the radio eleme
239
223
  <label for="inline-disabled-radio" class="select-none ms-2 text-sm font-medium text-fg-disabled">Inline disabled</label>
240
224
  </div>
241
225
  </div>
242
- {{< /example >}}
226
+ ```
243
227
 
244
228
  ## Advanced layout
245
229
 
246
230
  Use this example of a more advanced radio component to add more information and update the style of the whole card instead of just the circled dot.
247
231
 
248
- {{< example class="flex flex-wrap" github="forms/checkbox.md" show_dark=true >}}
232
+ ```html
249
233
  <h3 class="mb-5 text-lg font-medium text-gray-900 dark:text-white">How much do you expect to use each month?</h3>
250
234
  <ul class="grid w-full gap-6 md:grid-cols-2">
251
235
  <li>
@@ -270,13 +254,13 @@ Use this example of a more advanced radio component to add more information and
270
254
  </li>
271
255
  </ul>
272
256
 
273
- {{< /example >}}
257
+ ```
274
258
 
275
259
  ## Advanced layout with icons
276
260
 
277
261
  Use this example to show an advanced layout of radio button elements with icons.
278
262
 
279
- {{< example class="flex flex-wrap" github="forms/checkbox.md" show_dark=true >}}
263
+ ```html
280
264
  <h3 class="mb-4 text-lg font-medium text-heading">Choose technology:</h3>
281
265
  <ul class="select-none grid w-full gap-4 md:grid-cols-3">
282
266
  <li>
@@ -311,5 +295,5 @@ Use this example to show an advanced layout of radio button elements with icons.
311
295
  </li>
312
296
  </ul>
313
297
 
314
- {{< /example >}}
298
+ ```
315
299
 
@@ -1,17 +1,3 @@
1
- ---
2
- layout: docs
3
- title: Tailwind CSS Range Slider - Flowbite
4
- description: Get started with the range component to receive a number from the user anywhere from 1 to 100 by sliding form control horizontally based on multiple options
5
- group: forms
6
- toc: true
7
- requires_js: true
8
-
9
- previous: Toggle
10
- previousLink: forms/toggle/
11
- next: Floating Label
12
- nextLink: forms/floating-label/
13
- ---
14
-
15
1
  The range component can be used as an input field to get a number from the user based on your custom selection (ie. from 1 to 100) by using a sliding animation.
16
2
 
17
3
  The examples on this page are all coded with Tailwind CSS and requires you to install Flowbite as a plugin inside your project to obtain all the necessary stylings.
@@ -20,43 +6,43 @@ The examples on this page are all coded with Tailwind CSS and requires you to in
20
6
 
21
7
  Get started with this default example with values from 1 to 100 and the default value of 50.
22
8
 
23
- {{< example github="forms/range.md" show_dark=true >}}
9
+ ```html
24
10
  <label for="default-range" class="block mb-2.5 text-sm font-medium text-heading">Default range</label>
25
11
  <input id="default-range" type="range" value="50" class="w-full h-2 bg-neutral-quaternary rounded-full appearance-none cursor-pointer">
26
- {{< /example >}}
12
+ ```
27
13
 
28
14
  ## Disabled state
29
15
 
30
16
  Apply the `disabled` class to disallow the users from further selecting values.
31
17
 
32
- {{< example github="forms/range.md" show_dark=true >}}
18
+ ```html
33
19
  <label for="disabled-range" class="block mb-2.5 text-sm font-medium text-heading">Default range</label>
34
20
  <input id="disabled-range" type="range" value="50" class="w-full h-2 bg-neutral-quaternary rounded-full appearance-none cursor-pointer" disabled>
35
- {{< /example >}}
21
+ ```
36
22
 
37
23
  ## Min and max
38
24
 
39
25
  Use the min and max attributes on the range component to set the limits of the range values.
40
26
 
41
- {{< example github="forms/range.md" show_dark=true >}}
27
+ ```html
42
28
  <label for="minmax-range" class="block mb-2.5 text-sm font-medium text-heading">Min-max range</label>
43
29
  <input id="minmax-range" type="range" min="0" max="10" value="5" class="w-full h-2 bg-neutral-quaternary rounded-full appearance-none cursor-pointer">
44
- {{< /example >}}
30
+ ```
45
31
 
46
32
  ## Steps
47
33
 
48
34
  Use the step attribute on the range component to set the increment with which the values will change.
49
35
 
50
- {{< example github="forms/range.md" show_dark=true >}}
36
+ ```html
51
37
  <label for="steps-range" class="block mb-2.5 text-sm font-medium text-heading">Range steps</label>
52
38
  <input id="steps-range" type="range" min="0" max="5" value="2.5" step="0.5" class="w-full h-2 bg-neutral-quaternary rounded-full appearance-none cursor-pointer">
53
- {{< /example >}}
39
+ ```
54
40
 
55
41
  ## Sizes
56
42
 
57
43
  Apply the small, default, and large sizes for the range component by applying the `range-sm` and `range-lg` utility classes from Flowbite and Tailwind CSS.
58
44
 
59
- {{< example github="forms/range.md" show_dark=true >}}
45
+ ```html
60
46
  <label for="small-range" class="block mb-2.5 text-sm font-medium text-heading">Small range</label>
61
47
  <input id="small-range" type="range" value="50" class="w-full h-1 mb-6 bg-neutral-quaternary rounded-full appearance-none cursor-pointer range-sm">
62
48
 
@@ -65,13 +51,13 @@ Apply the small, default, and large sizes for the range component by applying th
65
51
 
66
52
  <label for="large-range" class="block mb-2.5 text-sm font-medium text-heading">Large range</label>
67
53
  <input id="large-range" type="range" value="50" class="w-full h-3 bg-neutral-quaternary rounded-full appearance-none cursor-pointer range-lg">
68
- {{< /example >}}
54
+ ```
69
55
 
70
56
  ## Labels
71
57
 
72
58
  Use the following example to add labels to each value milestone of the range slider component.
73
59
 
74
- {{< example github="forms/range.md" show_dark=true >}}
60
+ ```html
75
61
  <div class="relative mb-6">
76
62
  <label for="labels-range-input" class="sr-only">Labels range</label>
77
63
  <input id="labels-range-input" type="range" value="1000" min="100" max="1500" class="w-full h-2 bg-neutral-quaternary rounded-full appearance-none cursor-pointer">
@@ -80,4 +66,4 @@ Use the following example to add labels to each value milestone of the range sli
80
66
  <span class="text-sm text-body absolute start-2/3 -translate-x-1/2 rtl:translate-x-1/2 -bottom-6">$1000</span>
81
67
  <span class="text-sm text-body absolute end-0 -bottom-6">Max ($1500)</span>
82
68
  </div>
83
- {{< /example >}}
69
+ ```
@@ -1,16 +1,3 @@
1
- ---
2
- layout: docs
3
- title: Tailwind CSS Search Input - Flowbite
4
- description: Use the search input component as a text field to allow users to enter search queries and receive relevant page results available in multiple styles and sizes
5
- group: forms
6
- toc: true
7
-
8
- previous: File Input
9
- previousLink: forms/file-input/
10
- next: Number Input
11
- nextLink: forms/number-input/
12
- ---
13
-
14
1
  The search input component can be used to let your users search through your website using string queries and it comes in multiple styles, variants, and sizes built with the utility classes from Tailwind CSS.
15
2
 
16
3
  You will also find more advanced search components on this page including dropdown category selections, search buttons positioned inside the input field, voice search fields and more.
@@ -19,7 +6,7 @@ You will also find more advanced search components on this page including dropdo
19
6
 
20
7
  Get started with the default example of a search input component including and icon and submit button.
21
8
 
22
- {{< example github="forms/search-input.md" show_dark=true >}}
9
+ ```html
23
10
  <form class="max-w-md mx-auto">
24
11
  <label for="search" class="block mb-2.5 text-sm font-medium text-heading sr-only ">Search</label>
25
12
  <div class="relative">
@@ -30,17 +17,15 @@ Get started with the default example of a search input component including and i
30
17
  <button type="button" class="absolute end-1.5 bottom-1.5 text-white bg-brand hover:bg-brand-strong box-border border border-transparent focus:ring-4 focus:ring-brand-medium shadow-xs font-medium leading-5 rounded text-xs px-3 py-1.5 focus:outline-none">Search</button>
31
18
  </div>
32
19
  </form>
33
- {{< /example >}}
20
+ ```
21
+
34
22
 
35
- <div class="mt-8 -mb-5">
36
- {{< requires_js >}}
37
- </div>
38
23
 
39
24
  ## Search with dropdown
40
25
 
41
26
  Use this search component with a dropdown to let your users select a category in which they would like the search query to be targeted in.
42
27
 
43
- {{< example github="forms/search-input.md" show_dark=true iframeHeight="290" >}}
28
+ ```html
44
29
  <form class="max-w-2xl mx-auto">
45
30
  <div class="flex shadow-xs rounded-base -space-x-0.5">
46
31
  <label for="search-dropdown" class="block mb-2.5 text-sm font-medium text-heading sr-only ">Your Email</label>
@@ -72,13 +57,13 @@ Use this search component with a dropdown to let your users select a category in
72
57
  </button>
73
58
  </div>
74
59
  </form>
75
- {{< /example >}}
60
+ ```
76
61
 
77
62
  ## Simple search input
78
63
 
79
64
  Use the simplest form of a search input component with an icon and a search button next to the text field.
80
65
 
81
- {{< example github="forms/search-input.md" show_dark=true >}}
66
+ ```html
82
67
  <form class="flex items-center max-w-sm mx-auto space-x-2">
83
68
  <label for="simple-search" class="sr-only">Search</label>
84
69
  <div class="relative w-full">
@@ -92,17 +77,15 @@ Use the simplest form of a search input component with an icon and a search butt
92
77
  <span class="sr-only">Icon description</span>
93
78
  </button>
94
79
  </form>
95
- {{< /example >}}
80
+ ```
81
+
96
82
 
97
- <div class="mt-8 -mb-5">
98
- {{< requires_js >}}
99
- </div>
100
83
 
101
84
  ## Location search
102
85
 
103
86
  Use this example where you can select a country in which you want to search for an address or city.
104
87
 
105
- {{< example github="forms/search-input.md" show_dark=true iframeHeight="290" >}}
88
+ ```html
106
89
  <form class="max-w-lg mx-auto">
107
90
  <div class="flex shadow-xs rounded-base -space-x-0.5">
108
91
  <label for="search-dropdown-location" class="block mb-2.5 text-sm font-medium text-heading sr-only ">Choose city</label>
@@ -198,13 +181,13 @@ Use this example where you can select a country in which you want to search for
198
181
  </button>
199
182
  </div>
200
183
  </form>
201
- {{< /example >}}
184
+ ```
202
185
 
203
186
  ## Voice search
204
187
 
205
188
  Get started with this example if you would like to enable voice search for your website and users.
206
189
 
207
- {{< example github="forms/search-input.md" show_dark=true >}}
190
+ ```html
208
191
  <form class="flex items-center max-w-lg mx-auto space-x-2">
209
192
  <label for="voice-search" class="sr-only">Search</label>
210
193
  <div class="relative w-full">
@@ -221,13 +204,13 @@ Get started with this example if you would like to enable voice search for your
221
204
  Search
222
205
  </button>
223
206
  </form>
224
- {{< /example >}}
207
+ ```
225
208
 
226
209
  ## Advanced search input
227
210
 
228
211
  Use this example to show multiple dropdown selection elements next to the search field.
229
212
 
230
- {{< example github="forms/search-input.md" show_dark=true iframeHeight="290" >}}
213
+ ```html
231
214
 
232
215
  <form class="max-w-2xl mx-auto">
233
216
  <div class="flex shadow-xs rounded-base -space-x-0.5">
@@ -277,4 +260,4 @@ Use this example to show multiple dropdown selection elements next to the search
277
260
  </div>
278
261
  </form>
279
262
 
280
- {{< /example >}}
263
+ ```
@@ -1,23 +1,10 @@
1
- ---
2
- layout: docs
3
- title: Tailwind CSS Select - Flowbite
4
- description: Get started with the select component to allow the user to choose from one or more options from a dropdown list based on multiple styles, sizes, and variants
5
- group: forms
6
- toc: true
7
-
8
- previous: Phone Input
9
- previousLink: forms/phone-input/
10
- next: Textarea
11
- nextLink: forms/textarea/
12
- ---
13
-
14
1
  The select input component can be used to gather information from users based on multiple options in the form of a dropdown list and by browsing this page you will find multiple options, styles, sizes, and variants built with the utility classes from Tailwind CSS also available in dark mode.
15
2
 
16
3
  ## Select input example
17
4
 
18
5
  Get started with the default example of a select input component to get a single option selection.
19
6
 
20
- {{< example github="forms/select.md" show_dark=true >}}
7
+ ```html
21
8
  <form class="max-w-sm mx-auto">
22
9
  <label for="countries" class="block mb-2.5 text-sm font-medium text-heading">Select an option</label>
23
10
  <select id="countries" class="block w-full px-3 py-2.5 bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand shadow-xs placeholder:text-body">
@@ -28,13 +15,13 @@ Get started with the default example of a select input component to get a single
28
15
  <option value="DE">Germany</option>
29
16
  </select>
30
17
  </form>
31
- {{< /example >}}
18
+ ```
32
19
 
33
20
  ## Multiple options
34
21
 
35
22
  Apply the `multiple` attribute to the select component to allow users to select one or more options.
36
23
 
37
- {{< example github="forms/select.md" show_dark=true >}}
24
+ ```html
38
25
  <form class="max-w-sm mx-auto">
39
26
  <label for="countries_multiple" class="block mb-2.5 text-sm font-medium text-heading">Select an option</label>
40
27
  <select multiple id="countries_multiple" class="block w-full bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand px-3 py-2.5 shadow-xs placeholder:text-body">
@@ -45,13 +32,13 @@ Apply the `multiple` attribute to the select component to allow users to select
45
32
  <option value="DE">Germany</option>
46
33
  </select>
47
34
  </form>
48
- {{< /example >}}
35
+ ```
49
36
 
50
37
  ## Size attribute
51
38
 
52
39
  Use the size attribute for the select component to specify the number of visible options in the list.
53
40
 
54
- {{< example github="forms/select.md" show_dark=true >}}
41
+ ```html
55
42
  <form class="max-w-sm mx-auto">
56
43
  <label for="years" class="block mb-2.5 text-sm font-medium text-heading">Select an option</label>
57
44
  <select id="years" size="5" class="block w-full bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand px-3 py-2.5 shadow-xs placeholder:text-body">
@@ -64,13 +51,13 @@ Use the size attribute for the select component to specify the number of visible
64
51
  <option>2022</option>
65
52
  </select>
66
53
  </form>
67
- {{< /example >}}
54
+ ```
68
55
 
69
56
  ## Disabled state
70
57
 
71
58
  Apply the `disable` state to the select component to disallow the selection of new options.
72
59
 
73
- {{< example github="forms/select.md" show_dark=true >}}
60
+ ```html
74
61
  <form class="max-w-sm mx-auto">
75
62
  <label for="countries_disabled" class="block mb-2.5 text-sm font-medium text-heading">Select an option</label>
76
63
  <select disabled id="countries_disabled" class="block w-full bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand px-3 py-2.5 shadow-xs text-fg-disabled">
@@ -81,13 +68,13 @@ Apply the `disable` state to the select component to disallow the selection of n
81
68
  <option value="DE">Germany</option>
82
69
  </select>
83
70
  </form>
84
- {{< /example >}}
71
+ ```
85
72
 
86
73
  ## Underline select
87
74
 
88
75
  Use the underline style for the select component as an alternative appearance.
89
76
 
90
- {{< example github="forms/select.md" show_dark=true >}}
77
+ ```html
91
78
  <form class="max-w-sm mx-auto">
92
79
  <label for="underline_select" class="sr-only">Underline select</label>
93
80
  <select id="underline_select" class="block py-2.5 ps-0 w-full text-sm text-body bg-transparent border-0 border-b-2 border-default-medium appearance-none focus:outline-none focus:ring-0 focus:border-brand peer">
@@ -98,17 +85,15 @@ Use the underline style for the select component as an alternative appearance.
98
85
  <option value="DE">Germany</option>
99
86
  </select>
100
87
  </form>
101
- {{< /example >}}
88
+ ```
89
+
102
90
 
103
- <div class="mt-8 -mb-5">
104
- {{< requires_js >}}
105
- </div>
106
91
 
107
92
  ## Select with dropdown
108
93
 
109
94
  Use this example if you want to create a multi-level dropdown and select component combination.
110
95
 
111
- {{< example github="forms/select.md" show_dark=true iframeHeight="340" >}}
96
+ ```html
112
97
  <form class="max-w-sm mx-auto">
113
98
  <div class="flex">
114
99
  <button id="dropdown-states-button" data-dropdown-toggle="dropdown-states" type="button" class="inline-flex items-center shrink-0 z-10 text-body bg-neutral-secondary-medium box-border border border-default-medium hover:bg-neutral-tertiary-medium hover:text-fg-brand focus:ring-4 focus:ring-neutral-tertiary font-medium leading-5 rounded-s-base text-sm px-4 py-2.5 focus:outline-none">
@@ -215,13 +200,13 @@ Use this example if you want to create a multi-level dropdown and select compone
215
200
  </select>
216
201
  </div>
217
202
  </form>
218
- {{< /example >}}
203
+ ```
219
204
 
220
205
  ## Sizes
221
206
 
222
207
  Get started with the small, default, and large sizes for the select component from the example below.
223
208
 
224
- {{< example github="forms/select.md" show_dark=true >}}
209
+ ```html
225
210
  <form class="max-w-sm mx-auto">
226
211
  <label for="small" class="block mb-2.5 text-sm font-medium text-heading">Small select</label>
227
212
  <select id="small" class="block w-full px-3 py-2.5 bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand shadow-xs placeholder:text-body mb-4">
@@ -256,4 +241,4 @@ Get started with the small, default, and large sizes for the select component fr
256
241
  <option value="DE">Germany</option>
257
242
  </select>
258
243
  </form>
259
- {{< /example >}}
244
+ ```
@@ -1,16 +1,3 @@
1
- ---
2
- layout: docs
3
- title: Tailwind CSS Textarea - Flowbite
4
- description: Use the textarea component as a multi-line text field input and use it inside form elements available in multiple sizes, styles, and variants
5
- group: forms
6
- toc: true
7
-
8
- previous: Select
9
- previousLink: forms/select/
10
- next: Timepicker
11
- nextLink: forms/timepicker/
12
- ---
13
-
14
1
  The textarea component is a multi-line text field input that can be used to receive longer chunks of text from the user in the form of a comment box, description field, and more.
15
2
 
16
3
  From the examples on this page you will find multiple styles and variants of the textarea component coded with the utility classes from Tailwind CSS including a WYSIWYG editor, comment box, chatroom textarea, all available in dark mode as well.
@@ -19,16 +6,16 @@ From the examples on this page you will find multiple styles and variants of the
19
6
 
20
7
  Get started with the default example of a textarea component below.
21
8
 
22
- {{< example github="forms/textarea.md" show_dark=true >}}
9
+ ```html
23
10
  <label for="message" class="block mb-2.5 text-sm font-medium text-heading">Your message</label>
24
11
  <textarea id="message" rows="4" class="bg-neutral-secondary-medium border border-default-medium text-heading text-sm rounded-base focus:ring-brand focus:border-brand block w-full p-3.5 shadow-xs placeholder:text-body" placeholder="Write your thoughts here..."></textarea>
25
- {{< /example >}}
12
+ ```
26
13
 
27
14
  ## WYSIWYG Editor
28
15
 
29
16
  If you want to add other actions as buttons alongside your textarea component, such as with a WYSIWYG editor, then you can use the example below.
30
17
 
31
- {{< example github="forms/textarea.md" show_dark=true >}}
18
+ ```html
32
19
  <form>
33
20
  <div class="w-full mb-4 border border-default-medium rounded-base bg-neutral-secondary-medium shadow-xs">
34
21
  <div class="flex items-center justify-between px-3 py-2 border-b border-default-medium">
@@ -90,13 +77,13 @@ If you want to add other actions as buttons alongside your textarea component, s
90
77
  </div>
91
78
  <button type="submit" class="text-white bg-brand box-border border border-transparent hover:bg-brand-strong focus:ring-4 focus:ring-brand-medium shadow-xs font-medium leading-5 rounded-base text-sm px-4 py-2.5 focus:outline-none">Publish post</button>
92
79
  </form>
93
- {{< /example >}}
80
+ ```
94
81
 
95
82
  ## Comment box
96
83
 
97
84
  Most often the textarea component is used as the main text field input element in comment sections. Use this example to also apply a helper text and buttons below the textarea itself.
98
85
 
99
- {{< example github="forms/textarea.md" show_dark=true >}}
86
+ ```html
100
87
  <form>
101
88
  <div class="w-full mb-4 border border-default-medium rounded-base bg-neutral-secondary-medium shadow-xs">
102
89
  <div class="px-4 py-2 bg-neutral-secondary-medium rounded-t-base">
@@ -127,13 +114,13 @@ Most often the textarea component is used as the main text field input element i
127
114
  </div>
128
115
  </form>
129
116
  <p class="ms-auto text-xs text-body">Remember, contributions to this topic should follow our <a href="#" class="text-fg-brand hover:underline">Community Guidelines</a>.</p>
130
- {{< /example >}}
117
+ ```
131
118
 
132
119
  ## Chatroom input
133
120
 
134
121
  If you want to build a chatroom component you will usually want to use a textarea element to allow users to write multi-line chunks of text.
135
122
 
136
- {{< example github="forms/textarea.md" show_dark=true >}}
123
+ ```html
137
124
  <form>
138
125
  <label for="chat" class="sr-only">Your message</label>
139
126
  <div class="flex items-center px-3 py-2 rounded-base bg-neutral-secondary-soft">
@@ -152,4 +139,4 @@ If you want to build a chatroom component you will usually want to use a textare
152
139
  </button>
153
140
  </div>
154
141
  </form>
155
- {{< /example >}}
142
+ ```