mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-24 10:49:00 +02:00
Update the locale changer links every time turbo loads a new frame.
This commit is contained in:
parent
1a9dfee0ed
commit
7990cf56d1
3 changed files with 19 additions and 1 deletions
8
assets/controllers/turbo/locale_menu_controller.js
Normal file
8
assets/controllers/turbo/locale_menu_controller.js
Normal file
|
@ -0,0 +1,8 @@
|
|||
import { Controller } from '@hotwired/stimulus';
|
||||
|
||||
export default class extends Controller {
|
||||
connect() {
|
||||
const menu = document.getElementById('locale-select-menu');
|
||||
menu.innerHTML = this.element.innerHTML;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue