spoko-design-system 1.11.4 → 1.12.0
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/.github/workflows/deploy.yml +6 -1
- package/CHANGELOG.md +12 -0
- package/package.json +19 -19
- package/src/components/Jumbotron/index.astro +15 -1
- package/src/components/Jumbotron/variants/PostSplit.astro +9 -3
- package/src/pages/components/jumbotron.mdx +32 -0
- package/uno-config/theme/shortcuts/jumbotron.ts +1 -1
|
@@ -2,12 +2,17 @@ name: Deploy to GitHub Pages
|
|
|
2
2
|
|
|
3
3
|
on:
|
|
4
4
|
# Trigger the workflow every time you push to the `main` branch
|
|
5
|
-
# Using a different branch name? Replace `main` with your branch
|
|
5
|
+
# Using a different branch name? Replace `main` with your branch's name
|
|
6
6
|
push:
|
|
7
7
|
branches: [ main ]
|
|
8
8
|
# Allows you to run this workflow manually from the Actions tab on GitHub.
|
|
9
9
|
workflow_dispatch:
|
|
10
10
|
|
|
11
|
+
# Prevent concurrent deployments
|
|
12
|
+
concurrency:
|
|
13
|
+
group: pages
|
|
14
|
+
cancel-in-progress: false
|
|
15
|
+
|
|
11
16
|
# Allow this job to clone the repo and create a page deployment
|
|
12
17
|
permissions:
|
|
13
18
|
contents: read
|
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
## [1.12.0](https://github.com/polo-blue/sds/compare/v1.11.5...v1.12.0) (2025-12-06)
|
|
2
|
+
|
|
3
|
+
### Features
|
|
4
|
+
|
|
5
|
+
* **jumbotron:** add imageWidth, imageHeight and fullWidth props to post-split variant ([6d6ce17](https://github.com/polo-blue/sds/commit/6d6ce17ae7ce3ec444fbce3f4bda0aec57eb2d05))
|
|
6
|
+
|
|
7
|
+
## [1.11.5](https://github.com/polo-blue/sds/compare/v1.11.4...v1.11.5) (2025-11-19)
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **ci:** prevent concurrent GitHub Pages deployments ([7691c41](https://github.com/polo-blue/sds/commit/7691c417006711b3ec7b47300bbcc81abd303d3e))
|
|
12
|
+
|
|
1
13
|
## [1.11.4](https://github.com/polo-blue/sds/compare/v1.11.3...v1.11.4) (2025-11-19)
|
|
2
14
|
|
|
3
15
|
### Bug Fixes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "spoko-design-system",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.12.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "./index.ts",
|
|
@@ -55,8 +55,8 @@
|
|
|
55
55
|
],
|
|
56
56
|
"dependencies": {
|
|
57
57
|
"@algolia/client-search": "^5.44.0",
|
|
58
|
-
"@astrojs/mdx": "^4.3.
|
|
59
|
-
"@astrojs/node": "^9.5.
|
|
58
|
+
"@astrojs/mdx": "^4.3.11",
|
|
59
|
+
"@astrojs/node": "^9.5.1",
|
|
60
60
|
"@astrojs/sitemap": "^3.6.0",
|
|
61
61
|
"@astrojs/ts-plugin": "^1.10.5",
|
|
62
62
|
"@astrojs/vue": "^5.1.3",
|
|
@@ -83,24 +83,24 @@
|
|
|
83
83
|
"@iconify-json/noto-v1": "^1.2.5",
|
|
84
84
|
"@iconify-json/octicon": "^1.2.19",
|
|
85
85
|
"@iconify-json/ph": "^1.2.2",
|
|
86
|
-
"@iconify-json/simple-icons": "^1.2.
|
|
86
|
+
"@iconify-json/simple-icons": "^1.2.59",
|
|
87
87
|
"@iconify-json/streamline": "^1.2.5",
|
|
88
88
|
"@iconify-json/streamline-emojis": "^1.2.4",
|
|
89
89
|
"@iconify-json/streamline-freehand-color": "^1.2.2",
|
|
90
90
|
"@iconify-json/system-uicons": "^1.2.4",
|
|
91
91
|
"@iconify-json/uil": "^1.2.3",
|
|
92
|
-
"@iconify-json/vscode-icons": "^1.2.
|
|
93
|
-
"@iconify/json": "^2.2.
|
|
92
|
+
"@iconify-json/vscode-icons": "^1.2.35",
|
|
93
|
+
"@iconify/json": "^2.2.408",
|
|
94
94
|
"@iconify/vue": "^5.0.0",
|
|
95
95
|
"@playform/compress": "^0.2.0",
|
|
96
96
|
"@playform/inline": "^0.1.2",
|
|
97
|
-
"@unocss/astro": "66.5.
|
|
98
|
-
"@unocss/preset-attributify": "66.5.
|
|
99
|
-
"@unocss/preset-typography": "66.5.
|
|
100
|
-
"@unocss/preset-uno": "66.5.
|
|
101
|
-
"@unocss/preset-web-fonts": "66.5.
|
|
102
|
-
"@unocss/preset-wind": "66.5.
|
|
103
|
-
"@unocss/reset": "66.5.
|
|
97
|
+
"@unocss/astro": "66.5.7",
|
|
98
|
+
"@unocss/preset-attributify": "66.5.7",
|
|
99
|
+
"@unocss/preset-typography": "66.5.7",
|
|
100
|
+
"@unocss/preset-uno": "66.5.7",
|
|
101
|
+
"@unocss/preset-web-fonts": "66.5.7",
|
|
102
|
+
"@unocss/preset-wind": "66.5.7",
|
|
103
|
+
"@unocss/reset": "66.5.7",
|
|
104
104
|
"@vite-pwa/astro": "^1.1.1",
|
|
105
105
|
"@vueuse/core": "^14.0.0",
|
|
106
106
|
"astro-icon": "^1.1.5",
|
|
@@ -111,7 +111,7 @@
|
|
|
111
111
|
"dotenv": "^17.2.3",
|
|
112
112
|
"swiper": "^12.0.3",
|
|
113
113
|
"tippy.js": "^6.3.7",
|
|
114
|
-
"unocss": "66.5.
|
|
114
|
+
"unocss": "66.5.7",
|
|
115
115
|
"vite-plugin-pwa": "^1.1.0",
|
|
116
116
|
"vue": "^3.5.24"
|
|
117
117
|
},
|
|
@@ -122,13 +122,13 @@
|
|
|
122
122
|
"@semantic-release/git": "^10.0.1",
|
|
123
123
|
"@types/gtag.js": "^0.0.20",
|
|
124
124
|
"@types/node": "^24.10.1",
|
|
125
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
126
|
-
"@typescript-eslint/parser": "^8.
|
|
127
|
-
"@unocss/transformer-variant-group": "66.5.
|
|
128
|
-
"@vitejs/plugin-vue": "^6.0.
|
|
125
|
+
"@typescript-eslint/eslint-plugin": "^8.47.0",
|
|
126
|
+
"@typescript-eslint/parser": "^8.47.0",
|
|
127
|
+
"@unocss/transformer-variant-group": "66.5.7",
|
|
128
|
+
"@vitejs/plugin-vue": "^6.0.2",
|
|
129
129
|
"@vue/compiler-sfc": "^3.5.24",
|
|
130
130
|
"@vue/eslint-config-typescript": "^14.6.0",
|
|
131
|
-
"astro": "^5.15.
|
|
131
|
+
"astro": "^5.15.9",
|
|
132
132
|
"conventional-changelog-conventionalcommits": "^9.1.0",
|
|
133
133
|
"eslint": "^9.39.1",
|
|
134
134
|
"eslint-plugin-astro": "^1.5.0",
|
|
@@ -9,6 +9,8 @@ interface Props {
|
|
|
9
9
|
variant?: 'default' | 'hero' | 'post' | 'post-split';
|
|
10
10
|
title?: string;
|
|
11
11
|
image?: string;
|
|
12
|
+
imageWidth?: number;
|
|
13
|
+
imageHeight?: number;
|
|
12
14
|
small?: boolean;
|
|
13
15
|
description?: string;
|
|
14
16
|
info?: string;
|
|
@@ -17,12 +19,15 @@ interface Props {
|
|
|
17
19
|
categories?: Category[];
|
|
18
20
|
backgroundClass?: string;
|
|
19
21
|
lang?: string;
|
|
22
|
+
fullWidth?: boolean;
|
|
20
23
|
}
|
|
21
24
|
|
|
22
25
|
const {
|
|
23
26
|
variant = 'default',
|
|
24
27
|
title = '',
|
|
25
28
|
image,
|
|
29
|
+
imageWidth,
|
|
30
|
+
imageHeight,
|
|
26
31
|
small = false,
|
|
27
32
|
description,
|
|
28
33
|
info,
|
|
@@ -31,6 +36,7 @@ const {
|
|
|
31
36
|
categories = [],
|
|
32
37
|
backgroundClass = 'bg-blue-darker',
|
|
33
38
|
lang = 'en',
|
|
39
|
+
fullWidth = false,
|
|
34
40
|
} = Astro.props;
|
|
35
41
|
|
|
36
42
|
// Helper (function to check if a slot has content)
|
|
@@ -78,7 +84,15 @@ const commonProps = {
|
|
|
78
84
|
|
|
79
85
|
{
|
|
80
86
|
variant === 'post-split' && (
|
|
81
|
-
<PostSplitVariant
|
|
87
|
+
<PostSplitVariant
|
|
88
|
+
{...commonProps}
|
|
89
|
+
author={author}
|
|
90
|
+
date={date}
|
|
91
|
+
categories={categories}
|
|
92
|
+
imageWidth={imageWidth}
|
|
93
|
+
imageHeight={imageHeight}
|
|
94
|
+
fullWidth={fullWidth}
|
|
95
|
+
/>
|
|
82
96
|
)
|
|
83
97
|
}
|
|
84
98
|
|
|
@@ -7,23 +7,29 @@ import { Image } from 'astro:assets';
|
|
|
7
7
|
interface Props {
|
|
8
8
|
title?: string;
|
|
9
9
|
image?: string;
|
|
10
|
+
imageWidth?: number;
|
|
11
|
+
imageHeight?: number;
|
|
10
12
|
author?: Author;
|
|
11
13
|
date?: string;
|
|
12
14
|
categories?: Category[];
|
|
13
15
|
hasMetadata: boolean;
|
|
14
16
|
hasCategories: boolean;
|
|
15
17
|
lang: string;
|
|
18
|
+
fullWidth?: boolean;
|
|
16
19
|
}
|
|
17
20
|
|
|
18
21
|
const {
|
|
19
22
|
title = '',
|
|
20
23
|
image,
|
|
24
|
+
imageWidth = 768,
|
|
25
|
+
imageHeight = 432,
|
|
21
26
|
author,
|
|
22
27
|
date,
|
|
23
28
|
categories = [],
|
|
24
29
|
hasMetadata,
|
|
25
30
|
hasCategories,
|
|
26
31
|
lang = 'en',
|
|
32
|
+
fullWidth = false,
|
|
27
33
|
} = Astro.props;
|
|
28
34
|
|
|
29
35
|
// Helper function to remove HTML tags
|
|
@@ -35,7 +41,7 @@ const stripHtml = (html: string) => {
|
|
|
35
41
|
const cleanTitle = stripHtml(title);
|
|
36
42
|
---
|
|
37
43
|
|
|
38
|
-
<div class=
|
|
44
|
+
<div class:list={['jumbotron-split-wrapper bg-blue-900 bg-vw', { 'full-width-block': fullWidth }]}>
|
|
39
45
|
<div class="jumbotron-split-container">
|
|
40
46
|
<header class="jumbotron-split-header">
|
|
41
47
|
<div
|
|
@@ -76,8 +82,8 @@ const cleanTitle = stripHtml(title);
|
|
|
76
82
|
class="jumbotron-split-img"
|
|
77
83
|
src={image}
|
|
78
84
|
alt={cleanTitle}
|
|
79
|
-
width={
|
|
80
|
-
height={
|
|
85
|
+
width={imageWidth}
|
|
86
|
+
height={imageHeight}
|
|
81
87
|
loading="eager"
|
|
82
88
|
/>
|
|
83
89
|
</div>
|
|
@@ -299,6 +299,33 @@ A two-column layout variant for posts where image and content need equal emphasi
|
|
|
299
299
|
/>
|
|
300
300
|
```
|
|
301
301
|
|
|
302
|
+
### Post Split with Custom Image Dimensions
|
|
303
|
+
You can customize image dimensions using `imageWidth` and `imageHeight` props. This is useful for category pages with different aspect ratios (e.g., 3:2 instead of default 16:9).
|
|
304
|
+
|
|
305
|
+
```js
|
|
306
|
+
<Jumbotron
|
|
307
|
+
variant="post-split"
|
|
308
|
+
title="Category Title"
|
|
309
|
+
image="path/to/image.jpg"
|
|
310
|
+
imageWidth={600}
|
|
311
|
+
imageHeight={400}
|
|
312
|
+
/>
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
### Post Split Full Width
|
|
316
|
+
Use `fullWidth` prop to make the jumbotron span the full viewport width, useful for archive/category pages.
|
|
317
|
+
|
|
318
|
+
```js
|
|
319
|
+
<Jumbotron
|
|
320
|
+
variant="post-split"
|
|
321
|
+
title="Full Width Category"
|
|
322
|
+
image="path/to/image.jpg"
|
|
323
|
+
imageWidth={600}
|
|
324
|
+
imageHeight={400}
|
|
325
|
+
fullWidth
|
|
326
|
+
/>
|
|
327
|
+
```
|
|
328
|
+
|
|
302
329
|
## Custom Intro Slot Example
|
|
303
330
|
Shows how to fully customize the header section using the intro slot. Useful for complex layouts or custom styling.
|
|
304
331
|
|
|
@@ -348,6 +375,11 @@ Shows how to fully customize the header section using the intro slot. Useful for
|
|
|
348
375
|
- `name`: Category display name
|
|
349
376
|
- `uri`: Category link URL
|
|
350
377
|
|
|
378
|
+
### Post Split Props
|
|
379
|
+
- `imageWidth`: Custom image width in pixels (default: 768)
|
|
380
|
+
- `imageHeight`: Custom image height in pixels (default: 432)
|
|
381
|
+
- `fullWidth`: When true, adds `full-width-block` class for full viewport width
|
|
382
|
+
|
|
351
383
|
### Slots
|
|
352
384
|
- `intro`: Replaces the default title with custom content. Useful for complex headings or custom markup.
|
|
353
385
|
- `subtitle`: Additional content below the title. Supports markdown and HTML.
|
|
@@ -44,5 +44,5 @@ export const jumbotronShortcuts = [
|
|
|
44
44
|
['jumbotron-split-meta', 'order-3 flex items-center text-gray-100'],
|
|
45
45
|
['jumbotron-split-image-wrapper', 'relative -mb-8 md:(mt-4 -ml-4 mr-4) xl:(ml-0 mr-0)'],
|
|
46
46
|
['jumbotron-split-image', 'relative shadow-xl md:max-h-112'],
|
|
47
|
-
['jumbotron-split-img', '
|
|
47
|
+
['jumbotron-split-img', 'object-cover']
|
|
48
48
|
];
|