@@ -271,6 +271,11 @@ html.dark .lb-fav:hover { background:rgba(245,158,11,0.22) !important; }
271271 var state = { v: v };
272272
273273 if (v === ' composite' ) {
274+ /* View (table vs graph) */
275+ if (typeof window .compositeGetView === ' function' ) {
276+ var cv = window .compositeGetView ();
277+ if (cv && cv !== ' table' ) state .view = cv;
278+ }
274279 /* Protocol */
275280 var protos = [];
276281 document .querySelectorAll (' .composite-proto-select.active' ).forEach (function (p ) { protos .push (p .dataset .proto ); });
@@ -361,6 +366,7 @@ html.dark .lb-fav:hover { background:rgba(245,158,11,0.22) !important; }
361366 if (state .lang ) parts .push (' lang=' + encodeURIComponent (state .lang ));
362367 if (state .engine ) parts .push (' engine=' + encodeURIComponent (state .engine ));
363368 if (state .q ) parts .push (' q=' + encodeURIComponent (state .q ));
369+ if (state .view ) parts .push (' view=' + state .view );
364370 var newHash = parts .length > 0 ? ' #' + parts .join (' &' ) : ' ' ;
365371 if (location .hash !== newHash) history .replaceState (null , ' ' , newHash || location .pathname );
366372 }
@@ -465,6 +471,10 @@ html.dark .lb-fav:hover { background:rgba(245,158,11,0.22) !important; }
465471 }
466472 if (typeof renderComposite === ' function' ) renderComposite ();
467473 if (typeof updateCompositeNote === ' function' ) updateCompositeNote ();
474+ /* View (table vs graph) — apply after filters so the first paint uses them */
475+ if (typeof window .setCompositeView === ' function' ) {
476+ window .setCompositeView (p .view === ' graph' ? ' graph' : ' table' );
477+ }
468478 return ;
469479 }
470480
@@ -530,6 +540,7 @@ html.dark .lb-fav:hover { background:rgba(245,158,11,0.22) !important; }
530540 t .closest (' .lb-dropdown-item' ) || t .closest (' .composite-type-filter' ) ||
531541 t .closest (' .composite-proto-select' ) || t .closest (' .composite-profile-filter' ) ||
532542 t .closest (' .composite-dropdown-item' ) || t .closest (' .composite-resource-toggle' ) ||
543+ t .closest (' .composite-view-tab' ) ||
533544 t .closest (' [class*="lb-tab"]' )) {
534545 window .dlScheduleUpdate ();
535546 }
0 commit comments