@justeattakeaway/pie-list 0.2.0 → 0.4.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.
package/README.md CHANGED
@@ -21,7 +21,23 @@
21
21
  - [CSS Variables](#css-variables)
22
22
  - [Events](#events)
23
23
  - [Accessibility](#accessibility)
24
+ - [You never set ARIA on a list item or its slotted content](#you-never-set-aria-on-a-list-item-or-its-slotted-content)
25
+ - [How the naming is derived](#how-the-naming-is-derived)
24
26
  - [Usage Examples](#usage-examples)
27
+ - [Basic list](#basic-list)
28
+ - [Leading and trailing content](#leading-and-trailing-content)
29
+ - [Trailing tag](#trailing-tag)
30
+ - [Meta text](#meta-text)
31
+ - [Bold primary text](#bold-primary-text)
32
+ - [Compact list](#compact-list)
33
+ - [Media](#media)
34
+ - [Overriding alignment and padding](#overriding-alignment-and-padding)
35
+ - [Selectable lists](#selectable-lists)
36
+ - [Single-select (radios)](#single-select-radios)
37
+ - [Multi-select (checkboxes)](#multi-select-checkboxes)
38
+ - [Independent toggles (switches)](#independent-toggles-switches)
39
+ - [Link items](#link-items)
40
+ - [Framework variants](#framework-variants)
25
41
  - [Usage Notes and Rules](#usage-notes-and-rules)
26
42
  - [Questions and Support](#questions-and-support)
27
43
  - [Contributing](#contributing)
@@ -55,7 +71,7 @@ Ideally, you should install the component using the **`@justeattakeaway/pie-webc
55
71
  | `isCompact` | `true`, `false` | Decreases the item height to save vertical space. See the [rules](#usage-notes-and-rules) below. | `false` |
56
72
  | `isBold` | `true`, `false` | Sets the primary text to a bold font-weight. | `false` |
57
73
  | `hasMedia` | `true`, `false` | **Required whenever you slot a media element (e.g. `pie-thumbnail`) into the item.** Reduces the block padding so single-line media sits correctly (this padding adjustment has no effect when `secondaryText` is set, but you should still set `hasMedia`). | `false` |
58
- | `selectionType` | `"none"`, `"radio"`, `"checkbox"`, `"switch"` | Declares that the item hosts an interactive control in its `leading`/`trailing` slot, making the **whole row** a selectable target. Set it on each selectable row. Inside a `pie-radio-group`, the group lays the rows out as a divided list automatically. See [Selectable lists](#selectable-lists). | `"none"` |
74
+ | `interactionType` | `"none"`, `"radio"`, `"checkbox"`, `"switch"`, `"link"` | Declares how the **whole row** behaves, and drives its role, accessible naming, click forwarding and interactive states from this one prop. `"none"` is a static item; `"radio"`/`"checkbox"`/`"switch"` host the matching control in the `leading`/`trailing` slot; `"link"` turns the row into a single navigation link (slot an empty `<a slot="link" href="...">`). See [Selectable lists](#selectable-lists) and [Link items](#link-items). | `"none"` |
59
75
  | `disabled` | `true`, `false` | Marks the row as disabled: it takes the disabled styling and stops forwarding row clicks to its control. Set it alongside the slotted control's own `disabled` (the control still governs its own interactivity). No visible effect on a non-selectable (static) item. | `false` |
60
76
 
61
77
  ### Slots
@@ -66,6 +82,7 @@ Slots are provided by `pie-list-item`.
66
82
  |---|---|
67
83
  | `leading` | Content displayed at the start of the item, before the text. Intended for a small icon or a media element (e.g. `pie-thumbnail`). If slotting `pie-thumbnail`, it MUST use `size="40"`; this is the only size that fits the list-item layout correctly. |
68
84
  | `trailing` | Content displayed at the end of the item, after the text. Intended for a small icon, a `pie-tag`, etc. Not rendered when `metaText` is set. |
85
+ | `link` | Only rendered when `interactionType="link"`. Slot a single **empty** anchor (`<a slot="link" href="...">`) here. It is stretched over the whole row so the entire item becomes the navigation target. The item supplies the anchor's accessible name and description from its text, so the anchor must contain no text of its own; apply any native anchor attributes you need (`href`, `target`, `rel`, and so on). See [Link items](#link-items). |
69
86
 
70
87
  The permitted slotted elements are: a PIE WEBC icon, `pie-tag`, `pie-thumbnail`, `pie-avatar`*, `pie-switch`, and native HTML radio/checkbox inputs.
71
88
  Some slotted content is designed with specific properties being used. So please read the entire readme to understand correct slot usage.
@@ -116,9 +133,36 @@ This component does not emit any custom events. To listen for interactions, trea
116
133
  </pie-list>
117
134
  ```
118
135
 
136
+ ### You never set ARIA on a list item or its slotted content
137
+
138
+ > [!IMPORTANT]
139
+ > You do **not** add any ARIA attributes to a `pie-list-item`, nor to the control, anchor, icon or media you slot into it. The item manages all of that for you, driven entirely by the `primaryText`, `secondaryText` and `metaText` props (and the `interactionType`). Just provide the text and slot the element in.
140
+
141
+ Specifically, for **every** interaction type the item takes care of:
142
+
143
+ - the **role** on the item itself (`listitem`, or `presentation` for radio/checkbox rows so the group owns the control directly) - you never write `role="..."`;
144
+ - the **accessible name and description** of whatever it hosts - you never write `aria-label`, `aria-labelledby`, `aria-description` or `aria-describedby` on the control or anchor;
145
+ - **hiding the duplicated visible text** from assistive technology (the item `aria-hidden`s its own text once the name/description have been mirrored onto the interactive element), so nothing is announced twice.
146
+
147
+ The one accessibility attribute you **do** own is the accessible name of the `pie-list` container itself (`aria-label` / `aria-labelledby`), because only you know what the list represents. See the note above.
148
+
149
+ ### How the naming is derived
150
+
151
+ When a `pie-list-item` hosts an interactive element (a slotted control set via `interactionType="radio" | "checkbox" | "switch"`, or a slotted link anchor via `interactionType="link"`) it generates that element's accessibility naming from its own text:
152
+
153
+ - `primaryText` becomes the control's **accessible name**;
154
+ - `secondaryText` and `metaText` become its **accessible description** (combined with a full stop when both are present);
155
+ - the visible text rendered inside the item is `aria-hidden`, so a screen reader announces the name and description once (via the control) rather than twice.
156
+
157
+ How the naming reaches the element differs by type, but this is entirely internal - you never do it yourself. Selection controls receive it through a shared context and each applies it to the element that carries its role: `pie-radio` names its host, while `pie-checkbox` and `pie-switch` name their internal `input` (their host is role-less). A link anchor is a plain light-DOM element (not a PIE control), so `pie-list-item` sets `aria-label` and `aria-description` on it directly.
158
+
159
+ **If you do set something yourself, it always wins.** If a slotted control already has its own name (its `label` or `aria` prop), or the slotted anchor already has an `aria-label`/`aria-labelledby` (or `aria-description`/`aria-describedby`), the item leaves it untouched and does not overwrite it. This is an escape hatch for the rare case that needs it, not something you normally reach for.
160
+
119
161
  ## Usage Examples
120
162
 
121
- **For HTML:**
163
+ The examples below use HTML. For framework-specific syntax, see [Framework variants](#framework-variants).
164
+
165
+ ### Basic list
122
166
 
123
167
  ```js
124
168
  // import as modules into a js file e.g. main.js
@@ -142,7 +186,7 @@ A basic list with primary, secondary and meta text (note the required `aria-labe
142
186
  <script type="module" src="/main.js"></script>
143
187
  ```
144
188
 
145
- **Leading and trailing content (icons):**
189
+ ### Leading and trailing content
146
190
 
147
191
  ```js
148
192
  import '@justeattakeaway/pie-icons-webc/dist/IconChevronRight.js';
@@ -157,7 +201,7 @@ import '@justeattakeaway/pie-icons-webc/dist/IconChevronRight.js';
157
201
  </pie-list>
158
202
  ```
159
203
 
160
- **Trailing `pie-tag`:**
204
+ ### Trailing tag
161
205
 
162
206
  ```js
163
207
  import '@justeattakeaway/pie-webc/components/tag.js';
@@ -171,7 +215,9 @@ import '@justeattakeaway/pie-webc/components/tag.js';
171
215
  </pie-list>
172
216
  ```
173
217
 
174
- **Meta text** (renders as trailing text; do not combine with the `trailing` slot):
218
+ ### Meta text
219
+
220
+ Renders as trailing text; do not combine with the `trailing` slot:
175
221
 
176
222
  ```html
177
223
  <pie-list>
@@ -182,7 +228,7 @@ import '@justeattakeaway/pie-webc/components/tag.js';
182
228
  </pie-list>
183
229
  ```
184
230
 
185
- **Bold primary text:**
231
+ ### Bold primary text
186
232
 
187
233
  ```html
188
234
  <pie-list>
@@ -190,7 +236,9 @@ import '@justeattakeaway/pie-webc/components/tag.js';
190
236
  </pie-list>
191
237
  ```
192
238
 
193
- **Compact list** (reduced height, see [rules](#usage-notes-and-rules)):
239
+ ### Compact list
240
+
241
+ Reduced height, see [rules](#usage-notes-and-rules):
194
242
 
195
243
  ```html
196
244
  <pie-list>
@@ -203,7 +251,9 @@ import '@justeattakeaway/pie-webc/components/tag.js';
203
251
  </pie-list>
204
252
  ```
205
253
 
206
- **Media (`pie-thumbnail`) in the leading slot:**
254
+ ### Media
255
+
256
+ Slot larger media such as `pie-thumbnail` into the `leading` slot:
207
257
 
208
258
  ```js
209
259
  import '@justeattakeaway/pie-webc/components/thumbnail.js';
@@ -227,7 +277,9 @@ import '@justeattakeaway/pie-webc/components/thumbnail.js';
227
277
  </pie-list>
228
278
  ```
229
279
 
230
- **Overriding alignment and padding** (via CSS variables):
280
+ ### Overriding alignment and padding
281
+
282
+ Via CSS variables:
231
283
 
232
284
  ```html
233
285
  <!-- Vertically centre the content of the items. `--list-item-alignment` must be set on the
@@ -248,18 +300,22 @@ import '@justeattakeaway/pie-webc/components/thumbnail.js';
248
300
 
249
301
  ### Selectable lists
250
302
 
251
- `pie-list` itself is a static container with no selection or keyboard behaviour. To build a **selectable** list, do **not** put the controls in `pie-list`. Instead, place `pie-list-item`s inside a [`pie-radio-group`](https://webc.pie.design/?path=/docs/components-radio-group--overview) (single-select) with `selection-type="radio"`, and slot the control into each item's `leading` (or `trailing`) slot. The group lays the rows out as a divided list automatically.
303
+ `pie-list` itself is a static container with no selection or keyboard behaviour. To build a **selectable** list, do **not** put the controls in `pie-list`. Instead, place `pie-list-item`s inside a [`pie-radio-group`](https://webc.pie.design/?path=/docs/components-radio-group--overview) (single-select) or a [`pie-checkbox-group`](https://webc.pie.design/?path=/docs/components-checkbox-group--overview) (multi-select), set each item's `interactionType`, and slot the control into the item's `leading` (or `trailing`) slot. Switches have no group, so `interactionType="switch"` rows go directly in a `pie-list`.
252
304
 
253
- `selection-type` on each **item** makes that row selectable:
305
+ #### The `interactionType` prop
254
306
 
255
- - takes the correct **role** — `presentation` for `radio`/`checkbox` (so the group owns the controls directly), `listitem` for `switch` and `none`;
256
- - provides its `primaryText`, `secondaryText` and `metaText` as the slotted control's **accessible name and description** (and `aria-hidden`s the now-duplicated visible text);
257
- - **forwards a click** anywhere on the row to the control, so the whole row is a hit target;
258
- - shows **hover and active** states on the row (suppressed when the item's `disabled` is set, or the group is disabled).
307
+ `interactionType` (set to `"radio"`, `"checkbox"` or `"switch"`) is what makes a row selectable. Setting it drives the item to:
259
308
 
260
- Provide the label through the item's `primaryText` — not as the control's own content. The group still owns the group-level semantics (its own role, shared `name`, selection coordination and group-disable).
309
+ - take the correct **role** — `presentation` for `radio`/`checkbox` (so the group owns the controls directly), `listitem` for `switch` and `none`;
310
+ - provide its `primaryText`, `secondaryText` and `metaText` as the slotted control's **accessible name and description** (and `aria-hidden` the now-duplicated visible text);
311
+ - **forward a click** anywhere on the row to the control, so the whole row is a hit target;
312
+ - show **hover and active** states on the row (suppressed when the control is disabled, or when its group is disabled; switches have no group, so only per-row and per-switch disable applies).
261
313
 
262
- Single-select (radios):
314
+ Provide the label through the item's `primaryText` — not as the control's own content. The group still owns the group-level semantics (its own role, shared `name`, selection coordination and group-disable); `interactionType` only governs the item. See the [`pie-radio-group`](https://webc.pie.design/?path=/docs/components-radio-group--overview) and [`pie-checkbox-group`](https://webc.pie.design/?path=/docs/components-checkbox-group--overview) docs for the group behaviour.
315
+
316
+ You do not add any ARIA to the item or the slotted control - `pie-list-item` derives the control's accessible name and description from your `primaryText`, `secondaryText` and `metaText`. See [Accessibility](#accessibility).
317
+
318
+ #### Single-select (radios)
263
319
 
264
320
  ```js
265
321
  import '@justeattakeaway/pie-webc/components/radio-group.js';
@@ -268,18 +324,99 @@ import '@justeattakeaway/pie-webc/components/list-item.js';
268
324
  ```
269
325
 
270
326
  ```html
271
- <!-- `selection-type="radio"` makes each row selectable and the group lays them out as a divided
327
+ <!-- `interactionType="radio"` makes each row selectable and the group lays them out as a divided
272
328
  list. `value` on the group selects the matching radio (here, Express). -->
273
329
  <pie-radio-group name="delivery" value="express">
274
- <pie-list-item selection-type="radio" primaryText="Standard delivery" secondaryText="3 to 5 working days" metaText="Free">
330
+ <pie-list-item interactionType="radio" primaryText="Standard delivery" secondaryText="3 to 5 working days" metaText="Free">
275
331
  <pie-radio slot="leading" value="standard"></pie-radio>
276
332
  </pie-list-item>
277
- <pie-list-item selection-type="radio" primaryText="Express delivery" secondaryText="Next working day" metaText="£4.99">
333
+ <pie-list-item interactionType="radio" primaryText="Express delivery" secondaryText="Next working day" metaText="£4.99">
278
334
  <pie-radio slot="leading" value="express"></pie-radio>
279
335
  </pie-list-item>
280
336
  </pie-radio-group>
281
337
  ```
282
338
 
339
+ #### Multi-select (checkboxes)
340
+
341
+ ```js
342
+ import '@justeattakeaway/pie-webc/components/checkbox-group.js';
343
+ import '@justeattakeaway/pie-webc/components/checkbox.js';
344
+ import '@justeattakeaway/pie-webc/components/list-item.js';
345
+ ```
346
+
347
+ ```html
348
+ <pie-checkbox-group>
349
+ <pie-list-item interactionType="checkbox" primaryText="Cheese" secondaryText="Extra mature" metaText="Free">
350
+ <pie-checkbox slot="leading" name="cheese"></pie-checkbox>
351
+ </pie-list-item>
352
+ <pie-list-item interactionType="checkbox" primaryText="Pepperoni" secondaryText="Spicy">
353
+ <pie-checkbox slot="leading" name="pepperoni"></pie-checkbox>
354
+ </pie-list-item>
355
+ </pie-checkbox-group>
356
+ ```
357
+
358
+ #### Independent toggles (switches)
359
+
360
+ There is no group, so the rows go in a `pie-list` (which needs its own accessible name), and the switch sits in the `trailing` slot. Set `disabled` on the `pie-list-item` alongside any disabled `pie-switch`:
361
+
362
+ ```js
363
+ import '@justeattakeaway/pie-webc/components/list.js';
364
+ import '@justeattakeaway/pie-webc/components/list-item.js';
365
+ import '@justeattakeaway/pie-webc/components/switch.js';
366
+ ```
367
+
368
+ ```html
369
+ <pie-list aria-label="Notification settings">
370
+ <pie-list-item interactionType="switch" primaryText="Email" secondaryText="Order updates and receipts">
371
+ <pie-switch slot="trailing"></pie-switch>
372
+ </pie-list-item>
373
+ <pie-list-item interactionType="switch" primaryText="Push notifications">
374
+ <pie-switch slot="trailing"></pie-switch>
375
+ </pie-list-item>
376
+ <pie-list-item interactionType="switch" primaryText="SMS" disabled>
377
+ <pie-switch slot="trailing" disabled></pie-switch>
378
+ </pie-list-item>
379
+ </pie-list>
380
+ ```
381
+
382
+ Each `pie-switch` manages its own state and emits a native `change` event when toggled. Listen on the switch itself, or on the `pie-list` since the event bubbles. Set a switch's initial state with its `checked` prop. There is no group coordinating them, so each switch is independent.
383
+
384
+ ### Link items
385
+
386
+ Set `interactionType="link"` and slot a single **empty** anchor into the `link` slot to turn the whole row into one navigation link. The anchor is stretched over the entire item (`position: absolute; inset: 0`), so a click or tap anywhere on the row follows the link, and keyboard focus lands on the row as a whole (the focus ring hugs the row).
387
+
388
+ Because the anchor is empty, `pie-list-item` names it from its own text: `primaryText` becomes the anchor's `aria-label` and `secondaryText`/`metaText` its `aria-description`, and the visible text is hidden from assistive technology so nothing is announced twice (see [You never set ARIA on a list item or its slotted content](#you-never-set-aria-on-a-list-item-or-its-slotted-content)). If you set your own `aria-label`/`aria-labelledby` (or `aria-description`/`aria-describedby`) on the anchor, that wins and the item leaves it untouched. Apply whatever native anchor attributes you need (`href`, `target`, `rel`, `download`, and so on); the only requirement is that the anchor **contains no text** (it must stay empty for the naming to work). Give the `pie-list` its own accessible name (e.g. `aria-label`).
389
+
390
+ ```js
391
+ import '@justeattakeaway/pie-webc/components/list.js';
392
+ import '@justeattakeaway/pie-webc/components/list-item.js';
393
+ ```
394
+
395
+ ```html
396
+ <pie-list aria-label="Manage your restaurant">
397
+ <pie-list-item interactionType="link" primaryText="Orders" secondaryText="View and manage live orders" metaText="12 active">
398
+ <a slot="link" href="/orders"></a>
399
+ </pie-list-item>
400
+ <pie-list-item interactionType="link" primaryText="Menu" secondaryText="Edit items, prices and photos">
401
+ <a slot="link" href="/menu"></a>
402
+ </pie-list-item>
403
+ </pie-list>
404
+ ```
405
+
406
+ You are not limited to a raw `<a>`. Any component that renders an anchor and forwards the `slot` attribute works the same way, so in **Next.js you can slot the `next/link` `<Link>` component** (and in Nuxt, `<NuxtLink>`). Slot it into `link`, keep it empty, and `pie-list-item` names it exactly as it names a raw anchor:
407
+
408
+ ```jsx
409
+ // Next.js
410
+ import Link from 'next/link';
411
+ import { PieListItem } from '@justeattakeaway/pie-webc/react/list-item.js';
412
+
413
+ <PieListItem interactionType="link" primaryText="Orders" secondaryText="View and manage live orders">
414
+ <Link slot="link" href="/orders" />
415
+ </PieListItem>
416
+ ```
417
+
418
+ ### Framework variants
419
+
283
420
  **For Native JS Applications, Vue, Angular, Svelte etc.:**
284
421
 
285
422
  ```js
@@ -68,11 +68,11 @@
68
68
  "declarations": [
69
69
  {
70
70
  "kind": "variable",
71
- "name": "selectionTypes",
71
+ "name": "interactionTypes",
72
72
  "type": {
73
- "text": "['none', 'radio', 'checkbox', 'switch']"
73
+ "text": "['none', 'radio', 'checkbox', 'switch', 'link']"
74
74
  },
75
- "default": "['none', 'radio', 'checkbox', 'switch']"
75
+ "default": "['none', 'radio', 'checkbox', 'switch', 'link']"
76
76
  },
77
77
  {
78
78
  "kind": "variable",
@@ -80,15 +80,15 @@
80
80
  "type": {
81
81
  "text": "DefaultProps"
82
82
  },
83
- "default": "{ isCompact: false, isBold: false, hasMedia: false, selectionType: 'none', disabled: false, }"
83
+ "default": "{ isCompact: false, isBold: false, hasMedia: false, interactionType: 'none', disabled: false, }"
84
84
  }
85
85
  ],
86
86
  "exports": [
87
87
  {
88
88
  "kind": "js",
89
- "name": "selectionTypes",
89
+ "name": "interactionTypes",
90
90
  "declaration": {
91
- "name": "selectionTypes",
91
+ "name": "interactionTypes",
92
92
  "module": "src/pie-list-item/defs.js"
93
93
  }
94
94
  },
@@ -118,6 +118,10 @@
118
118
  {
119
119
  "description": "Content shown at the end of the item. Mutually exclusive with `metaText`.",
120
120
  "name": "trailing"
121
+ },
122
+ {
123
+ "description": "Rendered only when `interactionType=\"link\"`. Slot one empty anchor (e.g. `<a slot=\"link\" href=\"/x\">`) stretched over the whole row as the link target. Must contain no text.",
124
+ "name": "link"
121
125
  }
122
126
  ],
123
127
  "members": [
@@ -162,8 +166,8 @@
162
166
  },
163
167
  {
164
168
  "kind": "field",
165
- "name": "selectionType",
166
- "attribute": "selection-type"
169
+ "name": "interactionType",
170
+ "attribute": "interactionType"
167
171
  },
168
172
  {
169
173
  "kind": "field",
@@ -194,7 +198,34 @@
194
198
  },
195
199
  {
196
200
  "kind": "field",
197
- "name": "_hasExplicitRole",
201
+ "name": "_managedRole",
202
+ "type": {
203
+ "text": "string | null"
204
+ },
205
+ "privacy": "private",
206
+ "default": "null"
207
+ },
208
+ {
209
+ "kind": "field",
210
+ "name": "_linkAriaCaptured",
211
+ "type": {
212
+ "text": "boolean"
213
+ },
214
+ "privacy": "private",
215
+ "default": "false"
216
+ },
217
+ {
218
+ "kind": "field",
219
+ "name": "_consumerNamedLink",
220
+ "type": {
221
+ "text": "boolean"
222
+ },
223
+ "privacy": "private",
224
+ "default": "false"
225
+ },
226
+ {
227
+ "kind": "field",
228
+ "name": "_consumerDescribedLink",
198
229
  "type": {
199
230
  "text": "boolean"
200
231
  },
@@ -210,6 +241,24 @@
210
241
  "privacy": "private",
211
242
  "readonly": true
212
243
  },
244
+ {
245
+ "kind": "field",
246
+ "name": "_isLinkRow",
247
+ "type": {
248
+ "text": "boolean"
249
+ },
250
+ "privacy": "private",
251
+ "readonly": true
252
+ },
253
+ {
254
+ "kind": "field",
255
+ "name": "_providesAria",
256
+ "type": {
257
+ "text": "boolean"
258
+ },
259
+ "privacy": "private",
260
+ "readonly": true
261
+ },
213
262
  {
214
263
  "kind": "field",
215
264
  "name": "_ownedByGroup",
@@ -246,7 +295,7 @@
246
295
  "text": "void"
247
296
  }
248
297
  },
249
- "description": "Sets the item's role from `selectionType`: `presentation` for radio/checkbox (so the group\nowns those controls directly), otherwise `listitem` (static items and switches). A role set\nexplicitly by the consumer is left untouched."
298
+ "description": "Sets the item's role from `interactionType`: `presentation` for radio/checkbox (so the group\nowns those controls directly), otherwise `listitem` (static items, switches and links). A role\nset explicitly by the consumer is left untouched, even if it is added or removed dynamically\nafter the element connects."
250
299
  },
251
300
  {
252
301
  "kind": "field",
@@ -264,6 +313,17 @@
264
313
  "privacy": "private",
265
314
  "description": "Forwards a click anywhere on the row to the slotted control, so the whole item is a hit\ntarget. Skips clicks that already landed on the control, to avoid a double toggle."
266
315
  },
316
+ {
317
+ "kind": "method",
318
+ "name": "_applyLinkAria",
319
+ "privacy": "private",
320
+ "return": {
321
+ "type": {
322
+ "text": "void"
323
+ }
324
+ },
325
+ "description": "When the item is a link, names the slotted (empty) anchor from the item's own text: the parent\nowns the child's aria. The anchor is plain light-DOM, so it cannot reference the shadow-DOM text\nvia `aria-labelledby`; and it is not a PIE control that consumes `ariaContext`, so we set the\nattributes imperatively. The visible text is `aria-hidden` in the template, so nothing is\nannounced twice.\n\nA consumer-provided name/description always wins: we capture (once) whether the anchor already\ncarries `aria-label`/`aria-labelledby` or `aria-description`/`aria-describedby` and, if so,\nleave that attribute untouched. Otherwise we keep our generated value in sync with the text."
326
+ },
267
327
  {
268
328
  "kind": "method",
269
329
  "name": "_renderSecondaryText"
@@ -308,8 +368,8 @@
308
368
  "fieldName": "hasMedia"
309
369
  },
310
370
  {
311
- "name": "selection-type",
312
- "fieldName": "selectionType"
371
+ "name": "interactionType",
372
+ "fieldName": "interactionType"
313
373
  },
314
374
  {
315
375
  "name": "disabled",
@@ -4,7 +4,7 @@ const t = class t extends i {
4
4
  this.getAttribute("v") || this.setAttribute("v", t.v);
5
5
  }
6
6
  };
7
- t.v = "0.2.0";
7
+ t.v = "0.4.0";
8
8
  let s = t;
9
9
  export {
10
10
  s as P