about summary refs log tree commit diff
path: root/src/state/modals
diff options
context:
space:
mode:
authorPaul Frazee <pfrazee@gmail.com>2023-12-10 12:01:34 -0800
committerGitHub <noreply@github.com>2023-12-10 12:01:34 -0800
commit28fa5e4919ccf24073ccc92d88efb7e4b73b0b2b (patch)
treedf35206692d0d1adce2a32a2ba8188fb4ac5ad26 /src/state/modals
parentf5d014d4c7b42213e41f2cbc75d318e6462e6995 (diff)
downloadvoidsky-28fa5e4919ccf24073ccc92d88efb7e4b73b0b2b.tar.zst
Add "Who can reply" controls [WIP] (#1954)
* Add threadgating

* UI improvements

* More ui work

* Remove comment

* Tweak colors

* Add missing keys

* Tweak sizing

* Only show composer option on non-reply

* Flex wrap fix

* Move the threadgate control to the top of the composer
Diffstat (limited to 'src/state/modals')
-rw-r--r--src/state/modals/index.tsx8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/state/modals/index.tsx b/src/state/modals/index.tsx
index bff27f84d..81a220d1b 100644
--- a/src/state/modals/index.tsx
+++ b/src/state/modals/index.tsx
@@ -6,6 +6,7 @@ import {Image as RNImage} from 'react-native-image-crop-picker'
 import {ImageModel} from '#/state/models/media/image'
 import {GalleryModel} from '#/state/models/media/gallery'
 import {useNonReactiveCallback} from '#/lib/hooks/useNonReactiveCallback'
+import {ThreadgateSetting} from '../queries/threadgate'
 
 export interface ConfirmModal {
   name: 'confirm'
@@ -121,6 +122,12 @@ export interface SelfLabelModal {
   onChange: (labels: string[]) => void
 }
 
+export interface ThreadgateModal {
+  name: 'threadgate'
+  settings: ThreadgateSetting[]
+  onChange: (settings: ThreadgateSetting[]) => void
+}
+
 export interface ChangeHandleModal {
   name: 'change-handle'
   onChanged: () => void
@@ -207,6 +214,7 @@ export type Modal =
   | ServerInputModal
   | RepostModal
   | SelfLabelModal
+  | ThreadgateModal
 
   // Bluesky access
   | WaitlistModal