Fa-icon tooltips in profile menu

51 views
Skip to first unread message

Markus Stetschnig

unread,
Mar 20, 2021, 4:33:07 PM3/20/21
to Sakai Development
Hey!

I am working on replacing the Silk Icons with the Fontawsome ones in the
profile menu tooltips.

1) The path to the Silk icons is stored in the ProfileConstants.java
(e.g. INFO_IMAGE) file. I added another one to store the css class name
for the Fontawsome icon. When building with maven in sakai/profile2 the
new varibable INFO_ICON is not set (see no_INFO_ICON.png) and maven
complains (see build_fail.png).

My workaround was to rebuild the entire project, which takes forever on
my Core2Duo...

Is there a maven goal to specify or something, so this ProfileConstants
file gets compiled? I am wondering why there is this behavior and I
would be glad to know.

2) I was thinking it might be a good idea to use Bootstraps tooltips
instead of the qTip2 ones. I was trying that out for a bit but i did not
get it to work so far (i used
profile2/tool/src/webapp/javascript/profile2.js for the JS part). Do you
think it is a good idea to work on that? Or the use Bootstraps popups
instead maybe?

The changes I am doing are at
https://github.com/stetsche/sakai/tree/newtooltipicons

Thanks!

Markus

build_fail.png
no_INFO_ICON.png

Michael Greene II

unread,
Mar 22, 2021, 11:05:53 AM3/22/21
to Markus Stetschnig, Sakai Development
Markus, I'm generally in favor of using and reusing font awesome vs adding images for icons. I did some work in along these lines profile2 earlier this year to get it working with dark mode for the 21 release https://github.com/sakaiproject/sakai/pull/8956/commits/e9932f32352db6eb4f93c9e6d3fe459c7eb459c9

I wouldn't add embedded styles like this https://github.com/sakaiproject/sakai/compare/master...stetsche:newtooltipicons#diff-8dacfe602ed5d890ea062bf7c8d5eb4e9d03890d5bfe636f65a293766ea89c98R30-R41 unless you absolutely had to. There should be a CSS Class you can leverage from the library project to accomplish your goals. If not, then we should add it in library vs defining it in the tool in my opinion.

I haven't worked with qTip2 much yet to form an opinion on it vs Bootstrap tooltips. We're working to create the necessary components independent of a framework but we haven't done tooltips yet.



From: saka...@apereo.org <saka...@apereo.org> on behalf of Markus Stetschnig <d...@stetschom.at>
Sent: Saturday, March 20, 2021 4:33 PM
To: Sakai Development <saka...@apereo.org>
Subject: [sakai-dev] Fa-icon tooltips in profile menu
 

Markus Stetschnig

unread,
Mar 22, 2021, 2:57:49 PM3/22/21
to saka...@apereo.org

I was missing a dark mode! I am wondering why i can't find it on nightly servers. Shouldn't it be at Preferences > Colors?


I wouldn't add embedded styles like this...
Yes I was thinking about too. My plan was to change as little as possible of  the original code until the adapted version works well. Having the css this way shouldn't be necessary.


I don't have much experience with qTip too, but i have seen qTip2 is deprecated and i think Bootstrap is integrated a lot in Sakai.

Sam Ottenhoff

unread,
Mar 22, 2021, 3:05:34 PM3/22/21
to Markus Stetschnig, sakai-dev
Replacing qTip2 with Bootstrap tooltips or popups makes a lot of sense to me.

Reply all
Reply to author
Forward
0 new messages