Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 

56 строки
1.7 KiB

  1. import './secondary-menu.scss';
  2. import {createElement} from "../../_global/scripts/helpers";
  3. export const createSecondaryMenu = ({
  4. secondaryLinks = ['Über uns', 'Presse', 'Newsletter'],
  5. languageLinks = ['CZ', 'EN'],
  6. iconLinks = [
  7. {
  8. iconClass: 'sign-language',
  9. label: 'Zeichensprache',
  10. },
  11. {
  12. iconClass: 'simple-language',
  13. label: 'Einfach Sprache',
  14. },
  15. {
  16. iconClass: 'login',
  17. label: 'Einloggen',
  18. }
  19. ]
  20. }) => {
  21. const wrap = createElement('div', ['secondary-menu-wrapper']);
  22. const secondary = createElement('div', ['secondary-menu'], null, wrap);
  23. const secondaryUl = createElement('ul', [], null, secondary);
  24. secondaryLinks.map((link) => {
  25. const li = createElement('li', [], null, secondaryUl);
  26. const a = createElement('a', [], link, li);
  27. a.href = '#';
  28. })
  29. const meta = createElement('div', ['meta-menu'], null, wrap);
  30. const metaUl = createElement('ul', [], null, meta);
  31. const contactLi = createElement('li', ['contact'], null, metaUl);
  32. const contactA = createElement('a', [], 'Kontakt', contactLi);
  33. contactA.href = '#';
  34. const languageLi = createElement('li', ['language'], null, metaUl);
  35. const languageUl = createElement('ul', [], null, languageLi);
  36. languageLinks.map((link) => {
  37. const li = createElement('li', [], null, languageUl);
  38. const a = createElement('a', [], link, li);
  39. a.href = '#';
  40. })
  41. const iconsLi = createElement('li', ['icons'], null, metaUl);
  42. const iconsUl = createElement('ul', [], null, iconsLi);
  43. iconLinks.map((link) => {
  44. const li = createElement('li', [link.iconClass], null, iconsUl);
  45. const a = createElement('a', [], link.label, li);
  46. a.href = '#';
  47. })
  48. return wrap;
  49. }