Skip to content

Commit

Permalink
perf: ⚡️ 预览播放视频改为重复播放
Browse files Browse the repository at this point in the history
Closes: #254
  • Loading branch information
meetqy committed Jun 16, 2023
1 parent 432c87e commit 4527644
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion apps/nextjs/src/components/Navbar.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useRequest, useResponsive } from "ahooks";
import { useRouter } from "next/router";
import { useEffect, useMemo, useState } from "react";
import { StringParam, useQueryParams, withDefault } from "use-query-params";
import { StringParam, useQueryParams } from "use-query-params";

import { CONSTANT } from "@acme/constant";

Expand Down
1 change: 1 addition & 0 deletions apps/nextjs/src/utils/photoswipe-video.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ const initLightboxVideoPlugin = (lightbox: PhotoSwipeLightbox) => {
video.controls = true;
video.playsInline = true;
video.preload = "auto";
video.loop = true;
video.setAttribute("poster", content.data.msrc || "");
video.src = content.data.src as string;

Expand Down

0 comments on commit 4527644

Please sign in to comment.