From d1964f6219b4193090f855542cd52d9fe6ea5be8 Mon Sep 17 00:00:00 2001 From: muratcesmecioglu Date: Thu, 7 Apr 2022 13:45:50 +0300 Subject: [PATCH 1/3] Whatsapp Monospace Font Adds comment style for whatsapp monospace font. --- README.md | 14 ++++++++++++++ assets/js/script.js | 4 ++++ index.html | 1 + 3 files changed, 19 insertions(+) diff --git a/README.md b/README.md index 16edb79..c0633d0 100644 --- a/README.md +++ b/README.md @@ -212,6 +212,20 @@ Press **Create Table** to get something like: |} ``` +### Whatsapp monospace font + +```` +``` ++----------------------------------+---------+------------------------+----------------+ +| Col1 | Col2 | Col3 | Numeric Column | ++----------------------------------+---------+------------------------+----------------+ +| Value 1 | Value 2 | 123 | 10.0 | +| Separate | cols | with a tab or 4 spaces | -2,027.1 | +| This is a row with only one cell | | | | ++----------------------------------+---------+------------------------+----------------+ +``` +```` + ### Or even a boring html <table> Leading characters can be added by selecting a comment style: diff --git a/assets/js/script.js b/assets/js/script.js index 28b289f..ac95547 100644 --- a/assets/js/script.js +++ b/assets/js/script.js @@ -181,6 +181,10 @@ function createTable() { prefix = "|"; suffix = "|"; break; + case "whatsapp": + commentbefore = "```"; + commentafter = "```"; + break; default: break; } diff --git a/index.html b/index.html index 4f4ca81..d471e80 100644 --- a/index.html +++ b/index.html @@ -110,6 +110,7 @@

Input

+ From 00322267dd63e5688036593caf5a16eb1a9c1ede Mon Sep 17 00:00:00 2001 From: muratcesmecioglu Date: Thu, 7 Apr 2022 15:22:44 +0300 Subject: [PATCH 2/3] Update README.md --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index c0633d0..dcba082 100644 --- a/README.md +++ b/README.md @@ -245,6 +245,7 @@ Leading characters can be added by selecting a comment style: | exclamation | "! " | Fortran 90 | | slantsplat | "/* ... */ " | CSS | | xml | "<!-- ... -->" | XML | +| whatsapp | "```" | Whatsapp monospace font | ## License From d60b086cc198f513e8d73b85eb5aa61d71ff41f4 Mon Sep 17 00:00:00 2001 From: muratcesmecioglu Date: Mon, 11 Apr 2022 15:17:48 +0300 Subject: [PATCH 3/3] Name changes --- README.md | 34 +++++++++++++++++----------------- assets/js/script.js | 2 +- index.html | 2 +- 3 files changed, 19 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index dcba082..1b422aa 100644 --- a/README.md +++ b/README.md @@ -212,7 +212,7 @@ Press **Create Table** to get something like: |} ``` -### Whatsapp monospace font +### ASCII table (inside Github code block) ```` ``` @@ -230,22 +230,22 @@ Press **Create Table** to get something like: Leading characters can be added by selecting a comment style: -| Style | Characters | Usage | -|-------------|----------------------------------|--------------------------------------| -| none | "" | no comment style applied | -| doubleslant | "// " | C++/C#/F#/Java/JavaScript/Rust/Swift | -| hash | "# " | Perl/PowerShell/Python/R/Ruby | -| doubledash | "-- " | ada/AppleScript/Haskell/Lua/SQL | -| percent | "% " | MATLAB | -| singlespace | " " (1 space) | MediaWiki | -| quadspace | "    " (4 spaces) | reddit | -| singlequote | "' " (single quote) | VBA | -| rem | "REM " | BASIC/DOS batch file | -| c | "C " | Fortran IV | -| exclamation | "! " | Fortran 90 | -| slantsplat | "/* ... */ " | CSS | -| xml | "<!-- ... -->" | XML | -| whatsapp | "```" | Whatsapp monospace font | +| Style | Characters | Usage | +|-------------------|----------------------------------|--------------------------------------| +| none | "" | no comment style applied | +| doubleslant | "// " | C++/C#/F#/Java/JavaScript/Rust/Swift | +| hash | "# " | Perl/PowerShell/Python/R/Ruby | +| doubledash | "-- " | ada/AppleScript/Haskell/Lua/SQL | +| percent | "% " | MATLAB | +| singlespace | " " (1 space) | MediaWiki | +| quadspace | "    " (4 spaces) | reddit | +| singlequote | "' " (single quote) | VBA | +| rem | "REM " | BASIC/DOS batch file | +| c | "C " | Fortran IV | +| exclamation | "! " | Fortran 90 | +| slantsplat | "/* ... */ " | CSS | +| xml | "<!-- ... -->" | XML | +| triplebacktick | "```" | Github code block/Whatsapp table | ## License diff --git a/assets/js/script.js b/assets/js/script.js index ac95547..1a113b0 100644 --- a/assets/js/script.js +++ b/assets/js/script.js @@ -181,7 +181,7 @@ function createTable() { prefix = "|"; suffix = "|"; break; - case "whatsapp": + case "triplebacktick": commentbefore = "```"; commentafter = "```"; break; diff --git a/index.html b/index.html index d471e80..329d37f 100644 --- a/index.html +++ b/index.html @@ -110,7 +110,7 @@

Input

- +