A web-based drawing app
git clone git://soophie.de/outline
blob: f7dbf6103292e2d933d073b004492f8cf0195cf3 (7071 bytes)[doc][blame][raw]
1
canvas.canvas {2
position: relative;3
z-index: 1;4
cursor: none;5
touch-action: none;6
}8
canvas.overlay {9
pointer-events: none;10
user-select: none;11
position: absolute;12
top: 0;13
left: 0;14
right: 0;15
bottom: 0;16
z-index: 99;17
}19
.wrapper {20
width: 100vw;21
height: 100vh;22
position: fixed;23
top: 0;24
left: 0;25
right: 0;26
bottom: 0;27
display: flex;28
justify-content: center;29
align-items: center;30
background: rgba(0, 0, 0, 0.2);31
z-index: 99999;32
user-select: none;33
}35
.spinner {36
width: 80px;37
height: 80px;38
border-radius: 40px;39
border: 10px solid rgba(255,255,255,0.2);40
border-top: 10px solid white;41
animation: spin 2s linear infinite;42
}44
@keyframes spin {45
0% { transform: rotate(0deg); }46
100% { transform: rotate(360deg); }47
}49
.modal {50
background: white;51
width: 400px;52
border-radius: 6px;53
margin-top: -100px;54
padding: 20px;55
box-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.03);57
&.modal-error {58
width: 300px;60
.align {61
justify-content: flex-end;62
}63
}65
&.theme-dark {66
background: @color-dark;67
color: white;69
button.action-cancel {70
background: @color-dark-grey;71
color: white;73
&:hover {74
background: lighten(@color-dark-grey, -2%);75
}76
}78
input[type="text"] {79
background: @color-black;80
color: white;82
&:hover {83
background: lighten(@color-black, -2%);84
}86
&:focus {87
background: lighten(@color-black, -2%);88
}89
}91
.separator {92
border-color: @color-dark-grey;93
}95
input[type="range"] {96
background: lighten(@color-black, 2%);97
}99
.preview {100
background: lighten(@color-black, 2%);101
}103
ul.avatar-list {105
li.avatar {106
border-color: @color-dark;107
background: lighten(@color-black, 1%);109
&:hover {110
border-color: lighten(@color-black, 3.5%);111
}112
}113
}114
}116
input.action-uuid,117
input.action-file {118
padding: 12px 14px;119
width: 100%;120
border: none;121
background: #FAFAFA;122
border-radius: 3px;123
font-size: 16px;124
user-select: none;126
&:hover {127
background: #F8F8F8;128
}130
&:focus {131
background: #F5F5F5;132
}133
}135
.separator {136
border-top: 1px solid #F5F5F5;137
margin: 20px 0;138
}140
.align {141
display: flex;142
justify-content: space-between;143
align-items: center;144
}146
p {147
font-size: 18px;148
letter-spacing: 0.2px;149
padding-top: 5px;150
margin-bottom: 25px;151
}153
button {154
padding: 12px 14px;155
border: none;156
background: #F8F9FA;157
border-radius: 3px;158
font-size: 16px;159
cursor: pointer;160
user-select: none;161
transition: background 0.1s;162
color: #212121;164
&:hover {165
background: lighten(#F8F9FA, -5%);166
}168
&.success {169
background: #28A745;170
color: white;172
&:hover {173
background: lighten(#28A745, -5%);174
}175
}177
&.danger {178
background: #DC3545;179
color: white;181
&:hover {182
background: lighten(#DC3545, -5%);183
}184
}186
&.info {187
background: #007BFF;188
color: white;190
&:hover {191
background: lighten(#007BFF, -5%);192
}193
}194
}196
button.action-join {197
width: 100%;198
}200
button.action-cancel {201
width: calc(50% - 10px);202
}204
button.action-save,205
button.action-clear,206
button.action-background,207
button.action-scaling,208
button.action-color,209
button.action-default {210
width: calc(50% - 10px);211
}213
ul.avatar-list {214
display: flex;215
flex-wrap: wrap;216
width: 100%;217
list-style-type: none;219
li.avatar {220
background: #EEE;221
border-radius: 9999px;222
border: 5px solid white;223
margin: 10px;224
width: 70px;225
height: 70px;226
cursor: pointer;227
transition: border-color 0.1s;229
&:hover {230
border: 5px solid #F8F8F8;231
}232
}233
}235
input.action-range {236
width: calc(100% - 80px);237
-webkit-appearance: none;238
background: #F8F8F8;239
height: 6px;241
&:hover {242
background: #F5F5F5;244
&::-webkit-slider-thumb {245
background: lighten(#888888, -20%);246
}247
}249
&::-webkit-slider-thumb {250
-webkit-appearance: none;251
background: #888888;252
width: 20px;253
height: 20px;254
border-radius: 9999px;255
border: none;256
cursor: pointer;257
transition: background 0.1s;258
}260
&::-webkit-slider-runnable-track {261
-webkit-appearance: none;262
}263
}265
.preview {266
width: 60px;267
height: 60px;268
background: #F5F5F5;269
border-radius: 9999px;270
display: flex;271
justify-content: center;272
align-items: center;274
.circle {275
width: 12px;276
height: 12px;277
background: #212121;278
border-radius: 9999px;279
}280
}282
&.modal-color {283
width: 580px;285
.align {286
width: calc(100% - 200px);287
margin-left: 200px;288
justify-content: flex-end;289
}290
}292
ul.bucket-list {293
display: flex;294
flex-wrap: wrap;295
width: 100%;296
list-style-type: none;298
li.bucket {299
background: #EEE;300
border-radius: 9999px;301
margin: 10px;302
width: 70px;303
height: 70px;304
cursor: pointer;305
transition: transform 0.2s;306
box-shadow: 0 0px 8px 2px rgba(0, 0, 0, 0.05);308
transform: scale(0.9);309
user-select: none;311
&:hover {312
transition: transform 0.2s;313
transform: scale(1);314
}316
&.active {317
transform: scale(1);318
border: 3px solid #212121;319
}321
&::after {322
position: absolute;323
bottom: -20%;324
}325
}326
}327
}329
.toolbar {330
position: fixed;331
left: calc(50% - 252px);332
bottom: 30px;333
z-index: 2;334
display: flex;335
z-index: 999;337
.bucket {338
width: 56px;339
height: 56px;340
border-radius: 9999px;341
background: #CCC;342
margin: 8px;343
transition: transform 0.2s;344
box-shadow: 0 0px 8px 2px rgba(0, 0, 0, 0.05);345
cursor: pointer;346
transform: scale(0.9);347
user-select: none;349
&:hover {350
transition: transform 0.2s;351
transform: scale(1);352
}354
&.active {355
transform: scale(1.1);356
}357
}358
}360
.actions {361
position: fixed;362
top: 30px;363
left: 30px;364
display: flex;365
}367
.action {368
user-select: none;369
position: relative;370
width: 46px;371
height: 46px;372
border: none;373
border-radius: 9999px;374
background: transparent;375
cursor: pointer;376
outline: none;377
position: fixed;378
margin-right: 8px;380
i {381
color: #212121;382
user-select: none;383
pointer-events: none;384
}386
&:hover {387
background: #ECECEC;388
}390
&::after {391
bottom: -60%;392
}393
}395
.tooltip {396
position: relative;397
display: flex;398
justify-content: center;399
align-items: center;401
&:hover {403
&::before {404
opacity: 1;405
transition-delay: 0.6s;406
}408
&::after {409
opacity: 1;410
transition-delay: 0.6s;411
}412
}414
&::after {415
display: flex;416
opacity: 0;417
content: attr(data-title);418
justify-content: center;419
align-items: center;420
position: absolute;421
background: #212121;422
color: white;423
min-height: 24px;424
padding: 0 10px;425
border-radius: 4px;426
font-size: 12px;427
top: auto;428
bottom: -70%;429
white-space: nowrap;430
z-index: 9999;431
pointer-events: none;432
}434
&.up {436
&::before {437
top: ~'calc(-90% + 26px)';438
bottom: auto;439
border-left: 6px solid transparent;440
border-right: 6px solid transparent;441
border-top: 6px solid #212121;442
border-bottom: none;443
}445
&::after {446
top: -60%;447
bottom: auto;448
}449
}451
&.down {453
&::before {454
top: auto;455
bottom: ~'calc(-90% + 26px)';456
border-left: 6px solid transparent;457
border-right: 6px solid transparent;458
border-top: none;459
border-bottom: 6px solid #212121;460
}462
&::after {463
top: auto;464
bottom: -60%;465
}466
}467
}