@pega/cosmos-react-build 4.0.0-dev.2.0 → 4.0.0-dev.20.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 (179) hide show
  1. package/lib/components/AppShell/AppShell.d.ts +3 -2
  2. package/lib/components/AppShell/AppShell.d.ts.map +1 -1
  3. package/lib/components/AppShell/AppShell.js +42 -80
  4. package/lib/components/AppShell/AppShell.js.map +1 -1
  5. package/lib/components/AppShell/AppShell.styles.d.ts +12 -16
  6. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  7. package/lib/components/AppShell/AppShell.styles.js +208 -283
  8. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  9. package/lib/components/AppShell/AppShell.types.d.ts +63 -31
  10. package/lib/components/AppShell/AppShell.types.d.ts.map +1 -1
  11. package/lib/components/AppShell/AppShell.types.js.map +1 -1
  12. package/lib/components/AppShell/AppShellContext.d.ts.map +1 -1
  13. package/lib/components/AppShell/AppShellContext.js +3 -5
  14. package/lib/components/AppShell/AppShellContext.js.map +1 -1
  15. package/lib/components/AppShell/Header/AppHeader.d.ts.map +1 -0
  16. package/lib/components/AppShell/Header/AppHeader.js +73 -0
  17. package/lib/components/AppShell/Header/AppHeader.js.map +1 -0
  18. package/lib/components/{AppHeader → AppShell/Header}/AppHeader.styles.d.ts +7 -7
  19. package/lib/components/AppShell/Header/AppHeader.styles.d.ts.map +1 -0
  20. package/lib/components/AppShell/Header/AppHeader.styles.js +158 -0
  21. package/lib/components/AppShell/Header/AppHeader.styles.js.map +1 -0
  22. package/lib/components/{AppHeader → AppShell/Header}/AppHeader.types.d.ts +6 -5
  23. package/lib/components/AppShell/Header/AppHeader.types.d.ts.map +1 -0
  24. package/lib/components/AppShell/Header/AppHeader.types.js.map +1 -0
  25. package/lib/components/AppShell/Header/BranchButton.d.ts.map +1 -0
  26. package/lib/components/{AppHeader → AppShell/Header}/BranchButton.js +5 -5
  27. package/lib/components/AppShell/Header/BranchButton.js.map +1 -0
  28. package/lib/components/AppShell/NavigationList.d.ts +6 -0
  29. package/lib/components/AppShell/NavigationList.d.ts.map +1 -0
  30. package/lib/components/AppShell/NavigationList.js +97 -0
  31. package/lib/components/AppShell/NavigationList.js.map +1 -0
  32. package/lib/components/AppShell/index.d.ts +3 -1
  33. package/lib/components/AppShell/index.d.ts.map +1 -1
  34. package/lib/components/AppShell/index.js.map +1 -1
  35. package/lib/components/DynamicContentEditor/DynamicContentEditor.d.ts.map +1 -1
  36. package/lib/components/DynamicContentEditor/DynamicContentEditor.js +27 -27
  37. package/lib/components/DynamicContentEditor/DynamicContentEditor.js.map +1 -1
  38. package/lib/components/DynamicContentEditor/DynamicContentEditor.types.d.ts +1 -1
  39. package/lib/components/DynamicContentEditor/DynamicContentEditor.types.d.ts.map +1 -1
  40. package/lib/components/DynamicContentEditor/PegaCustomElement.d.ts +41 -27
  41. package/lib/components/DynamicContentEditor/PegaCustomElement.d.ts.map +1 -1
  42. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.d.ts.map +1 -1
  43. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.js +17 -33
  44. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.js.map +1 -1
  45. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.styles.js +6 -6
  46. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.styles.js.map +1 -1
  47. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.types.d.ts +4 -3
  48. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.types.d.ts.map +1 -1
  49. package/lib/components/ExpressionBuilder/CodeEditor/CodeEditor.types.js.map +1 -1
  50. package/lib/components/ExpressionBuilder/index.d.ts +1 -1
  51. package/lib/components/ExpressionBuilder/index.d.ts.map +1 -1
  52. package/lib/components/ExpressionBuilder/index.js.map +1 -1
  53. package/lib/components/FlowModeller/AddNode.d.ts.map +1 -1
  54. package/lib/components/FlowModeller/AddNode.js +3 -4
  55. package/lib/components/FlowModeller/AddNode.js.map +1 -1
  56. package/lib/components/FlowModeller/Connector.d.ts +2 -2
  57. package/lib/components/FlowModeller/Connector.d.ts.map +1 -1
  58. package/lib/components/FlowModeller/Connector.js +2 -4
  59. package/lib/components/FlowModeller/Connector.js.map +1 -1
  60. package/lib/components/FlowModeller/DeletePopover.d.ts +3 -3
  61. package/lib/components/FlowModeller/DeletePopover.d.ts.map +1 -1
  62. package/lib/components/FlowModeller/DeletePopover.js.map +1 -1
  63. package/lib/components/FlowModeller/FlowModeller.d.ts.map +1 -1
  64. package/lib/components/FlowModeller/FlowModeller.js +1 -3
  65. package/lib/components/FlowModeller/FlowModeller.js.map +1 -1
  66. package/lib/components/FlowModeller/Node/Node.types.d.ts +5 -0
  67. package/lib/components/FlowModeller/Node/Node.types.d.ts.map +1 -1
  68. package/lib/components/FlowModeller/Node/Node.types.js.map +1 -1
  69. package/lib/components/FlowModeller/Node/NodeTemplate.styles.d.ts +5 -1
  70. package/lib/components/FlowModeller/Node/NodeTemplate.styles.d.ts.map +1 -1
  71. package/lib/components/FlowModeller/Node/NodeTemplate.styles.js +10 -3
  72. package/lib/components/FlowModeller/Node/NodeTemplate.styles.js.map +1 -1
  73. package/lib/components/FlowModeller/Node/NodeTemplates.d.ts.map +1 -1
  74. package/lib/components/FlowModeller/Node/NodeTemplates.js +11 -29
  75. package/lib/components/FlowModeller/Node/NodeTemplates.js.map +1 -1
  76. package/lib/components/FlowModeller/Renderer/Utils/Graph.js.map +1 -1
  77. package/lib/components/FlowModeller/Renderer/Utils/GraphLayout.js +3 -3
  78. package/lib/components/FlowModeller/Renderer/Utils/GraphLayout.js.map +1 -1
  79. package/lib/components/ItemLibrary/ItemLibrary.d.ts.map +1 -1
  80. package/lib/components/ItemLibrary/ItemLibrary.js +2 -2
  81. package/lib/components/ItemLibrary/ItemLibrary.js.map +1 -1
  82. package/lib/components/LifeCycle/Category.d.ts.map +1 -1
  83. package/lib/components/LifeCycle/Category.js +2 -2
  84. package/lib/components/LifeCycle/Category.js.map +1 -1
  85. package/lib/components/LifeCycle/LifeCycle.types.d.ts +22 -1
  86. package/lib/components/LifeCycle/LifeCycle.types.d.ts.map +1 -1
  87. package/lib/components/LifeCycle/LifeCycle.types.js.map +1 -1
  88. package/lib/components/LifeCycle/LifeCycleList.d.ts +11 -0
  89. package/lib/components/LifeCycle/LifeCycleList.d.ts.map +1 -1
  90. package/lib/components/LifeCycle/LifeCycleList.js +1 -1
  91. package/lib/components/LifeCycle/LifeCycleList.js.map +1 -1
  92. package/lib/components/LifeCycle/Stage.d.ts +2 -0
  93. package/lib/components/LifeCycle/Stage.d.ts.map +1 -1
  94. package/lib/components/LifeCycle/Stage.js +4 -10
  95. package/lib/components/LifeCycle/Stage.js.map +1 -1
  96. package/lib/components/LifeCycle/Step.d.ts +6 -2
  97. package/lib/components/LifeCycle/Step.d.ts.map +1 -1
  98. package/lib/components/LifeCycle/Step.js +30 -24
  99. package/lib/components/LifeCycle/Step.js.map +1 -1
  100. package/lib/components/LifeCycle/Task.d.ts +1 -0
  101. package/lib/components/LifeCycle/Task.d.ts.map +1 -1
  102. package/lib/components/LifeCycle/Task.js +6 -12
  103. package/lib/components/LifeCycle/Task.js.map +1 -1
  104. package/lib/components/MobileBuildSummary/MobileBuildSummary.d.ts +0 -1
  105. package/lib/components/MobileBuildSummary/MobileBuildSummary.d.ts.map +1 -1
  106. package/lib/components/MobileBuildSummary/MobileBuildSummary.js +5 -16
  107. package/lib/components/MobileBuildSummary/MobileBuildSummary.js.map +1 -1
  108. package/lib/components/MobileBuildSummary/MobileBuildSummary.types.d.ts +5 -3
  109. package/lib/components/MobileBuildSummary/MobileBuildSummary.types.d.ts.map +1 -1
  110. package/lib/components/MobileBuildSummary/MobileBuildSummary.types.js.map +1 -1
  111. package/lib/components/ObjectPreview/ObjectPreview.d.ts +2 -2
  112. package/lib/components/ObjectPreview/ObjectPreview.d.ts.map +1 -1
  113. package/lib/components/ObjectPreview/ObjectPreview.js +1 -1
  114. package/lib/components/ObjectPreview/ObjectPreview.js.map +1 -1
  115. package/lib/components/ObjectSelect/ObjectSummary.d.ts +11 -3
  116. package/lib/components/ObjectSelect/ObjectSummary.d.ts.map +1 -1
  117. package/lib/components/ObjectSelect/ObjectSummary.js +50 -14
  118. package/lib/components/ObjectSelect/ObjectSummary.js.map +1 -1
  119. package/lib/components/ObjectSelect/useCreateModal.d.ts +9 -11
  120. package/lib/components/ObjectSelect/useCreateModal.d.ts.map +1 -1
  121. package/lib/components/ObjectSelect/useCreateModal.js +5 -6
  122. package/lib/components/ObjectSelect/useCreateModal.js.map +1 -1
  123. package/lib/components/PageBanner/PageBanner.d.ts +22 -0
  124. package/lib/components/PageBanner/PageBanner.d.ts.map +1 -0
  125. package/lib/components/PageBanner/PageBanner.js +59 -0
  126. package/lib/components/PageBanner/PageBanner.js.map +1 -0
  127. package/lib/components/PageBanner/index.d.ts +3 -0
  128. package/lib/components/PageBanner/index.d.ts.map +1 -0
  129. package/lib/components/PageBanner/index.js +2 -0
  130. package/lib/components/PageBanner/index.js.map +1 -0
  131. package/lib/components/PageTemplates/GalleryPage.d.ts +10 -10
  132. package/lib/components/PageTemplates/GalleryPage.d.ts.map +1 -1
  133. package/lib/components/PageTemplates/GalleryPage.js +35 -11
  134. package/lib/components/PageTemplates/GalleryPage.js.map +1 -1
  135. package/lib/components/PageTemplates/PageTemplates.d.ts +1 -1
  136. package/lib/components/PageTemplates/PageTemplates.d.ts.map +1 -1
  137. package/lib/components/PageTemplates/PageTemplates.js +8 -45
  138. package/lib/components/PageTemplates/PageTemplates.js.map +1 -1
  139. package/lib/components/PageTemplates/ShowcasePage.d.ts +16 -0
  140. package/lib/components/PageTemplates/ShowcasePage.d.ts.map +1 -0
  141. package/lib/components/PageTemplates/ShowcasePage.js +29 -0
  142. package/lib/components/PageTemplates/ShowcasePage.js.map +1 -0
  143. package/lib/components/PageTemplates/index.d.ts +3 -1
  144. package/lib/components/PageTemplates/index.d.ts.map +1 -1
  145. package/lib/components/PageTemplates/index.js +2 -1
  146. package/lib/components/PageTemplates/index.js.map +1 -1
  147. package/lib/components/SummaryCard/SummaryCard.d.ts.map +1 -1
  148. package/lib/components/SummaryCard/SummaryCard.js +4 -7
  149. package/lib/components/SummaryCard/SummaryCard.js.map +1 -1
  150. package/lib/components/Workbench/Workbench.types.d.ts +2 -2
  151. package/lib/components/Workbench/Workbench.types.d.ts.map +1 -1
  152. package/lib/index.d.ts +3 -2
  153. package/lib/index.d.ts.map +1 -1
  154. package/lib/index.js +3 -2
  155. package/lib/index.js.map +1 -1
  156. package/lib/utils/utils.d.ts +1 -1
  157. package/lib/utils/utils.d.ts.map +1 -1
  158. package/package.json +16 -9
  159. package/lib/components/AppHeader/AppHeader.d.ts.map +0 -1
  160. package/lib/components/AppHeader/AppHeader.js +0 -40
  161. package/lib/components/AppHeader/AppHeader.js.map +0 -1
  162. package/lib/components/AppHeader/AppHeader.styles.d.ts.map +0 -1
  163. package/lib/components/AppHeader/AppHeader.styles.js +0 -118
  164. package/lib/components/AppHeader/AppHeader.styles.js.map +0 -1
  165. package/lib/components/AppHeader/AppHeader.types.d.ts.map +0 -1
  166. package/lib/components/AppHeader/AppHeader.types.js.map +0 -1
  167. package/lib/components/AppHeader/BranchButton.d.ts.map +0 -1
  168. package/lib/components/AppHeader/BranchButton.js.map +0 -1
  169. package/lib/components/AppHeader/index.d.ts +0 -4
  170. package/lib/components/AppHeader/index.d.ts.map +0 -1
  171. package/lib/components/AppHeader/index.js +0 -3
  172. package/lib/components/AppHeader/index.js.map +0 -1
  173. package/lib/components/PageTemplates/GalleryPage.styles.d.ts +0 -9
  174. package/lib/components/PageTemplates/GalleryPage.styles.d.ts.map +0 -1
  175. package/lib/components/PageTemplates/GalleryPage.styles.js +0 -70
  176. package/lib/components/PageTemplates/GalleryPage.styles.js.map +0 -1
  177. /package/lib/components/{AppHeader → AppShell/Header}/AppHeader.d.ts +0 -0
  178. /package/lib/components/{AppHeader → AppShell/Header}/AppHeader.types.js +0 -0
  179. /package/lib/components/{AppHeader → AppShell/Header}/BranchButton.d.ts +0 -0
