1.14.0 (2024-10-20)
-
View relationship decomposition:
RelationshipCloud -> Amazon
from examples: -
Global styles:
Shared global stylesglobal { style mute_all * { color muted opacity 10% } } views { view of app { global style mute_all style cloud.* { color green } } }
Documentation (thanks @hubertmis, closes #1058)
-
Build with
--base './'
:
Allows to build a relocatable website (thanks @rumpelrausch, closes #1111)
- diagram: edges with no nearby nodes are not visible in the canvas (thanks @davydkov, closes #1109)
1.13.0 (2024-10-18)
-
Browse relationships
Disabled by default in generated components, to enable:
import { LikeC4View } from './likec4.generated' <LikeC4View viewId="index" enableRelationshipsBrowser />
Share your feedback in our Discussions
-
Local styles:
Shared styles in views block (thanks @hubertmis, #1113)views { // apply to all views in this views block style * { color muted opacity 10% } view apiApp of internetBankingSystem.apiApplication { include * } view mobileApp of internetBankingSystem.mobileApplication { include * } }
-
Alignment tools:
Implemented alignment tools for manual layouting (thanks @pavelpykhtin, #1099)
- react:
crow
arrow type (thanks @pavelpykhtin, #1092) - react:
controls
property to show/hide top left panel (b36880f) - react:
styleNonce
property for ReactLikeC4 (0c78314) - react: Text colors / backdrop not updated until page refresh when toggling between light and dark mode #1098 (6bb6cf3)
- vscode: autocompletion of "specification", "views" and "model" broken (closes #1102)
1.12.2 (2024-10-10)
- vscode: transparent layout spacing panel for a clearer preview of changes
- unable to open diagram from Sidebar (thanks @davydkov, closes #1091)
1.12.1 (2024-10-10)
- preview: change grouping in sidebar
- react: change layout spacings from the UI
- react: toolbar to change styles (instead of panel)
- vscode: nonce parameter for marking dynamic styles inserted by components (thanks @pavelpykhtin, #1065 (89be0f1)
- react: react component open full-screen mode (thanks @davydkov, 4cd1464), closes #1055
- vscode: space being added/removed before colon (thanks @pavelpykhtin, #1074) (fd3624c)
1.12.0 (2024-10-07)
-
dsl: params to adjust autolayout (thanks @pavelpykhtin, #1053)
view { include * autoLayout LeftRight 120 110 }
-
dsl: add Azure iconset (thanks @msisolak #1040)
-
publish extension to Open VSX (thanks @davydkov, #908)
- diagram: unable to drag multiple nodes (thanks @pavelpykhtin, #1043)
- diagram: long node names overflow in node options panel (thanks @pavelpykhtin)
- diagram: deleted control point being reverted on mouse up (thanks @pavelpykhtin, #1044 )
- vscode: extra space in dynamic step (thanks @pavelpykhtin, #1056)
- app: configure kroki url with
VITE_KROKI_D2_SVG_URL
(thanks @davydkov, #1060) - deps: upgrade playwright to 1.47.2 (73758c6)
- vscode:
--enable-source-maps
in node extension (eef8153)
1.11.0 (2024-09-24)
-
Relationship details
On hover displays direct relationships and resolved from nested. If relationship has
navigateTo
- displays navigation linkTo disable - set
showRelationshipDetails={false}
in react component -
Improved layout editing
Thanks to @pavelpykhtin, now it is possible add control points with right click, or reset all control points
Example here #1013 -
New API
LikeC4Model.Layouted
Difference between
LikeC4Model.Computed
andLikeC4Model.Layouted
- is that second one also includes layout data (dimensions, positions), that is needed for renderingimport { LikeC4 } from 'likec4' const likec4 = await LikeC4.fromWorkspace() // Sync and fast const model = likec4.computedModel() model .element('cloud.backend.api') .incoming() // relationships incoming to the element .filter(r => r.tags.includes('http')) // filter by tags .map(r => r.source) // get source elements // Async, includes layout data (dimensions, positions...) const diagram = await likec4.layoutedModel().view('index')
Generated React component also exports instance of
LikeC4Model.Layouted
, and hooks to use inside your app.
1.10.1 (2024-09-17)
- dsl: derived connection from multiple relationships with same endpoints always picks the last relationship (12b1899), closes #990
- vscode: preview does not work in remote workspaces (90e4725), closes #1004
- react: edge changes being reverted on mouse up (thanks @pavelpykhtin, #1008)
- vscode: space being inserted into relation's source (thanks @pavelpykhtin, #1001)
1.10.0 (2024-09-12)
-
Parallel steps and notes in dynamic views
[Playground example](https://playground.likec4.dev/w/dynamic/) -
Navigation for relationships (zoom-in to dynamic views)
model { webApp -> backend.api { title 'requests data for the dashboard' navigateTo dashboardRequestFlow } }
-
Code Formatter in VSCode Extension (thanks @pavelpykhtin, to #979)
-
New component
ReactLikeC4
Low-level component with more control and event listeners.const App = () => { return ( <div> <ReactLikeC4 viewId="index" pannable={false} zoomable keepAspectRatio={false} showElementLinks={false} showDiagramTitle={false} onNodeClick={...} /> </div> ) }
1.9.0 (2024-09-07)
-
LikeC4 Model API Access and traverse your architecture model programmatically using the LikeC4 Model API.
import { LikeC4 } from "likec4" const likec4 = await LikeC4.fromWorkspace(`....`) // Validation errors console.log(likec4.getErrors()) // Traverse the model const model = likec4.model() model .element('cloud.backend.api') .incoming() // relationships incoming to the element .filter(r => r.tags.includes('http')) // filter by tags .map(r => r.source) // get source elements // Layouted views const diagrams = await likec4.diagrams()
-
Custom colors
specification { color custom #6BD731 element customer { notation "Person, Customer" style { shape person color custom } } }
Thanks to @pavelpykhtin, resolves #916
1.8.1 (2024-08-30)
- dsl: warn message about ambiguous alternatives
- dsl: allow
this
andit
as targetmodel { frontend = component { customer -> it 'opens in browser' } }
1.8.0 (2024-08-27)
-
View notations
specification { element customer { notation "Person, Customer" style { shape person color green } } element staff { notation "Person, Staff" style { shape person } } }
-
technology
for relationships (Thanks to @pavelpykhtin, resolves #576) -
title
for links (Thanks to @pavelpykhtin, resolves #871) -
metadata
in DSL (Thanks to @pavelpykhtin) -
[experimental] overview all views with
use-overview
flag in cli
1.7.4 (2024-08-17)
- broken export to png
- add downloadedRef to track if download has already occurred
- compact diagram title panel and zoom out on double click
1.7.3 (2024-08-16)
-
dsl: hiding relationship titles in views (closes #910)
-
react:
where
filter on react components (closes #872, documentation)// Display elements and relationships where: // - tag is not 'legacy' // - and // - tag is 'v1' or 'v2' <LikeC4View viewId="index" where={{ and: [ { tag: { neq: 'legacy' } }, { or: [ { tag: { eq: 'v1' } }, { tag: { eq: 'v2' } } ] } ] }}/>
-
react: export to png in new tab (198d79e)
-
cli: export png to flat directory (bcd23dd)
-
cli: warn layout drifts (49c1100)
1.7.2 (2024-08-10)
- vscode: regression with preview panel (ba61a7b)
1.7.1 (2024-08-10)
- cli: regression on
build
command (5ebb251)
1.7.0 (2024-08-10)
-
where
in predicates// include only microservices from nested include cloud.* where kind is microservice // only microservices and not deprecated include cloud.* where kind == microservice and // possible to use 'is' or '==' tag != #deprecated // possible to use 'is not' or '!=' // Use logical operators include cloud.* where not (kind is microservice or kind is webapp) and tag is not #legacy and (tag is #v1 or tag is #v2)
This also applies to relationship predicates (Resolves #593)
include // only relationships with tag #messaging cloud.* <-> amazon.* where tag is #messaging, // only incoming http-requests -> backend where kind is http-request
- activate dynamic walkthrough on edge double click
- improve manual layouts
- add
description
andtechnology
to relationship (not yet rendered) - allow wildcard predicate together with
with
1.6.1 (2024-07-24)
- cli: vite error on build with v1.6.0 (#860)
- deps: update dependency playwright to v1.45.2 (#783) (73ddd69)
1.6.0 (2024-07-20)
-
Bundled icons
model { fn = service 'Lambda Function' { icon aws:lambda } k8s = service 'K8s Service' { icon gcp:google-kubernetes-engine } pg = storage 'PostgreSQL' { icon tech:postgresql } }
Besides, icon can be just an element property, skipping
style
block -
Improved code completion in view predicates
1.5.0 (2024-07-12)
-
Customize relationships per view
include // Include elements if they have any relationships // and customize these relationships cloud.* <-> amazon.* with { color red line solid }, // or only directed customer -> cloud.* with { // Override label title 'Customer uses cloud' }
- diagram: increased labels font size for better readability (f31dc2f)
- diagram: add css autoprefixer and inject xystore to diagram store (a15644b)
- diagram: arrow types (86eca4c), closes #755
- diagram: compound node draggable by title (9c3ff1f)
- diagram: edge rendering (dbd5a65)
- diagram: improve edge rendering and label bbox (a8f8d17)
- edge: remove control point on dbl click (831077b)
- layout: single relashionships (ebeaeef)
- layout: update layouts (851ec59)
- layout: wrap edge label (0f007ff)
- lsp: clear diagnostics for on rebuild (46206df)
- lsp: customize
<->
relationships (98c8b1f) - lsp: semantic token for navigateTo (09b1a11)
- vscode: update documentSelector if workspaceFolders is empty (9678ed2)
- webcomponent: improve dynamic view (65c2961)
- deps: update @xyflow (#807) (2408e16)
- deps: update dependency @astrojs/starlight to ^0.24.5 (#803) (6cc824a)
- deps: update dependency astro to ^4.11.5 (#818) (9cc7f44)
- deps: update dependency astro-og-canvas to ^0.5.3 (#835) (bea7ea7)
- deps: update dependency starlight-links-validator to ^0.9.1 (eea921b)
- deps: upgrade
monaco-vscode
(36be81e) - deps: upgrade mantine to 7.11 (23bde17)
- deps: upgrade typescript to 5.5.2 (dc996c8)
1.4.0 (2024-06-28)
- vscode: disable experimental editor in vscode preferences (effdef1)
- cli: use dev server when exporting to png (faster) (9a19db3)
- diagram: back/forward navigation buttons (4d258ed)
- react: use html dialog for browser (0981df2)
- deps: upgrade playwright to 1.45.0 (486140b)
- deps: upgrade vite to 5.3.2 (cf8956f)
- diagram: disable blur filter in safari (dd14526)
- diagram: improve rendering in safari (d530d98)
- playground: switch to vertical layout for better mobile experience (99b6b60)
1.3.0 (2024-06-23)
- View editor
Experimental layout editor (drag elements and relationships)
- dynamic-view: hotkeys navigation (8e36d7b), closes #769
- lsp: improve symantic highlighting (3968e07)
- playground: persistent workspace (911c632)
- deps: upgrade langium to 3.1.0 (a309316)
- diagram: rendering performance (2eef48b)
- diagram: responsive dynamic view (ad03301)
- lsp: 0% opacity in specification (bbec0a8)
1.2.2 (2024-06-14)
1.2.1 did not fix #765
1.2.1 (2024-06-14)
- cli: compatibility with vite 5.3 (closes #765, thanks to @simonwfarrow)
- deps: playwright 1.44.1 (3f277f7)
1.2.0 (2024-06-12)
Dynamic Views [Experimental]
Describe a particular use-case or scenario, with ad-hoc interactions (without polluting the model).
dynamic view example {
title 'Dynamic View Example'
customer -> web 'opens in browser'
web -> api 'POST request'
web <- api 'returns JSON'
}
Check example
- diagram: always zoom to 1.0 on container resize (f5b898c)
- diagram: backdrop in safari (94530ae)
- diagram: focus in dynamic walkthrough (b4c1752)
- playground: missing element type (4aad466)
- playground: unique extension for each playground (8fcfed6)
1.1.1 (2024-05-26)
- diagram: viewport transform is not rounded to integers which results in blurry nodes on some resolution (d268344), closes #734
1.1.0 (2024-05-24)
-
Change opacity and border for compounds background (#723)
view { include some._ style some { opacity 20% border dashed } }
1.0.2 (2024-05-21)
- vscode: preview fails with command
likec4:open-preview
not found (#724, thanks @4cio) - deps: update dependency playwright to v1.44.0 (#713) (dd62f8d)
- vscode: bundling
@hpcc-js/wasm
is necessary for the extension to work properly (6904afc)
1.0.1 (2024-05-18)
- lsp: correct selection range after changes (42999ef)
- vscode: correct view column for preview (6a33a48)
- download view as png from app (b316dfb)
1.0.0 (2024-05-17)
-
View Editor
VSCode Preview allows to change color, shape and switch auto-layout.
Changes are persistent and update sources.Also available in preview (via CLI), but changes are not saved back.
-
LikeC4 views as webcomponents Generates JS with custom elements:
<script src="https://published.website/likec4-views.js"></script> <likec4-view view-id="index"></likec4-view>
Always generated on
likec4 build
, but also available aslikec4 gen webcomponent
-
New predicate
include some._
Expand and include nested elements only if they have in/out relationships (internals are not considered):view { include some._ }
Differs from
include some.*
, which includes all nested elements regardless of relationships.Almost the same as:
view { include some include -> some.* -> exclude some.* -> some.* }
-
New predicate
<->
Include relationships of both directions between elements:view { include someA.* <-> someB.* }
-
CLI
Builds and exports with pre-bundled CLI are 6-8x times faster
Allow deep-linking in GitHub Pages, closes #661
Set color-scheme on export to png, closes #685 -
New renderer
Fast and responsive views on any device, based on xyflow -
New sites
https://docs.likec4.dev/ - (migration in progress...)
https://playground.likec4.dev/ - dedicated for playgrounds
1.0.0-rc.1 (2024-05-06)
-
LikeC4 views as webcomponents
Generates JS with custom elements:<script src="https://published.website/likec4-views.js"></script> <likec4-view view-id="index"></likec4-view>
Always generated on
likec4 build
, but also available aslikec4 gen webcomponent
-
New predicate
include some._
Expand and include nested elements only if they have in/out relationships (internals are not considered):view { include some._ }
Differs from
include some.*
, which includes all nested elements regardless of relationships.Almost the same as:
view { include some include -> some.* -> exclude some.* -> some.* }
-
New predicate
<->
Include relationships of both directions between elements:view { include someA.* <-> someB.* }
-
Pre-bundled CLI
Builds and exports are 6-8x times faster -
New renderer
Fast and responsive views on any device, based on xyflow -
Editor
VSCode Preview allows to change color, shape and switch auto-layout.
Changes are persistent and update sources.Also available in preview (via CLI), but changes are not saved back.
- Editor: manual layout
- New docs
1.0.0-next.14 (2024-04-30)
PRE-RELEASE
1.0.0-next.11 (2024-04-11)
PRE-RELEASE
- webcomponents (df430f0)
1.0.0-next.10 (2024-04-02)
Working on pre-release
1.0.0-next.2 (2024-03-31)
Working on pre-release
1.0.0-next.1 (2024-03-29)
Working on pre-release
1.0.0-next.0 (2024-03-29)
Working on pre-release
0.60.4 (2024-04-13)
- diagrams: Icons do not render when expected in React app, see #649
- deps: update dependencies
0.60.3 (2024-03-28)
0.60.2 (2024-03-26)
@mcpride reported that likec4 export png ...
timed out sometimes (see #634)
As a temporary workaround, now cli has the option to configure max attempts (retries) and set timeout. Or even ignore failures,
Options:
-i, --ignore continue if some views failed to export [boolean] [default: false]
-t, --timeout (ms) timeout for playwright operations [number] [default: 15000]
--max-attempts (number) if export failed, retry N times [number] [default: 4]
Example:
$ likec4 export png -o ./assets -i --max-attempts 3 -t 5000
LikeC4 sets default playwright timeout to 5sec, retries exporting failed views 3 times, and ignores these failures anyway (if there are any successful exports).
0.60.1 (2024-03-22)
- cli:
-v
returns undefined #615 - cli: reuse playwright page for screenshots (#635) (f07c61b), closes #634,
- deps: update dependency playwright-core to v1.42.1 (#636) (48d7ef4)
0.60.0 (2024-03-10)
- Relations with container elements #530
Relations with container elements were always used to layout diagrams but were not shown as they sometimes looked quite weird. While solving #614 it was figured out:
Compare results by starting two CLIs (with and without
--use-dot-bin
)
- decrease the number of nodes to group 7 -> 5, closes #614
0.58.0 (2024-03-08)
0.57.1 (2024-02-23)
- cli: fix build (d750521)
0.57.0 (2024-02-23)
- cli: tsx default tsconfig (2f5b3f0)
- lsp: returns references to the same views if no changes are made (56333e1)
- vscode: use browser and node
startServer
from@likec4/language-server
(67e3bab)
0.56.0 (2024-02-17)
- core: improve error stack trace (06ebf81)
- deps: update dependency @hpcc-js/wasm to ^2.15.3 (#537) (b2fc368)
- deps: update dependency @radix-ui/themes to ^2.0.3 (#544) (c0929a1)
- deps: update dependency autoprefixer to ^10.4.17 (#561) (56f462f)
- deps: update dependency jotai to ^2.6.4 (#545) (1f97776)
- deps: update dependency konva to ^9.3.2 (#546) (469c3bc)
- deps: update dependency konva to ^9.3.3 (58db259)
- deps: update dependency react-accessible-treeview to ^2.8.3 (#556) (919aede)
- deps: update dependency remeda to ^1.40.0 (#555) (a5797f6)
- deps: update dependency remeda to ^1.40.1 (#559) (8815004)
- deps: update dependency ts-graphviz to ^1.8.2 (ea80d34)
- deps: update playwright to 1.41.2 (18416f1)
Skipped due manual (and erroneous) publishing to marketplace.
0.54.0 (2024-01-12)
- lsp: add tags to relationships (a7e6e06)
- vscode: document selector on windows (2540f88)
0.53.0 (2024-01-10)
- cli: add fs watcher inside plugin on server configuration (73f4263)
- cli: d2 view fails to load (5f7690f)
- diagrams: minor ui improvements (2f38eb4)
- layout: add
headArrowPoint
andtailArrowPoint
to edges (89a9171) - layouts: ts compile error and remove dead code (667bc00)
- layout: use
constraint=false
instead ofminlen=0
(1fdc6ba) - types:
NonEmptyArray
has defined either head or tail (dccc52a)
0.52.0 (2023-12-12)
- deps: bump
@hpcc-js/wasm
to 2.15.1 (8e51156) - graph: remove implicit edges if there is any nested already included (94f935f)
- graph: sort graph nodes (3c8adf7)
- layout: edges with reverse direction (09edfb8)
- layouts: don't use
weight
edges in graphviz layout (60917eb)
0.51.0 (2023-12-05)
- language-server: tolerant parser, exclude only erroneous elements (previously ignored whole document) (2c9c456)
- graph: improve compound layouts (feec3b3)
- graph: correct relationship predicate (eba2be6)
- generators: indent in mermaid (6d27249)
- deps: bump
vitest
to 1.0.1 (0666acd) - deps: update dependency jotai to ^2.6.0 (62e46f2)
0.50.0 (2023-12-01)
- diagrams: navigate button (44d2182)
- likec4: display other formats (c2f5823)
- likec4: copy-to-clipboard button (ee444ac)
- likec4: display diagram links (c4932e7)
- likec4: show overlay on validation error (6f1c36f)
- layouts: background color for compounds in dot (773c1ae)
- deps: update dependency type-fest to ^4.8.2 (75c54fa)
- docs: show correct dot in playground (9e20da9)
- graph: sort graph nodes considering implicit edges (a1e33a4)
- layouts: improve graph layout (e71abfe)
- graph: removeRedundantImplicitEdges (a6420dc)
0.49.0 (2023-11-23)
- cli: export to JSON (f7a5db7)
- codegen: incorrect dot is generated (fddade6)
- vscode: extension lifecycle (correct "dispose") (ecedcd6)
0.48.0 (2023-11-21)
- deps: update dependency playwright-core to ^1.40.0 (#466) (ac979d4)
- likec4: import statements and error handling in code (efb0797)
- lsp: semantic tokens overlap (f4b9c00)
- vscode: init workspace for web (88b043d)
0.47.0 (2023-11-18)
Custom navigation and links between views:
view view2 {
include *
include cloud.backend with {
// navigate to 'view3' on click
navigateTo view3
}
}
view view3 {
include *
include cloud.backend with {
// the same element, but navigate back to 'view2'
navigateTo view2
}
}
- cli: output version (4e06953)
- deps: update dependency @radix-ui/themes to ^2.0.1 (8c6802f)
- deps: update dependency jotai to ^2.5.1 (4bb2362)
- deps: update dependency nanostores to ^0.9.5 (748554c)
- deps: update dependency type-fest to ^4.7.1 (cadebe0)
- layouts: improve edge weights (21f55cb)
- layouts: set
minlen=0
instead ofconstraint=false
for better layout (ccad492) - lsp: allow reserved words as ID (12636d5)
- lsp: make extended element resolvable inside its body (6c3b009)
0.46.1 (2023-11-14)
- cli: return optimizeDeps in serve (d8e065f)
0.46.0 (2023-11-11)
With the Langium update to version 2.1.2, the code completions in VSCode have significantly improved.
- core: add depth field to compound nodes (fe3083a)
- diagrams: backgroung pattern (c2bc83b)
- graph: sorting of relationships (bd8d694)
- lsp: any order of top-level statements (#445) (154844c)
- vscode: display error message on failed parse (789958f)
- core: hierarchical sorting of relationships (6325e0e)
- deps: update dependency remeda to ^1.29.0 (1ec9348)
- deps: update langium to 2.1.2 (#423) (ba17f44)
- graph: do not add element if it exists implicitly (27b5d7d)
- graph: left-align for edge labels (7e7dea8)
- likec4: improve transparent background for emded (174f296)
- lsp: onBuildPhase should be in async context (2a7f0cb)
0.45.0 (2023-11-04)
- likec4: dedicated page for export with transparent background (e992144)
- likec4: don't emptyOutDir on second run (9d58f39)
- diagrams: absolute position for FullscreenDiagram (29741f1)
- diagrams: adjust label positions (afdad65)
- diagrams: correct node label positions (500f53d)
- diagrams: smooth animation (ad054ce)
- docs: css classes for embedded diagram (9a0418a)
- layouts: strict align for node and edge labels (813fd10)
- vscode: git changes were parsed too, that led to duplicate entries (04d1a7f)
0.44.1 (2023-11-02)
0.44.0 (2023-10-30)
0.43.1 (2023-10-29)
- diagrams: better timing for edge onhover (2dec801)
- vscode: do not fail if source file was removed (96e15ff)
0.43.0 (2023-10-29)
- diagrams: highlight elements of the hovered edge (7e65b0e)
- language: add validation for incoming and outgoing expressions (b31c1f1)
0.42.2 (2023-10-28)
- graph: handle
-> .. ->
expressions (c7fb33e) - layouts:
haveNoOtherEdges
condition should be only for root (095c4ac)
0.42.1 (2023-10-26)
- cli: wrong vite entrypoint when embeded (4f43536)
0.42.0 (2023-10-26)
- cli: export to PNG from preview (6996184)
0.41.0 (2023-10-25)
-
diagrams: relationship kinds by @MoBoo (#342)
DocsRelationship kinds allow you to express different types of relations in a model and customize styling.
Example:
specification { relationship async { color amber line dotted head diamond } } model { service1 -[async]-> service2 }
-
cli: new CLI and preview mode
Try this in folder with your
*.c4
filesnpx likec4 serve
Documentation is updating... 👷
-
cli: export to static website
npx likec4 build -o dist
-
cli: Scaffold projects with
npm create likec4
(ef7cf93) -
diagrams: dashed relationships by default (3593d71)
- diagrams: don't animate element if animation is disabled (b039602)
- likec4: responsive embeds (c8b187d)
- likec4: use deviceScaleFactor = 2 (ad8099a)
- likec4: use window size for export/embed (a0b3d6b)
- remove redundant implicit edges (4a8daaf)
- use [...] for merged edges (81282e6)
- vscode launch task loads source maps (c867401)
@MoBoo made their first contribution in #374
0.40.0 (2023-10-09)
0.37.1 (2023-09-16)
- vscode: "Open source" from element context menu in preview panel (8b19661)
- vscode: Back button in preview panel
- diagrams: improve contextmenu (487972a)
- diagrams: use value from hash as initialViewId, if available (2145de6)
- language: add index view if not present (836a05e)
0.37.0 (2023-09-14)
- language: extends from another view (e2a4d59)
Documentation - cli: export views to Mermaid (#314), thanks to @kcaswick
0.36.0 (2023-09-12)
- cli: option to use custom HTML template for exported png (4e7ef2c)
This allows use custom CSS styling and render additional elements, like View title, description or watermarks.
Documentation
- language-server: separate elements and tags in specification (#305) (796068f)
- vscode: improve logging and telemetry (#310) (cd175e2)
0.35.0 (2023-09-09)
- diagrams: add
resetHashOnUnmount
andonReturnToInitial
props touseViewId
hook (#301) (563b35b) - update typescript to ^5.2.2 (#298) (956c180)
- use Node 20 (faf7949)
- babel compatiblity with Node 20.6 (b35846c)
- deps: update vitest ^0.34.3 (#297) (c4a2dbf)
- language-server: memory leak on keeping reference to element (c7e37f4)
0.34.0 (2023-09-01)
- CLI fails to export image on Windows (#281) (cc7e054), closes #280
- improve errors handling (98735ac)
- workaround for a bug in the
[email protected]
(2e20b96)
0.33.1 (2023-08-12)
No changes, just trigger release.
0.33.0 (2023-08-12)
We do not change major version yet, as the project is in active development.
This release includes breaking changes in @likec4/diagrams
:
- diagrams: DiagramsBrowser
You've already seen this component working on the project website, but it was not back-ported to the npm-module - diagrams: LikeC4 factory
Creates components, "bound" to your model, with type checks. It ensures that only existing views can be rendered.
With codegen
command, CLI generates structured data, like:
export const LikeC4Views = {
indexLR: {
title: 'Landscape View'
nodes: [/* ... */],
edges: [/* ... */],
},
cloud: {
title: 'Overview of Cloud'
nodes: [/* ... */],
edges: [/* ... */],
},
}
This data is used to draw views with @likec4/diagrams
react component.
import { LikeC4 } from '@likec4/diagrams'
import { LikeC4Views } from './generated-code'
// Creates components, bound to the data (with type checks).
// It ensures that only existing views can be rendered.
const { Diagram, Responsive, Embedded, Browser } = LikeC4.create(LikeC4Views)
export const IndexView = () => <Embedded viewId={'indexLR'} />
Documentaion (in progress)
- core: add color to DiagramLabel (47b7579)
- core: add in/out edges to ComputedNode (0ddb07c)
- core: available in ESM/CJS
- diagrams: available in ESM/CJS
- generators: can't infer result type from export
./compute-view
(#267) (1945a97) - layouts: disable graphviz.unflatten, requires research (5379926)
- deps: pin esbuild to 0.17 (3d6125d)
- deps: update dependency @hpcc-js/wasm to ^2.13.1 (#254) (3069dab)
- deps: update dependency jotai to ^2.2.3 (#255) (3179777)
- deps: update linters to ^6.3.0 (717770f)
0.32.0 (2023-08-04)
- core: more accurate computeElementView (e57c7c4)
- deps: update dependency class-variance-authority to ^0.7.0 (dd2bf46)
- deps: update dependency lucide-react to ^0.263.1 (d232c26)
- deps: update dependency turbo to ^1.10.11 (#227) (599c230)
- deps: update linters (a347385)
0.31.0 (2023-07-25)
- core: Add tags, description, links properties to View (13edf4c), closes #240
- language-server: Export element and view properties #240
- Relative links are not resolved, follow-up #244
- deps: update commitlint monorepo to ^17.6.7 (dd29487)
- deps: update dependency body-scroll-lock-upgrade to ^1.0.4 (b2da23d)
- deps: update dependency eslint to ^8.45.0 (82efda1)
- deps: update dependency jotai to ^2.2.2 (437a50f)
- deps: update dependency lucide-react to ^0.262.0 (97541cb)
- deps: update dependency remeda to ^1.24.0 (f7ec074)
- deps: update dependency tailwind-merge to ^1.14.0 (4c71882)
- deps: update dependency word-wrap to ^1.2.5 (2c0569c)
- deps: update nextra monorepo to ^2.10.0 (010447c)
- deps: update typescript-eslint monorepo to ^6.1.0 (c0da381)
- diagrams: unique edge key, scoped to diagram, to avoid any issues with diagram transitions (bc270da)
0.30.0 (2023-07-21)
- deps: update dependency word-wrap from 1.2.3 to 1.2.4 (🔒fix: CVE 2023 26115) (2e5f99)
0.29.0 (2023-07-12)
- core: introduce
modern-errors
and replacetiny-invariant
(4caeb61)
- simple caching for model (f79b53c)
- cli: use node:path module #212 (5f6e1d1)
- deps: update dependency lucide-react to ^0.259.0 (9636a47)
- deps: update typescript-eslint monorepo to ^5.62.0 (#209) (2c62486)
- deps: update typescript-eslint monorepo to v6 (major) (#210) (aff4cac)
0.28.3 (2023-07-07)
trigger release
0.28.2 (2023-07-07)
trigger release