@skygraph/styles 0.0.0-placeholder.0 → 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.
Files changed (75) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +92 -6
  3. package/components/autocomplete.css +33 -0
  4. package/components/avatar.css +37 -0
  5. package/components/badge.css +102 -0
  6. package/components/breadcrumb.css +29 -0
  7. package/components/button.css +181 -0
  8. package/components/calendar.css +408 -0
  9. package/components/carousel.css +102 -0
  10. package/components/cascader.css +354 -0
  11. package/components/charts.css +408 -0
  12. package/components/checkbox.css +29 -0
  13. package/components/collapse.css +166 -0
  14. package/components/colorpicker.css +252 -0
  15. package/components/context-menu.css +95 -0
  16. package/components/dashboard.css +299 -0
  17. package/components/datagrid.css +86 -0
  18. package/components/datepicker.css +601 -0
  19. package/components/descriptions.css +82 -0
  20. package/components/diagram.css +422 -0
  21. package/components/drawer.css +103 -0
  22. package/components/dropdown.css +93 -0
  23. package/components/empty.css +25 -0
  24. package/components/event-timeline.css +100 -0
  25. package/components/field.css +35 -0
  26. package/components/form.css +115 -0
  27. package/components/gantt.css +161 -0
  28. package/components/inline-edit.css +113 -0
  29. package/components/input-group.css +79 -0
  30. package/components/input-number.css +76 -0
  31. package/components/input-password.css +104 -0
  32. package/components/input.css +110 -0
  33. package/components/list.css +357 -0
  34. package/components/mentions.css +54 -0
  35. package/components/menu.css +309 -0
  36. package/components/modal.css +77 -0
  37. package/components/notification.css +128 -0
  38. package/components/pagination.css +162 -0
  39. package/components/pin-input.css +71 -0
  40. package/components/popconfirm.css +95 -0
  41. package/components/progress.css +116 -0
  42. package/components/radio.css +38 -0
  43. package/components/rate.css +34 -0
  44. package/components/resource-calendar.css +219 -0
  45. package/components/result.css +45 -0
  46. package/components/schema-form-editor.css +425 -0
  47. package/components/search-input.css +112 -0
  48. package/components/segmented.css +76 -0
  49. package/components/select.css +172 -0
  50. package/components/skeleton.css +68 -0
  51. package/components/slider.css +51 -0
  52. package/components/spin.css +86 -0
  53. package/components/steps.css +185 -0
  54. package/components/switch.css +69 -0
  55. package/components/table.css +984 -0
  56. package/components/tabs.css +117 -0
  57. package/components/tag-input.css +94 -0
  58. package/components/tag.css +61 -0
  59. package/components/textarea.css +22 -0
  60. package/components/timeline.css +169 -0
  61. package/components/timepicker.css +213 -0
  62. package/components/tooltip.css +91 -0
  63. package/components/transfer.css +140 -0
  64. package/components/tree.css +574 -0
  65. package/components/treeselect.css +219 -0
  66. package/components/upload.css +124 -0
  67. package/index.css +69 -3
  68. package/index.d.ts +9 -0
  69. package/package.json +102 -18
  70. package/print.css +88 -0
  71. package/reset.css +17 -0
  72. package/themes/dark.css +17 -0
  73. package/themes/default.css +14 -0
  74. package/tokens.css +312 -0
  75. package/transitions.css +158 -0
