Fix pointer cursor on descendants of primary buttons

The cursor in primary buttons is shown as a pointer (if the button is
not disabled) to convey that it can be interacted with. However, the
descendants of the button may not inherit the cursor from it (for
example, a "strong" element would, but a "span" element would not),
which causes a pointer cursor to be shown on some areas of the button
and a different one to be shown on other areas. To prevent that now all
the descendants of a primary button use a pointer cursor.

Although ".primary" is typically applied on buttons note that this is
applied too to other elements marked as primary (as they also have a
pointer cursor).

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
Daniel Calviño Sánchez 2020-02-27 10:58:16 +01:00
parent 72cc8270cd
commit d67c579fb3

View file

@ -91,6 +91,10 @@ div[contenteditable=true],
color: var(--color-primary-text);
cursor: pointer;
* {
cursor: pointer;
}
/* Apply border to primary button if on log in page (and not in a dark container) or if in header */
#body-login :not(.body-login-container) &,
#header & {
@ -113,6 +117,10 @@ div[contenteditable=true],
background-color: var(--color-primary-element);
color: var(--color-primary-text-dark);
cursor: default;
* {
cursor: default;
}
}
}
}