@cas-smartdesign/virtual-list 7.0.1 → 7.0.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.
@@ -1,2 +1 @@
1
- import"./doc.mjs";import{I as s}from"./item-provider.mjs";const o=document.querySelector("#selection-example"),t=o.querySelector("#notification"),r=Array.from(o.querySelectorAll("sd-virtual-list"));r.forEach(i=>{new s().connectList(i),i.addEventListener("selection",e=>{const n=r.indexOf(e.currentTarget);t.style.visibility="visible",t.style.gridColumnStart=`${n+1}`,t.innerText=`Item at index ${e.detail.index} has been ${e.detail.selected?"selected":"deselected"}
2
- Modifier pressed: ${e.detail.hasModifier}`})});
1
+ import"./doc.mjs";import{I as l}from"./item-provider.mjs";const r=document.querySelector("#selection-example"),t=r.querySelector("#notification"),n=Array.from(r.querySelectorAll("sd-virtual-list"));n.forEach(i=>{new l().connectList(i),i.addEventListener("selection",e=>{const o=n.indexOf(e.currentTarget);t.style.visibility="visible",t.style.gridColumnStart=`${o+1}`,t.innerText=`Item at index ${e.detail.index} has been ${e.detail.selected?"selected":"deselected"}`})});
package/dist/docs/doc.mjs CHANGED
@@ -55,7 +55,7 @@ lists.forEach((list: VirtualList) => {
55
55
  notification.style.gridColumnStart = \`\${listIndex + 1}\`;
56
56
  notification.innerText = \`Item at index \${event.detail.index} has been \${
57
57
  event.detail.selected ? "selected" : "deselected"
58
- }\\nModifier pressed: \${event.detail.hasModifier}\`;
58
+ }\`;
59
59
  });
60
60
  });
61
61
  `,gi=`import { ItemData } from "@cas-smartdesign/list-item";
@@ -496,7 +496,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`),ie=S,V=T),q===void 0&&
496
496
  <li><code>selection</code><ul>
497
497
  <li>Dispatched when one of the items is selected/deselected</li>
498
498
  <li>Contains the index of the item and a <code>selected</code> flag which is when false indicates that the item is deselected</li>
499
- <li>The <code>hasModifier</code> property is true if mouse wheel or ctrl/meta key is down while selection. Note that the auto scroll feature is disabled while middle mouse click.</li>
499
+ <li>The <code>originalEvent</code> a mouse or keyboard event that triggered the selection event.</li>
500
500
  </ul>
501
501
  </li>
502
502
  </ul>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cas-smartdesign/virtual-list",
3
- "version": "7.0.1",
3
+ "version": "7.0.2",
4
4
  "description": "A virtualized list element with SmartDesign look and feel.",
5
5
  "main": "dist/virtual-list-with-externals.js",
6
6
  "module": "dist/virtual-list.mjs",
package/readme.md CHANGED
@@ -43,7 +43,7 @@ The following properties are available:
43
43
  - `selection`
44
44
  - Dispatched when one of the items is selected/deselected
45
45
  - Contains the index of the item and a `selected` flag which is when false indicates that the item is deselected
46
- - The `hasModifier` property is true if mouse wheel or ctrl/meta key is down while selection. Note that the auto scroll feature is disabled while middle mouse click.
46
+ - The `originalEvent` a mouse or keyboard event that triggered the selection event.
47
47
 
48
48
  ## Public methods
49
49