bump
All checks were successful
Build and Release / build-and-release (push) Successful in 13m51s

This commit is contained in:
Bryan1029384756
2026-02-19 18:41:26 -06:00
parent bcd93291f8
commit 4e1a6225e1
3 changed files with 31 additions and 12 deletions

View File

@@ -27,14 +27,14 @@ export function UpdateProvider({ children }) {
return (
<UpdateContext.Provider value={state}>
{children}
{state && (state.updateType === 'major' || state.updateType === 'minor') && (
<ForcedUpdateModal latestVersion={state.latestVersion} />
{state && (state.updateType === 'major' || state.updateType === 'minor' || !features.hasWindowControls) && (
<ForcedUpdateModal updateType={state.updateType} latestVersion={state.latestVersion} />
)}
</UpdateContext.Provider>
);
}
function ForcedUpdateModal({ latestVersion }) {
function ForcedUpdateModal({ updateType, latestVersion }) {
const { links, updates } = usePlatform();
const [downloading, setDownloading] = useState(false);
const [progress, setProgress] = useState(0);
@@ -62,12 +62,17 @@ function ForcedUpdateModal({ latestVersion }) {
}
};
const isPatch = updateType === 'patch';
return (
<div className="forced-update-overlay">
<div className="forced-update-modal">
<h2>Update Required</h2>
<h2>{isPatch ? 'Update Available' : 'Update Required'}</h2>
<p>
A new version (v{latestVersion}) is available. This update is required to continue using the app.
{isPatch
? `A new version (v${latestVersion}) is available.`
: `A new version (v${latestVersion}) is available. This update is required to continue using the app.`
}
</p>
{downloading ? (
<div className="update-progress">