Scaling down the angular toolbar

Hello Syncfusion team,

I am trying to lower the height of the syncfusion toolbar. I tried to reproduce your solution from the following thread: https://www.syncfusion.com/forums/149519/toolbar-height 

But this way, it does not scale down the whole toolbar (including texts and icons). How can I achieve this? (A 50% scale of the the toolbar height for all relevant elements)

Thanks in regard,

Jonas Czeslik



8 Replies 1 reply marked as answer

HB Hareesh Balasubramanian Syncfusion Team February 5, 2021 08:01 AM UTC

Hi Jonas, 

Greetings from Syncfusion Support..! 

We have validated your shared query and suspect that your requirement is to reduce the size of the items of the Toolbar component and for that, we have prepared a sample using CSS, which can be viewed from the following link. 


.e-toolbar .e-tbar-btn .e-icons.e-btn-icon { 
  font-size: 12px; 
} 

Kindly try the above solution and if we misunderstood your requirement, kindly share more details like the use case scenario/image/video demo of your requirement/Toolbar rendering code snippets of your requirement which would help us to provide a prompt solution at the earliest. 

Regards, 
Hareesh 



JC Jonas Czeslik February 5, 2021 12:29 PM UTC

I dont know, if I am doing something wrong, but I cannot seem to make the custom css parts have an impact on the style of the toolbar. Or more precisely, I added a text to the toolbar items in your sample and added the css statement, but nothing changed visually (neither by adapting the height nor the font-size).  

Same goes for the  .e-tbar-btn .tb-icons {}     Neither height nor font-size have a visual impact here.

All in all, I want the complete toolbar to scale down because if there is more than one toolbar, it would be cool, if they dont have the standard 42(?)px height. But that also requires that not only the toolbar scales down but also the toolbar texts and the toolbar icons. And that I cannot really accomplish 




SK Satheesh Kumar Balasubramanian Syncfusion Team February 8, 2021 11:56 AM UTC

Hi Jonas, 
  
Thanks for your update. 
  
We have validated your reported query at our end and suspect that your requirement is to customize the height of the Toolbar component and text and icon within it. For that, we have prepared a sample using Height property, which can be viewed from the following link.

 
  
<ejs-toolbar height="60px"> 
.... 
.... 
 </ejs-toolbar> 
  
Kindly try the above solution and if we misunderstood your requirement, kindly share more details about your requirement like image reference to serve you better. 

 
Regards, 
Satheesh Kumar B 




JC Jonas Czeslik February 8, 2021 12:45 PM UTC

This does not work either. In your case you made the toolbar higher, which works fine. But I want to make it smaller. If I am trying to this by adapting the toolbar height to "20px" for example, it does not work out. There seems to be a minimum height. Also, the size of icons and texts are not scaling with this method and lastly, I am using dynamic toolbar elements that I bind to the ejs-grid [toolbar] property. So I have not such access to the e-toolbar html tag.


SK Satheesh Kumar Balasubramanian Syncfusion Team February 10, 2021 10:43 AM UTC

Hi Jonas, 
  
Thanks for your patience. 
  
We have validated your reported query at our end. We have confirmed this as a bug and logged the defect report "Toolbar Height customization not working less than minimum height value" which can be tracked from the following link. 
  
  
The issue fix for this defect will be included in our weekly patch release rolled out by the end of February 2021. We would appreciate your valuable patience until then. 
  
Regards, 
Satheesh Kumar B 




JC Jonas Czeslik February 10, 2021 02:12 PM UTC

Thanks a lot!
It would be very cool, if the toolbar texts and icons automatically adapt its sizes, when the toolbar gets a lower height, so that only the height change would be necessary


VD Vinitha Devi Murugan Syncfusion Team February 11, 2021 09:54 AM UTC

Hi Jonas, 

Thanks for your update.  
  
We will consider your scenario when we fixing this fix. 

Regards, 
Vinitha 



NR Nevitha Ravi Syncfusion Team April 5, 2021 06:14 AM UTC

Hi Jonas, 

We are glad to inform you that your requirement ‘toolbar with minimum height’ has been achieved at sample end itself with the below CSS. Since by default the minimum height of the toolbar is 42px, we need to use the following CSS to reduce the toolbar height less than its minimum height at sample end. Please try the following sample and get back to us if you need any further assistance. 


.e-toolbar { 
  min-height: 10px; 
} 
 
.e-toolbar .e-toolbar-items { 
  min-height: 10px; 
} 
.e-hscroll .e-scroll-nav { 
  min-height: 10px; 
} 
.e-toolbar .e-toolbar-items .e-toolbar-item { 
  min-height: 10px; 
} 
.e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn.e-btn { 
  height: 20px; 
  line-height: 20px; 
} 
.e-toolbar .e-tbar-btn .e-icons.e-btn-icon { 
  font-size: 10px; 
} 
.e-toolbar .e-tbar-btn .e-tbar-btn-text { 
  font-size: 10px; 
} 
e-toolbar .e-toolbar-items .e-toolbar-item .e-tbar-btn-text { 
  height: inherit; 
} 
.e-toolbar .e-toolbar-item .e-tbar-btn.e-btn .e-icons.e-btn-icon { 
  line-height: 20px; 
  min-height: 20px; 
} 
 

Regards, 
Nevitha 


Marked as answer
Loader.
Up arrow icon