I am currently working on a vuejs project with different user levels.
In the "user" level (and public area), there is a background image, while in the "admin" level, a plain white background is displayed.
I have read that using style tags in the template without the scoped keyword can affect everything. I tried this approach but it did not yield the desired results.
After experimenting by placing the styles in the parent div, everything worked almost perfectly. However, on the logged out page, the image does not cover the entire page, leaving a large white space.
Previously, I had applied the CSS directly to the body within the header component. The snippet of CSS code below shows my attempt at applying it to the parent div:
.backgroundCompany{
background-color: white;
}
.backgroundUser{
background: url('/img/bg_img.png') no-repeat center center fixed;
-webkit-background-size: cover;
-moz-background-size: cover;
background-size: cover;
-o-background-size: cover;
min-height: 100%;
}
During my troubleshooting process, I referred to Stackoverflow posts #49516424 and #48172814 for insights.
UPDATED: I have included a partial screenshot of the issues faced when the styles are applied in App.vue as the style for div id=app. While the admin section displays the pure white background correctly, the user section does not cover the entire body. https://i.sstatic.net/UhkEV.png