Skip to content

NavigationTabButton: Fix icon.source detection

ivan tkachenko requested to merge work/ratijas/nav-tabbutton-text-alignment into master

The icon.source property has url type, and can not be compared directly to an empty string.

See also: qqc2-desktop-style@e74b8530


Continuing this line of though, the following bindings below don't make much sense either:

            implicitHeight: source ? control.icon.height : 0
            implicitWidth: source ? control.icon.width : 0

because a url source is always considered truthy.

I wonder if we should use Kirigami.Icon::valid property more?

Merge request reports