@pega/cosmos-react-work 10.0.0-build.1.8 → 10.0.0-build.10.0

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.
Files changed (232) hide show
  1. package/lib/components/AppAnnouncement/AppAnnouncement.d.ts +8 -4
  2. package/lib/components/AppAnnouncement/AppAnnouncement.d.ts.map +1 -1
  3. package/lib/components/AppAnnouncement/AppAnnouncement.js +38 -11
  4. package/lib/components/AppAnnouncement/AppAnnouncement.js.map +1 -1
  5. package/lib/components/AppAnnouncement/AppAnnouncement.test-ids.d.ts +2 -0
  6. package/lib/components/AppAnnouncement/AppAnnouncement.test-ids.d.ts.map +1 -0
  7. package/lib/components/AppAnnouncement/AppAnnouncement.test-ids.js +8 -0
  8. package/lib/components/AppAnnouncement/AppAnnouncement.test-ids.js.map +1 -0
  9. package/lib/components/Article/ArticleRating.d.ts.map +1 -1
  10. package/lib/components/Article/ArticleRating.js +2 -2
  11. package/lib/components/Article/ArticleRating.js.map +1 -1
  12. package/lib/components/ArticleList/ArticleFeedback.d.ts.map +1 -1
  13. package/lib/components/ArticleList/ArticleFeedback.js +2 -2
  14. package/lib/components/ArticleList/ArticleFeedback.js.map +1 -1
  15. package/lib/components/CasePreview/CasePreview.d.ts +2 -0
  16. package/lib/components/CasePreview/CasePreview.d.ts.map +1 -1
  17. package/lib/components/CasePreview/CasePreview.js +33 -13
  18. package/lib/components/CasePreview/CasePreview.js.map +1 -1
  19. package/lib/components/CaseView/CaseHeader/CaseHeader.d.ts.map +1 -1
  20. package/lib/components/CaseView/CaseHeader/CaseHeader.js +5 -3
  21. package/lib/components/CaseView/CaseHeader/CaseHeader.js.map +1 -1
  22. package/lib/components/CaseView/CaseSummary.d.ts +3 -2
  23. package/lib/components/CaseView/CaseSummary.d.ts.map +1 -1
  24. package/lib/components/CaseView/CaseSummary.js +2 -2
  25. package/lib/components/CaseView/CaseSummary.js.map +1 -1
  26. package/lib/components/CaseView/CaseView.d.ts.map +1 -1
  27. package/lib/components/CaseView/CaseView.js +6 -12
  28. package/lib/components/CaseView/CaseView.js.map +1 -1
  29. package/lib/components/CaseView/CaseView.styles.d.ts +2 -2
  30. package/lib/components/CaseView/CaseView.styles.d.ts.map +1 -1
  31. package/lib/components/CaseView/CaseView.styles.js +193 -153
  32. package/lib/components/CaseView/CaseView.styles.js.map +1 -1
  33. package/lib/components/CaseView/CaseView.types.d.ts +6 -2
  34. package/lib/components/CaseView/CaseView.types.d.ts.map +1 -1
  35. package/lib/components/CaseView/CaseView.types.js.map +1 -1
  36. package/lib/components/CaseView/UtilitiesSummary.js +1 -4
  37. package/lib/components/CaseView/UtilitiesSummary.js.map +1 -1
  38. package/lib/components/CaseView/UtilitySummaryItemDialog.d.ts.map +1 -1
  39. package/lib/components/CaseView/UtilitySummaryItemDialog.js +7 -4
  40. package/lib/components/CaseView/UtilitySummaryItemDialog.js.map +1 -1
  41. package/lib/components/Details/Details.d.ts.map +1 -1
  42. package/lib/components/Details/Details.js +9 -6
  43. package/lib/components/Details/Details.js.map +1 -1
  44. package/lib/components/Details/Details.styles.d.ts.map +1 -1
  45. package/lib/components/Details/Details.styles.js +10 -7
  46. package/lib/components/Details/Details.styles.js.map +1 -1
  47. package/lib/components/Details/DetailsList.d.ts.map +1 -1
  48. package/lib/components/Details/DetailsList.js +2 -2
  49. package/lib/components/Details/DetailsList.js.map +1 -1
  50. package/lib/components/GenAICoach/ActiveCases.d.ts.map +1 -1
  51. package/lib/components/GenAICoach/ActiveCases.js +2 -1
  52. package/lib/components/GenAICoach/ActiveCases.js.map +1 -1
  53. package/lib/components/GenAICoach/GenAICoach.d.ts +1 -1
  54. package/lib/components/GenAICoach/GenAICoach.d.ts.map +1 -1
  55. package/lib/components/GenAICoach/GenAICoach.js +267 -73
  56. package/lib/components/GenAICoach/GenAICoach.js.map +1 -1
  57. package/lib/components/GenAICoach/GenAICoach.styles.d.ts +232 -9
  58. package/lib/components/GenAICoach/GenAICoach.styles.d.ts.map +1 -1
  59. package/lib/components/GenAICoach/GenAICoach.styles.js +374 -192
  60. package/lib/components/GenAICoach/GenAICoach.styles.js.map +1 -1
  61. package/lib/components/GenAICoach/GenAICoach.test-ids.d.ts +1 -1
  62. package/lib/components/GenAICoach/GenAICoach.test-ids.d.ts.map +1 -1
  63. package/lib/components/GenAICoach/GenAICoach.test-ids.js +3 -1
  64. package/lib/components/GenAICoach/GenAICoach.test-ids.js.map +1 -1
  65. package/lib/components/GenAICoach/GenAICoach.types.d.ts +36 -3
  66. package/lib/components/GenAICoach/GenAICoach.types.d.ts.map +1 -1
  67. package/lib/components/GenAICoach/GenAICoach.types.js.map +1 -1
  68. package/lib/components/GenAICoach/GenAIMessage.d.ts.map +1 -1
  69. package/lib/components/GenAICoach/GenAIMessage.js +44 -21
  70. package/lib/components/GenAICoach/GenAIMessage.js.map +1 -1
  71. package/lib/components/GenAICoach/GenAIMessageFeedback.d.ts.map +1 -1
  72. package/lib/components/GenAICoach/GenAIMessageFeedback.js +10 -3
  73. package/lib/components/GenAICoach/GenAIMessageFeedback.js.map +1 -1
  74. package/lib/components/GenAICoach/Questionnaire.d.ts.map +1 -1
  75. package/lib/components/GenAICoach/Questionnaire.js +10 -3
  76. package/lib/components/GenAICoach/Questionnaire.js.map +1 -1
  77. package/lib/components/GenAICoach/index.d.ts +1 -1
  78. package/lib/components/GenAICoach/index.d.ts.map +1 -1
  79. package/lib/components/GenAICoach/index.js.map +1 -1
  80. package/lib/components/HeroBanner/HeroBanner.d.ts +7 -0
  81. package/lib/components/HeroBanner/HeroBanner.d.ts.map +1 -0
  82. package/lib/components/HeroBanner/HeroBanner.js +63 -0
  83. package/lib/components/HeroBanner/HeroBanner.js.map +1 -0
  84. package/lib/components/HeroBanner/HeroBanner.styles.d.ts +35 -0
  85. package/lib/components/HeroBanner/HeroBanner.styles.d.ts.map +1 -0
  86. package/lib/components/HeroBanner/HeroBanner.styles.js +118 -0
  87. package/lib/components/HeroBanner/HeroBanner.styles.js.map +1 -0
  88. package/lib/components/HeroBanner/HeroBanner.test-ids.d.ts +2 -0
  89. package/lib/components/HeroBanner/HeroBanner.test-ids.d.ts.map +1 -0
  90. package/lib/components/HeroBanner/HeroBanner.test-ids.js +11 -0
  91. package/lib/components/HeroBanner/HeroBanner.test-ids.js.map +1 -0
  92. package/lib/components/HeroBanner/HeroBanner.types.d.ts +51 -0
  93. package/lib/components/HeroBanner/HeroBanner.types.d.ts.map +1 -0
  94. package/lib/components/HeroBanner/HeroBanner.types.js +2 -0
  95. package/lib/components/HeroBanner/HeroBanner.types.js.map +1 -0
  96. package/lib/components/HeroBanner/index.d.ts +3 -0
  97. package/lib/components/HeroBanner/index.d.ts.map +1 -0
  98. package/lib/components/HeroBanner/index.js +2 -0
  99. package/lib/components/HeroBanner/index.js.map +1 -0
  100. package/lib/components/HeroBanner/utils.d.ts +20 -0
  101. package/lib/components/HeroBanner/utils.d.ts.map +1 -0
  102. package/lib/components/HeroBanner/utils.js +125 -0
  103. package/lib/components/HeroBanner/utils.js.map +1 -0
  104. package/lib/components/HierarchicalAssignments/Assignments.styles.d.ts.map +1 -1
  105. package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.d.ts +5 -1
  106. package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.d.ts.map +1 -1
  107. package/lib/components/HierarchicalAssignments/HierarchicalAssignments.types.js.map +1 -1
  108. package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.d.ts +5 -1
  109. package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.d.ts.map +1 -1
  110. package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.js +25 -15
  111. package/lib/components/HierarchicalAssignments/nodeItems/AssignmentItem.js.map +1 -1
  112. package/lib/components/IntelligentGuidance/IntelligentGuidance.d.ts.map +1 -1
  113. package/lib/components/IntelligentGuidance/IntelligentGuidance.js +6 -5
  114. package/lib/components/IntelligentGuidance/IntelligentGuidance.js.map +1 -1
  115. package/lib/components/IntelligentGuidance/IntelligentGuidance.styles.d.ts.map +1 -1
  116. package/lib/components/IntelligentGuidance/IntelligentGuidance.styles.js +27 -9
  117. package/lib/components/IntelligentGuidance/IntelligentGuidance.styles.js.map +1 -1
  118. package/lib/components/IntelligentGuidance/IntelligentGuidance.types.d.ts +8 -0
  119. package/lib/components/IntelligentGuidance/IntelligentGuidance.types.d.ts.map +1 -1
  120. package/lib/components/IntelligentGuidance/IntelligentGuidance.types.js.map +1 -1
  121. package/lib/components/InteractionNotification/InteractionNotification.d.ts +2 -2
  122. package/lib/components/InteractionNotification/InteractionNotification.d.ts.map +1 -1
  123. package/lib/components/InteractionNotification/InteractionNotification.js +6 -4
  124. package/lib/components/InteractionNotification/InteractionNotification.js.map +1 -1
  125. package/lib/components/MasterDetail/DetailPanelHeader.d.ts +29 -0
  126. package/lib/components/MasterDetail/DetailPanelHeader.d.ts.map +1 -0
  127. package/lib/components/MasterDetail/DetailPanelHeader.js +14 -0
  128. package/lib/components/MasterDetail/DetailPanelHeader.js.map +1 -0
  129. package/lib/components/MasterDetail/MasterDetail.d.ts +6 -0
  130. package/lib/components/MasterDetail/MasterDetail.d.ts.map +1 -0
  131. package/lib/components/MasterDetail/MasterDetail.js +116 -0
  132. package/lib/components/MasterDetail/MasterDetail.js.map +1 -0
  133. package/lib/components/MasterDetail/MasterDetail.styles.d.ts +595 -0
  134. package/lib/components/MasterDetail/MasterDetail.styles.d.ts.map +1 -0
  135. package/lib/components/MasterDetail/MasterDetail.styles.js +246 -0
  136. package/lib/components/MasterDetail/MasterDetail.styles.js.map +1 -0
  137. package/lib/components/MasterDetail/MasterDetail.test-ids.d.ts +2 -0
  138. package/lib/components/MasterDetail/MasterDetail.test-ids.d.ts.map +1 -0
  139. package/lib/components/MasterDetail/MasterDetail.test-ids.js +19 -0
  140. package/lib/components/MasterDetail/MasterDetail.test-ids.js.map +1 -0
  141. package/lib/components/MasterDetail/MasterDetail.types.d.ts +71 -0
  142. package/lib/components/MasterDetail/MasterDetail.types.d.ts.map +1 -0
  143. package/lib/components/MasterDetail/MasterDetail.types.js +2 -0
  144. package/lib/components/MasterDetail/MasterDetail.types.js.map +1 -0
  145. package/lib/components/MasterDetail/MasterDetailActions.d.ts +10 -0
  146. package/lib/components/MasterDetail/MasterDetailActions.d.ts.map +1 -0
  147. package/lib/components/MasterDetail/MasterDetailActions.js +45 -0
  148. package/lib/components/MasterDetail/MasterDetailActions.js.map +1 -0
  149. package/lib/components/MasterDetail/index.d.ts +5 -0
  150. package/lib/components/MasterDetail/index.d.ts.map +1 -0
  151. package/lib/components/MasterDetail/index.js +4 -0
  152. package/lib/components/MasterDetail/index.js.map +1 -0
  153. package/lib/components/SearchResults/SearchResults.d.ts.map +1 -1
  154. package/lib/components/SearchResults/SearchResults.js +11 -7
  155. package/lib/components/SearchResults/SearchResults.js.map +1 -1
  156. package/lib/components/SearchResults/SearchResults.styles.js +3 -3
  157. package/lib/components/SearchResults/SearchResults.styles.js.map +1 -1
  158. package/lib/components/Shortcuts/Shortcuts.d.ts +1 -1
  159. package/lib/components/Shortcuts/Shortcuts.d.ts.map +1 -1
  160. package/lib/components/Shortcuts/Shortcuts.js +40 -18
  161. package/lib/components/Shortcuts/Shortcuts.js.map +1 -1
  162. package/lib/components/Shortcuts/Shortcuts.styles.d.ts +17 -6
  163. package/lib/components/Shortcuts/Shortcuts.styles.d.ts.map +1 -1
  164. package/lib/components/Shortcuts/Shortcuts.styles.js +104 -58
  165. package/lib/components/Shortcuts/Shortcuts.styles.js.map +1 -1
  166. package/lib/components/Shortcuts/Shortcuts.test-ids.d.ts +1 -1
  167. package/lib/components/Shortcuts/Shortcuts.test-ids.d.ts.map +1 -1
  168. package/lib/components/Shortcuts/Shortcuts.test-ids.js +4 -3
  169. package/lib/components/Shortcuts/Shortcuts.test-ids.js.map +1 -1
  170. package/lib/components/Shortcuts/Shortcuts.types.d.ts +18 -2
  171. package/lib/components/Shortcuts/Shortcuts.types.d.ts.map +1 -1
  172. package/lib/components/Shortcuts/Shortcuts.types.js.map +1 -1
  173. package/lib/components/Stages/Stages.d.ts +4 -2
  174. package/lib/components/Stages/Stages.d.ts.map +1 -1
  175. package/lib/components/Stages/Stages.js +123 -88
  176. package/lib/components/Stages/Stages.js.map +1 -1
  177. package/lib/components/Stages/Stages.styles.d.ts +88 -3
  178. package/lib/components/Stages/Stages.styles.d.ts.map +1 -1
  179. package/lib/components/Stages/Stages.styles.js +873 -171
  180. package/lib/components/Stages/Stages.styles.js.map +1 -1
  181. package/lib/components/Stages/Stages.test-ids.d.ts +2 -0
  182. package/lib/components/Stages/Stages.test-ids.d.ts.map +1 -0
  183. package/lib/components/Stages/Stages.test-ids.js +7 -0
  184. package/lib/components/Stages/Stages.test-ids.js.map +1 -0
  185. package/lib/components/Stages/Stages.types.d.ts +9 -3
  186. package/lib/components/Stages/Stages.types.d.ts.map +1 -1
  187. package/lib/components/Stages/Stages.types.js.map +1 -1
  188. package/lib/components/Stages/index.d.ts +2 -1
  189. package/lib/components/Stages/index.d.ts.map +1 -1
  190. package/lib/components/Stages/index.js +1 -0
  191. package/lib/components/Stages/index.js.map +1 -1
  192. package/lib/components/Stages/useStagesScrollbar.d.ts +21 -0
  193. package/lib/components/Stages/useStagesScrollbar.d.ts.map +1 -0
  194. package/lib/components/Stages/useStagesScrollbar.js +152 -0
  195. package/lib/components/Stages/useStagesScrollbar.js.map +1 -0
  196. package/lib/components/Stakeholders/Stakeholders.d.ts.map +1 -1
  197. package/lib/components/Stakeholders/Stakeholders.js +13 -11
  198. package/lib/components/Stakeholders/Stakeholders.js.map +1 -1
  199. package/lib/components/Stakeholders/Stakeholders.types.d.ts +1 -1
  200. package/lib/components/Stakeholders/Stakeholders.types.d.ts.map +1 -1
  201. package/lib/components/Stakeholders/Stakeholders.types.js.map +1 -1
  202. package/lib/components/Tags/Tags.d.ts.map +1 -1
  203. package/lib/components/Tags/Tags.js +2 -13
  204. package/lib/components/Tags/Tags.js.map +1 -1
  205. package/lib/components/Tasks/TaskCard.d.ts +8 -0
  206. package/lib/components/Tasks/TaskCard.d.ts.map +1 -0
  207. package/lib/components/Tasks/TaskCard.js +42 -0
  208. package/lib/components/Tasks/TaskCard.js.map +1 -0
  209. package/lib/components/Tasks/TaskCards.d.ts +9 -0
  210. package/lib/components/Tasks/TaskCards.d.ts.map +1 -0
  211. package/lib/components/Tasks/TaskCards.js +40 -0
  212. package/lib/components/Tasks/TaskCards.js.map +1 -0
  213. package/lib/components/Tasks/TaskList.d.ts +13 -1
  214. package/lib/components/Tasks/TaskList.d.ts.map +1 -1
  215. package/lib/components/Tasks/TaskList.js +31 -19
  216. package/lib/components/Tasks/TaskList.js.map +1 -1
  217. package/lib/components/Tasks/Tasks.d.ts +46 -6
  218. package/lib/components/Tasks/Tasks.d.ts.map +1 -1
  219. package/lib/components/Tasks/Tasks.js +11 -5
  220. package/lib/components/Tasks/Tasks.js.map +1 -1
  221. package/lib/components/Tasks/Tasks.test-ids.d.ts +1 -1
  222. package/lib/components/Tasks/Tasks.test-ids.d.ts.map +1 -1
  223. package/lib/components/Tasks/Tasks.test-ids.js +1 -1
  224. package/lib/components/Tasks/Tasks.test-ids.js.map +1 -1
  225. package/lib/components/Tasks/index.d.ts +1 -1
  226. package/lib/components/Tasks/index.d.ts.map +1 -1
  227. package/lib/components/Tasks/index.js.map +1 -1
  228. package/lib/index.d.ts +4 -0
  229. package/lib/index.d.ts.map +1 -1
  230. package/lib/index.js +4 -0
  231. package/lib/index.js.map +1 -1
  232. package/package.json +5 -6
