style: fix background image jumping around

This commit is contained in:
Youwen Wu 2024-03-18 21:54:41 -07:00
parent 63bfcaba4c
commit a3e2a0612d
Signed by: youwen5
GPG key ID: 865658ED1FE61EC3
2 changed files with 16 additions and 4 deletions

View file

@ -93,6 +93,9 @@
/* hide scrollbar */
-ms-overflow-style: none;
scrollbar-width: none;
background-position: top right;
width: 65vw;
height: 100vw;
}
.infotainment-container::-webkit-scrollbar {

View file

@ -1,3 +1,11 @@
<!--
@component
Visualization scene for the robot.
1:28in scale
aka 1:0.71m scale
-->
<script lang="ts">
import { T, useTask } from '@threlte/core'
import { Grid } from '@threlte/extras'
@ -15,7 +23,7 @@
const dispatch = createEventDispatcher()
const SPEED_MULTIPLIER = 4
const SPEED_MULTIPLIER = 1.408
const axis = new Vector3(0, 1, 0)
const follow = (delta: number) => {
@ -105,6 +113,7 @@
/* TODO: standardize a scale (meters : grid lengths) so we can have
accurate positioning of sensor detected objects */
// update position data for robot model
// Speed is reported in
$mesh.position.x +=
$telemetryReadonlyStore['chassis-y-speed'] * delta * SPEED_MULTIPLIER
$mesh.position.z +=
@ -135,10 +144,10 @@
<T.AmbientLight color={'#f0f0f0'} intensity={0.1} />
<RobotDecimated
scale={[10, 10, 10]}
scale={[9, 9, 9]}
position.y={0}
position.x={-3}
position.z={3}
position.x={-2.8}
position.z={2.8}
on:create={({ ref }) => {
// @ts-expect-error
mesh.set(ref)