Search…

X3 Photo Gallery Support Forums

Search…
 
Kat
Experienced
Topic Author
Posts: 45
Joined: 26 Sep 2016, 10:46

Footer button up

27 Jul 2017, 11:23

Hello Karl,

Is there is a way to add a button "up" for a gallery,  in a sidebar layout like in topbar layout ?

Also did you considered a "load more" or pagination for long gallery ?

Thank's 
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13997
Joined: 30 Sep 2006, 03:37

Re: Footer button up

28 Jul 2017, 00:21

Kat wrote:Is there is a way to add a button "up" for a gallery,  in a sidebar layout like in topbar layout ?
Good observation. I will add this to next release ... Until then, it would have to be custom javascript + CSS.
Kat wrote:Also did you considered a "load more" or pagination for long gallery ?
Yes, but I'm not convinced. X3 already loads images only once they are scrolled into view, and I don't really see how "load more" will offer any benefits. Sounds like "I want to scroll to the footer of page without having to load all images", which in itself is not a logical requirement. Pagination is a bit of an outdated concept, and would require page URL's to reflect upon this, for example /gallery/holidays/{page-number}/ (bad for SEO, URL referencing and caching concepts).

All in all, there may be a few arguments to consider "load more", but there are also many CONS.
 
Kat
Experienced
Topic Author
Posts: 45
Joined: 26 Sep 2016, 10:46

Re: Footer button up

28 Jul 2017, 06:28

mjau-mjau wrote: Good observation. I will add this to next release ... Until then, it would have to be custom javascript + CSS.
Thank you for that ! In the meantime can you please help me to implement custom javascript and  css and in which module to add the css tag ?
Not sure it's right thing to do and what next ?
Code
.footerup {
    position: absolute;
    width: 100%;
    top: 0;
} 
.footerup button {
    color: inherit;
    border-radius: 0 0 60px 60px;
    height: 30px;
    width: 60px;
    font-size: 1.6em;
    padding-bottom: 5px;
    background-color: #151b1e;
}
mjau-mjau wrote: All in all, there may be a few arguments to consider "load more", but there are also many CONS.
I understand. I already asked this in "new feature" and here something similar was asked https://forum.photo.gallery/viewtopic.php?f=57&t=9142
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13997
Joined: 30 Sep 2006, 03:37

Re: Footer button up

28 Jul 2017, 12:37

Kat wrote:In the meantime can you please help me to implement custom javascript and  css and in which module to add the css tag ?
Not sure it's right thing to do and what next ?
Code
.footerup {
    position: absolute;
    width: 100%;
    top: 0;
} 
.footerup button {
    color: inherit;
    border-radius: 0 0 60px 60px;
    height: 30px;
    width: 60px;
    font-size: 1.6em;
    padding-bottom: 5px;
    background-color: #151b1e;
}
Where did you get this code? Did you somehow add the html also? If it already displays a fixed button to your liking, then we can work with that. It would be a simple fix, as I don't have resources to write a dedicated custom "scroll to top" plugin per forum request, which would need 1. Custom HTML injected, 2. Custom CSS to fix the button to a specific location and 3. Javascript to target the button and cause a scroll-to-top on click, and 4. Ultimately it should exhibit smart behavior to not scroll to top if it's already almost at top.
 
Kat
Experienced
Topic Author
Posts: 45
Joined: 26 Sep 2016, 10:46

Re: Footer button up

28 Jul 2017, 19:03

mjau-mjau wrote:Where did you get this code? Did you somehow add the html also? If it already displays a fixed button to your liking, then we can work with that. It would be a simple fix, as I don't have resources to write a dedicated custom "scroll to top" plugin per forum request, which would need 1. Custom HTML injected, 2. Custom CSS to fix the button to a specific location and 3. Javascript to target the button and cause a scroll-to-top on click, and 4. Ultimately it should exhibit smart behavior to not scroll to top if it's already almost at top.
I inspected the html code from a topbar layout page which is
Code
<div class="up">
<button style="display: inline-block;">::before</button>
</div>
and wanted adapt a custom css. But i don't know how and where to add this html to display the button. I understand that you can't write a dedicated custom code.

Thank you anyway for your answer.  I will wait your next update and hopefully find this feature for the sidebar layout as well.
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13997
Joined: 30 Sep 2006, 03:37

Re: Footer button up

28 Jul 2017, 23:43

Thanks, I think better wait until next update ... The scroll-button for topbar layout is attached to footer, so for sidebar layouts, it will have to be re-designed so to speak and implemented into the templates. I would probably just create a small half-circle "up" button attached to the very bottom of page.

I could create a separate "scroll-to-top plugin" similar to the one used in control panel. The button itself is fixed bottom right (always visible on page, unless scroll position is at top), but I am not sure this is necessary.
 
Kat
Experienced
Topic Author
Posts: 45
Joined: 26 Sep 2016, 10:46

Re: Footer button up

29 Jul 2017, 09:12

mjau-mjau wrote:I would probably just create a small half-circle "up" button attached to the very bottom of page.
I give my vote for this cleaner solution, without the distraction of the fixed bottom right always visible
mjau-mjau wrote: The button itself is fixed bottom right (always visible on page, unless scroll position is at top), but I am not sure this is necessary.
I agree with you that this is not necessary 

Thank you in advance Karl
 
User avatar
mjau-mjau
X3 Wizard
Posts: 13997
Joined: 30 Sep 2006, 03:37

Re: Footer button up

25 Nov 2017, 11:30

FYI, "scroll to top" button is now added to sidebar and slidemenu layouts since X3.24.0.
https://forum.photo.gallery/viewtopic.php?f=51&t=9445