Code Monkey home page Code Monkey logo

Comments (6)

miromannino avatar miromannino commented on May 27, 2024

The animation for the mouseout is not needed, I tested and the fadeout for the caption is done. Have you some problems with that?

from justified-gallery.

Miami-T avatar Miami-T commented on May 27, 2024

As I remember, when I use cssAnimation:true there were no fadeout for caption. But I also changed some CSS rules so captions are always visible, mouseover and mouseout just change opacity.

Right now I'm on vacation. I will try to create some sample when I'm back later this month.

from justified-gallery.

miromannino avatar miromannino commented on May 27, 2024

Perfect, thank you

from justified-gallery.

Miami-T avatar Miami-T commented on May 27, 2024

I created a sample on http://slike.miamit.si/test.html

I decided to show captions on initial display because there is no "onmouseover" action on mobile devices so that mobile users can see them. To achieve this I have to use "cssAnimation:true" so captions will stay visible after "onmouseout" on computer devices. I add some css rules that are visible in source code.

So there are two problems that I see:

  • fade out is not happening on mouse out
  • if I chose value for ... to{opacity:.X} different than .7, "onmouseover" action is always ended with opacity .7

For now I am satisfied with solution I achieve. I just wanted to show you, how I want to use your excellent justified-gallery javascript code. If you someday decide to enable initial caption display I will be very happy.

from justified-gallery.

miromannino avatar miromannino commented on May 27, 2024

Yes, you are right. I'm implementing it

from justified-gallery.

miromannino avatar miromannino commented on May 27, 2024

In the next version 3.3, to set the initial opacity using CSS, there are three variables in the LESS file:

@caption-initial-opacity: 0.0;
@caption-visibile-opacity: 0.7;
@caption-animation-duration: 500ms;

Using javascript you can use the new settings for the caption:

captionSettings : { //ignored with css animations
    animationDuration : 500,
    visibleOpacity : 0.7, 
    nonVisibleOpacity : 0.0 
},

from justified-gallery.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.