@aquera/nile-elements 2.0.8 → 2.0.10

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 (97) hide show
  1. package/README.md +12 -0
  2. package/demo/nxtgen-classes.css +5 -5
  3. package/demo/nxtgen-dark.css +25 -25
  4. package/demo/nxtgen-properties.css +2 -2
  5. package/demo/nxtgen-utilities.css +5 -5
  6. package/demo/nxtgen.css +5 -5
  7. package/demo/utilities.css +2 -2
  8. package/demo/variables.css +2 -2
  9. package/dist/index.js +634 -264
  10. package/dist/nile-badge/nile-badge.css.cjs.js +1 -1
  11. package/dist/nile-badge/nile-badge.css.cjs.js.map +1 -1
  12. package/dist/nile-badge/nile-badge.css.esm.js +2 -2
  13. package/dist/nile-button-toggle/nile-button-toggle.css.cjs.js +1 -1
  14. package/dist/nile-button-toggle/nile-button-toggle.css.cjs.js.map +1 -1
  15. package/dist/nile-button-toggle/nile-button-toggle.css.esm.js +2 -2
  16. package/dist/nile-code-editor/nile-code-editor.cjs.js +1 -1
  17. package/dist/nile-code-editor/nile-code-editor.cjs.js.map +1 -1
  18. package/dist/nile-code-editor/nile-code-editor.esm.js +1 -1
  19. package/dist/nile-menu-item/nile-menu-item.css.cjs.js +1 -1
  20. package/dist/nile-menu-item/nile-menu-item.css.cjs.js.map +1 -1
  21. package/dist/nile-menu-item/nile-menu-item.css.esm.js +1 -1
  22. package/dist/nile-rich-text-editor/nile-rich-text-editor.css.cjs.js +1 -1
  23. package/dist/nile-rich-text-editor/nile-rich-text-editor.css.cjs.js.map +1 -1
  24. package/dist/nile-rich-text-editor/nile-rich-text-editor.css.esm.js +5 -2
  25. package/dist/nile-select/index.cjs.js +1 -1
  26. package/dist/nile-select/index.esm.js +1 -1
  27. package/dist/nile-select/nile-select.cjs.js +2 -1
  28. package/dist/nile-select/nile-select.cjs.js.map +1 -1
  29. package/dist/nile-select/nile-select.css.cjs.js +1 -1
  30. package/dist/nile-select/nile-select.css.cjs.js.map +1 -1
  31. package/dist/nile-select/nile-select.css.esm.js +126 -6
  32. package/dist/nile-select/nile-select.esm.js +77 -11
  33. package/dist/nile-select/virtual-scroll-helper.cjs.js +1 -1
  34. package/dist/nile-select/virtual-scroll-helper.cjs.js.map +1 -1
  35. package/dist/nile-select/virtual-scroll-helper.esm.js +3 -1
  36. package/dist/nile-toast/nile-toast.css.cjs.js +1 -1
  37. package/dist/nile-toast/nile-toast.css.cjs.js.map +1 -1
  38. package/dist/nile-toast/nile-toast.css.esm.js +5 -5
  39. package/dist/nile-virtual-select/index.cjs.js +1 -1
  40. package/dist/nile-virtual-select/index.esm.js +1 -1
  41. package/dist/nile-virtual-select/nile-virtual-select.cjs.js +4 -3
  42. package/dist/nile-virtual-select/nile-virtual-select.cjs.js.map +1 -1
  43. package/dist/nile-virtual-select/nile-virtual-select.css.cjs.js +1 -1
  44. package/dist/nile-virtual-select/nile-virtual-select.css.cjs.js.map +1 -1
  45. package/dist/nile-virtual-select/nile-virtual-select.css.esm.js +126 -6
  46. package/dist/nile-virtual-select/nile-virtual-select.esm.js +71 -12
  47. package/dist/src/nile-badge/nile-badge.css.js +2 -2
  48. package/dist/src/nile-badge/nile-badge.css.js.map +1 -1
  49. package/dist/src/nile-button-toggle/nile-button-toggle.css.js +2 -2
  50. package/dist/src/nile-button-toggle/nile-button-toggle.css.js.map +1 -1
  51. package/dist/src/nile-code-editor/nile-code-editor.d.ts +1 -1
  52. package/dist/src/nile-code-editor/nile-code-editor.js +2 -2
  53. package/dist/src/nile-code-editor/nile-code-editor.js.map +1 -1
  54. package/dist/src/nile-menu-item/nile-menu-item.css.js +1 -1
  55. package/dist/src/nile-menu-item/nile-menu-item.css.js.map +1 -1
  56. package/dist/src/nile-rich-text-editor/nile-rich-text-editor.css.js +5 -2
  57. package/dist/src/nile-rich-text-editor/nile-rich-text-editor.css.js.map +1 -1
  58. package/dist/src/nile-select/nile-select.css.js +126 -6
  59. package/dist/src/nile-select/nile-select.css.js.map +1 -1
  60. package/dist/src/nile-select/nile-select.d.ts +43 -5
  61. package/dist/src/nile-select/nile-select.js +445 -106
  62. package/dist/src/nile-select/nile-select.js.map +1 -1
  63. package/dist/src/nile-select/nile-select.test.d.ts +1 -0
  64. package/dist/src/nile-select/nile-select.test.js +342 -1
  65. package/dist/src/nile-select/nile-select.test.js.map +1 -1
  66. package/dist/src/nile-select/virtual-scroll-helper.js +3 -1
  67. package/dist/src/nile-select/virtual-scroll-helper.js.map +1 -1
  68. package/dist/src/nile-toast/nile-toast.css.js +5 -5
  69. package/dist/src/nile-toast/nile-toast.css.js.map +1 -1
  70. package/dist/src/nile-virtual-select/nile-virtual-select.css.js +126 -6
  71. package/dist/src/nile-virtual-select/nile-virtual-select.css.js.map +1 -1
  72. package/dist/src/nile-virtual-select/nile-virtual-select.d.ts +45 -4
  73. package/dist/src/nile-virtual-select/nile-virtual-select.js +385 -59
  74. package/dist/src/nile-virtual-select/nile-virtual-select.js.map +1 -1
  75. package/dist/src/nile-virtual-select/nile-virtual-select.test.js +253 -1
  76. package/dist/src/nile-virtual-select/nile-virtual-select.test.js.map +1 -1
  77. package/dist/src/version.js +1 -1
  78. package/dist/src/version.js.map +1 -1
  79. package/dist/tsconfig.tsbuildinfo +1 -1
  80. package/dist/version.cjs.js +1 -1
  81. package/dist/version.cjs.js.map +1 -1
  82. package/dist/version.esm.js +1 -1
  83. package/package.json +1 -1
  84. package/src/nile-badge/nile-badge.css.ts +2 -2
  85. package/src/nile-button-toggle/nile-button-toggle.css.ts +2 -2
  86. package/src/nile-code-editor/nile-code-editor.ts +2 -2
  87. package/src/nile-menu-item/nile-menu-item.css.ts +1 -1
  88. package/src/nile-rich-text-editor/nile-rich-text-editor.css.ts +5 -2
  89. package/src/nile-select/nile-select.css.ts +126 -6
  90. package/src/nile-select/nile-select.test.ts +478 -1
  91. package/src/nile-select/nile-select.ts +499 -91
  92. package/src/nile-select/virtual-scroll-helper.ts +3 -1
  93. package/src/nile-toast/nile-toast.css.ts +5 -5
  94. package/src/nile-virtual-select/nile-virtual-select.css.ts +126 -6
  95. package/src/nile-virtual-select/nile-virtual-select.test.ts +352 -1
  96. package/src/nile-virtual-select/nile-virtual-select.ts +460 -55
  97. package/vscode-html-custom-data.json +40 -6
