Currently, I have created a component template using Bootstrap that looks like this:
<div class="container">
<div class="row my-4">
<div class="col-md-12 d-flex justify-content-center">
<h2> EVALUACIÓN DE {{ curso }} </h2>
</div>
</div>
<div class="row">
<div class="col-md-9">
<h4>Pregunta 1 de 20 </h4>
<p>¿Cúal de las siguientes alternativas es correcta? </p>
</div>
<div class="col-md-3 d-flex align-items-center" id="icono-reloj">
<img class="mx-2" src="/assets/img/alarm-fill.svg" alt="" width="24" height="24" title="timer"> <span class="mx-3">0:20</span>
</div>
</div>
<div class="row">
<div class="col-md-12">
<div class="list-group" ngFor="let alternativa of alternativas">
<p class="list-group-item list-group-item-action" (click)="avanzar()">este es un ejemplo de una alternativa ...</p>
</div>
</div>
</div>
</div>
I am looking to implement a feature where the question lines will be centered when the browser screen is resized to less than 767.98px.
https://i.stack.imgur.com/1VRND.png
After researching, it seems that achieving this with jQuery is no longer recommended. It is suggested to use the "Renderer2" class instead. So, my question is:
Does the documentation on Renderer2 provide a way to detect the screen size and apply specific Bootstrap classes based on that, such as centering the divs in question when the screen width is less than 767.98px?