Add a notch mode that splits the bar around a pocket-dots style notch
Settings → Notch switches it on. The bar becomes left and right islands with a notch at the top centre. Super+C, Super+X and a click on the notch open a three-column panel: dashboard pages on the left (Media, Performance, Calendar; the wheel switches them), the Control Center tiles and weather in the middle, and notifications on the right. The Performance card opens the full "Your computer" view. The launcher drops out of the notch. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
178041edf9
commit
5217af4f67
20 files changed
+919
-14
No files matched your search
@@ -84,6 +84,7 @@ function validate(c) {
|
||||
if(!dash || ["enabled","openFromClock","rememberTab","easyEffects"].some(k=>typeof dash[k]!=="boolean") || !["top-left","top-center","top-right","center"].includes(dash.position) || !Array.isArray(dash.tabs))throw Error("Invalid dashboard preferences");
|
||||
const dashTabs=new Set();
|
||||
for(const t of dash.tabs) { if(!t || typeof t.id!=="string" || dashTabs.has(t.id) || typeof t.enabled!=="boolean")throw Error("Invalid dashboard tab"); dashTabs.add(t.id); }
|
||||
if(!c.notch || ["enabled","mediaFirst"].some(k=>typeof c.notch[k]!=="boolean"))throw Error("Invalid notch preferences");
|
||||
if(typeof c.osd.enabled!=="boolean" || !["slide","drop","fade","shrink"].includes(c.osd.animation) || !["top-right","top-center","bottom-center"].includes(c.osd.position) || !Number.isInteger(c.osd.timeout) || c.osd.timeout<500 || c.osd.timeout>5000 || !Number.isInteger(c.osd.step) || c.osd.step<1 || c.osd.step>20)throw Error("Invalid OSD preferences");
|
||||
const notes=c.notifications;
|
||||
if(!notes || ["enabled","doNotDisturb","criticalInDnd"].some(k=>typeof notes[k]!=="boolean") || !["slide","drop","fade","shrink"].includes(notes.animation) || !["top-right","top-center"].includes(notes.position) || !Number.isInteger(notes.timeout) || notes.timeout<1000 || notes.timeout>30000 || !Number.isInteger(notes.maxPopups) || notes.maxPopups<1 || notes.maxPopups>6)throw Error("Invalid notification preferences");
|
||||
|
||||
@@ -239,6 +239,7 @@ Singleton {
|
||||
activePopout.close();
|
||||
activePopout = owner;
|
||||
ShellState.controlCenterOpen = false;
|
||||
ShellState.notchOpen = false;
|
||||
ShellState.dashboardOpen = false;
|
||||
PopoutState.close();
|
||||
TrayService.close();
|
||||
|
||||
@@ -39,6 +39,10 @@ Singleton {
|
||||
if (!ShellState.controlCenterOpen)
|
||||
root.cancel();
|
||||
}
|
||||
function onNotchOpenChanged() {
|
||||
if (!ShellState.notchOpen)
|
||||
root.cancel();
|
||||
}
|
||||
function onSettingsPageChanged() {
|
||||
root.cancel();
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ Singleton {
|
||||
readonly property var features: {
|
||||
if (!ConfigService.ready)
|
||||
return [];
|
||||
if (ShellState.controlCenterOpen)
|
||||
if (ShellState.controlCenterOpen || ShellState.notchOpen)
|
||||
return ConfigService.data.controlCenter.modules.filter(m => m.enabled && ["brightness", "nightLight", "dnd", "profiles", "power"].includes(m.id)).map(m => m.id);
|
||||
if (ShellState.dashboardOpen)
|
||||
return ["power"];
|
||||
|
||||
@@ -71,6 +71,7 @@ Singleton {
|
||||
if (!options.enabled || !item || !item.hasMenu || !icon)
|
||||
return false;
|
||||
ShellState.controlCenterOpen = false;
|
||||
ShellState.notchOpen = false;
|
||||
ShellState.launcherOpen = false;
|
||||
ShellState.settingsOpen = false;
|
||||
currentItem = item;
|
||||
|
||||
Reference in new issue
Block a user