@@ -1,7 +1,7 @@
1
- import styled, { createGlobalStyle, css } from 'styled-components';
1
+ import styled, { createGlobalStyle, css, keyframes } from 'styled-components';
2
2
  import { useContext } from 'react';
3
- import { mix, darken, meetsContrastGuidelines, transparentize } from 'polished';
4
- import { AppShellContext, Button, FileList, Flex, FormControl, Icon, Image, MenuButton, InfoDialog, StyledEmptyState, StyledErrorState, StyledIcon, StyledText, SummaryItem, Text, TextArea, calculateFontSize, calculateForegroundColor, defaultThemeProp, isSolidColor, tryCatch, Avatar, Fullscreen, animations, Modal, StyledIconShape } from '@pega/cosmos-react-core';
3
+ import { mix, darken, transparentize } from 'polished';
4
+ import { AppShellContext, Button, FileList, Flex, FormControl, Icon, Image, MenuButton, InfoDialog, StyledEmptyState, StyledErrorState, StyledIcon, StyledText, SummaryItem, Text, TextArea, calculateFontSize, calculateForegroundColor, defaultThemeProp, isSolidColor, meetsMinContrast, tryCatch, Avatar, Fullscreen, animations, Modal, StyledIconShape } from '@pega/cosmos-react-core';
5
5
  import { StyledCard } from '@pega/cosmos-react-core/lib/components/Card/Card';
