Preserve frame position order for auto insertion

- Allow system frame position percentages to keep two decimal places without reordering saved values.

- Stop frontend and backend settings normalization from sorting framePositions on load or save.

- Capture automatic video frames in timeline order while retaining each configured position index.

- Insert automatically selected frames into report placeholders according to the configured percentage order.

- Add frame position utilities and unit coverage for two-decimal rounding, clamping, order preservation, and timeline capture planning.

- Update README, AGENTS, feature, requirement, report editor, system settings, progress, and testing docs for the new frame ordering behavior.
This commit is contained in:
2026-05-02 05:10:39 +08:00
parent 3774657ef5
commit 2cabe7e4fd
13 changed files with 106 additions and 55 deletions

View File

@@ -272,8 +272,7 @@ export class SettingsService {
...(input.aiProviders || {}),
};
const framePositions = [...(input.framePositions || DEFAULT_SETTINGS.framePositions)]
.map((value) => Math.round(value * 10) / 10)
.sort((a, b) => a - b);
.map((value) => Math.round(value * 100) / 100);
return {
...DEFAULT_SETTINGS,