@sebgroup/green-core 3.12.5 → 3.13.0

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 (66) hide show
  1. package/components/grouped-list/grouped-list.component.d.ts +0 -2
  2. package/components/grouped-list/grouped-list.component.js +3 -4
  3. package/components/grouped-list/index.d.ts +0 -1
  4. package/components/grouped-list/index.js +0 -1
  5. package/components/grouped-list/list-item.component.d.ts +1 -11
  6. package/components/grouped-list/list-item.component.js +2 -17
  7. package/components/index.d.ts +1 -0
  8. package/components/index.js +1 -0
  9. package/components/list/index.d.ts +2 -0
  10. package/components/list/index.js +2 -0
  11. package/components/list/list-item/index.d.ts +1 -0
  12. package/components/list/list-item/index.js +1 -0
  13. package/components/list/list-item/list-item.component.d.ts +16 -0
  14. package/components/list/list-item/list-item.component.js +24 -0
  15. package/components/list/list-item/list-item.d.ts +2 -0
  16. package/components/list/list-item/list-item.js +6 -0
  17. package/components/list/list-item/list-item.styles.d.ts +2 -0
  18. package/components/list/list-item/list-item.styles.js +13 -0
  19. package/components/list/list.component.d.ts +16 -0
  20. package/components/list/list.component.js +23 -0
  21. package/components/list/list.d.ts +2 -0
  22. package/components/list/list.js +6 -0
  23. package/components/list/list.styles.d.ts +2 -0
  24. package/components/list/list.styles.js +13 -0
  25. package/custom-elements.json +34865 -32572
  26. package/gds-element.js +1 -1
  27. package/generated/mcp/components.json +27 -2
  28. package/generated/mcp/icons.json +1 -1
  29. package/generated/mcp/index.json +1 -1
  30. package/generated/mcp/list/angular.md +17 -0
  31. package/generated/mcp/list/api.md +86 -0
  32. package/generated/mcp/list/guidelines.md +1 -0
  33. package/generated/mcp/list/index.json +9 -0
  34. package/generated/mcp/list/react.md +17 -0
  35. package/generated/mcp/list-item/angular.md +3 -1
  36. package/generated/mcp/list-item/api.md +17 -0
  37. package/generated/mcp/list-item/react.md +3 -1
  38. package/generated/mcp/list-item-pattern-01/angular.md +26 -0
  39. package/generated/mcp/list-item-pattern-01/api.md +55 -0
  40. package/generated/mcp/list-item-pattern-01/index.json +8 -0
  41. package/generated/mcp/list-item-pattern-01/react.md +26 -0
  42. package/generated/mcp/tokens.json +1 -1
  43. package/generated/react/index.d.ts +6 -4
  44. package/generated/react/index.js +6 -4
  45. package/generated/react/list/index.d.ts +727 -0
  46. package/generated/react/list/index.js +14 -0
  47. package/generated/react/list-item/index.d.ts +10 -1
  48. package/generated/react/list-item/index.js +1 -1
  49. package/generated/react/list-item-pattern-01/index.d.ts +690 -0
  50. package/generated/react/list-item-pattern-01/index.js +16 -0
  51. package/package.json +8 -1
  52. package/patterns/index.d.ts +1 -0
  53. package/patterns/index.js +1 -0
  54. package/patterns/list-item-pattern-01/index.d.ts +1 -0
  55. package/patterns/list-item-pattern-01/index.js +1 -0
  56. package/patterns/list-item-pattern-01/list-item-pattern-01.component.d.ts +74 -0
  57. package/patterns/list-item-pattern-01/list-item-pattern-01.component.js +278 -0
  58. package/patterns/list-item-pattern-01/list-item-pattern-01.d.ts +2 -0
  59. package/patterns/list-item-pattern-01/list-item-pattern-01.js +6 -0
  60. package/patterns/list-item-pattern-01/list-item-pattern-01.stories.data.d.ts +4 -0
  61. package/patterns/list-item-pattern-01/list-item-pattern-01.stories.data.js +8 -0
  62. package/patterns/list-item-pattern-01/list-item-pattern-01.styles.d.ts +2 -0
  63. package/patterns/list-item-pattern-01/list-item-pattern-01.styles.js +113 -0
  64. package/pure.d.ts +3 -0
  65. package/pure.js +3 -0
  66. package/utils/helpers/custom-element-scoping.js +1 -1
