forked from bluesky-social/social-app
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* New link card styles * Cleanup of consituent parts, add hover state * Fix gif alt text view * Fix alt text view more * Remove dupe * Update remove button * Remove added margin on gif
- Loading branch information
1 parent
2d88463
commit 4c3c10d
Showing
6 changed files
with
153 additions
and
231 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,26 @@ | ||
import React from 'react' | ||
import {TouchableOpacity} from 'react-native' | ||
import {FontAwesomeIcon} from '@fortawesome/react-native-fontawesome' | ||
import {View} from 'react-native' | ||
import {msg} from '@lingui/macro' | ||
import {useLingui} from '@lingui/react' | ||
|
||
import {s} from 'lib/styles' | ||
import {atoms as a} from '#/alf' | ||
import {Button, ButtonIcon} from '#/components/Button' | ||
import {TimesLarge_Stroke2_Corner0_Rounded as X} from '#/components/icons/Times' | ||
|
||
export function ExternalEmbedRemoveBtn({onRemove}: {onRemove: () => void}) { | ||
const {_} = useLingui() | ||
|
||
return ( | ||
<TouchableOpacity | ||
style={{ | ||
position: 'absolute', | ||
top: 10, | ||
right: 10, | ||
height: 36, | ||
width: 36, | ||
backgroundColor: 'rgba(0, 0, 0, 0.75)', | ||
borderRadius: 18, | ||
alignItems: 'center', | ||
justifyContent: 'center', | ||
zIndex: 1, | ||
}} | ||
onPress={onRemove} | ||
accessibilityRole="button" | ||
accessibilityLabel={_(msg`Remove attachment`)} | ||
accessibilityHint={_(msg`Removes the attachment`)} | ||
onAccessibilityEscape={onRemove}> | ||
<FontAwesomeIcon size={18} icon="xmark" style={s.white} /> | ||
</TouchableOpacity> | ||
<View style={[a.absolute, a.pt_sm, a.pr_sm, {top: 0, right: 0}]}> | ||
<Button | ||
label={_(msg`Remove attachment`)} | ||
onPress={onRemove} | ||
size="small" | ||
variant="solid" | ||
color="secondary" | ||
shape="round"> | ||
<ButtonIcon icon={X} size="sm" /> | ||
</Button> | ||
</View> | ||
) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.