-
Notifications
You must be signed in to change notification settings - Fork 70
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding Filter property to ConversationSelectMenu & ConversationMultiS…
…electMenu
- Loading branch information
Simon Oxtoby
committed
Apr 19, 2020
1 parent
fe9e622
commit ca6e0da
Showing
3 changed files
with
45 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
using System.Collections.Generic; | ||
|
||
namespace SlackNet.Blocks | ||
{ | ||
/// <summary> | ||
/// Provides a way to filter the list of options in a <see cref="ConversationSelectMenu"/> or <see cref="ConversationMultiSelectMenu"/>. | ||
/// </summary> | ||
public class ConversationFilter | ||
{ | ||
/// <summary> | ||
/// Indicates which type of conversations should be included in the list. | ||
/// When this field is provided, any conversations that do not match will be excluded. | ||
/// </summary> | ||
[IgnoreIfEmpty] | ||
public IList<ConversationTypeFilter> Include { get; set; } = new List<ConversationTypeFilter>(); | ||
|
||
/// <summary> | ||
/// Indicates whether to exclude external shared channels from conversation lists. | ||
/// </summary> | ||
public bool ExcludeExternalSharedChannels { get; set; } | ||
|
||
/// <summary> | ||
/// Indicates whether to exclude bot users from conversation lists. | ||
/// </summary> | ||
public bool ExcludeBotUsers { get; set; } | ||
} | ||
|
||
public enum ConversationTypeFilter | ||
{ | ||
Public, | ||
Private, | ||
Mpim, | ||
Im | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters