Code reference detail
GraphControls.svelte
packages/extension/webviews/ideas-summary/components/GraphControls.svelte
| Idea | Status | Tags | Summary | Katz |
|---|---|---|---|---|
| graph_design | The graph should show nodes for ideas and files and edges for references. Used by Ideas Summary, activity-bar minigraph, and export previews. | 0.040 | ||
| graph_label_modes | done | Every interactive graph should provide a Labels control that cycles auto ( default ), on, and off without changing graph membership. On forces full opacity; off hides all labels; auto follows [graph_label_auto]. Reset / default restore auto. Ideas Summary: control in ["../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte"], mode persisted via ["../workspace-summary/ideas_summary/graphical_graph.rq".graph_ui_persistence]. HTML export: control in ["../../../crates/reqlan-export/src/html_template/mod.rs"] / ["../../../crates/reqlan-export/assets/app.js"]. Driven by the same viewport zoom as [view_controls]. | 0.148 | |
| graph_status_tag_filters | done | Status and tag graph filters are searchable checkbox dropdowns ( still a dropdown trigger; multi-select via checkboxes; OR within each field ). They must distinguish attribute absence from an empty declaration and from a literal unspecified value: - Not present — attribute key absent ( no `@status` / no `@tags` ) - Empty — attribute declared with no value ( `@status`, `@tags`, `@status ""`, bare flag ) - unspecified — literal authored value " unspecified " Do not invent unspecified for missing attributes in rollups, clusters, or filter options. Special options render differently from concrete values ( italic muted Not present; info-tint Empty; warning-tint unspecified ). Shared helpers live in ["../../../packages/analytical/src/core/filter-specials.ts"]. Surfaces: Ideas Summary SearchableCheckboxDropdown; HTML export SCD in ["../../../crates/reqlan-export/assets/app.js"]. | 0.134 | |
| manual_reframe | Users can explicitly reframe the viewport when pan / zoom has moved the graph off-screen or they want to see the whole neighbourhood again. - " Fit to view " control in ["../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte"] dispatches to GraphView → GraphCyController. reframeToViewport ( ). - " Fit to view " control in ["../../../packages/extension/webviews/activity-bar/components/MiniGraphCanvas.svelte"] calls the same API on the mini-graph controller. Every graph surface that mounts GraphCyController should expose this control. | 0.150 | ||
| file_treatment_toggle | done | Toolbar dropdown selects how hosting `.rq` files ( implicit ideasets ) appear in the graph — distinct from explicit AST `ideaset` declarations and from external `file:` reference nodes. Options ( with info tooltips / help text ): - invisible / Hidden — no file containers or file leaf nodes; ideas float free - compound — one compound parent per hosting file ( basename label ); nests under folder / tag compounds when Controls → Compound is also on. Containers are draggable ( members move with the box; live physics pins descendants while dragging ). Clicking the title opens the file; double-click also opens. - linked / Linked nodes ( default ) — synthetic ideaset-styled leaf per hosting file ( `rq-file:…` ) with `ideaset_member` edges to ideas in that file; click / dbl-click opens the hosting file like other nodes. Client reshape via `applyFileTreatment` in ["../../../../packages/extension/webviews/shared/graph/file-treatment.ts"]; no re-query on mode flip. Ideas Summary: `FileTreatmentSelect` on GraphControls; persisted as `fileTreatment` in [graph_ui_persistence]. HTML export: same three options via a select; compound boxes are hittable / draggable with clickable titles; linked nodes carry `pageUrl` / `hostFilePageUrl` for navigation. Related: [graphical_graph], [ui_controls], [webview_export_graph_parity], ["../../../ontology.rq".file], ["../../../ontology.rq".ideaset], [html_export_graph_page]. | 0.170 | |
| graphical_graph | There should be a tab that renders requirement ideas and references as a force-directed web. The graph tab lives in the Ideas Summary webview per [ideas_summary]. UI is implemented in ["../../../../packages/extension/webviews/ideas-summary/components/GraphView.svelte"]. Graph slices are built in ["../../../../packages/analytical/src/index-store/webview-graph-queries.ts"] and served by ["../../../../packages/extension/src/ideas_summary_module/ideas-summary-panel.ts"]. By default the view focuses on the active editor file's first idea; without a focus it shows a capped slice of matching ideas rather than dumping the full graph. Users can filter by search text, path, multi-select @ status, and multi-select tags per [graph_status_tag_filters]. An " Indirect references " toggle expands neighbourhood depth from 1 to 2 hops. A " Wildcard refs " toggle includes or hides edges expanded from path + idea wildcards per [wildcard_refs_toggle] ["@/reqlan rq/language/imports.rq".wildcard_references] A " Files " dropdown selects hosting- `.rq` treatment per [file_treatment_toggle] ( hidden / compound containers / linked ideaset nodes ), with per-option info tooltips. Interactive graph controls that also exist on HTML export must stay aligned per [webview_export_graph_parity]. Clicking a node opens its source; double-click or " Focus graph " recenters the slice on that idea. Linked file ideaset nodes and file-compound titles open the hosting `.rq` file per [file_treatment_toggle]. External file references render as dashed edges to file nodes; wildcard-fan-out edges render dotted. A toggleable key explains node colours and edge styles and toggles node-type visibility per [key_panel_toggle]; a toggleable [control_panel] exposes layout, physics, and node-budget settings. Key and Controls state persist per workspace via [graph_ui_persistence]. Pan, zoom, and drag repositioning per [view_controls]. [manual_reframe] via " Fit to view " in [ui_controls]; [auto_reframe] when the loaded node set changes; [reframe_animation] for smooth transitions after the first paint. Node text labels per [graph_labels], [graph_label_modes], and [graph_label_auto]. Layout, compound grouping, and live physics behaviour per [layout_physics], [layout_options], [physics_options], and [compound_graph]. Cytoscape lifecycle and threading constraints per [graph_cy_controller] and [webview_threading]. | 0.207 | ||
| ui_controls | Controls live in ["../../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte"] and dispatch events to GraphView. [manual_reframe] — " Fit to view " calls GraphCyController. reframeToViewport per [reframe_view]. [auto_reframe] and [reframe_animation] are handled by the shared controller; no extra UI beyond pan / zoom / drag. Labels control cycles [graph_label_modes] ( auto / on / off ) and applies [graph_label_auto] via GraphCyController. setLabelMode. Files dropdown ( [file_treatment_toggle] ) uses ["../../../../packages/extension/webviews/ideas-summary/components/FileTreatmentSelect.svelte"] with Hidden / Compound / Linked options and info tooltips; selection patches `fileTreatment` in [graph_ui_persistence]. Status and tag filters are multi-select dropdowns per [graph_status_tag_filters]. The Key button toggles a draggable legend panel in ["../../../../packages/extension/webviews/ideas-summary/components/GraphKeyPanel.svelte"] over the graph canvas. The Controls button toggles [control_panel]. Overlay panels ( Key and Controls ) are siblings of the cytoscape mount inside a graph-surface-wrap — never children of the cy container — so native form controls receive pointer events. | 0.167 | ||
| webview_export_graph_parity | done | Interactive graph behaviour that authors rely on in Ideas Summary must have a matching affordance on the HTML export workspace graph ( [html_export_graph_page] ) unless a requirement explicitly scopes it to one host. Shared today: Labels auto / on / off, live physics, Fit, status / tag filters, path / search filters, hide external files, hide ideasets ( explicit AST ), [file_treatment_toggle] ( dropdown with the same three modes, compound drag / title-open, linked-node open ), and [wildcard_refs_toggle] ( default on; dotted wildcard edges ). Ideas Summary may still differ where the host model differs: Indirect refs rebuilds hop depth via `buildGraphViewSlice` ( export freezes neighbourhood at snapshot time — no Indirect chip ); Key / Controls panels and node-budget controls are webview-only; export uses client-side filters on the embedded graph JSON rather than re-querying the index; Ideas Summary uses cytoscape compound parents while export draws AABB compound boxes on canvas. When adding a new Ideas Summary graph chip or edge style, update [html_export_graph_page] ( or document an intentional exception here ) and keep labels / defaults aligned across surfaces. Related: [graphical_graph], [wildcard_refs_toggle], [file_treatment_toggle], [ui_controls], [graph_labels], [graph_label_modes], [graph_status_tag_filters]. | 0.165 | |
| wildcard_refs_toggle | done | Toolbar chip " Wildcard refs " ( next to Indirect refs ) on GraphControls toggles `GraphViewQuery.includeWildcardRefs`. Default true — edges of kind `wildcard_reference` from the indexer fan-out stay visible ( ["../../../indexer/indexer.rq".wildcard_reference_edges] ). When false, `buildGraphViewSlice` omits those edges and does not expand neighbourhood through them ( `includeWildcardRefs!== false` normalisation in Ideas Summary host + analytical query ). Distinct from plain `references` and from the Indirect refs depth toggle; Key legend shows a dotted " Wildcard reference " row; cytoscape marks `edge[?isWildcard]` with `line-style: dotted`. Query field flows Ideas Summary loadGraph → `buildGraphViewSlice` in ["../../../../packages/analytical/src/index-store/webview-graph-queries.ts"]. HTML export workspace graph has the same chip ( client filter on embedded edges; dotted stroke ) per [webview_export_graph_parity] and [html_export_graph_page]. Related: ["../../../language/imports.rq".wildcard_references], ["../../../indexer/indexer.rq".wildcard_reference_edges], ["../../../indexer/indexer.rq".index], [graphical_graph], [ui_controls], [webview_export_graph_parity]. | 0.308 |
Reference labels
"../../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte", "../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte", ../../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte, ../../../packages/extension/webviews/ideas-summary/components/GraphControls.svelte