mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-21 01:25:55 +02:00
Use correct translations for livesearch field in navbar
This commit is contained in:
parent
746ba398a9
commit
409dcce3c7
1 changed files with 10 additions and 1 deletions
|
@ -24,6 +24,12 @@ import "../../css/components/autocomplete_bootstrap_theme.css";
|
|||
import { createLocalStorageRecentSearchesPlugin } from '@algolia/autocomplete-plugin-recent-searches';
|
||||
import {marked} from "marked";
|
||||
|
||||
import {
|
||||
trans,
|
||||
SEARCH_PLACEHOLDER,
|
||||
SEARCH_SUBMIT
|
||||
} from '../../translator';
|
||||
|
||||
export default class extends Controller {
|
||||
|
||||
static targets = ["input"];
|
||||
|
@ -49,7 +55,10 @@ export default class extends Controller {
|
|||
panelPlacement: 'end',
|
||||
plugins: [recentSearchesPlugin],
|
||||
openOnFocus: true,
|
||||
placeholder: "Search for parts",
|
||||
placeholder: trans(SEARCH_PLACEHOLDER),
|
||||
translations: {
|
||||
submitButtonTitle: trans(SEARCH_SUBMIT)
|
||||
},
|
||||
|
||||
// Use a navigator compatible with turbo:
|
||||
navigator: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue