EC Styling Guidance

David Arbour
Tera Guru

When you update Employee Center to version 31.0.3, some changes are applied to the My Items widget that totally break any styling that was applied prior to the update. This occurs because the new version is updated with new classes, so any custom CSS that was added to target the old class names is no longer valid. We always attempt to apply styling in a way that prevents us from customizing widgets, so we put CSS on the theme, CSS includes, pages, etc. Since we are not updating the actual widget, updates from the store get applied rather than skipped, and our first indication that something changed was an unstyled My Items widget showing on a client's EC portal.

So, my question is, what is the guidance from ServiceNow for how we should be applying CSS styling to EC portals? Should we actually be customizing every widget with CSS so that attention is given to skips during an update? Or should we continue doing what we’re doing in trying to avoid widget customizations? This one update may have been a fluke, so we would really love to understand what ServiceNow recommends here.

8 REPLIES 8

Mark Roethof
Tera Patron
Tera Patron

Hi there,

 

Interesting to head. Didn't upgrade for my customers yet to 31.0.3, though reading what you are mentioning most likely going to run into similar 😞

 

I would definitely not go for cloning widgets like Rohan is mentioning in 3.1. Cloning widgets just for sstyling is in most cases not a practice.

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

Branimir Morfov
Tera Contributor

It would be about time ServiceNow to introduce the ability to add custom classes to some components

That would be amazing!

Not only classes, but id's as well. Currently you can add such only on column and row level, but not on instance level. I really do not understand why