-
Notifications
You must be signed in to change notification settings - Fork 0
/
script.js
27 lines (20 loc) · 769 Bytes
/
script.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
// const userform = document.querySelector('form')
// const userInputElement = document.querySelector('regexInput').value
// const submitButton = document.querySelector('button');
// submitButton.addEventListener('click', validateRegex);
// function validateRegex() {
// const regexString = new RegExp(userInputElement)
// // Get the user input value when the button is clicked
// const regexString = userInputElement.value;
// }
function showWarning() {
if (userInputElement == "") {
alert("Please enter a regular expression")
}
}
/* When the user clicks on the button,
toggle between hiding and showing the dropdown content */
function showDropDown() {
document.getElementById("drop").classList.toggle('show')
}
window.onclick