App.vue 38 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146
  1. <script setup lang="ts">
  2. import { useRouter } from "vue-router";
  3. import { defineAsyncComponent, ref, watch, onMounted } from "vue";
  4. import Toast from "toasters";
  5. import { storeToRefs } from "pinia";
  6. import { GenericResponse } from "@musare_types/actions/GenericActions";
  7. import { GetPreferencesResponse } from "@musare_types/actions/UsersActions";
  8. import { useWebsocketsStore } from "@/stores/websockets";
  9. import { useConfigStore } from "@/stores/config";
  10. import { useUserAuthStore } from "@/stores/userAuth";
  11. import { useUserPreferencesStore } from "@/stores/userPreferences";
  12. import { useModalsStore } from "@/stores/modals";
  13. import aw from "@/aw";
  14. import keyboardShortcuts from "@/keyboardShortcuts";
  15. const ModalManager = defineAsyncComponent(
  16. () => import("@/components/ModalManager.vue")
  17. );
  18. const LongJobs = defineAsyncComponent(
  19. () => import("@/components/LongJobs.vue")
  20. );
  21. const BannedPage = defineAsyncComponent(() => import("@/pages/Banned.vue"));
  22. const FallingSnow = defineAsyncComponent(
  23. () => import("@/components/FallingSnow.vue")
  24. );
  25. const router = useRouter();
  26. const { socket } = useWebsocketsStore();
  27. const configStore = useConfigStore();
  28. const userAuthStore = useUserAuthStore();
  29. const userPreferencesStore = useUserPreferencesStore();
  30. const modalsStore = useModalsStore();
  31. const socketConnected = ref(true);
  32. const keyIsDown = ref("");
  33. const broadcastChannel = ref({
  34. user_login: null,
  35. nightmode: null
  36. });
  37. const disconnectedMessage = ref();
  38. const { christmas } = storeToRefs(configStore);
  39. const { loggedIn, banned } = storeToRefs(userAuthStore);
  40. const { nightmode, activityWatch } = storeToRefs(userPreferencesStore);
  41. const {
  42. changeNightmode,
  43. changeAutoSkipDisliked,
  44. changeActivityLogPublic,
  45. changeAnonymousSongRequests,
  46. changeActivityWatch
  47. } = userPreferencesStore;
  48. const { activeModals } = storeToRefs(modalsStore);
  49. const { openModal, closeCurrentModal } = modalsStore;
  50. const toggleNightMode = () => {
  51. if (loggedIn.value) {
  52. socket.dispatch(
  53. "users.updatePreferences",
  54. { nightmode: !nightmode.value },
  55. (res: GenericResponse) => {
  56. if (res.status !== "success") new Toast(res.message);
  57. }
  58. );
  59. } else {
  60. broadcastChannel.value.nightmode.postMessage(!nightmode.value);
  61. }
  62. };
  63. const enableNightmode = () => {
  64. document.getElementsByTagName("html")[0].classList.add("night-mode");
  65. };
  66. const disableNightmode = () => {
  67. document.getElementsByTagName("html")[0].classList.remove("night-mode");
  68. };
  69. const enableChristmasMode = () => {
  70. document.getElementsByTagName("html")[0].classList.add("christmas-mode");
  71. };
  72. const disableChristmasMode = () => {
  73. document.getElementsByTagName("html")[0].classList.remove("christmas-mode");
  74. };
  75. watch(socketConnected, connected => {
  76. if (!connected && !userAuthStore.banned) disconnectedMessage.value.show();
  77. else disconnectedMessage.value.hide();
  78. });
  79. watch(banned, () => {
  80. disconnectedMessage.value.hide();
  81. });
  82. watch(nightmode, enabled => {
  83. if (enabled) enableNightmode();
  84. else disableNightmode();
  85. });
  86. watch(activityWatch, enabled => {
  87. if (enabled) aw.enable();
  88. else aw.disable();
  89. });
  90. watch(christmas, enabled => {
  91. if (enabled) enableChristmasMode();
  92. else disableChristmasMode();
  93. });
  94. onMounted(async () => {
  95. document.getElementsByTagName("html")[0].style.cssText =
  96. `--primary-color: ${configStore.primaryColor}`;
  97. window
  98. .matchMedia("(prefers-color-scheme: dark)")
  99. .addEventListener("change", e => {
  100. if (e.matches === !nightmode.value) changeNightmode(true);
  101. });
  102. disconnectedMessage.value = new Toast({
  103. content: "Could not connect to the server.",
  104. persistent: true,
  105. interactable: false
  106. });
  107. disconnectedMessage.value.hide();
  108. socket.onConnect(() => {
  109. socketConnected.value = true;
  110. document.getElementsByTagName("html")[0].style.cssText =
  111. `--primary-color: ${configStore.primaryColor}`;
  112. if (!loggedIn.value) {
  113. broadcastChannel.value.user_login = new BroadcastChannel(
  114. `${configStore.cookie}.user_login`
  115. );
  116. broadcastChannel.value.user_login.onmessage = res => {
  117. if (res.data) {
  118. broadcastChannel.value.user_login.close();
  119. window.location.reload();
  120. }
  121. };
  122. broadcastChannel.value.nightmode = new BroadcastChannel(
  123. `${configStore.cookie}.nightmode`
  124. );
  125. broadcastChannel.value.nightmode.onmessage = res => {
  126. changeNightmode(!!res.data);
  127. };
  128. }
  129. document.onkeydown = (ev: KeyboardEvent) => {
  130. const event = ev || window.event;
  131. const { keyCode } = event;
  132. const shift = event.shiftKey;
  133. const ctrl = event.ctrlKey;
  134. const alt = event.altKey;
  135. const identifier = `${keyCode}.${shift}.${ctrl}`;
  136. if (keyIsDown.value === identifier) return;
  137. keyIsDown.value = identifier;
  138. keyboardShortcuts.handleKeyDown(event, keyCode, shift, ctrl, alt);
  139. };
  140. document.onkeyup = () => {
  141. keyIsDown.value = "";
  142. };
  143. // ctrl + alt + n
  144. keyboardShortcuts.registerShortcut("nightmode", {
  145. keyCode: 78,
  146. ctrl: true,
  147. alt: true,
  148. handler: () => toggleNightMode()
  149. });
  150. keyboardShortcuts.registerShortcut("closeModal", {
  151. keyCode: 27,
  152. shift: false,
  153. ctrl: false,
  154. handler: () => {
  155. if (Object.keys(activeModals.value).length !== 0)
  156. closeCurrentModal();
  157. }
  158. });
  159. socket.dispatch(
  160. "users.getPreferences",
  161. (res: GetPreferencesResponse) => {
  162. if (res.status === "success") {
  163. const { preferences } = res.data;
  164. changeAutoSkipDisliked(preferences.autoSkipDisliked);
  165. changeNightmode(preferences.nightmode);
  166. changeActivityLogPublic(preferences.activityLogPublic);
  167. changeAnonymousSongRequests(
  168. preferences.anonymousSongRequests
  169. );
  170. changeActivityWatch(preferences.activityWatch);
  171. }
  172. }
  173. );
  174. openModal("whatIsNew");
  175. router.isReady().then(() => {
  176. if (
  177. configStore.githubAuthentication &&
  178. localStorage.getItem("github_redirect")
  179. ) {
  180. router.push(localStorage.getItem("github_redirect"));
  181. localStorage.removeItem("github_redirect");
  182. }
  183. });
  184. }, true);
  185. socket.onDisconnect(() => {
  186. socketConnected.value = false;
  187. }, true);
  188. socket.on("keep.event:user.session.deleted", () =>
  189. window.location.reload()
  190. );
  191. if (localStorage.getItem("nightmode") === "true") {
  192. changeNightmode(true);
  193. } else changeNightmode(false);
  194. });
  195. </script>
  196. <template>
  197. <div class="upper-container">
  198. <banned-page v-if="banned" />
  199. <div v-else class="upper-container">
  200. <router-view :key="$route.fullPath" class="main-container" />
  201. </div>
  202. <falling-snow v-if="christmas" />
  203. <modal-manager />
  204. <long-jobs />
  205. </div>
  206. </template>
  207. <style lang="less">
  208. @import "normalize.css/normalize.css";
  209. @import "tippy.js/dist/tippy.css";
  210. @import "tippy.js/animations/scale.css";
  211. @import "vue-draggable-list/dist/style.css";
  212. :root {
  213. --primary-color: var(--blue);
  214. --blue: rgb(2, 166, 242);
  215. --light-blue: rgb(163, 224, 255);
  216. --dark-blue: rgb(0, 102, 244);
  217. --teal: rgb(0, 209, 178);
  218. --purple: rgb(143, 40, 140);
  219. --light-purple: rgb(170, 141, 216);
  220. --yellow: rgb(241, 196, 15);
  221. --light-pink: rgb(228, 155, 166);
  222. --dark-pink: rgb(234, 72, 97);
  223. --orange: rgb(255, 94, 0);
  224. --dark-orange: rgb(250, 50, 0);
  225. --green: rgb(68, 189, 50);
  226. --red: rgb(231, 77, 60);
  227. --dark-red: rgb(235, 41, 19);
  228. --white: rgb(255, 255, 255);
  229. --black: rgb(0, 0, 0);
  230. --light-grey: rgb(245, 245, 245);
  231. --light-grey-2: rgb(221, 221, 221);
  232. --light-grey-3: rgb(195, 193, 195);
  233. --grey: rgb(107, 107, 107);
  234. --grey-2: rgb(113, 113, 113);
  235. --grey-3: rgb(126, 126, 126);
  236. --dark-grey: rgb(77, 77, 77);
  237. --dark-grey-2: rgb(51, 51, 51);
  238. --dark-grey-3: rgb(34, 34, 34);
  239. --dark-grey-4: rgb(26, 26, 26);
  240. --youtube: rgb(189, 46, 46);
  241. --soundcloud: rgb(242, 111, 35);
  242. --spotify: rgb(30, 215, 96);
  243. }
  244. .night-mode {
  245. body {
  246. background-color: var(--black) !important;
  247. }
  248. div {
  249. color: var(--light-grey-2);
  250. }
  251. .input,
  252. .textarea,
  253. .select select {
  254. background-color: var(--dark-grey);
  255. border-color: var(--grey-3);
  256. color: var(--white);
  257. &::placeholder {
  258. color: var(--light-grey-3);
  259. }
  260. }
  261. .control.has-addons .button {
  262. background-color: var(--dark-grey-2);
  263. border: 0;
  264. i {
  265. color: var(--white);
  266. }
  267. }
  268. h1,
  269. h2,
  270. h3,
  271. h4,
  272. h5,
  273. h6 {
  274. color: var(--white) !important;
  275. }
  276. p:not(.help),
  277. label,
  278. .label {
  279. color: var(--light-grey-2) !important;
  280. }
  281. .section,
  282. .content {
  283. background-color: var(--dark-grey-3) !important;
  284. }
  285. .content-box,
  286. .step:not(.selected) {
  287. background-color: var(--dark-grey-3) !important;
  288. }
  289. .tippy-box[data-theme~="songActions"] {
  290. background-color: var(--dark-grey);
  291. }
  292. code {
  293. background-color: var(--dark-grey-2) !important;
  294. }
  295. .button.is-dark {
  296. background-color: var(--light-grey) !important;
  297. color: var(--dark-grey-2) !important;
  298. }
  299. .checkbox input[type="checkbox"] {
  300. background-color: var(--dark-grey);
  301. border-color: transparent;
  302. &:checked:before,
  303. &:checked:after {
  304. background-color: var(--white);
  305. }
  306. }
  307. .pill {
  308. background-color: var(--dark-grey);
  309. color: var(--primary-color);
  310. }
  311. }
  312. .christmas-mode {
  313. --primary-color: var(--red);
  314. }
  315. /* nunito-200 - latin */
  316. @font-face {
  317. font-family: "Nunito";
  318. font-style: normal;
  319. font-weight: 200;
  320. src: url("/fonts/nunito-v16-latin-200.eot"); /* IE9 Compat Modes */
  321. src:
  322. local(""),
  323. url("/fonts/nunito-v16-latin-200.eot?#iefix")
  324. format("embedded-opentype"),
  325. /* IE6-IE8 */ url("/fonts/nunito-v16-latin-200.woff2") format("woff2"),
  326. /* Super Modern Browsers */ url("/fonts/nunito-v16-latin-200.woff")
  327. format("woff"),
  328. /* Modern Browsers */ url("/fonts/nunito-v16-latin-200.ttf")
  329. format("truetype"),
  330. /* Safari, Android, iOS */ url("/fonts/nunito-v16-latin-200.svg#Nunito")
  331. format("svg"); /* Legacy iOS */
  332. }
  333. /* nunito-regular - latin */
  334. @font-face {
  335. font-family: "Nunito";
  336. font-style: normal;
  337. font-weight: 400;
  338. src: url("/fonts/nunito-v16-latin-regular.eot"); /* IE9 Compat Modes */
  339. src:
  340. local(""),
  341. url("/fonts/nunito-v16-latin-regular.eot?#iefix")
  342. format("embedded-opentype"),
  343. /* IE6-IE8 */ url("/fonts/nunito-v16-latin-regular.woff2")
  344. format("woff2"),
  345. /* Super Modern Browsers */ url("/fonts/nunito-v16-latin-regular.woff")
  346. format("woff"),
  347. /* Modern Browsers */ url("/fonts/nunito-v16-latin-regular.ttf")
  348. format("truetype"),
  349. /* Safari, Android, iOS */
  350. url("/fonts/nunito-v16-latin-regular.svg#Nunito") format("svg"); /* Legacy iOS */
  351. }
  352. /* nunito-600 - latin */
  353. @font-face {
  354. font-family: "Nunito";
  355. font-style: normal;
  356. font-weight: 600;
  357. src: url("/fonts/nunito-v16-latin-600.eot"); /* IE9 Compat Modes */
  358. src:
  359. local(""),
  360. url("/fonts/nunito-v16-latin-600.eot?#iefix")
  361. format("embedded-opentype"),
  362. /* IE6-IE8 */ url("/fonts/nunito-v16-latin-600.woff2") format("woff2"),
  363. /* Super Modern Browsers */ url("/fonts/nunito-v16-latin-600.woff")
  364. format("woff"),
  365. /* Modern Browsers */ url("/fonts/nunito-v16-latin-600.ttf")
  366. format("truetype"),
  367. /* Safari, Android, iOS */ url("/fonts/nunito-v16-latin-600.svg#Nunito")
  368. format("svg"); /* Legacy iOS */
  369. }
  370. /* nunito-700 - latin */
  371. @font-face {
  372. font-family: "Nunito";
  373. font-style: normal;
  374. font-weight: 700;
  375. src: url("/fonts/nunito-v16-latin-700.eot"); /* IE9 Compat Modes */
  376. src:
  377. local(""),
  378. url("/fonts/nunito-v16-latin-700.eot?#iefix")
  379. format("embedded-opentype"),
  380. /* IE6-IE8 */ url("/fonts/nunito-v16-latin-700.woff2") format("woff2"),
  381. /* Super Modern Browsers */ url("/fonts/nunito-v16-latin-700.woff")
  382. format("woff"),
  383. /* Modern Browsers */ url("/fonts/nunito-v16-latin-700.ttf")
  384. format("truetype"),
  385. /* Safari, Android, iOS */ url("/fonts/nunito-v16-latin-700.svg#Nunito")
  386. format("svg"); /* Legacy iOS */
  387. }
  388. /* nunito-800 - latin */
  389. @font-face {
  390. font-family: "Nunito";
  391. font-style: normal;
  392. font-weight: 800;
  393. src: url("/fonts/nunito-v16-latin-800.eot"); /* IE9 Compat Modes */
  394. src:
  395. local(""),
  396. url("/fonts/nunito-v16-latin-800.eot?#iefix")
  397. format("embedded-opentype"),
  398. /* IE6-IE8 */ url("/fonts/nunito-v16-latin-800.woff2") format("woff2"),
  399. /* Super Modern Browsers */ url("/fonts/nunito-v16-latin-800.woff")
  400. format("woff"),
  401. /* Modern Browsers */ url("/fonts/nunito-v16-latin-800.ttf")
  402. format("truetype"),
  403. /* Safari, Android, iOS */ url("/fonts/nunito-v16-latin-800.svg#Nunito")
  404. format("svg"); /* Legacy iOS */
  405. }
  406. /* pacifico-regular - latin */
  407. @font-face {
  408. font-family: "Pacifico";
  409. font-style: normal;
  410. font-weight: 400;
  411. src: url("/fonts/pacifico-v17-latin-regular.eot"); /* IE9 Compat Modes */
  412. src:
  413. local(""),
  414. url("/fonts/pacifico-v17-latin-regular.eot?#iefix")
  415. format("embedded-opentype"),
  416. /* IE6-IE8 */ url("/fonts/pacifico-v17-latin-regular.woff2")
  417. format("woff2"),
  418. /* Super Modern Browsers */
  419. url("/fonts/pacifico-v17-latin-regular.woff") format("woff"),
  420. /* Modern Browsers */ url("/fonts/pacifico-v17-latin-regular.ttf")
  421. format("truetype"),
  422. /* Safari, Android, iOS */
  423. url("/fonts/pacifico-v17-latin-regular.svg#Pacifico") format("svg"); /* Legacy iOS */
  424. }
  425. @font-face {
  426. font-family: "Material Icons";
  427. font-style: normal;
  428. font-weight: 400;
  429. src: url(/fonts/MaterialIcons-Regular.ttf); /* For IE6-8 */
  430. src:
  431. local("Material Icons"),
  432. local("MaterialIcons-Regular"),
  433. url(/fonts/MaterialIcons-Regular.ttf) format("truetype");
  434. }
  435. .material-icons {
  436. font-family: "Material Icons";
  437. font-weight: normal;
  438. font-style: normal;
  439. font-size: 24px; /* Preferred icon size */
  440. display: inline-block;
  441. line-height: 1;
  442. text-transform: none;
  443. letter-spacing: normal;
  444. word-wrap: normal;
  445. white-space: nowrap;
  446. direction: ltr;
  447. /* Support for all WebKit browsers. */
  448. -webkit-font-smoothing: antialiased;
  449. /* Support for Safari and Chrome. */
  450. text-rendering: optimizeLegibility;
  451. /* Support for Firefox. */
  452. -moz-osx-font-smoothing: grayscale;
  453. /* Support for IE. */
  454. font-feature-settings: "liga";
  455. }
  456. code {
  457. background-color: var(--light-grey) !important;
  458. color: var(--dark-red) !important;
  459. }
  460. #toasts-container {
  461. z-index: 10000 !important;
  462. .toast {
  463. font-weight: 600;
  464. z-index: 10000 !important;
  465. }
  466. }
  467. html {
  468. height: 100%;
  469. overflow: hidden;
  470. font-size: 14px;
  471. }
  472. body {
  473. background-color: var(--light-grey);
  474. color: var(--dark-grey);
  475. line-height: 1.4285714;
  476. font-size: 1rem;
  477. font-family: Nunito, Arial, sans-serif;
  478. height: 100%;
  479. max-width: 100%;
  480. overflow-y: auto !important;
  481. overflow-x: hidden;
  482. }
  483. .app {
  484. min-height: 100vh;
  485. position: relative;
  486. }
  487. #root {
  488. height: 100%;
  489. max-width: 100%;
  490. }
  491. .content-wrapper {
  492. /* padding: 60px 0 calc(230px + 60px) 0; */
  493. padding-top: 60px;
  494. }
  495. .column {
  496. display: flex;
  497. flex: 1 1 0;
  498. flex-direction: column;
  499. padding: 10px;
  500. }
  501. ul {
  502. list-style: none;
  503. margin: 0;
  504. display: block;
  505. }
  506. h1,
  507. h2,
  508. h3,
  509. h4,
  510. h5,
  511. h6 {
  512. font-family: Nunito, Arial, sans-serif;
  513. font-weight: 400;
  514. line-height: 1.1;
  515. a {
  516. font-weight: inherit;
  517. }
  518. }
  519. h1 {
  520. font-size: 4.2rem;
  521. line-height: 110%;
  522. margin: 2.1rem 0 1.68rem 0;
  523. }
  524. h2 {
  525. font-size: 3.56rem;
  526. line-height: 110%;
  527. margin: 1.78rem 0 1.424rem 0;
  528. }
  529. h3 {
  530. font-size: 2.92rem;
  531. line-height: 110%;
  532. margin: 1.46rem 0 1.168rem 0;
  533. }
  534. h4 {
  535. font-size: 2.28rem;
  536. line-height: 110%;
  537. margin: 1.14rem 0 0.912rem 0;
  538. }
  539. h5 {
  540. font-size: 1.64rem;
  541. line-height: 110%;
  542. margin: 0.82rem 0 0.656rem 0;
  543. }
  544. h6 {
  545. font-size: 1rem;
  546. line-height: 110%;
  547. margin: 0.5rem 0 0.4rem 0;
  548. }
  549. .content {
  550. h4 {
  551. line-height: 1.125;
  552. }
  553. }
  554. .thin {
  555. font-weight: 200;
  556. }
  557. .left {
  558. float: left !important;
  559. }
  560. .right {
  561. float: right !important;
  562. }
  563. .white {
  564. background-color: var(--white) !important;
  565. }
  566. .btn-search {
  567. font-size: 14px;
  568. }
  569. a.nav-item.is-tab {
  570. border-bottom: 1px solid transparent;
  571. border-top: 1px solid transparent;
  572. }
  573. .button.is-info {
  574. border-width: 0;
  575. color: var(--white);
  576. }
  577. strong {
  578. color: inherit;
  579. }
  580. hr {
  581. background-color: var(--light-grey-2);
  582. border: none;
  583. height: 1px;
  584. }
  585. p,
  586. button,
  587. input,
  588. select,
  589. textarea {
  590. font-family: Nunito, Arial, sans-serif;
  591. }
  592. input,
  593. select,
  594. textarea {
  595. outline: none;
  596. }
  597. .label {
  598. display: flex;
  599. font-weight: 700;
  600. &:not(:last-child) {
  601. margin-bottom: 5px;
  602. }
  603. }
  604. #page-title {
  605. margin-top: 0;
  606. font-size: 35px;
  607. text-align: center;
  608. }
  609. @media only screen and (min-width: 700px) {
  610. #page-title {
  611. margin: 0;
  612. margin-bottom: 30px;
  613. font-size: 40px;
  614. }
  615. }
  616. @media screen and (min-width: 980px) {
  617. .container {
  618. max-width: 960px;
  619. margin-left: auto;
  620. margin-right: auto;
  621. }
  622. }
  623. @media screen and (min-width: 1180px) {
  624. .container {
  625. max-width: 1200px;
  626. }
  627. }
  628. .upper-container {
  629. height: 100%;
  630. max-width: 100%;
  631. }
  632. .main-container {
  633. height: 100%;
  634. min-height: 100vh;
  635. display: flex;
  636. flex-direction: column;
  637. max-width: 100%;
  638. > .container {
  639. position: relative;
  640. flex: 1 0 auto;
  641. margin: 0 auto;
  642. max-width: 1200px;
  643. }
  644. }
  645. a {
  646. color: var(--primary-color);
  647. text-decoration: none;
  648. cursor: pointer;
  649. &:hover,
  650. &:focus {
  651. filter: brightness(90%);
  652. }
  653. }
  654. table {
  655. border-collapse: collapse;
  656. width: 100%;
  657. thead {
  658. td {
  659. border-width: 0 0 2px;
  660. }
  661. }
  662. td {
  663. border: 1px solid var(--light-grey-2);
  664. border-width: 0 0 1px;
  665. padding: 8px 10px;
  666. }
  667. tbody {
  668. tr:last-child {
  669. td {
  670. border-bottom-width: 0;
  671. }
  672. }
  673. }
  674. }
  675. img {
  676. max-width: 100%;
  677. }
  678. .absolute-a {
  679. width: 100%;
  680. height: 100%;
  681. position: absolute;
  682. top: 0;
  683. left: 0;
  684. }
  685. .alert {
  686. padding: 20px;
  687. color: var(--white);
  688. background-color: var(--dark-red);
  689. position: fixed;
  690. top: 50px;
  691. right: 50px;
  692. font-size: 2em;
  693. border-radius: @border-radius;
  694. z-index: 10000000;
  695. }
  696. .night-mode {
  697. .tippy-box {
  698. border: 1px solid var(--light-grey-3);
  699. box-shadow: @box-shadow-dropdown;
  700. background-color: var(--white);
  701. .tippy-content {
  702. color: var(--black);
  703. }
  704. &[data-theme~="songActions"],
  705. &[data-theme~="dropdown"],
  706. &[data-theme~="search"],
  707. &[data-theme~="stationSettings"] {
  708. background-color: var(--dark-grey-2);
  709. border: 0 !important;
  710. }
  711. &[data-theme~="songActions"] {
  712. background-color: var(--dark-grey-2);
  713. border: 0 !important;
  714. i,
  715. a {
  716. color: var(--white);
  717. }
  718. .youtube-icon,
  719. .spotify-icon,
  720. .soundcloud-icon {
  721. background-color: var(--white);
  722. }
  723. }
  724. &[data-theme~="dropdown"] {
  725. background-color: var(--dark-grey-2);
  726. border: 0 !important;
  727. .nav-dropdown-items {
  728. .nav-item {
  729. background-color: var(--dark-grey);
  730. &:focus {
  731. outline-color: var(--dark-grey);
  732. }
  733. p {
  734. color: var(--white);
  735. }
  736. }
  737. }
  738. }
  739. &[data-theme~="search"] {
  740. background-color: var(--dark-grey-2);
  741. border: 0 !important;
  742. }
  743. &[data-theme~="info"] p {
  744. color: var(--black) !important;
  745. }
  746. }
  747. .tippy-box[data-placement^="top"] {
  748. &[data-theme~="songActions"],
  749. &[data-theme~="dropdown"],
  750. &[data-theme~="search"] {
  751. > .tippy-arrow::before {
  752. border-top-color: var(--dark-grey-2);
  753. }
  754. }
  755. }
  756. .tippy-box[data-placement^="bottom"] {
  757. &[data-theme~="songActions"],
  758. &[data-theme~="dropdown"],
  759. &[data-theme~="search"],
  760. &[data-theme~="stationSettings"] {
  761. > .tippy-arrow::before {
  762. border-bottom-color: var(--dark-grey-2);
  763. }
  764. }
  765. }
  766. .tippy-box[data-placement^="left"] {
  767. &[data-theme~="songActions"],
  768. &[data-theme~="dropdown"],
  769. &[data-theme~="search"] {
  770. > .tippy-arrow::before {
  771. border-left-color: var(--dark-grey-2);
  772. }
  773. }
  774. }
  775. .tippy-box[data-placement^="right"] {
  776. &[data-theme~="songActions"],
  777. &[data-theme~="dropdown"],
  778. &[data-theme~="search"] {
  779. > .tippy-arrow::before {
  780. border-right-color: var(--dark-grey-2);
  781. }
  782. }
  783. }
  784. }
  785. .tippy-box[data-theme~="info"] {
  786. font-size: 12px;
  787. letter-spacing: 1px;
  788. }
  789. .tippy-box[data-theme~="quickConfirm"] {
  790. background-color: var(--dark-red);
  791. border: 0;
  792. .tippy-content {
  793. padding: 0;
  794. }
  795. a {
  796. padding: 15px;
  797. line-height: 30px;
  798. color: var(--white);
  799. border-bottom: 0;
  800. font-size: 15px;
  801. font-weight: 600;
  802. &:hover,
  803. &:focus {
  804. filter: brightness(90%);
  805. }
  806. }
  807. }
  808. .tippy-box[data-theme~="songActions"] {
  809. font-size: 15px;
  810. padding: 5px 10px;
  811. border: 1px solid var(--light-grey-3);
  812. box-shadow: @box-shadow-dropdown;
  813. background-color: var(--white);
  814. .button {
  815. width: 146px;
  816. }
  817. i,
  818. a {
  819. display: inline-block;
  820. cursor: pointer;
  821. color: var(--dark-grey);
  822. vertical-align: middle;
  823. &:hover,
  824. &:focus {
  825. filter: brightness(90%);
  826. }
  827. &:not(:first) {
  828. margin-left: 5px;
  829. }
  830. }
  831. .play-icon,
  832. .added-to-playlist-icon {
  833. color: var(--green);
  834. }
  835. .edit-icon,
  836. .view-icon,
  837. .add-to-playlist-icon,
  838. .add-to-queue-icon {
  839. color: var(--primary-color);
  840. }
  841. .hide-icon {
  842. color: var(--light-grey-3);
  843. }
  844. .stop-icon,
  845. .delete-icon {
  846. color: var(--dark-red);
  847. }
  848. .report-icon {
  849. color: var(--yellow);
  850. }
  851. }
  852. .tippy-box[data-placement^="top"] {
  853. &[data-theme~="songActions"],
  854. &[data-theme~="dropdown"],
  855. &[data-theme~="search"] {
  856. > .tippy-arrow::before {
  857. border-top-color: var(--white);
  858. }
  859. }
  860. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  861. border-top-color: var(--dark-red);
  862. }
  863. }
  864. .tippy-box[data-placement^="bottom"] {
  865. &[data-theme~="songActions"],
  866. &[data-theme~="dropdown"],
  867. &[data-theme~="stationSettings"],
  868. &[data-theme~="search"] {
  869. > .tippy-arrow::before {
  870. border-bottom-color: var(--white);
  871. }
  872. }
  873. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  874. border-bottom-color: var(--dark-red);
  875. }
  876. }
  877. .tippy-box[data-placement^="left"] {
  878. &[data-theme~="songActions"],
  879. &[data-theme~="dropdown"],
  880. &[data-theme~="search"] {
  881. > .tippy-arrow::before {
  882. border-left-color: var(--white);
  883. }
  884. }
  885. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  886. border-left-color: var(--dark-red);
  887. }
  888. }
  889. .tippy-box[data-placement^="right"] {
  890. &[data-theme~="songActions"],
  891. &[data-theme~="dropdown"],
  892. &[data-theme~="search"] {
  893. > .tippy-arrow::before {
  894. border-right-color: var(--white);
  895. }
  896. }
  897. &[data-theme~="quickConfirm"] > .tippy-arrow::before {
  898. border-right-color: var(--dark-red);
  899. }
  900. }
  901. .tippy-box[data-theme~="stationSettings"] {
  902. border: 1px solid var(--light-grey-3);
  903. box-shadow: @box-shadow-dropdown;
  904. background-color: var(--white);
  905. button:not(:last-of-type) {
  906. margin-bottom: 5px;
  907. }
  908. }
  909. .tippy-box[data-theme~="dropdown"] {
  910. font-size: 15px;
  911. padding: 0;
  912. border: 1px solid var(--light-grey-3);
  913. box-shadow: @box-shadow-dropdown;
  914. background-color: var(--white);
  915. color: var(--dark-grey);
  916. width: 350px;
  917. .tippy-content {
  918. padding: 0;
  919. }
  920. .nav-dropdown-items {
  921. max-height: 220px;
  922. overflow-y: auto;
  923. padding: 10px;
  924. .nav-item {
  925. width: 100%;
  926. justify-content: flex-start;
  927. border: 0;
  928. padding: 8px 4px;
  929. font-size: 15.5px;
  930. min-height: 36px;
  931. background: var(--light-grey);
  932. border-radius: @border-radius;
  933. cursor: pointer;
  934. .checkbox-control {
  935. display: flex;
  936. flex-direction: row;
  937. align-items: center;
  938. overflow-wrap: anywhere;
  939. margin: 0 !important;
  940. p {
  941. margin-left: 10px;
  942. }
  943. .switch {
  944. position: relative;
  945. display: inline-block;
  946. flex-shrink: 0;
  947. width: 40px;
  948. height: 24px;
  949. }
  950. .switch input {
  951. opacity: 0;
  952. width: 0;
  953. height: 0;
  954. }
  955. .slider {
  956. width: 100%;
  957. position: absolute;
  958. cursor: pointer;
  959. top: 0;
  960. left: 0;
  961. right: 0;
  962. bottom: 0;
  963. background-color: var(--light-grey-3);
  964. transition: 0.2s;
  965. border-radius: 34px;
  966. }
  967. .slider:before {
  968. position: absolute;
  969. content: "";
  970. height: 16px;
  971. width: 16px;
  972. left: 4px;
  973. bottom: 4px;
  974. background-color: var(--white);
  975. transition: 0.2s;
  976. border-radius: 50%;
  977. }
  978. input:checked + .slider {
  979. background-color: var(--primary-color);
  980. }
  981. input:focus + .slider {
  982. box-shadow: 0 0 1px var(--primary-color);
  983. }
  984. input:checked + .slider:before {
  985. transform: translateX(16px);
  986. }
  987. }
  988. &:focus {
  989. outline-color: var(--light-grey-3);
  990. }
  991. &:not(:last-of-type) {
  992. margin-bottom: 5px;
  993. }
  994. }
  995. }
  996. .tippy-content > span {
  997. display: flex;
  998. flex-direction: column;
  999. button.nav-item {
  1000. &:not(:last-of-type) {
  1001. margin-bottom: 10px;
  1002. }
  1003. }
  1004. }
  1005. #create-playlist {
  1006. margin: 10px 10px 10px 10px;
  1007. width: calc(100% - 20px);
  1008. }
  1009. }
  1010. .tippy-box[data-theme~="search"] {
  1011. font-size: 15px;
  1012. padding: 0;
  1013. border: 1px solid var(--light-grey-3);
  1014. box-shadow: @box-shadow-dropdown;
  1015. background-color: var(--white);
  1016. color: var(--dark-grey);
  1017. width: 100% !important;
  1018. max-width: 600px !important;
  1019. max-height: calc(100vh - 300px);
  1020. overflow-y: auto;
  1021. .tippy-content {
  1022. padding: 0;
  1023. & > span {
  1024. display: flex;
  1025. flex-direction: column;
  1026. padding: 5px;
  1027. }
  1028. }
  1029. }
  1030. .has-text-centered {
  1031. text-align: center;
  1032. }
  1033. .select {
  1034. position: relative;
  1035. &.is-expanded {
  1036. width: 100%;
  1037. }
  1038. &.disabled,
  1039. .disabled {
  1040. filter: grayscale(1);
  1041. cursor: not-allowed;
  1042. }
  1043. &:after {
  1044. content: " ";
  1045. border: 1.5px solid var(--primary-color);
  1046. border-right: 0;
  1047. border-top: 0;
  1048. height: 7px;
  1049. pointer-events: none;
  1050. position: absolute;
  1051. transform: rotate(-45deg);
  1052. width: 7px;
  1053. margin-top: -6px;
  1054. right: 16px;
  1055. top: 50%;
  1056. }
  1057. select {
  1058. height: 36px;
  1059. width: 100%;
  1060. background-color: var(--white);
  1061. border: 1px solid var(--light-grey-2);
  1062. color: var(--dark-grey-2);
  1063. appearance: none;
  1064. border-radius: @border-radius;
  1065. font-size: 14px;
  1066. line-height: 24px;
  1067. padding-left: 8px;
  1068. position: relative;
  1069. padding-right: 36px;
  1070. cursor: pointer;
  1071. }
  1072. }
  1073. .checkbox {
  1074. height: 25px;
  1075. width: 25px;
  1076. input[type="checkbox"] {
  1077. height: 25px;
  1078. width: 25px;
  1079. background-color: var(--white);
  1080. border: 1px solid var(--light-grey-2);
  1081. appearance: none;
  1082. border-radius: @border-radius;
  1083. cursor: pointer;
  1084. position: relative;
  1085. &:checked {
  1086. &:before {
  1087. content: "";
  1088. position: absolute;
  1089. top: 4px;
  1090. right: 7px;
  1091. background-color: var(--primary-color);
  1092. width: 4px;
  1093. height: 16px;
  1094. transform: rotate(45deg);
  1095. }
  1096. &:after {
  1097. content: "";
  1098. position: absolute;
  1099. top: 12px;
  1100. left: 2px;
  1101. background-color: var(--primary-color);
  1102. width: 10px;
  1103. height: 4px;
  1104. transform: rotate(45deg);
  1105. }
  1106. }
  1107. }
  1108. }
  1109. .button:focus,
  1110. .button:active {
  1111. border-color: var(--light-grey-2) !important;
  1112. }
  1113. .input:focus,
  1114. .input:active,
  1115. .textarea:focus,
  1116. .textarea:active,
  1117. .select select:focus,
  1118. .select select:active {
  1119. border-color: var(--primary-color) !important;
  1120. }
  1121. button.delete:focus {
  1122. background-color: rgba(10, 10, 10, 0.3);
  1123. }
  1124. .tag {
  1125. background-color: var(--dark-grey-3);
  1126. font-family: monospace;
  1127. font-weight: 700;
  1128. color: white;
  1129. border-radius: 18px;
  1130. text-align: center;
  1131. padding: 0 4px !important;
  1132. font-size: 12px;
  1133. line-height: 18px;
  1134. min-width: 18px;
  1135. height: 18px;
  1136. margin-left: 4px;
  1137. &.has-icon {
  1138. padding: 0 !important;
  1139. }
  1140. .material-icons {
  1141. font-size: 18px;
  1142. }
  1143. }
  1144. .selected {
  1145. .tag {
  1146. background-color: var(--light-grey);
  1147. color: var(--dark-grey);
  1148. }
  1149. }
  1150. #tab-selection,
  1151. .tab-selection {
  1152. overflow-x: auto;
  1153. .button {
  1154. white-space: nowrap;
  1155. }
  1156. }
  1157. .table {
  1158. background-color: var(--white);
  1159. color: var(--dark-grey);
  1160. width: 100%;
  1161. border-collapse: collapse;
  1162. border-spacing: 0;
  1163. border-radius: @border-radius;
  1164. thead th {
  1165. padding: 5px 10px;
  1166. text-align: left;
  1167. font-weight: 600;
  1168. color: var(--grey-3);
  1169. }
  1170. tr {
  1171. &:nth-child(even) {
  1172. background-color: #fafafa;
  1173. }
  1174. &:hover,
  1175. &:focus {
  1176. background-color: var(--light-grey);
  1177. }
  1178. }
  1179. }
  1180. .button {
  1181. border: 1px solid var(--light-grey-2);
  1182. background-color: var(--white);
  1183. color: var(--dark-grey-2);
  1184. border-radius: @border-radius;
  1185. line-height: 24px;
  1186. align-items: center;
  1187. display: inline-flex;
  1188. font-size: 14px;
  1189. padding-left: 10px;
  1190. padding-right: 10px;
  1191. justify-content: center;
  1192. cursor: pointer;
  1193. user-select: none;
  1194. white-space: nowrap;
  1195. &:hover,
  1196. &:focus {
  1197. filter: brightness(95%);
  1198. }
  1199. &.is-success {
  1200. background-color: var(--green) !important;
  1201. border-width: 0;
  1202. color: var(--white);
  1203. }
  1204. &.is-primary {
  1205. background-color: var(--primary-color) !important;
  1206. border-width: 0;
  1207. color: var(--white);
  1208. }
  1209. &.is-danger {
  1210. background-color: var(--dark-red) !important;
  1211. border-width: 0;
  1212. color: var(--white);
  1213. }
  1214. &.is-info {
  1215. background-color: var(--primary-color) !important;
  1216. border-width: 0;
  1217. color: var(--white);
  1218. }
  1219. &.is-warning {
  1220. background-color: var(--yellow) !important;
  1221. border-width: 0;
  1222. color: rgba(0, 0, 0, 0.7);
  1223. }
  1224. &.is-dark {
  1225. background-color: var(--dark-grey-2);
  1226. border-width: 0;
  1227. color: var(--light-grey);
  1228. }
  1229. &.is-fullwidth {
  1230. display: flex;
  1231. width: 100%;
  1232. }
  1233. &.disabled {
  1234. filter: grayscale(1);
  1235. cursor: not-allowed;
  1236. }
  1237. }
  1238. .input,
  1239. .textarea {
  1240. width: 100%;
  1241. padding-left: 8px;
  1242. padding-right: 8px;
  1243. line-height: 24px;
  1244. font-size: 14px;
  1245. border-radius: @border-radius;
  1246. box-shadow: inset 0 1px 2px rgba(10, 10, 10, 0.1);
  1247. border: 1px solid var(--light-grey-2);
  1248. }
  1249. .input,
  1250. .button {
  1251. height: 36px;
  1252. }
  1253. .textarea {
  1254. display: block;
  1255. line-height: 1.2;
  1256. padding: 10px;
  1257. max-height: 600px;
  1258. min-height: 120px;
  1259. min-width: 100%;
  1260. resize: vertical;
  1261. }
  1262. .icon {
  1263. height: 24px;
  1264. width: 24px;
  1265. line-height: 24px;
  1266. margin-left: 4px;
  1267. margin-right: -2px;
  1268. }
  1269. .fadein-helpbox-enter-active {
  1270. transition-duration: 0.3s;
  1271. transition-timing-function: ease-in;
  1272. }
  1273. .fadein-helpbox-leave-active {
  1274. transition-duration: 0.3s;
  1275. transition-timing-function: cubic-bezier(0, 1, 0.5, 1);
  1276. }
  1277. .fadein-helpbox-enter-to,
  1278. .fadein-helpbox-leave {
  1279. max-height: 100px;
  1280. overflow: hidden;
  1281. }
  1282. .fadein-helpbox-enter,
  1283. .fadein-helpbox-leave-to {
  1284. overflow: hidden;
  1285. max-height: 0;
  1286. }
  1287. .control {
  1288. margin-bottom: 5px !important;
  1289. &.is-grouped {
  1290. display: flex;
  1291. & > .control {
  1292. &.select.is-expanded > select {
  1293. width: 100%;
  1294. }
  1295. & > input,
  1296. & > select,
  1297. & > .button,
  1298. &.label {
  1299. border-radius: 0;
  1300. }
  1301. &:first-child:not(:only-child) {
  1302. & > input,
  1303. & > select,
  1304. & > .button,
  1305. &.label {
  1306. border-radius: @border-radius 0 0 @border-radius;
  1307. }
  1308. }
  1309. &:last-child:not(:only-child) {
  1310. & > input,
  1311. & > select,
  1312. & > .button,
  1313. &.label {
  1314. border-radius: 0 @border-radius @border-radius 0;
  1315. }
  1316. }
  1317. &:only-child {
  1318. & > input,
  1319. & > select,
  1320. & > .button,
  1321. &.label {
  1322. border-radius: @border-radius;
  1323. }
  1324. }
  1325. }
  1326. }
  1327. &.is-expanded {
  1328. flex: 1;
  1329. }
  1330. &.has-addons {
  1331. display: flex;
  1332. .button {
  1333. border-radius: 0;
  1334. margin-right: -1px;
  1335. &:first-child {
  1336. border-radius: @border-radius 0 0 @border-radius;
  1337. }
  1338. &:last-child {
  1339. border-radius: 0 @border-radius @border-radius 0;
  1340. padding-left: 10px;
  1341. }
  1342. &.dropdown-toggle {
  1343. padding-left: 5px;
  1344. padding-right: 5px;
  1345. }
  1346. }
  1347. > .input {
  1348. margin-right: -1px;
  1349. &:first-child:not(:only-child) {
  1350. border-radius: @border-radius 0 0 @border-radius;
  1351. }
  1352. }
  1353. > div .input {
  1354. border-right: none;
  1355. &:first-child {
  1356. border-radius: @border-radius 0 0 @border-radius;
  1357. }
  1358. }
  1359. }
  1360. }
  1361. .input-with-button {
  1362. .control {
  1363. margin-right: 0px !important;
  1364. }
  1365. input,
  1366. select {
  1367. width: 100%;
  1368. height: 36px;
  1369. border-radius: @border-radius 0 0 @border-radius;
  1370. border-right: 0;
  1371. border-color: var(--light-grey-3);
  1372. }
  1373. .button {
  1374. height: 36px;
  1375. border-radius: 0 @border-radius @border-radius 0;
  1376. }
  1377. }
  1378. .page-title {
  1379. margin: 0 0 50px 0;
  1380. }
  1381. .material-icons {
  1382. user-select: none;
  1383. -webkit-user-select: none;
  1384. }
  1385. .icon-with-button {
  1386. margin-right: 3px;
  1387. font-size: 18px;
  1388. }
  1389. .verified-song {
  1390. font-size: 17px;
  1391. color: var(--primary-color);
  1392. }
  1393. .section-title,
  1394. h4.section-title {
  1395. font-size: 26px;
  1396. font-weight: 600;
  1397. margin: 0px;
  1398. }
  1399. .section-description {
  1400. font-size: 16px;
  1401. font-weight: 400;
  1402. margin-bottom: 10px !important;
  1403. }
  1404. .section-horizontal-rule {
  1405. margin: 15px 0 30px 0;
  1406. }
  1407. .section-margin-bottom {
  1408. height: 30px;
  1409. }
  1410. .margin-top-zero {
  1411. margin-top: 0 !important;
  1412. }
  1413. .margin-bottom-zero {
  1414. margin-bottom: 0 !important;
  1415. }
  1416. /** Universial items e.g. playlist items, queue items, activity items */
  1417. .universal-item {
  1418. display: flex;
  1419. flex-direction: row;
  1420. flex-grow: 1;
  1421. align-items: center;
  1422. justify-content: space-between;
  1423. padding: 7.5px;
  1424. border: 1px solid var(--light-grey-3);
  1425. border-radius: @border-radius;
  1426. overflow: hidden;
  1427. .item-thumbnail {
  1428. width: 65px;
  1429. height: 65px;
  1430. margin: -7.5px;
  1431. border-radius: @border-radius 0 0 @border-radius;
  1432. }
  1433. .item-title {
  1434. font-size: 20px;
  1435. overflow: hidden;
  1436. text-overflow: ellipsis;
  1437. white-space: nowrap;
  1438. }
  1439. .item-description {
  1440. font-size: 14px;
  1441. overflow: hidden;
  1442. text-overflow: ellipsis;
  1443. white-space: nowrap;
  1444. }
  1445. .universal-item-actions {
  1446. display: flex;
  1447. flex-direction: row;
  1448. margin-left: 10px;
  1449. justify-content: center;
  1450. @media screen and (max-width: 800px) {
  1451. flex-wrap: wrap;
  1452. }
  1453. .action-dropdown-icon {
  1454. display: flex;
  1455. color: var(--primary-color);
  1456. }
  1457. .icons-group {
  1458. display: flex;
  1459. align-items: center;
  1460. a {
  1461. padding: 0;
  1462. }
  1463. }
  1464. .button {
  1465. width: 146px;
  1466. }
  1467. i,
  1468. span {
  1469. cursor: pointer;
  1470. &:not(:first-child) {
  1471. margin-left: 5px;
  1472. }
  1473. }
  1474. .play-icon,
  1475. .added-to-playlist-icon {
  1476. color: var(--green);
  1477. }
  1478. .edit-icon,
  1479. .view-icon,
  1480. .add-to-playlist-icon,
  1481. .add-to-queue-icon {
  1482. color: var(--primary-color);
  1483. }
  1484. .hide-icon {
  1485. color: var(--light-grey-3);
  1486. }
  1487. .stop-icon,
  1488. .remove-from-playlist-icon,
  1489. .delete-icon {
  1490. color: var(--dark-red);
  1491. }
  1492. .report-icon {
  1493. color: var(--yellow);
  1494. }
  1495. }
  1496. }
  1497. .save-button-mixin {
  1498. min-width: 200px;
  1499. &:disabled {
  1500. background-color: var(--light-grey) !important;
  1501. color: var(--black);
  1502. }
  1503. }
  1504. .save-button-transition-enter-active {
  1505. transition: all 0.1s ease;
  1506. }
  1507. .save-button-transition-enter {
  1508. transform: translateX(20px);
  1509. opacity: 0;
  1510. }
  1511. .youtube-icon,
  1512. .spotify-icon,
  1513. .soundcloud-icon {
  1514. height: 20px;
  1515. min-height: 20px;
  1516. max-height: 20px;
  1517. width: 20px;
  1518. min-width: 20px;
  1519. max-width: 20px;
  1520. }
  1521. .youtube-icon {
  1522. margin-right: 3px;
  1523. -webkit-mask: url("/assets/social/youtube.svg") no-repeat center;
  1524. mask: url("/assets/social/youtube.svg") no-repeat center;
  1525. background-color: var(--youtube);
  1526. }
  1527. .spotify-icon {
  1528. -webkit-mask: url("/assets/social/spotify.svg") no-repeat center;
  1529. mask: url("/assets/social/spotify.svg") no-repeat center;
  1530. background-color: var(--spotify);
  1531. }
  1532. .soundcloud-icon {
  1533. -webkit-mask: url("/assets/social/soundcloud.svg") no-repeat center;
  1534. mask: url("/assets/social/soundcloud.svg") no-repeat center;
  1535. background-color: var(--soundcloud);
  1536. }
  1537. .warning-icon {
  1538. color: var(--orange);
  1539. }
  1540. #forgot-password {
  1541. justify-content: flex-start;
  1542. margin: 5px 0;
  1543. }
  1544. .steps-fade-leave-active {
  1545. display: none;
  1546. }
  1547. .steps-fade-enter-active,
  1548. .steps-fade-leave-active {
  1549. transition: all 0.3s ease;
  1550. }
  1551. .steps-fade-enter-from,
  1552. .steps-fade-leave-to {
  1553. opacity: 0;
  1554. }
  1555. .skip-step {
  1556. background-color: var(--grey-3);
  1557. color: var(--white);
  1558. }
  1559. #steps {
  1560. display: flex;
  1561. align-items: center;
  1562. justify-content: center;
  1563. height: 50px;
  1564. margin-top: 36px;
  1565. @media screen and (max-width: 300px) {
  1566. display: none;
  1567. }
  1568. .step {
  1569. display: flex;
  1570. align-items: center;
  1571. justify-content: center;
  1572. border-radius: 100%;
  1573. border: 1px solid var(--dark-grey);
  1574. min-width: 50px;
  1575. min-height: 50px;
  1576. background-color: var(--white);
  1577. font-size: 30px;
  1578. user-select: none;
  1579. &.selected {
  1580. background-color: var(--primary-color);
  1581. color: var(--white) !important;
  1582. border: 0;
  1583. }
  1584. }
  1585. .divider {
  1586. display: flex;
  1587. justify-content: center;
  1588. width: 180px;
  1589. height: 1px;
  1590. background-color: var(--dark-grey);
  1591. }
  1592. }
  1593. /* This class is used for content-box in ResetPassword, but not in RemoveAccount. This is because ResetPassword uses transitions and RemoveAccount does not */
  1594. .content-box-wrapper {
  1595. margin-top: 90px;
  1596. width: 100%;
  1597. display: flex;
  1598. align-items: center;
  1599. }
  1600. .content-box {
  1601. border-radius: @border-radius;
  1602. background-color: var(--white);
  1603. border: 1px solid var(--dark-grey);
  1604. max-width: 580px;
  1605. padding: 40px;
  1606. flex: 1;
  1607. @media screen and (max-width: 300px) {
  1608. margin-top: 30px;
  1609. padding: 30px 20px;
  1610. }
  1611. }
  1612. .content-box-optional-helper {
  1613. margin-top: 15px;
  1614. color: var(--primary-color);
  1615. font-size: 16px;
  1616. a {
  1617. color: var(--primary-color);
  1618. }
  1619. }
  1620. .content-box-title {
  1621. font-size: 25px;
  1622. color: var(--black);
  1623. }
  1624. .content-box-description {
  1625. font-size: 14px;
  1626. color: var(--dark-grey);
  1627. }
  1628. .content-box-inputs {
  1629. margin-top: 35px;
  1630. .input-with-button {
  1631. .button {
  1632. width: 105px;
  1633. }
  1634. @media screen and (max-width: 450px) {
  1635. flex-direction: column;
  1636. }
  1637. }
  1638. label {
  1639. font-size: 11px;
  1640. }
  1641. #change-password-button {
  1642. margin-top: 36px;
  1643. width: 175px;
  1644. }
  1645. }
  1646. #password-visibility-container {
  1647. display: flex;
  1648. align-items: center;
  1649. a {
  1650. width: 0;
  1651. margin-left: -30px;
  1652. z-index: 0;
  1653. top: 2px;
  1654. position: relative;
  1655. color: var(--light-grey-1);
  1656. }
  1657. }
  1658. .news-item {
  1659. font-family: Nunito, Arial, sans-serif;
  1660. border-radius: @border-radius;
  1661. padding: 20px;
  1662. border: unset !important;
  1663. box-shadow: @box-shadow;
  1664. * {
  1665. font-family: Nunito, Arial, sans-serif;
  1666. font-size: 16px;
  1667. }
  1668. h1 {
  1669. font-size: 40px;
  1670. &:first-of-type {
  1671. margin-top: 0;
  1672. }
  1673. }
  1674. h2 {
  1675. font-size: 30px;
  1676. }
  1677. h3 {
  1678. font-size: 25px;
  1679. }
  1680. h4,
  1681. h5,
  1682. h6 {
  1683. font-size: 20px;
  1684. }
  1685. h1,
  1686. h2,
  1687. h3,
  1688. h4,
  1689. h5,
  1690. h6 {
  1691. margin: 10px 0;
  1692. }
  1693. ul {
  1694. list-style: unset;
  1695. }
  1696. li {
  1697. margin-left: 30px;
  1698. }
  1699. blockquote {
  1700. padding: 0px 15px;
  1701. color: var(--grey-2);
  1702. border-left: 0.25em solid var(--light-grey-2);
  1703. }
  1704. code {
  1705. font-style: italic;
  1706. }
  1707. hr {
  1708. margin: 10px 0;
  1709. }
  1710. }
  1711. .checkbox-control {
  1712. display: flex;
  1713. flex-direction: row;
  1714. align-items: center;
  1715. p {
  1716. margin-left: 10px;
  1717. }
  1718. .switch {
  1719. position: relative;
  1720. display: inline-block;
  1721. flex-shrink: 0;
  1722. width: 40px;
  1723. height: 24px;
  1724. }
  1725. .switch input {
  1726. opacity: 0;
  1727. width: 0;
  1728. height: 0;
  1729. }
  1730. .slider {
  1731. position: absolute;
  1732. cursor: pointer;
  1733. top: 0;
  1734. left: 0;
  1735. right: 0;
  1736. bottom: 0;
  1737. background-color: var(--light-grey-3);
  1738. transition: 0.2s;
  1739. border-radius: 34px;
  1740. &.disabled {
  1741. filter: grayscale(1);
  1742. cursor: not-allowed;
  1743. }
  1744. }
  1745. .slider:before {
  1746. position: absolute;
  1747. content: "";
  1748. height: 16px;
  1749. width: 16px;
  1750. left: 4px;
  1751. bottom: 4px;
  1752. background-color: var(--white);
  1753. transition: 0.2s;
  1754. border-radius: 50%;
  1755. }
  1756. input:checked + .slider {
  1757. background-color: var(--primary-color);
  1758. }
  1759. input:focus + .slider {
  1760. box-shadow: 0 0 1px var(--primary-color);
  1761. }
  1762. input:checked + .slider:before {
  1763. transform: translateX(16px);
  1764. }
  1765. }
  1766. html {
  1767. &,
  1768. * {
  1769. scrollbar-color: var(--primary-color) transparent;
  1770. scrollbar-width: thin;
  1771. }
  1772. &.night-mode {
  1773. &,
  1774. * {
  1775. scrollbar-color: var(--light-grey) transparent !important;
  1776. }
  1777. &::-webkit-scrollbar-thumb,
  1778. ::-webkit-scrollbar-thumb {
  1779. background-color: var(--light-grey);
  1780. }
  1781. ::-webkit-scrollbar-track {
  1782. background-color: var(--dark-grey-3);
  1783. }
  1784. }
  1785. div {
  1786. ::-webkit-scrollbar-track {
  1787. background-color: transparent !important;
  1788. }
  1789. }
  1790. }
  1791. ::-webkit-scrollbar {
  1792. height: 10px;
  1793. width: 10px;
  1794. }
  1795. ::-webkit-scrollbar-track {
  1796. background-color: var(--light-grey-2);
  1797. }
  1798. ::-webkit-scrollbar-thumb {
  1799. background-color: var(--primary-color);
  1800. }
  1801. ::-webkit-scrollbar-corner {
  1802. background-color: transparent;
  1803. }
  1804. :disabled,
  1805. .disabled {
  1806. cursor: not-allowed;
  1807. }
  1808. .pill {
  1809. background-color: var(--light-grey);
  1810. color: var(--primary-color);
  1811. padding: 5px 10px;
  1812. border-radius: @border-radius;
  1813. font-size: 14px;
  1814. font-weight: 600;
  1815. white-space: nowrap;
  1816. margin-top: 5px;
  1817. box-shadow: @box-shadow;
  1818. transition: all 0.2s ease-in-out;
  1819. &:hover,
  1820. &:focus {
  1821. filter: brightness(95%);
  1822. }
  1823. &:not(:last-of-type) {
  1824. margin-right: 5px;
  1825. }
  1826. }
  1827. </style>