|
|
@ -99,14 +99,14 @@ document.addEventListener("DOMContentLoaded", function () { |
|
|
|
return textFile; |
|
|
|
}; |
|
|
|
|
|
|
|
var download = document.getElementById("downloadFirstEditor"); |
|
|
|
var download2 = document.getElementById("downloadSpecifications"); |
|
|
|
var downloadEditorText = document.getElementById("downloadFirstEditor"); |
|
|
|
var downloadSpecifications = document.getElementById("downloadSpecifications"); |
|
|
|
|
|
|
|
var input1 = editor; |
|
|
|
var input2 = editor2; |
|
|
|
|
|
|
|
// Add an event listener to the button for the click event
|
|
|
|
download.addEventListener("click", function () { |
|
|
|
downloadEditorText.addEventListener("click", function () { |
|
|
|
// Check if the editor is empty
|
|
|
|
if (!editor.getValue()) { |
|
|
|
Toastify({ |
|
|
@ -137,7 +137,7 @@ document.addEventListener("DOMContentLoaded", function () { |
|
|
|
} |
|
|
|
}); |
|
|
|
|
|
|
|
download2.addEventListener("click", function () { |
|
|
|
downloadSpecifications.addEventListener("click", function () { |
|
|
|
if (!editor2.getValue()) { |
|
|
|
Toastify({ |
|
|
|
text: "Specifications field empty", |
|
|
|