import { isValidElement as fn } from '../../../../preact/compat/dist/compat.module.mjs';

function isMuiElement(element, muiNames) {
  return /*#__PURE__*/fn(element) && muiNames.indexOf(
  // For server components `muiName` is avaialble in element.type._payload.value.muiName
  // relevant info - https://github.com/facebook/react/blob/2807d781a08db8e9873687fccc25c0f12b4fb3d4/packages/react/src/ReactLazy.js#L45
  // eslint-disable-next-line no-underscore-dangle
  element.type.muiName ?? element.type?._payload?.value?.muiName) !== -1;
}

export { isMuiElement as default };
//# sourceMappingURL=isMuiElement.mjs.map
