diff --git a/packages/client/components/ActivityLibrary/ActivityCard.tsx b/packages/client/components/ActivityLibrary/ActivityCard.tsx index 4885cab1900..bcfdeee68c6 100644 --- a/packages/client/components/ActivityLibrary/ActivityCard.tsx +++ b/packages/client/components/ActivityLibrary/ActivityCard.tsx @@ -1,16 +1,17 @@ +import graphql from 'babel-plugin-relay/macro' import clsx from 'clsx' import React, {PropsWithChildren, useEffect, useRef, useState} from 'react' -import {upperFirst} from '../../utils/upperFirst' -import {MeetingTypeEnum} from '../../__generated__/NewMeetingQuery.graphql' -import {ActivityCard_template$key} from '../../__generated__/ActivityCard_template.graphql' -import {backgroundImgMap, CategoryID, MEETING_TYPE_TO_CATEGORY} from './Categories' +import {useFragment} from 'react-relay' import {twMerge} from 'tailwind-merge' +import {ActivityCard_template$key} from '../../__generated__/ActivityCard_template.graphql' +import {MeetingTypeEnum} from '../../__generated__/NewMeetingQuery.graphql' import {Tooltip} from '../../ui/Tooltip/Tooltip' -import {TooltipTrigger} from '../../ui/Tooltip/TooltipTrigger' import {TooltipContent} from '../../ui/Tooltip/TooltipContent' -import {useFragment} from 'react-relay' -import graphql from 'babel-plugin-relay/macro' +import {TooltipTrigger} from '../../ui/Tooltip/TooltipTrigger' +import {upperFirst} from '../../utils/upperFirst' import {ActivityLibraryCardDescription} from './ActivityLibraryCardDescription' +import {CategoryID, MEETING_TYPE_TO_CATEGORY} from './Categories' +import {backgroundImgMap} from './backgroundImgMap' export interface CardTheme { primary: string diff --git a/packages/client/components/ActivityLibrary/Categories.ts b/packages/client/components/ActivityLibrary/Categories.ts index 5c02abf0b68..bc4c5b5425c 100644 --- a/packages/client/components/ActivityLibrary/Categories.ts +++ b/packages/client/components/ActivityLibrary/Categories.ts @@ -1,11 +1,4 @@ import {MeetingTypeEnum} from '../../__generated__/NewMeetingQuery.graphql' -import retroBackgroundSrc from '../../../../static/images/illustrations/retro-background.png' -import standupBackgroundSrc from '../../../../static/images/illustrations/standup-background.png' -import feedbackBackgroundSrc from '../../../../static/images/illustrations/feedback-background.png' -import estimationBackgroundSrc from '../../../../static/images/illustrations/estimation-background.png' -import strategyBackgroundSrc from '../../../../static/images/illustrations/strategy-background.png' -import premortemBackgroundSrc from '../../../../static/images/illustrations/premortem-background.png' -import postmortemBackgroundSrc from '../../../../static/images/illustrations/postmortem-background.png' import {CardTheme} from './ActivityCard' export const MAIN_CATEGORIES = [ @@ -54,13 +47,3 @@ export const MEETING_TYPE_TO_CATEGORY: Record = { poker: 'estimation', teamPrompt: 'standup' } - -export const backgroundImgMap = { - retrospective: retroBackgroundSrc, - standup: standupBackgroundSrc, - feedback: feedbackBackgroundSrc, - estimation: estimationBackgroundSrc, - strategy: strategyBackgroundSrc, - premortem: premortemBackgroundSrc, - postmortem: postmortemBackgroundSrc -} as const diff --git a/packages/client/components/ActivityLibrary/backgroundImgMap.ts b/packages/client/components/ActivityLibrary/backgroundImgMap.ts new file mode 100644 index 00000000000..2d6f2ebb059 --- /dev/null +++ b/packages/client/components/ActivityLibrary/backgroundImgMap.ts @@ -0,0 +1,17 @@ +import estimationBackgroundSrc from '../../../../static/images/illustrations/estimation-background.png' +import feedbackBackgroundSrc from '../../../../static/images/illustrations/feedback-background.png' +import postmortemBackgroundSrc from '../../../../static/images/illustrations/postmortem-background.png' +import premortemBackgroundSrc from '../../../../static/images/illustrations/premortem-background.png' +import retroBackgroundSrc from '../../../../static/images/illustrations/retro-background.png' +import standupBackgroundSrc from '../../../../static/images/illustrations/standup-background.png' +import strategyBackgroundSrc from '../../../../static/images/illustrations/strategy-background.png' + +export const backgroundImgMap = { + retrospective: retroBackgroundSrc, + standup: standupBackgroundSrc, + feedback: feedbackBackgroundSrc, + estimation: estimationBackgroundSrc, + strategy: strategyBackgroundSrc, + premortem: premortemBackgroundSrc, + postmortem: postmortemBackgroundSrc +} as const