I'm currently working on a website and I want to incorporate a dynamic bootstrap calendar. The issue I'm facing is that my site has its own style sheet, but the calendar comes with its own styles. When I try to integrate the two, it seems like elements from one stylesheet are conflicting with elements from the other (for example, the calendar styles are messing up my header, and my styles are making the calendar look asymmetric).
I attempted to solve this by nesting classes and applying them to a div where I placed the calendar code, but unfortunately, that didn't work.
.calendar_content{
sub {
bottom: -.25em; }
sup {
top: -.5em; }
a {
color: #007bff;
text-decoration: none;
background-color: transparent; }
a:hover {
color: #0056b3;
text-decoration: underline; }
a:not([href]):not([tabindex]) {
color: inherit;
text-decoration: none; }
a:not([href]):not([tabindex]):hover, a:not([href]):not([tabindex]):focus {
color: inherit;
text-decoration: none; }
a:not([href]):not([tabindex]):focus {
outline: 0; }
pre,
code,
kbd,
samp {
font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
font-size: 1em; }
pre {
margin-top: 0;
margin-bottom: 1rem;
overflow: auto; }
}
<link href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="c1a3aeaeb5b2b5b3a0b181f4eff2eff3">[email protected]</a>/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-T3c6CoIi6uLrA9TneNEoa7RxnatzjcDSCmG1MXxSR1GAsXEV/Dwwykc2MPK8M2HN" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="55373a3a21262127342515607b667b66">[email protected]</a>/dist/js/bootstrap.bundle.min.js" integrity="sha384-C6RzsynM9kWDrMNeT87bh95OGNyZPhcTNXj1NW7RuBCsyN/o0jlpcV8Qyq46cDfL" crossorigin="anonymous"></script>
<div class="calendar_content"> Calendar code </div>
I also tried using an id approach, but that didn't resolve the issue either.
CSS: #calendar_content{the entire stylesheet content}
HTML: <div id="calendar_content"> Calendar code </div>
Additionally, there are JavaScript files involved, but I don't think they're impacting how the site looks.