Skip to content

Commit

Permalink
Very small update and fix (MystenLabs#3140)
Browse files Browse the repository at this point in the history
* small changes/fixes

* lint update

* update e2e testing, added section

* fix home page height

* update

* rm recent changes
  • Loading branch information
Jibz1 authored Jul 11, 2022
1 parent 7147056 commit 4abe318
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 6 deletions.
2 changes: 1 addition & 1 deletion explorer/client/src/__tests__/e2e.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const coinGroup = (num: number) => {
};
};

const mainBodyCSS = 'main > div';
const mainBodyCSS = 'main > section > div';

const nftObject = (num: number) => `div#ownedObjects > div:nth-child(${num})`;

Expand Down
4 changes: 4 additions & 0 deletions explorer/client/src/app/App.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,7 @@ main {
@apply relative z-10 py-2 min-h-[77vh]
bg-offwhite rounded-[20px] shadow-2xl;
}

.suicontainer {
@apply max-w-[1440px] mx-auto p-5;
}
4 changes: 3 additions & 1 deletion explorer/client/src/app/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ function App() {
<div className={styles.app}>
<Header />
<main>
<AppRoutes />
<section className={styles.suicontainer}>
<AppRoutes />
</section>
</main>
<Footer />
</div>
Expand Down
2 changes: 1 addition & 1 deletion explorer/client/src/components/tabs/TabFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function TabFooter({
<></>
)}
{stats && (
<p>
<p className={styles.stats}>
{typeof stats.count === 'number'
? numberSuffix(stats.count)
: stats.count}{' '}
Expand Down
4 changes: 4 additions & 0 deletions explorer/client/src/components/tabs/Tabs.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,7 @@
.tabsfooter a {
@apply text-gray-700 font-semibold;
}

.stats {
@apply ml-auto;
}
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,9 @@ function LatestTxView({
const totalCount = results.totalTxcount || 1;
const [searchParams, setSearchParams] = useSearchParams();
const pageParam = parseInt(searchParams.get('p') || '1', 10);
const [showNextPage, setShowNextPage] = useState(true);
const [showNextPage, setShowNextPage] = useState(
NUMBER_OF_TX_PER_PAGE < totalCount
);

const changePage = useCallback(() => {
const nextpage = pageParam + (showNextPage ? 1 : 0);
Expand Down
4 changes: 2 additions & 2 deletions explorer/client/src/pages/home/Home.module.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
div.home {
@apply bg-white min-h-screen;
@apply bg-white;
}

div.container {
@apply min-h-screen mx-auto grid md:grid-cols-2 grid-cols-1 max-w-[1440px] pl-5 pr-5 pt-10 gap-10;
@apply mx-auto grid md:grid-cols-2 grid-cols-1;
}

0 comments on commit 4abe318

Please sign in to comment.