lapikit 0.0.0-insiders.443fd4d → 0.0.0-insiders.450e885

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,5 +1,5 @@
1
1
  <script lang="ts">
2
- import { BROWSER } from 'esm-env';
2
+ const BROWSER = typeof window !== 'undefined';
3
3
  import type { Snippet } from 'svelte';
4
4
  import { useTheme } from '../../actions/use-theme.js';
5
5
  import { modalOpen, setOpenModal } from '../../stores/components.js';
@@ -58,7 +58,7 @@
58
58
  }
59
59
 
60
60
  .kit-card[breakpoint]kit-card--variant-outline {
61
- --card-color: var(--base, var(--kit-label-primary));
61
+ --card-color: var(--card-background, var(--kit-label-primary));
62
62
  background-color: transparent;
63
63
  }
64
64
  .kit-card[breakpoint]kit-card--variant-outline::before {
@@ -71,7 +71,7 @@
71
71
  }
72
72
 
73
73
  .kit-card[breakpoint]kit-card--variant-text {
74
- --card-color: var(--base, var(--kit-label-primary));
74
+ --card-color: var(--card-background, var(--kit-label-primary));
75
75
  background-color: transparent;
76
76
  border: none;
77
77
  }
@@ -20,6 +20,8 @@
20
20
  color,
21
21
  background,
22
22
  noRipple,
23
+ width,
24
+ height,
23
25
  ...rest
24
26
  }: CardProps = $props();
25
27
 
@@ -58,6 +60,8 @@
58
60
  style:--card-background={assets.color(background)}
59
61
  style:--card-color={assets.color(color)}
60
62
  style:--card-shape={assets.shape(rounded)}
63
+ style:width
64
+ style:height
61
65
  >
62
66
  {@render children?.()}
63
67
  </svelte:element>
@@ -14,5 +14,7 @@ export interface CardProps extends Component {
14
14
  rounded?: string;
15
15
  color?: string;
16
16
  background?: string;
17
+ width?: string | number;
18
+ height?: string | number;
17
19
  }
18
20
  export {};
@@ -5,15 +5,30 @@
5
5
  max-height: 0px;
6
6
  opacity: var(--separator-opacity, 0.12);
7
7
  transition: inherit;
8
- border-color: var(--separator-color, var(--kit-state-shadow));
8
+ border-color: var(--separator-color, var(--kit-label-primary));
9
9
  border-style: solid;
10
10
  }
11
11
 
12
+ .kit-separator--inset:not(.kit-separator--orientation-vertical) {
13
+ max-width: calc(100% - 4.5rem);
14
+ margin-inline-start: 4.5rem;
15
+ }
16
+
17
+ .kit-separator--inset.kit-separator--orientation-vertical {
18
+ margin-bottom: 0.5rem;
19
+ margin-top: 0.5rem;
20
+ max-height: calc(100% - 1rem);
21
+ }
22
+
12
23
  .kit-separator:not(.kit-separator--orientation-vertical) {
24
+ width: 100%;
25
+ }
26
+
27
+ .kit-separator[breakpoint]kit-separator--orientation-horizontal {
13
28
  border-width: var(--separator-top-width, thin) 0 0 0;
14
29
  }
15
30
 
16
- .kit-separator--orientation-vertical {
31
+ .kit-separator[breakpoint]kit-separator--orientation-vertical {
17
32
  align-self: stretch;
18
33
  border-width: 0 thin 0 0;
19
34
  display: inline-flex;
@@ -25,18 +40,3 @@
25
40
  width: 0px;
26
41
  border-width: 0 var(--separator-right-width, thin) 0 0;
27
42
  }
28
-
29
- .kit-separator--inset:not(.kit-separator--orientation-vertical) {
30
- max-width: calc(100% - 4.5rem);
31
- margin-inline-start: 4.5rem;
32
- }
33
-
34
- .kit-separator--inset.kit-separator--orientation-vertical {
35
- margin-bottom: 0.5rem;
36
- margin-top: 0.5rem;
37
- max-height: calc(100% - 1rem);
38
- }
39
-
40
- .kit-separator:not(.kit-separator--orientation-vertical) {
41
- width: 100%;
42
- }
@@ -28,7 +28,7 @@
28
28
  orientation && assets.className('separator', 'orientation', orientation),
29
29
  rest.class
30
30
  ]}
