@synerise/ds-logic 2.0.11 → 2.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,17 @@
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.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-logic@2.0.11...@synerise/ds-logic@2.1.0) (2026-10-29)
7
+
8
+
9
+ ### Features
10
+
11
+ * integrate Token Studio design tokens across the design system ([aabb447](https://github.com/Synerise/synerise-design/commit/aabb447edfb2d0c85e3de1f07e809ef84083453b))
12
+
13
+
14
+
15
+
16
+
6
17
  ## [2.0.11](https://github.com/Synerise/synerise-design/compare/@synerise/ds-logic@2.0.10...@synerise/ds-logic@2.0.11) (2026-10-28)
7
18
 
8
19
  **Note:** Version bump only for package @synerise/ds-logic
package/CLAUDE.md CHANGED
@@ -118,11 +118,11 @@ import { Placeholder } from '@synerise/ds-logic';
118
118
 
119
119
  ## Styling
120
120
 
121
- - `Logic`: `styled.div` — dashed bottom border via `::after` pseudo-element (grey-600, hidden in `readOnly`); hover changes text and border to `blue-700`.
122
- - `Matching` toggle: `styled.span` — green (`green-600`/`green-700` hover) when `matching=true`, red (`red-600`/`red-700` hover) when `matching=false`; grey-800 when `readOnly`.
121
+ - `Logic`: `styled.div` — dashed bottom border via `::after` pseudo-element (`--ds-color-text-base-muted`, hidden in `readOnly`); hover changes text and border to `--ds-color-text-brand-defaulthover`.
122
+ - `Matching` toggle: `styled.span` — green (`--ds-color-background-success-solid` / `-solidactive` hover) when `matching=true`, red (`--ds-color-background-danger-solid` / `-solidactive` hover) when `matching=false`; `--ds-color-text-base-default` when `readOnly`.
123
123
  - Both use `user-select: none`.
124
- - `Placeholder`: fixed `min-height: 63px`, white background, icon + text centered in a row.
125
- - All colour values come from `theme.palette` tokens — no hardcoded hex values.
124
+ - `Placeholder`: fixed `min-height: 63px`, `--ds-color-background-base-default` background, icon + text centered in a row.
125
+ - All colour values come from `var(--ds-*)` tokens — no hardcoded hex values.
126
126
 
127
127
  ## Key dependencies
128
128
 
@@ -3,8 +3,7 @@ const Logic = /* @__PURE__ */ styled.div.withConfig({
3
3
  displayName: "Logicstyle__Logic",
4
4
  componentId: "sc-yp0pif-0"
5
5
  })(["user-select:none;position:relative;.ds-title{cursor:pointer;", "}", ""], ({
6
- readOnly,
7
- theme
6
+ readOnly
8
7
  }) => !readOnly ? `&:after {
9
8
  position: absolute;
10
9
  bottom: -2px;
@@ -14,23 +13,22 @@ const Logic = /* @__PURE__ */ styled.div.withConfig({
14
13
  left: 1px;
15
14
  background-image: linear-gradient(
16
15
  to right,
17
- ${theme.palette["grey-600"]} 25%,
18
- ${theme.palette.white} 0%
16
+ var(--ds-color-text-base-muted) 25%,
17
+ transparent 0%
19
18
  );
20
19
  background-position: top;
21
20
  background-size: 4px 1px;
22
21
  background-repeat: repeat-x;
23
22
  }` : "", ({
24
- readOnly,
25
- theme
23
+ readOnly
26
24
  }) => !readOnly ? ` &:hover {
27
25
  .ds-title {
28
- color: ${theme.palette["blue-700"]};
26
+ color: var(--ds-color-text-brand-defaulthover);
29
27
  &:after {
30
28
  background-image: linear-gradient(
31
29
  to right,
32
- ${theme.palette["blue-700"]} 25%,
33
- ${theme.palette.white} 0%
30
+ var(--ds-color-text-brand-defaulthover) 25%,
31
+ transparent 0%
34
32
  );
35
33
  }
36
34
  }
@@ -1,28 +1,28 @@
1
1
  import styled, { css } from "styled-components";
2
2
  const getColor = ({
3
- theme,
4
3
  matching,
5
4
  readOnly,
6
5
  hovered = false
7
6
  }) => {
8
7
  if (readOnly) {
9
- return theme.palette[`grey-800`];
8
+ return "var(--ds-color-text-base-default)";
10
9
  }
11
- const hue = hovered ? "700" : "600";
12
- return theme.palette[matching ? `green-${hue}` : `red-${hue}`];
10
+ if (matching) {
11
+ return hovered ? "var(--ds-color-background-success-solidactive)" : "var(--ds-color-background-success-solid)";
12
+ }
13
+ return hovered ? "var(--ds-color-background-danger-solidactive)" : "var(--ds-color-background-danger-solid)";
13
14
  };
14
15
  const MatchingWrapper = /* @__PURE__ */ styled.div.withConfig({
15
16
  displayName: "Matchingstyles__MatchingWrapper",
16
17
  componentId: "sc-7z57qz-0"
17
- })(["font-size:16px;font-weight:500;line-height:1.25;color:", ";text-align:left;user-select:none;&:first-letter{text-transform:uppercase;}"], (props) => props.theme.palette["grey-800"]);
18
+ })(["font-size:16px;font-weight:500;line-height:1.25;color:var(--ds-color-text-base-default);text-align:left;user-select:none;&:first-letter{text-transform:uppercase;}"]);
18
19
  const Toggle = /* @__PURE__ */ styled.span.withConfig({
19
20
  displayName: "Matchingstyles__Toggle",
20
21
  componentId: "sc-7z57qz-1"
21
22
  })(["cursor:pointer;font-size:16px;font-weight:500;line-height:1.25;color:", ";transition:color 0.1s ease-in-out;position:relative;display:inline-flex;", " ", ""], getColor, (props) => {
22
23
  const color = getColor(props);
23
24
  const {
24
- readOnly,
25
- theme
25
+ readOnly
26
26
  } = props;
27
27
  return !readOnly && `
28
28
  &:after {
@@ -35,7 +35,7 @@ const Toggle = /* @__PURE__ */ styled.span.withConfig({
35
35
  background-image: linear-gradient(
36
36
  to right,
37
37
  ${color} 25%,
38
- ${theme.palette.white} 0%
38
+ transparent 0%
39
39
  );
40
40
  background-position: top;
41
41
  background-size: 4px 1px;
@@ -47,10 +47,9 @@ const Toggle = /* @__PURE__ */ styled.span.withConfig({
47
47
  hovered: true
48
48
  });
49
49
  const {
50
- readOnly,
51
- theme
50
+ readOnly
52
51
  } = props;
53
- return !readOnly && css(["&:hover{color:", ";&:after{background-image:linear-gradient( to right,", " 25%,", " 0% );}"], hoveredColor, hoveredColor, theme.palette.white);
52
+ return !readOnly && css(["&:hover{color:", ";&:after{background-image:linear-gradient( to right,", " 25%,transparent 0% );}"], hoveredColor, hoveredColor);
54
53
  });
55
54
  export {
56
55
  MatchingWrapper,
@@ -1,5 +1,4 @@
1
1
  import { jsx, Fragment, jsxs } from "react/jsx-runtime";
2
- import { theme } from "@synerise/ds-core";
3
2
  import Icon, { ClickM } from "@synerise/ds-icon";
4
3
  import { Text } from "@synerise/ds-typography";
5
4
  import { PlaceholderContainer } from "./Placeholder.styles.js";
@@ -7,7 +6,7 @@ const Placeholder = ({
7
6
  text
8
7
  }) => {
9
8
  return /* @__PURE__ */ jsx(Fragment, { children: /* @__PURE__ */ jsxs(PlaceholderContainer, { children: [
10
- /* @__PURE__ */ jsx(Icon, { size: 24, color: theme.palette["grey-600"], component: /* @__PURE__ */ jsx(ClickM, {}) }),
9
+ /* @__PURE__ */ jsx(Icon, { size: 24, color: "var(--ds-color-icon-base-default)", component: /* @__PURE__ */ jsx(ClickM, {}) }),
11
10
  /* @__PURE__ */ jsx(Text, { size: "medium", children: text })
12
11
  ] }) });
13
12
  };
@@ -2,7 +2,7 @@ import styled from "styled-components";
2
2
  const PlaceholderContainer = /* @__PURE__ */ styled.div.withConfig({
3
3
  displayName: "Placeholderstyles__PlaceholderContainer",
4
4
  componentId: "sc-1dp40dc-0"
5
- })(["width:100%;min-height:63px;margin:auto;border-radius:3px;background-color:", ";display:flex;justify-content:center;align-items:center;flex-direction:row;span.ds-text{display:block;font-size:13px;margin:6px 0 5px 11px;color:", ";}"], (props) => props.theme.palette.white, (props) => props.theme.palette["grey-600"]);
5
+ })(["width:100%;min-height:63px;margin:auto;border-radius:3px;background-color:var(--ds-color-background-base-default);display:flex;justify-content:center;align-items:center;flex-direction:row;span.ds-text{display:block;font-size:13px;margin:6px 0 5px 11px;color:var(--ds-color-text-base-muted);}"]);
6
6
  export {
7
7
  PlaceholderContainer
8
8
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synerise/ds-logic",
3
- "version": "2.0.11",
3
+ "version": "2.1.0",
4
4
  "description": "Logic UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "Synerise/synerise-design",
@@ -42,9 +42,9 @@
42
42
  ],
43
43
  "types": "dist/index.d.ts",
44
44
  "dependencies": {
45
- "@synerise/ds-icon": "^2.2.3",
46
- "@synerise/ds-typography": "^2.0.11",
47
- "@synerise/ds-utils": "^2.2.2"
45
+ "@synerise/ds-icon": "^2.3.0",
46
+ "@synerise/ds-typography": "^2.1.0",
47
+ "@synerise/ds-utils": "^2.3.0"
48
48
  },
49
49
  "devDependencies": {
50
50
  "vitest": "4"
@@ -55,5 +55,5 @@
55
55
  "react-intl": ">=3.12.0 <= 6.8",
56
56
  "styled-components": "^5.3.3"
57
57
  },
58
- "gitHead": "c356039703d8826bbbdb6dadcb18bb008fea8bc5"
58
+ "gitHead": "5c3d61e30289486d14c7d6becb682e2d4a08ce41"
59
59
  }