-
Notifications
You must be signed in to change notification settings - Fork 331
CSV embed using wiki-link transclusion format #1287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
|
|
@@ -161,7 +161,44 @@ describe("micromark-extension-wiki-link", () => { | |||||
| '<p><img src="My Image.jpg" alt="My Image.jpg" class="internal" width="200" height="200" /></p>' | ||||||
| ); | ||||||
| }); | ||||||
|
|
||||||
| // CSV tests | ||||||
| test("parses a CSV file embed of supported file format", () => { | ||||||
| const serialized = micromark("![[data.csv]]", "ascii", { | ||||||
| extensions: [syntax()], | ||||||
| htmlExtensions: [html() as any], // TODO type fix | ||||||
| }); | ||||||
| expect(serialized).toBe( | ||||||
| '<p><a href="data.csv" class="internal new" download="data.csv">data.csv</a></p>' | ||||||
| ); | ||||||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is it a regular a tag and not FlatUiTable? Isn't it the aim of this PR? |
||||||
| }); | ||||||
|
|
||||||
| test("parses a CSV file embed of unsupported file format", () => { | ||||||
|
||||||
| test("parses a CSV file embed of unsupported file format", () => { | |
| test("leaves a CSV file embed of unsupported file format as plain text", () => { |
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, why does it include a regular a tag?
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
???
If anything, alias should be used as table title. But I think you can just ignore it for now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is already covered by the test with the same title above.