Tidy 5e Sheets API
    Preparing search index...

    Class ActorPortraitApi

    API functionality related to Actor portraits.

    Index

    Constructors

    Methods

    Constructors

    Methods

    • Register actor portrait menu commands which Tidy 5e can render on the sheet when appropriate.

      Parameters

      Returns void

      Hooks.once("tidy5e-sheet.ready", (api) => {
      api.config.actorPortrait.registerMenuCommands([
      {
      label: "Test",
      iconClass: "fa-solid fa-flask",
      tooltip: "Click for test result",
      enabled: (params) => params.actor.type !== "vehicle",
      execute: (params) => {
      console.log(params);
      ui.notifications.info(
      "Hello, Test Portrait Menu Command for " + params.actor.name
      );
      },
      },
      ]);
      });