prop/lib/microwaveprop_web/live/algo_live.ex
Graham McIntire cd8d7a0f52
Add contact detail map, elevation profile chart, and UI improvements
- Leaflet map on contact detail pages showing both station locations
- SRTM elevation profile with Chart.js: terrain, LOS, Fresnel zone
- Path info: distance, azimuth, elevation angle in both directions
- Compact 4-column grid layout for contact details
- Contact map page with all contacts plotted
- Rename QSOs to Contacts in page header
- Wrap algo page in standard layout
2026-04-01 12:34:03 -05:00

23 lines
513 B
Elixir

defmodule MicrowavepropWeb.AlgoLive do
@moduledoc false
use MicrowavepropWeb, :live_view
@external_resource "algo.md"
@algo_html "algo.md" |> File.read!() |> Earmark.as_html!()
@impl true
def mount(_params, _session, socket) do
{:ok, assign(socket, page_title: "Algorithm", content: @algo_html)}
end
@impl true
def render(assigns) do
~H"""
<Layouts.app flash={@flash}>
<div class="markdown-content">
{raw(@content)}
</div>
</Layouts.app>
"""
end
end