Proyectos de Subversion Moodle

Rev

Rev 1 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 1 Rev 1441
Línea 136... Línea 136...
136
                fetchNotifications(),
136
                fetchNotifications(),
137
            ]);
137
            ]);
Línea 138... Línea 138...
138
 
138
 
139
            // Refocus on the link that as pressed in the first place.
139
            // Refocus on the link that as pressed in the first place.
-
 
140
            updatedRoot.querySelector(`[data-action="togglestate"][data-plugin="${stateToggle.dataset.plugin}"]`).focus();
-
 
141
 
-
 
142
            // When clicking the toggle and it remains focused, a new tooltip will be generated.
-
 
143
            // Therefore, the old tooltip should be removed.
140
            updatedRoot.querySelector(`[data-action="togglestate"][data-plugin="${stateToggle.dataset.plugin}"]`).focus();
144
            this.removeTooltips();
141
            pendingPromise.resolve();
145
            pendingPromise.resolve();
142
        }
146
        }
Línea 143... Línea 147...
143
    }
147
    }
Línea 174... Línea 178...
174
            updatedRoot.querySelector(`[data-action="move"][data-plugin="${actionLink.dataset.plugin}"]`)?.focus();
178
            updatedRoot.querySelector(`[data-action="move"][data-plugin="${actionLink.dataset.plugin}"]`)?.focus();
175
        }
179
        }
Línea 176... Línea 180...
176
 
180
 
177
        pendingPromise.resolve();
181
        pendingPromise.resolve();
-
 
182
    }
-
 
183
 
-
 
184
    /**
-
 
185
     * Remove tooltips.
-
 
186
     */
-
 
187
    removeTooltips() {
-
 
188
        const tooltips = document.querySelectorAll('[id*="tooltip"]');
-
 
189
        if (tooltips.length > 0) {
-
 
190
            tooltips.forEach(tooltip => {
-
 
191
                tooltip.remove();
-
 
192
            });
-
 
193
        }
178
    }
194
    }