How to make profile picture clickable?

Dominik L Posted in General Discussion 2 months ago

I want that the profile picture is clickable so you can expand it for better view

how can I achieve that?

Replies
us Allon Prooit Replied 2 months ago

Same kind of coding in the ossnProfile component would suffice. Looks like you want a javascript fly out, right!
Html...

<button id="myButton">Hover me</button>
<div id="myFlyout">
This is the flyout content.</div>

Css...
//#myFlyout {
display: none; /* Hide the flyout initially */
position: absolute;
background-color: white;
border: 1px solid black;
padding: 10px;
}
Javascript...
const button = document.getElementById('myButton');
const flyout = document.getElementById('myFlyout');

button.addEventListener('mouseover', () => {
flyout.style.display = 'block';
});

button.addEventListener('mouseout', () => {
flyout.style.display = 'none';
});

That should do it up nice!

German Dominik L Replied 2 months ago

@Allon, thanks but thats what I meant.

I mean to make the profile picture expandable, you open the profile, click on the picture and it expands

Dutch Eric redegeld Replied 2 months ago

https://nlsociaal.nl/u/redegelde

Good one, like that to.
maybe editing the module Fancybox 2.4 its now for the newsfeeds and group active.

https://www.opensource-socialnetwork.org/component/view/369/fancybox