From 70498d7bbe37dc4ca1c900216f4a0ba66e904000 Mon Sep 17 00:00:00 2001 From: "Timothy J. Baek" Date: Sun, 3 Nov 2024 14:09:57 -0800 Subject: [PATCH] enh: export table as csv Co-Authored-By: Muhammad Afzaal --- .../Messages/Markdown/MarkdownTokens.svelte | 121 ++++++++++++++---- 1 file changed, 93 insertions(+), 28 deletions(-) diff --git a/src/lib/components/chat/Messages/Markdown/MarkdownTokens.svelte b/src/lib/components/chat/Messages/Markdown/MarkdownTokens.svelte index 7fc61c327..ca0737c58 100644 --- a/src/lib/components/chat/Messages/Markdown/MarkdownTokens.svelte +++ b/src/lib/components/chat/Messages/Markdown/MarkdownTokens.svelte @@ -1,6 +1,11 @@ @@ -55,35 +87,68 @@ {token.text} {/if} {:else if token.type === 'table'} -
- - - - {#each token.header as header, headerIdx} - - {/each} - - - - {#each token.rows as row, rowIdx} - - {#each row ?? [] as cell, cellIdx} - +
+
+
- -
- -
+ + + {#each token.header as header, headerIdx} + {/each} - {/each} - -
+
+ +
+
+ + + {#each token.rows as row, rowIdx} + + {#each row ?? [] as cell, cellIdx} + +
+ +
+ + {/each} + + {/each} + + +
+ + {:else if token.type === 'blockquote'}