Skip to content
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

Multiple lines table support #305

Closed
rickywu opened this issue Sep 29, 2018 · 10 comments
Closed

Multiple lines table support #305

rickywu opened this issue Sep 29, 2018 · 10 comments
Labels
Category: Table inactive Need Discussion Need discussion or investigation

Comments

@rickywu
Copy link

rickywu commented Sep 29, 2018

I use pandoc convert docx to markdown and use multiple line tables
But tui.editor seems don't support this feature

Pandoc output

+--------------+----------------------+
| **A**        | **B**                |
+==============+======================+
| 1            | multiple line tables |
|              | multiple line tables |
+--------------+----------------------+


Manually formatted for tui.editor

|--------------|----------------------|
| **A**        | **B**                |
|--------------|----------------------|
| 1            | multiple line tables |
|              | multiple line tables |
|--------------|----------------------|

tui.editor shows

multi

Can you support pandoc's output?

@rickywu
Copy link
Author

rickywu commented Mar 21, 2019

Any update or anything I can help for this? thanks!

@rickywu
Copy link
Author

rickywu commented Mar 27, 2019

I found that all multiline tables copy to Excel and then copy to WYSIWYG mode, it works well

I think about use python to extract table in docx and convert to Excel format after that implement paste function then no need tui.editor support pandoc multi line table, any adivce or you can tell me how implement paste function.

@sohee-lee7
Copy link
Contributor

sohee-lee7 commented Mar 28, 2019

If you make a multiline table in Wysiwyg like it, the line breaks are changed to <br> when change to Markdown.
image -> image

If you make a line break in table of Markdown, you should use <br>.

Pandoc's ouput is not standard in GFM(https://github.github.com/gfm/) so below table is not rendered properly.
|--------------|----------------------|
| A | B |
|--------------|----------------------|
| 1 | multiple line tables |
| | multiple line tables |
|--------------|----------------------|

We follow GFM so your suggestion about support multiline in table need to discussion with our team.
And paste logic in Wysiwyg use html tag of clipboard data. That's why multiline table is pasted in the Wysiwyg.

@rickywu
Copy link
Author

rickywu commented Mar 28, 2019

I found pandoc gfm.docx -f docx -t gfm support gfm with limited extensions and multiline table works well in tui editor but except multi line table header

This is pandoc gfm format output table header

<table>
<thead>
<tr class="header">
<th>交易卡类</th>
<th>发卡与收单</th>
<th>商户净计金额入账方式</th>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr class="odd">
<td></td>
<td></td>
<td>当日逐笔实时</td>
<td>次日对账后批量</td>
<td>手动入账</td>
</tr>
...

tui editor render as:
image

word render as:
image

If this problem solved then could be perfect, thanks.

@stale
Copy link

stale bot commented Dec 21, 2019

This issue has been automatically marked as inactive because there hasn’t been much going on it lately. It is going to be closed after 7 days. Thanks!

@stale stale bot added the inactive label Dec 21, 2019
@rickywu
Copy link
Author

rickywu commented Dec 23, 2019

Is that possible to support pandoc output?

@stale
Copy link

stale bot commented Jan 22, 2020

This issue has been automatically marked as inactive because there hasn’t been much going on it lately. It is going to be closed after 7 days. Thanks!

@stale stale bot added the inactive label Jan 22, 2020
@rickywu
Copy link
Author

rickywu commented Jan 22, 2020

@seonim-ryu Any update for this issue?

@stale stale bot removed the inactive label Jan 22, 2020
@stale
Copy link

stale bot commented Feb 21, 2020

This issue has been automatically marked as inactive because there hasn’t been much going on it lately. It is going to be closed after 7 days. Thanks!

@stale stale bot added the inactive label Feb 21, 2020
@rickywu
Copy link
Author

rickywu commented Feb 22, 2020

Pandoc not support column span jgm/pandoc#1024, so close it

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category: Table inactive Need Discussion Need discussion or investigation
Projects
None yet
Development

No branches or pull requests

3 participants