Seeking assistance with styling AngularJS directives, specifically a Bootstrap directive for progress bars within my project. Utilizing it within a custom div class.
<div class="diagnostics-widget-modal">
<div class="modal-header">
<h3>SOME CONTENT</h3>
</div>
<div class="modal-body">
<div class=left-workflow-area>
<uib-progressbar value="55"></uib-progressbar>
</div>
</div>
</div>
Upon page execution, the HTML directive renders correctly resulting in the following code snippet.
<div class="modal-body">
<div class="left-workflow-area">
<div class="progressbar ng-isolate-scope" value="55">
<div class="progress">
<div class="progress-bar" ng-class="type && 'progress-bar-' + type" role="progressbar" aria-valuenow="55" aria-valuemin="0" aria-valuemax="100" ng-style="{width: (percent < 100 ? percent: 100) + '%'}" aria-valuetext="%" aria-labelledby="" ng-transclude="" style="width: 100%;"> </div>
</div>
</div>
</div>
</div>
Desiring to apply styles to the "progress" and "progress-bar" classes, I have defined a SCSS file for left-workflow-area.
.diagnostics-widget-modal {
height: 100%;
width: 100%;
.modal-header {
height: 71px;
padding: 0 12px 0px 36px;
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
.modal-close {
width: 72px;
height: 72px;
display: flex;
align-items: center;
justify-content: center;
}
}
.modal-body {
display: flex;
flex-direction: row;
justify-content: space-between;
height: 90%;
.left-workflow-area {
display: flex;
width: 70%;
height: 100%;
}
.right-workflow-area {
display: flex;
width: 30%;
height: 100%;
}
}
Noticing that the styles from the directive's CSS file are not being applied as intended.
.progress {
height: 20px;
margin-bottom: 20px;
overflow: hidden;
background-color: #f5f5f5
border-radius: 4px;
box-shadow: inset 0 1px 2px rgba (0,0,0,.1);
}
While applying the class directly inside "left-workflow-area" works, the goal is to separate this style as the directive will be used across various sections of the application. Seeking guidance on how to achieve this separation?