mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-02-23 23:54:13 +08:00
- Adds a new InjectedComponentSet for the role 'ThreadList:Label'. - Adds a new label to the thread list indicating the snooze date if the thread has been snoozed - Coerces MailLabel to achieve this. This is a temporary hack, we should design a better view to display snooze date information
27 lines
985 B
JavaScript
27 lines
985 B
JavaScript
/** @babel */
|
|
import {ComponentRegistry} from 'nylas-exports';
|
|
import {ToolbarSnooze, BulkThreadSnooze} from './snooze-toolbar-components';
|
|
import SnoozeQuickActionButton from './snooze-quick-action-button'
|
|
import SnoozeMailLabel from './snooze-mail-label'
|
|
import SnoozeStore from './snooze-store'
|
|
|
|
|
|
export function activate() {
|
|
this.snoozeStore = new SnoozeStore()
|
|
ComponentRegistry.register(ToolbarSnooze, {role: 'message:Toolbar'});
|
|
ComponentRegistry.register(SnoozeQuickActionButton, {role: 'ThreadListQuickAction'});
|
|
ComponentRegistry.register(BulkThreadSnooze, {role: 'thread:BulkAction'});
|
|
ComponentRegistry.register(SnoozeMailLabel, {role: 'ThreadList:Label'});
|
|
}
|
|
|
|
export function deactivate() {
|
|
ComponentRegistry.unregister(ToolbarSnooze);
|
|
ComponentRegistry.unregister(SnoozeQuickActionButton);
|
|
ComponentRegistry.unregister(BulkThreadSnooze);
|
|
ComponentRegistry.unregister(SnoozeMailLabel);
|
|
this.snoozeStore.deactivate()
|
|
}
|
|
|
|
export function serialize() {
|
|
|
|
}
|