A Swiss Army knife for developers.
C# blazorcross-platformcsharpdesktopdesktop-appdesktop-applicationdeveloper-toolsextensiblefluentfluent-designlinuxmacosmicasyntax-highlightingtypescriptwindowswindows-10windows-11winui
Added a Markdown Preview tool (#43)
Etienne Baudoux84a28e65c9a4
diff --git a/README.md b/README.mdindex 428303afa..fd1ed28a5 100644--- a/README.md+++ b/README.md@@ -69,6 +69,7 @@ Here is the list of tool name you can use:- `jsonformat` Json Formatter- `jsonyaml` - Json <> Yaml- `jwt` - JWT Decoder+- `markdown` - Markdown Preview- `regex` - Regular Expression Tester- `string` - String Utilities- `diff` - Text Comparerdiff --git a/THIRD-PARTY-NOTICES.md b/THIRD-PARTY-NOTICES.mdindex dd03af9fe..f97092678 100644--- a/THIRD-PARTY-NOTICES.md+++ b/THIRD-PARTY-NOTICES.md@@ -11,6 +11,8 @@ This project incorporates components from the projects listed below. The origina7. Monaco Editor UWP (https://github.com/hawkerm/monaco-editor-uwp)8. Observable Vector (https://github.com/jamesqo/observable-vector)9. Azure Active Directory IdentityModel Extensions for .NET (https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet)+10. Markdig (https://github.com/xoofx/markdig)+11. github-markdown-css (https://github.com/sindresorhus/github-markdown-css)Newtonsoft.Json NOTICES AND INFORMATION BEGIN HERE=========================================@@ -167,7 +169,7 @@ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THESOFTWARE.-Azure Active Directory IdentityModel Extensions for .NET+Azure Active Directory IdentityModel Extensions for .NET NOTICES AND INFORMATION BEGIN HERE=========================================The MIT License (MIT)@@ -190,3 +192,41 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHERLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THESOFTWARE.++Markdig NOTICES AND INFORMATION BEGIN HERE+=========================================+Copyright (c) 2018-2019, Alexandre Mutel+All rights reserved.++Redistribution and use in source and binary forms, with or without modification+, are permitted provided that the following conditions are met:++1. Redistributions of source code must retain the above copyright notice, this+ list of conditions and the following disclaimer.++2. Redistributions in binary form must reproduce the above copyright notice,+ this list of conditions and the following disclaimer in the documentation+ and/or other materials provided with the distribution.++THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND+ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED+WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE+DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE+FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL+DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR+SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER+CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,+OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE+OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.++github-markdown-css NOTICES AND INFORMATION BEGIN HERE+=========================================+MIT License++Copyright (c) Sindre Sorhus <[email protected]> (https://sindresorhus.com)++Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:++The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.++THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.diff --git a/src/Directory.Build.props b/src/Directory.Build.propsindex 55ab9db91..b7146bf61 100644--- a/src/Directory.Build.props+++ b/src/Directory.Build.props@@ -22,6 +22,7 @@<PropertyGroup><Nuget_GitInfo>2.2.0</Nuget_GitInfo>+ <Nuget_Markdig>0.26.0</Nuget_Markdig><NuGet_MicrosoftNETCoreUniversalWindowsPlatform>6.2.12</NuGet_MicrosoftNETCoreUniversalWindowsPlatform><NuGet_MicrosoftToolkitMvvm>7.0.2</NuGet_MicrosoftToolkitMvvm><Nuget_MicrosoftToolkitUwpUI>7.0.2</Nuget_MicrosoftToolkitUwpUI>diff --git a/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-dark.css b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-dark.cssnew file mode 100644index 000000000..28358e96d--- /dev/null+++ b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-dark.css@@ -0,0 +1,900 @@+.markdown-body {+ color-scheme: dark;+ -ms-text-size-adjust: 100%;+ -webkit-text-size-adjust: 100%;+ margin: 0;+ color: #c9d1d9;+ background-color: #0d1117;+ font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";+ font-size: 16px;+ line-height: 1.5;+ word-wrap: break-word;+}++ .markdown-body .octicon {+ display: inline-block;+ fill: currentColor;+ vertical-align: text-bottom;+ }++ .markdown-body h1:hover .anchor .octicon-link:before,+ .markdown-body h2:hover .anchor .octicon-link:before,+ .markdown-body h3:hover .anchor .octicon-link:before,+ .markdown-body h4:hover .anchor .octicon-link:before,+ .markdown-body h5:hover .anchor .octicon-link:before,+ .markdown-body h6:hover .anchor .octicon-link:before {+ width: 16px;+ height: 16px;+ content: ' ';+ display: inline-block;+ background-color: currentColor;+ -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ }++ .markdown-body details,+ .markdown-body figcaption,+ .markdown-body figure {+ display: block;+ }++ .markdown-body summary {+ display: list-item;+ }++ .markdown-body a {+ background-color: transparent;+ color: #58a6ff;+ text-decoration: none;+ }++ .markdown-body a:active,+ .markdown-body a:hover {+ outline-width: 0;+ }++ .markdown-body abbr[title] {+ border-bottom: none;+ -webkit-text-decoration: underline dotted;+ text-decoration: underline dotted;+ }++ .markdown-body b,+ .markdown-body strong {+ font-weight: 600;+ }++ .markdown-body dfn {+ font-style: italic;+ }++ .markdown-body h1 {+ margin: .67em 0;+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 2em;+ border-bottom: 1px solid #21262d;+ }++ .markdown-body mark {+ background-color: #ff0;+ color: #c9d1d9;+ }++ .markdown-body small {+ font-size: 90%;+ }++ .markdown-body sub,+ .markdown-body sup {+ font-size: 75%;+ line-height: 0;+ position: relative;+ vertical-align: baseline;+ }++ .markdown-body sub {+ bottom: -0.25em;+ }++ .markdown-body sup {+ top: -0.5em;+ }++ .markdown-body img {+ border-style: none;+ max-width: 100%;+ box-sizing: content-box;+ background-color: #0d1117;+ }++ .markdown-body code,+ .markdown-body kbd,+ .markdown-body pre,+ .markdown-body samp {+ font-family: monospace,monospace;+ font-size: 1em;+ }++ .markdown-body figure {+ margin: 1em 40px;+ }++ .markdown-body hr {+ box-sizing: content-box;+ overflow: hidden;+ background: transparent;+ border-bottom: 1px solid #21262d;+ height: .25em;+ padding: 0;+ margin: 24px 0;+ background-color: #30363d;+ border: 0;+ }++ .markdown-body html [type=button],+ .markdown-body [type=reset],+ .markdown-body [type=submit] {+ -webkit-appearance: button;+ }++ .markdown-body [type=button]::-moz-focus-inner,+ .markdown-body [type=reset]::-moz-focus-inner,+ .markdown-body [type=submit]::-moz-focus-inner {+ border-style: none;+ padding: 0;+ }++ .markdown-body [type=button]:-moz-focusring,+ .markdown-body [type=reset]:-moz-focusring,+ .markdown-body [type=submit]:-moz-focusring {+ outline: 1px dotted ButtonText;+ }++ .markdown-body [type=checkbox],+ .markdown-body [type=radio] {+ box-sizing: border-box;+ padding: 0;+ }++ .markdown-body [type=number]::-webkit-inner-spin-button,+ .markdown-body [type=number]::-webkit-outer-spin-button {+ height: auto;+ }++ .markdown-body [type=search] {+ -webkit-appearance: textfield;+ outline-offset: -2px;+ }++ .markdown-body [type=search]::-webkit-search-cancel-button,+ .markdown-body [type=search]::-webkit-search-decoration {+ -webkit-appearance: none;+ }++ .markdown-body ::-webkit-input-placeholder {+ color: inherit;+ opacity: .54;+ }++ .markdown-body ::-webkit-file-upload-button {+ -webkit-appearance: button;+ font: inherit;+ }++ .markdown-body a:hover {+ text-decoration: underline;+ }++ .markdown-body hr::before {+ display: table;+ content: "";+ }++ .markdown-body hr::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body table {+ border-spacing: 0;+ border-collapse: collapse;+ display: block;+ width: max-content;+ max-width: 100%;+ overflow: auto;+ }++ .markdown-body td,+ .markdown-body th {+ padding: 0;+ }++ .markdown-body details summary {+ cursor: pointer;+ }++ .markdown-body details:not([open]) > *:not(summary) {+ display: none !important;+ }++ .markdown-body kbd {+ display: inline-block;+ padding: 3px 5px;+ font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ line-height: 10px;+ color: #c9d1d9;+ vertical-align: middle;+ background-color: #161b22;+ border: solid 1px rgba(110,118,129,0.4);+ border-bottom-color: rgba(110,118,129,0.4);+ border-radius: 6px;+ box-shadow: inset 0 -1px 0 rgba(110,118,129,0.4);+ }++ .markdown-body h1,+ .markdown-body h2,+ .markdown-body h3,+ .markdown-body h4,+ .markdown-body h5,+ .markdown-body h6 {+ margin-top: 24px;+ margin-bottom: 16px;+ font-weight: 600;+ line-height: 1.25;+ }++ .markdown-body h2 {+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 1.5em;+ border-bottom: 1px solid #21262d;+ }++ .markdown-body h3 {+ font-weight: 600;+ font-size: 1.25em;+ }++ .markdown-body h4 {+ font-weight: 600;+ font-size: 1em;+ }++ .markdown-body h5 {+ font-weight: 600;+ font-size: .875em;+ }++ .markdown-body h6 {+ font-weight: 600;+ font-size: .85em;+ color: #8b949e;+ }++ .markdown-body p {+ margin-top: 0;+ margin-bottom: 10px;+ }++ .markdown-body blockquote {+ margin: 0;+ padding: 0 1em;+ color: #8b949e;+ border-left: .25em solid #30363d;+ }++ .markdown-body ul,+ .markdown-body ol {+ margin-top: 0;+ margin-bottom: 0;+ padding-left: 2em;+ }++ .markdown-body ol ol,+ .markdown-body ul ol {+ list-style-type: lower-roman;+ }++ .markdown-body ul ul ol,+ .markdown-body ul ol ol,+ .markdown-body ol ul ol,+ .markdown-body ol ol ol {+ list-style-type: lower-alpha;+ }++ .markdown-body dd {+ margin-left: 0;+ }++ .markdown-body tt,+ .markdown-body code {+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ }++ .markdown-body pre {+ margin-top: 0;+ margin-bottom: 0;+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ word-wrap: normal;+ }++ .markdown-body :-ms-input-placeholder {+ color: #484f58;+ opacity: 1;+ }++ .markdown-body ::-ms-input-placeholder {+ color: #484f58;+ opacity: 1;+ }++ .markdown-body ::placeholder {+ color: #484f58;+ opacity: 1;+ }++ .markdown-body .pl-c {+ color: #8b949e;+ }++ .markdown-body .pl-c1,+ .markdown-body .pl-s .pl-v {+ color: #79c0ff;+ }++ .markdown-body .pl-e,+ .markdown-body .pl-en {+ color: #d2a8ff;+ }++ .markdown-body .pl-smi,+ .markdown-body .pl-s .pl-s1 {+ color: #c9d1d9;+ }++ .markdown-body .pl-ent {+ color: #7ee787;+ }++ .markdown-body .pl-k {+ color: #ff7b72;+ }++ .markdown-body .pl-s,+ .markdown-body .pl-pds,+ .markdown-body .pl-s .pl-pse .pl-s1,+ .markdown-body .pl-sr,+ .markdown-body .pl-sr .pl-cce,+ .markdown-body .pl-sr .pl-sre,+ .markdown-body .pl-sr .pl-sra {+ color: #a5d6ff;+ }++ .markdown-body .pl-v,+ .markdown-body .pl-smw {+ color: #ffa657;+ }++ .markdown-body .pl-bu {+ color: #f85149;+ }++ .markdown-body .pl-ii {+ color: #f0f6fc;+ background-color: #8e1519;+ }++ .markdown-body .pl-c2 {+ color: #f0f6fc;+ background-color: #b62324;+ }++ .markdown-body .pl-sr .pl-cce {+ font-weight: bold;+ color: #7ee787;+ }++ .markdown-body .pl-ml {+ color: #f2cc60;+ }++ .markdown-body .pl-mh,+ .markdown-body .pl-mh .pl-en,+ .markdown-body .pl-ms {+ font-weight: bold;+ color: #1f6feb;+ }++ .markdown-body .pl-mi {+ font-style: italic;+ color: #c9d1d9;+ }++ .markdown-body .pl-mb {+ font-weight: bold;+ color: #c9d1d9;+ }++ .markdown-body .pl-md {+ color: #ffdcd7;+ background-color: #67060c;+ }++ .markdown-body .pl-mi1 {+ color: #aff5b4;+ background-color: #033a16;+ }++ .markdown-body .pl-mc {+ color: #ffdfb6;+ background-color: #5a1e02;+ }++ .markdown-body .pl-mi2 {+ color: #c9d1d9;+ background-color: #1158c7;+ }++ .markdown-body .pl-mdr {+ font-weight: bold;+ color: #d2a8ff;+ }++ .markdown-body .pl-ba {+ color: #8b949e;+ }++ .markdown-body .pl-sg {+ color: #484f58;+ }++ .markdown-body .pl-corl {+ text-decoration: underline;+ color: #a5d6ff;+ }++ .markdown-body [data-catalyst] {+ display: block;+ }++ .markdown-body g-emoji {+ font-family: "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";+ font-size: 1em;+ font-style: normal !important;+ font-weight: 400;+ line-height: 1;+ vertical-align: -0.075em;+ }++ .markdown-body g-emoji img {+ width: 1em;+ height: 1em;+ }++ .markdown-body::before {+ display: table;+ content: "";+ }++ .markdown-body::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body > *:first-child {+ margin-top: 0 !important;+ }++ .markdown-body > *:last-child {+ margin-bottom: 0 !important;+ }++ .markdown-body a:not([href]) {+ color: inherit;+ text-decoration: none;+ }++ .markdown-body .absent {+ color: #f85149;+ }++ .markdown-body .anchor {+ float: left;+ padding-right: 4px;+ margin-left: -20px;+ line-height: 1;+ }++ .markdown-body .anchor:focus {+ outline: none;+ }++ .markdown-body p,+ .markdown-body blockquote,+ .markdown-body ul,+ .markdown-body ol,+ .markdown-body dl,+ .markdown-body table,+ .markdown-body pre,+ .markdown-body details {+ margin-top: 0;+ margin-bottom: 16px;+ }++ .markdown-body blockquote > :first-child {+ margin-top: 0;+ }++ .markdown-body blockquote > :last-child {+ margin-bottom: 0;+ }++ .markdown-body sup > a::before {+ content: "[";+ }++ .markdown-body sup > a::after {+ content: "]";+ }++ .markdown-body h1 .octicon-link,+ .markdown-body h2 .octicon-link,+ .markdown-body h3 .octicon-link,+ .markdown-body h4 .octicon-link,+ .markdown-body h5 .octicon-link,+ .markdown-body h6 .octicon-link {+ color: #c9d1d9;+ vertical-align: middle;+ visibility: hidden;+ }++ .markdown-body h1:hover .anchor,+ .markdown-body h2:hover .anchor,+ .markdown-body h3:hover .anchor,+ .markdown-body h4:hover .anchor,+ .markdown-body h5:hover .anchor,+ .markdown-body h6:hover .anchor {+ text-decoration: none;+ }++ .markdown-body h1:hover .anchor .octicon-link,+ .markdown-body h2:hover .anchor .octicon-link,+ .markdown-body h3:hover .anchor .octicon-link,+ .markdown-body h4:hover .anchor .octicon-link,+ .markdown-body h5:hover .anchor .octicon-link,+ .markdown-body h6:hover .anchor .octicon-link {+ visibility: visible;+ }++ .markdown-body h1 tt,+ .markdown-body h1 code,+ .markdown-body h2 tt,+ .markdown-body h2 code,+ .markdown-body h3 tt,+ .markdown-body h3 code,+ .markdown-body h4 tt,+ .markdown-body h4 code,+ .markdown-body h5 tt,+ .markdown-body h5 code,+ .markdown-body h6 tt,+ .markdown-body h6 code {+ padding: 0 .2em;+ font-size: inherit;+ }++ .markdown-body ul.no-list,+ .markdown-body ol.no-list {+ padding: 0;+ list-style-type: none;+ }++ .markdown-body ol[type="1"] {+ list-style-type: decimal;+ }++ .markdown-body ol[type=a] {+ list-style-type: lower-alpha;+ }++ .markdown-body ol[type=i] {+ list-style-type: lower-roman;+ }++ .markdown-body div > ol:not([type]) {+ list-style-type: decimal;+ }++ .markdown-body ul ul,+ .markdown-body ul ol,+ .markdown-body ol ol,+ .markdown-body ol ul {+ margin-top: 0;+ margin-bottom: 0;+ }++ .markdown-body li > p {+ margin-top: 16px;+ }++ .markdown-body li + li {+ margin-top: .25em;+ }++ .markdown-body dl {+ padding: 0;+ }++ .markdown-body dl dt {+ padding: 0;+ margin-top: 16px;+ font-size: 1em;+ font-style: italic;+ font-weight: 600;+ }++ .markdown-body dl dd {+ padding: 0 16px;+ margin-bottom: 16px;+ }++ .markdown-body table th {+ font-weight: 600;+ }++ .markdown-body table th,+ .markdown-body table td {+ padding: 6px 13px;+ border: 1px solid #30363d;+ }++ .markdown-body table tr {+ background-color: #0d1117;+ border-top: 1px solid #21262d;+ }++ .markdown-body table tr:nth-child(2n) {+ background-color: #161b22;+ }++ .markdown-body table img {+ background-color: transparent;+ }++ .markdown-body img[align=right] {+ padding-left: 20px;+ }++ .markdown-body img[align=left] {+ padding-right: 20px;+ }++ .markdown-body .emoji {+ max-width: none;+ vertical-align: text-top;+ background-color: transparent;+ }++ .markdown-body span.frame {+ display: block;+ overflow: hidden;+ }++ .markdown-body span.frame > span {+ display: block;+ float: left;+ width: auto;+ padding: 7px;+ margin: 13px 0 0;+ overflow: hidden;+ border: 1px solid #30363d;+ }++ .markdown-body span.frame span img {+ display: block;+ float: left;+ }++ .markdown-body span.frame span span {+ display: block;+ padding: 5px 0 0;+ clear: both;+ color: #c9d1d9;+ }++ .markdown-body span.align-center {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-center > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: center;+ }++ .markdown-body span.align-center span img {+ margin: 0 auto;+ text-align: center;+ }++ .markdown-body span.align-right {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-right > span {+ display: block;+ margin: 13px 0 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body span.align-right span img {+ margin: 0;+ text-align: right;+ }++ .markdown-body span.float-left {+ display: block;+ float: left;+ margin-right: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-left span {+ margin: 13px 0 0;+ }++ .markdown-body span.float-right {+ display: block;+ float: right;+ margin-left: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-right > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body code,+ .markdown-body tt {+ padding: .2em .4em;+ margin: 0;+ font-size: 85%;+ background-color: rgba(110,118,129,0.4);+ border-radius: 6px;+ }++ .markdown-body code br,+ .markdown-body tt br {+ display: none;+ }++ .markdown-body del code {+ text-decoration: inherit;+ }++ .markdown-body pre code {+ font-size: 100%;+ }++ .markdown-body pre > code {+ padding: 0;+ margin: 0;+ word-break: normal;+ white-space: pre;+ background: transparent;+ border: 0;+ }++ .markdown-body .highlight {+ margin-bottom: 16px;+ }++ .markdown-body .highlight pre {+ margin-bottom: 0;+ word-break: normal;+ }++ .markdown-body .highlight pre,+ .markdown-body pre {+ padding: 16px;+ overflow: auto;+ font-size: 85%;+ line-height: 1.45;+ background-color: #161b22;+ border-radius: 6px;+ }++ .markdown-body pre code,+ .markdown-body pre tt {+ display: inline;+ max-width: auto;+ padding: 0;+ margin: 0;+ overflow: visible;+ line-height: inherit;+ word-wrap: normal;+ background-color: transparent;+ border: 0;+ }++ .markdown-body .csv-data td,+ .markdown-body .csv-data th {+ padding: 5px;+ overflow: hidden;+ font-size: 12px;+ line-height: 1;+ text-align: left;+ white-space: nowrap;+ }++ .markdown-body .csv-data .blob-num {+ padding: 10px 8px 9px;+ text-align: right;+ background: #0d1117;+ border: 0;+ }++ .markdown-body .csv-data tr {+ border-top: 0;+ }++ .markdown-body .csv-data th {+ font-weight: 600;+ background: #161b22;+ border-top: 0;+ }++ .markdown-body .footnotes {+ font-size: 12px;+ color: #8b949e;+ border-top: 1px solid #30363d;+ }++ .markdown-body .footnotes ol {+ padding-left: 16px;+ }++ .markdown-body .footnotes li {+ position: relative;+ }++ .markdown-body .footnotes li:target::before {+ position: absolute;+ top: -8px;+ right: -8px;+ bottom: -8px;+ left: -24px;+ pointer-events: none;+ content: "";+ border: 2px solid #1f6feb;+ border-radius: 6px;+ }++ .markdown-body .footnotes li:target {+ color: #c9d1d9;+ }++ .markdown-body .footnotes .data-footnote-backref g-emoji {+ font-family: monospace;+ }++ .markdown-body [hidden] {+ display: none !important;+ }++ .markdown-body ::-webkit-calendar-picker-indicator {+ filter: invert(50%);+ }diff --git a/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-light.css b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-light.cssnew file mode 100644index 000000000..adce66f47--- /dev/null+++ b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown-light.css@@ -0,0 +1,899 @@+.markdown-body {+ -ms-text-size-adjust: 100%;+ -webkit-text-size-adjust: 100%;+ margin: 0;+ color: #24292f;+ background-color: #ffffff;+ font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";+ font-size: 16px;+ line-height: 1.5;+ word-wrap: break-word;+}++ .markdown-body .octicon {+ display: inline-block;+ fill: currentColor;+ vertical-align: text-bottom;+ }++ .markdown-body h1:hover .anchor .octicon-link:before,+ .markdown-body h2:hover .anchor .octicon-link:before,+ .markdown-body h3:hover .anchor .octicon-link:before,+ .markdown-body h4:hover .anchor .octicon-link:before,+ .markdown-body h5:hover .anchor .octicon-link:before,+ .markdown-body h6:hover .anchor .octicon-link:before {+ width: 16px;+ height: 16px;+ content: ' ';+ display: inline-block;+ background-color: currentColor;+ -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ }++ .markdown-body details,+ .markdown-body figcaption,+ .markdown-body figure {+ display: block;+ }++ .markdown-body summary {+ display: list-item;+ }++ .markdown-body a {+ background-color: transparent;+ color: #0969da;+ text-decoration: none;+ }++ .markdown-body a:active,+ .markdown-body a:hover {+ outline-width: 0;+ }++ .markdown-body abbr[title] {+ border-bottom: none;+ -webkit-text-decoration: underline dotted;+ text-decoration: underline dotted;+ }++ .markdown-body b,+ .markdown-body strong {+ font-weight: 600;+ }++ .markdown-body dfn {+ font-style: italic;+ }++ .markdown-body h1 {+ margin: .67em 0;+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 2em;+ border-bottom: 1px solid hsla(210,18%,87%,1);+ }++ .markdown-body mark {+ background-color: #ff0;+ color: #24292f;+ }++ .markdown-body small {+ font-size: 90%;+ }++ .markdown-body sub,+ .markdown-body sup {+ font-size: 75%;+ line-height: 0;+ position: relative;+ vertical-align: baseline;+ }++ .markdown-body sub {+ bottom: -0.25em;+ }++ .markdown-body sup {+ top: -0.5em;+ }++ .markdown-body img {+ border-style: none;+ max-width: 100%;+ box-sizing: content-box;+ background-color: #ffffff;+ }++ .markdown-body code,+ .markdown-body kbd,+ .markdown-body pre,+ .markdown-body samp {+ font-family: monospace,monospace;+ font-size: 1em;+ }++ .markdown-body figure {+ margin: 1em 40px;+ }++ .markdown-body hr {+ box-sizing: content-box;+ overflow: hidden;+ background: transparent;+ border-bottom: 1px solid hsla(210,18%,87%,1);+ height: .25em;+ padding: 0;+ margin: 24px 0;+ background-color: #d0d7de;+ border: 0;+ }++ .markdown-body html [type=button],+ .markdown-body [type=reset],+ .markdown-body [type=submit] {+ -webkit-appearance: button;+ }++ .markdown-body [type=button]::-moz-focus-inner,+ .markdown-body [type=reset]::-moz-focus-inner,+ .markdown-body [type=submit]::-moz-focus-inner {+ border-style: none;+ padding: 0;+ }++ .markdown-body [type=button]:-moz-focusring,+ .markdown-body [type=reset]:-moz-focusring,+ .markdown-body [type=submit]:-moz-focusring {+ outline: 1px dotted ButtonText;+ }++ .markdown-body [type=checkbox],+ .markdown-body [type=radio] {+ box-sizing: border-box;+ padding: 0;+ }++ .markdown-body [type=number]::-webkit-inner-spin-button,+ .markdown-body [type=number]::-webkit-outer-spin-button {+ height: auto;+ }++ .markdown-body [type=search] {+ -webkit-appearance: textfield;+ outline-offset: -2px;+ }++ .markdown-body [type=search]::-webkit-search-cancel-button,+ .markdown-body [type=search]::-webkit-search-decoration {+ -webkit-appearance: none;+ }++ .markdown-body ::-webkit-input-placeholder {+ color: inherit;+ opacity: .54;+ }++ .markdown-body ::-webkit-file-upload-button {+ -webkit-appearance: button;+ font: inherit;+ }++ .markdown-body a:hover {+ text-decoration: underline;+ }++ .markdown-body hr::before {+ display: table;+ content: "";+ }++ .markdown-body hr::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body table {+ border-spacing: 0;+ border-collapse: collapse;+ display: block;+ width: max-content;+ max-width: 100%;+ overflow: auto;+ }++ .markdown-body td,+ .markdown-body th {+ padding: 0;+ }++ .markdown-body details summary {+ cursor: pointer;+ }++ .markdown-body details:not([open]) > *:not(summary) {+ display: none !important;+ }++ .markdown-body kbd {+ display: inline-block;+ padding: 3px 5px;+ font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ line-height: 10px;+ color: #24292f;+ vertical-align: middle;+ background-color: #f6f8fa;+ border: solid 1px rgba(175,184,193,0.2);+ border-bottom-color: rgba(175,184,193,0.2);+ border-radius: 6px;+ box-shadow: inset 0 -1px 0 rgba(175,184,193,0.2);+ }++ .markdown-body h1,+ .markdown-body h2,+ .markdown-body h3,+ .markdown-body h4,+ .markdown-body h5,+ .markdown-body h6 {+ margin-top: 24px;+ margin-bottom: 16px;+ font-weight: 600;+ line-height: 1.25;+ }++ .markdown-body h2 {+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 1.5em;+ border-bottom: 1px solid hsla(210,18%,87%,1);+ }++ .markdown-body h3 {+ font-weight: 600;+ font-size: 1.25em;+ }++ .markdown-body h4 {+ font-weight: 600;+ font-size: 1em;+ }++ .markdown-body h5 {+ font-weight: 600;+ font-size: .875em;+ }++ .markdown-body h6 {+ font-weight: 600;+ font-size: .85em;+ color: #57606a;+ }++ .markdown-body p {+ margin-top: 0;+ margin-bottom: 10px;+ }++ .markdown-body blockquote {+ margin: 0;+ padding: 0 1em;+ color: #57606a;+ border-left: .25em solid #d0d7de;+ }++ .markdown-body ul,+ .markdown-body ol {+ margin-top: 0;+ margin-bottom: 0;+ padding-left: 2em;+ }++ .markdown-body ol ol,+ .markdown-body ul ol {+ list-style-type: lower-roman;+ }++ .markdown-body ul ul ol,+ .markdown-body ul ol ol,+ .markdown-body ol ul ol,+ .markdown-body ol ol ol {+ list-style-type: lower-alpha;+ }++ .markdown-body dd {+ margin-left: 0;+ }++ .markdown-body tt,+ .markdown-body code {+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ }++ .markdown-body pre {+ margin-top: 0;+ margin-bottom: 0;+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ word-wrap: normal;+ }++ .markdown-body :-ms-input-placeholder {+ color: #6e7781;+ opacity: 1;+ }++ .markdown-body ::-ms-input-placeholder {+ color: #6e7781;+ opacity: 1;+ }++ .markdown-body ::placeholder {+ color: #6e7781;+ opacity: 1;+ }++ .markdown-body .pl-c {+ color: #6e7781;+ }++ .markdown-body .pl-c1,+ .markdown-body .pl-s .pl-v {+ color: #0550ae;+ }++ .markdown-body .pl-e,+ .markdown-body .pl-en {+ color: #8250df;+ }++ .markdown-body .pl-smi,+ .markdown-body .pl-s .pl-s1 {+ color: #24292f;+ }++ .markdown-body .pl-ent {+ color: #116329;+ }++ .markdown-body .pl-k {+ color: #cf222e;+ }++ .markdown-body .pl-s,+ .markdown-body .pl-pds,+ .markdown-body .pl-s .pl-pse .pl-s1,+ .markdown-body .pl-sr,+ .markdown-body .pl-sr .pl-cce,+ .markdown-body .pl-sr .pl-sre,+ .markdown-body .pl-sr .pl-sra {+ color: #0a3069;+ }++ .markdown-body .pl-v,+ .markdown-body .pl-smw {+ color: #953800;+ }++ .markdown-body .pl-bu {+ color: #82071e;+ }++ .markdown-body .pl-ii {+ color: #f6f8fa;+ background-color: #82071e;+ }++ .markdown-body .pl-c2 {+ color: #f6f8fa;+ background-color: #cf222e;+ }++ .markdown-body .pl-sr .pl-cce {+ font-weight: bold;+ color: #116329;+ }++ .markdown-body .pl-ml {+ color: #3b2300;+ }++ .markdown-body .pl-mh,+ .markdown-body .pl-mh .pl-en,+ .markdown-body .pl-ms {+ font-weight: bold;+ color: #0550ae;+ }++ .markdown-body .pl-mi {+ font-style: italic;+ color: #24292f;+ }++ .markdown-body .pl-mb {+ font-weight: bold;+ color: #24292f;+ }++ .markdown-body .pl-md {+ color: #82071e;+ background-color: #FFEBE9;+ }++ .markdown-body .pl-mi1 {+ color: #116329;+ background-color: #dafbe1;+ }++ .markdown-body .pl-mc {+ color: #953800;+ background-color: #ffd8b5;+ }++ .markdown-body .pl-mi2 {+ color: #eaeef2;+ background-color: #0550ae;+ }++ .markdown-body .pl-mdr {+ font-weight: bold;+ color: #8250df;+ }++ .markdown-body .pl-ba {+ color: #57606a;+ }++ .markdown-body .pl-sg {+ color: #8c959f;+ }++ .markdown-body .pl-corl {+ text-decoration: underline;+ color: #0a3069;+ }++ .markdown-body [data-catalyst] {+ display: block;+ }++ .markdown-body g-emoji {+ font-family: "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";+ font-size: 1em;+ font-style: normal !important;+ font-weight: 400;+ line-height: 1;+ vertical-align: -0.075em;+ }++ .markdown-body g-emoji img {+ width: 1em;+ height: 1em;+ }++ .markdown-body::before {+ display: table;+ content: "";+ }++ .markdown-body::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body > *:first-child {+ margin-top: 0 !important;+ }++ .markdown-body > *:last-child {+ margin-bottom: 0 !important;+ }++ .markdown-body a:not([href]) {+ color: inherit;+ text-decoration: none;+ }++ .markdown-body .absent {+ color: #cf222e;+ }++ .markdown-body .anchor {+ float: left;+ padding-right: 4px;+ margin-left: -20px;+ line-height: 1;+ }++ .markdown-body .anchor:focus {+ outline: none;+ }++ .markdown-body p,+ .markdown-body blockquote,+ .markdown-body ul,+ .markdown-body ol,+ .markdown-body dl,+ .markdown-body table,+ .markdown-body pre,+ .markdown-body details {+ margin-top: 0;+ margin-bottom: 16px;+ }++ .markdown-body blockquote > :first-child {+ margin-top: 0;+ }++ .markdown-body blockquote > :last-child {+ margin-bottom: 0;+ }++ .markdown-body sup > a::before {+ content: "[";+ }++ .markdown-body sup > a::after {+ content: "]";+ }++ .markdown-body h1 .octicon-link,+ .markdown-body h2 .octicon-link,+ .markdown-body h3 .octicon-link,+ .markdown-body h4 .octicon-link,+ .markdown-body h5 .octicon-link,+ .markdown-body h6 .octicon-link {+ color: #24292f;+ vertical-align: middle;+ visibility: hidden;+ }++ .markdown-body h1:hover .anchor,+ .markdown-body h2:hover .anchor,+ .markdown-body h3:hover .anchor,+ .markdown-body h4:hover .anchor,+ .markdown-body h5:hover .anchor,+ .markdown-body h6:hover .anchor {+ text-decoration: none;+ }++ .markdown-body h1:hover .anchor .octicon-link,+ .markdown-body h2:hover .anchor .octicon-link,+ .markdown-body h3:hover .anchor .octicon-link,+ .markdown-body h4:hover .anchor .octicon-link,+ .markdown-body h5:hover .anchor .octicon-link,+ .markdown-body h6:hover .anchor .octicon-link {+ visibility: visible;+ }++ .markdown-body h1 tt,+ .markdown-body h1 code,+ .markdown-body h2 tt,+ .markdown-body h2 code,+ .markdown-body h3 tt,+ .markdown-body h3 code,+ .markdown-body h4 tt,+ .markdown-body h4 code,+ .markdown-body h5 tt,+ .markdown-body h5 code,+ .markdown-body h6 tt,+ .markdown-body h6 code {+ padding: 0 .2em;+ font-size: inherit;+ }++ .markdown-body ul.no-list,+ .markdown-body ol.no-list {+ padding: 0;+ list-style-type: none;+ }++ .markdown-body ol[type="1"] {+ list-style-type: decimal;+ }++ .markdown-body ol[type=a] {+ list-style-type: lower-alpha;+ }++ .markdown-body ol[type=i] {+ list-style-type: lower-roman;+ }++ .markdown-body div > ol:not([type]) {+ list-style-type: decimal;+ }++ .markdown-body ul ul,+ .markdown-body ul ol,+ .markdown-body ol ol,+ .markdown-body ol ul {+ margin-top: 0;+ margin-bottom: 0;+ }++ .markdown-body li > p {+ margin-top: 16px;+ }++ .markdown-body li + li {+ margin-top: .25em;+ }++ .markdown-body dl {+ padding: 0;+ }++ .markdown-body dl dt {+ padding: 0;+ margin-top: 16px;+ font-size: 1em;+ font-style: italic;+ font-weight: 600;+ }++ .markdown-body dl dd {+ padding: 0 16px;+ margin-bottom: 16px;+ }++ .markdown-body table th {+ font-weight: 600;+ }++ .markdown-body table th,+ .markdown-body table td {+ padding: 6px 13px;+ border: 1px solid #d0d7de;+ }++ .markdown-body table tr {+ background-color: #ffffff;+ border-top: 1px solid hsla(210,18%,87%,1);+ }++ .markdown-body table tr:nth-child(2n) {+ background-color: #f6f8fa;+ }++ .markdown-body table img {+ background-color: transparent;+ }++ .markdown-body img[align=right] {+ padding-left: 20px;+ }++ .markdown-body img[align=left] {+ padding-right: 20px;+ }++ .markdown-body .emoji {+ max-width: none;+ vertical-align: text-top;+ background-color: transparent;+ }++ .markdown-body span.frame {+ display: block;+ overflow: hidden;+ }++ .markdown-body span.frame > span {+ display: block;+ float: left;+ width: auto;+ padding: 7px;+ margin: 13px 0 0;+ overflow: hidden;+ border: 1px solid #d0d7de;+ }++ .markdown-body span.frame span img {+ display: block;+ float: left;+ }++ .markdown-body span.frame span span {+ display: block;+ padding: 5px 0 0;+ clear: both;+ color: #24292f;+ }++ .markdown-body span.align-center {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-center > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: center;+ }++ .markdown-body span.align-center span img {+ margin: 0 auto;+ text-align: center;+ }++ .markdown-body span.align-right {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-right > span {+ display: block;+ margin: 13px 0 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body span.align-right span img {+ margin: 0;+ text-align: right;+ }++ .markdown-body span.float-left {+ display: block;+ float: left;+ margin-right: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-left span {+ margin: 13px 0 0;+ }++ .markdown-body span.float-right {+ display: block;+ float: right;+ margin-left: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-right > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body code,+ .markdown-body tt {+ padding: .2em .4em;+ margin: 0;+ font-size: 85%;+ background-color: rgba(175,184,193,0.2);+ border-radius: 6px;+ }++ .markdown-body code br,+ .markdown-body tt br {+ display: none;+ }++ .markdown-body del code {+ text-decoration: inherit;+ }++ .markdown-body pre code {+ font-size: 100%;+ }++ .markdown-body pre > code {+ padding: 0;+ margin: 0;+ word-break: normal;+ white-space: pre;+ background: transparent;+ border: 0;+ }++ .markdown-body .highlight {+ margin-bottom: 16px;+ }++ .markdown-body .highlight pre {+ margin-bottom: 0;+ word-break: normal;+ }++ .markdown-body .highlight pre,+ .markdown-body pre {+ padding: 16px;+ overflow: auto;+ font-size: 85%;+ line-height: 1.45;+ background-color: #f6f8fa;+ border-radius: 6px;+ }++ .markdown-body pre code,+ .markdown-body pre tt {+ display: inline;+ max-width: auto;+ padding: 0;+ margin: 0;+ overflow: visible;+ line-height: inherit;+ word-wrap: normal;+ background-color: transparent;+ border: 0;+ }++ .markdown-body .csv-data td,+ .markdown-body .csv-data th {+ padding: 5px;+ overflow: hidden;+ font-size: 12px;+ line-height: 1;+ text-align: left;+ white-space: nowrap;+ }++ .markdown-body .csv-data .blob-num {+ padding: 10px 8px 9px;+ text-align: right;+ background: #ffffff;+ border: 0;+ }++ .markdown-body .csv-data tr {+ border-top: 0;+ }++ .markdown-body .csv-data th {+ font-weight: 600;+ background: #f6f8fa;+ border-top: 0;+ }++ .markdown-body .footnotes {+ font-size: 12px;+ color: #57606a;+ border-top: 1px solid #d0d7de;+ }++ .markdown-body .footnotes ol {+ padding-left: 16px;+ }++ .markdown-body .footnotes li {+ position: relative;+ }++ .markdown-body .footnotes li:target::before {+ position: absolute;+ top: -8px;+ right: -8px;+ bottom: -8px;+ left: -24px;+ pointer-events: none;+ content: "";+ border: 2px solid #0969da;+ border-radius: 6px;+ }++ .markdown-body .footnotes li:target {+ color: #24292f;+ }++ .markdown-body .footnotes .data-footnote-backref g-emoji {+ font-family: monospace;+ }++ .markdown-body [hidden] {+ display: none !important;+ }++ .markdown-body ::-webkit-calendar-picker-indicator {+ filter: invert(50%);+ }diff --git a/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown.css b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown.cssnew file mode 100644index 000000000..34fc9cf1a--- /dev/null+++ b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/github-markdown.css@@ -0,0 +1,993 @@+@media (prefers-color-scheme: dark) {+ .markdown-body {+ color-scheme: dark;+ --color-prettylights-syntax-comment: #8b949e;+ --color-prettylights-syntax-constant: #79c0ff;+ --color-prettylights-syntax-entity: #d2a8ff;+ --color-prettylights-syntax-storage-modifier-import: #c9d1d9;+ --color-prettylights-syntax-entity-tag: #7ee787;+ --color-prettylights-syntax-keyword: #ff7b72;+ --color-prettylights-syntax-string: #a5d6ff;+ --color-prettylights-syntax-variable: #ffa657;+ --color-prettylights-syntax-brackethighlighter-unmatched: #f85149;+ --color-prettylights-syntax-invalid-illegal-text: #f0f6fc;+ --color-prettylights-syntax-invalid-illegal-bg: #8e1519;+ --color-prettylights-syntax-carriage-return-text: #f0f6fc;+ --color-prettylights-syntax-carriage-return-bg: #b62324;+ --color-prettylights-syntax-string-regexp: #7ee787;+ --color-prettylights-syntax-markup-list: #f2cc60;+ --color-prettylights-syntax-markup-heading: #1f6feb;+ --color-prettylights-syntax-markup-italic: #c9d1d9;+ --color-prettylights-syntax-markup-bold: #c9d1d9;+ --color-prettylights-syntax-markup-deleted-text: #ffdcd7;+ --color-prettylights-syntax-markup-deleted-bg: #67060c;+ --color-prettylights-syntax-markup-inserted-text: #aff5b4;+ --color-prettylights-syntax-markup-inserted-bg: #033a16;+ --color-prettylights-syntax-markup-changed-text: #ffdfb6;+ --color-prettylights-syntax-markup-changed-bg: #5a1e02;+ --color-prettylights-syntax-markup-ignored-text: #c9d1d9;+ --color-prettylights-syntax-markup-ignored-bg: #1158c7;+ --color-prettylights-syntax-meta-diff-range: #d2a8ff;+ --color-prettylights-syntax-brackethighlighter-angle: #8b949e;+ --color-prettylights-syntax-sublimelinter-gutter-mark: #484f58;+ --color-prettylights-syntax-constant-other-reference-link: #a5d6ff;+ --color-fg-default: #c9d1d9;+ --color-fg-muted: #8b949e;+ --color-fg-subtle: #484f58;+ --color-canvas-default: #0d1117;+ --color-canvas-subtle: #161b22;+ --color-border-default: #30363d;+ --color-border-muted: #21262d;+ --color-neutral-muted: rgba(110,118,129,0.4);+ --color-accent-fg: #58a6ff;+ --color-accent-emphasis: #1f6feb;+ --color-danger-fg: #f85149;+ }+}++@media (prefers-color-scheme: light) {+ .markdown-body {+ color-scheme: light;+ --color-prettylights-syntax-comment: #6e7781;+ --color-prettylights-syntax-constant: #0550ae;+ --color-prettylights-syntax-entity: #8250df;+ --color-prettylights-syntax-storage-modifier-import: #24292f;+ --color-prettylights-syntax-entity-tag: #116329;+ --color-prettylights-syntax-keyword: #cf222e;+ --color-prettylights-syntax-string: #0a3069;+ --color-prettylights-syntax-variable: #953800;+ --color-prettylights-syntax-brackethighlighter-unmatched: #82071e;+ --color-prettylights-syntax-invalid-illegal-text: #f6f8fa;+ --color-prettylights-syntax-invalid-illegal-bg: #82071e;+ --color-prettylights-syntax-carriage-return-text: #f6f8fa;+ --color-prettylights-syntax-carriage-return-bg: #cf222e;+ --color-prettylights-syntax-string-regexp: #116329;+ --color-prettylights-syntax-markup-list: #3b2300;+ --color-prettylights-syntax-markup-heading: #0550ae;+ --color-prettylights-syntax-markup-italic: #24292f;+ --color-prettylights-syntax-markup-bold: #24292f;+ --color-prettylights-syntax-markup-deleted-text: #82071e;+ --color-prettylights-syntax-markup-deleted-bg: #FFEBE9;+ --color-prettylights-syntax-markup-inserted-text: #116329;+ --color-prettylights-syntax-markup-inserted-bg: #dafbe1;+ --color-prettylights-syntax-markup-changed-text: #953800;+ --color-prettylights-syntax-markup-changed-bg: #ffd8b5;+ --color-prettylights-syntax-markup-ignored-text: #eaeef2;+ --color-prettylights-syntax-markup-ignored-bg: #0550ae;+ --color-prettylights-syntax-meta-diff-range: #8250df;+ --color-prettylights-syntax-brackethighlighter-angle: #57606a;+ --color-prettylights-syntax-sublimelinter-gutter-mark: #8c959f;+ --color-prettylights-syntax-constant-other-reference-link: #0a3069;+ --color-fg-default: #24292f;+ --color-fg-muted: #57606a;+ --color-fg-subtle: #6e7781;+ --color-canvas-default: #ffffff;+ --color-canvas-subtle: #f6f8fa;+ --color-border-default: #d0d7de;+ --color-border-muted: hsla(210,18%,87%,1);+ --color-neutral-muted: rgba(175,184,193,0.2);+ --color-accent-fg: #0969da;+ --color-accent-emphasis: #0969da;+ --color-danger-fg: #cf222e;+ }+}++.markdown-body {+ -ms-text-size-adjust: 100%;+ -webkit-text-size-adjust: 100%;+ margin: 0;+ color: var(--color-fg-default);+ background-color: var(--color-canvas-default);+ font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Helvetica,Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji";+ font-size: 16px;+ line-height: 1.5;+ word-wrap: break-word;+}++ .markdown-body .octicon {+ display: inline-block;+ fill: currentColor;+ vertical-align: text-bottom;+ }++ .markdown-body h1:hover .anchor .octicon-link:before,+ .markdown-body h2:hover .anchor .octicon-link:before,+ .markdown-body h3:hover .anchor .octicon-link:before,+ .markdown-body h4:hover .anchor .octicon-link:before,+ .markdown-body h5:hover .anchor .octicon-link:before,+ .markdown-body h6:hover .anchor .octicon-link:before {+ width: 16px;+ height: 16px;+ content: ' ';+ display: inline-block;+ background-color: currentColor;+ -webkit-mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ mask-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' version='1.1' aria-hidden='true'><path fill-rule='evenodd' d='M7.775 3.275a.75.75 0 001.06 1.06l1.25-1.25a2 2 0 112.83 2.83l-2.5 2.5a2 2 0 01-2.83 0 .75.75 0 00-1.06 1.06 3.5 3.5 0 004.95 0l2.5-2.5a3.5 3.5 0 00-4.95-4.95l-1.25 1.25zm-4.69 9.64a2 2 0 010-2.83l2.5-2.5a2 2 0 012.83 0 .75.75 0 001.06-1.06 3.5 3.5 0 00-4.95 0l-2.5 2.5a3.5 3.5 0 004.95 4.95l1.25-1.25a.75.75 0 00-1.06-1.06l-1.25 1.25a2 2 0 01-2.83 0z'></path></svg>");+ }++ .markdown-body details,+ .markdown-body figcaption,+ .markdown-body figure {+ display: block;+ }++ .markdown-body summary {+ display: list-item;+ }++ .markdown-body a {+ background-color: transparent;+ color: var(--color-accent-fg);+ text-decoration: none;+ }++ .markdown-body a:active,+ .markdown-body a:hover {+ outline-width: 0;+ }++ .markdown-body abbr[title] {+ border-bottom: none;+ -webkit-text-decoration: underline dotted;+ text-decoration: underline dotted;+ }++ .markdown-body b,+ .markdown-body strong {+ font-weight: 600;+ }++ .markdown-body dfn {+ font-style: italic;+ }++ .markdown-body h1 {+ margin: .67em 0;+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 2em;+ border-bottom: 1px solid var(--color-border-muted);+ }++ .markdown-body mark {+ background-color: #ff0;+ color: var(--color-text-primary);+ }++ .markdown-body small {+ font-size: 90%;+ }++ .markdown-body sub,+ .markdown-body sup {+ font-size: 75%;+ line-height: 0;+ position: relative;+ vertical-align: baseline;+ }++ .markdown-body sub {+ bottom: -0.25em;+ }++ .markdown-body sup {+ top: -0.5em;+ }++ .markdown-body img {+ border-style: none;+ max-width: 100%;+ box-sizing: content-box;+ background-color: var(--color-canvas-default);+ }++ .markdown-body code,+ .markdown-body kbd,+ .markdown-body pre,+ .markdown-body samp {+ font-family: monospace,monospace;+ font-size: 1em;+ }++ .markdown-body figure {+ margin: 1em 40px;+ }++ .markdown-body hr {+ box-sizing: content-box;+ overflow: hidden;+ background: transparent;+ border-bottom: 1px solid var(--color-border-muted);+ height: .25em;+ padding: 0;+ margin: 24px 0;+ background-color: var(--color-border-default);+ border: 0;+ }++ .markdown-body html [type=button],+ .markdown-body [type=reset],+ .markdown-body [type=submit] {+ -webkit-appearance: button;+ }++ .markdown-body [type=button]::-moz-focus-inner,+ .markdown-body [type=reset]::-moz-focus-inner,+ .markdown-body [type=submit]::-moz-focus-inner {+ border-style: none;+ padding: 0;+ }++ .markdown-body [type=button]:-moz-focusring,+ .markdown-body [type=reset]:-moz-focusring,+ .markdown-body [type=submit]:-moz-focusring {+ outline: 1px dotted ButtonText;+ }++ .markdown-body [type=checkbox],+ .markdown-body [type=radio] {+ box-sizing: border-box;+ padding: 0;+ }++ .markdown-body [type=number]::-webkit-inner-spin-button,+ .markdown-body [type=number]::-webkit-outer-spin-button {+ height: auto;+ }++ .markdown-body [type=search] {+ -webkit-appearance: textfield;+ outline-offset: -2px;+ }++ .markdown-body [type=search]::-webkit-search-cancel-button,+ .markdown-body [type=search]::-webkit-search-decoration {+ -webkit-appearance: none;+ }++ .markdown-body ::-webkit-input-placeholder {+ color: inherit;+ opacity: .54;+ }++ .markdown-body ::-webkit-file-upload-button {+ -webkit-appearance: button;+ font: inherit;+ }++ .markdown-body a:hover {+ text-decoration: underline;+ }++ .markdown-body hr::before {+ display: table;+ content: "";+ }++ .markdown-body hr::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body table {+ border-spacing: 0;+ border-collapse: collapse;+ display: block;+ width: max-content;+ max-width: 100%;+ overflow: auto;+ }++ .markdown-body td,+ .markdown-body th {+ padding: 0;+ }++ .markdown-body details summary {+ cursor: pointer;+ }++ .markdown-body details:not([open]) > *:not(summary) {+ display: none !important;+ }++ .markdown-body kbd {+ display: inline-block;+ padding: 3px 5px;+ font: 11px ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ line-height: 10px;+ color: var(--color-fg-default);+ vertical-align: middle;+ background-color: var(--color-canvas-subtle);+ border: solid 1px var(--color-neutral-muted);+ border-bottom-color: var(--color-neutral-muted);+ border-radius: 6px;+ box-shadow: inset 0 -1px 0 var(--color-neutral-muted);+ }++ .markdown-body h1,+ .markdown-body h2,+ .markdown-body h3,+ .markdown-body h4,+ .markdown-body h5,+ .markdown-body h6 {+ margin-top: 24px;+ margin-bottom: 16px;+ font-weight: 600;+ line-height: 1.25;+ }++ .markdown-body h2 {+ font-weight: 600;+ padding-bottom: .3em;+ font-size: 1.5em;+ border-bottom: 1px solid var(--color-border-muted);+ }++ .markdown-body h3 {+ font-weight: 600;+ font-size: 1.25em;+ }++ .markdown-body h4 {+ font-weight: 600;+ font-size: 1em;+ }++ .markdown-body h5 {+ font-weight: 600;+ font-size: .875em;+ }++ .markdown-body h6 {+ font-weight: 600;+ font-size: .85em;+ color: var(--color-fg-muted);+ }++ .markdown-body p {+ margin-top: 0;+ margin-bottom: 10px;+ }++ .markdown-body blockquote {+ margin: 0;+ padding: 0 1em;+ color: var(--color-fg-muted);+ border-left: .25em solid var(--color-border-default);+ }++ .markdown-body ul,+ .markdown-body ol {+ margin-top: 0;+ margin-bottom: 0;+ padding-left: 2em;+ }++ .markdown-body ol ol,+ .markdown-body ul ol {+ list-style-type: lower-roman;+ }++ .markdown-body ul ul ol,+ .markdown-body ul ol ol,+ .markdown-body ol ul ol,+ .markdown-body ol ol ol {+ list-style-type: lower-alpha;+ }++ .markdown-body dd {+ margin-left: 0;+ }++ .markdown-body tt,+ .markdown-body code {+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ }++ .markdown-body pre {+ margin-top: 0;+ margin-bottom: 0;+ font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;+ font-size: 12px;+ word-wrap: normal;+ }++ .markdown-body :-ms-input-placeholder {+ color: var(--color-fg-subtle);+ opacity: 1;+ }++ .markdown-body ::-ms-input-placeholder {+ color: var(--color-fg-subtle);+ opacity: 1;+ }++ .markdown-body ::placeholder {+ color: var(--color-fg-subtle);+ opacity: 1;+ }++ .markdown-body .pl-c {+ color: var(--color-prettylights-syntax-comment);+ }++ .markdown-body .pl-c1,+ .markdown-body .pl-s .pl-v {+ color: var(--color-prettylights-syntax-constant);+ }++ .markdown-body .pl-e,+ .markdown-body .pl-en {+ color: var(--color-prettylights-syntax-entity);+ }++ .markdown-body .pl-smi,+ .markdown-body .pl-s .pl-s1 {+ color: var(--color-prettylights-syntax-storage-modifier-import);+ }++ .markdown-body .pl-ent {+ color: var(--color-prettylights-syntax-entity-tag);+ }++ .markdown-body .pl-k {+ color: var(--color-prettylights-syntax-keyword);+ }++ .markdown-body .pl-s,+ .markdown-body .pl-pds,+ .markdown-body .pl-s .pl-pse .pl-s1,+ .markdown-body .pl-sr,+ .markdown-body .pl-sr .pl-cce,+ .markdown-body .pl-sr .pl-sre,+ .markdown-body .pl-sr .pl-sra {+ color: var(--color-prettylights-syntax-string);+ }++ .markdown-body .pl-v,+ .markdown-body .pl-smw {+ color: var(--color-prettylights-syntax-variable);+ }++ .markdown-body .pl-bu {+ color: var(--color-prettylights-syntax-brackethighlighter-unmatched);+ }++ .markdown-body .pl-ii {+ color: var(--color-prettylights-syntax-invalid-illegal-text);+ background-color: var(--color-prettylights-syntax-invalid-illegal-bg);+ }++ .markdown-body .pl-c2 {+ color: var(--color-prettylights-syntax-carriage-return-text);+ background-color: var(--color-prettylights-syntax-carriage-return-bg);+ }++ .markdown-body .pl-sr .pl-cce {+ font-weight: bold;+ color: var(--color-prettylights-syntax-string-regexp);+ }++ .markdown-body .pl-ml {+ color: var(--color-prettylights-syntax-markup-list);+ }++ .markdown-body .pl-mh,+ .markdown-body .pl-mh .pl-en,+ .markdown-body .pl-ms {+ font-weight: bold;+ color: var(--color-prettylights-syntax-markup-heading);+ }++ .markdown-body .pl-mi {+ font-style: italic;+ color: var(--color-prettylights-syntax-markup-italic);+ }++ .markdown-body .pl-mb {+ font-weight: bold;+ color: var(--color-prettylights-syntax-markup-bold);+ }++ .markdown-body .pl-md {+ color: var(--color-prettylights-syntax-markup-deleted-text);+ background-color: var(--color-prettylights-syntax-markup-deleted-bg);+ }++ .markdown-body .pl-mi1 {+ color: var(--color-prettylights-syntax-markup-inserted-text);+ background-color: var(--color-prettylights-syntax-markup-inserted-bg);+ }++ .markdown-body .pl-mc {+ color: var(--color-prettylights-syntax-markup-changed-text);+ background-color: var(--color-prettylights-syntax-markup-changed-bg);+ }++ .markdown-body .pl-mi2 {+ color: var(--color-prettylights-syntax-markup-ignored-text);+ background-color: var(--color-prettylights-syntax-markup-ignored-bg);+ }++ .markdown-body .pl-mdr {+ font-weight: bold;+ color: var(--color-prettylights-syntax-meta-diff-range);+ }++ .markdown-body .pl-ba {+ color: var(--color-prettylights-syntax-brackethighlighter-angle);+ }++ .markdown-body .pl-sg {+ color: var(--color-prettylights-syntax-sublimelinter-gutter-mark);+ }++ .markdown-body .pl-corl {+ text-decoration: underline;+ color: var(--color-prettylights-syntax-constant-other-reference-link);+ }++ .markdown-body [data-catalyst] {+ display: block;+ }++ .markdown-body g-emoji {+ font-family: "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";+ font-size: 1em;+ font-style: normal !important;+ font-weight: 400;+ line-height: 1;+ vertical-align: -0.075em;+ }++ .markdown-body g-emoji img {+ width: 1em;+ height: 1em;+ }++ .markdown-body::before {+ display: table;+ content: "";+ }++ .markdown-body::after {+ display: table;+ clear: both;+ content: "";+ }++ .markdown-body > *:first-child {+ margin-top: 0 !important;+ }++ .markdown-body > *:last-child {+ margin-bottom: 0 !important;+ }++ .markdown-body a:not([href]) {+ color: inherit;+ text-decoration: none;+ }++ .markdown-body .absent {+ color: var(--color-danger-fg);+ }++ .markdown-body .anchor {+ float: left;+ padding-right: 4px;+ margin-left: -20px;+ line-height: 1;+ }++ .markdown-body .anchor:focus {+ outline: none;+ }++ .markdown-body p,+ .markdown-body blockquote,+ .markdown-body ul,+ .markdown-body ol,+ .markdown-body dl,+ .markdown-body table,+ .markdown-body pre,+ .markdown-body details {+ margin-top: 0;+ margin-bottom: 16px;+ }++ .markdown-body blockquote > :first-child {+ margin-top: 0;+ }++ .markdown-body blockquote > :last-child {+ margin-bottom: 0;+ }++ .markdown-body sup > a::before {+ content: "[";+ }++ .markdown-body sup > a::after {+ content: "]";+ }++ .markdown-body h1 .octicon-link,+ .markdown-body h2 .octicon-link,+ .markdown-body h3 .octicon-link,+ .markdown-body h4 .octicon-link,+ .markdown-body h5 .octicon-link,+ .markdown-body h6 .octicon-link {+ color: var(--color-fg-default);+ vertical-align: middle;+ visibility: hidden;+ }++ .markdown-body h1:hover .anchor,+ .markdown-body h2:hover .anchor,+ .markdown-body h3:hover .anchor,+ .markdown-body h4:hover .anchor,+ .markdown-body h5:hover .anchor,+ .markdown-body h6:hover .anchor {+ text-decoration: none;+ }++ .markdown-body h1:hover .anchor .octicon-link,+ .markdown-body h2:hover .anchor .octicon-link,+ .markdown-body h3:hover .anchor .octicon-link,+ .markdown-body h4:hover .anchor .octicon-link,+ .markdown-body h5:hover .anchor .octicon-link,+ .markdown-body h6:hover .anchor .octicon-link {+ visibility: visible;+ }++ .markdown-body h1 tt,+ .markdown-body h1 code,+ .markdown-body h2 tt,+ .markdown-body h2 code,+ .markdown-body h3 tt,+ .markdown-body h3 code,+ .markdown-body h4 tt,+ .markdown-body h4 code,+ .markdown-body h5 tt,+ .markdown-body h5 code,+ .markdown-body h6 tt,+ .markdown-body h6 code {+ padding: 0 .2em;+ font-size: inherit;+ }++ .markdown-body ul.no-list,+ .markdown-body ol.no-list {+ padding: 0;+ list-style-type: none;+ }++ .markdown-body ol[type="1"] {+ list-style-type: decimal;+ }++ .markdown-body ol[type=a] {+ list-style-type: lower-alpha;+ }++ .markdown-body ol[type=i] {+ list-style-type: lower-roman;+ }++ .markdown-body div > ol:not([type]) {+ list-style-type: decimal;+ }++ .markdown-body ul ul,+ .markdown-body ul ol,+ .markdown-body ol ol,+ .markdown-body ol ul {+ margin-top: 0;+ margin-bottom: 0;+ }++ .markdown-body li > p {+ margin-top: 16px;+ }++ .markdown-body li + li {+ margin-top: .25em;+ }++ .markdown-body dl {+ padding: 0;+ }++ .markdown-body dl dt {+ padding: 0;+ margin-top: 16px;+ font-size: 1em;+ font-style: italic;+ font-weight: 600;+ }++ .markdown-body dl dd {+ padding: 0 16px;+ margin-bottom: 16px;+ }++ .markdown-body table th {+ font-weight: 600;+ }++ .markdown-body table th,+ .markdown-body table td {+ padding: 6px 13px;+ border: 1px solid var(--color-border-default);+ }++ .markdown-body table tr {+ background-color: var(--color-canvas-default);+ border-top: 1px solid var(--color-border-muted);+ }++ .markdown-body table tr:nth-child(2n) {+ background-color: var(--color-canvas-subtle);+ }++ .markdown-body table img {+ background-color: transparent;+ }++ .markdown-body img[align=right] {+ padding-left: 20px;+ }++ .markdown-body img[align=left] {+ padding-right: 20px;+ }++ .markdown-body .emoji {+ max-width: none;+ vertical-align: text-top;+ background-color: transparent;+ }++ .markdown-body span.frame {+ display: block;+ overflow: hidden;+ }++ .markdown-body span.frame > span {+ display: block;+ float: left;+ width: auto;+ padding: 7px;+ margin: 13px 0 0;+ overflow: hidden;+ border: 1px solid var(--color-border-default);+ }++ .markdown-body span.frame span img {+ display: block;+ float: left;+ }++ .markdown-body span.frame span span {+ display: block;+ padding: 5px 0 0;+ clear: both;+ color: var(--color-fg-default);+ }++ .markdown-body span.align-center {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-center > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: center;+ }++ .markdown-body span.align-center span img {+ margin: 0 auto;+ text-align: center;+ }++ .markdown-body span.align-right {+ display: block;+ overflow: hidden;+ clear: both;+ }++ .markdown-body span.align-right > span {+ display: block;+ margin: 13px 0 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body span.align-right span img {+ margin: 0;+ text-align: right;+ }++ .markdown-body span.float-left {+ display: block;+ float: left;+ margin-right: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-left span {+ margin: 13px 0 0;+ }++ .markdown-body span.float-right {+ display: block;+ float: right;+ margin-left: 13px;+ overflow: hidden;+ }++ .markdown-body span.float-right > span {+ display: block;+ margin: 13px auto 0;+ overflow: hidden;+ text-align: right;+ }++ .markdown-body code,+ .markdown-body tt {+ padding: .2em .4em;+ margin: 0;+ font-size: 85%;+ background-color: var(--color-neutral-muted);+ border-radius: 6px;+ }++ .markdown-body code br,+ .markdown-body tt br {+ display: none;+ }++ .markdown-body del code {+ text-decoration: inherit;+ }++ .markdown-body pre code {+ font-size: 100%;+ }++ .markdown-body pre > code {+ padding: 0;+ margin: 0;+ word-break: normal;+ white-space: pre;+ background: transparent;+ border: 0;+ }++ .markdown-body .highlight {+ margin-bottom: 16px;+ }++ .markdown-body .highlight pre {+ margin-bottom: 0;+ word-break: normal;+ }++ .markdown-body .highlight pre,+ .markdown-body pre {+ padding: 16px;+ overflow: auto;+ font-size: 85%;+ line-height: 1.45;+ background-color: var(--color-canvas-subtle);+ border-radius: 6px;+ }++ .markdown-body pre code,+ .markdown-body pre tt {+ display: inline;+ max-width: auto;+ padding: 0;+ margin: 0;+ overflow: visible;+ line-height: inherit;+ word-wrap: normal;+ background-color: transparent;+ border: 0;+ }++ .markdown-body .csv-data td,+ .markdown-body .csv-data th {+ padding: 5px;+ overflow: hidden;+ font-size: 12px;+ line-height: 1;+ text-align: left;+ white-space: nowrap;+ }++ .markdown-body .csv-data .blob-num {+ padding: 10px 8px 9px;+ text-align: right;+ background: var(--color-canvas-default);+ border: 0;+ }++ .markdown-body .csv-data tr {+ border-top: 0;+ }++ .markdown-body .csv-data th {+ font-weight: 600;+ background: var(--color-canvas-subtle);+ border-top: 0;+ }++ .markdown-body .footnotes {+ font-size: 12px;+ color: var(--color-fg-muted);+ border-top: 1px solid var(--color-border-default);+ }++ .markdown-body .footnotes ol {+ padding-left: 16px;+ }++ .markdown-body .footnotes li {+ position: relative;+ }++ .markdown-body .footnotes li:target::before {+ position: absolute;+ top: -8px;+ right: -8px;+ bottom: -8px;+ left: -24px;+ pointer-events: none;+ content: "";+ border: 2px solid var(--color-accent-emphasis);+ border-radius: 6px;+ }++ .markdown-body .footnotes li:target {+ color: var(--color-fg-default);+ }++ .markdown-body .footnotes .data-footnote-backref g-emoji {+ font-family: monospace;+ }++ .markdown-body [hidden] {+ display: none !important;+ }++ .markdown-body ::-webkit-calendar-picker-indicator {+ filter: invert(50%);+ }diff --git a/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/index.html b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/index.htmlnew file mode 100644index 000000000..c627af391--- /dev/null+++ b/src/dev/impl/DevToys/Assets/GitHubMarkdownCss/index.html@@ -0,0 +1,26 @@+<!doctype html>+<html>+<head>+ <meta charset="utf-8">+ <meta name="viewport" content="width=device-width, initial-scale=1, minimal-ui">+ <title>DevToys Markdown Preview</title>+ <meta name="color-scheme" content="{{renderTheme}}">+ <link rel="stylesheet" href="ms-appx-web:///Assets/GitHubMarkdownCss/github-markdown.css">+ <link rel="stylesheet" href="ms-appx-web:///Assets/GitHubMarkdownCss/github-markdown-{{renderTheme}}.css">+ <style>+ body {+ box-sizing: border-box;+ min-width: 200px;+ max-width: 980px;+ margin: 0 auto;+ padding: 45px;+ background-color: {{backgroundColor}};+ }+ </style>+</head>+<body>+ <article class="markdown-body">+ {{htmlBody}}+ </article>+</body>+</html>diff --git a/src/dev/impl/DevToys/DevToys.csproj b/src/dev/impl/DevToys/DevToys.csprojindex 29184200a..681a98ab7 100644--- a/src/dev/impl/DevToys/DevToys.csproj+++ b/src/dev/impl/DevToys/DevToys.csproj@@ -142,6 +142,10 @@<Link>Assets\Logo\Wide310x150Logo.scale-400.png</Link></Content><Content Include="Assets\DemoSmartDetection.gif" />+ <Content Include="Assets\GitHubMarkdownCss\github-markdown-dark.css" />+ <Content Include="Assets\GitHubMarkdownCss\github-markdown-light.css" />+ <Content Include="Assets\GitHubMarkdownCss\github-markdown.css" />+ <Content Include="Assets\GitHubMarkdownCss\index.html" /><Content Include="Assets\ReleaseNote.txt"><CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory></Content>@@ -194,6 +198,7 @@<Compile Include="Core\TitleBar.cs" /><Compile Include="Core\ToolProviderFactory.cs" /><Compile Include="Helpers\JwtHelper.cs" />+ <Compile Include="Messages\NavigateToMarkdownPreviewHtmlMessage.cs" /><Compile Include="Models\IndentationDisplayPair.cs" /><Compile Include="Models\Indentation.cs" /><Compile Include="UI\Controls\CodeEditor.xaml.cs">@@ -209,6 +214,8 @@<Compile Include="ViewModels\Tools\JsonYaml\JsonYamlToolViewModel.cs" /><Compile Include="ViewModels\Tools\JwtDecoderEncoder\JwtDecoderEncoderToolProvider.cs" /><Compile Include="ViewModels\Tools\JwtDecoderEncoder\JwtDecoderEncoderToolViewModel.cs" />+ <Compile Include="ViewModels\Tools\MarkdownPreview\MarkdownPreviewToolProvider.cs" />+ <Compile Include="ViewModels\Tools\MarkdownPreview\MarkdownPreviewToolViewModel.cs" /><Compile Include="ViewModels\Tools\StringUtilities\StringUtilitiesToolProvider.cs" /><Compile Include="ViewModels\Tools\StringUtilities\StringUtilitiesToolViewModel.cs" /><Compile Include="ViewModels\Tools\ToolProviderBase.cs" />@@ -281,6 +288,9 @@<Compile Include="Views\Tools\JwtDecoderEncoder\JwtDecoderEncoderToolPage.xaml.cs"><DependentUpon>JwtDecoderEncoderToolPage.xaml</DependentUpon></Compile>+ <Compile Include="Views\Tools\MarkdownPreview\MarkdownPreviewToolPage.xaml.cs">+ <DependentUpon>MarkdownPreviewToolPage.xaml</DependentUpon>+ </Compile><Compile Include="Views\Tools\RegEx\RegExToolPage.xaml.cs"><DependentUpon>RegExToolPage.xaml</DependentUpon></Compile>@@ -376,6 +386,10 @@<Generator>MSBuild:Compile</Generator><SubType>Designer</SubType></Page>+ <Page Include="Views\Tools\MarkdownPreview\MarkdownPreviewToolPage.xaml">+ <SubType>Designer</SubType>+ <Generator>MSBuild:Compile</Generator>+ </Page><Page Include="Views\Tools\RegEx\RegExToolPage.xaml"><Generator>MSBuild:Compile</Generator><SubType>Designer</SubType>@@ -400,6 +414,7 @@</ItemGroup><ItemGroup><PackageReference Include="GitInfo" Version="$(Nuget_GitInfo)" />+ <PackageReference Include="Markdig" Version="$(Nuget_Markdig)" /><PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform" Version="$(NuGet_MicrosoftNETCoreUniversalWindowsPlatform)" /><PackageReference Include="Microsoft.Toolkit.Mvvm" Version="$(NuGet_MicrosoftToolkitMvvm)" /><PackageReference Include="Microsoft.Toolkit.Uwp.UI.Behaviors" Version="$(Nuget_MicrosoftToolkitUwpUIBehaviors)" />diff --git a/src/dev/impl/DevToys/LanguageManager.cs b/src/dev/impl/DevToys/LanguageManager.csindex 4946e62ef..b443de9f3 100644--- a/src/dev/impl/DevToys/LanguageManager.cs+++ b/src/dev/impl/DevToys/LanguageManager.cs@@ -31,6 +31,7 @@ namespace DevToysprivate readonly JsonYamlStrings _jsonyaml = new JsonYamlStrings();private readonly JwtDecoderEncoderStrings _jwtdecoderencoder = new JwtDecoderEncoderStrings();private readonly MainPageStrings _mainpage = new MainPageStrings();+ private readonly MarkdownPreviewStrings _markdownpreview = new MarkdownPreviewStrings();private readonly RegExStrings _regex = new RegExStrings();private readonly SettingsStrings _settings = new SettingsStrings();private readonly StringUtilitiesStrings _stringutilities = new StringUtilitiesStrings();@@ -81,6 +82,11 @@ namespace DevToys/// </summary>public MainPageStrings MainPage => _mainpage;+ /// <summary>+ /// Gets the <see cref="MarkdownPreviewStrings"/>.+ /// </summary>+ public MarkdownPreviewStrings MarkdownPreview => _markdownpreview;+/// <summary>/// Gets the <see cref="RegExStrings"/>./// </summary>@@ -585,6 +591,51 @@ namespace DevToys}}+ public class MarkdownPreviewStrings : ObservableObject+ {+ private readonly ResourceLoader _resources = ResourceLoader.GetForViewIndependentUse("MarkdownPreview");++ /// <summary>+ /// Gets the resource Configuration.+ /// </summary>+ public string Configuration => _resources.GetString("Configuration");++ /// <summary>+ /// Gets the resource Dark.+ /// </summary>+ public string Dark => _resources.GetString("Dark");++ /// <summary>+ /// Gets the resource DisplayName.+ /// </summary>+ public string DisplayName => _resources.GetString("DisplayName");++ /// <summary>+ /// Gets the resource Input.+ /// </summary>+ public string Input => _resources.GetString("Input");++ /// <summary>+ /// Gets the resource Light.+ /// </summary>+ public string Light => _resources.GetString("Light");++ /// <summary>+ /// Gets the resource Output.+ /// </summary>+ public string Output => _resources.GetString("Output");++ /// <summary>+ /// Gets the resource Theme.+ /// </summary>+ public string Theme => _resources.GetString("Theme");++ /// <summary>+ /// Gets the resource ThemeDescription.+ /// </summary>+ public string ThemeDescription => _resources.GetString("ThemeDescription");+ }+public class RegExStrings : ObservableObject{private readonly ResourceLoader _resources = ResourceLoader.GetForViewIndependentUse("RegEx");diff --git a/src/dev/impl/DevToys/Messages/NavigateToMarkdownPreviewHtmlMessage.cs b/src/dev/impl/DevToys/Messages/NavigateToMarkdownPreviewHtmlMessage.csnew file mode 100644index 000000000..b24349c17--- /dev/null+++ b/src/dev/impl/DevToys/Messages/NavigateToMarkdownPreviewHtmlMessage.cs@@ -0,0 +1,14 @@+#nullable enable++namespace DevToys.Messages+{+ public sealed class NavigateToMarkdownPreviewHtmlMessage+ {+ internal string Html { get; }++ public NavigateToMarkdownPreviewHtmlMessage(string html)+ {+ Html = html;+ }+ }+}diff --git a/src/dev/impl/DevToys/Strings/en/MarkdownPreview.resw b/src/dev/impl/DevToys/Strings/en/MarkdownPreview.reswnew file mode 100644index 000000000..4a044d2db--- /dev/null+++ b/src/dev/impl/DevToys/Strings/en/MarkdownPreview.resw@@ -0,0 +1,144 @@+<?xml version="1.0" encoding="utf-8"?>+<root>+ <!--+ Microsoft ResX Schema++ Version 2.0++ The primary goals of this format is to allow a simple XML format+ that is mostly human readable. The generation and parsing of the+ various data types are done through the TypeConverter classes+ associated with the data types.++ Example:++ ... ado.net/XML headers & schema ...+ <resheader name="resmimetype">text/microsoft-resx</resheader>+ <resheader name="version">2.0</resheader>+ <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>+ <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>+ <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>+ <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>+ <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">+ <value>[base64 mime encoded serialized .NET Framework object]</value>+ </data>+ <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">+ <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>+ <comment>This is a comment</comment>+ </data>++ There are any number of "resheader" rows that contain simple+ name/value pairs.++ Each data row contains a name, and value. The row also contains a+ type or mimetype. Type corresponds to a .NET class that support+ text/value conversion through the TypeConverter architecture.+ Classes that don't support this are serialized and stored with the+ mimetype set.++ The mimetype is used for serialized objects, and tells the+ ResXResourceReader how to depersist the object. This is currently not+ extensible. For a given mimetype the value must be set accordingly:++ Note - application/x-microsoft.net.object.binary.base64 is the format+ that the ResXResourceWriter will generate, however the reader can+ read any of the formats listed below.++ mimetype: application/x-microsoft.net.object.binary.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.soap.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Soap.SoapFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.bytearray.base64+ value : The object must be serialized into a byte array+ : using a System.ComponentModel.TypeConverter+ : and then encoded with base64 encoding.+ -->+ <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />+ <xsd:element name="root" msdata:IsDataSet="true">+ <xsd:complexType>+ <xsd:choice maxOccurs="unbounded">+ <xsd:element name="metadata">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" />+ </xsd:sequence>+ <xsd:attribute name="name" use="required" type="xsd:string" />+ <xsd:attribute name="type" type="xsd:string" />+ <xsd:attribute name="mimetype" type="xsd:string" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="assembly">+ <xsd:complexType>+ <xsd:attribute name="alias" type="xsd:string" />+ <xsd:attribute name="name" type="xsd:string" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="data">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />+ <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />+ <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="resheader">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" />+ </xsd:complexType>+ </xsd:element>+ </xsd:choice>+ </xsd:complexType>+ </xsd:element>+ </xsd:schema>+ <resheader name="resmimetype">+ <value>text/microsoft-resx</value>+ </resheader>+ <resheader name="version">+ <value>2.0</value>+ </resheader>+ <resheader name="reader">+ <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <resheader name="writer">+ <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <data name="Configuration" xml:space="preserve">+ <value>Configuration</value>+ </data>+ <data name="Dark" xml:space="preserve">+ <value>Dark</value>+ </data>+ <data name="DisplayName" xml:space="preserve">+ <value>Markdown Preview</value>+ </data>+ <data name="Input" xml:space="preserve">+ <value>Markdown</value>+ </data>+ <data name="Light" xml:space="preserve">+ <value>Light</value>+ </data>+ <data name="Output" xml:space="preserve">+ <value>Preview</value>+ </data>+ <data name="Theme" xml:space="preserve">+ <value>Theme</value>+ </data>+ <data name="ThemeDescription" xml:space="preserve">+ <value>Select which theme to use to preview the Markdown</value>+ </data>+</root>\ No newline at end of filediff --git a/src/dev/impl/DevToys/Strings/fr/MarkdownPreview.resw b/src/dev/impl/DevToys/Strings/fr/MarkdownPreview.reswnew file mode 100644index 000000000..05877d94e--- /dev/null+++ b/src/dev/impl/DevToys/Strings/fr/MarkdownPreview.resw@@ -0,0 +1,144 @@+<?xml version="1.0" encoding="utf-8"?>+<root>+ <!--+ Microsoft ResX Schema++ Version 2.0++ The primary goals of this format is to allow a simple XML format+ that is mostly human readable. The generation and parsing of the+ various data types are done through the TypeConverter classes+ associated with the data types.++ Example:++ ... ado.net/XML headers & schema ...+ <resheader name="resmimetype">text/microsoft-resx</resheader>+ <resheader name="version">2.0</resheader>+ <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>+ <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>+ <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>+ <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>+ <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">+ <value>[base64 mime encoded serialized .NET Framework object]</value>+ </data>+ <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">+ <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>+ <comment>This is a comment</comment>+ </data>++ There are any number of "resheader" rows that contain simple+ name/value pairs.++ Each data row contains a name, and value. The row also contains a+ type or mimetype. Type corresponds to a .NET class that support+ text/value conversion through the TypeConverter architecture.+ Classes that don't support this are serialized and stored with the+ mimetype set.++ The mimetype is used for serialized objects, and tells the+ ResXResourceReader how to depersist the object. This is currently not+ extensible. For a given mimetype the value must be set accordingly:++ Note - application/x-microsoft.net.object.binary.base64 is the format+ that the ResXResourceWriter will generate, however the reader can+ read any of the formats listed below.++ mimetype: application/x-microsoft.net.object.binary.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.soap.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Soap.SoapFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.bytearray.base64+ value : The object must be serialized into a byte array+ : using a System.ComponentModel.TypeConverter+ : and then encoded with base64 encoding.+ -->+ <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />+ <xsd:element name="root" msdata:IsDataSet="true">+ <xsd:complexType>+ <xsd:choice maxOccurs="unbounded">+ <xsd:element name="metadata">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" />+ </xsd:sequence>+ <xsd:attribute name="name" use="required" type="xsd:string" />+ <xsd:attribute name="type" type="xsd:string" />+ <xsd:attribute name="mimetype" type="xsd:string" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="assembly">+ <xsd:complexType>+ <xsd:attribute name="alias" type="xsd:string" />+ <xsd:attribute name="name" type="xsd:string" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="data">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />+ <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />+ <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="resheader">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" />+ </xsd:complexType>+ </xsd:element>+ </xsd:choice>+ </xsd:complexType>+ </xsd:element>+ </xsd:schema>+ <resheader name="resmimetype">+ <value>text/microsoft-resx</value>+ </resheader>+ <resheader name="version">+ <value>2.0</value>+ </resheader>+ <resheader name="reader">+ <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <resheader name="writer">+ <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <data name="Configuration" xml:space="preserve">+ <value>Configuration</value>+ </data>+ <data name="Dark" xml:space="preserve">+ <value>Sombre</value>+ </data>+ <data name="DisplayName" xml:space="preserve">+ <value>Aperçu de Markdown</value>+ </data>+ <data name="Input" xml:space="preserve">+ <value>Markdown</value>+ </data>+ <data name="Light" xml:space="preserve">+ <value>Clair</value>+ </data>+ <data name="Output" xml:space="preserve">+ <value>Aperçu</value>+ </data>+ <data name="Theme" xml:space="preserve">+ <value>Thème</value>+ </data>+ <data name="ThemeDescription" xml:space="preserve">+ <value>Sélectionner le thème à utiliser pour faire un aperçu du Markdown</value>+ </data>+</root>\ No newline at end of filediff --git a/src/dev/impl/DevToys/Strings/ru/MarkdownPreview.resw b/src/dev/impl/DevToys/Strings/ru/MarkdownPreview.reswnew file mode 100644index 000000000..4a044d2db--- /dev/null+++ b/src/dev/impl/DevToys/Strings/ru/MarkdownPreview.resw@@ -0,0 +1,144 @@+<?xml version="1.0" encoding="utf-8"?>+<root>+ <!--+ Microsoft ResX Schema++ Version 2.0++ The primary goals of this format is to allow a simple XML format+ that is mostly human readable. The generation and parsing of the+ various data types are done through the TypeConverter classes+ associated with the data types.++ Example:++ ... ado.net/XML headers & schema ...+ <resheader name="resmimetype">text/microsoft-resx</resheader>+ <resheader name="version">2.0</resheader>+ <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>+ <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>+ <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>+ <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>+ <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">+ <value>[base64 mime encoded serialized .NET Framework object]</value>+ </data>+ <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">+ <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>+ <comment>This is a comment</comment>+ </data>++ There are any number of "resheader" rows that contain simple+ name/value pairs.++ Each data row contains a name, and value. The row also contains a+ type or mimetype. Type corresponds to a .NET class that support+ text/value conversion through the TypeConverter architecture.+ Classes that don't support this are serialized and stored with the+ mimetype set.++ The mimetype is used for serialized objects, and tells the+ ResXResourceReader how to depersist the object. This is currently not+ extensible. For a given mimetype the value must be set accordingly:++ Note - application/x-microsoft.net.object.binary.base64 is the format+ that the ResXResourceWriter will generate, however the reader can+ read any of the formats listed below.++ mimetype: application/x-microsoft.net.object.binary.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.soap.base64+ value : The object must be serialized with+ : System.Runtime.Serialization.Formatters.Soap.SoapFormatter+ : and then encoded with base64 encoding.++ mimetype: application/x-microsoft.net.object.bytearray.base64+ value : The object must be serialized into a byte array+ : using a System.ComponentModel.TypeConverter+ : and then encoded with base64 encoding.+ -->+ <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">+ <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />+ <xsd:element name="root" msdata:IsDataSet="true">+ <xsd:complexType>+ <xsd:choice maxOccurs="unbounded">+ <xsd:element name="metadata">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" />+ </xsd:sequence>+ <xsd:attribute name="name" use="required" type="xsd:string" />+ <xsd:attribute name="type" type="xsd:string" />+ <xsd:attribute name="mimetype" type="xsd:string" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="assembly">+ <xsd:complexType>+ <xsd:attribute name="alias" type="xsd:string" />+ <xsd:attribute name="name" type="xsd:string" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="data">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />+ <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />+ <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />+ <xsd:attribute ref="xml:space" />+ </xsd:complexType>+ </xsd:element>+ <xsd:element name="resheader">+ <xsd:complexType>+ <xsd:sequence>+ <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />+ </xsd:sequence>+ <xsd:attribute name="name" type="xsd:string" use="required" />+ </xsd:complexType>+ </xsd:element>+ </xsd:choice>+ </xsd:complexType>+ </xsd:element>+ </xsd:schema>+ <resheader name="resmimetype">+ <value>text/microsoft-resx</value>+ </resheader>+ <resheader name="version">+ <value>2.0</value>+ </resheader>+ <resheader name="reader">+ <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <resheader name="writer">+ <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>+ </resheader>+ <data name="Configuration" xml:space="preserve">+ <value>Configuration</value>+ </data>+ <data name="Dark" xml:space="preserve">+ <value>Dark</value>+ </data>+ <data name="DisplayName" xml:space="preserve">+ <value>Markdown Preview</value>+ </data>+ <data name="Input" xml:space="preserve">+ <value>Markdown</value>+ </data>+ <data name="Light" xml:space="preserve">+ <value>Light</value>+ </data>+ <data name="Output" xml:space="preserve">+ <value>Preview</value>+ </data>+ <data name="Theme" xml:space="preserve">+ <value>Theme</value>+ </data>+ <data name="ThemeDescription" xml:space="preserve">+ <value>Select which theme to use to preview the Markdown</value>+ </data>+</root>\ No newline at end of filediff --git a/src/dev/impl/DevToys/Themes/Custom.xaml b/src/dev/impl/DevToys/Themes/Custom.xamlindex f8779dc67..708702f10 100644--- a/src/dev/impl/DevToys/Themes/Custom.xaml+++ b/src/dev/impl/DevToys/Themes/Custom.xaml@@ -14,6 +14,7 @@<x:String x:Key="RegExToolProvider">M1.62 10a13.63 13.63 0 0 0 .45 3.51A13.39 13.39 0 0 0 3.4 16.7a.91.91 0 0 1 .1.27.41.41 0 0 1 0 .21.38.38 0 0 1-.1.15l-.14.11-.83.5a14.89 14.89 0 0 1-1.11-2 13.62 13.62 0 0 1-.74-2 13.22 13.22 0 0 1-.42-2 16.4 16.4 0 0 1 0-4.14 13.22 13.22 0 0 1 .42-2 13.84 13.84 0 0 1 .74-2A14.94 14.94 0 0 1 2.4 2l.83.51.14.11a.4.4 0 0 1 .1.15.41.41 0 0 1 0 .21.93.93 0 0 1-.1.27A13.6 13.6 0 0 0 1.62 10zM5 13.51a1.53 1.53 0 0 1 .11-.59 1.5 1.5 0 0 1 .31-.48 1.5 1.5 0 0 1 1.65-.32 1.51 1.51 0 0 1 .8.8 1.47 1.47 0 0 1 .12.59 1.46 1.46 0 0 1-.12.59 1.56 1.56 0 0 1-.32.48 1.46 1.46 0 0 1-.48.32 1.57 1.57 0 0 1-1.18 0 1.4 1.4 0 0 1-.47-.32A1.5 1.5 0 0 1 5 13.51zm10.8-4.72l-.54.94-1.75-1-.34-.23a1.38 1.38 0 0 1-.27-.26A1.84 1.84 0 0 1 13 9v2h-1V9a2.16 2.16 0 0 1 .12-.76 1.82 1.82 0 0 1-.58.48l-1.74 1-.54-.94 1.73-1a2.25 2.25 0 0 1 .75-.29 1.77 1.77 0 0 1-.75-.28L9.2 6.2l.54-.94 1.75 1 .33.24a1.64 1.64 0 0 1 .27.27A2 2 0 0 1 12 6V4h1v2a2.93 2.93 0 0 1 0 .4 1.36 1.36 0 0 1-.1.36 2.24 2.24 0 0 1 .59-.49l1.74-1 .54.94-1.73 1-.36.18a1.29 1.29 0 0 1-.36.1 2.11 2.11 0 0 1 .36.1 2 2 0 0 1 .36.19zM18.37 10a13.65 13.65 0 0 0-.45-3.51 13.81 13.81 0 0 0-1.32-3.27.93.93 0 0 1-.1-.27.45.45 0 0 1 0-.21.36.36 0 0 1 .1-.15l.14-.11.86-.48a15.54 15.54 0 0 1 1.1 2 13.79 13.79 0 0 1 .74 2 13.18 13.18 0 0 1 .42 2 16.16 16.16 0 0 1 .14 2 16.21 16.21 0 0 1-.13 2 13.18 13.18 0 0 1-.42 2 13.57 13.57 0 0 1-.74 2 15.49 15.49 0 0 1-1.1 2l-.84-.5-.14-.11a.35.35 0 0 1-.1-.15.44.44 0 0 1 0-.21.91.91 0 0 1 .1-.27 13.62 13.62 0 0 0 1.31-3.23 13.69 13.69 0 0 0 .43-3.53z</x:String><x:String x:Key="JsonYamlToolProvider">M 5 5 L 5 7 L 25 7 L 25 18.585938 L 23.707031 17.292969 L 22.292969 18.707031 L 26 22.414062 L 29.707031 18.707031 L 28.292969 17.292969 L 27 18.585938 L 27 5 L 5 5 z M 6 9.5859375 L 2.2929688 13.292969 L 3.7070312 14.707031 L 5 13.414062 L 5 27 L 27 27 L 27 25 L 7 25 L 7 13.414062 L 8.2929688 14.707031 L 9.7070312 13.292969 L 6 9.5859375 z M 11 11 L 11 13 L 21 13 L 21 11 L 11 11 z M 11 15 L 11 17 L 21 17 L 21 15 L 11 15 z M 11 19 L 11 21 L 18 21 L 18 19 L 11 19 z</x:String><x:String x:Key="JwtDecoderEncoderToolProvider">M 16.996 26.797 L 19.597 24.073 L 22.197 26.797 L 22.197 38.025 L 16.996 38.025 Z M 12.827 24.083 L 16.532 23.408 L 17.035 27.14 L 10.435 36.224 L 6.228 33.166 Z M 11.052 19.434 L 14.445 21.066 L 12.659 24.381 L 1.98 27.85 L 0.373 22.904 Z M 12.346 14.632 L 14.132 17.947 L 10.739 19.579 L 0.06 16.109 L 1.667 11.162 Z M 16.216 11.507 L 15.713 15.239 L 12.008 14.564 L 5.408 5.48 L 9.616 2.423 Z M 21.184 11.253 L 18.583 13.977 L 15.983 11.253 L 15.983 0.025 L 21.184 0.025 Z M 25.352 13.968 L 21.648 14.643 L 21.145 10.911 L 27.744 1.827 L 31.952 4.884 Z M 27.129 18.615 L 23.735 16.983 L 25.521 13.668 L 36.2 10.199 L 37.807 15.145 Z M 25.834 23.418 L 24.048 20.103 L 27.441 18.472 L 38.12 21.941 L 36.513 26.888 Z M 21.964 26.543 L 22.468 22.811 L 26.172 23.486 L 32.772 32.57 L 28.564 35.627 Z</x:String>+ <x:String x:Key="MarkdownPreviewToolProvider">M 7.5 10 C 4.4802259 10 2 12.480226 2 15.5 L 2 32.5 C 2 35.519774 4.4802259 38 7.5 38 L 40.5 38 C 43.519774 38 46 35.519774 46 32.5 L 46 15.5 C 46 12.480226 43.519774 10 40.5 10 L 7.5 10 z M 7.5 13 L 40.5 13 C 41.898226 13 43 14.101774 43 15.5 L 43 32.5 C 43 33.898226 41.898226 35 40.5 35 L 7.5 35 C 6.1017741 35 5 33.898226 5 32.5 L 5 15.5 C 5 14.101774 6.1017741 13 7.5 13 z M 11.667969 17 C 10.193969 17 9 18.193969 9 19.667969 L 9 29 C 9 30.105 9.895 31 11 31 C 12.105 31 13 30.105 13 29 L 13 21.714844 L 15.564453 25.1875 C 16.361453 26.2675 17.975344 26.271312 18.777344 25.195312 L 21 22.214844 L 21 29 C 21 30.105 21.895 31 23 31 C 24.105 31 25 30.105 25 29 L 25 19.667969 C 25 18.193969 23.806031 17 22.332031 17 C 21.438031 17 20.603375 17.447359 20.109375 18.193359 L 17.167969 22.847656 L 13.898438 18.105469 C 13.396437 17.411469 12.592328 17 11.736328 17 L 11.667969 17 z M 34 17 C 32.895 17 32 17.895 32 19 L 32 24 L 30.535156 24 C 29.232156 24 28.531906 25.528578 29.378906 26.517578 L 32.712891 30.408203 C 33.388891 31.197203 34.610109 31.197203 35.287109 30.408203 L 38.621094 26.517578 C 39.469094 25.528578 38.767844 24 37.464844 24 L 36 24 L 36 19 C 36 17.895 35.105 17 34 17 z</x:String><!-- From https://github.com/morning4coffe-dev/storylines --><Style x:Key="RightAlignedToggleSwitchStyle" TargetType="ToggleSwitch">diff --git a/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolProvider.cs b/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolProvider.csnew file mode 100644index 000000000..8ce993652--- /dev/null+++ b/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolProvider.cs@@ -0,0 +1,41 @@+#nullable enable++using DevToys.Api.Core.Injection;+using DevToys.Api.Tools;+using System.Composition;+using System.Text.RegularExpressions;++namespace DevToys.ViewModels.Tools.MarkdownPreview+{+ [Export(typeof(IToolProvider))]+ [Name("Markdown Preview")]+ [ProtocolName("markdown")]+ [Order(0)]+ [NotScrollable]+ internal sealed class MarkdownPreviewToolProvider : ToolProviderBase, IToolProvider+ {+ private static readonly Regex MarkdownLinkDetection = new Regex(@"\[[^]]+\]\(https?:\/\/\S+\)", RegexOptions.Compiled);++ private readonly IMefProvider _mefProvider;++ public string DisplayName => LanguageManager.Instance.MarkdownPreview.DisplayName;++ public object IconSource => CreatePathIconFromPath(nameof(MarkdownPreviewToolProvider));++ [ImportingConstructor]+ public MarkdownPreviewToolProvider(IMefProvider mefProvider)+ {+ _mefProvider = mefProvider;+ }++ public bool CanBeTreatedByTool(string data)+ {+ return MarkdownLinkDetection.IsMatch(data);+ }++ public IToolViewModel CreateTool()+ {+ return _mefProvider.Import<MarkdownPreviewToolViewModel>();+ }+ }+}diff --git a/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolViewModel.cs b/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolViewModel.csnew file mode 100644index 000000000..7ca8f09c2--- /dev/null+++ b/src/dev/impl/DevToys/ViewModels/Tools/MarkdownPreview/MarkdownPreviewToolViewModel.cs@@ -0,0 +1,135 @@+#nullable enable++using DevToys.Api.Core.Settings;+using DevToys.Api.Tools;+using DevToys.Core;+using DevToys.Core.Threading;+using DevToys.Messages;+using DevToys.Views.Tools.MarkdownPreview;+using Markdig;+using Microsoft.Toolkit.Mvvm.ComponentModel;+using Microsoft.Toolkit.Mvvm.Messaging;+using System;+using System.Collections.Generic;+using System.Composition;+using System.Threading.Tasks;+using Windows.Storage;+using Windows.UI.Xaml;++namespace DevToys.ViewModels.Tools.MarkdownPreview+{+ [Export(typeof(MarkdownPreviewToolViewModel))]+ public sealed class MarkdownPreviewToolViewModel : ObservableRecipient, IToolViewModel+ {+ private static string? _htmlDocument;++ private static readonly SettingDefinition<ApplicationTheme> ThemeSetting+ = new(+ name: $"{nameof(MarkdownPreviewToolViewModel)}.{nameof(ThemeSetting)}",+ isRoaming: true,+ defaultValue: ApplicationTheme.Light);++ private readonly Queue<string> _workQueue = new();++ private bool _workInProgress;+ private string? _inputValue;++ public Type View { get; } = typeof(MarkdownPreviewToolPage);++ internal MarkdownPreviewStrings Strings => LanguageManager.Instance.MarkdownPreview;++ /// <summary>+ /// Gets or sets the input text.+ /// </summary>+ internal string? InputValue+ {+ get => _inputValue;+ set+ {+ SetProperty(ref _inputValue, value);+ QueueWork();+ }+ }++ internal ApplicationTheme Theme+ {+ get => SettingsProvider.GetSetting(ThemeSetting);+ set+ {+ if (SettingsProvider.GetSetting(ThemeSetting) != value)+ {+ SettingsProvider.SetSetting(ThemeSetting, value);+ OnPropertyChanged();+ QueueWork();+ }+ }+ }++ internal ISettingsProvider SettingsProvider { get; }++ [ImportingConstructor]+ public MarkdownPreviewToolViewModel(ISettingsProvider settingsProvider)+ {+ SettingsProvider = settingsProvider;++ // Activate the view model's messenger.+ IsActive = true;++ QueueWork();+ }++ private void QueueWork()+ {+ _workQueue.Enqueue(InputValue ?? string.Empty);+ TreatQueueAsync().Forget();+ }++ private async Task TreatQueueAsync()+ {+ if (_workInProgress)+ {+ return;+ }++ _workInProgress = true;++ await TaskScheduler.Default;++ while (_workQueue.TryDequeue(out string text))+ {+ string html = await MarkdownToHtmlPageAsync(text, Theme);++ ThreadHelper.RunOnUIThreadAsync(() =>+ {+ Messenger.Send(new NavigateToMarkdownPreviewHtmlMessage(html));+ }).ForgetSafely();+ }++ _workInProgress = false;+ }++ internal async Task<string> MarkdownToHtmlPageAsync(string markdown, ApplicationTheme theme)+ {+ await TaskScheduler.Default;++ MarkdownPipeline pipeline = new MarkdownPipelineBuilder().UseEmojiAndSmiley().UseSmartyPants().UseAdvancedExtensions().Build();+ string htmlBody = Markdown.ToHtml(markdown, pipeline);++ if (string.IsNullOrEmpty(_htmlDocument))+ {+ StorageFile indexFile = await StorageFile.GetFileFromApplicationUriAsync(new Uri("ms-appx:///Assets/GitHubMarkdownCss/index.html"));+ _htmlDocument = await FileIO.ReadTextAsync(indexFile);+ }++ Assumes.NotNullOrEmpty(_htmlDocument, nameof(_htmlDocument));++ string htmlDocument+ = ((string)_htmlDocument!.Clone())+ .Replace("{{renderTheme}}", theme.ToString().ToLower())+ .Replace("{{backgroundColor}}", theme == ApplicationTheme.Dark ? "#0d1117" : "#ffffff")+ .Replace("{{htmlBody}}", htmlBody);++ return htmlDocument;+ }+ }+}diff --git a/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xaml b/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xamlnew file mode 100644index 000000000..7d0e24cdc--- /dev/null+++ b/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xaml@@ -0,0 +1,94 @@+<Page+ x:Class="DevToys.Views.Tools.MarkdownPreview.MarkdownPreviewToolPage"+ xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"+ xmlns:d="http://schemas.microsoft.com/expression/blend/2008"+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"+ xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"+ xmlns:winxaml="using:Windows.UI.Xaml"+ xmlns:controls="using:DevToys.UI.Controls"+ xmlns:toolkit="using:Microsoft.Toolkit.Uwp.UI.Controls"+ mc:Ignorable="d"+ NavigationCacheMode="Required">+ <Page.Resources>+ <winxaml:ApplicationTheme x:Key="Light">Light</winxaml:ApplicationTheme>+ <winxaml:ApplicationTheme x:Key="Dark">Dark</winxaml:ApplicationTheme>+ </Page.Resources>++ <Grid Margin="0,0,0,16" RowSpacing="12">+ <Grid.ChildrenTransitions>+ <TransitionCollection>+ <EntranceThemeTransition IsStaggeringEnabled="True" FromVerticalOffset="50"/>+ </TransitionCollection>+ </Grid.ChildrenTransitions>++ <Grid.RowDefinitions>+ <RowDefinition Height="Auto"/>+ <RowDefinition Height="*"/>+ </Grid.RowDefinitions>++ <StackPanel Grid.Row="0" Spacing="4" >+ <TextBlock Style="{StaticResource SubTitleTextBlock}" Text="{x:Bind ViewModel.Strings.Configuration}" />++ <controls:ExpandableSettingControl+ VerticalAlignment="Stretch"+ VerticalContentAlignment="Stretch"+ Title="{x:Bind ViewModel.Strings.Theme}"+ Description="{x:Bind ViewModel.Strings.ThemeDescription}">+ <controls:ExpandableSettingControl.Icon>+ <FontIcon Glyph="" />+ </controls:ExpandableSettingControl.Icon>+ <ComboBox+ SelectedValuePath="Tag"+ SelectedValue="{x:Bind ViewModel.Theme, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">+ <ComboBoxItem Tag="{StaticResource Light}" Content="{x:Bind ViewModel.Strings.Light}"/>+ <ComboBoxItem Tag="{StaticResource Dark}" Content="{x:Bind ViewModel.Strings.Dark}"/>+ </ComboBox>+ </controls:ExpandableSettingControl>+ </StackPanel>++ <Grid Grid.Row="1">+ <Grid.ColumnDefinitions>+ <ColumnDefinition MinWidth="100"/>+ <ColumnDefinition Width="16"/>+ <ColumnDefinition MinWidth="100"/>+ </Grid.ColumnDefinitions>++ <controls:CodeEditor+ Grid.Column="0"+ Header="{x:Bind ViewModel.Strings.Input}"+ SettingsProvider="{x:Bind ViewModel.SettingsProvider}"+ Text="{x:Bind ViewModel.InputValue, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"+ CodeLanguage="markdown"/>++ <toolkit:GridSplitter+ Grid.Column="1"+ Width="16"+ Margin="0,42,0,0"+ ResizeBehavior="BasedOnAlignment"+ ResizeDirection="Auto">+ <toolkit:GridSplitter.Element>+ <FontIcon+ Glyph="ﵕ"+ FontSize="13"/>+ </toolkit:GridSplitter.Element>+ </toolkit:GridSplitter>++ <toolkit:HeaderedContentControl+ Grid.Column="2"+ Header="{x:Bind ViewModel.Strings.Output}"+ Margin="0,16,0,0"+ HorizontalContentAlignment="Stretch"+ VerticalContentAlignment="Stretch">+ <Border+ CornerRadius="4"+ Margin="0,8,0,0"+ HorizontalAlignment="Stretch"+ VerticalAlignment="Stretch">+ <WebView+ x:Name="PreviewWebView"+ DefaultBackgroundColor="Transparent"/>+ </Border>+ </toolkit:HeaderedContentControl>+ </Grid>+ </Grid>+</Page>diff --git a/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xaml.cs b/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xaml.csnew file mode 100644index 000000000..7ecf8e81f--- /dev/null+++ b/src/dev/impl/DevToys/Views/Tools/MarkdownPreview/MarkdownPreviewToolPage.xaml.cs@@ -0,0 +1,69 @@+#nullable enable++using DevToys.Api.Core.Navigation;+using DevToys.Core;+using DevToys.Messages;+using DevToys.ViewModels.Tools.MarkdownPreview;+using Microsoft.Toolkit.Mvvm.Messaging;+using Windows.UI.Xaml;+using Windows.UI.Xaml.Controls;+using Windows.UI.Xaml.Navigation;++namespace DevToys.Views.Tools.MarkdownPreview+{+ /// <summary>+ /// An empty page that can be used on its own or navigated to within a Frame.+ /// </summary>+ public sealed partial class MarkdownPreviewToolPage : Page, IRecipient<NavigateToMarkdownPreviewHtmlMessage>+ {+ public static readonly DependencyProperty ViewModelProperty+ = DependencyProperty.Register(+ nameof(ViewModel),+ typeof(MarkdownPreviewToolViewModel),+ typeof(MarkdownPreviewToolPage),+ new PropertyMetadata(null));++ /// <summary>+ /// Gets the page's view model.+ /// </summary>+ public MarkdownPreviewToolViewModel ViewModel+ {+ get => (MarkdownPreviewToolViewModel)GetValue(ViewModelProperty);+ set => SetValue(ViewModelProperty, value);+ }++ public MarkdownPreviewToolPage()+ {+ InitializeComponent();++ // Register all recipient for messages+ WeakReferenceMessenger.Default.RegisterAll(this);+ }++ protected override void OnNavigatedTo(NavigationEventArgs e)+ {+ var parameters = (NavigationParameter)e.Parameter;++ if (ViewModel is null)+ {+ // Set the view model+ Assumes.NotNull(parameters.ViewModel, nameof(parameters.ViewModel));+ ViewModel = (MarkdownPreviewToolViewModel)parameters.ViewModel!;+ DataContext = ViewModel;+ }++ if (!string.IsNullOrWhiteSpace(parameters.ClipBoardContent))+ {+ ViewModel.InputValue = parameters.ClipBoardContent;+ }++ base.OnNavigatedTo(e);+ }++ public void Receive(NavigateToMarkdownPreviewHtmlMessage message)+ {+ Arguments.NotNull(message, nameof(message));+ PreviewWebView.NavigateToString(message.Html);+ }+ }+}