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

Add tables directly form Pwndoc #355

Open
durantthibault opened this issue Aug 26, 2022 · 10 comments
Open

Add tables directly form Pwndoc #355

durantthibault opened this issue Aug 26, 2022 · 10 comments

Comments

@durantthibault
Copy link

Hello,

I would like to know if it was possible to add tables directly form pwndoc.

I am using word to finalize reports and i need to create tables from word to add some informations after the report generation. Therefore my question is to know if it would be possible to add the possibility to create tables directly from the "editor" field of pwndoc.

Please do not hesitate If you have any information that could be help me.

Thanks by advance for your help.

Thibault Durant

@yeln4ts
Copy link
Contributor

yeln4ts commented Aug 29, 2022

Hello, it's not possible for now but should be added in the future

@nitek29
Copy link

nitek29 commented Sep 1, 2022

Salut @durantthibault,

To do this, the Pwndoc editor library needs to be updated to tiptapV2 and update the backend/src/lib/html2ooxml.js too.
Currently, I have the ability to add a table from the editor but I don't know how to properly modify the html2ooxml.js file to take into account the HTML table tag.

@yeln4ts Do you know how I can add table with the html2ooxml.js ?

@unmotivatedgene
Copy link

unmotivatedgene commented Oct 20, 2022

@nitek29 Can you make a fork with the new table frontend and I'll try to get the backend working?

Also i'm not sure why we'd have to go to the v2 beta, looks like you can do tables in v1
https://codesandbox.io/s/fytkc?file=/src/pages/Index.vue:2064-2070

@nitek29
Copy link

nitek29 commented Oct 24, 2022

@unmotivatedgene Currently tables work on my backend & frontend but I use TiptapV2

@RobertDoc
Copy link

@nitek29 could you make a fork with those changes or a PR?

@nitek29
Copy link

nitek29 commented Nov 30, 2022

Sorry for the delay.
After reviewing my code, I correct my previous post. The frontend has the table functionality based on TiptapV2 but the backend translates the HTML table tag into a docx bordered paragraph.
I don't remember why I used the bordered paragraph instead of the table.

A fork is on my git.

@Zeecka
Copy link
Collaborator

Zeecka commented Nov 30, 2022

Impressive work. This may need more test before merging. Here is 2 bugs I spotted:

  • Drag & Drop doesn't work anymore
  • Leaving a finding and getting back to it will display raw html

image

@RobertDoc
Copy link

This would be amazing to get into the main branch. Thanks for posting your fork @nitek29!

@nitek29
Copy link

nitek29 commented Dec 1, 2022

@Zeecka
My bad ! For the second point, I forgot a file.
I updated my git :)

(to write under the table, you must use the bottom arrow inside the table)

@nitek29
Copy link

nitek29 commented Dec 1, 2022

@Zeecka thanks for your feedback. The 2 bugs are now fixed :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants