SarowarSaurav commited on
Commit
5e9353f
1 Parent(s): 53edc6a

Rename style.css to styles.css

Browse files
Files changed (2) hide show
  1. style.css +0 -19
  2. styles.css +210 -0
style.css DELETED
@@ -1,19 +0,0 @@
1
- h1 {
2
- text-align: center;
3
- display: block;
4
- }
5
-
6
- #duplicate-button {
7
- margin: auto;
8
- color: white;
9
- background: #1565c0;
10
- border-radius: 100vh;
11
- }
12
-
13
- .contain {
14
- max-width: 900px;
15
- margin: auto;
16
- /* padding-top: 1.5rem; */
17
- text-align: center;
18
- display: block;
19
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
styles.css ADDED
@@ -0,0 +1,210 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ @mixin size($w, $h) {
2
+ width: $w;
3
+ height: $h;
4
+ }
5
+
6
+ @mixin bdrs($bdrs) {
7
+ border-radius: $bdrs;
8
+ }
9
+
10
+ %center {
11
+ position: absolute;
12
+ top: 50%;
13
+ left: 50%;
14
+ transform: translate(-50%, -50%);
15
+ }
16
+
17
+ %clearfix {
18
+ &::after {
19
+ content: "";
20
+ display: block;
21
+ clear: both;
22
+ }
23
+ }
24
+
25
+ @keyframes ball {
26
+ 0% { margin-top: 0; }
27
+ 20% { margin-top: 3px; }
28
+ 80% { margin-top: -5px; }
29
+ }
30
+
31
+ @keyframes pop {
32
+ 0% { transform: scale(.6); }
33
+ 30% { transform: scale(1.1); }
34
+ 60% { transform: scale(.9); }
35
+ 100% { transform: scale(1); }
36
+ }
37
+
38
+ body, html {
39
+ margin: 0;
40
+ height: 100%;
41
+ width: 100%;
42
+ }
43
+
44
+ html {
45
+ background: #bdc3c7;
46
+ background: -webkit-linear-gradient(to right bottom, #bdc3c7 , #2c3e50);
47
+ background: linear-gradient(to right bottom, #bdc3c7 , #2c3e50);
48
+ }
49
+
50
+ body {
51
+ font-family: 'Microsoft JhengHei', Arial, sans-serif;
52
+ background: url('https://www.transparenttextures.com/patterns/45-degree-fabric-light.png');
53
+ letter-spacing: 1px;
54
+ }
55
+
56
+ .chat {
57
+ @extend %center;
58
+ @include size(300px, 80vh);
59
+ max-height: 500px;
60
+ @include bdrs(15px);
61
+ background-color: rgba(0, 0, 0, .5);
62
+ overflow: hidden;
63
+ }
64
+
65
+ .chat-title {
66
+ background-color: rgba(0, 0, 0, .3);
67
+ @extend %clearfix;
68
+ @include size(100%, 50px);
69
+
70
+ h2 {
71
+ margin: 10px 0;
72
+ padding: 0;
73
+ color: #f0f0f0;
74
+ font-weight: normal;
75
+ font-size: 16px;
76
+ display: inline-block;
77
+ line-height: 30px;
78
+ }
79
+
80
+ .avatar {
81
+ float: left;
82
+ margin: 10px;
83
+ padding: 0;
84
+ @include size(30px, 30px);
85
+
86
+ img {
87
+ @include bdrs(50%);
88
+ @include size(30px, 30px);
89
+ }
90
+ }
91
+ }
92
+
93
+ .messages {
94
+ @include size(100%, calc(100% - 90px));
95
+
96
+ .messages-content {
97
+ @include size(100%, 100%);
98
+ overflow-y: auto;
99
+ box-sizing: border-box;
100
+
101
+ .message {
102
+ max-width: calc(100% - 76px);
103
+ padding: 8px;
104
+ margin: 8px 0 8px 12px;
105
+ @include bdrs(5px);
106
+ background-color: rgba(171, 188, 202, .1);
107
+ color: #e3e3e3;
108
+ float: left;
109
+ font-size: 13px;
110
+ position: relative;
111
+ word-break: break-all;
112
+ clear: both;
113
+ animation: pop .3s forwards;
114
+
115
+ .timestamp {
116
+ position: absolute;
117
+ right: -40px;
118
+ bottom: 0;
119
+ font-size: 12px;
120
+ color: #bababa;
121
+ }
122
+
123
+ &.personal {
124
+ float: right;
125
+ margin: 8px 12px 8px 0;
126
+
127
+ .timestamp {
128
+ right: auto;
129
+ left: -40px;
130
+ }
131
+ }
132
+
133
+ &.typing {
134
+ @include size(30px, 16px);
135
+
136
+ &::after {
137
+ content: "";
138
+ @include bdrs(50%);
139
+ @include size(3px, 3px);
140
+ background-color: white;
141
+ @extend %center;
142
+ transform: translate(-50%, -50%);
143
+ animation: ball 1.2s infinite linear;
144
+ }
145
+
146
+ span {
147
+ @include size(3px, 3px);
148
+ @extend %center;
149
+ transform: translate(-50%, -50%);
150
+
151
+ &::before, &::after {
152
+ content: "";
153
+ @include bdrs(50%);
154
+ @include size(3px, 3px);
155
+ position: absolute;
156
+ background-color: white;
157
+ animation: ball 1.2s infinite linear;
158
+ }
159
+
160
+ &::before {
161
+ left: 8px;
162
+ animation-delay: .3s;
163
+ }
164
+
165
+ &::after {
166
+ right: 8px;
167
+ animation-delay: -.3s;
168
+ }
169
+ }
170
+ }
171
+ }
172
+ }
173
+ }
174
+
175
+ .action-box {
176
+ background-color: rgba(0, 0, 0, .3);
177
+ @include size(100%, 40px);
178
+ @extend %clearfix;
179
+
180
+ .action-box-input, .action-box-submit {
181
+ box-sizing: border-box;
182
+ border: 0;
183
+ float: left;
184
+ }
185
+
186
+ .action-box-input {
187
+ @include size(calc(100% - 60px), 20px);
188
+ background-color: transparent;
189
+ resize: none;
190
+ color: white;
191
+ margin: 10px 0;
192
+ padding: 0 10px;
193
+ line-height: 20px;
194
+ font-size: 16px;
195
+ letter-spacing: 1px;
196
+ overflow: hidden;
197
+
198
+ &::-webkit-input-placeholder {
199
+ line-height: 20px;
200
+ font-size: 13px;
201
+ }
202
+ }
203
+
204
+ .action-box-submit {
205
+ @include size(60px, 40px);
206
+ background-color: rgba(189, 195, 199, .2);
207
+ color: white;
208
+ cursor: pointer;
209
+ }
210
+ }