[READ-ONLY] Mirror of https://github.com/flo-bit/room. tiny 3d rooms saved locally or in your bluesky account, svelte/threlte flo-bit.dev/room/
0

Configure Feed

Select the types of activity you want to include in your feed.

room / src / lib / RoomObject.svelte
613 B 29 lines
1<script lang="ts"> 2 import { type Props } from '@threlte/core'; 3 import type * as THREE from 'three'; 4 import type { RoomObjectKind } from './state.svelte'; 5 import { AllObjects } from './state.svelte'; 6 7 let { 8 kind, 9 selected, 10 colors, 11 opacity, 12 ...restProps 13 }: { 14 kind: RoomObjectKind; 15 selected?: boolean; 16 colors?: (number | string)[]; 17 opacity?: number; 18 } & Props<THREE.Group> = $props(); 19 20 console.log(kind); 21 22 let ObjectComponent = AllObjects[kind]?.component; 23</script> 24 25{@render object()} 26 27{#snippet object()} 28 <ObjectComponent {...restProps} colors={colors} opacity={opacity} /> 29{/snippet}