@fluid-topics/ftds-popover 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +40 -0
- package/build/define.d.ts +1 -0
- package/build/define.js +3 -0
- package/build/definitions.d.ts +7 -0
- package/build/definitions.js +6 -0
- package/build/ftds-popover-section.d.ts +13 -0
- package/build/ftds-popover-section.js +61 -0
- package/build/ftds-popover-section.properties.d.ts +3 -0
- package/build/ftds-popover-section.properties.js +1 -0
- package/build/ftds-popover-section.styles.d.ts +1 -0
- package/build/ftds-popover-section.styles.js +22 -0
- package/build/ftds-popover.d.ts +53 -0
- package/build/ftds-popover.js +299 -0
- package/build/ftds-popover.light.js +1725 -0
- package/build/ftds-popover.min.js +1841 -0
- package/build/ftds-popover.properties.d.ts +14 -0
- package/build/ftds-popover.properties.js +5 -0
- package/build/ftds-popover.styles.d.ts +1 -0
- package/build/ftds-popover.styles.js +102 -0
- package/build/index.d.ts +7 -0
- package/build/index.js +7 -0
- package/package.json +35 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { Position } from "@fluid-topics/ft-tooltip";
|
|
2
|
+
export interface FtdsPopoverProperties {
|
|
3
|
+
heading?: string;
|
|
4
|
+
opened?: boolean;
|
|
5
|
+
hidden?: boolean;
|
|
6
|
+
closeButtonLabel?: string;
|
|
7
|
+
openButtonLabel?: string;
|
|
8
|
+
openButtonTooltipPosition?: Position;
|
|
9
|
+
margins?: FtdsPopoverMargins;
|
|
10
|
+
}
|
|
11
|
+
export declare enum FtdsPopoverMargins {
|
|
12
|
+
default = "default",
|
|
13
|
+
dense = "dense"
|
|
14
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const styles: import("lit").CSSResult;
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import { css } from "lit";
|
|
2
|
+
import { popover } from "@fluid-topics/design-system-variables";
|
|
3
|
+
// language=css
|
|
4
|
+
export const styles = css `
|
|
5
|
+
:host {
|
|
6
|
+
position: relative;
|
|
7
|
+
display: inline-block;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
[part="root-container"] {
|
|
11
|
+
position: relative;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
[part="popover-container"] {
|
|
15
|
+
position: absolute;
|
|
16
|
+
z-index: 100;
|
|
17
|
+
display: block;
|
|
18
|
+
margin: auto;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
[part="closing-button-container"] {
|
|
22
|
+
position: absolute;
|
|
23
|
+
top: 8px;
|
|
24
|
+
right: 8px;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
[part="overlay"] {
|
|
28
|
+
position: fixed;
|
|
29
|
+
top: 0;
|
|
30
|
+
right: 0;
|
|
31
|
+
bottom: 0;
|
|
32
|
+
left: 0;
|
|
33
|
+
height: 100%;
|
|
34
|
+
width: 100%;
|
|
35
|
+
opacity: 0;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
[part="wrapper"] {
|
|
39
|
+
visibility: hidden;
|
|
40
|
+
position: fixed;
|
|
41
|
+
display: flex;
|
|
42
|
+
flex-direction: column;
|
|
43
|
+
|
|
44
|
+
max-width: ${popover.maxWidth};
|
|
45
|
+
min-width: ${popover.minWidth};
|
|
46
|
+
max-height: ${popover.maxHeight};
|
|
47
|
+
|
|
48
|
+
padding-left: ${popover.defaultHorizontalPadding};
|
|
49
|
+
padding-right: ${popover.defaultHorizontalPadding};
|
|
50
|
+
padding-top: ${popover.defaultVerticalPadding};
|
|
51
|
+
padding-bottom: ${popover.defaultVerticalPadding};
|
|
52
|
+
gap: ${popover.gap};
|
|
53
|
+
|
|
54
|
+
background-color: ${popover.backgroundColor};
|
|
55
|
+
border-radius: ${popover.borderRadius};
|
|
56
|
+
box-shadow: ${popover.shadow};
|
|
57
|
+
|
|
58
|
+
&.positioned {
|
|
59
|
+
visibility: visible;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
&.ftds-popover--dense {
|
|
64
|
+
padding-left: ${popover.denseHorizontalPadding};
|
|
65
|
+
padding-right: ${popover.denseHorizontalPadding};
|
|
66
|
+
padding-top: ${popover.denseVerticalPadding};
|
|
67
|
+
padding-bottom: ${popover.denseVerticalPadding};
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
[part="heading"] {
|
|
72
|
+
flex-shrink: 0;
|
|
73
|
+
|
|
74
|
+
display: flex;
|
|
75
|
+
align-items: center;
|
|
76
|
+
gap: ${popover.gap};
|
|
77
|
+
|
|
78
|
+
color: ${popover.titleColor};
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
[part="heading"] ftds-typography {
|
|
82
|
+
flex-grow: 1;
|
|
83
|
+
flex-shrink: 1;
|
|
84
|
+
text-overflow: ellipsis;
|
|
85
|
+
overflow: hidden;
|
|
86
|
+
white-space: nowrap;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
[part="content"] {
|
|
90
|
+
color: ${popover.bodyColor};
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
[part="popover-sections"] {
|
|
94
|
+
display: flex;
|
|
95
|
+
flex-direction: column;
|
|
96
|
+
gap: ${popover.multiSectionVerticalGap};
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.hidden {
|
|
100
|
+
display: none;
|
|
101
|
+
}
|
|
102
|
+
`;
|
package/build/index.d.ts
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from "./ftds-popover";
|
|
2
|
+
export * from "./ftds-popover.styles";
|
|
3
|
+
export * from "./ftds-popover.properties";
|
|
4
|
+
export * from "./ftds-popover-section";
|
|
5
|
+
export * from "./ftds-popover-section.styles";
|
|
6
|
+
export * from "./ftds-popover-section.properties";
|
|
7
|
+
import "./define";
|
package/build/index.js
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export * from "./ftds-popover";
|
|
2
|
+
export * from "./ftds-popover.styles";
|
|
3
|
+
export * from "./ftds-popover.properties";
|
|
4
|
+
export * from "./ftds-popover-section";
|
|
5
|
+
export * from "./ftds-popover-section.styles";
|
|
6
|
+
export * from "./ftds-popover-section.properties";
|
|
7
|
+
import "./define";
|
package/package.json
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@fluid-topics/ftds-popover",
|
|
3
|
+
"version": "2.1.0",
|
|
4
|
+
"description": "The design system popover component",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"Lit"
|
|
7
|
+
],
|
|
8
|
+
"author": "Fluid Topics <devtopics@antidot.net>",
|
|
9
|
+
"license": "ISC",
|
|
10
|
+
"main": "build/index.js",
|
|
11
|
+
"web": "build/ftds-popover.min.js",
|
|
12
|
+
"typings": "build/index",
|
|
13
|
+
"files": [
|
|
14
|
+
"build/**/*.js",
|
|
15
|
+
"build/**/*.ts"
|
|
16
|
+
],
|
|
17
|
+
"repository": {
|
|
18
|
+
"type": "git",
|
|
19
|
+
"url": "ssh://git@scm.mrs.antidot.net:2222/fluidtopics/ft-web-components.git"
|
|
20
|
+
},
|
|
21
|
+
"dependencies": {
|
|
22
|
+
"@floating-ui/dom": "1.7.6",
|
|
23
|
+
"@fluid-topics/design-system-variables": "3.5.0",
|
|
24
|
+
"@fluid-topics/ft-tooltip": "2.1.0",
|
|
25
|
+
"@fluid-topics/ft-wc-utils": "2.1.0",
|
|
26
|
+
"@fluid-topics/ftds-button": "2.1.0",
|
|
27
|
+
"@fluid-topics/ftds-icon": "2.1.0",
|
|
28
|
+
"@fluid-topics/ftds-typography": "2.1.0",
|
|
29
|
+
"lit": "3.1.0"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@fluid-topics/ft-wc-test-utils": "2.1.0"
|
|
33
|
+
},
|
|
34
|
+
"gitHead": "4727cf19d04236ad1d2b2cb43ce1c46298834c7e"
|
|
35
|
+
}
|