theme_bootstrap
theme_bootstrap copied to clipboard
Activity edit dropdown on hidden activities looks poor
The transparency on the edit box when applied to hidden items can make the options hard to read...
Hey Howard, how's things?
There's a core bug filed about this: https://tracker.moodle.org/browse/MDL-42634
It kind of turned into a long meandering thread and then nothing got done about it, but there's a comment from me somewhere in there with a fix that would be appropriate for Bootstrap based themes.
Basically, rather than use opacity to lighten the colors, it just lightens the colors directly.
I rather liked the hover fix I suggested as it was neat and only affects the block when hovering. However you made it out to be a 'hack' and said it caused problems then later said... "...Oh, I just noticed that if you drag'n'drop a hidden block the opacity is set to 1 (not transparent at all) until you reload the page. Looking closer it seems to set opacity:1 on the block, so it seems the opacity has caused problems before..."
Hi Mary,
it seems like you and I regularly have discussions about my use of the word 'hack'. As always, in this case my usage of 'hack' is in a positive sense. Whoever came up with the idea of using opacity to 'fade' the blocks came up with a neat hack, that achieves the tricky goal of making something look faded regardless of the way the underlying theme styles the block. I'm impressed by its unorthodox yet effective approach.
I wasn't talking about your hover solution when I used the word hack (and re-reading the bug, neither was Andrew, he was saying that the opacity had to go, rather than keep it with your workaround in place). If people are having trouble with this right now it's a good quick fix that they could stick in their custom CSS.
But there are reasons for looking for other solutions, e.g. I'm not sure that anything using :hover would work on a tablet, or for people navigating by keyboards, and generally having a ghostly menu that only comes into focus when you mouse over it is a bit odd and users might wonder why that's happening. So perhaps there's another way to make blocks look hidden e.g. adding the text "block hidden from students" or similar. (This would also have accessibility and usability benefits by making it more obvious that some blocks are hidden).
But until (and posible after) core adopts such a change, Bootstrap based theme's could use less to fade the colors of the block itself when it is hidden.
Is this relevant? https://github.com/moodle/moodle/commit/d48dae7507a572ceda79be39fb45de450662c68d
Which equates to this... https://github.com/moodle/moodle/blob/d48dae7507a572ceda79be39fb45de450662c68d/theme/base/style/core.css#L12-L38
CSS Tricks has a better solution: http://css-tricks.com/css-transparency-settings-for-all-broswers/ updated in 2011 updated three months before the commit.