max project limit set to below warning threshold
This commit is contained in:
parent
ae5aa53b99
commit
7cc5017e56
@ -105,6 +105,7 @@ describe('Resume Projects Logic', () => {
|
|||||||
// p1 is visible in base, so it should be locked by default
|
// p1 is visible in base, so it should be locked by default
|
||||||
expect(result.resumeProjects.lockedProjectIds).toEqual(['p1']);
|
expect(result.resumeProjects.lockedProjectIds).toEqual(['p1']);
|
||||||
expect(result.resumeProjects.aiSelectableProjectIds).toEqual(['p2', 'p3']);
|
expect(result.resumeProjects.aiSelectableProjectIds).toEqual(['p2', 'p3']);
|
||||||
|
expect(result.resumeProjects.maxProjects).toBe(3);
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should apply valid overrides', () => {
|
it('should apply valid overrides', () => {
|
||||||
|
|||||||
@ -58,7 +58,7 @@ export function buildDefaultResumeProjectsSettings(
|
|||||||
.filter((id) => !lockedSet.has(id));
|
.filter((id) => !lockedSet.has(id));
|
||||||
|
|
||||||
const total = catalog.length;
|
const total = catalog.length;
|
||||||
const preferredMax = Math.max(lockedProjectIds.length, 4);
|
const preferredMax = Math.max(lockedProjectIds.length, 3);
|
||||||
const maxProjects = total === 0 ? 0 : Math.min(total, preferredMax);
|
const maxProjects = total === 0 ? 0 : Math.min(total, preferredMax);
|
||||||
|
|
||||||
return normalizeResumeProjectsSettings(
|
return normalizeResumeProjectsSettings(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user