By using this site, you agree to the Privacy Policy and Terms of Use.
Accept
rocoderesrocoderes
  • Home
  • HTML & CSS
    • Login and Registration Form
    • Card Design
    • Loader
  • JavaScript
  • Python
  • Internet
  • Landing Pages
  • Tools
    • Google Drive Direct Download Link Generator
    • Word Count
  • Games
    • House Painter
Notification Show More
Latest News
How to set the dropdown value by clicking on a table row
Javascript – How to set the dropdown value by clicking on a table row
JavaScript
Attempting to increase the counter, when the object's tag exist
Javascript – Attempting to increase the counter, when the object’s tag exist
JavaScript
Cycle2 JS center active slide
Javascript – Cycle2 JS center active slide
JavaScript
Can import all THREE.js post processing modules as ES6 modules except OutputPass
Javascript – Can import all THREE.js post processing modules as ES6 modules except OutputPass
JavaScript
How to return closest match for an array in Google Sheets Appscript
Javascript – How to return closest match for an array in Google Sheets Appscript
JavaScript
Aa
Aa
rocoderesrocoderes
Search
  • Home
  • HTML & CSS
    • Login and Registration Form
    • Card Design
    • Loader
  • JavaScript
  • Python
  • Internet
  • Landing Pages
  • Tools
    • Google Drive Direct Download Link Generator
    • Word Count
  • Games
    • House Painter
Follow US
High Quality Design Resources for Free.
rocoderes > JavaScript > Javascript – js webix border box not fully visible
JavaScript

Javascript – js webix border box not fully visible

Admin
Last updated: 2024/02/07 at 5:36 PM
Admin
Share
2 Min Read
js webix border box not fully visible

Problem:

I have the following code which looks like this:

Contents
Problem:Solution:Why this does not workWhat you should do
{id:'SetPopUp',view:'window',head:'',position:'center',move:true,body:
  {rows:[
    {height:7},
    {height: 140, cols:[
      {width:7},
      {css: { border: "2px solid #b3d9ff"},rows:[
        {id:"ll1", view:"label", label:"Select Tag", align:'left'},
        {id:'r1', view:"radio", value:1, height:50, options:[{id:1, value:"Tag1"},{id:2, value:"Tag2"}], align:'left'},
        {id:"l1", view:"label", label:"", width:70 , align:'left'},
        {id:"c1", view:"combo",options:[], width:190 , align:'left'}]},
      {view:"label", label:"vs", width: 30, align:'center' },
      {css: { border: "2px solid #99ffbb"},rows:[
        {id:"ll2", view:"label", label:"Select Tag", align:'left'},
        {id:'r2', view:"radio", value:2, height:50, options:[{id:1, value:"Tag1"},{id:2, value:"Tag2"}], align:'left'},
        {id:"l2", view:"label", label:"Select Feature Set", width:70 , align:'left'},
        {id:"c2", view:"combo",options:[], width:190 , align:'left'}]},
      {width:10},
    ]},{height:4},
    {cols:[
      {width:310},
      {view:'button',value:'Diff',width:60,click:function()  {
//some code
      }},
      {view:'button',value:'Close',align:'center',width:60,click:function(){this.getTopParentView().hide();}}
    ]}
  ]}
  };

and it creates a GUI like this
enter image description here

But the blue (#b3d9ff) and green (#99ffbb) color border does not slow in the bottom area. Can someone help me bring the border to be displayed in the lower bottom area as well?

Solution:

Why this does not work

You must not set borders, sizes, margins and paddings via CSS. This is a known limitation. In the resources below, they do not say per se that borders cannot be set this way, but this is the same case, because borders make div 2px wider and higher, so the JS cannot account for them during sizing and positioning.

  • docs
  • tutorials.

What you should do

Use JS means. Views have settings for borders to add them, and only then set their color via CSS. Only the color or style (like solid or dotted). Not sizes.
In this case, the easiest way to add borders around those two forms would be to add type: "form". https://snippet.webix.com/18zzs2jn

Related

Subscribe to Our Newsletter

Subscribe to our newsletter to get our newest articles instantly!

Share this Article
Facebook Twitter Email Print
What do you think?
Love0
Sad0
Happy0
Sleepy0
Angry0
Dead0
Wink0
Previous Article JavaScript progress bar unhides but won't update Javascript – JavaScript progress bar unhides but won’t update
Next Article Can I use import to read a JSON file in a Next.js 13 API? Javascript – Can I use import to read a JSON file in a Next.js 13 API?
Leave a comment Leave a comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

- Advertisement -

You Might Also Like

How to set the dropdown value by clicking on a table row

Javascript – How to set the dropdown value by clicking on a table row

February 11, 2024
Attempting to increase the counter, when the object's tag exist

Javascript – Attempting to increase the counter, when the object’s tag exist

February 11, 2024
Cycle2 JS center active slide

Javascript – Cycle2 JS center active slide

February 10, 2024
Can import all THREE.js post processing modules as ES6 modules except OutputPass

Javascript – Can import all THREE.js post processing modules as ES6 modules except OutputPass

February 10, 2024
rocoderesrocoderes
Follow US

Copyright © 2022 All Right Reserved By Rocoderes

  • Home
  • About us
  • Contact us
  • Disclaimer
Join Us!

Subscribe to our newsletter and never miss our latest news, podcasts etc.

Zero spam, Unsubscribe at any time.
Welcome Back!

Sign in to your account

Lost your password?