6
6
  import { StyledCardHeader } from '@pega/cosmos-react-core/lib/components/Card/CardHeader';
7
7
  import { StyledCardFooter } from '@pega/cosmos-react-core/lib/components/Card/CardFooter';
@@ -15,10 +15,10 @@ import { resizeDrawerMaxWidth, portalAgentMinWidth, portalAgentDefaultWidth } fr
15
15
  import { lineClamp } from '@pega/cosmos-react-core/lib/styles/mixins';
16
16
  import { RichTextViewer } from '@pega/cosmos-react-rte';
17
17
  import { StepMarker, StyledStepText } from '@pega/cosmos-react-core/lib/components/MultiStepForm/FormProgress.styles';
18
- import { StyledResizeHandle } from '@pega/cosmos-react-core/lib/components/Drawer/ResizeHandle';
18
+ import { StyledFileList } from '@pega/cosmos-react-core/lib/components/File/FileList';
19
+ import { StyledTouchDialog } from '@pega/cosmos-react-core/lib/components/Dialog/TouchDialog.styles';
19
20
  import { StyledStages } from '../Stages/Stages.styles';
20
21
  import { isInUtilities } from './GenAICoach.utils';
21
- const maxWidthMessage = '62.5rem';
22
22
  export const StyledComposerSection = styled.div ``;
23
23
  export const StyledGenAIFormControl = styled(FormControl)(({ theme, focused }) => {
24
24
  return css `
@@ -38,34 +38,59 @@ export const StyledGenAIFormControl = styled(FormControl)(({ theme, focused }) =
38
38
  `;
39
39
  });
40
40
  StyledGenAIFormControl.defaultProps = defaultThemeProp;
