/**
 * Message type identifiers
 */

export const MESSAGE_TYPES = {
  // Webview -> Extension
  GET_LOCAL_DATA: "GET_LOCAL_DATA",
  SAVE_STATE: "SAVE_STATE",
  UPDATE_ISSUE: "UPDATE_ISSUE",
  CREATE_ISSUE: "CREATE_ISSUE",
  OPEN_ISSUE_FILE: "OPEN_ISSUE_FILE",
  OPEN_URL: "OPEN_URL",
  UPDATE_CONFIG: "UPDATE_CONFIG",

  // Extension -> Webview
  DATA_UPDATED: "DATA_UPDATED",
  REFRESH: "REFRESH",
  SHOW_CREATE_VIEW: "SHOW_CREATE_VIEW",
  SHOW_SETTINGS: "SHOW_SETTINGS",
  AGENT_STATE_UPDATED: "AGENT_STATE_UPDATED",
} as const;

export type MessageType = (typeof MESSAGE_TYPES)[keyof typeof MESSAGE_TYPES];
