Skip to content

Commit ec3dba6

Browse files
committed
Update cloud dialog SCSS to newer syntax
1 parent 948d9cc commit ec3dba6

1 file changed

Lines changed: 72 additions & 68 deletions

File tree

src/css/_cloud_dialog.scss

Lines changed: 72 additions & 68 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,87 @@
1-
.plotly-cloud-dialog {
2-
font-family: 'Open Sans', verdana, arial, sans-serif; // Because not all contexts have this specified.
3-
position: absolute;
4-
top: 0;
5-
left: 0;
6-
width: 100%;
7-
height: 100%;
8-
z-index: 1001;
9-
10-
display: flex;
11-
align-items: center;
12-
justify-content: center;
13-
14-
background-color: rgba(0, 0, 0, 0.4);
15-
16-
.plotly-cloud-dialog-box {
17-
box-sizing: border-box;
18-
min-width: 300px;
19-
max-width: 420px;
20-
padding: 20px 24px;
21-
22-
background-color: $color-bg-light;
23-
border: 1px solid $color-bg-darker;
24-
border-radius: 4px;
25-
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
26-
27-
font-size: 13px;
28-
color: #2a3f5f;
29-
}
1+
@use "vars";
302

31-
.plotly-cloud-dialog-title {
32-
font-size: 16px;
33-
font-weight: bold;
34-
margin-bottom: 12px;
35-
}
3+
@mixin styles {
4+
.plotly-cloud-dialog {
5+
font-family: 'Open Sans', verdana, arial, sans-serif; // Because not all contexts have this specified.
6+
position: absolute;
7+
top: 0;
8+
left: 0;
9+
width: 100%;
10+
height: 100%;
11+
z-index: 1001;
3612

37-
.plotly-cloud-dialog-message {
38-
line-height: 1.5;
39-
overflow-wrap: break-word;
40-
word-wrap: break-word;
41-
}
42-
43-
.plotly-cloud-dialog-buttons {
4413
display: flex;
45-
justify-content: flex-end;
46-
margin-top: 20px;
47-
}
14+
align-items: center;
15+
justify-content: center;
4816

49-
.plotly-cloud-dialog-btn {
50-
font-family: inherit;
51-
font-size: 13px;
52-
padding: 7px 16px;
53-
margin-left: 8px;
17+
background-color: rgba(0, 0, 0, 0.4);
5418

55-
border-radius: 3px;
56-
border: 1px solid transparent;
57-
cursor: pointer;
19+
.plotly-cloud-dialog-box {
20+
box-sizing: border-box;
21+
min-width: 300px;
22+
max-width: 420px;
23+
padding: 20px 24px;
5824

59-
&:focus-visible {
60-
outline: 2px solid $color-brand-primary;
61-
outline-offset: 1px;
25+
background-color: vars.$color-bg-light;
26+
border: 1px solid vars.$color-bg-darker;
27+
border-radius: 4px;
28+
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
29+
30+
font-size: 13px;
31+
color: #2a3f5f;
6232
}
63-
}
6433

65-
.plotly-cloud-dialog-btn--cancel {
66-
background-color: $color-bg-light;
67-
border-color: $color-bg-darker;
68-
color: $color-muted-text;
34+
.plotly-cloud-dialog-title {
35+
font-size: 16px;
36+
font-weight: bold;
37+
margin-bottom: 12px;
38+
}
6939

70-
&:hover {
71-
background-color: $color-bg-base;
40+
.plotly-cloud-dialog-message {
41+
line-height: 1.5;
42+
overflow-wrap: break-word;
43+
word-wrap: break-word;
44+
}
45+
46+
.plotly-cloud-dialog-buttons {
47+
display: flex;
48+
justify-content: flex-end;
49+
margin-top: 20px;
50+
}
51+
52+
.plotly-cloud-dialog-btn {
53+
font-family: inherit;
54+
font-size: 13px;
55+
padding: 7px 16px;
56+
margin-left: 8px;
57+
58+
border-radius: 3px;
59+
border: 1px solid transparent;
60+
cursor: pointer;
61+
62+
&:focus-visible {
63+
outline: 2px solid vars.$color-brand-primary;
64+
outline-offset: 1px;
65+
}
66+
}
67+
68+
.plotly-cloud-dialog-btn--cancel {
69+
background-color: vars.$color-bg-light;
70+
border-color: vars.$color-bg-darker;
71+
color: vars.$color-muted-text;
72+
73+
&:hover {
74+
background-color: vars.$color-bg-base;
75+
}
7276
}
73-
}
7477

75-
.plotly-cloud-dialog-btn--confirm {
76-
background-color: $color-brand-primary;
77-
color: $color-bg-light;
78+
.plotly-cloud-dialog-btn--confirm {
79+
background-color: vars.$color-brand-primary;
80+
color: vars.$color-bg-light;
7881

79-
&:hover {
80-
background-color: $color-brand-accent;
82+
&:hover {
83+
background-color: vars.$color-brand-accent;
84+
}
8185
}
8286
}
8387
}

0 commit comments

Comments
 (0)