|
338 | 338 | opacity: 0; |
339 | 339 | } |
340 | 340 |
|
341 | | -.modal__add-btn { |
| 341 | +.modal-btn { |
342 | 342 | margin: 0; |
343 | 343 | border: none; |
344 | 344 | padding: 0; |
345 | | - font-family: var(--open-sans), sans-serif; |
346 | | - font-weight: var(--semi-bold); |
347 | | - font-size: var(--default-fs); |
348 | 345 | background: transparent; |
349 | 346 | outline: none; |
350 | | - overflow: hidden; |
351 | | - transition-property: color, background-color; |
352 | | - transition-duration: var(--short); |
353 | | - transition-timing-function: ease; |
354 | 347 | } |
355 | 348 |
|
356 | 349 | .modal__add-body-add-btn { |
357 | | - position: relative; |
358 | 350 | display: flex; |
359 | 351 | justify-content: flex-end; |
360 | 352 | align-items: center; |
| 353 | + position: relative; |
| 354 | + border: none; |
361 | 355 | padding: 10px 20px; |
362 | 356 | min-width: 191px; |
| 357 | + font-family: var(--open-sans), sans-serif; |
| 358 | + font-weight: var(--semi-bold); |
| 359 | + font-size: var(--default-fs); |
| 360 | + transition-property: color, background-color; |
| 361 | + transition-duration: 0.2s; |
| 362 | + transition-timing-function: ease; |
363 | 363 | } |
364 | 364 |
|
365 | | -.modal__add-body-add-btn:focus-visible:not(:hover) { |
366 | | - color: var(--cold-purple); |
| 365 | +.modal__add-body-add-btn::before, |
| 366 | +.modal__add-body-add-btn::after { |
| 367 | + content: ""; |
| 368 | + position: absolute; |
| 369 | + left: 20px; |
| 370 | + width: 19px; |
| 371 | + height: 19px; |
| 372 | + background-repeat: no-repeat; |
| 373 | + background-position: center; |
| 374 | + background-size: contain; |
| 375 | + transition: opacity 0.2s ease; |
367 | 376 | } |
368 | 377 |
|
369 | | -.modal__add-body-add-btn:focus-visible:not(:hover) .stroke-add-modal-icon { |
370 | | - opacity: 0; |
| 378 | +.modal__add-body-add-btn::before { |
| 379 | + background-image: url('../images/add-plus-stroke.svg'); |
| 380 | + opacity: 1; |
371 | 381 | } |
372 | 382 |
|
373 | | -.modal__add-body-add-btn:focus-visible:not(:hover) .fill-add-modal-icon { |
374 | | - opacity: 1; |
| 383 | +.modal__add-body-add-btn::after { |
| 384 | + background-image: url('../images/add-plus-fill.svg'); |
| 385 | + opacity: 0; |
375 | 386 | } |
376 | 387 |
|
377 | | -.modal__add-body-add-btn:focus-visible:active { |
378 | | - color: var(--light-purple); |
| 388 | +.modal__add-body-add-btn:focus-visible::before { |
| 389 | + opacity: 0; |
379 | 390 | } |
380 | 391 |
|
381 | | -.modal__add-body-add-btn:active:not(:disabled) { |
382 | | - color: var(--light-purple); |
| 392 | +.modal__add-body-add-btn:focus-visible::after { |
| 393 | + opacity: 1; |
383 | 394 | } |
384 | 395 |
|
385 | | -.modal__add-body-add-btn:active:not(:disabled) .stroke-add-modal-icon { |
| 396 | +.modal__add-body-add-btn:active::before { |
386 | 397 | opacity: 0; |
387 | 398 | } |
388 | 399 |
|
389 | | -.modal__add-body-add-btn:active:not(:disabled) .fill-add-modal-icon { |
| 400 | +.modal__add-body-add-btn:active::after { |
390 | 401 | opacity: 1; |
391 | 402 | } |
392 | 403 |
|
393 | | -.modal__add-body-add-btn:disabled .stroke-add-modal-icon { |
| 404 | +.modal__add-body-add-btn:disabled::before { |
394 | 405 | opacity: 0; |
395 | 406 | } |
396 | 407 |
|
397 | | -.modal__add-body-add-btn:disabled .stroke-gray-add-modal-icon { |
| 408 | +.modal__add-body-add-btn:disabled::after { |
| 409 | + background-image: url('../images/add-plus-stroke-gray.svg'); |
398 | 410 | opacity: 1; |
399 | 411 | } |
400 | 412 |
|
401 | | -.add-modal-btn-margin { |
402 | | - margin-bottom: 15px; |
403 | | -} |
404 | | - |
405 | | -.modal__add-body-btn-icon { |
406 | | - position: absolute; |
407 | | - left: 20px; |
408 | | - width: 19px; |
409 | | - height: 19px; |
410 | | - transition: opacity var(--short) ease; |
| 413 | +.modal__add-body-add-btn:focus-visible:not(:hover) { |
| 414 | + color: var(--cold-purple); |
411 | 415 | } |
412 | 416 |
|
413 | | -.stroke-add-modal-icon { |
414 | | - background: url("../images/add-plus-stroke.svg") no-repeat center / contain; |
415 | | - opacity: 1; |
| 417 | +.modal__add-body-add-btn:focus-visible:active { |
| 418 | + color: var(--light-purple); |
416 | 419 | } |
417 | 420 |
|
418 | | -.stroke-gray-add-modal-icon { |
419 | | - background: url("../images/add-plus-stroke-gray.svg") no-repeat center / contain; |
420 | | - opacity: 0; |
| 421 | +.modal__add-body-add-btn:active:not(:disabled) { |
| 422 | + color: var(--light-purple); |
421 | 423 | } |
422 | 424 |
|
423 | | -.fill-add-modal-icon { |
424 | | - background: url("../images/add-plus-fill.svg") no-repeat center / contain; |
425 | | - opacity: 0; |
| 425 | +.add-modal-btn-margin { |
| 426 | + margin-bottom: 15px; |
426 | 427 | } |
427 | 428 |
|
428 | 429 | .modal__add-body-save-btn { |
|
432 | 433 | max-width: 150px; |
433 | 434 | color: var(--white); |
434 | 435 | background-color: var(--main-purple); |
| 436 | + transition-property: color, background-color; |
| 437 | + transition-duration: 0.2s; |
| 438 | + transition-timing-function: ease; |
435 | 439 | } |
436 | 440 |
|
437 | 441 | .modal__add-body-save-btn:focus-visible:not(:hover) { |
|
471 | 475 | /* media queries, any-hover */ |
472 | 476 |
|
473 | 477 | @media (any-hover: hover) { |
474 | | - .modal__add-body-add-btn:hover:not(:active):not(:disabled) { |
475 | | - color: var(--cold-purple); |
476 | | - } |
477 | | - |
478 | | - .modal__add-body-add-btn:hover:not(:active):not(:disabled) .stroke-add-modal-icon { |
| 478 | + .modal__add-body-add-btn:hover:not(:active):not(:disabled)::before { |
479 | 479 | opacity: 0; |
480 | 480 | } |
481 | 481 |
|
482 | | - .modal__add-body-add-btn:hover:not(:active):not(:disabled) .fill-add-modal-icon { |
| 482 | + .modal__add-body-add-btn:hover:not(:active):not(:disabled)::after { |
| 483 | + background-image: url('../images/add-plus-fill.svg'); |
483 | 484 | opacity: 1; |
484 | 485 | } |
485 | 486 |
|
| 487 | + .modal__add-body-add-btn:hover:not(:active):not(:disabled) { |
| 488 | + color: var(--cold-purple); |
| 489 | + } |
| 490 | + |
486 | 491 | .modal__add-body-add-contact-item:hover:not(:active) { |
487 | 492 | background-color: var(--select-gray); |
488 | 493 | } |
|
0 commit comments