xwikisas / xwiki-pro-macros

XWiki rendering macros useful when migrating content from Confluence
GNU Lesser General Public License v2.1
3 stars 12 forks source link

Improve display of view-file macro #239 #256

Closed ChiuchiuSorin closed 5 months ago

ChiuchiuSorin commented 6 months ago

239

Created modals and custom box macro to better display the files used with the view-files macro.

trrenty commented 5 months ago

I also think that it would be more intuitive to have something more stylized than a simple link. I think its not expected to have a link that opens a modal.

Maybe something like this: image

Ofc this is subject to discussion. Maybe @snazare could give her opinion as well. And u, @ChiuchiuSorin , ofc :P

snazare commented 5 months ago

Hi :) Indeed @trrenty I agree that it would be good to style the link as suggested. When clicking on an attachment link usually the user expects the file to download. However, considering the fact that:

  1. you can download the file from the attachments section
  2. users coming from Confluence will expect the same behaviour as in Confluence - to open the file in a modal box when clicking on the thumbnail

I would keep the behaviour of opening the file in a modal when clicking on the styled link.

ChiuchiuSorin commented 5 months ago

Tried two thumbnail styles, I added for both of them a file type specific icon: Style 1, using XWiki button wrapper: style1 Style 2, using bootstrap default: style2 I left only those files that are not supported by office macro or pdf to be displayed as a hyperlink (as you can see in the images) Personally, I'd prefer the first option, as it is more visible and it adapts the aspect depending on the used skin WDYT @snazare and @trrenty ?

snazare commented 5 months ago

Hi @ChiuchiuSorin I agree, let's go with the XWiki button so that it follows the look&feel defined in the instance. Nice touch on the icons :).