@@ -1,5 +1,6 @@
1
- import { expect, fixture, html } from '@open-wc/testing';
1
+ import { aTimeout, expect, fixture, html, nextFrame } from '@open-wc/testing';
2
2
  import './nile-select';
3
+ import '../nile-option/nile-option';
3
4
  describe('NileSelect', () => {
4
5
  it('1. renders', async () => { const el = await fixture(html `<nile-select></nile-select>`); expect(el).to.exist; });
5
6
  it('2. shadow root', async () => { const el = await fixture(html `<nile-select></nile-select>`); expect(el.shadowRoot).to.not.be.null; });
@@ -105,4 +106,344 @@ describe('NileSelect', () => {
105
106
  it('99. no nile-card', async () => { const el = await fixture(html `<nile-select></nile-select>`); expect(el.shadowRoot.querySelector('nile-card')).to.be.null; });
106
107
  it('100. full integration', async () => { const el = await fixture(html `<nile-select class="sl" id="sl1"></nile-select>`); expect(el.id).to.equal('sl1'); expect(el.shadowRoot).to.not.be.null; expect(el.shadowRoot.querySelector('slot:not([name])')).to.exist; });
107
108
  });
109
+ describe('NileSelect chip fitting behaviour matrix', () => {
110
+ const LABELS = [
111
+ 'Engineering Operations Team',
112
+ 'Human Resources Department',
113
+ 'Finance And Accounting Group',
114
+ 'Customer Success Organisation',
115
+ 'Product Design Studio Unit'
116
+ ];
117
+ const options = () => LABELS.map(label => html `<nile-option value=${label}>${label}</nile-option>`);
118
+ async function settle(el) {
119
+ await el.updateComplete;
120
+ await nextFrame();
121
+ await nextFrame();
122
+ await el.updateComplete;
123
+ }
124
+ function tagsRoot(el) {
125
+ return el.shadowRoot.querySelector('.select__tags');
126
+ }
127
+ function chips(el) {
128
+ return Array.from(el.shadowRoot.querySelectorAll('.select__tags nile-tag'));
129
+ }
130
+ function hiddenChips(el) {
131
+ return chips(el).filter(chip => chip.style.display === 'none');
132
+ }
133
+ it('M1. multiple + no max-options-visible + autoResize=false renders fitted chips', async () => {
134
+ const host = await fixture(html `<div style="width: 320px">
135
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
136
+ </div>`);
137
+ const el = host.querySelector('nile-select');
138
+ await settle(el);
139
+ expect(el.autoResize).to.be.false;
140
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.true;
141
+ expect(el.shadowRoot.querySelector('button.select__tags-count')).to.exist;
142
+ expect(chips(el).length).to.equal(LABELS.length);
143
+ });
144
+ it('M2. multiple + no max-options-visible + autoResize=true refits when the container resizes', async () => {
145
+ const host = await fixture(html `<div style="width: 480px">
146
+ <nile-select multiple autoresize .value=${LABELS}>${options()}</nile-select>
147
+ </div>`);
148
+ const el = host.querySelector('nile-select');
149
+ await settle(el);
150
+ expect(el.autoResize).to.be.true;
151
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.true;
152
+ const wideHidden = hiddenChips(el).length;
153
+ host.style.width = '180px';
154
+ await aTimeout(200);
155
+ await settle(el);
156
+ expect(hiddenChips(el).length).to.be.at.least(wideHidden);
157
+ });
158
+ it('M3. explicit max-options-visible switches to fixed-count layout', async () => {
159
+ const host = await fixture(html `<div style="width: 320px">
160
+ <nile-select multiple max-options-visible="2" .value=${LABELS}>
161
+ ${options()}
162
+ </nile-select>
163
+ </div>`);
164
+ const el = host.querySelector('nile-select');
165
+ await settle(el);
166
+ expect(el.maxOptionsVisible).to.equal(2);
167
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.false;
168
+ expect(chips(el).length).to.equal(2);
169
+ expect(el.shadowRoot.querySelector('span.select__tags-count')).to.exist;
170
+ });
171
+ it('M3b. max-options-visible set as a property also switches to fixed-count layout', async () => {
172
+ const host = await fixture(html `<div style="width: 320px">
173
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
174
+ </div>`);
175
+ const el = host.querySelector('nile-select');
176
+ await settle(el);
177
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.true;
178
+ el.maxOptionsVisible = 1;
179
+ await settle(el);
180
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.false;
181
+ expect(chips(el).length).to.equal(1);
182
+ });
183
+ it('M3c. the default max-options-visible is still 3 and reading it does not opt out', async () => {
184
+ const host = await fixture(html `<div style="width: 320px">
185
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
186
+ </div>`);
187
+ const el = host.querySelector('nile-select');
188
+ await settle(el);
189
+ expect(el.maxOptionsVisible).to.equal(3);
190
+ expect(el.maxOptionsVisible).to.equal(3);
191
+ await settle(el);
192
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.true;
193
+ });
194
+ it('M5. autoresize works as a markup attribute', async () => {
195
+ const b = await fixture(html `<nile-select multiple autoresize></nile-select>`);
196
+ await b.updateComplete;
197
+ expect(b.autoResize).to.be.true;
198
+ const c = await fixture(html `<nile-select multiple></nile-select>`);
199
+ await c.updateComplete;
200
+ expect(c.autoResize).to.be.false;
201
+ });
202
+ it('M8. virtual-scroll mode keeps fitted chips when max-options-visible was never set', async () => {
203
+ const host = await fixture(html `<div style="width: 320px">
204
+ <nile-select
205
+ multiple
206
+ enable-virtual-scroll
207
+ .enableVirtualScroll=${true}
208
+ .data=${LABELS.map(label => ({ label, value: label }))}
209
+ .value=${LABELS}
210
+ ></nile-select>
211
+ </div>`);
212
+ const el = host.querySelector('nile-select');
213
+ await settle(el);
214
+ const inner = el.shadowRoot.querySelector('nile-virtual-select');
215
+ expect(inner, 'inner nile-virtual-select should render').to.exist;
216
+ await inner.updateComplete;
217
+ await nextFrame();
218
+ const innerTags = inner.shadowRoot.querySelector('.select__tags');
219
+ expect(innerTags.classList.contains('select__tags--fitted')).to.be.true;
220
+ });
221
+ it('M9. virtual-scroll mode forwards an explicit max-options-visible', async () => {
222
+ const host = await fixture(html `<div style="width: 320px">
223
+ <nile-select
224
+ multiple
225
+ max-options-visible="2"
226
+ .enableVirtualScroll=${true}
227
+ .data=${LABELS.map(label => ({ label, value: label }))}
228
+ .value=${LABELS}
229
+ ></nile-select>
230
+ </div>`);
231
+ const el = host.querySelector('nile-select');
232
+ await settle(el);
233
+ const inner = el.shadowRoot.querySelector('nile-virtual-select');
234
+ await inner.updateComplete;
235
+ await nextFrame();
236
+ expect(inner.maxOptionsVisible).to.equal(2);
237
+ expect(inner.shadowRoot
238
+ .querySelector('.select__tags')
239
+ .classList.contains('select__tags--fitted')).to.be.false;
240
+ });
241
+ it('M10. autoResize reflects to the autoresize attribute', async () => {
242
+ const el = await fixture(html `<nile-select multiple></nile-select>`);
243
+ await el.updateComplete;
244
+ expect(el.hasAttribute('autoresize')).to.be.false;
245
+ el.autoResize = true;
246
+ await el.updateComplete;
247
+ expect(el.hasAttribute('autoresize')).to.be.true;
248
+ el.autoResize = false;
249
+ await el.updateComplete;
250
+ expect(el.hasAttribute('autoresize')).to.be.false;
251
+ });
252
+ it('M11. toggling max-options-visible does not leak resize observers or lose the observed container', async () => {
253
+ const host = await fixture(html `<div style="width: 480px">
254
+ <nile-select multiple autoresize .value=${LABELS}>
255
+ ${options()}
256
+ </nile-select>
257
+ </div>`);
258
+ const el = host.querySelector('nile-select');
259
+ await settle(el);
260
+ el.maxOptionsVisible = 2;
261
+ await settle(el);
262
+ expect(tagsRoot(el).classList.contains('select__tags--fitted')).to.be.false;
263
+ const observed = el.observedTagsContainer;
264
+ expect(observed, 'observer detached in fixed-count mode').to.be.undefined;
265
+ });
266
+ it('M6. the +N button count matches the number of hidden chips', async () => {
267
+ const host = await fixture(html `<div style="width: 220px">
268
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
269
+ </div>`);
270
+ const el = host.querySelector('nile-select');
271
+ await settle(el);
272
+ const overflow = el.shadowRoot.querySelector('button.select__tags-count');
273
+ const hidden = hiddenChips(el).length;
274
+ if (hidden > 0) {
275
+ expect(overflow).to.exist;
276
+ expect(overflow.textContent.trim()).to.equal(`+${hidden}`);
277
+ expect(overflow.getAttribute('aria-label')).to.equal(`${hidden} more selected`);
278
+ }
279
+ else {
280
+ // Nothing overflows, so the button is not rendered at all.
281
+ expect(overflow).to.not.exist;
282
+ }
283
+ });
284
+ // The tooltip is opt-in: `showtooltip` present, and the chip's text clipped.
285
+ function tips(el) {
286
+ return Array.from(el.shadowRoot.querySelectorAll('.select__tag-tip'));
287
+ }
288
+ function liveTips(el) {
289
+ return tips(el).filter(tip => !tip.hasAttribute('disabled'));
290
+ }
291
+ it('M12. no showtooltip attribute hides the chip tooltip', async () => {
292
+ const host = await fixture(html `<div style="width: 200px">
293
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
294
+ </div>`);
295
+ const el = host.querySelector('nile-select');
296
+ await settle(el);
297
+ expect(el.showTooltip).to.be.false;
298
+ expect(el.hasAttribute('showtooltip')).to.be.false;
299
+ expect(tips(el).length).to.be.greaterThan(0);
300
+ expect(liveTips(el).length).to.equal(0);
301
+ });
302
+ it('M13. showtooltip shows the chip tooltip', async () => {
303
+ const host = await fixture(html `<div style="width: 200px">
304
+ <nile-select multiple showtooltip .value=${LABELS}>
305
+ ${options()}
306
+ </nile-select>
307
+ </div>`);
308
+ const el = host.querySelector('nile-select');
309
+ await settle(el);
310
+ expect(el.showTooltip).to.be.true;
311
+ expect(liveTips(el).length).to.be.greaterThan(0);
312
+ });
313
+ // Truncation is bound to the tooltip: a clipped chip is only acceptable when
314
+ // something can reveal the value it hid. A chip wider than the whole field is
315
+ // the one exception - there is nowhere for it to go.
316
+ function chipContent(chip) {
317
+ return chip.shadowRoot.querySelector('[part~="content"]');
318
+ }
319
+ function clippedChipCount(el) {
320
+ return chips(el)
321
+ .filter(chip => chip.style.display !== 'none')
322
+ .filter(chip => {
323
+ const content = chipContent(chip);
324
+ return content.scrollWidth > content.clientWidth + 1;
325
+ }).length;
326
+ }
327
+ it('M16. without showtooltip a fitted chip is never truncated', async () => {
328
+ const host = await fixture(html `<div style="width: 480px">
329
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
330
+ </div>`);
331
+ const el = host.querySelector('nile-select');
332
+ await settle(el);
333
+ expect(el.showTooltip).to.be.false;
334
+ expect(clippedChipCount(el)).to.equal(0);
335
+ // The chips that could not fit went into the +N button, not into an ellipsis.
336
+ expect(hiddenChips(el).length).to.be.greaterThan(0);
337
+ });
338
+ it('M17. showtooltip is what allows a fitted chip to be truncated', async () => {
339
+ const host = await fixture(html `<div style="width: 480px">
340
+ <nile-select multiple showtooltip .value=${LABELS}>
341
+ ${options()}
342
+ </nile-select>
343
+ </div>`);
344
+ const el = host.querySelector('nile-select');
345
+ await settle(el);
346
+ expect(el.showTooltip).to.be.true;
347
+ expect(clippedChipCount(el)).to.be.greaterThan(0);
348
+ });
349
+ it('M14. removing showtooltip hides the chip tooltip again', async () => {
350
+ const host = await fixture(html `<div style="width: 200px">
351
+ <nile-select multiple showtooltip .value=${LABELS}>
352
+ ${options()}
353
+ </nile-select>
354
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
355
+ </div>`);
356
+ const [el, control] = Array.from(host.querySelectorAll('nile-select'));
357
+ await settle(el);
358
+ await settle(control);
359
+ expect(liveTips(el).length).to.be.greaterThan(0);
360
+ el.removeAttribute('showtooltip');
361
+ await settle(el);
362
+ expect(el.showTooltip).to.be.false;
363
+ expect(liveTips(el).length).to.equal(0);
364
+ // Removing the attribute must land back on the default.
365
+ expect(tips(el).map(tip => tip.hasAttribute('disabled'))).to.deep.equal(tips(control).map(tip => tip.hasAttribute('disabled')));
366
+ });
367
+ it('M15. the overflow button label and text never disagree, including first paint', async () => {
368
+ const host = await fixture(html `<div style="width: 220px">
369
+ <nile-select multiple .value=${LABELS}>${options()}</nile-select>
370
+ </div>`);
371
+ const el = host.querySelector('nile-select');
372
+ // Before the layout frame runs, no button may claim a count it cannot back up.
373
+ await el.updateComplete;
374
+ const early = el.shadowRoot.querySelector('button.select__tags-count');
375
+ if (early) {
376
+ const shown = early.textContent.trim().replace('+', '');
377
+ expect(early.getAttribute('aria-label')).to.equal(`${shown} more selected`);
378
+ }
379
+ await settle(el);
380
+ const overflow = el.shadowRoot.querySelector('button.select__tags-count');
381
+ expect(overflow).to.exist;
382
+ const shown = overflow.textContent.trim().replace('+', '');
383
+ expect(overflow.getAttribute('aria-label')).to.equal(`${shown} more selected`);
384
+ expect(Number(shown)).to.equal(hiddenChips(el).length);
385
+ });
386
+ it('M16. no overflow button is rendered when every chip fits', async () => {
387
+ const host = await fixture(html `<div style="width: 1200px">
388
+ <nile-select multiple .value=${LABELS.slice(0, 1)}>
389
+ ${options()}
390
+ </nile-select>
391
+ </div>`);
392
+ const el = host.querySelector('nile-select');
393
+ await settle(el);
394
+ expect(hiddenChips(el).length).to.equal(0);
395
+ expect(el.shadowRoot.querySelector('button.select__tags-count')).to.not
396
+ .exist;
397
+ });
398
+ // `<nile-select enableVirtualScroll>` renders a nile-virtual-select in its own
399
+ // shadow root and hands it the public API by hand. Anything added to one and
400
+ // not to that list is silently dead on the wrapper form, which is how
401
+ // showTooltip / chipMinWidth / chipMaxWidth were missed - so assert the whole
402
+ // chip-fitting surface crosses over, defaults included.
403
+ function innerVirtual(el) {
404
+ return el.shadowRoot.querySelector('nile-virtual-select');
405
+ }
406
+ it('M17. enableVirtualScroll forwards the chip-fitting properties inward', async () => {
407
+ const el = await fixture(html `<nile-select
408
+ multiple
409
+ enableVirtualScroll
410
+ showtooltip
411
+ autoresize
412
+ chipminwidth="90"
413
+ chipmaxwidth="160"
414
+ ></nile-select>`);
415
+ await el.updateComplete;
416
+ const inner = innerVirtual(el);
417
+ expect(inner).to.exist;
418
+ expect(el.showTooltip).to.be.true;
419
+ expect(el.chipMinWidth).to.equal(90);
420
+ expect(el.chipMaxWidth).to.equal(160);
421
+ expect(el.autoResize).to.be.true;
422
+ expect(inner.showTooltip).to.equal(el.showTooltip);
423
+ expect(inner.chipMinWidth).to.equal(el.chipMinWidth);
424
+ expect(inner.chipMaxWidth).to.equal(el.chipMaxWidth);
425
+ expect(inner.autoResize).to.equal(el.autoResize);
426
+ });
427
+ it('M18. enableVirtualScroll forwards the chip-fitting defaults too', async () => {
428
+ const el = await fixture(html `<nile-select multiple enableVirtualScroll></nile-select>`);
429
+ await el.updateComplete;
430
+ const inner = innerVirtual(el);
431
+ expect(inner).to.exist;
432
+ // chipMinWidth defaults to 110 on both sides, so a missing forward looks
433
+ // correct here - the other two are what actually catch a dropped property.
434
+ expect(inner.showTooltip).to.be.false;
435
+ expect(inner.chipMinWidth).to.equal(110);
436
+ expect(inner.chipMaxWidth).to.equal(180);
437
+ });
438
+ it('M19. changing a chip property after first render reaches the inner select', async () => {
439
+ const el = await fixture(html `<nile-select multiple enableVirtualScroll></nile-select>`);
440
+ await el.updateComplete;
441
+ el.showTooltip = true;
442
+ el.chipMaxWidth = 240;
443
+ await el.updateComplete;
444
+ const inner = innerVirtual(el);
445
+ expect(inner.showTooltip).to.be.true;
446
+ expect(inner.chipMaxWidth).to.equal(240);
447
+ });
448
+ });
108
449
  //# sourceMappingURL=nile-select.test.js.map