Skip to content

Commit

Permalink
Fix hook call name
Browse files Browse the repository at this point in the history
  • Loading branch information
azro352 committed Dec 1, 2022
1 parent d3bdfdd commit 2d9ca25
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/_util/responsiveObserve.ts
Expand Up @@ -7,7 +7,7 @@ export type ScreenSizeMap = Partial<Record<Breakpoint, number>>;

export const responsiveArray: Breakpoint[] = ['xxxl', 'xxl', 'xl', 'lg', 'md', 'sm', 'xs'];

const getResponsiveMap = (): BreakpointMap => {
const useResponsiveMap = (): BreakpointMap => {
const [, token] = useToken();
return {
xs: `(max-width: ${token.screenXS}px)`,
Expand All @@ -20,7 +20,7 @@ const getResponsiveMap = (): BreakpointMap => {
} as BreakpointMap;
};

export const responsiveMap: BreakpointMap = getResponsiveMap();
export const responsiveMap: BreakpointMap = useResponsiveMap();

type SubscribeFunc = (screens: ScreenMap) => void;
const subscribers = new Map<Number, SubscribeFunc>();
Expand Down

0 comments on commit 2d9ca25

Please sign in to comment.