Projekt

Obecné

Profil

« Předchozí | Další » 

Revize c93d8df3

Přidáno uživatelem castic96 před téměř 5 roky(ů)

Re #8027: Checkbox pro spell checker FE
- checkbox viditelný pouze na stránce /search
- doplnění názvu checkboxu do nápovědy

Zobrazit rozdíly:

fe/fulltextsearch/src/app/components/shared-components/search-box/search-box.component.css
65 65
  padding: 6pt 6pt 1pt;
66 66
  background-color: white !important;
67 67
  color: var(--text-grey);
68
  display: none;
69
}
70

  
71
.is-visible {
72
  display: initial;
73
}
74

  
75
.is-not-visible {
76
  display: none;
68 77
}
fe/fulltextsearch/src/app/components/shared-components/search-box/search-box.component.html
13 13
      <button class="btn btn-outline-secondary" type="button" (click)="onSubmit()">{{'app-search-box.search' | translate}}</button>
14 14
    </div>
15 15
  </div>
16
    <mat-checkbox color="warn" (change)="onToggle()">{{'app-search-box.spell-check' | translate}}</mat-checkbox>
16
    <mat-checkbox [ngClass] = "setClasses()" color="warn" (change)="onToggle()">{{'app-search-box.spell-check' | translate}}</mat-checkbox>
17 17
</div>
fe/fulltextsearch/src/app/components/shared-components/search-box/search-box.component.ts
23 23

  
24 24
  onToggle() {
25 25
    this.enableSpellCheck = !this.enableSpellCheck;
26
    console.log('kontrola spell check: ' + this.enableSpellCheck);
27 26
  }
28 27

  
29 28
  onSubmit(): void {
......
44 43
      this.queryServiceSubscription$.unsubscribe();
45 44
    }
46 45
  }
46

  
47
  setClasses() {
48
    let classes;
49

  
50
    if (this.router.url === '/') {
51
      classes = {
52
        'is-not-visible': true,
53
        'is-visible': false
54
      };
55
    } else {
56
      classes = {
57
        'is-not-visible': false,
58
        'is-visible': true
59
      };
60
    }
61
    return classes;
62
  }
47 63
}
fe/fulltextsearch/src/assets/i18n/cz-lang.json
56 56
    "upload-title": "Nahrávání souborů",
57 57
    "upload-text": "Nahrávání souborů probíhá na stránce <b>Nahrát</b>, která je dostupná z hlavní lišty.<br><br>Tlačítko <b>Vybrat soubory</b> slouží ke zvolení souborů k nahrání. <br><br>Tlačítko <b>Nahrát</b> zvolené soubory nahraje do webové aplikace.<br><br><b>Soubor formátu XML a jeho původní obrazový soubor, ze kterého byl vytvořen, je nutné nahrávat společně a se stejným názvem!</b><br><br>Lze nahrávat libovolný počet souborů najednou.",
58 58
    "search-title": "Vyhledávání",
