mirror of
https://github.com/Syngnat/GoNavi.git
synced 2026-08-21 16:34:21 +08:00
🐛 fix(about): 移除重复更新日志入口 (#834)
This commit is contained in:
10
frontend/src/utils/aboutUpdateActions.test.ts
Normal file
10
frontend/src/utils/aboutUpdateActions.test.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { describe, expect, it } from 'vitest';
|
||||
|
||||
import { shouldShowFooterReleaseNotesAction } from './aboutUpdateActions';
|
||||
|
||||
describe('aboutUpdateActions', () => {
|
||||
it('keeps release notes in the legacy modal footer only', () => {
|
||||
expect(shouldShowFooterReleaseNotesAction('legacy-modal')).toBe(true);
|
||||
expect(shouldShowFooterReleaseNotesAction('settings-center')).toBe(false);
|
||||
});
|
||||
});
|
||||
5
frontend/src/utils/aboutUpdateActions.ts
Normal file
5
frontend/src/utils/aboutUpdateActions.ts
Normal file
@@ -0,0 +1,5 @@
|
||||
export type AboutUpdateActionsSurface = 'settings-center' | 'legacy-modal';
|
||||
|
||||
export const shouldShowFooterReleaseNotesAction = (
|
||||
surface: AboutUpdateActionsSurface,
|
||||
): boolean => surface === 'legacy-modal';
|
||||
Reference in New Issue
Block a user