Skip to content

Commit

Permalink
Add bg to stories directly
Browse files Browse the repository at this point in the history
  • Loading branch information
oskarvu committed Dec 9, 2024
1 parent 6980bbe commit 365179d
Show file tree
Hide file tree
Showing 11 changed files with 20 additions and 21 deletions.
1 change: 0 additions & 1 deletion packages/app/.storybook/styles.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
#storybook-root {
min-width: 375px;
min-height: 400px;
background: rgb(var(--neutral-50));
}

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { TokenSymbol } from '@/domain/types/TokenSymbol'
import { Objective } from '@/features/actions/logic/types'
import { getMockMarketInfo } from '@/test/integration/constants'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider, ZeroAllowanceWagmiDecorator } from '@sb/decorators'
import { WithClassname, WithTooltipProvider, ZeroAllowanceWagmiDecorator } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -121,7 +121,7 @@ function EasyBorrowViewStory(props: EasyBorrowViewStoryProps) {
const meta: Meta<typeof EasyBorrowViewStory> = {
title: 'Features/EasyBorrow/Views/EasyBorrowView',
component: EasyBorrowViewStory,
decorators: [withRouter, WithTooltipProvider(), ZeroAllowanceWagmiDecorator()],
decorators: [withRouter, WithTooltipProvider(), ZeroAllowanceWagmiDecorator(), WithClassname('bg-secondary')],
args: {
pageState: 'form',
assets: [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { farmAddresses } from '@/config/chain/constants'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand All @@ -13,7 +13,7 @@ import { FarmDetailsView } from './FarmDetailsView'
const meta: Meta<typeof FarmDetailsView> = {
title: 'Features/FarmDetails/Views/FarmDetailsView',
component: FarmDetailsView,
decorators: [WithTooltipProvider(), withRouter],
decorators: [WithTooltipProvider(), withRouter, WithClassname('bg-secondary')],
args: {
chainId: mainnet.id,
chainMismatch: false,
Expand Down
4 changes: 2 additions & 2 deletions packages/app/src/features/farms/views/FarmsView.stories.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { AssetsGroup } from '@/domain/farms/types'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -53,7 +53,7 @@ const meta: Meta<typeof FarmsView> = {
parameters: {
layout: 'fullscreen',
},
decorators: [WithTooltipProvider(), withRouter],
decorators: [WithTooltipProvider(), withRouter, WithClassname('bg-secondary')],
args: {
inactiveFarms,
activeFarms,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { WithDevContainer, WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithDevContainer, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand All @@ -18,7 +18,7 @@ const meta: Meta<typeof MarketDetailsView> = {
parameters: {
layout: 'fullscreen',
},
decorators: [WithTooltipProvider(), WithDevContainer(), withRouter],
decorators: [WithTooltipProvider(), WithDevContainer(), withRouter, WithClassname('bg-secondary')],
}

export default meta
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'

Expand All @@ -7,7 +7,7 @@ import { GuestView } from './GuestView'
const meta: Meta<typeof GuestView> = {
title: 'Features/MyPortfolio/Views/GuestView',
component: GuestView,
decorators: [WithTooltipProvider()],
decorators: [WithTooltipProvider(), WithClassname('bg-secondary')],
args: {
openConnectModal: () => {},
},
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand All @@ -11,7 +11,7 @@ import { PositionView } from './PositionView'
const meta: Meta<typeof PositionView> = {
title: 'Features/MyPortfolio/Views/PositionView',
component: PositionView,
decorators: [withRouter, WithTooltipProvider()],
decorators: [withRouter, WithTooltipProvider(), WithClassname('bg-secondary')],
args: {
positionSummary: {
totalCollateralUSD: NormalizedUnitNumber(167_600),
Expand Down
4 changes: 2 additions & 2 deletions packages/app/src/features/savings/views/GuestView.stories.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { UseMyEarningsInfoResult } from '@/domain/savings-charts/useMyEarningsIn
import { UseSavingsRateInfoResult } from '@/domain/savings-charts/useSavingsRateInfo/useSavingsRateInfo'
import { TokenSymbol } from '@/domain/types/TokenSymbol'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -60,7 +60,7 @@ const savingsTokenDetails = {
const meta: Meta<typeof GuestView> = {
title: 'Features/Savings/Views/GuestView',
component: GuestView,
decorators: [WithTooltipProvider()],
decorators: [WithTooltipProvider(), WithClassname('bg-secondary')],
parameters: {
layout: 'fullscreen',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { UseMyEarningsInfoResult } from '@/domain/savings-charts/useMyEarningsIn
import { UseSavingsRateInfoResult } from '@/domain/savings-charts/useSavingsRateInfo/useSavingsRateInfo'
import { TokenSymbol } from '@/domain/types/TokenSymbol'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -128,7 +128,7 @@ const sDaiDetails = {
const meta: Meta<typeof SavingsDaiAndUsdsView> = {
title: 'Features/Savings/Views/SavingsDaiAndUsdsView',
component: SavingsDaiAndUsdsView,
decorators: [WithTooltipProvider(), withRouter()],
decorators: [WithTooltipProvider(), withRouter(), WithClassname('bg-secondary')],
parameters: {
layout: 'fullscreen',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { UseMyEarningsInfoResult } from '@/domain/savings-charts/useMyEarningsIn
import { UseSavingsRateInfoResult } from '@/domain/savings-charts/useSavingsRateInfo/useSavingsRateInfo'
import { TokenSymbol } from '@/domain/types/TokenSymbol'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -93,7 +93,7 @@ const savingsTokenDetails = {
const meta: Meta<typeof SavingsDaiView> = {
title: 'Features/Savings/Views/SavingsDaiView',
component: SavingsDaiView,
decorators: [WithTooltipProvider()],
decorators: [WithTooltipProvider(), WithClassname('bg-secondary')],
parameters: {
layout: 'fullscreen',
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { UseMyEarningsInfoResult } from '@/domain/savings-charts/useMyEarningsIn
import { UseSavingsRateInfoResult } from '@/domain/savings-charts/useSavingsRateInfo/useSavingsRateInfo'
import { TokenSymbol } from '@/domain/types/TokenSymbol'
import { NormalizedUnitNumber, Percentage } from '@marsfoundation/common-universal'
import { WithTooltipProvider } from '@sb/decorators'
import { WithClassname, WithTooltipProvider } from '@sb/decorators'
import { tokens } from '@sb/tokens'
import { getMobileStory, getTabletStory } from '@sb/viewports'
import { Meta, StoryObj } from '@storybook/react'
Expand Down Expand Up @@ -92,7 +92,7 @@ const savingsTokenDetails = {
const meta: Meta<typeof SavingsUsdsView> = {
title: 'Features/Savings/Views/SavingsUsdsView',
component: SavingsUsdsView,
decorators: [WithTooltipProvider()],
decorators: [WithTooltipProvider(), WithClassname('bg-secondary')],
parameters: {
layout: 'fullscreen',
},
Expand Down

0 comments on commit 365179d

Please sign in to comment.