@@ -0,0 +1,16 @@
1
+ import "../../../chunks/chunk.CAV4X6PU.js";
2
+ import { createElement } from "react";
3
+ import { GdsListItemPattern01 as GdsListItemPattern01Class } from "../../../patterns/list-item-pattern-01/list-item-pattern-01.component.js";
4
+ import { getReactComponent } from "../../../utils/react.js";
5
+ const GdsListItemPattern01 = (props) => {
6
+ GdsListItemPattern01Class.define();
7
+ const JSXElement = getReactComponent(
8
+ "gds-list-item-pattern-01"
9
+ );
10
+ const propsWithClass = { ...props, class: props.className, ref: props.ref };
11
+ return createElement(JSXElement, propsWithClass);
12
+ };
13
+ GdsListItemPattern01.displayName = "GdsListItemPattern01";
14
+ export {
15
+ GdsListItemPattern01
16
+ };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@sebgroup/green-core",
3
3
  "description": "A carefully crafted set of Web Components, laying the foundation of the Green Design System.",
4
- "version": "3.12.5",
4
+ "version": "3.13.0",
5
5
  "main": "index.js",
6
6
  "module": "index.js",
7
7
  "type": "module",
@@ -111,6 +111,10 @@
111
111
  "./components/menu-button/index.js",
112
112
  "./components/mask/mask.js",
113
113
  "./components/mask/index.js",
114
+ "./components/list/list.js",
115
+ "./components/list/index.js",
116
+ "./components/list/list-item/list-item.js",
117
+ "./components/list/list-item/index.js",
114
118
  "./components/link/link.js",
115
119
  "./components/link/index.js",
116
120
  "./components/input/input.js",
@@ -510,6 +514,9 @@
510
514
  "./components/alert/index.js",
511
515
  "./components/alert/alert.js",
512
516
  "./patterns/index.js",
517
+ "./patterns/list-item-pattern-01/list-item-pattern-01.stories.data.js",
518
+ "./patterns/list-item-pattern-01/list-item-pattern-01.js",
519
+ "./patterns/list-item-pattern-01/index.js",
513
520
  "./patterns/card-pattern-01/index.js",
514
521
  "./patterns/card-pattern-01/card-pattern-01.js",
515
522
  "./primitives/toggle-controls-base/toggle-control-base.js",
@@ -1 +1,2 @@
1
1
  export * from './card-pattern-01/card-pattern-01';
2
+ export * from './list-item-pattern-01/list-item-pattern-01';
package/patterns/index.js CHANGED
@@ -1 +1,2 @@
1
1
  export * from "./card-pattern-01/card-pattern-01.js";
