Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
move ownbeaconstatus to write dir
Browse files Browse the repository at this point in the history
Signed-off-by: Kerry Archibald <kerrya@element.io>
  • Loading branch information
Kerry Archibald committed Apr 12, 2022
1 parent 356cd19 commit b11567e
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ import React, { HTMLProps } from 'react';

import { _t } from '../../../languageHandler';
import { useOwnLiveBeacons } from '../../../utils/beacon';
import BeaconStatus from '../beacon/BeaconStatus';
import { BeaconDisplayStatus } from '../beacon/displayStatus';
import BeaconStatus from './BeaconStatus';
import { BeaconDisplayStatus } from './displayStatus';
import AccessibleButton from '../elements/AccessibleButton';

interface Props {
Expand Down Expand Up @@ -56,33 +56,33 @@ const OwnBeaconStatus: React.FC<Props & HTMLProps<HTMLDivElement>> = ({
displayLiveTimeRemaining
{...rest}
>
{ ownDisplayStatus === BeaconDisplayStatus.Active && <AccessibleButton
{ownDisplayStatus === BeaconDisplayStatus.Active && <AccessibleButton
data-test-id='beacon-status-stop-beacon'
kind='link'
onClick={onStopSharing}
className='mx_BeaconStatus_destructiveButton'
disabled={stoppingInProgress}
>
{ _t('Stop') }
{_t('Stop')}
</AccessibleButton>
}
{ hasWireError && <AccessibleButton
{hasWireError && <AccessibleButton
data-test-id='beacon-status-reset-wire-error'
kind='link'
onClick={onResetWireError}
className='mx_BeaconStatus_destructiveButton'
>
{ _t('Retry') }
{_t('Retry')}
</AccessibleButton>
}
{ hasStopSharingError && <AccessibleButton
{hasStopSharingError && <AccessibleButton
data-test-id='beacon-status-stop-beacon-retry'
kind='link'
onClick={onStopSharing}
className='mx_BeaconStatus_destructiveButton'
>
{ _t('Retry') }
</AccessibleButton> }
{_t('Retry')}
</AccessibleButton>}
</BeaconStatus>;
};

Expand Down
2 changes: 1 addition & 1 deletion src/components/views/messages/MBeaconBody.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import BeaconStatus from '../beacon/BeaconStatus';
import Spinner from '../elements/Spinner';
import Map from '../location/Map';
import SmartMarker from '../location/SmartMarker';
import OwnBeaconStatus from '../location/OwnBeaconStatus';
import OwnBeaconStatus from '../beacon/OwnBeaconStatus';
import { IBodyProps } from "./IBodyProps";

const useBeaconState = (beaconInfoEvent: MatrixEvent): {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import { act } from 'react-dom/test-utils';
import { mocked } from 'jest-mock';
import { Beacon } from 'matrix-js-sdk/src/matrix';

import OwnBeaconStatus from '../../../../src/components/views/location/OwnBeaconStatus';
import OwnBeaconStatus from '../../../../src/components/views/beacon/OwnBeaconStatus';
import { BeaconDisplayStatus } from '../../../../src/components/views/beacon/displayStatus';
import { useOwnLiveBeacons } from '../../../../src/utils/beacon';
import { findByTestId, makeBeaconInfoEvent } from '../../../test-utils';
Expand Down

0 comments on commit b11567e

Please sign in to comment.