@using Microsoft.AspNetCore.Components @code { private double _currentX = -1000; private double _currentY = -1000; private double _yaw = 0; /// /// Transform string for SVG group element /// private string Transform => $"translate({_currentX:F6},{_currentY:F6}) rotate({_yaw * 180.0 / Math.PI:F2})"; /// /// Update robot pose với vị trí và góc quay /// /// X position trong world coordinates /// Y position trong world coordinates /// Yaw angle trong radians public void UpdatePose(double x, double y, double yaw) { _currentX = x; _currentY = y; _yaw = yaw; StateHasChanged(); } }