mirador
Version:
An open-source, web-based 'multi-up' viewer that supports zoom-pan-rotate functionality, ability to display/compare simple images, and images with annotations.
42 lines (41 loc) • 1.44 kB
JavaScript
import { U as e, at as t, dt as n, ft as r, g as i, st as a } from "./getters-B4oepJRC.js";
import { f as o, g as s, mt as c } from "./canvases-CeUwRIFA.js";
import { jsx as l, jsxs as u } from "react/jsx-runtime";
import { styled as d } from "@mui/material/styles";
//#region src/components/VideoViewer.jsx
var f = /* @__PURE__ */ r(t(), 1), p = d("div")(() => ({
alignItems: "center",
display: "flex",
width: "100%"
})), m = d("video")(() => ({
maxHeight: "100%",
width: "100%"
}));
function h({ captions: e = [], videoOptions: t = {}, videoResources: n = [] }) {
return /* @__PURE__ */ l(p, { children: /* @__PURE__ */ u(m, {
...t,
children: [n.map((e) => /* @__PURE__ */ l("source", {
src: e.id,
type: e.getFormat()
}, e.io)), e.map((e) => /* @__PURE__ */ l("track", {
src: e.id,
label: e.getDefaultLabel(),
srcLang: e.getProperty("language")
}, e.id))]
}) });
}
h.propTypes = {
captions: f.default.arrayOf(f.default.object),
videoOptions: f.default.object,
videoResources: f.default.arrayOf(f.default.object)
};
//#endregion
//#region src/containers/VideoViewer.js
var g = /* @__PURE__ */ n({ default: () => _ }), _ = e(a((e, { windowId: t }) => ({
captions: o(e, { windowId: t }) || [],
videoOptions: c(e).videoOptions,
videoResources: s(e, { windowId: t }) || []
}), null), i("VideoViewer"))(h);
//#endregion
export { g as n, h as r, _ as t };
//# sourceMappingURL=VideoViewer-Cmj4kJeg.js.map