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

change height="38px;" to height="38" #97

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mgkuhn
Copy link

@mgkuhn mgkuhn commented Nov 5, 2021

The height and width HTML attributes “must have values that are valid non-negative integers.” Unlike the CSS attributes of the same name, they cannot have a unit suffix such as “px”.

https://html.spec.whatwg.org/multipage/embedded-content-other.html#dimension-attributes

Tool: perl -pi -E 's/(width|height)="(\d+)px;"/$1="$2"/' *.html /.html ...

(Note that this is just a syntax fix. It doesn't yet address the fact that this HTML attribute is actually overridden in the global footer by the CSS class campl-scale-with-grid, which actually sets height: auto. CSS usually overrides HTML presentational attributes.)

The height and width HTML attributes “must have values that are
valid non-negative integers.” Unlike the CSS attributes of the
same name, they cannot have a unit suffix such as “px”.

https://html.spec.whatwg.org/multipage/embedded-content-other.html#dimension-attributes

Tool: perl -pi -E 's/(width|height)="(\d+)px;"/$1="$2"/' *.html */*.html ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant