Hiding Elements on Load Briefly shows Elements before Hiding them

eugenecjr

Member
I have searched through the forums and see mention of this issue but no solid solutions. I have five display elements that are used to provide information based on a dropdown selection. The issue is when opening an existing record all 5 of the display elements are shown then 4 are hidden to show the element that is expected. This momentary showing or flashing of elements that I expect to be hidden simple looks bad.

I have tried a number of suggestions such as hiding the element then using JavaScript to show the element which for the display element requires me to change the type to 'field', hide then save, then change back to Display and save, as the Display does not have a hide attribute. This does hide the element creating another issue that the JavaScript is not able to show the element. I know my JavaScript is correct as when the Display element is not forcefully hidden it works just fine.

I also have tried both using the pre-defined JavaScript options to show/hide elements as well as putting the code in the form_??.js.

Any suggestions on how to clean this up would be great.

-Eugene
 
Using a Calculate Element in conjunction with a Display element does not show anything. Simple set the calculate element to return ‘{table___element}’; and get no results.


Sent from my iPhone using Tapatalk
 
You can use calc or field element with edit access set to noone instead of display elements.
 
Unfortunately I wont be able to set any formatting such as larger font/bold/etc... to emphasize the importance of certain parts of the message if I set the element to a field. The information is information that I want to be displayed to the user based on the type of item. ie. if the item is a bulk item it will be handled differently then an item that can be individually counted. I am using the display field to provide information on how to approach certain items. If the item is set to 'bulk' then the 'details_bulk' element is shown while the other 4 are hidden. As mentioned above these are good size elements with regards to the formatting and information and when the page loads there is a moment where all 5 are present and that is all you see, then it is reduced to 1 where everything flies up on the screen.

-Eugene
 
Yep, that "briefly showing" of the element with javascript hide is an unfortunate side effect.

P.S. you can use any formatting you like also with calc element, e.g. return "<div style='color:#123456;'>Your text</div>";
 
Standard is showing elements and you can only hide via JS what is "there".
You can add custom CSS for the element container class fb_your-full-element-name {visibility:hidden;}, this can be "shown" with the built-in JS actions.

But do you know the "description field" of a databasejoin element (Advanced)?
 
I see the description field and will take a look at that. Not sure how much information. I can apply using it as for some of the drops own options their is a bit to explain. Also how this shows on the form. I will take a look as soon as I get a chance.

-Eugene


Sent from my iPhone using Tapatalk
 
I have looked at the description field and for cases where I need to give a hint or suggestion that would be awesome. However, I have more that I need to say. I am now looking at adding the custom CSS for the element containers class, but I am not sure exactly where this is at. I have looked at the element and I see several classes but none labeled container. I also look at the form and don't see any CSS settings. Can you point me in the right direction?

Thanks,
-Eugene
 
We are in need of some funding.
More details.

Thank you.

Staff online

Members online

Back
Top