@refinitiv-ui/efx-grid 6.0.157 → 6.0.158

Sign up to get free protection for your applications and to get access to all the features.
@@ -31,7 +31,10 @@ declare namespace ColumnSelectionDialog {
31
31
  height?: number|null,
32
32
  tags?: (string)[]|null,
33
33
  infoTooltip?: string|null,
34
- searchPlaceholder?: string|null
34
+ searchPlaceholder?: string|null,
35
+ dialogLabel?: string|null,
36
+ availableItemsLabel?: string|null,
37
+ visibleItemsLabel?: string|null
35
38
  };
36
39
 
37
40
  }
@@ -30,6 +30,9 @@ import { isEmptyObject } from "../../tr-grid-util/es6/Util.js";
30
30
  * @property {Array.<string>=} tags=null All available tags for filtering
31
31
  * @property {string=} infoTooltip="" If specified, an informational icon will appear on the top with the given text as its tooltip
32
32
  * @property {string=} searchPlaceholder="Search" Placeholder text inside the search input.
33
+ * @property {string=} dialogLabel="" Dialog's title displayed in the title bar of the dialog.
34
+ * @property {string=} availableItemsLabel="" The title of the available column list on the left pane.
35
+ * @property {string=} visibleItemsLabel="" The title of the visible column list on the right pane.
33
36
  */
34
37
 
35
38
  /** Insert multiple items to the given array. This is an in-place modification.
@@ -581,6 +584,9 @@ class ColumnSelectionDialog extends BasicElement {
581
584
  this._activeTags = null;
582
585
  this._infoTooltip = "";
583
586
  this._searchPlaceholder = "";
587
+ this._dialogLabel = "";
588
+ this._visibleItemsLabel = "";
589
+ this._availableItemsLabel = "";
584
590
 
585
591
  this._allItemMapping = {};
586
592
  this._filterItemMapping = {};
@@ -642,47 +648,48 @@ class ColumnSelectionDialog extends BasicElement {
642
648
  this.data = this.config.data;
643
649
  }
644
650
  }
651
+ var config = this.config;
645
652
  if(!changedProperties.has("visibleItems")) {
646
- var visibleItems = this.config ? this.config.activeItems || this.config.visibleItems : null;
653
+ var visibleItems = config ? config.activeItems || config.visibleItems : null;
647
654
  if(visibleItems) {
648
655
  this.visibleItems = visibleItems;
649
656
  }
650
657
  }
651
658
 
652
- if (this.config) {
659
+ if (config) {
653
660
  // allow config.lang overides default lang
654
- if(this.config.lang) {
655
- this._lang = ElfUtil.toLangString(this.config.lang);
661
+ if(config.lang) {
662
+ this._lang = ElfUtil.toLangString(config.lang);
656
663
  }
657
664
 
658
- if (this.config.confirm) {
659
- this.addEventListener('confirm', this.config.confirm);
665
+ if (config.confirm) {
666
+ this.addEventListener('confirm', config.confirm);
660
667
  }
661
668
 
662
- if (this.config.cancel) {
663
- this.addEventListener('cancel', this.config.cancel);
669
+ if (config.cancel) {
670
+ this.addEventListener('cancel', config.cancel);
664
671
  }
665
672
 
666
- if (this.config.descriptionBox != null) {
667
- this._descriptionBox = !!this.config.descriptionBox;
673
+ if (config.descriptionBox != null) {
674
+ this._descriptionBox = !!config.descriptionBox;
668
675
  }
669
676
 
670
- if (this.config.collapseAll != null) {
671
- this._defaultExpanded = !this.config.collapseAll;
677
+ if (config.collapseAll != null) {
678
+ this._defaultExpanded = !config.collapseAll;
672
679
  }
673
680
 
674
- if (this.config.width != null) {
675
- this._width = this.config.width;
681
+ if (config.width != null) {
682
+ this._width = config.width;
676
683
  } else {
677
684
  this._width = 0;
678
685
  }
679
686
 
680
- if (this.config.height != null) {
681
- this._height = this.config.height;
687
+ if (config.height != null) {
688
+ this._height = config.height;
682
689
  } else {
683
690
  this._height = 0;
684
691
  }
685
- var userTags = this.config.tags;
692
+ var userTags = config.tags;
686
693
  if (userTags != null) {
687
694
  this._activeTags = null; // All existing active tags must be removed
688
695
  if(Array.isArray(userTags) && userTags.length) {
@@ -695,14 +702,18 @@ class ColumnSelectionDialog extends BasicElement {
695
702
  this._tagDefs = null;
696
703
  }
697
704
  }
698
- if(this.config.infoTooltip != null) {
699
- this._infoTooltip = this.config.infoTooltip ? this.config.infoTooltip : "";
705
+ if(config.infoTooltip != null) {
706
+ this._infoTooltip = config.infoTooltip ? config.infoTooltip : "";
700
707
  }
701
- if(this.config.searchPlaceholder != null) {
702
- this._searchPlaceholder = this.config.searchPlaceholder ? this.config.searchPlaceholder : "";
708
+ if(config.searchPlaceholder != null) {
709
+ this._searchPlaceholder = config.searchPlaceholder ? config.searchPlaceholder : "";
703
710
  }
704
711
 
705
- this._defaultItems = this.config.defaultItems;
712
+ this._defaultItems = config.defaultItems;
713
+
714
+ this._dialogLabel = config.dialogLabel != null ? config.dialogLabel : "";
715
+ this._availableItemsLabel = config.availableItemsLabel != null ? config.availableItemsLabel : "";
716
+ this._visibleItemsLabel = config.visibleItemsLabel != null ? config.visibleItemsLabel : "";
706
717
  }
707
718
  }
708
719
 
@@ -728,11 +739,11 @@ class ColumnSelectionDialog extends BasicElement {
728
739
 
729
740
  /* eslint-disable */
