forked from TFMM/silent-auction
fix: add Tom Select CSS and use window load event
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
<script src="https://cdn.jsdelivr.net/npm/tom-select@2.4.3/dist/js/tom-select.complete.min.js"></script>
|
<script src="https://cdn.jsdelivr.net/npm/tom-select@2.4.3/dist/js/tom-select.complete.min.js"></script>
|
||||||
|
<link href="https://cdn.jsdelivr.net/npm/tom-select@2.4.3/dist/css/tom-select.bootstrap5.min.css" rel="stylesheet">
|
||||||
<script>
|
<script>
|
||||||
document.addEventListener('DOMContentLoaded', () => {
|
window.addEventListener('load', () => {
|
||||||
document.querySelectorAll('select').forEach((el) => {
|
document.querySelectorAll('select').forEach((el) => {
|
||||||
if (!el.classList.contains('tomselected')) {
|
if (!el.classList.contains('tomselected')) {
|
||||||
new TomSelect(el, {
|
new TomSelect(el, {
|
||||||
|
|||||||
Reference in New Issue
Block a user