@limetech/lime-elements 34.1.1-next.5 → 34.2.0-next.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.
Files changed (41) hide show
  1. package/dist/cjs/{checkbox.template-d4a3aa82.js → checkbox.template-50eb8b76.js} +7 -1
  2. package/dist/cjs/lime-elements.cjs.js +1 -1
  3. package/dist/cjs/limel-checkbox.cjs.entry.js +23 -9
  4. package/dist/cjs/limel-list_3.cjs.entry.js +2 -2
  5. package/dist/cjs/limel-menu-list.cjs.entry.js +2 -2
  6. package/dist/cjs/limel-tooltip_2.cjs.entry.js +20 -4
  7. package/dist/cjs/loader.cjs.js +1 -1
  8. package/dist/collection/components/checkbox/checkbox.css +6 -3
  9. package/dist/collection/components/checkbox/checkbox.js +43 -8
  10. package/dist/collection/components/checkbox/checkbox.template.js +7 -1
  11. package/dist/collection/components/list/list.css +13 -10
  12. package/dist/collection/components/menu/menu.js +2 -1
  13. package/dist/collection/components/menu-list/menu-list-renderer.js +1 -1
  14. package/dist/collection/components/menu-list/menu-list.css +16 -10
  15. package/dist/collection/components/tooltip/tooltip-content.css +18 -3
  16. package/dist/collection/components/tooltip/tooltip-content.js +35 -6
  17. package/dist/collection/components/tooltip/tooltip.js +37 -11
  18. package/dist/esm/{checkbox.template-652ef73b.js → checkbox.template-50f7c07b.js} +7 -1
  19. package/dist/esm/lime-elements.js +1 -1
  20. package/dist/esm/limel-checkbox.entry.js +23 -9
  21. package/dist/esm/limel-list_3.entry.js +2 -2
  22. package/dist/esm/limel-menu-list.entry.js +2 -2
  23. package/dist/esm/limel-tooltip_2.entry.js +20 -4
  24. package/dist/esm/loader.js +1 -1
  25. package/dist/lime-elements/lime-elements.esm.js +1 -1
  26. package/dist/lime-elements/p-050e8972.entry.js +82 -0
  27. package/dist/lime-elements/{p-06b2048f.entry.js → p-1652d3ca.entry.js} +1 -1
  28. package/dist/lime-elements/p-250f55be.js +1 -0
  29. package/dist/lime-elements/p-80cc0936.entry.js +73 -0
  30. package/dist/lime-elements/p-dfe0a58b.entry.js +1 -0
  31. package/dist/types/components/checkbox/checkbox.d.ts +6 -1
  32. package/dist/types/components/checkbox/checkbox.template.d.ts +1 -0
  33. package/dist/types/components/menu/menu.d.ts +2 -1
  34. package/dist/types/components/tooltip/tooltip-content.d.ts +7 -5
  35. package/dist/types/components/tooltip/tooltip.d.ts +12 -5
  36. package/dist/types/components.d.ts +31 -7
  37. package/package.json +1 -1
  38. package/dist/lime-elements/p-044d8b31.entry.js +0 -73
  39. package/dist/lime-elements/p-11f6d111.js +0 -1
  40. package/dist/lime-elements/p-4b80e3df.entry.js +0 -82
  41. package/dist/lime-elements/p-4bc5d3fc.entry.js +0 -1
@@ -7,9 +7,15 @@ const randomString = require('./random-string-4c3b7f1c.js');
7
7
 
8
8
  const tooltipCss = ".trigger-anchor{position:relative}";
9
9
 
10
+ const DEFAULT_MAX_LENGTH = 50;
10
11
  let Tooltip = class {
11
12
  constructor(hostRef) {
12
13
  index.registerInstance(this, hostRef);
14
+ /**
15
+ * The maximum amount of characters before rendering 'label' and
16
+ * 'helperLabel' in two rows.
17
+ */
18
+ this.maxlength = DEFAULT_MAX_LENGTH;
13
19
  this.showTooltip = () => {
14
20
  const tooltipDelay = 500;
15
21
  this.showTooltipTimeoutHandle = window.setTimeout(() => {
@@ -35,7 +41,7 @@ let Tooltip = class {
35
41
  return (index.h("div", { class: "trigger-anchor" }, index.h("limel-portal", { visible: this.open, containerId: this.portalId, containerStyle: {
36
42
  'z-index': tooltipZIndex,
37
43
  'pointer-events': 'none',
38
- } }, index.h("limel-tooltip-content", { label: this.label, helperLabel: this.helperLabel, role: "tooltip", "aria-hidden": !this.open, id: this.tooltipId }))));
44
+ } }, index.h("limel-tooltip-content", { label: this.label, helperLabel: this.helperLabel, maxlength: this.maxlength, role: "tooltip", "aria-hidden": !this.open, id: this.tooltipId }))));
39
45
  }
