blob: 724547fd35937cb20d2d1722f2c89ee3774b3541 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
|
@scope (#pop-demo) {
:scope {
position: relative;
display: block;
padding: 2rem 0.5rem 0;
height: 300px;
margin: 0 auto;
text-align: center;
}
.ui-popbutton {
border-radius: 0.25rem;
border-width: 1px;
background-color: rgb(0 0 0 / 0.1);
padding-top: 0.25rem;
padding-bottom: 0.25rem;
padding-left: 1rem;
padding-right: 1rem;
font-weight: 600;
color: white;
box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1),
0 4px 6px -4px rgb(0 0 0 / 0.1);
}
.ui-popbutton:hover {
background-color: rgb(0 0 0 / 0.2);
}
[popover] {
background-color: Canvas;
border-radius: 0.25rem;
border: 1px solid #666;
color: CanvasText;
height: fit-content;
margin: 0.75rem auto 0;
padding: 1rem;
width: 15rem;
overflow: visible;
transition: all 0.2s allow-discrete;
/* Final state of the exit animation */
opacity: 0;
transform: translateY(-3rem);
}
[popover]:popover-open {
opacity: 1;
transform: translateY(0);
}
/* Needs to be after the previous [popover]:popover-open rule
to take effect, as the specificity is the same */
@starting-style {
[popover]:popover-open {
opacity: 0;
transform: translateY(-3rem);
}
}
/* Transition for the popover's backdrop */
[popover]::backdrop {
/* Final state of the exit animation */
background-color: rgb(0 0 0 / 0%);
transition: all 0.2s allow-discrete;
}
[popover]:popover-open::backdrop {
background-color: rgb(0 0 0 / 15%);
}
@starting-style {
[popover]:popover-open::backdrop {
background-color: rgb(0 0 0 / 0%);
}
}
[popover] h1 {
font-weight: bold;
margin-bottom: 0.75rem;
}
[popover] label {
display: flex;
align-items: center;
justify-content: space-between;
font-size: 0.75rem;
line-height: 1rem;
}
[popover] input {
margin-left: auto;
width: 66.666667%;
border-radius: 0.25rem;
border-width: 1px;
padding: 0.25rem;
font-size: 0.75rem;
line-height: 1rem;
}
[popover] svg.arrow {
position: absolute;
top: -4px;
left: 50%;
z-index: 10;
display: block;
transform: rotate(180deg);
border-color: rgb(255 255 255);
fill: white;
}
}
|