@govtechsg/sgds-web-component 3.1.0-rc.2 → 3.1.0-rc.4

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.
@@ -5145,6 +5145,15 @@
5145
5145
  this._isTouched = true;
5146
5146
  });
5147
5147
  }
5148
+ firstUpdated(changedProperties) {
5149
+ super.firstUpdated(changedProperties);
5150
+ if (this.value) {
5151
+ this._updateInputValue();
5152
+ }
5153
+ console.log(this.input, "adding this to check checkbox group input");
5154
+ console.log(this.input.validity, "adding this to check checkbox group input");
5155
+ console.log(this.inputValidationController, "inputValidtionController");
5156
+ }
5148
5157
  _renderHintText() {
5149
5158
  const hintTextTemplate = html ` <div class="form-text">${this.hintText}</div> `;
5150
5159
  return this.hintText && hintTextTemplate;
@@ -5238,12 +5247,6 @@
5238
5247
  this.input.value = this.value;
5239
5248
  this.input.dispatchEvent(new InputEvent(eventName));
5240
5249
  }
5241
- firstUpdated(changedProperties) {
5242
- super.firstUpdated(changedProperties);
5243
- if (this.value) {
5244
- this._updateInputValue();
5245
- }
5246
- }
5247
5250
  render() {
5248
5251
  return html `
5249
5252
  <fieldset>
@@ -5256,9 +5259,7 @@
5256
5259
  </div>
5257
5260
  <input
5258
5261
  type="text"
5259
- class="checkbox-group-validation-input ${classMap({
5260
- "is-invalid": this.hasFeedback && this.invalid
5261
- })}"
5262
+ class="checkbox-group-validation-input"
5262
5263
  ?required=${this.required}
5263
5264
  tabindex="-1"
5264
5265
  @change=${(e) => {
@@ -5278,7 +5279,7 @@
5278
5279
  </svg>
5279
5280
  </slot>
5280
5281
  <div id="checkbox-feedback" tabindex="0" class="invalid-feedback">
5281
- ${this.invalidFeedback ? this.invalidFeedback : this.validationMessage}
5282
+ ${this.invalidFeedback ? this.invalidFeedback : this.input.validationMessage}
5282
5283
  </div>
5283
5284
  </div>
5284
5285
  `
@@ -5288,12 +5289,6 @@
5288
5289
  }
5289
5290
  }
5290
5291
  SgdsCheckboxGroup.styles = [...SgdsElement.styles, css_248z$6, css_248z$4, css_248z, css_248z$5];
5291
- __decorate([
5292
- queryAssignedElements({ flatten: true })
5293
- ], SgdsCheckboxGroup.prototype, "checkboxes", void 0);
5294
- __decorate([
5295
- queryAsync("slot")
5296
- ], SgdsCheckboxGroup.prototype, "checkboxesAsync", void 0);
5297
5292
  __decorate([
5298
5293
  property({ reflect: true })
5299
5294
  ], SgdsCheckboxGroup.prototype, "label", void 0);
@@ -5310,7 +5305,7 @@
5310
5305
  property({ type: Boolean, reflect: true })
5311
5306
  ], SgdsCheckboxGroup.prototype, "required", void 0);
5312
5307
  __decorate([
5313
- property({ type: String, reflect: true })
5308
+ property({ reflect: true })
5314
5309
  ], SgdsCheckboxGroup.prototype, "value", void 0);
5315
5310
  __decorate([
5316
5311
  state()