Skip to content

Commit

Permalink
Fix video tracking behavior for Vue 3
Browse files Browse the repository at this point in the history
  • Loading branch information
mzur committed Feb 13, 2025
1 parent 02eae9c commit 0726cbf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion resources/assets/js/core/echo.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export default {
if (!instance) {
const options = {
broadcaster: 'pusher',
key: process.env.MIX_PUSHER_APP_KEY,
key: import.meta.env.VITE_PUSHER_APP_KEY,
wsHost: window.location.hostname,
wsPort: window.location.port,
wssPort: window.location.port,
Expand Down
10 changes: 9 additions & 1 deletion resources/assets/js/videos/models/Annotation.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ let SHAPE_CACHE;
export default class Annotation {
constructor(args) {
this.id = args.id;
this.frames = args.frames;
this._frames = ref(args.frames);
this._points = args.points;
this.video_id = args.video_id;
this.shape_id = args.shape_id;
Expand Down Expand Up @@ -56,6 +56,14 @@ export default class Annotation {
this._tracking.value = value;
}
get frames() {
return this._frames.value;
}
set frames(value) {
this._frames.value = value;
}
get startFrame() {
return this.frames[0];
}
Expand Down

0 comments on commit 0726cbf

Please sign in to comment.