40
46
  setOwnerAriaLabel() {
41
47
  const owner = this.getOwnerElement();
@@ -67,16 +73,26 @@ let Tooltip = class {
67
73
  };
68
74
  Tooltip.style = tooltipCss;
69
75
 
70
- const tooltipContentCss = ":host{animation:display-tooltip 0.2s ease;display:flex;flex-direction:row;border-radius:0.25rem;padding:0.25rem 0.5rem;font-size:0.875rem;background-color:rgb(var(--contrast-1300));box-shadow:var(--shadow-depth-16)}.label{color:rgb(var(--contrast-200))}.helper-label{color:rgb(var(--contrast-800));padding:0 0 0 1rem}.helper-label:empty{display:none}@keyframes display-tooltip{0%{opacity:0;transform:translate3d(0, 0, 0) scale(0.94)}100%{opacity:1;transform:translate3d(0, 0, 0) scale(1)}}";
76
+ const tooltipContentCss = ":host{animation:display-tooltip 0.2s ease;display:flex;border-radius:0.25rem;padding:0.25rem 0.5rem;background-color:rgb(var(--contrast-1300));box-shadow:var(--shadow-depth-16)}text{font-size:0.875rem;line-height:1.25;display:flex;column-gap:1rem}text.has-column-layout{display:table-cell;width:fit-content;max-width:min(var(--tooltip-max-width-of-text), 80vw)}text.has-column-layout .label{padding-bottom:0.5rem}text.has-column-layout .helper-label{padding-bottom:0.25rem}.label{color:rgb(var(--contrast-200))}.helper-label{color:rgb(var(--contrast-800))}.helper-label:empty{display:none}@keyframes display-tooltip{0%{opacity:0;transform:translate3d(0, 0, 0) scale(0.94)}100%{opacity:1;transform:translate3d(0, 0, 0) scale(1)}}";
71
77
 
72
78
  let TooltipContent = class {
73
79
  constructor(hostRef) {
74
80
  index.registerInstance(this, hostRef);
75
81
  }
76
82
  render() {
83
+ let isLabelsTextLong = false;
84
+ if (this.helperLabel && this.maxlength) {
85
+ isLabelsTextLong =
86
+ this.label.length + this.helperLabel.length > this.maxlength;
87
+ }
88
+ const props = {};
89
+ if (this.maxlength) {
90
+ props.style = {
91
+ '--tooltip-max-width-of-text': `${this.maxlength}` + 'ch',
92
+ };
93
+ }
77
94
  return [
78
- index.h("div", { class: "label" }, this.label),
79
- index.h("div", { class: "helper-label" }, this.helperLabel),
95
+ index.h("text", Object.assign({ class: { 'has-column-layout': isLabelsTextLong } }, props), index.h("div", { class: "label" }, this.label), index.h("div", { class: "helper-label" }, this.helperLabel)),
80
96
  ];
81
97
  }
82
98
  };
@@ -14,7 +14,7 @@ const patchEsm = () => {
14
14
  const defineCustomElements = (win, options) => {
15
15
  if (typeof window === 'undefined') return Promise.resolve();
16
16
  return patchEsm().then(() => {
17
- return index.bootstrapLazy([["limel-color-picker.cjs",[[1,"limel-color-picker",{"value":[513],"label":[513],"helperText":[513,"helper-text"],"tooltipLabel":[513,"tooltip-label"],"required":[516],"readonly":[516],"isOpen":[32]}]]],["limel-picker.cjs",[[1,"limel-picker",{"disabled":[4],"readonly":[516],"label":[1],"searchLabel":[1,"search-label"],"helperText":[513,"helper-text"],"leadingIcon":[1,"leading-icon"],"emptyResultMessage":[1,"empty-result-message"],"required":[4],"value":[16],"searcher":[16],"multiple":[4],"delimiter":[513],"actions":[16],"actionPosition":[1,"action-position"],"actionScrollBehavior":[1,"action-scroll-behavior"],"badgeIcons":[516,"badge-icons"],"items":[32],"textValue":[32],"loading":[32],"chips":[32]}]]],["limel-date-picker.cjs",[[1,"limel-date-picker",{"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"helperText":[513,"helper-text"],"required":[516],"value":[16],"type":[513],"format":[513],"language":[513],"formattedValue":[32],"internalFormat":[32],"showPortal":[32]}]]],["limel-button-group.cjs",[[1,"limel-button-group",{"value":[16],"disabled":[516],"selectedButtonId":[32]}]]],["limel-select.cjs",[[1,"limel-select",{"disabled":[516],"readonly":[516],"invalid":[516],"required":[516],"label":[513],"helperText":[513,"helper-text"],"value":[16],"options":[16],"multiple":[4],"menuOpen":[32]}]]],["limel-tab-panel.cjs",[[1,"limel-tab-panel",{"tabs":[1040]}]]],["limel-file.cjs",[[1,"limel-file",{"value":[16],"label":[513],"required":[516],"disabled":[516],"readonly":[516],"accept":[513],"language":[1],"isDraggingOverDropZone":[32]}]]],["limel-menu.cjs",[[1,"limel-menu",{"items":[16],"disabled":[516],"openDirection":[513,"open-direction"],"open":[1540],"badgeIcons":[516,"badge-icons"],"gridLayout":[516,"grid-layout"]}]]],["limel-button.cjs",[[1,"limel-button",{"label":[513],"primary":[516],"outlined":[516],"icon":[513],"disabled":[516],"loading":[516]}]]],["limel-collapsible-section.cjs",[[1,"limel-collapsible-section",{"isOpen":[1540,"is-open"],"header":[513],"actions":[16]}]]],["limel-dialog.cjs",[[1,"limel-dialog",{"heading":[1],"fullscreen":[516],"open":[1540],"closingActions":[16]}]]],["limel-progress-flow.cjs",[[1,"limel-progress-flow",{"flowItems":[16],"disabled":[4],"readonly":[4]}]]],["limel-banner.cjs",[[1,"limel-banner",{"message":[513],"icon":[513],"isOpen":[32],"open":[64],"close":[64]}]]],["limel-table.cjs",[[1,"limel-table",{"data":[16],"columns":[16],"mode":[1],"pageSize":[2,"page-size"],"totalRows":[2,"total-rows"],"sorting":[16],"activeRow":[1040],"movableColumns":[4,"movable-columns"],"loading":[4],"page":[2],"emptyMessage":[1,"empty-message"]}]]],["limel-checkbox.cjs",[[1,"limel-checkbox",{"disabled":[516],"readonly":[516],"label":[513],"helperText":[513,"helper-text"],"checked":[516],"required":[516],"modified":[32]}]]],["limel-circular-progress.cjs",[[1,"limel-circular-progress",{"value":[2],"maxValue":[2,"max-value"],"suffix":[1],"displayPercentageColors":[4,"display-percentage-colors"],"size":[513]}]]],["limel-code-editor.cjs",[[1,"limel-code-editor",{"value":[1],"language":[1],"readonly":[4],"lineNumbers":[4,"line-numbers"],"colorScheme":[1,"color-scheme"],"random":[32]}]]],["limel-config.cjs",[[1,"limel-config",{"config":[16]}]]],["limel-flex-container.cjs",[[1,"limel-flex-container",{"direction":[513],"justify":[513],"align":[513],"reverse":[516]}]]],["limel-form.cjs",[[1,"limel-form",{"schema":[16],"value":[16],"disabled":[4],"propsFactory":[16],"transformErrors":[16]}]]],["limel-grid.cjs",[[1,"limel-grid"]]],["limel-linear-progress.cjs",[[1,"limel-linear-progress",{"value":[2],"indeterminate":[4]}]]],["limel-slider.cjs",[[1,"limel-slider",{"disabled":[516],"readonly":[516],"factor":[514],"label":[513],"helperText":[513,"helper-text"],"unit":[513],"value":[514],"valuemax":[514],"valuemin":[514],"step":[514],"percentageClass":[32]}]]],["limel-snackbar.cjs",[[1,"limel-snackbar",{"message":[1],"timeout":[2],"actionText":[1,"action-text"],"dismissible":[4],"multiline":[4],"language":[1],"show":[64]}]]],["limel-switch.cjs",[[1,"limel-switch",{"label":[513],"disabled":[516],"readonly":[516],"value":[516],"fieldId":[32]}]]],["limel-tab-bar.cjs",[[1,"limel-tab-bar",{"tabs":[1040],"canScrollLeft":[32],"canScrollRight":[32]},[[9,"resize","handleWindowResize"]]]]],["limel-header.cjs",[[1,"limel-header",{"icon":[1],"heading":[1],"subheading":[1],"supportingText":[1,"supporting-text"]}]]],["limel-progress-flow-item.cjs",[[0,"limel-progress-flow-item",{"item":[16],"disabled":[4],"readonly":[4]}]]],["limel-flatpickr-adapter.cjs",[[1,"limel-flatpickr-adapter",{"value":[16],"type":[1],"format":[1],"isOpen":[4,"is-open"],"inputElement":[16],"language":[1]}]]],["limel-menu-list.cjs",[[1,"limel-menu-list",{"items":[16],"badgeIcons":[4,"badge-icons"],"iconSize":[1,"icon-size"],"type":[1],"maxLinesSecondaryText":[2,"max-lines-secondary-text"]}]]],["limel-popover-surface.cjs",[[1,"limel-popover-surface",{"contentCollection":[16]}]]],["limel-icon.cjs",[[1,"limel-icon",{"size":[513],"name":[513],"badge":[516]}]]],["limel-input-field.cjs",[[1,"limel-input-field",{"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"helperText":[513,"helper-text"],"required":[516],"value":[513],"trailingIcon":[513,"trailing-icon"],"leadingIcon":[513,"leading-icon"],"pattern":[513],"type":[513],"formatNumber":[516,"format-number"],"step":[520],"max":[514],"min":[514],"maxlength":[514],"minlength":[514],"completions":[16],"showLink":[516,"show-link"],"isFocused":[32],"isModified":[32],"showCompletions":[32]}]]],["limel-color-picker-palette_2.cjs",[[1,"limel-color-picker-palette",{"value":[513],"label":[513],"helperText":[513,"helper-text"],"required":[516]}],[1,"limel-popover",{"open":[4]}]]],["limel-badge.cjs",[[1,"limel-badge",{"label":[514]}]]],["limel-chip-set.cjs",[[1,"limel-chip-set",{"value":[16],"type":[513],"label":[513],"helperText":[513,"helper-text"],"disabled":[516],"readonly":[516],"maxItems":[514,"max-items"],"required":[516],"searchLabel":[513,"search-label"],"emptyInputOnBlur":[516,"empty-input-on-blur"],"clearAllButton":[4,"clear-all-button"],"leadingIcon":[513,"leading-icon"],"delimiter":[513],"language":[1],"editMode":[32],"textValue":[32],"blurred":[32],"inputChipIndexSelected":[32],"getEditMode":[64],"setFocus":[64],"emptyInput":[64]}]]],["limel-icon-button.cjs",[[1,"limel-icon-button",{"icon":[513],"elevated":[516],"label":[513],"disabled":[516],"relayout":[64]}]]],["limel-spinner.cjs",[[1,"limel-spinner",{"size":[513],"limeBranded":[4,"lime-branded"]}]]],["limel-list_3.cjs",[[1,"limel-list",{"items":[16],"badgeIcons":[4,"badge-icons"],"iconSize":[1,"icon-size"],"type":[1],"maxLinesSecondaryText":[2,"max-lines-secondary-text"]}],[1,"limel-menu-surface",{"open":[4],"allowClicksElement":[16]}],[1,"limel-portal",{"openDirection":[1,"open-direction"],"position":[1],"containerId":[1,"container-id"],"containerStyle":[16],"parent":[16],"inheritParentWidth":[4,"inherit-parent-width"],"visible":[4]}]]],["limel-tooltip_2.cjs",[[1,"limel-tooltip",{"label":[513],"helperLabel":[513,"helper-label"],"elementId":[513,"element-id"],"open":[32]}],[1,"limel-tooltip-content",{"label":[513],"helperLabel":[513,"helper-label"]}]]]], options);
17
+ return index.bootstrapLazy([["limel-color-picker.cjs",[[1,"limel-color-picker",{"value":[513],"label":[513],"helperText":[513,"helper-text"],"tooltipLabel":[513,"tooltip-label"],"required":[516],"readonly":[516],"isOpen":[32]}]]],["limel-picker.cjs",[[1,"limel-picker",{"disabled":[4],"readonly":[516],"label":[1],"searchLabel":[1,"search-label"],"helperText":[513,"helper-text"],"leadingIcon":[1,"leading-icon"],"emptyResultMessage":[1,"empty-result-message"],"required":[4],"value":[16],"searcher":[16],"multiple":[4],"delimiter":[513],"actions":[16],"actionPosition":[1,"action-position"],"actionScrollBehavior":[1,"action-scroll-behavior"],"badgeIcons":[516,"badge-icons"],"items":[32],"textValue":[32],"loading":[32],"chips":[32]}]]],["limel-date-picker.cjs",[[1,"limel-date-picker",{"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"helperText":[513,"helper-text"],"required":[516],"value":[16],"type":[513],"format":[513],"language":[513],"formattedValue":[32],"internalFormat":[32],"showPortal":[32]}]]],["limel-button-group.cjs",[[1,"limel-button-group",{"value":[16],"disabled":[516],"selectedButtonId":[32]}]]],["limel-select.cjs",[[1,"limel-select",{"disabled":[516],"readonly":[516],"invalid":[516],"required":[516],"label":[513],"helperText":[513,"helper-text"],"value":[16],"options":[16],"multiple":[4],"menuOpen":[32]}]]],["limel-tab-panel.cjs",[[1,"limel-tab-panel",{"tabs":[1040]}]]],["limel-file.cjs",[[1,"limel-file",{"value":[16],"label":[513],"required":[516],"disabled":[516],"readonly":[516],"accept":[513],"language":[1],"isDraggingOverDropZone":[32]}]]],["limel-menu.cjs",[[1,"limel-menu",{"items":[16],"disabled":[516],"openDirection":[513,"open-direction"],"open":[1540],"badgeIcons":[516,"badge-icons"],"gridLayout":[516,"grid-layout"]}]]],["limel-button.cjs",[[1,"limel-button",{"label":[513],"primary":[516],"outlined":[516],"icon":[513],"disabled":[516],"loading":[516]}]]],["limel-collapsible-section.cjs",[[1,"limel-collapsible-section",{"isOpen":[1540,"is-open"],"header":[513],"actions":[16]}]]],["limel-dialog.cjs",[[1,"limel-dialog",{"heading":[1],"fullscreen":[516],"open":[1540],"closingActions":[16]}]]],["limel-progress-flow.cjs",[[1,"limel-progress-flow",{"flowItems":[16],"disabled":[4],"readonly":[4]}]]],["limel-banner.cjs",[[1,"limel-banner",{"message":[513],"icon":[513],"isOpen":[32],"open":[64],"close":[64]}]]],["limel-table.cjs",[[1,"limel-table",{"data":[16],"columns":[16],"mode":[1],"pageSize":[2,"page-size"],"totalRows":[2,"total-rows"],"sorting":[16],"activeRow":[1040],"movableColumns":[4,"movable-columns"],"loading":[4],"page":[2],"emptyMessage":[1,"empty-message"]}]]],["limel-checkbox.cjs",[[1,"limel-checkbox",{"disabled":[516],"readonly":[516],"label":[513],"helperText":[513,"helper-text"],"checked":[516],"indeterminate":[516],"required":[516],"modified":[32]}]]],["limel-circular-progress.cjs",[[1,"limel-circular-progress",{"value":[2],"maxValue":[2,"max-value"],"suffix":[1],"displayPercentageColors":[4,"display-percentage-colors"],"size":[513]}]]],["limel-code-editor.cjs",[[1,"limel-code-editor",{"value":[1],"language":[1],"readonly":[4],"lineNumbers":[4,"line-numbers"],"colorScheme":[1,"color-scheme"],"random":[32]}]]],["limel-config.cjs",[[1,"limel-config",{"config":[16]}]]],["limel-flex-container.cjs",[[1,"limel-flex-container",{"direction":[513],"justify":[513],"align":[513],"reverse":[516]}]]],["limel-form.cjs",[[1,"limel-form",{"schema":[16],"value":[16],"disabled":[4],"propsFactory":[16],"transformErrors":[16]}]]],["limel-grid.cjs",[[1,"limel-grid"]]],["limel-linear-progress.cjs",[[1,"limel-linear-progress",{"value":[2],"indeterminate":[4]}]]],["limel-slider.cjs",[[1,"limel-slider",{"disabled":[516],"readonly":[516],"factor":[514],"label":[513],"helperText":[513,"helper-text"],"unit":[513],"value":[514],"valuemax":[514],"valuemin":[514],"step":[514],"percentageClass":[32]}]]],["limel-snackbar.cjs",[[1,"limel-snackbar",{"message":[1],"timeout":[2],"actionText":[1,"action-text"],"dismissible":[4],"multiline":[4],"language":[1],"show":[64]}]]],["limel-switch.cjs",[[1,"limel-switch",{"label":[513],"disabled":[516],"readonly":[516],"value":[516],"fieldId":[32]}]]],["limel-tab-bar.cjs",[[1,"limel-tab-bar",{"tabs":[1040],"canScrollLeft":[32],"canScrollRight":[32]},[[9,"resize","handleWindowResize"]]]]],["limel-header.cjs",[[1,"limel-header",{"icon":[1],"heading":[1],"subheading":[1],"supportingText":[1,"supporting-text"]}]]],["limel-progress-flow-item.cjs",[[0,"limel-progress-flow-item",{"item":[16],"disabled":[4],"readonly":[4]}]]],["limel-flatpickr-adapter.cjs",[[1,"limel-flatpickr-adapter",{"value":[16],"type":[1],"format":[1],"isOpen":[4,"is-open"],"inputElement":[16],"language":[1]}]]],["limel-menu-list.cjs",[[1,"limel-menu-list",{"items":[16],"badgeIcons":[4,"badge-icons"],"iconSize":[1,"icon-size"],"type":[1],"maxLinesSecondaryText":[2,"max-lines-secondary-text"]}]]],["limel-popover-surface.cjs",[[1,"limel-popover-surface",{"contentCollection":[16]}]]],["limel-icon.cjs",[[1,"limel-icon",{"size":[513],"name":[513],"badge":[516]}]]],["limel-input-field.cjs",[[1,"limel-input-field",{"disabled":[516],"readonly":[516],"invalid":[516],"label":[513],"helperText":[513,"helper-text"],"required":[516],"value":[513],"trailingIcon":[513,"trailing-icon"],"leadingIcon":[513,"leading-icon"],"pattern":[513],"type":[513],"formatNumber":[516,"format-number"],"step":[520],"max":[514],"min":[514],"maxlength":[514],"minlength":[514],"completions":[16],"showLink":[516,"show-link"],"isFocused":[32],"isModified":[32],"showCompletions":[32]}]]],["limel-color-picker-palette_2.cjs",[[1,"limel-color-picker-palette",{"value":[513],"label":[513],"helperText":[513,"helper-text"],"required":[516]}],[1,"limel-popover",{"open":[4]}]]],["limel-badge.cjs",[[1,"limel-badge",{"label":[514]}]]],["limel-chip-set.cjs",[[1,"limel-chip-set",{"value":[16],"type":[513],"label":[513],"helperText":[513,"helper-text"],"disabled":[516],"readonly":[516],"maxItems":[514,"max-items"],"required":[516],"searchLabel":[513,"search-label"],"emptyInputOnBlur":[516,"empty-input-on-blur"],"clearAllButton":[4,"clear-all-button"],"leadingIcon":[513,"leading-icon"],"delimiter":[513],"language":[1],"editMode":[32],"textValue":[32],"blurred":[32],"inputChipIndexSelected":[32],"getEditMode":[64],"setFocus":[64],"emptyInput":[64]}]]],["limel-icon-button.cjs",[[1,"limel-icon-button",{"icon":[513],"elevated":[516],"label":[513],"disabled":[516],"relayout":[64]}]]],["limel-spinner.cjs",[[1,"limel-spinner",{"size":[513],"limeBranded":[4,"lime-branded"]}]]],["limel-list_3.cjs",[[1,"limel-list",{"items":[16],"badgeIcons":[4,"badge-icons"],"iconSize":[1,"icon-size"],"type":[1],"maxLinesSecondaryText":[2,"max-lines-secondary-text"]}],[1,"limel-menu-surface",{"open":[4],"allowClicksElement":[16]}],[1,"limel-portal",{"openDirection":[1,"open-direction"],"position":[1],"containerId":[1,"container-id"],"containerStyle":[16],"parent":[16],"inheritParentWidth":[4,"inherit-parent-width"],"visible":[4]}]]],["limel-tooltip_2.cjs",[[1,"limel-tooltip",{"elementId":[513,"element-id"],"label":[513],"helperLabel":[513,"helper-label"],"maxlength":[514],"open":[32]}],[1,"limel-tooltip-content",{"label":[513],"helperLabel":[513,"helper-label"],"maxlength":[514]}]]]], options);
18
18
  });
19
19
  };
20
20
 
@@ -764,6 +764,9 @@
764
764
  display: flex;
765
765
  flex-wrap: wrap;
766
766
  }
767
+ .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background, .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
768
+ background-color: rgb(var(--contrast-300));
769
+ }
767
770
  .mdc-form-field .mdc-checkbox.mdc-checkbox--invalid .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
768
771
  border-color: var(--lime-error-text-color);
769
772
  }
@@ -775,14 +778,14 @@
775
778
  border-radius: 0.25rem;
776
779
  box-shadow: var(--shadow-depth-8-focused);
777
780
  }
781
+ .mdc-form-field .mdc-checkbox--disabled {
782
+ opacity: 0.5;
783
+ }
778
784
  .mdc-form-field label {
779
785
  cursor: pointer;
780
786
  line-height: normal;
781
787
  padding-left: 0;
782
788
  }
783
- .mdc-form-field label.mdc-checkbox--disabled {
784
- opacity: 0.37;
785
- }
786
789
  .mdc-form-field label.mdc-checkbox--required::after {
787
790
  margin-left: 0.0625rem;
788
791
  content: "*";
@@ -1,6 +1,6 @@
1
1
  import { MDCCheckbox } from '@material/checkbox';
2
2
  import { MDCFormField } from '@material/form-field';
3
- import { Component, Element, Event, h, Prop, State, } from '@stencil/core';
3
+ import { Component, Element, Event, h, Prop, State, Watch, } from '@stencil/core';
4
4
  import { createRandomString } from '../../util/random-string';
5
5
  import { CheckboxTemplate } from './checkbox.template';
6
6
  /**
@@ -23,13 +23,28 @@ export class Checkbox {
23
23
  * The value of the checkbox. Set to `true` to make the checkbox checked.
24
24
  */
25
25
  this.checked = false;
26
+ /**
27
+ * Enables indeterminate state. Set to `true` to signal indeterminate check.
28
+ */
29
+ this.indeterminate = false;
26
30
  /**
27
31
  * Set to `true` to indicate that the checkbox must be checked.
28
32
  */
29
33
  this.required = false;
30
34
  this.modified = false;
31
35
  this.id = createRandomString();
32
- this.onChange = this.onChange.bind(this);
36
+ this.onChange = (event) => {
37
+ event.stopPropagation();
38
+ this.change.emit(this.mdcCheckbox.checked);
39
+ this.modified = true;
40
+ };
41
+ }
42
+ handleCheckedChange(newValue) {
43
+ this.mdcCheckbox.checked = newValue;
44
+ }
45
+ handleIndeterminateChange(newValue) {
46
+ this.mdcCheckbox.checked = this.checked;
47
+ this.mdcCheckbox.indeterminate = newValue;
33
48
  }
34
49
  connectedCallback() {
35
50
  this.initialize();
@@ -52,12 +67,7 @@ export class Checkbox {
52
67
  (_b = this.formField) === null || _b === void 0 ? void 0 : _b.destroy();
53
68
  }
54
69
  render() {
55
- return (h(CheckboxTemplate, { disabled: this.disabled || this.readonly, label: this.label, helperText: this.helperText, checked: this.checked, required: this.required, invalid: this.required && this.modified && !this.checked, onChange: this.onChange, id: this.id }));
56
- }
57
- onChange(event) {
58
- event.stopPropagation();
59
- this.change.emit(this.mdcCheckbox.checked);
60
- this.modified = true;
70
+ return (h(CheckboxTemplate, { disabled: this.disabled || this.readonly, label: this.label, helperText: this.helperText, checked: this.checked || this.indeterminate, indeterminate: this.indeterminate, required: this.required, invalid: this.required && this.modified && !this.checked, onChange: this.onChange, id: this.id }));
61
71
  }
62
72
  static get is() { return "limel-checkbox"; }
63
73
  static get encapsulation() { return "shadow"; }
@@ -156,6 +166,24 @@ export class Checkbox {
156
166
  "reflect": true,
157
167
  "defaultValue": "false"
158
168
  },
169
+ "indeterminate": {
170
+ "type": "boolean",
171
+ "mutable": false,
172
+ "complexType": {
173
+ "original": "boolean",
174
+ "resolved": "boolean",
175
+ "references": {}
176
+ },
177
+ "required": false,
178
+ "optional": false,
179
+ "docs": {
180
+ "tags": [],
181
+ "text": "Enables indeterminate state. Set to `true` to signal indeterminate check."
182
+ },
183
+ "attribute": "indeterminate",
184
+ "reflect": true,
185
+ "defaultValue": "false"
186
+ },
159
187
  "required": {
160
188
  "type": "boolean",
161
189
  "mutable": false,
@@ -195,4 +223,11 @@ export class Checkbox {
195
223
  }
196
224
  }]; }
197
225
  static get elementRef() { return "limelCheckbox"; }
226
+ static get watchers() { return [{
227
+ "propName": "checked",
228
+ "methodName": "handleCheckedChange"
229
+ }, {
230
+ "propName": "indeterminate",
231
+ "methodName": "handleIndeterminateChange"
232
+ }]; }
198
233
  }
@@ -1,13 +1,18 @@
1
1
  import { h } from '@stencil/core';
2
2
  export const CheckboxTemplate = (props) => {
3
+ const inputProps = {};
4
+ if (props.indeterminate) {
5
+ inputProps['data-indeterminate'] = 'true';
6
+ }
3
7
  return (h("div", { class: "mdc-form-field " },
4
8
  h("div", { class: {
5
9
  'mdc-checkbox': true,
6
10
  'mdc-checkbox--invalid': props.invalid,
7
11
  'mdc-checkbox--disabled': props.disabled,
8
12
  'mdc-checkbox--required': props.required,
13
+ 'mdc-checkbox--indeterminate': props.indeterminate,
9
14
  } },
10
- h("input", { type: "checkbox", class: "mdc-checkbox__native-control", id: props.id, checked: props.checked, disabled: props.disabled, required: props.required, onChange: props.onChange }),
15
+ h("input", Object.assign({ type: "checkbox", class: "mdc-checkbox__native-control", id: props.id, checked: props.checked, disabled: props.disabled, required: props.required, onChange: props.onChange }, inputProps)),
11
16
  h("div", { class: "mdc-checkbox__background" },
12
17
  h("svg", { class: "mdc-checkbox__checkmark", viewBox: "0 0 24 24" },
13
18
  h("path", { class: "mdc-checkbox__checkmark-path", fill: "none", d: "M1.73,12.91 8.1,19.28 22.79,4.59" })),
@@ -16,6 +21,7 @@ export const CheckboxTemplate = (props) => {
16
21
  'mdc-checkbox--invalid': props.invalid,
17
22
  'mdc-checkbox--disabled': props.disabled,
18
23
  'mdc-checkbox--required': props.required,
24
+ 'mdc-checkbox--indeterminate': props.indeterminate,
19
25
  }, htmlFor: props.id }, props.label),
20
26
  h(HelperText, { text: props.helperText })));
21
27
  };
@@ -3102,23 +3102,23 @@ a.mdc-list-item {
3102
3102
  bottom: 0;
3103
3103
  }
3104
3104
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset {
3105
- --icon-width: 2.5625rem;
3106
- --icon-right-padding: 1rem;
3107
- --list-right-padding: 1rem;
3108
- margin-left: calc( var(--icon-width) + var(--icon-right-padding) );
3105
+ --icon-width: 2.5rem;
3106
+ --icon-right-padding: 0.75rem;
3107
+ --list-right-padding: 0.75rem;
3108
+ right: 0;
3109
3109
  width: calc( 100% - var(--icon-width) - var(--icon-right-padding) - var(--list-right-padding) );
3110
3110
  }
3111
3111
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.x-small {
3112
- --icon-width: 1.4375rem;
3112
+ --icon-width: 1.5rem;
3113
3113
  }
3114
3114
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.small {
3115
- --icon-width: 1.875rem;
3115
+ --icon-width: 2rem;
3116
3116
  }
3117
3117
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.medium {
3118
3118
  --icon-width: 2.5rem;
3119
3119
  }
3120
3120
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.large {
3121
- --icon-width: 2.875rem;
3121
+ --icon-width: 3rem;
3122
3122
  }
3123
3123
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list .mdc-deprecated-list-item:last-child hr.mdc-deprecated-list-divider {
3124
3124
  display: none;
@@ -4030,6 +4030,9 @@ a.mdc-list-item {
4030
4030
  display: flex;
4031
4031
  flex-wrap: wrap;
4032
4032
  }
4033
+ .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background, .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
4034
+ background-color: rgb(var(--contrast-300));
4035
+ }
4033
4036
  .mdc-form-field .mdc-checkbox.mdc-checkbox--invalid .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
4034
4037
  border-color: var(--lime-error-text-color);
4035
4038
  }
@@ -4041,14 +4044,14 @@ a.mdc-list-item {
4041
4044
  border-radius: 0.25rem;
4042
4045
  box-shadow: var(--shadow-depth-8-focused);
4043
4046
  }
4047
+ .mdc-form-field .mdc-checkbox--disabled {
4048
+ opacity: 0.5;
4049
+ }
4044
4050
  .mdc-form-field label {
4045
4051
  cursor: pointer;
4046
4052
  line-height: normal;
4047
4053
  padding-left: 0;
4048
4054
  }
4049
- .mdc-form-field label.mdc-checkbox--disabled {
4050
- opacity: 0.37;
4051
- }
4052
4055
  .mdc-form-field label.mdc-checkbox--required::after {
4053
4056
  margin-left: 0.0625rem;
4054
4057
  content: "*";
@@ -9,8 +9,9 @@ import { zipObject } from 'lodash-es';
9
9
  * @exampleComponent limel-example-menu-icons
10
10
  * @exampleComponent limel-example-menu-badge-icons
11
11
  * @exampleComponent limel-example-menu-grid
12
- * @exampleComponent limel-example-menu-composite
13
12
  * @exampleComponent limel-example-menu-hotkeys
13
+ * @exampleComponent limel-example-menu-secondary-text
14
+ * @exampleComponent limel-example-menu-composite
14
15
  */
15
16
  export class Menu {
16
17
  constructor() {
@@ -145,6 +145,6 @@ export class MenuListRenderer {
145
145
  this.commandKey &&
146
146
  ['small', 'x-small'].includes(this.config.iconSize),
147
147
  };
148
- return (h("ul", { class: classNames, "aria-hidden": true, role: "menu", "aria-orientation": "vertical" }, items.map(this.renderMenuItem)));
148
+ return (h("ul", { class: classNames, "aria-hidden": true, role: "menu", "aria-orientation": "vertical", style: { '--maxLinesSecondaryText': '2' } }, items.map(this.renderMenuItem)));
149
149
  }
150
150
  }
@@ -3108,23 +3108,23 @@ a.mdc-list-item {
3108
3108
  bottom: 0;
3109
3109
  }
3110
3110
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset {
3111
- --icon-width: 2.5625rem;
3112
- --icon-right-padding: 1rem;
3113
- --list-right-padding: 1rem;
3114
- margin-left: calc( var(--icon-width) + var(--icon-right-padding) );
3111
+ --icon-width: 2.5rem;
3112
+ --icon-right-padding: 0.75rem;
3113
+ --list-right-padding: 0.75rem;
3114
+ right: 0;
3115
3115
  width: calc( 100% - var(--icon-width) - var(--icon-right-padding) - var(--list-right-padding) );
3116
3116
  }
3117
3117
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.x-small {
3118
- --icon-width: 1.4375rem;
3118
+ --icon-width: 1.5rem;
3119
3119
  }
3120
3120
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.small {
3121
- --icon-width: 1.875rem;
3121
+ --icon-width: 2rem;
3122
3122
  }
3123
3123
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.medium {
3124
3124
  --icon-width: 2.5rem;
3125
3125
  }
3126
3126
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset.large {
3127
- --icon-width: 2.875rem;
3127
+ --icon-width: 3rem;
3128
3128
  }
3129
3129
  .mdc-deprecated-list.mdc-deprecated-list--avatar-list .mdc-deprecated-list-item:last-child hr.mdc-deprecated-list-divider {
3130
3130
  display: none;
@@ -4036,6 +4036,9 @@ a.mdc-list-item {
4036
4036
  display: flex;
4037
4037
  flex-wrap: wrap;
4038
4038
  }
4039
+ .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control[disabled]:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background, .mdc-form-field .mdc-checkbox .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
4040
+ background-color: rgb(var(--contrast-300));
4041
+ }
4039
4042
  .mdc-form-field .mdc-checkbox.mdc-checkbox--invalid .mdc-checkbox__native-control:enabled:not(:checked):not(:indeterminate) ~ .mdc-checkbox__background {
4040
4043
  border-color: var(--lime-error-text-color);
4041
4044
  }
@@ -4047,14 +4050,14 @@ a.mdc-list-item {
4047
4050
  border-radius: 0.25rem;
4048
4051
  box-shadow: var(--shadow-depth-8-focused);
4049
4052
  }
4053
+ .mdc-form-field .mdc-checkbox--disabled {
4054
+ opacity: 0.5;
4055
+ }
4050
4056
  .mdc-form-field label {
4051
4057
  cursor: pointer;
4052
4058
  line-height: normal;
4053
4059
  padding-left: 0;
4054
4060
  }
4055
- .mdc-form-field label.mdc-checkbox--disabled {
4056
- opacity: 0.37;
4057
- }
4058
4061
  .mdc-form-field label.mdc-checkbox--required::after {
4059
4062
  margin-left: 0.0625rem;
4060
4063
  content: "*";
@@ -4698,4 +4701,7 @@ a.mdc-list-item {
4698
4701
  }
4699
4702
  .mdc-deprecated-list .mdc-deprecated-list-item[role=menuitem] .mdc-deprecated-list-item__graphic {
4700
4703
  margin-right: 0.875rem;
4704
+ }
4705
+ .mdc-deprecated-list hr.mdc-deprecated-list-divider.mdc-deprecated-list-divider--inset {
4706
+ display: none;
4701
4707
  }
@@ -1,21 +1,36 @@
1
1
  :host {
2
2
  animation: display-tooltip 0.2s ease;
3
3
  display: flex;
4
- flex-direction: row;
5
4
  border-radius: 0.25rem;
6
5
  padding: 0.25rem 0.5rem;
7
- font-size: 0.875rem;
8
6
  background-color: rgb(var(--contrast-1300));
9
7
  box-shadow: var(--shadow-depth-16);
10
8
  }
11
9
 
10
+ text {
11
+ font-size: 0.875rem;
12
+ line-height: 1.25;
13
+ display: flex;
14
+ column-gap: 1rem;
15
+ }
16
+ text.has-column-layout {
17
+ display: table-cell;
18
+ width: fit-content;
19
+ max-width: min(var(--tooltip-max-width-of-text), 80vw);
20
+ }
21
+ text.has-column-layout .label {
22
+ padding-bottom: 0.5rem;
23
+ }
24
+ text.has-column-layout .helper-label {
25
+ padding-bottom: 0.25rem;
26
+ }
27
+
12
28
  .label {
13
29
  color: rgb(var(--contrast-200));
14
30
  }
15
31
 
16
32
  .helper-label {
17
33
  color: rgb(var(--contrast-800));
18
- padding: 0 0 0 1rem;
19
34
  }
20
35
  .helper-label:empty {
21
36
  display: none;
@@ -6,9 +6,21 @@ import { Component, h, Prop } from '@stencil/core';
6
6
  */
7
7
  export class TooltipContent {
8
8
  render() {
9
+ let isLabelsTextLong = false;
10
+ if (this.helperLabel && this.maxlength) {
11
+ isLabelsTextLong =
12
+ this.label.length + this.helperLabel.length > this.maxlength;
13
+ }
14
+ const props = {};
15
+ if (this.maxlength) {
16
+ props.style = {
17
+ '--tooltip-max-width-of-text': `${this.maxlength}` + 'ch',
18
+ };
19
+ }
9
20
  return [
10
- h("div", { class: "label" }, this.label),
11
- h("div", { class: "helper-label" }, this.helperLabel),
21
+ h("text", Object.assign({ class: { 'has-column-layout': isLabelsTextLong } }, props),
22
+ h("div", { class: "label" }, this.label),
23
+ h("div", { class: "helper-label" }, this.helperLabel)),
12
24
  ];
13
25
  }
14
26
  static get is() { return "limel-tooltip-content"; }
@@ -28,11 +40,11 @@ export class TooltipContent {
28
40
  "resolved": "string",
29
41
  "references": {}
30
42
  },
31
- "required": false,
43
+ "required": true,
32
44
  "optional": false,
33
45
  "docs": {
34
46
  "tags": [],
35
- "text": "Short descriptive text of the owner element."
47
+ "text": "Read more in tooltip.tsx"
36
48
  },
37
49
  "attribute": "label",
38
50
  "reflect": true
@@ -46,13 +58,30 @@ export class TooltipContent {
46
58
  "references": {}
47
59
  },
48
60
  "required": false,
49
- "optional": false,
61
+ "optional": true,
50
62
  "docs": {
51
63
  "tags": [],
52
- "text": "Additional helper text for the element.\nExample usage can be a keyboard shortcut to activate the function of the\nowner element."
64
+ "text": "Read more in tooltip.tsx"
53
65
  },
54
66
  "attribute": "helper-label",
55
67
  "reflect": true
68
+ },
69
+ "maxlength": {
70
+ "type": "number",
71
+ "mutable": false,
72
+ "complexType": {
73
+ "original": "number",
74
+ "resolved": "number",
75
+ "references": {}
76
+ },
77
+ "required": false,
78
+ "optional": true,
79
+ "docs": {
80
+ "tags": [],
81
+ "text": "Read more in tooltip.tsx"
82
+ },
83
+ "attribute": "maxlength",
84
+ "reflect": true
56
85
  }
57
86
  }; }
58
87
  }
@@ -1,5 +1,6 @@
1
1
  import { Component, h, Prop, Element, State } from '@stencil/core';
2
2
  import { createRandomString } from '../../util/random-string';
3
+ const DEFAULT_MAX_LENGTH = 50;
3
4
  /**
4
5
  * A tooltip can be used to display a descriptive text for any element.
5
6
  * The displayed content must be a brief and supplemental string of text,
@@ -40,10 +41,17 @@ import { createRandomString } from '../../util/random-string';
40
41
  * effortlessly recognize can be hovered.
41
42
  *
42
43
  * @exampleComponent limel-example-tooltip
44
+ * @exampleComponent limel-example-tooltip-max-character
45
+ * @exampleComponent limel-example-tooltip-composite
43
46
  * @private
44
47
  */
45
48
  export class Tooltip {
46
49
  constructor() {
50
+ /**
51
+ * The maximum amount of characters before rendering 'label' and
52
+ * 'helperLabel' in two rows.
53
+ */
54
+ this.maxlength = DEFAULT_MAX_LENGTH;
47
55
  this.showTooltip = () => {
48
56
  const tooltipDelay = 500;
49
57
  this.showTooltipTimeoutHandle = window.setTimeout(() => {
@@ -71,7 +79,7 @@ export class Tooltip {
71
79
  'z-index': tooltipZIndex,
72
80
  'pointer-events': 'none',
73
81
  } },
74
- h("limel-tooltip-content", { label: this.label, helperLabel: this.helperLabel, role: "tooltip", "aria-hidden": !this.open, id: this.tooltipId }))));
82
+ h("limel-tooltip-content", { label: this.label, helperLabel: this.helperLabel, maxlength: this.maxlength, role: "tooltip", "aria-hidden": !this.open, id: this.tooltipId }))));
75
83
  }
