mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-12 20:18:41 -09:00
* add type definitions * rename files in lib/actions * rename files from lib/reducers to ts * renamed plugins.js to ts * Add hyper types * Fix ts errors in lib/reducers * Fix ts errors in lib/actions * Fix ts errors in plugins.ts
17 lines
383 B
TypeScript
17 lines
383 B
TypeScript
import {NOTIFICATION_MESSAGE, NOTIFICATION_DISMISS} from '../constants/notifications';
|
|
|
|
export function dismissNotification(id: string) {
|
|
return {
|
|
type: NOTIFICATION_DISMISS,
|
|
id
|
|
};
|
|
}
|
|
|
|
export function addNotificationMessage(text: string, url: string | null = null, dismissable = true) {
|
|
return {
|
|
type: NOTIFICATION_MESSAGE,
|
|
text,
|
|
url,
|
|
dismissable
|
|
};
|
|
}
|