@vaadin/vaadin-lumo-styles 25.0.0-alpha2 → 25.0.0-alpha21

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 (261) hide show
  1. package/all-imports.d.ts +0 -8
  2. package/all-imports.js +0 -18
  3. package/components/accordion-heading.css +14 -0
  4. package/components/accordion-panel.css +15 -0
  5. package/{user-colors.d.ts → components/accordion.css} +2 -3
  6. package/components/app-layout.css +11 -0
  7. package/components/avatar-group.css +31 -0
  8. package/components/avatar.css +17 -0
  9. package/components/button.css +11 -0
  10. package/components/card.css +50 -0
  11. package/components/charts.css +11 -0
  12. package/components/checkbox-group.css +23 -0
  13. package/components/checkbox.css +14 -0
  14. package/components/combo-box.css +47 -0
  15. package/components/confirm-dialog.css +17 -0
  16. package/components/context-menu.css +32 -0
  17. package/components/crud.css +40 -0
  18. package/components/custom-field.css +20 -0
  19. package/components/dashboard.css +34 -0
  20. package/components/date-picker.css +49 -0
  21. package/components/date-time-picker.css +28 -0
  22. package/components/details-summary.css +11 -0
  23. package/components/details.css +12 -0
  24. package/components/dialog.css +16 -0
  25. package/components/drawer-toggle.css +14 -0
  26. package/components/email-field.css +25 -0
  27. package/components/field-highlighter.css +22 -0
  28. package/components/form-item.css +11 -0
  29. package/components/form-layout.css +13 -0
  30. package/components/grid-filter-column.css +6 -0
  31. package/components/grid-filter.css +12 -0
  32. package/components/grid-pro-edit-column.css +48 -0
  33. package/components/grid-pro.css +14 -0
  34. package/components/grid-selection-column.css +6 -0
  35. package/components/grid-sort-column.css +6 -0
  36. package/components/grid-sorter.css +19 -0
  37. package/components/grid-tree-column.css +6 -0
  38. package/components/grid-tree-toggle.css +11 -0
  39. package/components/grid.css +11 -0
  40. package/components/horizontal-layout.css +11 -0
  41. package/components/icon.css +11 -0
  42. package/components/index.css +71 -0
  43. package/components/input-container.css +11 -0
  44. package/components/integer-field.css +25 -0
  45. package/components/item.css +11 -0
  46. package/components/list-box.css +11 -0
  47. package/components/login-form.css +14 -0
  48. package/components/login.css +15 -0
  49. package/components/map.css +11 -0
  50. package/components/master-detail-layout.css +19 -0
  51. package/components/menu-bar.css +47 -0
  52. package/components/message-input-button.css +11 -0
  53. package/components/message-input.css +13 -0
  54. package/components/message-list.css +6 -0
  55. package/components/message.css +12 -0
  56. package/components/multi-select-combo-box.css +61 -0
  57. package/components/notification.css +15 -0
  58. package/components/number-field.css +25 -0
  59. package/components/overlay.css +11 -0
  60. package/components/password-field.css +32 -0
  61. package/components/popover.css +14 -0
  62. package/components/progress-bar.css +11 -0
  63. package/components/radio-button.css +14 -0
  64. package/components/radio-group.css +23 -0
  65. package/components/rich-text-editor.css +26 -0
  66. package/components/scroller.css +11 -0
  67. package/components/select.css +48 -0
  68. package/components/side-nav-item.css +14 -0
  69. package/components/side-nav.css +12 -0
  70. package/components/split-layout.css +11 -0
  71. package/components/tab.css +11 -0
  72. package/components/tabs.css +12 -0
  73. package/components/tabsheet.css +19 -0
  74. package/components/text-area.css +25 -0
  75. package/components/text-field.css +23 -0
  76. package/components/time-picker.css +43 -0
  77. package/components/tooltip.css +14 -0
  78. package/components/upload.css +31 -0
  79. package/components/vertical-layout.css +11 -0
  80. package/dist/lumo.css +43 -0
  81. package/dist/presets/compact.css +1 -0
  82. package/dist/utility.css +1 -0
  83. package/{color-global.js → lumo.css} +3 -4
  84. package/mixins/field-button.js +3 -4
  85. package/mixins/helper.js +3 -4
  86. package/mixins/input-field-shared.js +5 -9
  87. package/mixins/loader.js +3 -2
  88. package/mixins/menu-overlay.js +3 -4
  89. package/mixins/overlay.js +3 -4
  90. package/mixins/required-field.js +3 -4
  91. package/package.json +24 -14
  92. package/presets/compact.css +31 -0
  93. package/src/components/accordion-heading.css +42 -0
  94. package/src/components/accordion-panel.css +38 -0
  95. package/src/components/app-layout.css +193 -0
  96. package/src/components/avatar-group-menu-item.css +22 -0
  97. package/src/components/avatar-group-overlay.css +11 -0
  98. package/src/components/avatar-group.css +67 -0
  99. package/src/components/avatar.css +86 -0
  100. package/src/components/button.css +334 -0
  101. package/src/components/card.css +38 -0
  102. package/src/components/chart.css +86 -0
  103. package/src/components/checkbox-group.css +18 -0
  104. package/src/components/checkbox.css +340 -0
  105. package/src/components/combo-box-item.css +18 -0
  106. package/src/components/combo-box-overlay.css +15 -0
  107. package/src/components/combo-box.css +14 -0
  108. package/src/components/confirm-dialog-overlay.css +55 -0
  109. package/src/components/context-menu-item.css +39 -0
  110. package/src/components/context-menu-list-box.css +40 -0
  111. package/src/components/context-menu-overlay.css +61 -0
  112. package/src/components/crud-dialog-overlay.css +57 -0
  113. package/src/components/crud-edit.css +30 -0
  114. package/src/components/crud.css +157 -0
  115. package/src/components/custom-field.css +102 -0
  116. package/src/components/dashboard-layout.css +28 -0
  117. package/src/components/dashboard-section.css +85 -0
  118. package/src/components/dashboard-widget.css +140 -0
  119. package/src/components/dashboard.css +14 -0
  120. package/src/components/date-picker-month-calendar.css +192 -0
  121. package/src/components/date-picker-overlay-content.css +127 -0
  122. package/src/components/date-picker-overlay.css +48 -0
  123. package/src/components/date-picker-year.css +35 -0
  124. package/src/components/date-picker.css +41 -0
  125. package/src/components/date-time-picker.css +36 -0
  126. package/src/components/details-summary.css +131 -0
  127. package/src/components/details.css +37 -0
  128. package/src/components/dialog-overlay.css +164 -0
  129. package/src/components/drawer-toggle.css +51 -0
  130. package/src/components/email-field.css +26 -0
  131. package/src/components/field-outline.css +51 -0
  132. package/src/components/form-item.css +36 -0
  133. package/src/components/grid-filter.css +16 -0
  134. package/src/components/grid-pro-edit-select.css +19 -0
  135. package/src/components/grid-pro.css +90 -0
  136. package/src/components/grid-sorter.css +70 -0
  137. package/src/components/grid-tree-toggle.css +104 -0
  138. package/src/components/grid.css +755 -0
  139. package/src/components/horizontal-layout.css +34 -0
  140. package/src/components/icon.css +11 -0
  141. package/src/components/input-container.css +228 -0
  142. package/src/components/item.css +94 -0
  143. package/src/components/list-box.css +31 -0
  144. package/src/components/login-form-wrapper.css +113 -0
  145. package/src/components/login-overlay-wrapper.css +189 -0
  146. package/src/components/map.css +182 -0
  147. package/src/components/menu-bar-button.css +128 -0
  148. package/src/components/menu-bar-item.css +23 -0
  149. package/{badge-global.js → src/components/menu-bar-overlay.css} +5 -4
  150. package/src/components/menu-bar.css +31 -0
  151. package/src/components/message-input.css +30 -0
  152. package/src/components/message.css +57 -0
  153. package/src/components/multi-select-combo-box-chip.css +113 -0
  154. package/src/components/multi-select-combo-box-container.css +20 -0
  155. package/src/components/multi-select-combo-box-item.css +13 -0
  156. package/src/components/multi-select-combo-box-overlay.css +18 -0
  157. package/src/components/multi-select-combo-box.css +102 -0
  158. package/src/components/notification-card.css +228 -0
  159. package/src/components/notification-container.css +60 -0
  160. package/src/components/number-field.css +53 -0
  161. package/src/components/password-field-button.css +19 -0
  162. package/src/components/password-field.css +24 -0
  163. package/src/components/popover-overlay.css +20 -0
  164. package/src/components/progress-bar.css +295 -0
  165. package/src/components/radio-button.css +156 -0
  166. package/src/components/radio-group.css +18 -0
  167. package/src/components/rich-text-editor-popup-overlay.css +27 -0
  168. package/src/components/rich-text-editor.css +383 -0
  169. package/src/components/scroller.css +21 -0
  170. package/src/components/select-overlay.css +54 -0
  171. package/src/components/select-value-button.css +57 -0
  172. package/src/components/select.css +73 -0
  173. package/src/components/side-nav-item.css +183 -0
  174. package/src/components/side-nav.css +102 -0
  175. package/src/components/split-layout.css +53 -0
  176. package/src/components/tab.css +246 -0
  177. package/src/components/tabs.css +285 -0
  178. package/src/components/tabsheet.css +63 -0
  179. package/src/components/text-area.css +116 -0
  180. package/src/components/time-picker-overlay.css +15 -0
  181. package/src/components/time-picker.css +36 -0
  182. package/src/components/tooltip-overlay.css +53 -0
  183. package/src/components/upload-file.css +99 -0
  184. package/src/components/upload-icon.css +20 -0
  185. package/src/components/upload.css +56 -0
  186. package/src/components/user-tag.css +48 -0
  187. package/src/components/user-tags-overlay.css +64 -0
  188. package/src/components/vertical-layout.css +34 -0
  189. package/src/global/badge.css +167 -0
  190. package/src/global/color-scheme.css +99 -0
  191. package/{utility-global.js → src/global/index.css} +3 -4
  192. package/src/global/typography.css +113 -0
  193. package/src/mixins/checkable-field.css +67 -0
  194. package/src/mixins/combo-box-loader.css +14 -0
  195. package/src/mixins/combo-box-overlay.css +30 -0
  196. package/src/mixins/dashboard-item.css +121 -0
  197. package/src/mixins/field-base.css +187 -0
  198. package/src/mixins/field-button.css +46 -0
  199. package/src/mixins/field-error-message.css +36 -0
  200. package/src/mixins/field-helper.css +62 -0
  201. package/src/mixins/field-label.css +62 -0
  202. package/src/mixins/field-required.css +26 -0
  203. package/src/mixins/grid-pro-editor.css +35 -0
  204. package/src/mixins/group-field.css +58 -0
  205. package/src/mixins/loader.css +48 -0
  206. package/src/mixins/menu-overlay-core.css +36 -0
  207. package/src/mixins/menu-overlay-ext.css +63 -0
  208. package/src/mixins/overlay.css +131 -0
  209. package/src/mixins/resizable-overlay.css +100 -0
  210. package/src/props/color.css +98 -0
  211. package/src/props/icons.css +63 -0
  212. package/src/props/index.css +12 -0
  213. package/src/props/reset.css +11 -0
  214. package/src/props/sizing.css +19 -0
  215. package/src/props/spacing.css +27 -0
  216. package/src/props/style.css +21 -0
  217. package/src/props/typography.css +24 -0
  218. package/src/utilities/accessibility.css +17 -0
  219. package/src/utilities/background.css +189 -0
  220. package/src/utilities/border.css +173 -0
  221. package/src/utilities/filter.css +37 -0
  222. package/src/utilities/flexbox-grid.css +781 -0
  223. package/src/utilities/layout.css +629 -0
  224. package/src/utilities/shadows.css +29 -0
  225. package/src/utilities/sizing.css +142 -0
  226. package/src/utilities/spacing.css +682 -0
  227. package/src/utilities/transition.css +46 -0
  228. package/src/utilities/typography.css +424 -0
  229. package/utility.css +16 -0
  230. package/vaadin-iconset.js +4 -0
  231. package/auto-complete.css +0 -2582
  232. package/badge.d.ts +0 -3
  233. package/badge.js +0 -178
  234. package/color.d.ts +0 -5
  235. package/color.js +0 -221
  236. package/font-icons.js +0 -67
  237. package/global.js +0 -5
  238. package/presets/compact.js +0 -40
  239. package/sizing.d.ts +0 -3
  240. package/sizing.js +0 -29
  241. package/spacing.d.ts +0 -3
  242. package/spacing.js +0 -37
  243. package/style.d.ts +0 -5
  244. package/style.js +0 -119
  245. package/typography-global.js +0 -13
  246. package/typography.d.ts +0 -7
  247. package/typography.js +0 -129
  248. package/user-colors.js +0 -33
  249. package/utilities/accessibility.js +0 -21
  250. package/utilities/background.js +0 -156
  251. package/utilities/border.js +0 -147
  252. package/utilities/filter.js +0 -34
  253. package/utilities/flexbox-grid.js +0 -619
  254. package/utilities/layout.js +0 -504
  255. package/utilities/shadows.js +0 -28
  256. package/utilities/sizing.js +0 -121
  257. package/utilities/spacing.js +0 -542
  258. package/utilities/transition.js +0 -49
  259. package/utilities/typography.js +0 -344
  260. package/utility.d.ts +0 -3
  261. package/utility.js +0 -34
