1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-16 16:23:44 +00:00

sweetalert tweaks

This commit is contained in:
Kyle Spearrin
2020-03-04 13:51:52 -05:00
parent 0b42d14d58
commit cc0125b920
3 changed files with 7 additions and 8 deletions

View File

@@ -102,7 +102,7 @@
"nord": "^0.2.1", "nord": "^0.2.1",
"papaparse": "4.6.0", "papaparse": "4.6.0",
"rxjs": "6.3.3", "rxjs": "6.3.3",
"sweetalert2": "^9.8.2", "sweetalert2": "9.8.2",
"tldjs": "2.3.1", "tldjs": "2.3.1",
"web-animations-js": "2.3.1", "web-animations-js": "2.3.1",
"zone.js": "0.8.28", "zone.js": "0.8.28",

View File

@@ -213,7 +213,7 @@ export class AppComponent implements OnInit {
} }
private async showDialog(msg: any) { private async showDialog(msg: any) {
let iconClasses = null; let iconClasses: string = null;
const type = msg.type; const type = msg.type;
if (type != null) { if (type != null) {
// If you add custom types to this part, the type to SweetAlertIcon cast below needs to be changed. // If you add custom types to this part, the type to SweetAlertIcon cast below needs to be changed.

View File

@@ -108,7 +108,7 @@ $fa-font-path: "~font-awesome/fonts";
// SweetAlert // SweetAlert
.swal2-popup { .swal2-popup {
padding: 0; padding: 15px 15px;
border-radius: $border-radius; border-radius: $border-radius;
width: 34em; // slightly bigger than the hardcoded 478px in v1. width: 34em; // slightly bigger than the hardcoded 478px in v1.
@include themify($themes) { @include themify($themes) {
@@ -117,14 +117,14 @@ $fa-font-path: "~font-awesome/fonts";
} }
.swal2-icon { .swal2-icon {
margin: 15px auto 0 auto; margin: 0 auto;
width: auto; width: auto;
height: auto; height: auto;
border: none; border: none;
} }
.swal2-content { .swal2-content {
padding: 20px 20px 15px; margin: 0;
font-size: $font-size-base; font-size: $font-size-base;
@include themify($themes) { @include themify($themes) {
color: themed('textColor'); color: themed('textColor');
@@ -173,7 +173,7 @@ $fa-font-path: "~font-awesome/fonts";
} }
.swal2-title { .swal2-title {
padding: 10px 10px 15px 10px; padding: 10px 0 15px;
margin: 0; margin: 0;
font-size: $font-size-large; font-size: $font-size-large;
@@ -196,8 +196,7 @@ $fa-font-path: "~font-awesome/fonts";
} }
.swal2-actions { .swal2-actions {
padding: 0 10px 10px 10px; // 0 due to padding to content being 15px margin: 20px auto 0;
margin: 0;
justify-content: flex-end; justify-content: flex-end;
button { button {