slidev-theme-neversink 0.3.2 → 0.3.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.
@@ -1,6 +1,5 @@
1
1
  <script setup>
2
2
  import { computed } from 'vue'
3
- //import { resolveColor } from '../layoutHelper'
4
3
  const props = defineProps({
5
4
  color: {
6
5
  type: String,
package/layoutHelper.ts CHANGED
@@ -1,41 +1,41 @@
1
1
  import type { CSSProperties } from 'vue'
2
- import { colors } from '@unocss/preset-mini'
2
+ // import { colors } from '@unocss/preset-mini'
3
3
 
4
- export function resolveColor(colorName: string, defaultColor: string = '#000000'): string {
5
- // If the input is already a hex code, return it
6
- if (/^#([0-9A-F]{3}){1,2}$/i.test(colorName)) {
7
- return colorName
8
- }
4
+ // export function resolveColor(colorName: string, defaultColor: string = '#000000'): string {
5
+ // // If the input is already a hex code, return it
6
+ // if (/^#([0-9A-F]{3}){1,2}$/i.test(colorName)) {
7
+ // return colorName
8
+ // }
9
9
 
10
- // Split the color name into base and shade
11
- const [baseColor, shade] = colorName.toLowerCase().split('-')
10
+ // // Split the color name into base and shade
11
+ // const [baseColor, shade] = colorName.toLowerCase().split('-')
12
12
 
13
- // Function to find the color in the colors object
14
- function findColor(obj: any, base: string, shade?: string): string | null {
15
- if (base in obj) {
16
- if (shade && typeof obj[base] === 'object' && shade in obj[base]) {
17
- return obj[base][shade]
18
- } else if (!shade && typeof obj[base] === 'string') {
19
- return obj[base]
20
- }
21
- }
13
+ // // Function to find the color in the colors object
14
+ // function findColor(obj: any, base: string, shade?: string): string | null {
15
+ // if (base in obj) {
16
+ // if (shade && typeof obj[base] === 'object' && shade in obj[base]) {
17
+ // return obj[base][shade]
18
+ // } else if (!shade && typeof obj[base] === 'string') {
19
+ // return obj[base]
20
+ // }
21
+ // }
22
22
 
23
- for (const value of Object.values(obj)) {
24
- if (typeof value === 'object' && value !== null) {
25
- const result = findColor(value, base, shade)
26
- if (result) return result
27
- }
28
- }
23
+ // for (const value of Object.values(obj)) {
24
+ // if (typeof value === 'object' && value !== null) {
25
+ // const result = findColor(value, base, shade)
26
+ // if (result) return result
27
+ // }
28
+ // }
29
29
 
30
- return null
31
- }
30
+ // return null
31
+ // }
32
32
 
33
- // Search for the color in the UnoCSS colors object
34
- const hexCode = findColor(colors, baseColor, shade)
33
+ // // Search for the color in the UnoCSS colors object
34
+ // const hexCode = findColor(colors, baseColor, shade)
35
35
 
36
- // If a valid color is found, return its hex code; otherwise, return the default color
37
- return hexCode || defaultColor
38
- }
36
+ // // If a valid color is found, return its hex code; otherwise, return the default color
37
+ // return hexCode || defaultColor
38
+ // }
39
39
 
40
40
  /**
41
41
  * Resolve urls from frontmatter and append with the base url
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "slidev-theme-neversink",
3
- "version": "0.3.2",
3
+ "version": "0.3.4",
4
4
  "author": "gureckis",
5
5
  "type": "module",
6
6
  "keywords": [
@@ -9,7 +9,7 @@
9
9
  ],
10
10
  "engines": {
11
11
  "node": ">=18.0.0",
12
- "slidev": ">=0.49.16"
12
+ "slidev": ">=0.49.21"
13
13
  },
14
14
  "dependencies": {
15
15
  "@iconify-json/logos": "^1.1.42",
@@ -19,7 +19,7 @@
19
19
  "@iconify/json": "^2.2.221",
20
20
  "@iconify/vue": "^4.1.2",
21
21
  "@mdit/plugin-sub": "^0.12.0",
22
- "@slidev/types": "^0.49.16",
22
+ "@slidev/types": "^0.49.21",
23
23
  "markdown-it-mark": "^4.0.0",
24
24
  "qrcode.vue": "^3.4.1"
25
25
  },
@@ -36,9 +36,9 @@
36
36
  "highlighter": "all"
37
37
  },
38
38
  "devDependencies": {
39
- "pnpm": "^9.4.0",
39
+ "pnpm": "^9.6.0",
40
40
  "vitepress": "^1.2.3",
41
- "@slidev/cli": "^0.49.16",
41
+ "@slidev/cli": "^0.49.21",
42
42
  "playwright-chromium": "^1.45.0",
43
43
  "bumpp": "^9.4.1"
44
44
  },
package/uno.config.ts CHANGED
@@ -195,8 +195,9 @@ export default defineConfig({
195
195
  'w-150px',
196
196
  'h-150px',
197
197
  'z-0',
198
- 'z-100',
199
- ] /* for the docs */,
198
+ 'z-100' /* for the docs */,
199
+ 'grid-cols-[1fr_max-content]' /* a fix for a uno bug */,
200
+ ],
200
201
  ],
201
202
  transformers: [transformerDirectives()],
202
203
  })