@pega/cosmos-react-work 9.0.0-build.29.2 → 9.0.0-build.29.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/components/CaseHierarchy/CaseHierarchy.d.ts +2 -2
- package/lib/components/CaseHierarchy/CaseHierarchy.d.ts.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.js +3 -3
- package/lib/components/CaseHierarchy/CaseHierarchy.js.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.styles.d.ts.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.styles.js +9 -7
- package/lib/components/CaseHierarchy/CaseHierarchy.styles.js.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.test-ids.d.ts +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.test-ids.d.ts.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.test-ids.js +2 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.test-ids.js.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.types.d.ts +7 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.types.d.ts.map +1 -1
- package/lib/components/CaseHierarchy/CaseHierarchy.types.js.map +1 -1
- package/lib/components/CasePreview/CasePreview.d.ts +1 -1
- package/lib/components/CasePreview/CasePreview.d.ts.map +1 -1
- package/lib/components/CasePreview/CasePreview.js +5 -4
- package/lib/components/CasePreview/CasePreview.js.map +1 -1
- package/lib/components/CaseView/CaseHeader/CaseHeader.d.ts.map +1 -1
- package/lib/components/CaseView/CaseHeader/CaseHeader.js +24 -4
- package/lib/components/CaseView/CaseHeader/CaseHeader.js.map +1 -1
- package/lib/components/CaseView/CaseView.d.ts.map +1 -1
- package/lib/components/CaseView/CaseView.js +1 -1
- package/lib/components/CaseView/CaseView.js.map +1 -1
- package/lib/components/CaseView/CaseView.styles.d.ts +1 -1
- package/lib/components/CaseView/CaseView.styles.d.ts.map +1 -1
- package/lib/components/CaseView/CaseView.styles.js +69 -65
- package/lib/components/CaseView/CaseView.styles.js.map +1 -1
- package/lib/components/CaseView/CaseView.types.d.ts +9 -3
- package/lib/components/CaseView/CaseView.types.d.ts.map +1 -1
- package/lib/components/CaseView/CaseView.types.js.map +1 -1
- package/lib/components/GenAICoach/CaseWorkflow.d.ts.map +1 -1
- package/lib/components/GenAICoach/CaseWorkflow.js +5 -4
- package/lib/components/GenAICoach/CaseWorkflow.js.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.d.ts.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.js +57 -7
- package/lib/components/GenAICoach/GenAICoach.js.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.styles.d.ts.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.styles.js +23 -23
- package/lib/components/GenAICoach/GenAICoach.styles.js.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.types.d.ts +2 -0
- package/lib/components/GenAICoach/GenAICoach.types.d.ts.map +1 -1
- package/lib/components/GenAICoach/GenAICoach.types.js.map +1 -1
- package/lib/components/HierarchicalAssignments/Assignments.styles.d.ts.map +1 -1
- package/lib/components/HierarchicalAssignments/Assignments.styles.js +0 -1
- package/lib/components/HierarchicalAssignments/Assignments.styles.js.map +1 -1
- package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.d.ts +2 -0
- package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.d.ts.map +1 -1
- package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.js.map +1 -1
- package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.d.ts +1 -1
- package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.d.ts.map +1 -1
- package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.js +2 -2
- package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.js.map +1 -1
- package/lib/components/Tasks/TaskList.d.ts +3 -1
- package/lib/components/Tasks/TaskList.d.ts.map +1 -1
- package/lib/components/Tasks/TaskList.js +2 -2
- package/lib/components/Tasks/TaskList.js.map +1 -1
- package/lib/components/Tasks/Tasks.d.ts +5 -0
- package/lib/components/Tasks/Tasks.d.ts.map +1 -1
- package/lib/components/Tasks/Tasks.js +29 -5
- package/lib/components/Tasks/Tasks.js.map +1 -1
- package/package.json +4 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseView.js","sourceRoot":"","sources":["../../../src/components/CaseView/CaseView.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,eAAe,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAG1F,OAAO,EACL,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,YAAY,EACZ,IAAI,EACJ,QAAQ,EACR,aAAa,EACb,cAAc,EACd,UAAU,EACV,IAAI,EACJ,MAAM,EACN,OAAO,EACP,YAAY,EACZ,qBAAqB,EACrB,iBAAiB,EACjB,uBAAuB,EACvB,gBAAgB,EAChB,SAAS,EACT,UAAU,EACV,WAAW,EACX,eAAe,EACf,kBAAkB,EAClB,IAAI,EACJ,UAAU,EACV,QAAQ,EACR,WAAW,EACZ,MAAM,yBAAyB,CAAC;AAGjC,OAAO,KAAK,kBAAkB,MAAM,yEAAyE,CAAC;AAC9G,OAAO,KAAK,iBAAiB,MAAM,wEAAwE,CAAC;AAC5G,OAAO,KAAK,gBAAgB,MAAM,sEAAsE,CAAC;AACzG,OAAO,KAAK,mBAAmB,MAAM,0EAA0E,CAAC;AAChH,OAAO,KAAK,kBAAkB,MAAM,yEAAyE,CAAC;AAC9G,OAAO,KAAK,QAAQ,MAAM,6DAA6D,CAAC;AACxF,OAAO,KAAK,UAAU,MAAM,+DAA+D,CAAC;AAE5F,OAAO,UAAU,MAAM,eAAe,CAAC;AAGvC,OAAO,WAAW,MAAM,eAAe,CAAC;AACxC,OAAO,gBAAgB,MAAM,oBAAoB,CAAC;AAClD,OAAO,EACL,gBAAgB,EAChB,uB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mBAAmB,EACxB,OAAO,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,EACxC,KAAK,EAAE,CAAC,CAAC,cAAc,CAAC,GACxB,CACH,IACA,CACJ,IACI,CACR,EACA,mBAAmB,CAAC,OAAO,IAAI,eAAe,IAAI,SAAS,IAAI,CAC9D,KAAC,wBAAwB,IACvB,IAAI,EAAE,CAAC,CAAC,cAAc,CAAC,EACvB,MAAM,EAAE,mBAAmB,CAAC,OAAO,EACnC,SAAS,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC,KAAK,CAAC,YAEpC,KAAC,UAAU,OACL,eAAe,EACnB,OAAO,EAAE;oCACP,SAAS,EAAE,QAAQ;oCACnB,OAAO,EAAE,GAAG,EAAE;wCACZ,eAAe,CAAC,OAAO,EAAE,EAAE,CAAC;wCAC5B,YAAY,CAAC,KAAK,CAAC,CAAC;wCACpB,mBAAmB,CAAC,OAAO,EAAE,KAAK,EAAE,CAAC;oCACvC,CAAC;iCACF,GACD,GACuB,CAC5B,IACI,GACkB,EAC1B,mBAAmB,IACnB,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC,QAAQ,EAAE,kBAAkB,CAAC,CAAC","sourcesContent":["import { useEffect, useMemo, useRef, useLayoutEffect, useState, useContext } from 'react';\nimport type { FC } from 'react';\n\nimport {\n Flex,\n Grid,\n Icon,\n registerIcon,\n Text,\n TabPanel,\n useBreakpoint,\n useScrollStick,\n useElement,\n Card,\n Drawer,\n useI18n,\n useDirection,\n useAfterInitialEffect,\n windowIsAvailable,\n focusHeadingOrContainer,\n useConfiguration,\n useRefMap,\n useTestIds,\n withTestIds,\n AppShellContext,\n useConsolidatedRef,\n Tabs,\n CardHeader,\n useTheme,\n usePrevious\n} from '@pega/cosmos-react-core';\nimport type { ForwardProps, Tab } from '@pega/cosmos-react-core';\nimport type { ScrollStickOptions } from '@pega/cosmos-react-core/lib/hooks/useScrollStick';\nimport * as moveRightSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/move-right-solid.icon';\nimport * as moveLeftSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/move-left-solid.icon';\nimport * as polarisSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/polaris-solid.icon';\nimport * as arrowMicroRightIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/arrow-micro-right.icon';\nimport * as arrowMicroLeftIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/arrow-micro-left.icon';\nimport * as dockIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/dock.icon';\nimport * as unDockIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/undock.icon';\n\nimport GenAICoach from '../GenAICoach';\nimport type { State } from '../GenAICoach/GenAICoach.types';\n\nimport CaseSummary from './CaseSummary';\nimport UtilitiesSummary from './UtilitiesSummary';\nimport {\n StyledCaseDrawer,\n StyledCaseDrawerContent,\n StyledCaseView,\n StyledWorkArea,\n StyledPersistentUtility,\n StyledPersistentContainer,\n StyledSummary,\n StyledSummaryTabContent,\n StyledUtilities,\n StyledExpandCollapseUtilitiesButton,\n StyledUtilitiesHeading,\n StyledCoachButton,\n StyledUtilitiesWrapper,\n StyledPersistentContent,\n StyledSummaryHeading,\n StyledTasks,\n StyledTabPanelWrapper,\n StyledBannersStagesTasksContainer\n} from './CaseView.styles';\nimport type { CaseViewContextValue, CaseViewProps } from './CaseView.types';\nimport CaseViewContext from './CaseView.context';\nimport CaseSummaryFields from './CaseSummaryFields';\nimport { getCaseViewTestIds } from './CaseView.test-ids';\nimport UtilitySummaryItemDialog from './UtilitySummaryItemDialog';\n\nregisterIcon(\n moveRightSolidIcon,\n moveLeftSolidIcon,\n polarisSolidIcon,\n arrowMicroRightIcon,\n arrowMicroLeftIcon,\n dockIcon,\n unDockIcon\n);\n\n// This function is responsible for auto sizing table height in case tab panels.\nconst resizeTable = (tabPanelEl: HTMLDivElement, workAreaEl: HTMLDivElement) => {\n tabPanelEl.style.removeProperty('--content-height-in-view');\n\n // .rs-wrapper is currently the class used by the table component which needs to be targeted.\n const tables = Array.from(tabPanelEl.querySelectorAll('.rs-wrapper')).filter(\n table => table.getBoundingClientRect().width !== 0\n );\n\n // Only perform this logic when there is a single table in a tab's panel.\n if (tables.length !== 1) return;\n\n // This selector finds the table's root element as they are always wrapped in a Card.\n const table = tables[0].closest('article');\n\n if (!table) return;\n\n const tabPanelRect = tabPanelEl.getBoundingClientRect();\n const tableRect = table.getBoundingClientRect();\n const vpHeight = document.documentElement.clientHeight;\n const tableRectOffsetTop = tableRect.top + window.scrollY;\n const workAreaPaddingBlockEnd =\n // px unit are required for proper CSS calc calculation.\n window.getComputedStyle(workAreaEl).getPropertyValue('padding-block-end') || '0px';\n\n // Accounts for content rendered after the table.\n const tableBottomToTabPanelBottom = tabPanelRect.bottom - tableRect.bottom;\n\n // Sets a CSS variable for available height based on screen size and view state.\n // Defines an available minimum height of ~600px.\n tabPanelEl.style.setProperty(\n '--content-height-in-view',\n `max(calc(${\n vpHeight - tableRectOffsetTop - tableBottomToTabPanelBottom\n }px - ${workAreaPaddingBlockEnd}), 37.5rem)`\n );\n};\n\nconst CaseView: FC<CaseViewProps & ForwardProps> = ({\n testId,\n\n // Case data mostly visually related to the case header\n caseId,\n heading,\n subheading,\n caseType,\n caseLink,\n parentCases,\n icon,\n color,\n followed,\n onFollowedChange,\n onEdit,\n actions,\n promotedActions,\n\n // Summary content and state props\n summaryFields,\n summaryExpanded: summaryExpandedProp = true,\n onToggleSummary,\n\n // Case tabs\n tabs: { currentTabId, items: tabItemsProp, onClick: onTabClick },\n\n // Workarea related content props\n banners,\n stages,\n tasks,\n tabContent: tabContentProp = [],\n\n // Utilities content and state props\n utilities,\n utilitiesSummaryItems,\n utilitiesExpanded: utilitiesExpandedProp = true,\n onToggleUtilities,\n\n // Etc...\n persistentUtility,\n intelligentGuidance,\n isPreview = false,\n // Gen AI coach props\n genAICoachProps,\n collaboration,\n ...restProps\n}: CaseViewProps) => {\n const testIds = useTestIds(testId, getCaseViewTestIds);\n\n // General util hooks\n const t = useI18n();\n const theme = useTheme();\n const { previewActive } = useContext(AppShellContext);\n const { start, end } = useDirection();\n const { loadedRef } = useConfiguration();\n\n // Element refs\n const [caseViewEl, setCaseViewEl] = useElement<HTMLDivElement>();\n const caseViewRef = useConsolidatedRef(setCaseViewEl);\n const summaryRef = useRef<HTMLDivElement>(null);\n // undefined used to allow ref to be mutable. Element set below in ref callback for scroll stick.\n const workAreaRef = useRef<HTMLDivElement | undefined>();\n const toggleButtonRef = useRef<HTMLButtonElement>(null);\n const persistentUtilityButtonRef = useRef<HTMLButtonElement>(null);\n const isToggleButtonFocused = useRef(false);\n const isPersistentUtilityButtonFocused = useRef(false);\n const tabsRef = useRef<HTMLElement>(null);\n // Tab content\n const [tabContentEl, setTabContentEl] = useElement<HTMLElement>(null);\n // Gen AI coach state\n const genAICoachButtonRef = useRef<HTMLButtonElement>(null);\n const [showCoach, setShowCoach] = useState(false);\n const [genAIState, setGenAIState] = useState<State>('minimized');\n\n // Breakpoint booleans\n const smOrAbove = useBreakpoint('sm');\n const mdOrAbove = useBreakpoint('md', { breakpointRef: caseViewRef });\n const lgOrAbove = useBreakpoint('lg', { breakpointRef: caseViewRef });\n const xlOrAbove = useBreakpoint('xl', { breakpointRef: caseViewRef });\n\n // DOM ids\n const initialTabId = tabItemsProp[0]?.id;\n const summaryTabId = `summary-${caseId}`;\n const utilitiesTabId = `utilities-${caseId}`;\n const persistentUtilityTabId = `persistent-utility-${caseId}`;\n const genAICoachTabId = `gen-ai-coach-${caseId}`;\n\n // Summary state handling\n let summaryExpanded = !isPreview && !!summaryExpandedProp;\n\n const [summaryHeightPx, setSummaryHeightPx] = useState(0);\n const prevSummaryHeightPx = usePrevious(summaryHeightPx);\n\n if (persistentUtility) {\n summaryExpanded = xlOrAbove;\n }\n\n const [persistentUtilityExpanded, setPersistentUtilityExpanded] = useState(false);\n\n // Focus heading on initial mount\n useEffect(() => {\n if (!caseViewRef.current) return;\n\n if (loadedRef.current) {\n focusHeadingOrContainer(caseViewRef.current, heading);\n } else {\n loadedRef.current = true;\n }\n }, [caseId]);\n\n // Utilities state handling\n\n // Used in coordination with a layoutEffect below to determine the utilities state on initial render.\n // Attempted with a ref but it did not work. Using state and enforcing a render in addition to the change render for lgOrAbove seems to fix...\n const [obeyUtilitiesExpandedProp, setObeyUtilitiesExpandedProp] = useState(lgOrAbove);\n\n // Allow the utilitiesExpandedProp to drive the utilities' state after the initial render\n useLayoutEffect(() => {\n if (lgOrAbove) setObeyUtilitiesExpandedProp(true);\n }, [lgOrAbove]);\n\n // Tracks whether a resize forced the onToggleUtilities to close the utilities when it's a drawer\n const utilitiesToggledByResize = useRef(false);\n\n // FIXME: Necessary to avoid utilitiesAndGenAI being mounted for a single render frame ⬇\n // only to be unmounted the next frame. This occurs with the utilities drawer in either direction.\n // Augments what obeyUtilitiesExpandedProp is already doing but we can not set that state ⬇\n // fast enough prior to the render. A larger refactor of state to a reducer could clean some of this up. Yuck.\n const previousLgOrAbove = usePrevious(lgOrAbove);\n const previousMdOrAbove = usePrevious(mdOrAbove);\n const justWentFromLGtoMD = previousLgOrAbove === true && lgOrAbove === false;\n const justWentFromSMtoMD = previousMdOrAbove === false && mdOrAbove === true;\n\n // If the initial render is within the MD size, where the utility drawer renders, it must begin collapsed. In CasePreview utilities should always remain collapsed.\n const utilitiesExpanded =\n !isPreview && obeyUtilitiesExpandedProp && !justWentFromLGtoMD && !justWentFromSMtoMD\n ? utilitiesExpandedProp\n : false;\n\n // Handles utilities state based on breakpoint changes.\n useAfterInitialEffect(() => {\n // If we change into the MD breakpoint range and the utilities state is expanded call the toggle prop to collapse it with controlled state\n if (mdOrAbove && !lgOrAbove && utilitiesExpandedProp) {\n onToggleUtilities?.();\n utilitiesToggledByResize.current = true;\n }\n\n if (lgOrAbove) {\n if (utilitiesToggledByResize.current && !utilitiesExpandedProp) {\n onToggleUtilities?.();\n }\n\n utilitiesToggledByResize.current = false;\n }\n // Purposely not listing utilitiesExpanded as a dependency as it is not a trigger and will be captured when BPs change\n }, [mdOrAbove, lgOrAbove]);\n\n // Handles focus of toggle button when toggled in drawer mode and when browser is resized\n useEffect(() => {\n if (isToggleButtonFocused.current) {\n toggleButtonRef.current?.focus();\n }\n\n if (!toggleButtonRef.current) {\n // Toggle button is not on DOM.\n isToggleButtonFocused.current = false;\n }\n }, [utilitiesExpanded, mdOrAbove, lgOrAbove]);\n\n useEffect(() => {\n if (isPersistentUtilityButtonFocused.current) {\n persistentUtilityButtonRef.current?.focus();\n }\n\n if (!persistentUtilityButtonRef.current) {\n isPersistentUtilityButtonFocused.current = false;\n }\n }, [persistentUtilityExpanded, mdOrAbove, lgOrAbove]);\n\n // Prepare tabs\n const [tabItems, tabContent] = useMemo(() => {\n const summaryTab = { id: summaryTabId, name: t('summary') };\n const summaryTabContent = {\n id: summaryTabId,\n content: (\n <Card>\n <StyledSummaryTabContent>\n <StyledSummaryHeading variant='h2'>{summaryTab.name}</StyledSummaryHeading>\n <CaseSummaryFields {...summaryFields} />\n </StyledSummaryTabContent>\n </Card>\n )\n };\n\n let items = tabItemsProp;\n let content = tabContentProp;\n\n if (mdOrAbove && !isPreview) {\n if (!summaryExpanded || (persistentUtility && !xlOrAbove)) {\n items = [summaryTab, ...tabItemsProp];\n content = [summaryTabContent, ...tabContentProp];\n }\n\n return [items, content];\n }\n\n const utilityTabsItems = [];\n const utilityTabsContent = [];\n\n if (utilities) {\n utilityTabsItems.push({ id: utilitiesTabId, name: t('utilities') });\n utilityTabsContent.push({\n id: utilitiesTabId,\n content: <Flex container={{ direction: 'column', gap: 2 }}>{utilities}</Flex>\n });\n }\n\n if (persistentUtility) {\n utilityTabsItems.push({ id: persistentUtilityTabId, name: persistentUtility.title });\n utilityTabsContent.push({ id: persistentUtilityTabId, content: persistentUtility?.content });\n }\n\n items = [summaryTab, ...tabItemsProp, ...utilityTabsItems];\n content = [summaryTabContent, ...tabContentProp, ...utilityTabsContent];\n\n if (genAICoachProps) {\n const genAICoachTabItem: Tab = { id: genAICoachTabId, name: t('chat_with_ai') };\n items.push(genAICoachTabItem);\n content.push({\n id: genAICoachTabId,\n content: <GenAICoach {...genAICoachProps} variant={{ placement: 'fullpage' }} />\n });\n }\n\n return [items, content];\n }, [\n tabItemsProp,\n summaryTabId,\n mdOrAbove,\n summaryExpanded,\n persistentUtility,\n xlOrAbove,\n tabContentProp,\n utilities,\n utilitiesTabId,\n persistentUtilityTabId\n ]);\n\n // Grid layout props\n let caseViewGridContainer = {\n cols: 'minmax(0, 1fr)',\n colGap: 0,\n rows: 'minmax(0, max-content) auto',\n areas: `\n \"summary\"\n \"work-area\"\n `\n };\n\n const sharedGridProps = {\n colGap: 2,\n rows: caseViewGridContainer.rows\n };\n\n if (persistentUtility) {\n if (xlOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: persistentUtilityExpanded\n ? 'minmax(0, max-content) repeat(2, minmax(0, 1fr)) minmax(0, max-content)'\n : 'minmax(0, max-content) minmax(0, 1fr) repeat(2, minmax(0, max-content))',\n\n areas: '\"summary work-area persistentUtility utilities\"'\n };\n } else if (mdOrAbove) {\n if (persistentUtilityExpanded) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'repeat(2, minmax(0, 1fr)) minmax(0, max-content)', // Work-area and PersistentUtility take equal space\n areas: `\n \"summary summary summary\"\n \"work-area persistentUtility utilities\"\n `\n };\n } else {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, 1fr) repeat(2, minmax(0, max-content))',\n areas: `\n \"summary summary summary\"\n \"work-area persistentUtility utilities\"\n `\n };\n }\n }\n } else if (summaryExpanded) {\n if (mdOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, max-content) minmax(0, 1fr) minmax(0, max-content)',\n areas: '\"summary work-area utilities\"'\n };\n }\n } else if (mdOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, 1fr) minmax(0, max-content)',\n areas: `\n \"summary summary\"\n \"work-area utilities\"\n `\n };\n }\n // Apply sticky columns\n const scrollStickOptions = useRef<ScrollStickOptions>({\n elements: [null, null]\n });\n\n const stickOffset = useMemo(() => {\n if (!windowIsAvailable || !caseViewEl) return 0;\n\n const styles = window.getComputedStyle(caseViewEl);\n const rootStyles = getComputedStyle(document.documentElement);\n const stickyOffsetRaw = parseFloat(styles.getPropertyValue('--appshell-sticky-offset'));\n const topOffsetRaw = parseFloat(rootStyles.getPropertyValue('--appshell-top-offset'));\n const appshellOffset =\n (!Number.isNaN(stickyOffsetRaw) && stickyOffsetRaw >= 0\n ? stickyOffsetRaw\n : parseFloat(styles.getPropertyValue('--appshell-offset')) || 0) +\n (!Number.isNaN(topOffsetRaw) ? topOffsetRaw : 0);\n\n const spacingStr = theme.base.spacing;\n const spacingPx = parseFloat(spacingStr) * parseFloat(rootStyles.fontSize);\n\n return appshellOffset + summaryHeightPx + 2 * spacingPx;\n }, [caseViewEl, summaryHeightPx, theme.base.spacing]);\n\n useScrollStick(\n // isMediumOrAbove means side by side columns | | |\n mdOrAbove ? { ...scrollStickOptions.current, offset: stickOffset } : undefined\n );\n\n // Preview set summary tab active\n useEffect(() => {\n if (isPreview) {\n onTabClick(summaryTabId);\n }\n }, []);\n\n // Initial tab selection\n useEffect(() => {\n if (\n mdOrAbove &&\n summaryExpanded &&\n !persistentUtility &&\n (currentTabId === summaryTabId || currentTabId === utilitiesTabId)\n ) {\n onTabClick(tabItemsProp[0]?.id);\n }\n // Toggle utilities tab selection\n if (mdOrAbove && [utilitiesTabId, persistentUtilityTabId].includes(currentTabId)) {\n onTabClick(initialTabId);\n }\n }, [mdOrAbove]);\n\n // Initial / summary tab selection\n useEffect(() => {\n if (!smOrAbove && currentTabId === initialTabId) {\n onTabClick(summaryTabId);\n } else if (smOrAbove && currentTabId === summaryTabId) {\n onTabClick(initialTabId);\n }\n }, [smOrAbove]);\n\n // Summary tab selection\n useEffect(() => {\n if (isPreview) {\n onTabClick(summaryTabId);\n }\n }, [isPreview]);\n\n // Initial tab selection\n useEffect(() => {\n if (summaryExpanded && currentTabId === summaryTabId) {\n onTabClick(initialTabId);\n }\n }, [summaryExpanded]);\n\n // Handles scrolling to tab content for newly clicked tab\n useEffect(() => {\n if (!tabContentEl) return;\n const scrollPos = window.scrollY;\n const windowHeight = document.documentElement.clientHeight;\n const bottomPos = scrollPos + windowHeight * 0.8;\n const tabContentPos = tabContentEl.offsetTop;\n if (tabContentPos > bottomPos) {\n const top = tabContentPos - windowHeight * 0.2;\n window.scrollTo({ top, behavior: 'smooth' });\n }\n }, [currentTabId]);\n\n // We need a css variable for the height of the case summary when it is collapsed into a header like layout\n useLayoutEffect(() => {\n const rafId = requestAnimationFrame(() => {\n if (!caseViewRef.current || !summaryRef.current) return;\n\n const newHeight = summaryExpanded ? 0 : summaryRef.current.offsetHeight;\n caseViewRef.current.style.setProperty('--summary-height', `${newHeight}px`);\n setSummaryHeightPx(newHeight);\n });\n\n return () => cancelAnimationFrame(rafId);\n }, [summaryExpanded, collaboration, prevSummaryHeightPx]);\n\n const utilitiesAndGenAI = (\n <>\n <Flex as={StyledUtilitiesWrapper} container={{ gap: 2, direction: 'column' }}>\n {utilities}\n </Flex>\n {genAICoachProps && (\n <GenAICoach\n {...genAICoachProps}\n variant={{\n placement: 'utilities',\n state: genAIState,\n onStateChange: (state: State) => {\n genAICoachProps.onStateChange?.(state);\n setGenAIState(state);\n }\n }}\n />\n )}\n </>\n );\n\n // CaseView context value\n // Choosing not to memo for now due to extent of deps and how often they change. Optimize as needed.\n // eslint-disable-next-line react/jsx-no-constructed-context-values\n const ctxValue: CaseViewContextValue = {\n testIds,\n caseId,\n heading,\n subheading,\n caseType,\n caseLink,\n parentCases,\n icon,\n color,\n followed,\n onFollowedChange,\n actions,\n promotedActions,\n onEdit,\n summaryFields,\n tabs: {\n items: tabItems,\n onClick: onTabClick,\n currentTabId\n },\n stages,\n tasks,\n persistentUtility,\n intelligentGuidance,\n collaboration,\n summaryExpanded,\n utilitiesExpanded,\n onToggleSummary,\n isPreview,\n hasGenAICoach: !!genAICoachProps,\n aboveSM: smOrAbove,\n aboveMD: mdOrAbove,\n aboveLG: lgOrAbove,\n aboveXL: xlOrAbove\n };\n\n const [tabPanelEls, getTabPanelCbRef] = useRefMap<HTMLDivElement>();\n\n // The following effects are dedicated to resizeTable handling.\n useLayoutEffect(() => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n const currentTabPanelEl = tabPanelEls.get(currentTabId)!;\n const workAreaEl = workAreaRef.current;\n\n resizeTable(currentTabPanelEl, workAreaEl);\n\n const onTabChange = () => {\n resizeTable(currentTabPanelEl, workAreaEl);\n };\n\n // TODO: optimize\n const mo = new MutationObserver(() => {\n resizeTable(currentTabPanelEl, workAreaEl);\n });\n\n mo.observe(currentTabPanelEl, { childList: true, subtree: true });\n\n currentTabPanelEl.addEventListener('cosmos-tab-changed', onTabChange);\n\n return () => {\n mo.disconnect();\n currentTabPanelEl.removeEventListener('cosmos-tab-changed', onTabChange);\n };\n });\n\n const [bannersStagesTasksEl, setBannersStagesTasksEl] = useElement<HTMLDivElement>(null);\n\n useEffect(() => {\n if (!bannersStagesTasksEl) return;\n\n const observer = new ResizeObserver(() => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n resizeTable(tabPanelEls.get(currentTabId)!, workAreaRef.current);\n });\n\n observer.observe(bannersStagesTasksEl);\n\n return () => {\n observer.disconnect();\n };\n }, [bannersStagesTasksEl, currentTabId]);\n\n useEffect(() => {\n const onResize = () => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n resizeTable(tabPanelEls.get(currentTabId)!, workAreaRef.current);\n };\n\n window.addEventListener('resize', onResize);\n\n return () => {\n window.removeEventListener('resize', onResize);\n };\n }, [currentTabId]);\n\n const utilitiesHeading = (\n <StyledUtilitiesHeading variant='h2'>{t('utilities')}</StyledUtilitiesHeading>\n );\n\n const utilitiesToggleButton = !isPreview && (\n <StyledExpandCollapseUtilitiesButton\n compact\n icon\n label={t(utilitiesExpanded ? 'collapse' : 'expand')}\n aria-label={t(utilitiesExpanded ? 'collapse_utilities_panel' : 'expand_utilities_panel')}\n onClick={() => {\n if (!obeyUtilitiesExpandedProp && utilitiesExpandedProp) {\n setObeyUtilitiesExpandedProp(true);\n } else {\n onToggleUtilities?.();\n }\n }}\n onFocus={() => {\n isToggleButtonFocused.current = true;\n }}\n onBlur={() => {\n isToggleButtonFocused.current = false;\n }}\n ref={toggleButtonRef}\n >\n <Icon name={utilitiesExpanded ? `arrow-micro-${end}` : `arrow-micro-${start}`} />\n </StyledExpandCollapseUtilitiesButton>\n );\n\n const persistentUtilityToggleButton = persistentUtility && (\n <StyledExpandCollapseUtilitiesButton\n compact\n icon\n label={t(persistentUtilityExpanded ? 'collapse' : 'expand')}\n aria-label={t(persistentUtilityExpanded ? 'collapse_noun' : 'expand_noun', [\n persistentUtility.title\n ])}\n onClick={() => {\n setPersistentUtilityExpanded(prevState => !prevState);\n if (utilitiesExpanded) {\n onToggleUtilities?.();\n }\n }}\n onFocus={() => {\n isPersistentUtilityButtonFocused.current = true;\n }}\n onBlur={() => {\n isPersistentUtilityButtonFocused.current = false;\n }}\n ref={persistentUtilityButtonRef}\n >\n <Icon name={persistentUtilityExpanded ? 'dock' : 'undock'} />\n </StyledExpandCollapseUtilitiesButton>\n );\n\n const shouldRenderMobileTabs =\n !mdOrAbove || (persistentUtility && !xlOrAbove) || !summaryExpanded;\n // Here we go...\n return (\n <>\n <CaseViewContext.Provider value={ctxValue}>\n {/* Root element */}\n <Grid\n data-testid={testIds.root}\n {...restProps}\n as={StyledCaseView}\n ref={caseViewRef}\n container={caseViewGridContainer}\n item={{ area: 'case-view' }}\n >\n {/* Summary */}\n <Grid\n as={StyledSummary}\n item={{ area: 'summary' }}\n desktop={mdOrAbove && (!persistentUtility || xlOrAbove) && !summaryExpanded}\n isLargeOrAbove={lgOrAbove}\n ref={summaryRef}\n >\n <CaseSummary tabsRef={tabsRef} />\n </Grid>\n\n {/* Work area */}\n <Flex\n container={{\n direction: 'column',\n alignContent: 'start',\n rowGap: 2\n }}\n as={StyledWorkArea}\n persistentUtility={Boolean(persistentUtility)}\n ref={(el: HTMLDivElement) => {\n workAreaRef.current = el;\n scrollStickOptions.current.elements[0] = el;\n }}\n data-app-region\n aria-label={t('case_work_area')}\n >\n {(banners || stages || tasks) && (\n <Flex\n container={{\n direction: 'column',\n alignContent: 'start',\n rowGap: 2\n }}\n as={StyledBannersStagesTasksContainer}\n ref={setBannersStagesTasksEl}\n >\n {banners && <div data-testid={testIds.banners}>{banners}</div>}\n {stages && <div data-testid={testIds.stages}>{stages}</div>}\n {tasks && (\n <StyledTasks\n onFocus={e => {\n if (e.target?.matches('[data-focusable-form-heading]')) {\n window.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n }\n }}\n data-testid={testIds.tasks}\n >\n {tasks}\n </StyledTasks>\n )}\n </Flex>\n )}\n\n <Flex container={{ direction: 'column', alignContent: 'start' }}>\n {shouldRenderMobileTabs && (\n <Tabs\n data-testid={testIds.tabs}\n tabs={tabItems}\n onTabClick={onTabClick}\n currentTabId={currentTabId}\n aria-label={t(isPreview ? 'case_preview_tabs' : 'case_tabs')}\n ref={tabsRef}\n />\n )}\n\n <StyledTabPanelWrapper ref={setTabContentEl}>\n {tabContent?.map(({ id, content }) => (\n <TabPanel\n data-testid={currentTabId === id ? testIds.tabContent : undefined}\n currentTabId={currentTabId}\n tabId={id}\n key={id}\n ref={getTabPanelCbRef(id)}\n tablistRef={tabsRef}\n tablistType={shouldRenderMobileTabs ? 'horizontal' : 'vertical'}\n >\n {content}\n </TabPanel>\n ))}\n </StyledTabPanelWrapper>\n </Flex>\n </Flex>\n\n {/* Persistent utility column */}\n {persistentUtility && mdOrAbove && (\n <Grid\n as={StyledPersistentUtility}\n item={{ area: 'persistentUtility' }}\n data-app-region\n aria-label={t('utilities_label')}\n persistentUtilityExpanded={persistentUtilityExpanded}\n >\n {persistentUtility.showExpand ? (\n <Flex\n container={{\n direction: 'column',\n gap: persistentUtilityExpanded ? undefined : 2\n }}\n as={StyledPersistentContainer}\n >\n {persistentUtilityExpanded ? (\n <Card as={StyledPersistentContainer}>\n <CardHeader>\n <Text variant='h2'>{persistentUtility.title}</Text>\n {persistentUtilityToggleButton}\n </CardHeader>\n <Flex container={{ direction: 'column' }} as={StyledPersistentContent}>\n {persistentUtility.content}\n </Flex>\n </Card>\n ) : (\n <>\n <Flex\n container={{\n justify: 'between',\n alignItems: 'center',\n pad: [undefined, 0.5, undefined, undefined]\n }}\n >\n <Text variant='h2'>{persistentUtility.title}</Text>\n {persistentUtilityToggleButton}\n </Flex>\n <Flex container={{ direction: 'column' }} as={StyledPersistentContent}>\n {persistentUtility.content}\n </Flex>\n </>\n )}\n </Flex>\n ) : (\n <>{persistentUtility.content}</>\n )}\n </Grid>\n )}\n\n {/* Utility drawer */}\n {(utilities || genAICoachProps) && mdOrAbove && !lgOrAbove && utilitiesExpanded && (\n <Drawer\n as={StyledCaseDrawer}\n open={utilitiesExpanded}\n previewActive={previewActive}\n position='fixed'\n placement={end}\n shadow\n nullWhenClosed\n utilitiesExpanded={!!utilitiesExpanded}\n hasPersistentUtility={!!persistentUtility}\n >\n <Flex\n as={StyledCaseDrawerContent}\n container={{ direction: 'column', gap: 2 }}\n data-app-region\n aria-label={t('utilities_label')}\n >\n <Flex container={{ alignItems: 'center', justify: 'between' }}>\n {utilitiesHeading}\n {utilitiesToggleButton}\n </Flex>\n {utilitiesAndGenAI}\n </Flex>\n </Drawer>\n )}\n\n {/* Utilities */}\n {(utilities || genAICoachProps) && mdOrAbove && !isPreview && (\n <Grid\n data-testid={testIds.utilities}\n ref={(el: HTMLDivElement) => {\n scrollStickOptions.current.elements[1] = el;\n }}\n as={StyledUtilities}\n container={{\n cols: 'minmax(0, 1fr)',\n rowGap: 2\n }}\n item={{\n area: 'utilities'\n }}\n data-app-region={lgOrAbove || !utilitiesExpanded || undefined}\n aria-label={t('utilities_label')}\n >\n <Flex\n container={{\n alignItems: 'center',\n justify: utilitiesExpanded ? 'between' : 'center'\n }}\n >\n {utilitiesHeading}\n {!lgOrAbove && utilitiesExpanded ? null : utilitiesToggleButton}\n </Flex>\n\n {utilitiesExpanded && lgOrAbove && utilitiesAndGenAI}\n\n {(!utilitiesExpanded || (mdOrAbove && !lgOrAbove)) && (\n <>\n {utilitiesSummaryItems && utilitiesSummaryItems.length > 0 && (\n <UtilitiesSummary\n items={utilitiesSummaryItems}\n isExpanded={utilitiesExpanded}\n />\n )}\n\n {genAICoachProps && (\n <StyledCoachButton\n iconOnly\n variant='primary'\n ref={genAICoachButtonRef}\n onClick={() => setShowCoach(cur => !cur)}\n label={t('chat_with_ai')}\n />\n )}\n </>\n )}\n </Grid>\n )}\n {genAICoachButtonRef.current && genAICoachProps && showCoach && (\n <UtilitySummaryItemDialog\n name={t('chat_with_ai')}\n target={genAICoachButtonRef.current}\n onDismiss={() => setShowCoach(false)}\n >\n <GenAICoach\n {...genAICoachProps}\n variant={{\n placement: 'dialog',\n onClose: () => {\n genAICoachProps.onClose?.();\n setShowCoach(false);\n genAICoachButtonRef.current?.focus();\n }\n }}\n />\n </UtilitySummaryItemDialog>\n )}\n </Grid>\n </CaseViewContext.Provider>\n {intelligentGuidance}\n </>\n );\n};\n\nexport default withTestIds(CaseView, getCaseViewTestIds);\n"]}
|
|
1
|
+
{"version":3,"file":"CaseView.js","sourceRoot":"","sources":["../../../src/components/CaseView/CaseView.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,MAAM,EAAE,eAAe,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAG1F,OAAO,EACL,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,YAAY,EACZ,IAAI,EACJ,QAAQ,EACR,aAAa,EACb,cAAc,EACd,UAAU,EACV,IAAI,EACJ,MAAM,EACN,OAAO,EACP,YAAY,EACZ,qBAA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CACZ,eAAe,CAAC,OAAO,EAAE,EAAE,CAAC;wCAC5B,YAAY,CAAC,KAAK,CAAC,CAAC;wCACpB,mBAAmB,CAAC,OAAO,EAAE,KAAK,EAAE,CAAC;oCACvC,CAAC;iCACF,GACD,GACuB,CAC5B,IACI,GACkB,EAC1B,mBAAmB,IACnB,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,WAAW,CAAC,QAAQ,EAAE,kBAAkB,CAAC,CAAC","sourcesContent":["import { useEffect, useMemo, useRef, useLayoutEffect, useState, useContext } from 'react';\nimport type { FC } from 'react';\n\nimport {\n Flex,\n Grid,\n Icon,\n registerIcon,\n Text,\n TabPanel,\n useBreakpoint,\n useScrollStick,\n useElement,\n Card,\n Drawer,\n useI18n,\n useDirection,\n useAfterInitialEffect,\n windowIsAvailable,\n focusHeadingOrContainer,\n useConfiguration,\n useRefMap,\n useTestIds,\n withTestIds,\n AppShellContext,\n useConsolidatedRef,\n Tabs,\n CardHeader,\n useTheme,\n usePrevious\n} from '@pega/cosmos-react-core';\nimport type { ForwardProps, Tab } from '@pega/cosmos-react-core';\nimport type { ScrollStickOptions } from '@pega/cosmos-react-core/lib/hooks/useScrollStick';\nimport * as moveRightSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/move-right-solid.icon';\nimport * as moveLeftSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/move-left-solid.icon';\nimport * as polarisSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/polaris-solid.icon';\nimport * as arrowMicroRightIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/arrow-micro-right.icon';\nimport * as arrowMicroLeftIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/arrow-micro-left.icon';\nimport * as dockIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/dock.icon';\nimport * as unDockIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/undock.icon';\n\nimport GenAICoach from '../GenAICoach';\nimport type { State } from '../GenAICoach/GenAICoach.types';\n\nimport CaseSummary from './CaseSummary';\nimport UtilitiesSummary from './UtilitiesSummary';\nimport {\n StyledCaseDrawer,\n StyledCaseDrawerContent,\n StyledCaseView,\n StyledWorkArea,\n StyledPersistentUtility,\n StyledPersistentContainer,\n StyledSummary,\n StyledSummaryTabContent,\n StyledUtilities,\n StyledExpandCollapseUtilitiesButton,\n StyledUtilitiesHeading,\n StyledCoachButton,\n StyledUtilitiesWrapper,\n StyledPersistentContent,\n StyledSummaryHeading,\n StyledTasks,\n StyledTabPanelWrapper,\n StyledBannersStagesTasksContainer\n} from './CaseView.styles';\nimport type { CaseViewContextValue, CaseViewProps } from './CaseView.types';\nimport CaseViewContext from './CaseView.context';\nimport CaseSummaryFields from './CaseSummaryFields';\nimport { getCaseViewTestIds } from './CaseView.test-ids';\nimport UtilitySummaryItemDialog from './UtilitySummaryItemDialog';\n\nregisterIcon(\n moveRightSolidIcon,\n moveLeftSolidIcon,\n polarisSolidIcon,\n arrowMicroRightIcon,\n arrowMicroLeftIcon,\n dockIcon,\n unDockIcon\n);\n\n// This function is responsible for auto sizing table height in case tab panels.\nconst resizeTable = (tabPanelEl: HTMLDivElement, workAreaEl: HTMLDivElement) => {\n tabPanelEl.style.removeProperty('--content-height-in-view');\n\n // .rs-wrapper is currently the class used by the table component which needs to be targeted.\n const tables = Array.from(tabPanelEl.querySelectorAll('.rs-wrapper')).filter(\n table => table.getBoundingClientRect().width !== 0\n );\n\n // Only perform this logic when there is a single table in a tab's panel.\n if (tables.length !== 1) return;\n\n // This selector finds the table's root element as they are always wrapped in a Card.\n const table = tables[0].closest('article');\n\n if (!table) return;\n\n const tabPanelRect = tabPanelEl.getBoundingClientRect();\n const tableRect = table.getBoundingClientRect();\n const vpHeight = document.documentElement.clientHeight;\n const tableRectOffsetTop = tableRect.top + window.scrollY;\n const workAreaPaddingBlockEnd =\n // px unit are required for proper CSS calc calculation.\n window.getComputedStyle(workAreaEl).getPropertyValue('padding-block-end') || '0px';\n\n // Accounts for content rendered after the table.\n const tableBottomToTabPanelBottom = tabPanelRect.bottom - tableRect.bottom;\n\n // Sets a CSS variable for available height based on screen size and view state.\n // Defines an available minimum height of ~600px.\n tabPanelEl.style.setProperty(\n '--content-height-in-view',\n `max(calc(${\n vpHeight - tableRectOffsetTop - tableBottomToTabPanelBottom\n }px - ${workAreaPaddingBlockEnd}), 37.5rem)`\n );\n};\n\nconst CaseView: FC<CaseViewProps & ForwardProps> = ({\n testId,\n\n // Case data mostly visually related to the case header\n caseId,\n heading,\n subheading,\n caseType,\n caseLink,\n parentCases,\n icon,\n color,\n followed,\n onFollowedChange,\n onEdit,\n actions,\n promotedActions,\n\n // Summary content and state props\n summaryFields,\n summaryExpanded: summaryExpandedProp = true,\n onToggleSummary,\n\n // Case tabs\n tabs: { currentTabId, items: tabItemsProp, onClick: onTabClick },\n\n // Workarea related content props\n banners,\n stages,\n tasks,\n tabContent: tabContentProp = [],\n\n // Utilities content and state props\n utilities,\n utilitiesSummaryItems,\n utilitiesExpanded: utilitiesExpandedProp = true,\n onToggleUtilities,\n\n // Etc...\n persistentUtility,\n intelligentGuidance,\n isPreview = false,\n // Gen AI coach props\n genAICoachProps,\n collaboration,\n ...restProps\n}: CaseViewProps) => {\n const testIds = useTestIds(testId, getCaseViewTestIds);\n\n // General util hooks\n const t = useI18n();\n const theme = useTheme();\n const { previewActive } = useContext(AppShellContext);\n const { start, end } = useDirection();\n const { loadedRef } = useConfiguration();\n\n // Element refs\n const [caseViewEl, setCaseViewEl] = useElement<HTMLDivElement>();\n const caseViewRef = useConsolidatedRef(setCaseViewEl);\n const summaryRef = useRef<HTMLDivElement>(null);\n // undefined used to allow ref to be mutable. Element set below in ref callback for scroll stick.\n const workAreaRef = useRef<HTMLDivElement | undefined>();\n const toggleButtonRef = useRef<HTMLButtonElement>(null);\n const persistentUtilityButtonRef = useRef<HTMLButtonElement>(null);\n const isToggleButtonFocused = useRef(false);\n const isPersistentUtilityButtonFocused = useRef(false);\n const tabsRef = useRef<HTMLElement>(null);\n // Tab content\n const [tabContentEl, setTabContentEl] = useElement<HTMLElement>(null);\n // Gen AI coach state\n const genAICoachButtonRef = useRef<HTMLButtonElement>(null);\n const [showCoach, setShowCoach] = useState(false);\n const [genAIState, setGenAIState] = useState<State>('minimized');\n\n // Breakpoint booleans\n const smOrAbove = useBreakpoint('sm');\n const mdOrAbove = useBreakpoint('md', { breakpointRef: caseViewRef });\n const lgOrAbove = useBreakpoint('lg', { breakpointRef: caseViewRef });\n const xlOrAbove = useBreakpoint('xl', { breakpointRef: caseViewRef });\n\n // DOM ids\n const initialTabId = tabItemsProp[0]?.id;\n const summaryTabId = `summary-${caseId}`;\n const utilitiesTabId = `utilities-${caseId}`;\n const persistentUtilityTabId = `persistent-utility-${caseId}`;\n const genAICoachTabId = `gen-ai-coach-${caseId}`;\n\n // Summary state handling\n let summaryExpanded = !isPreview && !!summaryExpandedProp;\n\n const [summaryHeightPx, setSummaryHeightPx] = useState(0);\n const prevSummaryHeightPx = usePrevious(summaryHeightPx);\n\n if (persistentUtility) {\n summaryExpanded = xlOrAbove;\n }\n\n const [persistentUtilityExpanded, setPersistentUtilityExpanded] = useState(false);\n\n // Focus heading on initial mount\n useEffect(() => {\n if (!caseViewRef.current) return;\n\n if (loadedRef.current) {\n focusHeadingOrContainer(\n caseViewRef.current,\n typeof heading === 'string' ? heading : heading.text\n );\n } else {\n loadedRef.current = true;\n }\n }, [caseId]);\n\n // Utilities state handling\n\n // Used in coordination with a layoutEffect below to determine the utilities state on initial render.\n // Attempted with a ref but it did not work. Using state and enforcing a render in addition to the change render for lgOrAbove seems to fix...\n const [obeyUtilitiesExpandedProp, setObeyUtilitiesExpandedProp] = useState(lgOrAbove);\n\n // Allow the utilitiesExpandedProp to drive the utilities' state after the initial render\n useLayoutEffect(() => {\n if (lgOrAbove) setObeyUtilitiesExpandedProp(true);\n }, [lgOrAbove]);\n\n // Tracks whether a resize forced the onToggleUtilities to close the utilities when it's a drawer\n const utilitiesToggledByResize = useRef(false);\n\n // FIXME: Necessary to avoid utilitiesAndGenAI being mounted for a single render frame ⬇\n // only to be unmounted the next frame. This occurs with the utilities drawer in either direction.\n // Augments what obeyUtilitiesExpandedProp is already doing but we can not set that state ⬇\n // fast enough prior to the render. A larger refactor of state to a reducer could clean some of this up. Yuck.\n const previousLgOrAbove = usePrevious(lgOrAbove);\n const previousMdOrAbove = usePrevious(mdOrAbove);\n const justWentFromLGtoMD = previousLgOrAbove === true && lgOrAbove === false;\n const justWentFromSMtoMD = previousMdOrAbove === false && mdOrAbove === true;\n\n // If the initial render is within the MD size, where the utility drawer renders, it must begin collapsed. In CasePreview utilities should always remain collapsed.\n const utilitiesExpanded =\n !isPreview && obeyUtilitiesExpandedProp && !justWentFromLGtoMD && !justWentFromSMtoMD\n ? utilitiesExpandedProp\n : false;\n\n // Handles utilities state based on breakpoint changes.\n useAfterInitialEffect(() => {\n // If we change into the MD breakpoint range and the utilities state is expanded call the toggle prop to collapse it with controlled state\n if (mdOrAbove && !lgOrAbove && utilitiesExpandedProp) {\n onToggleUtilities?.();\n utilitiesToggledByResize.current = true;\n }\n\n if (lgOrAbove) {\n if (utilitiesToggledByResize.current && !utilitiesExpandedProp) {\n onToggleUtilities?.();\n }\n\n utilitiesToggledByResize.current = false;\n }\n // Purposely not listing utilitiesExpanded as a dependency as it is not a trigger and will be captured when BPs change\n }, [mdOrAbove, lgOrAbove]);\n\n // Handles focus of toggle button when toggled in drawer mode and when browser is resized\n useEffect(() => {\n if (isToggleButtonFocused.current) {\n toggleButtonRef.current?.focus();\n }\n\n if (!toggleButtonRef.current) {\n // Toggle button is not on DOM.\n isToggleButtonFocused.current = false;\n }\n }, [utilitiesExpanded, mdOrAbove, lgOrAbove]);\n\n useEffect(() => {\n if (isPersistentUtilityButtonFocused.current) {\n persistentUtilityButtonRef.current?.focus();\n }\n\n if (!persistentUtilityButtonRef.current) {\n isPersistentUtilityButtonFocused.current = false;\n }\n }, [persistentUtilityExpanded, mdOrAbove, lgOrAbove]);\n\n // Prepare tabs\n const [tabItems, tabContent] = useMemo(() => {\n const summaryTab = { id: summaryTabId, name: t('summary') };\n const summaryTabContent = {\n id: summaryTabId,\n content: (\n <Card>\n <StyledSummaryTabContent>\n <StyledSummaryHeading variant='h2'>{summaryTab.name}</StyledSummaryHeading>\n <CaseSummaryFields {...summaryFields} />\n </StyledSummaryTabContent>\n </Card>\n )\n };\n\n let items = tabItemsProp;\n let content = tabContentProp;\n\n if (mdOrAbove && !isPreview) {\n if (!summaryExpanded || (persistentUtility && !xlOrAbove)) {\n items = [summaryTab, ...tabItemsProp];\n content = [summaryTabContent, ...tabContentProp];\n }\n\n return [items, content];\n }\n\n const utilityTabsItems = [];\n const utilityTabsContent = [];\n\n if (utilities) {\n utilityTabsItems.push({ id: utilitiesTabId, name: t('utilities') });\n utilityTabsContent.push({\n id: utilitiesTabId,\n content: <Flex container={{ direction: 'column', gap: 2 }}>{utilities}</Flex>\n });\n }\n\n if (persistentUtility) {\n utilityTabsItems.push({ id: persistentUtilityTabId, name: persistentUtility.title });\n utilityTabsContent.push({ id: persistentUtilityTabId, content: persistentUtility?.content });\n }\n\n items = [summaryTab, ...tabItemsProp, ...utilityTabsItems];\n content = [summaryTabContent, ...tabContentProp, ...utilityTabsContent];\n\n if (genAICoachProps) {\n const genAICoachTabItem: Tab = { id: genAICoachTabId, name: t('chat_with_ai') };\n items.push(genAICoachTabItem);\n content.push({\n id: genAICoachTabId,\n content: <GenAICoach {...genAICoachProps} variant={{ placement: 'fullpage' }} />\n });\n }\n\n return [items, content];\n }, [\n tabItemsProp,\n summaryTabId,\n mdOrAbove,\n summaryExpanded,\n persistentUtility,\n xlOrAbove,\n tabContentProp,\n utilities,\n utilitiesTabId,\n persistentUtilityTabId\n ]);\n\n // Grid layout props\n let caseViewGridContainer = {\n cols: 'minmax(0, 1fr)',\n colGap: 0,\n rows: 'minmax(0, max-content) auto',\n areas: `\n \"summary\"\n \"work-area\"\n `\n };\n\n const sharedGridProps = {\n colGap: 2,\n rows: caseViewGridContainer.rows\n };\n\n if (persistentUtility) {\n if (xlOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: persistentUtilityExpanded\n ? 'minmax(0, max-content) repeat(2, minmax(0, 1fr)) minmax(0, max-content)'\n : 'minmax(0, max-content) minmax(0, 1fr) repeat(2, minmax(0, max-content))',\n\n areas: '\"summary work-area persistentUtility utilities\"'\n };\n } else if (mdOrAbove) {\n if (persistentUtilityExpanded) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'repeat(2, minmax(0, 1fr)) minmax(0, max-content)', // Work-area and PersistentUtility take equal space\n areas: `\n \"summary summary summary\"\n \"work-area persistentUtility utilities\"\n `\n };\n } else {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, 1fr) repeat(2, minmax(0, max-content))',\n areas: `\n \"summary summary summary\"\n \"work-area persistentUtility utilities\"\n `\n };\n }\n }\n } else if (summaryExpanded) {\n if (mdOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, max-content) minmax(0, 1fr) minmax(0, max-content)',\n areas: '\"summary work-area utilities\"'\n };\n }\n } else if (mdOrAbove) {\n caseViewGridContainer = {\n ...sharedGridProps,\n cols: 'minmax(0, 1fr) minmax(0, max-content)',\n areas: `\n \"summary summary\"\n \"work-area utilities\"\n `\n };\n }\n // Apply sticky columns\n const scrollStickOptions = useRef<ScrollStickOptions>({\n elements: [null, null]\n });\n\n const stickOffset = useMemo(() => {\n if (!windowIsAvailable || !caseViewEl) return 0;\n\n const styles = window.getComputedStyle(caseViewEl);\n const rootStyles = getComputedStyle(document.documentElement);\n const stickyOffsetRaw = parseFloat(styles.getPropertyValue('--appshell-sticky-offset'));\n const topOffsetRaw = parseFloat(rootStyles.getPropertyValue('--appshell-top-offset'));\n const appshellOffset =\n (!Number.isNaN(stickyOffsetRaw) && stickyOffsetRaw >= 0\n ? stickyOffsetRaw\n : parseFloat(styles.getPropertyValue('--appshell-offset')) || 0) +\n (!Number.isNaN(topOffsetRaw) ? topOffsetRaw : 0);\n\n const spacingStr = theme.base.spacing;\n const spacingPx = parseFloat(spacingStr) * parseFloat(rootStyles.fontSize);\n\n return appshellOffset + summaryHeightPx + 2 * spacingPx;\n }, [caseViewEl, summaryHeightPx, theme.base.spacing]);\n\n useScrollStick(\n // isMediumOrAbove means side by side columns | | |\n mdOrAbove ? { ...scrollStickOptions.current, offset: stickOffset } : undefined\n );\n\n // Preview set summary tab active\n useEffect(() => {\n if (isPreview) {\n onTabClick(summaryTabId);\n }\n }, []);\n\n // Initial tab selection\n useEffect(() => {\n if (\n mdOrAbove &&\n summaryExpanded &&\n !persistentUtility &&\n (currentTabId === summaryTabId || currentTabId === utilitiesTabId)\n ) {\n onTabClick(tabItemsProp[0]?.id);\n }\n // Toggle utilities tab selection\n if (mdOrAbove && [utilitiesTabId, persistentUtilityTabId].includes(currentTabId)) {\n onTabClick(initialTabId);\n }\n }, [mdOrAbove]);\n\n // Initial / summary tab selection\n useEffect(() => {\n if (!smOrAbove && currentTabId === initialTabId) {\n onTabClick(summaryTabId);\n } else if (smOrAbove && currentTabId === summaryTabId) {\n onTabClick(initialTabId);\n }\n }, [smOrAbove]);\n\n // Summary tab selection\n useEffect(() => {\n if (isPreview) {\n onTabClick(summaryTabId);\n }\n }, [isPreview]);\n\n // Initial tab selection\n useEffect(() => {\n if (summaryExpanded && currentTabId === summaryTabId) {\n onTabClick(initialTabId);\n }\n }, [summaryExpanded]);\n\n // Handles scrolling to tab content for newly clicked tab\n useEffect(() => {\n if (!tabContentEl) return;\n const scrollPos = window.scrollY;\n const windowHeight = document.documentElement.clientHeight;\n const bottomPos = scrollPos + windowHeight * 0.8;\n const tabContentPos = tabContentEl.offsetTop;\n if (tabContentPos > bottomPos) {\n const top = tabContentPos - windowHeight * 0.2;\n window.scrollTo({ top, behavior: 'smooth' });\n }\n }, [currentTabId]);\n\n // We need a css variable for the height of the case summary when it is collapsed into a header like layout\n useLayoutEffect(() => {\n const rafId = requestAnimationFrame(() => {\n if (!caseViewRef.current || !summaryRef.current) return;\n\n const newHeight = summaryExpanded ? 0 : summaryRef.current.offsetHeight;\n caseViewRef.current.style.setProperty('--summary-height', `${newHeight}px`);\n setSummaryHeightPx(newHeight);\n });\n\n return () => cancelAnimationFrame(rafId);\n }, [summaryExpanded, collaboration, prevSummaryHeightPx]);\n\n const utilitiesAndGenAI = (\n <>\n <Flex as={StyledUtilitiesWrapper} container={{ gap: 2, direction: 'column' }}>\n {utilities}\n </Flex>\n {genAICoachProps && (\n <GenAICoach\n {...genAICoachProps}\n variant={{\n placement: 'utilities',\n state: genAIState,\n onStateChange: (state: State) => {\n genAICoachProps.onStateChange?.(state);\n setGenAIState(state);\n }\n }}\n />\n )}\n </>\n );\n\n // CaseView context value\n // Choosing not to memo for now due to extent of deps and how often they change. Optimize as needed.\n // eslint-disable-next-line react/jsx-no-constructed-context-values\n const ctxValue: CaseViewContextValue = {\n testIds,\n caseId,\n heading,\n subheading,\n caseType,\n caseLink,\n parentCases,\n icon,\n color,\n followed,\n onFollowedChange,\n actions,\n promotedActions,\n onEdit,\n summaryFields,\n tabs: {\n items: tabItems,\n onClick: onTabClick,\n currentTabId\n },\n stages,\n tasks,\n persistentUtility,\n intelligentGuidance,\n collaboration,\n summaryExpanded,\n utilitiesExpanded,\n onToggleSummary,\n isPreview,\n hasGenAICoach: !!genAICoachProps,\n aboveSM: smOrAbove,\n aboveMD: mdOrAbove,\n aboveLG: lgOrAbove,\n aboveXL: xlOrAbove\n };\n\n const [tabPanelEls, getTabPanelCbRef] = useRefMap<HTMLDivElement>();\n\n // The following effects are dedicated to resizeTable handling.\n useLayoutEffect(() => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n const currentTabPanelEl = tabPanelEls.get(currentTabId)!;\n const workAreaEl = workAreaRef.current;\n\n resizeTable(currentTabPanelEl, workAreaEl);\n\n const onTabChange = () => {\n resizeTable(currentTabPanelEl, workAreaEl);\n };\n\n // TODO: optimize\n const mo = new MutationObserver(() => {\n resizeTable(currentTabPanelEl, workAreaEl);\n });\n\n mo.observe(currentTabPanelEl, { childList: true, subtree: true });\n\n currentTabPanelEl.addEventListener('cosmos-tab-changed', onTabChange);\n\n return () => {\n mo.disconnect();\n currentTabPanelEl.removeEventListener('cosmos-tab-changed', onTabChange);\n };\n });\n\n const [bannersStagesTasksEl, setBannersStagesTasksEl] = useElement<HTMLDivElement>(null);\n\n useEffect(() => {\n if (!bannersStagesTasksEl) return;\n\n const observer = new ResizeObserver(() => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n resizeTable(tabPanelEls.get(currentTabId)!, workAreaRef.current);\n });\n\n observer.observe(bannersStagesTasksEl);\n\n return () => {\n observer.disconnect();\n };\n }, [bannersStagesTasksEl, currentTabId]);\n\n useEffect(() => {\n const onResize = () => {\n if (!tabPanelEls.has(currentTabId) || !workAreaRef.current) return;\n\n resizeTable(tabPanelEls.get(currentTabId)!, workAreaRef.current);\n };\n\n window.addEventListener('resize', onResize);\n\n return () => {\n window.removeEventListener('resize', onResize);\n };\n }, [currentTabId]);\n\n const utilitiesHeading = (\n <StyledUtilitiesHeading variant='h2'>{t('utilities')}</StyledUtilitiesHeading>\n );\n\n const utilitiesToggleButton = !isPreview && (\n <StyledExpandCollapseUtilitiesButton\n compact\n icon\n label={t(utilitiesExpanded ? 'collapse' : 'expand')}\n aria-label={t(utilitiesExpanded ? 'collapse_utilities_panel' : 'expand_utilities_panel')}\n onClick={() => {\n if (!obeyUtilitiesExpandedProp && utilitiesExpandedProp) {\n setObeyUtilitiesExpandedProp(true);\n } else {\n onToggleUtilities?.();\n }\n }}\n onFocus={() => {\n isToggleButtonFocused.current = true;\n }}\n onBlur={() => {\n isToggleButtonFocused.current = false;\n }}\n ref={toggleButtonRef}\n >\n <Icon name={utilitiesExpanded ? `arrow-micro-${end}` : `arrow-micro-${start}`} />\n </StyledExpandCollapseUtilitiesButton>\n );\n\n const persistentUtilityToggleButton = persistentUtility && (\n <StyledExpandCollapseUtilitiesButton\n compact\n icon\n label={t(persistentUtilityExpanded ? 'collapse' : 'expand')}\n aria-label={t(persistentUtilityExpanded ? 'collapse_noun' : 'expand_noun', [\n persistentUtility.title\n ])}\n onClick={() => {\n setPersistentUtilityExpanded(prevState => !prevState);\n if (utilitiesExpanded) {\n onToggleUtilities?.();\n }\n }}\n onFocus={() => {\n isPersistentUtilityButtonFocused.current = true;\n }}\n onBlur={() => {\n isPersistentUtilityButtonFocused.current = false;\n }}\n ref={persistentUtilityButtonRef}\n >\n <Icon name={persistentUtilityExpanded ? 'dock' : 'undock'} />\n </StyledExpandCollapseUtilitiesButton>\n );\n\n const shouldRenderMobileTabs =\n !mdOrAbove || (persistentUtility && !xlOrAbove) || !summaryExpanded;\n // Here we go...\n return (\n <>\n <CaseViewContext.Provider value={ctxValue}>\n {/* Root element */}\n <Grid\n data-testid={testIds.root}\n {...restProps}\n as={StyledCaseView}\n ref={caseViewRef}\n container={caseViewGridContainer}\n item={{ area: 'case-view' }}\n >\n {/* Summary */}\n <Grid\n as={StyledSummary}\n item={{ area: 'summary' }}\n desktop={mdOrAbove && (!persistentUtility || xlOrAbove) && !summaryExpanded}\n isLargeOrAbove={lgOrAbove}\n ref={summaryRef}\n >\n <CaseSummary tabsRef={tabsRef} />\n </Grid>\n\n {/* Work area */}\n <Flex\n container={{\n direction: 'column',\n alignContent: 'start',\n rowGap: 2\n }}\n as={StyledWorkArea}\n persistentUtility={Boolean(persistentUtility)}\n ref={(el: HTMLDivElement) => {\n workAreaRef.current = el;\n scrollStickOptions.current.elements[0] = el;\n }}\n data-app-region\n aria-label={t('case_work_area')}\n >\n {(banners || stages || tasks) && (\n <Flex\n container={{\n direction: 'column',\n alignContent: 'start',\n rowGap: 2\n }}\n as={StyledBannersStagesTasksContainer}\n ref={setBannersStagesTasksEl}\n >\n {banners && <div data-testid={testIds.banners}>{banners}</div>}\n {stages && <div data-testid={testIds.stages}>{stages}</div>}\n {tasks && (\n <StyledTasks\n onFocus={e => {\n if (e.target?.matches('[data-focusable-form-heading]')) {\n window.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n }\n }}\n data-testid={testIds.tasks}\n >\n {tasks}\n </StyledTasks>\n )}\n </Flex>\n )}\n\n <Flex container={{ direction: 'column', alignContent: 'start' }}>\n {shouldRenderMobileTabs && (\n <Tabs\n data-testid={testIds.tabs}\n tabs={tabItems}\n onTabClick={onTabClick}\n currentTabId={currentTabId}\n aria-label={t(isPreview ? 'case_preview_tabs' : 'case_tabs')}\n ref={tabsRef}\n />\n )}\n\n <StyledTabPanelWrapper ref={setTabContentEl}>\n {tabContent?.map(({ id, content }) => (\n <TabPanel\n data-testid={currentTabId === id ? testIds.tabContent : undefined}\n currentTabId={currentTabId}\n tabId={id}\n key={id}\n ref={getTabPanelCbRef(id)}\n tablistRef={tabsRef}\n tablistType={shouldRenderMobileTabs ? 'horizontal' : 'vertical'}\n >\n {content}\n </TabPanel>\n ))}\n </StyledTabPanelWrapper>\n </Flex>\n </Flex>\n\n {/* Persistent utility column */}\n {persistentUtility && mdOrAbove && (\n <Grid\n as={StyledPersistentUtility}\n item={{ area: 'persistentUtility' }}\n data-app-region\n aria-label={t('utilities_label')}\n persistentUtilityExpanded={persistentUtilityExpanded}\n >\n {persistentUtility.showExpand ? (\n <Flex\n container={{\n direction: 'column',\n gap: persistentUtilityExpanded ? undefined : 2\n }}\n as={StyledPersistentContainer}\n >\n {persistentUtilityExpanded ? (\n <Card as={StyledPersistentContainer}>\n <CardHeader>\n <Text variant='h2'>{persistentUtility.title}</Text>\n {persistentUtilityToggleButton}\n </CardHeader>\n <Flex container={{ direction: 'column' }} as={StyledPersistentContent}>\n {persistentUtility.content}\n </Flex>\n </Card>\n ) : (\n <>\n <Flex\n container={{\n justify: 'between',\n alignItems: 'center',\n pad: [undefined, 0.5, undefined, undefined]\n }}\n >\n <Text variant='h2'>{persistentUtility.title}</Text>\n {persistentUtilityToggleButton}\n </Flex>\n <Flex container={{ direction: 'column' }} as={StyledPersistentContent}>\n {persistentUtility.content}\n </Flex>\n </>\n )}\n </Flex>\n ) : (\n <>{persistentUtility.content}</>\n )}\n </Grid>\n )}\n\n {/* Utility drawer */}\n {(utilities || genAICoachProps) && mdOrAbove && !lgOrAbove && utilitiesExpanded && (\n <Drawer\n as={StyledCaseDrawer}\n open={utilitiesExpanded}\n previewActive={previewActive}\n position='fixed'\n placement={end}\n shadow\n nullWhenClosed\n utilitiesExpanded={!!utilitiesExpanded}\n hasPersistentUtility={!!persistentUtility}\n >\n <Flex\n as={StyledCaseDrawerContent}\n container={{ direction: 'column', gap: 2 }}\n data-app-region\n aria-label={t('utilities_label')}\n >\n <Flex container={{ alignItems: 'center', justify: 'between' }}>\n {utilitiesHeading}\n {utilitiesToggleButton}\n </Flex>\n {utilitiesAndGenAI}\n </Flex>\n </Drawer>\n )}\n\n {/* Utilities */}\n {(utilities || genAICoachProps) && mdOrAbove && !isPreview && (\n <Grid\n data-testid={testIds.utilities}\n ref={(el: HTMLDivElement) => {\n scrollStickOptions.current.elements[1] = el;\n }}\n as={StyledUtilities}\n container={{\n cols: 'minmax(0, 1fr)',\n rowGap: 2\n }}\n item={{\n area: 'utilities'\n }}\n data-app-region={lgOrAbove || !utilitiesExpanded || undefined}\n aria-label={t('utilities_label')}\n >\n <Flex\n container={{\n alignItems: 'center',\n justify: utilitiesExpanded ? 'between' : 'center'\n }}\n >\n {utilitiesHeading}\n {!lgOrAbove && utilitiesExpanded ? null : utilitiesToggleButton}\n </Flex>\n\n {utilitiesExpanded && lgOrAbove && utilitiesAndGenAI}\n\n {(!utilitiesExpanded || (mdOrAbove && !lgOrAbove)) && (\n <>\n {utilitiesSummaryItems && utilitiesSummaryItems.length > 0 && (\n <UtilitiesSummary\n items={utilitiesSummaryItems}\n isExpanded={utilitiesExpanded}\n />\n )}\n\n {genAICoachProps && (\n <StyledCoachButton\n iconOnly\n variant='primary'\n ref={genAICoachButtonRef}\n onClick={() => setShowCoach(cur => !cur)}\n label={t('chat_with_ai')}\n />\n )}\n </>\n )}\n </Grid>\n )}\n {genAICoachButtonRef.current && genAICoachProps && showCoach && (\n <UtilitySummaryItemDialog\n name={t('chat_with_ai')}\n target={genAICoachButtonRef.current}\n onDismiss={() => setShowCoach(false)}\n >\n <GenAICoach\n {...genAICoachProps}\n variant={{\n placement: 'dialog',\n onClose: () => {\n genAICoachProps.onClose?.();\n setShowCoach(false);\n genAICoachButtonRef.current?.focus();\n }\n }}\n />\n </UtilitySummaryItemDialog>\n )}\n </Grid>\n </CaseViewContext.Provider>\n {intelligentGuidance}\n </>\n );\n};\n\nexport default withTestIds(CaseView, getCaseViewTestIds);\n"]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { DefaultTheme } from 'styled-components';
|
|
2
2
|
import type { AppShellContextValue } from '@pega/cosmos-react-core/lib/components/AppShell/AppShellContext';
|
|
3
|
-
export declare const resolveCaseTypeColor: (theme: DefaultTheme, color: string) => string;
|
|
3
|
+
export declare const resolveCaseTypeColor: (theme: DefaultTheme, color: string | undefined) => string | undefined;
|
|
4
4
|
export declare const StyledSummaryPrimaryList: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("@pega/cosmos-react-core").FieldValueListProps & import("@pega/cosmos-react-core").ForwardProps, {
|
|
5
5
|
wrapped?: boolean;
|
|
6
6
|
}>> & string & Omit<import("react").FunctionComponent<import("@pega/cosmos-react-core").FieldValueListProps & import("@pega/cosmos-react-core").ForwardProps> & {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CaseView.styles.d.ts","sourceRoot":"","sources":["../../../src/components/CaseView/CaseView.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;
|
|
1
|
+
{"version":3,"file":"CaseView.styles.d.ts","sourceRoot":"","sources":["../../../src/components/CaseView/CaseView.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CA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C,CAAC;AAEH,eAAO,MAAM,cAAc,6NA4I1B,CAAC;AAIF,eAAO,MAAM,sBAAsB;;yLAAiB,CAAC;AAErD,eAAO,MAAM,mCAAmC;;2BAO9C,CAAC;AAMH,eAAO,MAAM,eAAe,6NAsC1B,CAAC;AAIH,eAAO,MAAM,aAAa,6NAiEzB,CAAC;AAIF,eAAO,MAAM,gBAAgB;oBACX,oBAAoB,CAAC,eAAe,CAAC;wBACjC,OAAO;YA8B3B,CAAC;AAIH,eAAO,MAAM,uBAAuB,6NAwBnC,CAAC;AAIF,eAAO,MAAM,uBAAuB;gCAA4C,OAAO;YAatF,CAAC;AAIF,eAAO,MAAM,yBAAyB,6NAQpC,CAAC;AAIH,eAAO,MAAM,uBAAuB,6NAIlC,CAAC;AAIH,eAAO,MAAM,WAAW,6NAGvB,CAAC;AAEF,eAAO,MAAM,cAAc,6NA+F1B,CAAC;AAIF,eAAO,MAAM,qBAAqB;;yLAMjC,CAAC;AAIF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;sSAsB5B,CAAC;AAIH,eAAO,MAAM,sBAAsB,6NAAe,CAAC;AAEnD,eAAO,MAAM,kBAAkB,kaAoC7B,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import styled, { css } from 'styled-components';
|
|
2
|
-
import { getContrast, hideVisually,
|
|
2
|
+
import { getContrast, hideVisually, mix, rgba, transparentize } from 'polished';
|
|
3
3
|
import { useContext } from 'react';
|
|
4
4
|
import { Button, calculateFontSize, CardContent, defaultThemeProp, resolveSupplementalColor, StyledBreadcrumbs, StyledButtonLink, StyledFieldValue, StyledInlineFieldValueRow, StyledStackedFieldValue, StyledIcon, StyledLabel, StyledPopover, StyledText, StyledTooltip, tryCatch, FieldValueList, StyledLink, readableHue, StyledCard, Text, readableColor, AppShellContext, AIButton, StyledButton, calculateForegroundColor, calculateBackgroundAndContrastColor, isSolidColor, StyledSummaryListItem, StyledProgressBackdrop, Image, Icon, animations, useDirection } from '@pega/cosmos-react-core';
|
|
5
5
|
import { StyledMenu } from '@pega/cosmos-react-core/lib/components/Menu/Menu.styles';
|
|
6
6
|
import { headerHeight } from '@pega/cosmos-react-core/lib/components/AppShell/AppShell.styles';
|
|
7
7
|
import { StyledCardHeader } from '@pega/cosmos-react-core/lib/components/Card/CardHeader';
|
|
8
8
|
import { StyledAllTabsWrapper, StyledTabs, StylesAllTabsButtonWrapper } from '@pega/cosmos-react-core/lib/components/Tabs/Tabs.styles';
|
|
9
|
-
import { resizeDrawerMinWidth, resizeDrawerMaxWidth, resizeDrawerDefaultWidth } from '@pega/cosmos-react-core/lib/styles/constants';
|
|
9
|
+
import { resizeDrawerMinWidth, resizeDrawerMaxWidth, resizeDrawerDefaultWidth, wcagContrast } from '@pega/cosmos-react-core/lib/styles/constants';
|
|
10
10
|
import { StyledMenuButton } from '@pega/cosmos-react-core/lib/components/MenuButton/MenuButton';
|
|
11
11
|
import { StyledTab } from '@pega/cosmos-react-core/lib/components/Tabs/Tab';
|
|
12
12
|
import { StyledTabPanel } from '@pega/cosmos-react-core/lib/components/Tabs/TabPanel';
|
|
@@ -21,6 +21,8 @@ import { useCaseViewContext } from './CaseView.context';
|
|
|
21
21
|
const labelWidth = '16ch';
|
|
22
22
|
const inlineEndButtonOffset = '0.375rem';
|
|
23
23
|
export const resolveCaseTypeColor = (theme, color) => {
|
|
24
|
+
if (!color)
|
|
25
|
+
return undefined;
|
|
24
26
|
const supplementalColor = resolveSupplementalColor(theme, color);
|
|
25
27
|
if (supplementalColor !== undefined)
|
|
26
28
|
return supplementalColor;
|
|
@@ -28,16 +30,41 @@ export const resolveCaseTypeColor = (theme, color) => {
|
|
|
28
30
|
};
|
|
29
31
|
const mixCaseColorWithBackground = (color, background) => mix(0.85, background, color);
|
|
30
32
|
const getCaseTypeHeaderColors = (theme, color) => {
|
|
31
|
-
if (color === undefined)
|
|
32
|
-
return null;
|
|
33
33
|
const resolvedCaseTypeColor = resolveCaseTypeColor(theme, color);
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
const headerBackground = isSolidColor(theme.components.card.background)
|
|
34
|
+
const headerBackground = resolvedCaseTypeColor &&
|
|
35
|
+
theme.base['case-type-colors'] === 'header-and-icon' &&
|
|
36
|
+
isSolidColor(theme.components.card.background)
|
|
38
37
|
? mixCaseColorWithBackground(resolvedCaseTypeColor, theme.components.card.background)
|
|
39
|
-
: theme.components.
|
|
40
|
-
|
|
38
|
+
: theme.components['case-view'].header.background;
|
|
39
|
+
const headerForeground = resolvedCaseTypeColor && theme.base['case-type-colors'] === 'header-and-icon'
|
|
40
|
+
? readableColor(headerBackground)
|
|
41
|
+
: calculateForegroundColor(headerBackground, theme.components['case-view'].header['foreground-color']);
|
|
42
|
+
return { caseTypeColor: resolvedCaseTypeColor ?? undefined, headerBackground, headerForeground };
|
|
43
|
+
};
|
|
44
|
+
const getCaseViewColors = (theme, caseTypeColor) => {
|
|
45
|
+
const interactive = theme.base.palette.interactive;
|
|
46
|
+
const caseTypeHeaderColors = getCaseTypeHeaderColors(theme, caseTypeColor);
|
|
47
|
+
const headerBackground = caseTypeHeaderColors.headerBackground;
|
|
48
|
+
const foregroundColor = caseTypeHeaderColors.headerForeground;
|
|
49
|
+
const isGradientBackground = !isSolidColor(headerBackground);
|
|
50
|
+
const elementBackground = isGradientBackground
|
|
51
|
+
? readableColor(foregroundColor)
|
|
52
|
+
: headerBackground;
|
|
53
|
+
const interactiveUsable = getContrast(elementBackground, interactive) >= wcagContrast.AA;
|
|
54
|
+
const interactiveColor = !isGradientBackground && interactiveUsable ? interactive : foregroundColor;
|
|
55
|
+
let hoverBackground = rgba(interactiveColor, 0.15);
|
|
56
|
+
if (!isGradientBackground && interactiveUsable) {
|
|
57
|
+
hoverBackground = readableHue(interactive, interactiveColor);
|
|
58
|
+
}
|
|
59
|
+
return {
|
|
60
|
+
caseTypeColor: caseTypeHeaderColors.caseTypeColor,
|
|
61
|
+
headerBackground,
|
|
62
|
+
foregroundColor,
|
|
63
|
+
elementBackground,
|
|
64
|
+
interactiveColor,
|
|
65
|
+
interactiveUsable,
|
|
66
|
+
hoverBackground
|
|
67
|
+
};
|
|
41
68
|
};
|
|
42
69
|
export const StyledSummaryPrimaryList = styled(FieldValueList)(({ theme, wrapped }) => {
|
|
43
70
|
const fontSizes = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
|
|
@@ -112,19 +139,15 @@ export const StyledCaseViewImage = styled(Image) `
|
|
|
112
139
|
max-height: 100%;
|
|
113
140
|
`;
|
|
114
141
|
export const StyledCaseHeader = styled.div(({ theme }) => {
|
|
115
|
-
const { components: { 'case-view': {
|
|
142
|
+
const { components: { 'case-view': { summary: { detached: summaryDetached }, utilities: { detached: utilitiesDetached } } }, base: { 'border-radius': borderRadius, spacing, shadow, 'z-index': zIndex, palette } } = theme;
|
|
116
143
|
const { aboveSM, aboveMD, color, persistentUtility, aboveXL, summaryExpanded, isPreview } = useCaseViewContext();
|
|
117
144
|
const shouldRenderMobileTabs = !aboveMD || (persistentUtility && !aboveXL) || !summaryExpanded;
|
|
118
145
|
const caseHeaderBorderRadius = shouldRenderMobileTabs
|
|
119
146
|
? `0 0 ${utilitiesDetached ? borderRadius : 0} ${borderRadius}`
|
|
120
147
|
: `${borderRadius} ${borderRadius} 0 0`;
|
|
121
|
-
const
|
|
122
|
-
const headerBackgroundColor = caseTypeHeaderColors?.headerBackground ?? background;
|
|
123
|
-
const foregroundColor = caseTypeHeaderColors
|
|
124
|
-
? readableColor(headerBackgroundColor)
|
|
125
|
-
: calculateForegroundColor(headerBackgroundColor, caseHeaderForegroundColor);
|
|
148
|
+
const { headerBackground, foregroundColor } = getCaseViewColors(theme, color);
|
|
126
149
|
return css `
|
|
127
|
-
background: ${
|
|
150
|
+
background: ${headerBackground};
|
|
128
151
|
color: ${foregroundColor};
|
|
129
152
|
padding: ${spacing} calc(2 * ${spacing});
|
|
130
153
|
position: relative;
|
|
@@ -166,39 +189,27 @@ StyledFollowIconWrap.defaultProps = defaultThemeProp;
|
|
|
166
189
|
export const StyledSubheading = styled.p ``;
|
|
167
190
|
StyledSubheading.defaultProps = defaultThemeProp;
|
|
168
191
|
export const StyledCaseHeaderPromotedAction = styled(Button)(({ theme }) => {
|
|
169
|
-
const { base: { palette: { interactive } }, components: { 'case-view': { header: { background, 'foreground-color': foregroundColor } } } } = theme;
|
|
170
192
|
const { color: caseTypeColor } = useCaseViewContext();
|
|
171
|
-
const
|
|
172
|
-
/* If the foreground-color is auto, we calculate the text color and transparentColor based on the background color. */
|
|
173
|
-
const headerBg = caseTypeHeaderColors?.headerBackground ?? background;
|
|
174
|
-
const textColor = calculateForegroundColor(headerBg, foregroundColor);
|
|
175
|
-
const isGradientBackground = !isSolidColor(headerBg);
|
|
176
|
-
const backgroundColor = isGradientBackground ? readableColor(textColor) : headerBg;
|
|
177
|
-
const interactiveUsable = getContrast(backgroundColor, interactive) >= 4.5;
|
|
178
|
-
const color = !isGradientBackground && interactiveUsable ? interactive : textColor;
|
|
179
|
-
let hoverBackground = rgba(color, 0.15);
|
|
180
|
-
if (!isGradientBackground && interactiveUsable) {
|
|
181
|
-
hoverBackground = readableHue(interactive, color);
|
|
182
|
-
}
|
|
193
|
+
const { elementBackground, interactiveColor, hoverBackground } = getCaseViewColors(theme, caseTypeColor);
|
|
183
194
|
return css `
|
|
184
|
-
--button-background-color: ${
|
|
185
|
-
color: ${
|
|
195
|
+
--button-background-color: ${elementBackground};
|
|
196
|
+
color: ${interactiveColor};
|
|
186
197
|
background-color: transparent;
|
|
187
|
-
border-color: ${
|
|
198
|
+
border-color: ${interactiveColor};
|
|
188
199
|
|
|
189
200
|
@media (hover: hover) {
|
|
190
201
|
&:hover {
|
|
191
202
|
--button-background-color: ${hoverBackground};
|
|
192
|
-
color: ${
|
|
203
|
+
color: ${interactiveColor};
|
|
193
204
|
background-color: ${hoverBackground};
|
|
194
|
-
border-color: ${
|
|
205
|
+
border-color: ${interactiveColor};
|
|
195
206
|
}
|
|
196
207
|
|
|
197
208
|
&:active {
|
|
198
209
|
--button-background-color: ${hoverBackground};
|
|
199
|
-
color: ${
|
|
210
|
+
color: ${interactiveColor};
|
|
200
211
|
background-color: ${hoverBackground};
|
|
201
|
-
border-color: ${
|
|
212
|
+
border-color: ${interactiveColor};
|
|
202
213
|
}
|
|
203
214
|
}
|
|
204
215
|
`;
|
|
@@ -226,16 +237,12 @@ export const StyledHeaderActions = styled.div(({ offsetEnd, theme }) => {
|
|
|
226
237
|
});
|
|
227
238
|
StyledHeaderActions.defaultProps = defaultThemeProp;
|
|
228
239
|
export const StyledCaseHeaderText = styled.hgroup(({ theme }) => {
|
|
229
|
-
const {
|
|
230
|
-
const {
|
|
231
|
-
const caseTypeHeaderColors = getCaseTypeHeaderColors(theme, caseTypeColor);
|
|
232
|
-
/* If the foreground-color is auto, we calculate the text color and transparentColor based on the background color. */
|
|
233
|
-
const headerBg = caseTypeHeaderColors?.headerBackground ?? caseHeaderBackground;
|
|
234
|
-
const color = calculateForegroundColor(headerBg, foregroundColor);
|
|
240
|
+
const { color } = useCaseViewContext();
|
|
241
|
+
const { foregroundColor, interactiveColor } = getCaseViewColors(theme, color);
|
|
235
242
|
const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
|
|
236
243
|
const idStyle = css `
|
|
237
|
-
color: ${
|
|
238
|
-
font-size: ${fontSize.
|
|
244
|
+
color: ${foregroundColor};
|
|
245
|
+
font-size: ${fontSize.xs};
|
|
239
246
|
font-weight: normal;
|
|
240
247
|
`;
|
|
241
248
|
return css `
|
|
@@ -268,7 +275,7 @@ export const StyledCaseHeaderText = styled.hgroup(({ theme }) => {
|
|
|
268
275
|
}
|
|
269
276
|
|
|
270
277
|
> ${StyledText} > ${StyledLink} {
|
|
271
|
-
color: ${
|
|
278
|
+
color: ${interactiveColor};
|
|
272
279
|
}
|
|
273
280
|
|
|
274
281
|
+ ${StyledHeaderActions} {
|
|
@@ -318,38 +325,32 @@ const popoverColorReset = (theme) => {
|
|
|
318
325
|
`;
|
|
319
326
|
};
|
|
320
327
|
export const StyledHeaderSummary = styled.dl(({ theme }) => {
|
|
321
|
-
const { base: { palette: { interactive } }, components: { 'case-view': { header: { 'foreground-color': foregroundColor, background } } } } = theme;
|
|
322
328
|
const { color: caseTypeColor } = useCaseViewContext();
|
|
323
|
-
const
|
|
324
|
-
/* If the foreground-color is auto, we calculate the text color and transparentColor based on the background color. */
|
|
325
|
-
const headerBg = caseTypeHeaderColors?.headerBackground ?? background;
|
|
326
|
-
const color = calculateForegroundColor(headerBg, foregroundColor);
|
|
327
|
-
const { backgroundColor } = calculateBackgroundAndContrastColor(headerBg, foregroundColor);
|
|
328
|
-
const interactiveUsable = meetsContrastGuidelines(backgroundColor, interactive).AA;
|
|
329
|
+
const { foregroundColor, interactiveUsable } = getCaseViewColors(theme, caseTypeColor);
|
|
329
330
|
return css `
|
|
330
331
|
max-width: 100%;
|
|
331
332
|
min-width: 0;
|
|
332
333
|
|
|
333
334
|
> ${StyledStackedFieldValue} {
|
|
334
335
|
> ${StyledLabel} {
|
|
335
|
-
color: ${
|
|
336
|
+
color: ${foregroundColor};
|
|
336
337
|
white-space: nowrap;
|
|
337
338
|
}
|
|
338
339
|
|
|
339
340
|
> ${StyledFieldValue} {
|
|
340
|
-
color: ${
|
|
341
|
+
color: ${foregroundColor};
|
|
341
342
|
white-space: nowrap;
|
|
342
343
|
}
|
|
343
344
|
|
|
344
345
|
${StyledButtonLink},
|
|
345
346
|
${StyledLink} {
|
|
346
347
|
&:focus-visible {
|
|
347
|
-
box-shadow: inset 0 0 0 0.0625rem ${
|
|
348
|
+
box-shadow: inset 0 0 0 0.0625rem ${foregroundColor};
|
|
348
349
|
}
|
|
349
350
|
|
|
350
351
|
${!interactiveUsable &&
|
|
351
352
|
css `
|
|
352
|
-
color: ${
|
|
353
|
+
color: ${foregroundColor};
|
|
353
354
|
text-decoration: underline;
|
|
354
355
|
`}
|
|
355
356
|
}
|
|
@@ -462,7 +463,7 @@ export const StyledExpandCollapseSummaryButton = styled(StyledExpandCollapseButt
|
|
|
462
463
|
StyledExpandCollapseSummaryButton.defaultProps = defaultThemeProp;
|
|
463
464
|
export const StyledCaseSummary = styled.div(({ theme, theme: { base: { spacing, palette: { 'border-line': borderLine }, 'border-radius': borderRadius, 'hit-area': { 'mouse-min': mouseMin, 'finger-min': fingerMin } }, components: { 'case-view': { summary: { detached } }, card: { background: cardBackground }, tabs: { detached: tabsDetached } } } }) => {
|
|
464
465
|
const { summaryExpanded, aboveMD, color } = useCaseViewContext();
|
|
465
|
-
const
|
|
466
|
+
const { caseTypeColor, headerBackground, interactiveColor } = getCaseViewColors(theme, color);
|
|
466
467
|
return css `
|
|
467
468
|
background: ${cardBackground};
|
|
468
469
|
position: relative;
|
|
@@ -497,20 +498,25 @@ export const StyledCaseSummary = styled.div(({ theme, theme: { base: { spacing,
|
|
|
497
498
|
}
|
|
498
499
|
`}
|
|
499
500
|
|
|
500
|
-
${
|
|
501
|
+
${caseTypeColor &&
|
|
502
|
+
theme.base['case-type-colors'] === 'header-and-icon' &&
|
|
501
503
|
css `
|
|
502
504
|
& ${StyledTabs} {
|
|
503
505
|
&[aria-orientation='vertical']::after {
|
|
504
|
-
background: ${
|
|
506
|
+
background: ${caseTypeColor};
|
|
505
507
|
}
|
|
506
508
|
|
|
507
509
|
&[aria-orientation='vertical']::before {
|
|
508
|
-
background: ${
|
|
510
|
+
background: ${headerBackground};
|
|
509
511
|
}
|
|
510
512
|
}
|
|
511
513
|
|
|
512
514
|
& ${StyledTab}[aria-selected='true'] {
|
|
513
|
-
background-color: ${
|
|
515
|
+
background-color: ${headerBackground};
|
|
516
|
+
|
|
517
|
+
span {
|
|
518
|
+
color: ${interactiveColor};
|
|
519
|
+
}
|
|
514
520
|
}
|
|
515
521
|
`}
|
|
516
522
|
`;
|
|
@@ -761,7 +767,7 @@ StyledUtilities.defaultProps = defaultThemeProp;
|
|
|
761
767
|
export const StyledSummary = styled.div(({ theme: { base: { spacing, breakpoints, 'z-index': zIndex, palette: { 'app-background': appBackground } }, components: { 'app-shell': { nav: { background: navBackground } }, 'case-view': { summary: { detached: summaryDetached }, utilities: { detached: utilitiesDetached } } } } }) => {
|
|
762
768
|
const { aboveSM, aboveMD, persistentUtility, aboveXL, summaryExpanded, isPreview } = useCaseViewContext();
|
|
763
769
|
const shouldRenderMobileTabs = !aboveMD || (persistentUtility && !aboveXL) || !summaryExpanded;
|
|
764
|
-
const inlineStartPadding = navBackground === appBackground ? `${spacing}` : `calc(${spacing} * 2)`;
|
|
770
|
+
const inlineStartPadding = navBackground === appBackground && summaryExpanded ? `${spacing}` : `calc(${spacing} * 2)`;
|
|
765
771
|
return css `
|
|
766
772
|
top: ${summaryExpanded
|
|
767
773
|
? 'var(--top-offset)'
|
|
@@ -805,7 +811,6 @@ StyledSummary.defaultProps = defaultThemeProp;
|
|
|
805
811
|
export const StyledCaseDrawer = styled.div(({ previewActive, utilitiesExpanded, theme }) => {
|
|
806
812
|
return css `
|
|
807
813
|
background-color: ${theme.base.palette['primary-background']};
|
|
808
|
-
/* stylelint-disable-next-line unit-allowed-list */
|
|
809
814
|
height: calc(
|
|
810
815
|
100dvh - var(--appshell-offset, ${headerHeight}) - var(--appshell-top-offset, 0rem) - var(
|
|
811
816
|
--appshell-bottom-offset,
|
|
@@ -893,7 +898,6 @@ export const StyledCaseView = styled.div(({ theme: { base: { palette: { 'app-bac
|
|
|
893
898
|
);
|
|
894
899
|
/* stylelint-disable-next-line length-zero-no-unit */
|
|
895
900
|
--bottom-offset: var(--appshell-bottom-offset, 0rem);
|
|
896
|
-
/* stylelint-disable-next-line unit-allowed-list */
|
|
897
901
|
--case-view-height: calc(100dvh - var(--top-offset) - var(--bottom-offset));
|
|
898
902
|
position: relative;
|
|
899
903
|
min-height: var(--case-view-height);
|