Skip to content

Commit

Permalink
Merge pull request #50795 from tsa321/fixPaddingBottomTextInput
Browse files Browse the repository at this point in the history
Fix some text inputs are unaligned if there are prefix characters
  • Loading branch information
youssef-lr authored Oct 15, 2024
2 parents 067e20f + 38c5b3b commit 137c6d6
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/components/TextInput/BaseTextInput/index.native.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,7 @@ function BaseTextInput(
!hideFocusedState && isFocused && styles.borderColorFocus,
(!!hasError || !!errorText) && styles.borderColorDanger,
autoGrowHeight && {scrollPaddingTop: typeof maxAutoGrowHeight === 'number' ? 2 * maxAutoGrowHeight : undefined},
isAutoGrowHeightMarkdown && styles.pb2,
]);

const inputPaddingLeft = !!prefixCharacter && StyleUtils.getPaddingLeft(StyleUtils.getCharacterPadding(prefixCharacter) + styles.pl1.paddingLeft);
Expand Down
1 change: 1 addition & 0 deletions src/components/TextInput/BaseTextInput/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,7 @@ function BaseTextInput(
!hideFocusedState && isFocused && styles.borderColorFocus,
(!!hasError || !!errorText) && styles.borderColorDanger,
autoGrowHeight && {scrollPaddingTop: typeof maxAutoGrowHeight === 'number' ? 2 * maxAutoGrowHeight : undefined},
isAutoGrowHeightMarkdown && styles.pb2,
]);
const isMultiline = multiline || autoGrowHeight;

Expand Down
1 change: 0 additions & 1 deletion src/styles/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1181,7 +1181,6 @@ const styles = (theme: ThemeColors) =>
overflow: 'hidden',
borderBottomWidth: 2,
borderColor: theme.border,
paddingBottom: 8,
},

optionRowAmountInput: {
Expand Down

0 comments on commit 137c6d6

Please sign in to comment.