diff options
| author | Armand Philippot <git@armandphilippot.com> | 2023-10-31 16:00:45 +0100 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2023-11-11 18:15:27 +0100 |
| commit | 3ff4c37a7a2c40340c17f9e6c1754444bce0f839 (patch) | |
| tree | 551ca3df148d46af2bd27995fa98c01378030644 /src/components/molecules/modals/tooltip/tooltip.module.scss | |
| parent | 0e52a59917406ad03c174e030c6c1c92ab23449d (diff) | |
refactor(components): rewrite Modal component
* add an optional close button
* add an icon prop
Diffstat (limited to 'src/components/molecules/modals/tooltip/tooltip.module.scss')
| -rw-r--r-- | src/components/molecules/modals/tooltip/tooltip.module.scss | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/src/components/molecules/modals/tooltip/tooltip.module.scss b/src/components/molecules/modals/tooltip/tooltip.module.scss new file mode 100644 index 0000000..8e6f877 --- /dev/null +++ b/src/components/molecules/modals/tooltip/tooltip.module.scss @@ -0,0 +1,46 @@ +@use "../../../../styles/abstracts/functions" as fun; +@use "../../../../styles/abstracts/mixins" as mix; +@use "../../../../styles/abstracts/variables" as var; + +.btn { + margin-right: var(--spacing-xs); +} + +.tooltip { + position: absolute; + z-index: 10; + font-size: var(--font-size-sm); + transition: all 0.75s ease-in-out 0s; + + @media screen and (max-height: #{var.get-breakpoint("2xs")}) { + width: calc(97.5vw - var(--spacing-md)); + right: 0; + } + + &--down { + top: calc(100% + var(--spacing-xs)); + transform-origin: top; + } + + &--up { + bottom: calc(100% + var(--spacing-2xs)); + transform-origin: bottom; + } + + &--hidden { + flex: 0 0 0; + opacity: 0; + visibility: hidden; + transform: scale(0); + } + + &--visible { + opacity: 1; + visibility: visible; + transform: scale(1); + } +} + +.heading { + font-size: var(--font-size-sm); +} |