59
    "search-text": "Vyhledávání probíhá na stránce <b>Vyhledat</b>, která je dostupná z hlavní lišty.<br><br>Hledaný výraz napište do textového pole a potvrďte tlačítkem <b>Vyhledat</b>. Po dokončení vyhledávání se zobrazí nalezené výsledky.<br><br>Zaškrtávací tlačítko <b>???</b> slouží k zapnutí/vypnutí kontroly překlepů. Když je tlačítko zaškrtnuté, tak při nenalezení žádného výskytu hledaného výrazu se vyhledá výraz jemu podobný do maximální vzdálenosti slov 2.<br><br>Hledaný výraz může obsahovat:<ul><li><b>Symbol *</b> zastupuje žádný nebo libovolný počet znaků.<ul><li>Například: <b>tes*</b> – vyhledá všechna slova začínající slovem <b>tes</b></li></ul></li><li><b>Symbol ?</b> zastupuje právě jeden znak.<ul><li>Například: <b>tes?</b> – vyhledá všechna slova začínající slovem <b>tes</b> a následována právě jedním znakem</li></ul></li><li><b>Symbol ~</b> na konci hledaného výrazu slouží k vyhledání všech výrazů do určité maximální vzdálenosti od hledaného výrazu.<ul><li> Například: <b>test~2</b> – vyhledá slovo <b>test</b> a všechna slova jemu blízká do maximální vzdálenosti slov 2</li></ul></li><li><b>Symbol && nebo výraz AND</b> slouží k nalezení dokumentů, kde se vykytuje všechny z hledaných výrazů zároveň.<ul><li> Například: <b>test AND test2</b> – vyhledá všechny dokumenty se slovy <b>test a test2</b> zároveň</li></ul></li><li><b>Symbol ! nebo výraz NOT</b> slouží k nalezení výsledků, kde se zadaný výraz nevyskytuje.<ul><li> Například: <b>test NOT test2</b> – vyhledá všechny výskyty slova <b>test</b>, kde není slovo <b>test2</b></li></ul></li><li><b>Symbol || nebo výraz OR</b> slouží k nalezení dokumentů, kde se vykytuje alespoň jeden z hledaných výrazů.<ul><li>Například: <b>test OR test2</b> – vyhledá všechny dokumenty se slovem <b>test</b> nebo <b>test2</b> nebo s oběma zároveň</li></ul></li></ul>Speciální symboly, které hledaný výraz nesmí obsahovat:  <b>+  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  /</b><br><br>Pokud je nutné použít některý z těchto symbolů, tak je nutné před něj přidat tento symbol:  <b>\\</b>",
59
    "search-text": "Vyhledávání probíhá na stránce <b>Vyhledat</b>, která je dostupná z hlavní lišty.<br><br>Hledaný výraz napište do textového pole a potvrďte tlačítkem <b>Vyhledat</b>. Po dokončení vyhledávání se zobrazí nalezené výsledky.<br><br>Zaškrtávací tlačítko <b>Zapnout automatickou kontrolu</b> slouží k zapnutí/vypnutí kontroly překlepů. Když je tlačítko zaškrtnuté, tak při nenalezení žádného výskytu hledaného výrazu se vyhledá výraz jemu podobný do maximální vzdálenosti slov 2.<br><br>Hledaný výraz může obsahovat:<ul><li><b>Symbol *</b> zastupuje žádný nebo libovolný počet znaků.<ul><li>Například: <b>tes*</b> – vyhledá všechna slova začínající slovem <b>tes</b></li></ul></li><li><b>Symbol ?</b> zastupuje právě jeden znak.<ul><li>Například: <b>tes?</b> – vyhledá všechna slova začínající slovem <b>tes</b> a následována právě jedním znakem</li></ul></li><li><b>Symbol ~</b> na konci hledaného výrazu slouží k vyhledání všech výrazů do určité maximální vzdálenosti od hledaného výrazu.<ul><li> Například: <b>test~2</b> – vyhledá slovo <b>test</b> a všechna slova jemu blízká do maximální vzdálenosti slov 2</li></ul></li><li><b>Symbol && nebo výraz AND</b> slouží k nalezení dokumentů, kde se vykytuje všechny z hledaných výrazů zároveň.<ul><li> Například: <b>test AND test2</b> – vyhledá všechny dokumenty se slovy <b>test a test2</b> zároveň</li></ul></li><li><b>Symbol ! nebo výraz NOT</b> slouží k nalezení výsledků, kde se zadaný výraz nevyskytuje.<ul><li> Například: <b>test NOT test2</b> – vyhledá všechny výskyty slova <b>test</b>, kde není slovo <b>test2</b></li></ul></li><li><b>Symbol || nebo výraz OR</b> slouží k nalezení dokumentů, kde se vykytuje alespoň jeden z hledaných výrazů.<ul><li>Například: <b>test OR test2</b> – vyhledá všechny dokumenty se slovem <b>test</b> nebo <b>test2</b> nebo s oběma zároveň</li></ul></li></ul>Speciální symboly, které hledaný výraz nesmí obsahovat:  <b>+  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  /</b><br><br>Pokud je nutné použít některý z těchto symbolů, tak je nutné před něj přidat tento symbol:  <b>\\</b>",
