Vendored Augani/openreel-video (MIT) into services/editor and wired it to the MAM. Editor runs as its own container on port 47435. Library assets pull in via ?asset=<uuid>; render exports route back via POST /api/v1/upload/simple. Sidebar Editor link on every page; Edit button on every preview modal. See services/editor/INTEGRATION.md for the patch map.
39 lines
936 B
TypeScript
39 lines
936 B
TypeScript
import React from "react";
|
|
import ReactDOM from "react-dom/client";
|
|
import posthog from "posthog-js";
|
|
import { PostHogProvider } from "posthog-js/react";
|
|
import App from "./App";
|
|
import "./index.css";
|
|
import { registerServiceWorker } from "./services/service-worker";
|
|
|
|
const POSTHOG_KEY = import.meta.env.VITE_PUBLIC_POSTHOG_KEY;
|
|
const POSTHOG_HOST = import.meta.env.VITE_PUBLIC_POSTHOG_HOST;
|
|
|
|
if (POSTHOG_KEY && POSTHOG_HOST) {
|
|
posthog.init(POSTHOG_KEY, {
|
|
api_host: POSTHOG_HOST,
|
|
capture_pageview: true,
|
|
capture_pageleave: true,
|
|
});
|
|
}
|
|
|
|
registerServiceWorker().then((registration) => {
|
|
if (registration) {
|
|
}
|
|
});
|
|
|
|
const root = document.getElementById("root")!;
|
|
|
|
ReactDOM.createRoot(root).render(
|
|
<React.StrictMode>
|
|
{POSTHOG_KEY && POSTHOG_HOST ? (
|
|
<PostHogProvider client={posthog}>
|
|
<App />
|
|
</PostHogProvider>
|
|
) : (
|
|
<App />
|
|
)}
|
|
</React.StrictMode>,
|
|
);
|
|
|
|
import "./mam-bridge";
|