easonwong-de / Tab-Preview-On-Hover

Adds on-hover tab preview to Firefox (requires CSS theme).
https://addons.mozilla.org/firefox/addon/tab-preview-on-hover/
MIT License
36 stars 0 forks source link

Customisable Font Size & Favicon #8

Open VitalSkib opened 1 year ago

VitalSkib commented 1 year ago

Hi there. Nice update, thanks. However, there is still no way to control the font size? I'll just remind you that if I resize (enlarge) the size of the preview window, then the caption's font gets bigger accordingly, which starts to look less pretty. And you said you'd see what you could do with it in the next release. So, any progress on it?

Oh, and one more thing while we're at it. Is it possible to call this window when hovering over the active tab, but without an image preview? Just like it is implemented in MS Edge, for example (see attachment).. TIA

2023_08_27_screenshot

easonwong-de commented 1 year ago

@VitalSkib I’m flattered that you stick around. As this update mainly focuses on performance and compatibility, introduction of new features were dropped.

The text-only tab preview panel on active tab is achievable with edits to the CSS theme. Appending this after the original CSS theme will enable the effect.

/* shows the tab preview panel on active tab */
.tabbrowser-tab[selected]:hover::after {
    opacity: 1 !important;
}

/* text-only variation */
.tabbrowser-tab[selected]::after {
    --preview-height: 50px !important;
    background-position: bottom;
}

/* height transition (optional) */
#tabbrowser-arrowscrollbox:not(:hover) .tabbrowser-tab::after {
    transition: opacity 0.5s, filter 0s var(--preview-delay-tolerance), height 100ms !important;
}

#tabbrowser-arrowscrollbox:hover .tabbrowser-tab::after {
    transition: opacity 0.5s, filter 0.5s var(--preview-delay), height 100ms !important;
}
VitalSkib commented 1 year ago

Ha, that's cool, thanks. 😎👍 A couple of wishes, kinda future request.. A favicon icon on the left of the url and dynamic text wrapping to another line(s) if the text is too long. tia

easonwong-de commented 1 year ago

My pleasure. In the released version, I didn’t include the above CSS because it seems to cause stuttering / performance degradation when Adaptive Tab Bar Colour is also installed. If you notice any unwanted behaviour, you might want to revoke the changes.

Customisations, including the possibility to change text size, are under way. So is adding favicon to the text box.

Text wrapping might be difficult.

VitalSkib commented 1 year ago

My pleasure. In the released version, I didn’t include the above CSS because it seems to cause stuttering / performance degradation when Adaptive Tab Bar Colour is also installed. If you notice any unwanted behaviour, you might want to revoke the changes.

Customisations, including the possibility to change text size, are under way. So is adding favicon to the text box.

Text wrapping might be difficult.

Well, I don't use the Adaptive Tab Bar Colour, but I also noticed some unwanted behavior that is a bit annoying. So, yeah, I'm probably going to drop this idea, but thanks for the help.

VitalSkib commented 10 months ago

In order not to create many posts, I’ll ask here, if you don’t mind. I'm wondering if there is a way to change the background color of this part? I couldn't figure out how (if) I could do this. tia

2023-10-26_Firefox Nightly

easonwong-de commented 6 months ago

@VitalSkib The background colour of the text box is decided by the frame colour of the current Firefox theme. For now, it cannot be configured alone.

VitalSkib commented 6 months ago

@VitalSkib The background colour of the text box is decided by the frame colour of the current Firefox theme. For now, it cannot be configured alone.

Tab-Preview-On-Hover doesn't want to work for me for a couple of months now with some of the latest Firefox Nightly updates. I don't know why and I don't have time to find out which of their changes affected this. So..

easonwong-de commented 6 months ago

Thanks for the information. Preview panels not showing up will be the CSS’s issue, while they being blank should be the add-on’s issue. Either way, I’ll wait until the new iteration of Firefox releases.

VitalSkib commented 6 months ago

Thanks for the information. Preview panels not showing up will be the CSS’s issue, while they being blank should be the add-on’s issue. Either way, I’ll wait until the new iteration of Firefox releases.

Yeah, it just doesn't show up at all. Thanks.