@aquera/nile-elements 1.1.3-beta-1.4 → 1.1.3-beta-2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/demo/index.html +124 -24
- package/dist/index.js +728 -770
- package/dist/nile-grid/nile-grid.cjs.js +1 -1
- package/dist/nile-grid/nile-grid.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid.css.cjs.js +1 -1
- package/dist/nile-grid/nile-grid.css.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid.css.esm.js +4 -8
- package/dist/nile-grid/nile-grid.esm.js +6 -6
- package/dist/nile-grid/nile-grid.utils.cjs.js +1 -1
- package/dist/nile-grid/nile-grid.utils.cjs.js.map +1 -1
- package/dist/nile-grid/nile-grid.utils.esm.js +1 -1
- package/dist/nile-grid-body/nile-grid-body.cjs.js +1 -1
- package/dist/nile-grid-body/nile-grid-body.cjs.js.map +1 -1
- package/dist/nile-grid-body/nile-grid-body.css.cjs.js +1 -1
- package/dist/nile-grid-body/nile-grid-body.css.cjs.js.map +1 -1
- package/dist/nile-grid-body/nile-grid-body.css.esm.js +4 -0
- package/dist/nile-grid-body/nile-grid-body.esm.js +3 -3
- package/dist/nile-grid-cell-item/nile-grid-cell-item.cjs.js +1 -1
- package/dist/nile-grid-cell-item/nile-grid-cell-item.cjs.js.map +1 -1
- package/dist/nile-grid-cell-item/nile-grid-cell-item.css.cjs.js +1 -1
- package/dist/nile-grid-cell-item/nile-grid-cell-item.css.cjs.js.map +1 -1
- package/dist/nile-grid-cell-item/nile-grid-cell-item.css.esm.js +3 -18
- package/dist/nile-grid-cell-item/nile-grid-cell-item.esm.js +3 -3
- package/dist/nile-grid-head/nile-grid-head.cjs.js +1 -1
- package/dist/nile-grid-head/nile-grid-head.cjs.js.map +1 -1
- package/dist/nile-grid-head/nile-grid-head.css.cjs.js +1 -1
- package/dist/nile-grid-head/nile-grid-head.css.cjs.js.map +1 -1
- package/dist/nile-grid-head/nile-grid-head.css.esm.js +1 -1
- package/dist/nile-grid-head/nile-grid-head.esm.js +3 -3
- package/dist/nile-grid-head-item/nile-grid-head-item.cjs.js +1 -1
- package/dist/nile-grid-head-item/nile-grid-head-item.cjs.js.map +1 -1
- package/dist/nile-grid-head-item/nile-grid-head-item.css.cjs.js +1 -1
- package/dist/nile-grid-head-item/nile-grid-head-item.css.cjs.js.map +1 -1
- package/dist/nile-grid-head-item/nile-grid-head-item.css.esm.js +5 -20
- package/dist/nile-grid-head-item/nile-grid-head-item.esm.js +3 -4
- package/dist/nile-grid-row/nile-grid-row.cjs.js +1 -1
- package/dist/nile-grid-row/nile-grid-row.cjs.js.map +1 -1
- package/dist/nile-grid-row/nile-grid-row.css.cjs.js +1 -1
- package/dist/nile-grid-row/nile-grid-row.css.cjs.js.map +1 -1
- package/dist/nile-grid-row/nile-grid-row.css.esm.js +5 -17
- package/dist/nile-grid-row/nile-grid-row.esm.js +5 -4
- package/dist/nile-virtual-select/nile-virtual-select.cjs.js +2 -2
- package/dist/nile-virtual-select/nile-virtual-select.cjs.js.map +1 -1
- package/dist/nile-virtual-select/nile-virtual-select.esm.js +7 -6
- package/dist/src/nile-grid/nile-grid.css.js +2 -6
- package/dist/src/nile-grid/nile-grid.css.js.map +1 -1
- package/dist/src/nile-grid/nile-grid.d.ts +3 -9
- package/dist/src/nile-grid/nile-grid.js +20 -96
- package/dist/src/nile-grid/nile-grid.js.map +1 -1
- package/dist/src/nile-grid/nile-grid.utils.d.ts +2 -3
- package/dist/src/nile-grid/nile-grid.utils.js +81 -223
- package/dist/src/nile-grid/nile-grid.utils.js.map +1 -1
- package/dist/src/nile-grid-body/nile-grid-body.css.js +4 -0
- package/dist/src/nile-grid-body/nile-grid-body.css.js.map +1 -1
- package/dist/src/nile-grid-body/nile-grid-body.js +1 -1
- package/dist/src/nile-grid-body/nile-grid-body.js.map +1 -1
- package/dist/src/nile-grid-cell-item/nile-grid-cell-item.css.js +2 -17
- package/dist/src/nile-grid-cell-item/nile-grid-cell-item.css.js.map +1 -1
- package/dist/src/nile-grid-cell-item/nile-grid-cell-item.d.ts +3 -0
- package/dist/src/nile-grid-cell-item/nile-grid-cell-item.js +11 -1
- package/dist/src/nile-grid-cell-item/nile-grid-cell-item.js.map +1 -1
- package/dist/src/nile-grid-head/nile-grid-head.css.js +1 -1
- package/dist/src/nile-grid-head/nile-grid-head.css.js.map +1 -1
- package/dist/src/nile-grid-head/nile-grid-head.js +1 -1
- package/dist/src/nile-grid-head/nile-grid-head.js.map +1 -1
- package/dist/src/nile-grid-head-item/nile-grid-head-item.css.js +3 -18
- package/dist/src/nile-grid-head-item/nile-grid-head-item.css.js.map +1 -1
- package/dist/src/nile-grid-head-item/nile-grid-head-item.d.ts +2 -3
- package/dist/src/nile-grid-head-item/nile-grid-head-item.js +11 -14
- package/dist/src/nile-grid-head-item/nile-grid-head-item.js.map +1 -1
- package/dist/src/nile-grid-row/nile-grid-row.css.js +5 -17
- package/dist/src/nile-grid-row/nile-grid-row.css.js.map +1 -1
- package/dist/src/nile-grid-row/nile-grid-row.d.ts +1 -4
- package/dist/src/nile-grid-row/nile-grid-row.js +4 -19
- package/dist/src/nile-grid-row/nile-grid-row.js.map +1 -1
- package/dist/src/nile-virtual-select/nile-virtual-select.d.ts +18 -0
- package/dist/src/nile-virtual-select/nile-virtual-select.js +230 -3
- package/dist/src/nile-virtual-select/nile-virtual-select.js.map +1 -1
- package/dist/src/version.js +1 -1
- package/dist/src/version.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/nile-grid/nile-grid.css.ts +2 -6
- package/src/nile-grid/nile-grid.ts +21 -124
- package/src/nile-grid/nile-grid.utils.ts +98 -353
- package/src/nile-grid-body/nile-grid-body.css.ts +4 -0
- package/src/nile-grid-body/nile-grid-body.ts +2 -2
- package/src/nile-grid-cell-item/nile-grid-cell-item.css.ts +2 -17
- package/src/nile-grid-cell-item/nile-grid-cell-item.ts +11 -3
- package/src/nile-grid-head/nile-grid-head.css.ts +1 -1
- package/src/nile-grid-head/nile-grid-head.ts +2 -2
- package/src/nile-grid-head-item/nile-grid-head-item.css.ts +3 -18
- package/src/nile-grid-head-item/nile-grid-head-item.ts +16 -8
- package/src/nile-grid-row/nile-grid-row.css.ts +5 -17
- package/src/nile-grid-row/nile-grid-row.ts +6 -9
- package/src/nile-virtual-select/nile-virtual-select.ts +257 -3
- package/vscode-html-custom-data.json +69 -37
- package/src/nile-grid/nile-grid.types.ts +0 -1
|
@@ -20,7 +20,10 @@ export declare class NileGridCellItem extends NileElement {
|
|
|
20
20
|
static get styles(): CSSResultArray;
|
|
21
21
|
colspan: number;
|
|
22
22
|
rowspan: number;
|
|
23
|
+
align?: 'start' | 'center' | 'end';
|
|
24
|
+
valign?: 'top' | 'middle' | 'bottom';
|
|
23
25
|
resizable: boolean;
|
|
26
|
+
textOverflowType: 'ellipsis' | 'clip';
|
|
24
27
|
connectedCallback(): void;
|
|
25
28
|
private onHandlePointerDown;
|
|
26
29
|
render(): TemplateResult;
|
|
@@ -22,6 +22,7 @@ let NileGridCellItem = class NileGridCellItem extends NileElement {
|
|
|
22
22
|
this.colspan = 1;
|
|
23
23
|
this.rowspan = 1;
|
|
24
24
|
this.resizable = false;
|
|
25
|
+
this.textOverflowType = 'ellipsis';
|
|
25
26
|
this.onHandlePointerDown = (ev) => {
|
|
26
27
|
const el = this;
|
|
27
28
|
const downXRef = { value: 0 };
|
|
@@ -51,7 +52,7 @@ let NileGridCellItem = class NileGridCellItem extends NileElement {
|
|
|
51
52
|
}
|
|
52
53
|
render() {
|
|
53
54
|
return html `
|
|
54
|
-
<div
|
|
55
|
+
<div style="display: contents;">
|
|
55
56
|
<slot></slot>
|
|
56
57
|
${this.resizable
|
|
57
58
|
? html `
|
|
@@ -72,9 +73,18 @@ __decorate([
|
|
|
72
73
|
__decorate([
|
|
73
74
|
property({ type: Number, reflect: true, attribute: true })
|
|
74
75
|
], NileGridCellItem.prototype, "rowspan", void 0);
|
|
76
|
+
__decorate([
|
|
77
|
+
property({ type: String, reflect: true, attribute: true })
|
|
78
|
+
], NileGridCellItem.prototype, "align", void 0);
|
|
79
|
+
__decorate([
|
|
80
|
+
property({ type: String, reflect: true, attribute: true })
|
|
81
|
+
], NileGridCellItem.prototype, "valign", void 0);
|
|
75
82
|
__decorate([
|
|
76
83
|
property({ type: Boolean, reflect: true, attribute: true })
|
|
77
84
|
], NileGridCellItem.prototype, "resizable", void 0);
|
|
85
|
+
__decorate([
|
|
86
|
+
property({ type: Boolean, reflect: true, attribute: true })
|
|
87
|
+
], NileGridCellItem.prototype, "textOverflowType", void 0);
|
|
78
88
|
NileGridCellItem = __decorate([
|
|
79
89
|
customElement('nile-grid-cell-item')
|
|
80
90
|
], NileGridCellItem);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-cell-item.js","sourceRoot":"","sources":["../../../src/nile-grid-cell-item/nile-grid-cell-item.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"nile-grid-cell-item.js","sourceRoot":"","sources":["../../../src/nile-grid-cell-item/nile-grid-cell-item.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,EAAc,IAAI,EAAkC,MAAM,KAAK,CAAC;AACvE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AACnD,OAAO,WAAW,MAAM,0BAA0B,CAAC;AACnD,OAAO,EACL,cAAc,EACd,cAAc,EACd,cAAc,GACf,MAAM,6BAA6B,CAAC;AAErC;;;;;GAKG;AAEI,IAAM,gBAAgB,GAAtB,MAAM,gBAAiB,SAAQ,WAAW;IAA1C;;QASuD,YAAO,GAAG,CAAC,CAAC;QACZ,YAAO,GAAG,CAAC,CAAC;QASX,cAAS,GAAG,KAAK,CAAC;QAClB,qBAAgB,GAAwB,UAAU,CAAC;QAOxG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I,CAAC,SAAS;YACd,CAAC,CAAC,IAAI,CAAA;;;;+BAIe,IAAI,CAAC,mBAAmB;;aAE1C;YACH,CAAC,CAAC,IAAI;;KAEX,CAAC;IACJ,CAAC;CAGF,CAAA;AAxD6D;IAA3D,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;iDAAa;AACZ;IAA3D,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;iDAAa;AACZ;IAA3D,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;+CAGjD;AACkD;IAA3D,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;gDAG9C;AACgD;IAA5D,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;mDAAmB;AAClB;IAA5D,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;0DAAoD;AApBrG,gBAAgB;IAD5B,aAAa,CAAC,qBAAqB,CAAC;GACxB,gBAAgB,CAiE5B;;AAED,eAAe,gBAAgB,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { LitElement, html, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { styles } from './nile-grid-cell-item.css';\nimport NileElement from '../internal/nile-element';\nimport {\n initCellResize,\n cellResizeMove,\n cellResizeDone,\n} from './nile-grid-cell-item.utils';\n\n/**\n * Nile grid-cell component.\n *\n * @tag nile-grid-cell-item\n *\n */\n@customElement('nile-grid-cell-item')\nexport class NileGridCellItem extends NileElement {\n /**\n * The styles for nile-grid-cell-item\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property({ type: Number, reflect: true, attribute: true }) colspan = 1;\n @property({ type: Number, reflect: true, attribute: true }) rowspan = 1;\n @property({ type: String, reflect: true, attribute: true }) align?:\n | 'start'\n | 'center'\n | 'end';\n @property({ type: String, reflect: true, attribute: true }) valign?:\n | 'top'\n | 'middle'\n | 'bottom';\n @property({ type: Boolean, reflect: true, attribute: true }) resizable = false;\n @property({ type: Boolean, reflect: true, attribute: true }) textOverflowType: 'ellipsis' | 'clip' = 'ellipsis';\n\n connectedCallback() {\n super.connectedCallback();\n this.setAttribute('role', 'cell');\n }\n\n private onHandlePointerDown = (ev: PointerEvent) => {\n const el = this as HTMLElement;\n\n const downXRef = { value: 0 };\n const startWRef = { value: 0 };\n\n const result = initCellResize(el, ev, downXRef, startWRef);\n if (!result) return;\n\n const { target, col } = result;\n\n const move = (e: PointerEvent) =>\n cellResizeMove(el, col, startWRef.value, downXRef.value, e);\n const done = () => cellResizeDone(el, ev, target, move);\n\n target.addEventListener('pointermove', move);\n target.addEventListener('pointerup', done, { once: true });\n target.addEventListener('pointercancel', done, { once: true });\n };\n\n public render(): TemplateResult {\n return html`\n <div style=\"display: contents;\">\n <slot></slot>\n ${this.resizable\n ? html`\n <div\n aria-hidden=\"true\"\n class=\"resize-handle\"\n @pointerdown=${this.onHandlePointerDown}\n ></div>\n `\n : null}\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileGridCellItem;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-grid-cell-item': NileGridCellItem;\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-head.css.js","sourceRoot":"","sources":["../../../src/nile-grid-head/nile-grid-head.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;CAMxB,CAAC;AAEF,eAAe,CAAC,MAAM,CAAC,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit';\n\n/**\n * GridHead CSS\n */\nexport const styles = css`\n :host([sticky]) {\n position: sticky;\n z-index:
|
|
1
|
+
{"version":3,"file":"nile-grid-head.css.js","sourceRoot":"","sources":["../../../src/nile-grid-head/nile-grid-head.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;CAMxB,CAAC;AAEF,eAAe,CAAC,MAAM,CAAC,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit';\n\n/**\n * GridHead CSS\n */\nexport const styles = css`\n :host([sticky]) {\n position: sticky;\n z-index: 2;\n top: 0;\n }\n`;\n\nexport default [styles];\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-head.js","sourceRoot":"","sources":["../../../src/nile-grid-head/nile-grid-head.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"nile-grid-head.js","sourceRoot":"","sources":["../../../src/nile-grid-head/nile-grid-head.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,EAAc,IAAI,EAAkC,MAAM,KAAK,CAAC;AACvE,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,WAAW,MAAM,0BAA0B,CAAC;AAEnD;;;;;GAKG;AAEI,IAAM,YAAY,GAAlB,MAAM,YAAa,SAAQ,WAAW;IAC3C;;;OAGG;IACI,MAAM,KAAK,MAAM;QACtB,OAAO,CAAC,MAAM,CAAC,CAAC;IAClB,CAAC;IAED,gBAAgB;IAEhB,qBAAqB;IAEd,MAAM;QACX,OAAO,IAAI,CAAA;;;;KAIV,CAAC;IACJ,CAAC;CAGF,CAAA;AAtBY,YAAY;IADxB,aAAa,CAAC,gBAAgB,CAAC;GACnB,YAAY,CAsBxB;;AAED,eAAe,YAAY,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { LitElement, html, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement } from 'lit/decorators.js';\nimport { styles } from './nile-grid-head.css';\nimport NileElement from '../internal/nile-element';\n\n/**\n * Nile grid-head component.\n *\n * @tag nile-grid-head\n *\n */\n@customElement('nile-grid-head')\nexport class NileGridHead extends NileElement {\n /**\n * The styles for nile-grid-head\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n /* #endregion */\n\n /* #region Methods */\n\n public render(): TemplateResult {\n return html`\n <div style=\"display: contents;\">\n <slot></slot>\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileGridHead;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-grid-head': NileGridHead;\n }\n}\n"]}
|
|
@@ -10,8 +10,7 @@ import { css } from 'lit';
|
|
|
10
10
|
*/
|
|
11
11
|
export const styles = css `
|
|
12
12
|
:host {
|
|
13
|
-
--padding: var(--nile-spacing-
|
|
14
|
-
--height: 50px;
|
|
13
|
+
--padding: var(--nile-spacing-xl) var(--nile-spacing-3xl);
|
|
15
14
|
position: relative;
|
|
16
15
|
box-sizing: border-box;
|
|
17
16
|
user-select: none;
|
|
@@ -22,16 +21,7 @@ export const styles = css `
|
|
|
22
21
|
padding: var(--padding);
|
|
23
22
|
background-color: var(--nile-colors-neutral-100);
|
|
24
23
|
border-bottom: 1px solid var(--nile-colors-neutral-400);
|
|
25
|
-
|
|
26
|
-
font-weight: 500;
|
|
27
|
-
font-family: var(--nile-font-weight-medium);
|
|
28
|
-
min-height: var(--height);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.head-item-base {
|
|
32
|
-
width: 100%;
|
|
33
|
-
overflow: hidden;
|
|
34
|
-
text-overflow: ellipsis;
|
|
24
|
+
border-right: 1px solid var(--nile-colors-neutral-400);
|
|
35
25
|
}
|
|
36
26
|
|
|
37
27
|
::slotted(*) {
|
|
@@ -40,17 +30,12 @@ export const styles = css `
|
|
|
40
30
|
white-space: nowrap;
|
|
41
31
|
}
|
|
42
32
|
|
|
43
|
-
:host(:last-child) .resize-handle {
|
|
44
|
-
border-right: none;
|
|
45
|
-
display: none;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
33
|
.resize-handle {
|
|
49
34
|
position: absolute;
|
|
50
35
|
top: 0;
|
|
51
36
|
right: 0;
|
|
52
37
|
height: 100%;
|
|
53
|
-
cursor:
|
|
38
|
+
cursor: col-resize;
|
|
54
39
|
touch-action: none;
|
|
55
40
|
z-index: 1;
|
|
56
41
|
width: 2px;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-head-item.css.js","sourceRoot":"","sources":["../../../src/nile-grid-head-item/nile-grid-head-item.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"nile-grid-head-item.css.js","sourceRoot":"","sources":["../../../src/nile-grid-head-item/nile-grid-head-item.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiCxB,CAAC;AAEF,eAAe,CAAC,MAAM,CAAC,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit';\n\n/**\n * NileGridHeadItem CSS\n */\nexport const styles = css`\n :host {\n --padding: var(--nile-spacing-xl) var(--nile-spacing-3xl);\n position: relative;\n box-sizing: border-box;\n user-select: none;\n white-space: nowrap;\n width: 100%;\n overflow: hidden;\n text-overflow: ellipsis;\n padding: var(--padding);\n background-color: var(--nile-colors-neutral-100);\n border-bottom: 1px solid var(--nile-colors-neutral-400);\n border-right: 1px solid var(--nile-colors-neutral-400);\n }\n\n ::slotted(*) {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .resize-handle {\n position: absolute;\n top: 0;\n right: 0;\n height: 100%;\n cursor: col-resize;\n touch-action: none;\n z-index: 1;\n width: 2px;\n border-right: 1px solid var(--nile-colors-neutral-400);\n }\n`;\n\nexport default [styles];\n"]}
|
|
@@ -20,10 +20,9 @@ export declare class NileGridHeadItem extends NileElement {
|
|
|
20
20
|
static get styles(): CSSResultArray;
|
|
21
21
|
colspan: number;
|
|
22
22
|
rowspan: number;
|
|
23
|
+
scope: 'col' | 'row';
|
|
23
24
|
resizable: boolean;
|
|
24
|
-
|
|
25
|
-
lastColSticky: boolean;
|
|
26
|
-
customWidth: number | null;
|
|
25
|
+
sticky: boolean;
|
|
27
26
|
connectedCallback(): void;
|
|
28
27
|
private onHandlePointerDown;
|
|
29
28
|
protected updated(changed: Map<string, unknown>): void;
|
|
@@ -21,10 +21,9 @@ let NileGridHeadItem = class NileGridHeadItem extends NileElement {
|
|
|
21
21
|
super(...arguments);
|
|
22
22
|
this.colspan = 1;
|
|
23
23
|
this.rowspan = 1;
|
|
24
|
+
this.scope = 'col';
|
|
24
25
|
this.resizable = false;
|
|
25
|
-
this.
|
|
26
|
-
this.lastColSticky = false;
|
|
27
|
-
this.customWidth = null;
|
|
26
|
+
this.sticky = false;
|
|
28
27
|
this.onHandlePointerDown = (ev) => {
|
|
29
28
|
const el = this;
|
|
30
29
|
const downXRef = { value: 0 };
|
|
@@ -50,10 +49,12 @@ let NileGridHeadItem = class NileGridHeadItem extends NileElement {
|
|
|
50
49
|
}
|
|
51
50
|
connectedCallback() {
|
|
52
51
|
super.connectedCallback();
|
|
53
|
-
this.setAttribute('role', 'row');
|
|
52
|
+
this.setAttribute('role', this.scope === 'row' ? 'rowheader' : 'columnheader');
|
|
54
53
|
}
|
|
55
54
|
updated(changed) {
|
|
56
|
-
|
|
55
|
+
if (changed.has('scope')) {
|
|
56
|
+
this.setAttribute('role', this.scope === 'row' ? 'rowheader' : 'columnheader');
|
|
57
|
+
}
|
|
57
58
|
}
|
|
58
59
|
disconnectedCallback() {
|
|
59
60
|
super.disconnectedCallback();
|
|
@@ -61,14 +62,13 @@ let NileGridHeadItem = class NileGridHeadItem extends NileElement {
|
|
|
61
62
|
}
|
|
62
63
|
render() {
|
|
63
64
|
return html `
|
|
64
|
-
<div
|
|
65
|
+
<div style="display: contents;">
|
|
65
66
|
<slot></slot>
|
|
66
67
|
${this.resizable
|
|
67
68
|
? html `
|
|
68
69
|
<div
|
|
69
70
|
aria-hidden="false"
|
|
70
71
|
class="resize-handle"
|
|
71
|
-
part="resize-handle"
|
|
72
72
|
@pointerdown=${this.onHandlePointerDown}
|
|
73
73
|
></div>
|
|
74
74
|
`
|
|
@@ -84,17 +84,14 @@ __decorate([
|
|
|
84
84
|
property({ type: Number, reflect: true, attribute: true })
|
|
85
85
|
], NileGridHeadItem.prototype, "rowspan", void 0);
|
|
86
86
|
__decorate([
|
|
87
|
-
property({ type:
|
|
88
|
-
], NileGridHeadItem.prototype, "
|
|
87
|
+
property({ type: String, reflect: true, attribute: true })
|
|
88
|
+
], NileGridHeadItem.prototype, "scope", void 0);
|
|
89
89
|
__decorate([
|
|
90
90
|
property({ type: Boolean, reflect: true, attribute: true })
|
|
91
|
-
], NileGridHeadItem.prototype, "
|
|
91
|
+
], NileGridHeadItem.prototype, "resizable", void 0);
|
|
92
92
|
__decorate([
|
|
93
93
|
property({ type: Boolean, reflect: true, attribute: true })
|
|
94
|
-
], NileGridHeadItem.prototype, "
|
|
95
|
-
__decorate([
|
|
96
|
-
property({ type: Number, reflect: true, attribute: true })
|
|
97
|
-
], NileGridHeadItem.prototype, "customWidth", void 0);
|
|
94
|
+
], NileGridHeadItem.prototype, "sticky", void 0);
|
|
98
95
|
NileGridHeadItem = __decorate([
|
|
99
96
|
customElement('nile-grid-head-item')
|
|
100
97
|
], NileGridHeadItem);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-head-item.js","sourceRoot":"","sources":["../../../src/nile-grid-head-item/nile-grid-head-item.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"nile-grid-head-item.js","sourceRoot":"","sources":["../../../src/nile-grid-head-item/nile-grid-head-item.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,EAAc,IAAI,EAAkC,MAAM,KAAK,CAAC;AACvE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AACnD,OAAO,WAAW,MAAM,0BAA0B,CAAC;AACnD,OAAO,EACL,cAAc,EACd,cAAc,EACd,cAAc,GACf,MAAM,6BAA6B,CAAC;AAErC;;;;;GAKG;AAEI,IAAM,gBAAgB,GAAtB,MA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B;AAClB;IAA5D,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC;gDAAgB;AAfjE,gBAAgB;IAD5B,aAAa,CAAC,qBAAqB,CAAC;GACxB,gBAAgB,CA8E5B;;AAED,eAAe,gBAAgB,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { LitElement, html, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { styles } from './nile-grid-head-item.css';\nimport NileElement from '../internal/nile-element';\nimport {\n initHeadResize,\n headResizeMove,\n headResizeDone,\n} from './nile-grid-head-item.utils';\n\n/**\n * Nile grid-head-item component.\n *\n * @tag nile-grid-head-item\n *\n */\n@customElement('nile-grid-head-item')\nexport class NileGridHeadItem extends NileElement {\n /**\n * The styles for nile-grid-head-item\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n @property({ type: Number, reflect: true, attribute: true }) colspan = 1;\n @property({ type: Number, reflect: true, attribute: true }) rowspan = 1;\n @property({ type: String, reflect: true, attribute: true }) scope:\n | 'col'\n | 'row' = 'col';\n @property({ type: Boolean, reflect: true, attribute: true }) resizable = false;\n @property({ type: Boolean, reflect: true, attribute: true }) sticky = false;\n\n connectedCallback() {\n super.connectedCallback();\n this.setAttribute(\n 'role',\n this.scope === 'row' ? 'rowheader' : 'columnheader'\n );\n }\n\n private onHandlePointerDown = (ev: PointerEvent) => {\n const el = this as HTMLElement;\n\n const downXRef = { value: 0 };\n const startWRef = { value: 0 };\n\n const result = initHeadResize(el, ev, downXRef, startWRef);\n if (!result) return;\n\n const { target, col } = result;\n\n const move = (e: PointerEvent) =>\n headResizeMove(el, col, startWRef.value, downXRef.value, e);\n\n const done = () => headResizeDone(el, ev, target, move);\n\n target.addEventListener('pointermove', move);\n target.addEventListener('pointerup', done, { once: true });\n target.addEventListener('pointercancel', done, { once: true });\n };\n\n protected updated(changed: Map<string, unknown>) {\n if (changed.has('scope')) {\n this.setAttribute(\n 'role',\n this.scope === 'row' ? 'rowheader' : 'columnheader'\n );\n }\n }\n\n disconnectedCallback() {\n super.disconnectedCallback();\n this.removeAttribute('role');\n }\n\n public render(): TemplateResult {\n return html`\n <div style=\"display: contents;\">\n <slot></slot>\n ${this.resizable\n ? html`\n <div\n aria-hidden=\"false\"\n class=\"resize-handle\"\n @pointerdown=${this.onHandlePointerDown}\n ></div>\n `\n : null}\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileGridHeadItem;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-grid-head-item': NileGridHeadItem;\n }\n}\n"]}
|
|
@@ -10,30 +10,18 @@ import { css } from 'lit';
|
|
|
10
10
|
*/
|
|
11
11
|
export const styles = css `
|
|
12
12
|
:host {
|
|
13
|
-
display:
|
|
14
|
-
grid-template-columns: var(--nile-grid-columns);
|
|
15
|
-
position: relative;
|
|
13
|
+
display: contents;
|
|
16
14
|
}
|
|
17
15
|
|
|
18
|
-
|
|
16
|
+
::slotted(nile-grid-header) {
|
|
19
17
|
background-color: var(--nile-colors-neutral-100);
|
|
20
18
|
}
|
|
21
19
|
|
|
22
|
-
.row-
|
|
23
|
-
|
|
24
|
-
pointer-events: none;
|
|
20
|
+
.row-layer {
|
|
21
|
+
background-color: var(--row-bg, transparent);
|
|
25
22
|
z-index: 0;
|
|
26
|
-
|
|
23
|
+
pointer-events: auto;
|
|
27
24
|
}
|
|
28
|
-
|
|
29
|
-
.row-slot {
|
|
30
|
-
grid-column: 1 / -1;
|
|
31
|
-
display: contents;
|
|
32
|
-
z-index: 1;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
:host([selected]) .row-bg { background: var(--row-selected-bg, rgba(0,0,0,.08)); }
|
|
36
|
-
:host([error]) .row-bg { background: var(--row-error-bg, #fff4f4); }
|
|
37
25
|
`;
|
|
38
26
|
export default [styles];
|
|
39
27
|
//# sourceMappingURL=nile-grid-row.css.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-row.css.js","sourceRoot":"","sources":["../../../src/nile-grid-row/nile-grid-row.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"nile-grid-row.css.js","sourceRoot":"","sources":["../../../src/nile-grid-row/nile-grid-row.css.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B;;GAEG;AACH,MAAM,CAAC,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;;;;;;;;;CAcxB,CAAC;AAEF,eAAe,CAAC,MAAM,CAAC,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit';\n\n/**\n * GridRow CSS\n */\nexport const styles = css`\n :host {\n display: contents;\n }\n\n ::slotted(nile-grid-header) {\n background-color: var(--nile-colors-neutral-100);\n }\n\n .row-layer {\n background-color: var(--row-bg, transparent);\n z-index: 0;\n pointer-events: auto;\n }\n`;\n\nexport default [styles];\n"]}
|
|
@@ -18,11 +18,8 @@ export declare class NileGridRow extends NileElement {
|
|
|
18
18
|
* @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`
|
|
19
19
|
*/
|
|
20
20
|
static get styles(): CSSResultArray;
|
|
21
|
-
disabled: boolean;
|
|
22
|
-
hover: boolean;
|
|
23
|
-
selected: boolean;
|
|
24
21
|
connectedCallback(): void;
|
|
25
|
-
|
|
22
|
+
render(): TemplateResult;
|
|
26
23
|
}
|
|
27
24
|
export default NileGridRow;
|
|
28
25
|
declare global {
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
import { __decorate } from "tslib";
|
|
8
8
|
import { html } from 'lit';
|
|
9
|
-
import { customElement
|
|
9
|
+
import { customElement } from 'lit/decorators.js';
|
|
10
10
|
import { styles } from './nile-grid-row.css';
|
|
11
11
|
import NileElement from '../internal/nile-element';
|
|
12
12
|
/**
|
|
@@ -16,13 +16,6 @@ import NileElement from '../internal/nile-element';
|
|
|
16
16
|
*
|
|
17
17
|
*/
|
|
18
18
|
let NileGridRow = class NileGridRow extends NileElement {
|
|
19
|
-
constructor() {
|
|
20
|
-
super(...arguments);
|
|
21
|
-
this.disabled = false;
|
|
22
|
-
this.hover = false;
|
|
23
|
-
this.selected = false;
|
|
24
|
-
/* #endregion */
|
|
25
|
-
}
|
|
26
19
|
/**
|
|
27
20
|
* The styles for nile-grid-row
|
|
28
21
|
* @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`
|
|
@@ -36,22 +29,14 @@ let NileGridRow = class NileGridRow extends NileElement {
|
|
|
36
29
|
}
|
|
37
30
|
render() {
|
|
38
31
|
return html `
|
|
39
|
-
<div part="row-
|
|
32
|
+
<div part="row-layer" class="row-layer" data-row-bg></div>
|
|
33
|
+
|
|
34
|
+
<div style="display: contents;">
|
|
40
35
|
<slot></slot>
|
|
41
36
|
</div>
|
|
42
|
-
<div part="row-bg" class="row-bg"></div>
|
|
43
37
|
`;
|
|
44
38
|
}
|
|
45
39
|
};
|
|
46
|
-
__decorate([
|
|
47
|
-
property({ type: Boolean, reflect: true, attribute: true })
|
|
48
|
-
], NileGridRow.prototype, "disabled", void 0);
|
|
49
|
-
__decorate([
|
|
50
|
-
property({ type: Boolean, reflect: true, attribute: true })
|
|
51
|
-
], NileGridRow.prototype, "hover", void 0);
|
|
52
|
-
__decorate([
|
|
53
|
-
property({ type: Boolean, reflect: true, attribute: true })
|
|
54
|
-
], NileGridRow.prototype, "selected", void 0);
|
|
55
40
|
NileGridRow = __decorate([
|
|
56
41
|
customElement('nile-grid-row')
|
|
57
42
|
], NileGridRow);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"nile-grid-row.js","sourceRoot":"","sources":["../../../src/nile-grid-row/nile-grid-row.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,
|
|
1
|
+
{"version":3,"file":"nile-grid-row.js","sourceRoot":"","sources":["../../../src/nile-grid-row/nile-grid-row.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;;AAEH,OAAO,EAAc,IAAI,EAAkC,MAAM,KAAK,CAAC;AACvE,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,OAAO,WAAW,MAAM,0BAA0B,CAAC;AAEnD;;;;;GAKG;AAEI,IAAM,WAAW,GAAjB,MAAM,WAAY,SAAQ,WAAW;IAC1C;;;OAGG;IACI,MAAM,KAAK,MAAM;QACtB,OAAO,CAAC,MAAM,CAAC,CAAC;IAClB,CAAC;IAED,iBAAiB;QACf,KAAK,CAAC,iBAAiB,EAAE,CAAC;QAC1B,IAAI,CAAC,YAAY,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;IACnC,CAAC;IAEM,MAAM;QACX,OAAO,IAAI,CAAA;;;;;;KAMV,CAAC;IACJ,CAAC;CAGF,CAAA;AAzBY,WAAW;IADvB,aAAa,CAAC,eAAe,CAAC;GAClB,WAAW,CAyBvB;;AAED,eAAe,WAAW,CAAC","sourcesContent":["/**\n * Copyright Aquera Inc 2025\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { LitElement, html, CSSResultArray, TemplateResult } from 'lit';\nimport { customElement } from 'lit/decorators.js';\nimport { styles } from './nile-grid-row.css';\nimport NileElement from '../internal/nile-element';\n\n/**\n * Nile grid-row component.\n *\n * @tag nile-grid-row\n *\n */\n@customElement('nile-grid-row')\nexport class NileGridRow extends NileElement {\n /**\n * The styles for nile-grid-row\n * @remarks If you are extending this class you can extend the base styles with super. Eg `return [super(), myCustomStyles]`\n */\n public static get styles(): CSSResultArray {\n return [styles];\n }\n\n connectedCallback() {\n super.connectedCallback();\n this.setAttribute('role', 'row');\n }\n\n public render(): TemplateResult {\n return html`\n <div part=\"row-layer\" class=\"row-layer\" data-row-bg></div>\n\n <div style=\"display: contents;\">\n <slot></slot>\n </div>\n `;\n }\n\n /* #endregion */\n}\n\nexport default NileGridRow;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-grid-row': NileGridRow;\n }\n}\n"]}
|
|
@@ -163,6 +163,11 @@ export declare class NileVirtualSelect extends NileElement implements NileFormCo
|
|
|
163
163
|
blockValueChange: boolean;
|
|
164
164
|
/** Disable width synchronization */
|
|
165
165
|
noWidthSync: boolean;
|
|
166
|
+
/**
|
|
167
|
+
* When true, the listbox will be appended to the document body instead of the parent container.
|
|
168
|
+
* This is useful when the parent has overflow: hidden, clip-path, or transform applied.
|
|
169
|
+
*/
|
|
170
|
+
bodyAppend: boolean;
|
|
166
171
|
/**
|
|
167
172
|
* The maximum number of selected options to show when `multiple` is true. After the maximum, "+n" will be shown to
|
|
168
173
|
* indicate the number of additional items that are selected. Set to 0 to remove the limit.
|
|
@@ -170,6 +175,8 @@ export declare class NileVirtualSelect extends NileElement implements NileFormCo
|
|
|
170
175
|
maxOptionsVisible: number;
|
|
171
176
|
oldMaxOptionsVisible: number;
|
|
172
177
|
showListbox: boolean;
|
|
178
|
+
private bodyAppendContainer;
|
|
179
|
+
private bodyAppendListbox;
|
|
173
180
|
/** Gets the validity state object */
|
|
174
181
|
get validity(): ValidityState;
|
|
175
182
|
/** Gets the validation message */
|
|
@@ -209,6 +216,8 @@ export declare class NileVirtualSelect extends NileElement implements NileFormCo
|
|
|
209
216
|
* we are catching only the error message related to the virtualizer.
|
|
210
217
|
*/
|
|
211
218
|
private handleWindowError;
|
|
219
|
+
private handleWindowResize;
|
|
220
|
+
private handleWindowScroll;
|
|
212
221
|
private handleFooterClick;
|
|
213
222
|
private toggleShowSelected;
|
|
214
223
|
private unSelectAll;
|
|
@@ -241,6 +250,7 @@ export declare class NileVirtualSelect extends NileElement implements NileFormCo
|
|
|
241
250
|
handleDataChange(): void;
|
|
242
251
|
handleRenderItemConfigChange(): void;
|
|
243
252
|
handleOptionsLoadingChange(): void;
|
|
253
|
+
handleBodyAppendChange(): void;
|
|
244
254
|
handleOpenChange(): Promise<void>;
|
|
245
255
|
private handleOpen;
|
|
246
256
|
private handleClose;
|
|
@@ -279,6 +289,14 @@ export declare class NileVirtualSelect extends NileElement implements NileFormCo
|
|
|
279
289
|
private calculateWidthOfSelectTagsDiv;
|
|
280
290
|
private calculateTotalWidthOfTags;
|
|
281
291
|
private resetScrollPosition;
|
|
292
|
+
private createBodyAppendContainer;
|
|
293
|
+
private createBodyAppendListbox;
|
|
294
|
+
private positionBodyAppend;
|
|
295
|
+
private updateBodyAppendPosition;
|
|
296
|
+
private updateBodyAppendContent;
|
|
297
|
+
private attachBodyAppendEventListeners;
|
|
298
|
+
private setupBodyAppend;
|
|
299
|
+
private cleanupBodyAppend;
|
|
282
300
|
}
|
|
283
301
|
export default NileVirtualSelect;
|
|
284
302
|
declare global {
|