Skip to content

Commit

Permalink
Merge pull request #285 from Itheum/test
Browse files Browse the repository at this point in the history
TEST -> STG 1.11.0
  • Loading branch information
newbreedofgeek authored Feb 12, 2024
2 parents d320e63 + c6de771 commit 65c6810
Show file tree
Hide file tree
Showing 14 changed files with 354 additions and 141 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import { TransactionsToastList, NotificationModal, SignTransactionsModals } from
import { apiTimeout, walletConnectV2ProjectId, sampleAuthenticatedDomains, ELROND_NETWORK } from "config";
import { MultiversxBubbles, MultiversxInfographics, MyWallet, PageNotFound, Unlock } from "pages";
import { ItheumTrailblazer } from "pages/AppMarketplace/ItheumTrailblazer/ItheumTrailblazer";
import { TimeCapsule } from "pages/AppMarketplace/TimeCapsule/TimeCapsule";
import { NFTunes } from "pages/AppMarketplace/NFTunes";
import { routes, routeNames } from "routes";
import { ThemeProvider } from "./libComponents/ThemeProvider";
Expand Down Expand Up @@ -44,6 +45,7 @@ export const App = () => {
<Route path={`${routeNames.multiversxbubbles}/:targetNonce/:targetMessageToBeSigned`} element={<MultiversxBubbles />} />
<Route path={`${routeNames.multiversxinfographics}/:targetNonce/:targetMessageToBeSigned`} element={<MultiversxInfographics />} />
<Route path={`${routeNames.nftunes}/:targetNonce/:targetMessageToBeSigned`} element={<NFTunes />} />
<Route path={`${routeNames.timecapsule}/:targetNonce/:targetMessageToBeSigned`} element={<TimeCapsule />} />
<Route path={`${routeNames.mywallet}/:targetNonce/:targetMessageToBeSigned`} element={<MyWallet />} />
<Route path="*" element={<PageNotFound />} />
</Routes>
Expand Down
5 changes: 4 additions & 1 deletion src/appsConfig.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ export const PLAYSTATION_GAMER_PASSPORT_TOKENS: app_token[] = [
export const ESDT_BUBBLE_TOKENS: app_token[] = [
// { tokenIdentifier: "DATANFTFT-e0b917", nonce: 417 }
];
export const TIMECAPSULE_TOKENS: app_token[] = IS_DEVNET
? [{ tokenIdentifier: "DATANFTFT-e0b917", nonce: 57 }]
: [{ tokenIdentifier: "DATANFTFT-e936d4", nonce: 5 }];

export const SUPPORTED_APPS = IS_DEVNET
? ["itheumtrailblazer", "multiversxbubbles", "esdtBubble", "playstationgamerpassport", "multiversxinfographics", "nftunes"]
? ["itheumtrailblazer", "multiversxbubbles", "esdtBubble", "playstationgamerpassport", "multiversxinfographics", "nftunes", "timecapsule"]
: ["itheumtrailblazer", "multiversxbubbles", "multiversxinfographics", "nftunes"];
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions src/components/AudioPlayer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -340,9 +340,9 @@ export const AudioPlayer = (props: AudioPlayerProps) => {
{props.previewUrl ? (
<div className="flex flex-col select-text justify-center ">
<span className="font-sans text-lg font-medium leading-7 text-foreground">{props.songs[currentTrackIndex]?.title}</span>{" "}
<span className="font-sans text-base font-medium text-foreground/60">{props.songs[currentTrackIndex]?.category}</span>
<span className="font-sans text-base font-medium leading-6 text-muted-foreground overflow-ellipsis overflow-hidden max-w-[90%]">
{props.songs[currentTrackIndex]?.album}
<span className="font-sans text-base font-medium text-foreground/60">Preview</span>
<span className="font-sans text-base font-medium leading-6 text-muted-foreground overflow-ellipsis overflow-y-auto max-w-[90%] max-h-32 ">
{props.songs[currentTrackIndex]?.description}
</span>
</div>
) : (
Expand Down
4 changes: 2 additions & 2 deletions src/components/Layout/Footer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ export const Footer = () => {
{...{
target: "_blank",
}}
className="flex items-center dark:text-white text-black"
href="https://itheum.com">
className="flex items-center dark:text-white text-black text-sm"
href="https://itheum.io">
Made with ♥ by Itheum
</a>
<div className="flex justify-center items-center gap-2">
Expand Down
19 changes: 19 additions & 0 deletions src/libComponents/YouTubeEmbed.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import React from "react";

const YouTubeEmbed = ({ embedId, title }: { embedId: string; title: string }) => {
return (
<iframe
className="h-full w-full"
src={`https://www.youtube.com/embed/${embedId}?controls=1&playsinline=1&color=white&autoplay=0`}
title={title}
frameborder="0"
allowfullscreen="allowfullscreen"
mozallowfullscreen="mozallowfullscreen"
msallowfullscreen="msallowfullscreen"
oallowfullscreen="oallowfullscreen"
webkitallowfullscreen="webkitallowfullscreen"
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"></iframe>
);
};

export default YouTubeEmbed;
8 changes: 8 additions & 0 deletions src/libs/utils/constant.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import iconBubbleMaps from "assets/img/expl-app-bubblemaps-icon.png";
import iconInfrographics from "assets/img/expl-app-infographics-icon.png";
import iconTrailblazer from "assets/img/expl-app-trailblazer-icon.png";
import iconTimeCapsule from "assets/img/timecapsule/expl-app-timecapsule-icon.png";
import iconNFTunes from "assets/img/nf-tunes-logo.png";

export const ERROR_CONNECT_WALLET = "Connect your wallet";
Expand Down Expand Up @@ -50,6 +51,13 @@ export const APP_MAPPINGS = [
desc: "Explore a multisensory journey with this app, extending art beyond visuals. Through vibrations, it unveils the creative potentials of Data NFTs, offering a unique and immersive experience.",
img: iconNFTunes,
},
{
appName: "Time Capsule",
appDescription: "Time Capsule",
routeKey: "timecapsule",
desc: "Capture, archive, and relive historic social media events through photos and videos, preserving memories for future generations. Join the nostalgia journey!",
img: iconTimeCapsule,
},
];

export const ITHEUM_EXPLORER_PROD_URL = "https://explorer.itheum.io";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,21 @@
import React, { useEffect, useState } from "react";
import { useGetLoginInfo } from "@multiversx/sdk-dapp/hooks";
import { Banknote, BarChart3, CalendarCheck, Flag, HeartHandshake, Map, ShoppingCart, Trophy } from "lucide-react";
import { Banknote, BarChart3, CalendarCheck, Flag, HeartHandshake, Map, ShoppingCart, Trophy, Drama } from "lucide-react";
import { VerticalTimeline, VerticalTimelineElement } from "react-vertical-timeline-component";
import { Loader } from "components";
import { Modal } from "../../../../components/Modal/Modal";
import { NoDataFound } from "../../../../components/NoDataFound";
import { Button } from "../../../../libComponents/Button";
import { Card } from "../../../../libComponents/Card";
import { useFilterStore } from "../../../../store/FilterStore";
import { Modal } from "components/Modal/Modal";
import { NoDataFound } from "components/NoDataFound";
import { Button } from "libComponents/Button";
import { Card } from "libComponents/Card";
import { useFilterStore } from "store/FilterStore";

export const TrailBlazerModal = ({ owned, isFetchingDataMarshal, data }: { owned: boolean; isFetchingDataMarshal?: boolean; data: any }) => {
const { filter } = useFilterStore();
const { loginMethod } = useGetLoginInfo();
const [filteredData, setFilteredData] = useState<number>(1000);

useEffect(() => {
const filteredDataTemp = new Set();
const allData = new Set(data);
allData.forEach((dataT: any) => {
// console.log(data.category);
if (dataT.category === filter) {
filteredDataTemp.add(dataT);
} else {
Expand All @@ -28,8 +25,6 @@ export const TrailBlazerModal = ({ owned, isFetchingDataMarshal, data }: { owned
});
}, [filter]);

// console.log(allData);

const getIconForCategory = (dataItem: any) => {
switch (dataItem.category) {
case "Partnership":
Expand All @@ -47,6 +42,9 @@ export const TrailBlazerModal = ({ owned, isFetchingDataMarshal, data }: { owned
case "Leaderboard":
return <BarChart3 strokeWidth={2.5} />;
break;
case "Meme":
return <Drama />;
break;
default:
return <CalendarCheck strokeWidth={2.5} />;
break;
Expand Down Expand Up @@ -165,6 +163,24 @@ export const TrailBlazerModal = ({ owned, isFetchingDataMarshal, data }: { owned
</div>
);
break;
case "Meme":
tileCode = (
<div className="bg-gradient-to-r from-yellow-300 to-orange-500 p-[1px] rounded-xl">
<Card className="flex flex-col items-start justify-center !p-4 text-foreground bg-background border-0 rounded-xl">
<h2>{dataItem.title}</h2>
<h3>{new Date(dataItem.date).toDateString()}</h3>
{dataItem.file && dataItem["file_mimeType"] && (
<video className="w-auto h-auto mx-auto my-4" style={{ maxHeight: "600px" }} controls>
<source src={dataItem.file} type={dataItem["file_mimeType"]}></source>
</video>
)}
<a href={dataItem.link} target="_blank" className="!text-blue-500">
See more...
</a>
</Card>
</div>
);
break;
default:
tileCode = (
<div className="bg-gradient-to-r from-yellow-300 to-orange-500 p-[1px] rounded-xl">
Expand Down
Loading

0 comments on commit 65c6810

Please sign in to comment.