Page 1 of 1
Treat element as xi:include
Posted: Sun Oct 08, 2023 3:42 am
by LeeHart
We'd like to have an element treated as `xi:include`, loading the file in the `href` attribute as text.
Is this currently supported? I browsed the docs but didn't see this.
I thought that in the CSS, `content : attr(href) ;` might work but it doesn't. If i add `-oxy-link : attr(href);` then clicking the href value in Author mode opens the referenced file, so I know the appropriate catalogs are set up.
Thanks,
Lee
Re: Treat element as xi:include
Posted: Mon Oct 09, 2023 7:49 am
by Radu
Hi Lee,
This cannot be easily done using just CSS. You would need to implement one of our Java based APIs to make this work.
https://www.oxygenxml.com/InstData/Edit ... olver.html
If you are a Java developer or have a Java developer willing to work on an Oxygen framework Java extension we could try to help with advice along the way.
Regards,
Radu
Re: Treat element as xi:include
Posted: Tue Oct 10, 2023 6:11 am
by LeeHart
Thanks. I'm fairly new to Java development (just a few projects), but I have many years of experience working with CSS and XSLT.
I see an implementation of that class for the DITA-OT project files (ro/sync/ecss/extensions/dita/DOTProjectAuthorReferenceResolver.java) - is that a reasonable start?
Lee
Re: Treat element as xi:include
Posted: Tue Oct 10, 2023 8:21 am
by Radu
Hi Lee,
Right, the DOTProjectAuthorReferenceResolver is a very simple example of a references resolver.
There is also a bit of documentation for implementing a references resolver as well:
https://www.oxygenxml.com/doc/versions/ ... olver.html
Regards,
Radu