likec4 1.24.1 → 1.25.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "likec4",
3
- "version": "1.24.1",
3
+ "version": "1.25.0",
4
4
  "license": "MIT",
5
5
  "homepage": "https://likec4.dev",
6
6
  "author": "Denis Davydkov <denis@davydkov.com>",
@@ -70,14 +70,14 @@
70
70
  "rollup": "4.34.6",
71
71
  "type-fest": "4.34.1",
72
72
  "vite": "5.4.14",
73
- "@likec4/core": "~1.24.1"
73
+ "@likec4/core": "~1.25.0"
74
74
  },
75
75
  "devDependencies": {
76
76
  "@dagrejs/dagre": "1.1.4",
77
77
  "@fontsource/ibm-plex-sans": "^5.1.1",
78
- "@mantine/core": "7.17.0",
79
- "@mantine/hooks": "7.17.0",
80
- "@mantine/vanilla-extract": "7.17.0",
78
+ "@mantine/core": "7.17.1",
79
+ "@mantine/hooks": "7.17.1",
80
+ "@mantine/vanilla-extract": "7.17.1",
81
81
  "@nanostores/react": "0.8.4",
82
82
  "@react-hookz/web": "^25.0.1",
83
83
  "@tabler/icons-react": "3.29.0",
@@ -150,13 +150,13 @@
150
150
  "vscode-uri": "3.1.0",
151
151
  "which": "^5.0.0",
152
152
  "yargs": "17.7.2",
153
- "@likec4/generators": "1.24.1",
154
- "@likec4/diagram": "1.24.1",
155
- "@likec4/icons": "1.24.1",
156
- "@likec4/language-server": "1.24.1",
157
- "@likec4/layouts": "1.24.1",
158
- "@likec4/log": "1.24.1",
159
- "@likec4/tsconfig": "1.24.1"
153
+ "@likec4/generators": "1.25.0",
154
+ "@likec4/icons": "1.25.0",
155
+ "@likec4/language-server": "1.25.0",
156
+ "@likec4/log": "1.25.0",
157
+ "@likec4/layouts": "1.25.0",
158
+ "@likec4/diagram": "1.25.0",
159
+ "@likec4/tsconfig": "1.25.0"
160
160
  },
161
161
  "scripts": {
162
162
  "turbo-build": "turbo run build --log-prefix=none --log-order=grouped",
package/react/index.d.ts CHANGED
@@ -109,6 +109,16 @@ declare interface Computed {
109
109
 
110
110
  declare const computed: Computed;
111
111
 
112
+ declare type ControlsCustomLayout = (props: ControlsCustomLayoutProps) => ReactNode;
113
+
114
+ declare type ControlsCustomLayoutProps = {
115
+ burgerMenu: ReactNode;
116
+ navigationButtons: ReactNode;
117
+ search: ReactNode;
118
+ actionsGroup: ReactNode;
119
+ syncInProgressBadge: ReactNode;
120
+ };
121
+
112
122
  declare type DiagramNodeWithNavigate<ID = ViewId> = Omit<DiagramNode, 'navigateTo'> & {
113
123
  navigateTo: ID;
114
124
  };
@@ -193,6 +203,12 @@ declare interface LikeC4BrowserProps {
193
203
  * @default true
194
204
  */
195
205
  showNotations?: boolean | undefined;
206
+ /**
207
+ * Improve performance by hiding certain elements and reducing visual effects (disable mix-blend, shadows, animations)
208
+ *
209
+ * @default 'auto' - will be set to true if view is pannable and has more than 3000 * 2000 pixels
210
+ */
211
+ reduceGraphics?: 'auto' | boolean | undefined;
196
212
  className?: string | undefined;
197
213
  style?: CSSProperties | undefined;
198
214
  }
@@ -322,13 +338,17 @@ declare interface LikeC4DiagramProperties {
322
338
  * By default, if icon is http:// or https://, it will be rendered as an image
323
339
  */
324
340
  renderIcon?: ElementIconRenderer | undefined;
341
+ /**
342
+ * Customize layout of the controls on the top left
343
+ */
344
+ renderControls?: ControlsCustomLayout | undefined;
325
345
  /**
326
346
  * Dynamic filter, applies both to nodes and edges
327
347
  */
328
348
  where?: WhereOperator<string, string> | undefined;
329
349
  }
330
350
 
331
- declare type LikeC4DiagramProps = LikeC4DiagramProperties & LikeC4DiagramEventHandlers;
351
+ declare type LikeC4DiagramProps = PropsWithChildren<LikeC4DiagramProperties & LikeC4DiagramEventHandlers>;
332
352
 
333
353
  export declare const LikeC4ModelProvider: (props: LikeC4ModelProviderProps) => JSX_2.Element;
334
354
 
@@ -440,6 +460,12 @@ export declare interface LikeC4ViewProps<ViewId = string, Tag = string, Kind = s
440
460
  * @default enableRelationshipBrowser
441
461
  */
442
462
  enableRelationshipDetails?: boolean | undefined;
463
+ /**
464
+ * Improve performance by hiding certain elements and reducing visual effects (disable mix-blend, shadows, animations)
465
+ *
466
+ * @default 'auto' - will be set to true if view is pannable and has more than 3000 * 2000 pixels
467
+ */
468
+ reduceGraphics?: 'auto' | boolean | undefined;
443
469
  where?: WhereOperator<Tag, Kind> | undefined;
444
470
  className?: string | undefined;
445
471
  style?: CSSProperties | undefined;