@@ -0,0 +1,157 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2000 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_crud {
7
+ :host {
8
+ --vaadin-crud-editor-max-height: 40%;
9
+ --vaadin-crud-editor-max-width: 40%;
10
+ --_focus-ring-color: var(--vaadin-focus-ring-color, var(--lumo-primary-color-50pct));
11
+ --_focus-ring-width: var(--vaadin-focus-ring-width, 2px);
12
+ width: 100%;
13
+ height: 400px;
14
+ font-family: var(--lumo-font-family);
15
+ }
16
+
17
+ :host,
18
+ #main {
19
+ display: flex;
20
+ flex-direction: column;
21
+ align-self: stretch;
22
+ position: relative;
23
+ overflow: hidden;
24
+ }
25
+
26
+ #main {
27
+ flex: 1 1 100%;
28
+ height: 100%;
29
+ }
30
+
31
+ :host([hidden]),
32
+ [hidden] {
33
+ display: none !important;
34
+ }
35
+
36
+ [part='toolbar'] {
37
+ display: flex;
38
+ flex-shrink: 0;
39
+ align-items: baseline;
40
+ justify-content: flex-end;
41
+ padding: var(--lumo-space-s) var(--lumo-space-m);
42
+ background-color: var(--lumo-contrast-5pct);
43
+ border-right: 1px solid var(--lumo-contrast-10pct);
44
+ border-left: 1px solid var(--lumo-contrast-10pct);
45
+ border-bottom: 1px solid var(--lumo-contrast-10pct);
46
+ }
47
+
48
+ :host([no-toolbar]) [part='toolbar'] {
49
+ display: none;
50
+ }
51
+
52
+ #container {
53
+ display: flex;
54
+ height: 100%;
55
+ }
56
+
57
+ :host([editor-position='bottom']) #container {
58
+ flex-direction: column;
59
+ }
60
+
61
+ [part='editor'] {
62
+ z-index: 1;
63
+ display: flex;
64
+ flex-direction: column;
65
+ height: 100%;
66
+ outline: none;
67
+ background: var(--lumo-base-color);
68
+ box-sizing: border-box;
69
+ position: relative;
70
+ }
71
+
72
+ :host(:not([editor-position=''])[editor-opened]:not([fullscreen])) [part='editor'] {
73
+ flex: 1 0 100%;
74
+ }
75
+
76
+ :host([editor-position='bottom'][editor-opened]:not([fullscreen])) [part='editor'] {
77
+ max-height: var(--vaadin-crud-editor-max-height);
78
+ }
79
+
80
+ :host([editor-position='aside'][editor-opened]:not([fullscreen])) [part='editor'] {
81
+ min-width: 300px;
82
+ max-width: var(--vaadin-crud-editor-max-width);
83
+ }
84
+
85
+ [part='scroller'] {
86
+ display: flex;
87
+ flex-direction: column;
88
+ overflow: auto;
89
+ flex: auto;
90
+ padding: var(--lumo-space-l);
91
+ }
92
+
93
+ [part='footer'] {
94
+ display: flex;
95
+ flex: none;
96
+ flex-direction: row-reverse;
97
+ background-color: var(--lumo-contrast-5pct);
98
+ padding: var(--lumo-space-s);
99
+ }
100
+
101
+ [part='header'] ::slotted(h3) {
102
+ margin-top: 0 !important;
103
+ }
104
+
105
+ :host(:not([dir='rtl'])) ::slotted([slot='delete-button']) {
106
+ margin-right: auto;
107
+ }
108
+
109
+ :host([dir='rtl']) ::slotted([slot='delete-button']) {
110
+ margin-left: auto;
111
+ }
112
+
113
+ :host(:not([dir='rtl'])) [part='toolbar'] ::slotted(*:not(:first-child)) {
114
+ margin-left: var(--lumo-space-s);
115
+ }
116
+
117
+ :host([dir='rtl']) [part='toolbar'] ::slotted(*:not(:first-child)) {
118
+ margin-right: var(--lumo-space-s);
119
+ }
120
+
121
+ :host([theme~='no-border']) [part='toolbar'] {
122
+ border: 0;
123
+ }
124
+
125
+ [part='footer'] ::slotted(*) {
126
+ margin-left: var(--lumo-space-s);
127
+ margin-right: var(--lumo-space-s);
128
+ }
129
+
130
+ [part='editor']:focus::before {
131
+ position: absolute;
132
+ inset: 0;
133
+ content: '';
134
+ box-shadow: inset 0 0 0 var(--_focus-ring-width) var(--_focus-ring-color);
135
+ pointer-events: none;
136
+ }
137
+
138
+ :host(:not([editor-position=''])) [part='editor']:not([hidden]) {
139
+ box-shadow: var(--lumo-box-shadow-m);
140
+ }
141
+
142
+ :host(:not([theme~='no-border']):not([editor-position=''])) [part='editor']:not([hidden]) {
143
+ border: 1px solid var(--lumo-contrast-20pct);
144
+ }
145
+
146
+ :host(:not([theme~='no-border'])[editor-position='bottom']) [part='editor']:not([hidden]) {
147
+ border-top: 0;
148
+ }
149
+
150
+ :host(:not([dir='rtl'])[editor-position='aside']) [part='editor']:not([hidden]) {
151
+ border-left: 0;
152
+ }
153
+
154
+ :host([dir='rtl']:not([theme~='no-border'])[editor-position='aside']) [part='editor']:not([hidden]) {
155
+ border-right: 0;
156
+ }
157
+ }
@@ -0,0 +1,102 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_custom-field {
7
+ :host {
8
+ display: inline-flex;
9
+ --lumo-text-field-size: var(--lumo-size-m);
10
+ color: var(--lumo-body-text-color);
11
+ font-size: var(--lumo-font-size-m);
12
+ /* align with text-field height + vertical paddings */
13
+ line-height: calc(var(--lumo-text-field-size) + 2 * var(--lumo-space-xs));
14
+ font-family: var(--lumo-font-family);
15
+ -webkit-font-smoothing: antialiased;
16
+ -moz-osx-font-smoothing: grayscale;
17
+ -webkit-tap-highlight-color: transparent;
18
+ padding: 0;
19
+ }
20
+
21
+ :host::before {
22
+ content: '\2003';
23
+ width: 0;
24
+ /* Size and position this element on the same vertical position as the input-field element
25
+ to make vertical align for the host element work as expected */
26
+ margin-top: var(--lumo-space-xs);
27
+ height: var(--lumo-text-field-size);
28
+ box-sizing: border-box;
29
+ display: inline-flex;
30
+ align-items: center;
31
+ }
32
+
33
+ :host([hidden]) {
34
+ display: none !important;
35
+ }
36
+
37
+ .vaadin-custom-field-container {
38
+ width: 100%;
39
+ display: flex;
40
+ flex-direction: column;
41
+ }
42
+
43
+ .inputs-wrapper {
44
+ flex: none;
45
+ }
46
+
47
+ /* align with text-field label */
48
+ :host([has-label]) [part='label'] {
49
+ padding-bottom: calc(0.5em - var(--lumo-space-xs));
50
+ }
51
+
52
+ :host(:not([has-label])) [part='label'],
53
+ :host(:not([has-label]))::before {
54
+ display: none;
55
+ }
56
+
57
+ /* align with text-field error message */
58
+ :host([has-error-message]) [part='error-message']::before {
59
+ height: calc(0.4em - var(--lumo-space-xs));
60
+ }
61
+
62
+ :host([focused]:not([readonly]):not([disabled])) [part='label'] {
63
+ color: var(--lumo-primary-text-color);
64
+ }
65
+
66
+ :host(:hover:not([readonly]):not([disabled]):not([focused])) [part='label'],
67
+ :host(:hover:not([readonly]):not([disabled]):not([focused])) [part='helper-text'] {
68
+ color: var(--lumo-body-text-color);
69
+ }
70
+
71
+ /* Touch device adjustment */
72
+ @media (pointer: coarse) {
73
+ :host(:hover:not([readonly]):not([disabled]):not([focused])) [part='label'] {
74
+ color: var(--lumo-secondary-text-color);
75
+ }
76
+ }
77
+
78
+ /* Disabled */
79
+ :host([disabled]) [part='label'] {
80
+ color: var(--lumo-disabled-text-color);
81
+ -webkit-text-fill-color: var(--lumo-disabled-text-color);
82
+ }
83
+
84
+ /* Small theme */
85
+ :host([theme~='small']) {
86
+ font-size: var(--lumo-font-size-s);
87
+ --lumo-text-field-size: var(--lumo-size-s);
88
+ }
89
+
90
+ :host([theme~='small'][has-label]) [part='label'] {
91
+ font-size: var(--lumo-font-size-xs);
92
+ }
93
+
94
+ :host([theme~='small'][has-label]) [part='error-message'] {
95
+ font-size: var(--lumo-font-size-xxs);
96
+ }
97
+
98
+ /* When custom-field is used with components without outer margin */
99
+ :host([theme~='whitespace'][has-label]) [part='label'] {
100
+ padding-bottom: 0.5em;
101
+ }
102
+ }
@@ -0,0 +1,28 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_dashboard-layout {
7
+ #grid {
8
+ --_default-padding: var(--lumo-space-m);
9
+ --_default-gap: var(--lumo-space-m);
10
+ --_default-row-min-height: 12rem;
11
+ }
12
+
13
+ :host([theme~='shaded-background']) {
14
+ background: var(--lumo-shade-5pct);
15
+ }
16
+
17
+ :host([theme~='elevated-widgets']) {
18
+ --vaadin-dashboard-widget-shadow: var(--lumo-box-shadow-xs);
19
+ --vaadin-dashboard-widget-border-color: var(--lumo-contrast-10pct);
20
+ --vaadin-dashboard-widget-background: linear-gradient(var(--lumo-tint-5pct), var(--lumo-tint-5pct))
21
+ var(--lumo-base-color);
22
+ }
23
+
24
+ :host([theme~='flat-widgets']) {
25
+ --vaadin-dashboard-widget-background: var(--lumo-contrast-5pct);
26
+ --vaadin-dashboard-widget-border-color: transparent;
27
+ }
28
+ }
@@ -0,0 +1,85 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_dashboard-section {
7
+ :host {
8
+ gap: var(--_gap, 1rem);
9
+ --_section-outline-offset: calc(min(var(--_gap), var(--_padding)) / 3);
10
+ --_focus-ring-offset: calc((var(--_section-outline-offset) - var(--_focus-ring-width)));
11
+ border-radius: var(--lumo-border-radius-l);
12
+ border: none;
13
+ margin: 0;
14
+ padding: 0;
15
+ }
16
+
17
+ header {
18
+ margin-bottom: calc(-1 * var(--_section-outline-offset));
19
+ line-height: var(--lumo-line-height-s);
20
+ padding-inline: var(--lumo-space-s);
21
+ min-height: var(--lumo-size-l);
22
+ align-items: center;
23
+ }
24
+
25
+ [part='title'] {
26
+ font-size: var(--lumo-font-size-xl);
27
+ font-weight: 600;
28
+ white-space: nowrap;
29
+ line-height: var(--lumo-line-height-m);
30
+ }
31
+
32
+ /* Section states */
33
+
34
+ :host([editable]) {
35
+ outline: 1px solid var(--lumo-contrast-10pct);
36
+ outline-offset: calc(var(--_section-outline-offset) - 1px);
37
+ background: var(--lumo-contrast-5pct);
38
+ box-shadow: 0 0 0 var(--_section-outline-offset) var(--lumo-contrast-5pct);
39
+ }
40
+
41
+ :host([editable]) header {
42
+ padding-inline: var(--lumo-space-xs);
43
+ }
44
+
45
+ :host([focused])::after {
46
+ content: '';
47
+ display: block;
48
+ position: absolute;
49
+ inset: 0;
50
+ border-radius: var(--lumo-border-radius-l);
51
+ z-index: 9;
52
+ outline: var(--_focus-ring-width) solid var(--_focus-ring-color);
53
+ outline-offset: var(--_focus-ring-offset);
54
+ }
55
+
56
+ :host([selected]) {
57
+ background: var(--lumo-primary-color-10pct);
58
+ box-shadow: 0 0 0 var(--_section-outline-offset) var(--lumo-primary-color-10pct);
59
+ }
60
+
61
+ :host([selected]:not([focused])) {
62
+ outline-color: var(--lumo-primary-color-50pct);
63
+ }
64
+
65
+ :host([move-mode]) ::slotted(*) {
66
+ --_widget-opacity: 0.3;
67
+ --_widget-filter: blur(10px);
68
+ }
69
+
70
+ :host([dragging]) {
71
+ background: var(--_drop-target-background-color);
72
+ outline: var(--_drop-target-border);
73
+ box-shadow: 0 0 0 var(--_section-outline-offset) var(--_drop-target-background-color);
74
+ }
75
+
76
+ /* Accessible move mode controls */
77
+
78
+ [part~='move-backward-button'] {
79
+ inset-inline-start: calc(-1 * var(--_section-outline-offset));
80
+ }
81
+
82
+ [part~='move-forward-button'] {
83
+ inset-inline-end: calc(-1 * var(--_section-outline-offset));
84
+ }
85
+ }
@@ -0,0 +1,140 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_dashboard-widget {
7
+ :host::before {
8
+ inset: calc(-1 * var(--_widget-border-width));
9
+ border: var(--_widget-border-width) solid var(--_widget-border-color);
10
+ border-radius: calc(var(--_widget-border-radius) + var(--_widget-border-width));
11
+ }
12
+
13
+ /* Widget states */
14
+
15
+ :host([editable]) {
16
+ --_widget-border-color: var(--lumo-contrast-20pct);
17
+ --_widget-border-width: 1px;
18
+ }
19
+
20
+ :host([focused])::before {
21
+ border-width: var(--_focus-ring-width);
22
+ border-color: var(--_focus-ring-color);
23
+ }
24
+
25
+ :host([selected]) {
26
+ background: var(--lumo-primary-color-10pct);
27
+ }
28
+
29
+ :host([dragging]) {
30
+ box-shadow: none;
31
+ background: var(--_drop-target-background-color);
32
+ border: var(--_drop-target-border);
33
+ }
34
+
35
+ :host([resizing])::after {
36
+ top: -1px;
37
+ background: var(--_drop-target-background-color);
38
+ border: var(--_drop-target-border);
39
+ }
40
+
41
+ /* Widget parts */
42
+
43
+ header {
44
+ min-height: var(--lumo-size-l);
45
+ padding: var(--lumo-space-xs) var(--lumo-space-m);
46
+ }
47
+
48
+ :host([editable]) header {
49
+ padding: var(--lumo-space-xs);
50
+ }
51
+
52
+ [part='title'] {
53
+ font-size: var(--lumo-font-size-l);
54
+ font-weight: 600;
55
+ }
56
+
57
+ #content {
58
+ min-height: var(--lumo-size-m);
59
+ padding-inline: var(--vaadin-dashboard-widget-padding, 0);
60
+ padding-bottom: var(--vaadin-dashboard-widget-padding, 0);
61
+ padding-top: 0;
62
+ border-radius: inherit;
63
+ border-top-left-radius: 0;
64
+ border-top-right-radius: 0;
65
+ overflow: hidden;
66
+ }
67
+
68
+ ::slotted([slot='header-content']) {
69
+ align-self: center;
70
+ }
71
+
72
+ :host([resize-mode]) #content,
73
+ :host([move-mode]) #content {
74
+ opacity: 0.75;
75
+ filter: blur(10px);
76
+ }
77
+
78
+ /* Resize handle */
79
+
80
+ [part~='resize-button'] {
81
+ --_resize-button-offset: min(var(--_gap), var(--_padding), var(--lumo-space-xs));
82
+ bottom: calc(-1 * var(--_resize-button-offset));
83
+ inset-inline-end: calc(-1 * var(--_resize-button-offset));
84
+ --icon: var(--lumo-icons-resize-handle);
85
+ }
86
+
87
+ /* Accessible resize mode controls */
88
+
89
+ [part~='resize-apply-button'] {
90
+ --icon: var(--lumo-icons-checkmark);
91
+ font-size: var(--lumo-icon-size-m);
92
+ }
93
+
94
+ [part~='resize-grow-width-button'],
95
+ [part~='resize-shrink-width-button'] {
96
+ padding-right: 0;
97
+ padding-left: 0;
98
+ min-width: var(--lumo-size-s);
99
+ }
100
+
101
+ [part~='resize-grow-height-button'],
102
+ [part~='resize-shrink-height-button'] {
103
+ height: var(--lumo-size-s);
104
+ padding-right: 0;
105
+ padding-left: 0;
106
+ }
107
+
108
+ [part~='resize-grow-height-button'],
109
+ [part~='resize-grow-width-button'] {
110
+ --icon: var(--lumo-icons-plus);
111
+ }
112
+
113
+ [part~='resize-shrink-height-button'],
114
+ [part~='resize-shrink-width-button'] {
115
+ --icon: var(--lumo-icons-minus);
116
+ }
117
+
118
+ /* Windows High Contrast Mode */
119
+ @media (forced-colors: active) {
120
+ :host {
121
+ border: 1px solid;
122
+ }
123
+
124
+ :host([focused]) {
125
+ outline: 2px solid;
126
+ outline-offset: 1px;
127
+ }
128
+
129
+ :host([selected]) {
130
+ outline-width: 1px;
131
+ outline-offset: 0;
132
+ outline-color: Highlight;
133
+ }
134
+
135
+ :host([selected][focused]) {
136
+ outline-width: 3px;
137
+ outline-offset: 0;
138
+ }
139
+ }
140
+ }
@@ -0,0 +1,14 @@
1
+ /**
2
+ * @license
3
+ * Copyright (c) 2017 - 2025 Vaadin Ltd.
4
+ * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/
5
+ */
6
+ @media lumo_components_dashboard {
7
+ :host {
8
+ --_widget-opacity: 1;
9
+ }
10
+
11
+ :host([item-selected]) {
12
+ --_widget-opacity: 0.7;
13
+ }
14
+ }