diff --git a/CHANGELOG.md b/CHANGELOG.md index 59bcbc4..1e29419 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## 0.45.14 - 2026-05-26 + +- Added a full-width `Changelog` button under Config page Runtime info that opens a floating scrollable panel and loads the contents of the project's `CHANGELOG.md`. +- Added a new `/api/changelog` route for the Config page modal and kept `CHANGELOG.md` inside the Docker runtime image so the in-container changelog viewer works after deployment. + ## 0.45.13 - 2026-05-26 - Trimmed the Docker runtime image by removing repo-only files from `/app` after cloning, so the container no longer carries development docs, Compose/build files, or the test suite it does not use at runtime. diff --git a/Dockerfile b/Dockerfile index 2aa9571..e242f67 100644 --- a/Dockerfile +++ b/Dockerfile @@ -51,7 +51,6 @@ RUN git clone --depth 1 "${ANI_CLI_WEB}" /app \ && rm -f \ /app/.dockerignore \ /app/.gitignore \ - /app/CHANGELOG.md \ /app/Dockerfile \ /app/README.md \ /app/ani-cli-web \ diff --git a/README.md b/README.md index 5a3ffea..40d18b8 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Small local web UI for a system-wide `ani-cli` install. -Current version: `0.45.13` +Current version: `0.45.14` ## Project Layout @@ -109,7 +109,7 @@ Container notes: - `ani-cli` is installed at `/usr/local/bin/ani-cli`. - `yt-dlp` is installed at `/usr/local/bin/yt-dlp` from the latest GitHub release during build. - `ani-cli-web` runs from `/app`. -- The runtime image removes repo-only files such as `README.md`, `Dockerfile`, `docker-compose.yaml`, and `test_app.py` after cloning, while keeping the app's `VERSION` file for Runtime info. +- The runtime image removes repo-only files such as `README.md`, `Dockerfile`, `docker-compose.yaml`, and `test_app.py` after cloning, while keeping the app's `VERSION` and `CHANGELOG.md` files for Runtime info and the changelog viewer. - Downloads go to `/downloads`. - App state lives in `/app/.ani-cli-web`. - The container binds `0.0.0.0:8421`. @@ -201,6 +201,7 @@ Layout: - The remaining Config sections use two columns on larger screens and collapse to one column at `1080px` width and below. - Runtime info shows both the `ani-cli-web` version and the installed `ani-cli` version. - The `ani-cli-web` Runtime info version is read directly from the project `VERSION` file so the UI and startup logs stay aligned with release metadata. +- Runtime info now includes a full-width `Changelog` button that opens a floating scrollable viewer backed by the project's `CHANGELOG.md`. - Path fields include `Browse` buttons that open a host-side folder picker modal in the browser. Saved settings are written to `.ani-cli-web/config.json`. diff --git a/VERSION b/VERSION index c45f326..00de776 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.45.13 +0.45.14 diff --git a/app_support.py b/app_support.py index c5c5f5f..e688a97 100644 --- a/app_support.py +++ b/app_support.py @@ -25,6 +25,7 @@ PROJECT_ROOT = Path(__file__).resolve().parent ANI_CLI = os.environ.get("ANI_CLI_BIN") or shutil.which("ani-cli") or "ani-cli" APP_NAME = "ani-cli-web" VERSION_FILE = PROJECT_ROOT / "VERSION" +CHANGELOG_FILE = PROJECT_ROOT / "CHANGELOG.md" ALLANIME_BASE = "allanime.day" ALLANIME_API = f"https://api.{ALLANIME_BASE}" ALLANIME_REFERER = "https://allmanga.to" @@ -87,6 +88,13 @@ def load_app_version(default="0.0.0"): return version or default +def load_project_text_file(path, default=""): + try: + return Path(path).read_text(encoding="utf-8") + except OSError: + return default + + VERSION = load_app_version() diff --git a/config_page.py b/config_page.py index d21d2cb..b911009 100644 --- a/config_page.py +++ b/config_page.py @@ -223,6 +223,9 @@ CONFIG_HTML = r""" display: grid; gap: 10px; } + .wide-button { + width: 100%; + } .chips { display: flex; flex-wrap: wrap; @@ -388,6 +391,39 @@ CONFIG_HTML = r""" .browser-entry-name { overflow-wrap: anywhere; } + .changelog-modal { + width: min(100%, 900px); + max-height: min(84vh, 820px); + overflow: hidden; + border: 1px solid var(--line); + border-radius: 22px; + background: linear-gradient(180deg, rgba(29, 22, 47, 0.96), rgba(17, 13, 29, 0.98)); + box-shadow: var(--shadow); + display: grid; + grid-template-rows: auto 1fr; + gap: 12px; + padding: 18px; + } + .changelog-header { + display: flex; + gap: 10px; + align-items: center; + justify-content: space-between; + } + .changelog-content { + overflow: auto; + border: 1px solid var(--line); + border-radius: 18px; + background: rgba(255, 255, 255, 0.03); + padding: 16px; + } + .changelog-content pre { + margin: 0; + white-space: pre-wrap; + overflow-wrap: anywhere; + color: var(--text); + font: 13px/1.55 "Cascadia Code", "Fira Code", Consolas, monospace; + } @media (max-width: 900px) { .app { grid-template-columns: 1fr; } aside { border-right: 0; border-bottom: 1px solid var(--line); } @@ -427,6 +463,7 @@ CONFIG_HTML = r"""
Detecting ani-cli version...
Saved settings live in `.ani-cli-web/config.json` inside this project.
+ @@ -607,6 +644,21 @@ CONFIG_HTML = r""" + +