@pega/cosmos-react-wss 10.0.0-build.9.8 → 10.0.0-build.9.9
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/ModernCaseView/ModernCaseView.d.ts +6 -0
- package/lib/components/ModernCaseView/ModernCaseView.d.ts.map +1 -0
- package/lib/components/ModernCaseView/ModernCaseView.js +206 -0
- package/lib/components/ModernCaseView/ModernCaseView.js.map +1 -0
- package/lib/components/ModernCaseView/ModernCaseView.styles.d.ts +39 -0
- package/lib/components/ModernCaseView/ModernCaseView.styles.d.ts.map +1 -0
- package/lib/components/ModernCaseView/ModernCaseView.styles.js +245 -0
- package/lib/components/ModernCaseView/ModernCaseView.styles.js.map +1 -0
- package/lib/components/ModernCaseView/index.d.ts +2 -0
- package/lib/components/ModernCaseView/index.d.ts.map +1 -0
- package/lib/components/ModernCaseView/index.js +2 -0
- package/lib/components/ModernCaseView/index.js.map +1 -0
- package/lib/index.d.ts +1 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { PropsWithoutRef } from 'react';
|
|
2
|
+
import type { ForwardProps } from '@pega/cosmos-react-core';
|
|
3
|
+
import type { CaseViewProps } from '../CaseView/CaseView.types';
|
|
4
|
+
declare const ModernCaseView: ({ caseId, heading, subheading, icon, color, actions, stages, tasks, summary, details, tabs: detailTabs, feed, utility, promotedActions, showPulse, showUtility, isCreateStage, ...restProps }: PropsWithoutRef<CaseViewProps> & ForwardProps) => import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export default ModernCaseView;
|
|
6
|
+
//# sourceMappingURL=ModernCaseView.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModernCaseView.d.ts","sourceRoot":"","sources":["../../../src/components/ModernCaseView/ModernCaseView.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAc,eAAe,EAAE,MAAM,OAAO,CAAC;AAoBzD,OAAO,KAAK,EAAE,YAAY,EAAO,MAAM,yBAAyB,CAAC;AAGjE,OAAO,KAAK,EAAE,aAAa,EAAU,MAAM,4BAA4B,CAAC;AAoBxE,QAAA,MAAM,cAAc,GAAI,+LAmBrB,eAAe,CAAC,aAAa,CAAC,GAAG,YAAY,4CAgZ/C,CAAC;AAEF,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { parseToHsl } from 'polished';
|
|
3
|
+
import { useCallback, useEffect, useLayoutEffect, useMemo, useRef, useState } from 'react';
|
|
4
|
+
import { CardContent, Flex, Icon, MenuButton, MetaList, TabPanel, Tabs, Text, getEdge, readableColor, throttle, tryCatch, useBreakpoint, useDirection, useI18n, useTheme } from '@pega/cosmos-react-core';
|
|
5
|
+
import { resolveCaseTypeColor } from '@pega/cosmos-react-work/lib/components/CaseView/CaseView.styles';
|
|
6
|
+
import { StyledModernCaseHeader, StyledModernCaseHeaderPromotedAction, StyledModernCaseHeaderText, StyledModernCaseSubheading, StyledModernCaseView, StyledModernCaseViewIcon, StyledModernContent, StyledModernContentContainer, StyledModernStagesContainer, StyledModernSummary, StyledModernSummaryCard, StyledModernSummaryFieldsDivider, StyledModernSummaryPrimaryList, StyledModernSummarySecondaryList, resolveModernCaseViewIconColor } from './ModernCaseView.styles';
|
|
7
|
+
const ModernCaseView = ({ caseId, heading, subheading, icon, color, actions, stages, tasks, summary, details, tabs: detailTabs, feed, utility, promotedActions = [], showPulse = true, showUtility = true, isCreateStage = false, ...restProps }) => {
|
|
8
|
+
const t = useI18n();
|
|
9
|
+
const theme = useTheme();
|
|
10
|
+
const { ltr } = useDirection();
|
|
11
|
+
const isSmallOrAbove = useBreakpoint('sm');
|
|
12
|
+
const isMediumOrAbove = useBreakpoint('md');
|
|
13
|
+
const tabsRef = useRef(null);
|
|
14
|
+
const singleRegionRef = useRef(null);
|
|
15
|
+
const restoreTabFocus = useRef(false);
|
|
16
|
+
const contentEl = useRef(null);
|
|
17
|
+
const headerEl = useRef(null);
|
|
18
|
+
const actionsContainerEl = useRef(null);
|
|
19
|
+
const wrapActionsBreakpoint = useRef(null);
|
|
20
|
+
const [wrapPromotedActions, setWrapPromotedActions] = useState(false);
|
|
21
|
+
const setTabsRef = useCallback((element) => {
|
|
22
|
+
if (!element && tabsRef.current?.contains(document.activeElement)) {
|
|
23
|
+
restoreTabFocus.current = true;
|
|
24
|
+
}
|
|
25
|
+
tabsRef.current = element;
|
|
26
|
+
}, []);
|
|
27
|
+
const primarySummaryFields = summary?.primarySummaryFields ?? [];
|
|
28
|
+
const secondarySummaryFields = summary?.secondarySummaryFields ?? [];
|
|
29
|
+
const hasPrimarySummaryFields = primarySummaryFields.length > 0;
|
|
30
|
+
const hasSecondarySummaryFields = secondarySummaryFields.length > 0;
|
|
31
|
+
const hasSummaryFields = hasPrimarySummaryFields || hasSecondarySummaryFields;
|
|
32
|
+
const hasSummaryContent = Boolean(summary?.content);
|
|
33
|
+
const detailRegions = useMemo(() => {
|
|
34
|
+
if (detailTabs?.length)
|
|
35
|
+
return detailTabs;
|
|
36
|
+
return details ? [details] : [];
|
|
37
|
+
}, [detailTabs, details]);
|
|
38
|
+
const { iconForeground, iconBackground } = useMemo(() => {
|
|
39
|
+
const backgroundSetting = theme.components['case-view'].icon.background;
|
|
40
|
+
const foregroundSetting = theme.components['case-view'].icon.color;
|
|
41
|
+
const usesIconGradient = backgroundSetting.includes('var(--gradient-');
|
|
42
|
+
const resolvedIconBackground = backgroundSetting !== 'auto'
|
|
43
|
+
? backgroundSetting
|
|
44
|
+
: tryCatch(() => {
|
|
45
|
+
const { lightness } = parseToHsl(theme.components['case-view'].header.background);
|
|
46
|
+
return lightness > 0.35 ? 'rgba(0, 0, 0, 0.2)' : 'rgba(255, 255, 255, 0.2)';
|
|
47
|
+
}, () => 'transparent');
|
|
48
|
+
let resolvedIconForeground = foregroundSetting !== 'auto'
|
|
49
|
+
? foregroundSetting
|
|
50
|
+
: theme.components['case-view'].header['foreground-color'];
|
|
51
|
+
if (foregroundSetting === 'auto' && usesIconGradient) {
|
|
52
|
+
resolvedIconForeground = 'auto';
|
|
53
|
+
}
|
|
54
|
+
if (resolvedIconForeground === 'auto') {
|
|
55
|
+
const caseTypeIconColor = theme.base['case-type-colors'] !== 'ignored'
|
|
56
|
+
? resolveCaseTypeColor(theme, color)
|
|
57
|
+
: undefined;
|
|
58
|
+
resolvedIconForeground = readableColor(usesIconGradient
|
|
59
|
+
? resolveModernCaseViewIconColor(theme, color)
|
|
60
|
+
: caseTypeIconColor ?? resolvedIconBackground, { mode: 'light', level: 'AANonText' });
|
|
61
|
+
}
|
|
62
|
+
return { iconForeground: resolvedIconForeground, iconBackground: resolvedIconBackground };
|
|
63
|
+
}, [theme, color]);
|
|
64
|
+
const promotedActionButtons = useMemo(() => promotedActions.map(action => (_jsx(StyledModernCaseHeaderPromotedAction, { variant: 'secondary', href: action.href, disabled: action.disabled, onClick: (e) => action.onClick?.(action.id, e), "$color": color, children: action.text }, action.id))), [promotedActions, color]);
|
|
65
|
+
const summaryFieldsCard = useMemo(() => hasSummaryFields ? (_jsxs(StyledModernSummaryCard, { children: [hasPrimarySummaryFields && (_jsx(CardContent, { children: _jsx(StyledModernSummaryPrimaryList, { variant: 'stacked', fields: primarySummaryFields, "aria-label": t('primary_summary_fields'), "$isSmallOrAbove": isSmallOrAbove }) })), hasPrimarySummaryFields && hasSecondarySummaryFields && (_jsx(StyledModernSummaryFieldsDivider, {})), hasSecondarySummaryFields && (_jsx(CardContent, { children: _jsx(StyledModernSummarySecondaryList, { variant: 'stacked', fields: secondarySummaryFields, "aria-label": t('summary_fields'), "$isSmallOrAbove": isSmallOrAbove }) }))] })) : null, [
|
|
66
|
+
hasSummaryFields,
|
|
67
|
+
hasPrimarySummaryFields,
|
|
68
|
+
hasSecondarySummaryFields,
|
|
69
|
+
primarySummaryFields,
|
|
70
|
+
secondarySummaryFields,
|
|
71
|
+
isSmallOrAbove,
|
|
72
|
+
t
|
|
73
|
+
]);
|
|
74
|
+
// Desktop: details + pulse + utilities. Mobile: summary is prepended as the first tab.
|
|
75
|
+
const bodyTabs = useMemo(() => {
|
|
76
|
+
const tabs = [];
|
|
77
|
+
if (!isSmallOrAbove) {
|
|
78
|
+
const summaryLabel = summary?.label ?? t('summary');
|
|
79
|
+
if (hasSummaryFields) {
|
|
80
|
+
tabs.push({
|
|
81
|
+
id: 'summary',
|
|
82
|
+
name: summaryLabel,
|
|
83
|
+
content: { label: summaryLabel, content: summaryFieldsCard }
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
else if (summary?.content) {
|
|
87
|
+
tabs.push({ id: 'summary', name: summary.label, content: summary });
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
detailRegions.forEach((region, index) => {
|
|
91
|
+
if (!region.content)
|
|
92
|
+
return;
|
|
93
|
+
tabs.push({
|
|
94
|
+
id: region.id ? `details-id-${region.id}` : `details-index-${index}`,
|
|
95
|
+
name: region.label,
|
|
96
|
+
content: region
|
|
97
|
+
});
|
|
98
|
+
});
|
|
99
|
+
if (feed?.content && showPulse)
|
|
100
|
+
tabs.push({ id: 'pulse', name: feed.label, content: feed });
|
|
101
|
+
if (utility?.content && showUtility) {
|
|
102
|
+
tabs.push({ id: 'utilities', name: utility.label, content: utility });
|
|
103
|
+
}
|
|
104
|
+
return tabs;
|
|
105
|
+
}, [
|
|
106
|
+
isSmallOrAbove,
|
|
107
|
+
summary,
|
|
108
|
+
detailRegions,
|
|
109
|
+
feed,
|
|
110
|
+
utility,
|
|
111
|
+
summaryFieldsCard,
|
|
112
|
+
hasSummaryFields,
|
|
113
|
+
showPulse,
|
|
114
|
+
showUtility,
|
|
115
|
+
t
|
|
116
|
+
]);
|
|
117
|
+
const [currentTabId, setCurrentTabId] = useState(() => bodyTabs[0]?.id ?? 'details');
|
|
118
|
+
useEffect(() => {
|
|
119
|
+
if (!bodyTabs.length)
|
|
120
|
+
return;
|
|
121
|
+
if (!bodyTabs.some(tab => tab.id === currentTabId)) {
|
|
122
|
+
setCurrentTabId(bodyTabs[0].id);
|
|
123
|
+
}
|
|
124
|
+
}, [bodyTabs, currentTabId]);
|
|
125
|
+
useLayoutEffect(() => {
|
|
126
|
+
if (restoreTabFocus.current) {
|
|
127
|
+
restoreTabFocus.current = false;
|
|
128
|
+
singleRegionRef.current?.focus();
|
|
129
|
+
}
|
|
130
|
+
}, [bodyTabs, isCreateStage]);
|
|
131
|
+
useLayoutEffect(() => {
|
|
132
|
+
wrapActionsBreakpoint.current = null;
|
|
133
|
+
setWrapPromotedActions(false);
|
|
134
|
+
}, [
|
|
135
|
+
promotedActions,
|
|
136
|
+
actions,
|
|
137
|
+
heading,
|
|
138
|
+
subheading,
|
|
139
|
+
icon,
|
|
140
|
+
color,
|
|
141
|
+
isSmallOrAbove,
|
|
142
|
+
isMediumOrAbove,
|
|
143
|
+
isCreateStage,
|
|
144
|
+
ltr
|
|
145
|
+
]);
|
|
146
|
+
useLayoutEffect(() => {
|
|
147
|
+
if (!isSmallOrAbove || isCreateStage || !promotedActions.length)
|
|
148
|
+
return;
|
|
149
|
+
// Measure changed content after restoring the natural, unwrapped action row.
|
|
150
|
+
if (wrapPromotedActions && wrapActionsBreakpoint.current === null)
|
|
151
|
+
return;
|
|
152
|
+
if (!wrapPromotedActions &&
|
|
153
|
+
contentEl.current &&
|
|
154
|
+
actionsContainerEl.current &&
|
|
155
|
+
headerEl.current) {
|
|
156
|
+
const contentStart = getEdge({ el: contentEl.current, side: 'leading', ltr });
|
|
157
|
+
const headerGroupEnd = getEdge({ el: headerEl.current, side: 'trailing', ltr });
|
|
158
|
+
const actionsContainerWidth = actionsContainerEl.current.getBoundingClientRect().width;
|
|
159
|
+
wrapActionsBreakpoint.current =
|
|
160
|
+
Math.abs(Math.ceil(contentStart) - Math.ceil(headerGroupEnd)) +
|
|
161
|
+
Math.ceil(actionsContainerWidth);
|
|
162
|
+
}
|
|
163
|
+
const promotedActionsWrapHandler = () => {
|
|
164
|
+
if (wrapActionsBreakpoint.current !== null && contentEl.current) {
|
|
165
|
+
const availableWidth = Math.ceil(contentEl.current.offsetWidth) - 20;
|
|
166
|
+
setWrapPromotedActions(availableWidth < wrapActionsBreakpoint.current);
|
|
167
|
+
}
|
|
168
|
+
};
|
|
169
|
+
const resizeObserver = new ResizeObserver(throttle(promotedActionsWrapHandler, 30));
|
|
170
|
+
promotedActionsWrapHandler();
|
|
171
|
+
if (contentEl.current) {
|
|
172
|
+
resizeObserver.observe(contentEl.current, { box: 'border-box' });
|
|
173
|
+
}
|
|
174
|
+
return () => {
|
|
175
|
+
resizeObserver.disconnect();
|
|
176
|
+
};
|
|
177
|
+
}, [
|
|
178
|
+
contentEl,
|
|
179
|
+
actionsContainerEl,
|
|
180
|
+
headerEl,
|
|
181
|
+
promotedActions,
|
|
182
|
+
actions,
|
|
183
|
+
heading,
|
|
184
|
+
subheading,
|
|
185
|
+
icon,
|
|
186
|
+
color,
|
|
187
|
+
wrapPromotedActions,
|
|
188
|
+
isSmallOrAbove,
|
|
189
|
+
isMediumOrAbove,
|
|
190
|
+
isCreateStage,
|
|
191
|
+
ltr
|
|
192
|
+
]);
|
|
193
|
+
const showActions = !isCreateStage && (promotedActions.length > 0 || !!actions?.length);
|
|
194
|
+
const shouldWrapPromotedActions = !isSmallOrAbove || wrapPromotedActions;
|
|
195
|
+
const showDesktopSummary = !isCreateStage && isSmallOrAbove;
|
|
196
|
+
return (_jsxs(StyledModernCaseView, { "$isCreateStage": isCreateStage, ...(isCreateStage && { 'data-create-stage': '' }), ...restProps, children: [_jsx(StyledModernCaseHeader, { "$color": color, "$isSmallOrAbove": isSmallOrAbove, children: _jsxs(Flex, { container: { direction: 'column', gap: 2, pad: 2, alignItems: 'start' }, ref: contentEl, as: StyledModernContentContainer, children: [_jsxs(Flex, { container: { justify: 'between', alignItems: 'start', gap: 2 }, item: { grow: 1 }, children: [_jsxs(Flex, { container: { gap: 2, alignItems: 'center' }, children: [icon && (_jsx(StyledModernCaseViewIcon, { name: icon, emphasized: true, foreground: iconForeground, background: iconBackground, "$color": color })), _jsxs(Flex, { as: StyledModernCaseHeaderText, container: { direction: 'column', alignItems: 'start', justify: 'center' }, item: { shrink: 1 }, ref: headerEl, children: [_jsx(Text, { variant: 'h1', children: heading }), subheading && (_jsx(StyledModernCaseSubheading, { "$color": color, children: Array.isArray(subheading) ? _jsx(MetaList, { items: subheading }) : subheading }))] })] }), showActions && (_jsxs(Flex, { container: { gap: 1 }, ref: actionsContainerEl, children: [!shouldWrapPromotedActions && promotedActionButtons, actions && actions.length > 0 && (_jsx(MenuButton, { icon: promotedActions.length > 0 || !isMediumOrAbove ? 'more' : undefined, iconOnly: promotedActions.length > 0 || !isMediumOrAbove, variant: 'simple', text: t('actions'), "aria-label": t('actions_for', [caseId]), menu: {
|
|
197
|
+
items: actions.map(action => ({
|
|
198
|
+
...action,
|
|
199
|
+
primary: action.text,
|
|
200
|
+
visual: action.icon ? _jsx(Icon, { name: action.icon }) : undefined
|
|
201
|
+
})),
|
|
202
|
+
scrollAt: 20
|
|
203
|
+
} }))] }))] }), shouldWrapPromotedActions && !isCreateStage && promotedActions.length > 0 && (_jsx(Flex, { item: { grow: 1 }, container: { justify: 'start', gap: 1, alignItems: 'center', wrap: 'wrap' }, children: promotedActionButtons }))] }) }), _jsxs(Flex, { container: { direction: 'column', gap: 2, pad: 2 }, as: StyledModernContentContainer, children: [!isCreateStage && stages?.content && (_jsx(StyledModernStagesContainer, { children: stages.content })), tasks?.content && (_jsx("div", { role: 'region', "aria-label": tasks.label, children: tasks.content })), showDesktopSummary && (hasSummaryFields || hasSummaryContent) && (_jsx(StyledModernSummary, { role: 'region', "aria-label": summary?.label ?? t('summary'), children: hasSummaryFields ? summaryFieldsCard : summary?.content })), !isCreateStage && bodyTabs.length === 1 && (_jsx(StyledModernContent, { role: 'region', "aria-label": bodyTabs[0].content.label, tabIndex: -1, ref: singleRegionRef, children: bodyTabs[0].content.content })), !isCreateStage && bodyTabs.length > 1 && (_jsxs("div", { children: [_jsx(Tabs, { tabs: bodyTabs, currentTabId: currentTabId, onTabClick: setCurrentTabId, ref: setTabsRef }), bodyTabs.map(tab => (_jsx(TabPanel, { tabId: tab.id, currentTabId: currentTabId, tablistRef: tabsRef, children: _jsx(StyledModernContent, { children: tab.content.content }) }, tab.id)))] }))] })] }));
|
|
204
|
+
};
|
|
205
|
+
export default ModernCaseView;
|
|
206
|
+
//# sourceMappingURL=ModernCaseView.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModernCaseView.js","sourceRoot":"","sources":["../../../src/components/ModernCaseView/ModernCaseView.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AACtC,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,eAAe,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AAG3F,OAAO,EACL,WAAW,EACX,IAAI,EACJ,IAAI,EACJ,UAAU,EACV,QAAQ,EACR,QAAQ,EACR,IAAI,EACJ,IAAI,EACJ,OAAO,EACP,aAAa,EACb,QAAQ,EACR,QAAQ,EACR,aAAa,EACb,YAAY,EACZ,OAAO,EACP,QAAQ,EACT,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,oBAAoB,EAAE,MAAM,iEAAiE,CAAC;AAIvG,OAAO,EACL,sBAAsB,EACtB,oCAAoC,EACpC,0BAA0B,EAC1B,0BAA0B,EAC1B,oBAAoB,EACpB,wBAAwB,EACxB,mBAAmB,EACnB,4BAA4B,EAC5B,2BAA2B,EAC3B,mBAAmB,EACnB,uBAAuB,EACvB,gCAAgC,EAChC,8BAA8B,EAC9B,gCAAgC,EAChC,8BAA8B,EAC/B,MAAM,yBAAyB,CAAC;AAEjC,MAAM,cAAc,GAAG,CAAC,EACtB,MAA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,CAAC,KAAK,EACrC,QAAQ,EAAE,CAAC,CAAC,EACZ,GAAG,EAAE,eAAe,YAEnB,QAAQ,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,GACR,CACvB,EAEA,CAAC,aAAa,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,IAAI,CACxC,0BACE,KAAC,IAAI,IACH,IAAI,EAAE,QAAQ,EACd,YAAY,EAAE,YAAY,EAC1B,UAAU,EAAE,eAAe,EAC3B,GAAG,EAAE,UAAU,GACf,EAED,QAAQ,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,CACnB,KAAC,QAAQ,IACP,KAAK,EAAE,GAAG,CAAC,EAAE,EACb,YAAY,EAAE,YAAY,EAE1B,UAAU,EAAE,OAAO,YAEnB,KAAC,mBAAmB,cAAE,GAAG,CAAC,OAAO,CAAC,OAAO,GAAuB,IAH3D,GAAG,CAAC,EAAE,CAIF,CACZ,CAAC,IACE,CACP,IACI,IACc,CACxB,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,cAAc,CAAC","sourcesContent":["import { parseToHsl } from 'polished';\nimport { useCallback, useEffect, useLayoutEffect, useMemo, useRef, useState } from 'react';\nimport type { MouseEvent, PropsWithoutRef } from 'react';\n\nimport {\n CardContent,\n Flex,\n Icon,\n MenuButton,\n MetaList,\n TabPanel,\n Tabs,\n Text,\n getEdge,\n readableColor,\n throttle,\n tryCatch,\n useBreakpoint,\n useDirection,\n useI18n,\n useTheme\n} from '@pega/cosmos-react-core';\nimport type { ForwardProps, Tab } from '@pega/cosmos-react-core';\nimport { resolveCaseTypeColor } from '@pega/cosmos-react-work/lib/components/CaseView/CaseView.styles';\n\nimport type { CaseViewProps, Region } from '../CaseView/CaseView.types';\n\nimport {\n StyledModernCaseHeader,\n StyledModernCaseHeaderPromotedAction,\n StyledModernCaseHeaderText,\n StyledModernCaseSubheading,\n StyledModernCaseView,\n StyledModernCaseViewIcon,\n StyledModernContent,\n StyledModernContentContainer,\n StyledModernStagesContainer,\n StyledModernSummary,\n StyledModernSummaryCard,\n StyledModernSummaryFieldsDivider,\n StyledModernSummaryPrimaryList,\n StyledModernSummarySecondaryList,\n resolveModernCaseViewIconColor\n} from './ModernCaseView.styles';\n\nconst ModernCaseView = ({\n caseId,\n heading,\n subheading,\n icon,\n color,\n actions,\n stages,\n tasks,\n summary,\n details,\n tabs: detailTabs,\n feed,\n utility,\n promotedActions = [],\n showPulse = true,\n showUtility = true,\n isCreateStage = false,\n ...restProps\n}: PropsWithoutRef<CaseViewProps> & ForwardProps) => {\n const t = useI18n();\n const theme = useTheme();\n const { ltr } = useDirection();\n\n const isSmallOrAbove = useBreakpoint('sm');\n const isMediumOrAbove = useBreakpoint('md');\n\n const tabsRef = useRef<HTMLElement | null>(null);\n const singleRegionRef = useRef<HTMLDivElement>(null);\n const restoreTabFocus = useRef(false);\n const contentEl = useRef<HTMLDivElement>(null);\n const headerEl = useRef<HTMLDivElement>(null);\n const actionsContainerEl = useRef<HTMLDivElement>(null);\n const wrapActionsBreakpoint = useRef<number | null>(null);\n\n const [wrapPromotedActions, setWrapPromotedActions] = useState(false);\n\n const setTabsRef = useCallback((element: HTMLElement | null) => {\n if (!element && tabsRef.current?.contains(document.activeElement)) {\n restoreTabFocus.current = true;\n }\n tabsRef.current = element;\n }, []);\n\n const primarySummaryFields = summary?.primarySummaryFields ?? [];\n const secondarySummaryFields = summary?.secondarySummaryFields ?? [];\n const hasPrimarySummaryFields = primarySummaryFields.length > 0;\n const hasSecondarySummaryFields = secondarySummaryFields.length > 0;\n const hasSummaryFields = hasPrimarySummaryFields || hasSecondarySummaryFields;\n const hasSummaryContent = Boolean(summary?.content);\n\n const detailRegions = useMemo(() => {\n if (detailTabs?.length) return detailTabs;\n return details ? [details] : [];\n }, [detailTabs, details]);\n\n const { iconForeground, iconBackground } = useMemo(() => {\n const backgroundSetting = theme.components['case-view'].icon.background;\n const foregroundSetting = theme.components['case-view'].icon.color;\n const usesIconGradient = backgroundSetting.includes('var(--gradient-');\n\n const resolvedIconBackground =\n backgroundSetting !== 'auto'\n ? backgroundSetting\n : tryCatch(\n () => {\n const { lightness } = parseToHsl(theme.components['case-view'].header.background);\n return lightness > 0.35 ? 'rgba(0, 0, 0, 0.2)' : 'rgba(255, 255, 255, 0.2)';\n },\n () => 'transparent'\n );\n\n let resolvedIconForeground =\n foregroundSetting !== 'auto'\n ? foregroundSetting\n : theme.components['case-view'].header['foreground-color'];\n\n if (foregroundSetting === 'auto' && usesIconGradient) {\n resolvedIconForeground = 'auto';\n }\n\n if (resolvedIconForeground === 'auto') {\n const caseTypeIconColor =\n theme.base['case-type-colors'] !== 'ignored'\n ? resolveCaseTypeColor(theme, color)\n : undefined;\n resolvedIconForeground = readableColor(\n usesIconGradient\n ? resolveModernCaseViewIconColor(theme, color)\n : caseTypeIconColor ?? resolvedIconBackground,\n { mode: 'light', level: 'AANonText' }\n );\n }\n\n return { iconForeground: resolvedIconForeground, iconBackground: resolvedIconBackground };\n }, [theme, color]);\n\n const promotedActionButtons = useMemo(\n () =>\n promotedActions.map(action => (\n <StyledModernCaseHeaderPromotedAction\n variant='secondary'\n href={action.href}\n disabled={action.disabled}\n onClick={(e: MouseEvent<HTMLButtonElement>) => action.onClick?.(action.id, e)}\n key={action.id}\n $color={color}\n >\n {action.text}\n </StyledModernCaseHeaderPromotedAction>\n )),\n [promotedActions, color]\n );\n\n const summaryFieldsCard = useMemo(\n () =>\n hasSummaryFields ? (\n <StyledModernSummaryCard>\n {hasPrimarySummaryFields && (\n <CardContent>\n <StyledModernSummaryPrimaryList\n variant='stacked'\n fields={primarySummaryFields}\n aria-label={t('primary_summary_fields')}\n $isSmallOrAbove={isSmallOrAbove}\n />\n </CardContent>\n )}\n {hasPrimarySummaryFields && hasSecondarySummaryFields && (\n <StyledModernSummaryFieldsDivider />\n )}\n {hasSecondarySummaryFields && (\n <CardContent>\n <StyledModernSummarySecondaryList\n variant='stacked'\n fields={secondarySummaryFields}\n aria-label={t('summary_fields')}\n $isSmallOrAbove={isSmallOrAbove}\n />\n </CardContent>\n )}\n </StyledModernSummaryCard>\n ) : null,\n [\n hasSummaryFields,\n hasPrimarySummaryFields,\n hasSecondarySummaryFields,\n primarySummaryFields,\n secondarySummaryFields,\n isSmallOrAbove,\n t\n ]\n );\n\n // Desktop: details + pulse + utilities. Mobile: summary is prepended as the first tab.\n const bodyTabs = useMemo(() => {\n const tabs: { id: string; name: Tab['name']; content: Region }[] = [];\n\n if (!isSmallOrAbove) {\n const summaryLabel = summary?.label ?? t('summary');\n\n if (hasSummaryFields) {\n tabs.push({\n id: 'summary',\n name: summaryLabel,\n content: { label: summaryLabel, content: summaryFieldsCard }\n });\n } else if (summary?.content) {\n tabs.push({ id: 'summary', name: summary.label, content: summary });\n }\n }\n\n detailRegions.forEach((region, index) => {\n if (!region.content) return;\n tabs.push({\n id: region.id ? `details-id-${region.id}` : `details-index-${index}`,\n name: region.label,\n content: region\n });\n });\n\n if (feed?.content && showPulse) tabs.push({ id: 'pulse', name: feed.label, content: feed });\n if (utility?.content && showUtility) {\n tabs.push({ id: 'utilities', name: utility.label, content: utility });\n }\n\n return tabs;\n }, [\n isSmallOrAbove,\n summary,\n detailRegions,\n feed,\n utility,\n summaryFieldsCard,\n hasSummaryFields,\n showPulse,\n showUtility,\n t\n ]);\n\n const [currentTabId, setCurrentTabId] = useState(() => bodyTabs[0]?.id ?? 'details');\n\n useEffect(() => {\n if (!bodyTabs.length) return;\n\n if (!bodyTabs.some(tab => tab.id === currentTabId)) {\n setCurrentTabId(bodyTabs[0].id);\n }\n }, [bodyTabs, currentTabId]);\n\n useLayoutEffect(() => {\n if (restoreTabFocus.current) {\n restoreTabFocus.current = false;\n singleRegionRef.current?.focus();\n }\n }, [bodyTabs, isCreateStage]);\n\n useLayoutEffect(() => {\n wrapActionsBreakpoint.current = null;\n setWrapPromotedActions(false);\n }, [\n promotedActions,\n actions,\n heading,\n subheading,\n icon,\n color,\n isSmallOrAbove,\n isMediumOrAbove,\n isCreateStage,\n ltr\n ]);\n\n useLayoutEffect(() => {\n if (!isSmallOrAbove || isCreateStage || !promotedActions.length) return;\n // Measure changed content after restoring the natural, unwrapped action row.\n if (wrapPromotedActions && wrapActionsBreakpoint.current === null) return;\n\n if (\n !wrapPromotedActions &&\n contentEl.current &&\n actionsContainerEl.current &&\n headerEl.current\n ) {\n const contentStart = getEdge({ el: contentEl.current, side: 'leading', ltr });\n const headerGroupEnd = getEdge({ el: headerEl.current, side: 'trailing', ltr });\n const actionsContainerWidth = actionsContainerEl.current.getBoundingClientRect().width;\n\n wrapActionsBreakpoint.current =\n Math.abs(Math.ceil(contentStart) - Math.ceil(headerGroupEnd)) +\n Math.ceil(actionsContainerWidth);\n }\n\n const promotedActionsWrapHandler = () => {\n if (wrapActionsBreakpoint.current !== null && contentEl.current) {\n const availableWidth = Math.ceil(contentEl.current.offsetWidth) - 20;\n setWrapPromotedActions(availableWidth < wrapActionsBreakpoint.current);\n }\n };\n\n const resizeObserver = new ResizeObserver(throttle(promotedActionsWrapHandler, 30));\n promotedActionsWrapHandler();\n\n if (contentEl.current) {\n resizeObserver.observe(contentEl.current, { box: 'border-box' });\n }\n\n return () => {\n resizeObserver.disconnect();\n };\n }, [\n contentEl,\n actionsContainerEl,\n headerEl,\n promotedActions,\n actions,\n heading,\n subheading,\n icon,\n color,\n wrapPromotedActions,\n isSmallOrAbove,\n isMediumOrAbove,\n isCreateStage,\n ltr\n ]);\n\n const showActions = !isCreateStage && (promotedActions.length > 0 || !!actions?.length);\n const shouldWrapPromotedActions = !isSmallOrAbove || wrapPromotedActions;\n const showDesktopSummary = !isCreateStage && isSmallOrAbove;\n\n return (\n <StyledModernCaseView\n $isCreateStage={isCreateStage}\n {...(isCreateStage && { 'data-create-stage': '' })}\n {...restProps}\n >\n <StyledModernCaseHeader $color={color} $isSmallOrAbove={isSmallOrAbove}>\n <Flex\n container={{ direction: 'column', gap: 2, pad: 2, alignItems: 'start' }}\n ref={contentEl}\n as={StyledModernContentContainer}\n >\n <Flex container={{ justify: 'between', alignItems: 'start', gap: 2 }} item={{ grow: 1 }}>\n <Flex container={{ gap: 2, alignItems: 'center' }}>\n {icon && (\n <StyledModernCaseViewIcon\n name={icon}\n emphasized\n foreground={iconForeground}\n background={iconBackground}\n $color={color}\n />\n )}\n\n <Flex\n as={StyledModernCaseHeaderText}\n container={{ direction: 'column', alignItems: 'start', justify: 'center' }}\n item={{ shrink: 1 }}\n ref={headerEl}\n >\n <Text variant='h1'>{heading}</Text>\n\n {subheading && (\n <StyledModernCaseSubheading $color={color}>\n {Array.isArray(subheading) ? <MetaList items={subheading} /> : subheading}\n </StyledModernCaseSubheading>\n )}\n </Flex>\n </Flex>\n\n {showActions && (\n <Flex container={{ gap: 1 }} ref={actionsContainerEl}>\n {!shouldWrapPromotedActions && promotedActionButtons}\n\n {actions && actions.length > 0 && (\n <MenuButton\n icon={promotedActions.length > 0 || !isMediumOrAbove ? 'more' : undefined}\n iconOnly={promotedActions.length > 0 || !isMediumOrAbove}\n variant='simple'\n text={t('actions')}\n aria-label={t('actions_for', [caseId])}\n menu={{\n items: actions.map(action => ({\n ...action,\n primary: action.text,\n visual: action.icon ? <Icon name={action.icon} /> : undefined\n })),\n scrollAt: 20\n }}\n />\n )}\n </Flex>\n )}\n </Flex>\n\n {shouldWrapPromotedActions && !isCreateStage && promotedActions.length > 0 && (\n <Flex\n item={{ grow: 1 }}\n container={{ justify: 'start', gap: 1, alignItems: 'center', wrap: 'wrap' }}\n >\n {promotedActionButtons}\n </Flex>\n )}\n </Flex>\n </StyledModernCaseHeader>\n\n <Flex container={{ direction: 'column', gap: 2, pad: 2 }} as={StyledModernContentContainer}>\n {!isCreateStage && stages?.content && (\n <StyledModernStagesContainer>{stages.content}</StyledModernStagesContainer>\n )}\n\n {tasks?.content && (\n <div role='region' aria-label={tasks.label}>\n {tasks.content}\n </div>\n )}\n\n {showDesktopSummary && (hasSummaryFields || hasSummaryContent) && (\n <StyledModernSummary role='region' aria-label={summary?.label ?? t('summary')}>\n {hasSummaryFields ? summaryFieldsCard : summary?.content}\n </StyledModernSummary>\n )}\n\n {!isCreateStage && bodyTabs.length === 1 && (\n <StyledModernContent\n role='region'\n aria-label={bodyTabs[0].content.label}\n tabIndex={-1}\n ref={singleRegionRef}\n >\n {bodyTabs[0].content.content}\n </StyledModernContent>\n )}\n\n {!isCreateStage && bodyTabs.length > 1 && (\n <div>\n <Tabs\n tabs={bodyTabs}\n currentTabId={currentTabId}\n onTabClick={setCurrentTabId}\n ref={setTabsRef}\n />\n\n {bodyTabs.map(tab => (\n <TabPanel\n tabId={tab.id}\n currentTabId={currentTabId}\n key={tab.id}\n tablistRef={tabsRef}\n >\n <StyledModernContent>{tab.content.content}</StyledModernContent>\n </TabPanel>\n ))}\n </div>\n )}\n </Flex>\n </StyledModernCaseView>\n );\n};\n\nexport default ModernCaseView;\n"]}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { DefaultTheme } from 'styled-components';
|
|
2
|
+
export declare const StyledModernCaseView: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
|
|
3
|
+
$isCreateStage?: boolean;
|
|
4
|
+
}>> & string;
|
|
5
|
+
export declare const StyledModernCaseHeader: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, {
|
|
6
|
+
$color?: string;
|
|
7
|
+
$isSmallOrAbove?: boolean;
|
|
8
|
+
}>> & string;
|
|
9
|
+
export declare const StyledModernCaseSubheading: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
|
|
10
|
+
$color?: string;
|
|
11
|
+
}>> & string;
|
|
12
|
+
export declare const StyledModernCaseHeaderText: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
13
|
+
/** Resolves `auto` accents to a solid palette color for the case icon gradient. */
|
|
14
|
+
export declare const resolveModernCaseViewIconColor: (theme: DefaultTheme, color: string | undefined) => string;
|
|
15
|
+
export declare const StyledModernCaseViewIcon: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("@pega/cosmos-react-core").IconProps & import("styled-components/dist/types").BaseObject, {
|
|
16
|
+
$color?: string;
|
|
17
|
+
}>> & string & Omit<import("react").ForwardRefExoticComponent<import("@pega/cosmos-react-core").IconProps>, keyof import("react").Component<any, {}, any>>;
|
|
18
|
+
export declare const StyledModernCaseHeaderPromotedAction: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<Omit<Omit<import("@pega/cosmos-react-core").ButtonProps, "ref"> & import("react").RefAttributes<HTMLAnchorElement | HTMLButtonElement> & import("@pega/cosmos-react-core").ForwardProps, "ref"> & {
|
|
19
|
+
ref?: ((instance: HTMLAnchorElement | HTMLButtonElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLAnchorElement | HTMLButtonElement> | null | undefined;
|
|
20
|
+
}, {
|
|
21
|
+
$color?: string;
|
|
22
|
+
}>> & string & Omit<import("@pega/cosmos-react-core").ForwardRefForwardPropsComponent<import("@pega/cosmos-react-core").ButtonProps>, keyof import("react").Component<any, {}, any>>;
|
|
23
|
+
export declare const StyledModernContentContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
24
|
+
export declare const StyledModernContent: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
25
|
+
export declare const StyledModernSummary: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
26
|
+
export declare const StyledModernSummaryFieldsDivider: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLHRElement>, HTMLHRElement>, never>> & string;
|
|
27
|
+
export declare const StyledModernSummaryPrimaryList: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("styled-components").FastOmit<import("@pega/cosmos-react-core").FieldValueListProps & import("@pega/cosmos-react-core").ForwardProps, "wrapped"> & {
|
|
28
|
+
wrapped?: boolean;
|
|
29
|
+
}, {
|
|
30
|
+
$isSmallOrAbove?: boolean;
|
|
31
|
+
}>> & string;
|
|
32
|
+
export declare const StyledModernSummarySecondaryList: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("styled-components").FastOmit<import("@pega/cosmos-react-core").FieldValueListProps & import("@pega/cosmos-react-core").ForwardProps, never>, {
|
|
33
|
+
$isSmallOrAbove?: boolean;
|
|
34
|
+
}>> & string;
|
|
35
|
+
export declare const StyledModernSummaryCard: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<Omit<Omit<import("@pega/cosmos-react-core").CardProps, "ref"> & import("react").RefAttributes<HTMLElement> & import("@pega/cosmos-react-core").ForwardProps, "ref"> & {
|
|
36
|
+
ref?: ((instance: HTMLElement | null) => void | import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import("react").DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import("react").RefObject<HTMLElement> | null | undefined;
|
|
37
|
+
}, never>> & string & Omit<import("@pega/cosmos-react-core").ForwardRefForwardPropsComponent<import("@pega/cosmos-react-core").CardProps>, keyof import("react").Component<any, {}, any>>;
|
|
38
|
+
export declare const StyledModernStagesContainer: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
|
|
39
|
+
//# sourceMappingURL=ModernCaseView.styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModernCaseView.styles.d.ts","sourceRoot":"","sources":["../../../src/components/ModernCaseView/ModernCaseView.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AA4FtD,eAAO,MAAM,oBAAoB;qBAAiC,OAAO;YASxE,CAAC;AAIF,eAAO,MAAM,sBAAsB;aACxB,MAAM;sBACG,OAAO;YAczB,CAAC;AAIH,eAAO,MAAM,0BAA0B;aAAyB,MAAM;YAiBpE,CAAC;AAIH,eAAO,MAAM,0BAA0B,6NAEtC,CAAC;AAIF,mFAAmF;AACnF,eAAO,MAAM,8BAA8B,GACzC,OAAO,YAAY,EACnB,OAAO,MAAM,GAAG,SAAS,KACxB,MAUF,CAAC;AAEF,eAAO,MAAM,wBAAwB;aAA2B,MAAM;0JAoCpE,CAAC;AAIH,eAAO,MAAM,oCAAoC;;;aAA6B,MAAM;oLAyBlF,CAAC;AAIH,eAAO,MAAM,4BAA4B,6NAuBvC,CAAC;AAIH,eAAO,MAAM,mBAAmB,6NAO9B,CAAC;AAIH,eAAO,MAAM,mBAAmB,6NAO9B,CAAC;AAIH,eAAO,MAAM,gCAAgC,2NAO3C,CAAC;AAIH,eAAO,MAAM,8BAA8B;;;sBACvB,OAAO;YASzB,CAAC;AAIH,eAAO,MAAM,gCAAgC;sBACzB,OAAO;YAYzB,CAAC;AAIH,eAAO,MAAM,uBAAuB;;yLAclC,CAAC;AAIH,eAAO,MAAM,2BAA2B,6NAIvC,CAAC"}
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
import styled, { css } from 'styled-components';
|
|
2
|
+
import { getContrast, mix, rgba } from 'polished';
|
|
3
|
+
import { Button, Card, Icon, StyledButton, StyledCard, StyledStackedFieldValue, calculateFontSize, calculateForegroundColor, defaultThemeProp, isSolidColor, readableColor, readableHue, tryCatch } from '@pega/cosmos-react-core';
|
|
4
|
+
import { wcagContrast } from '@pega/cosmos-react-core/lib/styles/constants';
|
|
5
|
+
import { StyledCardContent } from '@pega/cosmos-react-core/lib/components/Card/CardContent';
|
|
6
|
+
import { StyledTabPanel } from '@pega/cosmos-react-core/lib/components/Tabs/TabPanel';
|
|
7
|
+
import { StyledSummaryPrimaryList, StyledSummarySecondaryList, resolveCaseTypeColor } from '@pega/cosmos-react-work/lib/components/CaseView/CaseView.styles';
|
|
8
|
+
import { StyledStages } from '@pega/cosmos-react-work/lib/components/Stages/Stages.styles';
|
|
9
|
+
const getCaseTypeHeaderColors = (theme, color) => {
|
|
10
|
+
const resolvedCaseTypeColor = resolveCaseTypeColor(theme, color);
|
|
11
|
+
const headerBackground = resolvedCaseTypeColor &&
|
|
12
|
+
theme.base['case-type-colors'] === 'header-and-icon' &&
|
|
13
|
+
isSolidColor(theme.components.card.background)
|
|
14
|
+
? tryCatch(() => mix(0.85, theme.components.card.background, resolvedCaseTypeColor), () => theme.components.card.background)
|
|
15
|
+
: theme.components['case-view'].header.background;
|
|
16
|
+
const foregroundColor = calculateForegroundColor(headerBackground, resolvedCaseTypeColor && theme.base['case-type-colors'] === 'header-and-icon'
|
|
17
|
+
? 'auto'
|
|
18
|
+
: theme.components['case-view'].header['foreground-color'], theme);
|
|
19
|
+
return { headerBackground, foregroundColor };
|
|
20
|
+
};
|
|
21
|
+
const getModernCaseViewColors = (theme, color) => {
|
|
22
|
+
const { interactive } = theme.base.palette;
|
|
23
|
+
const { headerBackground, foregroundColor } = getCaseTypeHeaderColors(theme, color);
|
|
24
|
+
const isGradientBackground = !isSolidColor(headerBackground);
|
|
25
|
+
const elementBackground = isGradientBackground
|
|
26
|
+
? readableColor(foregroundColor)
|
|
27
|
+
: headerBackground;
|
|
28
|
+
const interactiveUsable = getContrast(elementBackground, interactive) >= wcagContrast.AA;
|
|
29
|
+
const interactiveColor = !isGradientBackground && interactiveUsable ? interactive : foregroundColor;
|
|
30
|
+
const hoverBackground = !isGradientBackground && interactiveUsable
|
|
31
|
+
? readableHue(interactive, interactiveColor)
|
|
32
|
+
: rgba(readableColor(interactiveColor), 0.15);
|
|
33
|
+
return {
|
|
34
|
+
headerBackground,
|
|
35
|
+
foregroundColor,
|
|
36
|
+
elementBackground,
|
|
37
|
+
interactiveColor,
|
|
38
|
+
hoverBackground
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
export const StyledModernCaseView = styled.div(({ $isCreateStage }) => css `
|
|
42
|
+
min-height: ${$isCreateStage ? 'calc(100vh - var(--appshell-total-offset, 3rem))' : 'inherit'};
|
|
43
|
+
|
|
44
|
+
${StyledTabPanel}${StyledTabPanel}${StyledTabPanel} ${StyledCard} {
|
|
45
|
+
border: none;
|
|
46
|
+
padding: 0;
|
|
47
|
+
}
|
|
48
|
+
`);
|
|
49
|
+
StyledModernCaseView.defaultProps = defaultThemeProp;
|
|
50
|
+
export const StyledModernCaseHeader = styled.header(({ theme, $color, $isSmallOrAbove }) => {
|
|
51
|
+
const { headerBackground, foregroundColor } = getModernCaseViewColors(theme, $color);
|
|
52
|
+
return css `
|
|
53
|
+
position: relative;
|
|
54
|
+
background: ${headerBackground};
|
|
55
|
+
color: ${foregroundColor};
|
|
56
|
+
|
|
57
|
+
h1 {
|
|
58
|
+
color: ${foregroundColor};
|
|
59
|
+
min-width: ${$isSmallOrAbove ? theme.base['content-width'].xs : 'auto'};
|
|
60
|
+
}
|
|
61
|
+
`;
|
|
62
|
+
});
|
|
63
|
+
StyledModernCaseHeader.defaultProps = defaultThemeProp;
|
|
64
|
+
export const StyledModernCaseSubheading = styled.div(({ theme, $color }) => {
|
|
65
|
+
const { foregroundColor } = getModernCaseViewColors(theme, $color);
|
|
66
|
+
const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
|
|
67
|
+
return css `
|
|
68
|
+
color: ${foregroundColor};
|
|
69
|
+
font-size: ${fontSize.xs};
|
|
70
|
+
font-weight: normal;
|
|
71
|
+
margin: 0;
|
|
72
|
+
|
|
73
|
+
/* MetaList renders items as Text elements with explicit styles. */
|
|
74
|
+
&& li {
|
|
75
|
+
color: inherit;
|
|
76
|
+
font-size: inherit;
|
|
77
|
+
font-weight: inherit;
|
|
78
|
+
}
|
|
79
|
+
`;
|
|
80
|
+
});
|
|
81
|
+
StyledModernCaseSubheading.defaultProps = defaultThemeProp;
|
|
82
|
+
export const StyledModernCaseHeaderText = styled.div `
|
|
83
|
+
word-break: break-word;
|
|
84
|
+
`;
|
|
85
|
+
StyledModernCaseHeaderText.defaultProps = defaultThemeProp;
|
|
86
|
+
/** Resolves `auto` accents to a solid palette color for the case icon gradient. */
|
|
87
|
+
export const resolveModernCaseViewIconColor = (theme, color) => {
|
|
88
|
+
const caseTypeColorsEnabled = theme.base['case-type-colors'] === 'icon-only' ||
|
|
89
|
+
theme.base['case-type-colors'] === 'header-and-icon';
|
|
90
|
+
const resolvedCaseTypeColor = caseTypeColorsEnabled
|
|
91
|
+
? resolveCaseTypeColor(theme, color)
|
|
92
|
+
: undefined;
|
|
93
|
+
const accent = theme.base.palette['brand-accent'];
|
|
94
|
+
return resolvedCaseTypeColor ?? (accent === 'auto' ? theme.base.palette.dark : accent);
|
|
95
|
+
};
|
|
96
|
+
export const StyledModernCaseViewIcon = styled(Icon)(({ theme, $color }) => {
|
|
97
|
+
const caseTypeColorsEnabled = theme.base['case-type-colors'] === 'icon-only' ||
|
|
98
|
+
theme.base['case-type-colors'] === 'header-and-icon';
|
|
99
|
+
const resolvedCaseTypeColor = caseTypeColorsEnabled
|
|
100
|
+
? resolveCaseTypeColor(theme, $color)
|
|
101
|
+
: undefined;
|
|
102
|
+
return css `
|
|
103
|
+
--icon-color: ${resolveModernCaseViewIconColor(theme, $color)};
|
|
104
|
+
--gradient-start: oklch(from var(--icon-color) calc(l - 0.3) calc(c * 1.5) h);
|
|
105
|
+
--gradient-mid: oklch(from var(--icon-color) l c h);
|
|
106
|
+
--gradient-end: oklch(from var(--icon-color) calc(l + 0.5) calc(c * 1.5) h);
|
|
107
|
+
flex-shrink: 0;
|
|
108
|
+
|
|
109
|
+
${theme.components['case-view'].icon.color !== 'auto' &&
|
|
110
|
+
css `
|
|
111
|
+
color: ${theme.components['case-view'].icon.color};
|
|
112
|
+
`}
|
|
113
|
+
|
|
114
|
+
${theme.components['case-view'].icon.background !== 'auto' &&
|
|
115
|
+
css `
|
|
116
|
+
background: ${theme.components['case-view'].icon.background};
|
|
117
|
+
`}
|
|
118
|
+
|
|
119
|
+
${theme.components['case-view'].icon.background === 'auto' &&
|
|
120
|
+
resolvedCaseTypeColor &&
|
|
121
|
+
css `
|
|
122
|
+
background: ${resolvedCaseTypeColor};
|
|
123
|
+
`}
|
|
124
|
+
|
|
125
|
+
${theme.components['case-view'].icon['box-shadow'] !== 'auto' &&
|
|
126
|
+
css `
|
|
127
|
+
box-shadow: ${theme.components['case-view'].icon['box-shadow']};
|
|
128
|
+
`}
|
|
129
|
+
`;
|
|
130
|
+
});
|
|
131
|
+
StyledModernCaseViewIcon.defaultProps = defaultThemeProp;
|
|
132
|
+
export const StyledModernCaseHeaderPromotedAction = styled(Button)(({ theme, $color }) => {
|
|
133
|
+
const { elementBackground, interactiveColor, hoverBackground } = getModernCaseViewColors(theme, $color);
|
|
134
|
+
return css `
|
|
135
|
+
--button-background-color: ${elementBackground};
|
|
136
|
+
color: ${interactiveColor};
|
|
137
|
+
background-color: transparent;
|
|
138
|
+
border-color: ${interactiveColor};
|
|
139
|
+
|
|
140
|
+
@media (hover: hover) {
|
|
141
|
+
&:hover,
|
|
142
|
+
&:active {
|
|
143
|
+
--button-background-color: ${hoverBackground};
|
|
144
|
+
color: ${interactiveColor};
|
|
145
|
+
background-color: ${hoverBackground};
|
|
146
|
+
border-color: ${interactiveColor};
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
`;
|
|
150
|
+
});
|
|
151
|
+
StyledModernCaseHeaderPromotedAction.defaultProps = defaultThemeProp;
|
|
152
|
+
export const StyledModernContentContainer = styled.div(({ theme }) => {
|
|
153
|
+
const { breakpoints } = theme.base;
|
|
154
|
+
return css `
|
|
155
|
+
width: 100%;
|
|
156
|
+
margin-inline: auto;
|
|
157
|
+
|
|
158
|
+
@media screen and (min-width: ${breakpoints.md}) {
|
|
159
|
+
width: 85%;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
@media screen and (min-width: ${breakpoints.lg}) {
|
|
163
|
+
max-width: ${theme.base['content-width'].xl};
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
& > div {
|
|
167
|
+
width: 100%;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
${StyledButton} {
|
|
171
|
+
margin-inline-start: 0;
|
|
172
|
+
}
|
|
173
|
+
`;
|
|
174
|
+
});
|
|
175
|
+
StyledModernContentContainer.defaultProps = defaultThemeProp;
|
|
176
|
+
export const StyledModernContent = styled.div(({ theme }) => {
|
|
177
|
+
return css `
|
|
178
|
+
${StyledSummaryPrimaryList} {
|
|
179
|
+
grid-template-columns: auto 1fr;
|
|
180
|
+
column-gap: calc(2 * ${theme.base.spacing});
|
|
181
|
+
}
|
|
182
|
+
`;
|
|
183
|
+
});
|
|
184
|
+
StyledModernContent.defaultProps = defaultThemeProp;
|
|
185
|
+
export const StyledModernSummary = styled.div(({ theme }) => {
|
|
186
|
+
return css `
|
|
187
|
+
background: ${theme.components.card.background};
|
|
188
|
+
border-radius: ${theme.base['border-radius']};
|
|
189
|
+
padding: calc(${theme.base.spacing} * 1.5);
|
|
190
|
+
align-self: start;
|
|
191
|
+
`;
|
|
192
|
+
});
|
|
193
|
+
StyledModernSummary.defaultProps = defaultThemeProp;
|
|
194
|
+
export const StyledModernSummaryFieldsDivider = styled.hr(({ theme }) => {
|
|
195
|
+
return css `
|
|
196
|
+
margin: 0 calc(2 * ${theme.base.spacing});
|
|
197
|
+
border: none;
|
|
198
|
+
border-block-start: ${theme.components.button['border-width']} solid
|
|
199
|
+
${theme.base.palette['border-line']};
|
|
200
|
+
`;
|
|
201
|
+
});
|
|
202
|
+
StyledModernSummaryFieldsDivider.defaultProps = defaultThemeProp;
|
|
203
|
+
export const StyledModernSummaryPrimaryList = styled(StyledSummaryPrimaryList)(({ theme, $isSmallOrAbove }) => {
|
|
204
|
+
return css `
|
|
205
|
+
&&& {
|
|
206
|
+
grid-template-columns: ${$isSmallOrAbove ? 'repeat(2, 1fr)' : '1fr'};
|
|
207
|
+
column-gap: calc(2 * ${theme.base.spacing});
|
|
208
|
+
row-gap: calc(2 * ${theme.base.spacing});
|
|
209
|
+
}
|
|
210
|
+
`;
|
|
211
|
+
});
|
|
212
|
+
StyledModernSummaryPrimaryList.defaultProps = defaultThemeProp;
|
|
213
|
+
export const StyledModernSummarySecondaryList = styled(StyledSummarySecondaryList)(({ theme, $isSmallOrAbove }) => {
|
|
214
|
+
return css `
|
|
215
|
+
&&& {
|
|
216
|
+
grid-template-columns: ${$isSmallOrAbove ? 'repeat(2, 1fr)' : '1fr'};
|
|
217
|
+
row-gap: calc(2 * ${theme.base.spacing});
|
|
218
|
+
}
|
|
219
|
+
|
|
220
|
+
${StyledStackedFieldValue} {
|
|
221
|
+
grid-column: auto;
|
|
222
|
+
}
|
|
223
|
+
`;
|
|
224
|
+
});
|
|
225
|
+
StyledModernSummarySecondaryList.defaultProps = defaultThemeProp;
|
|
226
|
+
export const StyledModernSummaryCard = styled(Card)(({ theme }) => {
|
|
227
|
+
const { base: { breakpoints, spacing } } = theme;
|
|
228
|
+
return css `
|
|
229
|
+
&&&& ${StyledCardContent} {
|
|
230
|
+
padding: calc(1.5 * ${spacing}) calc(${theme.components.card.padding} * 2);
|
|
231
|
+
|
|
232
|
+
@media (width < ${breakpoints.sm}) {
|
|
233
|
+
padding: ${spacing} calc(${theme.components.card.padding} * 1.5);
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
`;
|
|
237
|
+
});
|
|
238
|
+
StyledModernSummaryCard.defaultProps = defaultThemeProp;
|
|
239
|
+
export const StyledModernStagesContainer = styled.div `
|
|
240
|
+
${StyledStages} {
|
|
241
|
+
background: transparent;
|
|
242
|
+
}
|
|
243
|
+
`;
|
|
244
|
+
StyledModernStagesContainer.defaultProps = defaultThemeProp;
|
|
245
|
+
//# sourceMappingURL=ModernCaseView.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ModernCaseView.styles.js","sourceRoot":"","sources":["../../../src/components/ModernCaseView/ModernCaseView.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,WAAW,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAElD,OAAO,EACL,MAAM,EACN,IAAI,EACJ,IAAI,EACJ,YAAY,EACZ,UAAU,EACV,uBAAuB,EACvB,iBAAiB,EACjB,wBAAwB,EACxB,gBAAgB,EAChB,YAAY,EACZ,aAAa,EACb,WAAW,EACX,QAAQ,EACT,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,YAAY,EAAE,MAAM,8CAA8C,CAAC;AAC5E,OAAO,EAAE,iBAAiB,EAAE,MAAM,yDAAyD,CAAC;AAC5F,OAAO,EAAE,cAAc,EAAE,MAAM,sDAAsD,CAAC;AACtF,OAAO,EACL,wBAAwB,EACxB,0BAA0B,EAC1B,oBAAoB,EACrB,MAAM,iEAAiE,CAAC;AACzE,OAAO,EAAE,YAAY,EAAE,MAAM,6DAA6D,CAAC;AAU3F,MAAM,uBAAuB,GAAG,CAC9B,KAAmB,EACnB,KAAyB,E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uBAAuB;;;GAG1B,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,gCAAgC,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEjE,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAChE,MAAM,EACJ,IAAI,EAAE,EAAE,WAAW,EAAE,OAAO,EAAE,EAC/B,GAAG,KAAK,CAAC;IAEV,OAAO,GAAG,CAAA;WACD,iBAAiB;4BACA,OAAO,UAAU,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO;;wBAElD,WAAW,CAAC,EAAE;mBACnB,OAAO,SAAS,KAAK,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO;;;GAG7D,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,uBAAuB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAExD,MAAM,CAAC,MAAM,2BAA2B,GAAG,MAAM,CAAC,GAAG,CAAA;IACjD,YAAY;;;CAGf,CAAC;AAEF,2BAA2B,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport type { DefaultTheme } from 'styled-components';\nimport { getContrast, mix, rgba } from 'polished';\n\nimport {\n Button,\n Card,\n Icon,\n StyledButton,\n StyledCard,\n StyledStackedFieldValue,\n calculateFontSize,\n calculateForegroundColor,\n defaultThemeProp,\n isSolidColor,\n readableColor,\n readableHue,\n tryCatch\n} from '@pega/cosmos-react-core';\nimport { wcagContrast } from '@pega/cosmos-react-core/lib/styles/constants';\nimport { StyledCardContent } from '@pega/cosmos-react-core/lib/components/Card/CardContent';\nimport { StyledTabPanel } from '@pega/cosmos-react-core/lib/components/Tabs/TabPanel';\nimport {\n StyledSummaryPrimaryList,\n StyledSummarySecondaryList,\n resolveCaseTypeColor\n} from '@pega/cosmos-react-work/lib/components/CaseView/CaseView.styles';\nimport { StyledStages } from '@pega/cosmos-react-work/lib/components/Stages/Stages.styles';\n\ninterface ModernCaseViewColors {\n headerBackground: string;\n foregroundColor: string;\n elementBackground: string;\n interactiveColor: string;\n hoverBackground: string;\n}\n\nconst getCaseTypeHeaderColors = (\n theme: DefaultTheme,\n color: string | undefined\n): { headerBackground: string; foregroundColor: string } => {\n const resolvedCaseTypeColor = resolveCaseTypeColor(theme, color);\n const headerBackground =\n resolvedCaseTypeColor &&\n theme.base['case-type-colors'] === 'header-and-icon' &&\n isSolidColor(theme.components.card.background)\n ? tryCatch(\n () => mix(0.85, theme.components.card.background, resolvedCaseTypeColor),\n () => theme.components.card.background\n )\n : theme.components['case-view'].header.background;\n\n const foregroundColor = calculateForegroundColor(\n headerBackground,\n resolvedCaseTypeColor && theme.base['case-type-colors'] === 'header-and-icon'\n ? 'auto'\n : theme.components['case-view'].header['foreground-color'],\n theme\n );\n\n return { headerBackground, foregroundColor };\n};\n\nconst getModernCaseViewColors = (\n theme: DefaultTheme,\n color: string | undefined\n): ModernCaseViewColors => {\n const { interactive } = theme.base.palette;\n const { headerBackground, foregroundColor } = getCaseTypeHeaderColors(theme, color);\n\n const isGradientBackground = !isSolidColor(headerBackground);\n const elementBackground = isGradientBackground\n ? readableColor(foregroundColor)\n : headerBackground;\n\n const interactiveUsable = getContrast(elementBackground, interactive) >= wcagContrast.AA;\n const interactiveColor =\n !isGradientBackground && interactiveUsable ? interactive : foregroundColor;\n\n const hoverBackground =\n !isGradientBackground && interactiveUsable\n ? readableHue(interactive, interactiveColor)\n : rgba(readableColor(interactiveColor), 0.15);\n\n return {\n headerBackground,\n foregroundColor,\n elementBackground,\n interactiveColor,\n hoverBackground\n };\n};\n\nexport const StyledModernCaseView = styled.div<{ $isCreateStage?: boolean }>(\n ({ $isCreateStage }) => css`\n min-height: ${$isCreateStage ? 'calc(100vh - var(--appshell-total-offset, 3rem))' : 'inherit'};\n\n ${StyledTabPanel}${StyledTabPanel}${StyledTabPanel} ${StyledCard} {\n border: none;\n padding: 0;\n }\n `\n);\n\nStyledModernCaseView.defaultProps = defaultThemeProp;\n\nexport const StyledModernCaseHeader = styled.header<{\n $color?: string;\n $isSmallOrAbove?: boolean;\n}>(({ theme, $color, $isSmallOrAbove }) => {\n const { headerBackground, foregroundColor } = getModernCaseViewColors(theme, $color);\n\n return css`\n position: relative;\n background: ${headerBackground};\n color: ${foregroundColor};\n\n h1 {\n color: ${foregroundColor};\n min-width: ${$isSmallOrAbove ? theme.base['content-width'].xs : 'auto'};\n }\n `;\n});\n\nStyledModernCaseHeader.defaultProps = defaultThemeProp;\n\nexport const StyledModernCaseSubheading = styled.div<{ $color?: string }>(({ theme, $color }) => {\n const { foregroundColor } = getModernCaseViewColors(theme, $color);\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n\n return css`\n color: ${foregroundColor};\n font-size: ${fontSize.xs};\n font-weight: normal;\n margin: 0;\n\n /* MetaList renders items as Text elements with explicit styles. */\n && li {\n color: inherit;\n font-size: inherit;\n font-weight: inherit;\n }\n `;\n});\n\nStyledModernCaseSubheading.defaultProps = defaultThemeProp;\n\nexport const StyledModernCaseHeaderText = styled.div`\n word-break: break-word;\n`;\n\nStyledModernCaseHeaderText.defaultProps = defaultThemeProp;\n\n/** Resolves `auto` accents to a solid palette color for the case icon gradient. */\nexport const resolveModernCaseViewIconColor = (\n theme: DefaultTheme,\n color: string | undefined\n): string => {\n const caseTypeColorsEnabled =\n theme.base['case-type-colors'] === 'icon-only' ||\n theme.base['case-type-colors'] === 'header-and-icon';\n const resolvedCaseTypeColor = caseTypeColorsEnabled\n ? resolveCaseTypeColor(theme, color)\n : undefined;\n const accent = theme.base.palette['brand-accent'];\n\n return resolvedCaseTypeColor ?? (accent === 'auto' ? theme.base.palette.dark : accent);\n};\n\nexport const StyledModernCaseViewIcon = styled(Icon)<{ $color?: string }>(({ theme, $color }) => {\n const caseTypeColorsEnabled =\n theme.base['case-type-colors'] === 'icon-only' ||\n theme.base['case-type-colors'] === 'header-and-icon';\n const resolvedCaseTypeColor = caseTypeColorsEnabled\n ? resolveCaseTypeColor(theme, $color)\n : undefined;\n\n return css`\n --icon-color: ${resolveModernCaseViewIconColor(theme, $color)};\n --gradient-start: oklch(from var(--icon-color) calc(l - 0.3) calc(c * 1.5) h);\n --gradient-mid: oklch(from var(--icon-color) l c h);\n --gradient-end: oklch(from var(--icon-color) calc(l + 0.5) calc(c * 1.5) h);\n flex-shrink: 0;\n\n ${theme.components['case-view'].icon.color !== 'auto' &&\n css`\n color: ${theme.components['case-view'].icon.color};\n `}\n\n ${theme.components['case-view'].icon.background !== 'auto' &&\n css`\n background: ${theme.components['case-view'].icon.background};\n `}\n\n ${theme.components['case-view'].icon.background === 'auto' &&\n resolvedCaseTypeColor &&\n css`\n background: ${resolvedCaseTypeColor};\n `}\n\n ${theme.components['case-view'].icon['box-shadow'] !== 'auto' &&\n css`\n box-shadow: ${theme.components['case-view'].icon['box-shadow']};\n `}\n `;\n});\n\nStyledModernCaseViewIcon.defaultProps = defaultThemeProp;\n\nexport const StyledModernCaseHeaderPromotedAction = styled(Button)<{ $color?: string }>(({\n theme,\n $color\n}) => {\n const { elementBackground, interactiveColor, hoverBackground } = getModernCaseViewColors(\n theme,\n $color\n );\n\n return css`\n --button-background-color: ${elementBackground};\n color: ${interactiveColor};\n background-color: transparent;\n border-color: ${interactiveColor};\n\n @media (hover: hover) {\n &:hover,\n &:active {\n --button-background-color: ${hoverBackground};\n color: ${interactiveColor};\n background-color: ${hoverBackground};\n border-color: ${interactiveColor};\n }\n }\n `;\n});\n\nStyledModernCaseHeaderPromotedAction.defaultProps = defaultThemeProp;\n\nexport const StyledModernContentContainer = styled.div(({ theme }) => {\n const { breakpoints } = theme.base;\n\n return css`\n width: 100%;\n margin-inline: auto;\n\n @media screen and (min-width: ${breakpoints.md}) {\n width: 85%;\n }\n\n @media screen and (min-width: ${breakpoints.lg}) {\n max-width: ${theme.base['content-width'].xl};\n }\n\n & > div {\n width: 100%;\n }\n\n ${StyledButton} {\n margin-inline-start: 0;\n }\n `;\n});\n\nStyledModernContentContainer.defaultProps = defaultThemeProp;\n\nexport const StyledModernContent = styled.div(({ theme }) => {\n return css`\n ${StyledSummaryPrimaryList} {\n grid-template-columns: auto 1fr;\n column-gap: calc(2 * ${theme.base.spacing});\n }\n `;\n});\n\nStyledModernContent.defaultProps = defaultThemeProp;\n\nexport const StyledModernSummary = styled.div(({ theme }) => {\n return css`\n background: ${theme.components.card.background};\n border-radius: ${theme.base['border-radius']};\n padding: calc(${theme.base.spacing} * 1.5);\n align-self: start;\n `;\n});\n\nStyledModernSummary.defaultProps = defaultThemeProp;\n\nexport const StyledModernSummaryFieldsDivider = styled.hr(({ theme }) => {\n return css`\n margin: 0 calc(2 * ${theme.base.spacing});\n border: none;\n border-block-start: ${theme.components.button['border-width']} solid\n ${theme.base.palette['border-line']};\n `;\n});\n\nStyledModernSummaryFieldsDivider.defaultProps = defaultThemeProp;\n\nexport const StyledModernSummaryPrimaryList = styled(StyledSummaryPrimaryList)<{\n $isSmallOrAbove?: boolean;\n}>(({ theme, $isSmallOrAbove }) => {\n return css`\n &&& {\n grid-template-columns: ${$isSmallOrAbove ? 'repeat(2, 1fr)' : '1fr'};\n column-gap: calc(2 * ${theme.base.spacing});\n row-gap: calc(2 * ${theme.base.spacing});\n }\n `;\n});\n\nStyledModernSummaryPrimaryList.defaultProps = defaultThemeProp;\n\nexport const StyledModernSummarySecondaryList = styled(StyledSummarySecondaryList)<{\n $isSmallOrAbove?: boolean;\n}>(({ theme, $isSmallOrAbove }) => {\n return css`\n &&& {\n grid-template-columns: ${$isSmallOrAbove ? 'repeat(2, 1fr)' : '1fr'};\n row-gap: calc(2 * ${theme.base.spacing});\n }\n\n ${StyledStackedFieldValue} {\n grid-column: auto;\n }\n `;\n});\n\nStyledModernSummarySecondaryList.defaultProps = defaultThemeProp;\n\nexport const StyledModernSummaryCard = styled(Card)(({ theme }) => {\n const {\n base: { breakpoints, spacing }\n } = theme;\n\n return css`\n &&&& ${StyledCardContent} {\n padding: calc(1.5 * ${spacing}) calc(${theme.components.card.padding} * 2);\n\n @media (width < ${breakpoints.sm}) {\n padding: ${spacing} calc(${theme.components.card.padding} * 1.5);\n }\n }\n `;\n});\n\nStyledModernSummaryCard.defaultProps = defaultThemeProp;\n\nexport const StyledModernStagesContainer = styled.div`\n ${StyledStages} {\n background: transparent;\n }\n`;\n\nStyledModernStagesContainer.defaultProps = defaultThemeProp;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/ModernCaseView/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/ModernCaseView/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC","sourcesContent":["export { default } from './ModernCaseView';\n"]}
|
package/lib/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export { default as CaseView } from './components/CaseView';
|
|
|
4
4
|
export * from './components/CaseView';
|
|
5
5
|
export { default as Footer } from './components/Footer';
|
|
6
6
|
export * from './components/Footer';
|
|
7
|
+
export { default as ModernCaseView } from './components/ModernCaseView';
|
|
7
8
|
export * from './components/PageTemplates';
|
|
8
9
|
export { default as QuickCreate } from './components/QuickCreate';
|
|
9
10
|
export * from './components/QuickCreate';
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,cAAc,qBAAqB,CAAC;AACpC,cAAc,4BAA4B,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,0BAA0B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,6BAA6B,CAAC;AACxE,cAAc,4BAA4B,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,0BAA0B,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -5,6 +5,7 @@ export { default as CaseView } from './components/CaseView';
|
|
|
5
5
|
export * from './components/CaseView';
|
|
6
6
|
export { default as Footer } from './components/Footer';
|
|
7
7
|
export * from './components/Footer';
|
|
8
|
+
export { default as ModernCaseView } from './components/ModernCaseView';
|
|
8
9
|
export * from './components/PageTemplates';
|
|
9
10
|
export { default as QuickCreate } from './components/QuickCreate';
|
|
10
11
|
export * from './components/QuickCreate';
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,cAAc,qBAAqB,CAAC;AACpC,cAAc,4BAA4B,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,0BAA0B,CAAC","sourcesContent":["// This file is autogenerated. Any changes will be overwritten.\nexport { default as AppShell } from './components/AppShell';\nexport * from './components/AppShell';\nexport { default as CaseView } from './components/CaseView';\nexport * from './components/CaseView';\nexport { default as Footer } from './components/Footer';\nexport * from './components/Footer';\nexport * from './components/PageTemplates';\nexport { default as QuickCreate } from './components/QuickCreate';\nexport * from './components/QuickCreate';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,cAAc,uBAAuB,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,qBAAqB,CAAC;AACxD,cAAc,qBAAqB,CAAC;AACpC,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,6BAA6B,CAAC;AACxE,cAAc,4BAA4B,CAAC;AAC3C,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,0BAA0B,CAAC;AAClE,cAAc,0BAA0B,CAAC","sourcesContent":["// This file is autogenerated. Any changes will be overwritten.\nexport { default as AppShell } from './components/AppShell';\nexport * from './components/AppShell';\nexport { default as CaseView } from './components/CaseView';\nexport * from './components/CaseView';\nexport { default as Footer } from './components/Footer';\nexport * from './components/Footer';\nexport { default as ModernCaseView } from './components/ModernCaseView';\nexport * from './components/PageTemplates';\nexport { default as QuickCreate } from './components/QuickCreate';\nexport * from './components/QuickCreate';\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pega/cosmos-react-wss",
|
|
3
|
-
"version": "10.0.0-build.9.
|
|
3
|
+
"version": "10.0.0-build.9.9",
|
|
4
4
|
"license": "SEE LICENSE IN LICENSE",
|
|
5
5
|
"author": "Pegasystems",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
"build": "tsc -b tsconfig.build.json"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@pega/cosmos-react-core": "10.0.0-build.9.
|
|
18
|
-
"@pega/cosmos-react-work": "10.0.0-build.9.
|
|
17
|
+
"@pega/cosmos-react-core": "10.0.0-build.9.9",
|
|
18
|
+
"@pega/cosmos-react-work": "10.0.0-build.9.9",
|
|
19
19
|
"@types/react": "^17.0.62 || ^18.3.3",
|
|
20
20
|
"@types/react-dom": "^17.0.20 || ^18.3.0",
|
|
21
21
|
"polished": "^4.1.0",
|