Skip to content

Commit

Permalink
Dark mode button changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
aritrakar committed Jul 26, 2023
1 parent a557f49 commit d4b4d12
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 5 deletions.
6 changes: 5 additions & 1 deletion website/app/collection/albums/[albumId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,11 @@ export default function CollectionAlbumPage({params} : {params: {albumId: string
<Typography variant="subtitle2">{trackLength} {suffix}{totalTime}</Typography>
<Button
variant="outlined"
style={{ width: '5vw', marginTop: '2em' }}
style={{
width: '5vw',
marginTop: '2em',
color: appState.theme === "dark" ? "white" : "",
borderColor: appState.theme === "dark" ? "white" : "" }}
onClick={() => {
appState.changeQueue(tracks, 0);
appState.playCurrentTrack();
Expand Down
7 changes: 6 additions & 1 deletion website/app/collection/artists/[artistId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,12 @@ export default function CollectionArtistPage({
</Typography>
<Button
variant="outlined"
style={{ width: "5vw", marginTop: "2em"}}
style={{
width: "5vw",
marginTop: "2em",
color: appState.theme === "dark" ? "white" : "",
borderColor: appState.theme === "dark" ? "white" : ""
}}
onClick={() => {
appState.changeQueue(tracks, 0);
appState.playCurrentTrack();
Expand Down
7 changes: 6 additions & 1 deletion website/app/collection/playlists/[playlistId]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,12 @@ export default function CollectionPlaylistPage({params} : {params: {playlistId:
<Typography variant="subtitle2">{tracks.length} {suffix}{totalTime}</Typography>
<Button
variant="outlined"
style={{ width: '5vw', marginTop: '2em' }}
style={{
width: "5vw",
marginTop: "2em",
color: appState.theme === "dark" ? "white" : "",
borderColor: appState.theme === "dark" ? "white" : ""
}}
onClick={() => {
appState.changeQueue(tracks, 0);
appState.playCurrentTrack();
Expand Down
9 changes: 7 additions & 2 deletions website/app/collection/playlists/page.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
'use client'

import { useEffect, useState } from "react";
import { use, useEffect, useState } from "react";
import { apiGetCollectionPlaylists, apiPostCreatePlaylist } from "@/components/apiclient";
import { useLoginStateContext } from "@/components/loginstateprovider";
import { useRouter } from "next/navigation";
Expand All @@ -9,9 +9,11 @@ import AlertComponent, { AlertEntry } from "@/components/alerts";
import { Typography, Grid, Modal, TextField, Button, Dialog, DialogTitle, DialogContent, DialogActions } from "@mui/material";
import PlaylistCard from "@/components/playlistCard";
import CreatePlaylistDialog from "@/components/createPlaylistDialog";
import { useAppStateContext } from "@/components/appstateprovider";

export default function CollectionPlaylistsPage() {
const loginState = useLoginStateContext();
const appState = useAppStateContext();
const router = useRouter();

const [playlists, setPlaylists] = useState([] as APIPlaylist[]);
Expand Down Expand Up @@ -74,7 +76,10 @@ export default function CollectionPlaylistsPage() {
<Grid sx={{ padding: 2 }} container direction="row" justifyContent="space-between">
<Typography variant="h6">Playlists</Typography>

<Button variant="outlined" onClick={handleCreatePlaylist}>
<Button variant="outlined" onClick={handleCreatePlaylist}
sx={{
color: appState.theme === "dark" ? "white" : "",
borderColor: appState.theme === "dark" ? "white" : ""}}>
Create Playlist
</Button>
</Grid>
Expand Down

0 comments on commit d4b4d12

Please sign in to comment.