feat: support mixing API anime wallpapers with local backgrounds - #31
feat: support mixing API anime wallpapers with local backgrounds#31XRYua wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Important Installation incomplete: to start using Gemini Code Assist, please ask the organization owner(s) to visit the Gemini Code Assist Admin Console and sign the Terms of Services. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1a3649df93
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const localDesktop = toArray(localSrc.desktop); | ||
| const localMobile = toArray(localSrc.mobile); | ||
| return { | ||
| desktop: [...normalizedApiImages, ...localDesktop], | ||
| mobile: [...normalizedApiImages, ...localMobile], |
There was a problem hiding this comment.
Preserve cross-device fallback in banner image merging
When mixWithLocal is enabled and banner.src provides only one side (desktop or mobile), this merge branch appends local images only from the explicitly defined side and leaves the other side with API images only. The banner source handling otherwise supports cross-device fallback (mobile falling back to desktop and vice versa), so mixed mode now drops local images for one device class in valid single-side configs.
Useful? React with 👍 / 👎.
| const localDesktop = toArray(localSrc.desktop); | ||
| const localMobile = toArray(localSrc.mobile); | ||
| return { | ||
| desktop: [...normalizedApiImages, ...localDesktop], | ||
| mobile: [...normalizedApiImages, ...localMobile], |
There was a problem hiding this comment.
Preserve cross-device fallback in fullscreen image merging
The fullscreen merge path has the same regression: with mixWithLocal enabled and config.src defining only one side, the undefined side gets no local fallback and ends up using API images only. This diverges from the component’s normal fallback behavior for asymmetric desktop/mobile configs, so mixed mode can silently exclude intended local wallpapers on one device type.
Useful? React with 👍 / 👎.
Motivation
Description
mixWithLocal?: booleantobanner.imageApiinsrc/types/config.tsto control whether API images are mixed with local images.src/config.tsexample to show an anime-oriented text API endpoint and enabledmixWithLocalin the example comment to illustrate usage.src/layouts/MainGridLayout.astroto fetch the API text response, validate lines, and merge remote URLs with local desktop/mobile image arrays whenmixWithLocalis true, preserving per-device (desktop/mobile) logic.src/components/misc/FullscreenWallpaper.astroto use the same merge behavior so fullscreen mode gains parity with banner mode.Testing
pnpm -s exec astro check; the check executed and types were regenerated, but the repository still reports pre-existing TypeScript errors unrelated to this change (duplicate identifier insrc/pages/[...page].astro), and a warning about an inline script insrc/layouts/Layout.astro(the warning is informational aboutis:inline).astro check.Codex Task