76
84
  setOwnerAriaLabel() {
77
85
  const owner = this.getOwnerElement();
@@ -108,6 +116,23 @@ export class Tooltip {
108
116
  "$": ["tooltip.css"]
109
117
  }; }
110
118
  static get properties() { return {
119
+ "elementId": {
120
+ "type": "string",
121
+ "mutable": false,
122
+ "complexType": {
123
+ "original": "string",
124
+ "resolved": "string",
125
+ "references": {}
126
+ },
127
+ "required": true,
128
+ "optional": false,
129
+ "docs": {
130
+ "tags": [],
131
+ "text": "ID of the owner element that the tooltip should describe.\nMust be a child within the same document fragment as the tooltip element\nitself."
132
+ },
133
+ "attribute": "element-id",
134
+ "reflect": true
135
+ },
111
136
  "label": {
112
137
  "type": "string",
113
138
  "mutable": false,
@@ -134,7 +159,7 @@ export class Tooltip {
134
159
  "references": {}
135
160
  },
136
161
  "required": false,
137
- "optional": false,
162
+ "optional": true,
138
163
  "docs": {
139
164
  "tags": [],
140
165
  "text": "Additional helper text for the element.\nExample usage can be a keyboard shortcut to activate the function of the\nowner element."
@@ -142,22 +167,23 @@ export class Tooltip {
142
167
  "attribute": "helper-label",
143
168
  "reflect": true
144
169
  },
145
- "elementId": {
146
- "type": "string",
170
+ "maxlength": {
171
+ "type": "number",
147
172
  "mutable": false,
148
173
  "complexType": {
149
- "original": "string",
150
- "resolved": "string",
174
+ "original": "number",
175
+ "resolved": "number",
151
176
  "references": {}
152
177
  },
153
- "required": true,
154
- "optional": false,
178
+ "required": false,
179
+ "optional": true,
155
180
  "docs": {
156
181
  "tags": [],
157
- "text": "ID of the owner element that the tooltip should describe.\nMust be a child within the same document fragment as the tooltip element\nitself."
182
+ "text": "The maximum amount of characters before rendering 'label' and\n'helperLabel' in two rows."
158
183
  },
159
- "attribute": "element-id",
160
- "reflect": true
184
+ "attribute": "maxlength",
185
+ "reflect": true,
186
+ "defaultValue": "DEFAULT_MAX_LENGTH"
161
187
  }
162
188
  }; }
163
189
  static get states() { return {
@@ -1,14 +1,19 @@
1
1
  import { h } from './index-2316f345.js';
2
2
 
3
3
  const CheckboxTemplate = (props) => {
4
+ const inputProps = {};
5
+ if (props.indeterminate) {
6
+ inputProps['data-indeterminate'] = 'true';
7
+ }
4
8
  return (h("div", { class: "mdc-form-field " },
5
9
  h("div", { class: {
6
10
  'mdc-checkbox': true,
7
11
  'mdc-checkbox--invalid': props.invalid,
8
12
  'mdc-checkbox--disabled': props.disabled,
9
13
  'mdc-checkbox--required': props.required,
14
+ 'mdc-checkbox--indeterminate': props.indeterminate,
10
15
  } },
11
- h("input", { type: "checkbox", class: "mdc-checkbox__native-control", id: props.id, checked: props.checked, disabled: props.disabled, required: props.required, onChange: props.onChange }),
16
+ h("input", Object.assign({ type: "checkbox", class: "mdc-checkbox__native-control", id: props.id, checked: props.checked, disabled: props.disabled, required: props.required, onChange: props.onChange }, inputProps)),
12
17
  h("div", { class: "mdc-checkbox__background" },
13
18
  h("svg", { class: "mdc-checkbox__checkmark", viewBox: "0 0 24 24" },
14
19
  h("path", { class: "mdc-checkbox__checkmark-path", fill: "none", d: "M1.73,12.91 8.1,19.28 22.79,4.59" })),
@@ -17,6 +22,7 @@ const CheckboxTemplate = (props) => {
17
22
  'mdc-checkbox--invalid': props.invalid,
18
23
  'mdc-checkbox--disabled': props.disabled,
19
24
  'mdc-checkbox--required': props.required,
25
+ 'mdc-checkbox--indeterminate': props.indeterminate,
20
26
  }, htmlFor: props.id }, props.label),
21
27
  h(HelperText, { text: props.helperText })));
22
28
  };