@gridkitjs/theme-css 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 +54 -2
- package/package.json +33 -3
- package/src/presets/comfortable.css +58 -0
- package/src/presets/default.css +111 -0
- package/src/presets/high-contrast.css +56 -0
- package/src/presets/index.json +35 -0
- package/src/presets/midnight.css +56 -0
- package/src/presets/spreadsheet.css +57 -0
- package/src/styles.css +2226 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Blagoja Blazhevski
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,55 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @gridkitjs/theme-css
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Plain-CSS theme for [GridKit](https://github.com/gridkitjs/gridkitjs) —
|
|
4
|
+
palette tokens, dark mode and the grid's styles, for an app without
|
|
5
|
+
Tailwind. It is generated from
|
|
6
|
+
[`@gridkitjs/theme-tailwind`](https://www.npmjs.com/package/@gridkitjs/theme-tailwind),
|
|
7
|
+
so both draw the same grid.
|
|
8
|
+
|
|
9
|
+
> **Early development.** The API is still moving and may break between minor
|
|
10
|
+
> versions.
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
pnpm add @gridkitjs/theme-css
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Import it once, before your own CSS:
|
|
17
|
+
|
|
18
|
+
```css
|
|
19
|
+
@import "@gridkitjs/theme-css/styles.css";
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
`@gridkitjs/react` renders semantic class names (`gridkit-data-grid`,
|
|
23
|
+
`header-cell`, `grid-row`), and this stylesheet targets them directly.
|
|
24
|
+
|
|
25
|
+
## Dark mode
|
|
26
|
+
|
|
27
|
+
The grid follows the system's colour scheme (`prefers-color-scheme`). An app
|
|
28
|
+
with its own light and dark switch puts `.gridkit-light` or `.gridkit-dark`
|
|
29
|
+
on `<html>`, or on any ancestor of one grid to pin that grid alone:
|
|
30
|
+
|
|
31
|
+
```js
|
|
32
|
+
document.documentElement.classList.toggle("gridkit-dark", isDark);
|
|
33
|
+
document.documentElement.classList.toggle("gridkit-light", !isDark);
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## Theming
|
|
37
|
+
|
|
38
|
+
Every colour, size and line is a `--gridkit-*` custom property. Override the
|
|
39
|
+
ones you change on `:root`, after the import; a colour is set by its light
|
|
40
|
+
and dark pair:
|
|
41
|
+
|
|
42
|
+
```css
|
|
43
|
+
:root {
|
|
44
|
+
--gridkit-spacing: 0.1875rem;
|
|
45
|
+
--gridkit-accent-light: oklch(0.6 0.17 145);
|
|
46
|
+
--gridkit-accent-dark: oklch(0.7 0.15 145);
|
|
47
|
+
}
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
Every token and its default is listed at
|
|
51
|
+
[gridkitjs.com](https://gridkitjs.com/en/docs/theme-tailwind/tokens).
|
|
52
|
+
|
|
53
|
+
## License
|
|
54
|
+
|
|
55
|
+
MIT © Blagoja Blazhevski
|
package/package.json
CHANGED
|
@@ -1,6 +1,36 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gridkitjs/theme-css",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Plain-CSS theme for GridKit — palette tokens, dark mode and grid styles, no Tailwind needed.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"author": "Blagoja Blazhevski",
|
|
7
|
+
"homepage": "https://github.com/gridkitjs/gridkitjs#readme",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/gridkitjs/gridkitjs.git",
|
|
11
|
+
"directory": "packages/theme-css"
|
|
12
|
+
},
|
|
13
|
+
"keywords": [
|
|
14
|
+
"gridkit",
|
|
15
|
+
"datagrid",
|
|
16
|
+
"theme",
|
|
17
|
+
"css"
|
|
18
|
+
],
|
|
19
|
+
"exports": {
|
|
20
|
+
"./styles.css": "./src/styles.css",
|
|
21
|
+
"./presets/*": "./src/presets/*"
|
|
22
|
+
},
|
|
23
|
+
"files": [
|
|
24
|
+
"src",
|
|
25
|
+
"LICENSE",
|
|
26
|
+
"README.md"
|
|
27
|
+
],
|
|
28
|
+
"devDependencies": {
|
|
29
|
+
"postcss": "^8.5.25",
|
|
30
|
+
"prettier": "^3.9.6"
|
|
31
|
+
},
|
|
32
|
+
"scripts": {
|
|
33
|
+
"build": "node scripts/write-stylesheet.mjs && node scripts/copy-presets.mjs",
|
|
34
|
+
"test": "node --test \"scripts/*.test.mjs\""
|
|
35
|
+
}
|
|
6
36
|
}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* GridKit preset: Comfortable. Roomy rows, soft violet tints, rounded
|
|
3
|
+
* corners and no lines between columns.
|
|
4
|
+
*
|
|
5
|
+
* Load it after the theme's stylesheet, from the same package:
|
|
6
|
+
*
|
|
7
|
+
* @import "@gridkitjs/theme-tailwind/styles.css";
|
|
8
|
+
* @import "@gridkitjs/theme-tailwind/presets/comfortable.css";
|
|
9
|
+
*
|
|
10
|
+
* or the same two files from @gridkitjs/theme-css.
|
|
11
|
+
*/
|
|
12
|
+
:root {
|
|
13
|
+
--gridkit-surface-light: oklch(1 0 0);
|
|
14
|
+
--gridkit-surface-dark: oklch(0.23 0.015 285);
|
|
15
|
+
--gridkit-surface-muted-light: oklch(0.975 0.007 285);
|
|
16
|
+
--gridkit-surface-muted-dark: oklch(0.28 0.02 285);
|
|
17
|
+
--gridkit-line-light: oklch(0.93 0.01 285);
|
|
18
|
+
--gridkit-line-dark: oklch(0.33 0.02 285);
|
|
19
|
+
--gridkit-hover-line-light: oklch(0.72 0.08 285);
|
|
20
|
+
--gridkit-hover-line-dark: oklch(0.7 0.08 285);
|
|
21
|
+
--gridkit-fg-light: oklch(0.27 0.02 285);
|
|
22
|
+
--gridkit-fg-dark: oklch(0.95 0.006 285);
|
|
23
|
+
--gridkit-fg-muted-light: oklch(0.5 0.03 285);
|
|
24
|
+
--gridkit-fg-muted-dark: oklch(0.75 0.025 285);
|
|
25
|
+
--gridkit-accent-light: oklch(0.56 0.15 285);
|
|
26
|
+
--gridkit-accent-dark: oklch(0.75 0.12 285);
|
|
27
|
+
--gridkit-selected-light: oklch(0.955 0.025 285);
|
|
28
|
+
--gridkit-selected-dark: oklch(0.33 0.05 285);
|
|
29
|
+
--gridkit-selected-strong-light: oklch(0.92 0.045 285);
|
|
30
|
+
--gridkit-selected-strong-dark: oklch(0.39 0.07 285);
|
|
31
|
+
--gridkit-header-fg-light: var(--gridkit-fg-muted-light);
|
|
32
|
+
--gridkit-header-fg-dark: var(--gridkit-fg-muted-dark);
|
|
33
|
+
--gridkit-overlay-shadow-color-light: oklch(0.3 0.05 285 / 0.16);
|
|
34
|
+
--gridkit-overlay-shadow-color-dark: oklch(0 0 0 / 0.45);
|
|
35
|
+
|
|
36
|
+
--gridkit-menu-font-size: 0.9375rem;
|
|
37
|
+
--gridkit-bar-font-size: 0.875rem;
|
|
38
|
+
--gridkit-header-font-weight: 600;
|
|
39
|
+
|
|
40
|
+
--gridkit-spacing: 0.3125rem;
|
|
41
|
+
--gridkit-cell-padding-x: calc(var(--gridkit-spacing) * 3);
|
|
42
|
+
--gridkit-cell-padding-y: calc(var(--gridkit-spacing) * 2.5);
|
|
43
|
+
|
|
44
|
+
--gridkit-column-line-width: 0;
|
|
45
|
+
--gridkit-outer-border-width: var(--gridkit-border-width);
|
|
46
|
+
|
|
47
|
+
--gridkit-radius: 0.75rem;
|
|
48
|
+
--gridkit-menu-radius: 0.75rem;
|
|
49
|
+
--gridkit-control-radius: 0.5rem;
|
|
50
|
+
|
|
51
|
+
--gridkit-icon-size: 1.125rem;
|
|
52
|
+
--gridkit-header-icon-size: 16px;
|
|
53
|
+
--gridkit-overlay-shadow: 0 8px 24px;
|
|
54
|
+
--gridkit-menu-min-width: 14rem;
|
|
55
|
+
--gridkit-column-chooser-width: 18rem;
|
|
56
|
+
--gridkit-filter-menu-width: 20rem;
|
|
57
|
+
--gridkit-transition-duration: 0.15s;
|
|
58
|
+
}
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* GridKit preset: Default. The grid's own look, with every theme token set
|
|
3
|
+
* to its default.
|
|
4
|
+
*
|
|
5
|
+
* Copy it to start a theme of your own: change the tokens you want to, and
|
|
6
|
+
* delete the ones you keep. Load it after the theme's stylesheet, from the
|
|
7
|
+
* same package:
|
|
8
|
+
*
|
|
9
|
+
* @import "@gridkitjs/theme-tailwind/styles.css";
|
|
10
|
+
* @import "@gridkitjs/theme-tailwind/presets/default.css";
|
|
11
|
+
*
|
|
12
|
+
* or the same two files from @gridkitjs/theme-css.
|
|
13
|
+
*/
|
|
14
|
+
:root {
|
|
15
|
+
/* Colours, each a light and dark pair */
|
|
16
|
+
--gridkit-surface-light: oklch(1 0 0);
|
|
17
|
+
--gridkit-surface-dark: oklch(0.21 0.01 250);
|
|
18
|
+
--gridkit-surface-muted-light: oklch(0.97 0.003 250);
|
|
19
|
+
--gridkit-surface-muted-dark: oklch(0.26 0.012 250);
|
|
20
|
+
--gridkit-line-light: oklch(0.92 0.005 250);
|
|
21
|
+
--gridkit-line-dark: oklch(0.33 0.014 250);
|
|
22
|
+
--gridkit-hover-line-light: oklch(0.65 0.09 255);
|
|
23
|
+
--gridkit-hover-line-dark: oklch(0.75 0.09 255);
|
|
24
|
+
--gridkit-fg-light: oklch(0.21 0.01 250);
|
|
25
|
+
--gridkit-fg-dark: oklch(0.97 0.003 250);
|
|
26
|
+
--gridkit-fg-muted-light: oklch(0.5 0.015 250);
|
|
27
|
+
--gridkit-fg-muted-dark: oklch(0.7 0.015 250);
|
|
28
|
+
--gridkit-accent-light: oklch(0.6 0.17 255);
|
|
29
|
+
--gridkit-accent-dark: oklch(0.7 0.15 255);
|
|
30
|
+
--gridkit-selected-light: oklch(0.94 0.03 255);
|
|
31
|
+
--gridkit-selected-dark: oklch(0.32 0.05 255);
|
|
32
|
+
--gridkit-selected-strong-light: oklch(0.9 0.05 255);
|
|
33
|
+
--gridkit-selected-strong-dark: oklch(0.38 0.07 255);
|
|
34
|
+
--gridkit-header-bg-light: var(--gridkit-surface-light);
|
|
35
|
+
--gridkit-header-bg-dark: var(--gridkit-surface-dark);
|
|
36
|
+
--gridkit-header-fg-light: currentColor;
|
|
37
|
+
--gridkit-header-fg-dark: currentColor;
|
|
38
|
+
--gridkit-group-row-bg-light: var(--gridkit-surface-muted-light);
|
|
39
|
+
--gridkit-group-row-bg-dark: var(--gridkit-surface-muted-dark);
|
|
40
|
+
--gridkit-row-hover-bg-light: var(--gridkit-surface-muted-light);
|
|
41
|
+
--gridkit-row-hover-bg-dark: var(--gridkit-surface-muted-dark);
|
|
42
|
+
--gridkit-row-stripe-bg-light: transparent;
|
|
43
|
+
--gridkit-row-stripe-bg-dark: transparent;
|
|
44
|
+
--gridkit-focus-ring-light: var(--gridkit-accent-light);
|
|
45
|
+
--gridkit-focus-ring-dark: var(--gridkit-accent-dark);
|
|
46
|
+
--gridkit-accent-fg-light: var(--gridkit-surface-light);
|
|
47
|
+
--gridkit-accent-fg-dark: var(--gridkit-surface-dark);
|
|
48
|
+
--gridkit-error-light: oklch(from var(--gridkit-accent-light) l c 25);
|
|
49
|
+
--gridkit-error-dark: oklch(from var(--gridkit-accent-dark) l c 25);
|
|
50
|
+
--gridkit-scrollbar-thumb-light: color-mix(
|
|
51
|
+
in oklch,
|
|
52
|
+
var(--gridkit-fg-muted-light) 45%,
|
|
53
|
+
transparent
|
|
54
|
+
);
|
|
55
|
+
--gridkit-scrollbar-thumb-dark: color-mix(
|
|
56
|
+
in oklch,
|
|
57
|
+
var(--gridkit-fg-muted-dark) 45%,
|
|
58
|
+
transparent
|
|
59
|
+
);
|
|
60
|
+
--gridkit-overlay-shadow-color-light: oklch(0 0 0 / 0.15);
|
|
61
|
+
--gridkit-overlay-shadow-color-dark: oklch(0 0 0 / 0.15);
|
|
62
|
+
|
|
63
|
+
/* Typography */
|
|
64
|
+
--gridkit-font-family: inherit;
|
|
65
|
+
--gridkit-font-size: 1em;
|
|
66
|
+
--gridkit-menu-font-size: 0.875rem;
|
|
67
|
+
--gridkit-bar-font-size: 0.8125rem;
|
|
68
|
+
--gridkit-hint-font-size: 0.75rem;
|
|
69
|
+
--gridkit-header-font-weight: 700;
|
|
70
|
+
--gridkit-header-text-transform: inherit;
|
|
71
|
+
--gridkit-header-letter-spacing: inherit;
|
|
72
|
+
--gridkit-group-font-weight: 600;
|
|
73
|
+
--gridkit-font-variant-numeric: inherit;
|
|
74
|
+
|
|
75
|
+
/* Density */
|
|
76
|
+
--gridkit-spacing: 0.25rem;
|
|
77
|
+
--gridkit-cell-padding-x: calc(var(--gridkit-spacing) * 2);
|
|
78
|
+
--gridkit-cell-padding-y: calc(var(--gridkit-spacing) * 2);
|
|
79
|
+
--gridkit-header-padding-x: var(--gridkit-cell-padding-x);
|
|
80
|
+
--gridkit-header-padding-y: var(--gridkit-cell-padding-y);
|
|
81
|
+
--gridkit-toolbar-padding: calc(var(--gridkit-spacing) * 2);
|
|
82
|
+
--gridkit-group-by-bar-padding: calc(var(--gridkit-spacing) * 2);
|
|
83
|
+
--gridkit-pager-padding: calc(var(--gridkit-spacing) * 2);
|
|
84
|
+
--gridkit-menu-item-padding-x: calc(var(--gridkit-spacing) * 3);
|
|
85
|
+
--gridkit-menu-item-padding-y: calc(var(--gridkit-spacing) * 1.5);
|
|
86
|
+
|
|
87
|
+
/* Borders */
|
|
88
|
+
--gridkit-border-width: 1px;
|
|
89
|
+
--gridkit-border-style: solid;
|
|
90
|
+
--gridkit-row-line-width: var(--gridkit-border-width);
|
|
91
|
+
--gridkit-column-line-width: var(--gridkit-border-width);
|
|
92
|
+
--gridkit-outer-border-width: 0;
|
|
93
|
+
|
|
94
|
+
/* Shape */
|
|
95
|
+
--gridkit-radius: 0.25rem;
|
|
96
|
+
--gridkit-menu-radius: 0.375rem;
|
|
97
|
+
--gridkit-control-radius: 0.25rem;
|
|
98
|
+
|
|
99
|
+
/* Details */
|
|
100
|
+
--gridkit-icon-size: 1rem;
|
|
101
|
+
--gridkit-header-icon-size: 14px;
|
|
102
|
+
--gridkit-focus-ring-width: 2px;
|
|
103
|
+
--gridkit-indicator-width: 2px;
|
|
104
|
+
--gridkit-overlay-shadow: 0 4px 12px;
|
|
105
|
+
--gridkit-menu-min-width: 12rem;
|
|
106
|
+
--gridkit-column-chooser-width: 16rem;
|
|
107
|
+
--gridkit-filter-menu-width: 18rem;
|
|
108
|
+
--gridkit-column-chooser-max-height: 17.5rem;
|
|
109
|
+
--gridkit-filter-checklist-height: 12rem;
|
|
110
|
+
--gridkit-transition-duration: 0.1s;
|
|
111
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* GridKit preset: High contrast. Black on white, or white on black, with
|
|
3
|
+
* strong lines, larger small text, thick focus rings and WCAG AAA contrast
|
|
4
|
+
* for the menus' text.
|
|
5
|
+
*
|
|
6
|
+
* Load it after the theme's stylesheet, from the same package:
|
|
7
|
+
*
|
|
8
|
+
* @import "@gridkitjs/theme-tailwind/styles.css";
|
|
9
|
+
* @import "@gridkitjs/theme-tailwind/presets/high-contrast.css";
|
|
10
|
+
*
|
|
11
|
+
* or the same two files from @gridkitjs/theme-css.
|
|
12
|
+
*/
|
|
13
|
+
:root {
|
|
14
|
+
--gridkit-surface-light: oklch(1 0 0);
|
|
15
|
+
--gridkit-surface-dark: oklch(0 0 0);
|
|
16
|
+
--gridkit-surface-muted-light: oklch(0.94 0 0);
|
|
17
|
+
--gridkit-surface-muted-dark: oklch(0.26 0 0);
|
|
18
|
+
--gridkit-line-light: oklch(0.45 0 0);
|
|
19
|
+
--gridkit-line-dark: oklch(0.72 0 0);
|
|
20
|
+
--gridkit-hover-line-light: oklch(0 0 0);
|
|
21
|
+
--gridkit-hover-line-dark: oklch(1 0 0);
|
|
22
|
+
--gridkit-fg-light: oklch(0 0 0);
|
|
23
|
+
--gridkit-fg-dark: oklch(1 0 0);
|
|
24
|
+
--gridkit-fg-muted-light: oklch(0.33 0 0);
|
|
25
|
+
--gridkit-fg-muted-dark: oklch(0.88 0 0);
|
|
26
|
+
--gridkit-accent-light: oklch(0.45 0.2 265);
|
|
27
|
+
--gridkit-accent-dark: oklch(0.82 0.12 230);
|
|
28
|
+
--gridkit-selected-light: oklch(0.9 0.06 265);
|
|
29
|
+
--gridkit-selected-dark: oklch(0.33 0.1 265);
|
|
30
|
+
--gridkit-selected-strong-light: oklch(0.84 0.09 265);
|
|
31
|
+
--gridkit-selected-strong-dark: oklch(0.4 0.12 265);
|
|
32
|
+
--gridkit-header-bg-light: oklch(0.9 0 0);
|
|
33
|
+
--gridkit-header-bg-dark: oklch(0.2 0 0);
|
|
34
|
+
--gridkit-header-fg-light: oklch(0 0 0);
|
|
35
|
+
--gridkit-header-fg-dark: oklch(1 0 0);
|
|
36
|
+
--gridkit-focus-ring-dark: oklch(0.9 0.17 95);
|
|
37
|
+
--gridkit-overlay-shadow-color-light: oklch(0 0 0 / 0.35);
|
|
38
|
+
--gridkit-overlay-shadow-color-dark: oklch(0 0 0 / 0.6);
|
|
39
|
+
|
|
40
|
+
--gridkit-menu-font-size: 0.9375rem;
|
|
41
|
+
--gridkit-bar-font-size: 0.875rem;
|
|
42
|
+
--gridkit-hint-font-size: 0.8125rem;
|
|
43
|
+
--gridkit-group-font-weight: 700;
|
|
44
|
+
|
|
45
|
+
--gridkit-outer-border-width: var(--gridkit-border-width);
|
|
46
|
+
|
|
47
|
+
--gridkit-radius: 0.125rem;
|
|
48
|
+
--gridkit-menu-radius: 0.25rem;
|
|
49
|
+
--gridkit-control-radius: 0.125rem;
|
|
50
|
+
|
|
51
|
+
--gridkit-icon-size: 1.125rem;
|
|
52
|
+
--gridkit-header-icon-size: 16px;
|
|
53
|
+
--gridkit-focus-ring-width: 3px;
|
|
54
|
+
--gridkit-indicator-width: 3px;
|
|
55
|
+
--gridkit-transition-duration: 0s;
|
|
56
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{
|
|
2
|
+
"schemaVersion": 1,
|
|
3
|
+
"presets": [
|
|
4
|
+
{
|
|
5
|
+
"id": "default",
|
|
6
|
+
"label": "Default",
|
|
7
|
+
"description": "The grid's own look, with every token at its default: a template to copy.",
|
|
8
|
+
"file": "default.css"
|
|
9
|
+
},
|
|
10
|
+
{
|
|
11
|
+
"id": "spreadsheet",
|
|
12
|
+
"label": "Spreadsheet",
|
|
13
|
+
"description": "Dense rows, square corners, a grey header and firm lines between every cell.",
|
|
14
|
+
"file": "spreadsheet.css"
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
"id": "comfortable",
|
|
18
|
+
"label": "Comfortable",
|
|
19
|
+
"description": "Roomy rows, soft violet tints, rounded corners and no lines between columns.",
|
|
20
|
+
"file": "comfortable.css"
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
"id": "high-contrast",
|
|
24
|
+
"label": "High contrast",
|
|
25
|
+
"description": "Black and white with strong lines, larger small text and thick focus rings, at WCAG AAA contrast.",
|
|
26
|
+
"file": "high-contrast.css"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"id": "midnight",
|
|
30
|
+
"label": "Midnight",
|
|
31
|
+
"description": "Deep indigo and a vivid violet accent, with an uppercase header and striped rows.",
|
|
32
|
+
"file": "midnight.css"
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* GridKit preset: Midnight. Deep indigo and a vivid violet accent, with an
|
|
3
|
+
* uppercase header and striped rows, at its strongest in dark mode.
|
|
4
|
+
*
|
|
5
|
+
* Load it after the theme's stylesheet, from the same package:
|
|
6
|
+
*
|
|
7
|
+
* @import "@gridkitjs/theme-tailwind/styles.css";
|
|
8
|
+
* @import "@gridkitjs/theme-tailwind/presets/midnight.css";
|
|
9
|
+
*
|
|
10
|
+
* or the same two files from @gridkitjs/theme-css.
|
|
11
|
+
*/
|
|
12
|
+
:root {
|
|
13
|
+
--gridkit-surface-light: oklch(0.985 0.008 275);
|
|
14
|
+
--gridkit-surface-dark: oklch(0.2 0.04 272);
|
|
15
|
+
--gridkit-surface-muted-light: oklch(0.955 0.016 275);
|
|
16
|
+
--gridkit-surface-muted-dark: oklch(0.25 0.05 272);
|
|
17
|
+
--gridkit-line-light: oklch(0.9 0.02 275);
|
|
18
|
+
--gridkit-line-dark: oklch(0.32 0.05 272);
|
|
19
|
+
--gridkit-hover-line-light: oklch(0.6 0.16 290);
|
|
20
|
+
--gridkit-hover-line-dark: oklch(0.72 0.14 290);
|
|
21
|
+
--gridkit-fg-light: oklch(0.25 0.06 275);
|
|
22
|
+
--gridkit-fg-dark: oklch(0.95 0.015 275);
|
|
23
|
+
--gridkit-fg-muted-light: oklch(0.47 0.06 275);
|
|
24
|
+
--gridkit-fg-muted-dark: oklch(0.76 0.04 275);
|
|
25
|
+
--gridkit-accent-light: oklch(0.5 0.22 290);
|
|
26
|
+
--gridkit-accent-dark: oklch(0.72 0.17 295);
|
|
27
|
+
--gridkit-selected-light: oklch(0.93 0.04 290);
|
|
28
|
+
--gridkit-selected-dark: oklch(0.32 0.09 285);
|
|
29
|
+
--gridkit-selected-strong-light: oklch(0.88 0.07 290);
|
|
30
|
+
--gridkit-selected-strong-dark: oklch(0.38 0.11 285);
|
|
31
|
+
--gridkit-header-bg-light: oklch(0.93 0.03 275);
|
|
32
|
+
--gridkit-header-bg-dark: oklch(0.16 0.04 272);
|
|
33
|
+
--gridkit-header-fg-light: oklch(0.32 0.1 280);
|
|
34
|
+
--gridkit-header-fg-dark: oklch(0.86 0.06 285);
|
|
35
|
+
--gridkit-row-stripe-bg-light: oklch(0.975 0.01 275);
|
|
36
|
+
--gridkit-row-stripe-bg-dark: oklch(0.22 0.04 272);
|
|
37
|
+
--gridkit-accent-fg-light: oklch(1 0 0);
|
|
38
|
+
--gridkit-overlay-shadow-color-light: oklch(0.25 0.1 275 / 0.2);
|
|
39
|
+
--gridkit-overlay-shadow-color-dark: oklch(0 0 0 / 0.5);
|
|
40
|
+
|
|
41
|
+
--gridkit-bar-font-size: 0.75rem;
|
|
42
|
+
--gridkit-header-font-weight: 600;
|
|
43
|
+
--gridkit-header-text-transform: uppercase;
|
|
44
|
+
--gridkit-header-letter-spacing: 0.06em;
|
|
45
|
+
|
|
46
|
+
--gridkit-cell-padding-x: calc(var(--gridkit-spacing) * 3);
|
|
47
|
+
|
|
48
|
+
--gridkit-row-line-width: 0;
|
|
49
|
+
|
|
50
|
+
--gridkit-radius: 0.5rem;
|
|
51
|
+
--gridkit-menu-radius: 0.5rem;
|
|
52
|
+
--gridkit-control-radius: 0.375rem;
|
|
53
|
+
|
|
54
|
+
--gridkit-indicator-width: 3px;
|
|
55
|
+
--gridkit-overlay-shadow: 0 10px 30px;
|
|
56
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* GridKit preset: Spreadsheet. Dense rows, square corners, a grey header and
|
|
3
|
+
* firm lines between every cell, with a green accent.
|
|
4
|
+
*
|
|
5
|
+
* It restyles the lines the grid's borders prop draws, so pair it with
|
|
6
|
+
* borders="all" for lines between columns too. Load it after the theme's
|
|
7
|
+
* stylesheet, from the same package:
|
|
8
|
+
*
|
|
9
|
+
* @import "@gridkitjs/theme-tailwind/styles.css";
|
|
10
|
+
* @import "@gridkitjs/theme-tailwind/presets/spreadsheet.css";
|
|
11
|
+
*
|
|
12
|
+
* or the same two files from @gridkitjs/theme-css.
|
|
13
|
+
*/
|
|
14
|
+
:root {
|
|
15
|
+
--gridkit-surface-light: oklch(1 0 0);
|
|
16
|
+
--gridkit-surface-dark: oklch(0.2 0 0);
|
|
17
|
+
--gridkit-surface-muted-light: oklch(0.96 0 0);
|
|
18
|
+
--gridkit-surface-muted-dark: oklch(0.26 0 0);
|
|
19
|
+
--gridkit-line-light: oklch(0.85 0 0);
|
|
20
|
+
--gridkit-line-dark: oklch(0.38 0 0);
|
|
21
|
+
--gridkit-hover-line-light: oklch(0.6 0.1 150);
|
|
22
|
+
--gridkit-hover-line-dark: oklch(0.7 0.1 150);
|
|
23
|
+
--gridkit-fg-light: oklch(0.2 0 0);
|
|
24
|
+
--gridkit-fg-dark: oklch(0.95 0 0);
|
|
25
|
+
--gridkit-fg-muted-light: oklch(0.47 0 0);
|
|
26
|
+
--gridkit-fg-muted-dark: oklch(0.74 0 0);
|
|
27
|
+
--gridkit-accent-light: oklch(0.52 0.13 150);
|
|
28
|
+
--gridkit-accent-dark: oklch(0.72 0.15 150);
|
|
29
|
+
--gridkit-selected-light: oklch(0.94 0.04 150);
|
|
30
|
+
--gridkit-selected-dark: oklch(0.31 0.05 150);
|
|
31
|
+
--gridkit-selected-strong-light: oklch(0.89 0.07 150);
|
|
32
|
+
--gridkit-selected-strong-dark: oklch(0.37 0.07 150);
|
|
33
|
+
--gridkit-header-bg-light: oklch(0.94 0 0);
|
|
34
|
+
--gridkit-header-bg-dark: oklch(0.27 0 0);
|
|
35
|
+
--gridkit-overlay-shadow-color-light: oklch(0 0 0 / 0.2);
|
|
36
|
+
--gridkit-overlay-shadow-color-dark: oklch(0 0 0 / 0.4);
|
|
37
|
+
|
|
38
|
+
--gridkit-font-size: 0.875em;
|
|
39
|
+
--gridkit-menu-font-size: 0.8125rem;
|
|
40
|
+
--gridkit-bar-font-size: 0.8125rem;
|
|
41
|
+
--gridkit-header-font-weight: 600;
|
|
42
|
+
--gridkit-font-variant-numeric: tabular-nums;
|
|
43
|
+
|
|
44
|
+
--gridkit-spacing: 0.1875rem;
|
|
45
|
+
--gridkit-cell-padding-y: var(--gridkit-spacing);
|
|
46
|
+
|
|
47
|
+
--gridkit-outer-border-width: var(--gridkit-border-width);
|
|
48
|
+
|
|
49
|
+
--gridkit-radius: 0;
|
|
50
|
+
--gridkit-menu-radius: 0;
|
|
51
|
+
--gridkit-control-radius: 0;
|
|
52
|
+
|
|
53
|
+
--gridkit-icon-size: 0.875rem;
|
|
54
|
+
--gridkit-header-icon-size: 12px;
|
|
55
|
+
--gridkit-overlay-shadow: 0 2px 6px;
|
|
56
|
+
--gridkit-transition-duration: 0s;
|
|
57
|
+
}
|