@ray-js/ipc-player-integration 0.0.25 → 0.0.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -7,6 +7,7 @@ export declare function initPlayerWidgets(ctx: Ctx, options: {
7
7
  hideHorizontalMenu?: boolean;
8
8
  hideScreenShotMenu?: boolean;
9
9
  hideRecordVideoMenu?: boolean;
10
+ hideResolutionMenu?: boolean;
10
11
  hideKbsMenu?: boolean;
11
12
  directionControlProps?: Partial<React.ComponentProps<typeof FullScreen>['directionControlProps']>;
12
13
  }): Promise<void>;
@@ -21,7 +21,8 @@ export async function initPlayerWidgets(ctx, options) {
21
21
  if (resolutionIndex !== -1) {
22
22
  // @ts-ignore
23
23
  newDefaultBottomLeftContent[resolutionIndex].initProps = {
24
- verticalResolutionCustomClick: options.verticalResolutionCustomClick
24
+ verticalResolutionCustomClick: options.verticalResolutionCustomClick,
25
+ hideResolutionMenu: options.hideResolutionMenu
25
26
  };
26
27
  }
27
28
  if (screenShotIndex !== -1) {
@@ -5,6 +5,7 @@ export type ChangeResolutionWhenClick = ScreenType[];
5
5
  type Props = ComponentConfigProps & {
6
6
  className?: string;
7
7
  verticalResolutionCustomClick?: boolean;
8
+ hideResolutionMenu?: boolean;
8
9
  };
9
- export declare const Resolution: (props: Props) => React.JSX.Element;
10
+ export declare const Resolution: (props: Props) => React.JSX.Element | null;
10
11
  export {};
@@ -16,7 +16,8 @@ export const Resolution = props => {
16
16
  addContent,
17
17
  hasContent,
18
18
  className,
19
- verticalResolutionCustomClick
19
+ verticalResolutionCustomClick,
20
+ hideResolutionMenu
20
21
  } = props;
21
22
  const {
22
23
  resolution,
@@ -54,6 +55,9 @@ export const Resolution = props => {
54
55
  event.emit(pauseTimeToHideAllComponent);
55
56
  return true;
56
57
  });
58
+ if (hideResolutionMenu) {
59
+ return null;
60
+ }
57
61
  return /*#__PURE__*/React.createElement(View, {
58
62
  onClick: onResolution,
59
63
  className: clsx(className)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ray-js/ipc-player-integration",
3
- "version": "0.0.25",
3
+ "version": "0.0.26",
4
4
  "description": "IPC 融合播放器",
5
5
  "main": "lib/index",
6
6
  "files": [