2
+ export * from "./list-item-pattern-01/list-item-pattern-01.js";
@@ -0,0 +1 @@
1
+ export * from './list-item-pattern-01';
@@ -0,0 +1 @@
1
+ export * from "./list-item-pattern-01.js";
@@ -0,0 +1,74 @@
1
+ import { GdsListItem } from '../../components/list/list-item/list-item.component';
2
+ export interface ListPatternItem {
3
+ /** Optional label displayed above the value */
4
+ label?: string;
5
+ /** Required value for the item */
6
+ value: string;
7
+ }
8
+ declare const GdsListItemPattern01_base: (new (...args: any[]) => import("../../utils/mixins/props-link").LinkProps) & typeof GdsListItem;
9
+ /**
10
+ * @element gds-list-item-pattern-01
11
+ * @status beta
12
+ *
13
+ * A single row for use inside a `gds-list-pattern-01` container.
14
+ * The row has lead, main, and trail slots.
15
+ *
16
+ * The main slot supports multiple columns via the `items` property.
17
+ * Each column has an optional `label` and a required `value`, rendered vertically.
18
+ *
19
+ * When `selectable` is set, a checkbox is rendered in the lead slot.
20
+ * When `href` is set, the trail renders a chevron as a link and the row gains a hover state.
21
+ *
22
+ * @slot - Main content slot. Rendered after `items` columns when `items` is set, or as the sole main content when `items` is not set.
23
+ * @slot lead - Lead slot content. Ignored when `selectable` is set (checkbox takes precedence).
24
+ *
25
+ * @event input - Dispatched when the checkbox is checked or unchecked.
26
+ * @event change - Dispatched when the checkbox is checked or unchecked.
27
+ */
28
+ export declare class GdsListItemPattern01 extends GdsListItemPattern01_base {
29
+ #private;
30
+ static styles: (import("lit").CSSResult | import("lit").CSSResult[])[];
31
+ private _isWrapped;
32
+ private _hasLead;
33
+ private _itemsContainer?;
34
+ private _checkWrap;
35
+ /**
36
+ * Multi-column content for the main slot.
37
+ * Each entry has an optional `label` and a required `value`.
38
+ * When set, takes precedence over the default slot.
39
+ *
40
+ * Accepts: `Array<{ label?: string, value: string }>`
41
+ */
42
+ items?: ListPatternItem[];
43
+ /**
44
+ * Optional label displayed above the items in the main slot.
45
+ * If not set, falls back to the first item's label (if available).
46
+ */
47
+ label: string;
48
+ /**
49
+ * Enables a checkbox in the lead slot of the row.
50
+ * The checkbox can be toggled and emits a `toggle-change` event.
51
+ */
52
+ selectable: boolean;
53
+ /**
54
+ * Whether the checkbox is checked. Only relevant when `selectable` is true.
55
+ */
56
+ checked: boolean;
57
+ /**
58
+ * Whether the checkbox is in an indeterminate state. Only relevant when `selectable` is true.
59
+ */
60
+ indeterminate: boolean;
61
+ /**
62
+ * Whether the checkbox is disabled. Only relevant when `selectable` is true.
63
+ */
64
+ disabled: boolean;
65
+ /**
66
+ * Controls the `padding-inline` of the item.
67
+ * Accepts space token names (e.g. `s`, `m`, `l`) or custom CSS values (e.g. `0`).
68
+ * Defaults to `s` via the stylesheet. Set to `0` to remove padding.
69
+ */
70
+ 'padding-inline'?: string;
71
+ private _hasTrailContent;
72
+ render(): any;
73
+ }
74
+ export {};
@@ -0,0 +1,278 @@
1
+ import {
2
+ __decorateClass,
3
+ __privateAdd,
4
+ __privateGet,
5
+ __privateMethod
6
+ } from "../../chunks/chunk.CAV4X6PU.js";
7
+ var _isLinked, isLinked_get, _renderCheckbox, renderCheckbox_fn, _renderLead, renderLead_fn, _renderItems, renderItems_fn, _onLeadSlotChange, onLeadSlotChange_fn, _onTrailSlotChange, onTrailSlotChange_fn, _renderMain, renderMain_fn, _renderTrail, renderTrail_fn, _renderRowContent, renderRowContent_fn;
8
+ import { property, query, state } from "lit/decorators.js";
9
+ import { classMap } from "lit/directives/class-map.js";
10
+ import { ifDefined } from "lit/directives/if-defined.js";
11
+ import { when } from "lit/directives/when.js";
12
+ import { GdsButton } from "../../components/button/button.component.js";
13
+ import { GdsFlex } from "../../components/flex/flex.component.js";
14
+ import { IconCheckmark } from "../../components/icon/icons/checkmark.component.js";
15
+ import { IconChevronRight } from "../../components/icon/icons/chevron-right.component.js";
16
+ import { IconMinusSmall } from "../../components/icon/icons/minus-small.component.js";
17
+ import { GdsListItem } from "../../components/list/list-item/list-item.component.js";
18
+ import { GdsText } from "../../components/text/text.component.js";
19
+ import rbcbToggleStyles from "../../shared-styles/rbcb-toggle.style.js";
20
+ import { checkboxToggle } from "../../shared-styles/rbcb-toggle.template.js";
21
+ import { tokens } from "../../tokens.style.js";
22
+ import { resizeObserver } from "../../utils/decorators/resize-observer.js";
23
+ import { styleExpressionProperty } from "../../utils/decorators/style-expression-property.js";
24
+ import {
25
+ gdsCustomElement,
26
+ html
27
+ } from "../../utils/helpers/custom-element-scoping.js";
28
+ import { forSpaceTokensAndCustomValues } from "../../utils/helpers/style-expression-helpers.js";
29
+ import { withLinkProps } from "../../utils/mixins/props-link.js";
30
+ import ListPattern01ItemStyles from "./list-item-pattern-01.styles.js";
31
+ let GdsListItemPattern01 = class extends withLinkProps(GdsListItem) {
32
+ constructor() {
33
+ super(...arguments);
34
+ __privateAdd(this, _isLinked);
35
+ __privateAdd(this, _renderCheckbox);
36
+ __privateAdd(this, _renderLead);
37
+ __privateAdd(this, _renderItems);
38
+ __privateAdd(this, _onLeadSlotChange);
39
+ __privateAdd(this, _onTrailSlotChange);
40
+ __privateAdd(this, _renderMain);
41
+ __privateAdd(this, _renderTrail);
42
+ __privateAdd(this, _renderRowContent);
43
+ this._isWrapped = false;
44
+ this._hasLead = false;
45
+ this.label = "";
46
+ this.selectable = false;
47
+ this.checked = false;
48
+ this.indeterminate = false;
49
+ this.disabled = false;
50
+ this._hasTrailContent = false;
51
+ }
52
+ _checkWrap() {
53
+ const el = this._itemsContainer;
54
+ if (!el)
55
+ return;
56
+ const children = Array.from(el.children);
57
+ if (children.length < 2) {
58
+ this._isWrapped = false;
59
+ return;
60
+ }
61
+ const firstTop = children[0].getBoundingClientRect().top;
62
+ this._isWrapped = children.some(
63
+ (child) => child.getBoundingClientRect().top > firstTop
64
+ );
65
+ }
66
+ render() {
67
+ return html`${__privateMethod(this, _renderRowContent, renderRowContent_fn).call(this)}`;
68
+ }
69
+ };
70
+ _isLinked = new WeakSet();
71
+ isLinked_get = function() {
72
+ return !!this.href;
73
+ };
74
+ _renderCheckbox = new WeakSet();
75
+ renderCheckbox_fn = function() {
76
+ const toggle = (e) => {
77
+ e.stopPropagation();
78
+ if (this.disabled)
79
+ return;
80
+ this.checked = !this.checked;
81
+ this.dispatchEvent(new Event("input", { bubbles: true, composed: true }));
82
+ this.dispatchEvent(new Event("change", { bubbles: true, composed: true }));
83
+ };
84
+ const onKey = (e) => {
85
+ if (e.key === " " || e.key === "Enter") {
86
+ e.preventDefault();
87
+ toggle(e);
88
+ }
89
+ };
90
+ return html`
91
+ <div
92
+ class="rbcb-wrapper"
93
+ role="checkbox"
94
+ aria-checked=${this.indeterminate ? "mixed" : this.checked ? "true" : "false"}
95
+ aria-label=${this.label || "Select item"}
96
+ tabindex="0"
97
+ @click=${toggle}
98
+ @keydown=${onKey}
99
+ >
100
+ <input
101
+ type="checkbox"
102
+ class="visually-hidden-checkbox"
103
+ .checked=${this.checked}
104
+ .indeterminate=${this.indeterminate}
105
+ ?disabled=${this.disabled}
106
+ aria-hidden="true"
107
+ tabindex="-1"
108
+ @change=${toggle}
109
+ />
110
+ ${checkboxToggle({
111
+ checked: this.checked,
112
+ indeterminate: this.indeterminate,
113
+ disabled: this.disabled,
114
+ invalid: false
115
+ })}
116
+ </div>
117
+ `;
118
+ };
119
+ _renderLead = new WeakSet();
120
+ renderLead_fn = function() {
121
+ if (this.selectable)
122
+ return __privateMethod(this, _renderCheckbox, renderCheckbox_fn).call(this);
123
+ return html``;
124
+ };
125
+ _renderItems = new WeakSet();
126
+ renderItems_fn = function(col, alignEnd = false) {
127
+ return html`
128
+ <div class="item-column ${alignEnd ? "align-end" : ""}">
129
+ ${when(
130
+ col.label,
131
+ () => html`<gds-text font="detail-s-regular" tag="label"
132
+ >${col.label}</gds-text
133
+ >`
134
+ )}
135
+ <gds-text font="detail-m-book" tag="span">${col.value}</gds-text>
136
+ </div>
137
+ `;
138
+ };
139
+ _onLeadSlotChange = new WeakSet();
140
+ onLeadSlotChange_fn = function(e) {
141
+ const slot = e.target;
142
+ this._hasLead = slot.assignedElements().length > 0;
143
+ };
144
+ _onTrailSlotChange = new WeakSet();
145
+ onTrailSlotChange_fn = function(e) {
146
+ const slot = e.target;
147
+ this._hasTrailContent = slot.assignedElements().length > 0 || __privateGet(this, _isLinked, isLinked_get);
148
+ };
149
+ _renderMain = new WeakSet();
150
+ renderMain_fn = function() {
151
+ if (this.items && this.items.length > 0) {
152
+ const wrap = this.items.length >= 3 ? "wrap" : "nowrap";
153
+ const alignLastEnd = this.items.length >= 2 && !this._isWrapped;
154
+ return html`
155
+ <slot name="lead" @slotchange=${__privateMethod(this, _onLeadSlotChange, onLeadSlotChange_fn)}></slot>
156
+ <gds-flex
157
+ class="items-container"
158
+ flex="1"
159
+ justify-content="space-between"
160
+ gap="l"
161
+ flex-wrap=${wrap}
162
+ >
163
+ ${this.items.map((col, i) => {
164
+ const isLast = i === this.items.length - 1;
165
+ return __privateMethod(this, _renderItems, renderItems_fn).call(this, i === 0 && this.label && !col.label ? { ...col, label: this.label } : col, alignLastEnd && isLast);
166
+ })}
167
+ </gds-flex>
168
+ <slot></slot>
169
+ `;
170
+ }
171
+ return html`<slot name="lead" @slotchange=${__privateMethod(this, _onLeadSlotChange, onLeadSlotChange_fn)}></slot
172
+ ><slot></slot>`;
173
+ };
174
+ _renderTrail = new WeakSet();
175
+ renderTrail_fn = function() {
176
+ const classes = classMap({
177
+ "has-content": this._hasTrailContent
178
+ });
179
+ return html`
180
+ <slot name="trail" @slotchange=${__privateMethod(this, _onTrailSlotChange, onTrailSlotChange_fn)} class=${classes}
181
+ >${when(
182
+ this.href,
183
+ () => html`<gds-icon-chevron-right></gds-icon-chevron-right>`
184
+ )}</slot
185
+ >
186
+ `;
187
+ };
188
+ _renderRowContent = new WeakSet();
189
+ renderRowContent_fn = function() {
190
+ if (__privateGet(this, _isLinked, isLinked_get) && this.selectable) {
191
+ return html`
192
+ ${__privateMethod(this, _renderLead, renderLead_fn).call(this)} ${__privateMethod(this, _renderMain, renderMain_fn).call(this)}
193
+ <gds-button
194
+ slot="trail"
195
+ href=${ifDefined(this.href)}
196
+ target=${ifDefined(this.target)}
197
+ rel=${ifDefined(this.rel)}
198
+ download=${ifDefined(this.download)}
199
+ ping=${ifDefined(this.ping)}
200
+ rank="tertiary"
201
+ aria-label=${this.label || "Navigate"}
202
+ ><gds-icon-chevron-right></gds-icon-chevron-right
203
+ ></gds-button>
204
+ `;
205
+ }
206
+ if (__privateGet(this, _isLinked, isLinked_get)) {
207
+ const classes = classMap({
208
+ "has-lead": this._hasLead
209
+ });
210
+ return html`
211
+ ${__privateMethod(this, _renderLead, renderLead_fn).call(this)}
212
+ <a
213
+ class="linked-area ${classes}"
214
+ href=${ifDefined(this.href)}
215
+ target=${ifDefined(this.target)}
216
+ rel=${ifDefined(this.rel)}
217
+ download=${ifDefined(this.download)}
218
+ ping=${ifDefined(this.ping)}
219
+ >
220
+ ${__privateMethod(this, _renderMain, renderMain_fn).call(this)} ${__privateMethod(this, _renderTrail, renderTrail_fn).call(this)}
221
+ </a>
222
+ `;
223
+ }
224
+ return html`${__privateMethod(this, _renderLead, renderLead_fn).call(this)} ${__privateMethod(this, _renderMain, renderMain_fn).call(this)}
225
+ ${__privateMethod(this, _renderTrail, renderTrail_fn).call(this)}`;
226
+ };
227
+ GdsListItemPattern01.styles = [tokens, rbcbToggleStyles, ListPattern01ItemStyles];
228
+ __decorateClass([
229
+ state()
230
+ ], GdsListItemPattern01.prototype, "_isWrapped", 2);
231
+ __decorateClass([
232
+ state()
233
+ ], GdsListItemPattern01.prototype, "_hasLead", 2);
234
+ __decorateClass([
235
+ query(".items-container")
236
+ ], GdsListItemPattern01.prototype, "_itemsContainer", 2);
237
+ __decorateClass([
238
+ resizeObserver()
239
+ ], GdsListItemPattern01.prototype, "_checkWrap", 1);
240
+ __decorateClass([
241
+ property({ type: Array })
242
+ ], GdsListItemPattern01.prototype, "items", 2);
243
+ __decorateClass([
244
+ property({ reflect: true })
245
+ ], GdsListItemPattern01.prototype, "label", 2);
246
+ __decorateClass([
247
+ property({ type: Boolean, reflect: true })
248
+ ], GdsListItemPattern01.prototype, "selectable", 2);
249
+ __decorateClass([
250
+ property({ type: Boolean, reflect: true })
251
+ ], GdsListItemPattern01.prototype, "checked", 2);
252
+ __decorateClass([
253
+ property({ type: Boolean, reflect: true })
254
+ ], GdsListItemPattern01.prototype, "indeterminate", 2);
255
+ __decorateClass([
256
+ property({ type: Boolean, reflect: true })
257
+ ], GdsListItemPattern01.prototype, "disabled", 2);
258
+ __decorateClass([
259
+ styleExpressionProperty({ ...forSpaceTokensAndCustomValues, reflect: true })
260
+ ], GdsListItemPattern01.prototype, "padding-inline", 2);
261
+ __decorateClass([
262
+ state()
263
+ ], GdsListItemPattern01.prototype, "_hasTrailContent", 2);
264
+ GdsListItemPattern01 = __decorateClass([
265
+ gdsCustomElement("gds-list-item-pattern-01", {
266
+ dependsOn: [
267
+ GdsFlex,
268
+ GdsText,
269
+ GdsButton,
270
+ IconCheckmark,
271
+ IconMinusSmall,
272
+ IconChevronRight
273
+ ]
274
+ })
275
+ ], GdsListItemPattern01);
276
+ export {
277
+ GdsListItemPattern01
278
+ };
@@ -0,0 +1,2 @@
1
+ import { GdsListItemPattern01 } from './list-item-pattern-01.component';
2
+ export { GdsListItemPattern01 };
@@ -0,0 +1,6 @@
1
+ import "../../chunks/chunk.CAV4X6PU.js";
2
+ import { GdsListItemPattern01 } from "./list-item-pattern-01.component.js";
3
+ GdsListItemPattern01.define();
4
+ export {
5
+ GdsListItemPattern01
6
+ };
@@ -0,0 +1,4 @@
1
+ export declare const listPattern01Items: (items: number) => {
2
+ label: string;
3
+ value: string;
4
+ }[];
@@ -0,0 +1,8 @@
1
+ import "../../chunks/chunk.CAV4X6PU.js";
2
+ const listPattern01Items = (items) => Array.from({ length: items }, (_, i) => ({
3
+ label: `Item ${i + 1}`,
4
+ value: `Value ${i + 1}`
5
+ }));
6
+ export {
7
+ listPattern01Items
8
+ };
@@ -0,0 +1,2 @@
1
+ declare const style: import("lit").CSSResult;
2
+ export default style;
@@ -0,0 +1,113 @@
1
+ import "../../chunks/chunk.CAV4X6PU.js";
2
+ import { css } from "lit";
3
+ const style = css`
4
+ :host {
5
+ display: flex;
6
+ align-items: center;
7
+ gap: var(--gds-sys-space-s);
8
+ padding: var(--gds-sys-space-s);
9
+ padding-inline: var(--gds-sys-space-s);
10
+ border-radius: var(--gds-sys-space-2xs);
11
+ transition:
12
+ background-color 0.15s ease,
13
+ box-shadow 0.15s ease;
14
+ }
15
+
16
+ /* Anchor wrapping main when href is set */
17
+ .linked-area {
18
+ flex: 1;
19
+ display: flex;
20
+ align-items: center;
21
+ align-self: stretch;
22
+ gap: var(--gds-sys-space-s);
23
+ text-decoration: none;
24
+ color: inherit;
25
+ cursor: pointer;
26
+ border-radius: var(--gds-sys-space-2xs);
27
+ transition:
28
+ background-color 0.15s ease,
29
+ box-shadow 0.15s ease;
30
+ /* Extend hover to top, and bottom edges of the host */
31
+ margin-top: calc(-1 * var(--gds-sys-space-s));
32
+ margin-bottom: calc(-1 * var(--gds-sys-space-s));
33
+ padding: var(--gds-sys-space-s);
34
+ /* Pre-set transparent outline so it animates in on focus (same pattern as gds-button) */
35
+ outline-color: transparent;
36
+ outline-offset: calc(-1 * var(--gds-sys-space-4xs));
37
+ outline-style: solid;
38
+ outline-width: var(--gds-sys-space-4xs);
39
+ }
40
+
41
+ .linked-area:focus {
42
+ outline-color: var(--gds-sys-color-content-neutral-01);
43
+ }
44
+
45
+ .linked-area:focus:not(:focus-visible) {
46
+ outline-color: transparent;
47
+ }
48
+
49
+ @media (pointer: fine) {
50
+ .linked-area:hover {
51
+ background-color: color-mix(
52
+ in srgb,
53
+ var(--gds-sys-color-l2-neutral-01),
54
+ var(--gds-sys-color-state-neutral-03)
55
+ );
56
+ padding: var(--gds-sys-space-s);
57
+ }
58
+ }
59
+
60
+ .linked-area:active {
61
+ background-color: color-mix(
62
+ in srgb,
63
+ var(--gds-sys-color-l2-neutral-01),
64
+ var(--gds-sys-color-state-neutral-04)
65
+ );
66
+ }
67
+
68
+ .linked-area .has-lead {
69
+ flex-shrink: 0;
70
+ display: flex;
71
+ align-items: center;
72
+ }
73
+
74
+ slot[name='trail'] {
75
+ margin-inline-start: auto;
76
+ flex-shrink: 0;
77
+ display: flex;
78
+ align-items: center;
79
+ justify-content: end;
80
+ }
81
+
82
+ slot[name='trail']:not(.has-content) {
83
+ display: none;
84
+ }
85
+
86
+ :host([href]) slot[name='trail'] {
87
+ display: flex;
88
+ min-width: 40px;
89
+ }
90
+
91
+ .rbcb-wrapper {
92
+ display: flex;
93
+ align-items: center;
94
+ cursor: pointer;
95
+ outline: none;
96
+ }
97
+
98
+ .item-column {
99
+ display: flex;
100
+ flex-direction: column;
101
+ gap: var(--gds-sys-space-4xs);
102
+ justify-content: center;
103
+ text-align: start;
104
+ }
105
+
106
+ .item-column.align-end {
107
+ text-align: end;
108
+ }
109
+ `;
110
+ var list_item_pattern_01_styles_default = style;
111
+ export {
112
+ list_item_pattern_01_styles_default as default
113
+ };
package/pure.d.ts CHANGED
@@ -33,6 +33,8 @@ export * from './components/icon/icons/pure';
33
33
  export * from './components/img/img.component';