60 60
    "contact-admin-title": "Kontakt na administrátora"
61 61
  }
62 62
}
fe/fulltextsearch/src/assets/i18n/de-lang.json
56 56
    "upload-title": "Datei-Upload",
57 57
    "upload-text": "Das Hochladen von Dateien erfolgt auf der Seite <b>Hochladen</b>, auf die über die Hauptleiste zugegriffen werden kann.<br><br>Mit der Schaltfläche <b>Dateien auswählen</b> können Sie auswählen, welche Dateien hochgeladen werden sollen.<br><br>Mit der Schaltfläche <b>Hochladen</b> werden ausgewählte Dateien in die Webanwendung hochgeladen.<br><br><b> Die XML-Datei und ihre Quellbilddatei müssen zusammen und mit derselben hochgeladen werden name!</b><br><br>Sie können beliebig viele Dateien gleichzeitig hochladen.",
58 58
    "search-title": "Suchen",
59
    "search-text": "Die Suche wird auf der Seite <b>Suche</b> durchgeführt, auf die über die Hauptleiste zugegriffen werden kann.<br><br>Geben Sie Ihren Suchausdruck in das Textfeld ein und bestätigen Sie ihn mit der <b>Suche</b> Taste. Wenn die Suche abgeschlossen ist, werden die Ergebnisse angezeigt.<br><br>Verwenden Sie das Kontrollkästchen <b>???</b>, um die Rechtschreibprüfung ein- und auszuschalten. Wenn diese Option aktiviert ist und kein Ergebnis des Suchausdrucks gefunden wird, wird stattdessen ein ähnlicher Ausdruck bis zum maximalen Abstand von 2 zwischen den Wörtern gesucht.<br><br>Der Suchausdruck kann Folgendes enthalten:<ul><li><b>Symbol *</b> steht für Null oder eine beliebige Anzahl von Zeichen.<ul><li>Beispiel: <b>tes *</b> - sucht nach allen Wörtern, die mit <b>tes</b> beginnenli</li></ul></li><li><b>Symbol ?</b> repräsentiert genau ein Zeichen.<ul><li>Zum Beispiel: <b>tes ?</b> - findet alle Wörter beginnend mit <b>tes</b> und gefolgt von genau einem Zeichen</li></ul></li><li><b>Symbol ~</b> am Ende des Suchausdrucks wird zum Suchen verwendet alle Wörter innerhalb eines bestimmten maximalen Abstands zwischen ihnen und dem Suchausdruck.<ul><li> Zum Beispiel: <b>test ~ 2</b> - findet das Wort <b>test</b> und alle Wörter in der Nähe von bis zu einem maximalen Abstand von 2 </li></ul></li><li><b>Symbol && und der Ausdruck AND</b> werden verwendet, um Dokumente zu finden, in denen sich ALLE Suchausdrücke befinden.<ul><li>Zum Beispiel: <b>test AND test2</b> - findet al l Dokumente mit den Worten <b>test</b> und <b>test2</b></li></ul></li><li><b>Symbol ! oder der Ausdruck NOT</b> wird verwendet, um Ergebnisse zu finden, bei denen der angegebene Ausdruck nicht vorkommt.<ul><li>Beispiel: <b>test NOT test2</b> - findet alle Vorkommen des Wortes <b>test</b>, wobei das Wort <b>test2</b> nicht lautet.</li></ul></li><li><b>Symbol || oder der Ausdruck OR</b> wird verwendet, um Dokumente zu finden, bei denen MINDESTENS EINER des Suchausdrucks lautet.<ul><li>Beispiel: <b>test OR test2</b> - findet alle Dokumente mit dem Wort <b>test</b> oder <b>test2</b> oder beides</li></ul></ul></ul>Spezielle Symbole, die ein Suchausdruck nicht enthalten darf: <b>  +  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  /  </b><br><br>Wenn Sie eines dieser Symbole verwenden müssen, müssen Sie dieses Symbol davor hinzufügen: <b>\\</b>",
