Skip to content

Commit

Permalink
Merge pull request #2 from the-standard/202405-history-snagging
Browse files Browse the repository at this point in the history
202405 history snagging
  • Loading branch information
ZakMooney authored May 29, 2024
2 parents 06f62f6 + 3e64ccf commit bb91f82
Show file tree
Hide file tree
Showing 12 changed files with 291 additions and 7 deletions.
68 changes: 64 additions & 4 deletions src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,14 @@
}

.tst-inner {
padding: 1rem;
margin: auto;
padding: 1rem;
/* margin: auto; */
}

@media (min-width: 1440px) {
.tst-inner {
padding: 1rem 0px 1rem 1rem;
}
}

@media (min-width: 1610px) {
Expand Down Expand Up @@ -225,6 +231,41 @@
}
}

/* FOOTER */

.tst-footer {
z-index: 1;
}

.tst-footer,
.tst-footer > div,
.tst-footer > aside,
.tst-footer > nav {
position: relative;
}

.tst-footer::before {
content: "";
position: absolute;
top: 0px;
right: 0px;
left: 0px;
bottom: 0px;
-webkit-user-select: none;
-ms-user-select: none;
user-select: none;
backdrop-filter: var(--glass-blur);
background: var(--glass-bg);
box-shadow: var(--glass-inset);
}

@media (min-width: 1440px) {
.tst-footer,
.tst-footer:before {
border-radius: var(--card-border-radius) var(--card-border-radius) 0px 0px;
}
}

/* SIDENAV */

.tst-sidenav {
Expand Down Expand Up @@ -296,6 +337,7 @@
position: fixed;
width: 4rem;
margin-top: 1rem;
top: 64px;
}

.tst-sidenav,
Expand All @@ -312,9 +354,27 @@
height: 3rem;
}

.drawer-content {
.tst-inner {
margin-left: 4rem;
}

.tst-sidenav__content {
display: flex;
flex-direction: column;
justify-content: space-between;
height: calc(100vh - 64px);
}

.tst-sidenav__content > .tst-inner {
flex: 1;
}

/*
.md\:drawer-open > .drawer-toggle ~ .tst-sidenav__side.drawer-side {
position: fixed;
top: 64px;
} */

}

