A web-based drawing app
git clone git://soophie.de/outline
blob: ce67ccb663384e5ceaf882d3651df2e92fd44cdf (9099 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: 9999;32
user-select: none;34
& > .info {35
position: fixed;36
right: 30px;37
bottom: 30px;38
display: flex;40
ul.info-list {41
display: flex;42
list-style-type: none;44
li.info-item {45
color: @color-dark;46
margin-left: 15px;47
user-select: none;48
font-weight: 500;50
a {51
user-select: none;52
color: @color-blue;53
text-decoration: none;55
&.subtle {56
color: @color-grey;57
}59
&:hover {60
text-decoration: underline;61
}62
}63
}64
}65
}66
}68
.spinner {69
width: 80px;70
height: 80px;71
border-radius: 40px;72
border: 10px solid rgba(255,255,255,0.2);73
border-top: 10px solid white;74
animation: spin 2s linear infinite;76
&.theme-dark {77
border: 10px solid rgba(0,0,0,0.2);78
border-top: 10px solid @color-black;79
}80
}82
@keyframes spin {83
0% { transform: rotate(0deg); }84
100% { transform: rotate(360deg); }85
}87
.modal {88
background: white;89
width: 400px;90
border-radius: 6px;91
padding: 20px;92
margin: 20px;93
box-shadow: 0 0 4px 0 rgba(0, 0, 0, 0.03);95
&.modal-error {96
width: 300px;98
.align {99
justify-content: flex-end;100
}101
}103
&.theme-dark {104
background: @color-dark;105
color: white;107
button.action-cancel {108
background: lighten(@color-dark, 5%);109
color: white;111
&:hover {112
background: lighten(@color-dark, 2%);113
}114
}116
input[type="text"] {117
background: @color-black;118
color: white;120
&:hover {121
background: lighten(@color-black, -2%);122
}124
&:focus {125
background: lighten(@color-black, -2%);126
}127
}129
.separator {130
border-color: lighten(@color-dark, 5%);131
}133
input[type="range"] {134
background: lighten(@color-black, 2%);136
&:hover {137
background: @color-black;139
&::-webkit-slider-thumb {140
background: lighten(@color-dark, 2%);141
}142
}144
&::-webkit-slider-thumb {145
background: lighten(@color-dark, 5%);146
}147
}149
.preview {150
background: lighten(@color-black, 2%);151
}153
ul.avatar-list {155
li.avatar {156
border-color: @color-dark;157
background: lighten(@color-black, 1%);159
&:hover {160
border-color: lighten(@color-black, 3.5%);161
}162
}163
}165
&.modal-color {167
&:before {168
background: linear-gradient(@color-dark, transparent);169
}171
&:after {172
background: linear-gradient(transparent, @color-dark);173
}175
.bucket-list {177
&::-webkit-scrollbar-thumb {178
background: lighten(@color-black, 2%);180
&:hover {181
background: @color-black;182
}183
}184
}185
}186
}188
input.action-uuid,189
input.action-file {190
padding: 12px 14px;191
width: 100%;192
border: none;193
background: #FAFAFA;194
border-radius: 3px;195
font-size: 16px;196
user-select: none;197
margin-bottom: 3px;199
&:hover {200
background: #F8F8F8;201
}203
&:focus {204
background: #F5F5F5;205
}207
&.invalid {208
border-bottom: 3px solid #FF4A4A;209
border-radius: 3px 3px 0 0;210
margin-bottom: 0;211
}212
}214
.separator {215
border-top: 1px solid #F5F5F5;216
margin: 20px 0;217
}219
.align {220
display: flex;221
justify-content: space-between;222
align-items: center;223
}225
p {226
font-size: 18px;227
letter-spacing: 0.2px;228
padding-top: 5px;229
margin-bottom: 25px;230
}232
button {233
padding: 12px 14px;234
border: none;235
background: #F8F9FA;236
border-radius: 3px;237
font-size: 16px;238
cursor: pointer;239
user-select: none;240
transition: background 0.1s;241
color: #212121;243
&:hover {244
background: lighten(#F8F9FA, -5%);245
}247
&.success {248
background: #28A745;249
color: white;251
&:hover {252
background: lighten(#28A745, -5%);253
}254
}256
&.danger {257
background: #DC3545;258
color: white;260
&:hover {261
background: lighten(#DC3545, -5%);262
}263
}265
&.info {266
background: #007BFF;267
color: white;269
&:hover {270
background: lighten(#007BFF, -5%);271
}272
}273
}275
button.action-join {276
width: 100%;277
}279
button.action-cancel {280
width: calc(50% - 10px);281
}283
button.action-save,284
button.action-clear,285
button.action-background,286
button.action-scaling,287
button.action-color,288
button.action-default {289
width: calc(50% - 10px);290
}292
ul.avatar-list {293
display: flex;294
flex-wrap: wrap;295
width: 100%;296
list-style-type: none;298
li.avatar {299
background: #EEE;300
border-radius: 9999px;301
border: 5px solid white;302
margin: 10px;303
width: 70px;304
height: 70px;305
cursor: pointer;306
transition: border-color 0.1s;308
&:hover {309
border: 5px solid #F8F8F8;310
}311
}312
}314
input.action-range {315
width: calc(100% - 80px);316
-webkit-appearance: none;317
background: #F8F8F8;318
height: 6px;320
&:hover {321
background: #F5F5F5;323
&::-webkit-slider-thumb {324
background: lighten(#888888, -20%);325
}326
}328
&::-webkit-slider-thumb {329
-webkit-appearance: none;330
background: #888888;331
width: 20px;332
height: 20px;333
border-radius: 9999px;334
border: none;335
cursor: pointer;336
transition: background 0.1s;337
}339
&::-webkit-slider-runnable-track {340
-webkit-appearance: none;341
}342
}344
.preview {345
width: 60px;346
height: 60px;347
background: #F5F5F5;348
border-radius: 9999px;349
display: flex;350
justify-content: center;351
align-items: center;353
.circle {354
width: 12px;355
height: 12px;356
background: #212121;357
border-radius: 9999px;358
}359
}361
&.modal-color {362
width: 420px;363
position: relative;365
&:before {366
content: '';367
display: block;368
position: absolute;369
top: 20px;370
left: 20px;371
right: 26px;372
height: 10px;373
background: linear-gradient(white, transparent);374
z-index: 9;375
}377
&:after {378
content: '';379
display: block;380
position: absolute;381
bottom: 82px;382
left: 20px;383
right: 26px;384
height: 10px;385
background: linear-gradient(transparent, white);386
z-index: 9;387
}389
.bucket-list {390
display: flex;391
justify-content: center;392
max-height: 400px;393
overflow-x: hidden;394
overflow-y: auto;395
padding-top: 10px;396
padding-bottom: 10px;397
margin-bottom: 20px;399
&::-webkit-scrollbar {400
width: 6px;401
}403
&::-webkit-scrollbar-thumb {404
width: 6px;405
background: #EEE;407
&:hover {408
background: #CACACA;409
}410
}411
}413
.align {414
width: 100%;415
justify-content: flex-end;416
}417
}419
.bucket-list {420
display: flex;421
flex-wrap: wrap;422
width: 100%;423
list-style-type: none;425
.bucket {426
background: #EEE;427
border-radius: 9999px;428
margin: 5px;429
width: 60px;430
height: 60px;431
cursor: pointer;432
transition: transform 0.2s;433
box-shadow: 0 0px 8px 2px rgba(0, 0, 0, 0.05);435
transform: scale(0.9);436
user-select: none;438
&:hover {439
transition: transform 0.2s;440
transform: scale(1);441
}443
&.active {444
transform: scale(1);445
border: 3px solid #212121;446
}448
&::after {449
position: absolute;450
bottom: -20%;451
}452
}453
}454
}456
.toolbar {457
position: fixed;458
left: calc(50% - 210px);459
bottom: 30px;460
display: flex;461
z-index: 999;463
.bucket {464
width: 56px;465
height: 56px;466
border-radius: 9999px;467
background: #CCC;468
margin: 7px;469
transition: transform 0.2s;470
box-shadow: 0 0px 8px 2px rgba(0, 0, 0, 0.05);471
cursor: pointer;472
transform: scale(0.9);473
user-select: none;475
&:hover {476
transition: transform 0.2s;477
transform: scale(1);478
}480
&.active {481
transform: scale(1.1);482
}483
}484
}486
.actions {487
position: fixed;488
top: 30px;489
left: 30px;490
display: flex;491
}493
.action {494
user-select: none;495
position: relative;496
width: 46px;497
height: 46px;498
border: none;499
border-radius: 9999px;500
background: transparent;501
cursor: pointer;502
outline: none;503
position: fixed;504
margin-right: 8px;506
i {507
color: #212121;508
user-select: none;509
pointer-events: none;510
}512
&:hover {513
background: #ECECEC;514
}516
&::after {517
bottom: -60%;518
}519
}521
.tooltip {522
position: relative;523
display: flex;524
justify-content: center;525
align-items: center;527
&:hover {529
&::before {530
opacity: 1;531
transition-delay: 0.6s;532
}534
&::after {535
opacity: 1;536
transition-delay: 0.6s;537
}538
}540
&::after {541
display: flex;542
opacity: 0;543
content: attr(data-title);544
justify-content: center;545
align-items: center;546
position: absolute;547
background: #212121;548
color: white;549
min-height: 24px;550
padding: 0 10px;551
border-radius: 4px;552
font-size: 12px;553
top: auto;554
bottom: -70%;555
white-space: nowrap;556
z-index: 9999;557
pointer-events: none;558
}560
&.up {562
&::before {563
top: ~'calc(-90% + 26px)';564
bottom: auto;565
border-left: 6px solid transparent;566
border-right: 6px solid transparent;567
border-top: 6px solid #212121;568
border-bottom: none;569
}571
&::after {572
top: -60%;573
bottom: auto;574
}575
}577
&.down {579
&::before {580
top: auto;581
bottom: ~'calc(-90% + 26px)';582
border-left: 6px solid transparent;583
border-right: 6px solid transparent;584
border-top: none;585
border-bottom: 6px solid #212121;586
}588
&::after {589
top: auto;590
bottom: -60%;591
}592
}593
}