Skip to content

A local-first personal finance app

Fix mobile autocomplete colors (#2530)

Joel Jeremy Marquez7ee48e4c1d9c
diff --git a/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx
index 1dad100b37..e6efee159a 100644
--- a/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx
+++ b/packages/desktop-client/src/components/autocomplete/AccountAutocomplete.tsx
@@ -177,7 +177,6 @@ export function AccountItem({
const narrowStyle = isNarrowWidth
? {
...styles.mobileMenuItem,
- color: theme.menuItemText,
borderRadius: 0,
borderTop: `1px solid ${theme.pillBorder}`,
}
@@ -211,9 +210,7 @@ export function AccountItem({
className={`${className} ${css([
{
backgroundColor: highlighted
- ? embedded && isNarrowWidth
- ? theme.menuItemBackgroundHover
- : theme.menuAutoCompleteBackgroundHover
+ ? theme.menuAutoCompleteBackgroundHover
: 'transparent',
padding: 4,
paddingLeft: 20,
diff --git a/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx
index 91d542c11d..fc2617b930 100644
--- a/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx
+++ b/packages/desktop-client/src/components/autocomplete/CategoryAutocomplete.tsx
@@ -227,7 +227,6 @@ function SplitTransactionButton({
style,
...props
}: SplitTransactionButtonProps) {
- const { isNarrowWidth } = useResponsive();
return (
<View
// Downshift calls `setTimeout(..., 250)` in the `onMouseMove`
@@ -254,9 +253,7 @@ function SplitTransactionButton({
role="button"
style={{
backgroundColor: highlighted
- ? embedded && isNarrowWidth
- ? theme.menuItemBackgroundHover
- : theme.menuAutoCompleteBackgroundHover
+ ? theme.menuAutoCompleteBackgroundHover
: 'transparent',
borderRadius: embedded ? 4 : 0,
flexShrink: 0,
@@ -312,7 +309,6 @@ export function CategoryItem({
const narrowStyle = isNarrowWidth
? {
...styles.mobileMenuItem,
- color: theme.menuItemText,
borderRadius: 0,
borderTop: `1px solid ${theme.pillBorder}`,
}
@@ -326,9 +322,7 @@ export function CategoryItem({
className={`${className} ${css([
{
backgroundColor: highlighted
- ? embedded && isNarrowWidth
- ? theme.menuItemBackgroundHover
- : theme.menuAutoCompleteBackgroundHover
+ ? theme.menuAutoCompleteBackgroundHover
: 'transparent',
padding: 4,
paddingLeft: 20,
diff --git a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx
index 540125eb7d..5d660aab80 100644
--- a/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx
+++ b/packages/desktop-client/src/components/autocomplete/PayeeAutocomplete.tsx
@@ -427,9 +427,7 @@ export function CreatePayeeButton({
fontWeight: 500,
padding: '6px 9px',
backgroundColor: highlighted
- ? embedded && isNarrowWidth
- ? theme.menuItemBackgroundHover
- : theme.menuAutoCompleteBackgroundHover
+ ? theme.menuAutoCompleteBackgroundHover
: 'transparent',
':active': {
backgroundColor: 'rgba(100, 100, 100, .25)',
@@ -484,7 +482,6 @@ export function PayeeItem({
const narrowStyle = isNarrowWidth
? {
...styles.mobileMenuItem,
- color: theme.menuItemText,
borderRadius: 0,
borderTop: `1px solid ${theme.pillBorder}`,
}
@@ -517,9 +514,7 @@ export function PayeeItem({
className={`${className} ${css([
{
backgroundColor: highlighted
- ? embedded && isNarrowWidth
- ? theme.menuItemBackgroundHover
- : theme.menuAutoCompleteBackgroundHover
+ ? theme.menuAutoCompleteBackgroundHover
: 'transparent',
borderRadius: embedded ? 4 : 0,
padding: 4,
diff --git a/upcoming-release-notes/2530.md b/upcoming-release-notes/2530.md
new file mode 100644
index 0000000000..6871ef77e0
--- /dev/null
+++ b/upcoming-release-notes/2530.md
@@ -0,0 +1,6 @@
+---
+category: Bugfix
+authors: [joel-jeremy]
+---
+
+Fix mobile autocomplete colors.