@public-ui/hydrate 1.7.4 → 1.7.5

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.
Files changed (2) hide show
  1. package/dist/index.js +19 -17
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -7810,7 +7810,7 @@ const initKoliBri = () => {
7810
7810
  | . ' | .-. | | | ,--. | .-. \\ | .--' ,--.
7811
7811
  | |\\ \\ | '-' | | | | | | '--' / | | | |
7812
7812
  \`--' \`--´ \`---´ \`--' \`--' \`------´ \`--' \`--'
7813
- 🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | 1.7.4
7813
+ 🚹 The accessible HTML-Standard | 👉 https://public-ui.github.io | 1.7.5
7814
7814
  `, {
7815
7815
  forceLog: true,
7816
7816
  });
@@ -10151,6 +10151,9 @@ class KolAccordion {
10151
10151
  constructor(hostRef) {
10152
10152
  registerInstance(this, hostRef);
10153
10153
  this.nonce = nonce();
10154
+ this.catchRef = (ref) => {
10155
+ propagateFocus(this.host, ref);
10156
+ };
10154
10157
  this.onClick = (event) => {
10155
10158
  this._open = !this._open;
10156
10159
  setTimeout(() => {
@@ -10174,7 +10177,7 @@ class KolAccordion {
10174
10177
  return (hAsync(Host, null, hAsync("div", { class: {
10175
10178
  accordion: true,
10176
10179
  open: this.state._open === true,
10177
- } }, hAsync("kol-heading-wc", { _label: "", _level: this.state._level }, hAsync("kol-button-wc", { _ariaControls: this.nonce, _ariaExpanded: this.state._open, _icons: this.state._open ? 'codicon codicon-remove' : 'codicon codicon-add', _label: this.state._label, _on: { onClick: this.onClick } })), hAsync("div", { class: "header" }, hAsync("slot", { name: "header" })), hAsync("div", { class: "wrapper" }, hAsync("div", { class: "animation-wrapper" }, hAsync("div", { "aria-hidden": this.state._open === false ? 'true' : undefined, class: "content", id: this.nonce }, hAsync("slot", { name: "content" }), " ", hAsync("slot", null)))))));
10180
+ } }, hAsync("kol-heading-wc", { _label: "", _level: this.state._level }, hAsync("kol-button-wc", { ref: this.catchRef, slot: "expert", _ariaControls: this.nonce, _ariaExpanded: this.state._open, _icons: this.state._open ? 'codicon codicon-remove' : 'codicon codicon-add', _label: this.state._label, _on: { onClick: this.onClick } })), hAsync("div", { class: "header" }, hAsync("slot", { name: "header" })), hAsync("div", { class: "wrapper" }, hAsync("div", { class: "animation-wrapper" }, hAsync("div", { "aria-hidden": this.state._open === false ? 'true' : undefined, class: "content", id: this.nonce }, hAsync("slot", { name: "content" }), " ", hAsync("slot", null)))))));
10178
10181
  }
