@tabler/core 1.1.0 → 1.1.1

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 (145) hide show
  1. package/docs/emails/index.mdx +14 -0
  2. package/docs/emails/introduction/compiled-html.mdx +29 -0
  3. package/docs/emails/introduction/contents.mdx +63 -0
  4. package/docs/emails/introduction/index.mdx +9 -0
  5. package/docs/emails/introduction/source-html.mdx +26 -0
  6. package/docs/icons/index.mdx +13 -0
  7. package/docs/icons/libraries/index.mdx +5 -0
  8. package/docs/icons/libraries/preact.mdx +42 -0
  9. package/docs/icons/libraries/react.mdx +42 -0
  10. package/docs/icons/libraries/solidjs.mdx +42 -0
  11. package/docs/icons/libraries/svelte.mdx +43 -0
  12. package/docs/icons/libraries/vue.mdx +50 -0
  13. package/docs/icons/libraries/webfont.mdx +60 -0
  14. package/docs/icons/plugins/figma.mdx +15 -0
  15. package/docs/icons/plugins/index.mdx +4 -0
  16. package/docs/icons/static-files/eps.mdx +15 -0
  17. package/docs/icons/static-files/index.mdx +5 -0
  18. package/docs/icons/static-files/pdf.mdx +15 -0
  19. package/docs/icons/static-files/png.mdx +31 -0
  20. package/docs/icons/static-files/svg.mdx +85 -0
  21. package/docs/illustrations/index.mdx +8 -0
  22. package/docs/illustrations/introduction/contents.mdx +77 -0
  23. package/docs/illustrations/introduction/customization.mdx +1198 -0
  24. package/docs/illustrations/introduction/index.mdx +5 -0
  25. package/docs/illustrations/introduction/license.mdx +90 -0
  26. package/docs/img/browsers/brave.svg +1 -0
  27. package/docs/img/browsers/chrome.svg +1 -0
  28. package/docs/img/browsers/edge.svg +1 -0
  29. package/docs/img/browsers/electron.svg +1 -0
  30. package/docs/img/browsers/firefox.svg +1 -0
  31. package/docs/img/browsers/internet-explorer.svg +1 -0
  32. package/docs/img/browsers/opera.svg +1 -0
  33. package/docs/img/browsers/safari.svg +1 -0
  34. package/docs/img/browsers/vivaldi.svg +1 -0
  35. package/docs/img/cover-illustrations-dark.png +0 -0
  36. package/docs/img/cover-illustrations.png +0 -0
  37. package/docs/img/cover-tabler-dark.png +0 -0
  38. package/docs/img/cover-tabler.png +0 -0
  39. package/docs/img/icons/figma-plugin.png +0 -0
  40. package/docs/img/icons/package-angular-dark.png +0 -0
  41. package/docs/img/icons/package-angular.png +0 -0
  42. package/docs/img/icons/package-eps-dark.png +0 -0
  43. package/docs/img/icons/package-eps.png +0 -0
  44. package/docs/img/icons/package-js-dark.png +0 -0
  45. package/docs/img/icons/package-js.png +0 -0
  46. package/docs/img/icons/package-pdf-dark.png +0 -0
  47. package/docs/img/icons/package-pdf.png +0 -0
  48. package/docs/img/icons/package-png-dark.png +0 -0
  49. package/docs/img/icons/package-png.png +0 -0
  50. package/docs/img/icons/package-preact-dark.png +0 -0
  51. package/docs/img/icons/package-preact.png +0 -0
  52. package/docs/img/icons/package-react-dark.png +0 -0
  53. package/docs/img/icons/package-react-native-dark.png +0 -0
  54. package/docs/img/icons/package-react-native.png +0 -0
  55. package/docs/img/icons/package-react.png +0 -0
  56. package/docs/img/icons/package-solidjs-dark.png +0 -0
  57. package/docs/img/icons/package-solidjs.png +0 -0
  58. package/docs/img/icons/package-sprite-dark.png +0 -0
  59. package/docs/img/icons/package-sprite.png +0 -0
  60. package/docs/img/icons/package-svelte-dark.png +0 -0
  61. package/docs/img/icons/package-svelte.png +0 -0
  62. package/docs/img/icons/package-svg-dark.png +0 -0
  63. package/docs/img/icons/package-svg.png +0 -0
  64. package/docs/img/icons/package-vue-dark.png +0 -0
  65. package/docs/img/icons/package-vue.png +0 -0
  66. package/docs/img/icons/package-webfont-dark.png +0 -0
  67. package/docs/img/icons/package-webfont.png +0 -0
  68. package/docs/index.mdx +16 -0
  69. package/docs/ui/base/colors.mdx +83 -0
  70. package/docs/ui/base/index.mdx +6 -0
  71. package/docs/ui/base/typography.mdx +311 -0
  72. package/docs/ui/components/alerts.mdx +406 -0
  73. package/docs/ui/components/autosize.mdx +25 -0
  74. package/docs/ui/components/avatars.mdx +227 -0
  75. package/docs/ui/components/badges.mdx +112 -0
  76. package/docs/ui/components/breadcrumb.mdx +199 -0
  77. package/docs/ui/components/buttons.mdx +1213 -0
  78. package/docs/ui/components/cards.mdx +417 -0
  79. package/docs/ui/components/carousel.mdx +459 -0
  80. package/docs/ui/components/charts.mdx +697 -0
  81. package/docs/ui/components/countup.mdx +165 -0
  82. package/docs/ui/components/datagrid.mdx +120 -0
  83. package/docs/ui/components/divider.mdx +68 -0
  84. package/docs/ui/components/dropdowns.mdx +302 -0
  85. package/docs/ui/components/dropzone.mdx +88 -0
  86. package/docs/ui/components/empty.mdx +149 -0
  87. package/docs/ui/components/icons.mdx +392 -0
  88. package/docs/ui/components/index.mdx +6 -0
  89. package/docs/ui/components/inline-player.mdx +58 -0
  90. package/docs/ui/components/modals.mdx +297 -0
  91. package/docs/ui/components/offcanvas.mdx +70 -0
  92. package/docs/ui/components/placeholder.mdx +273 -0
  93. package/docs/ui/components/popover.mdx +142 -0
  94. package/docs/ui/components/progress.mdx +241 -0
  95. package/docs/ui/components/range-slider.mdx +32 -0
  96. package/docs/ui/components/ribbons.mdx +207 -0
  97. package/docs/ui/components/segmented-control.mdx +401 -0
  98. package/docs/ui/components/spinners.mdx +135 -0
  99. package/docs/ui/components/statuses.mdx +322 -0
  100. package/docs/ui/components/steps.mdx +174 -0
  101. package/docs/ui/components/switch-icon.mdx +386 -0
  102. package/docs/ui/components/tables.mdx +397 -0
  103. package/docs/ui/components/tabs.mdx +396 -0
  104. package/docs/ui/components/timelines.mdx +697 -0
  105. package/docs/ui/components/tinymce.mdx +46 -0
  106. package/docs/ui/components/toasts.mdx +126 -0
  107. package/docs/ui/components/tooltips.mdx +65 -0
  108. package/docs/ui/components/tracking.mdx +548 -0
  109. package/docs/ui/components/vector-maps.mdx +166 -0
  110. package/docs/ui/forms/form-color-check.mdx +220 -0
  111. package/docs/ui/forms/form-elements.mdx +632 -0
  112. package/docs/ui/forms/form-fieldset.mdx +45 -0
  113. package/docs/ui/forms/form-helpers.mdx +91 -0
  114. package/docs/ui/forms/form-image-check.mdx +213 -0
  115. package/docs/ui/forms/form-input-mask.mdx +61 -0
  116. package/docs/ui/forms/form-selectboxes.mdx +398 -0
  117. package/docs/ui/forms/form-validation.mdx +62 -0
  118. package/docs/ui/forms/index.mdx +6 -0
  119. package/docs/ui/getting-started/browser-support.mdx +28 -0
  120. package/docs/ui/getting-started/customize.mdx +28 -0
  121. package/docs/ui/getting-started/download.mdx +44 -0
  122. package/docs/ui/getting-started/faq.mdx +30 -0
  123. package/docs/ui/getting-started/how-to-contribute.mdx +84 -0
  124. package/docs/ui/getting-started/index.mdx +16 -0
  125. package/docs/ui/getting-started/installation.mdx +67 -0
  126. package/docs/ui/getting-started/license.mdx +30 -0
  127. package/docs/ui/index.mdx +8 -0
  128. package/docs/ui/layout/index.mdx +6 -0
  129. package/docs/ui/layout/navbars.mdx +164 -0
  130. package/docs/ui/layout/navs-tabls.mdx +201 -0
  131. package/docs/ui/layout/page-headers.mdx +365 -0
  132. package/docs/ui/layout/page-layouts.mdx +213 -0
  133. package/docs/ui/plugins/flags.mdx +316 -0
  134. package/docs/ui/plugins/index.mdx +6 -0
  135. package/docs/ui/plugins/payments.mdx +152 -0
  136. package/docs/ui/plugins/social-icons.mdx +135 -0
  137. package/docs/ui/utilities/borders.mdx +260 -0
  138. package/docs/ui/utilities/cursors.mdx +63 -0
  139. package/docs/ui/utilities/index.mdx +5 -0
  140. package/docs/ui/utilities/interactions.mdx +26 -0
  141. package/docs/ui/utilities/margins.mdx +234 -0
  142. package/docs/ui/utilities/vertical-align.mdx +66 -0
  143. package/docs/ui/utilities/visually-hidden.mdx +12 -0
  144. package/package.json +6 -6
  145. package/LICENSE +0 -21
