From 394c26123db21c410daa7ad57ec76bee4207b75f Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@gmail.com> Date: Fri, 29 Jul 2022 15:06:58 +0100 Subject: [PATCH] Delint --- src/@types/global.d.ts | 5 --- .../views/beacon/BeaconViewDialog.tsx | 42 +++++++++---------- 2 files changed, 21 insertions(+), 26 deletions(-) diff --git a/src/@types/global.d.ts b/src/@types/global.d.ts index d8c8ffef129..bd4dcbd4385 100644 --- a/src/@types/global.d.ts +++ b/src/@types/global.d.ts @@ -174,12 +174,7 @@ declare global { } interface HTMLDialogElement { - readonly open: boolean; - returnValue?: string; oncancel?(ev: Event); - show(): void; - showModal(): void; - close(returnValue?: string): void; } // Add Chrome-specific `instant` ScrollBehaviour diff --git a/src/components/views/beacon/BeaconViewDialog.tsx b/src/components/views/beacon/BeaconViewDialog.tsx index b99c14edccb..a7a5929b155 100644 --- a/src/components/views/beacon/BeaconViewDialog.tsx +++ b/src/components/views/beacon/BeaconViewDialog.tsx @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -import React, { useState, useEffect } from 'react'; +import React, { useState, useEffect, useContext } from 'react'; import { Beacon, Room, @@ -136,7 +136,8 @@ const BeaconViewDialog: React.FC = ({ id='mx_BeaconViewDialog' bounds={bounds} centerGeoUri={centerGeoUri} - interactiveonError={setMapDisplayError} + interactive + onError={setMapDisplayError} className="mx_BeaconViewDialog_map" > { @@ -152,26 +153,25 @@ const BeaconViewDialog: React.FC = ({ } } - { mapDisplayError && - - } - { !centerGeoUri && !mapDisplayError && - { _t('No live locations') } - - { _t('Close') } - - + { mapDisplayError && + } + { !centerGeoUri && !mapDisplayError && + { _t('No live locations') } + + { _t('Close') } + + } { isSidebarOpen ? setSidebarOpen(false)} /> :