@pega/cosmos-react-core 9.14.0 → 9.15.1

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 (83) hide show
  1. package/lib/components/AppShell/AppHeader.styles.js +1 -1
  2. package/lib/components/AppShell/AppHeader.styles.js.map +1 -1
  3. package/lib/components/AppShell/AppNavigationPanel.d.ts.map +1 -1
  4. package/lib/components/AppShell/AppNavigationPanel.js +3 -3
  5. package/lib/components/AppShell/AppNavigationPanel.js.map +1 -1
  6. package/lib/components/AppShell/AppShell.d.ts.map +1 -1
  7. package/lib/components/AppShell/AppShell.js +7 -17
  8. package/lib/components/AppShell/AppShell.js.map +1 -1
  9. package/lib/components/AppShell/AppShell.styles.d.ts +4 -6
  10. package/lib/components/AppShell/AppShell.styles.d.ts.map +1 -1
  11. package/lib/components/AppShell/AppShell.styles.js +42 -81
  12. package/lib/components/AppShell/AppShell.styles.js.map +1 -1
  13. package/lib/components/AppShell/AppTopNav.styles.d.ts.map +1 -1
  14. package/lib/components/AppShell/AppTopNav.styles.js +2 -2
  15. package/lib/components/AppShell/AppTopNav.styles.js.map +1 -1
  16. package/lib/components/AppShell/Drawer.d.ts +1 -2
  17. package/lib/components/AppShell/Drawer.d.ts.map +1 -1
  18. package/lib/components/AppShell/Drawer.js +4 -4
  19. package/lib/components/AppShell/Drawer.js.map +1 -1
  20. package/lib/components/AppShell/Drawer.styles.d.ts +1 -13
  21. package/lib/components/AppShell/Drawer.styles.d.ts.map +1 -1
  22. package/lib/components/AppShell/Drawer.styles.js +15 -31
  23. package/lib/components/AppShell/Drawer.styles.js.map +1 -1
  24. package/lib/components/Backdrop/Backdrop.js +1 -1
  25. package/lib/components/Backdrop/Backdrop.js.map +1 -1
  26. package/lib/components/ClassificationMarking/ClassificationMarking.styles.d.ts.map +1 -1
  27. package/lib/components/ClassificationMarking/ClassificationMarking.styles.js +5 -32
  28. package/lib/components/ClassificationMarking/ClassificationMarking.styles.js.map +1 -1
  29. package/lib/components/Fullscreen/Fullscreen.js +2 -2
  30. package/lib/components/Fullscreen/Fullscreen.js.map +1 -1
  31. package/lib/components/Lightbox/Lightbox.styles.d.ts.map +1 -1
  32. package/lib/components/Lightbox/Lightbox.styles.js +1 -0
  33. package/lib/components/Lightbox/Lightbox.styles.js.map +1 -1
  34. package/lib/components/PageTemplates/CategorySubPage.styles.js +1 -1
  35. package/lib/components/PageTemplates/CategorySubPage.styles.js.map +1 -1
  36. package/lib/components/PageTemplates/DashboardPage.js +1 -1
  37. package/lib/components/PageTemplates/DashboardPage.js.map +1 -1
  38. package/lib/components/Preview/PreviewPanel.d.ts.map +1 -1
  39. package/lib/components/Preview/PreviewPanel.js +7 -2
  40. package/lib/components/Preview/PreviewPanel.js.map +1 -1
  41. package/lib/components/Progress/Progress.d.ts.map +1 -1
  42. package/lib/components/Progress/Progress.js +39 -7
  43. package/lib/components/Progress/Progress.js.map +1 -1
  44. package/lib/components/Progress/Progress.types.d.ts +10 -4
  45. package/lib/components/Progress/Progress.types.d.ts.map +1 -1
  46. package/lib/components/Progress/Progress.types.js.map +1 -1
  47. package/lib/components/Scanner/Scanner.d.ts +21 -0
  48. package/lib/components/Scanner/Scanner.d.ts.map +1 -0
  49. package/lib/components/Scanner/Scanner.js +177 -0
  50. package/lib/components/Scanner/Scanner.js.map +1 -0
  51. package/lib/components/Scanner/Scanner.styles.d.ts +4 -0
  52. package/lib/components/Scanner/Scanner.styles.d.ts.map +1 -0
  53. package/lib/components/Scanner/Scanner.styles.js +17 -0
  54. package/lib/components/Scanner/Scanner.styles.js.map +1 -0
  55. package/lib/components/Scanner/Scanner.test-ids.d.ts +2 -0
  56. package/lib/components/Scanner/Scanner.test-ids.d.ts.map +1 -0
  57. package/lib/components/Scanner/Scanner.test-ids.js +3 -0
  58. package/lib/components/Scanner/Scanner.test-ids.js.map +1 -0
  59. package/lib/components/Scanner/index.d.ts +3 -0
  60. package/lib/components/Scanner/index.d.ts.map +1 -0
  61. package/lib/components/Scanner/index.js +2 -0
  62. package/lib/components/Scanner/index.js.map +1 -0
  63. package/lib/hooks/index.d.ts +1 -0
  64. package/lib/hooks/index.d.ts.map +1 -1
  65. package/lib/hooks/index.js +1 -0
  66. package/lib/hooks/index.js.map +1 -1
  67. package/lib/hooks/useComputedLengthPx.d.ts +10 -0
  68. package/lib/hooks/useComputedLengthPx.d.ts.map +1 -0
  69. package/lib/hooks/useComputedLengthPx.js +46 -0
  70. package/lib/hooks/useComputedLengthPx.js.map +1 -0
  71. package/lib/hooks/useI18n.d.ts +7 -0
  72. package/lib/hooks/useI18n.d.ts.map +1 -1
  73. package/lib/i18n/default.d.ts +7 -0
  74. package/lib/i18n/default.d.ts.map +1 -1
  75. package/lib/i18n/default.js +7 -0
  76. package/lib/i18n/default.js.map +1 -1
  77. package/lib/i18n/i18n.d.ts +7 -0
  78. package/lib/i18n/i18n.d.ts.map +1 -1
  79. package/lib/index.d.ts +2 -0
  80. package/lib/index.d.ts.map +1 -1
  81. package/lib/index.js +2 -0
  82. package/lib/index.js.map +1 -1
  83. package/package.json +2 -1
@@ -1,17 +1,5 @@
1
1
  import type { DrawerProps } from '../Drawer';
2
- export declare const StyledDrawerWrapper: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, DrawerProps & {
3
- topOffset: string;
4
- }>> & string;
5
- /**
6
- * Fixed-position container that offsets the drawer below the top chrome
7
- * (AppShell header + top nav bar) so the drawer doesn't overlap the navigation.
8
- * The inner Drawer uses position='absolute' relative to this container.
9
- * Uses inset-block-end: 0 to pin to the viewport bottom, avoiding dvh unit
10
- * rounding issues and ensuring the drawer always fills the available height.
11
- */
12
- export declare const StyledTopNavDrawerOffset: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
13
- $topOffset: string;
14
- }>> & string;
2
+ export declare const StyledDrawerWrapper: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, DrawerProps>> & string;
15
3
  export declare const StyledDrawerHeading: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, never>> & string;
