@orange-halo/components 2.2.0 → 3.1.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/custom-elements.json +565 -328
- package/dist/base.d.ts.map +1 -1
- package/dist/base.js +7 -0
- package/dist/base.js.map +1 -1
- package/dist/index.d.ts +2 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +0 -4
- package/dist/index.js.map +1 -1
- package/dist/oh-accordion.d.ts +53 -8
- package/dist/oh-accordion.d.ts.map +1 -1
- package/dist/oh-accordion.js +83 -21
- package/dist/oh-accordion.js.map +1 -1
- package/dist/oh-alert.d.ts +26 -8
- package/dist/oh-alert.d.ts.map +1 -1
- package/dist/oh-alert.js +32 -14
- package/dist/oh-alert.js.map +1 -1
- package/dist/oh-badge.d.ts +32 -13
- package/dist/oh-badge.d.ts.map +1 -1
- package/dist/oh-badge.js +35 -16
- package/dist/oh-badge.js.map +1 -1
- package/dist/oh-breadcrumb.d.ts +39 -12
- package/dist/oh-breadcrumb.d.ts.map +1 -1
- package/dist/oh-breadcrumb.js +43 -21
- package/dist/oh-breadcrumb.js.map +1 -1
- package/dist/oh-button.d.ts +50 -24
- package/dist/oh-button.d.ts.map +1 -1
- package/dist/oh-button.js +66 -47
- package/dist/oh-button.js.map +1 -1
- package/dist/oh-card.d.ts +47 -19
- package/dist/oh-card.d.ts.map +1 -1
- package/dist/oh-card.js +110 -82
- package/dist/oh-card.js.map +1 -1
- package/dist/oh-checkbox-group.d.ts +56 -12
- package/dist/oh-checkbox-group.d.ts.map +1 -1
- package/dist/oh-checkbox-group.js +87 -45
- package/dist/oh-checkbox-group.js.map +1 -1
- package/dist/oh-checkbox.d.ts +55 -18
- package/dist/oh-checkbox.d.ts.map +1 -1
- package/dist/oh-checkbox.js +91 -59
- package/dist/oh-checkbox.js.map +1 -1
- package/dist/oh-cluster.d.ts +19 -14
- package/dist/oh-cluster.d.ts.map +1 -1
- package/dist/oh-cluster.js +19 -19
- package/dist/oh-cluster.js.map +1 -1
- package/dist/oh-container.d.ts +19 -16
- package/dist/oh-container.d.ts.map +1 -1
- package/dist/oh-container.js +26 -33
- package/dist/oh-container.js.map +1 -1
- package/dist/oh-drawer.d.ts +36 -14
- package/dist/oh-drawer.d.ts.map +1 -1
- package/dist/oh-drawer.js +57 -26
- package/dist/oh-drawer.js.map +1 -1
- package/dist/oh-footer.d.ts +37 -18
- package/dist/oh-footer.d.ts.map +1 -1
- package/dist/oh-footer.js +38 -19
- package/dist/oh-footer.js.map +1 -1
- package/dist/oh-grid.d.ts +27 -14
- package/dist/oh-grid.d.ts.map +1 -1
- package/dist/oh-grid.js +27 -19
- package/dist/oh-grid.js.map +1 -1
- package/dist/oh-icon.d.ts +21 -5
- package/dist/oh-icon.d.ts.map +1 -1
- package/dist/oh-icon.js +28 -5
- package/dist/oh-icon.js.map +1 -1
- package/dist/oh-input.d.ts +105 -21
- package/dist/oh-input.d.ts.map +1 -1
- package/dist/oh-input.js +207 -68
- package/dist/oh-input.js.map +1 -1
- package/dist/oh-link.d.ts +42 -19
- package/dist/oh-link.d.ts.map +1 -1
- package/dist/oh-link.js +56 -34
- package/dist/oh-link.js.map +1 -1
- package/dist/oh-modal.d.ts +29 -6
- package/dist/oh-modal.d.ts.map +1 -1
- package/dist/oh-modal.js +37 -16
- package/dist/oh-modal.js.map +1 -1
- package/dist/oh-navbar.d.ts +42 -19
- package/dist/oh-navbar.d.ts.map +1 -1
- package/dist/oh-navbar.js +44 -21
- package/dist/oh-navbar.js.map +1 -1
- package/dist/oh-progress.d.ts +26 -7
- package/dist/oh-progress.d.ts.map +1 -1
- package/dist/oh-progress.js +32 -13
- package/dist/oh-progress.js.map +1 -1
- package/dist/oh-radio-group.d.ts +55 -13
- package/dist/oh-radio-group.d.ts.map +1 -1
- package/dist/oh-radio-group.js +84 -44
- package/dist/oh-radio-group.js.map +1 -1
- package/dist/oh-radio.d.ts +56 -18
- package/dist/oh-radio.d.ts.map +1 -1
- package/dist/oh-radio.js +93 -60
- package/dist/oh-radio.js.map +1 -1
- package/dist/oh-select.d.ts +58 -16
- package/dist/oh-select.d.ts.map +1 -1
- package/dist/oh-select.js +72 -36
- package/dist/oh-select.js.map +1 -1
- package/dist/oh-skip-link.d.ts +33 -15
- package/dist/oh-skip-link.d.ts.map +1 -1
- package/dist/oh-skip-link.js +39 -26
- package/dist/oh-skip-link.js.map +1 -1
- package/dist/oh-stack.d.ts +17 -14
- package/dist/oh-stack.d.ts.map +1 -1
- package/dist/oh-stack.js +18 -20
- package/dist/oh-stack.js.map +1 -1
- package/dist/oh-tabs.d.ts +56 -30
- package/dist/oh-tabs.d.ts.map +1 -1
- package/dist/oh-tabs.js +89 -70
- package/dist/oh-tabs.js.map +1 -1
- package/dist/oh-textarea.d.ts +37 -6
- package/dist/oh-textarea.d.ts.map +1 -1
- package/dist/oh-textarea.js +40 -9
- package/dist/oh-textarea.js.map +1 -1
- package/dist/oh-toggle.d.ts +45 -12
- package/dist/oh-toggle.d.ts.map +1 -1
- package/dist/oh-toggle.js +68 -33
- package/dist/oh-toggle.js.map +1 -1
- package/dist/styles/typography.d.ts.map +1 -1
- package/dist/styles/typography.js +1 -2
- package/dist/styles/typography.js.map +1 -1
- package/package.json +3 -7
- package/dist/oh-button.figma.d.ts +0 -2
- package/dist/oh-button.figma.d.ts.map +0 -1
- package/dist/oh-button.figma.js +0 -18
- package/dist/oh-button.figma.js.map +0 -1
- package/dist/oh-checkbox-group.figma.d.ts +0 -2
- package/dist/oh-checkbox-group.figma.d.ts.map +0 -1
- package/dist/oh-checkbox-group.figma.js +0 -24
- package/dist/oh-checkbox-group.figma.js.map +0 -1
- package/dist/oh-hero.d.ts +0 -33
- package/dist/oh-hero.d.ts.map +0 -1
- package/dist/oh-hero.js +0 -248
- package/dist/oh-hero.js.map +0 -1
- package/dist/oh-input.figma.d.ts +0 -2
- package/dist/oh-input.figma.d.ts.map +0 -1
- package/dist/oh-input.figma.js +0 -36
- package/dist/oh-input.figma.js.map +0 -1
- package/dist/oh-radio-group.figma.d.ts +0 -2
- package/dist/oh-radio-group.figma.d.ts.map +0 -1
- package/dist/oh-radio-group.figma.js +0 -22
- package/dist/oh-radio-group.figma.js.map +0 -1
package/dist/oh-alert.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-alert.js","sourceRoot":"","sources":["../src/oh-alert.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-alert.js","sourceRoot":"","sources":["../src/oh-alert.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;;;;;;;AAEH,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAIlD;;;;;;;;;;;;;;;;;;;GAmBG;AAEI,IAAM,OAAO,GAAb,MAAM,OAAQ,SAAQ,SAAS;IAA/B;;QA8NL,YAAO,GAAiB,MAAM,CAAC;QAG/B,gBAAW,GAAG,KAAK,CAAC;QAEpB;;;WAGG;QAEH,SAAI,GAAG,KAAK,CAAC;IA6Gf,CAAC;aApViB,WAAM,GAAG;QACvB,UAAU;QACV,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAuNF;KACF,AA1NqB,CA0NpB;IAeM,cAAc;QACpB,IAAI,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;QACxB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;IACrB,CAAC;IAEO,QAAQ;QACd,QAAQ,IAAI,CAAC,OAAO,EAAE,CAAC;YACrB,KAAK,SAAS;gBACZ,OAAO,IAAI,CAAA;;;;;;;;;;;;;SAaV,CAAC;YACJ,KAAK,OAAO;gBACV,OAAO,IAAI,CAAA;;;;;;;;;;;;;SAaV,CAAC;YACJ,KAAK,SAAS;gBACZ,OAAO,IAAI,CAAA;;;;;;;;;;;;;SAaV,CAAC;YACJ,KAAK,MAAM,CAAC;YACZ;gBACE,OAAO,IAAI,CAAA;;;;;;;;;;;;;SAaV,CAAC;QACN,CAAC;IACH,CAAC;IAED,MAAM;QACJ,MAAM,OAAO,GAAG,IAAI,CAAC,QAAQ,CAAC;YAC5B,KAAK,EAAE,IAAI;YACX,CAAC,UAAU,IAAI,CAAC,OAAO,EAAE,CAAC,EAAE,IAAI;SACjC,CAAC,CAAC;QAEH,OAAO,IAAI,CAAA;mBACI,OAAO,SAAS,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO;UACtD,IAAI,CAAC,QAAQ,EAAE;;;;;;UAMf,IAAI,CAAC,WAAW;YAChB,CAAC,CAAC,IAAI,CAAA;;;;;yBAKS,IAAI,CAAC,cAAc;;;;;;;;;;;aAW/B;YACH,CAAC,CAAC,OAAO;;KAEd,CAAC;IACJ,CAAC;;AAtHD;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;wCACX;AAG/B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4CACvB;AAOpB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;qCAC9B;AAxOF,OAAO;IADnB,aAAa,CAAC,UAAU,CAAC;GACb,OAAO,CAqVnB"}
|
package/dist/oh-badge.d.ts
CHANGED
|
@@ -1,33 +1,52 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* oh-badge
|
|
3
3
|
*
|
|
4
|
-
* A
|
|
5
|
-
* Two
|
|
4
|
+
* A non-interactive label for a status or category.
|
|
5
|
+
* Two types per variant: subtle and filled.
|
|
6
6
|
*
|
|
7
7
|
* DESIGN DECISIONS:
|
|
8
8
|
* ─────────────────
|
|
9
|
-
* 1.
|
|
10
|
-
* - No
|
|
9
|
+
* 1. NON-INTERACTIVE
|
|
10
|
+
* - No shadow, no hover states, pointer-events off
|
|
11
11
|
* - Pure informational element
|
|
12
12
|
* - Not clickable
|
|
13
13
|
*
|
|
14
|
-
* 2. TWO
|
|
15
|
-
* - Subtle:
|
|
16
|
-
* - Filled:
|
|
14
|
+
* 2. TWO TYPES
|
|
15
|
+
* - Subtle: the variant's *Subtle background token, its role colour as text
|
|
16
|
+
* - Filled: the role colour as background, its color.text.on* token as text
|
|
17
17
|
*
|
|
18
18
|
* 3. ACCESSIBLE CONTRAST
|
|
19
|
-
* -
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* @element oh-badge
|
|
19
|
+
* - Every text/background pair is in contrast-pairs.json, so
|
|
20
|
+
* check:contrast checks it in every brand and mode
|
|
23
21
|
*/
|
|
24
22
|
import { OhElement } from "./base.js";
|
|
25
23
|
export type BadgeVariant = "success" | "error" | "warning" | "info" | "brand" | "accent";
|
|
26
|
-
export type
|
|
24
|
+
export type BadgeAppearance = "subtle" | "filled";
|
|
25
|
+
/**
|
|
26
|
+
* A short, non-interactive label that shows the status or category of the thing next to it.
|
|
27
|
+
*
|
|
28
|
+
* **Use it for** a status ("Delivered", "Pending"), a count or a tag next to the item it describes. **Don't use it for** anything the user can select (use `oh-button` or a link); or for a message with more than a word or two (use `oh-alert`).
|
|
29
|
+
*
|
|
30
|
+
* **Variants:** `brand` (default) and `accent` for categories; `success`, `warning`, `error` and `info` for status. **Appearance:** `subtle` (default), for most badges; `filled`, the stronger appearance, for the one status that matters most.
|
|
31
|
+
*
|
|
32
|
+
* **Parts:** the default slot holds the text; the `icon` slot an optional leading icon, sized to the text.
|
|
33
|
+
*
|
|
34
|
+
* **Behaviour:** none. It doesn't take focus or respond to the pointer.
|
|
35
|
+
*
|
|
36
|
+
* **Accessibility:** the badge is plain text to screen readers, so the text must make sense on its own (say "Pending", don't rely on the colour). Mark a decorative icon `aria-hidden`.
|
|
37
|
+
*
|
|
38
|
+
* **Look:** set by tokens. Subtle uses the variant's `color.feedback.<variant>Subtle`, `color.brand.primarySubtle` or `color.accent.subtle` background with the role colour as text; filled uses the role colour (`color.feedback.<variant>`, `color.brand.primary`, `color.accent.default`) as background with `color.text.on<Role>` as text. `shape.compact` sets the corners; `typography.body.*`, `typography.label.base.fontWeight` and `typography.control.letterSpacing` the text.
|
|
39
|
+
*
|
|
40
|
+
* @element oh-badge
|
|
41
|
+
* @slot - The badge text.
|
|
42
|
+
* @slot icon - Optional leading icon.
|
|
43
|
+
* @csspart badge - The badge.
|
|
44
|
+
*/
|
|
27
45
|
export declare class OhBadge extends OhElement {
|
|
28
46
|
static styles: import("lit").CSSResult[];
|
|
29
47
|
variant: BadgeVariant;
|
|
30
|
-
|
|
48
|
+
/** `subtle` (default) for most badges; `filled`, the stronger appearance, for the one status that matters most */
|
|
49
|
+
appearance: BadgeAppearance;
|
|
31
50
|
render(): import("lit").TemplateResult<1>;
|
|
32
51
|
}
|
|
33
52
|
declare global {
|
package/dist/oh-badge.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-badge.d.ts","sourceRoot":"","sources":["../src/oh-badge.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-badge.d.ts","sourceRoot":"","sources":["../src/oh-badge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAIH,OAAO,EAAE,SAAS,EAAc,MAAM,WAAW,CAAC;AAElD,MAAM,MAAM,YAAY,GACpB,SAAS,GACT,OAAO,GACP,SAAS,GACT,MAAM,GACN,OAAO,GACP,QAAQ,CAAC;AACb,MAAM,MAAM,eAAe,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAElD;;;;;;;;;;;;;;;;;;;GAmBG;AACH,qBACa,OAAQ,SAAQ,SAAS;IACpC,OAAgB,MAAM,4BAgHpB;IAGF,OAAO,EAAE,YAAY,CAAW;IAEhC,kHAAkH;IAElH,UAAU,EAAE,eAAe,CAAY;IAEvC,MAAM;CAcP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,UAAU,EAAE,OAAO,CAAC;KACrB;CACF"}
|
package/dist/oh-badge.js
CHANGED
|
@@ -1,25 +1,23 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* oh-badge
|
|
3
3
|
*
|
|
4
|
-
* A
|
|
5
|
-
* Two
|
|
4
|
+
* A non-interactive label for a status or category.
|
|
5
|
+
* Two types per variant: subtle and filled.
|
|
6
6
|
*
|
|
7
7
|
* DESIGN DECISIONS:
|
|
8
8
|
* ─────────────────
|
|
9
|
-
* 1.
|
|
10
|
-
* - No
|
|
9
|
+
* 1. NON-INTERACTIVE
|
|
10
|
+
* - No shadow, no hover states, pointer-events off
|
|
11
11
|
* - Pure informational element
|
|
12
12
|
* - Not clickable
|
|
13
13
|
*
|
|
14
|
-
* 2. TWO
|
|
15
|
-
* - Subtle:
|
|
16
|
-
* - Filled:
|
|
14
|
+
* 2. TWO TYPES
|
|
15
|
+
* - Subtle: the variant's *Subtle background token, its role colour as text
|
|
16
|
+
* - Filled: the role colour as background, its color.text.on* token as text
|
|
17
17
|
*
|
|
18
18
|
* 3. ACCESSIBLE CONTRAST
|
|
19
|
-
* -
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* @element oh-badge
|
|
19
|
+
* - Every text/background pair is in contrast-pairs.json, so
|
|
20
|
+
* check:contrast checks it in every brand and mode
|
|
23
21
|
*/
|
|
24
22
|
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
25
23
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
@@ -30,18 +28,39 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
30
28
|
import { html, css } from "lit";
|
|
31
29
|
import { customElement, property } from "lit/decorators.js";
|
|
32
30
|
import { OhElement, baseStyles } from "./base.js";
|
|
31
|
+
/**
|
|
32
|
+
* A short, non-interactive label that shows the status or category of the thing next to it.
|
|
33
|
+
*
|
|
34
|
+
* **Use it for** a status ("Delivered", "Pending"), a count or a tag next to the item it describes. **Don't use it for** anything the user can select (use `oh-button` or a link); or for a message with more than a word or two (use `oh-alert`).
|
|
35
|
+
*
|
|
36
|
+
* **Variants:** `brand` (default) and `accent` for categories; `success`, `warning`, `error` and `info` for status. **Appearance:** `subtle` (default), for most badges; `filled`, the stronger appearance, for the one status that matters most.
|
|
37
|
+
*
|
|
38
|
+
* **Parts:** the default slot holds the text; the `icon` slot an optional leading icon, sized to the text.
|
|
39
|
+
*
|
|
40
|
+
* **Behaviour:** none. It doesn't take focus or respond to the pointer.
|
|
41
|
+
*
|
|
42
|
+
* **Accessibility:** the badge is plain text to screen readers, so the text must make sense on its own (say "Pending", don't rely on the colour). Mark a decorative icon `aria-hidden`.
|
|
43
|
+
*
|
|
44
|
+
* **Look:** set by tokens. Subtle uses the variant's `color.feedback.<variant>Subtle`, `color.brand.primarySubtle` or `color.accent.subtle` background with the role colour as text; filled uses the role colour (`color.feedback.<variant>`, `color.brand.primary`, `color.accent.default`) as background with `color.text.on<Role>` as text. `shape.compact` sets the corners; `typography.body.*`, `typography.label.base.fontWeight` and `typography.control.letterSpacing` the text.
|
|
45
|
+
*
|
|
46
|
+
* @element oh-badge
|
|
47
|
+
* @slot - The badge text.
|
|
48
|
+
* @slot icon - Optional leading icon.
|
|
49
|
+
* @csspart badge - The badge.
|
|
50
|
+
*/
|
|
33
51
|
let OhBadge = class OhBadge extends OhElement {
|
|
34
52
|
constructor() {
|
|
35
53
|
super(...arguments);
|
|
36
54
|
this.variant = "brand";
|
|
37
|
-
|
|
55
|
+
/** `subtle` (default) for most badges; `filled`, the stronger appearance, for the one status that matters most */
|
|
56
|
+
this.appearance = "subtle";
|
|
38
57
|
}
|
|
39
58
|
static { this.styles = [
|
|
40
59
|
baseStyles,
|
|
41
60
|
css `
|
|
42
61
|
/* ═══════════════════════════════════════════════════════════════
|
|
43
|
-
|
|
44
|
-
|
|
62
|
+
BADGE
|
|
63
|
+
Non-interactive • Informational
|
|
45
64
|
═══════════════════════════════════════════════════════════════ */
|
|
46
65
|
|
|
47
66
|
:host {
|
|
@@ -153,7 +172,7 @@ let OhBadge = class OhBadge extends OhElement {
|
|
|
153
172
|
const classes = this.classMap({
|
|
154
173
|
badge: true,
|
|
155
174
|
[`badge--${this.variant}`]: true,
|
|
156
|
-
[`badge--${this.
|
|
175
|
+
[`badge--${this.appearance}`]: true,
|
|
157
176
|
});
|
|
158
177
|
return html `
|
|
159
178
|
<span class=${classes} part="badge">
|
|
@@ -168,7 +187,7 @@ __decorate([
|
|
|
168
187
|
], OhBadge.prototype, "variant", void 0);
|
|
169
188
|
__decorate([
|
|
170
189
|
property({ type: String, reflect: true })
|
|
171
|
-
], OhBadge.prototype, "
|
|
190
|
+
], OhBadge.prototype, "appearance", void 0);
|
|
172
191
|
OhBadge = __decorate([
|
|
173
192
|
customElement("oh-badge")
|
|
174
193
|
], OhBadge);
|
package/dist/oh-badge.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-badge.js","sourceRoot":"","sources":["../src/oh-badge.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-badge.js","sourceRoot":"","sources":["../src/oh-badge.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;;;;;;;AAEH,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAChC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAWlD;;;;;;;;;;;;;;;;;;;GAmBG;AAEI,IAAM,OAAO,GAAb,MAAM,OAAQ,SAAQ,SAAS;IAA/B;;QAoHL,YAAO,GAAiB,OAAO,CAAC;QAEhC,kHAAkH;QAElH,eAAU,GAAoB,QAAQ,CAAC;IAgBzC,CAAC;aAvIiB,WAAM,GAAG;QACvB,UAAU;QACV,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KA6GF;KACF,AAhHqB,CAgHpB;IASF,MAAM;QACJ,MAAM,OAAO,GAAG,IAAI,CAAC,QAAQ,CAAC;YAC5B,KAAK,EAAE,IAAI;YACX,CAAC,UAAU,IAAI,CAAC,OAAO,EAAE,CAAC,EAAE,IAAI;YAChC,CAAC,UAAU,IAAI,CAAC,UAAU,EAAE,CAAC,EAAE,IAAI;SACpC,CAAC,CAAC;QAEH,OAAO,IAAI,CAAA;oBACK,OAAO;;;;KAItB,CAAC;IACJ,CAAC;;AAnBD;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;wCACV;AAIhC;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;2CACH;AAxH5B,OAAO;IADnB,aAAa,CAAC,UAAU,CAAC;GACb,OAAO,CAwInB"}
|
package/dist/oh-breadcrumb.d.ts
CHANGED
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* oh-breadcrumb
|
|
3
3
|
*
|
|
4
|
-
* Accessible breadcrumb navigation with responsive collapse.
|
|
5
|
-
*
|
|
6
4
|
* DESIGN DECISIONS:
|
|
7
5
|
* ─────────────────
|
|
8
6
|
* 1. SEMANTIC STRUCTURE
|
|
9
|
-
* - <nav
|
|
10
|
-
* -
|
|
11
|
-
* - aria-
|
|
7
|
+
* - <nav aria-label="Breadcrumb"> around an <ol>
|
|
8
|
+
* - aria-current="page" on the last item, which is not a link
|
|
9
|
+
* - Separators are aria-hidden
|
|
12
10
|
*
|
|
13
|
-
* 2.
|
|
14
|
-
* -
|
|
15
|
-
*
|
|
11
|
+
* 2. LINKS MIRROR oh-link INLINE
|
|
12
|
+
* - Same underline tokens and hover/focus behaviour, written locally
|
|
13
|
+
* so the trail is one component
|
|
16
14
|
*
|
|
17
15
|
* 3. RESPONSIVE
|
|
18
|
-
* -
|
|
19
|
-
* -
|
|
20
|
-
*
|
|
21
|
-
* @element oh-breadcrumb
|
|
16
|
+
* - Wide viewports: the full trail
|
|
17
|
+
* - Below `size.breakpoint.sm`: a single "Back to [parent]" link
|
|
22
18
|
*/
|
|
23
19
|
import { nothing } from "lit";
|
|
24
20
|
import { OhElement } from "./base.js";
|
|
@@ -26,6 +22,37 @@ export interface BreadcrumbItem {
|
|
|
26
22
|
label: string;
|
|
27
23
|
href?: string;
|
|
28
24
|
}
|
|
25
|
+
/**
|
|
26
|
+
* A breadcrumb trail showing where the current page sits in the site's hierarchy.
|
|
27
|
+
*
|
|
28
|
+
* **Use it for** pages two or more levels deep in a hierarchy. **Don't use it
|
|
29
|
+
* for** a site's main navigation (use `oh-navbar`) or for steps in a process.
|
|
30
|
+
*
|
|
31
|
+
* **Parts:** pass `items`, an array of `{ label, href }`, from the top level
|
|
32
|
+
* down. The last item is the current page and is shown as text, not a link.
|
|
33
|
+
*
|
|
34
|
+
* **Behaviour:** below the `size.breakpoint.sm` width the trail collapses to a
|
|
35
|
+
* single "Back to [parent]" link to the second-to-last item; with one item,
|
|
36
|
+
* nothing shows there. Link underlines retract on hover; keyboard focus
|
|
37
|
+
* (`:focus-visible`) shows a solid underline and a background tint.
|
|
38
|
+
* Transitions are cut short under `prefers-reduced-motion`. Renders nothing
|
|
39
|
+
* when `items` is empty.
|
|
40
|
+
*
|
|
41
|
+
* **Accessibility:** renders `<nav aria-label="Breadcrumb">` with an ordered
|
|
42
|
+
* list, `aria-current="page"` on the last item and `aria-hidden` separators.
|
|
43
|
+
* Use one breadcrumb per page.
|
|
44
|
+
*
|
|
45
|
+
* **Look:** set by tokens — `color.text.link` the links,
|
|
46
|
+
* `decoration.underlineThickness`, `decoration.underlineDash` and
|
|
47
|
+
* `decoration.underlinePeriod` their underline; `color.brand.primary` the
|
|
48
|
+
* focus underline and `color.surface.hover` the focus tint;
|
|
49
|
+
* `color.text.primary` and `typography.label.base.fontWeight` the current
|
|
50
|
+
* page; `color.text.secondary` the separators; `typography.body.*` the text;
|
|
51
|
+
* `spacing.*` the gaps; `motion.relaxed` and `motion.easeGentle` the
|
|
52
|
+
* transitions.
|
|
53
|
+
*
|
|
54
|
+
* @element oh-breadcrumb
|
|
55
|
+
*/
|
|
29
56
|
export declare class OhBreadcrumb extends OhElement {
|
|
30
57
|
static styles: import("lit").CSSResult[];
|
|
31
58
|
items: BreadcrumbItem[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-breadcrumb.d.ts","sourceRoot":"","sources":["../src/oh-breadcrumb.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-breadcrumb.d.ts","sourceRoot":"","sources":["../src/oh-breadcrumb.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,EAAa,OAAO,EAAE,MAAM,KAAK,CAAC;AAEzC,OAAO,EAAE,SAAS,EAAc,MAAM,WAAW,CAAC;AAElD,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;CACf;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,qBACa,YAAa,SAAQ,SAAS;IACzC,OAAgB,MAAM,4BA2LpB;IAGF,KAAK,EAAE,cAAc,EAAE,CAAM;IAE7B,MAAM;CA8DP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,eAAe,EAAE,YAAY,CAAC;KAC/B;CACF"}
|
package/dist/oh-breadcrumb.js
CHANGED
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* oh-breadcrumb
|
|
3
3
|
*
|
|
4
|
-
* Accessible breadcrumb navigation with responsive collapse.
|
|
5
|
-
*
|
|
6
4
|
* DESIGN DECISIONS:
|
|
7
5
|
* ─────────────────
|
|
8
6
|
* 1. SEMANTIC STRUCTURE
|
|
9
|
-
* - <nav
|
|
10
|
-
* -
|
|
11
|
-
* - aria-
|
|
7
|
+
* - <nav aria-label="Breadcrumb"> around an <ol>
|
|
8
|
+
* - aria-current="page" on the last item, which is not a link
|
|
9
|
+
* - Separators are aria-hidden
|
|
12
10
|
*
|
|
13
|
-
* 2.
|
|
14
|
-
* -
|
|
15
|
-
*
|
|
11
|
+
* 2. LINKS MIRROR oh-link INLINE
|
|
12
|
+
* - Same underline tokens and hover/focus behaviour, written locally
|
|
13
|
+
* so the trail is one component
|
|
16
14
|
*
|
|
17
15
|
* 3. RESPONSIVE
|
|
18
|
-
* -
|
|
19
|
-
* -
|
|
20
|
-
*
|
|
21
|
-
* @element oh-breadcrumb
|
|
16
|
+
* - Wide viewports: the full trail
|
|
17
|
+
* - Below `size.breakpoint.sm`: a single "Back to [parent]" link
|
|
22
18
|
*/
|
|
23
19
|
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
24
20
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
@@ -29,6 +25,37 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
29
25
|
import { html, css, nothing } from "lit";
|
|
30
26
|
import { customElement, property } from "lit/decorators.js";
|
|
31
27
|
import { OhElement, baseStyles } from "./base.js";
|
|
28
|
+
/**
|
|
29
|
+
* A breadcrumb trail showing where the current page sits in the site's hierarchy.
|
|
30
|
+
*
|
|
31
|
+
* **Use it for** pages two or more levels deep in a hierarchy. **Don't use it
|
|
32
|
+
* for** a site's main navigation (use `oh-navbar`) or for steps in a process.
|
|
33
|
+
*
|
|
34
|
+
* **Parts:** pass `items`, an array of `{ label, href }`, from the top level
|
|
35
|
+
* down. The last item is the current page and is shown as text, not a link.
|
|
36
|
+
*
|
|
37
|
+
* **Behaviour:** below the `size.breakpoint.sm` width the trail collapses to a
|
|
38
|
+
* single "Back to [parent]" link to the second-to-last item; with one item,
|
|
39
|
+
* nothing shows there. Link underlines retract on hover; keyboard focus
|
|
40
|
+
* (`:focus-visible`) shows a solid underline and a background tint.
|
|
41
|
+
* Transitions are cut short under `prefers-reduced-motion`. Renders nothing
|
|
42
|
+
* when `items` is empty.
|
|
43
|
+
*
|
|
44
|
+
* **Accessibility:** renders `<nav aria-label="Breadcrumb">` with an ordered
|
|
45
|
+
* list, `aria-current="page"` on the last item and `aria-hidden` separators.
|
|
46
|
+
* Use one breadcrumb per page.
|
|
47
|
+
*
|
|
48
|
+
* **Look:** set by tokens — `color.text.link` the links,
|
|
49
|
+
* `decoration.underlineThickness`, `decoration.underlineDash` and
|
|
50
|
+
* `decoration.underlinePeriod` their underline; `color.brand.primary` the
|
|
51
|
+
* focus underline and `color.surface.hover` the focus tint;
|
|
52
|
+
* `color.text.primary` and `typography.label.base.fontWeight` the current
|
|
53
|
+
* page; `color.text.secondary` the separators; `typography.body.*` the text;
|
|
54
|
+
* `spacing.*` the gaps; `motion.relaxed` and `motion.easeGentle` the
|
|
55
|
+
* transitions.
|
|
56
|
+
*
|
|
57
|
+
* @element oh-breadcrumb
|
|
58
|
+
*/
|
|
32
59
|
let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
33
60
|
constructor() {
|
|
34
61
|
super(...arguments);
|
|
@@ -37,11 +64,6 @@ let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
|
37
64
|
static { this.styles = [
|
|
38
65
|
baseStyles,
|
|
39
66
|
css `
|
|
40
|
-
/* ═══════════════════════════════════════════════════════════════
|
|
41
|
-
ORANGE HALO BREADCRUMB
|
|
42
|
-
Semantic • Responsive • Accessible
|
|
43
|
-
═══════════════════════════════════════════════════════════════ */
|
|
44
|
-
|
|
45
67
|
:host {
|
|
46
68
|
display: block;
|
|
47
69
|
font-family: var(--oh-typography-body-font-family);
|
|
@@ -93,7 +115,7 @@ let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
|
93
115
|
.breadcrumb-link::after {
|
|
94
116
|
content: "";
|
|
95
117
|
position: absolute;
|
|
96
|
-
|
|
118
|
+
inset-inline-start: 0;
|
|
97
119
|
bottom: 0;
|
|
98
120
|
width: 100%;
|
|
99
121
|
height: var(--oh-decoration-underline-thickness);
|
|
@@ -106,7 +128,7 @@ let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
|
106
128
|
);
|
|
107
129
|
background-size: 100% 100%;
|
|
108
130
|
background-repeat: no-repeat;
|
|
109
|
-
transform-origin:
|
|
131
|
+
transform-origin: calc(50% + 50% * var(--_oh-dir)); /* the end side */
|
|
110
132
|
transition: transform var(--oh-motion-relaxed)
|
|
111
133
|
var(--oh-motion-ease-gentle);
|
|
112
134
|
}
|
|
@@ -160,7 +182,7 @@ let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
|
160
182
|
.back-link::after {
|
|
161
183
|
content: "";
|
|
162
184
|
position: absolute;
|
|
163
|
-
|
|
185
|
+
inset-inline-start: 0;
|
|
164
186
|
bottom: 0;
|
|
165
187
|
width: 100%;
|
|
166
188
|
height: var(--oh-decoration-underline-thickness);
|
|
@@ -173,7 +195,7 @@ let OhBreadcrumb = class OhBreadcrumb extends OhElement {
|
|
|
173
195
|
);
|
|
174
196
|
background-size: 100% 100%;
|
|
175
197
|
background-repeat: no-repeat;
|
|
176
|
-
transform-origin:
|
|
198
|
+
transform-origin: calc(50% + 50% * var(--_oh-dir)); /* the end side */
|
|
177
199
|
transition: transform var(--oh-motion-relaxed)
|
|
178
200
|
var(--oh-motion-ease-gentle);
|
|
179
201
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-breadcrumb.js","sourceRoot":"","sources":["../src/oh-breadcrumb.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-breadcrumb.js","sourceRoot":"","sources":["../src/oh-breadcrumb.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;;;;;;;AAEH,OAAO,EAAE,IAAI,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC5D,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAOlD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AAEI,IAAM,YAAY,GAAlB,MAAM,YAAa,SAAQ,SAAS;IAApC;;QA+LL,UAAK,GAAqB,EAAE,CAAC;IAgE/B,CAAC;aA9PiB,WAAM,GAAG;QACvB,UAAU;QACV,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAwLF;KACF,AA3LqB,CA2LpB;IAKF,MAAM;QACJ,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YAC5B,OAAO,OAAO,CAAC;QACjB,CAAC;QAED,MAAM,UAAU,GACd,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;QAEnE,OAAO,IAAI,CAAA;;;;YAIH,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,KAAK,EAAE,EAAE;YAC/B,MAAM,MAAM,GAAG,KAAK,KAAK,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;YAC/C,MAAM,aAAa,GAAG,KAAK,GAAG,IAAI,CAAC,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC;YAEpD,OAAO,IAAI,CAAA;;kBAEL,MAAM;gBACN,CAAC,CAAC,IAAI,CAAA;yBACC,IAAI,CAAC,KAAK;sBACb;gBACJ,CAAC,CAAC,IAAI,CAAA,mCAAmC,IAAI,CAAC,IAAI,IAAI,GAAG;yBAClD,IAAI,CAAC,KAAK;sBACb;kBACJ,aAAa;gBACb,CAAC,CAAC,IAAI,CAAA;;sBAEF;gBACJ,CAAC,CAAC,OAAO;;aAEd,CAAC;QACJ,CAAC,CAAC;;;;UAIF,UAAU;YACV,CAAC,CAAC,IAAI,CAAA;;4CAE4B,UAAU,CAAC,IAAI,IAAI,GAAG;;;;;;;;;;;;;;;kCAehC,UAAU,CAAC,KAAK;;;aAGrC;YACH,CAAC,CAAC,OAAO;;KAEd,CAAC;IACJ,CAAC;;AA/DD;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,CAAC;2CACG;AA/LlB,YAAY;IADxB,aAAa,CAAC,eAAe,CAAC;GAClB,YAAY,CA+PxB"}
|
package/dist/oh-button.d.ts
CHANGED
|
@@ -1,37 +1,63 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* oh-button
|
|
3
3
|
*
|
|
4
|
-
* A chunky, confident button with playful personality.
|
|
5
|
-
* Inspired by hand-crafted, illustrative UI — not corporate SaaS.
|
|
6
|
-
*
|
|
7
4
|
* DESIGN DECISIONS:
|
|
8
5
|
* ─────────────────
|
|
9
|
-
* 1.
|
|
10
|
-
*
|
|
11
|
-
* -
|
|
12
|
-
*
|
|
6
|
+
* 1. Renders a native <button>, or an <a> when `href` is set, inside the
|
|
7
|
+
* shadow root, so keyboard and screen reader behaviour come from the
|
|
8
|
+
* platform. `accessible-label` is forwarded to it (an aria-label on the
|
|
9
|
+
* host isn't).
|
|
10
|
+
* 2. Look comes from button.* component tokens: button.base.borderWidth
|
|
11
|
+
* (stroke.control), button.base.borderRadius (shape.control),
|
|
12
|
+
* button.variant.<variant>.* for fills, text, border and shadow colour,
|
|
13
|
+
* button.size.<size>.* for type, padding and height.
|
|
14
|
+
* 3. Hover and active move the button by lift.hoverMd / lift.pressMd and set
|
|
15
|
+
* the shadow offset to elevation.offset.2xl / elevation.offset.xs (rest is
|
|
16
|
+
* elevation.offset.lg).
|
|
17
|
+
* 4. Focus is a solid underline on the label (an underline the button draws
|
|
18
|
+
* itself for icon-only and loading buttons, whose text is hidden).
|
|
19
|
+
* 5. Loading uses aria-disabled + aria-busy, not disabled, so focus stays on
|
|
20
|
+
* the button.
|
|
21
|
+
*/
|
|
22
|
+
import { OhElement } from "./base.js";
|
|
23
|
+
export type ButtonVariant = "primary" | "secondary" | "accent";
|
|
24
|
+
export type ButtonSize = "sm" | "md" | "lg";
|
|
25
|
+
export type ButtonState = "default" | "hover" | "active" | "focus";
|
|
26
|
+
/**
|
|
27
|
+
* A button that starts an action, or a link styled as a button when `href` is set.
|
|
13
28
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* - Feels like a physical sticker or stamp
|
|
17
|
-
* - Not a generic centered drop shadow
|
|
29
|
+
* **Use it for** actions: submitting, saving, opening a dialog, confirming.
|
|
30
|
+
* **Don't use it for** links inside running text (use `oh-link`).
|
|
18
31
|
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* - Focus: warm glow + accessible underline
|
|
32
|
+
* **Variants:** `primary` for the main action, `secondary` for the others,
|
|
33
|
+
* `accent` for an action that takes the accent colour role. **Sizes:** `sm`, `md` (default), `lg`.
|
|
34
|
+
* **States:** rest, hover, active, focus and `loading`.
|
|
23
35
|
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
36
|
+
* **Behaviour:** fires `oh-click` when the inner `<button>` is clicked, except
|
|
37
|
+
* while `loading`. `loading` shows a spinner, keeps the label for screen
|
|
38
|
+
* readers, sets `aria-busy` and `aria-disabled` and ignores clicks, while the
|
|
39
|
+
* button stays focusable. With `href` it renders an `<a>` (and
|
|
40
|
+
* `target="_blank"` adds `rel="noopener noreferrer"`); link buttons don't fire
|
|
41
|
+
* `oh-click`. It has no `disabled` property and doesn't submit a form by
|
|
42
|
+
* itself: handle `oh-click`. Under `prefers-reduced-motion` it doesn't move.
|
|
43
|
+
*
|
|
44
|
+
* **Accessibility:** focus shows a solid underline on the label. An
|
|
45
|
+
* `icon-only` button has no visible text, so always set `accessible-label`
|
|
46
|
+
* (not `aria-label`, which isn't forwarded into the shadow root).
|
|
47
|
+
*
|
|
48
|
+
* **Look:** set by tokens — `stroke.control` (border width), `shape.control`
|
|
49
|
+
* (corners), `typography.control.*` (type), `button.variant.<variant>.*`
|
|
50
|
+
* (background, text, border and shadow colour per state), `button.size.<size>.*`
|
|
51
|
+
* (font size, padding, minimum height), `elevation.offset.*` (shadow offset)
|
|
52
|
+
* and `lift.hoverMd` / `lift.pressMd` (movement on hover and press).
|
|
28
53
|
*
|
|
29
54
|
* @element oh-button
|
|
55
|
+
* @fires oh-click - The button was clicked (not while loading). `detail.originalEvent` is the click.
|
|
56
|
+
* @slot - The label.
|
|
57
|
+
* @slot icon-left - An icon before the label.
|
|
58
|
+
* @slot icon-right - An icon after the label.
|
|
59
|
+
* @csspart button - The inner `<button>` or `<a>`.
|
|
30
60
|
*/
|
|
31
|
-
import { OhElement } from "./base.js";
|
|
32
|
-
export type ButtonVariant = "primary" | "secondary" | "accent";
|
|
33
|
-
export type ButtonSize = "sm" | "md" | "lg";
|
|
34
|
-
export type ButtonState = "default" | "hover" | "active" | "focus";
|
|
35
61
|
export declare class OhButton extends OhElement {
|
|
36
62
|
static styles: import("lit").CSSResult[];
|
|
37
63
|
variant: ButtonVariant;
|
|
@@ -45,7 +71,7 @@ export declare class OhButton extends OhElement {
|
|
|
45
71
|
*/
|
|
46
72
|
accessibleLabel?: string;
|
|
47
73
|
/**
|
|
48
|
-
* Force a visual state (for documentation
|
|
74
|
+
* Force a visual state (for documentation only)
|
|
49
75
|
* Values: 'hover' | 'active' | 'focus'
|
|
50
76
|
*/
|
|
51
77
|
forceState: ButtonState;
|
package/dist/oh-button.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oh-button.d.ts","sourceRoot":"","sources":["../src/oh-button.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"oh-button.d.ts","sourceRoot":"","sources":["../src/oh-button.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;GAoBG;AAIH,OAAO,EAAE,SAAS,EAAc,MAAM,WAAW,CAAC;AAElD,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,CAAC;AAC/D,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAC5C,MAAM,MAAM,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEnE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,qBACa,QAAS,SAAQ,SAAS;IACrC,OAAgB,MAAM,4BAuYpB;IAGF,OAAO,EAAE,aAAa,CAAa;IAGnC,IAAI,EAAE,UAAU,CAAQ;IAGxB,OAAO,UAAS;IAGhB,QAAQ,UAAS;IAEjB;;;;OAIG;IAEH,eAAe,CAAC,EAAE,MAAM,CAAC;IAEzB;;;OAGG;IAEH,UAAU,EAAE,WAAW,CAAa;IAEpC,kEAAkE;IAElE,IAAI,CAAC,EAAE,MAAM,CAAC;IAEd,uDAAuD;IAEvD,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB,OAAO,CAAC,YAAY;IASpB,+CAA+C;IACtC,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY;IAKrC,8CAA8C;IACrC,IAAI;IAKb,MAAM;CAuDP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,WAAW,EAAE,QAAQ,CAAC;KACvB;CACF"}
|