Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CSS to pre-split version #31

Merged
merged 1 commit into from
Jun 30, 2022

Conversation

fpokryvk
Copy link
Contributor

@fpokryvk fpokryvk commented Jun 30, 2022

There were some fixes to CSS stirng in html.py that were not reflected to behave.css. Add missing definitions, as without them failed HTML is too green and links are not underlined (thus not visually clickable unless mouse hovered).

@fpokryvk fpokryvk force-pushed the fp/css_fixes branch 2 times, most recently from 5182727 to ead45fc Compare June 30, 2022 10:54
behave_html_formatter/behave.css Outdated Show resolved Hide resolved
Comment on lines 256 to 257
h3.failed,
#behave-header.failed {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
h3.failed,
#behave-header.failed {
.failed {

Can't we simply make this generic? I believe, CSS linters usually complain about over-specification.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This does not work unfortunately. With important it overwrites all other rules setting background to class failed, without it it has no effect, as it is overridden by rule:

.behave #behave-header, td #behave-header, th #behave-header {
  background: #65c400;
...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I copied matched rule, appended .failed (or .undefined) and it seems to work. Not sure, if that is better.

h3.failed, #behave-header.failed {
background: #c20000 !important;
}
h3.undefined, #behave-header.undefined {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
h3.undefined, #behave-header.undefined {
.undefined {

Same here. Thou shalt not over-specify.

There were some fixes to CSS sting in html.py that were not reflected to 
behave.css. Add missing definitions, as without them failed HTML is too 
green and links are not underlined (thus not visually clickable unless 
mouse 
hovered).
@bittner bittner merged commit b61bf3f into behave-contrib:main Jun 30, 2022
@bittner
Copy link
Member

bittner commented Jun 30, 2022

Awesome, thanks! 💯

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants