"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.ModuleStatic = void 0;
var _reactNative = require("react-native");
var _context = require("../../context");
var _core = require("../../core");
var _layout = require("../layout");
var _jsxRuntime = require("react/jsx-runtime");
const DISABLED_OPACITY = 0.5;
const ModuleStatic = ({
  disabled = false,
  startBlock,
  endBlock,
  children,
  accessible = false,
  accessibilityLabel,
  accessibilityState
}) => {
  const theme = (0, _context.useIOTheme)();
  return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.View, {
    style: [_core.IOModuleStyles.button, {
      borderColor: _core.IOColors[theme["cardBorder-default"]],
      opacity: disabled ? DISABLED_OPACITY : 1
    }],
    accessible: accessible,
    accessibilityLabel: accessibilityLabel,
    accessibilityState: accessibilityState,
    children: [startBlock && /*#__PURE__*/(0, _jsxRuntime.jsxs)(_layout.HStack, {
      space: 8,
      style: {
        alignItems: "center"
      },
      children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.View, {
        style: {
          flexDirection: "row",
          alignItems: "center",
          flexGrow: 1
        },
        children: startBlock
      }), endBlock]
    }), children]
  });
};
exports.ModuleStatic = ModuleStatic;
//# sourceMappingURL=ModuleStatic.js.map