The CreatorCon Call for Content is officially open! Get started here.

How to reduce the height of a container in Service Portal ?

Gopi22
Giga Guru

Hi,

I am trying to reduce the height of container in 'index' page in ServiceNow (marked in red). 

find_real_file.png

 

Please let me know how to achieve this and if there is any OOTB way to do this without cloning the widget. 

 

Thanks,

Gopi

 

7 REPLIES 7

Vipin Murugesan
Kilo Sage

Traverse to Service Portal -> Portal -> Open your Portal

Open your Homepage -> Eg. copy_of_Index (cloned one)

 find_real_file.png

Click on the Container , it will open a new page with properties of the container

Edit the class of the Parent class with below mentioned Bootstrap class

find_real_file.png

 

find_real_file.png

 

PS: Mark Correct or Hit Helpful depending on the impact of the response

Siddhnath Pande
Mega Guru

Hi Gopi,

As we cannot increase or decrease the size of container but if you change the size of widget it will automatically affect the size of container as well.

And the container you are talking about it contains the "Homepage Search" Widget so just go to widget module open this widget & clone this and add this below css in(that put the height you want).

find_real_file.png

 

After adding this save it. then go back again in the Widget module open the Homepage Search Widget & go in the related list you will find the instances of this widget there you select your instance then open that widget instance & in the widget tab add this cloned widget then save it & you will see the result like below.

 

find_real_file.png

 

Here is few SS that will help you:

find_real_file.png

find_real_file.png

 

If the above code helps then please mark my answer Correct and Helpful.

Thanks and Regards:
Siddhnath Pandey

Hey Gopi, Hope you doing well.

Please let me know if you have any questions and if your query is solved please close this thread by marking the correct answer.

Mark Roethof
Tera Patron
Tera Patron

Hi there,

You could increase the height of containers. For example by adding a class to the container:

find_real_file.png

And adding that class to the Page Specific CSS: 

find_real_file.png

If my answer helped you in any way, please then mark it as helpful.

Kind regards,
Mark
2020 ServiceNow Community MVP
2020 ServiceNow Developer MVP

---

LinkedIn
Community article list

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

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

LinkedIn