UNPKG

web-shared-folder

Version:

Web server for sharing folder on local network or Internet

353 lines (348 loc) 5.93 kB
:root { --main-bg-color-dark: #1e1e1e; --main-bg-color-light: white; --text-color-dark: #d4d4d4; --dragenter-color: rgb(182, 235, 160); } /*Блок, отвечающий за переключение темы (светлая, авто, тёмная)*/ .theme_selector { position: fixed; bottom: 1rem; right: 1rem; top: auto; padding: 0.125rem; margin: 0px; border: none; display: flex; width: 5rem; z-index: 1; } @media screen and (max-width: 900px) { .theme_selector { position: fixed; top: 90vh; bottom: auto; left: calc(100vw - 6rem); } } .theme_selector > label { pointer-events: none; padding: 0px; margin: 0px; opacity: 0; } .theme_selector > input { appearance: none; -webkit-appearance:none; width: 100%; height: 1rem; padding: 0px; margin: 0px; border: none; cursor: pointer; } .theme_selector > input:focus { outline: none; } .theme_selector > div { background-color: #d4d4d4; background-image: url("/wsf_app_files/circle.svg"); background-size: 1rem; background-repeat: no-repeat; background-position: center; border-radius: 0.5rem; position: absolute; top: 0px; bottom: 0px; left: 0px; right: 0px; z-index: -1; transition: background-position 0.1s linear; } .theme_selector > input:checked { filter: invert(100%); transition: filter 0.1s linear; } #radio-light-theme:checked ~ div { background-position: 0.125rem; } #radio-dark-theme:checked ~ div { background-position: calc(100% - 0.125rem); } #radio-light-theme { background-image: url("/wsf_app_files/sun.svg"); background-repeat: no-repeat; background-position: 11%; background-size: 0.85rem; } #radio-dark-theme { background-image: url("/wsf_app_files/moon.svg"); background-repeat: no-repeat; background-position: 75%; background-size: 0.4rem; } #radio-auto-theme { background-image: url("/wsf_app_files/auto.svg"); background-repeat: no-repeat; background-position: center; background-size: 0.5rem; } /*Конец блока, отвечающего за переключение темы*/ .main_container { display: inline-grid; grid-template-columns: minmax(200px, auto) repeat(2, minmax(100px, auto)); column-gap: 1rem; grid-auto-rows: minmax(1.5rem, auto); align-items: center; white-space: nowrap; margin-right: 1rem; } .main_container__head { display: flex; justify-content: space-between; padding-bottom: 1rem; } .main_container__head a { text-decoration: none; margin-left: 0.2rem; } .flex_right_icons { text-decoration: none; display: inline-block; margin-left: auto; width: 20px; height: 20px; background-size: contain; background-repeat: no-repeat; background-position: center; } .open-in-browser-icon { background-image: url("/wsf_app_files/eye.svg"); } .main_container__first_column { display: flex; justify-content: flex-start; flex-wrap: nowrap; column-gap: 0.2rem; } .error_message { color: tomato; } .header__controls { display: flex; flex-wrap: wrap; max-width: 25rem; justify-content: space-between; row-gap: 0.2rem; } .header__controls > * { width: 47%; } .header__stats { margin-top: 0.4rem; } .header { position: sticky; top: 0px; left: 0px; width: 100%; z-index: 1; } .hidden { display: none; } #select_form { outline: none; } .block_center { display: flex; justify-content: center; } @media screen and (max-width: 900px) { .main_container { grid-template-columns: max-content repeat(2, auto); } .header { position: static; } } /*---UPLOAD_SPLITTER---*/ .hidden_in_flow { visibility: hidden; } .unzip_icon { background-image: url("/wsf_app_files/unzip.svg"); } .footer { position: sticky; bottom: 0px; left: 0px; width: 100%; } .footer__controls { display: flex; flex-direction: column; row-gap: 0.5rem; min-width: max-content; } .footer__controls > progress { max-width: 100vw; width: 100%; } .footer__controls hr { width: 100%; margin-bottom: 0.2rem; } .footer__mk_dir_form { display: flex; justify-content: flex-start; column-gap: 0.2rem; } .footer__mk_dir_form input[name="dir"] { width: 100%; } .footer__dnd_placer { display: flex; justify-content: flex-start; flex-wrap: nowrap; align-items:center; } .footer__drag_and_drop { width:100%; align-self: stretch; margin-left: 0.5rem; border-radius: 1rem; border-style: dashed; border-width: 0.15rem; display: flex; align-items: center; justify-content: center; } .footer__drag_and_drop__dragenter { background-color: var(--dragenter-color); color: black; } .footer__drag_and_drop__while_upload { filter: contrast(0%); } .footer > div:last-child { height: 0.3rem; } .dialog p { text-align: center; } .dialog__buttons { display: flex; flex-wrap: nowrap; justify-content: space-around; margin-bottom: 0.5rem; min-width: 12rem; } .dialog__buttons button { min-width: 45%; } #upload_files + progress { max-width: 500px; } input[type="text"]:invalid { color: red; } .rename_button { width: 1.3rem; position: relative; } .rename_button > button { cursor: pointer; border: none; background: none; padding: 0px; width: 100%; height: 100%; } .rename_button > div { position: absolute; top: 0px; bottom: 0px; left: 0px; right: 0px; background-image: url("/wsf_app_files/rename.svg"); background-position: center; background-repeat: no-repeat; background-size: 0.9rem; z-index: -1; } @media screen and (max-width: 900px) { .footer { position: static; } .dialog { left: 0px; top: 0px; position: absolute; } #upload_files + progress { width: 90vw; max-width: 100%; align-self: center; } .footer__drag_and_drop { display: none; } }