@ni/nimble-components 9.0.3 → 10.0.1
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/all-components-bundle.js +81 -88
- package/dist/all-components-bundle.js.map +1 -1
- package/dist/all-components-bundle.min.js +798 -807
- package/dist/all-components-bundle.min.js.map +1 -1
- package/dist/esm/button/index.js +1 -1
- package/dist/esm/button/styles.js +2 -2
- package/dist/esm/button/types.d.ts +0 -1
- package/dist/esm/button/types.js.map +1 -1
- package/dist/esm/drawer/index.js +16 -16
- package/dist/esm/drawer/types.d.ts +12 -12
- package/dist/esm/drawer/types.js +10 -12
- package/dist/esm/drawer/types.js.map +1 -1
- package/dist/esm/icon-base/types.d.ts +7 -7
- package/dist/esm/icon-base/types.js +6 -7
- package/dist/esm/icon-base/types.js.map +1 -1
- package/dist/esm/menu-button/index.js +1 -1
- package/dist/esm/menu-button/types.d.ts +0 -1
- package/dist/esm/menu-button/types.js +4 -1
- package/dist/esm/menu-button/types.js.map +1 -1
- package/dist/esm/nimble-components/src/button/types.d.ts +0 -1
- package/dist/esm/nimble-components/src/drawer/types.d.ts +12 -12
- package/dist/esm/nimble-components/src/icon-base/types.d.ts +7 -7
- package/dist/esm/nimble-components/src/menu-button/types.d.ts +0 -1
- package/dist/esm/nimble-components/src/patterns/button/types.d.ts +6 -6
- package/dist/esm/nimble-components/src/text-area/types.d.ts +5 -6
- package/dist/esm/nimble-components/src/text-field/types.d.ts +7 -14
- package/dist/esm/nimble-components/src/theme-provider/types.d.ts +6 -6
- package/dist/esm/nimble-components/src/toggle-button/types.d.ts +0 -1
- package/dist/esm/nimble-components/src/tree-view/types.d.ts +6 -6
- package/dist/esm/nimble-components/src/utilities/style/theme.d.ts +5 -5
- package/dist/esm/patterns/button/styles.js +3 -3
- package/dist/esm/patterns/button/types.d.ts +6 -6
- package/dist/esm/patterns/button/types.js +5 -6
- package/dist/esm/patterns/button/types.js.map +1 -1
- package/dist/esm/text-area/index.js +1 -1
- package/dist/esm/text-area/styles.js +2 -2
- package/dist/esm/text-area/types.d.ts +5 -6
- package/dist/esm/text-area/types.js +4 -5
- package/dist/esm/text-area/types.js.map +1 -1
- package/dist/esm/text-field/index.js +1 -1
- package/dist/esm/text-field/styles.js +5 -5
- package/dist/esm/text-field/types.d.ts +7 -14
- package/dist/esm/text-field/types.js +6 -7
- package/dist/esm/text-field/types.js.map +1 -1
- package/dist/esm/theme-provider/design-tokens.js +5 -5
- package/dist/esm/theme-provider/index.js +2 -2
- package/dist/esm/theme-provider/types.d.ts +6 -6
- package/dist/esm/theme-provider/types.js +5 -6
- package/dist/esm/theme-provider/types.js.map +1 -1
- package/dist/esm/toggle-button/index.js +1 -1
- package/dist/esm/toggle-button/types.d.ts +0 -1
- package/dist/esm/toggle-button/types.js +4 -0
- package/dist/esm/toggle-button/types.js.map +1 -1
- package/dist/esm/tree-view/index.js +4 -4
- package/dist/esm/tree-view/types.d.ts +6 -6
- package/dist/esm/tree-view/types.js +5 -6
- package/dist/esm/tree-view/types.js.map +1 -1
- package/dist/esm/utilities/style/theme.d.ts +5 -5
- package/dist/esm/utilities/style/theme.js +3 -3
- package/dist/esm/utilities/style/theme.js.map +1 -1
- package/dist/tokens.scss +1 -1
- package/package.json +1 -1
package/dist/esm/button/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { appearanceBehavior } from '../utilities/style/appearance';
|
|
|
6
6
|
import { ButtonAppearance } from './types';
|
|
7
7
|
// prettier-ignore
|
|
8
8
|
export const styles = buttonStyles
|
|
9
|
-
.withBehaviors(appearanceBehavior(ButtonAppearance.
|
|
9
|
+
.withBehaviors(appearanceBehavior(ButtonAppearance.outline, css `
|
|
10
10
|
:host(.primary) .control {
|
|
11
11
|
box-shadow: 0px 0px 0px ${borderWidth} rgba(${actionRgbPartialColor}, 0.3) inset;
|
|
12
12
|
}
|
|
@@ -26,7 +26,7 @@ export const styles = buttonStyles
|
|
|
26
26
|
:host(.primary) .control[disabled] {
|
|
27
27
|
box-shadow: none;
|
|
28
28
|
}
|
|
29
|
-
`), appearanceBehavior(ButtonAppearance.
|
|
29
|
+
`), appearanceBehavior(ButtonAppearance.block, css `
|
|
30
30
|
:host(.primary) .control {
|
|
31
31
|
background-clip: padding-box;
|
|
32
32
|
border-color: rgba(${actionRgbPartialColor}, 0.3);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/button/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/button/types.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC"}
|
package/dist/esm/drawer/index.js
CHANGED
|
@@ -16,8 +16,8 @@ const animationDurationWhenDisabledMilliseconds = 0.001;
|
|
|
16
16
|
export class Drawer extends FoundationDialog {
|
|
17
17
|
constructor() {
|
|
18
18
|
super(...arguments);
|
|
19
|
-
this.location = DrawerLocation.
|
|
20
|
-
this.state = DrawerState.
|
|
19
|
+
this.location = DrawerLocation.left;
|
|
20
|
+
this.state = DrawerState.closed;
|
|
21
21
|
/**
|
|
22
22
|
* True to prevent dismissing the drawer when the overlay outside the drawer is clicked.
|
|
23
23
|
* Only applicable when 'modal' is set to true (i.e. when the overlay is used).
|
|
@@ -61,11 +61,11 @@ export class Drawer extends FoundationDialog {
|
|
|
61
61
|
}
|
|
62
62
|
show() {
|
|
63
63
|
// Not calling super.show() as that will immediately show the drawer, whereas 'Opening' state will animate
|
|
64
|
-
this.state = DrawerState.
|
|
64
|
+
this.state = DrawerState.opening;
|
|
65
65
|
}
|
|
66
66
|
hide() {
|
|
67
67
|
// Not calling super.hide() as that will immediately hide the drawer, whereas 'Closing' state will animate
|
|
68
|
-
this.state = DrawerState.
|
|
68
|
+
this.state = DrawerState.closing;
|
|
69
69
|
}
|
|
70
70
|
/**
|
|
71
71
|
* Handler for overlay clicks (user-initiated dismiss requests) only.
|
|
@@ -98,11 +98,11 @@ export class Drawer extends FoundationDialog {
|
|
|
98
98
|
}
|
|
99
99
|
}
|
|
100
100
|
onHiddenChanged() {
|
|
101
|
-
if (this.hidden && this.state !== DrawerState.
|
|
102
|
-
this.state = DrawerState.
|
|
101
|
+
if (this.hidden && this.state !== DrawerState.closed) {
|
|
102
|
+
this.state = DrawerState.closed;
|
|
103
103
|
}
|
|
104
|
-
else if (!this.hidden && this.state === DrawerState.
|
|
105
|
-
this.state = DrawerState.
|
|
104
|
+
else if (!this.hidden && this.state === DrawerState.closed) {
|
|
105
|
+
this.state = DrawerState.opened;
|
|
106
106
|
}
|
|
107
107
|
}
|
|
108
108
|
onLocationChanged() {
|
|
@@ -112,18 +112,18 @@ export class Drawer extends FoundationDialog {
|
|
|
112
112
|
if (this.isConnected) {
|
|
113
113
|
this.cancelCurrentAnimation();
|
|
114
114
|
switch (this.state) {
|
|
115
|
-
case DrawerState.
|
|
115
|
+
case DrawerState.opening:
|
|
116
116
|
this.animateOpening();
|
|
117
117
|
this.hidden = false;
|
|
118
118
|
break;
|
|
119
|
-
case DrawerState.
|
|
119
|
+
case DrawerState.opened:
|
|
120
120
|
this.hidden = false;
|
|
121
121
|
break;
|
|
122
|
-
case DrawerState.
|
|
122
|
+
case DrawerState.closing:
|
|
123
123
|
this.hidden = false;
|
|
124
124
|
this.animateClosing();
|
|
125
125
|
break;
|
|
126
|
-
case DrawerState.
|
|
126
|
+
case DrawerState.closed:
|
|
127
127
|
this.hidden = true;
|
|
128
128
|
break;
|
|
129
129
|
default:
|
|
@@ -152,7 +152,7 @@ export class Drawer extends FoundationDialog {
|
|
|
152
152
|
this.animateOpenClose(false);
|
|
153
153
|
}
|
|
154
154
|
else {
|
|
155
|
-
this.state = DrawerState.
|
|
155
|
+
this.state = DrawerState.closed;
|
|
156
156
|
}
|
|
157
157
|
}
|
|
158
158
|
animateOpenClose(drawerOpening) {
|
|
@@ -162,7 +162,7 @@ export class Drawer extends FoundationDialog {
|
|
|
162
162
|
: animationConfig.slideOutOptions),
|
|
163
163
|
duration: this.animationDurationMilliseconds
|
|
164
164
|
};
|
|
165
|
-
const drawerKeyframes = this.location === DrawerLocation.
|
|
165
|
+
const drawerKeyframes = this.location === DrawerLocation.right
|
|
166
166
|
? animationConfig.slideRightKeyframes
|
|
167
167
|
: animationConfig.slideLeftKeyframes;
|
|
168
168
|
const dialogAnimation = new AnimateTo(this.dialog, undefined, options);
|
|
@@ -177,8 +177,8 @@ export class Drawer extends FoundationDialog {
|
|
|
177
177
|
const animationGroup = new AnimateGroup(animations);
|
|
178
178
|
animationGroup.onFinish = () => {
|
|
179
179
|
this.state = drawerOpening
|
|
180
|
-
? DrawerState.
|
|
181
|
-
: DrawerState.
|
|
180
|
+
? DrawerState.opened
|
|
181
|
+
: DrawerState.closed;
|
|
182
182
|
};
|
|
183
183
|
this.animationGroup = animationGroup;
|
|
184
184
|
animationGroup.play();
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
export declare type
|
|
6
|
-
export declare
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
export declare type
|
|
1
|
+
export declare const DrawerLocation: {
|
|
2
|
+
readonly left: "left";
|
|
3
|
+
readonly right: "right";
|
|
4
|
+
};
|
|
5
|
+
export declare type DrawerLocation = typeof DrawerLocation[keyof typeof DrawerLocation];
|
|
6
|
+
export declare const DrawerState: {
|
|
7
|
+
readonly opening: "opening";
|
|
8
|
+
readonly opened: "opened";
|
|
9
|
+
readonly closing: "closing";
|
|
10
|
+
readonly closed: "closed";
|
|
11
|
+
};
|
|
12
|
+
export declare type DrawerState = typeof DrawerState[keyof typeof DrawerState];
|
package/dist/esm/drawer/types.js
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
|
-
export
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
DrawerState["Closed"] = "closed";
|
|
12
|
-
})(DrawerState || (DrawerState = {}));
|
|
1
|
+
export const DrawerLocation = {
|
|
2
|
+
left: 'left',
|
|
3
|
+
right: 'right'
|
|
4
|
+
};
|
|
5
|
+
export const DrawerState = {
|
|
6
|
+
opening: 'opening',
|
|
7
|
+
opened: 'opened',
|
|
8
|
+
closing: 'closing',
|
|
9
|
+
closed: 'closed'
|
|
10
|
+
};
|
|
13
11
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/drawer/types.ts"],"names":[],"mappings":"AAAA,MAAM,
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/drawer/types.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,cAAc,GAAG;IAC1B,IAAI,EAAE,MAAM;IACZ,KAAK,EAAE,OAAO;CACR,CAAC;AAGX,MAAM,CAAC,MAAM,WAAW,GAAG;IACvB,OAAO,EAAE,SAAS;IAClB,MAAM,EAAE,QAAQ;IAChB,OAAO,EAAE,SAAS;IAClB,MAAM,EAAE,QAAQ;CACV,CAAC"}
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* Predefined icon status states
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export declare
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
export declare type
|
|
5
|
+
export declare const IconStatus: {
|
|
6
|
+
readonly fail: "fail";
|
|
7
|
+
readonly warning: "warning";
|
|
8
|
+
readonly pass: "pass";
|
|
9
|
+
readonly regular: "regular";
|
|
10
|
+
};
|
|
11
|
+
export declare type IconStatus = typeof IconStatus[keyof typeof IconStatus];
|
|
@@ -2,11 +2,10 @@
|
|
|
2
2
|
* Predefined icon status states
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
})(IconStatus || (IconStatus = {}));
|
|
5
|
+
export const IconStatus = {
|
|
6
|
+
fail: 'fail',
|
|
7
|
+
warning: 'warning',
|
|
8
|
+
pass: 'pass',
|
|
9
|
+
regular: 'regular'
|
|
10
|
+
};
|
|
12
11
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/icon-base/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/icon-base/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG;IACtB,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,SAAS;IAClB,IAAI,EAAE,MAAM;IACZ,OAAO,EAAE,SAAS;CACZ,CAAC"}
|
|
@@ -12,7 +12,7 @@ import { MenuButtonPosition } from './types';
|
|
|
12
12
|
export class MenuButton extends FoundationElement {
|
|
13
13
|
constructor() {
|
|
14
14
|
super(...arguments);
|
|
15
|
-
this.appearance = ButtonAppearance.
|
|
15
|
+
this.appearance = ButtonAppearance.outline;
|
|
16
16
|
this.disabled = false;
|
|
17
17
|
this.contentHidden = false;
|
|
18
18
|
/**
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Types of menu button appearance.
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export type { ButtonAppearanceAttribute } from '../patterns/button/types';
|
|
6
5
|
export { ButtonAppearance } from '../patterns/button/types';
|
|
7
6
|
/**
|
|
8
7
|
* The options of where to position the menu relative to the menu button.
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Types of menu button appearance.
|
|
3
|
+
* @public
|
|
4
|
+
*/
|
|
1
5
|
export { ButtonAppearance } from '../patterns/button/types';
|
|
2
6
|
/**
|
|
3
7
|
* The options of where to position the menu relative to the menu button.
|
|
4
8
|
*/
|
|
5
|
-
// eslint-disable-next-line @typescript-eslint/naming-convention
|
|
6
9
|
export const MenuButtonPosition = {
|
|
7
10
|
above: 'above',
|
|
8
11
|
below: 'below',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/menu-button/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/menu-button/types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAE5D;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAC9B,KAAK,EAAE,OAAO;IACd,KAAK,EAAE,OAAO;IACd,IAAI,EAAE,MAAM;CACN,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
}
|
|
5
|
-
export declare type
|
|
6
|
-
export declare
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
export declare type
|
|
1
|
+
export declare const DrawerLocation: {
|
|
2
|
+
readonly left: "left";
|
|
3
|
+
readonly right: "right";
|
|
4
|
+
};
|
|
5
|
+
export declare type DrawerLocation = typeof DrawerLocation[keyof typeof DrawerLocation];
|
|
6
|
+
export declare const DrawerState: {
|
|
7
|
+
readonly opening: "opening";
|
|
8
|
+
readonly opened: "opened";
|
|
9
|
+
readonly closing: "closing";
|
|
10
|
+
readonly closed: "closed";
|
|
11
|
+
};
|
|
12
|
+
export declare type DrawerState = typeof DrawerState[keyof typeof DrawerState];
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
* Predefined icon status states
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export declare
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}
|
|
11
|
-
export declare type
|
|
5
|
+
export declare const IconStatus: {
|
|
6
|
+
readonly fail: "fail";
|
|
7
|
+
readonly warning: "warning";
|
|
8
|
+
readonly pass: "pass";
|
|
9
|
+
readonly regular: "regular";
|
|
10
|
+
};
|
|
11
|
+
export declare type IconStatus = typeof IconStatus[keyof typeof IconStatus];
|
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Types of menu button appearance.
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export type { ButtonAppearanceAttribute } from '../patterns/button/types';
|
|
6
5
|
export { ButtonAppearance } from '../patterns/button/types';
|
|
7
6
|
/**
|
|
8
7
|
* The options of where to position the menu relative to the menu button.
|
|
@@ -22,9 +22,9 @@ export interface IButton {
|
|
|
22
22
|
* Types of button appearance.
|
|
23
23
|
* @public
|
|
24
24
|
*/
|
|
25
|
-
export declare
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}
|
|
30
|
-
export declare type
|
|
25
|
+
export declare const ButtonAppearance: {
|
|
26
|
+
readonly outline: "outline";
|
|
27
|
+
readonly ghost: "ghost";
|
|
28
|
+
readonly block: "block";
|
|
29
|
+
};
|
|
30
|
+
export declare type ButtonAppearance = typeof ButtonAppearance[keyof typeof ButtonAppearance];
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { TextAreaResize } from '@microsoft/fast-foundation';
|
|
2
2
|
export { TextAreaResize };
|
|
3
|
-
export declare
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
export declare type TextAreaAppearanceAttribute = `${TextAreaAppearance}`;
|
|
3
|
+
export declare const TextAreaAppearance: {
|
|
4
|
+
readonly outline: "outline";
|
|
5
|
+
readonly block: "block";
|
|
6
|
+
};
|
|
7
|
+
export declare type TextAreaAppearance = typeof TextAreaAppearance[keyof typeof TextAreaAppearance];
|
|
@@ -1,22 +1,15 @@
|
|
|
1
1
|
import { TextFieldType } from '@microsoft/fast-foundation';
|
|
2
|
-
/**
|
|
3
|
-
* Values for the 'type' attribute of the text field.
|
|
4
|
-
*/
|
|
5
|
-
export declare type TextFieldTypeAttribute = `${TextFieldType}`;
|
|
6
2
|
/**
|
|
7
3
|
* Values for the 'type' property of the text field.
|
|
8
4
|
*/
|
|
9
5
|
export { TextFieldType };
|
|
10
|
-
/**
|
|
11
|
-
* Values for the 'appearance' attribute of the text field.
|
|
12
|
-
*/
|
|
13
|
-
export declare type TextFieldAppearanceAttribute = `${TextFieldAppearance}`;
|
|
14
6
|
/**
|
|
15
7
|
* Values for the 'appearance' property of the text field
|
|
16
8
|
*/
|
|
17
|
-
export declare
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
9
|
+
export declare const TextFieldAppearance: {
|
|
10
|
+
readonly underline: "underline";
|
|
11
|
+
readonly outline: "outline";
|
|
12
|
+
readonly block: "block";
|
|
13
|
+
readonly frameless: "frameless";
|
|
14
|
+
};
|
|
15
|
+
export declare type TextFieldAppearance = typeof TextFieldAppearance[keyof typeof TextFieldAppearance];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export declare
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
}
|
|
6
|
-
export declare type
|
|
1
|
+
export declare const Theme: {
|
|
2
|
+
readonly light: "light";
|
|
3
|
+
readonly dark: "dark";
|
|
4
|
+
readonly color: "color";
|
|
5
|
+
};
|
|
6
|
+
export declare type Theme = typeof Theme[keyof typeof Theme];
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export declare const pinnedSelectedAttribute = "pinned-selected";
|
|
2
2
|
export declare const groupSelectedAttribute = "group-selected";
|
|
3
|
-
export declare
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}
|
|
8
|
-
export declare type
|
|
3
|
+
export declare const TreeViewSelectionMode: {
|
|
4
|
+
readonly all: "all";
|
|
5
|
+
readonly leavesOnly: "leaves-only";
|
|
6
|
+
readonly none: "none";
|
|
7
|
+
};
|
|
8
|
+
export declare type TreeViewSelectionMode = typeof TreeViewSelectionMode[keyof typeof TreeViewSelectionMode];
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { Behavior, ElementStyles, FASTElement } from '@microsoft/fast-element';
|
|
2
2
|
import type { Theme } from '../../theme-provider/types';
|
|
3
3
|
export declare type LightStyle = ElementStyles | null;
|
|
4
|
-
export declare type DarkStyleOrAlias = ElementStyles | null | Theme
|
|
5
|
-
export declare type ColorStyleOrAlias = ElementStyles | null | Theme
|
|
4
|
+
export declare type DarkStyleOrAlias = ElementStyles | null | Extract<Theme, 'light'>;
|
|
5
|
+
export declare type ColorStyleOrAlias = ElementStyles | null | Extract<Theme, 'light' | 'dark'>;
|
|
6
6
|
/**
|
|
7
7
|
* Behavior to conditionally apply theme-based stylesheets.
|
|
8
8
|
*/
|
|
@@ -32,9 +32,9 @@ declare class ThemeStyleSheetBehavior implements Behavior {
|
|
|
32
32
|
* css`
|
|
33
33
|
* // ...
|
|
34
34
|
* `.withBehaviors(new ThemeStyleSheetBehavior(
|
|
35
|
-
* css`:host { ... Theme.
|
|
36
|
-
* null, // No style needed for Theme.
|
|
37
|
-
* Theme.
|
|
35
|
+
* css`:host { ... Theme.light style... }`),
|
|
36
|
+
* null, // No style needed for Theme.dark style
|
|
37
|
+
* Theme.light // For the Theme.color style, re-use the previously set Theme.light style
|
|
38
38
|
* )
|
|
39
39
|
* ```
|
|
40
40
|
*/
|
|
@@ -125,7 +125,7 @@ export const styles = css `
|
|
|
125
125
|
}
|
|
126
126
|
`
|
|
127
127
|
// prettier-ignore
|
|
128
|
-
.withBehaviors(appearanceBehavior(ButtonAppearance.
|
|
128
|
+
.withBehaviors(appearanceBehavior(ButtonAppearance.outline, css `
|
|
129
129
|
.control {
|
|
130
130
|
background-color: transparent;
|
|
131
131
|
border-color: rgba(${actionRgbPartialColor}, 0.3);
|
|
@@ -150,7 +150,7 @@ export const styles = css `
|
|
|
150
150
|
background-color: transparent;
|
|
151
151
|
border-color: rgba(${borderRgbPartialColor}, 0.2);
|
|
152
152
|
}
|
|
153
|
-
`), appearanceBehavior(ButtonAppearance.
|
|
153
|
+
`), appearanceBehavior(ButtonAppearance.ghost, css `
|
|
154
154
|
.control {
|
|
155
155
|
background-color: transparent;
|
|
156
156
|
border-color: transparent;
|
|
@@ -175,7 +175,7 @@ export const styles = css `
|
|
|
175
175
|
background-color: transparent;
|
|
176
176
|
border-color: transparent;
|
|
177
177
|
}
|
|
178
|
-
`), appearanceBehavior(ButtonAppearance.
|
|
178
|
+
`), appearanceBehavior(ButtonAppearance.block, css `
|
|
179
179
|
.control {
|
|
180
180
|
background-color: rgba(${borderRgbPartialColor}, 0.1);
|
|
181
181
|
border-color: transparent;
|
|
@@ -22,9 +22,9 @@ export interface IButton {
|
|
|
22
22
|
* Types of button appearance.
|
|
23
23
|
* @public
|
|
24
24
|
*/
|
|
25
|
-
export declare
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
}
|
|
30
|
-
export declare type
|
|
25
|
+
export declare const ButtonAppearance: {
|
|
26
|
+
readonly outline: "outline";
|
|
27
|
+
readonly ghost: "ghost";
|
|
28
|
+
readonly block: "block";
|
|
29
|
+
};
|
|
30
|
+
export declare type ButtonAppearance = typeof ButtonAppearance[keyof typeof ButtonAppearance];
|
|
@@ -2,10 +2,9 @@
|
|
|
2
2
|
* Types of button appearance.
|
|
3
3
|
* @public
|
|
4
4
|
*/
|
|
5
|
-
export
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
})(ButtonAppearance || (ButtonAppearance = {}));
|
|
5
|
+
export const ButtonAppearance = {
|
|
6
|
+
outline: 'outline',
|
|
7
|
+
ghost: 'ghost',
|
|
8
|
+
block: 'block'
|
|
9
|
+
};
|
|
11
10
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/patterns/button/types.ts"],"names":[],"mappings":"AAuBA;;;GAGG;AACH,MAAM,
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/patterns/button/types.ts"],"names":[],"mappings":"AAuBA;;;GAGG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC5B,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,OAAO;IACd,KAAK,EAAE,OAAO;CACR,CAAC"}
|
|
@@ -102,12 +102,12 @@ export const styles = css `
|
|
|
102
102
|
}
|
|
103
103
|
`
|
|
104
104
|
// prettier-ignore
|
|
105
|
-
.withBehaviors(appearanceBehavior(TextAreaAppearance.
|
|
105
|
+
.withBehaviors(appearanceBehavior(TextAreaAppearance.outline, css `
|
|
106
106
|
.control {
|
|
107
107
|
border-color: rgba(${borderRgbPartialColor}, 0.3);
|
|
108
108
|
background-color: transparent;
|
|
109
109
|
}
|
|
110
|
-
`), appearanceBehavior(TextAreaAppearance.
|
|
110
|
+
`), appearanceBehavior(TextAreaAppearance.block, css `
|
|
111
111
|
.control {
|
|
112
112
|
background-color: rgba(${borderRgbPartialColor}, 0.1);
|
|
113
113
|
}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { TextAreaResize } from '@microsoft/fast-foundation';
|
|
2
2
|
export { TextAreaResize };
|
|
3
|
-
export declare
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
export declare type TextAreaAppearanceAttribute = `${TextAreaAppearance}`;
|
|
3
|
+
export declare const TextAreaAppearance: {
|
|
4
|
+
readonly outline: "outline";
|
|
5
|
+
readonly block: "block";
|
|
6
|
+
};
|
|
7
|
+
export declare type TextAreaAppearance = typeof TextAreaAppearance[keyof typeof TextAreaAppearance];
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { TextAreaResize } from '@microsoft/fast-foundation';
|
|
2
2
|
export { TextAreaResize };
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
})(TextAreaAppearance || (TextAreaAppearance = {}));
|
|
3
|
+
export const TextAreaAppearance = {
|
|
4
|
+
outline: 'outline',
|
|
5
|
+
block: 'block'
|
|
6
|
+
};
|
|
8
7
|
//# sourceMappingURL=types.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/text-area/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAE5D,OAAO,EAAE,cAAc,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/text-area/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAE5D,OAAO,EAAE,cAAc,EAAE,CAAC;AAE1B,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAC9B,OAAO,EAAE,SAAS;IAClB,KAAK,EAAE,OAAO;CACR,CAAC"}
|
|
@@ -17,7 +17,7 @@ export class TextField extends FoundationTextField {
|
|
|
17
17
|
* @remarks
|
|
18
18
|
* HTML Attribute: appearance
|
|
19
19
|
*/
|
|
20
|
-
this.appearance = TextFieldAppearance.
|
|
20
|
+
this.appearance = TextFieldAppearance.underline;
|
|
21
21
|
}
|
|
22
22
|
connectedCallback() {
|
|
23
23
|
super.connectedCallback();
|