Skip to content

Instantly share code, notes, and snippets.

@tawhidulIKhan
Created December 7, 2018 11:25
Show Gist options
  • Save tawhidulIKhan/34c735a975b09a7e3b960068347c76e9 to your computer and use it in GitHub Desktop.
Save tawhidulIKhan/34c735a975b09a7e3b960068347c76e9 to your computer and use it in GitHub Desktop.
// Select Tag added bootstrap css class
let selectTags = document.querySelectorAll('select');
selectTags.forEach(function(x){
x.classList.add('form-control');
});
// Table Tag added bootstrap css class
let tableTags = document.querySelectorAll('table');
tableTags.forEach(function(x){
x.classList.add('table');
});
// Sidebar Widget class list modification
let widgetsUl = document.querySelectorAll('.widget ul');
widgetsUl.forEach(function(x){
x.classList.add('list-unstyled');
});
// Footer Widget class list modification
let FwidgetsUl = document.querySelectorAll('.footer-widget ul');
FwidgetsUl.forEach(function(x){
x.classList.add('list-unstyled');
});
// Footer Widget Style
let Fwidgets = document.querySelectorAll('.footer-widget');
let fWCounter = 0;
Fwidgets.forEach(function(x){
if (fWCounter === 4) {
x.classList.add(['col-md-6', 'col-lg-3', 'col-sm-6', 'col-12']);
}else if(fWCounter === 3){
x.classList.add(['col-md-6', 'col-lg-3', 'col-sm-6', 'col-12']);
}else{
x.classList.add(['col']);
}
fWCounter++;
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment