@synerise/ds-sidebar 2.0.12 → 2.1.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
@@ -3,6 +3,25 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [2.1.1](https://github.com/Synerise/synerise-design/compare/@synerise/ds-sidebar@2.1.0...@synerise/ds-sidebar@2.1.1) (2026-11-03)
7
+
8
+ **Note:** Version bump only for package @synerise/ds-sidebar
9
+
10
+
11
+
12
+
13
+
14
+ # [2.1.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-sidebar@2.0.12...@synerise/ds-sidebar@2.1.0) (2026-10-29)
15
+
16
+
17
+ ### Features
18
+
19
+ * integrate Token Studio design tokens across the design system ([aabb447](https://github.com/Synerise/synerise-design/commit/aabb447edfb2d0c85e3de1f07e809ef84083453b))
20
+
21
+
22
+
23
+
24
+
6
25
  ## [2.0.12](https://github.com/Synerise/synerise-design/compare/@synerise/ds-sidebar@2.0.11...@synerise/ds-sidebar@2.0.12) (2026-10-28)
7
26
 
8
27
  **Note:** Version bump only for package @synerise/ds-sidebar
package/CLAUDE.md CHANGED
@@ -101,7 +101,7 @@ import Sidebar from '@synerise/ds-sidebar';
101
101
 
102
102
  ## Styling
103
103
 
104
- `StyledCollapse` in `Sidebar.styles.ts` styles the DS accordion DOM via its `.ant-collapse-*` class hooks (retained for ui-tests / interim external CSS; `ds-sidebar-*` emitted alongside). Header padding is `18px 24px`. Content padding is `16px 24px`. Background is `blue-050`. The drag handle (`SidebarHandle`) is `cursor: grabbing` and positioned absolutely on the left of the header.
104
+ `StyledCollapse` in `Sidebar.styles.ts` styles the DS accordion DOM via its `.ant-collapse-*` class hooks (retained for ui-tests / interim external CSS; `ds-sidebar-*` emitted alongside). Header padding is `18px 24px`. Content padding is `16px 24px`. The accordion root background is `var(--ds-color-background-brand-subtle)` (`CollapseRoot` in `Collapse/Collapse.styles.ts`). The drag handle (`SidebarHandle`) is `cursor: grabbing` and positioned absolutely on the left of the header.
105
105
 
106
106
  ## Key dependencies
107
107
 
@@ -1,5 +1,5 @@
1
1
  import { CollapseExpandIconPosition } from './Collapse.types';
2
- export declare const headerStyle: import('styled-components').FlattenInterpolation<import('styled-components').ThemeProps<any>>;
2
+ export declare const headerStyle: import('styled-components').FlattenSimpleInterpolation;
3
3
  export declare const expandIconStyle: import('styled-components').FlattenSimpleInterpolation;
4
4
  export declare const CollapseRoot: import('styled-components').StyledComponent<"div", any, {}, never>;
5
5
  export declare const PanelItem: import('styled-components').StyledComponent<"div", any, {
@@ -1,14 +1,14 @@
1
1
  import styled, { css } from "styled-components";
2
- const headerStyle = /* @__PURE__ */ css(["padding:18px 24px;color:", ";font-weight:500;font-size:14px;background:white;position:relative;cursor:pointer;&:hover{color:", ";}"], (props) => props.theme.palette["grey-700"], (props) => props.theme.palette["grey-800"]);
2
+ const headerStyle = /* @__PURE__ */ css(["padding:18px 24px;color:var(--ds-color-text-base-subtle);font-weight:500;font-size:14px;background:var(--ds-color-background-base-default);position:relative;cursor:pointer;&:hover{color:var(--ds-color-text-base-default);}"]);
3
3
  const expandIconStyle = /* @__PURE__ */ css(["position:absolute;right:24px;top:50%;transform:translateY(-50%);"]);
4
4
  const CollapseRoot = /* @__PURE__ */ styled.div.withConfig({
5
5
  displayName: "Collapsestyles__CollapseRoot",
6
6
  componentId: "sc-1eq1yr7-0"
7
- })(["background-color:", ";border:none;"], (props) => props.theme.palette["blue-050"]);
7
+ })(["background-color:var(--ds-color-background-brand-subtle);border:none;"]);
8
8
  const PanelItem = /* @__PURE__ */ styled.div.withConfig({
9
9
  displayName: "Collapsestyles__PanelItem",
10
10
  componentId: "sc-1eq1yr7-1"
11
- })(["position:relative;border-top:solid 1px ", ";border-bottom:none;", ""], (props) => props.theme.palette["grey-200"], (props) => props.$isDragOverlay && css(["box-shadow:", ";z-index:10;"], props.theme.variables["box-shadow-2"]));
11
+ })(["position:relative;border-top:solid 1px var(--ds-color-border-base-default);border-bottom:none;", ""], (props) => props.$isDragOverlay && css(["box-shadow:var(--ds-shadows-shadow-2);z-index:10;"]));
12
12
  const PanelHeader = /* @__PURE__ */ styled.div.withConfig({
13
13
  displayName: "Collapsestyles__PanelHeader",
14
14
  componentId: "sc-1eq1yr7-2"
@@ -20,7 +20,7 @@ const PanelExpandIcon = /* @__PURE__ */ styled.span.withConfig({
20
20
  const PanelContent = /* @__PURE__ */ styled.div.withConfig({
21
21
  displayName: "Collapsestyles__PanelContent",
22
22
  componentId: "sc-1eq1yr7-4"
23
- })(["background-color:white;border-radius:0;border:none;display:grid;grid-template-rows:", ";transition:grid-template-rows 0.24s ease;overflow:hidden;"], (props) => props.$isActive ? "1fr" : "0fr");
23
+ })(["background-color:var(--ds-color-background-base-default);border-radius:0;border:none;display:grid;grid-template-rows:", ";transition:grid-template-rows 0.24s ease;overflow:hidden;"], (props) => props.$isActive ? "1fr" : "0fr");
24
24
  const PanelContentBox = /* @__PURE__ */ styled.div.withConfig({
25
25
  displayName: "Collapsestyles__PanelContentBox",
26
26
  componentId: "sc-1eq1yr7-5"
@@ -1,5 +1,4 @@
1
1
  import { jsxs, jsx } from "react/jsx-runtime";
2
- import { theme } from "@synerise/ds-core";
3
2
  import Icon, { DragHandleM, AngleUpS, AngleDownS } from "@synerise/ds-icon";
4
3
  import { DragOverlay, DragOverlayHeader, SidebarHeader, SidebarHandle, ExpandIcon, DragOverlayContent, SidebarContentWrapper } from "../Sidebar.styles.js";
5
4
  const DragOverlayPanel = ({
@@ -12,8 +11,8 @@ const DragOverlayPanel = ({
12
11
  return /* @__PURE__ */ jsxs(DragOverlay, { children: [
13
12
  /* @__PURE__ */ jsx(DragOverlayHeader, { children: /* @__PURE__ */ jsxs(SidebarHeader, { children: [
14
13
  /* @__PURE__ */ jsx("span", { children: header }),
15
- /* @__PURE__ */ jsx(SidebarHandle, { "data-testid": "ds-sidebar-header-handle", children: /* @__PURE__ */ jsx(Icon, { color: theme.palette["grey-400"], component: /* @__PURE__ */ jsx(DragHandleM, {}) }) }),
16
- /* @__PURE__ */ jsx(ExpandIcon, { children: /* @__PURE__ */ jsx(Icon, { color: theme.palette["grey-600"], component: isActive ? /* @__PURE__ */ jsx(AngleUpS, {}) : /* @__PURE__ */ jsx(AngleDownS, {}) }) })
14
+ /* @__PURE__ */ jsx(SidebarHandle, { "data-testid": "ds-sidebar-header-handle", children: /* @__PURE__ */ jsx(Icon, { color: "var(--ds-color-icon-base-muted)", component: /* @__PURE__ */ jsx(DragHandleM, {}) }) }),
15
+ /* @__PURE__ */ jsx(ExpandIcon, { children: /* @__PURE__ */ jsx(Icon, { color: "var(--ds-color-icon-base-default)", component: isActive ? /* @__PURE__ */ jsx(AngleUpS, {}) : /* @__PURE__ */ jsx(AngleDownS, {}) }) })
17
16
  ] }) }),
18
17
  (isActive || forceRender) && /* @__PURE__ */ jsx(DragOverlayContent, { children: /* @__PURE__ */ jsx(SidebarContentWrapper, { children }) })
19
18
  ] }, `sidebar-drag-overlay-${id}`);
@@ -1,5 +1,4 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { theme } from "@synerise/ds-core";
3
2
  import Icon, { DragHandleM } from "@synerise/ds-icon";
4
3
  import { CollapsePanel } from "../Collapse/CollapsePanel.js";
5
4
  import { SidebarContentWrapper, SidebarHeader, SidebarHandle } from "../Sidebar.styles.js";
@@ -13,7 +12,7 @@ const PanelContent = ({
13
12
  }) => {
14
13
  return /* @__PURE__ */ jsx(CollapsePanel, { header: /* @__PURE__ */ jsxs(SidebarHeader, { children: [
15
14
  /* @__PURE__ */ jsx("span", { "data-testid": `header-${id}`, children: header }),
16
- draggable && /* @__PURE__ */ jsx(SidebarHandle, { "data-testid": "ds-sidebar-header-handle", ...dragHandleProps, children: /* @__PURE__ */ jsx(Icon, { color: theme.palette["grey-400"], component: /* @__PURE__ */ jsx(DragHandleM, {}) }) })
15
+ draggable && /* @__PURE__ */ jsx(SidebarHandle, { "data-testid": "ds-sidebar-header-handle", ...dragHandleProps, children: /* @__PURE__ */ jsx(Icon, { color: "var(--ds-color-icon-base-muted)", component: /* @__PURE__ */ jsx(DragHandleM, {}) }) })
17
16
  ] }), isDragOverlay: id === "-1", ...props, children: /* @__PURE__ */ jsx(SidebarContentWrapper, { children }) }, id);
18
17
  };
19
18
  export {
package/dist/Sidebar.js CHANGED
@@ -2,7 +2,6 @@ import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useState, useRef, useMemo, useCallback, Children, createElement } from "react";
3
3
  import classNames from "classnames";
4
4
  import { createPortal } from "react-dom";
5
- import { useTheme } from "@synerise/ds-core";
6
5
  import Icon, { AngleUpS, AngleDownS } from "@synerise/ds-icon";
7
6
  import { DragOverlay, SortableContainer } from "@synerise/ds-sortable";
8
7
  import { Collapse } from "./Collapse/Collapse.js";
@@ -22,7 +21,6 @@ const Sidebar = ({
22
21
  }) => {
23
22
  const [draggedItem, setDraggedItem] = useState();
24
23
  const isSortable = Array.isArray(order) && order.length > 0 && !!onChangeOrder;
25
- const theme = useTheme();
26
24
  const wrapperRef = useRef(null);
27
25
  const [activeKeys, setActiveKeys] = useState(() => {
28
26
  if (!activeKey && !defaultActiveKey) {
@@ -74,10 +72,10 @@ const Sidebar = ({
74
72
  "is-drag-drop": isSortable
75
73
  }, className), expandIconPosition: "end", expandIcon: ({
76
74
  isActive
77
- }) => /* @__PURE__ */ jsx(Icon, { color: theme.palette["grey-600"], component: isActive ? /* @__PURE__ */ jsx(AngleUpS, {}) : /* @__PURE__ */ jsx(AngleDownS, {}) }), onChange: handleOnChange, ...collapseProps, children: isSortable ? sortedChildren : children }),
75
+ }) => /* @__PURE__ */ jsx(Icon, { color: "var(--ds-color-icon-base-default)", component: isActive ? /* @__PURE__ */ jsx(AngleUpS, {}) : /* @__PURE__ */ jsx(AngleDownS, {}) }), onChange: handleOnChange, ...collapseProps, children: isSortable ? sortedChildren : children }),
78
76
  wrapperRef.current && getPopupContainer ? createPortal(dragOverlay, getPopupContainer(wrapperRef.current)) : dragOverlay
79
77
  ] });
80
- }, [draggedItem, isDraggedPanelActive, activeKey, defaultActiveKey, isSortable, className, handleOnChange, collapseProps, sortedChildren, children, getPopupContainer, theme.palette]);
78
+ }, [draggedItem, isDraggedPanelActive, activeKey, defaultActiveKey, isSortable, className, handleOnChange, collapseProps, sortedChildren, children, getPopupContainer]);
81
79
  return isSortable ? /* @__PURE__ */ jsx(SortableContainer, { axis: "y", items: sortableItems, onDragStart: handleDragStart, onDragEnd: handleDragEnd, onDragCancel: handleDragEnd, onOrderChange: handleOrderChange, children: /* @__PURE__ */ jsx(SidebarContext.Provider, { value: {
82
80
  isSortable
83
81
  }, children: collapseContent }) }) : collapseContent;
@@ -23,11 +23,11 @@ const DragOverlay = /* @__PURE__ */ styled.div.withConfig({
23
23
  const DragOverlayHeader = /* @__PURE__ */ styled.div.withConfig({
24
24
  displayName: "Sidebarstyles__DragOverlayHeader",
25
25
  componentId: "sc-19um1hw-5"
26
- })(["border-top:1px solid ", ";", " user-select:none;"], (props) => props.theme.palette["grey-200"], headerStyle);
26
+ })(["border-top:1px solid var(--ds-color-border-base-default);", " user-select:none;"], headerStyle);
27
27
  const DragOverlayContent = /* @__PURE__ */ styled.div.withConfig({
28
28
  displayName: "Sidebarstyles__DragOverlayContent",
29
29
  componentId: "sc-19um1hw-6"
30
- })(["background-color:white;padding:16px 24px;"]);
30
+ })(["background-color:var(--ds-color-background-base-default);padding:16px 24px;"]);
31
31
  const ExpandIcon = /* @__PURE__ */ styled.div.withConfig({
32
32
  displayName: "Sidebarstyles__ExpandIcon",
33
33
  componentId: "sc-19um1hw-7"
@@ -2,7 +2,7 @@ import styled from "styled-components";
2
2
  const SidebarWithButtonWrapper = /* @__PURE__ */ styled.div.withConfig({
3
3
  displayName: "SidebarWithButtonstyles__SidebarWithButtonWrapper",
4
4
  componentId: "sc-1h2ysa0-0"
5
- })(["display:flex;align-items:center;justify-content:center;padding:12px;font-weight:500;color:", ";"], (props) => props.theme.palette["grey-700"]);
5
+ })(["display:flex;align-items:center;justify-content:center;padding:12px;font-weight:500;color:var(--ds-color-text-base-subtle);"]);
6
6
  const TextWrapper = /* @__PURE__ */ styled.div.withConfig({
7
7
  displayName: "SidebarWithButtonstyles__TextWrapper",
8
8
  componentId: "sc-1h2ysa0-1"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synerise/ds-sidebar",
3
- "version": "2.0.12",
3
+ "version": "2.1.1",
4
4
  "description": "Sidebar UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "Synerise/synerise-design",
@@ -42,12 +42,12 @@
42
42
  ],
43
43
  "types": "dist/index.d.ts",
44
44
  "dependencies": {
45
- "@synerise/ds-button": "^2.1.6",
46
- "@synerise/ds-dropdown": "^2.1.8",
47
- "@synerise/ds-icon": "^2.2.3",
48
- "@synerise/ds-list-item": "^2.2.4",
49
- "@synerise/ds-sortable": "^2.0.5",
50
- "@synerise/ds-utils": "^2.2.2",
45
+ "@synerise/ds-button": "^2.2.1",
46
+ "@synerise/ds-dropdown": "^2.2.1",
47
+ "@synerise/ds-icon": "^2.3.1",
48
+ "@synerise/ds-list-item": "^2.4.0",
49
+ "@synerise/ds-sortable": "^2.1.1",
50
+ "@synerise/ds-utils": "^2.3.1",
51
51
  "classnames": "^2.5.1"
52
52
  },
53
53
  "devDependencies": {
@@ -59,5 +59,5 @@
59
59
  "react-dom": ">=16.9.0 <= 18.3.1",
60
60
  "styled-components": "^5.3.3"
61
61
  },
62
- "gitHead": "c356039703d8826bbbdb6dadcb18bb008fea8bc5"
62
+ "gitHead": "2d2a540b35fddf8855da45f0dec2f4612c6d87b6"
63
63
  }