@@ -1,118 +0,0 @@
1
- import styled, { css } from 'styled-components';
2
- import { Avatar, defaultThemeProp, Flex, Text, Tabs } from '@pega/cosmos-react-core';
3
- import BareButton from '@pega/cosmos-react-core/lib/components/Button/BareButton';
4
- import { StyledAppHeaderSearchForm } from '@pega/cosmos-react-core/lib/components/AppShell/AppHeader.styles';
5
- export const StyledAppHeader = styled.header(({ theme }) => {
6
- return css `
7
- height: 3rem;
8
- padding: 0 calc(2 * ${theme.base.spacing});
9
- border-bottom: 0.0625rem solid ${theme.base.colors.gray.light};
10
- background-color: ${theme.base.palette['primary-background']};
11
- position: sticky;
12
- top: 0;
13
- z-index: calc(${theme.base['z-index'].drawer + 1});
14
- `;
15
- });
16
- StyledAppHeader.defaultProps = defaultThemeProp;
17
- export const StyledTitle = styled(Text)(({ theme }) => {
18
- return css `
19
- max-width: ${theme.base['content-width'].sm};
20
- text-overflow: ellipsis;
21
- overflow: hidden;
22
- white-space: nowrap;
23
- color: ${theme.base.palette['foreground-color']};
24
- font-weight: ${theme.base['font-weight'].bold};
25
- margin-inline-start: calc(0.75 * ${theme.base.spacing});
26
- `;
27
- });
28
- StyledTitle.defaultProps = defaultThemeProp;
29
- export const StyledBrandContainer = styled(Flex)(({ theme }) => {
30
- return css `
31
- padding-block: ${theme.base.spacing};
32
- text-decoration: none;
33
- max-height: 2.5rem;
34
-
35
- > img {
36
- min-width: ${theme.base['content-width'].xs};
37
- }
38
- `;
39
- });
40
- StyledBrandContainer.defaultProps = defaultThemeProp;
41
- export const StyledBrandButton = styled(BareButton)(({ theme }) => {
42
- return css `
43
- &:not([disabled]):focus {
44
- box-shadow: ${theme.base.shadow.focus};
45
- }
46
- `;
47
- });
48
- StyledBrandButton.defaultProps = defaultThemeProp;
49
- export const StyledTabs = styled(Tabs)(({ theme }) => {
50
- return css `
51
- margin-inline-start: calc(2 * ${theme.base.spacing});
52
- margin-inline-end: calc(2 * ${theme.base.spacing});
53
- border: none;
54
- min-height: 3rem;
55
- [role='tab'] {
56
- height: auto;
57
- span:first-of-type {
58
- text-transform: none;
59
- }
60
- }
61
- [role='tab'][aria-selected='false'] > span {
62
- font-weight: ${theme.base['font-weight']['semi-bold']};
63
- }
64
- [role='tab']:hover,
65
- [role='tab']:focus,
66
- [role='tab']:active {
67
- box-shadow: none;
68
- }
69
- `;
70
- });
71
- StyledTabs.defaultProps = defaultThemeProp;
72
- export const StyledUtilsContainer = styled.div(({ theme }) => {
73
- return css `
74
- padding-block: ${theme.base.spacing};
75
- & > div,
76
- & > span,
77
- & > button {
78
- margin-inline-start: ${theme.base.spacing};
79
- }
80
- & > div:last-child {
81
- margin-inline: calc(2 * ${theme.base.spacing}) 0;
82
- }
83
- `;
84
- });
85
- StyledUtilsContainer.defaultProps = defaultThemeProp;
86
- export const StyledAppHeaderSearch = styled.div `
87
- ${StyledAppHeaderSearchForm} {
88
- max-width: 100%;
89
- }
90
- `;
91
- StyledAppHeaderSearch.defaultProps = defaultThemeProp;
92
- export const StyledAppInfo = styled(StyledTitle)(({ theme }) => {
93
- return css `
94
- font-weight: ${theme.base['font-weight']['semi-bold']};
95
- margin-inline-start: 0;
96
- `;
97
- });
98
- StyledAppInfo.defaultProps = defaultThemeProp;
99
- export const StyledBranchContainer = styled(Flex)(({ theme }) => {
100
- return css `
101
- span {
102
- white-space: nowrap;
103
- max-width: 25ch;
104
- overflow: hidden;
105
- text-overflow: ellipsis;
106
- font-weight: ${theme.base['font-weight']['semi-bold']};
107
- margin-inline-start: calc(0.5 * ${theme.base.spacing});
108
- margin-inline-end: calc(0.75 * ${theme.base.spacing});
109
- }
110
- `;
111
- });
112
- StyledBranchContainer.defaultProps = defaultThemeProp;
113
- export const StyledAppAvatar = styled(Avatar) `
114
- width: 1.5rem;
115
- height: 1.5rem;
116
- `;
117
- StyledAppAvatar.defaultProps = defaultThemeProp;
118
- //# sourceMappingURL=AppHeader.styles.js.map
@@ -1 +0,0 @@
1
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D,MAAM,CAAC,MAAM,qBAAqB,GAAG,MAAM,CAAC,GAAG,CAAA;IAC3C,yBAAyB;;;CAG5B,CAAC;AAEF,qBAAqB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEtD,MAAM,CAAC,MAAM,aAAa,GAAgB,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC1E,OAAO,GAAG,CAAA;mBACO,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,WAAW,CAAC;;GAEtD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,aAAa,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE9C,MAAM,CAAC,MAAM,qBAAqB,GAAgB,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC3E,OAAO,GAAG,CAAA;;;;;;qBAMS,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,WAAW,CAAC;wCACnB,KAAK,CAAC,IAAI,CAAC,OAAO;uCACnB,KAAK,CAAC,IAAI,CAAC,OAAO;;GAEtD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,qBAAqB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEtD,MAAM,CAAC,MAAM,eAAe,GAAkB,MAAM,CAAC,MAAM,CAAC,CAAA;;;CAG3D,CAAC;AAEF,eAAe,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport { Avatar, defaultThemeProp, Flex, Text, Tabs } from '@pega/cosmos-react-core';\nimport BareButton from '@pega/cosmos-react-core/lib/components/Button/BareButton';\nimport { StyledAppHeaderSearchForm } from '@pega/cosmos-react-core/lib/components/AppShell/AppHeader.styles';\n\nexport const StyledAppHeader = styled.header(({ theme }) => {\n return css`\n height: 3rem;\n padding: 0 calc(2 * ${theme.base.spacing});\n border-bottom: 0.0625rem solid ${theme.base.colors.gray.light};\n background-color: ${theme.base.palette['primary-background']};\n position: sticky;\n top: 0;\n z-index: calc(${theme.base['z-index'].drawer + 1});\n `;\n});\n\nStyledAppHeader.defaultProps = defaultThemeProp;\n\nexport const StyledTitle: typeof Text = styled(Text)(({ theme }) => {\n return css`\n max-width: ${theme.base['content-width'].sm};\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n color: ${theme.base.palette['foreground-color']};\n font-weight: ${theme.base['font-weight'].bold};\n margin-inline-start: calc(0.75 * ${theme.base.spacing});\n `;\n});\n\nStyledTitle.defaultProps = defaultThemeProp;\n\nexport const StyledBrandContainer: typeof Flex = styled(Flex)(({ theme }) => {\n return css`\n padding-block: ${theme.base.spacing};\n text-decoration: none;\n max-height: 2.5rem;\n\n > img {\n min-width: ${theme.base['content-width'].xs};\n }\n `;\n});\n\nStyledBrandContainer.defaultProps = defaultThemeProp;\n\nexport const StyledBrandButton = styled(BareButton)(({ theme }) => {\n return css`\n &:not([disabled]):focus {\n box-shadow: ${theme.base.shadow.focus};\n }\n `;\n});\n\nStyledBrandButton.defaultProps = defaultThemeProp;\n\nexport const StyledTabs: typeof Tabs = styled(Tabs)(({ theme }) => {\n return css`\n margin-inline-start: calc(2 * ${theme.base.spacing});\n margin-inline-end: calc(2 * ${theme.base.spacing});\n border: none;\n min-height: 3rem;\n [role='tab'] {\n height: auto;\n span:first-of-type {\n text-transform: none;\n }\n }\n [role='tab'][aria-selected='false'] > span {\n font-weight: ${theme.base['font-weight']['semi-bold']};\n }\n [role='tab']:hover,\n [role='tab']:focus,\n [role='tab']:active {\n box-shadow: none;\n }\n `;\n});\n\nStyledTabs.defaultProps = defaultThemeProp;\n\nexport const StyledUtilsContainer = styled.div(({ theme }) => {\n return css`\n padding-block: ${theme.base.spacing};\n & > div,\n & > span,\n & > button {\n margin-inline-start: ${theme.base.spacing};\n }\n & > div:last-child {\n margin-inline: calc(2 * ${theme.base.spacing}) 0;\n }\n `;\n});\n\nStyledUtilsContainer.defaultProps = defaultThemeProp;\n\nexport const StyledAppHeaderSearch = styled.div`\n ${StyledAppHeaderSearchForm} {\n max-width: 100%;\n }\n`;\n\nStyledAppHeaderSearch.defaultProps = defaultThemeProp;\n\nexport const StyledAppInfo: typeof Text = styled(StyledTitle)(({ theme }) => {\n return css`\n font-weight: ${theme.base['font-weight']['semi-bold']};\n margin-inline-start: 0;\n `;\n});\n\nStyledAppInfo.defaultProps = defaultThemeProp;\n\nexport const StyledBranchContainer: typeof Flex = styled(Flex)(({ theme }) => {\n return css`\n span {\n white-space: nowrap;\n max-width: 25ch;\n overflow: hidden;\n text-overflow: ellipsis;\n font-weight: ${theme.base['font-weight']['semi-bold']};\n margin-inline-start: calc(0.5 * ${theme.base.spacing});\n margin-inline-end: calc(0.75 * ${theme.base.spacing});\n }\n `;\n});\n\nStyledBranchContainer.defaultProps = defaultThemeProp;\n\nexport const StyledAppAvatar: typeof Avatar = styled(Avatar)`\n width: 1.5rem;\n height: 1.5rem;\n`;\n\nStyledAppAvatar.defaultProps = defaultThemeProp;\n"]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"AppHeader.types.d.ts","sourceRoot":"","sources":["../../../src/components/AppHeader/AppHeader.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAExC,OAAO,EACL,MAAM,EACN,aAAa,EACb,SAAS,EACT,cAAc,EACd,SAAS,EACT,GAAG,EACH,WAAW,EACX,gBAAgB,EACjB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAEnD,MAAM,WAAW,WACf,SAAQ,IAAI,CAAC,aAAa,EAAE,IAAI,GAAG,SAAS,GAAG,QAAQ,GAAG,MAAM,GAAG,UAAU,CAAC;CAAG;AAEnF,MAAM,WAAW,cAAe,SAAQ,SAAS,EAAE,cAAc;IAC/D,QAAQ,EAAE,WAAW,EAAE,CAAC;IACxB,cAAc,CAAC,EAAE,SAAS,CAAC,aAAa,CAAC,CAAC;IAC1C,KAAK,EAAE;QACL,KAAK,EAAE,MAAM,CAAC;QACd,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,OAAO,CAAC,EAAE,CAAC,CAAC,EAAE,UAAU,CAAC,iBAAiB,GAAG,iBAAiB,CAAC,KAAK,IAAI,CAAC;KAC1E,CAAC;IACF,KAAK,CAAC,EAAE,SAAS,EAAE,CAAC;IACpB,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,GAAG,CAAC,EAAE,GAAG,CAAC,cAAc,CAAC,CAAC;CAC3B;AAED,MAAM,WAAW,SAAU,SAAQ,GAAG;IACpC,OAAO,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,CAAC,CAAC,EAAE,UAAU,CAAC,iBAAiB,GAAG,iBAAiB,CAAC,KAAK,IAAI,CAAC;CACvF;AAED,MAAM,WAAW,UAAU;IACzB,MAAM,EAAE,WAAW,CAAC;IACpB,MAAM,CAAC,EAAE,gBAAgB,CAAC;IAC1B,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,MAAM,CAAC,EAAE,IAAI,CAAC,MAAM,EAAE,IAAI,GAAG,MAAM,GAAG,SAAS,GAAG,UAAU,GAAG,MAAM,CAAC,CAAC;IACvE,OAAO,CAAC,EAAE;QACR,IAAI,EAAE,MAAM,CAAC;QACb,OAAO,EAAE,MAAM,CAAC;KACjB,CAAC;CACH"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"AppHeader.types.js","sourceRoot":"","sources":["../../../src/components/AppHeader/AppHeader.types.ts"],"names":[],"mappings":"","sourcesContent":["import { Ref, MouseEvent } from 'react';\n\nimport {\n Action,\n MenuItemProps,\n BaseProps,\n NoChildrenProp,\n MenuProps,\n Tab,\n AvatarProps,\n SearchInputProps\n} from '@pega/cosmos-react-core';\n\nimport { BranchButtonProps } from './BranchButton';\n\nexport interface ContextItem\n extends Pick<MenuItemProps, 'id' | 'primary' | 'visual' | 'href' | 'selected'> {}\n\nexport interface AppHeaderProps extends BaseProps, NoChildrenProp {\n contexts: ContextItem[];\n onContextClick?: MenuProps['onItemClick'];\n brand: {\n label: string;\n logo: string;\n href?: string;\n onClick?: (e: MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n };\n links?: LinkProps[];\n utils?: UtilsProps;\n ref?: Ref<HTMLDivElement>;\n}\n\nexport interface LinkProps extends Tab {\n onClick?: (id: string, e?: MouseEvent<HTMLButtonElement | HTMLAnchorElement>) => void;\n}\n\nexport interface UtilsProps {\n avatar: AvatarProps;\n search?: SearchInputProps;\n branch?: BranchButtonProps;\n action?: Pick<Action, 'id' | 'text' | 'onClick' | 'disabled' | 'icon'>;\n appInfo?: {\n name: string;\n version: string;\n };\n}\n"]}
@@ -1 +0,0 @@
1
- {"version":3,"file":"BranchButton.d.ts","sourceRoot":"","sources":["../../../src/components/AppHeader/BranchButton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAY,iBAAiB,EAAiB,MAAM,OAAO,CAAC;AAInE,OAAO,EACL,MAAM,EACN,UAAU,EAGV,IAAI,EAGJ,SAAS,EAMT,WAAW,EAGZ,MAAM,yBAAyB,CAAC;AAQjC,MAAM,WAAW,iBAAiB;IAChC,qEAAqE;IACrE,IAAI,EAAE,MAAM,CAAC;IACb,mDAAmD;IACnD,OAAO,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,SAAS,CAAC,EAAE,SAAS,GAAG,QAAQ,CAAC,CAAC;IAChE,6CAA6C;IAC7C,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,mEAAmE;IACnE,KAAK,CAAC,EAAE,UAAU,CAAC,UAAU,CAAC,CAAC;IAC/B,iCAAiC;IACjC,KAAK,EAAE,SAAS,CAAC,OAAO,CAAC,CAAC;CAC3B;AAED,eAAO,MAAM,kBAAkB,EAAE,OAAO,MAuDvC,CAAC;AAqBF,eAAO,MAAM,cAAc,EAAE,OAAO,IAIlC,CAAC;AAgBH,QAAA,MAAM,YAAY,EAAE,iBAAiB,CAAC,iBAAiB,CAqEtD,CAAC;AAEF,eAAe,YAAY,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"BranchButton.js","sourceRoot":"","sources":["../../../src/components/AppHeader/BranchButton.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAoC,MAAM,OAAO,CAAC;AACnE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAgB,MAAM,mBAAmB,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,OAAO,EACL,MAAM,EAEN,gBAAgB,EAChB,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,KAAK,EAEL,OAAO,EACP,YAAY,EACZ,UAAU,EACV,YAAY,EACZ,aAAa,EAEb,OAAO,EACP,QAAQ,EACT,MAAM,yBAAyB,CAAC;AACjC,OAAO,KAAK,kBAAkB,MAAM,yEAAyE,CAAC;AAC9G,OAAO,KAAK,aAAa,MAAM,mEAAmE,CAAC;AACnG,OAAO,KAAK,aAAa,MAAM,mEAAmE,CAAC;AACnG,OAAO,EAAE,WAAW,EAAE,MAAM,qDAAqD,CAAC;AAElF,YAAY,CAAC,kBAAkB,EAAE,aAAa,EAAE,aAAa,CAAC,CAAC;AAe/D,MAAM,CAAC,MAAM,kBAAkB,GAAkB,MAAM,CAAC,MAAM,CAAC,CAC7D,CAAC,EACC,KAAK,EACL,aAAa,EAId,EAAE,EAAE;IACH,MAAM,EACJ,IAAI,EAAE,EACJ,MAAM,EACN,OAAO,EAAE,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,EACpD,MAAM,EAAE,EAAE,KAAK,EAAE,EACjB,OAAO,EACR,EACD,UAAU,EAAE,EACV,MAAM,EAAE,EACN,MAAM,EACN,KAAK,EAAE,EACL,IAAI,EAAE,EAAE,UAAU,EAAE,UAAU,EAAE,EACjC,EACF,EACF,EACF,GAAG,KAAK,CAAC;IAEV,MAAM,eAAe,GAAG,aAAa,CAAC,CAAC,CAAC,MA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AAC,gBAAgB,EACnB,kBAAkB,QAClB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,QAAQ,EAChB,GAAG,EAAE,aAAa,YAElB,KAAC,IAAI,IACH,KAAK,EAAE,KAAK,EACZ,QAAQ,EAAE,EAAE,EACZ,WAAW,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,EACjC,cAAc,EAAE,QAAQ,IAAI,SAAS,EACrC,cAAc,EAAE,KAAK,GACrB,GACwB,IAC3B,CACJ,CAAC;AACJ,CAAC,CAAC;AAEF,eAAe,YAAY,CAAC","sourcesContent":["import { useState, FunctionComponent, KeyboardEvent } from 'react';\nimport styled, { css, DefaultTheme } from 'styled-components';\nimport { readableColor } from 'polished';\n\nimport {\n Button,\n CountProps,\n defaultThemeProp,\n Flex,\n Icon,\n Menu,\n Count,\n MenuProps,\n Popover,\n useDirection,\n useElement,\n registerIcon,\n useOuterEvent,\n StatusProps,\n useI18n,\n tryCatch\n} from '@pega/cosmos-react-core';\nimport * as nodesDownSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/nodes-down-solid.icon';\nimport * as warnSolidIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/warn-solid.icon';\nimport * as caretDownIcon from '@pega/cosmos-react-core/lib/components/Icon/icons/caret-down.icon';\nimport { StyledCount } from '@pega/cosmos-react-core/lib/components/Badges/Count';\n\nregisterIcon(nodesDownSolidIcon, warnSolidIcon, caretDownIcon);\n\nexport interface BranchButtonProps {\n /** The text for the BranchButton also used to set the aria-label. */\n text: string;\n /** Determines the variant for the BranchButton. */\n variant?: Extract<StatusProps['variant'], 'success' | 'urgent'>;\n /** Only display the branch and caret icon */\n compact?: boolean;\n /** The total count representing the number of unmerged changes. */\n count?: CountProps['children'];\n /** An array of MenuItemProps. */\n items: MenuProps['items'];\n}\n\nexport const StyledBranchButton: typeof Button = styled(Button)(\n ({\n theme,\n branchVariant\n }: {\n theme: DefaultTheme;\n branchVariant: BranchButtonProps['variant'];\n }) => {\n const {\n base: {\n colors,\n palette: { 'primary-background': primaryBackground },\n shadow: { focus },\n spacing\n },\n components: {\n badges: {\n status,\n count: {\n base: { background, foreground }\n }\n }\n }\n } = theme;\n\n const backgroundColor = branchVariant ? status[branchVariant].background : primaryBackground;\n const borderColor = !branchVariant ? colors.gray.medium : 'transparent';\n const countBgColor = branchVariant === 'success' ? colors.green.medium : background;\n const countColor = branchVariant === 'success' ? colors.white : foreground;\n const buttonColor = tryCatch(() => readableColor(backgroundColor));\n\n return css`\n flex-shrink: 0;\n background-color: ${backgroundColor};\n border-color: ${borderColor};\n color: ${buttonColor};\n padding-inline-start: ${spacing};\n padding-inline-end: ${spacing};\n\n &:hover {\n background-color: ${backgroundColor};\n box-shadow: ${focus};\n }\n\n svg {\n height: 1rem;\n width: 1rem;\n }\n\n ${StyledCount} {\n background-color: ${countBgColor};\n color: ${countColor};\n }\n `;\n }\n);\n\nStyledBranchButton.defaultProps = defaultThemeProp;\n\nconst StyledBranchButtonPopover = styled(Popover)(\n ({\n theme: {\n base: { spacing, 'content-width': contentWidth }\n }\n }) => {\n const minWidth = `calc(${contentWidth.xs} + (2 * ${spacing}))`;\n\n return css`\n min-width: ${minWidth};\n max-width: calc(${minWidth} + 5ch);\n `;\n }\n);\n\nStyledBranchButtonPopover.defaultProps = defaultThemeProp;\n\nexport const StyledWarnIcon: typeof Icon = styled(Icon)(({ theme }) => {\n return css`\n color: ${theme.base.colors.red.medium};\n `;\n});\n\nStyledWarnIcon.defaultProps = defaultThemeProp;\n\nconst StyledEllipsisedText = styled.span(({ theme }) => {\n return css`\n max-width: ${theme.base['content-width'].xs};\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n line-height: 1.5;\n `;\n});\n\nStyledEllipsisedText.defaultProps = defaultThemeProp;\n\nconst BranchButton: FunctionComponent<BranchButtonProps> = (props: BranchButtonProps) => {\n const { text, variant, count, compact = false, items = [] } = props;\n\n const [open, setOpen] = useState(false);\n\n const [popoverEl, setPopoverRef] = useElement<HTMLElement>();\n const [buttonEl, setButtonEl] = useElement<HTMLElement>();\n const { rtl } = useDirection();\n const t = useI18n();\n\n useOuterEvent('mousedown', [popoverEl, buttonEl], () => {\n if (open) setOpen(false);\n });\n\n let ariaLabel = t('branch_with_no_changes', [text]);\n if (variant === 'success') {\n ariaLabel = t('branch_with_no_potential_conflicts', [text, count ?? 0]);\n } else if (variant === 'urgent') {\n ariaLabel = t('branch_with_potential_conflicts', [text]);\n }\n\n return (\n <>\n <StyledBranchButton\n ref={setButtonEl}\n aria-expanded={open}\n aria-haspopup='menu'\n aria-controls='branch-popover'\n aria-label={ariaLabel}\n branchVariant={variant}\n label={!open ? text : undefined}\n onClick={() => setOpen(cur => !cur)}\n onKeyDown={(e: KeyboardEvent) => {\n if (e.key === 'Escape') setOpen(false);\n }}\n >\n <Flex container={{ alignItems: 'center', gap: compact ? 1 : 0.5 }}>\n <Icon name='nodes-down-solid' />\n {!compact && (\n <>\n <StyledEllipsisedText>{text}</StyledEllipsisedText>\n {variant === 'urgent' ? (\n <StyledWarnIcon name='warn-solid' />\n ) : (\n count !== undefined && <Count>{count}</Count>\n )}\n </>\n )}\n <Icon name='caret-down' />\n </Flex>\n </StyledBranchButton>\n <StyledBranchButtonPopover\n placement={rtl ? 'bottom-end' : 'bottom-start'}\n id='branch-popover'\n hideOnTargetHidden\n show={open}\n target={buttonEl}\n ref={setPopoverRef}\n >\n <Menu\n items={items}\n scrollAt={20}\n onItemClick={() => setOpen(false)}\n focusControlEl={buttonEl || undefined}\n focusElOnClose={false}\n />\n </StyledBranchButtonPopover>\n </>\n );\n};\n\nexport default BranchButton;\n"]}
@@ -1,4 +0,0 @@
1
- export { default } from './AppHeader';
2
- export { default as BranchButton, BranchButtonProps } from './BranchButton';
3
- export { AppHeaderProps } from './AppHeader.types';
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/AppHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAC5E,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC"}
@@ -1,3 +0,0 @@
1
- export { default } from './AppHeader';
2
- export { default as BranchButton } from './BranchButton';
3
- //# sourceMappingURL=index.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/AppHeader/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC;AACtC,OAAO,EAAE,OAAO,IAAI,YAAY,EAAqB,MAAM,gBAAgB,CAAC","sourcesContent":["export { default } from './AppHeader';\nexport { default as BranchButton, BranchButtonProps } from './BranchButton';\nexport { AppHeaderProps } from './AppHeader.types';\n"]}
@@ -1,9 +0,0 @@
1
- import { Text, Flex, OneColumnPage } from '@pega/cosmos-react-core';
2
- export declare const StyledBanner: import("styled-components").StyledComponent<"article", import("styled-components").DefaultTheme, {}, never>;
3
- export declare const StyledBannerInfo: typeof Flex;
4
- export declare const StyledImageContainer: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
5
- export declare const StyledSummaryCardList: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
6
- export declare const StyledHeading: typeof Text;
7
- export declare const StyledDescription: typeof Text;
8
- export declare const StyledGalleryPage: typeof OneColumnPage;
9
- //# sourceMappingURL=GalleryPage.styles.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GalleryPage.styles.d.ts","sourceRoot":"","sources":["../../../src/components/PageTemplates/GalleryPage.styles.ts"],"names":[],"mappings":"AAGA,OAAO,EACL,IAAI,EAGJ,IAAI,EAEJ,aAAa,EAEd,MAAM,yBAAyB,CAAC;AAEjC,eAAO,MAAM,YAAY,6GAcvB,CAAC;AAIH,eAAO,MAAM,gBAAgB,EAAE,OAAO,IAqBpC,CAAC;AAIH,eAAO,MAAM,oBAAoB,yGAQhC,CAAC;AAEF,eAAO,MAAM,qBAAqB,yGAIhC,CAAC;AAIH,eAAO,MAAM,aAAa,EAAE,OAAO,IAIlC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,OAAO,IAKtC,CAAC;AAEF,eAAO,MAAM,iBAAiB,EAAE,OAAO,aAStC,CAAC"}
@@ -1,70 +0,0 @@
1
- import styled, { css } from 'styled-components';
2
- import { readableColor } from 'polished';
3
- import { Text, StyledButton, tryCatch, Flex, defaultThemeProp, OneColumnPage, StyledRegion } from '@pega/cosmos-react-core';
4
- export const StyledBanner = styled.article(({ theme }) => {
5
- const { base: { palette: { 'brand-primary': brandBackground } } } = theme;
6
- const color = tryCatch(() => readableColor(brandBackground));
7
- return css `
8
- background: ${brandBackground};
9
- color: ${color};
10
- height: 11rem;
11
- `;
12
- });
13
- StyledBanner.defaultProps = defaultThemeProp;
14
- export const StyledBannerInfo = styled(Flex)(({ theme }) => {
15
- const { base: { spacing, shadow } } = theme;
16
- return css `
17
- padding-inline-start: calc(5 * ${spacing});
18
- max-width: 50%;
19
-
20
- ${StyledButton} {
21
- margin-block-start: calc(2 * ${spacing});
22
- &:enabled:focus,
23
- &:not([disabled]):focus {
24
- box-shadow: ${shadow.focus};
25
- }
26
- }
27
-
28
- span {
29
- margin-block-start: ${spacing};
30
- }
31
- `;
32
- });
33
- StyledBannerInfo.defaultProps = defaultThemeProp;
34
- export const StyledImageContainer = styled.div `
35
- padding: 0;
36
- height: 100%;
37
- max-width: 50%;
38
- img {
39
- object-fit: contain;
40
- height: 100%;
41
- }
42
- `;
43
- export const StyledSummaryCardList = styled.div(({ theme }) => {
44
- return css `
45
- margin-block-start: calc(2 * ${theme.base.spacing});
46
- `;
47
- });
48
- StyledSummaryCardList.defaultProps = defaultThemeProp;
49
- export const StyledHeading = styled(Text) `
50
- text-overflow: ellipsis;
51
- white-space: nowrap;
52
- overflow: hidden;
53
- `;
54
- export const StyledDescription = styled(Text) `
55
- display: -webkit-box;
56
- -webkit-box-orient: vertical;
57
- -webkit-line-clamp: 2;
58
- overflow: hidden;
59
- `;
60
- export const StyledGalleryPage = styled(OneColumnPage) `
61
- gap: 0;
62
- & > header {
63
- padding: 0;
64
- }
65
-
66
- ${StyledRegion} {
67
- height: 100%;
68
- }
69
- `;
70
- //# sourceMappingURL=GalleryPage.styles.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"GalleryPage.styles.js","sourceRoot":"","sources":["../../../src/components/PageTemplates/GalleryPage.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,OAAO,EACL,IAAI,EACJ,YAAY,EACZ,QAAQ,EACR,IAAI,EACJ,gBAAgB,EAChB,aAAa,EACb,YAAY,EACb,MAAM,yBAAyB,CAAC;AAEjC,MAAM,CAAC,MAAM,YAAY,GAAG,MAAM,CAAC,OAAO,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACvD,MAAM,EACJ,IAAI,EAAE,EACJ,OAAO,EAAE,EAAE,eAAe,EAAE,eAAe,EAAE,EAC9C,EACF,GAAG,KAAK,CAAC;IAEV,MAAM,KAAK,GAAG,QAAQ,CAAC,GAAG,EAAE,CAAC,aAAa,CAAC,eAAe,CAAC,CAAC,CAAC;IAE7D,OAAO,GAAG,CAAA;kBACM,eAAe;aACpB,KAAK;;GAEf,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,YAAY,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE7C,MAAM,CAAC,MAAM,gBAAgB,GAAgB,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACtE,MAAM,EACJ,IAAI,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,EAC1B,GAAG,KAAK,CAAC;IAEV,OAAO,GAAG,CAAA;qCACyB,OAAO;;;MAGtC,YAAY;qCACmB,OAAO;;;sBAGtB,MAAM,CAAC,KAAK;;;;;4BAKN,OAAO;;GAEhC,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,gBAAgB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEjD,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;CAQ7C,CAAC;AAEF,MAAM,CAAC,MAAM,qBAAqB,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC5D,OAAO,GAAG,CAAA;mCACuB,KAAK,CAAC,IAAI,CAAC,OAAO;GAClD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,qBAAqB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEtD,MAAM,CAAC,MAAM,aAAa,GAAgB,MAAM,CAAC,IAAI,CAAC,CAAA;;;;CAIrD,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAgB,MAAM,CAAC,IAAI,CAAC,CAAA;;;;;CAKzD,CAAC;AAEF,MAAM,CAAC,MAAM,iBAAiB,GAAyB,MAAM,CAAC,aAAa,CAAC,CAAA;;;;;;IAMxE,YAAY;;;CAGf,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { readableColor } from 'polished';\n\nimport {\n Text,\n StyledButton,\n tryCatch,\n Flex,\n defaultThemeProp,\n OneColumnPage,\n StyledRegion\n} from '@pega/cosmos-react-core';\n\nexport const StyledBanner = styled.article(({ theme }) => {\n const {\n base: {\n palette: { 'brand-primary': brandBackground }\n }\n } = theme;\n\n const color = tryCatch(() => readableColor(brandBackground));\n\n return css`\n background: ${brandBackground};\n color: ${color};\n height: 11rem;\n `;\n});\n\nStyledBanner.defaultProps = defaultThemeProp;\n\nexport const StyledBannerInfo: typeof Flex = styled(Flex)(({ theme }) => {\n const {\n base: { spacing, shadow }\n } = theme;\n\n return css`\n padding-inline-start: calc(5 * ${spacing});\n max-width: 50%;\n\n ${StyledButton} {\n margin-block-start: calc(2 * ${spacing});\n &:enabled:focus,\n &:not([disabled]):focus {\n box-shadow: ${shadow.focus};\n }\n }\n\n span {\n margin-block-start: ${spacing};\n }\n `;\n});\n\nStyledBannerInfo.defaultProps = defaultThemeProp;\n\nexport const StyledImageContainer = styled.div`\n padding: 0;\n height: 100%;\n max-width: 50%;\n img {\n object-fit: contain;\n height: 100%;\n }\n`;\n\nexport const StyledSummaryCardList = styled.div(({ theme }) => {\n return css`\n margin-block-start: calc(2 * ${theme.base.spacing});\n `;\n});\n\nStyledSummaryCardList.defaultProps = defaultThemeProp;\n\nexport const StyledHeading: typeof Text = styled(Text)`\n text-overflow: ellipsis;\n white-space: nowrap;\n overflow: hidden;\n`;\n\nexport const StyledDescription: typeof Text = styled(Text)`\n display: -webkit-box;\n -webkit-box-orient: vertical;\n -webkit-line-clamp: 2;\n overflow: hidden;\n`;\n\nexport const StyledGalleryPage: typeof OneColumnPage = styled(OneColumnPage)`\n gap: 0;\n & > header {\n padding: 0;\n }\n\n ${StyledRegion} {\n height: 100%;\n }\n`;\n"]}