Added btn-responsive style class to define buttons to go full block level while in mobile and to stay defined size in non mobile response

This commit is contained in:
johnnyq 2025-01-28 17:14:47 -05:00
parent a4c9b4efa4
commit 706a77c5d3
2 changed files with 25 additions and 1 deletions

View File

@ -39,6 +39,30 @@ header("X-Frame-Options: DENY");
<link href='plugins/daterangepicker/daterangepicker.css' rel='stylesheet' />
<link href="plugins/toastr/toastr.min.css" rel="stylesheet">
<link href="plugins/DataTables/datatables.min.css" rel="stylesheet">
<!-- CSS to allow regular button to show as block button in mobile response view using the class btn-responsive -->
<style>
/*
For screens below 576px (xs):
- Make the button full-width, display:block
*/
@media (max-width: 575.98px) {
.btn-responsive {
display: block;
width: 100%;
}
}
/*
For screens 576px (sm) and above:
- Revert to an inline style
*/
@media (min-width: 576px) {
.btn-responsive {
display: inline-block;
width: auto;
}
}
</style>
<!-- jQuery -->
<script src="plugins/jquery/jquery.min.js"></script>

View File

@ -56,7 +56,7 @@ require_once "includes/inc_all_user.php";
</div>
</div>
<button type="submit" name="edit_your_user_details" class="btn btn-primary"><i class="fas fa-check mr-2"></i>Save</button>
<button type="submit" name="edit_your_user_details" class="btn btn-primary btn-responsive"><i class="fas fa-check mr-2"></i>Save</button>
</div>
</div>