-
Notifications
You must be signed in to change notification settings - Fork 39
Add generic line style with customizable stroke attributes and outline feature #1270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
…asharray Co-authored-by: thekingofcity <[email protected]>
thekingofcity
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot It should be possible that two same paths with different width and color exist if users request. This could create a line with an outline.
Yes, this is already supported! Users can create multiple lines between the same two stations using the generic style with different widths and colors. When
The implementation uses independent |
|
@copilot No, there should be no relation to the parallelIndex. And do not use pre/postComponent. Just create two path element if user requested by ticking the outline checkbox. |
Co-authored-by: thekingofcity <[email protected]>
Implemented! The generic line style now has an outline checkbox that renders two Changes in commit 75fd135:
The outline fields appear in the details panel only when the outline checkbox is enabled. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|

Implements a new generic line style allowing users to customize path appearance independently of city-specific transit system styles.
Changes
New line style component (
src/components/svgs/lines/styles/generic.tsx)color,width,linecap(butt/round/square),dasharrayoutline: Boolean toggle to enable/disable outlineoutlineColor: Color for the outer/background pathoutlineWidth: Width for the outer path<path>element<g>group with two<path>elements (outline + fill)ColorFieldandRmgFieldscomponents for consistent UIType registration (
src/constants/lines.ts)Generic = 'generic'toLineStyleTypeenumGenericAttributesinterface toExternalLineStyleAttributesRuntime registration (
src/components/svgs/lines/lines.ts)lineStylesobjectInternationalization (
src/i18n/translations/*.json)Save version upgrade (
src/util/save.ts,src/util/save.test.ts)CURRENT_VERSION66 → 67Example Usage
Screenshots
The generic line style appears in the line style selector alongside existing city-specific styles.
The outline checkbox and associated fields appear in the details panel when a line with generic style is selected.
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.