31
- aria-orientation={orientation}
31
+ aria-orientation={typeof orientation === 'string' ? orientation : undefined}
32
32
  role="separator"
33
33
  style:--separator-color={assets.color(color)}
34
34
  style:--separator-opacity={opacity}
@@ -1,4 +1,5 @@
1
1
  import type { Base } from '../../internal/types/index.js';
2
+ type Orientation = 'horizontal' | 'vertical';
2
3
  export interface SeparatorProps extends Base {
3
4
  is?: 'div' | 'hr';
4
5
  light?: boolean;
@@ -7,5 +8,8 @@ export interface SeparatorProps extends Base {
7
8
  thickness?: string;
8
9
  opacity?: string | number;
9
10
  color?: string;
10
- orientation?: 'horizontal' | 'vertical';
11
+ orientation?: Orientation | {
12
+ [key: string]: Orientation;
13
+ };
11
14
  }
15
+ export {};
@@ -1,6 +1,5 @@
1
- import { BROWSER } from 'esm-env';
2
1
  export function disabledScroll(state) {
3
- if (BROWSER) {
2
+ if (typeof window !== 'undefined' && typeof document !== 'undefined') {
4
3
  document.body.style.overflow = state ? 'hidden' : '';
5
4
  }
6
5
  }
package/package.json CHANGED
@@ -1,101 +1,101 @@
1
1
  {
2
- "name": "lapikit",
3
- "version": "0.0.0-insiders.443fd4d",
4
- "license": "MIT",
5
- "publishConfig": {
6
- "access": "public"
7
- },
8
- "homepage": "https://lapikit.dev",
9
- "repository": {
10
- "type": "git",
11
- "url": "git+https://github.com/Nycolaide/lapikit.git",
12
- "directory": "packages/lapikit"
13
- },
14
- "scripts": {
15
- "dev": "vite dev",
16
- "build": "vite build && npm run prepack",
17
- "preview": "vite preview",
18
- "prepare": "svelte-kit sync || echo ''",
19
- "prepack": "svelte-kit sync && svelte-package && publint",
20
- "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
21
- "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
22
- "format": "prettier --write .",
23
- "lint": "prettier --check . && eslint .",
24
- "test:unit": "vitest",
25
- "test": "npm run test:unit -- --run"
26
- },
27
- "files": [
28
- "bin",
29
- "dist",
30
- "README.md",
31
- "LICENSE",
32
- "!dist/**/*.test.*",
33
- "!dist/**/*.spec.*"
34
- ],
35
- "sideEffects": [
36
- "**/*.css"
37
- ],
38
- "bin": {
39
- "lapikit": "bin/index.js"
40
- },
41
- "svelte": "./dist/index.js",
42
- "types": "./dist/index.d.ts",
43
- "type": "module",
44
- "exports": {
45
- ".": {
46
- "types": "./dist/index.d.ts",
47
- "svelte": "./dist/index.js"
48
- },
49
- "./components": {
50
- "svelte": "./dist/components/index.js",
51
- "default": "./dist/components/index.js"
52
- },
53
- "./vite": {
54
- "default": "./dist/internal/plugins/vite.js"
55
- },
56
- "./stores": {
57
- "default": "./dist/stores/index.js"
58
- },
59
- "./actions": {
60
- "default": "./dist/actions/index.js"
61
- },
62
- "./core/colors": {
63
- "default": "./dist/internal/core/standard-colors.js"
64
- },
65
- "./styles": "./dist/styles.css",
66
- "./themes": "./dist/themes.css"
67
- },
68
- "peerDependencies": {
69
- "svelte": "^5.0.0"
70
- },
71
- "devDependencies": {
72
- "@eslint/compat": "^1.2.5",
73
- "@eslint/js": "^9.18.0",
74
- "@sveltejs/adapter-auto": "^4.0.0",
75
- "@sveltejs/kit": "^2.16.0",
76
- "@sveltejs/package": "^2.0.0",
77
- "@sveltejs/vite-plugin-svelte": "^5.0.0",
78
- "@testing-library/jest-dom": "^6.6.3",
79
- "@testing-library/svelte": "^5.2.4",
80
- "eslint": "^9.18.0",
81
- "eslint-config-prettier": "^10.0.1",
82
- "eslint-plugin-svelte": "^3.0.0",
83
- "globals": "^16.0.0",
84
- "jsdom": "^26.0.0",
85
- "prettier": "^3.4.2",
86
- "prettier-plugin-svelte": "^3.3.3",
87
- "publint": "^0.3.2",
88
- "svelte": "^5.0.0",
89
- "svelte-check": "^4.0.0",
90
- "typescript": "^5.0.0",
91
- "typescript-eslint": "^8.20.0",
92
- "vite": "^6.2.5",
93
- "vitest": "^3.0.0"
94
- },
95
- "keywords": [
96
- "svelte"
97
- ],
98
- "dependencies": {
99
- "prompts": "^2.4.2"
100
- }
2
+ "name": "lapikit",
3
+ "version": "0.0.0-insiders.450e885",
4
+ "license": "MIT",
5
+ "publishConfig": {
6
+ "access": "public"
7
+ },
8
+ "homepage": "https://lapikit.dev",
9
+ "repository": {
10
+ "type": "git",
11
+ "url": "git+https://github.com/Nycolaide/lapikit.git",
12
+ "directory": "packages/lapikit"
13
+ },
14
+ "scripts": {
15
+ "dev": "vite dev",
16
+ "build": "vite build && npm run prepack",
17
+ "preview": "vite preview",
18
+ "prepare": "svelte-kit sync || echo ''",
19
+ "prepack": "svelte-kit sync && svelte-package && publint",
20
+ "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json",
21
+ "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch",
22
+ "format": "prettier --write .",
23
+ "lint": "prettier --check . && eslint .",
24
+ "test:unit": "vitest",
25
+ "test": "npm run test:unit -- --run"
26
+ },
27
+ "files": [
28
+ "bin",
29
+ "dist",
30
+ "README.md",
31
+ "LICENSE",
32
+ "!dist/**/*.test.*",
33
+ "!dist/**/*.spec.*"
34
+ ],
35
+ "sideEffects": [
36
+ "**/*.css"
37
+ ],
38
+ "bin": {
39
+ "lapikit": "bin/index.js"
40
+ },
41
+ "svelte": "./dist/index.js",
42
+ "types": "./dist/index.d.ts",
43
+ "type": "module",
44
+ "exports": {
45
+ ".": {
46
+ "types": "./dist/index.d.ts",
47
+ "svelte": "./dist/index.js"
48
+ },
49
+ "./components": {
50
+ "svelte": "./dist/components/index.js",
51
+ "default": "./dist/components/index.js"
52
+ },
53
+ "./vite": {
54
+ "default": "./dist/internal/plugins/vite.js"
55
+ },
56
+ "./stores": {
57
+ "default": "./dist/stores/index.js"
58
+ },
59
+ "./actions": {
60
+ "default": "./dist/actions/index.js"
61
+ },
62
+ "./core/colors": {
63
+ "default": "./dist/internal/core/standard-colors.js"
64
+ },
65
+ "./styles": "./dist/styles.css",
66
+ "./themes": "./dist/themes.css"
67
+ },
68
+ "peerDependencies": {
69
+ "svelte": "^5.0.0"
70
+ },
71
+ "devDependencies": {
72
+ "@eslint/compat": "^1.2.5",
73
+ "@eslint/js": "^9.18.0",
74
+ "@sveltejs/adapter-auto": "^4.0.0",
75
+ "@sveltejs/kit": "^2.16.0",
76
+ "@sveltejs/package": "^2.0.0",
77
+ "@sveltejs/vite-plugin-svelte": "^5.0.0",
78
+ "@testing-library/jest-dom": "^6.6.3",
79
+ "@testing-library/svelte": "^5.2.4",
80
+ "eslint": "^9.18.0",
81
+ "eslint-config-prettier": "^10.0.1",
82
+ "eslint-plugin-svelte": "^3.0.0",
83
+ "globals": "^16.0.0",
84
+ "jsdom": "^26.0.0",
85
+ "prettier": "^3.4.2",
86
+ "prettier-plugin-svelte": "^3.3.3",
87
+ "publint": "^0.3.2",
88
+ "svelte": "^5.0.0",
89
+ "svelte-check": "^4.0.0",
90
+ "typescript": "^5.0.0",
91
+ "typescript-eslint": "^8.20.0",
92
+ "vite": "^6.2.5",
93
+ "vitest": "^3.0.0"
94
+ },
95
+ "keywords": [
96
+ "svelte"
97
+ ],
98
+ "dependencies": {
99
+ "prompts": "^2.4.2"
100
+ }
101
101
  }