@scalar/components 0.5.1 → 0.5.2
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/dist/index.cjs +1 -1
- package/dist/index.d.ts +0 -60
- package/dist/index.js +323 -357
- package/package.json +7 -3
- package/src/tailwind/index.ts +1 -0
- package/src/tailwind/tailwind.theme.ts +62 -0
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"author": "Scalar (https://github.com/scalar)",
|
|
6
6
|
"homepage": "https://github.com/scalar/scalar",
|
|
7
7
|
"bugs": "https://github.com/scalar/scalar/issues/new/choose",
|
|
8
|
-
"version": "0.5.
|
|
8
|
+
"version": "0.5.2",
|
|
9
9
|
"engines": {
|
|
10
10
|
"node": ">=18"
|
|
11
11
|
},
|
|
@@ -16,10 +16,14 @@
|
|
|
16
16
|
".": {
|
|
17
17
|
"import": "./dist/index.js",
|
|
18
18
|
"require": "./dist/index.cjs"
|
|
19
|
+
},
|
|
20
|
+
"./tailwind": {
|
|
21
|
+
"import": "./src/tailwind/index.ts"
|
|
19
22
|
}
|
|
20
23
|
},
|
|
21
24
|
"files": [
|
|
22
|
-
"dist"
|
|
25
|
+
"dist",
|
|
26
|
+
"src/tailwind/**.ts"
|
|
23
27
|
],
|
|
24
28
|
"module": "./dist/index.js",
|
|
25
29
|
"dependencies": {
|
|
@@ -65,7 +69,7 @@
|
|
|
65
69
|
"vite-svg-loader": "^5.1.0",
|
|
66
70
|
"vitest": "^1.5.0",
|
|
67
71
|
"vue-tsc": "^1.8.19",
|
|
68
|
-
"@scalar/themes": "0.7.
|
|
72
|
+
"@scalar/themes": "0.7.3"
|
|
69
73
|
},
|
|
70
74
|
"peerDependencies": {
|
|
71
75
|
"vue": "^3.3.0"
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './tailwind.theme.ts'
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
export const theme = {
|
|
2
|
+
boxShadow: {
|
|
3
|
+
DEFAULT: 'var(--scalar-shadow-1)',
|
|
4
|
+
md: 'var(--scalar-shadow-2)',
|
|
5
|
+
sm: 'rgba(0, 0, 0, 0.09) 0px 1px 4px',
|
|
6
|
+
none: '0 0 #0000',
|
|
7
|
+
},
|
|
8
|
+
colors: {
|
|
9
|
+
'fore-1': 'var(--scalar-color-1)',
|
|
10
|
+
'fore-2': 'var(--scalar-color-2)',
|
|
11
|
+
'fore-3': 'var(--scalar-color-3)',
|
|
12
|
+
'accent': 'var(--scalar-color-accent)',
|
|
13
|
+
'back-1': 'var(--scalar-background-1)',
|
|
14
|
+
'back-2': 'var(--scalar-background-2)',
|
|
15
|
+
'back-3': 'var(--scalar-background-3)',
|
|
16
|
+
'back-accent': 'var(--scalar-background-accent)',
|
|
17
|
+
|
|
18
|
+
'backdrop': 'rgba(0, 0, 0, 0.44)',
|
|
19
|
+
'border': 'var(--scalar-border-color)',
|
|
20
|
+
|
|
21
|
+
'back-btn-1': 'var(--scalar-button-1)',
|
|
22
|
+
'fore-btn-1': 'var(--scalar-button-1-color)',
|
|
23
|
+
'hover-btn-1': 'var(--scalar-button-1-hover)',
|
|
24
|
+
|
|
25
|
+
'white': '#FFF',
|
|
26
|
+
'green': 'var(--scalar-color-green)',
|
|
27
|
+
'red': 'var(--scalar-color-red)',
|
|
28
|
+
'yellow': 'var(--scalar-color-yellow)',
|
|
29
|
+
'blue': 'var(--scalar-color-blue)',
|
|
30
|
+
'orange': 'var(--scalar-color-orange)',
|
|
31
|
+
'purple': 'var(--scalar-color-purple)',
|
|
32
|
+
'error': 'var(--scalar-error-color)',
|
|
33
|
+
'ghost': 'var(--scalar-color-ghost)',
|
|
34
|
+
'transparent': 'transparent',
|
|
35
|
+
},
|
|
36
|
+
} as const
|
|
37
|
+
|
|
38
|
+
export const extend = {
|
|
39
|
+
borderRadius: {
|
|
40
|
+
DEFAULT: 'var(--scalar-radius)',
|
|
41
|
+
md: 'var(--scalar-radius)',
|
|
42
|
+
lg: 'var(--scalar-radius-lg)',
|
|
43
|
+
xl: 'var(--scalar-radius-xl)',
|
|
44
|
+
},
|
|
45
|
+
fontSize: {
|
|
46
|
+
xxs: 'var(--scalar-micro, var(--scalar-font-size-5))',
|
|
47
|
+
xs: 'var(--scalar-mini, var(--scalar-font-size-4))',
|
|
48
|
+
sm: 'var(--scalar-small,var(--scalar-font-size-3))',
|
|
49
|
+
base: 'var(--scalar-paragraph, var(--scalar-font-size-2))',
|
|
50
|
+
lg: 'var(--scalar-font-size-1)',
|
|
51
|
+
},
|
|
52
|
+
fontWeight: {
|
|
53
|
+
medium: 'var(--scalar-font-medium)',
|
|
54
|
+
bold: 'var(--scalar-font-bold)',
|
|
55
|
+
},
|
|
56
|
+
maxWidth: {
|
|
57
|
+
'screen-xs': '480px',
|
|
58
|
+
'screen-sm': '540px',
|
|
59
|
+
'screen-md': '640px',
|
|
60
|
+
'screen-lg': '800px',
|
|
61
|
+
},
|
|
62
|
+
} as const
|