MCPcopy Create free account
hub / github.com/Coneja-Chibi/CarrotKernel / highlightElement

Function highlightElement

tutorials.js:309–318  ·  view source on GitHub ↗
(element, step)

Source from the content-addressed store, hash-verified

307
308// Highlight target element
309function highlightElement(element, step) {
310 // Remove existing highlights
311 document.querySelectorAll('.carrot-tutorial-highlight').forEach(el => {
312 el.classList.remove('carrot-tutorial-highlight');
313 });
314
315 // Add highlight to target
316 element.classList.add('carrot-tutorial-highlight');
317 element.scrollIntoView({ behavior: 'smooth', block: 'center' });
318}
319
320// Show tutorial overlay
321function showTutorialOverlay(tutorial, step, targetElement) {

Callers 1

showTutorialStepFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected