Repository navigation
v3.2.0
Add support for textures
Optional textures (image files) can be set on items.
const types = ref([
{
color: "#71a4a8",
description: "monitor",
icon: 'deviceDesktop',
typeId: 1,
iconColor: '#1A1A1A',
depth: 1,
texture: {
src: '/textures/monitor.png'
}
},
{
color: "#CCCCCC",
description: "patch panel",
icon: 'plugConnected',
typeId: 2,
iconColor: '#1A1A1A',
texture: {
src: '/textures/patch-panel.png'
}
},
]);The type of the texture attribute:
type GridPlanTexture = {
src: string;
repeatX?: number;
repeatY?: number;
rotation?: number;
metalness?: number;
roughness?: number;
}