@media (min-width: 1440px) {
Expand All @@ -331,7 +391,7 @@
.tst-sidenav {
margin-left: -5rem;
}
.drawer-content {
.tst-inner {
margin-left: 0rem;
}
}
Expand Down
2 changes: 2 additions & 0 deletions src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import Vaults from './pages/vaults/Vaults';
import Vault from './pages/vault/Vault';
import VaultHistory from './pages/vault/VaultHistory';
import LiquidationPools from './pages/liquidation-pools/LiquidationPools';
import TermsOfUse from './pages/TermsOfUse';

import './App.css';
import 'react-toastify/dist/ReactToastify.min.css';
Expand All @@ -33,6 +34,7 @@ function App() {
<Route path="vault/:vaultId" element={<DashLayout><Vault /></DashLayout>} />
<Route path="vault/:vaultId/history" element={<DashLayout><VaultHistory /></DashLayout>} />
<Route path="liquidation-pools" element={<DashLayout><LiquidationPools /></DashLayout>} />
<Route path="termsofuse" element={<DashLayout><TermsOfUse /></DashLayout>} />
<Route path="*" element={<Home/>} />
</Routes>
</DisconnectHandler>
Expand Down
1 change: 1 addition & 0 deletions src/assets/discordlogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/assets/githublogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions src/assets/linkedinlogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/assets/telegramlogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/assets/twitterlogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/assets/youtubelogo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 5 additions & 3 deletions src/components/ui/DashLayout.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {

import TopNav from './TopNav';
import SideNav from './SideNav';
import Footer from './Footer';

const DashLayout = ({children}) => {
const [showSideNav, setShowSideNav] = useState(false);
Expand All @@ -16,7 +17,6 @@ const DashLayout = ({children}) => {

return (
<div className="tst-con">
<TopNav toggleVisible={toggleVisible} />
<ToastContainer
position="bottom-left"
stacked
Expand All @@ -36,12 +36,14 @@ const DashLayout = ({children}) => {
<SideNav toggleVisible={toggleVisible} />
}
className="md:drawer-open bg-base-400/0"
contentClassName="min-h-screen bg-base-400/0"
sideClassName="bg-base-400/0 z-[1]"
contentClassName="tst-sidenav__content min-h-screen bg-base-400/0"
sideClassName="tst-sidenav__side bg-base-400/0 z-[1]"
>
<TopNav toggleVisible={toggleVisible} />
<div className="tst-inner">
{children}
</div>
<Footer />
</Drawer>
</div>
);
Expand Down
101 changes: 101 additions & 0 deletions src/components/ui/Footer.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
import {
useCurrentTheme,
} from "../../store/Store";

import Button from "./Button";

import twitterLogo from "../../assets/twitterlogo.svg";
import linkedinlogo from "../../assets/linkedinlogo.svg";
import youtubelogo from "../../assets/youtubelogo.svg";
import discordlogo from "../../assets/discordlogo.svg";
import telegramlogo from "../../assets/telegramlogo.svg";
import githublogo from "../../assets/githublogo.svg";

const links = [
{ name: "Home", link: "https://TheStandard.io" },
{ name: "About", link: "https://www.thestandard.io/about" },
{ name: "Whitepaper", link: "https://www.thestandard.io/tst-whitepaper" },
{ name: "Blog", link: "https://thestandard.io/blog" },
{ name: "Terms of Use", link: "/termsofuse" },
];

const icons = [
{
name: 'Discord',
logo: discordlogo,
link: "https://discord.gg/THWyBQ4RzQ",
},
{
name: 'LinkedIn',
logo: linkedinlogo,
link: "https://www.linkedin.com/company/the-standard-io",
},
{
name: 'Twitter',
logo: twitterLogo,
link: "https://twitter.com/thestandard_io",
},
{
name: 'YouTube',
logo: youtubelogo,
link: "https://www.youtube.com/@TheStandard_io",
},
{
name: 'Telegram',
logo: telegramlogo,
link: "https://t.me/TheStandard_io",
},
{
name: 'Github',
logo: githublogo,
link: "https://github.com/the-standard",
},
];

const Footer = (props) => {
const { currentTheme } = useCurrentTheme();
const isLight = currentTheme && currentTheme.includes('light');

return (
<footer className="tst-footer items-center p-4 tst-footer mt-20 gap-2 flex flex-col md:flex-row">
<aside className="w-full flex flex-row align-center justify-center md:justify-start flex-wrap md:flex-nowrap gap-4">
{links.map((link) => (
<a
key={link.name}
href={link.link}
target="_blank"
>
{link.name}
</a>
))}
</aside>
<nav className="w-full flex flex-row align-center justify-center md:justify-end flex-wrap md:flex-nowrap gap-1">
{icons.map((icon) => (
<Button
size="sm"
color="ghost"
onClick={() => window.open(icon.link, "_blank")}
>
<img
className={
isLight ? (
icon.name === 'Telegram' ? (
'h-4 w-4 inline-block'
) : (
'h-4 w-4 inline-block invert'
)
) : (
'h-4 w-4 inline-block'
)
}
src={icon.logo}
alt={`${icon.name} logo`}
/>
</Button>
))}
</nav>
</footer>
)
};

export default Footer;
97 changes: 97 additions & 0 deletions src/pages/TermsOfUse.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
import Card from "../components/ui/Card";
import Typography from "../components/ui/Typography";

const TermsOfUse = () => {
return (
<Card className="card-compact">
<div className="card-body">

<div>
<Typography variant="h1">
Terms of Service for TheStandard.io
</Typography>
</div>

<div className="flex flex-col">
<Typography variant="p">
Last Updated: [5.NOV.2023]
</Typography>

<Typography variant="h3" className="mt-4">
1. Introduction
</Typography>
<Typography variant="p">
Welcome to TheStandard.io. This website provides a decentralized finance (DeFi) lending platform through which users can interact with various blockchain-based smart contracts and interfaces. By using TheStandard.io, you agree to be bound by these Terms of Service and acknowledge that you have read and understood them.
</Typography>

<Typography variant="h3" className="mt-4">
2. Acceptance of Risk
</Typography>
<Typography variant="p">
As a user of TheStandard.io, you acknowledge and agree that:
<br/><br/>
2.1. Risk of Blockchain and Smart Contracts: Dealing with blockchain technology and smart contracts involves several risks. The technology is relatively new and may have undiscovered vulnerabilities. You understand that this could expose you to risks of hacks, code vulnerabilities, and unforeseen events in the blockchain network.
<br/><br/>
2.2. Responsibility for Decisions: You are solely responsible for all decisions made and actions taken in relation to your use of TheStandard.io and its smart contracts and interfaces.
<br/><br/>
2.3. No Liability for Losses: TheStandard.io, its developers, team members, or affiliates shall not be liable for any losses you may incur as a result of using our platform. This includes, but is not limited to, losses due to smart contract vulnerabilities, hacks, technical failures, or fluctuations in cryptocurrency value.
<br/><br/>
2.4. Absence of Guarantees: The platform does not guarantee any profits or protection from losses. Your use of TheStandard.io is at your own risk, and you should only commit assets that you are prepared to lose entirely.
</Typography>

<Typography variant="h3" className="mt-4">
3. Acknowledgment of Risks
</Typography>
<Typography variant="p">
By using TheStandard.io, you acknowledge that:
<br/><br/>
3.1. Potential for Losses: You understand and accept the risk that comes with the use of blockchain technology and smart contracts, which could result in total loss of your assets.
<br/><br/>
3.2. No Recourse: In the event of any losses, including those resulting from vulnerabilities, hacks, or any other security issues in the smart contracts, you agree that you have no recourse against TheStandard.io, its developers, team members, or affiliates.
<br/><br/>
3.3. Due Diligence: You have the necessary knowledge and experience in blockchain technology and understand the risks involved. You are also responsible for conducting your own due diligence regarding your transactions.
</Typography>

<Typography variant="h3" className="mt-4">
4. No Liability
</Typography>
<Typography variant="p">
TheStandard.io shall not be liable for any of the following:
<br/><br/>
4.1. Technical Failures: Any technical malfunction, breakdown, delay, or failure of the website or the underlying blockchain network.
<br/><br/>
4.2. Market Risks: Changes in market conditions that affect the value of cryptocurrencies or assets used on the platform.
<br/><br/>
4.3. Regulatory Changes: Any loss due to changes in regulatory status, legal challenges, or other external factors affecting the use of cryptocurrencies or blockchain technology.
<br/><br/>
4.4.1 You acknowledge and understand that the smart contracts used by TheStandard.io are experimental computer programs that may contain unforeseen vulnerabilities or errors. These vulnerabilities or errors could potentially lead to the loss of your assets.
<br/><br/>
4.4.2 By using TheStandard.io smart contracts, you expressly acknowledge and accept these inherent risks. You further acknowledge and accept that you, the user, bear sole responsibility for any losses that may occur as a result of using TheStandard.io smart contracts, regardless of the cause of such losses.
<br/><br/>
4.4.3 Under no circumstances shall TheStandard.io's developers, TST token holders, or other users of the platform be liable for any losses you may incur as a result of using TheStandard.io smart contracts.
<br/><br/>
4.4.4 YOU USE THE STANDARD.IO SMART CONTRACTS AT YOUR OWN RISK.
</Typography>

<Typography variant="h3" className="mt-4">
5. Amendments to Terms
</Typography>
<Typography variant="p">
TheStandard.io reserves the right to modify or amend these Terms of Service at any time. Your continued use of the platform after any such changes constitutes your acceptance of the new Terms of Service.
</Typography>

<Typography variant="h3" className="mt-4">
6. Contact Information
</Typography>
<Typography variant="p">
If you have any questions regarding these Terms of Service, please contact us on discord which is linked from TheStandard.io website.
</Typography>


</div>
</div>
</Card>
);
};

export default TermsOfUse;
8 changes: 8 additions & 0 deletions src/pages/vault/VaultHistory.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,14 @@ const VaultHistory = () => {
<Card className="card-compact">
<div className="card-body overflow-x-scroll">
{vaultNav()}

<div role="alert" className="alert alert-warning bg-yellow-400/20 mb-2">
<span>
<b>History Maintenance</b>
<br/>
We are are working on improving the speed of history updates. In the meantime you may experience temporary drops in history coverage or delayed new entries.
</span>
</div>
<table className="table table-zebra">
<thead>
<tr>
Expand Down

0 comments on commit bb91f82

Please sign in to comment.