@limetech/lime-elements 38.24.4 → 38.24.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.
- package/CHANGELOG.md +8 -0
- package/dist/cjs/limel-radio-button-group.cjs.entry.js.map +1 -1
- package/dist/collection/components/radio-button-group/radio-button-group.js.map +1 -1
- package/dist/esm/limel-radio-button-group.entry.js.map +1 -1
- package/dist/lime-elements/p-07988749.entry.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
## [38.24.5](https://github.com/Lundalogik/lime-elements/compare/v38.24.4...v38.24.5) (2025-10-03)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
* **radio-button-group:** use internal import path for types ([ff0df56](https://github.com/Lundalogik/lime-elements/commit/ff0df562c73687c5f82e3fd83d01c4d97a0cdeca))
|
|
8
|
+
|
|
1
9
|
## [38.24.4](https://github.com/Lundalogik/lime-elements/compare/v38.24.3...v38.24.4) (2025-10-01)
|
|
2
10
|
|
|
3
11
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"limel-radio-button-group.entry.cjs.js","mappings":";;;;;;MAwBa,gBAAgB;;;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC;MACzD,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;KAClC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,QACIA,wBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,EACJ;GACL;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB;;MACnC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;KACL,CAAC,CAAC;GACN;;;;;","names":["h"],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '
|
|
1
|
+
{"file":"limel-radio-button-group.entry.cjs.js","mappings":";;;;;;MAwBa,gBAAgB;;;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC;MACzD,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;KAClC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,QACIA,wBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,EACJ;GACL;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB;;MACnC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;KACL,CAAC,CAAC;GACN;;;;;","names":["h"],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '../../components';\n\n/**\n * The Radio Button component provides a convenient way to create a group of radio buttons\n * from an array of options. Radio buttons allow users to select a single option from\n * multiple choices, making them ideal for exclusive selections.\n *\n * :::note\n * A single radio button is never useful in a UI. Radio buttons should always come in groups\n * of at least 2 options where only one can be selected at a time.\n * :::\n *\n * @exampleComponent limel-example-radio-button-group-basic\n * @exampleComponent limel-example-radio-button-group-deselect-selected\n * @exampleComponent limel-example-radio-button-group-icons\n * @exampleComponent limel-example-radio-button-group-multiple-lines\n * @beta\n */\n@Component({\n tag: 'limel-radio-button-group',\n shadow: false,\n})\nexport class RadioButtonGroup {\n /**\n * Array of radio button options to display\n */\n @Prop()\n public items: Array<ListItem | ListSeparator>;\n\n /**\n * The currently selected item in the radio button group.\n * This is a ListItem object that contains the value and other properties of the selected item.\n * If no item is selected, this will be `undefined`.\n */\n @Prop()\n public selectedItem?: ListItem<string | number>;\n\n /**\n * Disables all radio buttons when `true`\n */\n @Prop({ reflect: true })\n public disabled = false;\n\n /**\n * Set to `true` if the radio button group should display larger icons with a background\n */\n @Prop({ reflect: true })\n public badgeIcons: boolean;\n\n /**\n * By default, lists will display 3 lines of text, and then truncate the rest.\n * Consumers can increase or decrease this number by specifying\n * `maxLinesSecondaryText`. If consumer enters zero or negative\n * numbers we default to 1; and if they type decimals we round up.\n */\n @Prop({ reflect: true })\n public maxLinesSecondaryText: number = 3;\n\n /**\n * Emitted when the selection changes with the full ListItem payload\n */\n @Event()\n public change: EventEmitter<ListItem<string | number | undefined>>;\n\n public render() {\n return (\n <limel-list\n items={this.createItems()}\n type=\"radio\"\n badgeIcons={this.badgeIcons}\n maxLinesSecondaryText={this.maxLinesSecondaryText}\n onChange={this.handleChange}\n />\n );\n }\n\n private createItems(): Array<ListItem | ListSeparator> {\n return this.items.map((option: ListItem) => {\n if ('separator' in option) {\n return option;\n }\n return {\n ...option,\n selected: option.value === this.selectedItem?.value,\n disabled: this.disabled || option.disabled,\n };\n });\n }\n\n private handleChange = (event: LimelListCustomEvent<ListItem>) => {\n event.stopPropagation();\n\n if (this.disabled) {\n return;\n }\n\n this.change.emit(event.detail);\n };\n}\n"],"version":3}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"radio-button-group.js","sourceRoot":"","sources":["../../../src/components/radio-button-group/radio-button-group.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAIxE;;;;;;;;;;;;;;;GAeG;AAKH,MAAM,OAAO,gBAAgB;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC,EAAE,EAAE;MAC7D,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IACnC,CAAC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,OAAO,CACH,kBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,CACL,CAAC;EACN,CAAC;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB,EAAE,EAAE;;MACvC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;IACN,CAAC,CAAC,CAAC;EACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWJ","sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '
|
|
1
|
+
{"version":3,"file":"radio-button-group.js","sourceRoot":"","sources":["../../../src/components/radio-button-group/radio-button-group.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAIxE;;;;;;;;;;;;;;;GAeG;AAKH,MAAM,OAAO,gBAAgB;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC,EAAE,EAAE;MAC7D,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IACnC,CAAC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,OAAO,CACH,kBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,CACL,CAAC;EACN,CAAC;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB,EAAE,EAAE;;MACvC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;IACN,CAAC,CAAC,CAAC;EACP,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAWJ","sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '../../components';\n\n/**\n * The Radio Button component provides a convenient way to create a group of radio buttons\n * from an array of options. Radio buttons allow users to select a single option from\n * multiple choices, making them ideal for exclusive selections.\n *\n * :::note\n * A single radio button is never useful in a UI. Radio buttons should always come in groups\n * of at least 2 options where only one can be selected at a time.\n * :::\n *\n * @exampleComponent limel-example-radio-button-group-basic\n * @exampleComponent limel-example-radio-button-group-deselect-selected\n * @exampleComponent limel-example-radio-button-group-icons\n * @exampleComponent limel-example-radio-button-group-multiple-lines\n * @beta\n */\n@Component({\n tag: 'limel-radio-button-group',\n shadow: false,\n})\nexport class RadioButtonGroup {\n /**\n * Array of radio button options to display\n */\n @Prop()\n public items: Array<ListItem | ListSeparator>;\n\n /**\n * The currently selected item in the radio button group.\n * This is a ListItem object that contains the value and other properties of the selected item.\n * If no item is selected, this will be `undefined`.\n */\n @Prop()\n public selectedItem?: ListItem<string | number>;\n\n /**\n * Disables all radio buttons when `true`\n */\n @Prop({ reflect: true })\n public disabled = false;\n\n /**\n * Set to `true` if the radio button group should display larger icons with a background\n */\n @Prop({ reflect: true })\n public badgeIcons: boolean;\n\n /**\n * By default, lists will display 3 lines of text, and then truncate the rest.\n * Consumers can increase or decrease this number by specifying\n * `maxLinesSecondaryText`. If consumer enters zero or negative\n * numbers we default to 1; and if they type decimals we round up.\n */\n @Prop({ reflect: true })\n public maxLinesSecondaryText: number = 3;\n\n /**\n * Emitted when the selection changes with the full ListItem payload\n */\n @Event()\n public change: EventEmitter<ListItem<string | number | undefined>>;\n\n public render() {\n return (\n <limel-list\n items={this.createItems()}\n type=\"radio\"\n badgeIcons={this.badgeIcons}\n maxLinesSecondaryText={this.maxLinesSecondaryText}\n onChange={this.handleChange}\n />\n );\n }\n\n private createItems(): Array<ListItem | ListSeparator> {\n return this.items.map((option: ListItem) => {\n if ('separator' in option) {\n return option;\n }\n return {\n ...option,\n selected: option.value === this.selectedItem?.value,\n disabled: this.disabled || option.disabled,\n };\n });\n }\n\n private handleChange = (event: LimelListCustomEvent<ListItem>) => {\n event.stopPropagation();\n\n if (this.disabled) {\n return;\n }\n\n this.change.emit(event.detail);\n };\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"limel-radio-button-group.entry.js","mappings":";;MAwBa,gBAAgB;;;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC;MACzD,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;KAClC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,QACI,kBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,EACJ;GACL;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB;;MACnC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;KACL,CAAC,CAAC;GACN;;;;;","names":[],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '
|
|
1
|
+
{"file":"limel-radio-button-group.entry.js","mappings":";;MAwBa,gBAAgB;;;;IAmEjB,iBAAY,GAAG,CAAC,KAAqC;MACzD,KAAK,CAAC,eAAe,EAAE,CAAC;MAExB,IAAI,IAAI,CAAC,QAAQ,EAAE;QACf,OAAO;OACV;MAED,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;KAClC,CAAC;;;oBAxDgB,KAAK;;iCAegB,CAAC;;EAQjC,MAAM;IACT,QACI,kBACI,KAAK,EAAE,IAAI,CAAC,WAAW,EAAE,EACzB,IAAI,EAAC,OAAO,EACZ,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,qBAAqB,EAAE,IAAI,CAAC,qBAAqB,EACjD,QAAQ,EAAE,IAAI,CAAC,YAAY,GAC7B,EACJ;GACL;EAEO,WAAW;IACf,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,MAAgB;;MACnC,IAAI,WAAW,IAAI,MAAM,EAAE;QACvB,OAAO,MAAM,CAAC;OACjB;MACD,uCACO,MAAM,KACT,QAAQ,EAAE,MAAM,CAAC,KAAK,MAAK,MAAA,IAAI,CAAC,YAAY,0CAAE,KAAK,CAAA,EACnD,QAAQ,EAAE,IAAI,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,IAC5C;KACL,CAAC,CAAC;GACN;;;;;","names":[],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '../../components';\n\n/**\n * The Radio Button component provides a convenient way to create a group of radio buttons\n * from an array of options. Radio buttons allow users to select a single option from\n * multiple choices, making them ideal for exclusive selections.\n *\n * :::note\n * A single radio button is never useful in a UI. Radio buttons should always come in groups\n * of at least 2 options where only one can be selected at a time.\n * :::\n *\n * @exampleComponent limel-example-radio-button-group-basic\n * @exampleComponent limel-example-radio-button-group-deselect-selected\n * @exampleComponent limel-example-radio-button-group-icons\n * @exampleComponent limel-example-radio-button-group-multiple-lines\n * @beta\n */\n@Component({\n tag: 'limel-radio-button-group',\n shadow: false,\n})\nexport class RadioButtonGroup {\n /**\n * Array of radio button options to display\n */\n @Prop()\n public items: Array<ListItem | ListSeparator>;\n\n /**\n * The currently selected item in the radio button group.\n * This is a ListItem object that contains the value and other properties of the selected item.\n * If no item is selected, this will be `undefined`.\n */\n @Prop()\n public selectedItem?: ListItem<string | number>;\n\n /**\n * Disables all radio buttons when `true`\n */\n @Prop({ reflect: true })\n public disabled = false;\n\n /**\n * Set to `true` if the radio button group should display larger icons with a background\n */\n @Prop({ reflect: true })\n public badgeIcons: boolean;\n\n /**\n * By default, lists will display 3 lines of text, and then truncate the rest.\n * Consumers can increase or decrease this number by specifying\n * `maxLinesSecondaryText`. If consumer enters zero or negative\n * numbers we default to 1; and if they type decimals we round up.\n */\n @Prop({ reflect: true })\n public maxLinesSecondaryText: number = 3;\n\n /**\n * Emitted when the selection changes with the full ListItem payload\n */\n @Event()\n public change: EventEmitter<ListItem<string | number | undefined>>;\n\n public render() {\n return (\n <limel-list\n items={this.createItems()}\n type=\"radio\"\n badgeIcons={this.badgeIcons}\n maxLinesSecondaryText={this.maxLinesSecondaryText}\n onChange={this.handleChange}\n />\n );\n }\n\n private createItems(): Array<ListItem | ListSeparator> {\n return this.items.map((option: ListItem) => {\n if ('separator' in option) {\n return option;\n }\n return {\n ...option,\n selected: option.value === this.selectedItem?.value,\n disabled: this.disabled || option.disabled,\n };\n });\n }\n\n private handleChange = (event: LimelListCustomEvent<ListItem>) => {\n event.stopPropagation();\n\n if (this.disabled) {\n return;\n }\n\n this.change.emit(event.detail);\n };\n}\n"],"version":3}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["RadioButtonGroup","this","handleChange","event","stopPropagation","disabled","change","emit","detail","render","h","items","createItems","type","badgeIcons","maxLinesSecondaryText","onChange","map","option","Object","assign","selected","value","_a","selectedItem"],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '
|
|
1
|
+
{"version":3,"names":["RadioButtonGroup","this","handleChange","event","stopPropagation","disabled","change","emit","detail","render","h","items","createItems","type","badgeIcons","maxLinesSecondaryText","onChange","map","option","Object","assign","selected","value","_a","selectedItem"],"sources":["./src/components/radio-button-group/radio-button-group.tsx"],"sourcesContent":["import { Component, Event, EventEmitter, h, Prop } from '@stencil/core';\nimport { ListItem, ListSeparator } from '../list-item/list-item.types';\nimport { LimelListCustomEvent } from '../../components';\n\n/**\n * The Radio Button component provides a convenient way to create a group of radio buttons\n * from an array of options. Radio buttons allow users to select a single option from\n * multiple choices, making them ideal for exclusive selections.\n *\n * :::note\n * A single radio button is never useful in a UI. Radio buttons should always come in groups\n * of at least 2 options where only one can be selected at a time.\n * :::\n *\n * @exampleComponent limel-example-radio-button-group-basic\n * @exampleComponent limel-example-radio-button-group-deselect-selected\n * @exampleComponent limel-example-radio-button-group-icons\n * @exampleComponent limel-example-radio-button-group-multiple-lines\n * @beta\n */\n@Component({\n tag: 'limel-radio-button-group',\n shadow: false,\n})\nexport class RadioButtonGroup {\n /**\n * Array of radio button options to display\n */\n @Prop()\n public items: Array<ListItem | ListSeparator>;\n\n /**\n * The currently selected item in the radio button group.\n * This is a ListItem object that contains the value and other properties of the selected item.\n * If no item is selected, this will be `undefined`.\n */\n @Prop()\n public selectedItem?: ListItem<string | number>;\n\n /**\n * Disables all radio buttons when `true`\n */\n @Prop({ reflect: true })\n public disabled = false;\n\n /**\n * Set to `true` if the radio button group should display larger icons with a background\n */\n @Prop({ reflect: true })\n public badgeIcons: boolean;\n\n /**\n * By default, lists will display 3 lines of text, and then truncate the rest.\n * Consumers can increase or decrease this number by specifying\n * `maxLinesSecondaryText`. If consumer enters zero or negative\n * numbers we default to 1; and if they type decimals we round up.\n */\n @Prop({ reflect: true })\n public maxLinesSecondaryText: number = 3;\n\n /**\n * Emitted when the selection changes with the full ListItem payload\n */\n @Event()\n public change: EventEmitter<ListItem<string | number | undefined>>;\n\n public render() {\n return (\n <limel-list\n items={this.createItems()}\n type=\"radio\"\n badgeIcons={this.badgeIcons}\n maxLinesSecondaryText={this.maxLinesSecondaryText}\n onChange={this.handleChange}\n />\n );\n }\n\n private createItems(): Array<ListItem | ListSeparator> {\n return this.items.map((option: ListItem) => {\n if ('separator' in option) {\n return option;\n }\n return {\n ...option,\n selected: option.value === this.selectedItem?.value,\n disabled: this.disabled || option.disabled,\n };\n });\n }\n\n private handleChange = (event: LimelListCustomEvent<ListItem>) => {\n event.stopPropagation();\n\n if (this.disabled) {\n return;\n }\n\n this.change.emit(event.detail);\n };\n}\n"],"mappings":"wDAwBaA,EAAgB,M,wDAmEjBC,KAAAC,aAAgBC,IACpBA,EAAMC,kBAEN,GAAIH,KAAKI,SAAU,CACf,M,CAGJJ,KAAKK,OAAOC,KAAKJ,EAAMK,OAAO,E,+DAvDhB,M,qDAeqB,C,CAQhCC,SACH,OACIC,EAAA,cACIC,MAAOV,KAAKW,cACZC,KAAK,QACLC,WAAYb,KAAKa,WACjBC,sBAAuBd,KAAKc,sBAC5BC,SAAUf,KAAKC,c,CAKnBU,cACJ,OAAOX,KAAKU,MAAMM,KAAKC,I,MACnB,GAAI,cAAeA,EAAQ,CACvB,OAAOA,C,CAEX,OAAAC,OAAAC,OAAAD,OAAAC,OAAA,GACOF,GAAM,CACTG,SAAUH,EAAOI,UAAUC,EAAAtB,KAAKuB,gBAAY,MAAAD,SAAA,SAAAA,EAAED,OAC9CjB,SAAUJ,KAAKI,UAAYa,EAAOb,UAAQ,G"}
|