@progressive-development/pd-forms 0.7.14-a → 0.7.14-b

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.
@@ -7,6 +7,7 @@ export declare class PdButtonGroup extends PdBaseUI {
7
7
  private _selectedButtons;
8
8
  static styles: CSSResultGroup;
9
9
  willUpdate(changedProps: PropertyValues<this>): void;
10
+ reset(selectedValue: number): void;
10
11
  render(): import('lit-html').TemplateResult<1>;
11
12
  private onClick;
12
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"pd-button-group.d.ts","sourceRoot":"","sources":["../src/pd-button-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,cAAc,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAEhE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,OAAO,2BAA2B,CAAC;AAEnC,qBACa,aAAc,SAAQ,QAAQ;IAEzC,UAAU,EAAE,UAAU,EAAE,CAAM;IAG9B,SAAS,EAAE,MAAM,EAAE,CAAM;IAGzB,OAAO,CAAC,gBAAgB,CAAgB;IAExC,OAAgB,MAAM,EAAE,cAAc,CA0CpC;IAEO,UAAU,CAAC,YAAY,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAMpD,MAAM;IAkBf,OAAO,CAAC,OAAO;CAYhB"}
1
+ {"version":3,"file":"pd-button-group.d.ts","sourceRoot":"","sources":["../src/pd-button-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,cAAc,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAEhE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAErC,OAAO,2BAA2B,CAAC;AAEnC,qBACa,aAAc,SAAQ,QAAQ;IAEzC,UAAU,EAAE,UAAU,EAAE,CAAM;IAG9B,SAAS,EAAE,MAAM,EAAE,CAAM;IAGzB,OAAO,CAAC,gBAAgB,CAAgB;IAExC,OAAgB,MAAM,EAAE,cAAc,CA0CpC;IAEO,UAAU,CAAC,YAAY,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAWtD,KAAK,CAAC,aAAa,EAAE,MAAM;IAIzB,MAAM;IAkBf,OAAO,CAAC,OAAO;CAYhB"}
@@ -20,10 +20,14 @@ let PdButtonGroup = class extends PdBaseUI {
20
20
  this._selectedButtons = [];
21
21
  }
22
22
  willUpdate(changedProps) {
23
- if (changedProps.has("initValue")) {
23
+ var _a;
24
+ if (changedProps.has("initValue") && ((_a = this.initValue) == null ? void 0 : _a.length) > 0 && this._selectedButtons.length === 0) {
24
25
  this._selectedButtons = [...this.initValue];
25
26
  }
26
27
  }
28
+ reset(selectedValue) {
29
+ this._selectedButtons = [selectedValue];
30
+ }
27
31
  render() {
28
32
  return html`
29
33
  <div class="button-group">
@@ -7,6 +7,7 @@ export declare class PdIconButtonSelectGroup extends PdBaseUI {
7
7
  private _selectedValue;
8
8
  static styles: CSSResultGroup;
9
9
  willUpdate(changedProps: PropertyValues<this>): void;
10
+ reset(selectedValue: number): void;
10
11
  render(): import('lit-html').TemplateResult<1> | "";
11
12
  private handleSelectionChange;
12
13
  }
@@ -1 +1 @@
1
- {"version":3,"file":"pd-icon-button-select-group.d.ts","sourceRoot":"","sources":["../src/pd-icon-button-select-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,cAAc,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAEhE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAExC,OAAO,wBAAwB,CAAC;AAChC,OAAO,mBAAmB,CAAC;AAE3B,qBACa,uBAAwB,SAAQ,QAAQ;IAEnD,OAAO,EAAE,UAAU,EAAE,CAAM;IAG3B,SAAS,EAAE,MAAM,CAAM;IAGvB,OAAO,CAAC,cAAc,CAAU;IAEhC,OAAgB,MAAM,EAAE,cAAc,CAcpC;IAEO,UAAU,CAAC,YAAY,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAMpD,MAAM;IAuBf,OAAO,CAAC,qBAAqB;CAe9B"}
1
+ {"version":3,"file":"pd-icon-button-select-group.d.ts","sourceRoot":"","sources":["../src/pd-icon-button-select-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,cAAc,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAEhE,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AAExC,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAExC,OAAO,wBAAwB,CAAC;AAChC,OAAO,mBAAmB,CAAC;AAE3B,qBACa,uBAAwB,SAAQ,QAAQ;IAEnD,OAAO,EAAE,UAAU,EAAE,CAAM;IAG3B,SAAS,EAAE,MAAM,CAAM;IAGvB,OAAO,CAAC,cAAc,CAAc;IAEpC,OAAgB,MAAM,EAAE,cAAc,CAcpC;IAEO,UAAU,CAAC,YAAY,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAWtD,KAAK,CAAC,aAAa,EAAE,MAAM;IAIzB,MAAM;IAuBf,OAAO,CAAC,qBAAqB;CAe9B"}
@@ -18,12 +18,16 @@ let PdIconButtonSelectGroup = class extends PdBaseUI {
18
18
  super(...arguments);
19
19
  this.options = [];
20
20
  this.initValue = -1;
21
+ this._selectedValue = -1;
21
22
  }
22
23
  willUpdate(changedProps) {
23
- if (changedProps.has("initValue") && this.initValue >= 0) {
24
+ if (changedProps.has("initValue") && this.initValue > 0 && this._selectedValue === -1) {
24
25
  this._selectedValue = this.initValue;
25
26
  }
26
27
  }
28
+ reset(selectedValue) {
29
+ this._selectedValue = selectedValue;
30
+ }
27
31
  render() {
28
32
  if (!this.options || this.options.length === 0) {
29
33
  return "";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progressive-development/pd-forms",
3
- "version": "0.7.14-a",
3
+ "version": "0.7.14-b",
4
4
  "description": "Webcomponent pd-forms for rendering form input elements.",
5
5
  "author": "PD Progressive Development",
6
6
  "license": "SEE LICENSE IN LICENSE",