16
4
  export declare const StyledDrawerList: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, {
17
5
  displayPins: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"Drawer.styles.d.ts","sourceRoot":"","sources":["../../../src/components/AppShell/Drawer.styles.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAQ7C,eAAO,MAAM,mBAAmB;eAAyC,MAAM;YA6B9E,CAAC;AAIF;;;;;;GAMG;AACH,eAAO,MAAM,wBAAwB;gBAA4B,MAAM;YAStE,CAAC;AAIF,eAAO,MAAM,mBAAmB,uNAsB9B,CAAC;AAIH,eAAO,MAAM,gBAAgB;iBAA4B,OAAO;YAE9D,CAAC;AAIH,eAAO,MAAM,oBAAoB,iOAIhC,CAAC;AAEF,eAAO,MAAM,iBAAiB,6NAK5B,CAAC;AAIH,eAAO,MAAM,uBAAuB,qOAWlC,CAAC;AAIH,eAAO,MAAM,mBAAmB,yOAiB9B,CAAC;AAIH,eAAO,MAAM,uBAAuB,6NAOlC,CAAC;AAIH,eAAO,MAAM,yBAAyB,6NAMpC,CAAC"}
1
+ {"version":3,"file":"Drawer.styles.d.ts","sourceRoot":"","sources":["../../../src/components/AppShell/Drawer.styles.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAC;AAQ7C,eAAO,MAAM,mBAAmB,gPA2B9B,CAAC;AAIH,eAAO,MAAM,mBAAmB,uNAsB9B,CAAC;AAIH,eAAO,MAAM,gBAAgB;iBAA4B,OAAO;YAE9D,CAAC;AAIH,eAAO,MAAM,oBAAoB,iOAIhC,CAAC;AAEF,eAAO,MAAM,iBAAiB,6NAK5B,CAAC;AAIH,eAAO,MAAM,uBAAuB,qOAWlC,CAAC;AAIH,eAAO,MAAM,mBAAmB,yOAiB9B,CAAC;AAIH,eAAO,MAAM,uBAAuB,6NAOlC,CAAC;AAIH,eAAO,MAAM,yBAAyB,6NAMpC,CAAC"}
@@ -7,44 +7,28 @@ import { StyledLabel } from '../Label';
7
7
  import { StyledForm } from '../MultiStepForm/MultiStepForm';
8
8
  import { navOpenWidth } from './AppShell.styles';
9
9
  import { navContrastColors } from './style-utils';
10
- export const StyledDrawerWrapper = styled.div(({ theme, open, topOffset }) => {
10
+ export const StyledDrawerWrapper = styled.div(({ theme, open }) => {
11
11
  const { components: { 'app-shell': { nav: { background: navBg } } } } = theme;
12
12
  const { foreground, border: borderColor } = navContrastColors(theme);
13
13
  return css `
14
- display: flex;
15
- flex-direction: column;
16
- background: ${navBg};
17
- width: calc(${navOpenWidth} + var(--safe-area-inset-inline-start, 0rem));
18
- height: unset;
19
- inset-block: ${topOffset} 0;
20
- color: ${foreground};
21
- opacity: ${open ? 1 : 0};
22
- border-inline-end: ${rem(1)} solid ${borderColor};
14
+ display: flex;
15
+ flex-direction: column;
16
+ background: ${navBg};
17
+ width: calc(${navOpenWidth} + var(--safe-area-inset-inline-start, 0rem));
18
+ height: unset;
19
+ inset-block: var(--appshell-top-offset, 0) var(--appshell-bottom-offset, 0);
20
+ color: ${foreground};
21
+ opacity: ${open ? 1 : 0};
22
+ border-inline-end: ${rem(1)} solid ${borderColor};
23
23
 
24
- ${StyledForm},
25
- ${StyledLabel},
24
+ ${StyledForm},
25
+ ${StyledLabel},
26
26
  ${StyledMetaListItem} {
27
- color: ${foreground};
28
- }
29
- `;
27
+ color: ${foreground};
28
+ }
29
+ `;
30
30
  });
31
31
  StyledDrawerWrapper.defaultProps = defaultThemeProp;
32
- /**
33
- * Fixed-position container that offsets the drawer below the top chrome
34
- * (AppShell header + top nav bar) so the drawer doesn't overlap the navigation.
35
- * The inner Drawer uses position='absolute' relative to this container.
36
- * Uses inset-block-end: 0 to pin to the viewport bottom, avoiding dvh unit
37
- * rounding issues and ensuring the drawer always fills the available height.
38
- */
39
- export const StyledTopNavDrawerOffset = styled.div(({ $topOffset, theme }) => css `
40
- position: fixed;
41
- inset-block-start: ${$topOffset};
42
- inset-inline-start: 0;
43
- inset-block-end: 0;
44
- width: ${navOpenWidth};
45
- z-index: ${theme.base['z-index'].drawer};
46
- `);
47
- StyledTopNavDrawerOffset.defaultProps = defaultThemeProp;
48
32
  export const StyledDrawerHeading = styled.header(({ theme }) => {
49
33
  const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);
50
34
  const { foreground } = navContrastColors(theme);
@@ -1 +1 @@
1
- {"version":3,"file":"Drawer.styles.js","sourceRoot":"","sources":["../../../src/components/AppShell/Drawer.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,gCAAgC,CAAC;AAE5D,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAElD,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,GAAG,CAC3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,MAAM,mBAAmB,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACxD,MAAM,EAAE,UAAU,EAAE,gBAAgB,EAAE,GAAG,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAElE,OAAO,GAAG,CAAA;;;eAGG,KAAK,CAAC,IAAI,CAAC,OAAO;aACpB,UAAU;kBACL,gBAAgB;;;;;;oBAMd,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC;;GAEjD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,mBAAmB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEpD,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC9D,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEzD,OAAO,GAAG,CAAA;kCACsB,WAAW;;GAE1C,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,uBAAuB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAExD,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE;IACvD,OAAO,GAAG,CAAA;;;;GAIT,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,yBAAyB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { rem } from 'polished';\n\nimport { calculateFontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\nimport type { DrawerProps } from '../Drawer';\nimport { StyledMetaListItem } from '../MetaList/MetaList';\nimport { StyledLabel } from '../Label';\nimport { StyledForm } from '../MultiStepForm/MultiStepForm';\n\nimport { navOpenWidth } from './AppShell.styles';\nimport { navContrastColors } from './style-utils';\n\nexport const StyledDrawerWrapper = styled.div<DrawerProps & { topOffset: string }>(\n ({ theme, open, topOffset }) => {\n const {\n components: {\n 'app-shell': {\n nav: { background: navBg }\n }\n }\n } = theme;\n const { foreground, border: borderColor } = navContrastColors(theme);\n\n return css`\n display: flex;\n flex-direction: column;\n background: ${navBg};\n width: calc(${navOpenWidth} + var(--safe-area-inset-inline-start, 0rem));\n height: unset;\n inset-block: ${topOffset} 0;\n color: ${foreground};\n opacity: ${open ? 1 : 0};\n border-inline-end: ${rem(1)} solid ${borderColor};\n\n ${StyledForm},\n ${StyledLabel},\n ${StyledMetaListItem} {\n color: ${foreground};\n }\n `;\n }\n);\n\nStyledDrawerWrapper.defaultProps = defaultThemeProp;\n\n/**\n * Fixed-position container that offsets the drawer below the top chrome\n * (AppShell header + top nav bar) so the drawer doesn't overlap the navigation.\n * The inner Drawer uses position='absolute' relative to this container.\n * Uses inset-block-end: 0 to pin to the viewport bottom, avoiding dvh unit\n * rounding issues and ensuring the drawer always fills the available height.\n */\nexport const StyledTopNavDrawerOffset = styled.div<{ $topOffset: string }>(\n ({ $topOffset, theme }) => css`\n position: fixed;\n inset-block-start: ${$topOffset};\n inset-inline-start: 0;\n inset-block-end: 0;\n width: ${navOpenWidth};\n z-index: ${theme.base['z-index'].drawer};\n `\n);\n\nStyledTopNavDrawerOffset.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerHeading = styled.header(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n const { foreground } = navContrastColors(theme);\n\n return css`\n padding: ${theme.base.spacing} calc(2 * ${theme.base.spacing});\n line-height: 1;\n\n h2 {\n font-size: ${fontSize.s};\n font-weight: ${theme.base['font-weight']['semi-bold']};\n margin: 0 auto;\n position: relative;\n left: -0.7rem;\n }\n\n svg {\n font-size: ${fontSize.xxl};\n cursor: pointer;\n color: ${foreground};\n }\n `;\n});\n\nStyledDrawerHeading.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerList = styled.ul<{ displayPins: boolean }>(() => {\n return css``;\n});\n\nStyledDrawerList.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerMetaList = styled.ul`\n li {\n color: inherit;\n }\n`;\n\nexport const EmptyDrawerVisual = styled.div(({ theme }) => {\n return css`\n width: calc(4 * ${theme.base.spacing});\n height: calc(4 * ${theme.base.spacing});\n `;\n});\n\nEmptyDrawerVisual.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListHeading = styled.h3(({ theme }) => {\n const { hoverBg, foreground } = navContrastColors(theme);\n\n return css`\n position: sticky;\n top: 0;\n padding: ${theme.base.spacing} calc(2 * ${theme.base.spacing});\n background-color: ${hoverBg};\n color: ${foreground};\n z-index: 1;\n `;\n});\n\nStyledDrawerListHeading.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerViewAll = styled.a(({ theme }) => {\n const { foreground, nestedListHeader } = navContrastColors(theme);\n\n return css`\n position: sticky;\n bottom: 0;\n padding: ${theme.base.spacing} 0;\n color: ${foreground};\n background: ${nestedListHeader};\n text-align: center;\n margin-top: 0.0625rem;\n\n &:focus-visible {\n outline: none;\n box-shadow: ${theme.base.shadow['focus-inset']};\n }\n `;\n});\n\nStyledDrawerViewAll.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListSection = styled.div(({ theme }) => {\n const { border: borderColor } = navContrastColors(theme);\n\n return css`\n border-top: 0.0625rem solid ${borderColor};\n min-height: max(20%, 8rem);\n `;\n});\n\nStyledDrawerListSection.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListContainer = styled.div(() => {\n return css`\n flex: 1;\n min-height: 0;\n overflow-y: auto;\n `;\n});\n\nStyledDrawerListContainer.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"Drawer.styles.js","sourceRoot":"","sources":["../../../src/components/AppShell/Drawer.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AAE/B,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD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C,YAAY,GAAG,gBAAgB,CAAC;AAExD,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACxD,MAAM,EAAE,UAAU,EAAE,gBAAgB,EAAE,GAAG,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAElE,OAAO,GAAG,CAAA;;;eAGG,KAAK,CAAC,IAAI,CAAC,OAAO;aACpB,UAAU;kBACL,gBAAgB;;;;;;oBAMd,KAAK,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC;;GAEjD,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,mBAAmB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAEpD,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC9D,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,iBAAiB,CAAC,KAAK,CAAC,CAAC;IAEzD,OAAO,GAAG,CAAA;kCACsB,WAAW;;GAE1C,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,uBAAuB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAExD,MAAM,CAAC,MAAM,yBAAyB,GAAG,MAAM,CAAC,GAAG,CAAC,GAAG,EAAE;IACvD,OAAO,GAAG,CAAA;;;;GAIT,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,yBAAyB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { rem } from 'polished';\n\nimport { calculateFontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\nimport type { DrawerProps } from '../Drawer';\nimport { StyledMetaListItem } from '../MetaList/MetaList';\nimport { StyledLabel } from '../Label';\nimport { StyledForm } from '../MultiStepForm/MultiStepForm';\n\nimport { navOpenWidth } from './AppShell.styles';\nimport { navContrastColors } from './style-utils';\n\nexport const StyledDrawerWrapper = styled.div<DrawerProps>(({ theme, open }) => {\n const {\n components: {\n 'app-shell': {\n nav: { background: navBg }\n }\n }\n } = theme;\n const { foreground, border: borderColor } = navContrastColors(theme);\n\n return css`\n display: flex;\n flex-direction: column;\n background: ${navBg};\n width: calc(${navOpenWidth} + var(--safe-area-inset-inline-start, 0rem));\n height: unset;\n inset-block: var(--appshell-top-offset, 0) var(--appshell-bottom-offset, 0);\n color: ${foreground};\n opacity: ${open ? 1 : 0};\n border-inline-end: ${rem(1)} solid ${borderColor};\n\n ${StyledForm},\n ${StyledLabel},\n ${StyledMetaListItem} {\n color: ${foreground};\n }\n `;\n});\n\nStyledDrawerWrapper.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerHeading = styled.header(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n const { foreground } = navContrastColors(theme);\n\n return css`\n padding: ${theme.base.spacing} calc(2 * ${theme.base.spacing});\n line-height: 1;\n\n h2 {\n font-size: ${fontSize.s};\n font-weight: ${theme.base['font-weight']['semi-bold']};\n margin: 0 auto;\n position: relative;\n left: -0.7rem;\n }\n\n svg {\n font-size: ${fontSize.xxl};\n cursor: pointer;\n color: ${foreground};\n }\n `;\n});\n\nStyledDrawerHeading.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerList = styled.ul<{ displayPins: boolean }>(() => {\n return css``;\n});\n\nStyledDrawerList.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerMetaList = styled.ul`\n li {\n color: inherit;\n }\n`;\n\nexport const EmptyDrawerVisual = styled.div(({ theme }) => {\n return css`\n width: calc(4 * ${theme.base.spacing});\n height: calc(4 * ${theme.base.spacing});\n `;\n});\n\nEmptyDrawerVisual.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListHeading = styled.h3(({ theme }) => {\n const { hoverBg, foreground } = navContrastColors(theme);\n\n return css`\n position: sticky;\n top: 0;\n padding: ${theme.base.spacing} calc(2 * ${theme.base.spacing});\n background-color: ${hoverBg};\n color: ${foreground};\n z-index: 1;\n `;\n});\n\nStyledDrawerListHeading.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerViewAll = styled.a(({ theme }) => {\n const { foreground, nestedListHeader } = navContrastColors(theme);\n\n return css`\n position: sticky;\n bottom: 0;\n padding: ${theme.base.spacing} 0;\n color: ${foreground};\n background: ${nestedListHeader};\n text-align: center;\n margin-top: 0.0625rem;\n\n &:focus-visible {\n outline: none;\n box-shadow: ${theme.base.shadow['focus-inset']};\n }\n `;\n});\n\nStyledDrawerViewAll.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListSection = styled.div(({ theme }) => {\n const { border: borderColor } = navContrastColors(theme);\n\n return css`\n border-top: 0.0625rem solid ${borderColor};\n min-height: max(20%, 8rem);\n `;\n});\n\nStyledDrawerListSection.defaultProps = defaultThemeProp;\n\nexport const StyledDrawerListContainer = styled.div(() => {\n return css`\n flex: 1;\n min-height: 0;\n overflow-y: auto;\n `;\n});\n\nStyledDrawerListContainer.defaultProps = defaultThemeProp;\n"]}
@@ -21,7 +21,7 @@ export const StyledBackdrop = styled(Flex)(props => {
21
21
  position: ${position};
22
22
  z-index: ${position === 'fixed' ? base['z-index'].backdrop : base['z-index'].popover + 1};
23
23
  inset-inline: 0;
24
- inset-block-start: ${position === 'fixed' ? 'var(--appshell-top-offset, 0rem)' : '0'};
24
+ inset-block-start: ${position === 'fixed' ? 'var(--appshell-hard-top-offset, 0rem)' : '0'};
25
25
  inset-block-end: 0;
26
26
  padding-block-end: ${position === 'fixed' ? 'var(--appshell-hard-bottom-offset, 0rem)' : '0'};
27
27
  border-radius: inherit;
@@ -1 +1 @@
1
- {"version":3,"file":"Backdrop.js","sourceRoot":"","sources":["../../../src/components/Backdrop/Backdrop.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAErE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;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C,KAAC,aAAa,IAAC,YAAY,EAAE,UAAU,IAAI,SAAS,YAClD,KAAC,cAAc,mBACA,OAAO,CAAC,IAAI,EACzB,SAAS,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,SAAS,EAAE,EACpE,eAAe,EAAE,eAAe,EAChC,OAAO,EAAE,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EACxD,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,QAAQ,EAClB,eAAe,EAAE,eAAe,EAChC,GAAG,EAAE,WAAW,KACZ,SAAS,YAEZ,QAAQ,GACM,GACH,CACjB,CAAC;AACJ,CAAC,CAAC,EACF,kBAAkB,CACnB,CAAC","sourcesContent":["import { useEffect, useState, useCallback, forwardRef } from 'react';\nimport type { PropsWithoutRef, TransitionEvent } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { defaultThemeProp } from '../../theme';\nimport { reflow, withTestIds } from '../../utils';\nimport type {\n PropsWithDefaults,\n ExcludeStrict,\n WithAttributes,\n RefElement,\n TestIdProp,\n OmitStrict\n} from '../../types';\nimport Configuration from '../Configuration';\nimport Flex from '../Flex';\nimport type { FlexProps } from '../Flex';\nimport { useConsolidatedRef, useElement, useTestIds } from '../../hooks';\n\nimport { getBackdropTestIds } from './Backdrop.test-ids';\n\nexport type BackdropProps = WithAttributes<\n 'div',\n TestIdProp & {\n /**\n * Opacity of the Backdrop.\n * @default 0.4\n */\n alpha?: number;\n /** Props passed to Flex container. */\n container?: ExcludeStrict<FlexProps['container'], true>;\n /**\n * Toggles visibility of Backdrop.\n * @default false\n */\n open?: boolean;\n /**\n * Determines the color of the Backdrop.\n * @default 'dark'\n */\n variant?: 'dark' | 'light';\n /**\n * Transition speed of Backdrop animation.\n * @default 'medium'\n */\n transitionSpeed?: 'slow' | 'medium' | 'fast' | 'none';\n /**\n * The position of the Backdrop.\n * @default 'fixed'\n */\n position?: 'absolute' | 'fixed';\n /** Accepts a callback that gets invoked before opening Backdrop. */\n onBeforeTransitionIn?: () => void;\n /** Accepts a callback that gets invoked after opening Backdrop. */\n onAfterTransitionIn?: () => void;\n /** Accepts a callback that gets invoked before closing Backdrop. */\n onBeforeTransitionOut?: () => void;\n /** Accepts a callback that gets invoked after closing Backdrop */\n onAfterTransitionOut?: () => void;\n }\n>;\n\ntype BackdropPropsWithDefaults = PropsWithDefaults<\n BackdropProps,\n 'open' | 'transitionSpeed' | 'alpha' | 'position'\n>;\n\nconst transitionSpeedToTheme = {\n slow: 2,\n medium: 1,\n fast: 0.5,\n none: 0\n} as const;\n\nexport const StyledBackdrop = styled(Flex)<\n OmitStrict<BackdropPropsWithDefaults, 'open'> & { opacity: 0 | 1 }\n>(props => {\n const {\n theme: { base }\n } = props;\n const { opacity, alpha, variant, position } = props;\n const transitionDuration = `max(calc(${transitionSpeedToTheme[props.transitionSpeed]} * ${\n base.animation.speed\n }), 1ms)`;\n\n return css`\n position: ${position};\n z-index: ${position === 'fixed' ? base['z-index'].backdrop : base['z-index'].popover + 1};\n inset-inline: 0;\n inset-block-start: ${position === 'fixed' ? 'var(--appshell-top-offset, 0rem)' : '0'};\n inset-block-end: 0;\n padding-block-end: ${position === 'fixed' ? 'var(--appshell-hard-bottom-offset, 0rem)' : '0'};\n border-radius: inherit;\n opacity: ${opacity};\n transition-property: opacity;\n transition-timing-function: ${props.theme.base.animation.timing.ease};\n /* stylelint-disable declaration-block-no-duplicate-properties */\n transition-duration: 1ms;\n transition-duration: ${transitionDuration};\n /* stylelint-enable declaration-block-no-duplicate-properties */\n\n ${variant === 'dark' &&\n css`\n background: rgba(0, 0, 0, ${alpha});\n `}\n\n ${variant === 'light' &&\n css`\n background: rgba(255, 255, 255, ${alpha});\n `}\n `;\n});\n\nStyledBackdrop.defaultProps = defaultThemeProp;\n\ntype State = 'closed' | 'opening' | 'open' | 'closing';\n\nexport default withTestIds(\n forwardRef<RefElement<BackdropProps>, PropsWithoutRef<BackdropProps>>(function Backdrop(\n {\n testId,\n children,\n container,\n open = false,\n variant = 'dark',\n transitionSpeed = 'medium',\n alpha = 0.6,\n position = 'fixed',\n onBeforeTransitionIn,\n onAfterTransitionIn,\n onBeforeTransitionOut,\n onAfterTransitionOut,\n ...restProps\n },\n ref\n ) {\n const testIds = useTestIds(testId, getBackdropTestIds);\n const [state, setState] = useState<State>('closed');\n const [backdropEl, setBackdropEl] = useElement<HTMLDivElement>();\n const backdropRef = useConsolidatedRef(ref, setBackdropEl);\n\n const onTransitionEnd = useCallback(\n (e: TransitionEvent) => {\n if (e.propertyName !== 'opacity' || e.target !== e.currentTarget) return;\n let nextState: State;\n\n if (state === 'closing') {\n nextState = 'closed';\n onAfterTransitionOut?.();\n } else {\n nextState = 'open';\n onAfterTransitionIn?.();\n }\n\n setState(nextState);\n },\n [state, onAfterTransitionOut, onAfterTransitionIn]\n );\n\n useEffect(() => {\n if (open) {\n if (state === 'closed' || state === 'closing') {\n onBeforeTransitionIn?.();\n reflow();\n setState('opening');\n }\n } else if (state === 'open' || state === 'opening') {\n onBeforeTransitionOut?.();\n setState('closing');\n }\n }, [open]);\n\n // Using a separate effect instead of combined logic above as it seems more intuitive to mentally manage.\n useEffect(() => {\n if (!backdropRef.current) return;\n const opacity = window.getComputedStyle(backdropRef.current).opacity;\n // If the opacity is already at the destination value, sync the state value.\n if (state === 'closing' && opacity === '0') {\n // Since the transition never ran, we have to pretend it did and call the callback.\n // TODO: This maybe can be fixed with the animation api\n onAfterTransitionOut?.();\n setState('closed');\n }\n if (state === 'opening' && opacity === '1') {\n // ditto, see above...\n onAfterTransitionIn?.();\n setState('open');\n }\n }, [state]);\n\n return !open && state === 'closed' ? null : (\n <Configuration portalTarget={backdropEl ?? undefined}>\n <StyledBackdrop\n data-testid={testIds.root}\n container={{ justify: 'center', alignItems: 'center', ...container }}\n transitionSpeed={transitionSpeed}\n opacity={state === 'opening' || state === 'open' ? 1 : 0}\n alpha={alpha}\n variant={variant}\n position={position}\n onTransitionEnd={onTransitionEnd}\n ref={backdropRef}\n {...restProps}\n >\n {children}\n </StyledBackdrop>\n </Configuration>\n );\n }),\n getBackdropTestIds\n);\n"]}
1
+ {"version":3,"file":"Backdrop.js","sourceRoot":"","sources":["../../../src/components/Backdrop/Backdrop.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,SAAS,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,OAAO,CAAC;AAErE,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AASlD,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,IAAI,MAAM,SAAS,CAAC;AAE3B,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzE,OAAO,EAAE,kBAAkB,EAAE,MAAM,qBAAqB,CAAC;AAgDzD,MAAM,sBAAsB,GAAG;IAC7B,IAAI,EAAE,CAAC;IACP,MAAM,EAAE,CAAC;IACT,IAAI,EAAE,GAAG;IACT,IAAI,EAAE,CAAC;CACC,CAAC;AAEX,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,IAAI,CAAC,CAExC,KAAK,CAAC,EAAE;IACR,MAAM,EACJ,KAAK,EAAE,EAAE,IAAI,EAAE,EAChB,GAAG,KAAK,CAAC;IACV,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,GAAG,KAAK,CAAC;IACpD,MAAM,kBAAkB,GAAG,YAAY,sBAAsB,CAAC,KAAK,CAAC,eAAe,CAAC,MAClF,IAAI,CAAC,SAAS,CAAC,KACjB,SAAS,CAAC;IAEV,OAAO,GAAG,CAAA;gBACI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D;YACvD,oBAAoB,EAAE,EAAE,CAAC;YACzB,QAAQ,CAAC,QAAQ,CAAC,CAAC;QACrB,CAAC;QACD,IAAI,KAAK,KAAK,SAAS,IAAI,OAAO,KAAK,GAAG,EAAE,CAAC;YAC3C,sBAAsB;YACtB,mBAAmB,EAAE,EAAE,CAAC;YACxB,QAAQ,CAAC,MAAM,CAAC,CAAC;QACnB,CAAC;IACH,CAAC,EAAE,CAAC,KAAK,CAAC,CAAC,CAAC;IAEZ,OAAO,CAAC,IAAI,IAAI,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,CAC1C,KAAC,aAAa,IAAC,YAAY,EAAE,UAAU,IAAI,SAAS,YAClD,KAAC,cAAc,mBACA,OAAO,CAAC,IAAI,EACzB,SAAS,EAAE,EAAE,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,SAAS,EAAE,EACpE,eAAe,EAAE,eAAe,EAChC,OAAO,EAAE,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,MAAM,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,EACxD,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,OAAO,EAChB,QAAQ,EAAE,QAAQ,EAClB,eAAe,EAAE,eAAe,EAChC,GAAG,EAAE,WAAW,KACZ,SAAS,YAEZ,QAAQ,GACM,GACH,CACjB,CAAC;AACJ,CAAC,CAAC,EACF,kBAAkB,CACnB,CAAC","sourcesContent":["import { useEffect, useState, useCallback, forwardRef } from 'react';\nimport type { PropsWithoutRef, TransitionEvent } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport { defaultThemeProp } from '../../theme';\nimport { reflow, withTestIds } from '../../utils';\nimport type {\n PropsWithDefaults,\n ExcludeStrict,\n WithAttributes,\n RefElement,\n TestIdProp,\n OmitStrict\n} from '../../types';\nimport Configuration from '../Configuration';\nimport Flex from '../Flex';\nimport type { FlexProps } from '../Flex';\nimport { useConsolidatedRef, useElement, useTestIds } from '../../hooks';\n\nimport { getBackdropTestIds } from './Backdrop.test-ids';\n\nexport type BackdropProps = WithAttributes<\n 'div',\n TestIdProp & {\n /**\n * Opacity of the Backdrop.\n * @default 0.4\n */\n alpha?: number;\n /** Props passed to Flex container. */\n container?: ExcludeStrict<FlexProps['container'], true>;\n /**\n * Toggles visibility of Backdrop.\n * @default false\n */\n open?: boolean;\n /**\n * Determines the color of the Backdrop.\n * @default 'dark'\n */\n variant?: 'dark' | 'light';\n /**\n * Transition speed of Backdrop animation.\n * @default 'medium'\n */\n transitionSpeed?: 'slow' | 'medium' | 'fast' | 'none';\n /**\n * The position of the Backdrop.\n * @default 'fixed'\n */\n position?: 'absolute' | 'fixed';\n /** Accepts a callback that gets invoked before opening Backdrop. */\n onBeforeTransitionIn?: () => void;\n /** Accepts a callback that gets invoked after opening Backdrop. */\n onAfterTransitionIn?: () => void;\n /** Accepts a callback that gets invoked before closing Backdrop. */\n onBeforeTransitionOut?: () => void;\n /** Accepts a callback that gets invoked after closing Backdrop */\n onAfterTransitionOut?: () => void;\n }\n>;\n\ntype BackdropPropsWithDefaults = PropsWithDefaults<\n BackdropProps,\n 'open' | 'transitionSpeed' | 'alpha' | 'position'\n>;\n\nconst transitionSpeedToTheme = {\n slow: 2,\n medium: 1,\n fast: 0.5,\n none: 0\n} as const;\n\nexport const StyledBackdrop = styled(Flex)<\n OmitStrict<BackdropPropsWithDefaults, 'open'> & { opacity: 0 | 1 }\n>(props => {\n const {\n theme: { base }\n } = props;\n const { opacity, alpha, variant, position } = props;\n const transitionDuration = `max(calc(${transitionSpeedToTheme[props.transitionSpeed]} * ${\n base.animation.speed\n }), 1ms)`;\n\n return css`\n position: ${position};\n z-index: ${position === 'fixed' ? base['z-index'].backdrop : base['z-index'].popover + 1};\n inset-inline: 0;\n inset-block-start: ${position === 'fixed' ? 'var(--appshell-hard-top-offset, 0rem)' : '0'};\n inset-block-end: 0;\n padding-block-end: ${position === 'fixed' ? 'var(--appshell-hard-bottom-offset, 0rem)' : '0'};\n border-radius: inherit;\n opacity: ${opacity};\n transition-property: opacity;\n transition-timing-function: ${props.theme.base.animation.timing.ease};\n /* stylelint-disable declaration-block-no-duplicate-properties */\n transition-duration: 1ms;\n transition-duration: ${transitionDuration};\n /* stylelint-enable declaration-block-no-duplicate-properties */\n\n ${variant === 'dark' &&\n css`\n background: rgba(0, 0, 0, ${alpha});\n `}\n\n ${variant === 'light' &&\n css`\n background: rgba(255, 255, 255, ${alpha});\n `}\n `;\n});\n\nStyledBackdrop.defaultProps = defaultThemeProp;\n\ntype State = 'closed' | 'opening' | 'open' | 'closing';\n\nexport default withTestIds(\n forwardRef<RefElement<BackdropProps>, PropsWithoutRef<BackdropProps>>(function Backdrop(\n {\n testId,\n children,\n container,\n open = false,\n variant = 'dark',\n transitionSpeed = 'medium',\n alpha = 0.6,\n position = 'fixed',\n onBeforeTransitionIn,\n onAfterTransitionIn,\n onBeforeTransitionOut,\n onAfterTransitionOut,\n ...restProps\n },\n ref\n ) {\n const testIds = useTestIds(testId, getBackdropTestIds);\n const [state, setState] = useState<State>('closed');\n const [backdropEl, setBackdropEl] = useElement<HTMLDivElement>();\n const backdropRef = useConsolidatedRef(ref, setBackdropEl);\n\n const onTransitionEnd = useCallback(\n (e: TransitionEvent) => {\n if (e.propertyName !== 'opacity' || e.target !== e.currentTarget) return;\n let nextState: State;\n\n if (state === 'closing') {\n nextState = 'closed';\n onAfterTransitionOut?.();\n } else {\n nextState = 'open';\n onAfterTransitionIn?.();\n }\n\n setState(nextState);\n },\n [state, onAfterTransitionOut, onAfterTransitionIn]\n );\n\n useEffect(() => {\n if (open) {\n if (state === 'closed' || state === 'closing') {\n onBeforeTransitionIn?.();\n reflow();\n setState('opening');\n }\n } else if (state === 'open' || state === 'opening') {\n onBeforeTransitionOut?.();\n setState('closing');\n }\n }, [open]);\n\n // Using a separate effect instead of combined logic above as it seems more intuitive to mentally manage.\n useEffect(() => {\n if (!backdropRef.current) return;\n const opacity = window.getComputedStyle(backdropRef.current).opacity;\n // If the opacity is already at the destination value, sync the state value.\n if (state === 'closing' && opacity === '0') {\n // Since the transition never ran, we have to pretend it did and call the callback.\n // TODO: This maybe can be fixed with the animation api\n onAfterTransitionOut?.();\n setState('closed');\n }\n if (state === 'opening' && opacity === '1') {\n // ditto, see above...\n onAfterTransitionIn?.();\n setState('open');\n }\n }, [state]);\n\n return !open && state === 'closed' ? null : (\n <Configuration portalTarget={backdropEl ?? undefined}>\n <StyledBackdrop\n data-testid={testIds.root}\n container={{ justify: 'center', alignItems: 'center', ...container }}\n transitionSpeed={transitionSpeed}\n opacity={state === 'opening' || state === 'open' ? 1 : 0}\n alpha={alpha}\n variant={variant}\n position={position}\n onTransitionEnd={onTransitionEnd}\n ref={backdropRef}\n {...restProps}\n >\n {children}\n </StyledBackdrop>\n </Configuration>\n );\n }),\n getBackdropTestIds\n);\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"ClassificationMarking.styles.d.ts","sourceRoot":"","sources":["../../../src/components/ClassificationMarking/ClassificationMarking.styles.ts"],"names":[],"mappings":"AAKA;;;GAGG;AACH,eAAO,MAAM,gCAAgC;YACnC,MAAM;EAKf,CAAC;AAEF,eAAO,MAAM,aAAa;gBACZ,MAAM;WACX,MAAM;YACL,MAAM;eACH,MAAM;iBACJ,MAAM;eACR,KAAK,GAAG,QAAQ;YAgB3B,CAAC;AAIH,eAAO,MAAM,uBAAuB;YAC1B,MAAM;YAmCd,CAAC"}
1
+ {"version":3,"file":"ClassificationMarking.styles.d.ts","sourceRoot":"","sources":["../../../src/components/ClassificationMarking/ClassificationMarking.styles.ts"],"names":[],"mappings":"AAIA;;;GAGG;AACH,eAAO,MAAM,gCAAgC;YACnC,MAAM;EAKf,CAAC;AAEF,eAAO,MAAM,aAAa;gBACZ,MAAM;WACX,MAAM;YACL,MAAM;eACH,MAAM;iBACJ,MAAM;eACR,KAAK,GAAG,QAAQ;YAoB3B,CAAC;AAIH,eAAO,MAAM,uBAAuB;YAC1B,MAAM;YAKd,CAAC"}
@@ -1,6 +1,5 @@
1
1
  import styled, { css, createGlobalStyle } from 'styled-components';
2
2
  import { defaultThemeProp } from '../../theme';
3
- import { headerHeight, StyledMobileNav } from '../AppShell/AppShell.styles';
4
3
  /**
5
4
  * Promotes --marking-height to :root so portaled elements
6
5
  * (Fullscreen, Lightbox) can read it outside the StyledClassifiedContent tree.
@@ -15,7 +14,11 @@ export const StyledMarking = styled.div(({ background, color, height, fontSize,
15
14
  position: fixed;
16
15
  ${placement}: 0;
17
16
  inset-inline: 0;
17
+ box-sizing: content-box;
18
18
  height: ${height};
19
+ ${placement === 'bottom'
20
+ ? 'padding-block-end: var(--safe-area-inset-block-end, 0);'
21
+ : 'padding-block-start: var(--safe-area-inset-block-start, 0);'}
19
22
  line-height: ${height};
20
23
  text-align: center;
21
24
  font-weight: ${theme.base['font-weight'].bold};
@@ -27,39 +30,9 @@ export const StyledMarking = styled.div(({ background, color, height, fontSize,
27
30
  `;
28
31
  });
29
32
  StyledMarking.defaultProps = defaultThemeProp;
30
- export const StyledClassifiedContent = styled.div(({ height, theme }) => {
33
+ export const StyledClassifiedContent = styled.div(({ height }) => {
31
34
  return css `
32
35
  --marking-height: ${height};
33
- --top-offset: calc(${headerHeight} + var(--marking-height));
34
- --remaining-height: calc(100vh - (${headerHeight} + (var(--marking-height) * 2)));
35
- height: calc(100% - var(--marking-height));
36
- min-height: calc(100% - var(--marking-height));
37
-
38
- /* Header layout fix: position below top banner */
39
- & > header:not(${StyledMobileNav}) {
40
- position: fixed;
41
- top: var(--marking-height);
42
- width: 100%;
43
- }
44
-
45
- /* Desktop only: nav and main top offset and min-height */
46
- @media (width > ${theme.base.breakpoints.sm}) {
47
- & nav[data-app-region],
48
- & nav[data-app-region] [role='dialog'],
49
- & main[data-app-region] {
50
- top: var(--top-offset);
51
- min-height: var(--remaining-height);
52
- }
53
-
54
- /* Nav height */
55
- & nav[data-app-region] {
56
- height: var(--remaining-height);
57
- }
58
-
59
- & main[data-app-region] {
60
- padding-block-end: var(--marking-height);
61
- }
62
- }
63
36
  `;
64
37
  });
65
38
  StyledClassifiedContent.defaultProps = defaultThemeProp;
@@ -1 +1 @@
1
- {"version":3,"file":"ClassificationMarking.styles.js","sourceRoot":"","sources":["../../../src/components/ClassificationMarking/ClassificationMarking.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAE5E;;;GAGG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG,iBAAiB,CAE/D;;wBAEsB,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM;;CAE7C,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAOpC,CAAC,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,KAAK,EAAE,EAAE,EAAE;IAC3E,OAAO,GAAG,CAAA;;MAEN,SAAS;;cAED,MAAM;mBACD,MAAM;;mBAEN,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,IAAI;MAC3C,UAAU,CAAC,CAAC,CAAC,gBAAgB,UAAU,GAAG,CAAC,CAAC,CAAC,EAAE;MAC/C,QAAQ,CAAC,CAAC,CAAC,cAAc,QAAQ,GAAG,CAAC,CAAC,CAAC,EAAE;eAChC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,GAAG;kBACtB,UAAU;aACf,KAAK;GACf,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,aAAa,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE9C,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,GAAG,CAE9C,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,EAAE;IACvB,OAAO,GAAG,CAAA;wBACY,MAAM;yBACL,YAAY;wCACG,YAAY;;;;;qBAK/B,eAAe;;;;;;;sBAOd,KAAK,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE;;;;;;;;;;;;;;;;;GAiB5C,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,uBAAuB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css, createGlobalStyle } from 'styled-components';\n\nimport { defaultThemeProp } from '../../theme';\nimport { headerHeight, StyledMobileNav } from '../AppShell/AppShell.styles';\n\n/**\n * Promotes --marking-height to :root so portaled elements\n * (Fullscreen, Lightbox) can read it outside the StyledClassifiedContent tree.\n */\nexport const ClassificationMarkingGlobalStyle = createGlobalStyle<{\n height: string;\n}>`\n :root {\n --marking-height: ${({ height }) => height};\n }\n`;\n\nexport const StyledMarking = styled.div<{\n background: string;\n color: string;\n height: string;\n fontSize?: string;\n fontFamily?: string;\n placement: 'top' | 'bottom';\n}>(({ background, color, height, fontSize, fontFamily, placement, theme }) => {\n return css`\n position: fixed;\n ${placement}: 0;\n inset-inline: 0;\n height: ${height};\n line-height: ${height};\n text-align: center;\n font-weight: ${theme.base['font-weight'].bold};\n ${fontFamily ? `font-family: ${fontFamily};` : ''}\n ${fontSize ? `font-size: ${fontSize};` : ''}\n z-index: ${theme.base['z-index'].max};\n background: ${background};\n color: ${color};\n `;\n});\n\nStyledMarking.defaultProps = defaultThemeProp;\n\nexport const StyledClassifiedContent = styled.div<{\n height: string;\n}>(({ height, theme }) => {\n return css`\n --marking-height: ${height};\n --top-offset: calc(${headerHeight} + var(--marking-height));\n --remaining-height: calc(100vh - (${headerHeight} + (var(--marking-height) * 2)));\n height: calc(100% - var(--marking-height));\n min-height: calc(100% - var(--marking-height));\n\n /* Header layout fix: position below top banner */\n & > header:not(${StyledMobileNav}) {\n position: fixed;\n top: var(--marking-height);\n width: 100%;\n }\n\n /* Desktop only: nav and main top offset and min-height */\n @media (width > ${theme.base.breakpoints.sm}) {\n & nav[data-app-region],\n & nav[data-app-region] [role='dialog'],\n & main[data-app-region] {\n top: var(--top-offset);\n min-height: var(--remaining-height);\n }\n\n /* Nav height */\n & nav[data-app-region] {\n height: var(--remaining-height);\n }\n\n & main[data-app-region] {\n padding-block-end: var(--marking-height);\n }\n }\n `;\n});\n\nStyledClassifiedContent.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"ClassificationMarking.styles.js","sourceRoot":"","sources":["../../../src/components/ClassificationMarking/ClassificationMarking.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAEnE,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C;;;GAGG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG,iBAAiB,CAE/D;;wBAEsB,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC,MAAM;;CAE7C,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,GAAG,CAOpC,CAAC,EAAE,UAAU,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,SAAS,EAAE,KAAK,EAAE,EAAE,EAAE;IAC3E,OAAO,GAAG,CAAA;;MAEN,SAAS;;;cAGD,MAAM;MACd,SAAS,KAAK,QAAQ;QACtB,CAAC,CAAC,yDAAyD;QAC3D,CAAC,CAAC,6DAA6D;mBAClD,MAAM;;mBAEN,KAAK,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,IAAI;MAC3C,UAAU,CAAC,CAAC,CAAC,gBAAgB,UAAU,GAAG,CAAC,CAAC,CAAC,EAAE;MAC/C,QAAQ,CAAC,CAAC,CAAC,cAAc,QAAQ,GAAG,CAAC,CAAC,CAAC,EAAE;eAChC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,GAAG;kBACtB,UAAU;aACf,KAAK;GACf,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,aAAa,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAE9C,MAAM,CAAC,MAAM,uBAAuB,GAAG,MAAM,CAAC,GAAG,CAE9C,CAAC,EAAE,MAAM,EAAE,EAAE,EAAE;IAChB,OAAO,GAAG,CAAA;wBACY,MAAM;GAC3B,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,uBAAuB,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css, createGlobalStyle } from 'styled-components';\n\nimport { defaultThemeProp } from '../../theme';\n\n/**\n * Promotes --marking-height to :root so portaled elements\n * (Fullscreen, Lightbox) can read it outside the StyledClassifiedContent tree.\n */\nexport const ClassificationMarkingGlobalStyle = createGlobalStyle<{\n height: string;\n}>`\n :root {\n --marking-height: ${({ height }) => height};\n }\n`;\n\nexport const StyledMarking = styled.div<{\n background: string;\n color: string;\n height: string;\n fontSize?: string;\n fontFamily?: string;\n placement: 'top' | 'bottom';\n}>(({ background, color, height, fontSize, fontFamily, placement, theme }) => {\n return css`\n position: fixed;\n ${placement}: 0;\n inset-inline: 0;\n box-sizing: content-box;\n height: ${height};\n ${placement === 'bottom'\n ? 'padding-block-end: var(--safe-area-inset-block-end, 0);'\n : 'padding-block-start: var(--safe-area-inset-block-start, 0);'}\n line-height: ${height};\n text-align: center;\n font-weight: ${theme.base['font-weight'].bold};\n ${fontFamily ? `font-family: ${fontFamily};` : ''}\n ${fontSize ? `font-size: ${fontSize};` : ''}\n z-index: ${theme.base['z-index'].max};\n background: ${background};\n color: ${color};\n `;\n});\n\nStyledMarking.defaultProps = defaultThemeProp;\n\nexport const StyledClassifiedContent = styled.div<{\n height: string;\n}>(({ height }) => {\n return css`\n --marking-height: ${height};\n `;\n});\n\nStyledClassifiedContent.defaultProps = defaultThemeProp;\n"]}
@@ -12,12 +12,12 @@ export const StyledFullscreen = styled.div(({ theme, fullscreen }) => {
12
12
  ${fullscreen &&
13
13
  css `
14
14
  --content-height-in-view: calc(
15
- 100dvh - var(--appshell-top-offset, 0rem) - var(--appshell-hard-bottom-offset, 0rem)
15
+ 100dvh - var(--appshell-hard-top-offset, 0rem) - var(--appshell-hard-bottom-offset, 0rem)
16
16
  );
17
17
  position: fixed;
18
18
  z-index: ${theme.base['z-index'].backdrop};
19
19
  inset-inline: 0;
20
- inset-block-start: var(--appshell-top-offset, 0);
20
+ inset-block-start: var(--appshell-hard-top-offset, 0);
21
21
  inset-block-end: var(--appshell-hard-bottom-offset, 0);
22
22
  background: ${theme.base.palette['primary-background']};
23
23
  `}
@@ -1 +1 @@
1
- {"version":3,"file":"Fullscreen.js","sourceRoot":"","sources":["../../../src/components/Fullscreen/Fullscreen.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,UAAU,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE5F,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAGzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EACL,gBAAgB,EAChB,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,aAAa,EACb,eAAe,EACf,UAAU,EACX,MAAM,aAAa,CAAC;AACrB,OAAO,aAAa,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,OAAO,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC;AAU7D,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,GAAG,CAA2B,CAAC,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE,EAAE;IAC7F,OAAO,GAAG,CAAA;MACN,UAAU;QACZ,GAAG,CAAA;;;;;iBAKU,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAA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AC;IAEzD,MAAM,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,UAAU,EAAkB,CAAC;IAE7D,MAAM,CAAC,UAAU,EAAE,aAAa,CAAC,GAAG,QAAQ,CAAsB,SAAS,CAAC,CAAC;IAE7E,MAAM,QAAQ,GAA2B,OAAO,CAAC,GAAG,EAAE;QACpD,OAAO;YACL,UAAU;YACV,GAAG,EAAE;gBACH,aAAa,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC;YAC7B,CAAC;SACF,CAAC;IACJ,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC;IAEjB,MAAM,SAAS,GAAG,aAAa,CAAC,QAAQ,EAAE,CAAC,CAAC,UAAU,CAAC,CAAC;IAExD,MAAM,SAAS,GAAG,CAChB,KAAC,gBAAgB,mBACF,OAAO,CAAC,IAAI,6BACA,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,SAAS,KAClD,SAAS,EACb,GAAG,EAAE,WAAW,EAChB,UAAU,EAAE,CAAC,CAAC,UAAU,qBACP,SAAS,YAEzB,QAAQ,GACQ,CACpB,CAAC;IAEF,OAAO,CACL,KAAC,iBAAiB,CAAC,QAAQ,IAAC,KAAK,EAAE,QAAQ,YACxC,UAAU,IAAI,QAAQ,CAAC,CAAC,CAAC,CACxB,8BAEE,cAAK,GAAG,EAAE,WAAW,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,MAAM,EAAE,GAAI,EACrD,KAAC,YAAY,IAAC,SAAS,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,GAAI,IAC/D,CACJ,CAAC,CAAC,CAAC,CACF,SAAS,CACV,GAC0B,CAC9B,CAAC;AACJ,CAAC,CAAC,EACF,oBAAoB,CACrB,CAAC","sourcesContent":["import { forwardRef, createContext, useContext, useMemo, useState, useEffect } from 'react';\nimport type { PropsWithoutRef, ReactNode, ReactElement, RefObject } from 'react';\nimport styled, { css } from 'styled-components';\nimport { createPortal } from 'react-dom';\n\nimport type { RefElement, TestIdProp, WithAttributes } from '../../types';\nimport { defaultThemeProp } from '../../theme';\nimport {\n useConfiguration,\n useConsolidatedRef,\n useElement,\n useFocusTrap,\n usePopoverMap,\n useScrollToggle,\n useTestIds\n} from '../../hooks';\nimport Configuration from '../Configuration';\nimport { withTestIds } from '../../utils';\n\nimport { getFullscreenTestIds } from './Fullscreen.test-ids';\n\nexport type FullscreenProps = WithAttributes<\n 'div',\n {\n children: ReactNode;\n }\n> &\n TestIdProp;\n\nexport const StyledFullscreen = styled.div<{ fullscreen?: boolean }>(({ theme, fullscreen }) => {\n return css`\n ${fullscreen &&\n css`\n --content-height-in-view: calc(\n 100dvh - var(--appshell-top-offset, 0rem) - var(--appshell-hard-bottom-offset, 0rem)\n );\n position: fixed;\n z-index: ${theme.base['z-index'].backdrop};\n inset-inline: 0;\n inset-block-start: var(--appshell-top-offset, 0);\n inset-block-end: var(--appshell-hard-bottom-offset, 0);\n background: ${theme.base.palette['primary-background']};\n `}\n `;\n});\n\nStyledFullscreen.defaultProps = defaultThemeProp;\n\nexport type FullscreenContextValue = [boolean | undefined, () => void] | undefined;\n\nexport const FullscreenContext = createContext<FullscreenContextValue>(undefined);\n\nexport const useFullscreenContext = () => {\n // Ensure easier/safer destructuring in use\n return useContext(FullscreenContext);\n};\n\nconst PortalRender = ({\n parentJSX,\n parentElRef\n}: {\n parentJSX: ReactElement;\n parentElRef: RefObject<HTMLDivElement>;\n}) => {\n const { portalTarget } = useConfiguration();\n useFocusTrap(parentElRef);\n const { disableScroll, enableScroll } = useScrollToggle();\n\n useEffect(() => {\n disableScroll();\n return enableScroll;\n }, []);\n\n return portalTarget\n ? createPortal(\n <Configuration portalTarget={parentElRef.current ?? undefined}>{parentJSX}</Configuration>,\n portalTarget\n )\n : null;\n};\n\nexport default withTestIds(\n forwardRef<RefElement<FullscreenProps>, PropsWithoutRef<FullscreenProps>>(function Fullscreen(\n { children, testId, ...restProps },\n ref\n ) {\n const testIds = useTestIds(testId, getFullscreenTestIds);\n // setParentEl ensures one extra render needed for keeping div passed to PortalRender up to date\n const [parentEl, setParentEl] = useElement<HTMLDivElement>();\n const parentElRef = useConsolidatedRef(setParentEl, ref);\n\n const [targetEl, setTargetEl] = useElement<HTMLDivElement>();\n\n const [fullscreen, setFullscreen] = useState<boolean | undefined>(undefined);\n\n const ctxValue: FullscreenContextValue = useMemo(() => {\n return [\n fullscreen,\n () => {\n setFullscreen(cur => !cur);\n }\n ];\n }, [fullscreen]);\n\n const popoverId = usePopoverMap(targetEl, !!fullscreen);\n\n const parentJSX = (\n <StyledFullscreen\n data-testid={testIds.root}\n data-fullscreen-enabled={fullscreen ? true : undefined}\n {...restProps}\n ref={parentElRef}\n fullscreen={!!fullscreen}\n data-popover-id={popoverId}\n >\n {children}\n </StyledFullscreen>\n );\n\n return (\n <FullscreenContext.Provider value={ctxValue}>\n {fullscreen && parentEl ? (\n <>\n {/* DOM element required for outer event management. */}\n <div ref={setTargetEl} style={{ display: 'none' }} />\n <PortalRender parentJSX={parentJSX} parentElRef={parentElRef} />\n </>\n ) : (\n parentJSX\n )}\n </FullscreenContext.Provider>\n );\n }),\n getFullscreenTestIds\n);\n"]}
1
+ {"version":3,"file":"Fullscreen.js","sourceRoot":"","sources":["../../../src/components/Fullscreen/Fullscreen.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,aAAa,EAAE,UAAU,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAE5F,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAGzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EACL,gBAAgB,EAChB,kBAAkB,EAClB,UAAU,EACV,YAAY,EACZ,aAAa,EACb,eAAe,EACf,UAAU,EACX,MAAM,aAAa,CAAC;AACrB,OAAO,aAA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AO,EAAE,MAAM,EAAE,GAAI,EACrD,KAAC,YAAY,IAAC,SAAS,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,GAAI,IAC/D,CACJ,CAAC,CAAC,CAAC,CACF,SAAS,CACV,GAC0B,CAC9B,CAAC;AACJ,CAAC,CAAC,EACF,oBAAoB,CACrB,CAAC","sourcesContent":["import { forwardRef, createContext, useContext, useMemo, useState, useEffect } from 'react';\nimport type { PropsWithoutRef, ReactNode, ReactElement, RefObject } from 'react';\nimport styled, { css } from 'styled-components';\nimport { createPortal } from 'react-dom';\n\nimport type { RefElement, TestIdProp, WithAttributes } from '../../types';\nimport { defaultThemeProp } from '../../theme';\nimport {\n useConfiguration,\n useConsolidatedRef,\n useElement,\n useFocusTrap,\n usePopoverMap,\n useScrollToggle,\n useTestIds\n} from '../../hooks';\nimport Configuration from '../Configuration';\nimport { withTestIds } from '../../utils';\n\nimport { getFullscreenTestIds } from './Fullscreen.test-ids';\n\nexport type FullscreenProps = WithAttributes<\n 'div',\n {\n children: ReactNode;\n }\n> &\n TestIdProp;\n\nexport const StyledFullscreen = styled.div<{ fullscreen?: boolean }>(({ theme, fullscreen }) => {\n return css`\n ${fullscreen &&\n css`\n --content-height-in-view: calc(\n 100dvh - var(--appshell-hard-top-offset, 0rem) - var(--appshell-hard-bottom-offset, 0rem)\n );\n position: fixed;\n z-index: ${theme.base['z-index'].backdrop};\n inset-inline: 0;\n inset-block-start: var(--appshell-hard-top-offset, 0);\n inset-block-end: var(--appshell-hard-bottom-offset, 0);\n background: ${theme.base.palette['primary-background']};\n `}\n `;\n});\n\nStyledFullscreen.defaultProps = defaultThemeProp;\n\nexport type FullscreenContextValue = [boolean | undefined, () => void] | undefined;\n\nexport const FullscreenContext = createContext<FullscreenContextValue>(undefined);\n\nexport const useFullscreenContext = () => {\n // Ensure easier/safer destructuring in use\n return useContext(FullscreenContext);\n};\n\nconst PortalRender = ({\n parentJSX,\n parentElRef\n}: {\n parentJSX: ReactElement;\n parentElRef: RefObject<HTMLDivElement>;\n}) => {\n const { portalTarget } = useConfiguration();\n useFocusTrap(parentElRef);\n const { disableScroll, enableScroll } = useScrollToggle();\n\n useEffect(() => {\n disableScroll();\n return enableScroll;\n }, []);\n\n return portalTarget\n ? createPortal(\n <Configuration portalTarget={parentElRef.current ?? undefined}>{parentJSX}</Configuration>,\n portalTarget\n )\n : null;\n};\n\nexport default withTestIds(\n forwardRef<RefElement<FullscreenProps>, PropsWithoutRef<FullscreenProps>>(function Fullscreen(\n { children, testId, ...restProps },\n ref\n ) {\n const testIds = useTestIds(testId, getFullscreenTestIds);\n // setParentEl ensures one extra render needed for keeping div passed to PortalRender up to date\n const [parentEl, setParentEl] = useElement<HTMLDivElement>();\n const parentElRef = useConsolidatedRef(setParentEl, ref);\n\n const [targetEl, setTargetEl] = useElement<HTMLDivElement>();\n\n const [fullscreen, setFullscreen] = useState<boolean | undefined>(undefined);\n\n const ctxValue: FullscreenContextValue = useMemo(() => {\n return [\n fullscreen,\n () => {\n setFullscreen(cur => !cur);\n }\n ];\n }, [fullscreen]);\n\n const popoverId = usePopoverMap(targetEl, !!fullscreen);\n\n const parentJSX = (\n <StyledFullscreen\n data-testid={testIds.root}\n data-fullscreen-enabled={fullscreen ? true : undefined}\n {...restProps}\n ref={parentElRef}\n fullscreen={!!fullscreen}\n data-popover-id={popoverId}\n >\n {children}\n </StyledFullscreen>\n );\n\n return (\n <FullscreenContext.Provider value={ctxValue}>\n {fullscreen && parentEl ? (\n <>\n {/* DOM element required for outer event management. */}\n <div ref={setTargetEl} style={{ display: 'none' }} />\n <PortalRender parentJSX={parentJSX} parentElRef={parentElRef} />\n </>\n ) : (\n parentJSX\n )}\n </FullscreenContext.Provider>\n );\n }),\n getFullscreenTestIds\n);\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"Lightbox.styles.d.ts","sourceRoot":"","sources":["../../../src/components/Lightbox/Lightbox.styles.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,YAAY;YAA2B,OAAO;YAuBzD,CAAC;AAIH,eAAO,MAAM,kBAAkB,6NAY7B,CAAC;AAIH,eAAO,MAAM,UAAU,6NAWrB,CAAC;AAIH,eAAO,MAAM,eAAe;;0KAgE1B,CAAC;AAIH,eAAO,MAAM,eAAe,6NAW1B,CAAC;AAIH,eAAO,MAAM,oBAAoB;YAAwB,OAAO;YAuC9D,CAAC;AAEH,eAAO,MAAM,YAAY,yOAKxB,CAAC;AAIF,eAAO,MAAM,mBAAmB,6NAG/B,CAAC;AAEF,eAAO,MAAM,gBAAgB,6NAE5B,CAAC;AAEF,eAAO,MAAM,mBAAmB;;uJAG/B,CAAC;AAEF,eAAO,MAAM,cAAc;;;YAA8B,OAAO;;;iDAW9D,CAAC"}
1
+ {"version":3,"file":"Lightbox.styles.d.ts","sourceRoot":"","sources":["../../../src/components/Lightbox/Lightbox.styles.ts"],"names":[],"mappings":"AAgBA,eAAO,MAAM,YAAY;YAA2B,OAAO;YAuBzD,CAAC;AAIH,eAAO,MAAM,kBAAkB,6NAY7B,CAAC;AAIH,eAAO,MAAM,UAAU,6NAWrB,CAAC;AAIH,eAAO,MAAM,eAAe;;0KAgE1B,CAAC;AAIH,eAAO,MAAM,eAAe,6NAW1B,CAAC;AAIH,eAAO,MAAM,oBAAoB;YAAwB,OAAO;YAwC9D,CAAC;AAEH,eAAO,MAAM,YAAY,yOAKxB,CAAC;AAIF,eAAO,MAAM,mBAAmB,6NAG/B,CAAC;AAEF,eAAO,MAAM,gBAAgB,6NAE5B,CAAC;AAEF,eAAO,MAAM,mBAAmB;;uJAG/B,CAAC;AAEF,eAAO,MAAM,cAAc;;;YAA8B,OAAO;;;iDAW9D,CAAC"}
@@ -145,6 +145,7 @@ export const StyledMediaContainer = styled.div(({ theme, global }) => {
145
145
  ${!global &&
146
146
  css `
147
147
  background-color: ${theme.base.colors.gray['extra-dark']};
148
+ overflow-y: auto;
148
149
  `}
149
150
 
150
151
  & > div {
@@ -1 +1 @@
1
- {"version":3,"file":"Lightbox.styles.js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AG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { hideVisually, rgba } from 'polished';\n\nimport { defaultThemeProp } from '../../theme';\nimport { tryCatch } from '../../utils';\nimport { calculateFontSize } from '../../styles';\nimport BareButton from '../Button/BareButton';\nimport { StyledIcon } from '../Icon';\nimport { StyledMetaList } from '../MetaList/MetaList';\nimport { StyledErrorState } from '../ErrorState';\nimport Text, { StyledText } from '../Text';\nimport { useDirection } from '../../hooks';\nimport Backdrop from '../Backdrop';\nimport { StyledLink } from '../Link/Link';\nimport { ellipsisOverflow } from '../../styles/mixins';\n\nexport const StyledHeader = styled.header<{ global: boolean }>(({ theme, global }) => {\n const color: string | undefined = tryCatch(() =>\n rgba(theme.base.palette.light, theme.base.transparency['transparent-2'])\n );\n\n return css`\n position: relative;\n width: 100%;\n padding: ${theme.base.spacing};\n color: ${color};\n ${!global &&\n css`\n background-color: ${theme.base.colors.gray['extra-dark']};\n border-block-end: 0.0625rem solid ${theme.base.palette['border-line']};\n `}\n\n ${StyledMetaList} {\n justify-content: center;\n li {\n color: ${color};\n }\n }\n `;\n});\n\nStyledHeader.defaultProps = defaultThemeProp;\n\nexport const StyledCountTracker = styled.div(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n\n return css`\n font-size: ${fontSize.xs};\n text-align: center;\n min-width: calc(2 * ${theme.base['hit-area']['mouse-min']});\n\n @media (pointer: coarse) {\n min-width: calc(2 * ${theme.base['hit-area']['finger-min']});\n }\n `;\n});\n\nStyledCountTracker.defaultProps = defaultThemeProp;\n\nexport const StyledInfo = styled.div(({ theme }) => {\n return css`\n color: ${theme.base.palette.light};\n font-weight: ${theme.base['font-weight']['semi-bold']};\n min-width: 0;\n\n ${StyledLink} {\n color: inherit;\n text-decoration: underline;\n }\n `;\n});\n\nStyledInfo.defaultProps = defaultThemeProp;\n\nexport const StyledNavButton = styled(BareButton)(({ theme }) => {\n const bg = tryCatch(() => rgba(theme.base.colors.gray.medium, 0.5));\n const hoverBg = tryCatch(() => rgba(theme.base.colors.gray.medium, 0.7));\n const { rtl } = useDirection();\n\n return css`\n position: absolute;\n z-index: 1;\n inset-block: 0;\n min-width: ${theme.base['hit-area']['mouse-min']};\n color: ${theme.base.palette['foreground-color']};\n box-shadow: none;\n border-radius: 0;\n\n @media (pointer: coarse) {\n min-width: ${theme.base['hit-area']['finger-min']};\n }\n\n &[hidden] {\n display: none;\n }\n\n & > span {\n display: inline-block;\n background-color: ${bg};\n\n ${StyledIcon} {\n color: ${theme.base.palette.light};\n width: 2rem;\n height: 3rem;\n\n ${rtl &&\n css`\n transform: rotateZ(180deg);\n `}\n }\n }\n\n &:nth-of-type(1) {\n inset-inline-start: 0;\n text-align: start;\n & > span {\n border-start-end-radius: calc(${theme.base['border-radius']} / 2);\n border-end-end-radius: calc(${theme.base['border-radius']} / 2);\n }\n }\n\n &:nth-of-type(2) {\n inset-inline-end: 0;\n text-align: end;\n & > span {\n border-start-start-radius: calc(${theme.base['border-radius']} / 2);\n border-end-start-radius: calc(${theme.base['border-radius']} / 2);\n }\n }\n\n &:hover > span {\n background-color: ${hoverBg};\n }\n\n &:focus > span {\n box-shadow: ${theme.base.shadow.focus};\n }\n `;\n});\n\nStyledNavButton.defaultProps = defaultThemeProp;\n\nexport const StyledContainer = styled.div(({ theme }) => {\n return css`\n button {\n padding: ${theme.base.spacing};\n color: ${theme.base.palette.light};\n\n &:focus:enabled {\n box-shadow: ${theme.base.shadow.focus};\n }\n }\n `;\n});\n\nStyledContainer.defaultProps = defaultThemeProp;\n\nexport const StyledMediaContainer = styled.div<{ global: boolean }>(({ theme, global }) => {\n return css`\n position: relative;\n\n ${!global &&\n css`\n background-color: ${theme.base.colors.gray['extra-dark']};\n `}\n\n & > div {\n position: absolute;\n inset: 0;\n }\n\n ${StyledErrorState} {\n margin: auto;\n & > ${StyledText} {\n color: ${theme.base.palette.light};\n }\n }\n\n img,\n video,\n audio {\n display: block;\n max-width: calc(100% - 5rem);\n max-height: 100%;\n margin: auto;\n }\n\n img,\n video {\n ${!global &&\n css`\n margin-block-start: calc(${theme.base.spacing} * 4);\n max-width: calc(100% - calc(${theme.base.spacing} * 4));\n `}\n }\n `;\n});\n\nexport const StyledObject = styled.object`\n display: block;\n margin: auto;\n width: calc(100% - 5rem);\n height: 100%;\n`;\n\nStyledMediaContainer.defaultProps = defaultThemeProp;\n\nexport const StyledPreviewRegion = styled.div`\n position: relative;\n width: 100%;\n`;\n\nexport const StyledLiveRegion = styled.div`\n ${hideVisually}\n`;\n\nexport const StyledLightboxTitle = styled(Text)`\n max-width: 100%;\n ${ellipsisOverflow};\n`;\n\nexport const StyledLightbox = styled(Backdrop)<{ global: boolean }>(({ global, theme }) => {\n return css`\n ${global &&\n css`\n z-index: ${theme.base['z-index'].max};\n `}\n\n &:focus {\n outline: none;\n }\n `;\n});\n\nStyledLightbox.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"Lightbox.styles.js","sourceRoot":"","sources":["../../../src/components/Lightbox/Lightbox.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAChD,OAAO,EAAE,YAAY,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAE9C,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,UAAU,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,IAAI,EAAE,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;A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oBAAoB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAErD,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,GAAG,CAAA;;;CAG5C,CAAC;AAEF,MAAM,CAAC,MAAM,gBAAgB,GAAG,MAAM,CAAC,GAAG,CAAA;IACtC,YAAY;CACf,CAAC;AAEF,MAAM,CAAC,MAAM,mBAAmB,GAAG,MAAM,CAAC,IAAI,CAAC,CAAA;;IAE3C,gBAAgB;CACnB,CAAC;AAEF,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,QAAQ,CAAC,CAAsB,CAAC,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE,EAAE;IACxF,OAAO,GAAG,CAAA;MACN,MAAM;QACR,GAAG,CAAA;iBACU,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,GAAG;KACrC;;;;;GAKF,CAAC;AACJ,CAAC,CAAC,CAAC;AAEH,cAAc,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\nimport { hideVisually, rgba } from 'polished';\n\nimport { defaultThemeProp } from '../../theme';\nimport { tryCatch } from '../../utils';\nimport { calculateFontSize } from '../../styles';\nimport BareButton from '../Button/BareButton';\nimport { StyledIcon } from '../Icon';\nimport { StyledMetaList } from '../MetaList/MetaList';\nimport { StyledErrorState } from '../ErrorState';\nimport Text, { StyledText } from '../Text';\nimport { useDirection } from '../../hooks';\nimport Backdrop from '../Backdrop';\nimport { StyledLink } from '../Link/Link';\nimport { ellipsisOverflow } from '../../styles/mixins';\n\nexport const StyledHeader = styled.header<{ global: boolean }>(({ theme, global }) => {\n const color: string | undefined = tryCatch(() =>\n rgba(theme.base.palette.light, theme.base.transparency['transparent-2'])\n );\n\n return css`\n position: relative;\n width: 100%;\n padding: ${theme.base.spacing};\n color: ${color};\n ${!global &&\n css`\n background-color: ${theme.base.colors.gray['extra-dark']};\n border-block-end: 0.0625rem solid ${theme.base.palette['border-line']};\n `}\n\n ${StyledMetaList} {\n justify-content: center;\n li {\n color: ${color};\n }\n }\n `;\n});\n\nStyledHeader.defaultProps = defaultThemeProp;\n\nexport const StyledCountTracker = styled.div(({ theme }) => {\n const fontSize = calculateFontSize(theme.base['font-size'], theme.base['font-scale']);\n\n return css`\n font-size: ${fontSize.xs};\n text-align: center;\n min-width: calc(2 * ${theme.base['hit-area']['mouse-min']});\n\n @media (pointer: coarse) {\n min-width: calc(2 * ${theme.base['hit-area']['finger-min']});\n }\n `;\n});\n\nStyledCountTracker.defaultProps = defaultThemeProp;\n\nexport const StyledInfo = styled.div(({ theme }) => {\n return css`\n color: ${theme.base.palette.light};\n font-weight: ${theme.base['font-weight']['semi-bold']};\n min-width: 0;\n\n ${StyledLink} {\n color: inherit;\n text-decoration: underline;\n }\n `;\n});\n\nStyledInfo.defaultProps = defaultThemeProp;\n\nexport const StyledNavButton = styled(BareButton)(({ theme }) => {\n const bg = tryCatch(() => rgba(theme.base.colors.gray.medium, 0.5));\n const hoverBg = tryCatch(() => rgba(theme.base.colors.gray.medium, 0.7));\n const { rtl } = useDirection();\n\n return css`\n position: absolute;\n z-index: 1;\n inset-block: 0;\n min-width: ${theme.base['hit-area']['mouse-min']};\n color: ${theme.base.palette['foreground-color']};\n box-shadow: none;\n border-radius: 0;\n\n @media (pointer: coarse) {\n min-width: ${theme.base['hit-area']['finger-min']};\n }\n\n &[hidden] {\n display: none;\n }\n\n & > span {\n display: inline-block;\n background-color: ${bg};\n\n ${StyledIcon} {\n color: ${theme.base.palette.light};\n width: 2rem;\n height: 3rem;\n\n ${rtl &&\n css`\n transform: rotateZ(180deg);\n `}\n }\n }\n\n &:nth-of-type(1) {\n inset-inline-start: 0;\n text-align: start;\n & > span {\n border-start-end-radius: calc(${theme.base['border-radius']} / 2);\n border-end-end-radius: calc(${theme.base['border-radius']} / 2);\n }\n }\n\n &:nth-of-type(2) {\n inset-inline-end: 0;\n text-align: end;\n & > span {\n border-start-start-radius: calc(${theme.base['border-radius']} / 2);\n border-end-start-radius: calc(${theme.base['border-radius']} / 2);\n }\n }\n\n &:hover > span {\n background-color: ${hoverBg};\n }\n\n &:focus > span {\n box-shadow: ${theme.base.shadow.focus};\n }\n `;\n});\n\nStyledNavButton.defaultProps = defaultThemeProp;\n\nexport const StyledContainer = styled.div(({ theme }) => {\n return css`\n button {\n padding: ${theme.base.spacing};\n color: ${theme.base.palette.light};\n\n &:focus:enabled {\n box-shadow: ${theme.base.shadow.focus};\n }\n }\n `;\n});\n\nStyledContainer.defaultProps = defaultThemeProp;\n\nexport const StyledMediaContainer = styled.div<{ global: boolean }>(({ theme, global }) => {\n return css`\n position: relative;\n\n ${!global &&\n css`\n background-color: ${theme.base.colors.gray['extra-dark']};\n overflow-y: auto;\n `}\n\n & > div {\n position: absolute;\n inset: 0;\n }\n\n ${StyledErrorState} {\n margin: auto;\n & > ${StyledText} {\n color: ${theme.base.palette.light};\n }\n }\n\n img,\n video,\n audio {\n display: block;\n max-width: calc(100% - 5rem);\n max-height: 100%;\n margin: auto;\n }\n\n img,\n video {\n ${!global &&\n css`\n margin-block-start: calc(${theme.base.spacing} * 4);\n max-width: calc(100% - calc(${theme.base.spacing} * 4));\n `}\n }\n `;\n});\n\nexport const StyledObject = styled.object`\n display: block;\n margin: auto;\n width: calc(100% - 5rem);\n height: 100%;\n`;\n\nStyledMediaContainer.defaultProps = defaultThemeProp;\n\nexport const StyledPreviewRegion = styled.div`\n position: relative;\n width: 100%;\n`;\n\nexport const StyledLiveRegion = styled.div`\n ${hideVisually}\n`;\n\nexport const StyledLightboxTitle = styled(Text)`\n max-width: 100%;\n ${ellipsisOverflow};\n`;\n\nexport const StyledLightbox = styled(Backdrop)<{ global: boolean }>(({ global, theme }) => {\n return css`\n ${global &&\n css`\n z-index: ${theme.base['z-index'].max};\n `}\n\n &:focus {\n outline: none;\n }\n `;\n});\n\nStyledLightbox.defaultProps = defaultThemeProp;\n"]}
@@ -261,7 +261,7 @@ export const StyledTemplateRow = styled.div(({ theme }) => {
261
261
  StyledTemplateRow.defaultProps = defaultThemeProp;
262
262
  export const StyledTemplate = styled.div(({ theme }) => {
263
263
  const { base: { breakpoints } } = theme;
264
- const templateHeight = 'calc(100dvh - var(--appshell-offset, 0rem))';
264
+ const templateHeight = 'calc(100dvh - var(--appshell-top-offset, 0rem))';
265
265
  return css `
266
266
  height: 100%;
267
267
  min-height: 0;
@@ -1 +1 @@
1
- {"version":3,"file":"CategorySubPage.styles.js","sourceRoot":"","sources":["../../../src/components/PageTemplates/CategorySubPage.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,EAAE,MAAM,mBAAmB,CAAC;AAEhD,OAAO,IAAI,MAAM,SAAS,CAAC;AAC3B,OAAO,MAAM,MAAM,WAAW,CAAC;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAEhF,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,MAAM,CAAC,MAAM,oBAAoB,GAAG,MAAM,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC/D,MAAM,EACJ,IAAI,EAAE,EACJ,OAAO,EAAE,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,EACpD,OAAO,EACR,EACF,GAAG,KAAK,CAAC;IAEV,OAAO,GAAG,CAAA;;WAED,OAAO;;wBAEM,iBAAiB;wBACjB,OAAO;;;;cAIjB,OAAO;;GAElB,CAAC;AACJ,CAAC,CAAC,CAAC;AACH,oBAAoB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAErD,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IAC3D,MAAM,EACJ,IAAI,EAAE,E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CAAC;IACV,MAAM,cAAc,GAAG,6CAA6C,CAAC;IAErE,OAAO,GAAG,CAAA;;;;;iCAKqB,WAAW,CAAC,EAAE;gBAC/B,cAAc;oBACV,cAAc;oBACd,cAAc;;;GAG/B,CAAC;AACJ,CAAC,CAAC,CAAC;AACH,cAAc,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport Text from '../Text';\nimport Button from '../Button';\nimport { StyledTab } from '../Tabs/Tab';\nimport { calculateFontSize, getHoverColors, readableColor } from '../../styles';\nimport type { FontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\nimport { tryCatch } from '../../utils';\n\nexport const StyledSkipNavigation = styled(Button)(({ theme }) => {\n const {\n base: {\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: absolute;\n top: ${spacing};\n left: -200vw;\n background-color: ${primaryBackground};\n padding: calc(2 * ${spacing});\n\n &:focus,\n &:active {\n left: ${spacing};\n }\n `;\n});\nStyledSkipNavigation.defaultProps = defaultThemeProp;\n\nexport const StyledNavItem = styled(StyledTab)(({ theme }) => {\n const {\n base: {\n breakpoints,\n palette: { interactive, 'app-background': hoverBase },\n spacing\n }\n } = theme;\n const hoverColors = getHoverColors(hoverBase);\n\n return css`\n height: auto;\n\n a,\n button {\n display: block;\n width: 100%;\n padding: calc(0.8 * ${spacing}) calc(2 * ${spacing});\n }\n\n &[aria-current='page'] {\n a {\n color: ${interactive};\n }\n\n &::after {\n background: ${interactive};\n }\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n a,\n button {\n text-transform: uppercase;\n padding: calc(1.5 * ${spacing}) 0;\n\n &:hover {\n text-decoration: none;\n }\n }\n }\n\n /* md or above / \"Desktop\" */\n @media all and (min-width: ${breakpoints.md}) {\n padding-left: 0;\n padding-right: 0;\n border: none;\n\n &::after {\n content: none;\n }\n\n a,\n button {\n &:hover,\n &:focus {\n background: ${hoverColors.background};\n color: ${hoverColors.foreground};\n text-decoration: none;\n }\n }\n }\n `;\n});\nStyledNavItem.defaultProps = defaultThemeProp;\n\nexport const StyledNavGroupHeader = styled(Text)(({ theme }) => {\n const {\n base: { spacing, breakpoints }\n } = theme;\n\n return css`\n padding: calc(1.5 * ${spacing}) calc(2 * ${spacing});\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n display: none;\n }\n `;\n});\nStyledNavGroupHeader.defaultProps = defaultThemeProp;\n\nexport const StyledNavGroupList = styled.ul``;\n\nexport const StyledNavGroup = styled.li(({ theme }) => {\n const {\n base: { breakpoints, spacing }\n } = theme;\n\n return css`\n margin: calc(2 * ${spacing}) 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n margin: 0;\n }\n `;\n});\nStyledNavGroup.defaultProps = defaultThemeProp;\n\nexport const StyledNavList = styled.ul(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n\n return css`\n &&,\n li {\n list-style-type: none;\n }\n\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n white-space: nowrap;\n\n li,\n > div {\n display: inline-block;\n }\n }\n\n > ${StyledNavGroup}:first-child {\n margin-top: 0;\n }\n `;\n});\nStyledNavList.defaultProps = defaultThemeProp;\n\nexport const StyledNav = styled.nav``;\n\nexport const StyledCategoryIconBlock = styled.div(({ theme }) => {\n const {\n base: {\n palette: { 'brand-primary': brandPrimary },\n 'border-radius': baseBorderRadius,\n spacing\n }\n } = theme;\n\n const color = tryCatch(() => readableColor(brandPrimary));\n\n return css`\n background: ${brandPrimary};\n width: 2rem;\n height: 2rem;\n margin-inline-end: ${spacing};\n border-radius: calc(0.5 * ${baseBorderRadius});\n\n svg {\n color: ${color};\n }\n `;\n});\nStyledCategoryIconBlock.defaultProps = defaultThemeProp;\n\nexport const StyledCategoryHeadingRow = styled.div(({ theme }) => {\n const {\n base: { breakpoints, spacing }\n } = theme;\n\n return css`\n padding: 0 calc(2 * ${spacing});\n margin-bottom: calc(2 * ${spacing});\n\n h1:focus-visible {\n outline: transparent;\n box-shadow: ${theme.base.shadow.focus};\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n margin-bottom: ${spacing};\n }\n `;\n});\nStyledCategoryHeadingRow.defaultProps = defaultThemeProp;\n\nexport const StyledMenuColumn = styled.div(({ theme }) => {\n const {\n base: {\n palette: { 'app-background': appBackground },\n breakpoints,\n spacing\n }\n } = theme;\n\n return css`\n background-color: ${appBackground};\n position: sticky;\n top: 0;\n height: 100%;\n min-height: 0;\n max-height: 100%;\n overflow-y: auto;\n width: 100%;\n padding: calc(2 * ${spacing}) 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n position: static;\n padding-bottom: 0;\n }\n\n /* md or above */\n @media all and (min-width: ${breakpoints.md}) {\n max-width: 14.438rem;\n }\n\n /* lg or above */\n @media all and (min-width: ${breakpoints.lg}) {\n max-width: 17.563rem;\n }\n\n /* xl or above */\n @media all and (min-width: ${breakpoints.xl}) {\n max-width: 20.75rem;\n }\n `;\n});\nStyledMenuColumn.defaultProps = defaultThemeProp;\n\nexport const StyledPageTitle = styled.h2(({ theme }) => {\n const {\n base: {\n 'font-weight': { 'semi-bold': fontWeight },\n 'font-size': fontSize,\n 'font-scale': fontScale\n }\n } = theme;\n\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n font-size: ${fontSizes['m' as FontSize]};\n font-weight: ${fontWeight};\n `;\n});\nStyledPageTitle.defaultProps = defaultThemeProp;\n\nexport const StyledPageActionCol = styled.div``;\n\nexport const StyledArticleHeader = styled.header(({ theme }) => {\n const {\n base: {\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: sticky;\n top: 0;\n z-index: 1;\n background-color: ${primaryBackground};\n padding: calc(2 * ${spacing}) 0 calc(3 * ${spacing});\n `;\n});\nStyledArticleHeader.defaultProps = defaultThemeProp;\n\nexport const StyledPageArticle = styled.article(({ theme }) => {\n const {\n base: {\n breakpoints,\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: relative;\n background-color: ${primaryBackground};\n width: 100%;\n height: 100%;\n min-height: 0;\n max-height: 100%;\n overflow-y: auto;\n padding: 0 calc(3 * ${spacing}) calc(2 * ${spacing});\n\n &:focus {\n outline: none;\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n padding: 0 calc(2 * ${spacing}) calc(2 * ${spacing});\n }\n `;\n});\nStyledPageArticle.defaultProps = defaultThemeProp;\n\nexport const StyledTemplateRow = styled.div(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n\n return css`\n position: relative;\n height: 100%;\n min-height: 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n flex-direction: column;\n height: auto;\n min-height: inherit;\n }\n `;\n});\nStyledTemplateRow.defaultProps = defaultThemeProp;\n\nexport const StyledTemplate = styled.div(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n const templateHeight = 'calc(100dvh - var(--appshell-offset, 0rem))';\n\n return css`\n height: 100%;\n min-height: 0;\n\n /* md or above / split-scroll layout */\n @media all and (min-width: ${breakpoints.md}) {\n height: ${templateHeight};\n min-height: ${templateHeight};\n max-height: ${templateHeight};\n overflow: hidden;\n }\n `;\n});\nStyledTemplate.defaultProps = defaultThemeProp;\n"]}
1
+ {"version":3,"file":"CategorySubPage.styles.js","sourceRoot":"","sources":["../../../src/components/PageTemplates/CategorySubPage.styles.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,EAAE,EAAE,GAAG,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,EAAE,KAAK,EAAE,EAAE,EAAE;IAC5D,MAAM,EACJ,IAAI,EAAE,EACJ,WAAW,EACX,OAAO,EAAE,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,EACpD,OAAO,EACR,EACF,GAAG,KAAK,CAAC;IAEV,OAAO,GAAG,CAAA;;wBAEY,iBAAiB;;;;;;0BAMf,OAAO,cAAc,OAAO;;;;;;;sCAOhB,WAAW,CAAC,EAAE;4BACxB,OAAO,cAAc,OAAO;;GAErD,CAAC;AACJ,CAAC,CAAC,CAAC;AACH,iBAAiB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAElD,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACxD,MAAM,EACJ,IAAI,EAAE,EAAE,WAAW,EAAE,EACtB,GAAG,KAAK,CAAC;IAEV,OAAO,GAAG,CAAA;;;;;;sCAM0B,WAAW,CAAC,EAAE;;;;;GAKjD,CAAC;AACJ,CAAC,CAAC,CAAC;AACH,iBAAiB,CAAC,YAAY,GAAG,gBAAgB,CAAC;AAElD,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE;IACrD,MAAM,EACJ,IAAI,EAAE,EAAE,WAAW,EAAE,EACtB,GAAG,KAAK,CAAC;IACV,MAAM,cAAc,GAAG,iDAAiD,CAAC;IAEzE,OAAO,GAAG,CAAA;;;;;iCAKqB,WAAW,CAAC,EAAE;gBAC/B,cAAc;oBACV,cAAc;oBACd,cAAc;;;GAG/B,CAAC;AACJ,CAAC,CAAC,CAAC;AACH,cAAc,CAAC,YAAY,GAAG,gBAAgB,CAAC","sourcesContent":["import styled, { css } from 'styled-components';\n\nimport Text from '../Text';\nimport Button from '../Button';\nimport { StyledTab } from '../Tabs/Tab';\nimport { calculateFontSize, getHoverColors, readableColor } from '../../styles';\nimport type { FontSize } from '../../styles';\nimport { defaultThemeProp } from '../../theme';\nimport { tryCatch } from '../../utils';\n\nexport const StyledSkipNavigation = styled(Button)(({ theme }) => {\n const {\n base: {\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: absolute;\n top: ${spacing};\n left: -200vw;\n background-color: ${primaryBackground};\n padding: calc(2 * ${spacing});\n\n &:focus,\n &:active {\n left: ${spacing};\n }\n `;\n});\nStyledSkipNavigation.defaultProps = defaultThemeProp;\n\nexport const StyledNavItem = styled(StyledTab)(({ theme }) => {\n const {\n base: {\n breakpoints,\n palette: { interactive, 'app-background': hoverBase },\n spacing\n }\n } = theme;\n const hoverColors = getHoverColors(hoverBase);\n\n return css`\n height: auto;\n\n a,\n button {\n display: block;\n width: 100%;\n padding: calc(0.8 * ${spacing}) calc(2 * ${spacing});\n }\n\n &[aria-current='page'] {\n a {\n color: ${interactive};\n }\n\n &::after {\n background: ${interactive};\n }\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n a,\n button {\n text-transform: uppercase;\n padding: calc(1.5 * ${spacing}) 0;\n\n &:hover {\n text-decoration: none;\n }\n }\n }\n\n /* md or above / \"Desktop\" */\n @media all and (min-width: ${breakpoints.md}) {\n padding-left: 0;\n padding-right: 0;\n border: none;\n\n &::after {\n content: none;\n }\n\n a,\n button {\n &:hover,\n &:focus {\n background: ${hoverColors.background};\n color: ${hoverColors.foreground};\n text-decoration: none;\n }\n }\n }\n `;\n});\nStyledNavItem.defaultProps = defaultThemeProp;\n\nexport const StyledNavGroupHeader = styled(Text)(({ theme }) => {\n const {\n base: { spacing, breakpoints }\n } = theme;\n\n return css`\n padding: calc(1.5 * ${spacing}) calc(2 * ${spacing});\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n display: none;\n }\n `;\n});\nStyledNavGroupHeader.defaultProps = defaultThemeProp;\n\nexport const StyledNavGroupList = styled.ul``;\n\nexport const StyledNavGroup = styled.li(({ theme }) => {\n const {\n base: { breakpoints, spacing }\n } = theme;\n\n return css`\n margin: calc(2 * ${spacing}) 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n margin: 0;\n }\n `;\n});\nStyledNavGroup.defaultProps = defaultThemeProp;\n\nexport const StyledNavList = styled.ul(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n\n return css`\n &&,\n li {\n list-style-type: none;\n }\n\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n white-space: nowrap;\n\n li,\n > div {\n display: inline-block;\n }\n }\n\n > ${StyledNavGroup}:first-child {\n margin-top: 0;\n }\n `;\n});\nStyledNavList.defaultProps = defaultThemeProp;\n\nexport const StyledNav = styled.nav``;\n\nexport const StyledCategoryIconBlock = styled.div(({ theme }) => {\n const {\n base: {\n palette: { 'brand-primary': brandPrimary },\n 'border-radius': baseBorderRadius,\n spacing\n }\n } = theme;\n\n const color = tryCatch(() => readableColor(brandPrimary));\n\n return css`\n background: ${brandPrimary};\n width: 2rem;\n height: 2rem;\n margin-inline-end: ${spacing};\n border-radius: calc(0.5 * ${baseBorderRadius});\n\n svg {\n color: ${color};\n }\n `;\n});\nStyledCategoryIconBlock.defaultProps = defaultThemeProp;\n\nexport const StyledCategoryHeadingRow = styled.div(({ theme }) => {\n const {\n base: { breakpoints, spacing }\n } = theme;\n\n return css`\n padding: 0 calc(2 * ${spacing});\n margin-bottom: calc(2 * ${spacing});\n\n h1:focus-visible {\n outline: transparent;\n box-shadow: ${theme.base.shadow.focus};\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n margin-bottom: ${spacing};\n }\n `;\n});\nStyledCategoryHeadingRow.defaultProps = defaultThemeProp;\n\nexport const StyledMenuColumn = styled.div(({ theme }) => {\n const {\n base: {\n palette: { 'app-background': appBackground },\n breakpoints,\n spacing\n }\n } = theme;\n\n return css`\n background-color: ${appBackground};\n position: sticky;\n top: 0;\n height: 100%;\n min-height: 0;\n max-height: 100%;\n overflow-y: auto;\n width: 100%;\n padding: calc(2 * ${spacing}) 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n position: static;\n padding-bottom: 0;\n }\n\n /* md or above */\n @media all and (min-width: ${breakpoints.md}) {\n max-width: 14.438rem;\n }\n\n /* lg or above */\n @media all and (min-width: ${breakpoints.lg}) {\n max-width: 17.563rem;\n }\n\n /* xl or above */\n @media all and (min-width: ${breakpoints.xl}) {\n max-width: 20.75rem;\n }\n `;\n});\nStyledMenuColumn.defaultProps = defaultThemeProp;\n\nexport const StyledPageTitle = styled.h2(({ theme }) => {\n const {\n base: {\n 'font-weight': { 'semi-bold': fontWeight },\n 'font-size': fontSize,\n 'font-scale': fontScale\n }\n } = theme;\n\n const fontSizes = calculateFontSize(fontSize, fontScale);\n\n return css`\n font-size: ${fontSizes['m' as FontSize]};\n font-weight: ${fontWeight};\n `;\n});\nStyledPageTitle.defaultProps = defaultThemeProp;\n\nexport const StyledPageActionCol = styled.div``;\n\nexport const StyledArticleHeader = styled.header(({ theme }) => {\n const {\n base: {\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: sticky;\n top: 0;\n z-index: 1;\n background-color: ${primaryBackground};\n padding: calc(2 * ${spacing}) 0 calc(3 * ${spacing});\n `;\n});\nStyledArticleHeader.defaultProps = defaultThemeProp;\n\nexport const StyledPageArticle = styled.article(({ theme }) => {\n const {\n base: {\n breakpoints,\n palette: { 'primary-background': primaryBackground },\n spacing\n }\n } = theme;\n\n return css`\n position: relative;\n background-color: ${primaryBackground};\n width: 100%;\n height: 100%;\n min-height: 0;\n max-height: 100%;\n overflow-y: auto;\n padding: 0 calc(3 * ${spacing}) calc(2 * ${spacing});\n\n &:focus {\n outline: none;\n }\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n padding: 0 calc(2 * ${spacing}) calc(2 * ${spacing});\n }\n `;\n});\nStyledPageArticle.defaultProps = defaultThemeProp;\n\nexport const StyledTemplateRow = styled.div(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n\n return css`\n position: relative;\n height: 100%;\n min-height: 0;\n\n /* sm or below / \"Mobile\" (note: 0.0625em = 1px) */\n @media all and (max-width: calc(${breakpoints.md} - 0.0625em)) {\n flex-direction: column;\n height: auto;\n min-height: inherit;\n }\n `;\n});\nStyledTemplateRow.defaultProps = defaultThemeProp;\n\nexport const StyledTemplate = styled.div(({ theme }) => {\n const {\n base: { breakpoints }\n } = theme;\n const templateHeight = 'calc(100dvh - var(--appshell-top-offset, 0rem))';\n\n return css`\n height: 100%;\n min-height: 0;\n\n /* md or above / split-scroll layout */\n @media all and (min-width: ${breakpoints.md}) {\n height: ${templateHeight};\n min-height: ${templateHeight};\n max-height: ${templateHeight};\n overflow: hidden;\n }\n `;\n});\nStyledTemplate.defaultProps = defaultThemeProp;\n"]}
@@ -19,7 +19,7 @@ export const StyledDashboardRegion = styled(StyledRegion) `
19
19
  `;
20
20
  StyledDashboardRegion.defaultProps = defaultThemeProp;
21
21
  export const StyledDashboardPageLayout = styled(StyledPageLayout)(({ fitToViewport, theme: { base: { palette: { 'primary-background': primaryBackground, 'secondary-background': secondaryBackground } }, components: { tabs: { detached: detachedTabs } } } }) => {
22
- const height = 'calc(100dvh - var(--appshell-offset, 0rem))';
22
+ const height = 'calc(100dvh - var(--appshell-top-offset, 0rem))';
23
23
  return css `
24
24
  min-height: ${height};
25
25
  background-color: ${detachedTabs ? primaryBackground : secondaryBackground};