spoko-design-system 1.1.3 → 1.1.4
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/CHANGELOG.md +6 -0
- package/package.json +1 -1
- package/src/components/Card.astro +1 -1
- package/src/components/Category/CategoriesCarousel.astro +1 -1
- package/src/components/Category/CategoryDetails.astro +2 -10
- package/src/components/LeftSidebar.astro +1 -1
- package/src/components/Product/ProductCarousel.astro +1 -1
- package/src/components/Product/ProductNumber.astro +0 -1
- package/src/components/ProductTile.astro +1 -1
- package/src/components/layout/Header.astro +1 -1
- package/src/pages/components/icons.astro +0 -6
- package/src/utils/category/getMainCategoryList.ts +1 -1
- package/src/utils/product/getPriceFormatted.ts +6 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
## [1.1.4](https://github.com/polo-blue/sds/compare/v1.1.3...v1.1.4) (2025-09-23)
|
|
2
|
+
|
|
3
|
+
### Bug Fixes
|
|
4
|
+
|
|
5
|
+
* remove unused variables and improve TypeScript types ([db637f6](https://github.com/polo-blue/sds/commit/db637f6829bb2a23342a35d8041e803d4c9ad9c4))
|
|
6
|
+
|
|
1
7
|
## [1.1.3](https://github.com/polo-blue/sds/compare/v1.1.2...v1.1.3) (2025-09-23)
|
|
2
8
|
|
|
3
9
|
### Bug Fixes
|
package/package.json
CHANGED
|
@@ -3,16 +3,8 @@ import CategorySidebarToggler from './CategorySidebarToggler.vue';
|
|
|
3
3
|
import CategoryViewToggler from './CategoryViewToggler.astro';
|
|
4
4
|
import { Icon } from 'astro-icon/components';
|
|
5
5
|
|
|
6
|
-
const {
|
|
7
|
-
|
|
8
|
-
subcategory,
|
|
9
|
-
subtitle,
|
|
10
|
-
subsubtitle,
|
|
11
|
-
titleSmall,
|
|
12
|
-
locale,
|
|
13
|
-
showViewToggler,
|
|
14
|
-
viewerLabels,
|
|
15
|
-
} = Astro.props;
|
|
6
|
+
const { category, subcategory, subtitle, subsubtitle, titleSmall, showViewToggler, viewerLabels } =
|
|
7
|
+
Astro.props;
|
|
16
8
|
|
|
17
9
|
const baseURL = '';
|
|
18
10
|
---
|
|
@@ -44,7 +44,7 @@ const getLinkClasses = link => {
|
|
|
44
44
|
</Astronav>
|
|
45
45
|
|
|
46
46
|
<script is:inline>
|
|
47
|
-
window.addEventListener('DOMContentLoaded',
|
|
47
|
+
window.addEventListener('DOMContentLoaded', () => {
|
|
48
48
|
var target = document.querySelector('[aria-current="page"]');
|
|
49
49
|
if (target && target.offsetTop > window.innerHeight - 100) {
|
|
50
50
|
document.querySelector('.nav-groups').scrollTop = target.offsetTop;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import ProductLink from './ProductLink.astro';
|
|
3
3
|
|
|
4
4
|
// Get the product directly from the prop on render
|
|
5
|
-
const { locale,
|
|
5
|
+
const { locale, products, isShopProduct = false } = Astro.props;
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
{
|
|
@@ -32,7 +32,7 @@ const navItemsLeft = [
|
|
|
32
32
|
<div class="hidden sm:block sm:ml-6">
|
|
33
33
|
<div class="flex space-x-4" itemprop="hasPart">
|
|
34
34
|
{
|
|
35
|
-
navItemsLeft.map(({ title, description, url
|
|
35
|
+
navItemsLeft.map(({ title, description, url }) => (
|
|
36
36
|
<a
|
|
37
37
|
href={url}
|
|
38
38
|
class="text-gray-400 hover:bg-blue-darker hover:text-white px-3 py-1 rounded-full text-sm font-medium"
|
|
@@ -6,12 +6,6 @@ import { iconConfig } from '../../../icon.config';
|
|
|
6
6
|
const iconifyUrl = 'https://icon-sets.iconify.design/';
|
|
7
7
|
const ICONS = iconConfig.include;
|
|
8
8
|
|
|
9
|
-
type IconGroup = {
|
|
10
|
-
name: string;
|
|
11
|
-
icons: string[];
|
|
12
|
-
url: string;
|
|
13
|
-
};
|
|
14
|
-
|
|
15
9
|
const sortedIconCollections = Object.entries(ICONS)
|
|
16
10
|
.sort(([a], [b]) => a.localeCompare(b))
|
|
17
11
|
.map(([name, icons]) => ({
|
|
@@ -4,7 +4,7 @@ import { getApiCategories } from '@utils/api/getCategories';
|
|
|
4
4
|
import { getSortedCategories } from '@utils/category/getSortedCategories';
|
|
5
5
|
|
|
6
6
|
// Retrieve main categories:
|
|
7
|
-
export const getMainCategoryList = async (
|
|
7
|
+
export const getMainCategoryList = async (): Promise<CatObject[]> => {
|
|
8
8
|
// Fetch categories from API
|
|
9
9
|
const categories = await getApiCategories();
|
|
10
10
|
|
|
@@ -1,4 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
interface Product {
|
|
2
|
+
price_eur?: number;
|
|
3
|
+
price_pln?: number;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export const getPriceFormatted = (product: Product) => {
|
|
2
7
|
// Default to EUR formatting for English-only design system
|
|
3
8
|
if (product.price_eur) {
|
|
4
9
|
return new Intl.NumberFormat('de-DE', { style: 'currency', currency: 'EUR' }).format(
|