-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/add map to robot tab #530
Conversation
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Codecov Report
@@ Coverage Diff @@
## main #530 +/- ##
==========================================
- Coverage 80.57% 80.41% -0.16%
==========================================
Files 255 256 +1
Lines 5384 5428 +44
Branches 601 599 -2
==========================================
+ Hits 4338 4365 +27
- Misses 849 865 +16
- Partials 197 198 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
React.useEffect(() => { | ||
if (!leaflet.map) return; | ||
if (zoom) leaflet.map.setZoom(zoom); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I increase the zoom value because the original zoom is really small.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
robot.centering.of.icon.mov
I'm not sure if it's just on my end but there seem to be 2 different panning motions (1 immediate, 1 delayed) when there are no active tasks. if robot1 is currently centered, clicking on robot2 moves the position immediately (no panning motion) but if there are no robots in focus/center, clicking on either entry will show the desired panning motion
is this something that can be kept the same?
also could the mouse icon change to a suitable icon that indicates the entries are clickable?
|
||
// robot panel stuff | ||
const [hasMore, setHasMore] = React.useState(true); | ||
const [page, setPage] = React.useState(0); | ||
const [verboseRobots, setVerboseRobots] = React.useState<VerboseRobot[]>([]); | ||
const fetchVerboseRobots = React.useCallback(async () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would it help if the fetching of the robots states can be toggled with autorefresh
like the tasks tabs to fix the problem of the position og the centering feature?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure! Maybe I could create a separate task for this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed the positioning issue by calling fetchVerboseRobots
when clicking the robot.
This will require some digging into the behavior of how
Thanks for pointing that out! |
Signed-off-by: ChawinTan <chawin15@gmail.com>
Turns out the panning motion can be fixed by simply setting the animation option in |
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
packages/dashboard/src/components/schedule-visualizer/index.tsx
Outdated
Show resolved
Hide resolved
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
|
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
packages/dashboard/src/components/schedule-visualizer/index.tsx
Outdated
Show resolved
Hide resolved
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
Signed-off-by: ChawinTan <chawin15@gmail.com>
What's new
Related to #503 and #504
There is a minor inconsistency currently in the zooming feature. When a robot is assigned a task and on the move,you would need to click on therefresh
button on the panel to get the latest position of the robot before clicking onthe robot row, otherwise the map would center to its current position when the robot has already move away.Self-checks
Discussion