Skip to content

Commit c45920b

Browse files
Update data (#24)
Co-authored-by: fisker <172584+fisker@users.noreply.github.com>
1 parent 548b284 commit c45920b

File tree

2 files changed

+46
-11
lines changed

2 files changed

+46
-11
lines changed

index.css

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,16 +98,20 @@ dialog:not([open]) {
9898
}
9999
dialog {
100100
position: absolute;
101-
justify-self: dialog;
101+
inset-inline-start: 0;
102+
inset-inline-end: 0;
103+
width: fit-content;
104+
height: fit-content;
105+
margin: auto;
102106
border: solid;
103107
padding: 1em;
104108
background-color: Canvas;
105109
color: CanvasText;
106110
}
107111
dialog:modal {
108112
position: fixed;
109-
place-self: dialog;
110113
overflow: auto;
114+
inset-block: 0;
111115
max-width: calc(100% - 6px - 2em);
112116
max-height: calc(100% - 6px - 2em);
113117
}
@@ -125,7 +129,10 @@ dialog:popover-open {
125129

126130
[popover] {
127131
position: fixed;
128-
place-self: dialog;
132+
inset: 0;
133+
width: fit-content;
134+
height: fit-content;
135+
margin: auto;
129136
border: solid;
130137
padding: 0.25em;
131138
overflow: auto;

index.js

Lines changed: 36 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -200,8 +200,24 @@ export default [
200200
value: 'absolute',
201201
},
202202
{
203-
property: 'justify-self',
204-
value: 'dialog',
203+
property: 'inset-inline-start',
204+
value: '0',
205+
},
206+
{
207+
property: 'inset-inline-end',
208+
value: '0',
209+
},
210+
{
211+
property: 'width',
212+
value: 'fit-content',
213+
},
214+
{
215+
property: 'height',
216+
value: 'fit-content',
217+
},
218+
{
219+
property: 'margin',
220+
value: 'auto',
205221
},
206222
{
207223
property: 'border',
@@ -229,14 +245,14 @@ export default [
229245
property: 'position',
230246
value: 'fixed',
231247
},
232-
{
233-
property: 'place-self',
234-
value: 'dialog',
235-
},
236248
{
237249
property: 'overflow',
238250
value: 'auto',
239251
},
252+
{
253+
property: 'inset-block',
254+
value: '0',
255+
},
240256
{
241257
property: 'max-width',
242258
value: 'calc(100% - 6px - 2em)',
@@ -286,8 +302,20 @@ export default [
286302
value: 'fixed',
287303
},
288304
{
289-
property: 'place-self',
290-
value: 'dialog',
305+
property: 'inset',
306+
value: '0',
307+
},
308+
{
309+
property: 'width',
310+
value: 'fit-content',
311+
},
312+
{
313+
property: 'height',
314+
value: 'fit-content',
315+
},
316+
{
317+
property: 'margin',
318+
value: 'auto',
291319
},
292320
{
293321
property: 'border',

0 commit comments

Comments
 (0)