@digital-realty/ix-grid 1.0.49-alpha.1 → 1.0.49-alpha.2

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 (66) hide show
  1. package/dist/IxGrid.d.ts +74 -74
  2. package/dist/IxGrid.js +280 -280
  3. package/dist/IxGridNav.d.ts +2 -0
  4. package/dist/IxGridNav.js +9 -0
  5. package/dist/IxGridNav.js.map +1 -0
  6. package/dist/components/IxGridColumnFilter.d.ts +29 -29
  7. package/dist/components/IxGridColumnFilter.js +158 -158
  8. package/dist/components/IxGridDownloadMenu.d.ts +15 -15
  9. package/dist/components/IxGridDownloadMenu.js +51 -51
  10. package/dist/components/IxGridNav.d.ts +15 -15
  11. package/dist/components/IxGridNav.js +20 -20
  12. package/dist/components/IxGridNoRows.d.ts +10 -9
  13. package/dist/components/IxGridNoRows.js +49 -36
  14. package/dist/components/IxGridNoRows.js.map +1 -1
  15. package/dist/components/IxGridRowFilter.d.ts +41 -41
  16. package/dist/components/IxGridRowFilter.js +201 -201
  17. package/dist/components/IxPagination.d.ts +13 -13
  18. package/dist/components/IxPagination.js +59 -59
  19. package/dist/components/grid-column-filter-styles.d.ts +1 -1
  20. package/dist/components/grid-column-filter-styles.js +2 -2
  21. package/dist/components/grid-download-menu-styles.d.ts +1 -1
  22. package/dist/components/grid-download-menu-styles.js +2 -2
  23. package/dist/components/grid-row-filter-styles.d.ts +1 -1
  24. package/dist/components/grid-row-filter-styles.js +3 -3
  25. package/dist/components/grid-row-filter-styles.js.map +1 -1
  26. package/dist/components/ix-grid-nav.d.ts +1 -1
  27. package/dist/components/ix-grid-nav.js +2 -2
  28. package/dist/components/ix-grid-no-rows.d.ts +1 -1
  29. package/dist/components/ix-grid-no-rows.js +2 -2
  30. package/dist/components/pagination-styles.d.ts +1 -1
  31. package/dist/components/pagination-styles.js +2 -2
  32. package/dist/grid-view-styles.d.ts +1 -1
  33. package/dist/grid-view-styles.js +2 -2
  34. package/dist/index.d.ts +3 -3
  35. package/dist/index.js +3 -3
  36. package/dist/ix-grid-copy.d.ts +10 -10
  37. package/dist/ix-grid-copy.js +10 -10
  38. package/dist/ix-grid-nav.d.ts +1 -0
  39. package/dist/ix-grid-nav.js +3 -0
  40. package/dist/ix-grid-nav.js.map +1 -0
  41. package/dist/ix-grid-no-rows.d.ts +1 -0
  42. package/dist/ix-grid-no-rows.js +3 -0
  43. package/dist/ix-grid-no-rows.js.map +1 -0
  44. package/dist/ix-grid.d.ts +1 -1
  45. package/dist/ix-grid.js +2 -2
  46. package/dist/ix-grid.min.js +1 -1
  47. package/dist/models/IxGridDownloadMenuItemModel.d.ts +7 -7
  48. package/dist/models/IxGridDownloadMenuItemModel.js +1 -1
  49. package/dist/react/IxGridNav.d.ts +2 -2
  50. package/dist/react/IxGridNav.js +8 -8
  51. package/dist/test/ix-grid-column-filter.test.d.ts +1 -1
  52. package/dist/test/ix-grid-column-filter.test.js +35 -35
  53. package/dist/test/ix-grid-row-filter.test.d.ts +1 -1
  54. package/dist/test/ix-grid-row-filter.test.js +36 -36
  55. package/dist/test/ix-grid.test.d.ts +2 -2
  56. package/dist/test/ix-grid.test.js +49 -49
  57. package/dist/test/ix-grid.test.js.map +1 -1
  58. package/dist/test/ix-pagination.test.d.ts +1 -1
  59. package/dist/test/ix-pagination.test.js +21 -21
  60. package/package.json +11 -11
  61. package/src/{react/IxGridNav.ts → IxGridNav.ts} +1 -1
  62. package/src/components/IxGridNoRows.ts +22 -11
  63. package/src/components/grid-row-filter-styles.ts +1 -1
  64. package/src/{components/ix-grid-nav.ts → ix-grid-nav.ts} +1 -1
  65. package/src/ix-grid-no-rows.ts +3 -0
  66. package/src/test/ix-grid.test.ts +1 -1
