// npm package: easymde
// github link: https://github.com/Ionaru/easy-markdown-editor

//	SonicCampGuard
//
//	Copyright(c) 2024 Bundeswehr
//	Diese Anwendung wurde von Cedric Prietz entwickelt.
//	E - Mail: CedricPrietz @bundeswehr.org
//	App: 90 - 8303 - 54618
//
//	Letzte Änderung: 26.01.2025

'use strict';

(function () {

  // Beispiel
  const easyMdeExample = document.querySelector('#easyMdeExample');
  if (easyMdeExample) {
    const easymde = new EasyMDE({
      element: easyMdeExample
    });
  }

  // Form : Neuer Sperrlisten Eintrag
  const blacklistReasonMDE = document.querySelector('#blacklistReasonMDE');
  if (blacklistReasonMDE) {
    const easymde = new EasyMDE({
      element: blacklistReasonMDE
    });
  }
  const blacklistNotesMDE = document.querySelector('#blacklistNotesMDE');
  if (blacklistNotesMDE) {
    const easymde = new EasyMDE({
      element: blacklistNotesMDE
    });
  }

  // Authorized Identity Notes
  const authorizedIdentityNotesMDE = document.querySelector('#authorizedIdentityNotesMDE');
  if (authorizedIdentityNotesMDE) {
    const easymde = new EasyMDE({
      element: authorizedIdentityNotesMDE,
      toolbar: false,
      status: false,
      spellChecker: false,
      shortcuts: false
    });
    easymde.togglePreview();
  }

})();