about summary refs log tree commit diff
path: root/src/components/ContextMenu/Backdrop.tsx
diff options
context:
space:
mode:
authorSamuel Newman <mozzius@protonmail.com>2025-03-28 08:43:40 +0200
committerGitHub <noreply@github.com>2025-03-28 08:43:40 +0200
commit55a40c2436b68dea850e54a65c5dd197132c08e4 (patch)
treee6d4d2d45ce5a3475aa4f73556910ff7d818986f /src/components/ContextMenu/Backdrop.tsx
parentac2c2a9a1d2d09442a497dc0dcfd8bc0bf715372 (diff)
downloadvoidsky-55a40c2436b68dea850e54a65c5dd197132c08e4.tar.zst
[DMs] Emoji reaction picker (#8023)
Diffstat (limited to 'src/components/ContextMenu/Backdrop.tsx')
-rw-r--r--src/components/ContextMenu/Backdrop.tsx8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/components/ContextMenu/Backdrop.tsx b/src/components/ContextMenu/Backdrop.tsx
index 857be7c44..027bf9849 100644
--- a/src/components/ContextMenu/Backdrop.tsx
+++ b/src/components/ContextMenu/Backdrop.tsx
@@ -9,6 +9,7 @@ import {msg} from '@lingui/macro'
 import {useLingui} from '@lingui/react'
 
 import {atoms as a, useTheme} from '#/alf'
+import {useContextMenuContext} from './context'
 
 export function Backdrop({
   animation,
@@ -21,12 +22,17 @@ export function Backdrop({
 }) {
   const t = useTheme()
   const {_} = useLingui()
+  const {mode} = useContextMenuContext()
+
+  const reduced = mode === 'auxiliary-only'
+
+  const target = reduced ? 0.05 : intensity / 100
 
   const animatedStyle = useAnimatedStyle(() => ({
     opacity: interpolate(
       animation.get(),
       [0, 1],
-      [0, intensity / 100],
+      [0, target],
       Extrapolation.CLAMP,
     ),
   }))