chore: updated usage of tv scaling, alert text fix (#1587)

Signed-off-by: Lance Chant <13349722+lancechant@users.noreply.github.com>
This commit is contained in:
lance chant
2026-05-22 15:28:03 +02:00
committed by GitHub
parent 5fd8e40c44
commit f1140927a8
53 changed files with 575 additions and 424 deletions

View File

@@ -0,0 +1,40 @@
const {
withAndroidColors,
withAndroidColorsNight,
} = require("expo/config-plugins");
const withAndroidAlertColors = (config) => {
const setColor = (colorsList, name, value) => {
const existingColor = colorsList.find(
(item) => item.$ && item.$.name === name,
);
if (existingColor) {
existingColor._ = value;
} else {
colorsList.push({
$: { name },
_: value,
});
}
};
config = withAndroidColors(config, (config) => {
const colors = config.modResults;
const colorsList = colors.resources.color || [];
setColor(colorsList, "colorPrimary", "#000000");
colors.resources.color = colorsList;
return config;
});
config = withAndroidColorsNight(config, (config) => {
const colors = config.modResults;
const colorsList = colors.resources.color || [];
setColor(colorsList, "colorPrimary", "#FFFFFF");
colors.resources.color = colorsList;
return config;
});
return config;
};
module.exports = withAndroidAlertColors;