mirror of
https://github.com/codex-team/editor.js
synced 2024-06-04 15:02:42 +02:00
758c5080df
* Add tooltip * styles updated * updates * Update CHANGELOG.md * rm map * update * upd pkg
81 lines
1.5 KiB
CSS
81 lines
1.5 KiB
CSS
.ce-toolbox {
|
|
position: absolute;
|
|
visibility: hidden;
|
|
transition: opacity 100ms ease;
|
|
will-change: opacity;
|
|
display: flex;
|
|
flex-direction: row;
|
|
|
|
@media (--mobile){
|
|
position: static;
|
|
transform: none !important;
|
|
align-items: center;
|
|
visibility: visible !important;
|
|
}
|
|
|
|
&--opened {
|
|
opacity: 1;
|
|
visibility: visible;
|
|
}
|
|
|
|
&__button {
|
|
@apply --toolbox-button;
|
|
}
|
|
|
|
&__tooltip {
|
|
position: absolute;
|
|
top: 43px;
|
|
padding: 6px 10px;
|
|
transform: translateX(-50%);
|
|
border-radius: 5px;
|
|
line-height: 21px;
|
|
opacity: 0;
|
|
background: var(--bg-light);
|
|
box-shadow: 0 10px 12px -9px rgba(26, 39, 54, 0.32), 0 3px 2px -2px rgba(33, 48, 73, 0.05);
|
|
color: #5C6174;
|
|
font-size: 12px;
|
|
text-align: center;
|
|
user-select: none;
|
|
pointer-events: none;
|
|
transition: opacity 150ms ease-in, left 0.1s linear;
|
|
will-change: opacity, left;
|
|
letter-spacing: 0.02em;
|
|
line-height: 1em;
|
|
|
|
&-shortcut {
|
|
color: rgba(100, 105, 122, 0.6);
|
|
word-spacing: -2px;
|
|
margin-top: 5px;
|
|
}
|
|
|
|
&--shown {
|
|
opacity: 1;
|
|
transition-delay: 0.1s, 0s;
|
|
}
|
|
|
|
&::before {
|
|
content: '';
|
|
width: 10px;
|
|
height: 10px;
|
|
position: absolute;
|
|
top: -5px;
|
|
left: 50%;
|
|
margin-left: -5px;
|
|
transform: rotate(-45deg);
|
|
background-color: var(--bg-light);
|
|
z-index: -1;
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
/**
|
|
* Styles for Narrow mode
|
|
*/
|
|
.codex-editor--narrow .ce-toolbox {
|
|
@media (--not-mobile) {
|
|
background: #fff;
|
|
z-index: 2;
|
|
}
|
|
}
|