spoko-design-system 0.9.3 → 0.9.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.
- package/.astro/settings.json +4 -4
- package/.astro/types.d.ts +1 -1
- package/.claude/settings.local.json +2 -1
- package/.github/dependabot.yml +11 -11
- package/.github/todo.yml +3 -3
- package/.github/workflows/deploy.yml +39 -39
- package/.stackblitzrc +5 -5
- package/.vscode/extensions.json +5 -5
- package/.vscode/launch.json +11 -11
- package/.vscode/settings.json +5 -5
- package/LICENSE +21 -21
- package/README.md +116 -116
- package/astro-i18next.config.mjs +17 -17
- package/astro-i18next.config.ts +10 -10
- package/astro.config.mjs +86 -86
- package/dev-dist/sw.js +91 -91
- package/dev-dist/workbox-c676b6d3.js +3391 -3391
- package/icon.config.ts +310 -310
- package/index.ts +70 -70
- package/package.json +37 -33
- package/public/arrow-bottom.svg +7 -7
- package/public/fonts/lg.svg +53 -53
- package/public/fonts/vwhead-bold-demo.html +549 -549
- package/public/fonts/vwhead-regular-demo.html +549 -549
- package/public/fonts/vwtext-bold-demo.html +549 -549
- package/public/fonts/vwtext-regular-demo.html +549 -549
- package/public/github.svg +3 -3
- package/public/grid_dot.svg +4 -4
- package/public/linkedin.svg +44 -44
- package/public/locales/en/translation.json +12 -12
- package/public/locales/pl/translation.json +12 -12
- package/public/make-scrollable-code-focusable.js +3 -3
- package/public/pagefind.yml +3 -3
- package/public/polo.blue.svg +29 -29
- package/public/spoko.space.svg +71 -71
- package/public/twitter.svg +46 -46
- package/renovate.json +6 -6
- package/sandbox.config.json +11 -11
- package/src/MyComponent.astro +8 -8
- package/src/components/Badge.vue +19 -19
- package/src/components/Badges.vue +21 -21
- package/src/components/Breadcrumbs.vue +94 -94
- package/src/components/Button.vue +101 -101
- package/src/components/ButtonCopy.astro +183 -183
- package/src/components/ButtonCopy.vue +36 -36
- package/src/components/Card.astro +27 -27
- package/src/components/Carousel.astro +26 -26
- package/src/components/Category/CategoriesCarousel.astro +101 -101
- package/src/components/Category/CategoryDetails.astro +169 -169
- package/src/components/Category/CategoryLink.vue +28 -28
- package/src/components/Category/CategorySidebarToggler.vue +9 -9
- package/src/components/Category/CategoryTile.astro +37 -37
- package/src/components/Category/CategoryViewToggler.astro +89 -89
- package/src/components/Category/SubCategoryLink.vue +19 -19
- package/src/components/Copyright.astro +12 -12
- package/src/components/Date.astro +7 -7
- package/src/components/Faq.astro +33 -33
- package/src/components/FaqItem.astro +80 -80
- package/src/components/FeaturesList.vue +37 -37
- package/src/components/FuckRussia.vue +62 -62
- package/src/components/HandDrive.astro +29 -29
- package/src/components/Header/Header.astro +210 -210
- package/src/components/Header/SkipToContent.astro +1 -1
- package/src/components/Headline.vue +87 -87
- package/src/components/Image.astro +30 -30
- package/src/components/{layout → Layout}/CallToAction.astro +52 -52
- package/src/components/{layout → Layout}/Container.astro +7 -7
- package/src/components/{layout → Layout}/Header.astro +80 -80
- package/src/components/LeftSidebar.astro +53 -53
- package/src/components/MainColors.vue +22 -22
- package/src/components/MainInput.vue +15 -15
- package/src/components/Modal.astro +27 -27
- package/src/components/PageContent.astro +5 -5
- package/src/components/PartNumber.vue +27 -27
- package/src/components/Post/PostCategories.astro +41 -41
- package/src/components/Post/PostCategories.vue +30 -30
- package/src/components/PostHeader.astro +103 -103
- package/src/components/PrCode.vue +141 -141
- package/src/components/Product/ProductButton.vue +18 -18
- package/src/components/Product/ProductCarousel.astro +35 -35
- package/src/components/Product/ProductEngineType.vue +42 -42
- package/src/components/Product/ProductImage.astro +40 -40
- package/src/components/Product/ProductLink.astro +101 -101
- package/src/components/Product/ProductLink.vue +59 -59
- package/src/components/Product/ProductLinkInfo.astro +37 -37
- package/src/components/Product/ProductNumber.astro +60 -60
- package/src/components/ProductCarousel.astro +38 -38
- package/src/components/ProductCodes.vue +39 -39
- package/src/components/ProductDetailName.vue +52 -52
- package/src/components/ProductDetailsList.vue +216 -216
- package/src/components/ProductTile.astro +48 -48
- package/src/components/Quote.vue +23 -23
- package/src/components/ReloadPrompt.astro +50 -50
- package/src/components/SlimBanner.vue +72 -72
- package/src/components/Table.vue +32 -32
- package/src/components/TableOfContents.astro +15 -15
- package/src/components/Translations.vue +23 -23
- package/src/components/flags/FlagPL.vue +3 -3
- package/src/components/flags/FlagUA.vue +2 -2
- package/src/config.ts +56 -56
- package/src/design.config.ts +98 -98
- package/src/env.d.ts +6 -6
- package/src/layouts/Layout.astro +61 -61
- package/src/layouts/MainLayout.astro +81 -81
- package/src/layouts/partials/FooterCommon.astro +4 -4
- package/src/layouts/partials/HeadCommon.astro +44 -44
- package/src/layouts/partials/HeadSEO.astro +41 -41
- package/src/pages/components/badges.mdx +57 -57
- package/src/pages/components/breadcrumbs.mdx +139 -139
- package/src/pages/components/buttons.mdx +360 -360
- package/src/pages/components/card.mdx +294 -294
- package/src/pages/components/carousel.mdx +62 -62
- package/src/pages/components/copyright.mdx +42 -42
- package/src/pages/components/details-list.mdx +115 -115
- package/src/pages/components/features-list.mdx +37 -37
- package/src/pages/components/flags.mdx +49 -49
- package/src/pages/components/fuck-russia.mdx +39 -39
- package/src/pages/components/hand-drive.mdx +38 -38
- package/src/pages/components/headline.mdx +137 -137
- package/src/pages/components/icons.astro +135 -135
- package/src/pages/components/image.mdx +513 -513
- package/src/pages/components/input.mdx +367 -367
- package/src/pages/components/jumbotron.mdx +359 -359
- package/src/pages/components/modal.mdx +64 -64
- package/src/pages/components/post-header.mdx +64 -64
- package/src/pages/components/pr-code.mdx +65 -65
- package/src/pages/components/product-number.mdx +58 -58
- package/src/pages/components/product-tile.mdx +51 -51
- package/src/pages/components/quote.mdx +33 -33
- package/src/pages/components/slimbanner.mdx +35 -35
- package/src/pages/components/table.mdx +108 -108
- package/src/pages/core/colors.mdx +10 -10
- package/src/pages/core/grid.mdx +89 -89
- package/src/pages/core/introduction.mdx +77 -77
- package/src/pages/core/shadows.astro +20 -20
- package/src/pages/core/typography.astro +49 -49
- package/src/pages/index.astro +133 -133
- package/src/pages/patterns/introduction.mdx +60 -60
- package/src/pwa.ts +12 -12
- package/src/styles/_variables.scss +70 -70
- package/src/styles/base/base.css +184 -184
- package/src/styles/base/grid.css +92 -92
- package/src/styles/base/typography.css +70 -70
- package/src/styles/content.css +73 -73
- package/src/styles/main.css +7 -7
- package/src/types/Product.ts +31 -31
- package/src/types/astro.d.ts +3 -3
- package/src/utils/product/getPriceFormatted.ts +15 -15
- package/src/utils/product/getProductChecklist.ts +17 -17
- package/src/utils/product/useFormatProductNumber.ts +41 -41
- package/src/utils/seo/getShorterDescription.ts +14 -14
- package/src/utils/text/formatDate.ts +5 -5
- package/src/utils/text/formatLocaleNumber.ts +6 -6
- package/src/utils/text/formatPad.ts +12 -12
- package/src/utils/text/getNumberFormatted.ts +33 -33
- package/src/utils/text/getTranslatedLink.ts +5 -5
- package/src/utils/text.ts +19 -19
- package/tailwind.config.cjs +8 -8
- package/tsconfig.json +28 -28
- package/uno-config/index.ts +268 -268
- package/uno-config/theme/breakpoints.ts +9 -9
- package/uno-config/theme/colors.ts +64 -64
- package/uno-config/theme/dimensions.ts +17 -17
- package/uno-config/theme/effects.ts +14 -14
- package/uno-config/theme/grid.ts +10 -10
- package/uno-config/theme/index.ts +28 -28
- package/uno-config/theme/shortcuts/buttons.ts +53 -53
- package/uno-config/theme/shortcuts/components.ts +123 -123
- package/uno-config/theme/shortcuts/index.ts +20 -20
- package/uno-config/theme/shortcuts/jumbotron.ts +1 -1
- package/uno-config/theme/shortcuts/layout.ts +74 -74
- package/uno-config/theme/typography.ts +29 -29
- package/uno.config.ts +2 -2
|
@@ -1,360 +1,360 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: "Jumbotron"
|
|
3
|
-
layout: "../../layouts/MainLayout.astro"
|
|
4
|
-
---
|
|
5
|
-
import Jumbotron from '../../components/Jumbotron.astro'
|
|
6
|
-
import Button from '../../components/Button.vue'
|
|
7
|
-
|
|
8
|
-
# Jumbotron
|
|
9
|
-
|
|
10
|
-
A Jumbotron indicates a big box for calling extra attention to some special content or information. It provides various layouts through different variants to suit your content presentation needs.
|
|
11
|
-
|
|
12
|
-
## Table of Contents
|
|
13
|
-
- [Best Practices](#best-practices)
|
|
14
|
-
- [Responsive Behavior](#responsive-behavior)
|
|
15
|
-
- [Variants](#variants)
|
|
16
|
-
- [Default Variant](#default-variant-classic)
|
|
17
|
-
- [Small Variant](#small-variant)
|
|
18
|
-
- [Hero Variant](#hero-variant)
|
|
19
|
-
- [Post Variant](#post-variant-full-overlay)
|
|
20
|
-
- [Post Split Variant](#post-split-variant)
|
|
21
|
-
- [Component API](#component-api)
|
|
22
|
-
- [Accessibility](#accessibility)
|
|
23
|
-
|
|
24
|
-
## Best Practices
|
|
25
|
-
- Use the `default` variant for main content sections and general announcements
|
|
26
|
-
- Use the `hero` variant for page headers with background images and important messaging
|
|
27
|
-
- Use the `post` variant for blog posts and articles with full-width image overlays
|
|
28
|
-
- Use the `post-split` variant when you need to display image alongside content
|
|
29
|
-
- Consider using `small` prop for less important or secondary sections
|
|
30
|
-
|
|
31
|
-
## Responsive Behavior
|
|
32
|
-
The component adapts to different screen sizes:
|
|
33
|
-
- On mobile: Stacks content vertically, adjusts font sizes and padding
|
|
34
|
-
- On tablet: Optimizes layout and spacing
|
|
35
|
-
- On desktop: Full layout with optimal content width and spacing
|
|
36
|
-
|
|
37
|
-
## Default Variant (Classic)
|
|
38
|
-
The default variant is ideal for primary content sections. It supports custom intro, subtitle, and CTA content with centered layout.
|
|
39
|
-
|
|
40
|
-
<div class="component-preview !block">
|
|
41
|
-
<Jumbotron
|
|
42
|
-
variant="default"
|
|
43
|
-
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
44
|
-
>
|
|
45
|
-
<p slot="subtitle"
|
|
46
|
-
class="mt-3 text-base text-gray-200 sm:mt-5 text-lg md:text-xl lg:mx-0 md:mt-5"
|
|
47
|
-
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
48
|
-
<Fragment slot="cta-content">
|
|
49
|
-
<Button primary rounded href="#" title="short text">
|
|
50
|
-
Read More
|
|
51
|
-
</Button>
|
|
52
|
-
</Fragment>
|
|
53
|
-
</Jumbotron>
|
|
54
|
-
</div>
|
|
55
|
-
|
|
56
|
-
```js
|
|
57
|
-
<Jumbotron
|
|
58
|
-
variant="default"
|
|
59
|
-
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
60
|
-
>
|
|
61
|
-
<p slot="subtitle"
|
|
62
|
-
class="mt-3 text-base text-gray-200 sm:mt-5 text-lg md:text-xl lg:mx-0 md:mt-5"
|
|
63
|
-
>
|
|
64
|
-
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
65
|
-
</p>
|
|
66
|
-
<Fragment slot="cta-content">
|
|
67
|
-
<Button primary rounded href="#" title="short text">
|
|
68
|
-
Read More
|
|
69
|
-
</Button>
|
|
70
|
-
</Fragment>
|
|
71
|
-
</Jumbotron>
|
|
72
|
-
```
|
|
73
|
-
|
|
74
|
-
## Small Variant
|
|
75
|
-
A more compact version of the default variant, useful for secondary content sections or when vertical space is limited.
|
|
76
|
-
|
|
77
|
-
<div class="component-preview">
|
|
78
|
-
<Jumbotron
|
|
79
|
-
variant="default"
|
|
80
|
-
small
|
|
81
|
-
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
82
|
-
>
|
|
83
|
-
<p slot="subtitle"
|
|
84
|
-
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
85
|
-
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
86
|
-
</Jumbotron>
|
|
87
|
-
</div>
|
|
88
|
-
|
|
89
|
-
```js
|
|
90
|
-
<Jumbotron
|
|
91
|
-
variant="default"
|
|
92
|
-
small
|
|
93
|
-
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
94
|
-
>
|
|
95
|
-
<p slot="subtitle"
|
|
96
|
-
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
97
|
-
>
|
|
98
|
-
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
99
|
-
</p>
|
|
100
|
-
</Jumbotron>
|
|
101
|
-
```
|
|
102
|
-
|
|
103
|
-
## Hero Variant
|
|
104
|
-
Perfect for page headers and key sections that need visual impact. Features a background image with gradient overlay and optional description and info text.
|
|
105
|
-
|
|
106
|
-
<div class="component-preview">
|
|
107
|
-
<Jumbotron
|
|
108
|
-
variant="hero"
|
|
109
|
-
title="<b>Main Hero</b> Title"
|
|
110
|
-
description="Detailed description of the hero section goes here."
|
|
111
|
-
info="<span>Additional</span> information can be displayed here"
|
|
112
|
-
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
113
|
-
/>
|
|
114
|
-
</div>
|
|
115
|
-
|
|
116
|
-
```js
|
|
117
|
-
<Jumbotron
|
|
118
|
-
variant="hero"
|
|
119
|
-
title="<b>Main Hero</b> Title"
|
|
120
|
-
description="Detailed description of the hero section goes here."
|
|
121
|
-
info="<span>Additional</span> information can be displayed here"
|
|
122
|
-
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
123
|
-
/>
|
|
124
|
-
```
|
|
125
|
-
|
|
126
|
-
### Hero Variant without image
|
|
127
|
-
When used without an image, the hero variant provides a clean, simple header with a solid background color.
|
|
128
|
-
|
|
129
|
-
<div class="component-preview">
|
|
130
|
-
<Jumbotron
|
|
131
|
-
variant="hero"
|
|
132
|
-
title="<b>Simple Hero</b> Title"
|
|
133
|
-
description="A clean and simple hero section without background image."
|
|
134
|
-
info="Perfect for text-focused content sections"
|
|
135
|
-
/>
|
|
136
|
-
</div>
|
|
137
|
-
|
|
138
|
-
```js
|
|
139
|
-
<Jumbotron
|
|
140
|
-
variant="hero"
|
|
141
|
-
title="<b>Simple Hero</b> Title"
|
|
142
|
-
description="A clean and simple hero section without background image."
|
|
143
|
-
info="Perfect for text-focused content sections"
|
|
144
|
-
/>
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
### Hero Variant with Different Backgrounds
|
|
148
|
-
Hero variant supports different background classes to match your design needs.
|
|
149
|
-
|
|
150
|
-
<div class="component-preview">
|
|
151
|
-
<Jumbotron
|
|
152
|
-
variant="hero"
|
|
153
|
-
title="<b>Blue Darker Background</b> (Default)"
|
|
154
|
-
description="Uses the default bg-blue-darker background"
|
|
155
|
-
/>
|
|
156
|
-
</div>
|
|
157
|
-
```js
|
|
158
|
-
<div class="component-preview">
|
|
159
|
-
<Jumbotron
|
|
160
|
-
variant="hero"
|
|
161
|
-
title="<b>Blue Darker Background</b> (Default)"
|
|
162
|
-
description="Uses the default bg-blue-darker background"
|
|
163
|
-
/>
|
|
164
|
-
</div>
|
|
165
|
-
```
|
|
166
|
-
<br/>
|
|
167
|
-
|
|
168
|
-
<div class="component-preview">
|
|
169
|
-
<Jumbotron
|
|
170
|
-
variant="hero"
|
|
171
|
-
title="<b>Blue Darkest Background</b>"
|
|
172
|
-
description="Uses blue-darkest background"
|
|
173
|
-
backgroundClass="bg-blue-darkest"
|
|
174
|
-
/>
|
|
175
|
-
</div>
|
|
176
|
-
```js
|
|
177
|
-
<div class="component-preview">
|
|
178
|
-
<Jumbotron
|
|
179
|
-
variant="hero"
|
|
180
|
-
title="<b>Blue Darkest Background</b>"
|
|
181
|
-
description="Uses blue-darkest background"
|
|
182
|
-
backgroundClass="bg-blue-darkest"
|
|
183
|
-
/>
|
|
184
|
-
</div>
|
|
185
|
-
```
|
|
186
|
-
<br/>
|
|
187
|
-
|
|
188
|
-
<div class="component-preview">
|
|
189
|
-
<Jumbotron
|
|
190
|
-
variant="hero"
|
|
191
|
-
title="<b>Accent Background</b>"
|
|
192
|
-
description="Uses accent-darker background"
|
|
193
|
-
backgroundClass="bg-accent-darker"
|
|
194
|
-
/>
|
|
195
|
-
</div>
|
|
196
|
-
|
|
197
|
-
```js
|
|
198
|
-
<div class="component-preview">
|
|
199
|
-
<Jumbotron
|
|
200
|
-
variant="hero"
|
|
201
|
-
title="<b>Accent Background</b>"
|
|
202
|
-
description="Uses accent-darker background"
|
|
203
|
-
backgroundClass="bg-accent-darker"
|
|
204
|
-
/>
|
|
205
|
-
</div>
|
|
206
|
-
```
|
|
207
|
-
<br/>
|
|
208
|
-
|
|
209
|
-
<div class="component-preview">
|
|
210
|
-
<Jumbotron
|
|
211
|
-
variant="hero"
|
|
212
|
-
title="<b>Gradient Background</b>"
|
|
213
|
-
description="Uses custom gradient background"
|
|
214
|
-
backgroundClass="bg-vw"
|
|
215
|
-
/>
|
|
216
|
-
</div>
|
|
217
|
-
```js
|
|
218
|
-
<div class="component-preview">
|
|
219
|
-
<Jumbotron
|
|
220
|
-
variant="hero"
|
|
221
|
-
title="<b>Gradient Background</b>"
|
|
222
|
-
description="Uses custom gradient background"
|
|
223
|
-
backgroundClass="bg-vw"
|
|
224
|
-
/>
|
|
225
|
-
</div>
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
## Post Variant (Full Overlay)
|
|
229
|
-
Designed for blog posts and articles, featuring a full-width image overlay with metadata support for author, date, and categories.
|
|
230
|
-
|
|
231
|
-
<div class="component-preview">
|
|
232
|
-
<Jumbotron
|
|
233
|
-
variant="post"
|
|
234
|
-
title="Blog Post Title"
|
|
235
|
-
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
236
|
-
categories={[
|
|
237
|
-
{ name: 'Technology', link: '#' },
|
|
238
|
-
{ name: 'Design', link: '#' }
|
|
239
|
-
]}
|
|
240
|
-
author={{
|
|
241
|
-
firstName: "John",
|
|
242
|
-
name: "John Doe"
|
|
243
|
-
}}
|
|
244
|
-
date="2024-02-12"
|
|
245
|
-
/>
|
|
246
|
-
</div>
|
|
247
|
-
|
|
248
|
-
```js
|
|
249
|
-
<Jumbotron
|
|
250
|
-
variant="post"
|
|
251
|
-
title="Blog Post Title"
|
|
252
|
-
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
253
|
-
categories={[
|
|
254
|
-
{ name: 'Technology', link: '#' },
|
|
255
|
-
{ name: 'Design', link: '#' }
|
|
256
|
-
]}
|
|
257
|
-
author={{
|
|
258
|
-
firstName: "John",
|
|
259
|
-
name: "John Doe"
|
|
260
|
-
}}
|
|
261
|
-
date="2024-02-12"
|
|
262
|
-
/>
|
|
263
|
-
```
|
|
264
|
-
|
|
265
|
-
## Post Split Variant
|
|
266
|
-
A two-column layout variant for posts where image and content need equal emphasis. Great for featured articles or important announcements.
|
|
267
|
-
|
|
268
|
-
<div class="component-preview pb-0 !block">
|
|
269
|
-
<Jumbotron
|
|
270
|
-
variant="post-split"
|
|
271
|
-
title="<b>Formatted</b> Blog Post Title <small>Lorem Ipsum</small>"
|
|
272
|
-
image="http://localhost:1234/_image?href=https%3A%2F%2Fimg.freepik.com%2Ffree-photo%2Fnature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg%3Fsize%3D960%26ext%3Djpg&w=1200&h=675&f=webp"
|
|
273
|
-
categories={[
|
|
274
|
-
{ name: 'Technology', link: '#' },
|
|
275
|
-
{ name: 'Design', link: '#' }
|
|
276
|
-
]}
|
|
277
|
-
author={{
|
|
278
|
-
firstName: "John",
|
|
279
|
-
name: "John Doe"
|
|
280
|
-
}}
|
|
281
|
-
date="2024-02-12"
|
|
282
|
-
/>
|
|
283
|
-
</div>
|
|
284
|
-
|
|
285
|
-
```js
|
|
286
|
-
<Jumbotron
|
|
287
|
-
variant="post-split"
|
|
288
|
-
title="<b>Formatted</b> Blog Post Title <small>Lorem Ipsum</small>"
|
|
289
|
-
image="path/to/image.jpg"
|
|
290
|
-
categories={[
|
|
291
|
-
{ name: 'Technology', link: '#' },
|
|
292
|
-
{ name: 'Design', link: '#' }
|
|
293
|
-
]}
|
|
294
|
-
author={{
|
|
295
|
-
firstName: "John",
|
|
296
|
-
name: "John Doe"
|
|
297
|
-
}}
|
|
298
|
-
date="2024-02-12"
|
|
299
|
-
/>
|
|
300
|
-
```
|
|
301
|
-
|
|
302
|
-
## Custom Intro Slot Example
|
|
303
|
-
Shows how to fully customize the header section using the intro slot. Useful for complex layouts or custom styling.
|
|
304
|
-
|
|
305
|
-
<div class="component-preview">
|
|
306
|
-
<Jumbotron variant="default" small>
|
|
307
|
-
<h2 slot="intro" class="text-3xl text-white sm:(text-3xl pt-0) md:text-4xl lg:text-5xl">
|
|
308
|
-
Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.
|
|
309
|
-
</h2>
|
|
310
|
-
<p slot="subtitle"
|
|
311
|
-
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
312
|
-
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
313
|
-
</Jumbotron>
|
|
314
|
-
</div>
|
|
315
|
-
|
|
316
|
-
```js
|
|
317
|
-
<Jumbotron variant="default" small>
|
|
318
|
-
<h2 slot="intro" class="text-3xl text-white sm:(text-3xl pt-0) md:text-4xl lg:text-5xl">
|
|
319
|
-
Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.
|
|
320
|
-
</h2>
|
|
321
|
-
<p slot="subtitle"
|
|
322
|
-
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
323
|
-
>
|
|
324
|
-
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
325
|
-
</p>
|
|
326
|
-
</Jumbotron>
|
|
327
|
-
```
|
|
328
|
-
|
|
329
|
-
## Component API
|
|
330
|
-
|
|
331
|
-
### Common Props
|
|
332
|
-
- `variant`: Layout variant ('default' | 'hero' | 'post' | 'post-split')
|
|
333
|
-
- default: 'default'
|
|
334
|
-
- `title`: Main heading text. Supports HTML markup for styling.
|
|
335
|
-
- `image`: Image URL (required for hero, post and post-split variants)
|
|
336
|
-
|
|
337
|
-
### Default & Hero Props
|
|
338
|
-
- `small`: Reduces vertical padding (useful for secondary content)
|
|
339
|
-
- `description`: Secondary text below title (hero variant only)
|
|
340
|
-
- `info`: Additional information text (hero variant only)
|
|
341
|
-
|
|
342
|
-
### Post Variants Props
|
|
343
|
-
- `date`: Publication date string
|
|
344
|
-
- `author`: Author information object
|
|
345
|
-
- `firstName`: Author's first name (used in title attribute)
|
|
346
|
-
- `name`: Full author name (displayed)
|
|
347
|
-
- `categories`: Array of category objects for post categorization
|
|
348
|
-
- `name`: Category display name
|
|
349
|
-
- `uri`: Category link URL
|
|
350
|
-
|
|
351
|
-
### Slots
|
|
352
|
-
- `intro`: Replaces the default title with custom content. Useful for complex headings or custom markup.
|
|
353
|
-
- `subtitle`: Additional content below the title. Supports markdown and HTML.
|
|
354
|
-
- `cta-content`: Call to action content (buttons, links etc.) - wrapped in centered container.
|
|
355
|
-
|
|
356
|
-
## Accessibility
|
|
357
|
-
- Use semantic HTML markup in slots
|
|
358
|
-
- Ensure proper contrast for text over background images
|
|
359
|
-
- Provide meaningful alt text for images
|
|
1
|
+
---
|
|
2
|
+
title: "Jumbotron"
|
|
3
|
+
layout: "../../layouts/MainLayout.astro"
|
|
4
|
+
---
|
|
5
|
+
import Jumbotron from '../../components/Jumbotron.astro'
|
|
6
|
+
import Button from '../../components/Button.vue'
|
|
7
|
+
|
|
8
|
+
# Jumbotron
|
|
9
|
+
|
|
10
|
+
A Jumbotron indicates a big box for calling extra attention to some special content or information. It provides various layouts through different variants to suit your content presentation needs.
|
|
11
|
+
|
|
12
|
+
## Table of Contents
|
|
13
|
+
- [Best Practices](#best-practices)
|
|
14
|
+
- [Responsive Behavior](#responsive-behavior)
|
|
15
|
+
- [Variants](#variants)
|
|
16
|
+
- [Default Variant](#default-variant-classic)
|
|
17
|
+
- [Small Variant](#small-variant)
|
|
18
|
+
- [Hero Variant](#hero-variant)
|
|
19
|
+
- [Post Variant](#post-variant-full-overlay)
|
|
20
|
+
- [Post Split Variant](#post-split-variant)
|
|
21
|
+
- [Component API](#component-api)
|
|
22
|
+
- [Accessibility](#accessibility)
|
|
23
|
+
|
|
24
|
+
## Best Practices
|
|
25
|
+
- Use the `default` variant for main content sections and general announcements
|
|
26
|
+
- Use the `hero` variant for page headers with background images and important messaging
|
|
27
|
+
- Use the `post` variant for blog posts and articles with full-width image overlays
|
|
28
|
+
- Use the `post-split` variant when you need to display image alongside content
|
|
29
|
+
- Consider using `small` prop for less important or secondary sections
|
|
30
|
+
|
|
31
|
+
## Responsive Behavior
|
|
32
|
+
The component adapts to different screen sizes:
|
|
33
|
+
- On mobile: Stacks content vertically, adjusts font sizes and padding
|
|
34
|
+
- On tablet: Optimizes layout and spacing
|
|
35
|
+
- On desktop: Full layout with optimal content width and spacing
|
|
36
|
+
|
|
37
|
+
## Default Variant (Classic)
|
|
38
|
+
The default variant is ideal for primary content sections. It supports custom intro, subtitle, and CTA content with centered layout.
|
|
39
|
+
|
|
40
|
+
<div class="component-preview !block">
|
|
41
|
+
<Jumbotron
|
|
42
|
+
variant="default"
|
|
43
|
+
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
44
|
+
>
|
|
45
|
+
<p slot="subtitle"
|
|
46
|
+
class="mt-3 text-base text-gray-200 sm:mt-5 text-lg md:text-xl lg:mx-0 md:mt-5"
|
|
47
|
+
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
48
|
+
<Fragment slot="cta-content">
|
|
49
|
+
<Button primary rounded href="#" title="short text">
|
|
50
|
+
Read More
|
|
51
|
+
</Button>
|
|
52
|
+
</Fragment>
|
|
53
|
+
</Jumbotron>
|
|
54
|
+
</div>
|
|
55
|
+
|
|
56
|
+
```js
|
|
57
|
+
<Jumbotron
|
|
58
|
+
variant="default"
|
|
59
|
+
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
60
|
+
>
|
|
61
|
+
<p slot="subtitle"
|
|
62
|
+
class="mt-3 text-base text-gray-200 sm:mt-5 text-lg md:text-xl lg:mx-0 md:mt-5"
|
|
63
|
+
>
|
|
64
|
+
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
65
|
+
</p>
|
|
66
|
+
<Fragment slot="cta-content">
|
|
67
|
+
<Button primary rounded href="#" title="short text">
|
|
68
|
+
Read More
|
|
69
|
+
</Button>
|
|
70
|
+
</Fragment>
|
|
71
|
+
</Jumbotron>
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
## Small Variant
|
|
75
|
+
A more compact version of the default variant, useful for secondary content sections or when vertical space is limited.
|
|
76
|
+
|
|
77
|
+
<div class="component-preview">
|
|
78
|
+
<Jumbotron
|
|
79
|
+
variant="default"
|
|
80
|
+
small
|
|
81
|
+
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
82
|
+
>
|
|
83
|
+
<p slot="subtitle"
|
|
84
|
+
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
85
|
+
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
86
|
+
</Jumbotron>
|
|
87
|
+
</div>
|
|
88
|
+
|
|
89
|
+
```js
|
|
90
|
+
<Jumbotron
|
|
91
|
+
variant="default"
|
|
92
|
+
small
|
|
93
|
+
title={`Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.`}
|
|
94
|
+
>
|
|
95
|
+
<p slot="subtitle"
|
|
96
|
+
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
97
|
+
>
|
|
98
|
+
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
99
|
+
</p>
|
|
100
|
+
</Jumbotron>
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
## Hero Variant
|
|
104
|
+
Perfect for page headers and key sections that need visual impact. Features a background image with gradient overlay and optional description and info text.
|
|
105
|
+
|
|
106
|
+
<div class="component-preview">
|
|
107
|
+
<Jumbotron
|
|
108
|
+
variant="hero"
|
|
109
|
+
title="<b>Main Hero</b> Title"
|
|
110
|
+
description="Detailed description of the hero section goes here."
|
|
111
|
+
info="<span>Additional</span> information can be displayed here"
|
|
112
|
+
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
113
|
+
/>
|
|
114
|
+
</div>
|
|
115
|
+
|
|
116
|
+
```js
|
|
117
|
+
<Jumbotron
|
|
118
|
+
variant="hero"
|
|
119
|
+
title="<b>Main Hero</b> Title"
|
|
120
|
+
description="Detailed description of the hero section goes here."
|
|
121
|
+
info="<span>Additional</span> information can be displayed here"
|
|
122
|
+
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
123
|
+
/>
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Hero Variant without image
|
|
127
|
+
When used without an image, the hero variant provides a clean, simple header with a solid background color.
|
|
128
|
+
|
|
129
|
+
<div class="component-preview">
|
|
130
|
+
<Jumbotron
|
|
131
|
+
variant="hero"
|
|
132
|
+
title="<b>Simple Hero</b> Title"
|
|
133
|
+
description="A clean and simple hero section without background image."
|
|
134
|
+
info="Perfect for text-focused content sections"
|
|
135
|
+
/>
|
|
136
|
+
</div>
|
|
137
|
+
|
|
138
|
+
```js
|
|
139
|
+
<Jumbotron
|
|
140
|
+
variant="hero"
|
|
141
|
+
title="<b>Simple Hero</b> Title"
|
|
142
|
+
description="A clean and simple hero section without background image."
|
|
143
|
+
info="Perfect for text-focused content sections"
|
|
144
|
+
/>
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
### Hero Variant with Different Backgrounds
|
|
148
|
+
Hero variant supports different background classes to match your design needs.
|
|
149
|
+
|
|
150
|
+
<div class="component-preview">
|
|
151
|
+
<Jumbotron
|
|
152
|
+
variant="hero"
|
|
153
|
+
title="<b>Blue Darker Background</b> (Default)"
|
|
154
|
+
description="Uses the default bg-blue-darker background"
|
|
155
|
+
/>
|
|
156
|
+
</div>
|
|
157
|
+
```js
|
|
158
|
+
<div class="component-preview">
|
|
159
|
+
<Jumbotron
|
|
160
|
+
variant="hero"
|
|
161
|
+
title="<b>Blue Darker Background</b> (Default)"
|
|
162
|
+
description="Uses the default bg-blue-darker background"
|
|
163
|
+
/>
|
|
164
|
+
</div>
|
|
165
|
+
```
|
|
166
|
+
<br/>
|
|
167
|
+
|
|
168
|
+
<div class="component-preview">
|
|
169
|
+
<Jumbotron
|
|
170
|
+
variant="hero"
|
|
171
|
+
title="<b>Blue Darkest Background</b>"
|
|
172
|
+
description="Uses blue-darkest background"
|
|
173
|
+
backgroundClass="bg-blue-darkest"
|
|
174
|
+
/>
|
|
175
|
+
</div>
|
|
176
|
+
```js
|
|
177
|
+
<div class="component-preview">
|
|
178
|
+
<Jumbotron
|
|
179
|
+
variant="hero"
|
|
180
|
+
title="<b>Blue Darkest Background</b>"
|
|
181
|
+
description="Uses blue-darkest background"
|
|
182
|
+
backgroundClass="bg-blue-darkest"
|
|
183
|
+
/>
|
|
184
|
+
</div>
|
|
185
|
+
```
|
|
186
|
+
<br/>
|
|
187
|
+
|
|
188
|
+
<div class="component-preview">
|
|
189
|
+
<Jumbotron
|
|
190
|
+
variant="hero"
|
|
191
|
+
title="<b>Accent Background</b>"
|
|
192
|
+
description="Uses accent-darker background"
|
|
193
|
+
backgroundClass="bg-accent-darker"
|
|
194
|
+
/>
|
|
195
|
+
</div>
|
|
196
|
+
|
|
197
|
+
```js
|
|
198
|
+
<div class="component-preview">
|
|
199
|
+
<Jumbotron
|
|
200
|
+
variant="hero"
|
|
201
|
+
title="<b>Accent Background</b>"
|
|
202
|
+
description="Uses accent-darker background"
|
|
203
|
+
backgroundClass="bg-accent-darker"
|
|
204
|
+
/>
|
|
205
|
+
</div>
|
|
206
|
+
```
|
|
207
|
+
<br/>
|
|
208
|
+
|
|
209
|
+
<div class="component-preview">
|
|
210
|
+
<Jumbotron
|
|
211
|
+
variant="hero"
|
|
212
|
+
title="<b>Gradient Background</b>"
|
|
213
|
+
description="Uses custom gradient background"
|
|
214
|
+
backgroundClass="bg-vw"
|
|
215
|
+
/>
|
|
216
|
+
</div>
|
|
217
|
+
```js
|
|
218
|
+
<div class="component-preview">
|
|
219
|
+
<Jumbotron
|
|
220
|
+
variant="hero"
|
|
221
|
+
title="<b>Gradient Background</b>"
|
|
222
|
+
description="Uses custom gradient background"
|
|
223
|
+
backgroundClass="bg-vw"
|
|
224
|
+
/>
|
|
225
|
+
</div>
|
|
226
|
+
|
|
227
|
+
|
|
228
|
+
## Post Variant (Full Overlay)
|
|
229
|
+
Designed for blog posts and articles, featuring a full-width image overlay with metadata support for author, date, and categories.
|
|
230
|
+
|
|
231
|
+
<div class="component-preview">
|
|
232
|
+
<Jumbotron
|
|
233
|
+
variant="post"
|
|
234
|
+
title="Blog Post Title"
|
|
235
|
+
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
236
|
+
categories={[
|
|
237
|
+
{ name: 'Technology', link: '#' },
|
|
238
|
+
{ name: 'Design', link: '#' }
|
|
239
|
+
]}
|
|
240
|
+
author={{
|
|
241
|
+
firstName: "John",
|
|
242
|
+
name: "John Doe"
|
|
243
|
+
}}
|
|
244
|
+
date="2024-02-12"
|
|
245
|
+
/>
|
|
246
|
+
</div>
|
|
247
|
+
|
|
248
|
+
```js
|
|
249
|
+
<Jumbotron
|
|
250
|
+
variant="post"
|
|
251
|
+
title="Blog Post Title"
|
|
252
|
+
image="https://img.freepik.com/free-photo/nature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg?size=1920&ext=jpg"
|
|
253
|
+
categories={[
|
|
254
|
+
{ name: 'Technology', link: '#' },
|
|
255
|
+
{ name: 'Design', link: '#' }
|
|
256
|
+
]}
|
|
257
|
+
author={{
|
|
258
|
+
firstName: "John",
|
|
259
|
+
name: "John Doe"
|
|
260
|
+
}}
|
|
261
|
+
date="2024-02-12"
|
|
262
|
+
/>
|
|
263
|
+
```
|
|
264
|
+
|
|
265
|
+
## Post Split Variant
|
|
266
|
+
A two-column layout variant for posts where image and content need equal emphasis. Great for featured articles or important announcements.
|
|
267
|
+
|
|
268
|
+
<div class="component-preview pb-0 !block">
|
|
269
|
+
<Jumbotron
|
|
270
|
+
variant="post-split"
|
|
271
|
+
title="<b>Formatted</b> Blog Post Title <small>Lorem Ipsum</small>"
|
|
272
|
+
image="http://localhost:1234/_image?href=https%3A%2F%2Fimg.freepik.com%2Ffree-photo%2Fnature-beauty-tropical-rainforest-adventure-tranquility-freshness-generated-by-artificial-intellingence_25030-62539.jpg%3Fsize%3D960%26ext%3Djpg&w=1200&h=675&f=webp"
|
|
273
|
+
categories={[
|
|
274
|
+
{ name: 'Technology', link: '#' },
|
|
275
|
+
{ name: 'Design', link: '#' }
|
|
276
|
+
]}
|
|
277
|
+
author={{
|
|
278
|
+
firstName: "John",
|
|
279
|
+
name: "John Doe"
|
|
280
|
+
}}
|
|
281
|
+
date="2024-02-12"
|
|
282
|
+
/>
|
|
283
|
+
</div>
|
|
284
|
+
|
|
285
|
+
```js
|
|
286
|
+
<Jumbotron
|
|
287
|
+
variant="post-split"
|
|
288
|
+
title="<b>Formatted</b> Blog Post Title <small>Lorem Ipsum</small>"
|
|
289
|
+
image="path/to/image.jpg"
|
|
290
|
+
categories={[
|
|
291
|
+
{ name: 'Technology', link: '#' },
|
|
292
|
+
{ name: 'Design', link: '#' }
|
|
293
|
+
]}
|
|
294
|
+
author={{
|
|
295
|
+
firstName: "John",
|
|
296
|
+
name: "John Doe"
|
|
297
|
+
}}
|
|
298
|
+
date="2024-02-12"
|
|
299
|
+
/>
|
|
300
|
+
```
|
|
301
|
+
|
|
302
|
+
## Custom Intro Slot Example
|
|
303
|
+
Shows how to fully customize the header section using the intro slot. Useful for complex layouts or custom styling.
|
|
304
|
+
|
|
305
|
+
<div class="component-preview">
|
|
306
|
+
<Jumbotron variant="default" small>
|
|
307
|
+
<h2 slot="intro" class="text-3xl text-white sm:(text-3xl pt-0) md:text-4xl lg:text-5xl">
|
|
308
|
+
Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.
|
|
309
|
+
</h2>
|
|
310
|
+
<p slot="subtitle"
|
|
311
|
+
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
312
|
+
>Nunc posuere massa eget turpis laoreet ultrices eget vel massa.</p>
|
|
313
|
+
</Jumbotron>
|
|
314
|
+
</div>
|
|
315
|
+
|
|
316
|
+
```js
|
|
317
|
+
<Jumbotron variant="default" small>
|
|
318
|
+
<h2 slot="intro" class="text-3xl text-white sm:(text-3xl pt-0) md:text-4xl lg:text-5xl">
|
|
319
|
+
Lorem ipsum dolor sit amet, <span class="text-accent-light">consectetur</span> adipiscing elit.
|
|
320
|
+
</h2>
|
|
321
|
+
<p slot="subtitle"
|
|
322
|
+
class="mt-5 sm:mt-8 sm:flex sm:justify-center"
|
|
323
|
+
>
|
|
324
|
+
Nunc posuere massa eget turpis laoreet ultrices eget vel massa.
|
|
325
|
+
</p>
|
|
326
|
+
</Jumbotron>
|
|
327
|
+
```
|
|
328
|
+
|
|
329
|
+
## Component API
|
|
330
|
+
|
|
331
|
+
### Common Props
|
|
332
|
+
- `variant`: Layout variant ('default' | 'hero' | 'post' | 'post-split')
|
|
333
|
+
- default: 'default'
|
|
334
|
+
- `title`: Main heading text. Supports HTML markup for styling.
|
|
335
|
+
- `image`: Image URL (required for hero, post and post-split variants)
|
|
336
|
+
|
|
337
|
+
### Default & Hero Props
|
|
338
|
+
- `small`: Reduces vertical padding (useful for secondary content)
|
|
339
|
+
- `description`: Secondary text below title (hero variant only)
|
|
340
|
+
- `info`: Additional information text (hero variant only)
|
|
341
|
+
|
|
342
|
+
### Post Variants Props
|
|
343
|
+
- `date`: Publication date string
|
|
344
|
+
- `author`: Author information object
|
|
345
|
+
- `firstName`: Author's first name (used in title attribute)
|
|
346
|
+
- `name`: Full author name (displayed)
|
|
347
|
+
- `categories`: Array of category objects for post categorization
|
|
348
|
+
- `name`: Category display name
|
|
349
|
+
- `uri`: Category link URL
|
|
350
|
+
|
|
351
|
+
### Slots
|
|
352
|
+
- `intro`: Replaces the default title with custom content. Useful for complex headings or custom markup.
|
|
353
|
+
- `subtitle`: Additional content below the title. Supports markdown and HTML.
|
|
354
|
+
- `cta-content`: Call to action content (buttons, links etc.) - wrapped in centered container.
|
|
355
|
+
|
|
356
|
+
## Accessibility
|
|
357
|
+
- Use semantic HTML markup in slots
|
|
358
|
+
- Ensure proper contrast for text over background images
|
|
359
|
+
- Provide meaningful alt text for images
|
|
360
360
|
- Title text supports HTML markup for better semantics and styling
|