diff --git a/src/main/resources/messages_en_GB.properties b/src/main/resources/messages_en_GB.properties index 97f1568c..6d0d22a0 100644 --- a/src/main/resources/messages_en_GB.properties +++ b/src/main/resources/messages_en_GB.properties @@ -127,84 +127,113 @@ changeMetadata.tags==Title,author,date,creation,time,publisher,producer,stats home.fileToPDF.title=Convert file to PDF home.fileToPDF.desc=Convert nearly any file to PDF (DOCX, PNG, XLS, PPT, TXT and more) +fileToPDF.tags=transformation,format,document,picture,slide,text,conversion,office,docs,word,excel,powerpoint home.ocr.title=OCR / Cleanup scans home.ocr.desc=Cleanup scans and detects text from images within a PDF and re-adds it as text. +ocr.tags=recognition,text,image,scan,read,identify,detection,editable + home.extractImages.title=Extract Images home.extractImages.desc=Extracts all images from a PDF and saves them to zip +extractImages.tags=picture,photo,save,archive,zip,capture,grab home.pdfToPDFA.title=PDF to PDF/A home.pdfToPDFA.desc=Convert PDF to PDF/A for long-term storage +pdfToPDFA.tags=archive,long-term,standard,conversion,storage,preservation home.PDFToWord.title=PDF to Word home.PDFToWord.desc=Convert PDF to Word formats (DOC, DOCX and ODT) +PDFToWord.tags=doc,docx,odt,word,transformation,format,conversion,office,microsoft,docfile home.PDFToPresentation.title=PDF to Presentation home.PDFToPresentation.desc=Convert PDF to Presentation formats (PPT, PPTX and ODP) +PDFToPresentation.tags=slides,show,office,microsoft home.PDFToText.title=PDF to RTF (Text) home.PDFToText.desc=Convert PDF to Text or RTF format +PDFToText.tags=richformat,richtextformat,rich text format home.PDFToHTML.title=PDF to HTML home.PDFToHTML.desc=Convert PDF to HTML format +PDFToHTML.tags=web content,browser friendly + home.PDFToXML.title=PDF to XML home.PDFToXML.desc=Convert PDF to XML format +PDFToXML.tags=data-extraction,structured-content,interop,transformation,convert home.ScannerImageSplit.title=Detect/Split Scanned photos home.ScannerImageSplit.desc=Splits multiple photos from within a photo/PDF +ScannerImageSplit.tags=separate,auto-detect,scans,multi-photo,organize home.sign.title=Sign home.sign.desc=Adds signature to PDF by drawing, text or image +sign.tags=authorize,initials,drawn-signature,text-sign,image-signature home.flatten.title=Flatten home.flatten.desc=Remove all interactive elements and forms from a PDF +flatten.tags=static,deactivate,non-interactive,streamline home.repair.title=Repair home.repair.desc=Tries to repair a corrupt/broken PDF +repair.tags=fix,restore,correction,recover home.removeBlanks.title=Remove Blank pages home.removeBlanks.desc=Detects and removes blank pages from a document +removeBlanks.tags=cleanup,streamline,non-content,organize home.compare.title=Compare home.compare.desc=Compares and shows the differences between 2 PDF Documents +compare.tags=differentiate,contrast,changes,analysis home.certSign.title=Sign with Certificate home.certSign.desc=Signs a PDF with a Certificate/Key (PEM/P12) +certSign.tags=authenticate,PEM,P12,official,encrypt home.pageLayout.title=Multi-Page Layout home.pageLayout.desc=Merge multiple pages of a PDF document into a single page +pageLayout.tags=merge,composite,single-view,organize home.scalePages.title=Adjust page size/scale home.scalePages.desc=Change the size/scale of a page and/or its contents. +scalePages.tags=resize,modify,dimension,adapt home.pipeline.title=Pipeline (Advanced) home.pipeline.desc=Run multiple actions on PDFs by defining pipeline scripts +pipeline.tags=automate,sequence,scripted,batch-process home.add-page-numbers.title=Add Page Numbers home.add-page-numbers.desc=Add Page numbers throughout a document in a set location +add-page-numbers.tags=paginate,label,organize,index home.auto-rename.title=Auto Rename PDF File home.auto-rename.desc=Auto renames a PDF file based on its detected header +auto-rename.tags=auto-detect,header-based,organize,relabel home.adjust-contrast.title=Adjust Colors/Contrast home.adjust-contrast.desc=Adjust Contrast, Saturation and Brightness of a PDF +adjust-contrast.tags=color-correction,tune,modify,enhance home.crop.title=Crop PDF home.crop.desc=Crop a PDF to reduce its size (maintains text!) +crop.tags=trim,shrink,edit,shape home.autoSplitPDF.title=Auto Split Pages home.autoSplitPDF.desc=Auto Split Scanned PDF with physical scanned page splitter QR Code +autoSplitPDF.tags=QR-based,separate,scan-segment,organize home.sanitizePdf.title=Sanitize home.sanitizePdf.desc=Remove scripts and other elements from PDF files +sanitizePdf.tags=clean,secure,safe,remove-threats home.URLToPDF.title=URL/Website To PDF home.URLToPDF.desc=Converts any http(s)URL to PDF +URLToPDF.tags=web-capture,save-page,web-to-doc,archive home.HTMLToPDF.title=HTML to PDF home.HTMLToPDF.desc=Converts any HTML file or zip to PDF +HTMLToPDF.tags=markup,web-content,transformation,convert ########################### diff --git a/src/main/resources/static/js/homecard.js b/src/main/resources/static/js/homecard.js index fb962a12..72997a02 100644 --- a/src/main/resources/static/js/homecard.js +++ b/src/main/resources/static/js/homecard.js @@ -7,8 +7,12 @@ function filterCards() { var card = cards[i]; var title = card.querySelector('h5.card-title').innerText; var text = card.querySelector('p.card-text').innerText; - var tags = card.getAttribute('data-tags'); - var content = title + ' ' + text + ' ' + tags; + + // Get the navbar tags associated with the card + var navbarItem = document.querySelector(`a.dropdown-item[href="${card.id}"]`); + var navbarTags = navbarItem ? navbarItem.getAttribute('data-tags') : ''; + + var content = title + ' ' + text + ' ' + navbarTags; if (content.toUpperCase().indexOf(filter) > -1) { card.style.display = ""; @@ -19,6 +23,7 @@ function filterCards() { } + function toggleFavorite(element) { var img = element.querySelector('img'); var card = element.closest('.feature-card'); diff --git a/src/main/resources/static/js/search.js b/src/main/resources/static/js/search.js index e8c9bf9e..a4007206 100644 --- a/src/main/resources/static/js/search.js +++ b/src/main/resources/static/js/search.js @@ -43,9 +43,11 @@ document.querySelector('#navbarSearchInput').addEventListener('input', function( var titleElement = item.querySelector('.icon-text'); var iconElement = item.querySelector('.icon'); var itemHref = item.getAttribute('href'); + var tags = item.getAttribute('data-tags') || ""; // If no tags, default to empty string + if (titleElement && iconElement && itemHref !== '#') { var title = titleElement.innerText; - if (title.toLowerCase().indexOf(searchText) !== -1 && !resultsBox.querySelector(`a[href="${item.getAttribute('href')}"]`)) { + if ((title.toLowerCase().indexOf(searchText) !== -1 || tags.toLowerCase().indexOf(searchText) !== -1) && !resultsBox.querySelector(`a[href="${item.getAttribute('href')}"]`)) { var result = document.createElement('a'); result.href = itemHref; result.classList.add('dropdown-item'); @@ -70,3 +72,4 @@ document.querySelector('#navbarSearchInput').addEventListener('input', function( resultsBox.style.width = window.navItemMaxWidth + 'px'; }); + diff --git a/src/main/resources/templates/fragments/navbar.html b/src/main/resources/templates/fragments/navbar.html index 024b7bc3..5b4b594a 100644 --- a/src/main/resources/templates/fragments/navbar.html +++ b/src/main/resources/templates/fragments/navbar.html @@ -47,16 +47,16 @@
@@ -69,19 +69,19 @@