diff --git a/config/ags/apps/settings/apps.ts b/config/ags/apps/settings/apps.ts index c9f10f61..64ff9a18 100644 --- a/config/ags/apps/settings/apps.ts +++ b/config/ags/apps/settings/apps.ts @@ -3,7 +3,7 @@ import { MaterialIcon } from "icons"; const Row = (app: string, title: string, icon: string) => Widget.EventBox({ class_name: "row", - on_primary_click: self => { + on_primary_click_release: self => { self.child.children[1]!.activate() }, child: Widget.Box({ diff --git a/config/ags/apps/settings/bluetooth.ts b/config/ags/apps/settings/bluetooth.ts index 45da047b..90d28506 100644 --- a/config/ags/apps/settings/bluetooth.ts +++ b/config/ags/apps/settings/bluetooth.ts @@ -33,7 +33,7 @@ const BluetoothToggle = () => Widget.EventBox({ }), Widget.Switch({ vexpand: false, - hpack: "center", + vpack: "center", hpack: "end", on_activate: self => { if (self.state != bluetooth.enabled) @@ -43,10 +43,10 @@ const BluetoothToggle = () => Widget.EventBox({ }) ] }), - on_primary_click: (self) => { + on_primary_click_release: (self) => { self.child.children[1]!.activate(); }, - on_secondary_click: (self, event) => { + on_secondary_click_release: (self, event) => { Widget.Menu({ children: [Widget.MenuItem({ child: HpackStartLabel("Open blueman-manager"), @@ -90,10 +90,10 @@ const DeviceMenu = (device: BluetoothDevice) => { const DeviceItem = (device: BluetoothDevice) => Widget.Button({ class_name: "row", - on_primary_click: () => { + on_primary_click_release: () => { device.setConnection(!device.connected); }, - on_secondary_click: (self, event) => { + on_secondary_click_release: (self, event) => { DeviceMenu(device)?.popup_at_pointer(event); }, child: Widget.Box({ diff --git a/config/ags/apps/settings/info.ts b/config/ags/apps/settings/info.ts index 829b55e8..35291bb8 100644 --- a/config/ags/apps/settings/info.ts +++ b/config/ags/apps/settings/info.ts @@ -11,8 +11,8 @@ const Row = ( on_primary_click: any = empty_func, on_secondary_click: any = empty_func ) => Widget.EventBox({ class_name: "row", - on_primary_click: on_primary_click, - on_secondary_click: on_secondary_click, + on_primary_click_release: on_primary_click, + on_secondary_click_release: on_secondary_click, child: Widget.Box({ class_name: "row", vpack: "start", @@ -39,21 +39,21 @@ const Row = ( }) }) -const repo_link = "https://github.com/S4NKALP/hyprland" +const repo_link = "https://github.com/koeqaife/hyprland-material-you" const current_de = GLib.getenv("DESKTOP_SESSION"); export function Info() { const box = Widget.Box({ vertical: true, children: [ - Row("Dotfiles", "hyprland"), - Row("Author", "S4NKALP (Discord)"), + Row("Dotfiles", "Material You"), + Row("Author", "mrdan__ (Discord)"), Row("Repo", repo_link, () => { Utils.execAsync(`xdg-open "${repo_link}"`).catch(print) }), Widget.Separator(), - Row("OS", current_os), Row("DE", current_de!), + Row("OS", current_os), Row("Kernel", kernel_name), Row("CPU", `${cpu_name} (${cpu_cores} Cores)`), Row("GPU", `${gpu_name}`), diff --git a/config/ags/apps/settings/main.ts b/config/ags/apps/settings/main.ts index ae9d1a3e..2c2d0202 100644 --- a/config/ags/apps/settings/main.ts +++ b/config/ags/apps/settings/main.ts @@ -20,12 +20,8 @@ export async function OpenSettings(cur_tab: string = "network") { }) if (_client && _current_workspace != _client.workspace.id) { current_tab.setValue(cur_tab) - print("a") current_window.hide() current_window.show() - // current_window.destroy(); - // current_window = undefined; - // SettingsWindow(cur_tab); } else current_tab.setValue(cur_tab) @@ -46,6 +42,7 @@ function Settings(cur_tab: string) { children: { "network": Page(Network(), "Network"), "bluetooth": Page(Bluetooth(), "Bluetooth"), + "theme": Page(Theme(), "Theme"), "wallpaper": Page(Wallpapers(), "Wallpapers"), "info": Page(Info(), "Info"), "apps": Page(Apps(), "Apps") @@ -59,7 +56,7 @@ function Settings(cur_tab: string) { Widget.Label(label) ] }), - class_name: current_tab.bind().as(c => c == name ? "row active" : "row") + class_name: current_tab.bind().as(c => c == name ? "sidebar_row active" : "sidebar_row") }) const sidebar = Widget.Box({ vertical: true, diff --git a/config/ags/apps/settings/network.ts b/config/ags/apps/settings/network.ts index a4b47f1a..e8207a9f 100644 --- a/config/ags/apps/settings/network.ts +++ b/config/ags/apps/settings/network.ts @@ -63,7 +63,7 @@ const WifiNetwork = (access_point: AccessPoint) => { const connected = access_point.ssid == network.wifi.ssid; return Widget.Button({ class_name: "row", - on_primary_click: () => { + on_primary_click_release: () => { if (!connected) Utils.execAsync(`nmcli device wifi connect '${access_point.ssid}'`) .catch(print); @@ -71,7 +71,7 @@ const WifiNetwork = (access_point: AccessPoint) => { Utils.execAsync(`${App.configDir}/scripts/network.sh --edit ${access_point.ssid}`) .catch(print); }, - on_secondary_click: () => { + on_secondary_click_release: () => { if (!connected && is_saved) Utils.execAsync(`${App.configDir}/scripts/network.sh --edit ${access_point.ssid}`) .catch(print); @@ -155,7 +155,7 @@ const WifiToggle = () => Widget.EventBox({ }) ] }), - on_primary_click: self => { + on_primary_click_release: self => { self.child.children[1]!.activate(); } }) diff --git a/config/ags/modules/bar.ts b/config/ags/modules/bar.ts index 06d806bc..9ae659ab 100644 --- a/config/ags/modules/bar.ts +++ b/config/ags/modules/bar.ts @@ -172,25 +172,31 @@ function BatteryLabel() { function SysTray() { - const items = systemtray.bind("items") - .as(items => items.map(item => { - if (item.id.trim() != "nm-applet" && item.id.trim() != "blueman") { - return Widget.Button({ - child: Widget.Icon({ icon: item.bind("icon") }), - on_primary_click: (_, event) => item.activate(event), - on_secondary_click: (_, event) => item.openMenu(event), - tooltip_markup: item.bind("tooltip_markup"), - }) - } else { - return undefined - } - })) - - // @ts-ignore return Widget.Box({ class_name: "tray", spacing: 5, - children: items, + setup: (self) => { + self.hook(systemtray, () => { + const items = systemtray.items; + // @ts-expect-error + self.children = items.map(item => { + if (item.id.trim() != "nm-applet" && item.id.trim() != "blueman") { + return Widget.Button({ + child: Widget.Icon({ icon: item.bind("icon") }), + on_primary_click_release: (_, event) => item.activate(event), + on_secondary_click_release: (_, event) => item.openMenu(event), + tooltip_markup: item.bind("tooltip_markup"), + }) + } else { + return undefined + } + }); + if (self.children.length > 0) + self.visible = true; + else + self.visible = false; + }) + } }) } @@ -217,7 +223,7 @@ function Wifi() { on_primary_click: () => { OpenSettings("network") }, - on_secondary_click: (_, event) => { + on_secondary_click_release: (_, event) => { const nm_applet = systemtray.items.find(item => item.id == "nm-applet") if (nm_applet) { nm_applet.openMenu(event) @@ -243,10 +249,10 @@ function Wifi() { function Bluetooth() { return Widget.Button({ class_name: "bar_bluetooth", - on_primary_click: () => { + on_primary_click_release: () => { OpenSettings("bluetooth") }, - on_secondary_click: (_, event) => { + on_secondary_click_release: (_, event) => { const blueman = systemtray.items.find(item => item.id == "blueman") if (blueman) { blueman.openMenu(event) @@ -278,10 +284,10 @@ function MediaPlayer() { let metadata = mpris.players[0]?.metadata; const button = Widget.Button({ class_name: "filled_tonal_button awesome_icon", - on_primary_click: () => { + on_primary_click_release: () => { App.toggleWindow("media") }, - on_secondary_click: () => { + on_secondary_click_release: () => { Utils.execAsync(["playerctl", "play-pause"]).catch(print) }, child: MaterialIcon("play_circle"), @@ -316,11 +322,11 @@ function KeyboardLayout() { function OpenSideBar() { const button = Widget.Button({ class_name: "filled_tonal_button awesome_icon", - on_primary_click: () => { + on_primary_click_release: () => { App.toggleWindow("sidebar") }, - on_secondary_click: () => { + on_secondary_click_release: () => { OpenSettings() }, child: MaterialIcon("dock_to_left") @@ -387,8 +393,8 @@ function volumeIndicator() { onScrollDown: () => audio.speaker.volume -= 0.01, class_name: "filled_tonal_button volume_box", child: Widget.Button({ - on_primary_click: () => Utils.execAsync("pavucontrol").catch(print), - on_secondary_click: () => audio.speaker.is_muted = !audio.speaker.is_muted, + on_primary_click_release: () => Utils.execAsync("pavucontrol").catch(print), + on_secondary_click_release: () => audio.speaker.is_muted = !audio.speaker.is_muted, child: Widget.Box({ children: [ MaterialIcon("volume_off", "20px").hook(audio.speaker, self => { diff --git a/config/ags/modules/cliphist.ts b/config/ags/modules/cliphist.ts index 92fd2f94..eceb32b7 100644 --- a/config/ags/modules/cliphist.ts +++ b/config/ags/modules/cliphist.ts @@ -9,19 +9,35 @@ type EntryObject = { content: string; entry: string; }; - +// · function ClipHistItem(entry: string) { let [id, ...content] = entry.split('\t'); let clickCount = 0; let button = Widget.Button({ - class_name: "entry_container", - child: Widget.Label({ - label: entry, - class_name: "entry_label", - xalign: 0, - vpack: "center", - truncate: "end", + class_name: "clip_container", + child: Widget.Box({ + children: [ + Widget.Label({ + label: id, + class_name: "clip_id", + xalign: 0, + vpack: "center", + }), + Widget.Label({ + label: "・", + class_name: "dot_divider", + xalign: 0, + vpack: "center", + }), + Widget.Label({ + label: content.join(' ').trim(), + class_name: "clip_label", + xalign: 0, + vpack: "center", + truncate: "end", + }), + ] }) }) @@ -44,7 +60,7 @@ function ClipHistItem(entry: string) { children: [ button, Widget.Separator({ - class_name: "entry_divider", + class_name: "clip_divider", orientation: Gtk.Orientation.HORIZONTAL }) ] diff --git a/config/ags/modules/musicplayer.ts b/config/ags/modules/musicplayer.ts new file mode 100644 index 00000000..009cf69a --- /dev/null +++ b/config/ags/modules/musicplayer.ts @@ -0,0 +1,112 @@ +const WINDOW_NAME = "musicplayer"; +import popupwindow from './misc/popupwindow.ts'; +import Box from 'types/widgets/box.js'; +import Gtk from "gi://Gtk?version=3.0"; +import GLib from "gi://GLib?version=2.0"; + +type Track = { + id: string; + title: string; + artist: string; + url: string; // Assuming we use URLs for identification, but not playback. +}; + +function MusicPlayerItem(track: Track) { + let button = Widget.Button({ + class_name: "track_container", + child: Widget.Label({ + label: `${track.title} - ${track.artist}`, + class_name: "track_label", + xalign: 0, + vpack: "center", + truncate: "end", + }) + }); + + button.connect('clicked', () => { + playTrack(track); // Function to handle playback + }); + + return Widget.Box({ + orientation: Gtk.Orientation.VERTICAL, + children: [ + button, + Widget.Separator({ + orientation: Gtk.Orientation.HORIZONTAL + }) + ] + }); +} + +async function playTrack(track: Track) { + try { + // Placeholder for playing audio via libcanberra or other suitable GTK audio APIs + GLib.spawn_command_line_async(`canberra-gtk-play -i audio-file-id`); + } catch (error) { + console.error(`Error playing track: ${error}`); + } +} + +function MusicPlayerWidget({ width = 500, height = 500, spacing = 12 }) { + let tracks: Track[] = [ + { id: "1", title: "Track 1", artist: "Artist 1", url: "1" }, + { id: "2", title: "Track 2", artist: "Artist 2", url: "2" }, + { id: "3", title: "Track 3", artist: "Artist 3", url: "3" } + // Add more tracks as needed + ]; + + let widgets: Box[] = tracks.map(track => MusicPlayerItem(track)); + + const list = Widget.Box({ + vertical: true, + spacing, + children: widgets + }); + + const entry = Widget.Entry({ + hexpand: true, + class_name: "musicplayer_entry", + placeholder_text: "Search", + + on_change: ({ text }) => widgets.forEach(item => { + item.visible = item.attribute.content.match(text ?? "") + }), + }); + + return Widget.Box({ + vertical: true, + class_name: "musicplayer_box", + margin_top: 14, + margin_right: 14, + children: [ + entry, + Widget.Scrollable({ + hscroll: "never", + css: `min-width: ${width}px;` + + `min-height: ${height}px;`, + child: list, + }), + ], + setup: self => self.hook(App, (_, windowName, visible) => { + if (windowName !== WINDOW_NAME) + return; + + if (visible) { + entry.text = ""; + } + }), + }); +} + +export const musicplayer = popupwindow({ + name: WINDOW_NAME, + class_name: "musicplayer", + visible: false, + keymode: "exclusive", + child: MusicPlayerWidget({ + width: 500, + height: 500, + spacing: 0, + }), + anchor: ["bottom", "right"] +}); diff --git a/config/ags/modules/notificationPopups.ts b/config/ags/modules/notificationPopups.ts index 1e51866d..fcf3f065 100644 --- a/config/ags/modules/notificationPopups.ts +++ b/config/ags/modules/notificationPopups.ts @@ -38,7 +38,7 @@ export const Notification = (notification: NotificationType, dismiss = true) => vertical: true, children: [ Widget.EventBox({ - on_primary_click: (box) => { + on_primary_click_release: (box) => { // @ts-ignore const label: Label = box.child.children[1].children[1]; if (label.lines < 0) { diff --git a/config/ags/modules/sidebar/management.ts b/config/ags/modules/sidebar/management.ts index b4b542f7..d53f34e0 100644 --- a/config/ags/modules/sidebar/management.ts +++ b/config/ags/modules/sidebar/management.ts @@ -149,17 +149,17 @@ function Page1() { Widget.Box({ orientation: Gtk.Orientation.HORIZONTAL, hexpand: true, - spacing: 2.5, + spacing: 5, children: [ Widget.Button({ hexpand: true, class_name: network.wifi.bind("enabled") .as(enabled => enabled ? "management_button active" : "management_button"), child: NetworkIndicator(), - on_primary_click: () => { + on_primary_click_release: () => { network.toggleWifi(); }, - on_secondary_click: () => { + on_secondary_click_release: () => { App.closeWindow(WINDOW_NAME); App.openWindow("network"); } @@ -174,11 +174,11 @@ function Page1() { icon: "bluetooth", arrow: true, }), - on_primary_click: () => { + on_primary_click_release: () => { Utils.execAsync(`${App.configDir}/scripts/bluetooth.sh --toggle`) .then(out => { bluetooth_enabled.setValue(out) }) }, - on_secondary_click: () => { + on_secondary_click_release: () => { OpenSettings("bluetooth") App.closeWindow(WINDOW_NAME) } @@ -187,7 +187,7 @@ function Page1() { }), Widget.Box({ orientation: Gtk.Orientation.HORIZONTAL, - spacing: 2.5, + spacing: 5, hexpand: true, children: [ Widget.Button({ @@ -225,7 +225,7 @@ function Page1() { }), Widget.Box({ orientation: Gtk.Orientation.HORIZONTAL, - spacing: 2.5, + spacing: 5, hexpand: true, children: [ Widget.Button({ @@ -310,7 +310,7 @@ function Page2() { children: [ Widget.Box({ orientation: Gtk.Orientation.HORIZONTAL, - spacing: 2.5, + spacing: 5, children: [ Widget.Button({ hexpand: true, @@ -320,7 +320,7 @@ function Page2() { icon: "colorize", arrow: true, }), - on_primary_click: () => { + on_clicked: () => { App.closeWindow(WINDOW_NAME); Utils.execAsync("sleep 0.5") .then(() => @@ -369,7 +369,7 @@ function Page2() { }), Widget.Box({ orientation: Gtk.Orientation.HORIZONTAL, - spacing: 2.5, + spacing: 5, hexpand: true, children: [ Widget.Button({ @@ -380,7 +380,7 @@ function Page2() { icon: "settings", arrow: true, }), - on_primary_click: () => { + on_clicked: () => { OpenSettings() App.closeWindow(WINDOW_NAME); } diff --git a/config/ags/modules/sidebar/navigation.ts b/config/ags/modules/sidebar/navigation.ts index 40639efc..1e47670b 100644 --- a/config/ags/modules/sidebar/navigation.ts +++ b/config/ags/modules/sidebar/navigation.ts @@ -3,6 +3,7 @@ import { SystemBox } from "./system.ts" let shown = Variable("Messages"); import Gtk from "gi://Gtk?version=3.0" import { MaterialIcon } from "icons.ts"; +import { enableClickThrough } from "modules/misc/clickthrough.js"; type ButtonType = { @@ -20,11 +21,14 @@ function Button({ page, label, icon }: ButtonType) { orientation: Gtk.Orientation.VERTICAL, class_name: "container_outer", children: [ - Widget.Box({ - orientation: Gtk.Orientation.VERTICAL, - hpack: "center", - class_name: "container", - child: MaterialIcon(icon, "20px"), + Widget.Overlay({ + child: Widget.Box({ + orientation: Gtk.Orientation.VERTICAL, + hpack: "center", + class_name: "container", + }), + overlay: MaterialIcon(icon, "20px"), + pass_through: true }), Widget.Label({ label: label, diff --git a/config/ags/modules/sidebar/notifications.ts b/config/ags/modules/sidebar/notifications.ts index 9677b5e6..0e9461bd 100644 --- a/config/ags/modules/sidebar/notifications.ts +++ b/config/ags/modules/sidebar/notifications.ts @@ -4,7 +4,6 @@ import Box from "types/widgets/box"; const notifications = await Service.import("notifications") - type NotificationsBoxType = { exclude?: string[], include?: string[] @@ -66,7 +65,7 @@ export function NotificationsBox({ exclude = [], include = [] }: NotificationsBo return Widget.EventBox({ vexpand: true, hexpand: true, - on_secondary_click: (_, event) => { + on_secondary_click_release: (_, event) => { menu.popup_at_pointer(event) }, child: Widget.Scrollable({ diff --git a/config/ags/style-apps.css b/config/ags/style-apps.css index 2bbde905..ab129c67 100644 --- a/config/ags/style-apps.css +++ b/config/ags/style-apps.css @@ -41,7 +41,7 @@ background-color: @surfaceContainerLow; } -.settings .sidebar .row { +.settings .sidebar_row { border-radius: 100px; padding: 0px; padding-right: 24px; @@ -50,30 +50,35 @@ background-color: @surfaceContainerLow; } -.settings .sidebar .row:hover { +.settings .sidebar_row:hover { background-color: mix(@onSurface, @surface, 0.92); } -.settings .sidebar .row.active { - background-color: @secondaryContainer; +.settings .sidebar_row:active { + background-image: radial-gradient(circle, mix(@onSurface, @surface, 0.9) 10%, transparent 0%); } -.settings .sidebar .row label { +.settings .sidebar_row.active { + background-color: @secondaryContainer; + background-image: radial-gradient(circle, @secondaryContainer 10%, transparent 0%); +} + +.settings .sidebar_row label { color: @onSurfaceVariant; font-weight: normal; font-size: 16px; } -.settings .sidebar .row.active label { +.settings .sidebar_row.active label { color: @onSecondaryContainer; } -.settings .sidebar .row .icon { +.settings .sidebar_row .icon { margin-right: 12px; color: @onSurfaceVariant; } -.settings .sidebar .row.active image { +.settings .sidebar_row.active image { margin-right: 12px; color: @onSecondaryContainer; } @@ -100,6 +105,17 @@ } .settings .row { + background: transparent; + transition-property: all, border-image, background-size, background-image; + transition-duration: 0.3s, 0.3s, 0.3s, 0.3s; + transition-timing-function: ease-out; + outline: none; + background-image: radial-gradient(circle, transparent 10%, transparent 0%); + background-repeat: no-repeat; + background-position: center; + background-size: 1000% 1000%; + background-color: transparent; + padding-left: 16px; padding-right: 16px; padding-top: 12px; @@ -112,12 +128,15 @@ background-color: mix(@onSurface, @surface, 0.92) } -.settings .row:active { - background-color: mix(@onSurface, @surface, 0.8) +.settings .row:active:not(.focused) { + transition-duration: 0.3s, 0.3s, 0ms, 0ms; + animation: ripple 0.3s ease-out forwards; + background-size: 0% 0%; + background-image: radial-gradient(circle, mix(@onSurface, @surface, 0.9) 10%, transparent 0%); } .settings .row.focused { - background-color: mix(@onSurface, @surface, 0.8) + background-color: mix(@onSurface, @surface, 0.8); } .settings .row .title { diff --git a/config/ags/style.css b/config/ags/style.css index 89e9c548..ca564a55 100644 --- a/config/ags/style.css +++ b/config/ags/style.css @@ -9,8 +9,22 @@ window.bar { font-weight: bold; } -button { +button, box { background: transparent; + transition-property: all, border-image, background-size, background-image; + transition-duration: 0.2s, 0.3s, 0.3s, 0.3s; + transition-timing-function: ease-out; + background-image: radial-gradient(circle, transparent 10%, transparent 0%); + background-repeat: no-repeat; + background-position: center; + background-size: 1000% 1000%; + background-color: transparent; +} + +button:active, box:active { + transition-duration: 0.3s, 0.3s, 0ms, 0ms; + animation: ripple 0.3s ease-out forwards; + background-size: 0% 0%; } highlight { @@ -18,6 +32,7 @@ highlight { } * { + margin: 0px; border: none; outline: none; transition: 0.2s ease-in-out; @@ -135,11 +150,13 @@ separator { .time { color: @onSurface; font-size: 14px; + font-feature-settings: "tnum"; } .date { color: @onSurface; font-size: 10px; + font-feature-settings: "tnum"; } /* ----------------------------------------------------- @@ -293,6 +310,10 @@ window.notification-popups box.notifications { outline: none; } +.application_container:active { + background-image: radial-gradient(circle, mix(@onSurface, @surface, 0.78) 10%, transparent 0%); +} + .application_divider { color: @outline; margin: 0px 0px 0px 0px; @@ -334,35 +355,52 @@ window.notification-popups box.notifications { margin: 11px; } -.entry_container { +.clip_container { border: none; outline: none; border-radius: 0px; min-height: 40px; } -.entry_container label { +.clip_container label { margin-left: 11px; margin-right: 11px; } -.entry_container:hover { +.clip_container:hover { background-color: mix(@onSurface, @surface, 0.92) } -.entry_container:focus { +.clip_container:focus { background-color: mix(@onSurface, @surface, 0.8); border: 0px solid; border: none; outline: none; } -.entry_divider { +.clip_container:active { + background-image: radial-gradient(circle, mix(@onSurface, @surface, 0.78) 10%, transparent 0%); +} + +.clip_container .clip_id { + font-weight: 200; + font-feature-settings: "tnum"; +} + +.clip_container .dot_divider { + font-weight: 900; + font-size: 12px; + min-width: 0px; + margin: 0px; + color: @outlineVariant; +} + +.clip_divider { color: @outline; margin: 0px; } -.entry_label { +.clip_label { color: @onSurface; font-weight: normal; } @@ -540,6 +578,15 @@ window.notification-popups box.notifications { background: @surfaceContainer; border: none; outline: none; + + transition-property: all, border-image, background-size, background-image; + transition-duration: 0.3s, 0.3s, 0.3s, 0.3s; + transition-timing-function: ease-out; + outline: none; + background-image: radial-gradient(circle, transparent 10%, transparent 0%); + background-repeat: no-repeat; + background-position: center; + background-size: 1000% 1000%; } .management_button label { @@ -561,7 +608,15 @@ window.notification-popups box.notifications { } .management_button:hover { - background-color: @surfaceContainerHigh; + background-color: mix(@onSurfaceVariant, @surface, 0.9); +} + +.management_button:active { + transition-duration: 0.3s, 0.3s, 0ms, 0ms; + animation: ripple 0.3s ease-out forwards; + background-size: 0% 0%; + + background-image: radial-gradient(circle, mix(@onSurface, @surface, 0.85) 10%, transparent 0%); } .management_button.active label { @@ -576,6 +631,11 @@ window.notification-popups box.notifications { .management_button.active { background-color: @primary; border: 0px solid; + background-image: radial-gradient(circle, @primary 10%, transparent 0%); +} + +.management_button.active:active { + background-image: radial-gradient(circle, transparent 10%, transparent 0%); } .management_button.waiting label { @@ -645,7 +705,7 @@ window.notification-popups box.notifications { } .system_scale.backlight { - margin-bottom: 29px; + margin-bottom: 25px; } .system_scale.brightness slider { @@ -777,6 +837,13 @@ window.notification-popups box.notifications { border-color: @primary; } +.outline_button:active { + background-image: radial-gradient(circle, mix(@primaryFixed, transparent, 0.7) 10%, transparent 0%); + + /* background-color: mix(@primaryFixed, transparent, 0.9); */ + /* border-color: @primary; */ +} + /* filled tonal */ .filled_tonal_button { background-color: @secondaryContainer; @@ -801,7 +868,8 @@ window.notification-popups box.notifications { } .filled_tonal_button:active { - background-color: mix(@secondaryContainer, @onSecondaryContainer, 0.1); + background-image: radial-gradient(circle, mix(@secondaryContainer, @onSecondaryContainer, 0.1) 10%, transparent 0%); + /* background-color: mix(@secondaryContainer, @onSecondaryContainer, 0.1); */ box-shadow: none; } @@ -826,7 +894,7 @@ window.notification-popups box.notifications { } .standard_icon_button:active { - background-color: mix(@onSurfaceVariant, transparent, 0.7); + background-image: radial-gradient(circle, mix(@onSurfaceVariant, transparent, 0.7) 10%, transparent 0%); } /* standard button */ @@ -851,8 +919,8 @@ window.notification-popups box.notifications { background-color: mix(@onSurfaceVariant, @surface, 0.8); } -.standard_button:active { - background-color: mix(@onSurfaceVariant, @surface, 0.7); +.standard_button:active:not(.disabled) { + background-image: radial-gradient(circle, mix(@onSurfaceVariant, @surface, 0.7) 10%, transparent 0%); } .standard_button.disabled { @@ -888,8 +956,8 @@ window.notification-popups box.notifications { background-color: mix(@onPrimary, @primary, 0.92); } -.filled_button:active { - background-color: mix(@onPrimary, @primary, 0.8); +.filled_button:active:not(.disabled) { + background-image: radial-gradient(circle, mix(@onPrimary, @primary, 0.8) 10%, transparent 0%); } .filled_button.disabled { @@ -923,12 +991,19 @@ filled_button.disabled .awesome_icon, } .navigation_button .container { + transition-property: all, border-image, background-size, background-image; + transition-duration: 0.3s, 0.3s, 0.3s, 0.3s; + transition-timing-function: ease-out; + background-image: radial-gradient(circle, transparent 10%, transparent 0%); + background-repeat: no-repeat; + background-position: center; + background-size: 1000% 1000%; + border-radius: 16px; padding-left: 5px; padding-right: 5px; - min-height: 15px; + min-height: 25px; min-width: 0px; - transition-property: min-width, color, background-color, border-color; } .navigation_button .icon { @@ -950,16 +1025,20 @@ filled_button.disabled .awesome_icon, } .navigation_button:active .container { - background-color: mix(@onSurface, @surfaceContainer, 0.9); + transition-duration: 0.3s, 0.3s, 0ms, 0ms; + animation: ripple 0.3s ease-out forwards; + background-size: 0% 0%; + + background-image: radial-gradient(circle, mix(@onSurface, @surfaceContainer, 0.87) 10%, transparent 0%); min-width: 40px; } .navigation_button.active .container { - background: @secondaryContainer; + background-color: @secondaryContainer; + background-image: radial-gradient(circle, @secondaryContainer 10%, transparent 0%); min-width: 40px; } - /* ----------------------------------------------------- * Switch * ----------------------------------------------------- */ @@ -1112,3 +1191,9 @@ switch:checked:active slider { all: unset; font-family: "Material Symbols Outlined", "Material Symbols Sharp"; } + +@keyframes ripple { + to { + background-size: 1000% 1000%; + } +}