code optimization

This commit is contained in:
2025-09-02 15:21:13 +05:30
parent 175f6eac4f
commit 4f8bf81a60
162 changed files with 2381 additions and 2822 deletions

View File

@@ -120,7 +120,6 @@ const DashboardHome: React.FC = () => {
}
return (
projectList &&
projectList.map((project) => (
<DashboardCard
key={project._id}

View File

@@ -28,7 +28,7 @@ const GlobalProperties: React.FC = () => {
const { email, userId, organization } = getUserData();
const optimizeScene = async (value: any) => {
if (!projectId) return;
setEnvironment(
organization,
userId,
@@ -44,7 +44,7 @@ const GlobalProperties: React.FC = () => {
};
const limitRenderDistance = async () => {
if (!projectId) return;
if (limitDistance) {
setEnvironment(
organization,
@@ -78,6 +78,7 @@ const GlobalProperties: React.FC = () => {
}
const updatedDist = async (value: number) => {
if (!projectId) return;
setRenderDistance(value);
// setDistance(value);
const data = await setEnvironment(
@@ -95,6 +96,8 @@ const GlobalProperties: React.FC = () => {
// Function to toggle roof visibility
const changeRoofVisibility = async () => {
if (!projectId) return;
//using REST
const data = await setEnvironment(
organization,
@@ -123,6 +126,8 @@ const GlobalProperties: React.FC = () => {
};
const changeWallVisibility = async () => {
if (!projectId) return;
//using REST
const data = await setEnvironment(
organization,
@@ -150,6 +155,8 @@ const GlobalProperties: React.FC = () => {
};
const shadowVisibility = async () => {
if (!projectId) return;
//using REST
const data = await setEnvironment(
organization,