This question is answered. Helpful answers available: 2. Correct answers available: 1.


Permlink Replies: 7 - Pages: 1 - Last Post: 22 Jul 21, 23:39 Last Post By: rfm2 Threads: [ Previous | Next ]
rfm2

Posts: 143
Registered: 13-Dec-2007
Neptune 64: opacity
Posted: 22 Jul 21, 18:58
 
  Click to reply to this thread Reply
I installed version 64 (jAlbum 24.1) and it appears that the opacity of the video overlay is not being applied, regardless of whether I apply it through the UI Code tab or add it to the common.css for the finished album. The default opacity appears to be 0.5, and I can't override it. What am I missing?
JeffTucker

Posts: 7,667
Registered: 31-Jan-2006
Re: Neptune 64: opacity
Posted: 22 Jul 21, 19:03   in response to: rfm2 in response to: rfm2
 
  Click to reply to this thread Reply
In order to prevent the opacity from starting at 1.0 when the page loads, and then changing to 0.4 when the CSS is applied, which produces an annoying "flash" on page load, the opacity is set inline. That means that to override it, you need:
.ne-videooverlay {opacity: 0.7 !important;}
Otherwise, the inline styling takes precedence.

Forgot to warn you about that! :)
JeffTucker

Posts: 7,667
Registered: 31-Jan-2006
Re: Neptune 64: opacity
Posted: 22 Jul 21, 19:14   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
And if you also want to reposition it:
.ne-videooverlay {opacity: 0.7 !important;}
.ne-videooverlay img {top: 10px; left: 10px; margin: 0px;}
The UI lets you set the size.
rfm2

Posts: 143
Registered: 13-Dec-2007
Re: Neptune 64: opacity
Posted: 22 Jul 21, 19:35   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
OK, I finally have that one sorted out. I still prefer the specified width (and inferred height) to the % in the UI since even at 20% (the minimum) it is pretty large if I am using large thumbnails for some special reason.

Now for the next opacity question. I have a line in the UI Code for the page top icon of:
#ne-pagetop:hover{opacity: 0.9}
The effect now is the opposite of what I expect - that is, a value of 0.9 or 1.0 makes the icon completely transparent.upon hovering. I need for you to straighten me out on that one.
JeffTucker

Posts: 7,667
Registered: 31-Jan-2006
Re: Neptune 64: opacity
Posted: 22 Jul 21, 19:49   in response to: rfm2 in response to: rfm2
 
  Click to reply to this thread Reply
Attachment hoverDiff.png (2.1 KB)
Must be something else going on there. The default, non-hovered opacity of the pagetop icon is 0.75, and it gets fully opaque on hover if I include this:
#ne-pagetop:hover {opacity:1.0;}
But there's not a lot of daylight between 0.75 and 1.0. The effect is pretty subtle.

ETA: Screenshot.
rfm2

Posts: 143
Registered: 13-Dec-2007
Re: Neptune 64: opacity
Posted: 22 Jul 21, 20:14   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
After replacing my line in the UI with a pasted copy of yours it behaves as expected. When I go back and replace yours with my original UI code I can't duplicate what I was seeing. Whatever I was doing wrong with that line of code must have vanished, so all is well now.

Thanks for the help.
JeffTucker

Posts: 7,667
Registered: 31-Jan-2006
Re: Neptune 64: opacity
Posted: 22 Jul 21, 20:19   in response to: rfm2 in response to: rfm2
 
  Click to reply to this thread Reply
More proof of the existence of Code Gnomes™.

https://jalbum.net/help/en/JAlbum/Glossary/C#Code_Gnomes.E2.84.A2

But I'll bet I can guess what the error was, having done the same thing enough times myself. Stare at this for a moment:
#ne-pagetop:hover {opacity: 0;9;}
See what's wrong? Hint: a semi-colon is not a period. ;)

This is the kind of thing that a good code validator would find. I have a pro license for Total Validator, and I run my entire demo site through it before I push out changes. With one click, it checks the HTML, CSS, and links in all of the demo albums and the hundreds of pages of user's manuals. Worth every penny I paid for it.
rfm2

Posts: 143
Registered: 13-Dec-2007
Re: Neptune 64: opacity
Posted: 22 Jul 21, 23:39   in response to: JeffTucker in response to: JeffTucker
 
  Click to reply to this thread Reply
Well, in my case your guess of a typo error would be a pretty good guess (I am a 2-finger, dyslectic typist, frequently reversing 2 letters/numbers), but in this case when you look at the message where I broached this subject, that quoted line from the UI code was copied from the test album, and there are no typos. The only difference between what I used and your version is the absence of a space before the opening bracket, and no closing semi-colon after the number, neither of which should affect the usage.

I think the error was in my dyslectic brain where when I used a certain value, what I expected to see was the opposite of what I should have (and really was) expected. I have gone back and replaced the line in the test album with what I sent in the message, and it works the way it is supposed to work, not the way I thought I saw it work.

Oh well, if that's the worst goof for the rest of this year I'll be thrilled.
Legend
Forum admins
Helpful Answer
Correct Answer

Point your RSS reader here for a feed of the latest messages in all forums