Home Reference Source
import {NotificationCategory} from '~/models/NotificationCategorizer.js'
public class | source

NotificationCategory

Represents a notification category

Constructor Summary

Public Constructor
public

constructor(name: string, notification: NotificationGroup[])

Member Summary

Public Members
public

Time-based name of category

public

Prefer the generator

Method Summary

Public Methods
public

This iterates in sorted order

public

Returns all IDs

public

Returns if any item in the group is unread

Public Constructors

public constructor(name: string, notification: NotificationGroup[]) source

Params:

NameTypeAttributeDescription
name string
notification NotificationGroup[]

groups expects in sorted order.

Public Members

public name: string source

Time-based name of category

public notificationGroups: NotificationGroup[] source

Prefer the generator

Public Methods

public * [Symbol.iterator]() source

This iterates in sorted order

public * getIds(): Generator<string> source

Returns all IDs

Return:

Generator<string>

public async getStatus(): NotificationStatus source

Returns if any item in the group is unread