feat: refresh creation config and visual assets

This commit is contained in:
2026-05-20 14:02:36 +08:00
parent 83e92fc3c4
commit ef09a23c35
509 changed files with 19470 additions and 43 deletions

View File

@@ -6069,6 +6069,10 @@ export function PlatformEntryFlowShellImpl({
pushAppHistoryPath('/runtime/baby-love-drawing');
}, [setSelectionStage]);
const startChildMotionDemo = useCallback(() => {
window.location.assign('/child-motion-demo');
}, []);
const resolveBabyObjectMatchRuntimeDraft = useCallback(
async (entry: PlatformPublicGalleryCard) => {
if (!isEdutainmentGalleryEntry(entry)) {
@@ -11806,6 +11810,7 @@ export function PlatformEntryFlowShellImpl({
onOpenCreateWorld={openCreationTypePicker}
onOpenCreateTypePicker={openCreationTypePicker}
onOpenGalleryDetail={openPublicGalleryDetail}
onOpenChildMotionDemo={startChildMotionDemo}
onOpenBabyLoveDrawing={startBabyLoveDrawingRuntime}
onOpenRecommendGalleryDetail={openRecommendGalleryDetail}
recommendRuntimeContent={recommendRuntimeContent}

View File

@@ -182,3 +182,29 @@ test('edutainment switch hides baby object match creation entry from database co
getVisiblePlatformCreationTypes(hiddenCards).map((item) => item.id),
).toEqual(['puzzle']);
});
test('baby object match entry is visible and open when database marks it creatable', () => {
const cards = derivePlatformCreationTypes([
{
id: 'baby-object-match',
title: '宝贝识物',
subtitle: '亲子识物分类',
badge: '可创建',
imageSrc: '/child-motion-demo/picture-book-grass-stage.png',
visible: true,
open: true,
sortOrder: 90,
updatedAtMicros: 1,
},
]);
expect(getVisiblePlatformCreationTypes(cards)).toEqual([
expect.objectContaining({
id: 'baby-object-match',
hidden: false,
locked: false,
}),
]);
expect(isPlatformCreationTypeVisible(cards, 'baby-object-match')).toBe(true);
expect(isPlatformCreationTypeOpen(cards, 'baby-object-match')).toBe(true);
});