There are instances wherein while using custom HTML code inside an HTML tile in a page in Jive, the elements inside it appear misaligned. For example, margins inside the details displayed on the HTML tile do not match alignment with other tiles on the same column.
This article provides information about the misalignment of the HTML tiles.
If no style is specified for an element inside a custom HTML tile, the browser defaults will apply. It is, in fact, expected behavior. HTML tiles are intended to contain custom HTML code, which must not be affected by other styles and code within the same page.
For example, if your code includes the
<body> tag, it will get an
8-pixel margin on all sides. This is the default setting that most browsers have. (Please refer to w3schools body tags for more information). The browser renders the tag with the
8-pixel margin because it does not have any other style which points at it. All the other styles on the page affect their respective, specific elements. To avoid the default margin to cause these alignment issues, the default style must be overridden in the custom HTML code. Setting a style that includes a
margin: 0 for the
<body> tag will make the default margin disappear.