telegramsjs
    Preparing search index...

    Class Checklist

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    entities?: MessageEntities

    Special entities that appear in the checklist title

    othersCanAddTasks?: true

    True, if users other than the creator of the list can add tasks to the list

    othersCanMarkTasksAsDone?: true

    True, if users other than the creator of the list can mark tasks as done or not done

    tasks: ReadonlyCollection<number, ChecklistTask>

    Collection of tasks in the checklist

    title: string

    Title of the checklist

    Accessors

    • get completedTasks(): ReadonlyCollection<
          number,
          ChecklistTask & {
              completedByUser: User;
              completionTimestamp: number;
              completionUnixTime: number;
              isCompleted: true;
          },
      >

      Get completed tasks

      Returns ReadonlyCollection<
          number,
          ChecklistTask & {
              completedByUser: User;
              completionTimestamp: number;
              completionUnixTime: number;
              isCompleted: true;
          },
      >

    • get completedTasksCount(): number

      Get number of completed tasks

      Returns number

    • get pendingTasks(): ReadonlyCollection<number, never>

      Get pending tasks

      Returns ReadonlyCollection<number, never>

    • get totalTasks(): number

      Get total number of tasks

      Returns number

    Methods

    • Protected

      Creates a clone of the current instance

      Returns Base

      A clone of the current instance

    • Protected

      Patches the current instance with new data

      Parameters

      • data: Record<string, any>

        The data to patch the instance with

      Returns Record<string, any>

      The patched data

    • Protected

      Updates the current instance with new data and returns a clone of the updated instance

      Parameters

      • data: Record<string, any>

        The data to update the instance with

      Returns Base

      A clone of the updated instance

    • Makes the class iterable, returning each check task list

      Returns IterableIterator<ChecklistTask>

    • Flatten an object. Any properties that are collections will get converted to an array of keys.

      Parameters

      • OptionalpropsRecursive: boolean

        Optional. If true, calls toJSON method on nested objects.

      • ...props: Record<string, string | boolean>[]

        Optional. Specific properties to include/exclude, or rename.

      Returns Record<string, any>

      Flattened object.

    • Returns the id instance Chat, User, ChatMember and other

      Returns string | null