App.vue 32 KB

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