redact allow colors, bug fixes

This commit is contained in:
Anthony Stirling
2023-08-30 22:52:38 +01:00
parent 8509a16d6e
commit 0fc29de02c
27 changed files with 403 additions and 95 deletions

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,17 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -320,6 +330,7 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Color
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=afficher,javascript,js
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Verwijderen
username=Gebruikersnaam
password=Wachtwoord
welcome=Welkom
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JavaScript
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -35,7 +35,20 @@ delete=Delete
username=Username
password=Password
welcome=Welcome
=Property
##########################
### TODO: Translate ###
##########################
property=Property
black=Black
white=White
red=Red
green=Green
blue=Blue
custom=Custom...
#############
# NAVBAR #
@@ -309,9 +322,6 @@ showJS.tags=JS
# #
###########################
#login
##########################
### TODO: Translate ###
##########################
login.title=Sign in
login.signin=Sign in
login.rememberme=Remember me
@@ -323,6 +333,10 @@ login.signinTitle=Please sign in
#auto-redact
autoRedact.title=Auto Redact
autoRedact.header=Auto Redact
##########################
### TODO: Translate ###
##########################
autoRedact.colorLabel=Colour
autoRedact.textsToRedactLabel=Text to Redact (line-separated)
autoRedact.textsToRedactPlaceholder=e.g. \nConfidential \nTop-Secret
autoRedact.useRegexLabel=Use Regex

View File

@@ -6,7 +6,7 @@ security:
enableLogin: false # set to 'true' to enable login
initialLogin:
username: 'username' # Specify the initial username for first boot (e.g. 'admin')
password: 'password'# Specify the initial password for first boot (e.g. 'password123')
password: 'password' # Specify the initial password for first boot (e.g. 'password123')
csrfDisabled: true
system:

View File

@@ -20,23 +20,26 @@
<table class="table">
<thead>
<tr>
<th th:text="#{username}">Username</th>
<th th:text="#{adminUserSettings.roles}">Roles</th>
<th th:text="#{adminUserSettings.actions}">Actions</th>
</tr>
</thead>
<tbody>
<tr th:each="user : ${users}">
<td th:text="${user.username}"></td>
<td th:text="${user.getRolesAsString()}"></td>
<td>
<a th:href="@{'/admin/deleteUser/' + ${user.username}}" th:text="#{delete}">Delete</a>
</td>
</tr>
</tbody>
</table>
<thead>
<tr>
<th th:text="#{username}">Username</th>
<th th:text="#{adminUserSettings.roles}">Roles</th>
<th th:text="#{adminUserSettings.actions}">Actions</th>
</tr>
</thead>
<tbody>
<tr th:each="user : ${users}">
<td th:text="${user.username}"></td>
<td th:text="${user.getRolesAsString()}"></td>
<td>
<form th:if="${user.username != currentUsername}" th:action="@{'/admin/deleteUser/' + ${user.username}}" method="post">
<button type="submit" th:text="#{delete}">Delete</button>
</form>
</td>
</tr>
</tbody>
</table>
<h2 th:text="#{adminUserSettings.addUser}">Add New User</h2>

View File

@@ -21,6 +21,37 @@
<textarea class="form-control" id="listOfText" name="listOfText" rows="4" required th:placeholder="#{autoRedact.textsToRedactPlaceholder}"></textarea>
</div>
<div class="mb-3">
<label for="defaultColor" class="form-label" th:text="#{autoRedact.colorLabel}">Color</label>
<select class="form-control" id="defaultColor" name="defaultColor" onchange="handleColorChange(this.value)">
<option value="#000000" th:text="#{black}">Black</option>
<option value="#FFFFFF" th:text="#{white}">White</option>
<option value="#FF0000" th:text="#{red}">Red</option>
<option value="#00FF00" th:text="#{green}">Green</option>
<option value="#0000FF" th:text="#{blue}">Blue</option>
<option value="custom" th:text="#{custom}">Custom...</option>
</select>
</div>
<!-- Custom Color Input -->
<div class="mb-3" id="customColorContainer" style="display: none;">
<label for="customColor" class="form-label" th:text="#{autoRedact.colorLabel}">Custom Color</label>
<input type="text" class="form-control" id="customColor" name="redactColor" placeholder="#FF00FF">
</div>
<script>
function handleColorChange(selectedValue) {
if (selectedValue === "custom") {
document.getElementById('customColorContainer').style.display = 'block';
} else {
document.getElementById('customColorContainer').style.display = 'none';
document.getElementById('customColor').value = selectedValue;
}
}
</script>
<div class="mb-3 form-check">
<input type="checkbox" class="form-check-input" id="useRegex" name="useRegex">
<label class="form-check-label" for="useRegex" th:text="#{autoRedact.useRegexLabel}"></label>