import { Spinner as e } from "../../atoms/spinner/Spinner.js";
import { button as t, container as n, left as r, meta as i } from "./backofficeLoadMore.css.js";
import { jsx as a, jsxs as o } from "react/jsx-runtime";
import { useTranslation as s } from "react-i18next";
//#region src/backoffice/molecules/backoffice_load_more/BackofficeLoadMore.tsx
var c = ({ hasNextPage: c, isLoading: l, onLoadMore: u, loadMoreLabel: d, endLabel: f, loadingLabel: p, meta: m }) => {
	let { t: h } = s("ui"), g = d ?? h("backoffice.loadMore.moreAvailable"), _ = f ?? h("backoffice.loadMore.end"), v = p ?? h("backoffice.loadMore.loading"), y = _;
	c && (y = g), l && (y = v);
	let b = null;
	l && (b = /* @__PURE__ */ a(e, { size: 16 }));
	let x = null;
	return c && !l && u != null && (x = /* @__PURE__ */ a("button", {
		type: "button",
		className: t,
		onClick: u,
		children: g
	})), /* @__PURE__ */ o("div", {
		className: n,
		children: [/* @__PURE__ */ o("div", {
			className: r,
			children: [
				b,
				/* @__PURE__ */ a("span", {
					className: i,
					children: y
				}),
				m
			]
		}), x]
	});
};
//#endregion
export { c as BackofficeLoadMore, c as default };

//# sourceMappingURL=BackofficeLoadMore.js.map