Skip to content

Bug in "_sections.less" mixins: missing rules and incorrect default variables #18729

Closed
@dmytro-ch

Description

@dmytro-ch

There are couple of issues when trying to use mixins for "tabs" and "accordion" components.

The issue is related to lib/web/css/source/lib/_sections.less.
The default variables are predefined in lib/web/css/source/lib/variables/_sections.less.

Summary (*)

When you try to customize the view of "tabs" and "accordion" components by redefining the default variables in the scope of a custom theme, the following issues appear:

  1. The text color for active "accordion" control is not applied.
  2. The text-decoration for active control is not working for both "accordion" and "tabs" components.
  3. There are also incorrectly defined default variables for mixins. (e.g. accordion control visited and tab control hover variables etc.).

Examples (*)

Let's try to define the following variables in the scope of a custom theme.

@tab-control__active__background-color: yellow;
@tab-control__active__color: red;
@tab-control__active__text-decoration: underline;

Assuming that those variables are not defined elsewhere (in the scope of current or parent theme) except the default lib variables file lib/web/css/source/lib/variables/_sections.less.

Expected Result

There are red color, yellow background and underline text decoration applied for both accordion and tabs active controls.

screen shot 2018-10-21 at 8 41 00 pm

screen shot 2018-10-21 at 8 52 33 pm

Actual Result

The red color is not applied accordion active controls.
The underline text decoration is not apllied for both accordion and tabs active controls.

screen shot 2018-10-21 at 9 01 22 pm

screen shot 2018-10-21 at 9 00 35 pm

Proposed solution

Add missing rules to lib/web/css/source/lib/_sections.less and change the default variable names to the correct ones.

Metadata

Metadata

Assignees

Labels

Fixed in 2.2.xThe issue has been fixed in 2.2 release lineFixed in 2.3.xThe issue has been fixed in 2.3 release lineIssue: Format is validGate 1 Passed. Automatic verification of issue format passedReproduced on 2.2.xThe issue has been reproduced on latest 2.2 releaseReproduced on 2.3.xThe issue has been reproduced on latest 2.3 release

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions