[Dev file previewer]Add option to set custom max file size and fix styling issue (#23689)

* [Dev file previewer] Add option to set costum max file size and fix style issue
This commit is contained in:
Aaron Junker
2023-02-13 19:57:33 +01:00
committed by GitHub
parent bc4bde8cee
commit 00e10d38c2
6 changed files with 63 additions and 4 deletions

View File

@@ -13,6 +13,7 @@ namespace Microsoft.PowerToys.Settings.UI.Library
public class PowerPreviewProperties
{
public const string DefaultStlThumbnailColor = "#FFC924";
public const int DefaultMonacoMaxFileSize = 50;
private bool enableSvgPreview = true;
@@ -116,6 +117,9 @@ namespace Microsoft.PowerToys.Settings.UI.Library
}
}
[JsonPropertyName("monaco-previewer-max-file-size")]
public IntProperty MonacoPreviewMaxFileSize { get; set; }
private bool enablePdfPreview;
[JsonPropertyName("pdf-previewer-toggle-setting")]
@@ -207,6 +211,7 @@ namespace Microsoft.PowerToys.Settings.UI.Library
public PowerPreviewProperties()
{
StlThumbnailColor = new StringProperty(DefaultStlThumbnailColor);
MonacoPreviewMaxFileSize = new IntProperty(DefaultMonacoMaxFileSize);
}
public override string ToString()