@stack-spot/portal-layout 2.21.2 → 2.22.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,19 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.22.1](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.22.0...portal-layout@v2.22.1) (2025-01-16)
4
+
5
+
6
+ ### Bug Fixes
7
+
8
+ * change notification panel width ([004dafc](https://github.com/stack-spot/portal-commons/commit/004dafc8c5069d0ce95738e81979e316f9101a2d))
9
+
10
+ ## [2.22.0](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.21.2...portal-layout@v2.22.0) (2025-01-15)
11
+
12
+
13
+ ### Features
14
+
15
+ * add new prop onClickViewNotification ([5252d3b](https://github.com/stack-spot/portal-commons/commit/5252d3bdd01d81735a56fbcbd2cd12ed4c1aff53))
16
+
3
17
  ## [2.21.2](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.21.1...portal-layout@v2.21.2) (2025-01-06)
4
18
 
5
19
 
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationPanel.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationPanel.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAA;AAEhD,eAAO,MAAM,iBAAiB,qEAAsE,sBAAsB,4CAyBzH,CAAA"}
1
+ {"version":3,"file":"NotificationPanel.d.ts","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationPanel.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAE,sBAAsB,EAAE,MAAM,SAAS,CAAA;AAEhD,eAAO,MAAM,iBAAiB,qEAAsE,sBAAsB,4CA6BzH,CAAA"}
@@ -8,7 +8,10 @@ import { NotificationPanelFooter } from './NotificationsPanelFooter.js';
8
8
  import { StyledBackdrop } from './styled.js';
9
9
  export const NotificationPanel = ({ filter, onFilter, loading, error, visible, onClose, ...props }) => {
10
10
  const controller = useNotificationController();
11
- return (_jsx(StyledBackdrop, { visible: visible, onClose: onClose, persistent: true, children: _jsx(AnimatedHeight, { className: "notification-panel", visible: visible, header: _jsx(NotificationPanelHeader, { filter: filter, onChangeFilter: onFilter, onClose: onClose }), footer: _jsx(NotificationPanelFooter, { onClose: onClose }), children: _jsx(ScrollView, { direction: "vertical", style: { maxHeight: 'calc(100vh - 300px)' }, children: error ? _jsx(ErrorFeedback, { code: error.code, direction: "column" }) : _jsx(NotificationList, { ...props, compact: true, loading: loading, onCommit: id => controller.markAsCommitted(id), onClickAction: (id) => {
11
+ return (_jsx(StyledBackdrop, { visible: visible, onClose: onClose, persistent: true, children: _jsx(AnimatedHeight, { className: "notification-panel", visible: visible, header: _jsx(NotificationPanelHeader, { filter: filter, onChangeFilter: onFilter, onClose: onClose }), footer: _jsx(NotificationPanelFooter, { onClose: onClose }), children: _jsx(ScrollView, { direction: "vertical", style: { maxHeight: 'calc(100vh - 300px)' }, children: error ? _jsx(ErrorFeedback, { code: error.code, direction: "column" }) : _jsx(NotificationList, { ...props, compact: true, loading: loading, onCommit: id => controller.markAsCommitted(id), onClickViewNotification: () => {
12
+ onClose();
13
+ controller.config.onClickViewNotification?.();
14
+ }, onClickAction: (id) => {
12
15
  onClose();
13
16
  controller.config.onClickAction?.(id);
14
17
  } }) }) }) }));
@@ -1 +1 @@
1
- {"version":3,"file":"NotificationPanel.js","sourceRoot":"","sources":["../../../src/components/NotificationCenter/NotificationPanel.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,8CAA8C,CAAA;AAC7E,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAA;AACnE,OAAO,EAAE,gBAAgB,EAAE,yBAAyB,EAAE,MAAM,6CAA6C,CAAA;AACzG,OAAO,EAAE,UAAU,EAAE,MAAM,0CAA0C,CAAA;AACrE,OAAO,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAA;AACnE,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AO,EAAE,OAAO,EAChB,QAAQ,EAAE,EAAE,CAAC,EAAE,CAAC,UAAU,CAAC,eAAe,CAAC,EAAE,CAAC,EAC9C,uBAAuB,EAAE,GAAG,EAAE;wBAC5B,OAAO,EAAE,CAAA;wBACT,UAAU,CAAC,MAAM,CAAC,uBAAuB,EAAE,EAAE,CAAA;oBAC/C,CAAC,EACD,aAAa,EAAE,CAAC,EAAE,EAAE,EAAE;wBACpB,OAAO,EAAE,CAAA;wBACT,UAAU,CAAC,MAAM,CAAC,aAAa,EAAE,CAAC,EAAE,CAAC,CAAA;oBACvC,CAAC,GACD,GACS,GACE,GACF,CAClB,CAAA;AACH,CAAC,CAAA"}
@@ -38,7 +38,7 @@ export const StyledBackdrop = styled(Backdrop) `
38
38
  box-shadow: 4px 4px 48px ${theme.color.danger.contrastText};
39
39
 
40
40
  .notification-panel {
41
- width: 368px;
41
+ width: 400px;
42
42
  padding: 16px;
43
43
  border-radius: 4px;
44
44
  background-color: ${theme.color.light[300]};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stack-spot/portal-layout",
3
- "version": "2.21.2",
3
+ "version": "2.22.1",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -15,7 +15,7 @@
15
15
  "@citric/ui": "^6.5.5",
16
16
  "@stack-spot/portal-theme": "^1.0.0",
17
17
  "@stack-spot/portal-translate": "^1.1.0",
18
- "@stack-spot/portal-components": "^2.11.0",
18
+ "@stack-spot/portal-components": "^2.12.0",
19
19
  "react": "^18.2.0",
20
20
  "react-dom": "^18.2.0",
21
21
  "styled-components": "^6.1.10"
@@ -23,6 +23,10 @@ export const NotificationPanel = ({ filter, onFilter, loading, error, visible, o
23
23
  compact
24
24
  loading={loading}
25
25
  onCommit={id => controller.markAsCommitted(id)}
26
+ onClickViewNotification={() => {
27
+ onClose()
28
+ controller.config.onClickViewNotification?.()
29
+ }}
26
30
  onClickAction={(id) => {
27
31
  onClose()
28
32
  controller.config.onClickAction?.(id)
@@ -40,7 +40,7 @@ export const StyledBackdrop = styled(Backdrop)`
40
40
  box-shadow: 4px 4px 48px ${theme.color.danger.contrastText};
41
41
 
42
42
  .notification-panel {
43
- width: 368px;
43
+ width: 400px;
44
44
  padding: 16px;
45
45
  border-radius: 4px;
46
46
  background-color: ${theme.color.light[300]};