TOPIC:

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274173

  • Topic Author
  • Dankill
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 26
  • Thanks: 0
So I have a ContentBuilder list view which includes a column to display the username of the users who create the entries to the list. The length of these names can vary quite a bit and we have noticed that this is creating a lot of white space when an especially long username expands the column. I would like to set the column to a fixed width to prevent this horizontal expansion to the table, but the css "width" property seems to get ignored (even with the !important tag). Other css works fine on the column, such as colour changes.

Here is the simple css that I have tried:
.table th.sectiontableheader:nth-child(3), td:nth-child(3) {
    width: 100px !important;
}

Is there anything unique that must be done to achieve this?

Thank you.

Please Log in or Create an account to join the conversation.

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274176

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Registered
  • Posts: 12079
  • Thanks: 786
Hi,

could you please send me link of that view that I can check it with css in Console?

Regards,
Tihana

Please Log in or Create an account to join the conversation.

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274227

  • Topic Author
  • Dankill
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 26
  • Thanks: 0
Thank you for taking a look. You can find an example at: muleit.ca/get-me-a-lift/item-to-move

The site is under construction, so ignore any unrelated errors you see in the inspection panel.
The goal is to have column 3 (Username) be a fixed width of 100px just to prove the concept.

Please Log in or Create an account to join the conversation.

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274233

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Registered
  • Posts: 12079
  • Thanks: 786
Hi,

ok, if you add this:
.table th.sectiontableheader:nth-child(3), td:nth-child(3) {
    max-width: 100px !important;
}
then you will see that the code works ok.

Please test it and let me know if you need more help

Regards,
Tihana
The following user(s) said Thank You: Dankill

Please Log in or Create an account to join the conversation.

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274242

  • Topic Author
  • Dankill
  • Offline
  • Junior Member
  • Junior Member
  • Registered
  • Posts: 26
  • Thanks: 0
Thanks tihana, it looks like I will have to word-wrap or obscure the overflow into the neighboring cell, but that fixes the width issue. Thought it would be simple and glad it was.

Please Log in or Create an account to join the conversation.

Setting Fixed Width for a Column in a View 1 year 2 weeks ago #274243

  • tihana.krivic's Avatar
  • tihana.krivic
  • Offline
  • Moderator
  • Moderator
  • Registered
  • Posts: 12079
  • Thanks: 786
Hi,

np, anytime :)

If you need anything else, feel free to ask

Regards,
Tihana

Please Log in or Create an account to join the conversation.

  • Page:
  • 1
  • 2
Moderators: ForumSupport
Time to create page: 0.061 seconds

Support Chat

Join our Discord chat and enter the Crosstec channels for live-support, chat forums and interact directly with the community!

After joining, please enter the Crosstec Area and use the #crosstec-support or #crosstec-general channels.

Quick Links

Downloads

BreezingForms

ContentBuilder

BreezingCommerce

Templates

Documentation

BreezingForms

ContentBuilder

BreezingCommerce

Apprendre BreezingForms (French Community)

Apprendre et maîtriser BreezingForms par des tutoriels et exemples, le tout en français

breezingforms.eddy-vh.com

Questions et réponses sur les forums de l'AFUJ

AFUJ

Subscribe to news and updates!

Special Offer

Sale! All subscriptions at a special price!

Includes prio support, all of our current and future Joomla!® extensions and Joomla!® templates for the duration of your membership.

Get it from here

3rd Party Discount - 25% Off

We help you to keep your costs under control. If you are a new member and purchased a form building tool from a different form vendor, then you'll get a 25% discount on our subscription plans.

How to receive the discount:

Send us a quick email to sales@crosstec.org with a proof of purchase (for example a paypal receipt), await payment instructions and enjoy your membership!

Live Support Chat Opened!

Join our Discord chat here and enter the Crosstec channels to receive live support and talk directly to the team!