@tylertech/forge 3.8.0-dev.3 → 3.8.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 +3948 -3215
- package/dist/app-bar/forge-app-bar.css +20 -11
- package/dist/forge.css +2 -2
- package/dist/lib.js +14 -14
- package/dist/lib.js.map +4 -4
- package/dist/table/forge-table.css +2 -2
- package/dist/vscode.css-custom-data.json +218 -208
- package/dist/vscode.html-custom-data.json +370 -245
- package/esm/app-bar/app-bar/app-bar-constants.d.ts +2 -0
- package/esm/app-bar/app-bar/app-bar-constants.js +2 -1
- package/esm/app-bar/app-bar/app-bar-core.d.ts +5 -1
- package/esm/app-bar/app-bar/app-bar-core.js +10 -0
- package/esm/app-bar/app-bar/app-bar.d.ts +9 -1
- package/esm/app-bar/app-bar/app-bar.js +15 -2
- package/esm/app-bar/help-button/app-bar-help-button.js +1 -1
- package/esm/app-bar/menu-button/app-bar-menu-button.js +1 -1
- package/esm/app-bar/notification-button/app-bar-notification-button.js +1 -1
- package/esm/app-bar/profile-button/app-bar-profile-button.d.ts +1 -1
- package/esm/app-bar/profile-button/app-bar-profile-button.js +13 -10
- package/esm/app-bar/search/app-bar-search.js +1 -1
- package/esm/autocomplete/autocomplete-core.js +5 -0
- package/esm/avatar/avatar.d.ts +4 -4
- package/esm/avatar/avatar.js +5 -6
- package/esm/badge/badge.d.ts +4 -3
- package/esm/badge/badge.js +5 -4
- package/esm/button/button-constants.d.ts +1 -1
- package/esm/button/button.js +1 -1
- package/esm/card/card.d.ts +4 -3
- package/esm/card/card.js +3 -2
- package/esm/core/base/base-lit-element.d.ts +9 -0
- package/esm/core/base/base-lit-element.js +12 -0
- package/esm/core/utils/lit-utils.d.ts +11 -0
- package/esm/core/utils/lit-utils.js +31 -0
- package/esm/dialog/dialog-adapter.d.ts +0 -1
- package/esm/dialog/dialog-adapter.js +4 -39
- package/esm/dialog/dialog-constants.d.ts +6 -2
- package/esm/dialog/dialog-constants.js +4 -4
- package/esm/dialog/dialog-core.d.ts +3 -3
- package/esm/dialog/dialog-core.js +8 -7
- package/esm/dialog/dialog.d.ts +3 -3
- package/esm/dialog/dialog.js +4 -4
- package/esm/icon-button/icon-button-constants.d.ts +1 -1
- package/esm/icon-button/icon-button.js +1 -1
- package/esm/key/key/key.d.ts +3 -2
- package/esm/key/key/key.js +3 -2
- package/esm/key/key-item/key-item.d.ts +3 -2
- package/esm/key/key-item/key-item.js +3 -2
- package/esm/list-dropdown/list-dropdown-aware-core.d.ts +22 -0
- package/esm/list-dropdown/list-dropdown-aware-core.js +30 -0
- package/esm/list-dropdown/list-dropdown-aware.d.ts +35 -0
- package/esm/list-dropdown/list-dropdown-aware.js +35 -16
- package/esm/list-dropdown/list-dropdown-constants.d.ts +22 -3
- package/esm/list-dropdown/list-dropdown-constants.js +9 -1
- package/esm/list-dropdown/list-dropdown-utils.js +6 -0
- package/esm/menu/menu-core.js +2 -0
- package/esm/menu/menu.js +1 -0
- package/esm/meter/meter/meter.d.ts +4 -2
- package/esm/meter/meter/meter.js +4 -2
- package/esm/meter/meter-group/meter-group.d.ts +3 -2
- package/esm/meter/meter-group/meter-group.js +3 -2
- package/esm/overlay/base/overlay-aware.d.ts +4 -4
- package/esm/overlay/base/overlay-aware.js +3 -3
- package/esm/select/core/base-select-core.js +5 -0
- package/esm/select/select/select.d.ts +25 -1
- package/esm/select/select/select.js +26 -1
- package/esm/split-view/split-view-panel/split-view-panel.js +1 -1
- package/esm/tabs/tab-bar/tab-bar.js +1 -1
- package/package.json +2 -2
- package/sass/app-bar/app-bar/_core.scss +0 -1
- package/sass/app-bar/app-bar/app-bar.scss +57 -23
- package/sass/app-bar/forge-app-bar.scss +41 -11
- package/sass/app-bar/search/app-bar-search.scss +3 -0
- package/sass/button/button.scss +24 -0
- package/sass/core/styles/scrollbar/index.scss +14 -0
- package/sass/core/styles/tokens/app-bar/app-bar/_tokens.scss +2 -8
- package/sass/icon-button/icon-button.scss +8 -9
- package/sass/table/_core.scss +1 -1
- package/sass/tabs/tab-bar/tab-bar.scss +24 -0
|
@@ -18,6 +18,7 @@ export declare const APP_BAR_CONSTANTS: {
|
|
|
18
18
|
THEME: string;
|
|
19
19
|
HREF: string;
|
|
20
20
|
TARGET: string;
|
|
21
|
+
THEME_MODE: string;
|
|
21
22
|
};
|
|
22
23
|
classes: {
|
|
23
24
|
NO_CENTER: string;
|
|
@@ -30,3 +31,4 @@ export declare const APP_BAR_CONSTANTS: {
|
|
|
30
31
|
};
|
|
31
32
|
export type AppBarElevation = 'none' | 'raised';
|
|
32
33
|
export type AppBarTheme = 'white' | 'custom' | '';
|
|
34
|
+
export type AppBarThemeMode = 'inherit' | 'scoped';
|
|
@@ -4,11 +4,12 @@
|
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import { IAppBarAdapter } from './app-bar-adapter';
|
|
7
|
-
import { AppBarElevation, AppBarTheme } from './app-bar-constants';
|
|
7
|
+
import { AppBarElevation, AppBarTheme, AppBarThemeMode } from './app-bar-constants';
|
|
8
8
|
export interface IAppBarCore {
|
|
9
9
|
titleText: string;
|
|
10
10
|
elevation: AppBarElevation;
|
|
11
11
|
theme: string;
|
|
12
|
+
themeMode: AppBarThemeMode;
|
|
12
13
|
href: string;
|
|
13
14
|
target: string;
|
|
14
15
|
}
|
|
@@ -19,6 +20,7 @@ export declare class AppBarCore implements IAppBarCore {
|
|
|
19
20
|
private _theme;
|
|
20
21
|
private _href;
|
|
21
22
|
private _target;
|
|
23
|
+
private _themeMode;
|
|
22
24
|
private _centerSlotListener;
|
|
23
25
|
private _anchorClickListener;
|
|
24
26
|
constructor(_adapter: IAppBarAdapter);
|
|
@@ -34,4 +36,6 @@ export declare class AppBarCore implements IAppBarCore {
|
|
|
34
36
|
set href(value: string);
|
|
35
37
|
get target(): string;
|
|
36
38
|
set target(value: string);
|
|
39
|
+
get themeMode(): AppBarThemeMode;
|
|
40
|
+
set themeMode(value: AppBarThemeMode);
|
|
37
41
|
}
|
|
@@ -11,6 +11,7 @@ export class AppBarCore {
|
|
|
11
11
|
this._elevation = 'raised';
|
|
12
12
|
this._href = '';
|
|
13
13
|
this._target = '';
|
|
14
|
+
this._themeMode = 'inherit';
|
|
14
15
|
this._centerSlotListener = () => this._adapter.setCenterSlotVisibility();
|
|
15
16
|
this._anchorClickListener = this._onHrefClick.bind(this);
|
|
16
17
|
}
|
|
@@ -79,4 +80,13 @@ export class AppBarCore {
|
|
|
79
80
|
this._adapter.toggleHostAttribute(APP_BAR_CONSTANTS.attributes.TARGET, !!this._target, this._target);
|
|
80
81
|
}
|
|
81
82
|
}
|
|
83
|
+
get themeMode() {
|
|
84
|
+
return this._themeMode;
|
|
85
|
+
}
|
|
86
|
+
set themeMode(value) {
|
|
87
|
+
if (this._themeMode !== value) {
|
|
88
|
+
this._themeMode = value;
|
|
89
|
+
this._adapter.toggleHostAttribute(APP_BAR_CONSTANTS.attributes.THEME_MODE, this._themeMode !== 'inherit', this._themeMode);
|
|
90
|
+
}
|
|
91
|
+
}
|
|
82
92
|
}
|
|
@@ -3,12 +3,13 @@
|
|
|
3
3
|
* Copyright Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import { AppBarElevation, AppBarTheme } from './app-bar-constants';
|
|
6
|
+
import { AppBarElevation, AppBarTheme, AppBarThemeMode } from './app-bar-constants';
|
|
7
7
|
import { BaseComponent, IBaseComponent } from '../../core/base/base-component';
|
|
8
8
|
export interface IAppBarComponent extends IBaseComponent {
|
|
9
9
|
titleText: string;
|
|
10
10
|
elevation: AppBarElevation;
|
|
11
11
|
theme: AppBarTheme;
|
|
12
|
+
themeMode: AppBarThemeMode;
|
|
12
13
|
href: string;
|
|
13
14
|
target: string;
|
|
14
15
|
}
|
|
@@ -30,15 +31,19 @@ declare global {
|
|
|
30
31
|
* @property {AppBarTheme} theme - The theme of the app bar.
|
|
31
32
|
* @property {string} href - The href that will be used to make the logo and title area a clickable link.
|
|
32
33
|
* @property {string} target - The `<a>` target of the logo + title area link when `href` is set.
|
|
34
|
+
* @property {AppBarThemeMode} [themeMode="inherit"] - Controls how the theme is applied. `inherit` will apply the global theme to the app bar and all child components. `scoped` will only apply the theme to the app bar and not set any global tokens.
|
|
33
35
|
*
|
|
34
36
|
* @attribute {string} title-text - The text to display in the title.
|
|
35
37
|
* @attribute {string} [elevation="raised"] - The elevation of the app bar.
|
|
36
38
|
* @attribute {string} theme - The theme of the app bar.
|
|
37
39
|
* @attribute {string} href - The href that will be used to make the logo and title area a clickable link
|
|
38
40
|
* @attribute {string} target - The `<a>` target of the logo + title area link when `href` is set.
|
|
41
|
+
* @attribute {string} [theme-mode="inherit"] - Controls how the theme is applied. `inherit` will apply the global theme to the app bar and all child components. `scoped` will only apply the theme to the app bar and not set any global tokens.
|
|
39
42
|
*
|
|
40
43
|
* @cssproperty --forge-app-bar-background - The background color of the app bar.
|
|
41
44
|
* @cssproperty --forge-app-bar-foreground - The text color of the app bar.
|
|
45
|
+
* @cssproperty --forge-app-bar-theme-foreground - The text color of the app bar when using the **scoped theme mode**.
|
|
46
|
+
* @cssproperty --forge-app-bar-theme-foreground-muted - The muted text color of the app bar when using the **scoped theme mode**.
|
|
42
47
|
* @cssproperty --forge-app-bar-z-index - The `z-index` of the app bar.
|
|
43
48
|
* @cssproperty --forge-app-bar-elevation - The elevation of the app bar.
|
|
44
49
|
* @cssproperty --forge-app-bar-height - The height of the app bar.
|
|
@@ -61,6 +66,8 @@ declare global {
|
|
|
61
66
|
* @slot end - Places content at the end of the app bar.
|
|
62
67
|
*
|
|
63
68
|
* @cssclass forge-app-bar - The app bar container element _(required)_.
|
|
69
|
+
* @cssclass forge-app-bar--scoped - Sets the theme mode to scoped.
|
|
70
|
+
* @cssclass forge-app-bar-theme - Applies the scoped theme from the app bar to the element.
|
|
64
71
|
* @cssclass forge-app-bar--raised - The app bar container element when raised.
|
|
65
72
|
* @cssclass forge-app-bar__logo - The logo container element.
|
|
66
73
|
* @cssclass forge-app-bar__title - The title container element.
|
|
@@ -81,4 +88,5 @@ export declare class AppBarComponent extends BaseComponent implements IAppBarCom
|
|
|
81
88
|
theme: AppBarTheme;
|
|
82
89
|
href: string;
|
|
83
90
|
target: string;
|
|
91
|
+
themeMode: AppBarThemeMode;
|
|
84
92
|
}
|
|
@@ -10,7 +10,7 @@ import { AppBarCore } from './app-bar-core';
|
|
|
10
10
|
import { APP_BAR_CONSTANTS } from './app-bar-constants';
|
|
11
11
|
import { BaseComponent } from '../../core/base/base-component';
|
|
12
12
|
const template = '<template><div class=\"forge-app-bar\" part=\"root\"><div class=\"row\"><div class=\"section\"><slot name=\"start\"></slot><div class=\"logo-title-container\"><slot name=\"logo\"></slot><slot name=\"title\"></slot></div></div><div id=\"center-section\" class=\"section\"><slot name=\"center\"></slot></div><div class=\"section\"><slot name=\"end\"></slot></div></div><div><slot name=\"bottom\"></slot></div></div></template>';
|
|
13
|
-
const styles = ':host{--_app-bar-background:var(--forge-app-bar-background, var(--forge-theme-brand, #283593));--_app-bar-foreground:var(--forge-app-bar-foreground, var(--forge-theme-on-brand, #ffffff))}:host{display:block}:host([hidden]){display:none}:host{--forge-
|
|
13
|
+
const styles = ':host{--_app-bar-background:var(--forge-app-bar-background, var(--forge-theme-brand, #283593));--_app-bar-foreground:var(--forge-app-bar-foreground, var(--forge-theme-on-brand, #ffffff))}:host{display:block}:host([hidden]){display:none}:host(:not([theme]):not([theme-mode=scoped])){--forge-theme-primary:var(--_app-bar-foreground);--forge-theme-on-primary:rgba(0, 0, 0, 0.87);--forge-theme-text-high:rgba(255, 255, 255, 0.87);--forge-theme-text-medium:rgba(255, 255, 255, 0.54);--forge-theme-text-low:rgba(255, 255, 255, 0.38);--forge-theme-outline-high:rgba(255, 255, 255, 0.87);--forge-theme-outline-medium:rgba(255, 255, 255, 0.54);--forge-theme-outline-low:rgba(255, 255, 255, 0.38)}:host([theme-mode=scoped]) .forge-app-bar{color:inherit}:host([theme-mode=scoped]) .forge-app-bar .logo-title-container{color:var(--_app-bar-foreground)}:host{--forge-app-bar-theme-foreground:var(--_app-bar-foreground);--forge-app-bar-theme-foreground-muted:rgba(255, 255, 255, 0.54)}.forge-app-bar{--_app-bar-z-index:var(--forge-app-bar-z-index, var(--forge-z-index-header, 4));--_app-bar-elevation:var(--forge-app-bar-elevation, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12));--_app-bar-height:var(--forge-app-bar-height, 56px);--_app-bar-row-padding:var(--forge-app-bar-row-padding, var(--forge-spacing-xxsmall, 4px));--_app-bar-logo-gap:var(--forge-app-bar-logo-gap, var(--forge-spacing-medium, 16px));--_app-bar-logo-font-size:var(--forge-app-bar-logo-font-size, calc(var(--forge-typography-font-size, 1rem) * 2.5));--_app-bar-title-padding:var(--forge-app-bar-title-padding, var(--forge-spacing-xsmall, 8px));--_app-bar-columns:var(--forge-app-bar-columns, 1fr 1fr 1fr);--_app-bar-transition-duration:var(--forge-app-bar-transition-duration, var(--forge-animation-duration-short4, 200ms));--_app-bar-transition-timing:var(--forge-app-bar-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_app-bar-theme-foreground:var(--forge-app-bar-theme-foreground, var(--_app-bar-foreground));--_app-bar-theme-foreground-muted:var(--forge-app-bar-theme-foreground-muted, rgba(255, 255, 255, 0.54))}.forge-app-bar{background:var(--_app-bar-background);color:var(--_app-bar-foreground);position:relative;z-index:var(--_app-bar-z-index);display:grid;grid-template-rows:1fr auto;transition-property:box-shadow,background-color;transition-duration:var(--_app-bar-transition-duration);transition-timing-function:var(--_app-bar-transition-timing);box-sizing:border-box;width:100%}.forge-app-bar .row{display:grid;align-items:center;grid-template-columns:var(--_app-bar-columns);height:var(--_app-bar-height);padding-inline:var(--_app-bar-row-padding)}.forge-app-bar.no-center .row{grid-template-columns:1fr auto}.forge-app-bar .section{display:inline-flex;flex:1 1 auto;align-items:center;box-sizing:border-box;min-width:0;height:100%}.forge-app-bar .section:not(:last-child):not(:first-child){justify-content:center}.forge-app-bar .section:last-child{justify-self:end}.forge-app-bar h1{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-heading4-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-heading4-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-heading4-font-size-scale, 1.25)));font-weight:var(--forge-typography-heading4-font-weight,500);line-height:var(--forge-typography-heading4-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-heading4-line-height-scale, 1.5)));letter-spacing:var(--forge-typography-heading4-letter-spacing, .005em);text-transform:var(--forge-typography-heading4-text-transform,inherit);text-decoration:var(--forge-typography-heading4-text-decoration,inherit);margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.forge-app-bar a{outline:0;text-decoration:none;color:inherit;box-sizing:border-box;height:100%}.forge-app-bar a forge-state-layer{--forge-state-layer-color:var(--_app-bar-foreground)}.forge-app-bar a forge-focus-indicator{--forge-focus-indicator-color:var(--_app-bar-foreground);--forge-focus-indicator-shape:4px;--forge-focus-indicator-offset-block:4px}.forge-app-bar .logo-title-container{position:relative;display:flex;align-items:center;gap:var(--_app-bar-logo-gap);min-width:0;padding-inline:var(--_app-bar-title-padding)}:host(:is(:not([elevation]),[elevation=raised])) .forge-app-bar{box-shadow:var(--_app-bar-elevation)}:host([theme-mode=scoped]) ::slotted(:where(forge-tab-bar,forge-icon-button,forge-button)){color:var(--_app-bar-theme-foreground);--forge-tab-active-color:var(--_app-bar-theme-foreground);--forge-tab-inactive-color:var(--_app-bar-theme-foreground-muted)}::slotted(forge-tab-bar){--forge-tab-bar-divider-thickness:0}::slotted([slot=logo]){font-size:var(--_app-bar-logo-font-size);height:1em}::slotted(forge-app-bar-search[slot=center]){width:100%}:host([theme=white]){--_app-bar-background:var(--forge-app-bar-background, white);--_app-bar-foreground:var(--forge-app-bar-foreground, black);--forge-app-bar-theme-foreground-muted:rgba(0, 0, 0, 0.54)}:host([theme=white]:not([theme-mode=scoped])){--forge-theme-primary:black;--forge-theme-on-primary:rgba(255, 255, 255, 0.87);--forge-theme-text-medium:rgba(0, 0, 0, 0.54)}';
|
|
14
14
|
/**
|
|
15
15
|
* @tag forge-app-bar
|
|
16
16
|
*
|
|
@@ -21,15 +21,19 @@ const styles = ':host{--_app-bar-background:var(--forge-app-bar-background, var(
|
|
|
21
21
|
* @property {AppBarTheme} theme - The theme of the app bar.
|
|
22
22
|
* @property {string} href - The href that will be used to make the logo and title area a clickable link.
|
|
23
23
|
* @property {string} target - The `<a>` target of the logo + title area link when `href` is set.
|
|
24
|
+
* @property {AppBarThemeMode} [themeMode="inherit"] - Controls how the theme is applied. `inherit` will apply the global theme to the app bar and all child components. `scoped` will only apply the theme to the app bar and not set any global tokens.
|
|
24
25
|
*
|
|
25
26
|
* @attribute {string} title-text - The text to display in the title.
|
|
26
27
|
* @attribute {string} [elevation="raised"] - The elevation of the app bar.
|
|
27
28
|
* @attribute {string} theme - The theme of the app bar.
|
|
28
29
|
* @attribute {string} href - The href that will be used to make the logo and title area a clickable link
|
|
29
30
|
* @attribute {string} target - The `<a>` target of the logo + title area link when `href` is set.
|
|
31
|
+
* @attribute {string} [theme-mode="inherit"] - Controls how the theme is applied. `inherit` will apply the global theme to the app bar and all child components. `scoped` will only apply the theme to the app bar and not set any global tokens.
|
|
30
32
|
*
|
|
31
33
|
* @cssproperty --forge-app-bar-background - The background color of the app bar.
|
|
32
34
|
* @cssproperty --forge-app-bar-foreground - The text color of the app bar.
|
|
35
|
+
* @cssproperty --forge-app-bar-theme-foreground - The text color of the app bar when using the **scoped theme mode**.
|
|
36
|
+
* @cssproperty --forge-app-bar-theme-foreground-muted - The muted text color of the app bar when using the **scoped theme mode**.
|
|
33
37
|
* @cssproperty --forge-app-bar-z-index - The `z-index` of the app bar.
|
|
34
38
|
* @cssproperty --forge-app-bar-elevation - The elevation of the app bar.
|
|
35
39
|
* @cssproperty --forge-app-bar-height - The height of the app bar.
|
|
@@ -52,6 +56,8 @@ const styles = ':host{--_app-bar-background:var(--forge-app-bar-background, var(
|
|
|
52
56
|
* @slot end - Places content at the end of the app bar.
|
|
53
57
|
*
|
|
54
58
|
* @cssclass forge-app-bar - The app bar container element _(required)_.
|
|
59
|
+
* @cssclass forge-app-bar--scoped - Sets the theme mode to scoped.
|
|
60
|
+
* @cssclass forge-app-bar-theme - Applies the scoped theme from the app bar to the element.
|
|
55
61
|
* @cssclass forge-app-bar--raised - The app bar container element when raised.
|
|
56
62
|
* @cssclass forge-app-bar__logo - The logo container element.
|
|
57
63
|
* @cssclass forge-app-bar__title - The title container element.
|
|
@@ -68,7 +74,8 @@ let AppBarComponent = class AppBarComponent extends BaseComponent {
|
|
|
68
74
|
APP_BAR_CONSTANTS.attributes.ELEVATION,
|
|
69
75
|
APP_BAR_CONSTANTS.attributes.THEME,
|
|
70
76
|
APP_BAR_CONSTANTS.attributes.HREF,
|
|
71
|
-
APP_BAR_CONSTANTS.attributes.TARGET
|
|
77
|
+
APP_BAR_CONSTANTS.attributes.TARGET,
|
|
78
|
+
APP_BAR_CONSTANTS.attributes.THEME_MODE
|
|
72
79
|
];
|
|
73
80
|
}
|
|
74
81
|
constructor() {
|
|
@@ -96,6 +103,9 @@ let AppBarComponent = class AppBarComponent extends BaseComponent {
|
|
|
96
103
|
case APP_BAR_CONSTANTS.attributes.TARGET:
|
|
97
104
|
this.target = newValue;
|
|
98
105
|
break;
|
|
106
|
+
case APP_BAR_CONSTANTS.attributes.THEME_MODE:
|
|
107
|
+
this.themeMode = newValue;
|
|
108
|
+
break;
|
|
99
109
|
}
|
|
100
110
|
}
|
|
101
111
|
};
|
|
@@ -114,6 +124,9 @@ __decorate([
|
|
|
114
124
|
__decorate([
|
|
115
125
|
coreProperty()
|
|
116
126
|
], AppBarComponent.prototype, "target", void 0);
|
|
127
|
+
__decorate([
|
|
128
|
+
coreProperty()
|
|
129
|
+
], AppBarComponent.prototype, "themeMode", void 0);
|
|
117
130
|
AppBarComponent = __decorate([
|
|
118
131
|
customElement({
|
|
119
132
|
name: APP_BAR_CONSTANTS.elementName
|
|
@@ -14,7 +14,7 @@ import { IconButtonComponent } from '../../icon-button';
|
|
|
14
14
|
import { TooltipComponent } from '../../tooltip';
|
|
15
15
|
import { IconRegistry } from '../../icon';
|
|
16
16
|
import { BaseComponent } from '../../core/base/base-component';
|
|
17
|
-
const template = '<template><forge-menu placement=\"bottom-end\"><forge-icon-button><forge-icon name=\"help\"></forge-icon></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Help</forge-tooltip></forge-menu></template>';
|
|
17
|
+
const template = '<template><forge-menu placement=\"bottom-end\"><forge-icon-button theme=\"app-bar\"><forge-icon name=\"help\"></forge-icon></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Help</forge-tooltip></forge-menu></template>';
|
|
18
18
|
/**
|
|
19
19
|
* @tag forge-app-bar-help-button
|
|
20
20
|
*
|
|
@@ -12,7 +12,7 @@ import { IconRegistry, ICON_CONSTANTS } from '../../icon';
|
|
|
12
12
|
import { tylIconMenu } from '@tylertech/tyler-icons/standard';
|
|
13
13
|
import { BaseComponent } from '../../core/base/base-component';
|
|
14
14
|
import { forwardAttributes } from '../../core/utils/reflect-utils';
|
|
15
|
-
const template = '<template><forge-icon-button><forge-icon name=\"menu\"></forge-icon></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Menu</forge-tooltip></template>';
|
|
15
|
+
const template = '<template><forge-icon-button theme=\"app-bar\"><forge-icon name=\"menu\"></forge-icon></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Menu</forge-tooltip></template>';
|
|
16
16
|
/**
|
|
17
17
|
* @tag forge-app-bar-menu-button
|
|
18
18
|
*
|
|
@@ -14,7 +14,7 @@ import { TooltipComponent } from '../../tooltip';
|
|
|
14
14
|
import { AppBarNotificationButtonAdapter } from './app-bar-notification-button-adapter';
|
|
15
15
|
import { APP_BAR_NOTIFICATION_BUTTON_CONSTANTS } from './app-bar-notification-button-constants';
|
|
16
16
|
import { AppBarNotificationButtonCore } from './app-bar-notification-button-core';
|
|
17
|
-
const template = '<template><forge-icon-button><forge-icon></forge-icon><forge-badge slot=\"badge\"></forge-badge></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Notifications</forge-tooltip></template>';
|
|
17
|
+
const template = '<template><forge-icon-button theme=\"app-bar\"><forge-icon></forge-icon><forge-badge slot=\"badge\"></forge-badge></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom\">Notifications</forge-tooltip></template>';
|
|
18
18
|
/**
|
|
19
19
|
* @tag forge-app-bar-notification-button
|
|
20
20
|
*
|
|
@@ -3,9 +3,9 @@
|
|
|
3
3
|
* Copyright Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
+
import { AppBarProfileButtonProfileCardBuilder } from './app-bar-profile-button-constants';
|
|
6
7
|
import { BaseComponent, IBaseComponent } from '../../core/base/base-component';
|
|
7
8
|
import { IPopoverComponent } from '../../popover/popover';
|
|
8
|
-
import { AppBarProfileButtonProfileCardBuilder } from './app-bar-profile-button-constants';
|
|
9
9
|
export interface IAppBarProfileButtonComponent extends IBaseComponent {
|
|
10
10
|
avatarImageUrl: string;
|
|
11
11
|
avatarLetterCount: number;
|
|
@@ -4,17 +4,17 @@
|
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
6
|
import { __decorate } from "tslib";
|
|
7
|
-
import {
|
|
8
|
-
import { BaseComponent } from '../../core/base/base-component';
|
|
9
|
-
import { IconButtonComponent } from '../../icon-button';
|
|
10
|
-
import { PopoverComponent } from '../../popover/popover';
|
|
11
|
-
import { ProfileCardComponent } from '../../profile-card';
|
|
12
|
-
import { TooltipComponent } from '../../tooltip';
|
|
7
|
+
import { customElement, attachLightTemplate, coerceNumber, coerceBoolean, coreProperty } from '@tylertech/forge-core';
|
|
13
8
|
import { AppBarProfileButtonAdapter } from './app-bar-profile-button-adapter';
|
|
14
|
-
import { APP_BAR_PROFILE_BUTTON_CONSTANTS } from './app-bar-profile-button-constants';
|
|
15
9
|
import { AppBarProfileButtonCore } from './app-bar-profile-button-core';
|
|
16
|
-
import {
|
|
17
|
-
|
|
10
|
+
import { APP_BAR_PROFILE_BUTTON_CONSTANTS } from './app-bar-profile-button-constants';
|
|
11
|
+
import { ProfileCardComponent } from '../../profile-card';
|
|
12
|
+
import { IconButtonComponent } from '../../icon-button';
|
|
13
|
+
import { defineAvatarComponent } from '../../avatar';
|
|
14
|
+
import { TooltipComponent } from '../../tooltip';
|
|
15
|
+
import { BaseComponent } from '../../core/base/base-component';
|
|
16
|
+
import { PopoverComponent } from '../../popover/popover';
|
|
17
|
+
const template = '<template><forge-icon-button theme=\"app-bar\"><forge-avatar aria-hidden=\"true\"></forge-avatar></forge-icon-button><forge-tooltip type=\"label\" placement=\"bottom-end\">View profile</forge-tooltip></template>';
|
|
18
18
|
/**
|
|
19
19
|
* @tag forge-app-bar-profile-button
|
|
20
20
|
*
|
|
@@ -119,6 +119,9 @@ let AppBarProfileButtonComponent = class AppBarProfileButtonComponent extends Ba
|
|
|
119
119
|
return this._core.popupElement;
|
|
120
120
|
}
|
|
121
121
|
};
|
|
122
|
+
(() => {
|
|
123
|
+
defineAvatarComponent();
|
|
124
|
+
})();
|
|
122
125
|
__decorate([
|
|
123
126
|
coreProperty()
|
|
124
127
|
], AppBarProfileButtonComponent.prototype, "fullName", void 0);
|
|
@@ -158,7 +161,7 @@ __decorate([
|
|
|
158
161
|
AppBarProfileButtonComponent = __decorate([
|
|
159
162
|
customElement({
|
|
160
163
|
name: APP_BAR_PROFILE_BUTTON_CONSTANTS.elementName,
|
|
161
|
-
dependencies: [PopoverComponent, ProfileCardComponent, IconButtonComponent, TooltipComponent
|
|
164
|
+
dependencies: [PopoverComponent, ProfileCardComponent, IconButtonComponent, TooltipComponent]
|
|
162
165
|
})
|
|
163
166
|
], AppBarProfileButtonComponent);
|
|
164
167
|
export { AppBarProfileButtonComponent };
|
|
@@ -13,7 +13,7 @@ import { FocusIndicatorComponent } from '../../focus-indicator';
|
|
|
13
13
|
import { IconComponent, IconRegistry } from '../../icon';
|
|
14
14
|
import { BaseComponent } from '../../core/base/base-component';
|
|
15
15
|
const template = '<template><div class=\"forge-app-bar-search\" part=\"root\"><slot name=\"start\"><forge-icon name=\"search\" class=\"icon\" part=\"icon\"></forge-icon></slot><slot name=\"input\"></slot><slot></slot><slot name=\"end\"></slot></div></template>';
|
|
16
|
-
const styles = ':host{display:block}:host([hidden]){display:none}.forge-app-bar-search{--_app-bar-search-color:var(--forge-app-bar-search-color, currentColor);--_app-bar-search-height:var(--forge-app-bar-search-height, 36px);--_app-bar-search-padding:var(--forge-app-bar-search-padding, 8px);--_app-bar-search-shape:var(--forge-app-bar-search-shape, calc(var(--forge-shape-small, 2px) * var(--forge-shape-factor, 1)));--_app-bar-search-gap:var(--forge-app-bar-search-gap, 4px);--_app-bar-search-input-placeholder-color:var(--forge-app-bar-search-input-placeholder-color, var(--_app-bar-search-color));--_app-bar-search-input-placeholder-opacity:var(--forge-app-bar-search-input-placeholder-opacity, 0.7);--_app-bar-search-background-color:var(--forge-app-bar-search-background-color, var(--_app-bar-search-color));--_app-bar-search-background-color-opacity:var(--forge-app-bar-search-background-color-opacity, 0.08);--_app-bar-search-border-color:var(--forge-app-bar-search-border-color, var(--_app-bar-search-color));--_app-bar-search-border-opacity:var(--forge-app-bar-search-border-opacity, 0.54);--_app-bar-search-border-hover-opacity:var(--forge-app-bar-search-border-hover-opacity, 0.87);--_app-bar-search-transition-duration:var(--forge-app-bar-search-transition-duration, var(--forge-animation-duration-short3, 150ms));--_app-bar-search-transition-timing-function:var(--forge-app-bar-search-transition-timing-function, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)))}.forge-app-bar-search{position:relative;display:flex;align-items:center;flex:1 1 auto;gap:var(--_app-bar-search-gap);height:var(--_app-bar-search-height);width:100%;padding-inline:var(--_app-bar-search-padding);box-sizing:border-box;border-radius:var(--_app-bar-search-shape)}.forge-app-bar-search:hover::after{opacity:var(--_app-bar-search-border-hover-opacity)}.forge-app-bar-search::before{content:\"\";position:absolute;inset:0;pointer-events:none;background-color:var(--_app-bar-search-background-color);opacity:var(--_app-bar-search-background-color-opacity)}.forge-app-bar-search::after{content:\"\";position:absolute;inset:0;pointer-events:none;opacity:var(--_app-bar-search-border-opacity);border-radius:var(--_app-bar-search-shape);outline:1px solid var(--_app-bar-search-border-color);transition-property:opacity;transition-duration:var(--_app-bar-search-transition-duration);transition-timing-function:var(--_app-bar-search-transition-timing-function)}:host([disabled]){cursor:not-allowed}:host([disabled]) .forge-app-bar-search{pointer-events:none;opacity:38%}:host([disabled]) ::slotted(input){pointer-events:none}forge-focus-indicator{--forge-focus-indicator-color:currentColor;--forge-focus-indicator-outward-offset:0px}::slotted(input){-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-body2-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-body2-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-body-font-size-scale, 1)));font-weight:var(--forge-typography-body2-font-weight,400);line-height:var(--forge-typography-body2-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-body-line-height-scale, 1.375)));letter-spacing:var(--forge-typography-body2-letter-spacing, .015625em);text-transform:var(--forge-typography-body2-text-transform,inherit);text-decoration:var(--forge-typography-body2-text-decoration,inherit);display:block;overflow:hidden;background:0 0;color:currentColor;border:none;width:100%;margin:0;outline:0}::slotted(input)::placeholder{color:currentColor;opacity:var(--_app-bar-search-input-placeholder-opacity)}';
|
|
16
|
+
const styles = ':host{display:block;color:var(--_app-bar-theme-foreground)}:host([hidden]){display:none}.forge-app-bar-search{--_app-bar-search-color:var(--forge-app-bar-search-color, currentColor);--_app-bar-search-height:var(--forge-app-bar-search-height, 36px);--_app-bar-search-padding:var(--forge-app-bar-search-padding, 8px);--_app-bar-search-shape:var(--forge-app-bar-search-shape, calc(var(--forge-shape-small, 2px) * var(--forge-shape-factor, 1)));--_app-bar-search-gap:var(--forge-app-bar-search-gap, 4px);--_app-bar-search-input-placeholder-color:var(--forge-app-bar-search-input-placeholder-color, var(--_app-bar-search-color));--_app-bar-search-input-placeholder-opacity:var(--forge-app-bar-search-input-placeholder-opacity, 0.7);--_app-bar-search-background-color:var(--forge-app-bar-search-background-color, var(--_app-bar-search-color));--_app-bar-search-background-color-opacity:var(--forge-app-bar-search-background-color-opacity, 0.08);--_app-bar-search-border-color:var(--forge-app-bar-search-border-color, var(--_app-bar-search-color));--_app-bar-search-border-opacity:var(--forge-app-bar-search-border-opacity, 0.54);--_app-bar-search-border-hover-opacity:var(--forge-app-bar-search-border-hover-opacity, 0.87);--_app-bar-search-transition-duration:var(--forge-app-bar-search-transition-duration, var(--forge-animation-duration-short3, 150ms));--_app-bar-search-transition-timing-function:var(--forge-app-bar-search-transition-timing-function, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)))}.forge-app-bar-search{position:relative;display:flex;align-items:center;flex:1 1 auto;gap:var(--_app-bar-search-gap);height:var(--_app-bar-search-height);width:100%;padding-inline:var(--_app-bar-search-padding);box-sizing:border-box;border-radius:var(--_app-bar-search-shape)}.forge-app-bar-search:hover::after{opacity:var(--_app-bar-search-border-hover-opacity)}.forge-app-bar-search::before{content:\"\";position:absolute;inset:0;pointer-events:none;background-color:var(--_app-bar-search-background-color);opacity:var(--_app-bar-search-background-color-opacity)}.forge-app-bar-search::after{content:\"\";position:absolute;inset:0;pointer-events:none;opacity:var(--_app-bar-search-border-opacity);border-radius:var(--_app-bar-search-shape);outline:1px solid var(--_app-bar-search-border-color);transition-property:opacity;transition-duration:var(--_app-bar-search-transition-duration);transition-timing-function:var(--_app-bar-search-transition-timing-function)}:host([disabled]){cursor:not-allowed}:host([disabled]) .forge-app-bar-search{pointer-events:none;opacity:38%}:host([disabled]) ::slotted(input){pointer-events:none}forge-focus-indicator{--forge-focus-indicator-color:currentColor;--forge-focus-indicator-outward-offset:0px}::slotted(input){-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-body2-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-body2-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-body-font-size-scale, 1)));font-weight:var(--forge-typography-body2-font-weight,400);line-height:var(--forge-typography-body2-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-body-line-height-scale, 1.375)));letter-spacing:var(--forge-typography-body2-letter-spacing, .015625em);text-transform:var(--forge-typography-body2-text-transform,inherit);text-decoration:var(--forge-typography-body2-text-decoration,inherit);display:block;overflow:hidden;background:0 0;color:currentColor;border:none;width:100%;margin:0;outline:0}::slotted(input)::placeholder{color:currentColor;opacity:var(--_app-bar-search-input-placeholder-opacity)}';
|
|
17
17
|
/**
|
|
18
18
|
* @tag forge-app-bar-search
|
|
19
19
|
*
|
|
@@ -374,6 +374,11 @@ export class AutocompleteCore extends ListDropdownAwareCore {
|
|
|
374
374
|
wrapOptionText: this._wrapOptionText,
|
|
375
375
|
observeScroll: this._observeScroll,
|
|
376
376
|
observeScrollThreshold: this._observeScrollThreshold,
|
|
377
|
+
popupPlacement: this._popoverPlacement,
|
|
378
|
+
popupOffset: this._popoverOffset,
|
|
379
|
+
popupFlip: this._popoverFlip,
|
|
380
|
+
popupShift: this._popoverShift,
|
|
381
|
+
popupFallbackPlacements: this._popoverFallbackPlacements,
|
|
377
382
|
scrollEndListener: this._dropdownScrollEndListener,
|
|
378
383
|
activeChangeCallback: this._activeChangeListener,
|
|
379
384
|
targetWidthCallback: this._targetWidthCallback,
|
package/esm/avatar/avatar.d.ts
CHANGED
|
@@ -3,9 +3,10 @@
|
|
|
3
3
|
* Copyright Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import {
|
|
6
|
+
import { PropertyValues, TemplateResult } from 'lit';
|
|
7
7
|
import { CUSTOM_ELEMENT_NAME_PROPERTY } from '@tylertech/forge-core';
|
|
8
|
-
|
|
8
|
+
import { BaseLitElement } from '../core/base/base-lit-element';
|
|
9
|
+
export interface IAvatarComponent extends BaseLitElement {
|
|
9
10
|
text: string;
|
|
10
11
|
letterCount: number;
|
|
11
12
|
imageUrl: string;
|
|
@@ -34,7 +35,7 @@ export declare const AVATAR_TAG_NAME: keyof HTMLElementTagNameMap;
|
|
|
34
35
|
*
|
|
35
36
|
* @cssclass forge-avatar - The avatar class _(required)_.
|
|
36
37
|
*/
|
|
37
|
-
export declare class AvatarComponent extends
|
|
38
|
+
export declare class AvatarComponent extends BaseLitElement implements IAvatarComponent {
|
|
38
39
|
static styles: import("lit").CSSResult;
|
|
39
40
|
/** @deprecated Used for compatibility with legacy Forge @customElement decorator. */
|
|
40
41
|
static [CUSTOM_ELEMENT_NAME_PROPERTY]: keyof HTMLElementTagNameMap;
|
|
@@ -46,7 +47,6 @@ export declare class AvatarComponent extends LitElement implements IAvatarCompon
|
|
|
46
47
|
text: string;
|
|
47
48
|
/**
|
|
48
49
|
* Controls the number of letters to display from the text. By default the text is split on spaces and the first character of each word is used.
|
|
49
|
-
* @default 2
|
|
50
50
|
* @attribute letter-count
|
|
51
51
|
*/
|
|
52
52
|
letterCount: number;
|
package/esm/avatar/avatar.js
CHANGED
|
@@ -5,12 +5,12 @@
|
|
|
5
5
|
*/
|
|
6
6
|
var _a;
|
|
7
7
|
import { __decorate } from "tslib";
|
|
8
|
-
import {
|
|
8
|
+
import { html, nothing, unsafeCSS } from 'lit';
|
|
9
9
|
import { customElement, property, state } from 'lit/decorators.js';
|
|
10
10
|
import { styleMap } from 'lit/directives/style-map.js';
|
|
11
11
|
import { classMap } from 'lit/directives/class-map.js';
|
|
12
|
-
import { AVATAR_CONSTANTS } from './avatar-constants';
|
|
13
12
|
import { CUSTOM_ELEMENT_NAME_PROPERTY } from '@tylertech/forge-core';
|
|
13
|
+
import { BaseLitElement } from '../core/base/base-lit-element';
|
|
14
14
|
const styles = ':host{display:inline-block}:host([hidden]){display:none}.forge-avatar{--_avatar-size:var(--forge-avatar-size, 40px);--_avatar-background:var(--forge-avatar-background, var(--forge-theme-tertiary, #3d5afe));--_avatar-color:var(--forge-avatar-color, var(--forge-theme-on-tertiary, #ffffff));--_avatar-transition-duration:var(--forge-avatar-transition-duration, var(--forge-animation-duration-short4, 200ms));--_avatar-transition-timing:var(--forge-avatar-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_avatar-shape:var(--forge-avatar-shape, calc(var(--forge-shape-round, 50%) * var(--forge-shape-factor, 1)))}.forge-avatar{display:flex;align-items:center;justify-content:center;overflow:hidden;transition:height var(--_avatar-transition-duration) var(--_avatar-transition-timing),width var(--_avatar-transition-duration) var(--_avatar-transition-timing);border-radius:var(--_avatar-shape);box-sizing:border-box;width:var(--_avatar-size);height:var(--_avatar-size);background-color:var(--_avatar-background);background-position:center;background-repeat:no-repeat;background-size:cover;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-subheading2-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-subheading2-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-subheading2-font-size-scale, 1)));font-weight:var(--forge-typography-subheading2-font-weight,400);line-height:var(--forge-typography-subheading2-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-subheading2-line-height-scale, 1.25)));letter-spacing:var(--forge-typography-subheading2-letter-spacing, normal);text-transform:var(--forge-typography-subheading2-text-transform,inherit);text-decoration:var(--forge-typography-subheading2-text-decoration,inherit);color:var(--_avatar-color)}.forge-avatar--image{background-color:inherit}';
|
|
15
15
|
const charsByLetterCount = (text, count) => {
|
|
16
16
|
if (!text?.trim()) {
|
|
@@ -43,7 +43,7 @@ export const AVATAR_TAG_NAME = 'forge-avatar';
|
|
|
43
43
|
*
|
|
44
44
|
* @cssclass forge-avatar - The avatar class _(required)_.
|
|
45
45
|
*/
|
|
46
|
-
let AvatarComponent = class AvatarComponent extends
|
|
46
|
+
let AvatarComponent = class AvatarComponent extends BaseLitElement {
|
|
47
47
|
constructor() {
|
|
48
48
|
super(...arguments);
|
|
49
49
|
/**
|
|
@@ -54,10 +54,9 @@ let AvatarComponent = class AvatarComponent extends LitElement {
|
|
|
54
54
|
this.text = '';
|
|
55
55
|
/**
|
|
56
56
|
* Controls the number of letters to display from the text. By default the text is split on spaces and the first character of each word is used.
|
|
57
|
-
* @default 2
|
|
58
57
|
* @attribute letter-count
|
|
59
58
|
*/
|
|
60
|
-
this.letterCount =
|
|
59
|
+
this.letterCount = 2;
|
|
61
60
|
/**
|
|
62
61
|
* The background image URL to use.
|
|
63
62
|
* @default ''
|
|
@@ -77,7 +76,7 @@ let AvatarComponent = class AvatarComponent extends LitElement {
|
|
|
77
76
|
part="root"
|
|
78
77
|
class=${classMap({ 'forge-avatar': true, 'forge-avatar--image': !!this._image })}
|
|
79
78
|
style=${this._image ? styleMap({ backgroundImage: `url(${this._image.src})` }) : nothing}>
|
|
80
|
-
<slot>${this._image ? nothing : charsByLetterCount(this.text, this.letterCount
|
|
79
|
+
<slot>${this._image ? nothing : charsByLetterCount(this.text, this.letterCount)}</slot>
|
|
81
80
|
</div>
|
|
82
81
|
`;
|
|
83
82
|
}
|
package/esm/badge/badge.d.ts
CHANGED
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
* Copyright Tyler Technologies, Inc.
|
|
4
4
|
* License: Apache-2.0
|
|
5
5
|
*/
|
|
6
|
-
import {
|
|
6
|
+
import { PropertyValues, TemplateResult } from 'lit';
|
|
7
7
|
import { BadgeTheme } from './badge-constants';
|
|
8
8
|
import { CUSTOM_ELEMENT_NAME_PROPERTY } from '@tylertech/forge-core';
|
|
9
|
-
|
|
9
|
+
import { BaseLitElement } from '../core/base/base-lit-element';
|
|
10
|
+
export interface IBadgeComponent extends BaseLitElement {
|
|
10
11
|
dot: boolean;
|
|
11
12
|
theme: BadgeTheme;
|
|
12
13
|
strong: boolean;
|
|
@@ -43,7 +44,7 @@ export declare const BADGE_TAG_NAME: keyof HTMLElementTagNameMap;
|
|
|
43
44
|
* @cssclass forge-badge--dot - Renders the badge as a dot.
|
|
44
45
|
* @cssclass forge-badge__icon - Styles a child element as an icon.
|
|
45
46
|
*/
|
|
46
|
-
export declare class BadgeComponent extends
|
|
47
|
+
export declare class BadgeComponent extends BaseLitElement implements IBadgeComponent {
|
|
47
48
|
#private;
|
|
48
49
|
static styles: import("lit").CSSResult;
|
|
49
50
|
/** @deprecated Used for compatibility with legacy Forge @customElement decorator. */
|
package/esm/badge/badge.js
CHANGED
|
@@ -5,11 +5,12 @@
|
|
|
5
5
|
*/
|
|
6
6
|
var _BadgeComponent_internals, _a;
|
|
7
7
|
import { __classPrivateFieldGet, __classPrivateFieldSet, __decorate } from "tslib";
|
|
8
|
-
import { html,
|
|
8
|
+
import { html, unsafeCSS } from 'lit';
|
|
9
9
|
import { customElement, property } from 'lit/decorators.js';
|
|
10
|
-
import { toggleState } from '../core';
|
|
11
|
-
const styles = ':host{display:flex;box-sizing:border-box}:host([hidden]){display:none}.forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary, #ffc107));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary, #000000));--_badge-shape:var(--forge-badge-shape, calc(var(--forge-shape-full, 9999px) * var(--forge-shape-factor, 1)));--_badge-height:var(--forge-badge-height, 20px);--_badge-min-width:var(--forge-badge-min-width, 0);--_badge-max-width:var(--forge-badge-max-width, auto);--_badge-padding-inline:var(--forge-badge-padding-inline, var(--forge-spacing-xsmall, 8px));--_badge-padding-block:var(--forge-badge-padding-block, 0);--_badge-border-width:var(--forge-badge-border-width, var(--forge-border-thin, 1px));--_badge-border-style:var(--forge-badge-border-style, none);--_badge-border-color:var(--forge-badge-border-color, var(--_badge-color));--_badge-gap:var(--forge-badge-gap, var(--forge-spacing-xsmall, 8px));--_badge-font-weight:var(--forge-badge-font-weight, bold);--_badge-dot-size:var(--forge-badge-dot-size, 8px);--_badge-dot-height:var(--forge-badge-dot-height, var(--_badge-dot-size));--_badge-dot-width:var(--forge-badge-dot-width, var(--_badge-dot-size));--_badge-dot-padding:var(--forge-badge-dot-padding, 0);--_badge-transition-duration:var(--forge-badge-transition-duration, var(--forge-animation-duration-short4, 200ms));--_badge-transition-easing:var(--forge-badge-transition-easing, var(--forge-animation-easing-decelerate, cubic-bezier(0, 0, 0, 1)))}.forge-badge{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-label1-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-label1-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-label-font-size-scale, .75)));font-weight:var(--forge-typography-label1-font-weight,400);line-height:var(--forge-typography-label1-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-label-line-height-scale, 1.25)));letter-spacing:var(--forge-typography-label1-letter-spacing, .0357142857em);text-transform:var(--forge-typography-label1-text-transform,inherit);text-decoration:var(--forge-typography-label1-text-decoration,inherit);background:var(--_badge-background);color:var(--_badge-color);height:var(--_badge-height);min-width:var(--_badge-min-width);max-width:var(--_badge-max-width);border-width:var(--_badge-border-width);border-style:var(--_badge-border-style);border-color:var(--_badge-border-color);display:inline-flex;align-items:center;gap:var(--_badge-gap);border-radius:var(--_badge-shape);padding-inline:var(--_badge-padding-inline);padding-block:var(--_badge-padding-block);overflow:hidden;box-sizing:border-box;pointer-events:none;transition:transform var(--_badge-transition-duration) var(--_badge-transition-easing);font-weight:var(--_badge-font-weight);text-overflow:ellipsis;white-space:nowrap}.forge-badge .content{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}::slotted(:is([slot=start],[slot=end])){font-size:inherit}:host(:where([hide],:state(hidden))) .forge-badge{transform:scale(0)}:host(:where([dot],:state(dot))) .forge-badge{--_badge-height:var(--_badge-dot-height);--_badge-min-width:var(--forge-badge-min-width, auto);padding:var(--_badge-dot-padding);width:var(--_badge-dot-width)}:host(:where([dot],:state(dot))) .content>slot{display:none}:host([theme=primary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-primary-container, #d1d5ed));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-primary-container, #222c62))}:host(:where([strong],:state(strong))[theme=primary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-primary, #3f51b5));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-primary, #ffffff))}:host([theme=secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary-container, #fff0c3));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary-container, #8a6804))}:host(:where([strong],:state(strong))[theme=secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary, #ffc107));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary, #000000))}:host([theme=tertiary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-tertiary-container, #d0d7ff));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-tertiary-container, #213189))}:host(:where([strong],:state(strong))[theme=tertiary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-tertiary, #3d5afe));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=success]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-success-container, #cde0ce));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-success-container, #19441b))}:host(:where([strong],:state(strong))[theme=success]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-success, #2e7d32));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-success, #ffffff))}:host([theme=warning]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-warning-container, #f4d3c2));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-warning-container, #712700))}:host(:where([strong],:state(strong))[theme=warning]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-warning, #d14900));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-warning, #ffffff))}:host(:not(:where([strong],:state(strong))):is([theme=error],[theme=danger])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-error-container-low, #f6e0e4));--_badge-color:var(--forge-badge-color, var(--forge-theme-error, #b00020))}:host(:where([strong],:state(strong)):is([theme=error],[theme=danger])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-error, #b00020));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-error, #ffffff))}:host(:not(:where([strong],:state(strong))):is([theme=info],[theme=info-primary])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-info-container, #c7daf0));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-info-container, #0b3768))}:host(:where([strong],:state(strong)):is([theme=info],[theme=info-primary])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-info, #1565c0));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-info, #ffffff))}:host(:not(:where([strong],:state(strong)))[theme=info-secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-surface-container-low, #ebebeb));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-surface-container-low, #000000))}:host(:where([strong],:state(strong))[theme=info-secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-surface-inverse, #333333));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-surface-inverse, #ffffff))}';
|
|
10
|
+
import { toggleState } from '../core/utils/utils';
|
|
12
11
|
import { CUSTOM_ELEMENT_NAME_PROPERTY } from '@tylertech/forge-core';
|
|
12
|
+
import { BaseLitElement } from '../core/base/base-lit-element';
|
|
13
|
+
const styles = ':host{display:flex;box-sizing:border-box}:host([hidden]){display:none}.forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary, #ffc107));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary, #000000));--_badge-shape:var(--forge-badge-shape, calc(var(--forge-shape-full, 9999px) * var(--forge-shape-factor, 1)));--_badge-height:var(--forge-badge-height, 20px);--_badge-min-width:var(--forge-badge-min-width, 0);--_badge-max-width:var(--forge-badge-max-width, auto);--_badge-padding-inline:var(--forge-badge-padding-inline, var(--forge-spacing-xsmall, 8px));--_badge-padding-block:var(--forge-badge-padding-block, 0);--_badge-border-width:var(--forge-badge-border-width, var(--forge-border-thin, 1px));--_badge-border-style:var(--forge-badge-border-style, none);--_badge-border-color:var(--forge-badge-border-color, var(--_badge-color));--_badge-gap:var(--forge-badge-gap, var(--forge-spacing-xsmall, 8px));--_badge-font-weight:var(--forge-badge-font-weight, bold);--_badge-dot-size:var(--forge-badge-dot-size, 8px);--_badge-dot-height:var(--forge-badge-dot-height, var(--_badge-dot-size));--_badge-dot-width:var(--forge-badge-dot-width, var(--_badge-dot-size));--_badge-dot-padding:var(--forge-badge-dot-padding, 0);--_badge-transition-duration:var(--forge-badge-transition-duration, var(--forge-animation-duration-short4, 200ms));--_badge-transition-easing:var(--forge-badge-transition-easing, var(--forge-animation-easing-decelerate, cubic-bezier(0, 0, 0, 1)))}.forge-badge{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-label1-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-label1-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-label-font-size-scale, .75)));font-weight:var(--forge-typography-label1-font-weight,400);line-height:var(--forge-typography-label1-line-height, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-label-line-height-scale, 1.25)));letter-spacing:var(--forge-typography-label1-letter-spacing, .0357142857em);text-transform:var(--forge-typography-label1-text-transform,inherit);text-decoration:var(--forge-typography-label1-text-decoration,inherit);background:var(--_badge-background);color:var(--_badge-color);height:var(--_badge-height);min-width:var(--_badge-min-width);max-width:var(--_badge-max-width);border-width:var(--_badge-border-width);border-style:var(--_badge-border-style);border-color:var(--_badge-border-color);display:inline-flex;align-items:center;gap:var(--_badge-gap);border-radius:var(--_badge-shape);padding-inline:var(--_badge-padding-inline);padding-block:var(--_badge-padding-block);overflow:hidden;box-sizing:border-box;pointer-events:none;transition:transform var(--_badge-transition-duration) var(--_badge-transition-easing);font-weight:var(--_badge-font-weight);text-overflow:ellipsis;white-space:nowrap}.forge-badge .content{overflow:hidden;white-space:nowrap;text-overflow:ellipsis}::slotted(:is([slot=start],[slot=end])){font-size:inherit}:host(:where([hide],:state(hidden))) .forge-badge{transform:scale(0)}:host(:where([dot],:state(dot))) .forge-badge{--_badge-height:var(--_badge-dot-height);--_badge-min-width:var(--forge-badge-min-width, auto);padding:var(--_badge-dot-padding);width:var(--_badge-dot-width)}:host(:where([dot],:state(dot))) .content>slot{display:none}:host([theme=primary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-primary-container, #d1d5ed));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-primary-container, #222c62))}:host(:where([strong],:state(strong))[theme=primary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-primary, #3f51b5));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-primary, #ffffff))}:host([theme=secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary-container, #fff0c3));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary-container, #8a6804))}:host(:where([strong],:state(strong))[theme=secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-secondary, #ffc107));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-secondary, #000000))}:host([theme=tertiary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-tertiary-container, #d0d7ff));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-tertiary-container, #213189))}:host(:where([strong],:state(strong))[theme=tertiary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-tertiary, #3d5afe));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=success]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-success-container, #cde0ce));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-success-container, #19441b))}:host(:where([strong],:state(strong))[theme=success]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-success, #2e7d32));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-success, #ffffff))}:host([theme=warning]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-warning-container, #f4d3c2));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-warning-container, #712700))}:host(:where([strong],:state(strong))[theme=warning]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-warning, #d14900));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-warning, #ffffff))}:host(:not(:where([strong],:state(strong))):is([theme=error],[theme=danger])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-error-container-low, #f6e0e4));--_badge-color:var(--forge-badge-color, var(--forge-theme-error, #b00020))}:host(:where([strong],:state(strong)):is([theme=error],[theme=danger])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-error, #b00020));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-error, #ffffff))}:host(:not(:where([strong],:state(strong))):is([theme=info],[theme=info-primary])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-info-container, #c7daf0));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-info-container, #0b3768))}:host(:where([strong],:state(strong)):is([theme=info],[theme=info-primary])) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-info, #1565c0));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-info, #ffffff))}:host(:not(:where([strong],:state(strong)))[theme=info-secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-surface-container-low, #ebebeb));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-surface-container-low, #000000))}:host(:where([strong],:state(strong))[theme=info-secondary]) .forge-badge{--_badge-background:var(--forge-badge-background, var(--forge-theme-surface-inverse, #333333));--_badge-color:var(--forge-badge-color, var(--forge-theme-on-surface-inverse, #ffffff))}';
|
|
13
14
|
export const BADGE_TAG_NAME = 'forge-badge';
|
|
14
15
|
/**
|
|
15
16
|
* @tag forge-badge
|
|
@@ -36,7 +37,7 @@ export const BADGE_TAG_NAME = 'forge-badge';
|
|
|
36
37
|
* @cssclass forge-badge--dot - Renders the badge as a dot.
|
|
37
38
|
* @cssclass forge-badge__icon - Styles a child element as an icon.
|
|
38
39
|
*/
|
|
39
|
-
let BadgeComponent = class BadgeComponent extends
|
|
40
|
+
let BadgeComponent = class BadgeComponent extends BaseLitElement {
|
|
40
41
|
constructor() {
|
|
41
42
|
super();
|
|
42
43
|
_BadgeComponent_internals.set(this, void 0);
|
package/esm/button/button.js
CHANGED
|
@@ -14,7 +14,7 @@ import { BUTTON_CONSTANTS } from './button-constants';
|
|
|
14
14
|
import { ButtonCore } from './button-core';
|
|
15
15
|
import { BASE_BUTTON_CONSTANTS } from './base/base-button-constants';
|
|
16
16
|
const template = '<template><div class=\"forge-button\" part=\"root\"><slot name=\"start\"></slot><slot></slot><slot name=\"end\"></slot><forge-focus-indicator target=\":host\" part=\"focus-indicator\"></forge-focus-indicator><forge-state-layer target=\":host\" exportparts=\"surface:state-layer\"></forge-state-layer></div></template>';
|
|
17
|
-
const styles = ':host{--_button-display:var(--forge-button-display, inline-grid);--_button-disabled-cursor:var(--forge-button-disabled-cursor, not-allowed)}:host{display:var(--_button-display);position:relative;outline:0;vertical-align:middle;-webkit-tap-highlight-color:transparent}:host([hidden]){display:none}.forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-primary, #3f51b5));--_button-text-color:var(--forge-button-text-color, var(--_button-primary-color));--_button-disabled-color:var(--forge-button-disabled-color, var(--forge-theme-surface-container, #e0e0e0));--_button-padding:var(--forge-button-padding, var(--forge-spacing-medium, 16px));--_button-justify:var(--forge-button-justify, center);--_button-shape:var(--forge-button-shape, calc(var(--forge-shape-medium, 4px) * var(--forge-shape-factor, 1)));--_button-height:var(--forge-button-height, 36px);--_button-min-width:var(--forge-button-min-width, 64px);--_button-spacing:var(--forge-button-spacing, var(--forge-spacing-xsmall, 8px));--_button-border-width:var(--forge-button-border-width, medium);--_button-border-style:var(--forge-button-border-style, none);--_button-border-color:var(--forge-button-border-color, currentColor);--_button-shape-start-start-radius:var(--forge-button-shape-start-start-radius, var(--_button-shape));--_button-shape-start-end-radius:var(--forge-button-shape-start-end-radius, var(--_button-shape));--_button-shape-end-start-radius:var(--forge-button-shape-end-start-radius, var(--_button-shape));--_button-shape-end-end-radius:var(--forge-button-shape-end-end-radius, var(--_button-shape));--_button-padding-block:var(--forge-button-padding-block, var(--_button-0));--_button-padding-inline:var(--forge-button-padding-inline, var(--_button-padding));--_button-background:var(--forge-button-background, transparent);--_button-hover-background:var(--forge-button-hover-background, var(--_button-background));--_button-active-background:var(--forge-button-active-background, var(--_button-background));--_button-color:var(--forge-button-color, var(--_button-text-color));--_button-icon-size:var(--forge-button-icon-size, calc(var(--forge-typography-font-size, 1rem) * 1.125));--_button-shadow:var(--forge-button-shadow, none);--_button-hover-shadow:var(--forge-button-hover-shadow, none);--_button-active-shadow:var(--forge-button-active-shadow, none);--_button-cursor:var(--forge-button-cursor, pointer);--_button-transition-duration:var(--forge-button-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-transition-timing:var(--forge-button-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-text-padding-inline:var(--forge-button-text-padding-inline, var(--forge-spacing-xsmall, 8px));--_button-outlined-background:var(--forge-button-outlined-background, transparent);--_button-outlined-color:var(--forge-button-outlined-color, var(--_button-primary-color));--_button-outlined-border-width:var(--forge-button-outlined-border-width, var(--forge-border-thin, 1px));--_button-outlined-border-style:var(--forge-button-outlined-border-style, solid);--_button-outlined-border-color:var(--forge-button-outlined-border-color, var(--_button-primary-color));--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-primary-container, #d1d5ed));--_button-tonal-disabled-background:var(--forge-button-tonal-disabled-background, var(--_button-disabled-color));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-primary-container, #222c62));--_button-tonal-disabled-color:var(--forge-button-tonal-disabled-color, var(--_button-disabled-text-color));--_button-filled-background:var(--forge-button-filled-background, var(--_button-primary-color));--_button-filled-disabled-background:var(--forge-button-filled-disabled-background, var(--_button-disabled-color));--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-primary, #ffffff));--_button-filled-disabled-color:var(--forge-button-filled-disabled-color, var(--_button-disabled-text-color));--_button-raised-background:var(--forge-button-raised-background, var(--_button-primary-color));--_button-raised-disabled-background:var(--forge-button-raised-disabled-background, var(--_button-disabled-color));--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-primary, #ffffff));--_button-raised-disabled-color:var(--forge-button-raised-disabled-color, var(--_button-disabled-text-color));--_button-raised-shadow:var(--forge-button-raised-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));--_button-raised-hover-shadow:var(--forge-button-raised-hover-shadow, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12));--_button-raised-active-shadow:var(--forge-button-raised-active-shadow, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12));--_button-raised-disabled-shadow:var(--forge-button-raised-disabled-shadow, none);--_button-link-color:var(--forge-button-link-color, var(--_button-primary-color));--_button-link-text-decoration:var(--forge-button-link-text-decoration, underline);--_button-link-height:var(--forge-button-link-height, auto);--_button-link-padding:var(--forge-button-link-padding, 0);--_button-link-line-height:var(--forge-button-link-line-height, normal);--_button-link-width:var(--forge-button-link-width, auto);--_button-link-hover-text-decoration:var(--forge-button-link-hover-text-decoration, none);--_button-link-active-opacity:var(--forge-button-link-active-opacity, 0.65);--_button-link-transition-duration:var(--forge-button-link-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-link-transition-timing:var(--forge-button-link-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-disabled-text-color:var(--forge-button-disabled-text-color, var(--forge-theme-text-low, rgba(0, 0, 0, 0.38)));--_button-disabled-background:var(--forge-button-disabled-background, transparent);--_button-disabled-border-color:var(--forge-button-disabled-border-color, var(--_button-disabled-color));--_button-disabled-shadow:var(--forge-button-disabled-shadow, none);--_button-dense-height:var(--forge-button-dense-height, 24px);--_button-pill-shape:var(--forge-button-pill-shape, calc(var(--forge-shape-full, 9999px) * var(--forge-shape-factor, 1)));--_button-pill-padding-inline:var(--forge-button-pill-padding-inline, var(--forge-spacing-small, 12px));--_button-focus-indicator-offset:var(--forge-button-focus-indicator-offset, 4px);--_button-text-focus-indicator-offset:var(--forge-button-text-focus-indicator-offset, 0px);--_button-link-focus-indicator-offset:var(--forge-button-link-focus-indicator-offset, 2px);--_button-popover-icon-transition-duration:var(--forge-button-popover-icon-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-popover-icon-transition-timing:var(--forge-button-popover-icon-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-popover-icon-open-rotation:var(--forge-button-popover-icon-open-rotation, 180deg)}.forge-button{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-button-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-button-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-button-font-size-scale, .875)));font-weight:var(--forge-typography-button-font-weight,500);line-height:var(--forge-typography-button-line-height, normal);letter-spacing:var(--forge-typography-button-letter-spacing, .0714285714em);text-transform:var(--forge-typography-button-text-transform,inherit);text-decoration:var(--forge-typography-button-text-decoration,inherit);position:relative;display:var(--_button-display);grid-auto-flow:column;align-items:center;justify-content:var(--_button-justify);gap:var(--_button-spacing);z-index:0;box-sizing:border-box;min-inline-size:var(--_button-min-width);height:var(--_button-height);inline-size:100%;border-width:var(--_button-border-width);border-style:var(--_button-border-style);border-color:var(--_button-border-color);border-start-start-radius:var(--_button-shape-start-start-radius);border-start-end-radius:var(--_button-shape-start-end-radius);border-end-start-radius:var(--_button-shape-end-start-radius);border-end-end-radius:var(--_button-shape-end-end-radius);padding-block:var(--_button-padding-block);padding-inline:var(--_button-padding-inline);box-shadow:var(--_button-shadow);outline:0;user-select:none;-webkit-appearance:none;vertical-align:middle;text-decoration:none;white-space:nowrap;background:var(--_button-background);color:var(--_button-color);cursor:var(--_button-cursor);transition-property:box-shadow,background;transition-duration:var(--_button-transition-duration);transition-timing-function:var(--_button-transition-timing)}.forge-button::-moz-focus-inner{padding:0;border:0}.forge-button:hover{--_button-shadow:var(--_button-hover-shadow);background:var(--_button-hover-background)}.forge-button:active{--_button-shadow:var(--_button-active-shadow);background:var(--_button-active-background)}.forge-button ::slotted(:is([slot=start],[slot=end])){font-size:var(--_button-icon-size)}.with-anchor{display:flex;justify-content:stretch;align-items:stretch;padding:0}::slotted(a){display:flex;align-items:center;justify-content:center;gap:var(--_button-spacing);width:100%;padding:var(--_button-padding);color:var(--_button-color);outline:0;border-radius:var(--_button-shape);text-decoration:none;--forge-icon-font-size:var(--_button-icon-size)}:host([variant=link]) ::slotted(a){position:relative;inset:auto}forge-state-layer{--forge-state-layer-color:var(--_button-color)}forge-focus-indicator{--forge-focus-indicator-color:var(--_button-primary-color);--forge-focus-indicator-outward-offset:var(--_button-focus-indicator-offset)}:host([theme=secondary]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-secondary, #ffc107))}:host([theme=secondary][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-secondary, #000000))}:host([theme=secondary][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-secondary, #000000))}:host([theme=secondary][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-secondary-container, #fff0c3));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-secondary-container, #8a6804))}:host([theme=tertiary]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-tertiary, #3d5afe))}:host([theme=tertiary][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=tertiary][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=tertiary][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-tertiary-container, #d0d7ff));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-tertiary-container, #213189))}:host([theme=success]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-success, #2e7d32))}:host([theme=success][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-success, #ffffff))}:host([theme=success][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-success, #ffffff))}:host([theme=success][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-success-container, #cde0ce));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-success-container, #19441b))}:host([theme=error]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-error, #b00020))}:host([theme=error][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-error, #ffffff))}:host([theme=error][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-error, #ffffff))}:host([theme=error][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-error-container, #ecc2c9));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-error-container, #5f0011))}:host([theme=warning]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-warning, #d14900))}:host([theme=warning][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-warning, #ffffff))}:host([theme=warning][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-warning, #ffffff))}:host([theme=warning][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-warning-container, #f4d3c2));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-warning-container, #712700))}:host([theme=info]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-info, #1565c0))}:host([theme=info][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-info, #ffffff))}:host([theme=info][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-info, #ffffff))}:host([theme=info][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-info-container, #c7daf0));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-info-container, #0b3768))}:host(:where(:not([variant]),[variant=text])) .forge-button{--_button-padding-inline:var(--_button-text-padding-inline)}:host([variant=filled]) .forge-button{--_button-background:var(--_button-filled-background);--_button-color:var(--_button-filled-color)}:host([variant=filled]) forge-state-layer{--forge-state-layer-color:var(--_button-filled-color)}:host([variant=raised]) .forge-button{--_button-background:var(--_button-raised-background);--_button-color:var(--_button-raised-color);--_button-shadow:var(--_button-raised-shadow)}:host([variant=raised]) .forge-button:hover{--_button-shadow:var(--_button-raised-hover-shadow)}:host([variant=raised]) .forge-button:active{--_button-shadow:var(--_button-raised-active-shadow)}:host([variant=raised]) forge-state-layer{--forge-state-layer-color:var(--_button-raised-color)}:host([variant=tonal]) .forge-button{--_button-background:var(--_button-tonal-background);--_button-color:var(--_button-tonal-color)}:host([variant=tonal]) forge-state-layer{--forge-state-layer-color:var(--_button-tonal-color)}:host([variant=outlined]) .forge-button{--_button-background:var(--_button-outlined-background);--_button-color:var(--_button-outlined-color);--_button-border-width:var(--_button-outlined-border-width);--_button-border-style:var(--_button-outlined-border-style);--_button-border-color:var(--_button-outlined-border-color)}:host([variant=link]) .forge-button{--_button-color:var(--_button-link-color);--_button-height:var(--_button-link-height);--_button-padding:var(--_button-link-padding);--_button-focus-indicator-offset:var(--_button-link-focus-indicator-offset);text-decoration:var(--_button-link-text-decoration);line-height:var(--_button-link-line-height);transition:opacity var(--_button-link-transition-duration) var(--_button-link-transition-timing);inline-size:var(--_button-link-width)}:host([variant=link]) .forge-button:hover{text-decoration:var(--_button-link-hover-text-decoration)}:host([variant=link]) .forge-button:active{opacity:var(--_button-link-active-opacity)}:host([full-width]){width:100%}:host([dense]) .forge-button{--_button-height:var(--_button-dense-height)}:host([pill]) .forge-button{--_button-shape:var(--_button-pill-shape);--_button-padding-inline:var(--_button-pill-padding-inline)}:host([pill]) forge-focus-indicator{--forge-focus-indicator-shape:var(--_button-pill-shape)}:host(:not([anchor])[disabled]){cursor:var(--_button-disabled-cursor)}:host(:not([anchor])[disabled]) .forge-button{--_button-background:var(--_button-disabled-background);--_button-color:var(--_button-disabled-text-color);--_button-shadow:var(--_button-disabled-shadow);pointer-events:none}:host(:not([anchor])[variant=outlined][disabled]) .forge-button{--_button-border-color:var(--_button-disabled-border-color)}:host(:not([anchor])[variant=tonal][disabled]) .forge-button{--_button-background:var(--_button-tonal-disabled-background);--_button-color:var(--_button-tonal-disabled-color)}:host(:not([anchor])[variant=filled][disabled]) .forge-button{--_button-background:var(--_button-filled-disabled-background);--_button-color:var(--_button-filled-disabled-color)}:host(:not([anchor])[variant=raised][disabled]) .forge-button{--_button-background:var(--_button-raised-disabled-background);--_button-color:var(--_button-raised-disabled-color);--_button-shadow:var(--_button-raised-disabled-shadow)}:host([popover-icon]) .forge-button__popover-icon{transition:rotate var(--_button-popover-icon-transition-duration) var(--_button-popover-icon-transition-timing)}:host([popover-icon][aria-expanded=true]) .forge-button__popover-icon{rotate:var(--_button-popover-icon-open-rotation)}::slotted(forge-circular-progress){--forge-circular-progress-indicator-color:var(--_button-color);--forge-circular-progress-track-color:transparent;--forge-circular-progress-size:1em}';
|
|
17
|
+
const styles = ':host{--_button-display:var(--forge-button-display, inline-grid);--_button-disabled-cursor:var(--forge-button-disabled-cursor, not-allowed)}:host{display:var(--_button-display);position:relative;outline:0;vertical-align:middle;-webkit-tap-highlight-color:transparent}:host([hidden]){display:none}.forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-primary, #3f51b5));--_button-text-color:var(--forge-button-text-color, var(--_button-primary-color));--_button-disabled-color:var(--forge-button-disabled-color, var(--forge-theme-surface-container, #e0e0e0));--_button-padding:var(--forge-button-padding, var(--forge-spacing-medium, 16px));--_button-justify:var(--forge-button-justify, center);--_button-shape:var(--forge-button-shape, calc(var(--forge-shape-medium, 4px) * var(--forge-shape-factor, 1)));--_button-height:var(--forge-button-height, 36px);--_button-min-width:var(--forge-button-min-width, 64px);--_button-spacing:var(--forge-button-spacing, var(--forge-spacing-xsmall, 8px));--_button-border-width:var(--forge-button-border-width, medium);--_button-border-style:var(--forge-button-border-style, none);--_button-border-color:var(--forge-button-border-color, currentColor);--_button-shape-start-start-radius:var(--forge-button-shape-start-start-radius, var(--_button-shape));--_button-shape-start-end-radius:var(--forge-button-shape-start-end-radius, var(--_button-shape));--_button-shape-end-start-radius:var(--forge-button-shape-end-start-radius, var(--_button-shape));--_button-shape-end-end-radius:var(--forge-button-shape-end-end-radius, var(--_button-shape));--_button-padding-block:var(--forge-button-padding-block, var(--_button-0));--_button-padding-inline:var(--forge-button-padding-inline, var(--_button-padding));--_button-background:var(--forge-button-background, transparent);--_button-hover-background:var(--forge-button-hover-background, var(--_button-background));--_button-active-background:var(--forge-button-active-background, var(--_button-background));--_button-color:var(--forge-button-color, var(--_button-text-color));--_button-icon-size:var(--forge-button-icon-size, calc(var(--forge-typography-font-size, 1rem) * 1.125));--_button-shadow:var(--forge-button-shadow, none);--_button-hover-shadow:var(--forge-button-hover-shadow, none);--_button-active-shadow:var(--forge-button-active-shadow, none);--_button-cursor:var(--forge-button-cursor, pointer);--_button-transition-duration:var(--forge-button-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-transition-timing:var(--forge-button-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-text-padding-inline:var(--forge-button-text-padding-inline, var(--forge-spacing-xsmall, 8px));--_button-outlined-background:var(--forge-button-outlined-background, transparent);--_button-outlined-color:var(--forge-button-outlined-color, var(--_button-primary-color));--_button-outlined-border-width:var(--forge-button-outlined-border-width, var(--forge-border-thin, 1px));--_button-outlined-border-style:var(--forge-button-outlined-border-style, solid);--_button-outlined-border-color:var(--forge-button-outlined-border-color, var(--_button-primary-color));--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-primary-container, #d1d5ed));--_button-tonal-disabled-background:var(--forge-button-tonal-disabled-background, var(--_button-disabled-color));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-primary-container, #222c62));--_button-tonal-disabled-color:var(--forge-button-tonal-disabled-color, var(--_button-disabled-text-color));--_button-filled-background:var(--forge-button-filled-background, var(--_button-primary-color));--_button-filled-disabled-background:var(--forge-button-filled-disabled-background, var(--_button-disabled-color));--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-primary, #ffffff));--_button-filled-disabled-color:var(--forge-button-filled-disabled-color, var(--_button-disabled-text-color));--_button-raised-background:var(--forge-button-raised-background, var(--_button-primary-color));--_button-raised-disabled-background:var(--forge-button-raised-disabled-background, var(--_button-disabled-color));--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-primary, #ffffff));--_button-raised-disabled-color:var(--forge-button-raised-disabled-color, var(--_button-disabled-text-color));--_button-raised-shadow:var(--forge-button-raised-shadow, 0px 3px 1px -2px rgba(0, 0, 0, 0.2), 0px 2px 2px 0px rgba(0, 0, 0, 0.14), 0px 1px 5px 0px rgba(0, 0, 0, 0.12));--_button-raised-hover-shadow:var(--forge-button-raised-hover-shadow, 0px 2px 4px -1px rgba(0, 0, 0, 0.2), 0px 4px 5px 0px rgba(0, 0, 0, 0.14), 0px 1px 10px 0px rgba(0, 0, 0, 0.12));--_button-raised-active-shadow:var(--forge-button-raised-active-shadow, 0px 5px 5px -3px rgba(0, 0, 0, 0.2), 0px 8px 10px 1px rgba(0, 0, 0, 0.14), 0px 3px 14px 2px rgba(0, 0, 0, 0.12));--_button-raised-disabled-shadow:var(--forge-button-raised-disabled-shadow, none);--_button-link-color:var(--forge-button-link-color, var(--_button-primary-color));--_button-link-text-decoration:var(--forge-button-link-text-decoration, underline);--_button-link-height:var(--forge-button-link-height, auto);--_button-link-padding:var(--forge-button-link-padding, 0);--_button-link-line-height:var(--forge-button-link-line-height, normal);--_button-link-width:var(--forge-button-link-width, auto);--_button-link-hover-text-decoration:var(--forge-button-link-hover-text-decoration, none);--_button-link-active-opacity:var(--forge-button-link-active-opacity, 0.65);--_button-link-transition-duration:var(--forge-button-link-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-link-transition-timing:var(--forge-button-link-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-disabled-text-color:var(--forge-button-disabled-text-color, var(--forge-theme-text-low, rgba(0, 0, 0, 0.38)));--_button-disabled-background:var(--forge-button-disabled-background, transparent);--_button-disabled-border-color:var(--forge-button-disabled-border-color, var(--_button-disabled-color));--_button-disabled-shadow:var(--forge-button-disabled-shadow, none);--_button-dense-height:var(--forge-button-dense-height, 24px);--_button-pill-shape:var(--forge-button-pill-shape, calc(var(--forge-shape-full, 9999px) * var(--forge-shape-factor, 1)));--_button-pill-padding-inline:var(--forge-button-pill-padding-inline, var(--forge-spacing-small, 12px));--_button-focus-indicator-offset:var(--forge-button-focus-indicator-offset, 4px);--_button-text-focus-indicator-offset:var(--forge-button-text-focus-indicator-offset, 0px);--_button-link-focus-indicator-offset:var(--forge-button-link-focus-indicator-offset, 2px);--_button-popover-icon-transition-duration:var(--forge-button-popover-icon-transition-duration, var(--forge-animation-duration-short3, 150ms));--_button-popover-icon-transition-timing:var(--forge-button-popover-icon-transition-timing, var(--forge-animation-easing-standard, cubic-bezier(0.2, 0, 0, 1)));--_button-popover-icon-open-rotation:var(--forge-button-popover-icon-open-rotation, 180deg)}.forge-button{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:var(--forge-typography-button-font-family, var(--forge-typography-font-family, \"Roboto\", sans-serif));font-size:var(--forge-typography-button-font-size, calc(var(--forge-typography-font-size, 1rem) * var(--forge-typography-button-font-size-scale, .875)));font-weight:var(--forge-typography-button-font-weight,500);line-height:var(--forge-typography-button-line-height, normal);letter-spacing:var(--forge-typography-button-letter-spacing, .0714285714em);text-transform:var(--forge-typography-button-text-transform,inherit);text-decoration:var(--forge-typography-button-text-decoration,inherit);position:relative;display:var(--_button-display);grid-auto-flow:column;align-items:center;justify-content:var(--_button-justify);gap:var(--_button-spacing);z-index:0;box-sizing:border-box;min-inline-size:var(--_button-min-width);height:var(--_button-height);inline-size:100%;border-width:var(--_button-border-width);border-style:var(--_button-border-style);border-color:var(--_button-border-color);border-start-start-radius:var(--_button-shape-start-start-radius);border-start-end-radius:var(--_button-shape-start-end-radius);border-end-start-radius:var(--_button-shape-end-start-radius);border-end-end-radius:var(--_button-shape-end-end-radius);padding-block:var(--_button-padding-block);padding-inline:var(--_button-padding-inline);box-shadow:var(--_button-shadow);outline:0;user-select:none;-webkit-appearance:none;vertical-align:middle;text-decoration:none;white-space:nowrap;background:var(--_button-background);color:var(--_button-color);cursor:var(--_button-cursor);transition-property:box-shadow,background;transition-duration:var(--_button-transition-duration);transition-timing-function:var(--_button-transition-timing)}.forge-button::-moz-focus-inner{padding:0;border:0}.forge-button:hover{--_button-shadow:var(--_button-hover-shadow);background:var(--_button-hover-background)}.forge-button:active{--_button-shadow:var(--_button-active-shadow);background:var(--_button-active-background)}.forge-button ::slotted(:is([slot=start],[slot=end])){font-size:var(--_button-icon-size)}.with-anchor{display:flex;justify-content:stretch;align-items:stretch;padding:0}::slotted(a){display:flex;align-items:center;justify-content:center;gap:var(--_button-spacing);width:100%;padding:var(--_button-padding);color:var(--_button-color);outline:0;border-radius:var(--_button-shape);text-decoration:none;--forge-icon-font-size:var(--_button-icon-size)}:host([variant=link]) ::slotted(a){position:relative;inset:auto}forge-state-layer{--forge-state-layer-color:var(--_button-color)}forge-focus-indicator{--forge-focus-indicator-color:var(--_button-primary-color);--forge-focus-indicator-outward-offset:var(--_button-focus-indicator-offset)}:host([theme=secondary]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-secondary, #ffc107))}:host([theme=secondary][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-secondary, #000000))}:host([theme=secondary][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-secondary, #000000))}:host([theme=secondary][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-secondary-container, #fff0c3));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-secondary-container, #8a6804))}:host([theme=tertiary]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-tertiary, #3d5afe))}:host([theme=tertiary][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=tertiary][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-tertiary, #ffffff))}:host([theme=tertiary][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-tertiary-container, #d0d7ff));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-tertiary-container, #213189))}:host([theme=success]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-success, #2e7d32))}:host([theme=success][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-success, #ffffff))}:host([theme=success][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-success, #ffffff))}:host([theme=success][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-success-container, #cde0ce));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-success-container, #19441b))}:host([theme=error]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-error, #b00020))}:host([theme=error][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-error, #ffffff))}:host([theme=error][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-error, #ffffff))}:host([theme=error][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-error-container, #ecc2c9));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-error-container, #5f0011))}:host([theme=warning]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-warning, #d14900))}:host([theme=warning][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-warning, #ffffff))}:host([theme=warning][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-warning, #ffffff))}:host([theme=warning][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-warning-container, #f4d3c2));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-warning-container, #712700))}:host([theme=info]) .forge-button{--_button-primary-color:var(--forge-button-primary-color, var(--forge-theme-info, #1565c0))}:host([theme=info][variant=filled]) .forge-button{--_button-filled-color:var(--forge-button-filled-color, var(--forge-theme-on-info, #ffffff))}:host([theme=info][variant=raised]) .forge-button{--_button-raised-color:var(--forge-button-raised-color, var(--forge-theme-on-info, #ffffff))}:host([theme=info][variant=tonal]) .forge-button{--_button-tonal-background:var(--forge-button-tonal-background, var(--forge-theme-info-container, #c7daf0));--_button-tonal-color:var(--forge-button-tonal-color, var(--forge-theme-on-info-container, #0b3768))}:host([theme=app-bar]){--forge-button-text-color:var(--_app-bar-theme-foreground);--forge-button-outlined-color:var(--_app-bar-theme-foreground);--forge-button-outlined-border-color:var(--_app-bar-theme-foreground);--forge-button-link-color:var(--_app-bar-theme-foreground)}:host([theme=app-bar]) forge-focus-indicator{--forge-focus-indicator-color:var(--_app-bar-theme-foreground)}:host(:where(:not([variant]),[variant=text])) .forge-button{--_button-padding-inline:var(--_button-text-padding-inline)}:host([variant=filled]) .forge-button{--_button-background:var(--_button-filled-background);--_button-color:var(--_button-filled-color)}:host([variant=filled]) forge-state-layer{--forge-state-layer-color:var(--_button-filled-color)}:host([variant=raised]) .forge-button{--_button-background:var(--_button-raised-background);--_button-color:var(--_button-raised-color);--_button-shadow:var(--_button-raised-shadow)}:host([variant=raised]) .forge-button:hover{--_button-shadow:var(--_button-raised-hover-shadow)}:host([variant=raised]) .forge-button:active{--_button-shadow:var(--_button-raised-active-shadow)}:host([variant=raised]) forge-state-layer{--forge-state-layer-color:var(--_button-raised-color)}:host([variant=tonal]) .forge-button{--_button-background:var(--_button-tonal-background);--_button-color:var(--_button-tonal-color)}:host([variant=tonal]) forge-state-layer{--forge-state-layer-color:var(--_button-tonal-color)}:host([variant=outlined]) .forge-button{--_button-background:var(--_button-outlined-background);--_button-color:var(--_button-outlined-color);--_button-border-width:var(--_button-outlined-border-width);--_button-border-style:var(--_button-outlined-border-style);--_button-border-color:var(--_button-outlined-border-color)}:host([variant=link]) .forge-button{--_button-color:var(--_button-link-color);--_button-height:var(--_button-link-height);--_button-padding:var(--_button-link-padding);--_button-focus-indicator-offset:var(--_button-link-focus-indicator-offset);text-decoration:var(--_button-link-text-decoration);line-height:var(--_button-link-line-height);transition:opacity var(--_button-link-transition-duration) var(--_button-link-transition-timing);inline-size:var(--_button-link-width)}:host([variant=link]) .forge-button:hover{text-decoration:var(--_button-link-hover-text-decoration)}:host([variant=link]) .forge-button:active{opacity:var(--_button-link-active-opacity)}:host([full-width]){width:100%}:host([dense]) .forge-button{--_button-height:var(--_button-dense-height)}:host([pill]) .forge-button{--_button-shape:var(--_button-pill-shape);--_button-padding-inline:var(--_button-pill-padding-inline)}:host([pill]) forge-focus-indicator{--forge-focus-indicator-shape:var(--_button-pill-shape)}:host(:not([anchor])[disabled]){cursor:var(--_button-disabled-cursor)}:host(:not([anchor])[disabled]) .forge-button{--_button-background:var(--_button-disabled-background);--_button-color:var(--_button-disabled-text-color);--_button-shadow:var(--_button-disabled-shadow);pointer-events:none}:host(:not([anchor])[variant=outlined][disabled]) .forge-button{--_button-border-color:var(--_button-disabled-border-color)}:host(:not([anchor])[variant=tonal][disabled]) .forge-button{--_button-background:var(--_button-tonal-disabled-background);--_button-color:var(--_button-tonal-disabled-color)}:host(:not([anchor])[variant=filled][disabled]) .forge-button{--_button-background:var(--_button-filled-disabled-background);--_button-color:var(--_button-filled-disabled-color)}:host(:not([anchor])[variant=raised][disabled]) .forge-button{--_button-background:var(--_button-raised-disabled-background);--_button-color:var(--_button-raised-disabled-color);--_button-shadow:var(--_button-raised-disabled-shadow)}:host([popover-icon]) .forge-button__popover-icon{transition:rotate var(--_button-popover-icon-transition-duration) var(--_button-popover-icon-transition-timing)}:host([popover-icon][aria-expanded=true]) .forge-button__popover-icon{rotate:var(--_button-popover-icon-open-rotation)}::slotted(forge-circular-progress){--forge-circular-progress-indicator-color:var(--_button-color);--forge-circular-progress-track-color:transparent;--forge-circular-progress-size:1em}';
|
|
18
18
|
/**
|
|
19
19
|
* @tag forge-button
|
|
20
20
|
*
|