34
34
  export * from './components/input/input.component';
35
35
  export * from './components/link/link.component';
36
+ export * from './components/list/list.component';
37
+ export * from './components/list/list-item/list-item.component';
36
38
  export * from './components/mask/mask.component';
37
39
  export * from './components/menu-button/menu-button.component';
38
40
  export * from './components/pagination/pagination.component';
@@ -54,3 +56,4 @@ export * from './components/textarea/textarea.component';
54
56
  export * from './components/theme/theme.component';
55
57
  export * from './components/video/video.component';
56
58
  export * from './patterns/card-pattern-01/card-pattern-01.component';
59
+ export * from './patterns/list-item-pattern-01/list-item-pattern-01.component';
package/pure.js CHANGED
@@ -33,6 +33,8 @@ export * from "./components/icon/icons/pure.js";
33
33
  export * from "./components/img/img.component.js";
34
34
  export * from "./components/input/input.component.js";
35
35
  export * from "./components/link/link.component.js";
36
+ export * from "./components/list/list.component.js";
37
+ export * from "./components/list/list-item/list-item.component.js";
36
38
  export * from "./components/mask/mask.component.js";
37
39
  export * from "./components/menu-button/menu-button.component.js";
38
40
  export * from "./components/pagination/pagination.component.js";
@@ -54,3 +56,4 @@ export * from "./components/textarea/textarea.component.js";
54
56
  export * from "./components/theme/theme.component.js";
55
57
  export * from "./components/video/video.component.js";
56
58
  export * from "./patterns/card-pattern-01/card-pattern-01.component.js";
59
+ export * from "./patterns/list-item-pattern-01/list-item-pattern-01.component.js";
@@ -1,6 +1,6 @@
1
1
  import "../../chunks/chunk.CAV4X6PU.js";
2
2
  import { html as litHtml } from "lit";
3
- const VER_SUFFIX = "-0e517f";
3
+ const VER_SUFFIX = "-1035d1";
4
4
  class ScopedElementRegistry {
5
5
  static get instance() {
6
6
  if (!globalThis.__gdsElementLookupTable?.[VER_SUFFIX])