allow moderators to change group invite state, up version

This commit is contained in:
rootdarkarchon
2022-12-16 21:24:18 +01:00
parent 581e9370aa
commit b5360c58f5
2 changed files with 9 additions and 9 deletions

View File

@@ -3,7 +3,7 @@
<PropertyGroup>
<Authors></Authors>
<Company></Company>
<Version>0.5.12</Version>
<Version>0.5.13</Version>
<Description></Description>
<Copyright></Copyright>
<PackageProjectUrl>https://github.com/Penumbra-Sync/client</PackageProjectUrl>

View File

@@ -483,16 +483,16 @@ namespace MareSynchronos.UI
{
ImGui.Separator();
var changedToIcon = !invitesEnabled ? FontAwesomeIcon.LockOpen : FontAwesomeIcon.Lock;
if (UiShared.IconTextButton(changedToIcon, invitesEnabled ? "Lock Syncshell" : "Unlock Syncshell"))
{
ImGui.CloseCurrentPopup();
_ = _apiController.GroupChangeInviteState(entry.GID, !entry.InvitesEnabled ?? true);
}
UiShared.AttachToolTip("Change Syncshell joining permissions" + Environment.NewLine + "Syncshell is currently " + (invitesEnabled ? "open" : "closed") + " for people to join");
if (isOwner)
{
var changedToIcon = !invitesEnabled ? FontAwesomeIcon.LockOpen : FontAwesomeIcon.Lock;
if (UiShared.IconTextButton(changedToIcon, invitesEnabled ? "Lock Syncshell" : "Unlock Syncshell"))
{
ImGui.CloseCurrentPopup();
_ = _apiController.GroupChangeInviteState(entry.GID, !entry.InvitesEnabled ?? true);
}
UiShared.AttachToolTip("Change Syncshell joining permissions" + Environment.NewLine + "Syncshell is currently " + (invitesEnabled ? "open" : "closed") + " for people to join");
if (UiShared.IconTextButton(FontAwesomeIcon.Passport, "Change Password"))
{
ImGui.CloseCurrentPopup();