@proximus/lavender-button 2.0.0-alpha.24 → 2.0.0-alpha.242
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/dist/Button.d.ts +104 -36
- package/dist/ButtonWrapper.d.ts +17 -0
- package/dist/custom-elements.json +1651 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +270 -234
- package/dist/vscode.css-custom-data.json +6 -0
- package/dist/vscode.html-custom-data.json +220 -0
- package/dist/web-types.json +350 -0
- package/package.json +2 -2
package/dist/Button.d.ts
CHANGED
|
@@ -1,19 +1,49 @@
|
|
|
1
1
|
import { PxElement } from '@proximus/lavender-common';
|
|
2
|
-
export declare const variantValues: readonly ["", "default", "secondary", "tertiary", "link", "patch", "patch-info", "patch-black-friday", "patch-eco", "actionable-tag", "header-dropdown"];
|
|
2
|
+
export declare const variantValues: readonly ["", "default", "secondary", "tertiary", "link", "patch", "patch-info", "patch-black-friday", "patch-eco", "actionable-tag", "actionable-tag-secondary", "header-dropdown", "header-minimal-dropdown"];
|
|
3
3
|
export declare const shapeValues: string[];
|
|
4
|
-
export type ButtonVariant = (typeof variantValues)[number];
|
|
5
4
|
/**
|
|
6
5
|
* @summary Primary button for actions, forms, and more.
|
|
7
|
-
* @slot before - Content to be placed before the button text
|
|
8
|
-
* @slot after - Content to be placed after the button text
|
|
6
|
+
* @slot before - Content to be placed before the button text.
|
|
7
|
+
* @slot after - Content to be placed after the button text.
|
|
8
|
+
* @attr {string} commandfor - The ID of the command target.
|
|
9
|
+
* @attr {string} popovertarget - The ID of the target popover.
|
|
10
|
+
* @attr {string} form - The ID of the associated form; the form property is the native form reference.
|
|
9
11
|
*/
|
|
10
12
|
export declare class Button extends PxElement<HTMLButtonElement> {
|
|
13
|
+
protected static readonly template: HTMLTemplateElement;
|
|
11
14
|
static nativeName: string;
|
|
12
|
-
|
|
13
|
-
|
|
15
|
+
static nativeProperties: {
|
|
16
|
+
form: "readonly";
|
|
17
|
+
labels: "readonly";
|
|
18
|
+
popoverTargetElement: "writable";
|
|
19
|
+
commandForElement: "writable";
|
|
20
|
+
validity: "readonly";
|
|
21
|
+
validationMessage: "readonly";
|
|
22
|
+
willValidate: "readonly";
|
|
23
|
+
};
|
|
24
|
+
static nativeMethods: ("checkValidity" | "reportValidity" | "setCustomValidity")[];
|
|
25
|
+
static nativeAttributes: {
|
|
26
|
+
disabled: "disabled"[];
|
|
27
|
+
name: "name"[];
|
|
28
|
+
value: "value"[];
|
|
29
|
+
type: "type"[];
|
|
30
|
+
formaction: "formAction"[];
|
|
31
|
+
formenctype: "formEnctype"[];
|
|
32
|
+
formmethod: "formMethod"[];
|
|
33
|
+
formnovalidate: "formNoValidate"[];
|
|
34
|
+
formtarget: "formTarget"[];
|
|
35
|
+
form: never[];
|
|
36
|
+
autofocus: "autofocus"[];
|
|
37
|
+
title: "title"[];
|
|
38
|
+
popovertarget: never[];
|
|
39
|
+
popovertargetaction: "popoverTargetAction"[];
|
|
40
|
+
command: "command"[];
|
|
41
|
+
commandfor: never[];
|
|
42
|
+
};
|
|
14
43
|
constructor();
|
|
15
44
|
static get observedAttributes(): string[];
|
|
16
45
|
connectedCallback(): void;
|
|
46
|
+
disconnectedCallback(): void;
|
|
17
47
|
attributeChangedCallback(attrName: string, oldValue: string, newValue: string): void;
|
|
18
48
|
checkClass(value: string): void;
|
|
19
49
|
_toggleClass(oldValue: string, newValue: string): void;
|
|
@@ -22,34 +52,72 @@ export declare class Button extends PxElement<HTMLButtonElement> {
|
|
|
22
52
|
updateExtended(attributeName: string, newValue: string): void;
|
|
23
53
|
updateLoading(): void;
|
|
24
54
|
updateShape(attrName: string, newValue: string, attrValue: string[]): void;
|
|
25
|
-
get variant(): string;
|
|
26
|
-
set variant(value: string);
|
|
27
|
-
get state(): string;
|
|
28
|
-
set state(value: string);
|
|
29
|
-
get extended():
|
|
30
|
-
set extended(value:
|
|
31
|
-
get extendedMobile():
|
|
32
|
-
set extendedMobile(value:
|
|
33
|
-
get extendedTablet():
|
|
34
|
-
set extendedTablet(value:
|
|
35
|
-
get extendedLaptop():
|
|
36
|
-
set extendedLaptop(value:
|
|
37
|
-
get extendedDesktop():
|
|
38
|
-
set extendedDesktop(value:
|
|
39
|
-
get loading():
|
|
40
|
-
set loading(value:
|
|
41
|
-
get shape(): string;
|
|
42
|
-
set shape(value: string);
|
|
43
|
-
get shapeMobile(): string;
|
|
44
|
-
set shapeMobile(value: string);
|
|
45
|
-
get shapeTablet(): string;
|
|
46
|
-
set shapeTablet(value: string);
|
|
47
|
-
get shapeLaptop(): string;
|
|
48
|
-
set shapeLaptop(value: string);
|
|
49
|
-
get shapeDesktop(): string;
|
|
50
|
-
set shapeDesktop(value: string);
|
|
51
|
-
get inverted():
|
|
52
|
-
set inverted(value:
|
|
53
|
-
get ariaExpanded(): string;
|
|
54
|
-
set ariaExpanded(value: string);
|
|
55
|
+
get variant(): string | null;
|
|
56
|
+
set variant(value: string | null);
|
|
57
|
+
get state(): string | null;
|
|
58
|
+
set state(value: string | null);
|
|
59
|
+
get extended(): boolean;
|
|
60
|
+
set extended(value: boolean);
|
|
61
|
+
get extendedMobile(): boolean;
|
|
62
|
+
set extendedMobile(value: boolean);
|
|
63
|
+
get extendedTablet(): boolean;
|
|
64
|
+
set extendedTablet(value: boolean);
|
|
65
|
+
get extendedLaptop(): boolean;
|
|
66
|
+
set extendedLaptop(value: boolean);
|
|
67
|
+
get extendedDesktop(): boolean;
|
|
68
|
+
set extendedDesktop(value: boolean);
|
|
69
|
+
get loading(): boolean;
|
|
70
|
+
set loading(value: boolean);
|
|
71
|
+
get shape(): string | null;
|
|
72
|
+
set shape(value: string | null);
|
|
73
|
+
get shapeMobile(): string | null;
|
|
74
|
+
set shapeMobile(value: string | null);
|
|
75
|
+
get shapeTablet(): string | null;
|
|
76
|
+
set shapeTablet(value: string | null);
|
|
77
|
+
get shapeLaptop(): string | null;
|
|
78
|
+
set shapeLaptop(value: string | null);
|
|
79
|
+
get shapeDesktop(): string | null;
|
|
80
|
+
set shapeDesktop(value: string | null);
|
|
81
|
+
get inverted(): boolean;
|
|
82
|
+
set inverted(value: boolean);
|
|
83
|
+
get ariaExpanded(): string | null;
|
|
84
|
+
set ariaExpanded(value: string | null);
|
|
85
|
+
get size(): string | null;
|
|
86
|
+
set size(value: string | null);
|
|
87
|
+
readonly form: HTMLFormElement | null;
|
|
88
|
+
readonly labels: NodeListOf<HTMLLabelElement>;
|
|
89
|
+
popoverTargetElement: Element | null;
|
|
90
|
+
commandForElement: Element | null;
|
|
91
|
+
/** @attr disabled - Whether the native button is disabled. */
|
|
92
|
+
disabled: boolean;
|
|
93
|
+
/** @attr name - The name submitted with the button's value. */
|
|
94
|
+
name: string;
|
|
95
|
+
/** @attr value - The value associated with the button. */
|
|
96
|
+
value: string;
|
|
97
|
+
/** @attr type - The native button behavior: submit, reset, or button. */
|
|
98
|
+
type: 'submit' | 'reset' | 'button';
|
|
99
|
+
/** @attr formaction - The submission URL override. */
|
|
100
|
+
formAction: string;
|
|
101
|
+
/** @attr formenctype - The submission encoding override. */
|
|
102
|
+
formEnctype: string;
|
|
103
|
+
/** @attr formmethod - The submission method override. */
|
|
104
|
+
formMethod: string;
|
|
105
|
+
/** @attr formnovalidate - Whether submission bypasses validation. */
|
|
106
|
+
formNoValidate: boolean;
|
|
107
|
+
/** @attr formtarget - The submission target override. */
|
|
108
|
+
formTarget: string;
|
|
109
|
+
/** @attr autofocus - Whether the native button requests autofocus. */
|
|
110
|
+
autofocus: boolean;
|
|
111
|
+
/** @attr title - The native button tooltip. */
|
|
112
|
+
title: string;
|
|
113
|
+
/** @attr popovertargetaction - The action for the target popover. */
|
|
114
|
+
popoverTargetAction: string;
|
|
115
|
+
/** @attr command - The command for the target element, where supported. */
|
|
116
|
+
command: string;
|
|
117
|
+
readonly validity: ValidityState;
|
|
118
|
+
readonly validationMessage: string;
|
|
119
|
+
readonly willValidate: boolean;
|
|
120
|
+
readonly checkValidity: HTMLButtonElement['checkValidity'];
|
|
121
|
+
readonly reportValidity: HTMLButtonElement['reportValidity'];
|
|
122
|
+
readonly setCustomValidity: HTMLButtonElement['setCustomValidity'];
|
|
55
123
|
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { Button } from './Button';
|
|
2
|
+
/**
|
|
3
|
+
* @summary A wrapper button that propagates interactive states (hover/focus) to child components.
|
|
4
|
+
* @slot before - Content to be placed before the button text.
|
|
5
|
+
* @slot after - Content to be placed after the button text.
|
|
6
|
+
* @attr {string} name - The name of the button, submitted as a pair with the button's value as part of the form data.
|
|
7
|
+
* @attr {string} value - The value associated with the button's name when it's submitted with a form.
|
|
8
|
+
* @attr {string} type - The default behavior of the button. Possible values are 'submit', 'reset', and 'button'.
|
|
9
|
+
* @attr {boolean} disabled - Whether the button is disabled.
|
|
10
|
+
*/
|
|
11
|
+
export declare class ButtonWrapper extends Button {
|
|
12
|
+
#private;
|
|
13
|
+
constructor();
|
|
14
|
+
connectedCallback(): void;
|
|
15
|
+
disconnectedCallback(): void;
|
|
16
|
+
attributeChangedCallback(attrName: string, oldValue: string, newValue: string): void;
|
|
17
|
+
}
|