730
741
  return html`
731
- <ef-dialog header="${t["Column Selection"]}" id="columnDialog" lang="${lang}">
742
+ <ef-dialog header="${this._dialogLabel ? this._dialogLabel : t["Column Selection"]}" id="columnDialog" lang="${lang}">
732
743
  <div class="container">
733
744
  <div class="row">
734
745
  <div class="side">
735
- <label class="title">${t["Add / Remove Columns"]}
746
+ <label class="title">${this._availableItemsLabel ? this._availableItemsLabel : t["Add / Remove Columns"]}
736
747
  ${this._infoTooltip ? html`<ef-icon icon="info" id="info_icon" title="${this._infoTooltip}"></ef-icon>` : ""}
737
748
  </label>
738
749
  </div>
@@ -743,7 +754,7 @@ class ColumnSelectionDialog extends BasicElement {
743
754
  <ef-search-field aria-label="search for columns" placeholder="${this._searchPlaceholder ? this._searchPlaceholder : t["Search"]}" id="searchInput"></ef-search-field>
744
755
  </div>
745
756
  <div class="side">
746
- <label>${t["Show in this order"]}</label>
757
+ <label>${this._visibleItemsLabel ? this._visibleItemsLabel : t["Show in this order"]}</label>
747
758
  </div>
748
759
  </div>
749
760
  <div class="row" id='listSection'>
package/lib/grid/index.js CHANGED
@@ -1,3 +1,3 @@
1
1
  import {Grid} from "./lib/efx-grid.js";
2
2
  export {Grid}
3
- window.EFX_GRID = { version: "6.0.157" };
3
+ window.EFX_GRID = { version: "6.0.158" };
package/lib/versions.json CHANGED
@@ -31,7 +31,7 @@
31
31
  "tr-grid-textformatting": "1.0.49",
32
32
  "tr-grid-titlewrap": "1.0.22",
33
33
  "@grid/formatters": "1.0.56",
34
- "@grid/column-selection-dialog": "4.0.59",
34
+ "@grid/column-selection-dialog": "4.0.61",
35
35
  "@grid/filter-dialog": "4.0.79",
36
36
  "@grid/column-format-dialog": "4.0.45"
37
37
  }
package/package.json CHANGED
@@ -69,5 +69,5 @@
69
69
  "publishConfig": {
70
70
  "access": "public"
71
71
  },
72
- "version": "6.0.157"
72
+ "version": "6.0.158"
73
73
  }