diff --git a/.env b/.env new file mode 100644 index 0000000..4eddc0e --- /dev/null +++ b/.env @@ -0,0 +1,26 @@ +NEXT_PUBLIC_SANITY_DATASET=production +NEXT_PUBLIC_SANITY_PROJECT_ID=mlxdtup8 +NEXT_PUBLIC_BASE_URL=http://localhost:3000/ +SANITY_API_TOKEN=skT2G7wl4BFGvOLkELSIrcnFEBG3MyrXC71IJgv5iBOj5yxJx75MjgBzbbTvIwUtckXFIluhN2iEHiV37jNA0EcJmbTkMT1LJKwCNWH3ddJnof3mPQWDoVNggRM4ZCNgTDpbGqvjf4FE7xb5TkkTVUX5Rf1Fp4Z3IWZmlmwkSR2Fa8UdcikH +NEXTAUTH_SECRET=k3yf4g3h2u1t4sr5eh6s7i +NEXTAUTH_URL=http://localhost:3000/ +GOOGLE_CLIENT_ID=618426972732-a7fqd0fdg2aoa8iagu0vb7f6m0sl2hhs.apps.googleusercontent.com +GOOGLE_CLIENT_SECRET=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 +TRACING_ENABLED=false +NEXT_PUBLIC_SOCKET_URL="http://localhost:4000/" +NEXT_PUBLIC_SOCKETIO_URL_2=http://localhost:5000/ +NEXT_PUBLIC_SHAZAM_CORE_RAPID_API_KEY='2d7b7a8dfcmsh5d7d9d777fe58aap127c50jsn3b17984aa2a3' +NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY=pk_test_c2FjcmVkLWdhcmZpc2gtNy5jbGVyay5hY2NvdW50cy5kZXYk +CLERK_SECRET_KEY=sk_test_LPEsuGh4YWMmMpL3t18rOw08KDjht3lBIsCgRq0Hl6 +NEXT_PUBLIC_CLERK_SIGN_IN_URL=/sign-in +NEXT_PUBLIC_CLERK_SIGN_UP_URL=/sign-up +NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL=/ +NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL=/ +NEXT_PUBLIC_RAPID_API_KEY=0e8903e27emsh2333e866a960be6p1d76cbjsn8250ba0b208d +NEXT_PUBLIC_TINY=limjfdlb66u3w96h1skw5m93kdvmf55zt4ohb3ol4jeb3q6m +NEXT_PUBLIC_CLIENT_SECRET=505a9fece5074f17b4b9a5edee644089 +NEXT_PUBLIC_CLIENT_ID=db6947afde104dbc94f707562b9c20fc +JWT_SECRET=BQBjHQZbyyIZW-WjQ0TxejxcA9dO4v-CRE3zsHabyeowEWKGhepBwAbAPX1B1cnzZkV15J7KEZXA2pUfAmtc8Hms9TTXuAyQxsCB__qKtHDUteEoTsoipMzsiDXTi2kx9Vz0S1cInDyNsevceq29ivhfV-U3oFCWFtRyknTaEQsH1mCigpn-uXZ5AVD5gSqqPt3mK0Z2e5G40r0HpCJtCLgi1Ld2OufzmzagXiKcv9MY7unDjo5hjthV2UF9rmlAy0E6bUH3FcdtCoSsA7JFqAGZyg +NEXT_PUBLIC_CATTO_KEY=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 +NEXT_PUBLIC_CHAT_KEY=8ef40a21-bcb4-47f3-928e-2b83389392b1 +NEXT_PUBLIC_CHAT_KEY=pk-ihWDwESgKjNoJBbORkgfGDrBGEqnBSCIVwftLcSjoEgIYuFK \ No newline at end of file diff --git a/components/Notes/LofiNotes.tsx b/components/Notes/LofiNotes.tsx index e681177..3603765 100644 --- a/components/Notes/LofiNotes.tsx +++ b/components/Notes/LofiNotes.tsx @@ -155,9 +155,9 @@ const LofiNotes = ({ notes, user, setNotes }: any) => {
- -
- + +
+ { {filteredNotes.map((note: any) => ( <> - -
+ +
setShowModal(false)} className="flex justify-end right-2 text-white/30 text-sm font-light cursor-pointer absolute top-2" @@ -227,14 +227,14 @@ const LofiNotes = ({ notes, user, setNotes }: any) => {
{notesshow && ( - +
{ setShowModal(true); setSelectedNote(note.topic); setSelectedNoteData(note.note); }} - className=" bg-white bg-opacity-30 rounded-md border w-64 h-56 overflow-y-scroll border-white border-opacity-50 backdrop-blur-xl p-4 space-y-5 text-neutral-200" + className="btn bg-white bg-opacity-30 rounded-md border w-64 h-56 overflow-y-scroll border-white border-opacity-50 backdrop-blur-xl p-4 space-y-5 text-neutral-200" >

{note.topic}

@@ -252,8 +252,8 @@ const LofiNotes = ({ notes, user, setNotes }: any) => { {showTaskInput && (
{" "} - -
+ +
( -
- setRepeat((prev: any) => !prev)} - className="hidden sm:block cursor-pointer" - /> - {currentSongs?.length && ( - +
+ setRepeat((prev: any) => !prev)} + className="hidden sm:block cursor-pointer" /> +
+ {currentSongs?.length && ( +
+ +
)} {isPlaying ? ( - +
+ +
) : ( - +
+ +
)} {currentSongs?.length && ( - +
+ +
)} - setShuffle((prev: any) => !prev)} - className="hidden sm:block cursor-pointer" - /> +
+ setShuffle((prev: any) => !prev)} + className="hidden sm:block cursor-pointer" + /> +
); diff --git a/components/lofi/MusicPlayer/index.tsx b/components/lofi/MusicPlayer/index.tsx index 2e839ec..3c0f55b 100644 --- a/components/lofi/MusicPlayer/index.tsx +++ b/components/lofi/MusicPlayer/index.tsx @@ -12,7 +12,17 @@ import Seekbar from "./Seekbar"; import Track from "./Track"; import VolumeBar from "./VolumeBar"; -const MusicPlayer = () => { +import { + BsArrowRepeat, + BsFillPauseFill, + BsFillPlayFill, + BsShuffle, +} from "react-icons/bs"; + +import "../../Clock/clock.css"; + +//@ts-ignore +const MusicPlayer = ({ sessionStarted }) => { const { activeSong, currentSongs, currentIndex, isActive, isPlaying } = useSelector((state: any) => state.player); const [duration, setDuration] = useState(0); @@ -58,52 +68,86 @@ const MusicPlayer = () => { }; return ( -
- + {sessionStarted ? ( +
+ {isPlaying ? ( +
+ +
+ ) : ( +
+ +
+ )} + +
+
+
+
+ ) : null} + +
+ {/* -
- - */} + +
+ + {/* setSeekTime(event.target.value)} setSeekTime={setSeekTime} appTime={appTime} - /> - setAppTime(event.target.currentTime)} - onLoadedData={(event: any) => setDuration(event.target.duration)} - /> -
- */} + setAppTime(event.target.currentTime)} + onLoadedData={(event: any) => setDuration(event.target.duration)} + /> +
+ {/* setVolume(event.target.value)} setVolume={setVolume} - /> + /> */} +
); }; diff --git a/components/lofi/components/Discover.tsx b/components/lofi/components/Discover.tsx index 11f4e1d..982d38f 100644 --- a/components/lofi/components/Discover.tsx +++ b/components/lofi/components/Discover.tsx @@ -45,9 +45,9 @@ const Discover = () => {
- +
-
+
{filteredSongs?.map((song: any, i: any) => (
{ const showNote = () => { setShowModal(true); }; - console.log(notess); const [showAddNotesModal, setShowAddNotesModal] = useState(false); const handleAddingNewNote = () => { @@ -209,20 +208,21 @@ const lofi = ({ users, goals, notes, setLoading }: Props) => { <> {seconds > 0 && ( -
+
)} )} - - + {!sessionStarted && } + +
@@ -241,8 +241,8 @@ const lofi = ({ users, goals, notes, setLoading }: Props) => { )}
- -
+ +
{
+ {/* {from-white/10 to-[#2a2a80] backdrop-blur-lg rounded-t-3xl } */} + {activeSong?.title && ( -
- -
- )} + +
+ +
)} + +
} /> diff --git a/pages/select-categories.tsx b/pages/select-categories.tsx index bcb0e92..1e79c71 100644 --- a/pages/select-categories.tsx +++ b/pages/select-categories.tsx @@ -17,11 +17,11 @@ import { Toaster, toast } from "react-hot-toast"; interface Props { users: User[]; } -const Home = ({ users }: Props) => { +const Home = ({ users,next,setNext }: any) => { const router = useRouter(); const { isLoaded, isSignedIn, user } = useUser(); const match = users.filter( - (userss) => userss.email == user?.emailAddresses[0].emailAddress + (userss:any) => userss.email == user?.emailAddresses[0].emailAddress ); const [isNewUser, setIsNewUser] = useState(false); @@ -102,7 +102,6 @@ const Home = ({ users }: Props) => { -
Hi There! @@ -154,13 +153,12 @@ const Home = ({ users }: Props) => {
router.push("/dashboard")} + onClick={() => {router.push("/workspace"); setNext(!next)}} className="bg-cyan-500 p-3 text-white font-semibold rounded-lg mt-20 cursor-pointer" >

Return To User Dashboard

-
); diff --git a/pages/workspace.tsx b/pages/workspace.tsx index 8241740..d906845 100644 --- a/pages/workspace.tsx +++ b/pages/workspace.tsx @@ -39,6 +39,9 @@ import CustomLoader from "../components/CustomLoader"; import Notes from "../components/Notes/Notes"; import { DeleteIcon, XIcon } from "lucide-react"; +import Category from '../pages/select-categories' +import { nextSong } from "../redux/features/playerSlice"; + const ReactQuill = dynamic(import("react-quill"), { ssr: false }); interface Props { users: User[]; @@ -416,8 +419,11 @@ const Home = ({ users, goals, notes, setLoading }: Props) => { // const notes = [1,2,2,3,3,3,3,3,3,3,3,3] + const [onboard,setOnboard] = useState(false); + const [next,setNext] = useState(true); return ( <> + { !onboard ? next?

Welcome to Ownboon ... before going to app we woild lile u to select some categories u follow

: :
{
+} ); };