2223babc2b
* Add report dialog to LiveStatus dialog * Mr Worldwide™ * Bug fix bug fix * Copy update * Simplify parsing * Bump api sdk * update dev-env * Update yarn.lock * Bump api sdk * Refactor useActorStatus, add disablement and appeal dialog * Fix types * Guard against chat profile views * Go live (disabled) * Fix types * Update config and gates * Add allowed services * Merge conflicts * Fix gradient handling for nudge * Only show nudge on your own profile * Fix live avi overflow breakage * Add TODO * Feedback * Update nux image --------- Co-authored-by: Samuel Newman <mozzius@protonmail.com>
25 lines
720 B
TypeScript
25 lines
720 B
TypeScript
import {LinearGradient} from 'expo-linear-gradient'
|
|
|
|
import {atoms as a, useTheme, utils, type ViewStyleProp} from '#/alf'
|
|
|
|
/**
|
|
* A gradient overlay using the primary color at low opacity. This component is
|
|
* absolutely positioned and intended to be composed within other components,
|
|
* with optional styling allowed, such as adjusting border radius.
|
|
*/
|
|
export function Gradient({style}: ViewStyleProp) {
|
|
const t = useTheme()
|
|
return (
|
|
<LinearGradient
|
|
colors={[
|
|
utils.alpha(t.palette.primary_500, 0.2),
|
|
utils.alpha(t.palette.primary_500, 0.1),
|
|
]}
|
|
locations={[0, 1]}
|
|
start={{x: 0, y: 0}}
|
|
end={{x: 1, y: 0}}
|
|
style={[a.absolute, a.inset_0, style]}
|
|
/>
|
|
)
|
|
}
|