@@ -0,0 +1,219 @@
1
+ /* === TreeSelect === */
2
+
3
+ .sg-treeselect {
4
+ position: relative;
5
+ display: inline-block;
6
+ min-width: 180px;
7
+ font-size: var(--sg-font-size);
8
+ }
9
+
10
+ .sg-treeselect-disabled {
11
+ opacity: 0.5;
12
+ pointer-events: none;
13
+ }
14
+
15
+ /* Selector trigger */
16
+
17
+ .sg-treeselect-selector {
18
+ display: flex;
19
+ align-items: center;
20
+ justify-content: space-between;
21
+ min-height: var(--sg-height-md);
22
+ padding: var(--sg-padding-xs) var(--sg-padding-md);
23
+ background: var(--sg-color-bg-container);
24
+ border: 1px solid var(--sg-color-border);
25
+ border-radius: var(--sg-border-radius);
26
+ cursor: pointer;
27
+ transition: border-color var(--sg-transition-duration) var(--sg-transition-timing);
28
+ gap: var(--sg-padding-xs);
29
+ }
30
+
31
+ .sg-treeselect-small .sg-treeselect-selector {
32
+ min-height: var(--sg-height-sm);
33
+ font-size: var(--sg-font-size-sm);
34
+ }
35
+
36
+ .sg-treeselect-large .sg-treeselect-selector {
37
+ min-height: var(--sg-height-lg);
38
+ font-size: var(--sg-font-size-lg);
39
+ }
40
+
41
+ .sg-treeselect-open .sg-treeselect-selector {
42
+ border-color: var(--sg-color-primary);
43
+ box-shadow: 0 0 0 2px var(--sg-color-primary-bg);
44
+ }
45
+
46
+ .sg-treeselect-selector:hover {
47
+ border-color: var(--sg-color-primary-hover);
48
+ }
49
+
50
+ /* Selection wrap */
51
+
52
+ .sg-treeselect-selection-wrap {
53
+ display: flex;
54
+ flex-wrap: wrap;
55
+ align-items: center;
56
+ gap: var(--sg-padding-xs);
57
+ flex: 1;
58
+ min-width: 0;
59
+ overflow: hidden;
60
+ }
61
+
62
+ .sg-treeselect-placeholder {
63
+ color: var(--sg-color-text-placeholder);
64
+ white-space: nowrap;
65
+ overflow: hidden;
66
+ text-overflow: ellipsis;
67
+ }
68
+
69
+ .sg-treeselect-selection-item {
70
+ color: var(--sg-color-text);
71
+ white-space: nowrap;
72
+ overflow: hidden;
73
+ text-overflow: ellipsis;
74
+ }
75
+
76
+ /* Tags (multiple mode) */
77
+
78
+ .sg-treeselect-tag {
79
+ display: inline-flex;
80
+ align-items: center;
81
+ gap: 2px;
82
+ max-width: 100%;
83
+ padding: 1px var(--sg-padding-sm);
84
+ background: var(--sg-color-bg-hover);
85
+ border: 1px solid var(--sg-color-border-secondary);
86
+ border-radius: var(--sg-border-radius-sm);
87
+ font-size: var(--sg-font-size-sm);
88
+ line-height: 20px;
89
+ }
90
+
91
+ .sg-treeselect-tag-label {
92
+ overflow: hidden;
93
+ text-overflow: ellipsis;
94
+ white-space: nowrap;
95
+ }
96
+
97
+ .sg-treeselect-tag-close {
98
+ display: inline-flex;
99
+ align-items: center;
100
+ justify-content: center;
101
+ width: 16px;
102
+ height: 16px;
103
+ font-size: 12px;
104
+ color: var(--sg-color-text-tertiary);
105
+ cursor: pointer;
106
+ border-radius: 50%;
107
+ transition: all var(--sg-transition-duration);
108
+ flex-shrink: 0;
109
+ }
110
+
111
+ .sg-treeselect-tag-close:hover {
112
+ color: var(--sg-color-text);
113
+ background: var(--sg-color-border-secondary);
114
+ }
115
+
116
+ .sg-treeselect-tag-rest {
117
+ color: var(--sg-color-text-tertiary);
118
+ font-style: italic;
119
+ }
120
+
121
+ /* Search input */
122
+
123
+ .sg-treeselect-search-input {
124
+ flex: 1;
125
+ min-width: 60px;
126
+ border: none;
127
+ outline: none;
128
+ background: transparent;
129
+ font-size: inherit;
130
+ color: var(--sg-color-text);
131
+ padding: 0;
132
+ line-height: var(--sg-line-height);
133
+ }
134
+
135
+ .sg-treeselect-search-input::placeholder {
136
+ color: var(--sg-color-text-placeholder);
137
+ }
138
+
139
+ /* Actions (clear + arrow) */
140
+
141
+ .sg-treeselect-actions {
142
+ display: flex;
143
+ align-items: center;
144
+ gap: var(--sg-padding-xs);
145
+ flex-shrink: 0;
146
+ }
147
+
148
+ .sg-treeselect-arrow {
149
+ font-size: 10px;
150
+ color: var(--sg-color-text-tertiary);
151
+ }
152
+
153
+ .sg-treeselect-clear {
154
+ display: inline-flex;
155
+ align-items: center;
156
+ justify-content: center;
157
+ width: 16px;
158
+ height: 16px;
159
+ font-size: 12px;
160
+ color: var(--sg-color-text-tertiary);
161
+ cursor: pointer;
162
+ border-radius: 50%;
163
+ transition: all var(--sg-transition-duration);
164
+ }
165
+
166
+ .sg-treeselect-clear:hover {
167
+ color: var(--sg-color-text);
168
+ background: var(--sg-color-border-secondary);
169
+ }
170
+
171
+ /* Dropdown */
172
+
173
+ .sg-treeselect-dropdown {
174
+ position: absolute;
175
+ top: 100%;
176
+ left: 0;
177
+ right: 0;
178
+ z-index: var(--sg-z-dropdown);
179
+ margin-top: 4px;
180
+ padding: var(--sg-padding-sm);
181
+ background: var(--sg-color-bg-elevated);
182
+ border: 1px solid var(--sg-color-border-secondary);
183
+ border-radius: var(--sg-border-radius-lg);
184
+ box-shadow: var(--sg-shadow-lg);
185
+ max-height: 300px;
186
+ overflow-x: hidden;
187
+ overflow-y: auto;
188
+ }
189
+
190
+ .sg-treeselect-dropdown::-webkit-scrollbar {
191
+ width: 6px;
192
+ }
193
+
194
+ .sg-treeselect-dropdown::-webkit-scrollbar-thumb {
195
+ background: var(--sg-color-border);
196
+ border-radius: 3px;
197
+ }
198
+
199
+ .sg-treeselect-dropdown::-webkit-scrollbar-track {
200
+ background: transparent;
201
+ }
202
+
203
+ .sg-treeselect-empty {
204
+ padding: var(--sg-padding-lg);
205
+ text-align: center;
206
+ color: var(--sg-color-text-tertiary);
207
+ }
208
+
209
+ /* Tree inside dropdown overrides */
210
+
211
+ .sg-treeselect-dropdown .sg-tree {
212
+ font-size: inherit;
213
+ }
214
+
215
+ .sg-treeselect-dropdown .sg-tree-node {
216
+ padding: 1px 0;
217
+ min-height: 26px;
218
+ }
219
+
@@ -0,0 +1,124 @@
1
+ .sg-upload {
2
+ --sg-spin-color: var(--sg-color-text-tertiary);
3
+ }
4
+
5
+ .sg-upload-list {
6
+ margin-top: var(--sg-margin-sm);
7
+ display: flex;
8
+ flex-direction: column;
9
+ gap: var(--sg-margin-xs);
10
+ }
11
+
12
+ .sg-upload-item {
13
+ display: flex;
14
+ align-items: center;
15
+ justify-content: space-between;
16
+ padding: var(--sg-padding-xs) var(--sg-padding-sm);
17
+ border: 1px solid var(--sg-color-border-secondary);
18
+ border-radius: var(--sg-border-radius-sm);
19
+ font-size: var(--sg-font-size-sm);
20
+ color: var(--sg-color-text);
21
+ }
22
+
23
+ .sg-upload-item-error {
24
+ border-color: var(--sg-color-error);
25
+ color: var(--sg-color-error);
26
+ }
27
+
28
+ .sg-upload-item-name {
29
+ display: flex;
30
+ align-items: center;
31
+ gap: var(--sg-padding-xs);
32
+ }
33
+
34
+ .sg-upload-item-remove {
35
+ cursor: pointer;
36
+ color: var(--sg-color-text-tertiary);
37
+ font-size: var(--sg-font-size);
38
+ background: transparent;
39
+ border: none;
40
+ padding: 0 var(--sg-padding-xs);
41
+ line-height: 1;
42
+ border-radius: var(--sg-border-radius-sm);
43
+ }
44
+
45
+ .sg-upload-item-remove:hover {
46
+ color: var(--sg-color-error);
47
+ }
48
+
49
+ .sg-upload-item-remove:focus-visible {
50
+ outline: 2px solid var(--sg-color-primary);
51
+ outline-offset: 2px;
52
+ }
53
+
54
+ .sg-upload-item-progress {
55
+ font-size: var(--sg-font-size-sm);
56
+ color: var(--sg-color-text-secondary);
57
+ font-variant-numeric: tabular-nums;
58
+ }
59
+
60
+ /* Drag area (Vue-only — sister components in React do not ship a drag mode). */
61
+ .sg-upload-drag-area {
62
+ display: flex;
63
+ flex-direction: column;
64
+ align-items: center;
65
+ justify-content: center;
66
+ gap: var(--sg-margin-xs);
67
+ padding: var(--sg-padding-lg);
68
+ border: 1px dashed var(--sg-color-border);
69
+ border-radius: var(--sg-border-radius);
70
+ color: var(--sg-color-text-secondary);
71
+ background: var(--sg-color-bg-container);
72
+ cursor: pointer;
73
+ transition:
74
+ border-color var(--sg-transition-duration),
75
+ background var(--sg-transition-duration);
76
+ text-align: center;
77
+ }
78
+
79
+ .sg-upload-drag-area:hover,
80
+ .sg-upload-dragging .sg-upload-drag-area {
81
+ border-color: var(--sg-color-primary);
82
+ background: var(--sg-color-primary-bg);
83
+ }
84
+
85
+ .sg-upload-drag-icon {
86
+ font-size: 32px;
87
+ color: var(--sg-color-primary);
88
+ margin: 0;
89
+ line-height: 1;
90
+ }
91
+
92
+ .sg-upload-drag-text {
93
+ margin: 0;
94
+ font-size: var(--sg-font-size);
95
+ color: var(--sg-color-text);
96
+ }
97
+
98
+ .sg-upload-disabled .sg-upload-drag-area {
99
+ cursor: not-allowed;
100
+ opacity: 0.6;
101
+ background: var(--sg-color-bg-disabled);
102
+ }
103
+
104
+ /* Picture-card layout (Vue-only — image-grid trigger like the AntD one). */
105
+ .sg-upload-picture-card .sg-upload-list,
106
+ .sg-upload-picture .sg-upload-list {
107
+ flex-direction: row;
108
+ flex-wrap: wrap;
109
+ gap: var(--sg-margin-sm);
110
+ }
111
+
112
+ .sg-upload-picture-card .sg-upload-item {
113
+ width: 96px;
114
+ height: 96px;
115
+ flex-direction: column;
116
+ justify-content: center;
117
+ align-items: center;
118
+ text-align: center;
119
+ padding: var(--sg-padding-xs);
120
+ }
121
+
122
+ .sg-upload-picture .sg-upload-item {
123
+ padding: var(--sg-padding-sm);
124
+ }
package/index.css CHANGED
@@ -1,3 +1,69 @@
1
- /* @skygraph/styles placeholder. Real release pending.
2
- * See https://skygraph.ruslansinkevich.ru
3
- */
1
+ /* SkyGraph -- all styles */
2
+ @import './tokens.css';
3
+ @import './reset.css';
4
+ @import './components/button.css';
5
+ @import './components/input.css';
6
+ @import './components/textarea.css';
7
+ @import './components/input-number.css';
8
+ @import './components/form.css';
9
+ @import './components/field.css';
10
+ @import './components/spin.css';
11
+ @import './components/modal.css';
12
+ @import './components/checkbox.css';
13
+ @import './components/radio.css';
14
+ @import './components/switch.css';
15
+ @import './components/select.css';
16
+ @import './components/tabs.css';
17
+ @import './components/tooltip.css';
18
+ @import './components/table.css';
19
+ @import './components/datagrid.css';
20
+ @import './components/datepicker.css';
21
+ @import './components/timepicker.css';
22
+ @import './components/autocomplete.css';
23
+ @import './components/slider.css';
24
+ @import './components/rate.css';
25
+ @import './components/upload.css';
26
+ @import './components/notification.css';
27
+ @import './components/drawer.css';
28
+ @import './components/popconfirm.css';
29
+ @import './components/badge.css';
30
+ @import './components/tag.css';
31
+ @import './components/avatar.css';
32
+ @import './components/breadcrumb.css';
33
+ @import './components/pagination.css';
34
+ @import './components/dropdown.css';
35
+ @import './components/progress.css';
36
+ @import './components/tree.css';
37
+ @import './components/treeselect.css';
38
+ @import './components/cascader.css';
39
+ @import './components/calendar.css';
40
+ @import './components/list.css';
41
+ @import './components/transfer.css';
42
+ @import './components/menu.css';
43
+ @import './components/context-menu.css';
44
+ @import './components/collapse.css';
45
+ @import './components/colorpicker.css';
46
+ @import './components/empty.css';
47
+ @import './components/result.css';
48
+ @import './components/skeleton.css';
49
+ @import './components/segmented.css';
50
+ @import './components/steps.css';
51
+ @import './components/timeline.css';
52
+ @import './components/carousel.css';
53
+ @import './components/descriptions.css';
54
+ @import './components/mentions.css';
55
+ @import './components/input-password.css';
56
+ @import './components/search-input.css';
57
+ @import './components/tag-input.css';
58
+ @import './components/pin-input.css';
59
+ @import './components/inline-edit.css';
60
+ @import './components/input-group.css';
61
+ @import './components/diagram.css';
62
+ @import './components/charts.css';
63
+ @import './components/dashboard.css';
64
+ @import './components/gantt.css';
65
+ @import './components/resource-calendar.css';
66
+ @import './components/event-timeline.css';
67
+ @import './components/schema-form-editor.css';
68
+ @import './transitions.css';
69
+ @import './print.css';
package/index.d.ts ADDED
@@ -0,0 +1,9 @@
1
+ // `@skygraph/styles` is a CSS-only package — every entrypoint is a stylesheet
2
+ // and is consumed via side-effect import (`import '@skygraph/styles'` /
3
+ // `import '@skygraph/styles/components/button'`). This declaration file exists
4
+ // solely so TypeScript with `moduleResolution: bundler` can resolve a typed
5
+ // "module" for those side-effect imports.
6
+ //
7
+ // There is no JS / TS API to type — the package contributes only style rules.
8
+
9
+ export {}
package/package.json CHANGED
@@ -1,19 +1,103 @@
1
1
  {
2
- "name": "@skygraph/styles",
3
- "version": "0.0.0-placeholder.0",
4
- "description": "SkyGraph framework-agnostic CSS — tokens, themes, component stylesheets. Placeholder.",
5
- "keywords": ["css", "design-tokens", "theme", "styles", "skygraph"],
6
- "homepage": "https://skygraph.ruslansinkevich.ru",
7
- "repository": {
8
- "type": "git",
9
- "url": "https://github.com/RuslanSinkevich/skygraph.git",
10
- "directory": "packages/styles"
11
- },
12
- "bugs": {
13
- "url": "https://github.com/RuslanSinkevich/skygraph/issues"
14
- },
15
- "author": "Ruslan Sinkevich",
16
- "license": "MIT",
17
- "main": "index.css",
18
- "files": ["index.css", "README.md"]
19
- }
2
+ "name": "@skygraph/styles",
3
+ "version": "0.1.0",
4
+ "description": "SkyGraph framework-agnostic CSS — tokens, themes, transitions, print and 60+ component stylesheets",
5
+ "license": "MIT",
6
+ "type": "module",
7
+ "sideEffects": [
8
+ "*.css"
9
+ ],
10
+ "main": "./index.css",
11
+ "types": "./index.d.ts",
12
+ "exports": {
13
+ ".": {
14
+ "types": "./index.d.ts",
15
+ "default": "./index.css"
16
+ },
17
+ "./index.css": {
18
+ "types": "./index.d.ts",
19
+ "default": "./index.css"
20
+ },
21
+ "./tokens": {
22
+ "types": "./index.d.ts",
23
+ "default": "./tokens.css"
24
+ },
25
+ "./tokens.css": {
26
+ "types": "./index.d.ts",
27
+ "default": "./tokens.css"
28
+ },
29
+ "./reset": {
30
+ "types": "./index.d.ts",
31
+ "default": "./reset.css"
32
+ },
33
+ "./reset.css": {
34
+ "types": "./index.d.ts",
35
+ "default": "./reset.css"
36
+ },
37
+ "./transitions": {
38
+ "types": "./index.d.ts",
39
+ "default": "./transitions.css"
40
+ },
41
+ "./transitions.css": {
42
+ "types": "./index.d.ts",
43
+ "default": "./transitions.css"
44
+ },
45
+ "./print": {
46
+ "types": "./index.d.ts",
47
+ "default": "./print.css"
48
+ },
49
+ "./print.css": {
50
+ "types": "./index.d.ts",
51
+ "default": "./print.css"
52
+ },
53
+ "./themes/*": {
54
+ "types": "./index.d.ts",
55
+ "default": "./themes/*.css"
56
+ },
57
+ "./themes/*.css": {
58
+ "types": "./index.d.ts",
59
+ "default": "./themes/*.css"
60
+ },
61
+ "./components/*": {
62
+ "types": "./index.d.ts",
63
+ "default": "./components/*.css"
64
+ },
65
+ "./components/*.css": {
66
+ "types": "./index.d.ts",
67
+ "default": "./components/*.css"
68
+ }
69
+ },
70
+ "files": [
71
+ "index.css",
72
+ "index.d.ts",
73
+ "reset.css",
74
+ "tokens.css",
75
+ "transitions.css",
76
+ "print.css",
77
+ "themes",
78
+ "components",
79
+ "README.md"
80
+ ],
81
+ "publishConfig": {
82
+ "access": "public"
83
+ },
84
+ "author": "Ruslan Sinkevich",
85
+ "homepage": "https://skygraph.ruslansinkevich.ru",
86
+ "repository": {
87
+ "type": "git",
88
+ "url": "git+https://github.com/RuslanSinkevich/skygraph-public.git",
89
+ "directory": "packages/styles"
90
+ },
91
+ "bugs": {
92
+ "url": "https://github.com/RuslanSinkevich/skygraph-public/issues"
93
+ },
94
+ "keywords": [
95
+ "css",
96
+ "design-tokens",
97
+ "theme",
98
+ "skygraph",
99
+ "ui",
100
+ "framework-agnostic",
101
+ "design-system"
102
+ ]
103
+ }
package/print.css ADDED
@@ -0,0 +1,88 @@
1
+ /* SkyGraph — общие правила для @media print.
2
+ *
3
+ * Подключается из styles/index.css. Все переопределения сидят строго внутри
4
+ * @media print, поэтому экранный рендеринг не затронут. `!important`
5
+ * сознательно используется ради побеждания inline-стилей (которые JS-код
6
+ * применяет на скрол-контейнерах, тенях, transform-ах для пана/зума) — это
7
+ * стандартный print-CSS паттерн и разрешён в check-no-important media-allowlist.
8
+ *
9
+ * Дополнительные компонент-специфичные блоки (например `.sg-table-toolbar`,
10
+ * `.sg-table-pagination`) живут рядом со своим компонентом
11
+ * (см. components/table.css). Этот файл — общий слой.
12
+ */
13
+
14
+ @media print {
15
+ /* Универсальная маркировка "не печатать" — ставится JS-кодом на тулбары,
16
+ * fab-кнопки, hover-overlay и т.п. */
17
+ .sg-no-print {
18
+ display: none !important;
19
+ }
20
+
21
+ /* Принудительный page-break после блока. Используется data-атрибутом
22
+ * вместо класса, чтобы не конфликтовать с пользовательскими CSS-классами. */
23
+ [data-sg-page-break] {
24
+ page-break-after: always;
25
+ break-after: page;
26
+ }
27
+
28
+ [data-sg-page-break-before] {
29
+ page-break-before: always;
30
+ break-before: page;
31
+ }
32
+
33
+ /* Корневая обёртка popup-окна — добавляется printElement(). Ничего
34
+ * лишнего, только сброс отступов и прозрачный фон под печать. */
35
+ .sg-print-root {
36
+ background: #fff;
37
+ color: #000;
38
+ }
39
+
40
+ /* На случай корпоративных принтеров: убрать тяжёлые тени и transform —
41
+ * современные браузеры в большинстве случаев игнорируют CSS-анимации в
42
+ * print-mode, но `transform` (используется панами / зумами Diagram-а)
43
+ * сохраняется и ломает раскладку, если не сбросить. */
44
+ .sg-print-root [class*="sg-"][style*="transform"] {
45
+ /* Сбрасывается JS-side в Diagram через специальный data-атрибут
46
+ * (см. ниже), чтобы пан/зум не уезжал в печать. */
47
+ }
48
+
49
+ /* Раскрыть скролл-контейнеры — иначе печатается только видимое окно. */
50
+ .sg-table-wrapper,
51
+ .sg-table-scroll,
52
+ .sg-diagram,
53
+ .sg-chart-wrapper {
54
+ overflow: visible !important;
55
+ max-height: none !important;
56
+ height: auto !important;
57
+ }
58
+
59
+ /* Diagram: при печати сбрасываем pan/zoom transform на canvas-обёртке.
60
+ * Координата `data-pan-*` остаётся атрибутом — это диагностика, не CSS. */
61
+ .sg-diagram-canvas {
62
+ transform: none !important;
63
+ }
64
+
65
+ /* Таблица — каждую строку держим вместе. */
66
+ .sg-table-row,
67
+ .sg-table-tr,
68
+ .sg-datagrid-row {
69
+ page-break-inside: avoid;
70
+ break-inside: avoid;
71
+ }
72
+
73
+ /* Charts — скрыть hover crosshair и brushing, если они оказались
74
+ * закрашены на момент печати (selection rect остаётся в DOM). */
75
+ .sg-chart-crosshair,
76
+ .sg-chart-brush-overlay {
77
+ display: none !important;
78
+ }
79
+
80
+ /* Diagram — спрятать тулбары / минимапы. Стандартного minimap-классa у
81
+ * SkyGraph пока нет, но префикс зарезервирован — пусть пользователь
82
+ * добавит `.sg-no-print` или дочерний класс из этого списка. */
83
+ .sg-diagram-toolbar,
84
+ .sg-diagram-minimap,
85
+ .sg-diagram-controls {
86
+ display: none !important;
87
+ }
88
+ }
package/reset.css ADDED
@@ -0,0 +1,17 @@
1
+ /* SkyGraph reset — all sg-* scoped elements */
2
+
3
+ [class^="sg-"],
4
+ [class*=" sg-"],
5
+ [class^="sg-"] *,
6
+ [class*=" sg-"] *,
7
+ [class^="sg-"] *::before,
8
+ [class*=" sg-"] *::before,
9
+ [class^="sg-"] *::after,
10
+ [class*=" sg-"] *::after {
11
+ box-sizing: border-box;
12
+ }
13
+
14
+ [class^="sg-"] button,
15
+ [class*=" sg-"] button {
16
+ font-family: inherit;
17
+ }
@@ -0,0 +1,17 @@
1
+ /* SkyGraph -- Dark theme
2
+ *
3
+ * Convenience re-export of the full token set. Activate dark mode by setting
4
+ * `data-sg-theme="dark"` on `<html>` (or any wrapper). The dark semantic
5
+ * tokens kick in via the `[data-sg-theme="dark"]` selector inside `tokens.css`.
6
+ *
7
+ * NOTE: this file imports the SAME `tokens.css` as `default.css`. Both light
8
+ * and dark semantic tokens live there; importing only `dark.css` does NOT
9
+ * give you a "dark-only" stylesheet — the selector decides which set wins.
10
+ *
11
+ * Example:
12
+ * import '@skygraph/styles/themes/dark'
13
+ *
14
+ * <html data-sg-theme="dark"> ... </html>
15
+ */
16
+
17
+ @import '../tokens.css';
@@ -0,0 +1,14 @@
1
+ /* SkyGraph -- Light theme (default)
2
+ *
3
+ * Convenience re-export of the full token set. After importing this file the
4
+ * `[data-sg-theme="light"]` selector inside `tokens.css` is the active layer.
5
+ *
6
+ * NOTE: this file imports the SAME `tokens.css` as `dark.css`. Both light and
7
+ * dark semantic tokens live there; the active set is decided at runtime via
8
+ * the `data-sg-theme` attribute on a parent element.
9
+ *
10
+ * Import:
11
+ * import '@skygraph/styles/themes/default'
12
+ */
13
+
14
+ @import '../tokens.css';