Web

Modal & dialog

Në shqip: Dritarja modale

ShpjegimiSQ

Një modal është një dritare që del mbi faqe dhe e bllokon pjesën tjetër derisa ta mbyllësh — p.sh. „A je i sigurt që do ta fshish?“. HTML-ja ka elementin <dialog> që e bën këtë me qasshmëri të integruar.

EnglishEN

A modal is a window that pops up over the page and blocks the rest until you close it — like “Are you sure you want to delete this?”. HTML has the <dialog> element that does this with accessibility built in.

Si ta mendosh

Si kur mësuesja të thërret në tabelë: e gjithë klasa ndalet derisa të kthehesh në bankë.

Lexoje në anglisht

Like when the teacher calls you up to the board: the whole class pauses until you sit back down.

Shembull kodihtml

<dialog id="konfirmo">
  <p>A je i sigurt?</p>
  <button onclick="konfirmo.close()">Po</button>
</dialog>

Terma të lidhur