import { r as registerInstance, B as Build, h } from './index-e0adbd54.js';

const appExhaustListCss = "";

const AppExhaustList = class {
  constructor(hostRef) {
    registerInstance(this, hostRef);
    this.paginationEl = undefined;
    this.query = undefined;
  }
  onSearchInput(event) {
    this.query = event.target.value;
  }
  componentDidLoad() {
    if (!(Build === null || Build === void 0 ? void 0 : Build.isBrowser))
      return;
  }
  render() {
    return [
      h("ion-content", { class: "ion-padding" }, h("floodteam-title-bar", null, h("ion-router-link", { href: "/exhausts" }, "Exhaust Readings"), h("ion-buttons", { slot: "end" }, h("ion-button", { fill: "solid", color: "primary", href: "/exhausts/new" }, "Add"))), h("div", { class: "ion-padding" }, h("fireenjin-search-bar", { ref: (el) => (this.filterBarEl = el), paginationEl: this.paginationEl, filters: null })), h("fireenjin-pagination", { ref: (el) => (this.paginationEl = el), gridEl: ({ result }) => (h("floodteam-snapshot-card", { href: `/exhaust/${result.id}`, buttonText: "View Exhaust" }, h("ion-label", null, h("h2", null, result.id ? result.id : "")))), listEl: ({ result }) => (h("ion-item", { href: `/exhaust/${result.id}`, detail: true }, h("ion-label", null, h("h2", null, result.id ? result.id : "")))), endpoint: "listExhausts", limit: 20, resultsKey: "exhausts", query: this.query, name: "exhausts" })),
      h("floodteam-navigation-footer", null),
    ];
  }
};
AppExhaustList.style = appExhaustListCss;

export { AppExhaustList as app_exhaust_list };
