so://phie

outline

A web-based drawing app
git clone git://soophie.de/outline

blob: f7dbf6103292e2d933d073b004492f8cf0195cf3 (7071 bytes)[doc][blame][raw]

1canvas.canvas {

2 position: relative;

3 z-index: 1;

4 cursor: none;

5 touch-action: none;

6}

7

8canvas.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}

18

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}

34

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}

43

44@keyframes spin {

45 0% { transform: rotate(0deg); }

46 100% { transform: rotate(360deg); }

47}

48

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);

56

57 &.modal-error {

58 width: 300px;

59

60 .align {

61 justify-content: flex-end;

62 }

63 }

64

65 &.theme-dark {

66 background: @color-dark;

67 color: white;

68

69 button.action-cancel {

70 background: @color-dark-grey;

71 color: white;

72

73 &:hover {

74 background: lighten(@color-dark-grey, -2%);

75 }

76 }

77

78 input[type="text"] {

79 background: @color-black;

80 color: white;

81

82 &:hover {

83 background: lighten(@color-black, -2%);

84 }

85

86 &:focus {

87 background: lighten(@color-black, -2%);

88 }

89 }

90

91 .separator {

92 border-color: @color-dark-grey;

93 }

94

95 input[type="range"] {

96 background: lighten(@color-black, 2%);

97 }

98

99 .preview {

100 background: lighten(@color-black, 2%);

101 }

102

103 ul.avatar-list {

104

105 li.avatar {

106 border-color: @color-dark;

107 background: lighten(@color-black, 1%);

108

109 &:hover {

110 border-color: lighten(@color-black, 3.5%);

111 }

112 }

113 }

114 }

115

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;

125

126 &:hover {

127 background: #F8F8F8;

128 }

129

130 &:focus {

131 background: #F5F5F5;

132 }

133 }

134

135 .separator {

136 border-top: 1px solid #F5F5F5;

137 margin: 20px 0;

138 }

139

140 .align {

141 display: flex;

142 justify-content: space-between;

143 align-items: center;

144 }

145

146 p {

147 font-size: 18px;

148 letter-spacing: 0.2px;

149 padding-top: 5px;

150 margin-bottom: 25px;

151 }

152

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;

163

164 &:hover {

165 background: lighten(#F8F9FA, -5%);

166 }

167

168 &.success {

169 background: #28A745;

170 color: white;

171

172 &:hover {

173 background: lighten(#28A745, -5%);

174 }

175 }

176

177 &.danger {

178 background: #DC3545;

179 color: white;

180

181 &:hover {

182 background: lighten(#DC3545, -5%);

183 }

184 }

185

186 &.info {

187 background: #007BFF;

188 color: white;

189

190 &:hover {

191 background: lighten(#007BFF, -5%);

192 }

193 }

194 }

195

196 button.action-join {

197 width: 100%;

198 }

199

200 button.action-cancel {

201 width: calc(50% - 10px);

202 }

203

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 }

212

213 ul.avatar-list {

214 display: flex;

215 flex-wrap: wrap;

216 width: 100%;

217 list-style-type: none;

218

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;

228

229 &:hover {

230 border: 5px solid #F8F8F8;

231 }

232 }

233 }

234

235 input.action-range {

236 width: calc(100% - 80px);

237 -webkit-appearance: none;

238 background: #F8F8F8;

239 height: 6px;

240

241 &:hover {

242 background: #F5F5F5;

243

244 &::-webkit-slider-thumb {

245 background: lighten(#888888, -20%);

246 }

247 }

248

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 }

259

260 &::-webkit-slider-runnable-track {

261 -webkit-appearance: none;

262 }

263 }

264

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;

273

274 .circle {

275 width: 12px;

276 height: 12px;

277 background: #212121;

278 border-radius: 9999px;

279 }

280 }

281

282 &.modal-color {

283 width: 580px;

284

285 .align {

286 width: calc(100% - 200px);

287 margin-left: 200px;

288 justify-content: flex-end;

289 }

290 }

291

292 ul.bucket-list {

293 display: flex;

294 flex-wrap: wrap;

295 width: 100%;

296 list-style-type: none;

297

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);

307

308 transform: scale(0.9);

309 user-select: none;

310

311 &:hover {

312 transition: transform 0.2s;

313 transform: scale(1);

314 }

315

316 &.active {

317 transform: scale(1);

318 border: 3px solid #212121;

319 }

320

321 &::after {

322 position: absolute;

323 bottom: -20%;

324 }

325 }

326 }

327}

328

329.toolbar {

330 position: fixed;

331 left: calc(50% - 252px);

332 bottom: 30px;

333 z-index: 2;

334 display: flex;

335 z-index: 999;

336

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;

348

349 &:hover {

350 transition: transform 0.2s;

351 transform: scale(1);

352 }

353

354 &.active {

355 transform: scale(1.1);

356 }

357 }

358}

359

360.actions {

361 position: fixed;

362 top: 30px;

363 left: 30px;

364 display: flex;

365}

366

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;

379

380 i {

381 color: #212121;

382 user-select: none;

383 pointer-events: none;

384 }

385

386 &:hover {

387 background: #ECECEC;

388 }

389

390 &::after {

391 bottom: -60%;

392 }

393}

394

395.tooltip {

396 position: relative;

397 display: flex;

398 justify-content: center;

399 align-items: center;

400

401 &:hover {

402

403 &::before {

404 opacity: 1;

405 transition-delay: 0.6s;

406 }

407

408 &::after {

409 opacity: 1;

410 transition-delay: 0.6s;

411 }

412 }

413

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 }

433

434 &.up {

435

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 }

444

445 &::after {

446 top: -60%;

447 bottom: auto;

448 }

449 }

450

451 &.down {

452

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 }

461

462 &::after {

463 top: auto;

464 bottom: -60%;

465 }

466 }

467}