59
    "search-text": "Die Suche wird auf der Seite <b>Suche</b> durchgeführt, auf die über die Hauptleiste zugegriffen werden kann.<br><br>Geben Sie Ihren Suchausdruck in das Textfeld ein und bestätigen Sie ihn mit der <b>Suche</b> Taste. Wenn die Suche abgeschlossen ist, werden die Ergebnisse angezeigt.<br><br>Verwenden Sie das Kontrollkästchen <b>Ermöglichen autocorrect</b>, um die Rechtschreibprüfung ein- und auszuschalten. Wenn diese Option aktiviert ist und kein Ergebnis des Suchausdrucks gefunden wird, wird stattdessen ein ähnlicher Ausdruck bis zum maximalen Abstand von 2 zwischen den Wörtern gesucht.<br><br>Der Suchausdruck kann Folgendes enthalten:<ul><li><b>Symbol *</b> steht für Null oder eine beliebige Anzahl von Zeichen.<ul><li>Beispiel: <b>tes *</b> - sucht nach allen Wörtern, die mit <b>tes</b> beginnenli</li></ul></li><li><b>Symbol ?</b> repräsentiert genau ein Zeichen.<ul><li>Zum Beispiel: <b>tes ?</b> - findet alle Wörter beginnend mit <b>tes</b> und gefolgt von genau einem Zeichen</li></ul></li><li><b>Symbol ~</b> am Ende des Suchausdrucks wird zum Suchen verwendet alle Wörter innerhalb eines bestimmten maximalen Abstands zwischen ihnen und dem Suchausdruck.<ul><li> Zum Beispiel: <b>test ~ 2</b> - findet das Wort <b>test</b> und alle Wörter in der Nähe von bis zu einem maximalen Abstand von 2 </li></ul></li><li><b>Symbol && und der Ausdruck AND</b> werden verwendet, um Dokumente zu finden, in denen sich ALLE Suchausdrücke befinden.<ul><li>Zum Beispiel: <b>test AND test2</b> - findet al l Dokumente mit den Worten <b>test</b> und <b>test2</b></li></ul></li><li><b>Symbol ! oder der Ausdruck NOT</b> wird verwendet, um Ergebnisse zu finden, bei denen der angegebene Ausdruck nicht vorkommt.<ul><li>Beispiel: <b>test NOT test2</b> - findet alle Vorkommen des Wortes <b>test</b>, wobei das Wort <b>test2</b> nicht lautet.</li></ul></li><li><b>Symbol || oder der Ausdruck OR</b> wird verwendet, um Dokumente zu finden, bei denen MINDESTENS EINER des Suchausdrucks lautet.<ul><li>Beispiel: <b>test OR test2</b> - findet alle Dokumente mit dem Wort <b>test</b> oder <b>test2</b> oder beides</li></ul></ul></ul>Spezielle Symbole, die ein Suchausdruck nicht enthalten darf: <b>  +  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  /  </b><br><br>Wenn Sie eines dieser Symbole verwenden müssen, müssen Sie dieses Symbol davor hinzufügen: <b>\\</b>",
60 60
    "contact-admin-title": "Administratorkontakt"
61 61
  }
62 62
}
fe/fulltextsearch/src/assets/i18n/en-lang.json
56 56
    "upload-title": "File upload",
57 57
    "upload-text": "Uploading files is performed on the <b>Upload</b> page, which is accessible from the main bar.<br><br>The <b>Pick files</b> button is used to select which files to upload.<br><br>The <b>Upload</b> button will upload selected files to the web application.<br><br><b>The XML file and its source image file must be uploaded together and with the same name!</b><br><br>You can upload any number of files at once.",
58 58
    "search-title": "Searching",
