mirror of
https://github.com/vector-im/element-call.git
synced 2026-03-28 06:50:26 +00:00
Hide back & hangup buttons when ?embed query param is passed
This commit is contained in:
@@ -80,6 +80,14 @@ export function RoomHeaderInfo({ roomName, avatarUrl }) {
|
||||
export function RoomSetupHeaderInfo({ roomName, avatarUrl, ...rest }) {
|
||||
const ref = useRef();
|
||||
const { buttonProps } = useButton(rest, ref);
|
||||
const isEmbedded = window.location.search.includes("embed");
|
||||
if (isEmbedded) {
|
||||
return (
|
||||
<div className={styles.backButton} ref={ref} {...buttonProps}>
|
||||
<RoomHeaderInfo roomName={roomName} avatarUrl={avatarUrl} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
return (
|
||||
<button className={styles.backButton} ref={ref} {...buttonProps}>
|
||||
<ArrowLeftIcon width={16} height={16} />
|
||||
|
||||
Reference in New Issue
Block a user