From 2932ffbf4b1528533b4c5241f97582a0b01bdf83 Mon Sep 17 00:00:00 2001 From: end-4 <97237370+end-4@users.noreply.github.com> Date: Mon, 1 Jan 2024 16:15:05 +0700 Subject: [PATCH] small fixes --- .config/ags/services/waifus.js | 7 ++--- .config/ags/style.css | 30 +++++++++++----------- .config/ags/widgets/bar/system.js | 2 +- .config/ags/widgets/sideleft/apis/waifu.js | 4 +-- 4 files changed, 20 insertions(+), 23 deletions(-) diff --git a/.config/ags/services/waifus.js b/.config/ags/services/waifus.js index f1e167b00..dc15e3ff4 100644 --- a/.config/ags/services/waifus.js +++ b/.config/ags/services/waifus.js @@ -1,9 +1,6 @@ +const { Gdk, Gio, GLib } = imports.gi; import { Utils, Widget } from '../imports.js'; import Service from 'resource:///com/github/Aylur/ags/service.js'; -import Gio from 'gi://Gio'; -import GLib from 'gi://GLib'; -import Soup from 'gi://Soup?version=3.0'; -import { fileExists } from './messages.js'; // Usage from my python waifu fetcher, for reference // Usage: waifu-get.py [OPTION]... [TAG]... @@ -127,7 +124,7 @@ class WaifuService extends Service { signature: imageData?.signature || -1, url: imageData?.url || undefined, source: imageData?.source, - dominant_color: imageData?.dominant_color || '#000000', + dominant_color: imageData?.dominant_color || '#9392A6', is_nsfw: imageData?.is_nsfw || false, width: imageData?.width || 0, height: imageData?.height || 0, diff --git a/.config/ags/style.css b/.config/ags/style.css index fefa3cfee..7a00589c1 100644 --- a/.config/ags/style.css +++ b/.config/ags/style.css @@ -2247,9 +2247,9 @@ tooltip { border-radius: 1.159rem; -gtk-outline-radius: 1.159rem; min-width: 29.659rem; - background-color: #100d10; + background-color: #dae8ed; padding: 0rem 1.023rem; - background: linear-gradient(127deg, rgba(47, 41, 46, 0.7), rgba(47, 41, 46, 0.55) 70.71%), linear-gradient(217deg, rgba(78, 68, 75, 0.7), rgba(78, 68, 75, 0.55) 70.71%), radial-gradient(circle at 0% 100%, #554050 13%, rgba(0, 0, 0, 0) 100%), linear-gradient(336deg, rgba(85, 64, 80, 0.7), rgba(85, 64, 80, 0.55) 70.71%), linear-gradient(#100d10, #100d10); } + background: linear-gradient(127deg, rgba(131, 159, 170, 0.7), rgba(131, 159, 170, 0.55) 70.71%), linear-gradient(217deg, rgba(102, 105, 105, 0.7), rgba(102, 105, 105, 0.55) 70.71%), radial-gradient(circle at 0% 100%, #86776E 13%, rgba(0, 0, 0, 0) 100%), linear-gradient(336deg, rgba(144, 134, 123, 0.7), rgba(144, 134, 123, 0.55) 70.71%), linear-gradient(#dae8ed, #dae8ed); } .osd-music-cover-fallback { transition: 300ms cubic-bezier(0.1, 1, 0, 1); @@ -2257,8 +2257,8 @@ tooltip { -gtk-outline-radius: 0.818rem; min-width: 7.5rem; min-height: 7.5rem; - background-color: rgba(33, 27, 31, 0.31); - color: #dad0d5; } + background-color: rgba(233, 241, 247, 0.3); + color: #0a0b0f; } .osd-music-cover { border-radius: 0.818rem; @@ -2284,13 +2284,13 @@ tooltip { transition: 300ms cubic-bezier(0.1, 1, 0, 1); font-family: 'Gabarito', 'Poppins', 'Lexend', sans-serif; font-size: 1.364rem; - color: #dad0d5; } + color: #0a0b0f; } .osd-music-artists { transition: 300ms cubic-bezier(0.1, 1, 0, 1); font-family: 'Rubik', 'Geist', 'AR One Sans', 'Reddit Sans', 'Inter', 'Roboto', 'Ubuntu', 'Noto Sans', sans-serif; font-size: 0.955rem; - color: rgba(205, 196, 201, 0.9); } + color: rgba(20, 22, 26, 0.9); } .osd-music-pill { transition: 300ms cubic-bezier(0.1, 1, 0, 1); @@ -2299,8 +2299,8 @@ tooltip { font-family: 'Gabarito', 'Poppins', 'Lexend', sans-serif; min-width: 1.833rem; padding: 0.273rem 0.682rem; - background-color: rgba(55, 46, 53, 0.5); - color: #dad0d5; } + background-color: rgba(139, 149, 154, 0.5); + color: #0a0b0f; } .osd-music-controls { transition: 300ms cubic-bezier(0.1, 1, 0, 1); @@ -2309,8 +2309,8 @@ tooltip { font-family: 'Gabarito', 'Poppins', 'Lexend', sans-serif; min-width: 1.833rem; padding: 0.205rem; - background-color: rgba(55, 46, 53, 0.5); - color: #dad0d5; } + background-color: rgba(139, 149, 154, 0.5); + color: #0a0b0f; } .osd-music-controlbtn { transition: 300ms cubic-bezier(0.1, 1, 0, 1); @@ -2321,10 +2321,10 @@ tooltip { .osd-music-controlbtn:hover, .osd-music-controlbtn:focus { - background-color: rgba(96, 87, 93, 0.55); } + background-color: rgba(107, 115, 119, 0.55); } .osd-music-controlbtn:active { - background-color: rgba(111, 102, 108, 0.575); } + background-color: rgba(94, 101, 106, 0.575); } .osd-music-controlbtn-txt { transition: 300ms cubic-bezier(0.1, 1, 0, 1); @@ -2338,15 +2338,15 @@ tooltip { min-width: 0.409rem; min-height: 3.068rem; padding: 0.273rem; - color: #dad0d5; } + color: #0a0b0f; } .osd-music-playstate { transition: 300ms cubic-bezier(0.1, 1, 0, 1); min-height: 3.068rem; min-width: 3.068rem; border-radius: 10rem; - background-color: rgba(55, 46, 53, 0.5); - color: #dad0d5; } + background-color: rgba(139, 149, 154, 0.5); + color: #0a0b0f; } .osd-music-playstate-btn > label { transition: 50ms cubic-bezier(0.05, 0.7, 0.1, 1); diff --git a/.config/ags/widgets/bar/system.js b/.config/ags/widgets/bar/system.js index b2b51ecb4..8c5465339 100644 --- a/.config/ags/widgets/bar/system.js +++ b/.config/ags/widgets/bar/system.js @@ -61,7 +61,7 @@ const UtilButton = ({ name, icon, onClicked }) => Button({ const Utilities = () => Box({ hpack: 'center', - className: 'spacing-h-5', + className: 'spacing-h-5 txt-onSurfaceVariant', children: [ UtilButton({ name: 'Screen snip', icon: 'screenshot_region', onClicked: () => { diff --git a/.config/ags/widgets/sideleft/apis/waifu.js b/.config/ags/widgets/sideleft/apis/waifu.js index e89cb41c7..7d48a98be 100644 --- a/.config/ags/widgets/sideleft/apis/waifu.js +++ b/.config/ags/widgets/sideleft/apis/waifu.js @@ -141,9 +141,9 @@ const WaifuImage = (taglist) => { const showImage = () => { downloadState.shown = 'done'; blockImage.css = `background-image:url('${imagePath}');`; - blockImage.get_children()[0].revealChild = true; + blockImageRevealer.revealChild = true; Utils.timeout(blockImageRevealer.transitionDuration, - () => blockImageRevealer.revealChild = true + () => blockImage.get_children()[0].revealChild = true ); downloadIndicator._hide(downloadIndicator); }