@@ -1,36 +1,36 @@
1
- import { html } from 'lit';
2
- import { fixture, expect, elementUpdated } from '@open-wc/testing';
3
- import '../components/IxGridColumnFilter.js';
4
- const columns = [
5
- {
6
- name: 'firstName',
7
- header: 'First name',
8
- hidden: false,
9
- },
10
- {
11
- name: 'lastName',
12
- header: 'Last name',
13
- hidden: true,
14
- },
15
- {
16
- name: 'middleName',
17
- header: 'Middle name',
18
- hidden: false,
19
- },
20
- ];
21
- describe('IxGridColumnFilter', () => {
22
- it('renders the grid column filter component', async () => {
23
- const el = await fixture(html `<ix-grid-column-filter></ix-grid-column-filter>`);
24
- expect(el).to.not.be.null;
25
- });
26
- it('renders the grid column filters list', async () => {
27
- var _a, _b;
28
- const el = await fixture(html `<ix-grid-column-filter .columns=${columns}></ix-grid-column-filter>`);
29
- const list = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('.list');
30
- list.click();
31
- await elementUpdated(el);
32
- const options = (_b = el.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelectorAll('ix-switch');
33
- expect(options === null || options === void 0 ? void 0 : options.length).to.equal(3);
34
- });
35
- });
1
+ import { html } from 'lit';
2
+ import { fixture, expect, elementUpdated } from '@open-wc/testing';
3
+ import '../components/IxGridColumnFilter.js';
4
+ const columns = [
5
+ {
6
+ name: 'firstName',
7
+ header: 'First name',
8
+ hidden: false,
9
+ },
10
+ {
11
+ name: 'lastName',
12
+ header: 'Last name',
13
+ hidden: true,
14
+ },
15
+ {
16
+ name: 'middleName',
17
+ header: 'Middle name',
18
+ hidden: false,
19
+ },
20
+ ];
21
+ describe('IxGridColumnFilter', () => {
22
+ it('renders the grid column filter component', async () => {
23
+ const el = await fixture(html `<ix-grid-column-filter></ix-grid-column-filter>`);
24
+ expect(el).to.not.be.null;
25
+ });
26
+ it('renders the grid column filters list', async () => {
27
+ var _a, _b;
28
+ const el = await fixture(html `<ix-grid-column-filter .columns=${columns}></ix-grid-column-filter>`);
29
+ const list = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('.list');
30
+ list.click();
31
+ await elementUpdated(el);
32
+ const options = (_b = el.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelectorAll('ix-switch');
33
+ expect(options === null || options === void 0 ? void 0 : options.length).to.equal(3);
34
+ });
35
+ });
36
36
  //# sourceMappingURL=ix-grid-column-filter.test.js.map
@@ -1 +1 @@
1
- import '../components/IxGridRowFilter.js';
1
+ import '../components/IxGridRowFilter.js';
@@ -1,37 +1,37 @@
1
- import { html } from 'lit';
2
- import { fixture, expect, elementUpdated } from '@open-wc/testing';
3
- import '../components/IxGridRowFilter.js';
4
- const columns = [
5
- {
6
- name: 'firstName',
7
- header: 'First name',
8
- filterable: true,
9
- },
10
- {
11
- name: 'lastName',
12
- header: 'Last name',
13
- filterable: true,
14
- },
15
- {
16
- name: 'middleName',
17
- header: 'Middle name',
18
- filterable: false,
19
- },
20
- {
21
- name: 'email',
22
- header: 'Email',
23
- filterable: true,
24
- },
25
- ];
26
- describe('IxGridRowFilter', () => {
27
- it('renders and popluates the grid row filter', async () => {
28
- var _a, _b;
29
- const el = await fixture(html `<ix-grid-row-filter .columns=${columns}></ix-grid-row-filter>`);
30
- const openMenu = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('.filter-button');
31
- openMenu.click();
32
- await elementUpdated(el);
33
- const options = (_b = el.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelectorAll('select[data-v="firstName"] option');
34
- expect(options === null || options === void 0 ? void 0 : options.length).to.equal(3);
35
- });
36
- });
1
+ import { html } from 'lit';
2
+ import { fixture, expect, elementUpdated } from '@open-wc/testing';
3
+ import '../components/IxGridRowFilter.js';
4
+ const columns = [
5
+ {
6
+ name: 'firstName',
7
+ header: 'First name',
8
+ filterable: true,
9
+ },
10
+ {
11
+ name: 'lastName',
12
+ header: 'Last name',
13
+ filterable: true,
14
+ },
15
+ {
16
+ name: 'middleName',
17
+ header: 'Middle name',
18
+ filterable: false,
19
+ },
20
+ {
21
+ name: 'email',
22
+ header: 'Email',
23
+ filterable: true,
24
+ },
25
+ ];
26
+ describe('IxGridRowFilter', () => {
27
+ it('renders and popluates the grid row filter', async () => {
28
+ var _a, _b;
29
+ const el = await fixture(html `<ix-grid-row-filter .columns=${columns}></ix-grid-row-filter>`);
30
+ const openMenu = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('.filter-button');
31
+ openMenu.click();
32
+ await elementUpdated(el);
33
+ const options = (_b = el.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelectorAll('select[data-v="firstName"] option');
34
+ expect(options === null || options === void 0 ? void 0 : options.length).to.equal(3);
35
+ });
36
+ });
37
37
  //# sourceMappingURL=ix-grid-row-filter.test.js.map
@@ -1,2 +1,2 @@
1
- import '../components/ix-grid-no-rows.js';
2
- import '../ix-grid.js';
1
+ import '../ix-grid-no-rows.js';
2
+ import '../ix-grid.js';
@@ -1,57 +1,57 @@
1
- import { html } from 'lit';
2
- import { fixture, expect } from '@open-wc/testing';
3
- import '../components/ix-grid-no-rows.js';
4
- import '../ix-grid.js';
5
- const rows = [
6
- {
7
- name: 'one',
8
- },
9
- {
10
- name: 'two',
11
- },
12
- {
13
- name: 'three',
14
- },
15
- ];
16
- const columns = [
17
- {
18
- name: 'one',
19
- header: 'one',
20
- bodyRenderer: row => html ` <span>${row.name}</span>`,
21
- },
22
- {
23
- name: 'two',
24
- header: 'one',
25
- bodyRenderer: row => html ` <span>${row.name}</span>`,
26
- },
27
- {
28
- name: 'three',
29
- header: 'one',
30
- bodyRenderer: row => html ` <span>${row.name}</span>`,
31
- },
32
- ];
33
- describe('IxGrid', () => {
34
- it('renders a grid', async () => {
35
- const el = await fixture(html `<ix-grid></ix-grid>`);
36
- expect(el).to.not.be.null;
37
- });
38
- it('renders the correct number of rows', async () => {
1
+ import { html } from 'lit';
2
+ import { fixture, expect } from '@open-wc/testing';
3
+ import '../ix-grid-no-rows.js';
4
+ import '../ix-grid.js';
5
+ const rows = [
6
+ {
7
+ name: 'one',
8
+ },
9
+ {
10
+ name: 'two',
11
+ },
12
+ {
13
+ name: 'three',
14
+ },
15
+ ];
16
+ const columns = [
17
+ {
18
+ name: 'one',
19
+ header: 'one',
20
+ bodyRenderer: row => html ` <span>${row.name}</span>`,
21
+ },
22
+ {
23
+ name: 'two',
24
+ header: 'one',
25
+ bodyRenderer: row => html ` <span>${row.name}</span>`,
26
+ },
27
+ {
28
+ name: 'three',
29
+ header: 'one',
30
+ bodyRenderer: row => html ` <span>${row.name}</span>`,
31
+ },
32
+ ];
33
+ describe('IxGrid', () => {
34
+ it('renders a grid', async () => {
35
+ const el = await fixture(html `<ix-grid></ix-grid>`);
36
+ expect(el).to.not.be.null;
37
+ });
38
+ it('renders the correct number of rows', async () => {
39
39
  const el = await fixture(html `<ix-grid
40
40
  .columns=${columns}
41
41
  .rows=${rows}
42
- ></ix-grid>`);
43
- expect(rows.length).to.equal(3);
44
- expect(el).to.not.be.null;
45
- });
46
- it('renders no rows component state', async () => {
47
- var _a;
42
+ ></ix-grid>`);
43
+ expect(rows.length).to.equal(3);
44
+ expect(el).to.not.be.null;
45
+ });
46
+ it('renders no rows component state', async () => {
47
+ var _a;
48
48
  const el = await fixture(html `<ix-grid
49
49
  .columns=${columns}
50
50
  .rows=${[]}
51
51
  ><ix-grid-no-rows slot="no-rows"></ix-grid-no-rows
52
- ></ix-grid>`);
53
- const noRows = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('slot[name="no-rows"]');
54
- expect(noRows).to.not.be.null;
55
- });
56
- });
52
+ ></ix-grid>`);
53
+ const noRows = (_a = el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector('slot[name="no-rows"]');
54
+ expect(noRows).to.not.be.null;
55
+ });
56
+ });
57
57
  //# sourceMappingURL=ix-grid.test.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ix-grid.test.js","sourceRoot":"","sources":["../../src/test/ix-grid.test.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,KAAK,CAAC;AAC3B,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAEnD,OAAO,kCAAkC,CAAC;AAC1C,OAAO,eAAe,CAAC;AAEvB,MAAM,I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AAE,KAAK,IAAI,EAAE;;QAC/C,MAAM,EAAE,GAAG,MAAM,OAAO,CAAS,IAAI,CAAA;iBACxB,OAAO;cACV,EAAE;;gBAEA,CAAC,CAAC;QAEd,MAAM,MAAM,GAAG,MAAA,EAAE,CAAC,UAAU,0CAAE,aAAa,CAAC,sBAAsB,CAAC,CAAC;QACpE,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC;IAChC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { html } from 'lit';\nimport { fixture, expect } from '@open-wc/testing';\nimport { IxGrid } from '../IxGrid.js';\nimport '../components/ix-grid-no-rows.js';\nimport '../ix-grid.js';\n\nconst rows = [\n {\n name: 'one',\n },\n {\n name: 'two',\n },\n {\n name: 'three',\n },\n];\n\nconst columns = [\n {\n name: 'one',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n {\n name: 'two',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n {\n name: 'three',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n];\n\ndescribe('IxGrid', () => {\n it('renders a grid', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid></ix-grid>`);\n\n expect(el).to.not.be.null;\n });\n\n it('renders the correct number of rows', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid\n .columns=${columns}\n .rows=${rows}\n ></ix-grid>`);\n\n expect(rows.length).to.equal(3);\n\n expect(el).to.not.be.null;\n });\n\n it('renders no rows component state', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid\n .columns=${columns}\n .rows=${[]}\n ><ix-grid-no-rows slot=\"no-rows\"></ix-grid-no-rows\n ></ix-grid>`);\n\n const noRows = el.shadowRoot?.querySelector('slot[name=\"no-rows\"]');\n expect(noRows).to.not.be.null;\n });\n});\n"]}
1
+ {"version":3,"file":"ix-grid.test.js","sourceRoot":"","sources":["../../src/test/ix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CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;QAEhC,MAAM,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC;IAC5B,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iCAAiC,EAAE,KAAK,IAAI,EAAE;;QAC/C,MAAM,EAAE,GAAG,MAAM,OAAO,CAAS,IAAI,CAAA;iBACxB,OAAO;cACV,EAAE;;gBAEA,CAAC,CAAC;QAEd,MAAM,MAAM,GAAG,MAAA,EAAE,CAAC,UAAU,0CAAE,aAAa,CAAC,sBAAsB,CAAC,CAAC;QACpE,MAAM,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC;IAChC,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { html } from 'lit';\nimport { fixture, expect } from '@open-wc/testing';\nimport { IxGrid } from '../IxGrid.js';\nimport '../ix-grid-no-rows.js';\nimport '../ix-grid.js';\n\nconst rows = [\n {\n name: 'one',\n },\n {\n name: 'two',\n },\n {\n name: 'three',\n },\n];\n\nconst columns = [\n {\n name: 'one',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n {\n name: 'two',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n {\n name: 'three',\n header: 'one',\n bodyRenderer: row => html` <span>${row.name}</span>`,\n },\n];\n\ndescribe('IxGrid', () => {\n it('renders a grid', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid></ix-grid>`);\n\n expect(el).to.not.be.null;\n });\n\n it('renders the correct number of rows', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid\n .columns=${columns}\n .rows=${rows}\n ></ix-grid>`);\n\n expect(rows.length).to.equal(3);\n\n expect(el).to.not.be.null;\n });\n\n it('renders no rows component state', async () => {\n const el = await fixture<IxGrid>(html`<ix-grid\n .columns=${columns}\n .rows=${[]}\n ><ix-grid-no-rows slot=\"no-rows\"></ix-grid-no-rows\n ></ix-grid>`);\n\n const noRows = el.shadowRoot?.querySelector('slot[name=\"no-rows\"]');\n expect(noRows).to.not.be.null;\n });\n});\n"]}
@@ -1 +1 @@
1
- import '../components/IxPagination.js';
1
+ import '../components/IxPagination.js';
@@ -1,28 +1,28 @@
1
- import { html } from 'lit';
2
- import { fixture, expect } from '@open-wc/testing';
3
- import '../components/IxPagination.js';
4
- describe('IxPagination', () => {
5
- it('renders pagination', async () => {
6
- const el = await fixture(html `<ix-pagination></ix-pagination>`);
7
- expect(el).to.not.be.null;
8
- });
9
- it('renders pagination page size select', async () => {
10
- var _a;
1
+ import { html } from 'lit';
2
+ import { fixture, expect } from '@open-wc/testing';
3
+ import '../components/IxPagination.js';
4
+ describe('IxPagination', () => {
5
+ it('renders pagination', async () => {
6
+ const el = await fixture(html `<ix-pagination></ix-pagination>`);
7
+ expect(el).to.not.be.null;
8
+ });
9
+ it('renders pagination page size select', async () => {
10
+ var _a;
11
11
  const el = await fixture(html `<ix-pagination
12
12
  .pageSizes=${[1, 2, 3]}
13
- ></ix-pagination>`);
14
- const pageSizeSelect = (_a = el === null || el === void 0 ? void 0 : el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll('ix-select-option');
15
- expect(pageSizeSelect === null || pageSizeSelect === void 0 ? void 0 : pageSizeSelect.length).to.equal(3);
16
- });
17
- it('renders pagination range info', async () => {
18
- var _a;
13
+ ></ix-pagination>`);
14
+ const pageSizeSelect = (_a = el === null || el === void 0 ? void 0 : el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll('ix-select-option');
15
+ expect(pageSizeSelect === null || pageSizeSelect === void 0 ? void 0 : pageSizeSelect.length).to.equal(3);
16
+ });
17
+ it('renders pagination range info', async () => {
18
+ var _a;
19
19
  const el = await fixture(html `<ix-pagination
20
20
  pageSize="10"
21
21
  page="2"
22
22
  recordCount="99"
23
- ></ix-pagination>`);
24
- const pageRangeInfo = (_a = el === null || el === void 0 ? void 0 : el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll('p')[1];
25
- expect(pageRangeInfo === null || pageRangeInfo === void 0 ? void 0 : pageRangeInfo.innerText).to.equal('11 - 20 of 99');
26
- });
27
- });
23
+ ></ix-pagination>`);
24
+ const pageRangeInfo = (_a = el === null || el === void 0 ? void 0 : el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll('p')[1];
25
+ expect(pageRangeInfo === null || pageRangeInfo === void 0 ? void 0 : pageRangeInfo.innerText).to.equal('11 - 20 of 99');
26
+ });
27
+ });
28
28
  //# sourceMappingURL=ix-pagination.test.js.map
package/package.json CHANGED
@@ -3,17 +3,17 @@
3
3
  "description": "Webcomponent ix-grid following open-wc recommendations",
4
4
  "license": "MIT",
5
5
  "author": "Digital Realty",
6
- "version": "1.0.49-alpha.1",
6
+ "version": "1.0.49-alpha.2",
7
7
  "type": "module",
8
8
  "main": "dist/index.js",
9
9
  "module": "dist/index.js",
10
10
  "exports": {
11
11
  ".": "./dist/index.js",
12
12
  "./ix-grid.js": "./dist/ix-grid.js",
13
- "./ix-grid-nav.js": "./dist/components/ix-grid-nav.js",
13
+ "./ix-grid-nav.js": "./dist/ix-grid-nav.js",
14
14
  "./ix-grid.min.js": "./dist/ix-grid.min.js",
15
- "./ix-grid-no-rows.js": "./dist/components/ix-grid-no-rows.js",
16
- "./IxGridNav": "./dist/react/IxGridNav.js"
15
+ "./ix-grid-no-rows.js": "./dist/ix-grid-no-rows.js",
16
+ "./IxGridNav": "./dist/IxGridNav.js"
17
17
  },
18
18
  "publishConfig": {
19
19
  "access": "public"
@@ -29,12 +29,12 @@
29
29
  "test:watch": "tsc && concurrently -k -r \"tsc --watch --preserveWatchOutput\" \"wtr --watch\""
30
30
  },
31
31
  "dependencies": {
32
- "@digital-realty/ix-button": "^3.2.32-alpha.1",
33
- "@digital-realty/ix-icon": "^1.0.37-alpha.1",
34
- "@digital-realty/ix-icon-button": "^1.0.41-alpha.1",
35
- "@digital-realty/ix-menu": "^1.0.5-alpha.1",
36
- "@digital-realty/ix-select": "^1.0.39-alpha.1",
37
- "@digital-realty/ix-switch": "^2.1.12-alpha.1",
32
+ "@digital-realty/ix-button": "^3.2.32-alpha.0",
33
+ "@digital-realty/ix-icon": "^1.0.37-alpha.0",
34
+ "@digital-realty/ix-icon-button": "^1.0.41-alpha.0",
35
+ "@digital-realty/ix-menu": "^1.0.5-alpha.0",
36
+ "@digital-realty/ix-select": "^1.0.39-alpha.0",
37
+ "@digital-realty/ix-switch": "^2.1.12-alpha.0",
38
38
  "@lit/react": "^1.0.5",
39
39
  "@vaadin/grid": "^24.3.11",
40
40
  "lit": "^2.0.2",
@@ -103,5 +103,5 @@
103
103
  "prettier --write"
104
104
  ]
105
105
  },
106
- "gitHead": "22ec023bfc49506327d74412840e42412735bb09"
106
+ "gitHead": "60da388c5cabac1ab856f981c965c44ed46d27a0"
107
107
  }
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { createComponent } from '@lit/react';
3
- import { IxGridNavigation } from '../components/IxGridNav.js';
3
+ import { IxGridNavigation } from './components/IxGridNav.js';
4
4
 
5
5
  export const IxGridNav = createComponent({
6
6
  tagName: 'ix-grid-nav',
@@ -6,23 +6,24 @@ export class IxGridNoRows extends LitElement {
6
6
  static styles = css`
7
7
  .container {
8
8
  display: flex;
9
- align-items: center;
10
9
  justify-content: center;
11
- padding: 1rem;
10
+ align-items: center;
12
11
  flex-direction: column;
12
+ text-align: center;
13
+ padding: 3.125rem 0;
13
14
  }
14
15
  .icon {
15
- margin: 4rem 0 0;
16
- width: var(--no-rows-icon-size, 48px);
17
- height: var(--no-rows-icon-size, 48px);
18
- --ix-icon-font-size: var(--no-rows-icon-size, 48px);
19
- --ix-icon-line-height: var(--no-rows-icon-line-height, 1);
16
+ user-select: none;
17
+ display: inline-block;
18
+ fill: currentcolor;
19
+ flex-shrink: 0;
20
+ font-size: 1.5rem;
21
+ color: rgb(255, 152, 0);
22
+ transition: fill 200ms cubic-bezier(0.4, 0, 0.2, 1);
20
23
  }
21
24
  .warning,
22
25
  .error {
23
26
  user-select: none;
24
- width: 48px;
25
- height: 44px;
26
27
  color: var(--clr-warning, #ff9800);
27
28
  }
28
29
  .critical {
@@ -32,7 +33,15 @@ export class IxGridNoRows extends LitElement {
32
33
  font-family: var(--ix-font-family, 'Red Hat Display');
33
34
  }
34
35
  h2.dlr-text-heading {
35
- margin-top: 10px;
36
+ margin: 0.5rem 0 0;
37
+ font-family: 'Red Hat Display', sans-serif;
38
+ font-style: normal;
39
+ font-size: 1.5rem;
40
+ line-height: 2rem;
41
+ letter-spacing: 0em;
42
+ color: rgb(9, 34, 65);
43
+ text-align: center;
44
+ font-weight: 700;
36
45
  }
37
46
  `;
38
47
 
@@ -42,9 +51,11 @@ export class IxGridNoRows extends LitElement {
42
51
 
43
52
  @property({ type: String }) message: string = 'No data to display';
44
53
 
54
+ @property({ type: String }) iconFontSize: string = '3rem';
55
+
45
56
  render() {
46
57
  return html`
47
- <div class="container">
58
+ <div class="container" style="--ix-icon-font-size: ${this.iconFontSize};">
48
59
  <ix-icon class="icon ${this.type}">${this.icon}</ix-icon>
49
60
  <h2 class="dlr-text-heading">${this.message}</h2>
50
61
  </div>
@@ -257,7 +257,7 @@ export const IxGridRowFilterStyles = css`
257
257
  position: absolute;
258
258
  top: 6px;
259
259
  left: 14px;
260
- z-index: 98;
260
+ z-index: 1;
261
261
  display: flex;
262
262
  align-items: center;
263
263
  justify-content: center;
@@ -1,3 +1,3 @@
1
- import { IxGridNavigation } from './IxGridNav.js';
1
+ import { IxGridNavigation } from './components/IxGridNav.js';
2
2
 
3
3
  window.customElements.define('ix-grid-nav', IxGridNavigation);
@@ -0,0 +1,3 @@
1
+ import { IxGridNoRows } from './components/IxGridNoRows.js';
2
+
3
+ window.customElements.define('ix-grid-no-rows', IxGridNoRows);
@@ -1,7 +1,7 @@
1
1
  import { html } from 'lit';
2
2
  import { fixture, expect } from '@open-wc/testing';
3
3
  import { IxGrid } from '../IxGrid.js';
4
- import '../components/ix-grid-no-rows.js';
4
+ import '../ix-grid-no-rows.js';
5
5
  import '../ix-grid.js';
6
6
 
7
7
  const rows = [