From 6a84511b1b17001c61b1be3896b47792573c513d Mon Sep 17 00:00:00 2001 From: Arpita-Jaiswal Date: Wed, 9 Oct 2024 10:28:38 +0530 Subject: [PATCH 1/2] Fix: markdown strikethrough syntax support. --- ftd/ftd-js.css | 4 ++++ ftd/t/js/01-basic.ftd | 2 ++ ftd/t/js/01-basic.html | 4 +++- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ftd/ftd-js.css b/ftd/ftd-js.css index ff39a1d267..736ff82a79 100644 --- a/ftd/ftd-js.css +++ b/ftd/ftd-js.css @@ -61,6 +61,10 @@ table { width: auto; } +del { + text-decoration: line-through !important; +} + *, pre, div { padding: 0; margin: 0; diff --git a/ftd/t/js/01-basic.ftd b/ftd/t/js/01-basic.ftd index 256a5c8d66..2f99094c0a 100644 --- a/ftd/t/js/01-basic.ftd +++ b/ftd/t/js/01-basic.ftd @@ -10,6 +10,8 @@ background.solid: $inherited.colors.background.step-1 -- ftd.text: Hello background.solid: $bg-og +-- ftd.text: This ~~sentence is grammatically wrong~~, correct it. + -- ftd.color bg-og: light: yellow dark: green diff --git a/ftd/t/js/01-basic.html b/ftd/t/js/01-basic.html index 7866c84bf4..483e2ee1d0 100644 --- a/ftd/t/js/01-basic.html +++ b/ftd/t/js/01-basic.html @@ -18,7 +18,7 @@ -
"Hello"
Hello
Hello
- + @@ -84,6 +84,15 @@ width: auto; } +/** +This is needed since the global css makes `text-decoration: none`. +To ensure that the del element's `text-decoration: line-through` is applied, +we need to add `!important` to the rule +**/ +del { + text-decoration: line-through !important; +} + *, pre, div { padding: 0; margin: 0; @@ -405,483 +414,158 @@ .__cur-59 { cursor: pointer; } .__w-60 { width: 30px; }