Skip to content

Commit

Permalink
fixed typings
Browse files Browse the repository at this point in the history
  • Loading branch information
SamueleA committed Nov 21, 2023
1 parent db3a397 commit 11193f4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/checkout/src/contexts/CheckoutModal.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from 'react'
import { MethodArguments } from '../api'
import { createGenericContext } from '@0xsequence/kit'
import { createGenericContext, Theme } from '@0xsequence/kit'

interface CoinQuantity {
contractAddress: string,
Expand Down Expand Up @@ -41,7 +41,7 @@ type CheckoutModalContext = {
triggerCheckout: (settings: CheckoutSettings) => void
closeCheckout: () => void
settings?: CheckoutSettings
theme: 'light'|'dark'
theme: Theme
}

export const [useCheckoutModalContext, CheckoutModalContextProvider] = createGenericContext<CheckoutModalContext>()
2 changes: 1 addition & 1 deletion packages/kit/src/components/KitProvider/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import '@0xsequence/design-system/styles.css'
import * as sharedStyles from '../styles.css'

export declare const THEME: readonly ["dark", "light"];
export declare type Theme = ComponentProps<typeof ThemeProvider>['theme'];
export declare type Theme = Exclude<ComponentProps<typeof ThemeProvider>['theme'], undefined>;
export const THEMES = {
dark: 'dark' as Theme,
light: 'light' as Theme
Expand Down

0 comments on commit 11193f4

Please sign in to comment.