mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-05 06:27:21 +00:00
Turned getter-like extension methods into extension properties (#1157)
This commit is contained in:
1 parent
0375318b1b
commit
f649febf88
286 files changed
+1379
-1109
No files matched your search
@@ -27,7 +27,7 @@ internal static class PlaceholderRoleExtensions
|
||||
|
||||
foreach (var candidate in SLOT_ROLES)
|
||||
{
|
||||
if (!string.Equals(words[0], candidate.CatalogName(), StringComparison.OrdinalIgnoreCase))
|
||||
if (!string.Equals(words[0], candidate.CatalogName, StringComparison.OrdinalIgnoreCase))
|
||||
continue;
|
||||
|
||||
var number = 1;
|
||||
@@ -51,7 +51,7 @@ internal static class PlaceholderRoleExtensions
|
||||
/// Footer, slide number and date are filled as well, but by the presentation as a whole rather
|
||||
/// than by a single slide, so they are no slots of a layout.
|
||||
/// </remarks>
|
||||
public bool IsSlot() => role switch
|
||||
public bool IsSlot => role switch
|
||||
{
|
||||
PlaceholderRole.TITLE => true,
|
||||
PlaceholderRole.SUBTITLE => true,
|
||||
@@ -70,7 +70,7 @@ internal static class PlaceholderRoleExtensions
|
||||
/// A layout offering nothing but a title and some labels has no room for content. Such layouts are
|
||||
/// samples or blank pages, and they are left out of the catalog.
|
||||
/// </remarks>
|
||||
public bool CarriesContent() => role switch
|
||||
public bool CarriesContent => role switch
|
||||
{
|
||||
PlaceholderRole.SUBTITLE => true,
|
||||
PlaceholderRole.TEXT => true,
|
||||
@@ -83,7 +83,7 @@ internal static class PlaceholderRoleExtensions
|
||||
/// <summary>
|
||||
/// How the role is called in the catalog the model reads.
|
||||
/// </summary>
|
||||
public string CatalogName() => role switch
|
||||
public string CatalogName => role switch
|
||||
{
|
||||
PlaceholderRole.TITLE => "title",
|
||||
PlaceholderRole.SUBTITLE => "subtitle",
|
||||
|
||||
Reference in new issue
Block a user