Skip to Content Skip to Menu

[SOLVED] Can I do this with CB Conditionals (or, somehow?)

8 years 2 weeks ago #287632 by Paladin Brewer
Replied by Paladin Brewer on topic Can I do this with CB Conditionals (or, somehow?)
So I'm trying:
Code:
.cb_template .cbEditProfile .myFieldRows { width: 30% !important; display: inline-block !important; vertical-align: top !important; }

In hopes that will only apply the rows I wanted previously to the Edit page. This actually does nothing, it just breaks as if myFieldRows is no longer being used as at all.

I also tried it for the spacing with my text on only the profile page:
Code:
.cb_template .cbProfile .form-group { margin-bottom: 0px !important; }

And also, nothing happened :(

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48548
  • Thanks: 8290
  • Karma: 1445
8 years 2 weeks ago #287656 by krileon

I'm guessing I can also do this to fix my first problem? Some sort of ".cb_template .form-group .cbProfile {" So it only effects the spacing on the profile and not the field spacing in the edit? I'm not home to test right now which is why I ask. Is it .cbProfile for the profile info?

Yes.

In hopes that will only apply the rows I wanted previously to the Edit page.

That should only affect profile edit.

And also, nothing happened

Remove the .cb_template from the selector and see if that fixes it. Forgot those 2 selectors are on the same div. Example as follows.


.cbEditProfile .myFieldRows
.cbProfile .form-group

The below will probably also work.

.cb_template.cbEditProfile .myFieldRows
.cb_template.cbProfile .form-group


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

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

8 years 2 weeks ago #287669 by Paladin Brewer
Replied by Paladin Brewer on topic Can I do this with CB Conditionals (or, somehow?)
That worked, much thanks :)

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

  • MMDoege
  • MMDoege
  • OFFLINE
  • Posts: 98
  • Thanks: 3
  • Karma: 0
7 years 10 months ago #289478 by MMDoege
Hello,

I've implemented the css to get fields side-by-side as Kyle suggested (see 1st attachment).
Actually these fields have type "Custom HTML" which call APIs of Facebook, Twitter and LinkedIn.
Which works fine.

However, it appears responsiveness gets lost when resizing the tab which holds the fields.
Fields become overlapped when shrinking user profile to small device level (see 2nd attachment).

What causes this: Joomla template? css of fields or custom HTML?

Thank you!

I put the following code into CB default template's override.css:

.myFieldRows {
width: 30%;
display: inline-block;
vertical-align: top;
}

.myFieldRows + .myFieldRows + .myFieldRows + .myFieldRows > .control-label {
display: none;
}
Attachments:

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

  • krileon
  • krileon
  • ONLINE
  • Posts: 48548
  • Thanks: 8290
  • Karma: 1445
7 years 10 months ago #289511 by krileon
Your CSS has no responsiveness. You've set for them to have 30% width no matter what. Responsiveness is done using @media max-width and/or min-width for it to change the width based off the window size. The example I gave you below uses Bootstrap classes which already handle the responsiveness.

www.joomlapolis.com/forum/153-professional-member-support/235064-solved-can-i-do-this-with-cb-conditionals-or-somehow?start=24#287532

If you insist on using your own CSS for the width then you need to write CSS to handle responsiveness for that width. See the below Bootstrap grid for examples (it explains how to use @media as well).

getbootstrap.com/css/#grid


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
The following user(s) said Thank You: nant

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

Moderators: beatnantkrileon
Powered by Kunena Forum