some vkui improvements

This commit is contained in:
gdlbo
2022-08-01 01:53:50 +03:00
parent 4d0573ffe5
commit 7299c9e33a
2 changed files with 15 additions and 8 deletions
@@ -5,8 +5,10 @@ import static ru.vtosters.lite.utils.AndroidUtils.getGlobalContext;
import static ru.vtosters.lite.utils.AndroidUtils.getPrefsValue;
import static ru.vtosters.lite.utils.Preferences.getBoolValue;
import static ru.vtosters.lite.utils.ThemesUtils.getAccentColor;
import static ru.vtosters.lite.utils.ThemesUtils.getAttrId;
import static ru.vtosters.lite.utils.ThemesUtils.getBackgroundContent;
import static ru.vtosters.lite.utils.ThemesUtils.getBackgroundPage;
import static ru.vtosters.lite.utils.ThemesUtils.getColorFromAttr;
import static ru.vtosters.lite.utils.ThemesUtils.getHeaderBackground;
import static ru.vtosters.lite.utils.ThemesUtils.getHeaderText;
import static ru.vtosters.lite.utils.ThemesUtils.getTextAttr;
@@ -59,8 +61,13 @@ public class VKUIHook {
.replace("%header_text%", hex(getHeaderText()))
.replace("%accent%", hex(getAccentColor()))
.replace("%background_page%", hex(getBackgroundPage()))
.replace("%content_tint_background%", hex(getColorFromAttr(getAttrId("content_tint_background"))))
.replace("%button_primary_background%", hex(getColorFromAttr(getAttrId("button_primary_background"))))
.replace("%button_outline_foreground%", hex(getColorFromAttr(getAttrId("button_outline_foreground"))))
.replace("%button_outline_border%", hex(getColorFromAttr(getAttrId("button_outline_border"))))
.replace("%text_primary%", hex(getTextAttr()));
loadedCSSAmoled = load("vt_ui_oled.css");
isLoaded = true;
}
+8 -8
View File
@@ -11,9 +11,9 @@ body[scheme=bright_light] {
--attach_picker_tab_active_background: %accent% !important;
--attach_picker_tab_active_text: %accent% !important;
--button_muted_foreground: %accent% !important;
--button_outline_border: %accent% !important;
--button_outline_foreground: %accent% !important;
--button_primary_background: %accent% !important;
--button_outline_border: %button_outline_border% !important;
--button_outline_foreground: %button_outline_foreground% !important;
--button_primary_background: %button_primary_background% !important;
--button_secondary_foreground: %accent% !important;
--button_tertiary_foreground: %accent% !important;
--cell_button_foreground: %accent% !important;
@@ -40,7 +40,7 @@ body[scheme=bright_light] {
/* backgrounds */
--background_content: %background_content% !important;
--background_page: %background_page% !important;
--content_tint_background: %background_page% !important;
--content_tint_background: %content_tint_background% !important;
--loader_background: %background_page% !important;
--header_background: %header_background% !important;
--header_background_before_blur: %header_background% !important;
@@ -62,9 +62,9 @@ body[scheme=space_gray] {
--attach_picker_tab_active_background: %accent% !important;
--attach_picker_tab_active_text: %accent% !important;
--button_muted_foreground: %accent% !important;
--button_outline_border: %accent% !important;
--button_outline_foreground: %accent% !important;
--button_primary_background: %accent% !important;
--button_outline_border: %button_outline_border% !important;
--button_outline_foreground: %button_outline_foreground% !important;
--button_primary_background: %button_primary_background% !important;
--button_secondary_foreground: %accent% !important;
--button_tertiary_foreground: %accent% !important;
--cell_button_foreground: %accent% !important;
@@ -90,7 +90,7 @@ body[scheme=space_gray] {
--dynamic_blue: %accent% !important;
--background_content: %background_content% !important;
--background_page: %background_page% !important;
--content_tint_background: %background_page% !important;
--content_tint_background: %content_tint_background% !important;
--loader_background: %background_page% !important;
--header_background: %header_background% !important;
--header_background_before_blur: %header_background% !important;