Move link notification to the conversation hero
This commit is contained in:
parent
5f3a62cbb6
commit
2f44e33c9c
26 changed files with 174 additions and 350 deletions
|
@ -38,7 +38,6 @@ import {
|
|||
} from './sessionTranslation';
|
||||
import * as zkgroup from './zkgroup';
|
||||
import { StartupQueue } from './StartupQueue';
|
||||
import { postLinkExperience } from './postLinkExperience';
|
||||
import { sendToGroup, sendContentMessageToGroup } from './sendToGroup';
|
||||
import { RetryPlaceholders } from './retryPlaceholders';
|
||||
import * as expirationTimer from './expirationTimer';
|
||||
|
@ -70,7 +69,6 @@ export {
|
|||
MessageController,
|
||||
missingCaseError,
|
||||
parseRemoteClientExpiration,
|
||||
postLinkExperience,
|
||||
queueUpdateMessage,
|
||||
RetryPlaceholders,
|
||||
saveNewMessageBatcher,
|
||||
|
|
|
@ -1,32 +0,0 @@
|
|||
// Copyright 2021 Signal Messenger, LLC
|
||||
// SPDX-License-Identifier: AGPL-3.0-only
|
||||
|
||||
import { MINUTE } from './durations';
|
||||
|
||||
class PostLinkExperience {
|
||||
private hasNotFinishedSync: boolean;
|
||||
|
||||
constructor() {
|
||||
this.hasNotFinishedSync = false;
|
||||
}
|
||||
|
||||
start() {
|
||||
this.hasNotFinishedSync = true;
|
||||
|
||||
// timeout "post link" after 10 minutes in case the syncs don't complete
|
||||
// in time or are never called.
|
||||
setTimeout(() => {
|
||||
this.stop();
|
||||
}, 10 * MINUTE);
|
||||
}
|
||||
|
||||
stop() {
|
||||
this.hasNotFinishedSync = false;
|
||||
}
|
||||
|
||||
isActive(): boolean {
|
||||
return this.hasNotFinishedSync === true;
|
||||
}
|
||||
}
|
||||
|
||||
export const postLinkExperience = new PostLinkExperience();
|
Loading…
Add table
Add a link
Reference in a new issue