ngx-snotifire 15.0.3 → 15.0.4-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/styles/_shared/animations.scss +188 -0
- package/styles/_shared/icons.scss +39 -0
- package/styles/dark/buttons.scss +41 -0
- package/styles/dark/icon.scss +60 -0
- package/styles/dark/prompt.scss +134 -0
- package/styles/dark/snotify.scss +65 -0
- package/styles/dark/toast.scss +104 -0
- package/styles/dark.scss +9 -0
- package/styles/material/buttons.scss +75 -0
- package/styles/material/icon.scss +60 -0
- package/styles/material/prompt.scss +135 -0
- package/styles/material/snotify.scss +65 -0
- package/styles/material/toast.scss +232 -0
- package/styles/material.scss +8 -0
- package/styles/simple/buttons.scss +41 -0
- package/styles/simple/icon.scss +60 -0
- package/styles/simple/prompt.scss +134 -0
- package/styles/simple/snotify.scss +65 -0
- package/styles/simple/toast.scss +143 -0
- package/styles/simple.scss +8 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
.notifire-toast__input {
|
|
2
|
+
position: relative;
|
|
3
|
+
z-index: 1;
|
|
4
|
+
display: inline-block;
|
|
5
|
+
margin: 0;
|
|
6
|
+
width: 100%;
|
|
7
|
+
vertical-align: top;
|
|
8
|
+
transition: all 0.5s;
|
|
9
|
+
transition-delay: 0.3s;
|
|
10
|
+
transition-timing-function: cubic-bezier(0.2, 1, 0.3, 1);
|
|
11
|
+
|
|
12
|
+
&__field {
|
|
13
|
+
position: relative;
|
|
14
|
+
display: block;
|
|
15
|
+
float: right;
|
|
16
|
+
padding: 0.85em 0.5em;
|
|
17
|
+
width: 100%;
|
|
18
|
+
border: none;
|
|
19
|
+
border-radius: 0;
|
|
20
|
+
background: transparent;
|
|
21
|
+
color: #333;
|
|
22
|
+
font-weight: bold;
|
|
23
|
+
-webkit-appearance: none; /* for box shadows to show on iOS */
|
|
24
|
+
opacity: 0;
|
|
25
|
+
transition: opacity 0.3s;
|
|
26
|
+
|
|
27
|
+
&:focus {
|
|
28
|
+
outline: none;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&__label {
|
|
33
|
+
display: inline-block;
|
|
34
|
+
float: right;
|
|
35
|
+
padding: 0 0.85em;
|
|
36
|
+
width: 100%;
|
|
37
|
+
color: #999;
|
|
38
|
+
font-weight: bold;
|
|
39
|
+
font-size: 70.25%;
|
|
40
|
+
-webkit-font-smoothing: antialiased;
|
|
41
|
+
-moz-osx-font-smoothing: grayscale;
|
|
42
|
+
-webkit-touch-callout: none;
|
|
43
|
+
-webkit-user-select: none;
|
|
44
|
+
-khtml-user-select: none;
|
|
45
|
+
-moz-user-select: none;
|
|
46
|
+
-ms-user-select: none;
|
|
47
|
+
user-select: none;
|
|
48
|
+
position: absolute;
|
|
49
|
+
left: 0;
|
|
50
|
+
height: 100%;
|
|
51
|
+
text-align: left;
|
|
52
|
+
pointer-events: none;
|
|
53
|
+
|
|
54
|
+
&::before,
|
|
55
|
+
&::after {
|
|
56
|
+
content: "";
|
|
57
|
+
position: absolute;
|
|
58
|
+
top: 0;
|
|
59
|
+
left: 0;
|
|
60
|
+
width: 100%;
|
|
61
|
+
height: 100%;
|
|
62
|
+
transition: transform 0.3s;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
&::before {
|
|
66
|
+
border-top: 2px solid $prompt-border-color;
|
|
67
|
+
transform: translate3d(0, 100%, 0) translate3d(0, -2px, 0);
|
|
68
|
+
transition-delay: 0.3s;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
&::after {
|
|
72
|
+
z-index: -1;
|
|
73
|
+
background: #eee;
|
|
74
|
+
transform: scale3d(1, 0, 1);
|
|
75
|
+
transform-origin: 50% 0;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&__labelContent {
|
|
80
|
+
position: relative;
|
|
81
|
+
display: block;
|
|
82
|
+
padding: 1em 0;
|
|
83
|
+
width: 100%;
|
|
84
|
+
transition: transform 0.3s 0.3s;
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.notifire-toast__input--filled {
|
|
89
|
+
margin-top: 2.5em;
|
|
90
|
+
|
|
91
|
+
&:focus,
|
|
92
|
+
.notifire-toast__input__field {
|
|
93
|
+
opacity: 1;
|
|
94
|
+
transition-delay: 0.3s;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.notifire-toast__input__field:focus
|
|
99
|
+
+ .notifire-toast__input__label
|
|
100
|
+
.notifire-toast__input__labelContent,
|
|
101
|
+
.notifire-toast__input--filled .notifire-toast__input__labelContent {
|
|
102
|
+
transform: translate(0, -80%);
|
|
103
|
+
transition-timing-function: cubic-bezier(0.2, 1, 0.3, 1);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.notifire-toast__input__field:focus + .notifire-toast__input__label::before,
|
|
107
|
+
.notifire-toast__input--filled .notifire-toast__input__label::before {
|
|
108
|
+
transition-delay: 0s;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.notifire-toast__input__field:focus + .notifire-toast__input__label::before,
|
|
112
|
+
.notifire-toast__input--filled .notifire-toast__input__label::before {
|
|
113
|
+
transform: translate(0, 0);
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.notifire-toast__input__field:focus + .notifire-toast__input__label::after,
|
|
117
|
+
.notifire-toast__input--filled .notifire-toast__input__label::after {
|
|
118
|
+
transform: scale(1, 1);
|
|
119
|
+
transition-delay: 0.3s;
|
|
120
|
+
transition-timing-function: cubic-bezier(0.2, 1, 0.3, 1);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.notifire-toast {
|
|
124
|
+
&--invalid {
|
|
125
|
+
.notifire-toast__input__label::before {
|
|
126
|
+
border-color: $error-border-color;
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
&--valid {
|
|
130
|
+
.notifire-toast__input__label::before {
|
|
131
|
+
border-color: $success-border-color;
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
$backdrop-color: #000000;
|
|
2
|
+
$snotify-width: auto !default;
|
|
3
|
+
|
|
4
|
+
@if $snotify-width == auto {
|
|
5
|
+
$snotify-width: 300px;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
.snotify {
|
|
9
|
+
display: block;
|
|
10
|
+
position: fixed;
|
|
11
|
+
width: $snotify-width;
|
|
12
|
+
z-index: 9999;
|
|
13
|
+
box-sizing: border-box;
|
|
14
|
+
pointer-events: none;
|
|
15
|
+
* {
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.snotify-leftTop,
|
|
21
|
+
.snotify-leftCenter,
|
|
22
|
+
.snotify-leftBottom {
|
|
23
|
+
left: 10px;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.snotify-rightTop,
|
|
27
|
+
.snotify-rightCenter,
|
|
28
|
+
.snotify-rightBottom {
|
|
29
|
+
right: 10px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.snotify-centerTop,
|
|
33
|
+
.snotify-centerCenter,
|
|
34
|
+
.snotify-centerBottom {
|
|
35
|
+
left: calc(50% - #{$snotify-width} / 2);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.snotify-leftTop,
|
|
39
|
+
.snotify-centerTop,
|
|
40
|
+
.snotify-rightTop {
|
|
41
|
+
top: 10px;
|
|
42
|
+
}
|
|
43
|
+
.snotify-leftCenter,
|
|
44
|
+
.snotify-rightCenter,
|
|
45
|
+
.snotify-centerCenter {
|
|
46
|
+
top: 50%;
|
|
47
|
+
transform: translateY(-50%);
|
|
48
|
+
}
|
|
49
|
+
.snotify-leftBottom,
|
|
50
|
+
.snotify-rightBottom,
|
|
51
|
+
.snotify-centerBottom {
|
|
52
|
+
bottom: 10px;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.snotifire-backdrop{
|
|
56
|
+
position: fixed;
|
|
57
|
+
top: 0;
|
|
58
|
+
right: 0;
|
|
59
|
+
bottom: 0;
|
|
60
|
+
left: 0;
|
|
61
|
+
background-color: $backdrop-color;
|
|
62
|
+
opacity: 0;
|
|
63
|
+
z-index: 9998;
|
|
64
|
+
transition: opacity 0.3s;
|
|
65
|
+
}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
$toast-bg: #fff;
|
|
2
|
+
$toast-color: #000;
|
|
3
|
+
$toast-progressBar: #c7c7c7;
|
|
4
|
+
$toast-progressBarPercentage: #4c4c4c;
|
|
5
|
+
|
|
6
|
+
$border-width: 4px;
|
|
7
|
+
$simple-border-color: #000;
|
|
8
|
+
$success-border-color: #4caf50;
|
|
9
|
+
$info-border-color: #1e88e5;
|
|
10
|
+
$warning-border-color: #ff9800;
|
|
11
|
+
$error-border-color: #f44336;
|
|
12
|
+
$async-border-color: $info-border-color;
|
|
13
|
+
$confirm-border-color: #009688;
|
|
14
|
+
$prompt-border-color: $confirm-border-color;
|
|
15
|
+
|
|
16
|
+
$snotify-title-font-size: auto !default;
|
|
17
|
+
$snotify-body-font-size: auto !default;
|
|
18
|
+
|
|
19
|
+
@if $snotify-title-font-size == auto {
|
|
20
|
+
$snotify-title-font-size: 1.8em;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
@if $snotify-body-font-size == auto {
|
|
24
|
+
$snotify-body-font-size: 1em;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.notifire-toast {
|
|
28
|
+
display: block;
|
|
29
|
+
cursor: pointer;
|
|
30
|
+
background-color: $toast-bg;
|
|
31
|
+
max-height: 300px;
|
|
32
|
+
height: 100%;
|
|
33
|
+
margin: 5px;
|
|
34
|
+
opacity: 0;
|
|
35
|
+
overflow: hidden;
|
|
36
|
+
pointer-events: auto;
|
|
37
|
+
|
|
38
|
+
&--in {
|
|
39
|
+
animation-name: appear;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
&--out {
|
|
43
|
+
animation-name: disappear;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
&__inner {
|
|
47
|
+
display: flex;
|
|
48
|
+
flex-flow: column nowrap;
|
|
49
|
+
align-items: flex-start;
|
|
50
|
+
justify-content: center;
|
|
51
|
+
position: relative;
|
|
52
|
+
padding: 5px 65px 5px 15px;
|
|
53
|
+
min-height: 78px;
|
|
54
|
+
font-size: 16px;
|
|
55
|
+
color: $toast-color;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
&__progressBar {
|
|
59
|
+
position: relative;
|
|
60
|
+
width: 100%;
|
|
61
|
+
height: 5px;
|
|
62
|
+
background-color: $toast-progressBar;
|
|
63
|
+
|
|
64
|
+
&__percentage {
|
|
65
|
+
position: absolute;
|
|
66
|
+
top: 0;
|
|
67
|
+
left: 0;
|
|
68
|
+
height: 5px;
|
|
69
|
+
background-color: $toast-progressBarPercentage;
|
|
70
|
+
max-width: 100%;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
&__title {
|
|
75
|
+
font-size: $snotify-title-font-size;
|
|
76
|
+
line-height: 1.2em;
|
|
77
|
+
margin-bottom: 5px;
|
|
78
|
+
color: $toast-color;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
&__body {
|
|
82
|
+
font-size: $snotify-body-font-size;
|
|
83
|
+
color: $toast-color;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.notifire-toast-show {
|
|
88
|
+
transform: translate(0, 0);
|
|
89
|
+
opacity: 1;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.notifire-toast-remove {
|
|
93
|
+
max-height: 0;
|
|
94
|
+
overflow: hidden;
|
|
95
|
+
transform: translate(0, 50%);
|
|
96
|
+
opacity: 0;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
/***************
|
|
100
|
+
** Modifiers **
|
|
101
|
+
**************/
|
|
102
|
+
|
|
103
|
+
.snotify-simple {
|
|
104
|
+
border-left: $border-width solid $simple-border-color;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.snotify-success {
|
|
108
|
+
border-left: $border-width solid $success-border-color;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.snotify-info {
|
|
112
|
+
border-left: $border-width solid $info-border-color;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.snotify-warning {
|
|
116
|
+
border-left: $border-width solid $warning-border-color;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.snotify-error {
|
|
120
|
+
border-left: $border-width solid $error-border-color;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.snotify-async {
|
|
124
|
+
border-left: $border-width solid $async-border-color;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
.snotify-confirm {
|
|
128
|
+
border-left: $border-width solid $confirm-border-color;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.snotify-prompt {
|
|
132
|
+
border-left: $border-width solid $prompt-border-color;
|
|
133
|
+
ngx-snotify-prompt {
|
|
134
|
+
width: 100%;
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.snotify-confirm,
|
|
139
|
+
.snotify-prompt {
|
|
140
|
+
.notifire-toast__inner {
|
|
141
|
+
padding: 10px 15px;
|
|
142
|
+
}
|
|
143
|
+
}
|