Files
logseq/src/main/frontend/ui.css

308 lines
6.0 KiB
CSS

#ui__ac {
&-inner {
overflow-x: hidden;
overflow-y: auto;
position: relative;
-webkit-overflow-scrolling: touch;
.menu-link {
@apply break-all rounded;
.has-help {
display: flex;
align-items: center;
justify-content: space-between;
small {
@apply cursor-help visible flex;
svg {
@apply opacity-30 hover:opacity-90;
}
}
}
&:hover, &.chosen {
background-color: var(--lx-gray-04, var(--ls-menu-hover-color, hsl(var(--secondary))));
.has-help small {
visibility: visible;
}
}
&:not(.chosen):hover {
background-color: unset !important;
color: var(--lx-gray-12, var(--ls-primary-text-color, hsl(var(--secondary))));
}
}
}
}
.menu-link {
&.no-padding {
padding: 0 !important;
}
}
.ui__ac-group-name {
@apply p-2 text-xs text-popover-foreground/20 font-medium;
}
.search-all #ui__ac-inner {
max-height: none;
}
.ui__notifications {
position: fixed;
z-index: var(--ls-z-index-level-4);
width: 100%;
top: 3.2em;
pointer-events: none;
&-content {
@apply inset-0 flex items-end justify-center px-4 py-3
pointer-events-none sm:px-6 sm:py-3 sm:items-start
sm:justify-end;
}
.notification-area {
@apply border;
background-color: or(--ls-notification-background, --lx-gray-03, --ls-tertiary-background-color, --rx-gray-03);
color: or(--ls-notification-text-color, --lx-gray-11, --ls-primary-text-color, --rx-gray-11);
&:has(.ls-wrap-widen) {
@apply w-[680px] max-w-[96vw];
}
}
}
.ui__toggle {
.wrapper {
@apply relative flex-shrink-0
h-6 w-11 border-2 border-transparent flex
rounded-full cursor-pointer focus:outline-none;
}
.switcher {
@apply inline-block h-5 w-5 rounded-full bg-white shadow;
}
&.is-small {
.wrapper {
@apply h-4 w-8;
}
.switcher {
@apply h-3 w-3;
}
}
}
.ui__modal {
@apply fixed px-4 pb-4 inset-0 flex items-baseline justify-center
top-12 sm:top-[calc(3vh+50px)];
&-overlay {
@apply fixed inset-0;
}
&-overlay div {
--from: or(--ls-modal-overlay-gradient-start, --lx-gray-03, --ls-primary-background-color);
--to: or(--ls-modal-overlay-gradient-end, --lx-gray-06, --ls-quaternary-background-color);
background-image: linear-gradient(to bottom, var(--from), var(--to));
}
&-panel {
@apply relative rounded-md shadow-lg border border-gray-06 overflow-hidden;
background: var(--lx-gray-02, var(--ls-secondary-background-color, hsl(var(--popover))));
.panel-content {
overflow-y: auto;
overflow-x: hidden;
width: calc(96vw - 2rem);
max-height: 89vh;
padding: 2rem 1.5rem;
@screen sm {
overflow-y: overlay;
max-height: 85vh;
padding: 2rem;
width: auto;
min-width: 600px;
.ls-card,
.ls-search {
width: 740px;
}
.ls-card {
min-height: 60vh;
}
.ls-search {
width: var(--ls-main-content-max-width);
}
}
@screen md {
min-width: 720px;
}
}
}
&-close {
@apply text-gray-400 hover:text-gray-500
focus:outline-none focus:text-gray-500
transition ease-in-out duration-150 opacity-60
hover:opacity-100;
&-wrap {
@apply z-10 absolute top-0 right-0 pt-2 pr-2;
}
}
}
.ui__dialog-content {
&[label=flashcards__cp] {
.ui__dialog-main-content {
@apply max-h-[85vh] overflow-auto;
}
}
}
.instruction {
height: 40%;
@screen sm {
height: 70%;
}
}
html.is-native-android,
html.is-native-iphone,
html.is-native-iphone-without-notch {
.references {
.blocks-container {
transform: translateX(-8px);
width: 104%;
}
}
.ls-card {
min-height: 65vh;
}
}
html.is-mobile {
.ui__modal {
@apply bottom-0 inset-x-0 top-20;
&[label="ls-modal-search"] {
.panel-content {
padding-bottom: 0;
}
.ls-search {
padding-bottom: 0;
}
}
}
}
.dropdown-wrapper {
@apply border min-w-[12rem] rounded-md bg-popover overflow-hidden;
.menu-links-wrapper {
@apply border-0;
}
}
.dropdown-caret {
display: inline-block;
width: 0;
height: 0;
vertical-align: middle;
content: '';
border-top-style: solid;
border-top-width: 4px;
border-right: 4px solid transparent;
border-bottom: 0 solid transparent;
border-left: 4px solid transparent;
}
.form-select {
@apply block w-full pl-3 pr-10 py-2 text-base leading-6 rounded border-gray-06;
@apply focus:border-gray-04 focus:ring-2 focus:ring-ring focus:ring-offset-2 sm:text-sm sm:leading-5;
background-color: var(--lx-gray-03, var(--ls-primary-background-color, transparent));
background-repeat: no-repeat;
&.is-small {
@apply pl-2 py-1.5 sm:leading-[15px] sm:text-xs;
}
}
.form-input {
@apply block w-full mt-1 pl-2 sm:text-sm sm:leading-5 rounded bg-background border border-gray-07;
&.is-small {
@apply py-1.5 sm:leading-4 sm:text-xs;
}
}
.rotating-arrow.not-collapsed svg {
transform: rotate(90deg);
}
.rotating-arrow svg {
transition: all 100ms ease-in 0ms;
}
.bg-quaternary {
background-color: or(--ls-bg-quaternary, --lx-gray-06, --ls-quaternary-background-color);
}
.ui__icon {
display: inline-block;
}
.type-icon {
@apply text-base text-center flex items-center justify-center rounded border mr-2 relative;
width: 24px;
height: 24px;
flex-shrink: 0;
border-color: var(--lx-gray-03, var(--ls-primary-background-color));
overflow: hidden;
color: var(--lx-gray-12, var(--ls-primary-text-color));
.ti,
.tie {
z-index: 1;
}
&:before {
@apply block absolute inset-0 ;
background: var(--lx-gray-03, var(--ls-primary-background-color));
content: " ";
}
}
.ui__radio-list {
@apply grid grid-flow-col gap-2;
}
.ui__toggle-background-on {
@apply bg-primary;
}
.ui__toggle-background-off {
background: var(--lx-gray-08, rgb(212, 212, 212));
}
input[type='range'] {
accent-color: var(--lx-accent-10, var(--rx-blue-10));
}