mirror of
https://0xacab.org/sutty/sutty
synced 2025-02-21 21:21:49 +00:00
usar tabs acá
This commit is contained in:
parent
85efaf988a
commit
3fdbd01b78
1 changed files with 11 additions and 11 deletions
|
@ -278,19 +278,19 @@ function setupEditor (editorEl: HTMLElement): void {
|
||||||
}
|
}
|
||||||
|
|
||||||
document.addEventListener("turbolinks:load", () => {
|
document.addEventListener("turbolinks:load", () => {
|
||||||
const flash = document.querySelector<HTMLElement>('.js-flash')
|
const flash = document.querySelector<HTMLElement>('.js-flash')
|
||||||
|
|
||||||
if (flash) {
|
if (flash) {
|
||||||
const keys = JSON.parse(flash.dataset.keys || '[]')
|
const keys = JSON.parse(flash.dataset.keys || '[]')
|
||||||
|
|
||||||
switch (flash.dataset.target) {
|
switch (flash.dataset.target) {
|
||||||
case 'editor':
|
case 'editor':
|
||||||
switch (flash.dataset.action) {
|
switch (flash.dataset.action) {
|
||||||
case 'forget-content':
|
case 'forget-content':
|
||||||
keys.forEach(forgetContent)
|
keys.forEach(forgetContent)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
for (const editorEl of document.querySelectorAll<HTMLElement>('.editor[data-editor]')) {
|
for (const editorEl of document.querySelectorAll<HTMLElement>('.editor[data-editor]')) {
|
||||||
try {
|
try {
|
||||||
|
|
Loading…
Reference in a new issue