Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
require("../chunk-BN4qSVkS.cjs");
const require_utils_strings = require("../utils/strings.cjs");
const require_utils_toReactNodes_nodes = require("../utils/toReactNodes/nodes.cjs");
const require_components_Icon_Icon = require("./Icon/Icon.cjs");
const require_styles_fields = require("../styles/fields.cjs");
const require_components_InfoIconTooltip = require("./InfoIconTooltip.cjs");
let _emotion_react_jsx_runtime = require("@emotion/react/jsx-runtime");
//#region src/components/SatoshiInputLabel.tsx
function SatoshiInputLabel({ text, availableSats, showTooltip = true }) {
	const availableSatsTooltipNode = showTooltip ? /* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsxs)(require_styles_fields.Label, {
		style: {
			display: "inline-flex",
			margin: "0 0 0 3px"
		},
		children: [
			"available",
			" ",
			/* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsx)(require_components_InfoIconTooltip.InfoIconTooltip, {
				id: "available-balance-tooltip",
				content: ["Your available balance may differ from your total balance due to operational funds being held on the Lightning Network. ", require_utils_toReactNodes_nodes.link({
					text: "Learn more",
					externalLink: "https://docs.lightspark.com/lightspark-sdk/api-reference/types/Balances"
				})]
			})
		]
	}) : null;
	return /* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsxs)(require_styles_fields.Label, { children: [/* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsx)("div", { children: text }), /* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsx)("div", { children: availableSats !== void 0 && /* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsxs)("div", { children: [
		/* @__PURE__ */ (0, _emotion_react_jsx_runtime.jsx)(require_components_Icon_Icon.Icon, {
			name: "Satoshi",
			width: 8,
			mr: 4,
			verticalAlign: -2
		}),
		require_utils_strings.addCommasToDigits(Math.floor(availableSats)),
		availableSatsTooltipNode
	] }) })] });
}
//#endregion
exports.SatoshiInputLabel = SatoshiInputLabel;
