@fluid-topics/ft-modal 2.0.38 → 2.1.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/build/definitions.d.ts +0 -4
- package/build/definitions.js +0 -4
- package/build/ft-modal.js +1 -2
- package/build/ft-modal.light.js +392 -1608
- package/build/ft-modal.min.js +526 -1742
- package/build/ft-modal.styles.d.ts +20 -20
- package/build/index.d.ts +0 -4
- package/build/index.js +0 -4
- package/package.json +4 -4
- package/build/FtDsModalMessages.d.ts +0 -6
- package/build/FtDsModalMessages.js +0 -5
- package/build/ftds-modal-confirm.d.ts +0 -17
- package/build/ftds-modal-confirm.js +0 -97
- package/build/ftds-modal.d.ts +0 -23
- package/build/ftds-modal.js +0 -119
- package/build/ftds-modal.properties.d.ts +0 -7
- package/build/ftds-modal.properties.js +0 -2
- package/build/ftds-modal.styles.d.ts +0 -3
- package/build/ftds-modal.styles.js +0 -95
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
export declare const FtModalCssVariables: {
|
|
2
|
-
shadow: import("@fluid-topics/
|
|
3
|
-
borderRadius: import("@fluid-topics/
|
|
4
|
-
height: import("@fluid-topics/
|
|
5
|
-
width: import("@fluid-topics/
|
|
6
|
-
headerPadding: import("@fluid-topics/
|
|
7
|
-
headerGap: import("@fluid-topics/
|
|
8
|
-
headerBorderColor: import("@fluid-topics/
|
|
9
|
-
headerBorderWidth: import("@fluid-topics/
|
|
10
|
-
headerBackgroundColor: import("@fluid-topics/
|
|
11
|
-
headerColor: import("@fluid-topics/
|
|
12
|
-
headerIconColor: import("@fluid-topics/
|
|
13
|
-
contentPadding: import("@fluid-topics/
|
|
14
|
-
contentGap: import("@fluid-topics/
|
|
15
|
-
contentBackgroundColor: import("@fluid-topics/
|
|
16
|
-
contentColor: import("@fluid-topics/
|
|
17
|
-
actionsGap: import("@fluid-topics/
|
|
18
|
-
overlayBackgroundColor: import("@fluid-topics/
|
|
19
|
-
overlayOpacity: import("@fluid-topics/
|
|
20
|
-
closingButtonColor: import("@fluid-topics/
|
|
21
|
-
contentOverflow: import("@fluid-topics/
|
|
2
|
+
shadow: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
3
|
+
borderRadius: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
4
|
+
height: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
5
|
+
width: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
6
|
+
headerPadding: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
7
|
+
headerGap: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
8
|
+
headerBorderColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
9
|
+
headerBorderWidth: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
10
|
+
headerBackgroundColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
11
|
+
headerColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
12
|
+
headerIconColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
13
|
+
contentPadding: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
14
|
+
contentGap: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
15
|
+
contentBackgroundColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
16
|
+
contentColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
17
|
+
actionsGap: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
18
|
+
overlayBackgroundColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
19
|
+
overlayOpacity: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
20
|
+
closingButtonColor: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
21
|
+
contentOverflow: import("@fluid-topics/design-system-variables").FtCssVariable;
|
|
22
22
|
};
|
|
23
23
|
export declare const ftmodalStyles: import("lit").CSSResult;
|
package/build/index.d.ts
CHANGED
|
@@ -1,8 +1,4 @@
|
|
|
1
1
|
export * from "./ft-modal";
|
|
2
2
|
export * from "./ft-modal.styles";
|
|
3
3
|
export * from "./ft-modal.properties";
|
|
4
|
-
export * from "./ftds-modal.styles";
|
|
5
|
-
export * from "./ftds-modal.properties";
|
|
6
|
-
export * from "./ftds-modal";
|
|
7
|
-
export * from "./ftds-modal-confirm";
|
|
8
4
|
import "./define";
|
package/build/index.js
CHANGED
|
@@ -1,8 +1,4 @@
|
|
|
1
1
|
export * from "./ft-modal";
|
|
2
2
|
export * from "./ft-modal.styles";
|
|
3
3
|
export * from "./ft-modal.properties";
|
|
4
|
-
export * from "./ftds-modal.styles";
|
|
5
|
-
export * from "./ftds-modal.properties";
|
|
6
|
-
export * from "./ftds-modal";
|
|
7
|
-
export * from "./ftds-modal-confirm";
|
|
8
4
|
import "./define";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluid-topics/ft-modal",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.1",
|
|
4
4
|
"description": "Modal for Design System V2",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Lit"
|
|
@@ -19,11 +19,11 @@
|
|
|
19
19
|
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@fluid-topics/ft-wc-utils": "2.
|
|
22
|
+
"@fluid-topics/ft-wc-utils": "2.1.1",
|
|
23
23
|
"lit": "3.1.0"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
|
-
"@fluid-topics/ft-wc-test-utils": "2.
|
|
26
|
+
"@fluid-topics/ft-wc-test-utils": "2.1.1"
|
|
27
27
|
},
|
|
28
|
-
"gitHead": "
|
|
28
|
+
"gitHead": "a9f1e471fb2dba9aeb8c12394a25460f675597dc"
|
|
29
29
|
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { DefaultI18nMessages, I18nMessageContext, I18nMessages } from "@fluid-topics/ft-i18n";
|
|
2
|
-
export interface FtDsModalMessages extends I18nMessages {
|
|
3
|
-
closeModal(): string;
|
|
4
|
-
}
|
|
5
|
-
export declare const modal: I18nMessageContext<FtDsModalMessages>;
|
|
6
|
-
export declare const defaultModalMessages: DefaultI18nMessages<FtDsModalMessages>;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { ElementDefinitionsMap, FtLitElement } from "@fluid-topics/ft-wc-utils";
|
|
2
|
-
import { FtdsModal } from "./ftds-modal";
|
|
3
|
-
export declare class FtdsModalConfirm extends FtLitElement {
|
|
4
|
-
static elementDefinitions: ElementDefinitionsMap;
|
|
5
|
-
heading: string;
|
|
6
|
-
text: string;
|
|
7
|
-
confirmText: string;
|
|
8
|
-
cancelText: string;
|
|
9
|
-
confirmIcon: string;
|
|
10
|
-
cancelIcon: string;
|
|
11
|
-
modal: FtdsModal;
|
|
12
|
-
promiseResolve?: (value: boolean) => void;
|
|
13
|
-
protected render(): import("lit-html").TemplateResult<1>;
|
|
14
|
-
askConfirmation(): Promise<boolean>;
|
|
15
|
-
onConfirm(): void;
|
|
16
|
-
onCancel(): void;
|
|
17
|
-
}
|
|
@@ -1,97 +0,0 @@
|
|
|
1
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
import { DesignSystemFamily, FtLitElement, } from "@fluid-topics/ft-wc-utils";
|
|
8
|
-
import { html } from "lit";
|
|
9
|
-
import { FtdsModal } from "./ftds-modal";
|
|
10
|
-
import { DesignSystemSize } from "@fluid-topics/design-system-variables";
|
|
11
|
-
import { FtDsModalBodyTypography } from "./ftds-modal.properties";
|
|
12
|
-
import { FtIcons } from "@fluid-topics/ft-icon";
|
|
13
|
-
import { property, query, } from "lit/decorators.js";
|
|
14
|
-
import { FtdsTypography } from "@fluid-topics/ft-typography";
|
|
15
|
-
import { FtdsButton } from "@fluid-topics/ft-button";
|
|
16
|
-
export class FtdsModalConfirm extends FtLitElement {
|
|
17
|
-
constructor() {
|
|
18
|
-
super(...arguments);
|
|
19
|
-
this.confirmText = "Confirm";
|
|
20
|
-
this.cancelText = "Cancel";
|
|
21
|
-
this.confirmIcon = FtIcons.CHECK;
|
|
22
|
-
this.cancelIcon = FtIcons.CLOSE;
|
|
23
|
-
}
|
|
24
|
-
render() {
|
|
25
|
-
return html `
|
|
26
|
-
<ftds-modal
|
|
27
|
-
heading="${this.heading}"
|
|
28
|
-
size="${DesignSystemSize.small}"
|
|
29
|
-
@close=${this.onCancel}
|
|
30
|
-
>
|
|
31
|
-
<ftds-typography variant="${FtDsModalBodyTypography}">
|
|
32
|
-
${this.text}
|
|
33
|
-
</ftds-typography>
|
|
34
|
-
<ftds-button slot="actions"
|
|
35
|
-
tertiary
|
|
36
|
-
autofocus
|
|
37
|
-
family="${DesignSystemFamily.neutral}"
|
|
38
|
-
size="${DesignSystemSize.large}"
|
|
39
|
-
icon="${this.cancelIcon}"
|
|
40
|
-
@click=${this.onCancel}>
|
|
41
|
-
${this.cancelText}
|
|
42
|
-
</ftds-button>
|
|
43
|
-
<ftds-button slot="actions"
|
|
44
|
-
primary
|
|
45
|
-
size="${DesignSystemSize.large}"
|
|
46
|
-
@click=${this.onConfirm}
|
|
47
|
-
icon="${this.confirmIcon}">
|
|
48
|
-
${this.confirmText}
|
|
49
|
-
</ftds-button>
|
|
50
|
-
</ftds-modal>
|
|
51
|
-
`;
|
|
52
|
-
}
|
|
53
|
-
async askConfirmation() {
|
|
54
|
-
this.modal.open();
|
|
55
|
-
const result = await new Promise((resolve) => {
|
|
56
|
-
this.promiseResolve = resolve;
|
|
57
|
-
});
|
|
58
|
-
this.modal.close();
|
|
59
|
-
return result;
|
|
60
|
-
}
|
|
61
|
-
onConfirm() {
|
|
62
|
-
var _a;
|
|
63
|
-
(_a = this.promiseResolve) === null || _a === void 0 ? void 0 : _a.call(this, true);
|
|
64
|
-
this.promiseResolve = undefined;
|
|
65
|
-
}
|
|
66
|
-
onCancel() {
|
|
67
|
-
var _a;
|
|
68
|
-
(_a = this.promiseResolve) === null || _a === void 0 ? void 0 : _a.call(this, false);
|
|
69
|
-
this.promiseResolve = undefined;
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
FtdsModalConfirm.elementDefinitions = {
|
|
73
|
-
"ftds-modal": FtdsModal,
|
|
74
|
-
"ftds-typography": FtdsTypography,
|
|
75
|
-
"ftds-button": FtdsButton,
|
|
76
|
-
};
|
|
77
|
-
__decorate([
|
|
78
|
-
property({ type: String })
|
|
79
|
-
], FtdsModalConfirm.prototype, "heading", void 0);
|
|
80
|
-
__decorate([
|
|
81
|
-
property({ type: String })
|
|
82
|
-
], FtdsModalConfirm.prototype, "text", void 0);
|
|
83
|
-
__decorate([
|
|
84
|
-
property({ type: String })
|
|
85
|
-
], FtdsModalConfirm.prototype, "confirmText", void 0);
|
|
86
|
-
__decorate([
|
|
87
|
-
property({ type: String })
|
|
88
|
-
], FtdsModalConfirm.prototype, "cancelText", void 0);
|
|
89
|
-
__decorate([
|
|
90
|
-
property({ type: String })
|
|
91
|
-
], FtdsModalConfirm.prototype, "confirmIcon", void 0);
|
|
92
|
-
__decorate([
|
|
93
|
-
property({ type: String })
|
|
94
|
-
], FtdsModalConfirm.prototype, "cancelIcon", void 0);
|
|
95
|
-
__decorate([
|
|
96
|
-
query("ftds-modal")
|
|
97
|
-
], FtdsModalConfirm.prototype, "modal", void 0);
|
package/build/ftds-modal.d.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { PropertyValues } from "lit";
|
|
2
|
-
import { ElementDefinitionsMap, FtdsBase } from "@fluid-topics/ft-wc-utils";
|
|
3
|
-
import { FtdsModalProperties } from "./ftds-modal.properties";
|
|
4
|
-
import { DesignSystemSize } from "@fluid-topics/design-system-variables";
|
|
5
|
-
declare const FtdsModal_base: typeof FtdsBase & import("@fluid-topics/ft-wc-utils").Constructor<import("@fluid-topics/ft-i18n").FtLitElementWithI18nInterface>;
|
|
6
|
-
export declare class FtdsModal extends FtdsModal_base implements FtdsModalProperties {
|
|
7
|
-
static elementDefinitions: ElementDefinitionsMap;
|
|
8
|
-
static styles: import("lit").CSSResult[];
|
|
9
|
-
heading: string;
|
|
10
|
-
icon?: string;
|
|
11
|
-
dialogOpen?: boolean;
|
|
12
|
-
private dialog;
|
|
13
|
-
size: DesignSystemSize;
|
|
14
|
-
constructor();
|
|
15
|
-
protected render(): import("lit-html").TemplateResult<1>;
|
|
16
|
-
protected contentAvailableCallback(props: PropertyValues): void;
|
|
17
|
-
open(): void;
|
|
18
|
-
close(): void;
|
|
19
|
-
disconnectedCallback(): void;
|
|
20
|
-
private onOverlayClick;
|
|
21
|
-
private onClose;
|
|
22
|
-
}
|
|
23
|
-
export {};
|
package/build/ftds-modal.js
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
-
};
|
|
7
|
-
import { html, nothing, } from "lit";
|
|
8
|
-
import { property, query, } from "lit/decorators.js";
|
|
9
|
-
import { DesignSystemFamily, FtdsBase, } from "@fluid-topics/ft-wc-utils";
|
|
10
|
-
import { classMap } from "lit/directives/class-map.js";
|
|
11
|
-
import { designSystemStyle } from "./ftds-modal.styles";
|
|
12
|
-
import { FtdsButton } from "@fluid-topics/ft-button";
|
|
13
|
-
import { DesignSystemSize } from "@fluid-topics/design-system-variables";
|
|
14
|
-
import { FtIcon, FtIcons, } from "@fluid-topics/ft-icon";
|
|
15
|
-
import { FtdsTypography, FtdsTypographyVariants, } from "@fluid-topics/ft-typography";
|
|
16
|
-
import { withI18n } from "@fluid-topics/ft-i18n";
|
|
17
|
-
import { defaultModalMessages, modal, } from "./FtDsModalMessages";
|
|
18
|
-
class FtdsModalCloseEvent extends Event {
|
|
19
|
-
constructor() {
|
|
20
|
-
super("close");
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
export class FtdsModal extends withI18n(FtdsBase) {
|
|
24
|
-
constructor() {
|
|
25
|
-
super();
|
|
26
|
-
this.heading = "";
|
|
27
|
-
this.size = DesignSystemSize.small;
|
|
28
|
-
this.addI18nContext(modal, defaultModalMessages);
|
|
29
|
-
}
|
|
30
|
-
render() {
|
|
31
|
-
const classes = {
|
|
32
|
-
"ftds-modal": true,
|
|
33
|
-
...this.getDesignSystemBaseClasses(),
|
|
34
|
-
};
|
|
35
|
-
return html `
|
|
36
|
-
<div class="${classMap(classes)}" part="container">
|
|
37
|
-
<dialog part="dialog"
|
|
38
|
-
@close=${this.onClose}>
|
|
39
|
-
<div part="overlay" @click=${this.onOverlayClick}></div>
|
|
40
|
-
<div part="inner-container">
|
|
41
|
-
<div part="header">
|
|
42
|
-
${this.icon ? html `
|
|
43
|
-
<ft-icon part="icon" value="${this.icon}"></ft-icon>
|
|
44
|
-
` : nothing}
|
|
45
|
-
<ftds-typography part="heading" variant="${FtdsTypographyVariants.body1semibold}">
|
|
46
|
-
${this.heading}
|
|
47
|
-
</ftds-typography>
|
|
48
|
-
<ftds-button part="closing-button"
|
|
49
|
-
size="${DesignSystemSize.large}"
|
|
50
|
-
icon="${FtIcons.CLOSE}"
|
|
51
|
-
tertiary
|
|
52
|
-
family="${DesignSystemFamily.neutral}"
|
|
53
|
-
label="${modal.messages.closeModal()}"
|
|
54
|
-
@click=${this.close}>
|
|
55
|
-
</ftds-button>
|
|
56
|
-
</div>
|
|
57
|
-
<div part="body">
|
|
58
|
-
<div part="content">
|
|
59
|
-
<slot></slot>
|
|
60
|
-
</div>
|
|
61
|
-
<div part="actions">
|
|
62
|
-
<slot name="actions"></slot>
|
|
63
|
-
</div>
|
|
64
|
-
</div>
|
|
65
|
-
</div>
|
|
66
|
-
</dialog>
|
|
67
|
-
</div>
|
|
68
|
-
`;
|
|
69
|
-
}
|
|
70
|
-
contentAvailableCallback(props) {
|
|
71
|
-
super.contentAvailableCallback(props);
|
|
72
|
-
if (props.has("dialogOpen")) {
|
|
73
|
-
if (this.dialogOpen) {
|
|
74
|
-
this.dialog.showModal();
|
|
75
|
-
}
|
|
76
|
-
else {
|
|
77
|
-
this.dialog.close();
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
}
|
|
81
|
-
open() {
|
|
82
|
-
this.dialogOpen = true;
|
|
83
|
-
}
|
|
84
|
-
close() {
|
|
85
|
-
this.dialogOpen = false;
|
|
86
|
-
}
|
|
87
|
-
disconnectedCallback() {
|
|
88
|
-
super.disconnectedCallback();
|
|
89
|
-
this.close();
|
|
90
|
-
}
|
|
91
|
-
onOverlayClick() {
|
|
92
|
-
this.close();
|
|
93
|
-
}
|
|
94
|
-
onClose() {
|
|
95
|
-
this.dispatchEvent(new FtdsModalCloseEvent());
|
|
96
|
-
this.close();
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
FtdsModal.elementDefinitions = {
|
|
100
|
-
"ftds-button": FtdsButton,
|
|
101
|
-
"ftds-typography": FtdsTypography,
|
|
102
|
-
"ft-icon": FtIcon,
|
|
103
|
-
};
|
|
104
|
-
FtdsModal.styles = designSystemStyle;
|
|
105
|
-
__decorate([
|
|
106
|
-
property()
|
|
107
|
-
], FtdsModal.prototype, "heading", void 0);
|
|
108
|
-
__decorate([
|
|
109
|
-
property()
|
|
110
|
-
], FtdsModal.prototype, "icon", void 0);
|
|
111
|
-
__decorate([
|
|
112
|
-
property({ type: Boolean, reflect: true })
|
|
113
|
-
], FtdsModal.prototype, "dialogOpen", void 0);
|
|
114
|
-
__decorate([
|
|
115
|
-
query("dialog")
|
|
116
|
-
], FtdsModal.prototype, "dialog", void 0);
|
|
117
|
-
__decorate([
|
|
118
|
-
property()
|
|
119
|
-
], FtdsModal.prototype, "size", void 0);
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { FtdsTypographyVariants } from "@fluid-topics/ft-typography";
|
|
2
|
-
import { FtdsBaseInterface } from "@fluid-topics/ft-wc-utils";
|
|
3
|
-
export interface FtdsModalProperties extends FtdsBaseInterface {
|
|
4
|
-
heading: string;
|
|
5
|
-
icon?: string;
|
|
6
|
-
}
|
|
7
|
-
export declare const FtDsModalBodyTypography = FtdsTypographyVariants.body2regular;
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { css } from "lit";
|
|
2
|
-
import { modal, } from "@fluid-topics/design-system-variables";
|
|
3
|
-
import { foundation } from "@fluid-topics/ft-wc-utils";
|
|
4
|
-
export { modal as FtdsModalCssVariables };
|
|
5
|
-
// language=CSS
|
|
6
|
-
export const designSystemStyle = [
|
|
7
|
-
css `
|
|
8
|
-
.ftds--size-small [part=dialog] {
|
|
9
|
-
--ftds-modal--target-width: ${modal.smallContainerTargetWidth};
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.ftds--size-medium [part=dialog] {
|
|
13
|
-
--ftds-modal--target-width: ${modal.mediumContainerTargetWidth};
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.ftds--size-large [part=dialog] {
|
|
17
|
-
--ftds-modal--target-width: ${modal.largeContainerTargetWidth};
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
[part=container] {
|
|
21
|
-
position: relative;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
[part=dialog] {
|
|
25
|
-
width: 100%;
|
|
26
|
-
height: 100%;
|
|
27
|
-
max-width: unset; /*Override user-agent stylesheet for dialog:modal set a max width and height to 100% - 6px*/
|
|
28
|
-
max-height: unset;
|
|
29
|
-
background: transparent;
|
|
30
|
-
border: none;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
[part=overlay] {
|
|
34
|
-
position: absolute;
|
|
35
|
-
inset: 0;
|
|
36
|
-
background-color: rgba(from ${modal.overlayBackgroundColor} r g b / ${modal.overlayOpacity});
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
[part=inner-container] {
|
|
40
|
-
position: fixed;
|
|
41
|
-
top: 50%;
|
|
42
|
-
transform: translate(0, -50%);
|
|
43
|
-
box-shadow: ${modal.shadow};
|
|
44
|
-
border-radius: ${modal.borderRadius};
|
|
45
|
-
overflow: hidden;
|
|
46
|
-
width: var(--ftds-modal--target-width);
|
|
47
|
-
background-color: ${modal.bodyBackgroundColor};
|
|
48
|
-
margin: auto max(
|
|
49
|
-
${foundation.spacing6},
|
|
50
|
-
calc((100% - var(--ftds-modal--target-width)) / 2)
|
|
51
|
-
);
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
[part=header] {
|
|
55
|
-
padding: ${modal.headerVerticalPadding} ${modal.headerRightPadding} ${modal.headerVerticalPadding} ${modal.headerLeftPadding};
|
|
56
|
-
display: flex;
|
|
57
|
-
align-items: center;
|
|
58
|
-
gap: ${modal.headerGap};
|
|
59
|
-
border-color: ${modal.headerBorderColor};
|
|
60
|
-
border-bottom-width: ${modal.headerBorderBottomWidth};
|
|
61
|
-
border-bottom-style: solid;
|
|
62
|
-
color: ${modal.headerColor};
|
|
63
|
-
background-color: ${modal.headerBackgroundColor};
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
[part=heading] {
|
|
67
|
-
flex-grow: 1;
|
|
68
|
-
overflow-wrap: anywhere;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
[part=icon] {
|
|
72
|
-
color: ${modal.headerLeadingIconColor};
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
[part=closing-button] {
|
|
76
|
-
justify-self: flex-end;
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
[part=body] {
|
|
80
|
-
padding: ${modal.bodyVerticalPadding} ${modal.bodyHorizontalPadding};
|
|
81
|
-
display: flex;
|
|
82
|
-
flex-direction: column;
|
|
83
|
-
gap: ${modal.bodyVerticalGap};
|
|
84
|
-
color: ${modal.bodyColor};
|
|
85
|
-
background-color: ${modal.bodyBackgroundColor};
|
|
86
|
-
overflow-wrap: anywhere;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
[part=actions] {
|
|
90
|
-
align-self: flex-end;
|
|
91
|
-
display: flex;
|
|
92
|
-
gap: ${foundation.spacing3}
|
|
93
|
-
}
|
|
94
|
-
`
|
|
95
|
-
];
|