Skip to content

Commit 0aac9a8

Browse files
committed
Dashboard: dedicated engine header UI tweak on mobile, Tab component tweaks (#7787)
<!-- ## title your PR with this format: "[SDK/Dashboard/Portal] Feature/Fix: Concise title for the changes" If you did not copy the branch name from Linear, paste the issue tag here (format is TEAM-0000): ## Notes for the reviewer Anything important to call out? Be sure to also clarify these in your comments. ## How to test Unit tests, playground, etc. --> <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on updating the `TabButtons` component across various files by modifying class names and adjusting properties to improve styling and functionality. ### Detailed summary - Updated `tabClassName` for `TabButtons` in multiple files to enhance styling. - Changed `tabContainerClassName` in several instances to adjust layout. - Added `activeTabClassName` in certain components to manage active tab styles. - Refined `isActive` logic for better tab state management. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex --> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Style** * Updated tab button styling across multiple areas of the dashboard for a more consistent appearance, removing explicit small text overrides and adjusting layout and padding. * Improved header layout and button appearance in the transactions section for better responsiveness and visual clarity. * Enhanced code snippet formatting in API usage examples for readability. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent fa7a812 commit 0aac9a8

File tree

21 files changed

+12
-28
lines changed

21 files changed

+12
-28
lines changed

apps/dashboard/src/@/components/batch-upload/batch-lazy-mint.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -324,7 +324,6 @@ function SelectReveal(props: {
324324
{canCreateDelayedRevealBatch && (
325325
<TabButtons
326326
containerClassName="mb-8"
327-
tabClassName="!text-sm"
328327
tabs={[
329328
{
330329
name: "Reveal upon mint",

apps/dashboard/src/@/components/blocks/code/code-segment.client.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ export const CodeSegment: React.FC<CodeSegmentProps> = ({
9595
{!hideTabs && (
9696
<TabButtons
9797
hideBottomLine={!!onlyTabs}
98-
tabClassName="text-sm gap-2 !text-sm"
9998
tabContainerClassName="px-3 pt-1.5 gap-0.5"
10099
tabIconClassName="size-4"
101100
tabs={environments.map((env) => ({

apps/dashboard/src/@/components/contract-components/contract-publish-form/factory-fieldset.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ export const FactoryFieldset: React.FC<FactoryFieldsetProps> = ({
3030
</p>
3131

3232
<TabButtons
33-
tabClassName="!text-sm font-semibold"
3433
tabs={[
3534
{
3635
name: "Default Factory",

apps/dashboard/src/@/components/contract-components/contract-publish-form/landing-fieldset.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ export function LandingFieldset({
144144
</p>
145145

146146
<TabButtons
147-
tabClassName="!text-sm"
148147
tabs={[
149148
{
150149
name: "Write",
@@ -226,7 +225,6 @@ export function LandingFieldset({
226225
</p>
227226
)}
228227
<TabButtons
229-
tabClassName="!text-sm"
230228
tabs={[
231229
{
232230
name: "Write",

apps/dashboard/src/@/components/contracts/code-overview.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -743,7 +743,6 @@ export function CodeOverview(props: {
743743
<div className="bg-background">
744744
<TabButtons
745745
tabs={tabList}
746-
tabClassName="!text-sm"
747746
tabContainerClassName="px-3 pt-2"
748747
/>
749748
</div>

apps/dashboard/src/@/components/contracts/functions/contract-function.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,6 @@ export const ContractFunctionsPanel: React.FC<ContractFunctionsPanelProps> = ({
332332
<div className="flex flex-col h-full relative">
333333
<TabButtons
334334
tabContainerClassName="px-3 pt-2"
335-
tabClassName="!text-sm"
336335
tabs={[
337336
...(viewFunctions.length > 0
338337
? [

apps/dashboard/src/@/components/ui/DatePickerWithRange.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,6 @@ export function DatePickerWithRange(props: {
7979
<div className={cn("px-4", !props.header && "py-4")}>
8080
<TabButtons
8181
activeTabClassName="!bg-inverted !text-inverted-foreground"
82-
tabClassName="!text-sm"
8382
tabContainerClassName="gap-2"
8483
tabs={[
8584
{

apps/dashboard/src/@/components/ui/tabs.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ export function TabLinks(props: {
5656
<Link
5757
aria-disabled={tab.isDisabled}
5858
className={cn(
59-
"relative h-auto rounded-lg px-3 font-normal text-muted-foreground text-sm lg:text-sm",
59+
"relative inline-flex h-auto items-center gap-1.5 rounded-lg font-medium hover:bg-accent !px-3",
6060
!tab.isActive && !tab.isDisabled && "hover:text-foreground",
6161
tab.isDisabled && "pointer-events-none",
6262
tab.isActive && "!text-foreground",
@@ -125,7 +125,7 @@ export function TabButtons(props: {
125125
>
126126
<Button
127127
className={cn(
128-
"relative inline-flex h-auto items-center gap-1.5 rounded-lg px-2 font-medium text-sm hover:bg-accent lg:px-3 lg:text-base",
128+
"relative inline-flex h-auto items-center gap-1.5 rounded-lg font-medium hover:bg-accent !px-3",
129129
!tab.isActive &&
130130
"text-muted-foreground hover:text-foreground",
131131
tab.isDisabled && "cursor-not-allowed opacity-50",

apps/dashboard/src/app/(app)/(dashboard)/(chain)/[chain_id]/[contractAddress]/(marketplace)/components/list-button.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,6 @@ export const CreateListingButton: React.FC<CreateListingButtonProps> = ({
6464
{isInsightSupported ? (
6565
<>
6666
<TabButtons
67-
tabClassName="text-sm gap-2 !text-sm"
68-
tabContainerClassName="gap-0.5"
6967
tabs={LISTING_MODES.map((mode) => ({
7068
isActive: mode === listingMode,
7169
name: mode,

apps/dashboard/src/app/(app)/(dashboard)/(chain)/[chain_id]/[contractAddress]/nfts/[tokenId]/token-id.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,6 @@ export const TokenIdPage: React.FC<TokenIdPageProps> = ({
157157
</div>
158158

159159
<TabButtons
160-
tabClassName="!text-sm"
161160
tabs={[
162161
{
163162
isActive: tab === "Details",

0 commit comments

Comments
 (0)