From 8896af095da76cf7763d2acb934c4bb29d5dcd62 Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Wed, 17 Jul 2024 12:53:52 -0700 Subject: [PATCH] WIP not working dropdown --- src/components/dialogs/MutedWords.tsx | 79 +++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) diff --git a/src/components/dialogs/MutedWords.tsx b/src/components/dialogs/MutedWords.tsx index 526652be95..fe12002210 100644 --- a/src/components/dialogs/MutedWords.tsx +++ b/src/components/dialogs/MutedWords.tsx @@ -3,7 +3,12 @@ import {Keyboard, View} from 'react-native' import {AppBskyActorDefs, sanitizeMutedWordValue} from '@atproto/api' import {msg, Trans} from '@lingui/macro' import {useLingui} from '@lingui/react' +import RNPickerSelect, {PickerSelectProps} from 'react-native-picker-select' +import { + DropdownItem, + NativeDropdown, +} from '#/view/com/util/forms/NativeDropdown' import {logger} from '#/logger' import {isNative} from '#/platform/detection' import { @@ -28,6 +33,7 @@ import {Hashtag_Stroke2_Corner0_Rounded as Hashtag} from '#/components/icons/Has import {PageText_Stroke2_Corner0_Rounded as PageText} from '#/components/icons/PageText' import {PlusLarge_Stroke2_Corner0_Rounded as Plus} from '#/components/icons/Plus' import {TimesLarge_Stroke2_Corner0_Rounded as X} from '#/components/icons/Times' +import {ChevronBottom_Stroke2_Corner0_Rounded as ChevronDown} from '#/components/icons/Chevron' import {Loader} from '#/components/Loader' import * as Prompt from '#/components/Prompt' import {Text} from '#/components/Typography' @@ -78,6 +84,23 @@ function MutedWordsInner() { } }, [_, field, options, addMutedWord, setField]) + const onDurationChange = React.useCallback( + (value: Parameters[0]) => { + if (!value) return + }, + [], + ) + + const selectStyle = [ + a.border_0, + a.rounded_sm, + a.py_sm, + a.text_md, + a.px_md, + t.atoms.bg_contrast_25, + t.atoms.text_contrast_medium, + ] + return ( @@ -108,6 +131,62 @@ function MutedWordsInner() { onSubmitEditing={submit} /> + + } + /> + +