VerificationExplorer: remove reference to internal class (#12362)
* VerificationExplorer: remove reference to internal class The legacy `VerificationRequest` is an internal class. * handle null timeout
This commit is contained in:
parent
d36c1b39fd
commit
4a182e89b0
2 changed files with 10 additions and 9 deletions
|
@ -16,8 +16,11 @@ limitations under the License.
|
|||
*/
|
||||
|
||||
import React, { useContext, useEffect, useState } from "react";
|
||||
import { VerificationRequest } from "matrix-js-sdk/src/crypto/verification/request/VerificationRequest";
|
||||
import { VerificationPhase as Phase, VerificationRequestEvent } from "matrix-js-sdk/src/crypto-api";
|
||||
import {
|
||||
VerificationPhase as Phase,
|
||||
VerificationRequest,
|
||||
VerificationRequestEvent,
|
||||
} from "matrix-js-sdk/src/crypto-api";
|
||||
import { CryptoEvent } from "matrix-js-sdk/src/crypto";
|
||||
|
||||
import { useTypedEventEmitter, useTypedEventEmitterState } from "../../../../hooks/useEventEmitter";
|
||||
|
@ -67,13 +70,11 @@ const VerificationRequestExplorer: React.FC<{
|
|||
<dt>{_t("devtools|phase")}</dt>
|
||||
<dd>{PHASE_MAP[request.phase] ? _t(PHASE_MAP[request.phase]) : request.phase}</dd>
|
||||
<dt>{_t("devtools|timeout")}</dt>
|
||||
<dd>{Math.floor(timeout / 1000)}</dd>
|
||||
<dd>{timeout === null ? _t("devtools|timeout_none") : Math.floor(timeout / 1000)}</dd>
|
||||
<dt>{_t("devtools|methods")}</dt>
|
||||
<dd>{request.methods && request.methods.join(", ")}</dd>
|
||||
<dt>{_t("devtools|requester")}</dt>
|
||||
<dd>{request.requestingUserId}</dd>
|
||||
<dt>{_t("devtools|observe_only")}</dt>
|
||||
<dd>{JSON.stringify(request.observeOnly)}</dd>
|
||||
<dt>{_t("devtools|other_user")}</dt>
|
||||
<dd>{request.otherUserId}</dd>
|
||||
</dl>
|
||||
</div>
|
||||
);
|
||||
|
|
|
@ -742,15 +742,14 @@
|
|||
"notification_state": "Notification state is <strong>%(notificationState)s</strong>",
|
||||
"notifications_debug": "Notifications debug",
|
||||
"number_of_users": "Number of users",
|
||||
"observe_only": "Observe only",
|
||||
"original_event_source": "Original event source",
|
||||
"other_user": "Other user",
|
||||
"phase": "Phase",
|
||||
"phase_cancelled": "Cancelled",
|
||||
"phase_ready": "Ready",
|
||||
"phase_requested": "Requested",
|
||||
"phase_started": "Started",
|
||||
"phase_transaction": "Transaction",
|
||||
"requester": "Requester",
|
||||
"room_encrypted": "Room is <strong>encrypted ✅</strong>",
|
||||
"room_id": "Room ID: %(roomId)s",
|
||||
"room_not_encrypted": "Room is <strong>not encrypted 🚨</strong>",
|
||||
|
@ -789,6 +788,7 @@
|
|||
"thread_root_id": "Thread Root ID: %(threadRootId)s",
|
||||
"threads_timeline": "Threads timeline",
|
||||
"timeout": "Timeout",
|
||||
"timeout_none": "None",
|
||||
"title": "Developer tools",
|
||||
"toggle_event": "toggle event",
|
||||
"toolbox": "Toolbox",
|
||||
|
|
Loading…
Reference in a new issue