Not a bug Inconsistent markup on account details fields

RobinHood

Well-known member
Affected version
2.2
Not really bug, but just a little inconsistency making it harder to layout the settings page at data-template="account_details"

We've got really detailed markup for targeting custom user fields on the account details page, which is great, like so:

1613601548473.webp

But the core fields on the same page, aren't marked up, so it's not easy to target them without adding additional markup,

1613601700960.webp
 
Are you referring to the data-field values?

It kind of goes with the suggestion I made regarding data-content-key values.

 
Yep. Sort of ties into this suggestion aswell.

Found myself trying to target all the things the last few weeks, and on things like custom user fields and menu's, where things can swap around it's so useful to have the data-fields.
 
The bit you point to is specific to custom fields. Nothing else will automatically have it. That isn't really a bug, as we simply don't do that in generally (and we wouldn't really intend to). We do occasionally apply some extra identifiers to components that are dynamically generated (like custom fields and navigation items) as they are harder to more individually target. If you want to target a specific field on a specific page, we'd have to recommend making direct changes to expose the selector you want for that field.
 
Not really bug, but just a little inconsistency making it harder to layout the settings page at data-template="account_details"

We've got really detailed markup for targeting custom user fields on the account details page, which is great, like so:

View attachment 246583

But the core fields on the same page, aren't marked up, so it's not easy to target them without adding additional markup,

View attachment 246584
Quite some time has passed...

Have you found a solution?
I'm struggling with this right now- trying to hide a few formRows from the account_details template...
 
Ok, that was quick :D :D
I just found this hack:


@cmpe suggested adding a row-type to the xf element like this: rowtype="nameOfClass", which basically adds another class to the formRow which looks like:
formRow--nameOfClass

Mission accomplished :)
 
Top Bottom