diff --git a/images/login-dark.png b/images/login-dark.png new file mode 100644 index 00000000..672a6967 Binary files /dev/null and b/images/login-dark.png differ diff --git a/images/login-light.png b/images/login-light.png new file mode 100644 index 00000000..7b845c61 Binary files /dev/null and b/images/login-light.png differ diff --git a/images/stirling-home.png b/images/stirling-home.png index 27241bf4..c01af6f9 100644 Binary files a/images/stirling-home.png and b/images/stirling-home.png differ diff --git a/src/main/java/stirling/software/SPDF/controller/api/UserController.java b/src/main/java/stirling/software/SPDF/controller/api/UserController.java index d7dfbcc0..dbb18df5 100644 --- a/src/main/java/stirling/software/SPDF/controller/api/UserController.java +++ b/src/main/java/stirling/software/SPDF/controller/api/UserController.java @@ -9,6 +9,7 @@ import org.springframework.beans.factory.annotation.Autowired; import org.springframework.http.HttpStatus; import org.springframework.http.ResponseEntity; import org.springframework.security.access.prepost.PreAuthorize; +import org.springframework.security.core.Authentication; import org.springframework.security.web.authentication.logout.SecurityContextLogoutHandler; import org.springframework.stereotype.Controller; import org.springframework.ui.Model; @@ -121,8 +122,17 @@ public class UserController { @PreAuthorize("hasRole('ROLE_ADMIN')") - @GetMapping("/admin/deleteUser/{username}") - public String deleteUser(@PathVariable String username) { + @PostMapping("/admin/deleteUser/{username}") + public String deleteUser(@PathVariable String username, Authentication authentication) { + + // Get the currently authenticated username + String currentUsername = authentication.getName(); + + // Check if the provided username matches the current session's username + if (currentUsername.equals(username)) { + throw new IllegalArgumentException("Cannot delete currently logined in user."); + } + userService.deleteUser(username); return "redirect:/addUsers"; } diff --git a/src/main/java/stirling/software/SPDF/controller/api/security/RedactController.java b/src/main/java/stirling/software/SPDF/controller/api/security/RedactController.java index 863c31cd..006968ae 100644 --- a/src/main/java/stirling/software/SPDF/controller/api/security/RedactController.java +++ b/src/main/java/stirling/software/SPDF/controller/api/security/RedactController.java @@ -45,6 +45,7 @@ public class RedactController { @Parameter(description = "List of listOfText to redact from the PDF", required = true, schema = @Schema(type = "string")) @RequestParam("listOfText") String listOfTextString, @RequestParam(value = "useRegex", required = false) boolean useRegex, @RequestParam(value = "wholeWordSearch", required = false) boolean wholeWordSearchBool, + @RequestParam(value = "redactColor", required = false, defaultValue = "#000000") String colorString, @RequestParam(value = "customPadding", required = false) float customPadding, @RequestParam(value = "convertPDFToImage", required = false) boolean convertPDFToImage) throws Exception { @@ -52,12 +53,26 @@ public class RedactController { String[] listOfText = listOfTextString.split("\n"); byte[] bytes = file.getBytes(); PDDocument document = PDDocument.load(new ByteArrayInputStream(bytes)); + + Color redactColor; + try { + if (!colorString.startsWith("#")) { + colorString = "#" + colorString; + } + redactColor = Color.decode(colorString); + } catch (NumberFormatException e) { + logger.warn("Invalid color string provided. Using default color BLACK for redaction."); + redactColor = Color.BLACK; + } + + + for (String text : listOfText) { text = text.trim(); System.out.println(text); TextFinder textFinder = new TextFinder(text, useRegex, wholeWordSearchBool); List foundTexts = textFinder.getTextLocations(document); - redactFoundText(document, foundTexts, customPadding); + redactFoundText(document, foundTexts, customPadding,redactColor); } @@ -88,13 +103,13 @@ public class RedactController { } - private void redactFoundText(PDDocument document, List blocks, float customPadding) throws IOException { + private void redactFoundText(PDDocument document, List blocks, float customPadding, Color redactColor) throws IOException { var allPages = document.getDocumentCatalog().getPages(); for (PDFText block : blocks) { var page = allPages.get(block.getPageIndex()); PDPageContentStream contentStream = new PDPageContentStream(document, page, PDPageContentStream.AppendMode.APPEND, true, true); - contentStream.setNonStrokingColor(Color.BLACK); + contentStream.setNonStrokingColor(redactColor); float padding = (block.getY2() - block.getY1()) * 0.3f + customPadding; PDRectangle pageBox = page.getBBox(); contentStream.addRect(block.getX1(), pageBox.getHeight() - block.getY1() - padding, block.getX2() - block.getX1(), block.getY2() - block.getY1() + 2 * padding); @@ -103,4 +118,5 @@ public class RedactController { } } + } diff --git a/src/main/java/stirling/software/SPDF/controller/web/AccountWebController.java b/src/main/java/stirling/software/SPDF/controller/web/AccountWebController.java index daf162dc..c4c747aa 100644 --- a/src/main/java/stirling/software/SPDF/controller/web/AccountWebController.java +++ b/src/main/java/stirling/software/SPDF/controller/web/AccountWebController.java @@ -58,14 +58,13 @@ public class AccountWebController { @Autowired private UserRepository userRepository; // Assuming you have a repository for user operations - @Autowired - private UserService userService; // Assuming you have a repository for user operations @PreAuthorize("hasRole('ROLE_ADMIN')") @GetMapping("/addUsers") - public String showAddUserForm(Model model) { + public String showAddUserForm(Model model, Authentication authentication) { List allUsers = userRepository.findAll(); model.addAttribute("users", allUsers); + model.addAttribute("currentUsername", authentication.getName()); return "addUsers"; } diff --git a/src/main/resources/messages_ar_AR.properties b/src/main/resources/messages_ar_AR.properties index 290cec4c..54e816e6 100644 --- a/src/main/resources/messages_ar_AR.properties +++ b/src/main/resources/messages_ar_AR.properties @@ -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 diff --git a/src/main/resources/messages_ca_CA.properties b/src/main/resources/messages_ca_CA.properties index 99075d55..2c25a115 100644 --- a/src/main/resources/messages_ca_CA.properties +++ b/src/main/resources/messages_ca_CA.properties @@ -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 diff --git a/src/main/resources/messages_de_DE.properties b/src/main/resources/messages_de_DE.properties index 43c24f65..ccaaad84 100644 --- a/src/main/resources/messages_de_DE.properties +++ b/src/main/resources/messages_de_DE.properties @@ -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 diff --git a/src/main/resources/messages_en_GB.properties b/src/main/resources/messages_en_GB.properties index 05a4bd91..03362eec 100644 --- a/src/main/resources/messages_en_GB.properties +++ b/src/main/resources/messages_en_GB.properties @@ -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 diff --git a/src/main/resources/messages_en_US.properties b/src/main/resources/messages_en_US.properties index dc7c93f8..38807e3d 100644 --- a/src/main/resources/messages_en_US.properties +++ b/src/main/resources/messages_en_US.properties @@ -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 diff --git a/src/main/resources/messages_es_ES.properties b/src/main/resources/messages_es_ES.properties index 8ece9c78..37edd2cf 100644 --- a/src/main/resources/messages_es_ES.properties +++ b/src/main/resources/messages_es_ES.properties @@ -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 diff --git a/src/main/resources/messages_eu_ES.properties b/src/main/resources/messages_eu_ES.properties index 75edb5a4..91e888e2 100644 --- a/src/main/resources/messages_eu_ES.properties +++ b/src/main/resources/messages_eu_ES.properties @@ -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 diff --git a/src/main/resources/messages_fr_FR.properties b/src/main/resources/messages_fr_FR.properties index dad35713..eb47e7e0 100644 --- a/src/main/resources/messages_fr_FR.properties +++ b/src/main/resources/messages_fr_FR.properties @@ -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 diff --git a/src/main/resources/messages_it_IT.properties b/src/main/resources/messages_it_IT.properties index 0f150f8c..b302b171 100644 --- a/src/main/resources/messages_it_IT.properties +++ b/src/main/resources/messages_it_IT.properties @@ -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 diff --git a/src/main/resources/messages_ja_JP.properties b/src/main/resources/messages_ja_JP.properties index 46a45d48..fbb28254 100644 --- a/src/main/resources/messages_ja_JP.properties +++ b/src/main/resources/messages_ja_JP.properties @@ -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 diff --git a/src/main/resources/messages_ko_KR.properties b/src/main/resources/messages_ko_KR.properties index 50a8a7d0..39471e4a 100644 --- a/src/main/resources/messages_ko_KR.properties +++ b/src/main/resources/messages_ko_KR.properties @@ -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 diff --git a/src/main/resources/messages_nl_NL.properties b/src/main/resources/messages_nl_NL.properties index 331ecd89..1043641a 100644 --- a/src/main/resources/messages_nl_NL.properties +++ b/src/main/resources/messages_nl_NL.properties @@ -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 diff --git a/src/main/resources/messages_pl_PL.properties b/src/main/resources/messages_pl_PL.properties index bac7aa5f..3fa81afb 100644 --- a/src/main/resources/messages_pl_PL.properties +++ b/src/main/resources/messages_pl_PL.properties @@ -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 diff --git a/src/main/resources/messages_pt_BR.properties b/src/main/resources/messages_pt_BR.properties index 3a89624e..d1645d3e 100644 --- a/src/main/resources/messages_pt_BR.properties +++ b/src/main/resources/messages_pt_BR.properties @@ -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 diff --git a/src/main/resources/messages_ro_RO.properties b/src/main/resources/messages_ro_RO.properties index bc038897..98b58a58 100644 --- a/src/main/resources/messages_ro_RO.properties +++ b/src/main/resources/messages_ro_RO.properties @@ -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 diff --git a/src/main/resources/messages_ru_RU.properties b/src/main/resources/messages_ru_RU.properties index 7e4121ee..08f86f6b 100644 --- a/src/main/resources/messages_ru_RU.properties +++ b/src/main/resources/messages_ru_RU.properties @@ -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 diff --git a/src/main/resources/messages_sv_SE.properties b/src/main/resources/messages_sv_SE.properties index 139c9ca2..fd3fbfd0 100644 --- a/src/main/resources/messages_sv_SE.properties +++ b/src/main/resources/messages_sv_SE.properties @@ -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 diff --git a/src/main/resources/messages_zh_CN.properties b/src/main/resources/messages_zh_CN.properties index 3bfdab32..1eea17a1 100644 --- a/src/main/resources/messages_zh_CN.properties +++ b/src/main/resources/messages_zh_CN.properties @@ -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 diff --git a/src/main/resources/settings.yml.template b/src/main/resources/settings.yml.template index 4cac795b..5d9d6118 100644 --- a/src/main/resources/settings.yml.template +++ b/src/main/resources/settings.yml.template @@ -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: diff --git a/src/main/resources/templates/addUsers.html b/src/main/resources/templates/addUsers.html index c590988a..18d32557 100644 --- a/src/main/resources/templates/addUsers.html +++ b/src/main/resources/templates/addUsers.html @@ -20,23 +20,26 @@ - - - - - - - - - - - - - - -
UsernameRolesActions
- Delete -
+ + + Username + Roles + Actions + + + + + + + +
+ +
+ + + + +

Add New User

diff --git a/src/main/resources/templates/security/auto-redact.html b/src/main/resources/templates/security/auto-redact.html index 32887d92..2af1fa45 100644 --- a/src/main/resources/templates/security/auto-redact.html +++ b/src/main/resources/templates/security/auto-redact.html @@ -21,6 +21,37 @@ +
+ + +
+ + + + + + + +