@refinitiv-ui/elements 7.6.0 → 7.6.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.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,19 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [7.6.2](https://github.com/Refinitiv/refinitiv-ui/compare/@refinitiv-ui/elements@7.6.1...@refinitiv-ui/elements@7.6.2) (2023-10-09)
7
+
8
+ ### Bug Fixes
9
+
10
+ - **overlay-menu:** missing nested items property ([#982](https://github.com/Refinitiv/refinitiv-ui/issues/982)) ([bac94cb](https://github.com/Refinitiv/refinitiv-ui/commit/bac94cbb39f5a2dde2046c385020941a2d35317e))
11
+
12
+ ## [7.6.1](https://github.com/Refinitiv/refinitiv-ui/compare/@refinitiv-ui/elements@7.6.0...@refinitiv-ui/elements@7.6.1) (2023-10-02)
13
+
14
+ ### Bug Fixes
15
+
16
+ - **list, tree:** stateless list and tree should have `aria-readonly`="true" ([#971](https://github.com/Refinitiv/refinitiv-ui/issues/971)) ([6856c0f](https://github.com/Refinitiv/refinitiv-ui/commit/6856c0fdff5e7165f8c07e99865ebfdc7f190558))
17
+ - **tree:** parent label can't expand/collapse in stateless mode ([#967](https://github.com/Refinitiv/refinitiv-ui/issues/967)) ([74f9877](https://github.com/Refinitiv/refinitiv-ui/commit/74f9877b8643e49059f4e35a141b4a892f17cd86))
18
+
6
19
  # [7.6.0](https://github.com/Refinitiv/refinitiv-ui/compare/@refinitiv-ui/elements@7.5.0...@refinitiv-ui/elements@7.6.0) (2023-09-25)
7
20
 
8
21
  ### Bug Fixes
@@ -5,6 +5,10 @@ interface CommonItem extends DataItem {
5
5
  * Type of item. Value can be `text`, `header`, `divider`
6
6
  */
7
7
  type?: ItemType;
8
+ /**
9
+ * Used for nested ItemData.
10
+ */
11
+ items?: ItemData[];
8
12
  }
9
13
  interface CommonLabelItem extends CommonItem {
10
14
  /**
@@ -572,6 +572,14 @@ let List = class List extends ControlElement {
572
572
  this.renderTimestamp.clear(); // force render of all items
573
573
  this.setAttribute('aria-multiselectable', this.multiple ? 'true' : 'false');
574
574
  }
575
+ if (changeProperties.has('stateless')) {
576
+ if (this.stateless) {
577
+ this.setAttribute('aria-readonly', 'true');
578
+ }
579
+ else {
580
+ this.removeAttribute('aria-readonly');
581
+ }
582
+ }
575
583
  }
576
584
  /**
577
585
  * A `CSSResultGroup` that will be used
@@ -96,6 +96,10 @@ let Tree = class Tree extends List {
96
96
  selectItem(item) {
97
97
  // Stateless tree
98
98
  if (this.stateless) {
99
+ // Single selection - expand/collapse group (parent)
100
+ if (!this.multiple && this.manager.isItemParent(item)) {
101
+ this.toggleExpandedState(item);
102
+ }
99
103
  return false;
100
104
  }
101
105
  // Multiple selection
@@ -14,6 +14,10 @@ export interface TreeDataItem extends DataItem {
14
14
  * If `true`, child items will be visible
15
15
  */
16
16
  expanded?: boolean;
17
+ /**
18
+ * Used for nested TreeDataItem.
19
+ */
20
+ items?: TreeDataItem[];
17
21
  }
18
22
  /**
19
23
  * Predicate callback
package/lib/version.js CHANGED
@@ -1 +1 @@
1
- export const VERSION = '7.6.0';
1
+ export const VERSION = '7.6.2';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@refinitiv-ui/elements",
3
- "version": "7.6.0",
3
+ "version": "7.6.2",
4
4
  "description": "Element Framework Elements",
5
5
  "author": "LSEG",
6
6
  "license": "Apache-2.0",
@@ -351,25 +351,25 @@
351
351
  "tslib": "^2.3.1"
352
352
  },
353
353
  "devDependencies": {
354
- "@refinitiv-ui/core": "^7.2.0",
355
- "@refinitiv-ui/demo-block": "^7.0.6",
354
+ "@refinitiv-ui/core": "^7.2.1",
355
+ "@refinitiv-ui/demo-block": "^7.0.8",
356
356
  "@refinitiv-ui/i18n": "^7.0.4",
357
357
  "@refinitiv-ui/phrasebook": "^7.0.4",
358
358
  "@refinitiv-ui/test-helpers": "^7.0.4",
359
- "@refinitiv-ui/translate": "^7.0.4",
360
- "@refinitiv-ui/utils": "^7.1.0",
359
+ "@refinitiv-ui/translate": "^7.0.5",
360
+ "@refinitiv-ui/utils": "^7.1.1",
361
361
  "@types/d3-interpolate": "^3.0.1"
362
362
  },
363
363
  "peerDependencies": {
364
364
  "@refinitiv-ui/browser-sparkline": "^1.0.0 || ^2.0.0",
365
- "@refinitiv-ui/core": "^7.2.0",
365
+ "@refinitiv-ui/core": "^7.2.1",
366
366
  "@refinitiv-ui/i18n": "^7.0.4",
367
367
  "@refinitiv-ui/phrasebook": "^7.0.4",
368
- "@refinitiv-ui/translate": "^7.0.4",
369
- "@refinitiv-ui/utils": "^7.1.0"
368
+ "@refinitiv-ui/translate": "^7.0.5",
369
+ "@refinitiv-ui/utils": "^7.1.1"
370
370
  },
371
371
  "publishConfig": {
372
372
  "access": "public"
373
373
  },
374
- "gitHead": "4b172b7204c0d71ba30a01777ec1a00d0e35996a"
374
+ "gitHead": "4ba5cbcd3390fba7f3d554afc8886976291c47a2"
375
375
  }