app.astro 825 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. ---
  2. let app = Astro.props.item;
  3. let itemName = app.name.replace(" ", "");
  4. const actionLabel = app.redirectUrl ? `Open ${app.name} link` : `Open ${app.name} window`;
  5. ---
  6. <a
  7. id={itemName}
  8. data-id={app.name}
  9. data-window-id={app.windowId}
  10. data-redirect-url={app.redirectUrl}
  11. href={app.redirectUrl ?? "#"}
  12. role="button"
  13. aria-label={actionLabel}
  14. >
  15. <div class="h-100 m-4">
  16. <img src={app.logo} alt="" aria-hidden="true" class="w-auto h-16 mx-auto my-2" />
  17. <h3 class="font-sans text-white text-center">{app.name}</h3>
  18. </div>
  19. </a>
  20. <style>
  21. h3 {
  22. font-weight: 300;
  23. /* font-family: Arial, sans-serif; */
  24. }
  25. a {
  26. cursor: pointer;
  27. user-select: none;
  28. display: block;
  29. }
  30. a:focus-visible {
  31. outline: 1px dotted #fff;
  32. outline-offset: -2px;
  33. }
  34. .link {
  35. width: 100%;
  36. height: 100%;
  37. z-index: 1;
  38. }
  39. </style>