diff --git a/neutralino.config.json b/neutralino.config.json
index 570bdfa..e92cf28 100644
--- a/neutralino.config.json
+++ b/neutralino.config.json
@@ -16,7 +16,8 @@
"nativeAllowList": [
"app.*",
"os.*",
- "debug.log"
+ "debug.log",
+ "clipboard.*"
],
"globalVariables": {
"TEST1": "Hello",
diff --git a/src/views/cleaner/cleaner.css b/src/views/cleaner/cleaner.css
index 8f718a2..7c5e7be 100644
--- a/src/views/cleaner/cleaner.css
+++ b/src/views/cleaner/cleaner.css
@@ -1,3 +1,4 @@
.sidebar {
border-left: 1px solid #b1b1b1;
+ transition: all 0.3s;
}
\ No newline at end of file
diff --git a/src/views/cleaner/cleaner.js b/src/views/cleaner/cleaner.js
index 6051237..6b6bbe4 100644
--- a/src/views/cleaner/cleaner.js
+++ b/src/views/cleaner/cleaner.js
@@ -52,13 +52,11 @@
});
}
- function clean() {
+ async function clean() {
console.log("Cleaning...");
- // Read the input from the textarea
let outputText = $("#input-textarea").val();
- // Process each rule
config.rules.forEach(rule => {
if (rule.enabled) {
const searchValue = rule.ignoreCase ? new RegExp(rule.strToReplace, 'gi') : new RegExp(rule.strToReplace, 'g');
@@ -66,10 +64,12 @@
}
});
- // Output the processed text to the output textarea
$("#output-textarea").val(outputText);
-
- // Display the output container
$("#output-container-div").removeClass("visually-hidden");
+
+ if($("#enable-auto-copy").prop("checked")) {
+ console.log("Copying result to clipboard...")
+ await Neutralino.clipboard.writeText(outputText);
+ }
}
})();
\ No newline at end of file
diff --git a/src/views/config/config.html b/src/views/config/config.html
index 7cac645..d332049 100644
--- a/src/views/config/config.html
+++ b/src/views/config/config.html
@@ -17,18 +17,24 @@
Create new rule
-