@vaadin/grid-pro 24.8.4 → 25.0.0-alpha10
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/README.md +0 -26
- package/package.json +16 -17
- package/src/styles/vaadin-grid-pro-base-styles.d.ts +13 -0
- package/src/styles/vaadin-grid-pro-base-styles.js +101 -0
- package/src/styles/vaadin-grid-pro-core-styles.d.ts +13 -0
- package/src/styles/vaadin-grid-pro-core-styles.js +13 -0
- package/src/vaadin-grid-pro-inline-editing-mixin.js +5 -5
- package/src/vaadin-grid-pro.d.ts +1 -1
- package/src/vaadin-grid-pro.js +32 -2
- package/web-types.json +2 -2
- package/web-types.lit.json +2 -2
- package/src/vaadin-lit-grid-pro-edit-checkbox.js +0 -27
- package/src/vaadin-lit-grid-pro-edit-column.js +0 -34
- package/src/vaadin-lit-grid-pro-edit-select.js +0 -29
- package/src/vaadin-lit-grid-pro-edit-text-field.js +0 -32
- package/src/vaadin-lit-grid-pro.js +0 -35
- package/theme/lumo/vaadin-lit-grid-pro-edit-checkbox.d.ts +0 -2
- package/theme/lumo/vaadin-lit-grid-pro-edit-checkbox.js +0 -2
- package/theme/lumo/vaadin-lit-grid-pro-edit-column.d.ts +0 -4
- package/theme/lumo/vaadin-lit-grid-pro-edit-column.js +0 -4
- package/theme/lumo/vaadin-lit-grid-pro-edit-select.d.ts +0 -3
- package/theme/lumo/vaadin-lit-grid-pro-edit-select.js +0 -3
- package/theme/lumo/vaadin-lit-grid-pro-edit-text-field.d.ts +0 -3
- package/theme/lumo/vaadin-lit-grid-pro-edit-text-field.js +0 -3
- package/theme/lumo/vaadin-lit-grid-pro.d.ts +0 -3
- package/theme/lumo/vaadin-lit-grid-pro.js +0 -3
- package/theme/material/vaadin-grid-pro-edit-checkbox.d.ts +0 -2
- package/theme/material/vaadin-grid-pro-edit-checkbox.js +0 -2
- package/theme/material/vaadin-grid-pro-edit-column.d.ts +0 -4
- package/theme/material/vaadin-grid-pro-edit-column.js +0 -4
- package/theme/material/vaadin-grid-pro-edit-select-styles.d.ts +0 -1
- package/theme/material/vaadin-grid-pro-edit-select-styles.js +0 -16
- package/theme/material/vaadin-grid-pro-edit-select.d.ts +0 -3
- package/theme/material/vaadin-grid-pro-edit-select.js +0 -3
- package/theme/material/vaadin-grid-pro-edit-text-field-styles.d.ts +0 -1
- package/theme/material/vaadin-grid-pro-edit-text-field-styles.js +0 -6
- package/theme/material/vaadin-grid-pro-edit-text-field.d.ts +0 -3
- package/theme/material/vaadin-grid-pro-edit-text-field.js +0 -3
- package/theme/material/vaadin-grid-pro-editor-styles.d.ts +0 -2
- package/theme/material/vaadin-grid-pro-editor-styles.js +0 -21
- package/theme/material/vaadin-grid-pro-styles.d.ts +0 -2
- package/theme/material/vaadin-grid-pro-styles.js +0 -23
- package/theme/material/vaadin-grid-pro.d.ts +0 -3
- package/theme/material/vaadin-grid-pro.js +0 -3
- package/theme/material/vaadin-lit-grid-pro-edit-checkbox.d.ts +0 -2
- package/theme/material/vaadin-lit-grid-pro-edit-checkbox.js +0 -2
- package/theme/material/vaadin-lit-grid-pro-edit-column.d.ts +0 -4
- package/theme/material/vaadin-lit-grid-pro-edit-column.js +0 -4
- package/theme/material/vaadin-lit-grid-pro-edit-select.d.ts +0 -3
- package/theme/material/vaadin-lit-grid-pro-edit-select.js +0 -3
- package/theme/material/vaadin-lit-grid-pro-edit-text-field.d.ts +0 -3
- package/theme/material/vaadin-lit-grid-pro-edit-text-field.js +0 -3
- package/theme/material/vaadin-lit-grid-pro.d.ts +0 -3
- package/theme/material/vaadin-lit-grid-pro.js +0 -3
- package/vaadin-lit-grid-pro-edit-column.d.ts +0 -1
- package/vaadin-lit-grid-pro-edit-column.js +0 -3
- package/vaadin-lit-grid-pro.d.ts +0 -1
- package/vaadin-lit-grid-pro.js +0 -3
package/README.md
CHANGED
|
@@ -40,32 +40,6 @@ import '@vaadin/grid-pro';
|
|
|
40
40
|
import '@vaadin/grid-pro/vaadin-grid-pro-edit-column.js';
|
|
41
41
|
```
|
|
42
42
|
|
|
43
|
-
## Themes
|
|
44
|
-
|
|
45
|
-
Vaadin components come with two built-in [themes](https://vaadin.com/docs/latest/styling), Lumo and Material.
|
|
46
|
-
The [main entrypoint](https://github.com/vaadin/web-components/blob/main/packages/grid-pro/vaadin-grid-pro.js) of the package uses the Lumo theme.
|
|
47
|
-
|
|
48
|
-
To use the Material theme, import the components from the `theme/material` folder:
|
|
49
|
-
|
|
50
|
-
```js
|
|
51
|
-
import '@vaadin/grid-pro/theme/material/vaadin-grid-pro.js';
|
|
52
|
-
import '@vaadin/grid-pro/theme/material/vaadin-grid-pro-edit-column.js';
|
|
53
|
-
```
|
|
54
|
-
|
|
55
|
-
You can also import the Lumo version of the components explicitly:
|
|
56
|
-
|
|
57
|
-
```js
|
|
58
|
-
import '@vaadin/grid-pro/theme/lumo/vaadin-grid-pro.js';
|
|
59
|
-
import '@vaadin/grid-pro/theme/lumo/vaadin-grid-pro-edit-column.js';
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
Finally, you can import the un-themed components from the `src` folder to get a minimal starting point:
|
|
63
|
-
|
|
64
|
-
```js
|
|
65
|
-
import '@vaadin/grid-pro/src/vaadin-grid-pro.js';
|
|
66
|
-
import '@vaadin/grid-pro/src/vaadin-grid-pro-edit-column.js';
|
|
67
|
-
```
|
|
68
|
-
|
|
69
43
|
## Contributing
|
|
70
44
|
|
|
71
45
|
Read the [contributing guide](https://vaadin.com/docs/latest/contributing) to learn about our development process, how to propose bugfixes and improvements, and how to test your changes to Vaadin components.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/grid-pro",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "25.0.0-alpha10",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -23,6 +23,8 @@
|
|
|
23
23
|
"lit.d.ts",
|
|
24
24
|
"lit.js",
|
|
25
25
|
"src",
|
|
26
|
+
"!src/styles/*-base-styles.d.ts",
|
|
27
|
+
"!src/styles/*-base-styles.js",
|
|
26
28
|
"theme",
|
|
27
29
|
"vaadin-*.d.ts",
|
|
28
30
|
"vaadin-*.js",
|
|
@@ -33,27 +35,24 @@
|
|
|
33
35
|
"Vaadin",
|
|
34
36
|
"vaadin-grid-pro",
|
|
35
37
|
"web-components",
|
|
36
|
-
"web-component"
|
|
37
|
-
"polymer"
|
|
38
|
+
"web-component"
|
|
38
39
|
],
|
|
39
40
|
"dependencies": {
|
|
40
41
|
"@open-wc/dedupe-mixin": "^1.3.0",
|
|
41
|
-
"@
|
|
42
|
-
"@vaadin/
|
|
43
|
-
"@vaadin/
|
|
44
|
-
"@vaadin/
|
|
45
|
-
"@vaadin/
|
|
46
|
-
"@vaadin/
|
|
47
|
-
"@vaadin/
|
|
48
|
-
"@vaadin/vaadin-
|
|
49
|
-
"@vaadin/vaadin-material-styles": "~24.8.4",
|
|
50
|
-
"@vaadin/vaadin-themable-mixin": "~24.8.4",
|
|
42
|
+
"@vaadin/checkbox": "25.0.0-alpha10",
|
|
43
|
+
"@vaadin/component-base": "25.0.0-alpha10",
|
|
44
|
+
"@vaadin/grid": "25.0.0-alpha10",
|
|
45
|
+
"@vaadin/lit-renderer": "25.0.0-alpha10",
|
|
46
|
+
"@vaadin/select": "25.0.0-alpha10",
|
|
47
|
+
"@vaadin/text-field": "25.0.0-alpha10",
|
|
48
|
+
"@vaadin/vaadin-lumo-styles": "25.0.0-alpha10",
|
|
49
|
+
"@vaadin/vaadin-themable-mixin": "25.0.0-alpha10",
|
|
51
50
|
"lit": "^3.0.0"
|
|
52
51
|
},
|
|
53
52
|
"devDependencies": {
|
|
54
|
-
"@vaadin/chai-plugins": "
|
|
55
|
-
"@vaadin/test-runner-commands": "
|
|
56
|
-
"@vaadin/testing-helpers": "^
|
|
53
|
+
"@vaadin/chai-plugins": "25.0.0-alpha10",
|
|
54
|
+
"@vaadin/test-runner-commands": "25.0.0-alpha10",
|
|
55
|
+
"@vaadin/testing-helpers": "^2.0.0",
|
|
57
56
|
"sinon": "^18.0.0"
|
|
58
57
|
},
|
|
59
58
|
"cvdlName": "vaadin-grid-pro",
|
|
@@ -61,5 +60,5 @@
|
|
|
61
60
|
"web-types.json",
|
|
62
61
|
"web-types.lit.json"
|
|
63
62
|
],
|
|
64
|
-
"gitHead": "
|
|
63
|
+
"gitHead": "6cc6c94079e805fa5b2f0af4dbf3b2a7485e57d0"
|
|
65
64
|
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
+
*
|
|
5
|
+
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
+
* license.
|
|
10
|
+
*/
|
|
11
|
+
import type { CSSResult } from 'lit';
|
|
12
|
+
|
|
13
|
+
export const gridProStyles: CSSResult;
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
+
*
|
|
5
|
+
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
+
* license.
|
|
10
|
+
*/
|
|
11
|
+
import '@vaadin/component-base/src/style-props.js';
|
|
12
|
+
import { css } from 'lit';
|
|
13
|
+
import { gridStyles } from '@vaadin/grid/src/styles/vaadin-grid-base-styles.js';
|
|
14
|
+
|
|
15
|
+
const gridPro = css`
|
|
16
|
+
[part~='body-cell'] {
|
|
17
|
+
--_highlight-color: color-mix(in srgb, currentColor 5%, transparent);
|
|
18
|
+
--_highlight-color2: color-mix(in srgb, currentColor 10%, transparent);
|
|
19
|
+
--_highlight-bg: linear-gradient(var(--_highlight-color), var(--_highlight-color));
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
[part~='editable-cell'] {
|
|
23
|
+
display: flex;
|
|
24
|
+
align-items: inherit;
|
|
25
|
+
align-self: stretch;
|
|
26
|
+
flex: 1;
|
|
27
|
+
min-width: 0;
|
|
28
|
+
cursor: var(--vaadin-clickable-cursor);
|
|
29
|
+
outline: 0;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
[part~='editable-cell']:hover,
|
|
33
|
+
:host([navigating]) [part~='editable-cell']:focus {
|
|
34
|
+
background: var(--vaadin-grid-pro-editable-cell-background-hover, var(--_highlight-bg));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/* Indicate editable cells */
|
|
38
|
+
|
|
39
|
+
:host([theme~='highlight-editable-cells']) [part~='editable-cell'] {
|
|
40
|
+
background: var(--vaadin-grid-pro-editable-cell-background, var(--_highlight-bg));
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
:host([theme~='highlight-editable-cells']) [part~='editable-cell']:is(:hover, :focus-visible) {
|
|
44
|
+
background:
|
|
45
|
+
var(--vaadin-grid-pro-editable-cell-background-hover, var(--_highlight-bg)),
|
|
46
|
+
var(--vaadin-grid-pro-editable-cell-background, var(--_highlight-bg));
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/* Indicate read-only cells */
|
|
50
|
+
|
|
51
|
+
/* prettier-ignore */
|
|
52
|
+
:host([theme~='highlight-read-only-cells']) [part~='body-cell']:not(:has([part~='editable-cell'])) {
|
|
53
|
+
--vaadin-grid-cell-background-hover: repeating-linear-gradient(
|
|
54
|
+
-45deg,
|
|
55
|
+
transparent,
|
|
56
|
+
transparent 30%,
|
|
57
|
+
var(--_highlight-color2) 30%,
|
|
58
|
+
var(--_highlight-color2) 50%
|
|
59
|
+
);
|
|
60
|
+
background-size: 6px 6px;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/* Loading editor cell styles are used by Flow GridPro */
|
|
64
|
+
:host([loading-editor]) [part~='focused-cell']::before {
|
|
65
|
+
content: '';
|
|
66
|
+
position: absolute;
|
|
67
|
+
inset: 0;
|
|
68
|
+
pointer-events: none;
|
|
69
|
+
box-shadow: inset 0 0 0 var(--vaadin-focus-ring-width) var(--vaadin-focus-ring-color);
|
|
70
|
+
animation: loading-editor 1.4s infinite;
|
|
71
|
+
opacity: 0;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
@keyframes loading-editor {
|
|
75
|
+
50% {
|
|
76
|
+
opacity: 1;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
[part~='updating-cell']::after {
|
|
81
|
+
content: '';
|
|
82
|
+
position: absolute;
|
|
83
|
+
inset: var(--_cell-padding);
|
|
84
|
+
margin: var(--vaadin-focus-ring-width);
|
|
85
|
+
border-radius: 4px;
|
|
86
|
+
background-size: max(4em, 50%);
|
|
87
|
+
background-repeat: no-repeat;
|
|
88
|
+
background-position: min(-200%, -4em) 0;
|
|
89
|
+
background-image: linear-gradient(90deg, transparent, currentColor, transparent);
|
|
90
|
+
animation: updating-cell 1.3s ease-out infinite;
|
|
91
|
+
opacity: 0.1;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
@keyframes updating-cell {
|
|
95
|
+
100% {
|
|
96
|
+
background-position: max(300%, 8em) 0;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
`;
|
|
100
|
+
|
|
101
|
+
export const gridProStyles = [gridPro, gridStyles];
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
+
*
|
|
5
|
+
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
+
* license.
|
|
10
|
+
*/
|
|
11
|
+
import type { CSSResult } from 'lit';
|
|
12
|
+
|
|
13
|
+
export const gridProStyles: CSSResult;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
+
*
|
|
5
|
+
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
+
* license.
|
|
10
|
+
*/
|
|
11
|
+
import { gridStyles } from '@vaadin/grid/src/styles/vaadin-grid-core-styles.js';
|
|
12
|
+
|
|
13
|
+
export const gridProStyles = gridStyles;
|
|
@@ -543,17 +543,17 @@ export const InlineEditingMixin = (superClass) =>
|
|
|
543
543
|
|
|
544
544
|
/**
|
|
545
545
|
* @param {!HTMLElement} row
|
|
546
|
-
* @
|
|
547
|
-
* @protected
|
|
546
|
+
* @private
|
|
548
547
|
*/
|
|
549
|
-
|
|
548
|
+
__updateRow(row) {
|
|
549
|
+
const item = this.__getRowItem(row);
|
|
550
550
|
if (this.__edited) {
|
|
551
551
|
const { cell, model } = this.__edited;
|
|
552
552
|
if (cell.parentNode === row && model.item !== item) {
|
|
553
553
|
this._stopEdit();
|
|
554
554
|
}
|
|
555
555
|
}
|
|
556
|
-
super.
|
|
556
|
+
super.__updateRow(row, item);
|
|
557
557
|
}
|
|
558
558
|
|
|
559
559
|
/**
|
|
@@ -588,7 +588,7 @@ export const InlineEditingMixin = (superClass) =>
|
|
|
588
588
|
const isEditable = column.isCellEditable(model);
|
|
589
589
|
|
|
590
590
|
// Cancel editing if the cell is currently edited one and becomes no longer editable
|
|
591
|
-
// TODO: should be moved to `
|
|
591
|
+
// TODO: should be moved to `__updateRow` when Grid connector is updated to use it.
|
|
592
592
|
if (this.__edited && this.__edited.cell === cell && !isEditable) {
|
|
593
593
|
this._stopEdit(true, true);
|
|
594
594
|
}
|
package/src/vaadin-grid-pro.d.ts
CHANGED
package/src/vaadin-grid-pro.js
CHANGED
|
@@ -9,7 +9,9 @@
|
|
|
9
9
|
* license.
|
|
10
10
|
*/
|
|
11
11
|
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
12
|
+
import { SlotStylesMixin } from '@vaadin/component-base/src/slot-styles-mixin.js';
|
|
12
13
|
import { Grid } from '@vaadin/grid/src/vaadin-grid.js';
|
|
14
|
+
import { gridProStyles } from './styles/vaadin-grid-pro-core-styles.js';
|
|
13
15
|
import { InlineEditingMixin } from './vaadin-grid-pro-inline-editing-mixin.js';
|
|
14
16
|
|
|
15
17
|
/**
|
|
@@ -19,7 +21,7 @@ import { InlineEditingMixin } from './vaadin-grid-pro-inline-editing-mixin.js';
|
|
|
19
21
|
*
|
|
20
22
|
* See [`<vaadin-grid>`](#/elements/vaadin-grid) documentation for details.
|
|
21
23
|
*
|
|
22
|
-
* ```
|
|
24
|
+
* ```html
|
|
23
25
|
* <vaadin-grid-pro></vaadin-grid-pro>
|
|
24
26
|
* ```
|
|
25
27
|
*
|
|
@@ -49,7 +51,7 @@ import { InlineEditingMixin } from './vaadin-grid-pro-inline-editing-mixin.js';
|
|
|
49
51
|
* @extends Grid
|
|
50
52
|
* @mixes InlineEditingMixin
|
|
51
53
|
*/
|
|
52
|
-
class GridPro extends InlineEditingMixin(Grid) {
|
|
54
|
+
class GridPro extends SlotStylesMixin(InlineEditingMixin(Grid)) {
|
|
53
55
|
static get is() {
|
|
54
56
|
return 'vaadin-grid-pro';
|
|
55
57
|
}
|
|
@@ -57,6 +59,34 @@ class GridPro extends InlineEditingMixin(Grid) {
|
|
|
57
59
|
static get cvdlName() {
|
|
58
60
|
return 'vaadin-grid-pro';
|
|
59
61
|
}
|
|
62
|
+
|
|
63
|
+
static get styles() {
|
|
64
|
+
return gridProStyles;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
get slotStyles() {
|
|
68
|
+
const tag = this.localName;
|
|
69
|
+
|
|
70
|
+
return [
|
|
71
|
+
`
|
|
72
|
+
${tag} [theme="grid-pro-editor"] {
|
|
73
|
+
--vaadin-input-field-border-radius: 0px;
|
|
74
|
+
--vaadin-input-field-border-width: 0px;
|
|
75
|
+
width: 100%;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
${tag} [theme="grid-pro-editor"]::part(input-field) {
|
|
79
|
+
height: 100%;
|
|
80
|
+
outline-offset: calc(var(--vaadin-focus-ring-width) * -1);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
vaadin-grid-cell-content:has([theme="grid-pro-editor"]) {
|
|
84
|
+
padding: 0;
|
|
85
|
+
overflow: visible;
|
|
86
|
+
}
|
|
87
|
+
`,
|
|
88
|
+
];
|
|
89
|
+
}
|
|
60
90
|
}
|
|
61
91
|
|
|
62
92
|
defineCustomElement(GridPro);
|
package/web-types.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/grid-pro",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "25.0.0-alpha10",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"contributions": {
|
|
7
7
|
"html": {
|
|
@@ -401,7 +401,7 @@
|
|
|
401
401
|
},
|
|
402
402
|
{
|
|
403
403
|
"name": "vaadin-grid-pro",
|
|
404
|
-
"description": "`<vaadin-grid-pro>` is a high quality data grid / data table Web Component with extended functionality.\nIt extends `<vaadin-grid>` and adds extra features on top of the basic ones.\n\nSee [`<vaadin-grid>`](https://cdn.vaadin.com/vaadin-web-components/
|
|
404
|
+
"description": "`<vaadin-grid-pro>` is a high quality data grid / data table Web Component with extended functionality.\nIt extends `<vaadin-grid>` and adds extra features on top of the basic ones.\n\nSee [`<vaadin-grid>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-grid) documentation for details.\n\n```html\n<vaadin-grid-pro></vaadin-grid-pro>\n```\n\n### Internal components\n\nIn addition to `<vaadin-grid-pro>` itself, the following internal\ncomponents are themable:\n\n- `<vaadin-grid-pro-edit-checkbox>` - has the same API as [`<vaadin-checkbox>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-checkbox).\n- `<vaadin-grid-pro-edit-text-field>` - has the same API as [`<vaadin-text-field>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-text-field).\n- `<vaadin-grid-pro-edit-select>` - has the same API as [`<vaadin-select>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-select).",
|
|
405
405
|
"attributes": [
|
|
406
406
|
{
|
|
407
407
|
"name": "accessible-name",
|
package/web-types.lit.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/grid-pro",
|
|
4
|
-
"version": "
|
|
4
|
+
"version": "25.0.0-alpha10",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"framework": "lit",
|
|
7
7
|
"framework-config": {
|
|
@@ -177,7 +177,7 @@
|
|
|
177
177
|
},
|
|
178
178
|
{
|
|
179
179
|
"name": "vaadin-grid-pro",
|
|
180
|
-
"description": "`<vaadin-grid-pro>` is a high quality data grid / data table Web Component with extended functionality.\nIt extends `<vaadin-grid>` and adds extra features on top of the basic ones.\n\nSee [`<vaadin-grid>`](https://cdn.vaadin.com/vaadin-web-components/
|
|
180
|
+
"description": "`<vaadin-grid-pro>` is a high quality data grid / data table Web Component with extended functionality.\nIt extends `<vaadin-grid>` and adds extra features on top of the basic ones.\n\nSee [`<vaadin-grid>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-grid) documentation for details.\n\n```html\n<vaadin-grid-pro></vaadin-grid-pro>\n```\n\n### Internal components\n\nIn addition to `<vaadin-grid-pro>` itself, the following internal\ncomponents are themable:\n\n- `<vaadin-grid-pro-edit-checkbox>` - has the same API as [`<vaadin-checkbox>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-checkbox).\n- `<vaadin-grid-pro-edit-text-field>` - has the same API as [`<vaadin-text-field>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-text-field).\n- `<vaadin-grid-pro-edit-select>` - has the same API as [`<vaadin-select>`](https://cdn.vaadin.com/vaadin-web-components/25.0.0-alpha10/#/elements/vaadin-select).",
|
|
181
181
|
"extension": true,
|
|
182
182
|
"attributes": [
|
|
183
183
|
{
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import { Checkbox } from '@vaadin/checkbox/src/vaadin-lit-checkbox.js';
|
|
12
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* An element used internally by `<vaadin-grid-pro>`. Not intended to be used separately.
|
|
16
|
-
*
|
|
17
|
-
* @customElement
|
|
18
|
-
* @extends Checkbox
|
|
19
|
-
* @private
|
|
20
|
-
*/
|
|
21
|
-
class GridProEditCheckbox extends Checkbox {
|
|
22
|
-
static get is() {
|
|
23
|
-
return 'vaadin-grid-pro-edit-checkbox';
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
defineCustomElement(GridProEditCheckbox);
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import './vaadin-lit-grid-pro-edit-checkbox.js';
|
|
12
|
-
import './vaadin-lit-grid-pro-edit-select.js';
|
|
13
|
-
import './vaadin-lit-grid-pro-edit-text-field.js';
|
|
14
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
15
|
-
import { GridColumn } from '@vaadin/grid/src/vaadin-lit-grid-column.js';
|
|
16
|
-
import { GridProEditColumnMixin } from './vaadin-grid-pro-edit-column-mixin.js';
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* LitElement based version of `<vaadin-grid-pro-edit-column>` web component.
|
|
20
|
-
*
|
|
21
|
-
* ## Disclaimer
|
|
22
|
-
*
|
|
23
|
-
* This component is an experiment and not yet a part of Vaadin platform.
|
|
24
|
-
* There is no ETA regarding specific Vaadin version where it'll land.
|
|
25
|
-
*/
|
|
26
|
-
class GridProEditColumn extends GridProEditColumnMixin(GridColumn) {
|
|
27
|
-
static get is() {
|
|
28
|
-
return 'vaadin-grid-pro-edit-column';
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
defineCustomElement(GridProEditColumn);
|
|
33
|
-
|
|
34
|
-
export { GridProEditColumn };
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
12
|
-
import { Select } from '@vaadin/select/src/vaadin-lit-select.js';
|
|
13
|
-
import { GridProEditSelectMixin } from './vaadin-grid-pro-edit-select-mixin.js';
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* An element used internally by `<vaadin-grid-pro>`. Not intended to be used separately.
|
|
17
|
-
*
|
|
18
|
-
* @customElement
|
|
19
|
-
* @extends Select
|
|
20
|
-
* @mixes GridProEditSelectMixin
|
|
21
|
-
* @private
|
|
22
|
-
*/
|
|
23
|
-
class GridProEditSelect extends GridProEditSelectMixin(Select) {
|
|
24
|
-
static get is() {
|
|
25
|
-
return 'vaadin-grid-pro-edit-select';
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
defineCustomElement(GridProEditSelect);
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
12
|
-
import { TextField } from '@vaadin/text-field/src/vaadin-lit-text-field.js';
|
|
13
|
-
|
|
14
|
-
/**
|
|
15
|
-
* An element used internally by `<vaadin-grid-pro>`. Not intended to be used separately.
|
|
16
|
-
*
|
|
17
|
-
* @customElement
|
|
18
|
-
* @extends TextField
|
|
19
|
-
* @private
|
|
20
|
-
*/
|
|
21
|
-
class GridProEditText extends TextField {
|
|
22
|
-
static get is() {
|
|
23
|
-
return 'vaadin-grid-pro-edit-text-field';
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
ready() {
|
|
27
|
-
super.ready();
|
|
28
|
-
this.setAttribute('theme', 'grid-pro-editor');
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
defineCustomElement(GridProEditText);
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright (c) 2000 - 2025 Vaadin Ltd.
|
|
4
|
-
*
|
|
5
|
-
* This program is available under Vaadin Commercial License and Service Terms.
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* See https://vaadin.com/commercial-license-and-service-terms for the full
|
|
9
|
-
* license.
|
|
10
|
-
*/
|
|
11
|
-
import { defineCustomElement } from '@vaadin/component-base/src/define.js';
|
|
12
|
-
import { Grid } from '@vaadin/grid/src/vaadin-lit-grid.js';
|
|
13
|
-
import { InlineEditingMixin } from './vaadin-grid-pro-inline-editing-mixin.js';
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* LitElement based version of `<vaadin-grid-pro>` web component.
|
|
17
|
-
*
|
|
18
|
-
* ## Disclaimer
|
|
19
|
-
*
|
|
20
|
-
* This component is an experiment and not yet a part of Vaadin platform.
|
|
21
|
-
* There is no ETA regarding specific Vaadin version where it'll land.
|
|
22
|
-
*/
|
|
23
|
-
class GridPro extends InlineEditingMixin(Grid) {
|
|
24
|
-
static get is() {
|
|
25
|
-
return 'vaadin-grid-pro';
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
static get cvdlName() {
|
|
29
|
-
return 'vaadin-grid-pro';
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
defineCustomElement(GridPro);
|
|
34
|
-
|
|
35
|
-
export { GridPro };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
2
|
-
import { gridProEditor } from './vaadin-grid-pro-editor-styles.js';
|
|
3
|
-
|
|
4
|
-
const gridProEditSelect = css`
|
|
5
|
-
:host([theme~='grid-pro-editor']) [part='input-field'] ::slotted([slot='value']) {
|
|
6
|
-
box-sizing: border-box;
|
|
7
|
-
font-size: inherit;
|
|
8
|
-
/* prevent selection on editor focus */
|
|
9
|
-
-webkit-user-select: none;
|
|
10
|
-
user-select: none;
|
|
11
|
-
}
|
|
12
|
-
`;
|
|
13
|
-
|
|
14
|
-
registerStyles('vaadin-grid-pro-edit-select', [gridProEditor, gridProEditSelect], {
|
|
15
|
-
moduleId: 'material-grid-pro-edit-select',
|
|
16
|
-
});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
2
|
-
import { gridProEditor } from './vaadin-grid-pro-editor-styles.js';
|
|
3
|
-
|
|
4
|
-
registerStyles('vaadin-grid-pro-edit-text-field', gridProEditor, {
|
|
5
|
-
moduleId: 'material-grid-pro-edit-text-field',
|
|
6
|
-
});
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
2
|
-
|
|
3
|
-
const gridProEditor = css`
|
|
4
|
-
:host([theme~='grid-pro-editor']) {
|
|
5
|
-
width: 100%;
|
|
6
|
-
margin: -6px 0 0;
|
|
7
|
-
padding: 0;
|
|
8
|
-
top: 6px;
|
|
9
|
-
will-change: transform;
|
|
10
|
-
font-size: inherit;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
:host([theme~='grid-pro-editor']) ::slotted(input) {
|
|
14
|
-
box-sizing: border-box;
|
|
15
|
-
font-size: inherit;
|
|
16
|
-
}
|
|
17
|
-
`;
|
|
18
|
-
|
|
19
|
-
registerStyles('', gridProEditor, { moduleId: 'material-grid-pro-editor' });
|
|
20
|
-
|
|
21
|
-
export { gridProEditor };
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import '@vaadin/vaadin-material-styles/color.js';
|
|
2
|
-
import '@vaadin/grid/theme/material/vaadin-grid-styles.js';
|
|
3
|
-
import { css, registerStyles } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';
|
|
4
|
-
|
|
5
|
-
registerStyles(
|
|
6
|
-
'vaadin-grid-pro',
|
|
7
|
-
css`
|
|
8
|
-
:host([navigating]) [part~='cell']:active {
|
|
9
|
-
box-shadow: inset 0 0 0 2px var(--material-primary-color);
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
[part~='editable-cell'],
|
|
13
|
-
[part~='editable-cell'] ::slotted(vaadin-grid-cell-content) {
|
|
14
|
-
cursor: pointer;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
[part~='row'] > [part~='editable-cell']:hover,
|
|
18
|
-
[part~='row'] > [part~='editable-cell']:focus {
|
|
19
|
-
background: var(--material-background-color) linear-gradient(rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.08));
|
|
20
|
-
}
|
|
21
|
-
`,
|
|
22
|
-
{ moduleId: 'material-grid-pro' },
|
|
23
|
-
);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/vaadin-grid-pro-edit-column.js';
|
package/vaadin-lit-grid-pro.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './src/vaadin-grid-pro.js';
|
package/vaadin-lit-grid-pro.js
DELETED