Skip to content

Commit 8a9eaa0

Browse files
committed
docs: updates
1 parent 8b852cf commit 8a9eaa0

File tree

4 files changed

+16
-18
lines changed

4 files changed

+16
-18
lines changed

docs/api.md

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ The auro-tail element displays Alaska, Hawaiian, and partner airline tail graphi
1111
| `borderColor` | `border-color` | | `String` | "undefined" | Sets the border color around the tail. |
1212
| `borderWidth` | `border-width` | | `String` | "undefined" | Sets the border width around the tail. |
1313
| `hasBorder` | | readonly | `boolean` | | Checks if tail has border properties defined. |
14-
| `href` | `href` | | `String` | "undefined" | When provided, makes the tail clickable as a hyperlink. |
14+
| `href` | `href` | | `String` | "undefined" | When provided, makes the tail clickable using auro-hyperlink. |
1515
| `isInGroup` | | readonly | `boolean` | | Checks if this tail is inside an auro-tail-group element. |
1616
| `isInHorizontalGroup` | | readonly | `boolean` | | Checks if this tail is in a horizontal group layout. |
1717
| `labelTypeClass` | | readonly | `string` | | Gets the appropriate CSS type class based on tail size. |
@@ -34,16 +34,8 @@ The auro-tail-group element displays multiple auro-tail elements in a grouped la
3434

3535
## Properties
3636

37-
| Property | Attribute | Type | Default | Description |
38-
|---------------|----------------|----------|--------------|--------------------------------------------------|
39-
| `borderColor` | `border-color` | `String` | "undefined" | Sets the border color for all child tails in the group. Does not apply to diagonal layout. |
40-
| `layout` | `layout` | `String` | "horizontal" | Sets the layout direction for the group ('horizontal' or 'vertical'). Default is 'horizontal'. |
41-
| `size` | `size` | `String` | "lg" | Sets the size for all child tails in the group ('xs', 'sm', 'md', 'lg'). Default is 'lg'. xl and 2xl sizes are not supported in groups. |
42-
43-
## Methods
44-
45-
| Method | Type | Description |
46-
|--------------------|---------------------------------------|--------------------------------------------------|
47-
| `createRenderRoot` | `(): HTMLElement \| DocumentFragment` | Prevent shadow DOM creation for unsupported sizes |
48-
| `handleSlotChange` | `(): void` | Handle slot changes to update tails |
49-
| `updateChildTails` | `(): void` | Manages child tails - removes excess tails and updates sizes |
37+
| Property | Attribute | Type | Default | Description |
38+
|---------------|----------------|----------------------------|--------------|--------------------------------------------------|
39+
| `borderColor` | `border-color` | `String` | "undefined" | Sets the border color for all child tails in the group. Does not apply to diagonal layout. |
40+
| `layout` | `layout` | `'horizontal'\|'diagonal'` | "horizontal" | Sets the layout direction for the group. |
41+
| `size` | `size` | `'xs'\|'sm'\|'md'\|'lg'` | "lg" | Sets the size for all child tails in the group. |

docs/partials/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ This file is generated based on a template fetched from `./docs/partials/index.m
3434
There are two important parts of every Auro component. The <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes">class</a> and the custom element. The class is exported and then used as part of defining the Web Component. When importing this component as described in the <a href="#install">install</a> section, the class is imported and the `auro-tail` custom element is defined automatically.
3535

3636
To protect from versioning conflicts with other instances of the component being loaded, it is recommended to use our `AuroTail.register(name)` method and pass in a unique name.
37-
37+
3838
```js
3939
import { AuroTail } from '@aurodesignsystem/auro-tail/class';
4040

src/auro-tail-group.js

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import groupStyleCss from './styles/auro-tail-group.scss';
66
/**
77
* The auro-tail-group element displays multiple auro-tail elements in a grouped layout. When tails are placed within a group, labels/links and badge logos are not displayed, and only two tails can be paired together.
88
*
9-
* @attr {String} layout - Sets the layout direction for the group ('horizontal' or 'vertical'). Default is 'horizontal'.
10-
* @attr {String} size - Sets the size for all child tails in the group ('xs', 'sm', 'md', 'lg'). Default is 'lg'. xl and 2xl sizes are not supported in groups.
9+
* @attr {'horizontal'|'diagonal'} layout - Sets the layout direction for the group.
10+
* @attr {'xs'|'sm'|'md'|'lg'} size - Sets the size for all child tails in the group.
1111
* @attr {String} border-color - Sets the border color for all child tails in the group. Does not apply to diagonal layout.
1212
*/
1313
export class AuroTailGroup extends LitElement {
@@ -33,7 +33,9 @@ export class AuroTailGroup extends LitElement {
3333

3434
constructor() {
3535
super();
36+
/** @type {'horizontal'|'diagonal'} */
3637
this.layout = 'horizontal';
38+
/** @type {'xs'|'sm'|'md'|'lg'} */
3739
this.size = 'lg';
3840
/** @type {string|undefined} */
3941
this.borderColor = undefined;
@@ -46,7 +48,9 @@ export class AuroTailGroup extends LitElement {
4648

4749
/**
4850
* Prevent shadow DOM creation for unsupported sizes
51+
* @private
4952
*/
53+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
5054
createRenderRoot() {
5155
if (!GROUPS_SIZES.includes(this.size)) {
5256
return this;
@@ -76,6 +80,7 @@ export class AuroTailGroup extends LitElement {
7680

7781
/**
7882
* Manages child tails - removes excess tails and updates sizes
83+
* @private
7984
*/
8085
updateChildTails() {
8186
// Small delay to ensure slotted content is available
@@ -109,6 +114,7 @@ export class AuroTailGroup extends LitElement {
109114

110115
/**
111116
* Handle slot changes to update tails
117+
* @private
112118
*/
113119
handleSlotChange() {
114120
this.updateChildTails();

src/auro-tail.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ import styleCss from './styles/auro-tail.scss';
3131
* @attr {Boolean} outline - Renders the tail with an outline style.
3232
* @attr {String} border-width - Sets the border width around the tail.
3333
* @attr {String} border-color - Sets the border color around the tail.
34-
* @attr {String} href - When provided, makes the tail clickable as a hyperlink.
34+
* @attr {String} href - When provided, makes the tail clickable using auro-hyperlink.
3535
*
3636
* @fires {CustomEvent<{ href: string }>} href-click - Fired when the auro-hyperlink is clicked.
3737
*/

0 commit comments

Comments
 (0)