@synergy-design-system/mcp 1.31.0 → 1.33.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 +20 -0
- package/dist/build/build.js +2 -0
- package/dist/build/fonts.d.ts +4 -0
- package/dist/build/fonts.js +49 -0
- package/dist/tools/font-info.d.ts +6 -0
- package/dist/tools/font-info.js +35 -0
- package/dist/tools/index.d.ts +1 -0
- package/dist/tools/index.js +1 -0
- package/dist/utilities/config.d.ts +4 -0
- package/dist/utilities/config.js +4 -0
- package/dist/utilities/fonts.d.ts +2 -0
- package/dist/utilities/fonts.js +3 -0
- package/dist/utilities/index.d.ts +1 -0
- package/dist/utilities/index.js +1 -0
- package/metadata/checksum.txt +1 -1
- package/metadata/packages/assets/README.md +4 -2
- package/metadata/packages/components/components/syn-combobox/component.styles.ts +3 -5
- package/metadata/packages/components/components/syn-optgroup/component.styles.ts +2 -2
- package/metadata/packages/components/components/syn-option/component.custom.styles.ts +44 -13
- package/metadata/packages/components/components/syn-select/component.custom.styles.ts +3 -5
- package/metadata/packages/components/migration/migration-synergy-v3.md +234 -49
- package/metadata/packages/components/static/CHANGELOG.md +9 -0
- package/metadata/packages/fonts/CHANGELOG.md +12 -0
- package/metadata/packages/fonts/README.md +157 -0
- package/metadata/packages/fonts/package.json +72 -0
- package/metadata/static/fonts/index.md +4 -0
- package/metadata/static/setup/prerequisites.md +179 -122
- package/package.json +4 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.33.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#1095](https://github.com/synergy-design-system/synergy-design-system/pull/1095) [`f9f544f`](https://github.com/synergy-design-system/synergy-design-system/commit/f9f544feb2adb3edef95bd1b50a303440e0c8385) Thanks [@schilchSICKAG](https://github.com/schilchSICKAG)! - Released on: 2025-12-04
|
|
8
|
+
|
|
9
|
+
feat: ✨ Brand updates for `<syn-select>`, `<syn-option>` and `<syn-optgroup>` (#988)
|
|
10
|
+
feat: ✨ Brand updates for `<syn-combobox>` (#944)
|
|
11
|
+
|
|
12
|
+
## 1.32.0
|
|
13
|
+
|
|
14
|
+
### Minor Changes
|
|
15
|
+
|
|
16
|
+
- [#1099](https://github.com/synergy-design-system/synergy-design-system/pull/1099) [`fc1e550`](https://github.com/synergy-design-system/synergy-design-system/commit/fc1e550fb4aa28eabf0bef6b089993a1dd939ff2) Thanks [@schilchSICKAG](https://github.com/schilchSICKAG)! - Released on: 2025-12-04
|
|
17
|
+
|
|
18
|
+
feat: ✨ add sick intl to fonts (#1085)
|
|
19
|
+
|
|
20
|
+
Add an optimized variant of the `SICK Intl` font as a shared asset to the new `@synergy-design-system/fonts` package.
|
|
21
|
+
It also adds the fonts package to the Synergy MCP server.
|
|
22
|
+
|
|
3
23
|
## 1.31.0
|
|
4
24
|
|
|
5
25
|
### Minor Changes
|
package/dist/build/build.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import ora from 'ora';
|
|
2
2
|
import { buildAssets } from './assets.js';
|
|
3
3
|
import { buildComponents } from './components.js';
|
|
4
|
+
import { buildFonts } from './fonts.js';
|
|
4
5
|
import { buildFrameworkFiles } from './frameworks.js';
|
|
5
6
|
import { buildStaticFiles } from './static.js';
|
|
6
7
|
import { buildTokens } from './tokens.js';
|
|
@@ -14,6 +15,7 @@ const build = async () => {
|
|
|
14
15
|
await buildAssets();
|
|
15
16
|
await buildComponents();
|
|
16
17
|
await buildFrameworkFiles();
|
|
18
|
+
await buildFonts();
|
|
17
19
|
await buildTokens();
|
|
18
20
|
await buildStyles();
|
|
19
21
|
// Should be run last as we will copy files where we see fit and paths must exist
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { existsSync } from 'node:fs';
|
|
2
|
+
import { copyFile } from 'node:fs/promises';
|
|
3
|
+
import { basename, join } from 'node:path';
|
|
4
|
+
import { rimraf } from 'rimraf';
|
|
5
|
+
import ora from 'ora';
|
|
6
|
+
import { createPath, fontsPath, getAbsolutePath, } from '../utilities/index.js';
|
|
7
|
+
/**
|
|
8
|
+
* List of relative paths to files that should be copied to the static metadata directory.
|
|
9
|
+
*/
|
|
10
|
+
const staticFilesToCopy = [
|
|
11
|
+
'README.md',
|
|
12
|
+
'CHANGELOG.md',
|
|
13
|
+
'package.json',
|
|
14
|
+
].map(file => ([
|
|
15
|
+
getAbsolutePath(`../../../../packages/fonts/${file}`),
|
|
16
|
+
join(fontsPath, ''),
|
|
17
|
+
]));
|
|
18
|
+
/**
|
|
19
|
+
* Sets up all wanted data from the fonts package and adds it to the static metadata.
|
|
20
|
+
*/
|
|
21
|
+
export const buildFonts = async () => {
|
|
22
|
+
const spinner = ora({
|
|
23
|
+
prefixText: 'Fonts:',
|
|
24
|
+
text: 'Generating static metadata...',
|
|
25
|
+
}).start();
|
|
26
|
+
try {
|
|
27
|
+
spinner.text = 'Cleaning up old metadata...';
|
|
28
|
+
await rimraf(fontsPath);
|
|
29
|
+
spinner.succeed('Old metadata cleaned up.');
|
|
30
|
+
spinner.text = 'Creating new metadata directory...';
|
|
31
|
+
// Create the fonts directory if it doesn't exist
|
|
32
|
+
await createPath(fontsPath);
|
|
33
|
+
spinner.succeed('New metadata directory created.');
|
|
34
|
+
spinner.text = 'Copying files to metadata directory...';
|
|
35
|
+
const staticFiles = staticFilesToCopy
|
|
36
|
+
.filter(file => existsSync(file.at(0)))
|
|
37
|
+
.map(async ([staticFile, target]) => {
|
|
38
|
+
await createPath(target);
|
|
39
|
+
return copyFile(staticFile, join(target, basename(staticFile)));
|
|
40
|
+
});
|
|
41
|
+
await Promise.all(staticFiles);
|
|
42
|
+
spinner.succeed('Framework metadata generated successfully.');
|
|
43
|
+
spinner.succeed('Generation of metadata generated successfully.');
|
|
44
|
+
}
|
|
45
|
+
catch (error) {
|
|
46
|
+
spinner.fail(`Failed to generate fonts metadata. Error: ${error}`);
|
|
47
|
+
throw error; // Re-throw to handle it in the calling function
|
|
48
|
+
}
|
|
49
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import type { McpServer } from '@modelcontextprotocol/sdk/server/mcp.js';
|
|
2
|
+
/**
|
|
3
|
+
* Simple tool to retrieve information about the fonts used in the Synergy Design System.
|
|
4
|
+
* @param server - The MCP server instance to register the tool on.
|
|
5
|
+
*/
|
|
6
|
+
export declare const fontInfoTool: (server: McpServer) => void;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { getFontsMetaData, getStructuredMetaData, } from '../utilities/index.js';
|
|
2
|
+
/**
|
|
3
|
+
* Simple tool to retrieve information about the fonts used in the Synergy Design System.
|
|
4
|
+
* @param server - The MCP server instance to register the tool on.
|
|
5
|
+
*/
|
|
6
|
+
export const fontInfoTool = (server) => {
|
|
7
|
+
server.registerTool('font-info', {
|
|
8
|
+
description: 'Get the list of used fonts and their setup for the Synergy Design System.',
|
|
9
|
+
title: 'Font Information',
|
|
10
|
+
}, async () => {
|
|
11
|
+
const aiRules = await getStructuredMetaData('../../metadata/static/fonts');
|
|
12
|
+
const fontsData = await getFontsMetaData((fileName) => !fileName.toLowerCase().startsWith('changelog'));
|
|
13
|
+
return {
|
|
14
|
+
content: [
|
|
15
|
+
{
|
|
16
|
+
text: 'Available fonts in the Synergy Design System:',
|
|
17
|
+
type: 'text',
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
text: JSON.stringify([
|
|
21
|
+
{
|
|
22
|
+
text: JSON.stringify(aiRules, null, 2),
|
|
23
|
+
type: 'text',
|
|
24
|
+
},
|
|
25
|
+
], null, 2),
|
|
26
|
+
type: 'text',
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
text: JSON.stringify(fontsData, null, 2),
|
|
30
|
+
type: 'text',
|
|
31
|
+
},
|
|
32
|
+
],
|
|
33
|
+
};
|
|
34
|
+
});
|
|
35
|
+
};
|
package/dist/tools/index.d.ts
CHANGED
|
@@ -3,6 +3,7 @@ export * from './asset-list.js';
|
|
|
3
3
|
export * from './component-info.js';
|
|
4
4
|
export * from './component-list.js';
|
|
5
5
|
export * from './davinci-migration.js';
|
|
6
|
+
export * from './font-info.js';
|
|
6
7
|
export * from './framework-info.js';
|
|
7
8
|
export * from './migration-info.js';
|
|
8
9
|
export * from './styles-info.js';
|
package/dist/tools/index.js
CHANGED
|
@@ -3,6 +3,7 @@ export * from './asset-list.js';
|
|
|
3
3
|
export * from './component-info.js';
|
|
4
4
|
export * from './component-list.js';
|
|
5
5
|
export * from './davinci-migration.js';
|
|
6
|
+
export * from './font-info.js';
|
|
6
7
|
export * from './framework-info.js';
|
|
7
8
|
export * from './migration-info.js';
|
|
8
9
|
export * from './styles-info.js';
|
|
@@ -70,6 +70,10 @@ export declare const staticPath: string;
|
|
|
70
70
|
* Path to the migration directory, relative to the MCP directory.
|
|
71
71
|
*/
|
|
72
72
|
export declare const staticMigrationPath: string;
|
|
73
|
+
/**
|
|
74
|
+
* Path to the fonts directory, relative to the MCP directory.
|
|
75
|
+
*/
|
|
76
|
+
export declare const fontsPath: string;
|
|
73
77
|
/**
|
|
74
78
|
* List of supported frameworks.
|
|
75
79
|
*/
|
package/dist/utilities/config.js
CHANGED
|
@@ -75,3 +75,7 @@ export const staticPath = join(currentDirname, '../../metadata/static');
|
|
|
75
75
|
* Path to the migration directory, relative to the MCP directory.
|
|
76
76
|
*/
|
|
77
77
|
export const staticMigrationPath = join(currentDirname, '../../metadata/static/migration');
|
|
78
|
+
/**
|
|
79
|
+
* Path to the fonts directory, relative to the MCP directory.
|
|
80
|
+
*/
|
|
81
|
+
export const fontsPath = join(currentDirname, '../../metadata/packages/fonts');
|
package/dist/utilities/index.js
CHANGED
package/metadata/checksum.txt
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
bcccb716196fa09334ce6f5caa139721
|
|
@@ -18,7 +18,9 @@ npm install --save @synergy-design-system/assets
|
|
|
18
18
|
|
|
19
19
|
### Usage
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
#### Images
|
|
22
|
+
|
|
23
|
+
All images are provided as svg's.
|
|
22
24
|
|
|
23
25
|
The recommended way of using the icons is using the [<syn-icon> Synergy component](https://synergy-design-system.github.io/?path=/docs/components-syn-icon--docs). Here you will also get more information about how setting up the assets package on bundlers like vite.
|
|
24
26
|
|
|
@@ -26,7 +28,7 @@ The recommended way of using the icons is using the [<syn-icon> Synergy componen
|
|
|
26
28
|
<syn-icon name="warning"></syn-icon>
|
|
27
29
|
```
|
|
28
30
|
|
|
29
|
-
|
|
31
|
+
Images could also be used directly:
|
|
30
32
|
|
|
31
33
|
```html
|
|
32
34
|
<img src="assets/icons/warning.svg" />
|
|
@@ -306,7 +306,7 @@ export default css`
|
|
|
306
306
|
|
|
307
307
|
/* Change combobox border on hover */
|
|
308
308
|
.combobox:not(.combobox--disabled):hover .combobox__inputs {
|
|
309
|
-
border-color: var(--syn-input-color-hover);
|
|
309
|
+
border-color: var(--syn-input-border-color-hover);
|
|
310
310
|
}
|
|
311
311
|
|
|
312
312
|
/* Prefix and Suffix */
|
|
@@ -353,18 +353,16 @@ export default css`
|
|
|
353
353
|
font-size: var(--syn-font-size-2x-large);
|
|
354
354
|
}
|
|
355
355
|
|
|
356
|
-
|
|
357
356
|
.combobox__prefix,
|
|
358
357
|
.combobox__suffix {
|
|
359
|
-
color: var(--syn-input-
|
|
358
|
+
color: var(--syn-input-icon-color);
|
|
360
359
|
}
|
|
361
360
|
|
|
362
361
|
|
|
363
362
|
|
|
364
363
|
/* Listbox */
|
|
365
364
|
.combobox__listbox {
|
|
366
|
-
|
|
367
|
-
border-radius: var(--syn-border-radius-none);
|
|
365
|
+
border-radius: var(--syn-input-border-radius-medium);
|
|
368
366
|
box-shadow: var(--syn-shadow-medium);
|
|
369
367
|
}
|
|
370
368
|
|
|
@@ -14,7 +14,7 @@ export default css`
|
|
|
14
14
|
.optgroup__label-container {
|
|
15
15
|
align-items: center;
|
|
16
16
|
box-sizing: border-box;
|
|
17
|
-
color: var(--syn-color
|
|
17
|
+
color: var(--syn-input-color);
|
|
18
18
|
display: flex;
|
|
19
19
|
gap: var(--syn-spacing-small);
|
|
20
20
|
min-height: var(--option-min-height, var(--syn-input-height-medium));
|
|
@@ -49,7 +49,7 @@ export default css`
|
|
|
49
49
|
|
|
50
50
|
.optgroup__prefix,
|
|
51
51
|
.optgroup__suffix {
|
|
52
|
-
color: var(--syn-color-neutral-800);
|
|
52
|
+
color: var(--syn-option-icon-color, var(--syn-color-neutral-800));
|
|
53
53
|
font-size: var(--syn-spacing-large);
|
|
54
54
|
}
|
|
55
55
|
|
|
@@ -13,28 +13,54 @@ export default css`
|
|
|
13
13
|
* See below for usage of these variables
|
|
14
14
|
*/
|
|
15
15
|
.option {
|
|
16
|
+
/*
|
|
17
|
+
* #988: Brand2025 defines a small gap between options
|
|
18
|
+
* and rounded corners. We achieve that using an outline
|
|
19
|
+
* that simulates the gap using the menu background color.
|
|
20
|
+
*/
|
|
21
|
+
--outline: calc(var(--syn-focus-ring-border-radius) * 1.5);
|
|
22
|
+
|
|
23
|
+
border-radius: calc(var(--outline) * 1.5);
|
|
16
24
|
font-size: var(--option-font-size, var(--syn-font-size-medium));
|
|
17
|
-
|
|
25
|
+
|
|
18
26
|
/* Height is dependent on line-height of .option__label, which does not fit completely to layout */
|
|
19
27
|
min-height: var(--option-min-height, var(--syn-input-height-medium));
|
|
20
|
-
|
|
28
|
+
outline: var(--outline) solid var(--syn-panel-background-color);
|
|
29
|
+
outline-offset: calc(var(--outline) * -1 + 1px);
|
|
30
|
+
padding: var(--option-padding, var(--syn-spacing-small) var(--syn-spacing-medium));
|
|
21
31
|
}
|
|
22
32
|
|
|
23
33
|
.option:not(.option--current) {
|
|
24
|
-
color: var(--syn-color-
|
|
34
|
+
color: var(--syn-option-color, var(--syn-typography-color-text));
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.option--current,
|
|
38
|
+
.option--current.option--hover:not(.option--disabled) {
|
|
39
|
+
background-color: var(--syn-option-background-color-active, var(--syn-color-neutral-1000));
|
|
40
|
+
color: var(--syn-option-color-active, var(--syn-typography-color-text-inverted));
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.option--hover:not(.option--current):not(.option--disabled) {
|
|
44
|
+
background-color: var(--syn-option-background-color-hover, var(--syn-color-neutral-1000));
|
|
45
|
+
color: var(--syn-option-color-hover, var(--syn-typography-color-text-inverted));
|
|
25
46
|
}
|
|
26
47
|
|
|
27
48
|
/** #429: Use token for opacity */
|
|
28
|
-
.option--disabled {
|
|
49
|
+
.option--disabled {
|
|
29
50
|
opacity: var(--syn-input-disabled-opacity);
|
|
30
51
|
}
|
|
31
52
|
|
|
53
|
+
.option--current.option--disabled {
|
|
54
|
+
background-color: var(--syn-option-background-color-hover, var(--syn-color-neutral-1000));
|
|
55
|
+
color: var(--syn-option-color-hover, var(--syn-typography-color-text-inverted));
|
|
56
|
+
}
|
|
57
|
+
|
|
32
58
|
.option__label {
|
|
33
59
|
line-height: var(--syn-line-height-normal);
|
|
34
60
|
}
|
|
35
61
|
|
|
36
62
|
.option__check {
|
|
37
|
-
color: var(--syn-color-primary-600);
|
|
63
|
+
color: var(--syn-option-check-color, var(--syn-color-primary-600));
|
|
38
64
|
font-size: var(--option-icon-size, var(--syn-spacing-large));
|
|
39
65
|
}
|
|
40
66
|
|
|
@@ -44,7 +70,11 @@ export default css`
|
|
|
44
70
|
|
|
45
71
|
/* Invert the check mark when keyboard navigation is used */
|
|
46
72
|
.option--current .option__check {
|
|
47
|
-
color: var(--syn-color-neutral-0);
|
|
73
|
+
color: var(--syn-option-check-color-active, var(--syn-color-neutral-0));
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.option--hover:not(.option--current) .option__check {
|
|
77
|
+
color: var(--syn-option-check-color-hover, var(--syn-color-neutral-0));
|
|
48
78
|
}
|
|
49
79
|
|
|
50
80
|
/* Use larger spacing between icons and content */
|
|
@@ -59,23 +89,24 @@ export default css`
|
|
|
59
89
|
/* Set correct icon size when someone uses syn-icon in the slots */
|
|
60
90
|
.option__prefix::slotted(syn-icon),
|
|
61
91
|
.option__suffix::slotted(syn-icon) {
|
|
62
|
-
color: var(--syn-color-
|
|
92
|
+
color: var(--syn-option-icon-color, var(--syn-typography-color-text));
|
|
63
93
|
font-size: var(--option-icon-size, var(--syn-spacing-large));
|
|
64
94
|
}
|
|
65
95
|
|
|
96
|
+
.option--hover .option__prefix::slotted(syn-icon),
|
|
97
|
+
.option--hover .option__suffix::slotted(syn-icon) {
|
|
98
|
+
color: var(--syn-option-icon-color-hover, var(--syn-color-neutral-800));
|
|
99
|
+
}
|
|
100
|
+
|
|
66
101
|
.option--current .option__prefix::slotted(syn-icon),
|
|
67
102
|
.option--current .option__suffix::slotted(syn-icon) {
|
|
68
|
-
color: var(--syn-color-neutral-
|
|
103
|
+
color: var(--syn-option-icon-color-active, var(--syn-color-neutral-800));
|
|
69
104
|
}
|
|
70
105
|
|
|
71
106
|
/* This is needed for the highlight styling of the options in syn-combobox */
|
|
72
107
|
.option__label::slotted(.syn-highlight-style) {
|
|
73
108
|
background-color: transparent;
|
|
74
|
-
color:
|
|
109
|
+
color: unset;
|
|
75
110
|
font: var(--syn-body-medium-bold);
|
|
76
111
|
}
|
|
77
|
-
|
|
78
|
-
:host([aria-selected='true']) .option__label::slotted(.syn-highlight-style) {
|
|
79
|
-
color: var(--syn-color-neutral-0);
|
|
80
|
-
}
|
|
81
112
|
`;
|
|
@@ -59,7 +59,7 @@ export default css`
|
|
|
59
59
|
/* Change select border on hover */
|
|
60
60
|
/* stylelint-disable-next-line no-descending-specificity */
|
|
61
61
|
.select:not(.select--disabled):hover .select__combobox {
|
|
62
|
-
border-color: var(--syn-input-color-hover);
|
|
62
|
+
border-color: var(--syn-input-border-color-hover);
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
/* Prefix and Suffix */
|
|
@@ -106,10 +106,9 @@ export default css`
|
|
|
106
106
|
font-size: var(--syn-font-size-2x-large);
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
-
|
|
110
109
|
.select__prefix,
|
|
111
110
|
.select__suffix {
|
|
112
|
-
color: var(--syn-input-
|
|
111
|
+
color: var(--syn-input-icon-color);
|
|
113
112
|
}
|
|
114
113
|
|
|
115
114
|
/* Multi Select */
|
|
@@ -131,8 +130,7 @@ export default css`
|
|
|
131
130
|
|
|
132
131
|
/* Listbox */
|
|
133
132
|
.select__listbox {
|
|
134
|
-
|
|
135
|
-
border-radius: var(--syn-border-radius-none);
|
|
133
|
+
border-radius: var(--syn-input-border-radius-medium);
|
|
136
134
|
box-shadow: var(--syn-shadow-medium);
|
|
137
135
|
}
|
|
138
136
|
|