From bfaa6d73f37f251259c521befa9e9ee8ea877560 Mon Sep 17 00:00:00 2001 From: Paul Frazee Date: Tue, 27 Jun 2023 09:52:49 -0500 Subject: Improvements to the alt text behaviors in the composer (#910) * Add an image preview in the alt modal * Composer: add info about alt text and a green checkmark when done * Shrink the alt visual indicator a bit so it doesnt obscure the image * Fix typo * Fix: avoid requiring multiple tabs to save alt text * update react-native-screens * Improve the alt text help tip * Remove redundant hints --------- Co-authored-by: Ansh Nanda --- src/view/com/util/post-embeds/index.tsx | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) (limited to 'src/view/com/util/post-embeds/index.tsx') diff --git a/src/view/com/util/post-embeds/index.tsx b/src/view/com/util/post-embeds/index.tsx index 53ef17318..7f2244b7b 100644 --- a/src/view/com/util/post-embeds/index.tsx +++ b/src/view/com/util/post-embeds/index.tsx @@ -126,7 +126,11 @@ export function PostEmbeds({ onPress={() => openLightbox(0)} onPressIn={() => onPressIn(0)} style={styles.singleImage}> - {alt === '' ? null : ALT} + {alt === '' ? null : ( + + ALT + + )} ) @@ -201,17 +205,18 @@ const styles = StyleSheet.create({ borderRadius: 8, marginTop: 4, }, - alt: { + altContainer: { backgroundColor: 'rgba(0, 0, 0, 0.75)', borderRadius: 6, - color: 'white', - fontSize: 12, - fontWeight: 'bold', - letterSpacing: 1, - paddingHorizontal: 10, + paddingHorizontal: 6, paddingVertical: 3, position: 'absolute', left: 6, bottom: 6, }, + alt: { + color: 'white', + fontSize: 10, + fontWeight: 'bold', + }, }) -- cgit 1.4.1