Show/add live comments in Speckle Viewer node js

Dear community, I want to have a live-commenting functionality(the one that already exists in Speckle web app) in the speckle viewer embedded in my node.js web application. Is there something already implemented in the SDK or maybe it is in the coming release plan? Cannot find it…
P.s I could also implement it by myself, but it would be stupid if it is already there

1 Like

Hi @Aleksandr_Bulankin, the live comments are not part of the viewer but rather part of the frontend, and they use parts of the viewer api to “render” and update them (we use simple html to actually display them).

As such, the code you’re looking for is in the frontend package in our monorepo (speckle-server/packages/frontend/src/main/components/viewer/ViewerBubbles.vue at 95ef34b67f6c4a20478fe988ec6355d652fe8bf0 · specklesystems/speckle-server · GitHub - i’m linking to the 1.0 version as it might be easier to parse).

For live event tracking we’re using some of our api’s subscriptions (see commentActivity for example).
On the viewer end, to project from 3D to screen space we use the viewer’s query api.

Docs here: Notion – The all-in-one workspace for your notes, tasks, wikis, and databases.

2 Likes

thanks @dimitrie, that’s exaclty what I need!

2 Likes

Happy to help. Mind you, it’s not going to be super easy to recreate that functionality - going by our efforts in that direction, but with some good eyes you should get it going :slight_smile:

If (or when) you run into trouble, don’t hesitate to ping us - it would be a good way for us to document how to do it at the same time :smiley:

2 Likes