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

Transfer more information from Confluence import data to DITA to allow powerfull custom XSLT post processing #56

Open
SanFanDocu opened this issue Apr 18, 2023 · 1 comment

Comments

@SanFanDocu
Copy link

It seems, there is no way to customize the Confluence to DITA import.
Maybe it would be possible to pass more information to the DITA output.
This would help to develop custom XSLT post processing.

Todo

  • Pass div elements from HTML to DITA.
  • Translate span elements into e.g. data or unknown elements
  • Transform @Class attributes into e.g. @base in DITA.

Here is an example of a Confluence export HTML fragment containig a notice block:

     <div class="confluence-information-macro confluence-information-macro-note">
              <span class="aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon"></span>
              <div class="confluence-information-macro-body">
                    <p>Service may only be carried out by technicians trained by manufacturer!</p>
               </div>
      </div>        

the current generated DITA output looks like this

      <p>Service may only be carried out by technicians trained by manufacturer!</p>

if the importer would keep as much information, structure and metadata as possible like the following...

      <div base="confluence-information-macro confluence-information-macro-note">
                 <unknown base="aui-icon aui-icon-small aui-iconfont-warning confluence-information-macro-icon"></unknown>
                  <div base="confluence-information-macro-body">
                        <p>Service may only be carried out by technicians trained by manufacturer!</p>
                  </div>
      </div>

... the customer has all information required to build a individual XSLT post processing output like this:

     <note type="warning">
              <p>Service may only be carried out by technicians trained by manufacturer!</p>   
     </note>                                   
@DunaMariusCosmin
Copy link
Collaborator

Hi,
Thank you for your feedback.
I registered an internal issue for adding an option for controlling the preservation of information from the class attribute.
I will update this thread when we manage to implement this in a future release.

Best regards,
Cosmin

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

2 participants