mirror of
https://github.com/vector-im/element-call.git
synced 2026-07-30 19:39:22 +00:00
add appBar logging
This commit is contained in:
@@ -19,6 +19,7 @@ import {
|
|||||||
import { Button, Heading, Tooltip } from "@vector-im/compound-web";
|
import { Button, Heading, Tooltip } from "@vector-im/compound-web";
|
||||||
import { CollapseIcon } from "@vector-im/compound-design-tokens/assets/web/icons";
|
import { CollapseIcon } from "@vector-im/compound-design-tokens/assets/web/icons";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
|
import { logger } from "matrix-js-sdk/lib/logger";
|
||||||
|
|
||||||
import { Header, LeftNav, RightNav } from "./Header";
|
import { Header, LeftNav, RightNav } from "./Header";
|
||||||
import { platform } from "./Platform";
|
import { platform } from "./Platform";
|
||||||
@@ -132,6 +133,10 @@ export function useAppBarSecondaryButton(button: ReactNode): void {
|
|||||||
if (setSecondaryButton !== undefined) {
|
if (setSecondaryButton !== undefined) {
|
||||||
setSecondaryButton(button);
|
setSecondaryButton(button);
|
||||||
return (): void => setSecondaryButton("");
|
return (): void => setSecondaryButton("");
|
||||||
|
} else {
|
||||||
|
logger.warn(
|
||||||
|
"[AppBar] useAppBarSecondaryButton called without AppBarContext provider, this will have no effect",
|
||||||
|
);
|
||||||
}
|
}
|
||||||
}, [button, setSecondaryButton]);
|
}, [button, setSecondaryButton]);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -157,7 +157,8 @@ export const InCallFooter: FC<InCallFooterProps> = ({
|
|||||||
if (audioOutputButton) buttons.push(audioOutputButton);
|
if (audioOutputButton) buttons.push(audioOutputButton);
|
||||||
|
|
||||||
useAppBarSecondaryButton(
|
useAppBarSecondaryButton(
|
||||||
<SettingsButton key="settings" onClick={openSettings} />,
|
// <SettingsButton key="settings" onClick={openSettings} />,
|
||||||
|
<div style={{ backgroundColor: "red", width: "20px", height: "20px" }} />,
|
||||||
);
|
);
|
||||||
|
|
||||||
buttons.push(
|
buttons.push(
|
||||||
|
|||||||
Reference in New Issue
Block a user