Build the new Bento Hub shell and browsing tiles
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/* Draw legacy control glyphs only in Glass; restore them on theme changes. */
|
||||
/* Draw legacy control glyphs in Glass and Bento; restore them on theme changes. */
|
||||
(function(root) {
|
||||
'use strict';
|
||||
const paths = {
|
||||
@@ -45,10 +45,11 @@
|
||||
}
|
||||
function paint() {
|
||||
scheduled=false;observer.disconnect();
|
||||
const active=doc.documentElement.dataset.layout==='glass-stage';
|
||||
const bento=doc.documentElement.dataset.layout==='bento-hub';
|
||||
const active=bento || doc.documentElement.dataset.layout==='glass-stage';
|
||||
for(const [parent,record] of tabLabels)if(!active || !parent.isConnected){restoreTab(parent,record);tabLabels.delete(parent);}
|
||||
for(const record of decorations)if(!active || !record.svg.isConnected){restore(record);decorations.delete(record);}
|
||||
if(active) for(const parent of doc.querySelectorAll(selector)) {
|
||||
if(active) for(const parent of doc.querySelectorAll(selector+(bento?', .service-btn, .np-btn, .ctrl, .empty-icon, .dl-saved-cta, .brand-mark, .upnext-head button':''))) {
|
||||
// Existing SVGs already express the action; only legacy glyphs change.
|
||||
if(parent.querySelector('svg:not(.glass-control-icon),.legacy-nav-icon'))continue;
|
||||
for(const node of [...parent.childNodes]) {
|
||||
|
||||
Reference in New Issue
Block a user