Opened 2 years ago
Closed 17 months ago
#56951 closed defect (bug) (invalid)
Incorrect use of class in wp-admin fields
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | |
Component: | Administration | Keywords: | |
Focuses: | css, administration, coding-standards | Cc: |
Description (last modified by )
in wp-admin/options-general.php and profile.php we are using the class 'regular-text code' to display the text in the Website field. However in other url field instances, we use the 'regular-text' class.
See Here: https://prnt.sc/wQ7zuSY-pWRX
This seems incorrect, for example in wp-admin/profile.php, we have a list of url fields beginning with the website url. The website field is the only one which uses this 'regular-text code' class. It looks unusual to differ between the url classes in this way:
I found this page which also contradicts the use of 'regular-text code' for a url:
Therefore, is the usage of this class correct? If not, i'm happy to be assigned to contribute the fix for this, if it is indeed classed as incorrect.
Attachments (1)
Change History (4)
#1
follow-up:
↓ 2
@
2 years ago
- Component changed from General to Administration
- Description modified (diff)
- Keywords close 2nd-opinion added
Hi and thanks for the report!
The style guide page describes how to style "Code in text"; these are input fields. For the "Website" field, the regular-text
class sets the input width, and the code
class gives it the fixed-width font and text direction.
"Facebook profile URL" is not a Core profile field, but it seems to be from Yoast SEO. You could open an issue (and/or pull request) to suggest adding the code
class to each profile URL field and probably changing the type
from text
to url
.
https://github.com/Yoast/wordpress-seo/issues
#2
in reply to:
↑ 1
@
2 years ago
Hello @sabernhardt and thank you for your prompt reply.
Yes, you are correct, the additional fields have been generated from the Yoast Seo plugin.
I will raise this with Yoast Seo and issue a PR to fix in line with core styles.
Replying to sabernhardt:
Hi and thanks for the report!
The style guide page describes how to style "Code in text"; these are input fields. For the "Website" field, the
regular-text
class sets the input width, and thecode
class gives it the fixed-width font and text direction.
"Facebook profile URL" is not a Core profile field, but it seems to be from Yoast SEO. You could open an issue (and/or pull request) to suggest adding the
code
class to each profile URL field and probably changing thetype
fromtext
tourl
.
https://github.com/Yoast/wordpress-seo/issues
showing the font classes used