Home > Blockchain >  Css getting applied to all pages in angular primeng
Css getting applied to all pages in angular primeng

Time:01-06

I am using p-dropdown and I have applied min-width to p-dropdown panel for two different pages.

In page1 css

.p-dropdown panel {
  min-width: 35% !important;
  } 

In page2 css

.p-dropdown panel {
  min-width: 20% !important;
 }    

When I open page2 after opening page1, then page1 css for p-dropdown panel is getting applied.

enter image description here

CodePudding user response:

Try this in page2 css.

.p-dropdown panel {
  min-width: 20% !important
 } 

CodePudding user response:

Without looking at your entire css/project - in Chrome you can open up Dev Tools, select the element, and view the "Computed" tab to look up what file/css is determining the width.

  •  Tags:  
  • Related