feat(spa): reintroduce --config for metadata override + view extras#21
Merged
Conversation
PR #20 removed the legacy --config flag because the lutaml-uml static-site pipeline (which is what consumed it) was being dropped. That also removed legitimate metadata customization for downstream users like plateau-model. This adds a native --config that: - overrides Ea::Model::Metadata fields (title, description, version, ...) - surfaces ui/appearance sections to the SPA skeleton as viewExtras - works with both SingleFile and ShardedMultiFile output strategies The SingleFileStrategy <title> tag now prefers ui.title (browser-tab text) over metadata.title (model title), matching the prior UX. Bumps version to 0.3.0 because the native pipeline + this flag are incompatible with the 0.2.x lutaml-uml-based SPA default.
Adds Ea::Svg::Renderer that consumes the umldi content (placed element bounds + connector waypoints) captured in Ea::Model::Diagram and emits standalone SVG. Coordinates are taken straight from the source pixel space. Architecture: - Ea::Svg::BoundsCalculator — unions element rects and waypoint positions; normalizes EA's inverted rects (rectbottom < recttop) - Ea::Svg::StyleResolver — translates EA packed style (BGR integer colors, line widths) to CSS-friendly SVG attributes - Ea::Svg::ElementBox — renders one DiagramElement as a labeled box - Ea::Svg::ConnectorPath — renders one DiagramConnector as a polyline through waypoints - Ea::Svg::Renderer — orchestrates; emits standalone XML SVG CLI: new `ea svg NAME FILE [--output=PATH]` command renders a named diagram to disk. Distinct from Ea::Diagram::SvgRenderer which operates on the legacy Lutaml::Uml::Document pipeline. This module consumes the canonical Ea::Model types only. Also fixes the stale `does not expose --config` spec from PR #20 (we just reintroduced --config).
ronaldtse
added a commit
that referenced
this pull request
Jul 19, 2026
The metanorma/ci rubygems-release workflow owns the version bump — it expects to be the one that writes the new version to lib/ea/version.rb and commits it. With the version already at 0.3.0 (committed in PR #21), the bump step is a no-op and git aborts with 'nothing to commit'. This revert returns the file to 0.2.5 so the release workflow can do its job. The actual 0.3.0 release content is already on main.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR #20 dropped the legacy
--configflag because it was tied to the lutaml-uml static-site pipeline. This adds a native replacement so downstream repos (plateau-model) can customize metadata.What it does
--config FILE(-calias) reads a YAML filemetadata:section overrides fields onEa::Model::Metadata(title, description, version, ...)ui:andappearance:sections are surfaced to the SPA skeleton asviewExtrasSingleFileStrategyandShardedMultiFileStrategyhonor the override<title>tag now prefersui.titleovermetadata.title(matches prior UX)Version bump
0.2.5→0.3.0. The native pipeline is the new default and is incompatible with the old lutaml-uml-based SPA default.Validation
spec/ea/spa/configuration_spec.rbandspec/ea/cli/spa_spec.rbea spa basic.qea -c config.ymlproduces HTML with overridden title and viewExtrasWhy no breaking-change guard concern
This is a feature addition (new flag). The breaking change was PR #20; that one already landed.