Start writing role to database (#3120)

Scaffolding for guest members in channels

Release notes:
- You can now set channels to "public" which will allow anyone to join
and become a member. In a future release guests joining public channels
will have reduced permissions.
This commit is contained in:
Conrad Irwin
2023-10-17 13:40:58 -06:00
committed by GitHub
41 changed files with 2185 additions and 864 deletions
+22 -1
View File
@@ -1,10 +1,11 @@
import { useTheme } from "../theme"
import { StyleSets, useTheme } from "../theme"
import { background, border, foreground, text } from "./components"
import picker from "./picker"
import { input } from "../component/input"
import contact_finder from "./contact_finder"
import { tab } from "../component/tab"
import { icon_button } from "../component/icon_button"
import { interactive } from "../element/interactive"
export default function channel_modal(): any {
const theme = useTheme()
@@ -27,6 +28,24 @@ export default function channel_modal(): any {
const picker_input = input()
const interactive_text = (styleset: StyleSets) =>
interactive({
base: {
padding: {
left: 8,
top: 8
},
...text(theme.middle, "sans", styleset, "default"),
}, state: {
hovered: {
...text(theme.middle, "sans", styleset, "hovered"),
},
clicked: {
...text(theme.middle, "sans", styleset, "active"),
}
}
})
const member_icon_style = icon_button({
variant: "ghost",
size: "sm",
@@ -88,6 +107,8 @@ export default function channel_modal(): any {
left: BUTTON_OFFSET,
},
},
visibility_toggle: interactive_text("base"),
channel_link: interactive_text("accent"),
picker: {
empty_container: {},
item: {