gd-bs 6.6.29 → 6.6.31

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.
@@ -82,8 +82,19 @@ var _CheckboxGroup = /** @class */ (function (_super) {
82
82
  }
83
83
  // Render the checkboxes
84
84
  this.renderItems();
85
- // Set the value
86
- this.setValue(this.props.value);
85
+ // Parse the items
86
+ var valueSet = false;
87
+ var items = this.props.items || [];
88
+ for (var i = 0; i < items.length; i++) {
89
+ // See if the item is using the isSelected property
90
+ if (typeof (items[i].isSelected) === "boolean") {
91
+ // Set the flag
92
+ valueSet = true;
93
+ break;
94
+ }
95
+ }
96
+ // Set the value if we need to
97
+ valueSet ? null : this.setValue(this.props.value);
87
98
  };
88
99
  // Configure the events
89
100
  _CheckboxGroup.prototype.configureEvents = function (item) {
@@ -94,6 +94,15 @@ var _Navbar = /** @class */ (function (_super) {
94
94
  _Navbar.prototype.configureEvents = function () {
95
95
  var _this = this;
96
96
  var props = this.props.searchBox || {};
97
+ // See if the brand element and click event exist
98
+ var brand = this.el.querySelector(".navbar-brand");
99
+ if (brand && this.props.onClickBrand) {
100
+ // Set the click event
101
+ brand.addEventListener("click", function (ev) {
102
+ // Call the event
103
+ _this.props.onClickBrand(brand, ev);
104
+ });
105
+ }
97
106
  // See if search events exist
98
107
  var searchbox = this.el.querySelector("form input");
99
108
  if (searchbox) {