59
    "search-text": "Searching is performed on the <b>Search</b> page, which is accessible from the main bar.<br><br>Type your search expression in the text box and confirm it with the <b>Search</b> button. When the search is finished, results will be displayed.<br><br>Use the <b>???</b> checkbox to turn spell checking on/off. When checked, if no result of the search expression is found, a similar expression is searched instead up to the maximum distance of 2 between the words.<br><br>The search expression can contain:<ul><li><b>Symbol *</b> represents zero or any number of characters.<ul><li>For example: <b>tes*</b> - searches for all words starting with <b>tes</b></li></ul></li><li><b>Symbol ?</b> represents exactly one character.<ul><li>For example: <b>tes?</b> - finds all words starting with <b>tes</b> and followed by exactly one character</li></ul></li><li><b>Symbol ~</b> at the end of the search expression is used to find all words within a certain maximum distance between them and the search expression.<ul><li>For example : <b> test~2</b> - finds the word <b>test</b> and all words close to it up to a maximum distance of 2</li></ul></li><li><b>The symbol && and the expression AND</b> are used to find documents where ALL of the search expressions are.<ul><li>For example: <b>test AND test2</b> - finds all documents with the words <b>test</b> and <b>test2</b></li></ul></li><li><b> Symbol ! or the expression NOT</b> is used to find results where the specified expression does not occur.<ul><li>For example: <b>test NOT test2</b> - finds all occurrences of the word <b>test</b>, where the word <b>test2</b> is not.</li></ul></li><li><b>Symbol || or the expression OR</b> is used to find documents where AT LEAST ONE of the search expression is.<ul><li>For example: <b>test OR test2</b> - finds all documents with the word <b>test</b> or <b>test2</b> or both</li> </ul></li></ul>Special symbols that a search expression cannot contain: <b>+  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  / </b> <br> <br>If you need to use one of these symbols, you must add this symbol before it: <b>\\</b>",
59
    "search-text": "Searching is performed on the <b>Search</b> page, which is accessible from the main bar.<br><br>Type your search expression in the text box and confirm it with the <b>Search</b> button. When the search is finished, results will be displayed.<br><br>Use the <b>Enable autocorrect</b> checkbox to turn spell checking on/off. When checked, if no result of the search expression is found, a similar expression is searched instead up to the maximum distance of 2 between the words.<br><br>The search expression can contain:<ul><li><b>Symbol *</b> represents zero or any number of characters.<ul><li>For example: <b>tes*</b> - searches for all words starting with <b>tes</b></li></ul></li><li><b>Symbol ?</b> represents exactly one character.<ul><li>For example: <b>tes?</b> - finds all words starting with <b>tes</b> and followed by exactly one character</li></ul></li><li><b>Symbol ~</b> at the end of the search expression is used to find all words within a certain maximum distance between them and the search expression.<ul><li>For example : <b> test~2</b> - finds the word <b>test</b> and all words close to it up to a maximum distance of 2</li></ul></li><li><b>The symbol && and the expression AND</b> are used to find documents where ALL of the search expressions are.<ul><li>For example: <b>test AND test2</b> - finds all documents with the words <b>test</b> and <b>test2</b></li></ul></li><li><b> Symbol ! or the expression NOT</b> is used to find results where the specified expression does not occur.<ul><li>For example: <b>test NOT test2</b> - finds all occurrences of the word <b>test</b>, where the word <b>test2</b> is not.</li></ul></li><li><b>Symbol || or the expression OR</b> is used to find documents where AT LEAST ONE of the search expression is.<ul><li>For example: <b>test OR test2</b> - finds all documents with the word <b>test</b> or <b>test2</b> or both</li> </ul></li></ul>Special symbols that a search expression cannot contain: <b>+  -  &&  ||  !  (  )  {  }  [  ]  ^  “  ~  *  ?  :  / </b> <br> <br>If you need to use one of these symbols, you must add this symbol before it: <b>\\</b>",
60 60
    "contact-admin-title": "Contact admin"
61 61
  }
62 62
}

Také k dispozici: Unified diff