10179
10182
  validateHeading(value) {
10180
10183
  this.validateLabel(value);
@@ -10199,6 +10202,7 @@ class KolAccordion {
10199
10202
  this.validateOn(this._on);
10200
10203
  this.validateOpen(this._open);
10201
10204
  }
10205
+ get host() { return getElement(this); }
10202
10206
  static get watchers() { return {
10203
10207
  "_heading": ["validateHeading"],
10204
10208
  "_label": ["validateLabel"],
@@ -11298,8 +11302,7 @@ class KolButton {
11298
11302
  constructor(hostRef) {
11299
11303
  registerInstance(this, hostRef);
11300
11304
  this.catchRef = (ref) => {
11301
- this.ref = ref;
11302
- propagateFocus(this.host, this.ref);
11305
+ propagateFocus(this.host, ref);
11303
11306
  };
11304
11307
  this._accessKey = undefined;
11305
11308
  this._ariaControls = undefined;
@@ -11420,8 +11423,7 @@ class KolButtonLink {
11420
11423
  constructor(hostRef) {
11421
11424
  registerInstance(this, hostRef);
11422
11425
  this.catchRef = (ref) => {
11423
- this.ref = ref;
11424
- propagateFocus(this.host, this.ref);
11426
+ propagateFocus(this.host, ref);
11425
11427
  };
11426
11428
  this._accessKey = undefined;
11427
11429
  this._ariaControls = undefined;
@@ -12318,6 +12320,10 @@ const defaultStyleCss$z = "/*!@:host*/.sc-kol-details-default-h{--a11y-min-size:
12318
12320
  class KolDetails {
12319
12321
  constructor(hostRef) {
12320
12322
  registerInstance(this, hostRef);
12323
+ this.catchRef = (ref) => {
12324
+ this.summaryElement = ref;
12325
+ propagateFocus(this.host, this.summaryElement);
12326
+ };
12321
12327
  this.handleToggle = (event) => {
12322
12328
  clearTimeout(this.toggleTimeout);
12323
12329
  this.toggleTimeout = setTimeout(() => {
@@ -12344,7 +12350,7 @@ class KolDetails {
12344
12350
  render() {
12345
12351
  return (hAsync(Host, null, hAsync("details", { ref: (el) => {
12346
12352
  this.detailsElement = el;
12347
- }, onToggle: this.handleToggle }, hAsync("summary", { ref: (element) => (this.summaryElement = element) }, this.state._open ? hAsync("kol-icon", { _label: "", _icons: "codicon codicon-chevron-down" }) : hAsync("kol-icon", { _label: "", _icons: "codicon codicon-chevron-right" }), hAsync("span", null, this.state._label)), hAsync("div", { class: "content", ref: (element) => (this.contentElement = element) }, hAsync("kol-indented-text", null, hAsync("slot", null))))));
12353
+ }, onToggle: this.handleToggle }, hAsync("summary", { ref: this.catchRef }, this.state._open ? hAsync("kol-icon", { _label: "", _icons: "codicon codicon-chevron-down" }) : hAsync("kol-icon", { _label: "", _icons: "codicon codicon-chevron-right" }), hAsync("span", null, this.state._label)), hAsync("div", { "aria-hidden": this.state._open === false ? 'true' : undefined, class: "content", ref: (element) => (this.contentElement = element) }, hAsync("kol-indented-text", null, hAsync("slot", null))))));
12348
12354
  }
12349
12355
  validateLabel(value) {
12350
12356
  validateLabel(this, value);
@@ -12695,7 +12701,7 @@ function validateLoading(component, value) {
12695
12701
  watchValidator(component, '_loading', (value) => value === 'eager' || value === 'lazy', AVAILABLE_LOADING_VALUES, value);
12696
12702
  }
12697
12703
 
12698
- const defaultStyleCss$w = "/*!@img*/img.sc-kol-image-default{max-height:100%;max-width:100%}";
12704
+ const defaultStyleCss$w = "/*!@:host*/.sc-kol-image-default-h{display:inline-block}/*!@img*/img.sc-kol-image-default{max-height:100%;max-width:100%}";
12699
12705
 
12700
12706
  class KolImage {
12701
12707
  constructor(hostRef) {
@@ -13304,13 +13310,12 @@ class KolInputCheckbox {
13304
13310
  [this.state._variant]: true,
13305
13311
  'hide-label': !!this.state._hideLabel,
13306
13312
  checked: this.state._checked,
13307
- }, "data-role": this.state._variant === 'button' ? 'button' : undefined, onKeyPress: this.state._variant === 'button' ? this.onChange : undefined, tabIndex: this.state._variant === 'button' ? 0 : undefined, _alert: this.state._alert, _disabled: this.state._disabled, _error: this.state._error, _hideError: this.state._hideError, _hideLabel: this.state._hideLabel, _hint: this.state._hint, _id: this.state._id, _label: this.state._label, _required: this.state._required, _tooltipAlign: this._tooltipAlign, _touched: this.state._touched }, hAsync("span", { slot: "label" }, hasExpertSlot ? hAsync("slot", null) : this.state._label), hAsync("div", { slot: "input" }, hAsync("kol-icon", { class: "icon", onClick: this.handleIconClick.bind(this), _icons: this.state._indeterminate ? this.state._icons.indeterminate : this.state._checked ? this.state._icons.checked : this.state._icons.unchecked, _label: "" }), hAsync("input", Object.assign({ ref: this.catchRef, title: "", accessKey: this.state._accessKey, "aria-describedby": ariaDescribedBy.length > 0 ? ariaDescribedBy.join(' ') : undefined, "aria-label": this.state._hideLabel && typeof this.state._label === 'string' ? this.state._label : undefined, checked: this.state._checked, disabled: this.state._disabled, id: this.state._id, indeterminate: this.state._indeterminate, name: this.state._name, required: this.state._required, tabIndex: this.state._tabIndex, type: "checkbox" }, this.controller.onFacade, { onChange: this.onChange, onClick: undefined }))))));
13313
+ }, "data-role": this.state._variant === 'button' ? 'button' : undefined, onKeyPress: this.state._variant === 'button' ? this.onChange : undefined, tabIndex: this.state._variant === 'button' && !this.state._disabled ? 0 : undefined, _alert: this.state._alert, _disabled: this.state._disabled, _error: this.state._error, _hideError: this.state._hideError, _hideLabel: this.state._hideLabel, _hint: this.state._hint, _id: this.state._id, _label: this.state._label, _required: this.state._required, _tooltipAlign: this._tooltipAlign, _touched: this.state._touched }, hAsync("span", { slot: "label" }, hasExpertSlot ? hAsync("slot", null) : this.state._label), hAsync("div", { slot: "input" }, hAsync("kol-icon", { class: "icon", onClick: this.handleIconClick.bind(this), _icons: this.state._indeterminate ? this.state._icons.indeterminate : this.state._checked ? this.state._icons.checked : this.state._icons.unchecked, _label: "" }), hAsync("input", Object.assign({ ref: this.catchRef, title: "", accessKey: this.state._accessKey, "aria-describedby": ariaDescribedBy.length > 0 ? ariaDescribedBy.join(' ') : undefined, "aria-label": this.state._hideLabel && typeof this.state._label === 'string' ? this.state._label : undefined, checked: this.state._checked, disabled: this.state._disabled, id: this.state._id, indeterminate: this.state._indeterminate, name: this.state._name, required: this.state._required, tabIndex: this.state._tabIndex, type: "checkbox" }, this.controller.onFacade, { onChange: this.onChange, onClick: undefined }))))));
13308
13314
  }
13309
13315
  constructor(hostRef) {
13310
13316
  registerInstance(this, hostRef);
13311
13317
  this.catchRef = (ref) => {
13312
- this.ref = ref;
13313
- propagateFocus(this.host, this.ref);
13318
+ propagateFocus(this.host, ref);
13314
13319
  };
13315
13320
  this.onChange = (event) => {
13316
13321
  var _a;
@@ -15369,8 +15374,7 @@ class KolInputRadio {
15369
15374
  constructor(hostRef) {
15370
15375
  registerInstance(this, hostRef);
15371
15376
  this.catchRef = (ref) => {
15372
- this.ref = ref;
15373
- propagateFocus(this.host, this.ref);
15377
+ propagateFocus(this.host, ref);
15374
15378
  };
15375
15379
  this.onChange = (event) => {
15376
15380
  var _a;
@@ -16236,8 +16240,7 @@ class KolLink {
16236
16240
  constructor(hostRef) {
16237
16241
  registerInstance(this, hostRef);
16238
16242
  this.catchRef = (ref) => {
16239
- this.ref = ref;
16240
- propagateFocus(this.host, this.ref);
16243
+ propagateFocus(this.host, ref);
16241
16244
  };
16242
16245
  this._ariaControls = undefined;
16243
16246
  this._ariaCurrent = undefined;
@@ -16312,8 +16315,7 @@ class KolLinkButton {
16312
16315
  constructor(hostRef) {
16313
16316
  registerInstance(this, hostRef);
16314
16317
  this.catchRef = (ref) => {
16315
- this.ref = ref;
16316
- propagateFocus(this.host, this.ref);
16318
+ propagateFocus(this.host, ref);
16317
16319
  };
16318
16320
  this._ariaControls = undefined;
16319
16321
  this._ariaCurrent = undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@public-ui/hydrate",
3
- "version": "1.7.4",
3
+ "version": "1.7.5",
4
4
  "license": "EUPL-1.2",
5
5
  "homepage": "https://public-ui.github.io",
6
6
  "repository": "https://github.com/public-ui/kolibri",
@@ -42,11 +42,11 @@
42
42
  "hydrate"
43
43
  ],
44
44
  "devDependencies": {
45
- "@public-ui/components": "1.7.4",
45
+ "@public-ui/components": "1.7.5",
46
46
  "rimraf": "3.0.2"
47
47
  },
48
48
  "peerDependencies": {
49
- "@public-ui/components": "1.7.4"
49
+ "@public-ui/components": "1.7.5"
50
50
  },
51
51
  "sideEffects": false,
52
52
  "type": "commonjs",