@passui/tokens 0.0.0-stage → 0.1.0
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/LICENSE +21 -0
- package/README.md +7 -2
- package/package.json +57 -5
- package/src/accent.ts +166 -0
- package/src/color.ts +113 -0
- package/src/index.ts +6 -0
- package/src/layout.ts +34 -0
- package/src/motion.ts +31 -0
- package/src/theme-css.ts +127 -0
- package/src/typography.ts +99 -0
- package/styles/base.css +78 -0
- package/styles/styles.css +59 -0
- package/styles/typeset.css +726 -0
- package/styles/utilities.css +263 -0
- package/theme.css +316 -0
package/styles/base.css
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Passui base layer: global element defaults shared by every app.
|
|
3
|
+
* Import after the design tokens: `@import "@passui/tokens/base.css";`
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
@layer base {
|
|
7
|
+
* {
|
|
8
|
+
@apply border-separator outline-accent/50;
|
|
9
|
+
scrollbar-color: var(--color-separator) transparent;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
html {
|
|
13
|
+
@apply font-sans;
|
|
14
|
+
height: 100%;
|
|
15
|
+
-webkit-font-smoothing: antialiased;
|
|
16
|
+
-moz-osx-font-smoothing: grayscale;
|
|
17
|
+
text-rendering: optimizeLegibility;
|
|
18
|
+
-webkit-tap-highlight-color: transparent;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
body {
|
|
22
|
+
@apply bg-background text-label [&_svg:not([data-brand])]:dualTone;
|
|
23
|
+
height: 100%;
|
|
24
|
+
overscroll-behavior: none;
|
|
25
|
+
transition:
|
|
26
|
+
background-color var(--duration-normal) var(--ease-standard),
|
|
27
|
+
color var(--duration-normal) var(--ease-standard);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
input:-webkit-autofill,
|
|
31
|
+
input:-webkit-autofill:hover,
|
|
32
|
+
input:-webkit-autofill:focus,
|
|
33
|
+
textarea:-webkit-autofill,
|
|
34
|
+
textarea:-webkit-autofill:hover,
|
|
35
|
+
textarea:-webkit-autofill:focus {
|
|
36
|
+
-webkit-background-clip: text;
|
|
37
|
+
background-clip: text;
|
|
38
|
+
-webkit-text-fill-color: var(--color-label);
|
|
39
|
+
caret-color: var(--color-label);
|
|
40
|
+
transition: background-color 999999s ease-in-out 0s;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
button:not(:disabled),
|
|
44
|
+
[role="button"]:not(:disabled) {
|
|
45
|
+
cursor: pointer;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
:focus-visible {
|
|
49
|
+
outline: 2px solid var(--color-accent-text);
|
|
50
|
+
outline-offset: 2px;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
::selection {
|
|
54
|
+
background: color-mix(in srgb, var(--color-accent) 40%, transparent);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
input[type="number"]::-webkit-outer-spin-button,
|
|
58
|
+
input[type="number"]::-webkit-inner-spin-button {
|
|
59
|
+
-webkit-appearance: none;
|
|
60
|
+
margin: 0;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
input[type="number"] {
|
|
64
|
+
-moz-appearance: textfield;
|
|
65
|
+
appearance: textfield;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
@media (prefers-reduced-motion: reduce) {
|
|
70
|
+
*,
|
|
71
|
+
*::before,
|
|
72
|
+
*::after {
|
|
73
|
+
scroll-behavior: auto !important;
|
|
74
|
+
transition-duration: 0.01ms !important;
|
|
75
|
+
animation-duration: 0.01ms !important;
|
|
76
|
+
animation-iteration-count: 1 !important;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Passui's one stylesheet: Tailwind, the theme, utilities, base styles,
|
|
3
|
+
* and typeset. Framework packages register their own component sources.
|
|
4
|
+
*
|
|
5
|
+
* @import "@passui/tokens/styles.css";
|
|
6
|
+
*/
|
|
7
|
+
@import "tailwindcss";
|
|
8
|
+
@import "tw-animate-css";
|
|
9
|
+
@import "../theme.css";
|
|
10
|
+
@import "./utilities.css";
|
|
11
|
+
@import "./base.css";
|
|
12
|
+
@import "./typeset.css";
|
|
13
|
+
|
|
14
|
+
@custom-variant dark (&:is(.dark *));
|
|
15
|
+
|
|
16
|
+
/* Older role names some views still use, mapped onto Passui's roles. */
|
|
17
|
+
@theme inline {
|
|
18
|
+
--color-foreground: var(--color-label);
|
|
19
|
+
--color-muted: var(--color-fill);
|
|
20
|
+
--color-muted-foreground: var(--color-label-secondary);
|
|
21
|
+
--color-card: var(--color-elevated);
|
|
22
|
+
--color-card-foreground: var(--color-label);
|
|
23
|
+
--color-popover: var(--color-elevated);
|
|
24
|
+
--color-popover-foreground: var(--color-label);
|
|
25
|
+
--color-primary: var(--color-inverse);
|
|
26
|
+
--color-primary-foreground: var(--color-on-inverse);
|
|
27
|
+
--color-secondary: var(--color-fill);
|
|
28
|
+
--color-secondary-foreground: var(--color-label);
|
|
29
|
+
--color-accent-foreground: var(--color-label);
|
|
30
|
+
--color-border: var(--color-separator);
|
|
31
|
+
--color-input: var(--color-separator);
|
|
32
|
+
--color-ring: var(--color-accent-text);
|
|
33
|
+
--color-destructive: var(--color-danger);
|
|
34
|
+
--color-destructive-foreground: var(--color-on-inverse);
|
|
35
|
+
--color-sidebar-border: var(--color-separator);
|
|
36
|
+
--color-sidebar-accent: var(--color-accent-soft);
|
|
37
|
+
--color-sidebar-accent-foreground: var(--color-label);
|
|
38
|
+
--color-sidebar-foreground: var(--color-label);
|
|
39
|
+
--font-heading: var(--font-sans);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
:root {
|
|
43
|
+
--background: var(--color-background);
|
|
44
|
+
--foreground: var(--color-label);
|
|
45
|
+
--primary: var(--color-inverse);
|
|
46
|
+
--secondary: var(--color-fill);
|
|
47
|
+
--border: var(--color-separator);
|
|
48
|
+
--muted-foreground: var(--color-label-secondary);
|
|
49
|
+
--card: var(--color-elevated);
|
|
50
|
+
--accent: var(--color-accent-soft);
|
|
51
|
+
--sidebar-border: var(--color-separator);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
@utility no-scrollbar {
|
|
55
|
+
scrollbar-width: none;
|
|
56
|
+
&::-webkit-scrollbar {
|
|
57
|
+
display: none;
|
|
58
|
+
}
|
|
59
|
+
}
|