fix: align male and female effect IDs with thumbnails, add gender filter tabs and strip request prefixes

This commit is contained in:
2026-11-12 13:50:06 +05:30
parent 5445a8cbee
commit 473b269080
13 changed files with 1339 additions and 720 deletions
+6
View File
@@ -117,6 +117,9 @@ export async function POST(req: NextRequest, { params }: { params: { toolId: str
(formData.get('dress') as string) ||
(formData.get('expression') as string) ||
'';
const gender = (formData.get('gender') as string) || '';
const category = (formData.get('category') as string) || '';
const effectId = (formData.get('effectId') as string) || '';
const variantId = (formData.get('variant') as string) || tool.tryIt.endpointRef?.defaultVariant;
const optionsRaw = formData.get('options') as string | null;
let options: Record<string, any> = {};
@@ -129,6 +132,9 @@ export async function POST(req: NextRequest, { params }: { params: { toolId: str
}
if (style) options.style = style;
if (gender) options.gender = gender;
if (category) options.category = category;
if (effectId) options.effectId = effectId;
const isTextToImage = tool.pageType === 'text-to-image' || tool.id.includes('text');