"use strict";

import { View } from "react-native";
import { useIOTheme } from "../../context";
import { IOColors, IOModuleStyles } from "../../core";
import { HStack } from "../layout";
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
const DISABLED_OPACITY = 0.5;
export const ModuleStatic = ({
  disabled = false,
  startBlock,
  endBlock,
  children,
  accessible = false,
  accessibilityLabel,
  accessibilityState
}) => {
  const theme = useIOTheme();
  return /*#__PURE__*/_jsxs(View, {
    style: [IOModuleStyles.button, {
      borderColor: IOColors[theme["cardBorder-default"]],
      opacity: disabled ? DISABLED_OPACITY : 1
    }],
    accessible: accessible,
    accessibilityLabel: accessibilityLabel,
    accessibilityState: accessibilityState,
    children: [startBlock && /*#__PURE__*/_jsxs(HStack, {
      space: 8,
      style: {
        alignItems: "center"
      },
      children: [/*#__PURE__*/_jsx(View, {
        style: {
          flexDirection: "row",
          alignItems: "center",
          flexGrow: 1
        },
        children: startBlock
      }), endBlock]
    }), children]
  });
};
//# sourceMappingURL=ModuleStatic.js.map