In some of our larger manuals, we need to be able to use multiple variable (keydef) maps: some with text keydefs and some with image keydefs (or a mix of both types of keydefs in the same variable map file).
Currently, as long as the keydefs are text only, we can have variable maps inserted into our primary map, and the variable/keys generate without any problems. Image keydefs must be placed outside of variable maps and inside the primary map to generate the output correctly.
Is there any way to be able to have variable/keydef map files that include both the image keydefs and text keydef?
AEM Guides (UUID) v4.2 On-Prem Installation (late April/early May 2023)
AEM 6.5.15 On-Prem Installation
Views
Replies
Total Likes
Hi @sschnelbach
Attached is the sample package containing variable/keydef map with both image and text keydefs, which has been inserted into the primary map. Please try and let us know if it meets your requirements.
Note: Upload the package directly from Assets UI and extract its content to a folder using 'Extract Archive' option.
I need to investigate further. When I originally ran into this problem, any image variable defined within a keydef map was outputting as a blank square.
Today, the text keydef maps AND image keydefs maps are all generating PDF outputs perfectly. I have two text keydef maps and one image keydef map -- all working now in my test maps and topics.
Are there any background tasks within either AEM or AEM Guides that would affect performance like this? Or, as we sometimes see, images that generate in the PDF (Native PDF Publishing) as unusably pixelated, but if I wait a few minutes and generate another PDF, the image will be crisp and clear?
From what you described I think following explanation may help:
I am still open to understand what happened in the other scenario where the images were shown as blank square. Is that still happening? Please also share the image format (png, jpg, svg or any other) you are using to test this?
I'm seeing inconsistent behavior regarding image and text keydef maps vs inserting the keydefs directly into the map.
I've tested using more than one text keydef map with one image keydef map and this works great... for some maps. For other maps, the only way to get the image keydefs to appear in the PDF is to insert the keydefs directly into the map instead of using a keydef map. For some maps, I can combine the text and image keydefs into a single map and for other maps, the text and image keydefs had to be in separate maps to work.
The behavior is weirdly inconsistent.
For most tests, the images are all SVGs. I did have one PNG I was using in my sandbox test, but most images were SVGs.
I'm uploading a sample map (Sandbox Map for Testing) with the Installation sub-map inserted into the primary map. For this specific example (Sandbox Map for Testing), the image variables render correction when all the keydefs are defined at the primary map level.
For another map (Q4X Discrete Laser Sensor, not included in this ZIP file) with the Installation sub-map inserted, the image keydefs render correctly when the image keydefs and text keydefs are defined in their own (separate) maps (which are also uploaded here for you to see).