Skip to content

Jep/utility#108

Merged
Drakae merged 6 commits into
masterfrom
jep/utility
Jun 30, 2026
Merged

Jep/utility#108
Drakae merged 6 commits into
masterfrom
jep/utility

Conversation

@Drakae

@Drakae Drakae commented Jun 30, 2026

Copy link
Copy Markdown
Contributor
  • adjusted fault tree visualization (condition for inhibit gate is now right with port east)
  • option to hide redundant gates in fault trees
  • causal factors are not in camel case

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refines the fault tree (FTA) rendering pipeline in the language server and webview by improving gate/condition visualization and introducing a synthesis option to hide “redundant” gates, along with a STPA grammar tweak for causal-factor naming.

Changes:

  • Adjust K/N gate label positioning in the webview renderer.
  • Add a new FTA synthesis option to show/hide redundant gates and update diagram generation/layout behavior (including inhibit-gate condition port placement).
  • Change STPA CausalFactor literals to PascalCase and update FTA top-event naming to include hazard ID.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
extension/src-webview/views-rendering.tsx Centers the K/N gate text label horizontally.
extension/src-language-server/stpa/stpa.langium Updates CausalFactor keyword literals (currently a breaking change).
extension/src-language-server/stpa/ftaGeneration/fta-generation.ts Includes hazard name in generated FTA top-event label.
extension/src-language-server/fta/diagram/fta-synthesis-options.ts Introduces “Show Redundant Gates” synthesis option (and exposes getter).
extension/src-language-server/fta/diagram/fta-layout-config.ts Enables ELK hierarchy handling to include children.
extension/src-language-server/fta/diagram/fta-diagram-generator.ts Implements redundant-gate hiding, fixes inhibit-gate condition port side, and adjusts gate-description generation flow.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread extension/src-language-server/fta/diagram/fta-diagram-generator.ts
Comment thread extension/src-language-server/fta/diagram/fta-diagram-generator.ts
Comment thread extension/src-language-server/fta/diagram/fta-diagram-generator.ts
Comment thread extension/src-language-server/fta/diagram/fta-synthesis-options.ts Outdated
Comment on lines 145 to +149
CausalFactor returns string:
'controlAction' | 'inadequateOperation' | 'delayedOperation' | 'componentFailure' | 'changesOverTime' |
'conflictingCA' | 'wrongProcessInput' | 'disturbance' | 'processOutput' | 'delayedFeedback' |
'measurementInaccurate' | 'incorrectInformationProvided' | 'missingFeedback' | 'inadequateControlAlgorithm' |
'wrongProcessModel' | 'wrongControlInput';
'ControlAction' | 'InadequateOperation' | 'DelayedOperation' | 'ComponentFailure' | 'ChangesOverTime' |
'ConflictingCA' | 'WrongProcessInput' | 'Disturbance' | 'ProcessOutput' | 'DelayedFeedback' |
'MeasurementInaccurate' | 'IncorrectInformationProvided' | 'MissingFeedback' | 'InadequateControlAlgorithm' |
'WrongProcessModel' | 'WrongControlInput';
@Drakae Drakae merged commit 1cd36cc into master Jun 30, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants