Skip to content

Commit 1197d66

Browse files
Merge pull request #1525 from karinakharchenko/new-alerts-banners
New alerts banners
2 parents 66adf95 + 213e43c commit 1197d66

File tree

39 files changed

+360
-214
lines changed

39 files changed

+360
-214
lines changed

frontend/src/app/app.component.css

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -256,18 +256,18 @@
256256
width: 12px;
257257
} */
258258

259-
.connection-name {
259+
/* .connection-name {
260260
position: absolute;
261261
top: 6px;
262262
left: 8px;
263263
max-width: calc((100vw - 980px) / 2);
264264
overflow: hidden;
265265
text-overflow: ellipsis;
266-
}
266+
} */
267267

268-
.tab-icon {
268+
/* .tab-icon {
269269
margin-right: 8px;
270-
}
270+
} */
271271

272272
.main-menu-content {
273273
flex-grow: 1;
@@ -288,11 +288,19 @@
288288
}
289289

290290
.content {
291+
--top-margin: 4em;
292+
291293
display: grid;
292294
grid-template-rows: 0 100%;
293295
height: 100%;
294296
}
295297

298+
@media (prefers-color-scheme: dark) {
299+
.main-menu-content_interior .content {
300+
background-color: #212121;
301+
}
302+
}
303+
296304
.helpContainer {
297305
position: fixed;
298306
right: 16px;

frontend/src/app/components/audit/audit.component.css

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
flex-direction: column;
44
align-items: stretch;
55
margin: 0 auto;
6+
height: 100%;
67
width: clamp(300px, 75vw, 1000px);
78
}
89

@@ -105,7 +106,8 @@ th.mat-header-cell, td.mat-cell {
105106
}
106107

107108
.audit-banner {
108-
margin-top: 60px;
109+
margin: -60px calc((100vw - clamp(300px, 75vw, 1000px)) / -2) 0;
110+
width: 100vw;
109111
}
110112

111113
.hidden {

frontend/src/app/components/company-member-invitation/company-member-invitation.component.css

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
:host app-alert:not(:empty) {
2+
--alert-margin: 24px;
3+
4+
position: absolute;
5+
top: var(--mat-toolbar-standard-height);
6+
width: calc(100% - 48px);
7+
}
8+
19
.wrapper {
210
display: flex;
311
flex-direction: column;

frontend/src/app/components/company/company.component.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
1+
:host app-alert:not(:empty) {
2+
--alert-margin: 24px;
3+
}
4+
15
.companyPage {
2-
margin: 3em auto;
6+
margin: var(--top-margin) auto;
37
padding: 0 clamp(200px, 20vw, 300px);
48
}
59

frontend/src/app/components/company/company.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,6 @@ import { orderBy } from "lodash-es";
5555
schemas: [CUSTOM_ELEMENTS_SCHEMA]
5656
})
5757
export class CompanyComponent {
58-
5958
CompanyMemberRole = CompanyMemberRole;
6059
public isSaas = (environment as any).saas;
6160
public company: Company = null;

frontend/src/app/components/connect-db/connect-db.component.css

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
1+
:host app-alert:not(:empty) {
2+
--alert-margin: 24px;
3+
}
4+
15
.connectPage {
2-
padding-top: 16px;
3-
padding-bottom: 20px;
6+
margin-top: var(--top-margin);
7+
margin-bottom: 4em;
48
}
59

610
.form {
@@ -82,6 +86,10 @@
8286
margin-bottom: 0;
8387
}
8488

89+
.connectForm__ipAlert {
90+
--alert-margin: 0;
91+
}
92+
8593
.connectForm__title {
8694
grid-column: 1 / span 3;
8795
}

frontend/src/app/components/connect-db/connect-db.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ <h1 class="mat-h1 connectForm__fullLine">
6060
</div>
6161

6262
<ng-template #warningAlert>
63-
<app-alert [alert]="warning">
63+
<app-alert [alert]="warning" class="connectForm__ipAlert">
6464
<div class="mat-body-1" style="margin-bottom: 0">
6565
Please make sure our servers are able to access your database. <br/> Rocketadmin uses the IP address
6666
<app-ip-address-button ip="18.221.81.73"></app-ip-address-button>

frontend/src/app/components/connection-settings/connection-settings.component.css

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
1-
.zapier-page {
2-
padding: 32px max(calc(50vw - 325px), 10%);
1+
:host app-alert:not(:empty) {
2+
--alert-margin: 24px;
33
}
44

55
.settings-page {
6+
height: 100%;
7+
margin: var(--top-margin) 0;
68
padding: 0 max(calc(50vw - 325px), 10%);
79
}
810

911
.mat-h1 {
10-
margin-top: 2em !important;
1112
margin-bottom: 1.5em !important;
1213
}
1314

@@ -163,8 +164,9 @@
163164
margin-left: 20px;
164165
}
165166

166-
.settings-banner ::ng-deep .banner-wrapper {
167-
margin-top: 60px;
167+
.settings-banner {
168+
margin: -124px calc(max(calc(50vw - 325px), 10%) * -1) 0;
169+
width: 100vw;
168170
}
169171

170172
.error-details {

frontend/src/app/components/connections-list/connections-list.component.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
:host app-alert:not(:empty) {
2+
--alert-margin: 24px;
3+
}
4+
15
.wrapper {
26
display: flex;
37
flex-direction: column;

frontend/src/app/components/connections-list/connections-list.component.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,11 @@ import { take } from 'rxjs/operators';
3838
})
3939
export class ConnectionsListComponent implements OnInit {
4040

41+
public testAlert = {
42+
type: 'info' as const,
43+
message: 'These connections are for demonstration purposes only. To create your own connections, please use the "Add Connection" button above.',
44+
};
45+
4146
public connections: Connection[] = null;
4247
// public testConnections: Connection[] = null;
4348
public titles: Object;

0 commit comments

Comments
 (0)