@@ -0,0 +1,406 @@
1
+ ---
2
+ title: Alerts
3
+ summary: Alert messages are used to inform users of the status of their action and help them solve any problems that might have occurred. Good design of alert modals is very important for the overall user experience of a website or app.
4
+ bootstrapLink: components/alerts/
5
+ description: Alert messages for user notifications.
6
+ ---
7
+
8
+ ## Default markup
9
+
10
+ Depending on the information you need to convey, you can use one of the following types of alert messages - **success**, **info**, **warning** or **danger**. Using the right type of alert modal will help draw users' attention to the message and prompt them to take action.
11
+
12
+ Combine `alert` class with one of the following: `alert-success`, `alert-info`, `alert-warning`, `alert-danger` to get the alert that you need.
13
+
14
+ Alert classes affect the color of all the text inside an alert. Use another class, e.g. `text-secondary` to change the color of the alert's content.
15
+
16
+ ```html example vertical background="surface" columns={2} centered separated height="420px"
17
+ <div class="alert alert-success" role="alert">
18
+ <h4 class="alert-title">Wow! Everything worked!</h4>
19
+ <div class="text-secondary">Your account has been saved!</div>
20
+ </div>
21
+ <div class="alert alert-info" role="alert">
22
+ <h4 class="alert-title">Did you know?</h4>
23
+ <div class="text-secondary">Here is something that you might like to know.</div>
24
+ </div>
25
+ <div class="alert alert-warning" role="alert">
26
+ <h4 class="alert-title">Uh oh, something went wrong</h4>
27
+ <div class="text-secondary">Sorry! There was a problem with your request.</div>
28
+ </div>
29
+ <div class="alert alert-danger" role="alert">
30
+ <h4 class="alert-title">I'm so sorry&hellip;</h4>
31
+ <div class="text-secondary">Your account has been deleted and can't be restored.</div>
32
+ </div>
33
+ ```
34
+
35
+ ## Alert links
36
+
37
+ Add a link to your alert message to redirect users to the details they need to complete or additional information they should read. Use `alert-link` class to style the link and match the text color.
38
+
39
+ ```html example vertical background="surface" columns={2} centered height="120px"
40
+ <div class="alert alert-danger m-0">
41
+ This is a danger alert — <a href="#" class="alert-link">check it out</a>!
42
+ </div>
43
+ ```
44
+
45
+ ## Dismissible alerts
46
+
47
+ Add the `x` close button to make an alert modal dismissible. Thanks to that, your alert modal will disappear only when the user closes it.
48
+
49
+ ```html
50
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
51
+ ```
52
+
53
+ ```html example vertical background="surface" columns={2} centered separated height="420px"
54
+ <div class="alert alert-success alert-dismissible" role="alert">
55
+ <div>
56
+ <h4 class="alert-title">Wow! Everything worked!</h4>
57
+ <div class="text-secondary">Your account has been saved!</div>
58
+ </div>
59
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
60
+ </div>
61
+ <div class="alert alert-info alert-dismissible" role="alert">
62
+ <div>
63
+ <h4 class="alert-title">Did you know?</h4>
64
+ <div class="text-secondary">Here is something that you might like to know.</div>
65
+ </div>
66
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
67
+ </div>
68
+ <div class="alert alert-warning alert-dismissible" role="alert">
69
+ <div>
70
+ <h4 class="alert-title">Uh oh, something went wrong</h4>
71
+ <div class="text-secondary">Sorry! There was a problem with your request.</div>
72
+ </div>
73
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
74
+ </div>
75
+ <div class="alert alert-danger alert-dismissible" role="alert">
76
+ <div>
77
+ <h4 class="alert-title">I'm so sorry&hellip;</h4>
78
+ <div class="text-secondary">Your account has been deleted and can't be restored.</div>
79
+ </div>
80
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
81
+ </div>
82
+ ```
83
+
84
+ ## Alerts with icons
85
+
86
+ Add an icon to your alert modal to make it more user-friendly and help users easily identify the message.
87
+
88
+ Use the `alert-icon` class on an `<svg>` (or on an `<i>` when using the webfont) to provide the proper styling.
89
+
90
+ ```html example vertical background="surface" columns={2} centered separated height="420px"
91
+ <div class="alert alert-success" role="alert">
92
+ <div class="d-flex">
93
+ <div>
94
+ <svg
95
+ xmlns="http://www.w3.org/2000/svg"
96
+ class="icon alert-icon"
97
+ width="24"
98
+ height="24"
99
+ viewBox="0 0 24 24"
100
+ stroke-width="2"
101
+ stroke="currentColor"
102
+ fill="none"
103
+ stroke-linecap="round"
104
+ stroke-linejoin="round"
105
+ >
106
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
107
+ <path d="M5 12l5 5l10 -10" />
108
+ </svg>
109
+ </div>
110
+ <div>
111
+ <h4 class="alert-title">Wow! Everything worked!</h4>
112
+ <div class="text-secondary">Your account has been saved!</div>
113
+ </div>
114
+ </div>
115
+ </div>
116
+ <div class="alert alert-info" role="alert">
117
+ <div class="d-flex">
118
+ <div>
119
+ <svg
120
+ xmlns="http://www.w3.org/2000/svg"
121
+ class="icon alert-icon"
122
+ width="24"
123
+ height="24"
124
+ viewBox="0 0 24 24"
125
+ stroke-width="2"
126
+ stroke="currentColor"
127
+ fill="none"
128
+ stroke-linecap="round"
129
+ stroke-linejoin="round"
130
+ >
131
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
132
+ <circle cx="12" cy="12" r="9" />
133
+ <line x1="12" y1="8" x2="12.01" y2="8" />
134
+ <polyline points="11 12 12 12 12 16 13 16" />
135
+ </svg>
136
+ </div>
137
+ <div>
138
+ <h4 class="alert-title">Did you know?</h4>
139
+ <div class="text-secondary">Here is something that you might like to know.</div>
140
+ </div>
141
+ </div>
142
+ </div>
143
+ <div class="alert alert-warning" role="alert">
144
+ <div class="d-flex">
145
+ <div>
146
+ <svg
147
+ xmlns="http://www.w3.org/2000/svg"
148
+ class="icon alert-icon"
149
+ width="24"
150
+ height="24"
151
+ viewBox="0 0 24 24"
152
+ stroke-width="2"
153
+ stroke="currentColor"
154
+ fill="none"
155
+ stroke-linecap="round"
156
+ stroke-linejoin="round"
157
+ >
158
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
159
+ <path d="M12 9v2m0 4v.01" />
160
+ <path
161
+ d="M5 19h14a2 2 0 0 0 1.84 -2.75l-7.1 -12.25a2 2 0 0 0 -3.5 0l-7.1 12.25a2 2 0 0 0 1.75 2.75"
162
+ />
163
+ </svg>
164
+ </div>
165
+ <div>
166
+ <h4 class="alert-title">Uh oh, something went wrong</h4>
167
+ <div class="text-secondary">Sorry! There was a problem with your request.</div>
168
+ </div>
169
+ </div>
170
+ </div>
171
+ <div class="alert alert-danger" role="alert">
172
+ <div class="d-flex">
173
+ <div>
174
+ <svg
175
+ xmlns="http://www.w3.org/2000/svg"
176
+ class="icon alert-icon"
177
+ width="24"
178
+ height="24"
179
+ viewBox="0 0 24 24"
180
+ stroke-width="2"
181
+ stroke="currentColor"
182
+ fill="none"
183
+ stroke-linecap="round"
184
+ stroke-linejoin="round"
185
+ >
186
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
187
+ <circle cx="12" cy="12" r="9" />
188
+ <line x1="12" y1="8" x2="12" y2="12" />
189
+ <line x1="12" y1="16" x2="12.01" y2="16" />
190
+ </svg>
191
+ </div>
192
+ <div>
193
+ <h4 class="alert-title">I'm so sorry&hellip;</h4>
194
+ <div class="text-secondary">Your account has been deleted and can't be restored.</div>
195
+ </div>
196
+ </div>
197
+ </div>
198
+ ```
199
+
200
+ ## Alert with avatar
201
+
202
+ Add an avatar to your alert modal to make it more personalized.
203
+
204
+ ```html example vertical background="surface" columns={2} centered separated height="420px"
205
+ <div class="alert alert-success" role="alert">
206
+ <div class="d-flex">
207
+ <div>
208
+ <span
209
+ class="avatar me-3"
210
+ style="background-image: url(/static/samples/avatars/039m.jpg)"
211
+ ></span>
212
+ </div>
213
+ <div>
214
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Lorem ipsum dolor sit amet,
215
+ consectetur adipisicing elit. Lorem ipsum dolor sit amet, consectetur adipisicing elit.
216
+ </div>
217
+ </div>
218
+ </div>
219
+ <div class="alert alert-info" role="alert">
220
+ <div class="d-flex">
221
+ <div>
222
+ <span class="avatar me-3">JL</span>
223
+ </div>
224
+ <div>
225
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Lorem ipsum dolor sit amet,
226
+ consectetur adipisicing elit. Lorem ipsum dolor sit amet, consectetur adipisicing elit.
227
+ </div>
228
+ </div>
229
+ </div>
230
+ <div class="alert alert-warning" role="alert">
231
+ <div class="d-flex">
232
+ <div>
233
+ <span
234
+ class="avatar me-3"
235
+ style="background-image: url(/static/samples/avatars/035f.jpg)"
236
+ ></span>
237
+ </div>
238
+ <div>
239
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Lorem ipsum dolor sit amet,
240
+ consectetur adipisicing elit. Lorem ipsum dolor sit amet, consectetur adipisicing elit.
241
+ </div>
242
+ </div>
243
+ </div>
244
+ <div class="alert alert-danger" role="alert">
245
+ <div class="d-flex">
246
+ <div>
247
+ <span
248
+ class="avatar me-3"
249
+ style="background-image: url(/static/samples/avatars/056f.jpg)"
250
+ ></span>
251
+ </div>
252
+ <div>
253
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit. Lorem ipsum dolor sit amet,
254
+ consectetur adipisicing elit. Lorem ipsum dolor sit amet, consectetur adipisicing elit.
255
+ </div>
256
+ </div>
257
+ </div>
258
+ ```
259
+
260
+ ## Alert with buttons
261
+
262
+ Add primary and secondary buttons to your alert modals if you want users to take a particular action based on the information included in the modal message.
263
+
264
+ Buttons don't inherit the alert's color, so you should set the proper class if you want it to be matched. For example, `btn-success` for `alert-success`.
265
+
266
+ ```html example vertical background="surface" columns={2} centered separated height="740px"
267
+ <div class="alert alert-success alert-dismissible" role="alert">
268
+ <h3 class="mb-1">Some Title</h3>
269
+ <p class="text-secondary">
270
+ Lorem ipsum Minim ad pariatur eiusmod ea ut nulla aliqua est quis id dolore minim voluptate.
271
+ </p>
272
+ <div class="btn-list">
273
+ <a href="#" class="btn btn-success">Okay</a>
274
+ <a href="#" class="btn">Cancel</a>
275
+ </div>
276
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
277
+ </div>
278
+ <div class="alert alert-info alert-dismissible" role="alert">
279
+ <h3 class="mb-1">Some Title</h3>
280
+ <p class="text-secondary">
281
+ Lorem ipsum Minim ad pariatur eiusmod ea ut nulla aliqua est quis id dolore minim voluptate.
282
+ </p>
283
+ <div class="btn-list">
284
+ <a href="#" class="btn btn-info">Okay</a>
285
+ <a href="#" class="btn">Cancel</a>
286
+ </div>
287
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
288
+ </div>
289
+ <div class="alert alert-warning alert-dismissible" role="alert">
290
+ <h3 class="mb-1">Some Title</h3>
291
+ <p class="text-secondary">
292
+ Lorem ipsum Minim ad pariatur eiusmod ea ut nulla aliqua est quis id dolore minim voluptate.
293
+ </p>
294
+ <div class="btn-list">
295
+ <a href="#" class="btn btn-warning">Okay</a>
296
+ <a href="#" class="btn">Cancel</a>
297
+ </div>
298
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
299
+ </div>
300
+ <div class="alert alert-danger alert-dismissible" role="alert">
301
+ <h3 class="mb-1">Some Title</h3>
302
+ <p class="text-secondary">
303
+ Lorem ipsum Minim ad pariatur eiusmod ea ut nulla aliqua est quis id dolore minim voluptate.
304
+ </p>
305
+ <div class="btn-list">
306
+ <a href="#" class="btn btn-danger">Okay</a>
307
+ <a href="#" class="btn">Cancel</a>
308
+ </div>
309
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
310
+ </div>
311
+ ```
312
+
313
+ ## Important alerts
314
+
315
+ If you want your alert to be really eye-catching, you can add an `alert-important` class. It will use the selected color as a background for the alert.
316
+
317
+ ```html
318
+ <div class="alert alert-important alert-success alert-dismissible" role="alert">...</div>
319
+ ```
320
+
321
+ You can also use other elements, like icons and dismissible buttons, with this type of alert.
322
+
323
+ ```html example vertical columns={2} centered separated
324
+ <div class="alert alert-important alert-success alert-dismissible" role="alert">
325
+ <div class="d-flex">
326
+ <div>
327
+ <svg
328
+ xmlns="http://www.w3.org/2000/svg"
329
+ class="icon alert-icon"
330
+ width="24"
331
+ height="24"
332
+ viewBox="0 0 24 24"
333
+ stroke-width="2"
334
+ stroke="currentColor"
335
+ fill="none"
336
+ stroke-linecap="round"
337
+ stroke-linejoin="round"
338
+ >
339
+ <path stroke="none" d="M0 0h24v24H0z" fill="none"></path>
340
+ <path d="M5 12l5 5l10 -10"></path>
341
+ </svg>
342
+ </div>
343
+ <div>Wow! Everything worked!</div>
344
+ </div>
345
+ <a class="btn-close btn-close-white" data-bs-dismiss="alert" aria-label="close"></a>
346
+ </div>
347
+ <div class="alert alert-important alert-danger alert-dismissible" role="alert">
348
+ <div class="d-flex">
349
+ <div>
350
+ <svg
351
+ xmlns="http://www.w3.org/2000/svg"
352
+ class="icon alert-icon"
353
+ width="24"
354
+ height="24"
355
+ viewBox="0 0 24 24"
356
+ stroke-width="2"
357
+ stroke="currentColor"
358
+ fill="none"
359
+ stroke-linecap="round"
360
+ stroke-linejoin="round"
361
+ >
362
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
363
+ <circle cx="12" cy="12" r="9" />
364
+ <line x1="12" y1="8" x2="12" y2="12" />
365
+ <line x1="12" y1="16" x2="12.01" y2="16" />
366
+ </svg>
367
+ </div>
368
+ <div>Your account has been deleted and can't be restored.</div>
369
+ </div>
370
+ <a class="btn-close btn-close-white" data-bs-dismiss="alert" aria-label="close"></a>
371
+ </div>
372
+ ```
373
+
374
+ ## Custom alert color
375
+
376
+ You're not limited to the 4 default alert colors. You can use any [base or social color](../base/colors) you want.
377
+
378
+ ```html example vertical background="surface" columns={2} centered separated height="420px"
379
+ <div class="alert alert-lime" role="alert">
380
+ <h4 class="alert-title">Wow! Everything worked!</h4>
381
+ <div class="text-secondary">Your account has been saved!</div>
382
+ </div>
383
+ <div class="alert alert-cyan" role="alert">
384
+ <h4 class="alert-title">Did you know?</h4>
385
+ <div class="text-secondary">Here is something that you might like to know.</div>
386
+ </div>
387
+ <div class="alert alert-facebook" role="alert">
388
+ <h4 class="alert-title">You have a new friend on Facebook</h4>
389
+ <div class="text-secondary">Say hello to your new friend!</div>
390
+ </div>
391
+ <div class="alert alert-instagram alert-dismissible alert-important" role="alert">
392
+ <div class="d-flex">
393
+ <div>
394
+ <span
395
+ class="avatar me-3"
396
+ style="background-image: url(/static/samples/avatars/035f.jpg)"
397
+ ></span>
398
+ </div>
399
+ <div>
400
+ <h4 class="alert-title">Sophia just added a new post on Instagram</h4>
401
+ <div>Be the first to see it!</div>
402
+ </div>
403
+ </div>
404
+ <a class="btn-close" data-bs-dismiss="alert" aria-label="close"></a>
405
+ </div>
406
+ ```
@@ -0,0 +1,25 @@
1
+ ---
2
+ title: Autosize
3
+ summary: The autosize element will automatically adjust the textarea height and make it easier for users to follow as they type.
4
+ libs: autosize
5
+ description: Auto-adjusting textarea for better usability.
6
+ ---
7
+
8
+ To be able to use the autosize in your application you will need to install the autosize dependency with `npm install autosize`.
9
+
10
+ ## Default markup
11
+
12
+ Add the autosize element to your input to make it automatically adjust to the length of a text as a user types it.
13
+
14
+ To create autosize textarea, add the `data-bs-toggle="autosize"` attribute to the textarea element:
15
+
16
+ ```html
17
+ <textarea class="form-control" data-bs-toggle="autosize" placeholder="Type something…"></textarea>
18
+ ```
19
+
20
+ Look at the example below to see how the autosize element works:
21
+
22
+ ```html example centered columns={1} scrollable height="20rem"
23
+ <label class="form-label">Autosize example</label>
24
+ <textarea class="form-control" data-bs-toggle="autosize" placeholder="Type something…"></textarea>
25
+ ```
@@ -0,0 +1,227 @@
1
+ ---
2
+ title: Avatars
3
+ summary: Avatars help customize various elements of a user interface and make the product experience more personalized. They are often used in communication apps, collaboration tools and social media.
4
+ description: Personalize UI with user avatars.
5
+ ---
6
+
7
+ ## Default markup
8
+
9
+ Use the `avatar` class to add an avatar to your interface design for greater customization.
10
+
11
+ ```html example centered separated code
12
+ <span class="avatar" style="background-image: url(/samples/avatars/002f.jpg)"></span>
13
+ <span class="avatar">JL</span>
14
+ <span class="avatar" style="background-image: url(/samples/avatars/004f.jpg)"></span>
15
+ ```
16
+
17
+ ## Avatar image
18
+
19
+ Set an image as the background to make users easy to indentify and create a personalized experience.
20
+
21
+ ```html example centered separated code
22
+ <span class="avatar" style="background-image: url(/samples/avatars/016f.jpg)"></span>
23
+ <span class="avatar" style="background-image: url(/samples/avatars/022m.jpg)"></span>
24
+ <span class="avatar" style="background-image: url(/samples/avatars/036m.jpg)"></span>
25
+ ```
26
+
27
+ ## Initials
28
+
29
+ You can also use initials instead of pictures.
30
+
31
+ ```html example centered separated code
32
+ <span class="avatar">AB</span>
33
+ <span class="avatar">CD</span>
34
+ <span class="avatar">EF</span>
35
+ <span class="avatar">GH</span>
36
+ <span class="avatar">IJ</span>
37
+ ```
38
+
39
+ ## Avatar icons
40
+
41
+ Besides pictures and initials, you can also use icons to make the avatars more universal.
42
+
43
+ ```html example centered separated
44
+ <span class="avatar">
45
+ <svg
46
+ xmlns="http://www.w3.org/2000/svg"
47
+ class="icon avatar-icon"
48
+ width="24"
49
+ height="24"
50
+ viewBox="0 0 24 24"
51
+ stroke-width="2"
52
+ stroke="currentColor"
53
+ fill="none"
54
+ stroke-linecap="round"
55
+ stroke-linejoin="round"
56
+ >
57
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
58
+ <circle cx="12" cy="7" r="4" />
59
+ <path d="M6 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2" />
60
+ </svg>
61
+ </span>
62
+ <span class="avatar">
63
+ <svg
64
+ xmlns="http://www.w3.org/2000/svg"
65
+ class="icon avatar-icon"
66
+ width="24"
67
+ height="24"
68
+ viewBox="0 0 24 24"
69
+ stroke-width="2"
70
+ stroke="currentColor"
71
+ fill="none"
72
+ stroke-linecap="round"
73
+ stroke-linejoin="round"
74
+ >
75
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
76
+ <line x1="12" y1="5" x2="12" y2="19" />
77
+ <line x1="5" y1="12" x2="19" y2="12" />
78
+ </svg>
79
+ </span>
80
+ <span class="avatar">
81
+ <svg
82
+ xmlns="http://www.w3.org/2000/svg"
83
+ class="icon avatar-icon"
84
+ width="24"
85
+ height="24"
86
+ viewBox="0 0 24 24"
87
+ stroke-width="2"
88
+ stroke="currentColor"
89
+ fill="none"
90
+ stroke-linecap="round"
91
+ stroke-linejoin="round"
92
+ >
93
+ <path stroke="none" d="M0 0h24v24H0z" fill="none" />
94
+ <circle cx="9" cy="7" r="4" />
95
+ <path d="M3 21v-2a4 4 0 0 1 4 -4h4a4 4 0 0 1 4 4v2" />
96
+ <path d="M16 11h6m-3 -3v6" />
97
+ </svg>
98
+ </span>
99
+ ```
100
+
101
+ ```html
102
+ <span class="avatar">
103
+ <!-- SVG icon from http://tabler.io/icons/icon/user -->
104
+ <svg>...</svg>
105
+ </span>
106
+ ```
107
+
108
+ ## Avatar initials color
109
+
110
+ Customize the color of the avatars' background. You can click [here](/docs/ui/base/colors) to see the list of available colors.
111
+
112
+ ```html example centered separated code
113
+ <span class="avatar bg-green-lt">AB</span>
114
+ <span class="avatar bg-red-lt">CD</span>
115
+ <span class="avatar bg-yellow-lt">EF</span>
116
+ <span class="avatar bg-primary-lt">GH</span>
117
+ <span class="avatar bg-purple-lt">IJ</span>
118
+ ```
119
+
120
+ ## Avatar size
121
+
122
+ Using Bootstrap’s typical naming structure, you can create a standard avatar or scale it up or down to different sizes based on what you need.
123
+
124
+ ```html example centered separated code
125
+ <span class="avatar avatar-xl" style="background-image: url(/samples/avatars/000m.jpg)"></span>
126
+ <span class="avatar avatar-lg" style="background-image: url(/samples/avatars/000m.jpg)"></span>
127
+ <span class="avatar avatar-md" style="background-image: url(/samples/avatars/000m.jpg)"></span>
128
+ <span class="avatar" style="background-image: url(/samples/avatars/000m.jpg)"></span>
129
+ <span class="avatar avatar-sm" style="background-image: url(/samples/avatars/000m.jpg)"></span>
130
+ <span class="avatar avatar-xs" style="background-image: url(/samples/avatars/000m.jpg)"></span>
131
+ ```
132
+
133
+ ## Avatar status
134
+
135
+ Add a status indicator to your avatar to show, for instance, if a user is online or offline or indicate the number of messages they have received.
136
+
137
+ ```html example centered separated code
138
+ <span class="avatar" style="background-image: url(/samples/avatars/018m.jpg)"></span>
139
+ <span class="avatar" style="background-image: url(/samples/avatars/015m.jpg)">
140
+ <span class="badge bg-danger"></span>
141
+ </span>
142
+ <span class="avatar" style="background-image: url(/samples/avatars/022m.jpg)">
143
+ <span class="badge bg-success"></span>
144
+ </span>
145
+ <span class="avatar"> <span class="badge bg-warning"></span>SA </span>
146
+ <span class="avatar" style="background-image: url(/samples/avatars/022m.jpg)">
147
+ <span class="badge bg-info"></span>
148
+ </span>
149
+ <span class="avatar" style="background-image: url(/samples/avatars/048m.jpg)">
150
+ <span class="badge bg-gray">5</span>
151
+ </span>
152
+ ```
153
+
154
+ ## Avatar shape
155
+
156
+ Change the shape of an avatar with the default Bootstrap image classes. You can make them round or square and change their border radius.
157
+
158
+ ```html example centered separated
159
+ <span class="avatar" style="background-image: url(/samples/avatars/019m.jpg)"></span>
160
+ <span class="avatar rounded" style="background-image: url(/samples/avatars/039f.jpg)"></span>
161
+ <span class="avatar rounded-circle">AA</span>
162
+ <span class="avatar rounded-0" style="background-image: url(/samples/avatars/043f.jpg)"></span>
163
+ <span class="avatar rounded-3" style="background-image: url(/samples/avatars/044f.jpg)"></span>
164
+ ```
165
+
166
+ ## Avatars list
167
+
168
+ Create a list of avatars within one parent container.
169
+
170
+ ```html example centered separated code
171
+ <div class="avatar-list">
172
+ <span class="avatar rounded" style="background-image: url(/samples/avatars/031f.jpg)"></span>
173
+ <span class="avatar rounded">JL</span>
174
+ <span class="avatar rounded" style="background-image: url(/samples/avatars/033f.jpg)"></span>
175
+ <span class="avatar rounded" style="background-image: url(/samples/avatars/017m.jpg)"></span>
176
+ <span class="avatar rounded" style="background-image: url(/samples/avatars/024m.jpg)"></span>
177
+ </div>
178
+ ```
179
+
180
+ ## Stacked list
181
+
182
+ Make the list stack once a certain number of avatars is reached to make it look clear and display well regardless of the screen size.
183
+
184
+ ```html example centered separated code
185
+ <div class="avatar-list avatar-list-stacked">
186
+ <span class="avatar">EB</span>
187
+ <span class="avatar" style="background-image: url(/samples/avatars/026m.jpg)"></span>
188
+ <span class="avatar" style="background-image: url(/samples/avatars/016f.jpg)"></span>
189
+ <span class="avatar" style="background-image: url(/samples/avatars/028m.jpg)"></span>
190
+ <span class="avatar" style="background-image: url(/samples/avatars/030m.jpg)"></span>
191
+ <span class="avatar">+8</span>
192
+ </div>
193
+ ```
194
+
195
+ ```html example centered separated code
196
+ <div class="avatar-list avatar-list-stacked">
197
+ <span
198
+ class="avatar avatar-sm rounded-circle"
199
+ style="background-image: url(/samples/avatars/035m.jpg)"
200
+ ></span>
201
+ <span
202
+ class="avatar avatar-sm rounded-circle"
203
+ style="background-image: url(/samples/avatars/027f.jpg)"
204
+ ></span>
205
+ <span
206
+ class="avatar avatar-sm rounded-circle"
207
+ style="background-image: url(/samples/avatars/036f.jpg)"
208
+ ></span>
209
+ <span class="avatar avatar-sm rounded-circle">SA</span>
210
+ <span
211
+ class="avatar avatar-sm rounded-circle"
212
+ style="background-image: url(/samples/avatars/034f.jpg)"
213
+ ></span>
214
+ <span
215
+ class="avatar avatar-sm rounded-circle"
216
+ style="background-image: url(/samples/avatars/043f.jpg)"
217
+ ></span>
218
+ <span
219
+ class="avatar avatar-sm rounded-circle"
220
+ style="background-image: url(/samples/avatars/039f.jpg)"
221
+ ></span>
222
+ <span
223
+ class="avatar avatar-sm rounded-circle"
224
+ style="background-image: url(/samples/avatars/020m.jpg)"
225
+ ></span>
226
+ </div>
227
+ ```