Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(mfi-v2-ui): various responsive fixes #385

Merged
merged 1 commit into from
Nov 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion apps/marginfi-v2-ui/src/components/common/PageHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const PageHeader: FC<PageHeaderProps> = ({ children }) => {

return (
<div className="flex w-full h-[90px] sm:h-[60px] justify-center items-center border-y bg-[url('/WaveBG3.png')]">
<div className="w-full px-4 sm:max-w-7xl flex flex-row justify-between items-center border-solid font-aeonik font-normal text-2xl sm:text-3xl">
<div className="w-full xl:w-4/5 px-4 xl:max-w-7xl flex flex-row justify-between items-center border-solid font-aeonik font-normal text-2xl sm:text-3xl">
<div className="flex gap-4 justify-center items-center">
<Mobile>
<div className="ml-[4px]">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ const AccountSummary = () => {
const { connected } = useWalletContext();

return (
<div className={cn("flex flex-col lg:flex-row w-full justify-between items-center")}>
<div className={cn("flex flex-col py-[10px] px-4 lg:flex-row w-full justify-between items-center")}>
<div className="font-[500] lg:block w-full h-[118px]">
<div className="h-full rounded-xl p-[10px]">
<div className="h-full rounded-xl">
<span className="w-full flex justify-start text-xl">Global stats</span>
<GlobalStats
tvl={protocolStats.tvl}
Expand All @@ -37,7 +37,7 @@ const AccountSummary = () => {

<div className="w-full">
{connected && (
<div className="font-[500] h-full rounded-xl p-[10px]">
<div className="font-[500] h-full rounded-xl">
<span className="w-full h-full flex justify-start text-xl text-white">Your account</span>
<UserStats
accountSummary={isStoreInitialized && selectedAccount ? accountSummary : null}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ const UserPositionRow: FC<UserPositionRowProps> = ({ activeBankInfo, marginfiAcc
return (
<TableRow className="h-full w-full bg-[#171C1F] border border-[#1E2122] rounded-2xl">
<TableCell className={`text-white p-0 font-aeonik border-[1px] border-none`}>
<div className="flex justify-center items-center px-4 gap-2">
<div className="flex xl:justify-center items-center px-4 gap-2">
{activeBankInfo.meta.tokenLogoUri && (
<Image
src={activeBankInfo.meta.tokenLogoUri}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export const MobileAssetsList = () => {
</Typography>
{isStoreInitialized && globalBanks ? (
globalBanks.length > 0 ? (
<div className="flex flew-row flex-wrap gap-5 justify-center items-center pt-2">
<div className="space-y-5 justify-center items-center pt-2">
{globalBanks.map((bank) => {
if (poolFilter === "stable" && !STABLECOINS.includes(bank.meta.tokenSymbol)) return null;
if (poolFilter === "lst" && !LSTS.includes(bank.meta.tokenSymbol)) return null;
Expand Down
4 changes: 2 additions & 2 deletions apps/marginfi-v2-ui/src/pages/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ const Home = () => {
<>
<Desktop>
<PageHeader>lend</PageHeader>
<div className="flex flex-col h-full justify-start content-start pt-[16px] w-4/5 max-w-7xl gap-4">
<div className="flex flex-col h-full justify-start content-start pt-[16px] w-full xl:w-4/5 xl:max-w-7xl gap-4">
{walletAddress && selectedAccount && isOverride && (
<Banner
text={`Read-only view of ${selectedAccount.address.toBase58()} (owner: ${shortenAddress(
Expand All @@ -107,7 +107,7 @@ const Home = () => {
)}
<DesktopAccountSummary />
</div>
<div className="pt-[16px] pb-[64px] grid w-4/5 max-w-7xl gap-4 grid-cols-1 xl:grid-cols-2">
<div className="pt-[16px] pb-[64px] px-4 grid w-full xl:w-4/5 xl:max-w-7xl gap-4 grid-cols-1 xl:grid-cols-2">
<AssetsList />
</div>
<OverlaySpinner fetching={!isStoreInitialized || isRefreshingStore} />
Expand Down