5uck1t commited on
Commit
b65a903
·
verified ·
1 Parent(s): 0cb9223

they still dont do anything

Browse files
Files changed (1) hide show
  1. script.js +8 -0
script.js CHANGED
@@ -19,6 +19,14 @@ document.addEventListener('DOMContentLoaded', function() {
19
  <i data-feather="trash-2" class="w-3 h-3 mr-1"></i> Remove
20
  </button>
21
  `;
 
 
 
 
 
 
 
 
22
  });
23
 
24
  // Add relation field
 
19
  <i data-feather="trash-2" class="w-3 h-3 mr-1"></i> Remove
20
  </button>
21
  `;
22
+ inputContainer.appendChild(inputGroup);
23
+ feather.replace();
24
+
25
+ // Add event listener to remove button
26
+ const removeBtn = inputGroup.querySelector('.remove-input');
27
+ removeBtn.addEventListener('click', () => {
28
+ inputGroup.remove();
29
+ });
30
  });
31
 
32
  // Add relation field