Feature: Release named views to all users (#5814)

* chore: cleanup to get named views released!

* fix: fixed gizmo, client side camera sync and remove DEV flag

* yarp

* chore: implementing E2E tests for creating a named view

* fix: cleaning up and commenting E2E tests for named views

* fix: we did it bois, the skip ceral i zation bricked my E2E test :(

* fix: auto formatter

* fix: snapshot uuid matching because rust will randomly generate thme

* fix: auto fmt

* fix: trying to resolve typescript issues

* fix: handling NamedView vs CameraViewState type checking

* fix: no idea I just mapped export to 3d export because we have no 2d export yet...

* fix: random file I wrote because my editor was too slow

* fix: git merge did not do what I wanted

* A snapshot a day keeps the bugs away! 📷🐛

* fix: linter errors

* A snapshot a day keeps the bugs away! 📷🐛

---------

Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
This commit is contained in:
Kevin Nadro
2025-03-26 11:12:35 -05:00
committed by GitHub
parent fa16fcedff
commit 1753047d87
12 changed files with 538 additions and 70 deletions

View File

@ -4,7 +4,6 @@ import { type IndexLoaderData } from 'lib/types'
import { BROWSER_PATH, PATHS } from 'lib/paths'
import React, { createContext, useEffect, useMemo } from 'react'
import { toast } from 'react-hot-toast'
import { DEV } from 'env'
import {
Actor,
AnyStateMachine,
@ -61,34 +60,31 @@ export const FileMachineProvider = ({
)
useEffect(() => {
// TODO: Engine feature is not deployed
if (DEV) {
const {
createNamedViewCommand,
deleteNamedViewCommand,
loadNamedViewCommand,
} = createNamedViewsCommand()
const {
createNamedViewCommand,
deleteNamedViewCommand,
loadNamedViewCommand,
} = createNamedViewsCommand()
const commands = [
createNamedViewCommand,
deleteNamedViewCommand,
loadNamedViewCommand,
]
const commands = [
createNamedViewCommand,
deleteNamedViewCommand,
loadNamedViewCommand,
]
commandBarActor.send({
type: 'Add commands',
data: {
commands,
},
})
return () => {
// Remove commands if you go to the home page
commandBarActor.send({
type: 'Add commands',
type: 'Remove commands',
data: {
commands,
},
})
return () => {
// Remove commands if you go to the home page
commandBarActor.send({
type: 'Remove commands',
data: {
commands,
},
})
}
}
}, [])