41
- export const StyledComposerWrapper = styled.div(({ theme, focused, hasQuestionnaire }) => {
41
+ export const StyledComposerWrapper = styled.div(({ theme, focused, hasQuestionnaire, $agentInBanner }) => {
42
42
  const { 'border-radius': formControlBorderRadius, 'border-width': formControlBorderWidth } = theme.components['form-control'];
43
43
  const { 'border-radius': baseBorderRadius, palette } = theme.base;
44
44
  const borderRadius = `calc(${formControlBorderRadius} * ${baseBorderRadius})`;
45
45
  const borderWidth = formControlBorderWidth ?? '0.0625rem';
46
46
  return css `
47
- ${hasQuestionnaire &&
47
+ ${$agentInBanner &&
48
48
  css `
49
- border: ${borderWidth} solid ${palette['border-line']};
50
- border-radius: ${borderRadius};
51
- overflow: hidden;
49
+ > ${StyledFormField} {
50
+ position: relative;
51
+ z-index: 1;
52
+ }
53
+ `}
52
54
 
53
- ${focused &&
54
- css `
55
- border-color: ${theme.components['form-control'][':focus']['border-color']};
56
- box-shadow: ${theme.components['form-control'][':focus']['box-shadow']};
57
- `}
55
+ ${hasQuestionnaire &&
56
+ css `
57
+ border: ${borderWidth} solid ${palette['border-line']};
58
+ border-radius: ${borderRadius};
59
+ overflow: hidden;
58
60
 
59
- ${StyledGenAIFormControl} {
60
- border: none;
61
- border-radius: 0;
62
- box-shadow: none;
63
- overflow: visible;
64
- }
61
+ ${focused &&
62
+ css `
63
+ border-color: ${theme.components['form-control'][':focus']['border-color']};
64
+ box-shadow: ${theme.components['form-control'][':focus']['box-shadow']};
65
65
  `}
66
- `;
66
+
67
+ ${StyledGenAIFormControl} {
68
+ border: none;
69
+ border-radius: 0;
70
+ box-shadow: none;
71
+ overflow: visible;
72
+ }
73
+ `}
74
+ `;
67
75
  });
68
76
  StyledComposerWrapper.defaultProps = defaultThemeProp;
77
+ export const StyledConversationHistoryButton = styled.div(({ theme }) => css `
78
+ position: relative;
79
+ padding-inline-end: ${theme.base.spacing};
80
+ margin-inline-end: ${theme.base.spacing};
81
+
82
+ &::after {
83
+ content: '';
84
+ position: absolute;
85
+ inset-block-start: 50%;
86
+ inset-inline-end: 0;
87
+ width: 0.0625rem;
88
+ height: 1.5rem;
89
+ background: ${theme.base.palette['border-line']};
90
+ transform: translateY(-50%);
91
+ }
92
+ `);
93
+ StyledConversationHistoryButton.defaultProps = defaultThemeProp;
69
94
  export const StyledMessagesContainer = styled.div(({ theme: { base: { spacing } }, withSuggestionCards }) => {
70
95
  return css `
71
96
  margin-block-end: calc(0.5 * ${spacing});
@@ -84,46 +109,62 @@ StyledMessagesContainer.defaultProps = defaultThemeProp;
84
109
  export const StyledFullscreenWrapper = styled(Fullscreen) `
85
110
  height: 100%;
86
111
  `;
87
- export const StyledGenAICoachContainer = styled.div(({ theme: { base: { palette, 'z-index': zIndex, spacing, breakpoints, animation, 'border-radius': baseBorderRadius }, components: { card: { 'border-radius': cardBorderRadius }, agent: { background: agentBackground, 'foreground-color': agentForegroundColor }, 'form-control': { 'border-radius': formControlBorderRadius } } }, variant, fullScreen, isCompact, isPortalAgent }) => {
112
+ export const StyledHeaderContainer = styled(Flex)(({ theme }) => {
113
+ return css `
114
+ border-block-end: 0.0625rem solid
115
+ ${transparentize(0.88, theme.components.agent['foreground-color'])};
116
+ `;
117
+ });
118
+ StyledHeaderContainer.defaultProps = defaultThemeProp;
119
+ export const StyledGenAICoachContainer = styled.div(({ theme, variant, fullScreen, isCompact, isPortalAgent, simplifiedAgent }) => {
120
+ const { base: { palette, 'z-index': zIndex, spacing, breakpoints, animation, 'border-radius': baseBorderRadius }, components: { card: { 'border-radius': cardBorderRadius }, agent: { background: agentBackground, 'foreground-color': agentForegroundColor }, 'form-control': { 'border-radius': formControlBorderRadius } } } = theme;
88
121
  const { previewActive } = useContext(AppShellContext);
89
- const foregroundColorForAgent = calculateForegroundColor(agentBackground, agentForegroundColor);
122
+ const foregroundColorForAgent = calculateForegroundColor(agentBackground, agentForegroundColor, theme);
90
123
  return css `
91
- background: ${agentBackground};
92
- color: ${foregroundColorForAgent};
93
- min-width: var(--utilities-drawer-min-width);
94
- border-radius: ${cardBorderRadius};
95
- transition: height ${animation.speed} ${animation.timing.ease};
124
+ background: ${agentBackground};
125
+ color: ${foregroundColorForAgent};
126
+ min-width: var(--utilities-drawer-min-width);
127
+ border-radius: ${cardBorderRadius};
128
+ transition: height ${animation.speed} ${animation.timing.ease};
129
+ ${simplifiedAgent
130
+ ? css `
131
+ --message-container-width: 40rem;
132
+ --messages-list-margin-start: 0;
133
+ `
134
+ : css `
135
+ --message-container-width: 62.5rem;
136
+ `}
96
137
 
97
- ${variant.placement === 'dialog' &&
138
+ ${variant.placement === 'dialog' &&
98
139
  css `
99
- border-radius: calc(${formControlBorderRadius} * ${baseBorderRadius});
100
- `}
140
+ border-radius: calc(${formControlBorderRadius} * ${baseBorderRadius});
141
+ `}
101
142
 
102
143
  ${isInUtilities(variant) &&
103
144
  !fullScreen &&
104
145
  css `
105
- min-height: 3rem;
106
- max-width: 31.25rem;
107
- box-shadow: 0 -1rem 1rem ${palette['app-background']};
108
- border-radius: ${cardBorderRadius} ${cardBorderRadius} 0 0;
109
- position: fixed;
110
- inset-block-end: var(--appshell-bottom-offset, 0);
111
- inset-inline-end: calc(2 * ${spacing});
112
- z-index: calc(${zIndex.drawer} + 1);
113
- width: 25rem;
114
-
115
- ${previewActive &&
146
+ min-height: 3rem;
147
+ max-width: 31.25rem;
148
+ box-shadow: 0 -1rem 1rem ${palette['app-background']};
149
+ border-radius: ${cardBorderRadius} ${cardBorderRadius} 0 0;
150
+ position: fixed;
151
+ inset-block-end: var(--appshell-bottom-offset, 0);
152
+ inset-inline-end: calc(2 * ${spacing});
153
+ z-index: calc(${zIndex.drawer} + 1);
154
+ width: 25rem;
155
+
156
+ ${previewActive &&
116
157
  css `
117
- @media (min-width: ${breakpoints.md}) {
118
- margin-inline-end: min(var(--resize-drawer-width), ${resizeDrawerMaxWidth});
119
- }
120
- `}
158
+ @media (min-width: ${breakpoints.md}) {
159
+ margin-inline-end: min(var(--resize-drawer-width), ${resizeDrawerMaxWidth});
160
+ }
161
+ `}
121
162
 
122
- ${variant.state === 'minimized' &&
163
+ ${variant.state === 'minimized' &&
123
164
  css `
124
- height: 3rem;
125
- `}
165
+ height: 3rem;
126
166
  `}
167
+ `}
127
168
 
128
169
  /*
129
170
  ~85% of Utilities height and fixed height if screen size less than md and devices with coarse pointer
@@ -132,42 +173,62 @@ export const StyledGenAICoachContainer = styled.div(({ theme: { base: { palette,
132
173
  ${((isInUtilities(variant) && variant.state === 'maximized') || !isInUtilities(variant)) &&
133
174
  !fullScreen &&
134
175
  css `
135
- height: calc(0.85 * var(--case-view-height, 95vh));
136
- @media (pointer: coarse) and (max-width: ${breakpoints.md}) {
137
- height: 40rem;
138
- }
139
- `}
176
+ height: calc(0.85 * var(--case-view-height, 95vh));
177
+ @media (pointer: coarse) and (max-width: ${breakpoints.md}) {
178
+ height: 40rem;
179
+ }
180
+ `}
140
181
 
141
182
  ${variant.placement === 'fullpage' &&
142
183
  css `
143
- height: var(--content-height-in-view, 100vh);
144
- `}
184
+ ${simplifiedAgent
185
+ ? css `
186
+ transition: height 0.6s cubic-bezier(0.4, 0, 0.6, 1);
187
+ height: var(--content-height-in-agent, var(--content-height-in-view, 100vh));
188
+ `
189
+ : css `
190
+ height: var(--content-height-in-view, 100vh);
191
+ `}
192
+ `}
145
193
 
146
194
  ${isCompact &&
147
195
  css `
148
- height: 100%;
149
- max-height: var(--content-height-in-view, 100vh);
196
+ height: ${simplifiedAgent ? 'auto' : '100%'};
197
+ max-height: ${simplifiedAgent
198
+ ? 'var(--content-height-in-agent, var(--content-height-in-view, 100vh))'
199
+ : 'var(--content-height-in-view, 100vh)'};
150
200
 
151
- ${StyledMessagesContainer} {
152
- margin-block-end: 0;
153
- }
154
- `}
201
+ ${StyledMessagesContainer} {
202
+ margin-block-end: 0;
203
+ }
204
+ `}
155
205
 
156
206
  ${fullScreen &&
157
207
  css `
158
- height: 100vh;
159
- border-radius: 0;
160
- `}
208
+ height: 100vh;
209
+ border-radius: 0;
210
+ `}
161
211
 
162
212
  ${isPortalAgent &&
163
213
  css `
164
- height: calc(100vh - var(--appshell-offset, 0vh));
165
- border-radius: 0;
166
- `}
167
- `;
214
+ height: 100%;
215
+ min-height: 0;
216
+ border-radius: 0;
217
+ `}
218
+
219
+ ${StyledErrorState} {
220
+ ${StyledText} {
221
+ color: ${agentForegroundColor};
222
+ }
223
+ }
224
+
225
+ ${StyledFileList} {
226
+ color: ${palette['foreground-color']};
227
+ }
228
+ `;
168
229
  });
169
230
  StyledGenAICoachContainer.defaultProps = defaultThemeProp;
170
- export const StyledGenAIOptionsMenu = styled(MenuButton)(({ theme: { base: { 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight, palette: { ai } } } }) => {
231
+ export const StyledGenAIOptionsMenu = styled(MenuButton)(({ theme: { base: { 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight }, components: { agent: { ai } } } }) => {
171
232
  const { l } = calculateFontSize(fontSize, fontScale);
172
233
  return css `
173
234
  color: inherit;
@@ -188,9 +249,32 @@ export const StyledMenuSuggestions = styled(MenuButton)(({ theme: { base: { 'bor
188
249
  `;
189
250
  });
190
251
  StyledMenuSuggestions.defaultProps = defaultThemeProp;
191
- export const StyledDisclaimerText = styled(Text)(({ inFullPage, theme: { base: { 'font-size': fontSize, 'font-scale': fontScale, spacing } } }) => {
252
+ /**
253
+ * Compact MenuButton used in the composer toolbar for agent mode and model selection.
254
+ * Appears only when the corresponding config prop is provided.
255
+ */
256
+ export const StyledComposerSelector = styled(MenuButton)(({ theme: { base: { spacing } } }) => {
257
+ return css `
258
+ color: inherit;
259
+ padding-inline: calc(0.5 * ${spacing});
260
+ margin-inline-start: ${spacing};
261
+ flex-shrink: 1;
262
+ min-width: 7ch;
263
+ max-width: 30ch;
264
+ `;
265
+ });
266
+ StyledComposerSelector.defaultProps = defaultThemeProp;
267
+ export const StyledDisclaimerText = styled(Text)(({ inFullPage, theme: { base: { 'font-size': fontSize, 'font-scale': fontScale, spacing, animation } } }) => {
192
268
  const systemFontSize = calculateFontSize(fontSize, fontScale).xs;
193
269
  return css `
270
+ @keyframes disclaimer-fade-in {
271
+ from {
272
+ opacity: 0;
273
+ }
274
+ to {
275
+ opacity: 0.7;
276
+ }
277
+ }
194
278
  font-size: ${systemFontSize};
195
279
  margin-block-start: ${spacing};
196
280
  ${inFullPage &&
@@ -198,14 +282,24 @@ export const StyledDisclaimerText = styled(Text)(({ inFullPage, theme: { base: {
198
282
  padding-block-end: calc(2 * ${spacing});
199
283
  `}
200
284
  opacity: 0.7;
285
+ animation: disclaimer-fade-in ${animation.speed} ${animation.timing.ease} both;
286
+ @media (prefers-reduced-motion: reduce) {
287
+ animation-duration: 1ms;
288
+ }
201
289
  `;
202
290
  });
203
291
  StyledDisclaimerText.defaultProps = defaultThemeProp;
204
- export const StyledFlexWrapper = styled.div `
205
- height: 100%;
206
- overflow-y: auto;
207
- position: relative;
208
- `;
292
+ export const StyledFlexWrapper = styled.div(({ isExpanded }) => css `
293
+ height: ${isExpanded ? 'auto' : '100%'};
294
+ overflow-y: auto;
295
+ position: relative;
296
+
297
+ ${isExpanded &&
298
+ css `
299
+ flex: 1 1 0;
300
+ min-height: 0;
301
+ `}
302
+ `);
209
303
  StyledFlexWrapper.defaultProps = defaultThemeProp;
210
304
  export const StyledGridContainer = styled.div(({ theme: { base }, conversationHistory }) => {
211
305
  return css `
@@ -223,11 +317,23 @@ export const StyledInitialMessageContainer = styled.div(() => {
223
317
  return css `
224
318
  ${StyledFormField} {
225
319
  width: 100%;
226
- max-width: ${maxWidthMessage};
320
+ max-width: var(--message-container-width);
227
321
  }
228
322
  `;
229
323
  });
230
324
  StyledInitialMessageContainer.defaultProps = defaultThemeProp;
325
+ export const StyledBannerSalutationBlock = styled.div(({ isExpanded }) => css `
326
+ transition:
327
+ opacity 0.45s ease,
328
+ transform 0.45s ease;
329
+ ${isExpanded &&
330
+ css `
331
+ opacity: 0;
332
+ transform: translateY(-1.5rem);
333
+ pointer-events: none;
334
+ `}
335
+ `);
336
+ StyledBannerSalutationBlock.defaultProps = defaultThemeProp;
231
337
  export const StyledInputContainer = styled(Flex)(({ theme: { base: { spacing } } }) => {
232
338
  return css `
233
339
  margin-block-end: ${spacing};
@@ -236,7 +342,7 @@ export const StyledInputContainer = styled(Flex)(({ theme: { base: { spacing } }
236
342
 
237
343
  ${StyledFormField}, ${StyledComposerSection} {
238
344
  width: 100%;
239
- max-width: ${maxWidthMessage};
345
+ max-width: var(--message-container-width);
240
346
  }
241
347
  `;
242
348
  });
@@ -281,16 +387,27 @@ export const StyledSuggestionsContainer = styled.div(({ theme: { base: { spacing
281
387
  `;
282
388
  });
283
389
  StyledSuggestionsContainer.defaultProps = defaultThemeProp;
284
- export const StyledMessage = styled.p(({ theme }) => {
390
+ export const StyledMessage = styled.p(({ theme, simplified }) => {
285
391
  return css `
286
392
  margin-block-start: calc(0.5 * ${theme.base.spacing});
287
393
  width: 100%;
288
394
  min-width: 0;
289
395
  overflow-wrap: break-word;
290
396
 
397
+ ${simplified &&
398
+ css `
399
+ padding-inline-start: calc(2.5rem + ${theme.base.spacing});
400
+ `}
401
+
291
402
  ${StyledEditorContainer} {
292
403
  padding: 0;
293
404
 
405
+ table {
406
+ display: block;
407
+ max-width: 100%;
408
+ overflow-x: auto;
409
+ }
410
+
294
411
  span {
295
412
  animation: ${animations.reveal} 1s forwards;
296
413
  }
@@ -298,56 +415,67 @@ export const StyledMessage = styled.p(({ theme }) => {
298
415
  `;
299
416
  });
300
417
  StyledMessage.defaultProps = defaultThemeProp;
301
- export const StyledUserMessage = styled.li(({ theme: { base: { 'border-radius': borderRadius, spacing }, components: { agent: { 'user-message': { background: userMessageBackground, 'foreground-color': userMessageForegroundColor } } } } }) => {
302
- const foregroundColorForUserMessage = calculateForegroundColor(userMessageBackground, userMessageForegroundColor);
418
+ export const StyledMessageSender = styled(Text)(({ theme: { base: { 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight } } }) => {
303
419
  return css `
304
- overflow-wrap: break-word;
305
- background: ${userMessageBackground};
306
- color: ${foregroundColorForUserMessage};
307
- margin-inline-start: calc(4 * ${spacing});
308
- margin-block-end: calc(0.5 * ${spacing});
309
- padding: calc(0.5 * ${spacing});
310
- border-start-start-radius: calc(1.25 * ${borderRadius});
311
- border-start-end-radius: calc(0.5 * ${borderRadius});
312
- border-end-start-radius: calc(1.25 * ${borderRadius});
313
- border-end-end-radius: calc(1.25 * ${borderRadius});
314
- `;
420
+ font-size: ${calculateFontSize(fontSize, fontScale).xl};
421
+ font-weight: ${fontWeight['semi-bold']};
422
+ opacity: 0.7;
423
+ `;
424
+ });
425
+ StyledMessageSender.defaultProps = defaultThemeProp;
426
+ export const StyledUserMessage = styled.li(({ theme }) => {
427
+ const { base: { 'border-radius': borderRadius, spacing }, components: { agent: { 'user-message': { background: userMessageBackground, 'foreground-color': userMessageForegroundColor } } } } = theme;
428
+ const foregroundColorForUserMessage = calculateForegroundColor(userMessageBackground, userMessageForegroundColor, theme);
429
+ return css `
430
+ overflow-wrap: break-word;
431
+ background: ${userMessageBackground};
432
+ color: ${foregroundColorForUserMessage};
433
+ margin-inline-start: calc(4 * ${spacing});
434
+ margin-block-end: calc(0.5 * ${spacing});
435
+ padding: calc(0.5 * ${spacing});
436
+ border-start-start-radius: calc(1.25 * ${borderRadius});
437
+ border-start-end-radius: calc(0.5 * ${borderRadius});
438
+ border-end-start-radius: calc(1.25 * ${borderRadius});
439
+ border-end-end-radius: calc(1.25 * ${borderRadius});
440
+ `;
315
441
  });
316
442
  StyledUserMessage.defaultProps = defaultThemeProp;
317
- export const StyledSystemMessage = styled.li(({ stopped, theme: { base: { spacing, 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight, palette } } }) => {
443
+ export const StyledSystemMessage = styled.li(({ stopped, theme }) => {
444
+ const { base: { spacing, 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight }, components: { agent: { 'foreground-color': agentForegroundColor, background: agentBackground } } } = theme;
318
445
  const systemFontSize = calculateFontSize(fontSize, fontScale).xs;
446
+ const foregroundColorForSystemMessage = calculateForegroundColor(agentBackground, agentForegroundColor, theme);
319
447
  return css `
320
- display: flex;
321
- align-items: center;
322
- gap: ${spacing};
323
- overflow-wrap: break-word;
324
- font-size: ${systemFontSize};
325
- color: ${palette['foreground-color']};
326
- opacity: 0.7;
327
- margin-block: calc(2 * ${spacing});
328
- ${stopped &&
448
+ display: flex;
449
+ align-items: center;
450
+ gap: ${spacing};
451
+ overflow-wrap: break-word;
452
+ font-size: ${systemFontSize};
453
+ color: ${foregroundColorForSystemMessage};
454
+ opacity: 0.7;
455
+ margin-block: calc(2 * ${spacing});
456
+ ${stopped &&
329
457
  css `
330
- font-weight: ${fontWeight.normal};
331
- `}
458
+ font-weight: ${fontWeight.normal};
459
+ `}
332
460
 
333
- &::before,
334
- &::after {
335
- content: '';
336
- flex: 1;
337
- border-block-start: 0.0625rem solid ${palette['foreground-color']};
338
- opacity: 0.7;
339
- }
340
- `;
461
+ &::before,
462
+ &::after {
463
+ content: '';
464
+ flex: 1;
465
+ border-block-start: 0.0625rem solid ${foregroundColorForSystemMessage};
466
+ opacity: 0.7;
467
+ }
468
+ `;
341
469
  });
342
470
  StyledSystemMessage.defaultProps = defaultThemeProp;
343
- export const StyledMessagesList = styled.ul(({ theme: { base: { shadow, spacing } } }) => {
471
+ export const StyledMessagesList = styled.ul(({ theme: { base: { shadow, spacing } }, simplified }) => {
344
472
  return css `
345
- padding-block-start: ${spacing};
473
+ padding-block-start: ${simplified ? `calc(4 * ${spacing})` : spacing};
346
474
  list-style-type: none;
347
475
  align-self: center;
348
- max-width: ${maxWidthMessage};
476
+ max-width: var(--message-container-width);
349
477
  width: 100%;
350
- margin-block-start: auto;
478
+ margin-block-start: var(--messages-list-margin-start, auto);
351
479
  min-height: var(--stream-buffer, auto);
352
480
 
353
481
  & > li {
@@ -379,7 +507,7 @@ export const StyledMessagesList = styled.ul(({ theme: { base: { shadow, spacing
379
507
  StyledMessagesList.defaultProps = defaultThemeProp;
380
508
  export const StyledHistoryContainer = styled(Flex)(({ theme, inFullPage }) => {
381
509
  const { background, 'foreground-color': foregroundColor } = theme.components.agent.history;
382
- const foreground = calculateForegroundColor(background, foregroundColor);
510
+ const foreground = calculateForegroundColor(background, foregroundColor, theme);
383
511
  return css `
384
512
  height: 100%;
385
513
  min-height: 0;
@@ -415,7 +543,7 @@ export const StyledInnerList = styled.ul(({ theme }) => css `
415
543
  `);
416
544
  StyledInnerList.defaultProps = defaultThemeProp;
417
545
  export const StyledHistorySummaryListItem = styled(SummaryItem)(({ theme }) => {
418
- const hoverColor = tryCatch(() => mix(0.95, theme.base.palette['primary-background'], theme.base.palette.interactive));
546
+ const hoverColor = tryCatch(() => mix(0.95, theme.components.agent.history.background, theme.base.palette.interactive));
419
547
  return css `
420
548
  padding-inline: calc(2 * ${theme.base.spacing});
421
549
  padding-block: ${theme.base.spacing};
@@ -468,7 +596,7 @@ export const StyledAttachmentsList = styled(FileList)(({ theme }) => {
468
596
  StyledAttachmentsList.defaultProps = defaultThemeProp;
469
597
  export const StyledGuidedSuggestions = styled(MenuButton) `
470
598
  width: 100%;
471
- max-width: ${maxWidthMessage};
599
+ max-width: var(--message-container-width);
472
600
  > span {
473
601
  justify-content: center;
474
602
  }
@@ -478,7 +606,7 @@ export const StyledAgentIcon = styled.svg `
478
606
  height: 3rem;
479
607
  `;
480
608
  StyledAgentIcon.defaultProps = defaultThemeProp;
481
- export const StyledGenAITextArea = styled(TextArea)(({ theme: { components } }) => {
609
+ export const StyledGenAITextArea = styled(TextArea)(({ theme: { components, base }, simplified }) => {
482
610
  return css `
483
611
  border: none;
484
612
  box-shadow: none;
@@ -486,6 +614,10 @@ export const StyledGenAITextArea = styled(TextArea)(({ theme: { components } })
486
614
  max-height: 6rem;
487
615
  overflow-y: auto;
488
616
  padding-block-end: 0;
617
+ ${simplified &&
618
+ css `
619
+ padding: calc(2 * ${base.spacing});
620
+ `}
489
621
  &:focus:not([disabled]) {
490
622
  border: none;
491
623
  box-shadow: none;
@@ -494,29 +626,47 @@ export const StyledGenAITextArea = styled(TextArea)(({ theme: { components } })
494
626
  `;
495
627
  });
496
628
  StyledGenAITextArea.defaultProps = defaultThemeProp;
497
- export const StyledSendButton = styled(Button)(({ theme: { base: { 'border-radius': baseBorderRadius }, components: { 'form-control': { 'border-radius': formControlBorderRadius } } } }) => {
629
+ export const StyledSendButton = styled(Button)(({ theme: { base: { 'border-radius': baseBorderRadius }, components: { 'form-control': { 'border-radius': formControlBorderRadius } } }, simplified }) => {
630
+ const radiusMultiplier = simplified ? 0.5 : 1;
498
631
  return css `
499
- border-radius: calc(${baseBorderRadius} * ${formControlBorderRadius});
500
- margin-inline-start: auto;
632
+ border-radius: calc(${baseBorderRadius} * ${formControlBorderRadius} * ${radiusMultiplier});
633
+ flex-shrink: 0;
501
634
  `;
502
635
  });
503
636
  StyledSendButton.defaultProps = defaultThemeProp;
504
- export const StyledStopGeneratingButton = styled(Button)(({ theme: { base: { 'border-radius': baseBorderRadius }, components: { 'form-control': { 'border-radius': formControlBorderRadius } } } }) => {
637
+ export const StyledStopGeneratingButton = styled(Button)(({ theme: { base: { 'border-radius': baseBorderRadius }, components: { 'form-control': { 'border-radius': formControlBorderRadius } } }, simplified }) => {
638
+ const radiusMultiplier = simplified ? 0.5 : 1;
505
639
  return css `
506
- border-radius: calc(${baseBorderRadius} * ${formControlBorderRadius});
507
- margin-inline-start: auto;
640
+ border-radius: calc(${baseBorderRadius} * ${formControlBorderRadius} * ${radiusMultiplier});
641
+ flex-shrink: 0;
508
642
  `;
509
643
  });
510
644
  StyledStopGeneratingButton.defaultProps = defaultThemeProp;
511
645
  export const StyledInitialMessageGrid = styled.div `
512
- max-width: ${maxWidthMessage};
646
+ max-width: var(--message-container-width);
513
647
  width: 100%;
514
648
  `;
649
+ export const StyledSimplifiedInitialMessageGrid = styled(StyledInitialMessageGrid)(({ theme: { base: { 'border-radius': baseBorderRadius, spacing }, components: { 'form-control': { 'background-color': composerBackground, 'border-radius': formControlBorderRadius } } } }) => {
650
+ const borderRadius = `calc(${baseBorderRadius} * ${formControlBorderRadius})`;
651
+ return css `
652
+ background: ${transparentize(0.8, composerBackground)};
653
+ border-radius: 0 0 ${borderRadius} ${borderRadius};
654
+ margin-block-start: calc(-1 * ${borderRadius});
655
+ padding: calc(${borderRadius} + 1.5 * ${spacing}) calc(1.5 * ${spacing}) calc(1.5 * ${spacing});
656
+
657
+ > button {
658
+ width: fit-content;
659
+ max-width: 100%;
660
+ }
661
+ `;
662
+ });
663
+ StyledSimplifiedInitialMessageGrid.defaultProps = defaultThemeProp;
515
664
  export const StyledInitialMessageButton = styled(Button)(({ theme: { base: { spacing } } }) => {
516
665
  return css `
517
666
  white-space: normal;
518
667
  text-align: left;
519
668
  min-width: unset;
669
+ max-width: 100%;
520
670
  padding-block: ${spacing};
521
671
  padding-inline: calc(2 * ${spacing});
522
672
  align-items: start;
@@ -530,15 +680,16 @@ StyledInitialMessageButton.defaultProps = defaultThemeProp;
530
680
  export const StyledInitialMessageText = styled.span `
531
681
  ${lineClamp(3)};
532
682
  `;
533
- export const StyledGenAIAvatar = styled(Avatar)(({ theme: { components: { agent: { 'coach-message': { avatar: { background: avatarBackground } } } } } }) => {
683
+ export const StyledGenAIAvatar = styled(Avatar)(({ theme: { components: { agent: { 'coach-message': { avatar: { background: avatarBackground, 'foreground-color': avatarForegroundColor } } } } } }) => {
534
684
  return css `
535
685
  background: ${avatarBackground};
686
+ color: ${avatarForegroundColor};
536
687
  `;
537
688
  });
538
689
  StyledGenAIAvatar.defaultProps = defaultThemeProp;
539
690
  export const StyledGenAIFooter = styled.div `
540
691
  width: 100%;
541
- max-width: ${maxWidthMessage};
692
+ max-width: var(--message-container-width);
542
693
  `;
543
694
  export const StyledToolMessage = styled.p(({ theme: { base: { spacing, palette: { 'border-line': borderLine } } } }) => {
544
695
  return css `
@@ -581,41 +732,52 @@ export const StyledScrollButton = styled(Button)(({ theme }) => {
581
732
  });
582
733
  StyledScrollButton.defaultProps = defaultThemeProp;
583
734
  export const ProgressAngleStyle = createGlobalStyle `
584
- @property --angle {
735
+ @property --progress-border-angle {
585
736
  syntax: "<angle>";
586
- inherits: true;
737
+ inherits: false;
587
738
  initial-value: 0deg;
588
739
  }
589
740
  `;
741
+ const progressBorderSpin = keyframes `
742
+ to { --progress-border-angle: 360deg; }
743
+ `;
590
744
  export const StyledProgressContainer = styled.div(({ theme }) => {
591
- const aiColor = isSolidColor(theme.base.palette.ai)
592
- ? theme.base.palette.ai
745
+ const aiColor = isSolidColor(theme.components.agent.ai)
746
+ ? theme.components.agent.ai
593
747
  : theme.base.colors.purple.dark;
594
748
  const aiTransparent = transparentize(0.85, aiColor);
749
+ const borderWidth = '0.0625rem';
595
750
  return css `
596
751
  position: relative;
597
- isolation: isolate;
598
752
  border-radius: calc(2 * ${theme.base.spacing});
599
753
  border-start-start-radius: calc(0.5 * ${theme.base.spacing});
600
- border: calc(0.125 * ${theme.base.spacing}) solid transparent;
601
- background:
602
- linear-gradient(${aiTransparent} 0 0) padding-box,
603
- conic-gradient(
604
- from var(--angle) in oklab,
605
- ${aiTransparent} 0%,
606
- ${aiTransparent} 10%,
607
- ${aiColor} 50%,
608
- ${aiTransparent} 90%,
609
- ${aiTransparent} 100%
610
- )
611
- border-box;
612
- animation: spin 1s ease-in-out infinite;
613
754
  width: fit-content;
614
755
 
615
- @keyframes spin {
616
- to {
617
- --angle: 360deg;
618
- }
756
+ &::before {
757
+ content: '';
758
+ position: absolute;
759
+ inset: -${borderWidth};
760
+ border-radius: calc(1.875 * ${theme.base.spacing} + ${borderWidth});
761
+ border-start-start-radius: calc(0.375 * ${theme.base.spacing} + ${borderWidth});
762
+ padding: ${borderWidth};
763
+ background: conic-gradient(
764
+ from var(--progress-border-angle, 0deg) in oklab,
765
+ ${aiTransparent} 0%,
766
+ ${aiTransparent} 10%,
767
+ ${aiColor} 50%,
768
+ ${aiTransparent} 90%,
769
+ ${aiTransparent} 100%
770
+ );
771
+ -webkit-mask:
772
+ linear-gradient(#000000 0 0) content-box,
773
+ linear-gradient(#000000 0 0);
774
+ -webkit-mask-composite: xor;
775
+ mask:
776
+ linear-gradient(#000000 0 0) content-box,
777
+ linear-gradient(#000000 0 0);
778
+ mask-composite: exclude;
779
+ pointer-events: none;
780
+ animation: ${progressBorderSpin} 1.25s linear infinite;
619
781
  }
620
782
  `;
621
783
  });
@@ -635,7 +797,7 @@ export const StyledProgressContent = styled.div(({ theme }) => {
635
797
  StyledProgressContent.defaultProps = defaultThemeProp;
636
798
  export const StyledProgressText = styled(Text)(({ theme }) => {
637
799
  return css `
638
- color: ${theme.base.palette.ai};
800
+ color: ${theme.components.agent.ai};
639
801
  `;
640
802
  });
641
803
  StyledProgressText.defaultProps = defaultThemeProp;
@@ -660,8 +822,7 @@ export const StyledPortalSplitContainer = styled.div `
660
822
  container-name: portal-split;
661
823
  display: flex;
662
824
  width: 100%;
663
- height: calc(100dvh - var(--appshell-offset, 0));
664
- min-height: calc(100dvh - var(--appshell-offset, 0));
825
+ min-height: calc(100dvh - var(--appshell-total-offset, 0rem));
665
826
  `;
666
827
  StyledPortalSplitContainer.defaultProps = defaultThemeProp;
667
828
  const portalAgentRegionBasis = (agentVisible, mainVisible) => {
@@ -677,7 +838,10 @@ export const StyledPortalAgentRegion = styled.aside(({ agentVisible, mainVisible
677
838
  transition: flex-basis calc(${theme.base.animation.speed} / 2)
678
839
  ${theme.base.animation.timing.ease};
679
840
  will-change: flex-basis;
680
- border-inline-end: 0.0625rem solid ${theme.base.palette['border-line']};
841
+ position: sticky;
842
+ top: var(--appshell-top-offset, 0);
843
+ height: calc(100dvh - var(--appshell-total-offset, 0rem));
844
+ align-self: flex-start;
681
845
 
682
846
  @container portal-split (min-width: ${theme.base.breakpoints.xl}) {
683
847
  ${agentVisible &&
@@ -691,6 +855,12 @@ export const StyledPortalAgentRegion = styled.aside(({ agentVisible, mainVisible
691
855
  `}
692
856
  }
693
857
 
858
+ ${agentVisible &&
859
+ mainVisible &&
860
+ css `
861
+ border-inline-end: 0.0625rem solid ${theme.base.palette['border-line']};
862
+ `}
863
+
694
864
  ${!agentVisible &&
695
865
  css `
696
866
  overflow: hidden;
@@ -698,12 +868,9 @@ export const StyledPortalAgentRegion = styled.aside(({ agentVisible, mainVisible
698
868
  `);
699
869
  StyledPortalAgentRegion.defaultProps = defaultThemeProp;
700
870
  export const StyledPortalMainRegion = styled.div `
701
- --appshell-sticky-offset: 0;
702
871
  flex: 1 1 0%;
703
- overflow: auto;
704
872
  min-width: 0;
705
- min-height: inherit;
706
- contain: style;
873
+ min-height: calc(100dvh - var(--appshell-total-offset, 0rem));
707
874
 
708
875
  &[inert] {
709
876
  display: none;
@@ -711,13 +878,12 @@ export const StyledPortalMainRegion = styled.div `
711
878
  `;
712
879
  StyledPortalMainRegion.defaultProps = defaultThemeProp;
713
880
  export const StyledPortalSeparator = styled.div `
714
- position: relative;
881
+ position: sticky;
882
+ top: var(--appshell-top-offset, 0);
883
+ align-self: flex-start;
715
884
  flex-shrink: 0;
716
- align-self: stretch;
717
-
718
- ${StyledResizeHandle} {
719
- z-index: 1;
720
- }
885
+ height: calc(100dvh - var(--appshell-total-offset, 0rem));
886
+ z-index: 1;
721
887
  `;
722
888
  StyledPortalSeparator.defaultProps = defaultThemeProp;
723
889
  export const StyledSuggestionCardsView = styled.div(({ theme: { base: { spacing, 'font-size': fontSize, 'font-scale': fontScale, 'font-weight': fontWeight, transparency, 'content-width': contentWidth }, components: { 'form-control': { 'border-color': formControlBorderColor } } } }) => {
@@ -811,7 +977,7 @@ export const StyledSuggestionCardsBottomHalf = styled(Flex)(({ theme: { base: {
811
977
  StyledSuggestionCardsBottomHalf.defaultProps = defaultThemeProp;
812
978
  export const StyledCaseWorkflowBanner = styled(Flex)(({ theme }) => {
813
979
  const background = theme.components['case-view'].header.background;
814
- const foreground = calculateForegroundColor(background, theme.components['case-view'].header['foreground-color']);
980
+ const foreground = calculateForegroundColor(background, theme.components['case-view'].header['foreground-color'], theme);
815
981
  return css `
816
982
  @keyframes case-header-fade-in {
817
983
  from {
@@ -888,8 +1054,10 @@ export const StyledProgressLabel = styled.span(({ theme }) => {
888
1054
  StyledProgressLabel.defaultProps = defaultThemeProp;
889
1055
  export const StyledWorkflowInfoDialog = styled(InfoDialog)(({ theme }) => {
890
1056
  return css `
891
- width: ${theme.base['content-width'].sm};
892
- max-height: 80vh;
1057
+ &:not(${StyledTouchDialog}) {
1058
+ width: ${theme.base['content-width'].sm};
1059
+ max-height: 80vh;
1060
+ }
893
1061
  `;
894
1062
  });
895
1063
  StyledWorkflowInfoDialog.defaultProps = defaultThemeProp;
@@ -953,8 +1121,9 @@ export const StyledStepsContainer = styled.div(({ theme, stageStatus }) => {
953
1121
  });
954
1122
  StyledStepsContainer.defaultProps = defaultThemeProp;
955
1123
  export const StyledCaseViewIcon = styled(Icon)(({ theme, foreground, background }) => {
1124
+ const minContrast = theme.base['min-contrast'];
956
1125
  const meetsContrast = foreground && background
957
- ? tryCatch(() => meetsContrastGuidelines(foreground, background).AA, () => false)
1126
+ ? tryCatch(() => meetsMinContrast(foreground, background, minContrast), () => false)
958
1127
  : true;
959
1128
  return css `
960
1129
  --brand-accent: ${theme.base.palette['brand-accent']};
@@ -995,7 +1164,7 @@ export const StyledCaseViewImage = styled(Image) `
995
1164
  StyledCaseViewImage.defaultProps = defaultThemeProp;
996
1165
  export const StyledActiveCaseButton = styled.button(({ theme }) => {
997
1166
  const background = theme.components['case-view'].header.background;
998
- const foreground = calculateForegroundColor(background, theme.components['case-view'].header['foreground-color']);
1167
+ const foreground = calculateForegroundColor(background, theme.components['case-view'].header['foreground-color'], theme);
999
1168
  const hoverBg = tryCatch(() => darken(0.05, background), () => background);
1000
1169
  const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
1001
1170
  return css `
@@ -1048,39 +1217,52 @@ export const StyledActiveCaseStages = styled.div(({ theme }) => {
1048
1217
  `;
1049
1218
  });
1050
1219
  StyledActiveCaseStages.defaultProps = defaultThemeProp;
1051
- export const StyledSalutation = styled(Text)(({ theme }) => {
1220
+ export const StyledSalutation = styled(Text)(({ theme, simplified }) => {
1052
1221
  return css `
1053
1222
  text-align: center;
1054
1223
  overflow-wrap: break-word;
1055
1224
  word-break: break-word;
1056
- font-size: clamp(1.5rem, 1.333rem + 0.052vw, 2rem);
1225
+ font-size: ${simplified
1226
+ ? 'clamp(2.5rem, 2rem + 1vw, 3.5rem)'
1227
+ : 'clamp(1.5rem, 1.333rem + 0.052vw, 2rem)'};
1057
1228
  font-weight: ${theme.base['font-weight'].bold};
1058
1229
  `;
1059
1230
  });
1060
1231
  StyledSalutation.defaultProps = defaultThemeProp;
1061
- export const StyledQuestionnaireCard = styled.article(({ theme: { base: { spacing, palette: { 'border-line': borderLine } }, components: { agent: { questionnaire: { background, 'foreground-color': foregroundColor } } } } }) => {
1062
- const foreground = calculateForegroundColor(background, foregroundColor);
1232
+ export const StyledSubHeading = styled(Text)(({ theme }) => {
1233
+ const { xxl } = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
1063
1234
  return css `
1064
- width: 100%;
1065
- border: none;
1066
- border-block-end: 0.0625rem solid ${borderLine};
1067
- border-radius: 0;
1068
- background: ${background};
1069
- color: ${foreground};
1235
+ text-align: center;
1236
+ overflow-wrap: break-word;
1237
+ word-break: break-word;
1238
+ font-size: ${xxl};
1239
+ `;
1240
+ });
1241
+ StyledSubHeading.defaultProps = defaultThemeProp;
1242
+ export const StyledQuestionnaireCard = styled.article(({ theme }) => {
1243
+ const { base: { spacing, palette: { 'border-line': borderLine } }, components: { agent: { questionnaire: { background, 'foreground-color': foregroundColor } } } } = theme;
1244
+ const foreground = calculateForegroundColor(background, foregroundColor, theme);
1245
+ return css `
1246
+ width: 100%;
1247
+ border: none;
1248
+ border-block-end: 0.0625rem solid ${borderLine};
1249
+ border-radius: 0;
1250
+ background: ${background};
1251
+ color: ${foreground};
1070
1252
 
1071
- &&& ${StyledCardHeader} {
1072
- padding-block-start: ${spacing};
1073
- padding-inline-end: ${spacing};
1074
- }
1253
+ &&& ${StyledCardHeader} {
1254
+ padding-block-start: ${spacing};
1255
+ padding-inline-end: ${spacing};
1256
+ }
1075
1257
 
1076
- &&& ${StyledCardFooter} {
1077
- padding-block-end: ${spacing};
1078
- }
1258
+ &&& ${StyledCardFooter} {
1259
+ padding-block-end: ${spacing};
1260
+ }
1079
1261
 
1080
- &&& ${StyledCardContent} {
1081
- padding-block-end: ${spacing};
1082
- }
1083
- `;
1262
+ &&& ${StyledCardContent} {
1263
+ padding-block-end: ${spacing};
1264
+ }
1265
+ `;
1084
1266
  });
1085
1267
  StyledQuestionnaireCard.defaultProps = defaultThemeProp;
1086
1268
  export const StyledQuestionBlock = styled.fieldset `