| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528 |
- .fake-full-width-bg(@bg-color) {
- &::before {
- content: '\00a0';
- position: absolute;
- width: 100%;
- right: 100%;
- background-color: @bg-color;
- }
- }
- .editor-sidebar {
- display: flex;
- flex-direction: column;
- background-color: @file-tree-bg;
- }
- .file-tree {
- display: flex !important; // To work around jQuery layout's inline styles
- flex-direction: column;
- flex-grow: 1;
- max-height: 100%;
- .toolbar.toolbar-filetree {
- .toolbar-small-mixin;
- .toolbar-alt-mixin;
- padding: 0 5px;
- flex-shrink: 0;
- }
- > file-tree-root,
- .file-tree-inner {
- position: relative;
- display: flex;
- flex-direction: column;
- flex-grow: 1;
- overflow-y: auto;
- width: inherit;
- height: inherit;
- &.no-toolbar {
- top: 0;
- }
- }
- // TODO; Consolidate with "Project files" in Overleaf
- h3 {
- font-size: 1rem;
- border-bottom: 1px solid @gray;
- padding-bottom: (@line-height-computed / 4);
- margin: (@line-height-computed / 2);
- }
- &-history {
- .entity-name {
- padding-left: 6px;
- &.deleted {
- text-decoration: line-through;
- }
- }
- .loading {
- padding-left: 6px;
- color: #fff;
- i.fa {
- color: #fff;
- }
- }
- }
- li.dnd-droppable-hover .entity-name,
- li .entity-name.droppable-hover {
- font-weight: bold;
- background-color: @file-tree-item-hover-bg;
- .fake-full-width-bg(@file-tree-item-hover-bg);
- }
- ul.droppable-hover li div.entity-name:hover {
- background-color: transparent;
- .fake-full-width-bg(transparent);
- &.droppable-hover {
- background-color: @file-tree-item-hover-bg;
- .fake-full-width-bg(@file-tree-item-hover-bg);
- }
- }
- ul.file-tree-list {
- margin: 0;
- overflow-x: hidden;
- height: 100%;
- flex-grow: 1;
- position: relative;
- overflow-y: auto;
- .entity > ul,
- ul[role='tree'] {
- margin-left: 22px;
- }
- &::after {
- content: '';
- display: block;
- min-height: @line-height-computed;
- }
- li {
- line-height: @file-tree-line-height;
- position: relative;
- &:focus {
- outline: none;
- }
- .entity {
- user-select: none;
- &:focus {
- outline: none;
- }
- }
- .entity > .entity-name > button {
- background-color: transparent;
- border: 0;
- padding: 0;
- &:focus {
- outline: none;
- }
- &.item-name-button {
- width: 100%;
- overflow: hidden;
- text-overflow: ellipsis;
- text-align: left;
- padding-right: 32px;
- }
- }
- .entity-name {
- color: @file-tree-item-color;
- cursor: pointer;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- &.entity-name-react {
- text-overflow: clip;
- }
- &:focus {
- outline: none;
- }
- &:hover {
- background-color: @file-tree-item-hover-bg;
- }
- &:hover {
- // When the entity is a subfolder, the DOM element is "indented" via margin-left. This makes the
- // element not fill the entire file-tree width (as it's spaced from the left-hand side via margin)
- // and, in consequence, the background gets clipped. The ::before pseudo-selector is used to fill
- // the empty space.
- .fake-full-width-bg(@file-tree-item-hover-bg);
- }
- input {
- line-height: 1.6;
- }
- .entity-menu-toggle > i {
- color: white;
- font-size: 18px;
- }
- }
- .entity.dnd-draggable-dragging {
- .entity-name:hover {
- background-color: transparent;
- .fake-full-width-bg(transparent);
- }
- }
- i.fa {
- color: @file-tree-item-icon-color;
- font-size: 14px;
- &.file-tree-icon {
- margin-right: 4px;
- margin-left: 8px;
- &.linked-file-icon {
- position: relative;
- left: -2px;
- + .linked-file-highlight {
- & {
- color: inherit;
- }
- position: relative;
- top: 4px;
- width: 0;
- left: -5px;
- font-size: 12px;
- }
- }
- }
- &.file-tree-folder-icon {
- margin-right: 4px;
- }
- &.file-tree-expand-icon {
- margin-left: 8px;
- }
- }
- i.fa-folder-open,
- i.fa-folder {
- color: @file-tree-item-folder-color;
- font-size: 14px;
- }
- i.toggle {
- width: 24px;
- padding: 6px;
- font-size: 16px;
- color: @file-tree-item-toggle-color;
- }
- .file-tree-dropdown-toggle {
- display: flex;
- align-items: center;
- color: #fff;
- line-height: 1.6;
- font-size: 20px;
- padding: 0 4px 0 18px;
- &:hover,
- &:focus {
- text-decoration: none;
- }
- &::before {
- content: '\00B7\00B7\00B7';
- transform: rotate(90deg);
- letter-spacing: 0.5px;
- }
- }
- &.multi-selected {
- > .entity {
- > .entity-name {
- > div > i.fa,
- > button > i.fa,
- > i.fa,
- .entity-menu-toggle i.fa {
- color: #fff;
- }
- > i.linked-file-highlight {
- color: @blue;
- }
- color: #fff;
- font-weight: bold;
- background-color: @file-tree-multiselect-bg;
- .fake-full-width-bg(@file-tree-multiselect-bg);
- &:hover {
- background-color: @file-tree-multiselect-hover-bg;
- .fake-full-width-bg(@file-tree-multiselect-hover-bg);
- }
- }
- }
- }
- .menu-button {
- position: absolute;
- right: 0;
- top: 3px;
- }
- .rename-input {
- display: block;
- position: absolute;
- top: 1px;
- left: 32px;
- right: 32px;
- color: @file-tree-item-input-color;
- input {
- width: 100%;
- }
- }
- > .entity > .entity-name {
- .entity-menu-toggle {
- display: none;
- }
- }
- .entity-limit-hit {
- color: @file-tree-item-color;
- line-height: 2.05;
- margin-left: (@line-height-computed / 2);
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
- .entity-limit-hit-message {
- font-style: italic;
- }
- i.fa.entity-limit-hit-tooltip-trigger {
- margin-left: (@line-height-computed / 4);
- cursor: pointer;
- }
- }
- }
- &:not(.multi-selected) {
- ul.file-tree-list li.selected {
- > .entity {
- > .entity-name {
- color: @file-tree-item-selected-color;
- > div > i.fa,
- > button > i.fa,
- > i.fa,
- .entity-menu-toggle i.fa {
- color: @file-tree-item-selected-color;
- }
- > i.linked-file-highlight {
- color: @blue;
- }
- background-color: @file-tree-item-selected-bg;
- font-weight: bold;
- padding-right: 32px;
- .fake-full-width-bg(@file-tree-item-selected-bg);
- .entity-menu-toggle {
- display: inline-block;
- background-color: transparent;
- box-shadow: none;
- border: 0;
- }
- }
- }
- }
- ul.file-tree-list li.selected.dnd-droppable-hover {
- > .entity {
- > .entity-name {
- background-color: @file-tree-item-hover-bg;
- .fake-full-width-bg(@file-tree-item-hover-bg);
- }
- }
- }
- }
- .dnd-draggable-preview-layer {
- position: absolute;
- pointer-events: none;
- z-index: 100;
- width: 100%;
- height: 100%;
- overflow: hidden;
- &.dnd-droppable-hover {
- border: 3px solid @file-tree-item-selected-bg;
- }
- }
- .dnd-draggable-preview-item,
- .ui-draggable-dragging {
- background-color: fade(@file-tree-item-selected-bg, 60%);
- color: @file-tree-item-selected-color;
- width: 75%;
- padding-left: @line-height-computed;
- }
- .dnd-draggable-preview-item {
- line-height: @file-tree-line-height;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- }
- .disconnected-overlay {
- position: absolute;
- top: 0;
- left: 0;
- width: 100%;
- height: 100%;
- z-index: 10;
- background: @file-tree-bg;
- opacity: 0.5;
- cursor: wait;
- }
- }
- .modal-new-file {
- padding: 0;
- table {
- width: 100%;
- td {
- vertical-align: top;
- }
- }
- /* old modal */
- .toggle-output-files-button {
- font-size: 80%;
- }
- /* new modal */
- .toggle-file-type-button {
- font-size: 80%;
- margin-top: -12px;
- .btn {
- display: inline-block;
- padding: 0;
- vertical-align: baseline;
- font-size: inherit;
- }
- .btn:focus-within {
- outline: none;
- text-decoration: none;
- }
- }
- }
- .modal-new-file--list {
- background-color: @modal-footer-background-color;
- width: 220px;
- ul {
- li {
- /* old modal (a) */
- a {
- color: @text-color;
- padding: (@line-height-computed / 4);
- display: block;
- text-decoration: none;
- }
- /* new modal (button) */
- .btn {
- color: @text-color;
- padding: (@line-height-computed / 4);
- }
- .btn:hover {
- text-decoration: none;
- }
- .btn:focus {
- outline: none;
- text-decoration: none;
- background-color: white;
- }
- }
- li.active {
- background-color: white;
- /* old modal (a) */
- a {
- color: @link-color;
- }
- /* new modal (button) */
- .btn {
- color: @link-color;
- text-decoration: none;
- }
- }
- li:hover {
- background-color: white;
- }
- }
- }
- .file-tree-error {
- text-align: center;
- color: @file-tree-error-color;
- padding: 20px;
- }
- .file-tree-modal-alert {
- margin-top: 10px;
- margin-bottom: 0px;
- }
- .btn.modal-new-file-mode {
- text-align: left;
- }
- .modal-new-file--body {
- padding: 20px;
- padding-top: (@line-height-computed / 4);
- }
- .modal-new-file--body-upload {
- padding-top: 20px;
- }
- .modal-new-file--body-conflict {
- background-color: @red-10;
- border: 1px dashed @red-50;
- min-height: 400px;
- border-radius: 3px;
- color: @neutral-90;
- display: flex;
- flex-direction: column;
- justify-content: center;
- padding: @padding-sm;
- }
- .modal-footer {
- .approaching-file-limit {
- font-weight: bold;
- }
- .at-file-limit {
- text-align: left;
- }
- }
- .modal-new-file--body-upload .uppy-Root {
- font-family: inherit;
- }
- .modal-new-file--body-upload .uppy-Dashboard {
- .uppy-Dashboard-inner {
- border: none;
- }
- .uppy-Dashboard-dropFilesHereHint {
- top: 0;
- bottom: 0;
- left: 0;
- right: 0;
- }
- .uppy-Dashboard-AddFiles {
- margin: 0;
- border: 1px dashed @neutral-60;
- height: 100%;
- .uppy-Dashboard-AddFiles-title {
- font-size: inherit;
- }
- }
- }
|