spoko-design-system 0.2.75 → 0.2.77

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/index.ts CHANGED
@@ -58,11 +58,11 @@ export { default as getShorterDescription } from './src/utils/seo/getShorterDesc
58
58
  // Utils: Text
59
59
 
60
60
  export { getTranslation, text2paragraphs, countWords, firstSentence, removeSemicolon } from './src/utils/text';
61
- export { apiInfo, getData } from './src/utils/getData';
61
+ // export { apiInfo, getData } from './src/utils/getData';
62
62
  export { default as formatDate } from './src/utils/text/formatDate';
63
63
  export { default as formatLocaleNumber } from './src/utils/text/formatLocaleNumber';
64
64
  export { default as formatPad } from './src/utils/text/formatPad';
65
65
  export { default as getNumberFormatted } from './src/utils/text/getNumberFormatted';
66
66
  export { default as getTranslatedLink } from './src/utils/text/getTranslatedLink';
67
- export { default as getApiCategories } from './src/utils/api/getCategories';
67
+ // export { default as getApiCategories } from './src/utils/api/getCategories';
68
68
  export { default as getEnvVariable } from './src/utils/getEnvVariable';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "spoko-design-system",
3
- "version": "0.2.75",
3
+ "version": "0.2.77",
4
4
  "private": false,
5
5
  "main": "./index.ts",
6
6
  "module": "./index.ts",
@@ -67,13 +67,13 @@
67
67
  "@playform/compress": "^0.1.6",
68
68
  "@playform/inline": "github:playform/inline",
69
69
  "@types/node": "^22.9.0",
70
- "@unocss/astro": "^0.64.0",
71
- "@unocss/preset-attributify": "^0.64.0",
72
- "@unocss/preset-typography": "^0.64.0",
73
- "@unocss/preset-uno": "^0.64.0",
74
- "@unocss/preset-web-fonts": "^0.64.0",
75
- "@unocss/preset-wind": "^0.64.0",
76
- "@unocss/reset": "^0.64.0",
70
+ "@unocss/astro": "^0.64.1",
71
+ "@unocss/preset-attributify": "^0.64.1",
72
+ "@unocss/preset-typography": "^0.64.1",
73
+ "@unocss/preset-uno": "^0.64.1",
74
+ "@unocss/preset-web-fonts": "^0.64.1",
75
+ "@unocss/preset-wind": "^0.64.1",
76
+ "@unocss/reset": "^0.64.1",
77
77
  "@vite-pwa/astro": "^0.4.3",
78
78
  "@vueuse/core": "^11.2.0",
79
79
  "astro-i18next": "1.0.0-beta.21",
@@ -89,12 +89,12 @@
89
89
  "i18next-http-backend": "^2.6.2",
90
90
  "i18next-vue": "^5.0.0",
91
91
  "swiper": "^11.1.14",
92
- "unocss": "^0.64.0",
92
+ "unocss": "^0.64.1",
93
93
  "vite": "^5.4.11",
94
94
  "vue": "^3.5.12"
95
95
  },
96
96
  "devDependencies": {
97
- "@unocss/transformer-variant-group": "^0.64.0",
97
+ "@unocss/transformer-variant-group": "^0.64.1",
98
98
  "@vitejs/plugin-vue": "^5.2.0",
99
99
  "astro": "^4.16.12",
100
100
  "unocss": "^0.60.0"
@@ -39,7 +39,7 @@ const activeIndex = activeCategorySlug && categories ? categories.map(a => a.slu
39
39
  <swiper-slide itemprop="hasPart" role="presentation"
40
40
  class={`swiper-slide cats-slide group ${category.slug === activeCategorySlug ? 'active': ''}`}
41
41
  >
42
- <a href={getTranslatedLink(`/${category.slug}/`, i18next.language)}
42
+ <a href={getTranslatedLink(`/${category.slug}/`)}
43
43
  class="carousel-item"
44
44
  >
45
45
  {
@@ -1,6 +1,7 @@
1
1
  ---
2
2
 
3
3
  import { Image } from "astro:assets";
4
+ import { getTranslatedLink } from "../../utils/text/getTranslatedLink"
4
5
 
5
6
  interface CategoryObject {
6
7
  photo: string;
@@ -11,18 +12,21 @@ interface CategoryObject {
11
12
  height?: number;
12
13
  width?: number;
13
14
  class?: string;
14
- url: string;
15
15
  }
16
16
 
17
+
18
+
17
19
  let inputProps = {};
18
- const { CategoryObject } = Astro.props as { CategoryObject: CategoryObject };
20
+ const { CategoryObject, locale='en' } = Astro.props as { CategoryObject: CategoryObject, locale: string };
19
21
  CategoryObject.height = CategoryObject.height ?? 70;
20
22
  CategoryObject.width = CategoryObject.width ?? 70;
21
23
 
24
+ const mainCategoryLink = getTranslatedLink(`/${CategoryObject.slug}/`, locale);
25
+
22
26
  ---
23
27
 
24
28
  <a
25
- href={CategoryObject.url}
29
+ href={mainCategoryLink}
26
30
  class="carousel-item"
27
31
  data-astro-prefetch
28
32
  {...inputProps}