1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240 |
- <template>
- <div>
- <metadata title="Home" />
- <div class="app">
- <main-header
- :hide-logo="true"
- :transparent="true"
- :hide-logged-out="true"
- />
- <div class="header" :class="{ loggedIn }">
- <img class="background" src="/assets/homebg.jpeg" />
- <div class="overlay"></div>
- <div class="content-container">
- <div class="content">
- <img
- class="logo"
- src="/assets/white_wordmark.png"
- :alt="`${this.sitename}` || `Musare`"
- />
- <div v-if="!loggedIn" class="buttons">
- <button
- class="button login"
- @click="openModal('login')"
- >
- Login
- </button>
- <button
- class="button register"
- @click="openModal('register')"
- >
- Register
- </button>
- </div>
- </div>
- </div>
- </div>
- <div v-if="favoriteStations.length > 0" class="group">
- <div class="group-title">
- <div>
- <h2>My Favorites</h2>
- </div>
- </div>
- <draggable
- class="scrollable-list"
- v-model="favoriteStations"
- v-bind="dragOptions"
- @start="drag = true"
- @end="drag = false"
- @change="changeFavoriteOrder"
- >
- <transition-group
- type="transition"
- :name="!drag ? 'draggable-list-transition' : null"
- >
- <router-link
- v-for="station in favoriteStations"
- :key="`key-${station._id}`"
- :to="{
- name: 'station',
- params: { id: station.name }
- }"
- :class="{
- card: true,
- 'station-card': true,
- 'item-draggable': true,
- isPrivate: station.privacy === 'private',
- isMine: isOwner(station)
- }"
- :style="
- '--primary-color: var(--' + station.theme + ')'
- "
- >
- <song-thumbnail
- class="card-image"
- :song="station.currentSong"
- />
- <div class="card-content">
- <div class="media">
- <div class="media-left displayName">
- <i
- v-if="
- loggedIn && !station.isFavorited
- "
- @click.prevent="
- favoriteStation(station)
- "
- class="favorite material-icons"
- content="Favorite Station"
- v-tippy
- >star_border</i
- >
- <i
- v-if="
- loggedIn && station.isFavorited
- "
- @click.prevent="
- unfavoriteStation(station)
- "
- class="favorite material-icons"
- content="Unfavorite Station"
- v-tippy
- >star</i
- >
- <h5>{{ station.displayName }}</h5>
- <i
- v-if="station.type === 'official'"
- class="material-icons verified-station"
- content="Verified Station"
- v-tippy
- >
- check_circle
- </i>
- </div>
- </div>
- <div class="content">
- {{ station.description }}
- </div>
- <div class="under-content">
- <p class="hostedBy">
- Hosted by
- <span class="host">
- <span
- v-if="
- station.type === 'official'
- "
- title="Musare"
- >Musare</span
- >
- <user-id-to-username
- v-else
- :user-id="station.owner"
- :link="true"
- />
- </span>
- </p>
- <div class="icons">
- <i
- v-if="
- station.type === 'community' &&
- isOwner(station)
- "
- class="homeIcon material-icons"
- content="This is your station."
- v-tippy
- >home</i
- >
- <i
- v-if="station.privacy === 'private'"
- class="privateIcon material-icons"
- content="This station is not visible to other users."
- v-tippy
- >lock</i
- >
- <i
- v-if="
- station.privacy === 'unlisted'
- "
- class="unlistedIcon material-icons"
- content="Unlisted Station"
- v-tippy
- >link</i
- >
- </div>
- </div>
- </div>
- <div class="bottomBar">
- <i
- v-if="
- station.paused &&
- station.currentSong.title
- "
- class="material-icons"
- content="Station Paused"
- v-tippy
- >pause</i
- >
- <i
- v-else-if="station.currentSong.title"
- class="material-icons"
- >music_note</i
- >
- <i v-else class="material-icons">music_off</i>
- <span
- v-if="station.currentSong.title"
- class="songTitle"
- :title="
- station.currentSong.artists.length > 0
- ? 'Now Playing: ' +
- station.currentSong.title +
- ' by ' +
- station.currentSong.artists.join(
- ','
- )
- : 'Now Playing: ' +
- station.currentSong.title
- "
- >{{ station.currentSong.title }}
- {{
- station.currentSong.artists.length > 0
- ? " by " +
- station.currentSong.artists.join(
- ","
- )
- : ""
- }}</span
- >
- <span v-else class="songTitle"
- >No Songs Playing</span
- >
- <i
- class="material-icons stationMode"
- :content="
- station.partyMode
- ? 'Station in Party mode'
- : 'Station in Playlist mode'
- "
- v-tippy
- >{{
- station.partyMode
- ? "emoji_people"
- : "playlist_play"
- }}</i
- >
- </div>
- </router-link>
- </transition-group>
- </draggable>
- </div>
- <div class="group bottom">
- <div class="group-title">
- <div>
- <h1>Stations</h1>
- </div>
- </div>
- <a
- v-if="loggedIn"
- @click="openModal('createCommunityStation')"
- class="card station-card createStation"
- >
- <div class="card-image">
- <figure class="image is-square">
- <i class="material-icons">radio</i>
- </figure>
- </div>
- <div class="card-content">
- <div class="media">
- <div class="media-left displayName">
- <h5>Create Station</h5>
- </div>
- </div>
- <div class="content">
- Click here to create your own station!
- </div>
- </div>
- <div class="bottomBar"></div>
- </a>
- <a
- v-else
- @click="openModal('login')"
- class="card station-card createStation"
- >
- <div class="card-image">
- <figure class="image is-square">
- <i class="material-icons">radio</i>
- </figure>
- </div>
- <div class="card-content">
- <div class="media">
- <div class="media-left displayName">
- <h5>Create Station</h5>
- </div>
- </div>
- <div class="content">Login to create a station!</div>
- </div>
- <div class="bottomBar"></div>
- </a>
- <router-link
- v-for="station in filteredStations"
- :key="station._id"
- :to="{
- name: 'station',
- params: { id: station.name }
- }"
- class="card station-card"
- :class="{
- isPrivate: station.privacy === 'private',
- isMine: isOwner(station)
- }"
- :style="'--primary-color: var(--' + station.theme + ')'"
- >
- <song-thumbnail
- class="card-image"
- :song="station.currentSong"
- />
- <div class="card-content">
- <div class="media">
- <div class="media-left displayName">
- <i
- v-if="loggedIn && !station.isFavorited"
- @click.prevent="favoriteStation(station)"
- class="favorite material-icons"
- content="Favorite Station"
- v-tippy
- >star_border</i
- >
- <i
- v-if="loggedIn && station.isFavorited"
- @click.prevent="unfavoriteStation(station)"
- class="favorite material-icons"
- content="Unfavorite Station"
- v-tippy
- >star</i
- >
- <h5>{{ station.displayName }}</h5>
- <i
- v-if="station.type === 'official'"
- class="material-icons verified-station"
- content="Verified Station"
- v-tippy
- >
- check_circle
- </i>
- </div>
- </div>
- <div class="content">
- {{ station.description }}
- </div>
- <div class="under-content">
- <p class="hostedBy">
- Hosted by
- <span class="host">
- <span
- v-if="station.type === 'official'"
- title="Musare"
- >Musare</span
- >
- <user-id-to-username
- v-else
- :user-id="station.owner"
- :link="true"
- />
- </span>
- </p>
- <div class="icons">
- <i
- v-if="
- station.type === 'community' &&
- isOwner(station)
- "
- class="homeIcon material-icons"
- content="This is your station."
- v-tippy
- >home</i
- >
- <i
- v-if="station.privacy === 'private'"
- class="privateIcon material-icons"
- content="This station is not visible to other users."
- v-tippy
- >lock</i
- >
- <i
- v-if="station.privacy === 'unlisted'"
- class="unlistedIcon material-icons"
- content="Unlisted Station"
- v-tippy
- >link</i
- >
- </div>
- </div>
- </div>
- <div class="bottomBar">
- <i
- v-if="station.paused && station.currentSong.title"
- class="material-icons"
- content="Station Paused"
- v-tippy
- >pause</i
- >
- <i
- v-else-if="station.currentSong.title"
- class="material-icons"
- >music_note</i
- >
- <i v-else class="material-icons">music_off</i>
- <span
- v-if="station.currentSong.title"
- class="songTitle"
- :title="
- station.currentSong.artists.length > 0
- ? 'Now Playing: ' +
- station.currentSong.title +
- ' by ' +
- station.currentSong.artists.join(',')
- : 'Now Playing: ' +
- station.currentSong.title
- "
- >{{ station.currentSong.title }}
- {{
- station.currentSong.artists.length > 0
- ? " by " +
- station.currentSong.artists.join(",")
- : ""
- }}</span
- >
- <span v-else class="songTitle">No Songs Playing</span>
- <i
- class="material-icons stationMode"
- :content="
- station.partyMode
- ? 'Station in Party mode'
- : 'Station in Playlist mode'
- "
- v-tippy
- >{{
- station.partyMode
- ? "emoji_people"
- : "playlist_play"
- }}</i
- >
- </div>
- </router-link>
- <h4 v-if="stations.length === 0">
- There are no stations to display
- </h4>
- </div>
- <main-footer />
- </div>
- <create-community-station v-if="modals.createCommunityStation" />
- </div>
- </template>
- <script>
- import { mapState, mapGetters, mapActions } from "vuex";
- import draggable from "vuedraggable";
- import Toast from "toasters";
- import MainHeader from "@/components/layout/MainHeader.vue";
- import MainFooter from "@/components/layout/MainFooter.vue";
- import SongThumbnail from "@/components/SongThumbnail.vue";
- import UserIdToUsername from "@/components/UserIdToUsername.vue";
- import ws from "@/ws";
- export default {
- components: {
- MainHeader,
- MainFooter,
- SongThumbnail,
- CreateCommunityStation: () =>
- import("@/components/modals/CreateCommunityStation.vue"),
- UserIdToUsername,
- draggable
- },
- data() {
- return {
- recaptcha: { key: "" },
- stations: [],
- favoriteStations: [],
- searchQuery: "",
- sitename: "Musare",
- orderOfFavoriteStations: [],
- drag: false
- };
- },
- computed: {
- ...mapState({
- loggedIn: state => state.user.auth.loggedIn,
- userId: state => state.user.auth.userId,
- modals: state => state.modalVisibility.modals
- }),
- ...mapGetters({
- socket: "websockets/getSocket"
- }),
- filteredStations() {
- const privacyOrder = ["public", "unlisted", "private"];
- return this.stations
- .filter(
- station =>
- JSON.stringify(Object.values(station)).indexOf(
- this.searchQuery
- ) !== -1
- )
- .sort(
- (a, b) =>
- this.isOwner(b) - this.isOwner(a) ||
- this.isPlaying(b) - this.isPlaying(a) ||
- a.paused - b.paused ||
- privacyOrder.indexOf(a.privacy) -
- privacyOrder.indexOf(b.privacy) ||
- b.userCount - a.userCount
- );
- },
- dragOptions() {
- return {
- animation: 200,
- group: "favoriteStations",
- disabled: false,
- ghostClass: "draggable-list-ghost"
- };
- }
- },
- watch: {
- orderOfFavoriteStations() {
- this.calculateFavoriteStations();
- }
- },
- async mounted() {
- this.sitename = await lofig.get("siteSettings.sitename");
- if (this.socket.readyState === 1) this.init();
- ws.onConnect(() => this.init());
- this.socket.on("event:stations.created", res => {
- const { station } = res.data;
- if (this.stations.find(_station => _station._id === station._id)) {
- this.stations.forEach(s => {
- const _station = s;
- if (_station._id === station._id) {
- _station.privacy = station.privacy;
- }
- });
- } else {
- if (!station.currentSong)
- station.currentSong = {
- thumbnail: "/assets/notes-transparent.png"
- };
- if (station.currentSong && !station.currentSong.thumbnail)
- station.currentSong.ytThumbnail = `https://img.youtube.com/vi/${station.currentSong.youtubeId}/mqdefault.jpg`;
- this.stations.push(station);
- }
- });
- this.socket.on("event:station.removed", res => {
- const { stationId } = res.data;
- const station = this.stations.find(
- station => station._id === stationId
- );
- if (station) {
- const stationIndex = this.stations.indexOf(station);
- this.stations.splice(stationIndex, 1);
- if (station.isFavorited)
- this.orderOfFavoriteStations.filter(
- favoritedId => favoritedId !== stationId
- );
- }
- });
- this.socket.on("event:userCount.updated", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.userCount = res.data.userCount;
- });
- this.socket.on("event:station.updatePrivacy", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.privacy = res.data.privacy;
- });
- this.socket.on("event:station.updateName", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.name = res.data.name;
- });
- this.socket.on("event:station.updateDisplayName", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.displayName = res.data.displayName;
- });
- this.socket.on("event:station.updateDescription", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.description = res.data.description;
- });
- this.socket.on("event:station.updateTheme", res => {
- const { stationId, theme } = res.data;
- const station = this.stations.find(
- station => station._id === stationId
- );
- if (station) station.theme = theme;
- });
- this.socket.on("event:station.updatePartyMode", res => {
- const { stationId, partyMode } = res.data;
- const station = this.stations.find(
- station => station._id === stationId
- );
- if (station) station.partyMode = partyMode;
- });
- this.socket.on("event:station.nextSong", res => {
- console.log("NEXT SONG!");
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) {
- let newSong = res.data.song;
- if (!newSong)
- newSong = {
- thumbnail: "/assets/notes-transparent.png"
- };
- station.currentSong = newSong;
- }
- });
- this.socket.on("event:station.pause", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.paused = true;
- });
- this.socket.on("event:station.resume", res => {
- const station = this.stations.find(
- station => station._id === res.data.stationId
- );
- if (station) station.paused = false;
- });
- this.socket.on("event:user.favoritedStation", res => {
- const { stationId } = res.data;
- const station = this.stations.find(
- station => station._id === stationId
- );
- if (station) {
- station.isFavorited = true;
- this.orderOfFavoriteStations.push(stationId);
- }
- });
- this.socket.on("event:user.unfavoritedStation", res => {
- const { stationId } = res.data;
- const station = this.stations.find(
- station => station._id === stationId
- );
- if (station) {
- station.isFavorited = false;
- this.orderOfFavoriteStations = this.orderOfFavoriteStations.filter(
- favoritedId => favoritedId !== stationId
- );
- }
- });
- this.socket.on("event:user.orderOfFavoriteStations.changed", res => {
- this.orderOfFavoriteStations = res.data.order;
- });
- },
- beforeDestroy() {
- this.socket.dispatch("apis.leaveRoom", "home", () => {});
- },
- methods: {
- init() {
- this.socket.dispatch("stations.index", res => {
- this.stations = [];
- if (res.status === "success") {
- res.data.stations.forEach(station => {
- const modifiableStation = station;
- if (!modifiableStation.currentSong)
- modifiableStation.currentSong = {
- thumbnail: "/assets/notes-transparent.png"
- };
- if (
- modifiableStation.currentSong &&
- !modifiableStation.currentSong.thumbnail
- )
- modifiableStation.currentSong.ytThumbnail = `https://img.youtube.com/vi/${station.currentSong.youtubeId}/mqdefault.jpg`;
- this.stations.push(modifiableStation);
- });
- this.orderOfFavoriteStations = res.data.favorited;
- }
- });
- this.socket.dispatch("apis.joinRoom", "home");
- },
- isOwner(station) {
- return station.owner === this.userId;
- },
- isPlaying(station) {
- return typeof station.currentSong.title !== "undefined";
- },
- favoriteStation(station) {
- this.socket.dispatch(
- "stations.favoriteStation",
- station._id,
- res => {
- if (res.status === "success") {
- new Toast("Successfully favorited station.");
- } else new Toast(res.message);
- }
- );
- },
- unfavoriteStation(station) {
- this.socket.dispatch(
- "stations.unfavoriteStation",
- station._id,
- res => {
- if (res.status === "success") {
- new Toast("Successfully unfavorited station.");
- } else new Toast(res.message);
- }
- );
- },
- calculateFavoriteStations() {
- this.favoriteStations = this.filteredStations
- .filter(station => station.isFavorited === true)
- .sort(
- (a, b) =>
- this.orderOfFavoriteStations.indexOf(a._id) -
- this.orderOfFavoriteStations.indexOf(b._id)
- );
- },
- changeFavoriteOrder() {
- const recalculatedOrder = [];
- this.favoriteStations.forEach(station =>
- recalculatedOrder.push(station._id)
- );
- this.socket.dispatch(
- "users.updateOrderOfFavoriteStations",
- recalculatedOrder,
- res => {
- return new Toast(res.message);
- }
- );
- },
- ...mapActions("modalVisibility", ["openModal"]),
- ...mapActions("station", ["updateIfStationIsFavorited"])
- }
- };
- </script>
- <style lang="scss">
- * {
- box-sizing: border-box;
- }
- html {
- width: 100%;
- height: 100%;
- color: rgba(0, 0, 0, 0.87);
- body {
- width: 100%;
- height: 100%;
- margin: 0;
- padding: 0;
- }
- }
- .night-mode {
- .header .overlay {
- background: linear-gradient(
- 180deg,
- rgba(34, 34, 34, 0.8) 0%,
- rgba(34, 34, 34, 0.95) 31.25%,
- rgba(34, 34, 34, 0.9) 54.17%,
- rgba(34, 34, 34, 0.8) 100%
- );
- }
- .card,
- .card-content,
- .card-content div {
- background-color: var(--dark-grey-3);
- }
- .card-content .icons i,
- .group-title i {
- color: var(--light-grey-2);
- }
- .card-image.thumbnail {
- background-color: var(--dark-grey-2);
- }
- .card-content .under-content .hostedBy {
- color: var(--light-grey-2);
- }
- }
- @media only screen and (min-width: 1200px) {
- html {
- font-size: 15px;
- }
- }
- @media only screen and (min-width: 992px) {
- html {
- font-size: 14.5px;
- }
- }
- @media only screen and (min-width: 0) {
- html {
- font-size: 14px;
- }
- }
- .header {
- display: flex;
- height: 35vh;
- margin-top: -64px;
- border-radius: 0% 0% 33% 33% / 0% 0% 7% 7%;
- img.background {
- height: 35vh;
- width: 100%;
- object-fit: cover;
- object-position: center;
- filter: blur(1px);
- border-radius: 0% 0% 33% 33% / 0% 0% 7% 7%;
- overflow: hidden;
- }
- .overlay {
- background: linear-gradient(
- 180deg,
- rgba(3, 169, 244, 0.8) 0%,
- rgba(3, 169, 244, 0.95) 31.25%,
- rgba(3, 169, 244, 0.9) 54.17%,
- rgba(3, 169, 244, 0.8) 100%
- );
- position: absolute;
- height: 35vh;
- width: 100%;
- border-radius: 0% 0% 33% 33% / 0% 0% 7% 7%;
- overflow: hidden;
- }
- .content-container {
- position: absolute;
- left: 0;
- right: 0;
- margin-left: auto;
- margin-right: auto;
- text-align: center;
- height: 100%;
- height: 35vh;
- .content {
- position: absolute;
- top: 50%;
- left: 0;
- right: 0;
- transform: translateY(-50%);
- background-color: transparent !important;
- img.logo {
- max-height: 90px;
- font-size: 40px;
- color: var(--white);
- font-family: Pacifico, cursive;
- }
- .buttons {
- display: flex;
- justify-content: center;
- margin-top: 20px;
- flex-wrap: wrap;
- .login,
- .register {
- margin: 5px 10px;
- padding: 10px 15px;
- border-radius: 5px;
- font-size: 18px;
- width: 100%;
- max-width: 250px;
- font-weight: 600;
- border: 0;
- height: inherit;
- }
- .login {
- background: var(--white);
- color: var(--primary-color);
- }
- .register {
- background: var(--purple);
- color: var(--white);
- }
- }
- }
- }
- &.loggedIn {
- height: 20vh;
- .overlay,
- .content-container,
- img.background {
- height: 20vh;
- }
- }
- }
- @media only screen and (max-width: 550px) {
- .header {
- height: 45vh;
- .overlay,
- .content-container,
- img.background {
- height: 45vh;
- }
- }
- }
- .under-content {
- height: 20px;
- position: relative;
- line-height: 1;
- font-size: 24px;
- display: flex;
- align-items: center;
- text-align: left;
- margin-top: 10px;
- p {
- font-size: 15px;
- line-height: 15px;
- display: inline;
- }
- i {
- font-size: 20px;
- }
- * {
- z-index: 10;
- position: relative;
- }
- .icons {
- position: absolute;
- right: 0;
- .material-icons {
- font-size: 22px;
- }
- .material-icons:first-child {
- margin-left: 5px;
- }
- .unlistedIcon {
- color: var(--orange);
- }
- .privateIcon {
- color: var(--dark-pink);
- }
- .homeIcon {
- color: var(--light-purple);
- }
- }
- .hostedBy {
- font-weight: 400;
- font-size: 12px;
- color: var(--black);
- .host,
- .host a {
- font-weight: 400;
- color: var(--primary-color);
- &:hover,
- &:focus {
- filter: brightness(90%);
- }
- }
- }
- }
- .app {
- display: flex;
- flex-direction: column;
- }
- .users-count {
- font-size: 20px;
- position: relative;
- top: -4px;
- }
- .group {
- min-height: 64px;
- flex: 1 0 auto;
- }
- .station-card {
- display: inline-flex;
- flex-direction: row;
- overflow: hidden;
- margin: 10px;
- cursor: pointer;
- height: 150px;
- width: calc(100% - 30px);
- max-width: 400px;
- flex-wrap: wrap;
- border-radius: 5px;
- box-shadow: 0 2px 3px rgba(10, 10, 10, 0.1), 0 0 0 1px rgba(10, 10, 10, 0.1);
- transition: all ease-in-out 0.2s;
- .card-content {
- padding: 10px 10px 10px 15px;
- display: flex;
- flex-direction: column;
- flex-grow: 1;
- -webkit-line-clamp: 2;
- .media {
- display: flex;
- align-items: center;
- margin-bottom: 0;
- .displayName {
- display: flex;
- align-items: center;
- width: 100%;
- overflow: hidden;
- text-overflow: ellipsis;
- display: flex;
- line-height: 30px;
- max-height: 30px;
- .favorite {
- position: absolute;
- color: var(--yellow);
- right: 10px;
- top: 10px;
- font-size: 28px;
- }
- h5 {
- font-size: 20px;
- font-weight: 400;
- margin: 0;
- display: inline;
- margin-right: 6px;
- line-height: 30px;
- text-overflow: ellipsis;
- overflow: hidden;
- white-space: nowrap;
- max-width: 200px;
- }
- i {
- font-size: 22px;
- }
- .verified-station {
- color: var(--primary-color);
- }
- }
- }
- .content {
- word-wrap: break-word;
- overflow: hidden;
- text-overflow: ellipsis;
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-line-clamp: 3;
- line-height: 20px;
- flex-grow: 1;
- text-align: left;
- word-wrap: break-word;
- margin-bottom: 0;
- }
- }
- .card-image.thumbnail {
- min-width: 120px;
- width: 120px;
- height: 120px;
- margin: 0;
- }
- .bottomBar {
- position: relative;
- display: flex;
- align-items: center;
- background: var(--primary-color);
- // box-shadow: inset 0px 2px 4px rgba(100, 100, 100, 0.3);
- width: 100%;
- height: 30px;
- line-height: 30px;
- color: var(--white);
- font-weight: 400;
- font-size: 12px;
- padding: 0 5px;
- flex-basis: 100%;
- i.material-icons {
- vertical-align: middle;
- margin-left: 5px;
- font-size: 22px;
- }
- .songTitle {
- text-align: left;
- vertical-align: middle;
- margin-left: 5px;
- line-height: 30px;
- flex: 2 1 0;
- overflow: hidden;
- text-overflow: ellipsis;
- white-space: nowrap;
- }
- }
- &.createStation {
- height: auto;
- .card-image {
- .image.is-square {
- width: 120px;
- @media screen and (max-width: 330px) {
- width: 50px;
- .material-icons {
- font-size: 35px !important;
- }
- }
- .material-icons {
- position: absolute;
- top: 25px;
- bottom: 25px;
- left: 0;
- right: 0;
- text-align: center;
- font-size: 70px;
- color: var(--primary-color);
- }
- }
- }
- .card-content {
- width: min-content;
- .media {
- margin-top: auto;
- .displayName h5 {
- font-weight: 600;
- }
- }
- .content {
- flex-grow: unset;
- margin-bottom: auto;
- }
- }
- }
- }
- .station-card:hover {
- box-shadow: 0 2px 3px rgba(10, 10, 10, 0.3), 0 0 10px rgba(10, 10, 10, 0.3);
- transition: all ease-in-out 0.2s;
- }
- .community-button {
- cursor: pointer;
- transition: 0.25s ease color;
- font-size: 30px;
- color: var(--dark-grey);
- }
- .community-button:hover {
- color: var(--primary-color);
- }
- .station-privacy {
- text-transform: capitalize;
- }
- .label {
- display: flex;
- }
- .g-recaptcha {
- display: flex;
- justify-content: center;
- margin-top: 20px;
- }
- .group {
- text-align: center;
- width: 100%;
- margin: 10px 0;
- .group-title {
- display: flex;
- align-items: center;
- justify-content: center;
- margin: 25px 0;
- h1 {
- display: inline-block;
- font-size: 45px;
- margin: 0;
- }
- h2 {
- font-size: 35px;
- margin: 0;
- }
- a {
- display: flex;
- margin-left: 8px;
- }
- }
- &.bottom {
- margin-bottom: 40px;
- }
- }
- </style>
|