import { getElementId } from "../../../state/react-page";
import { useDocumentKey } from "./use-document-context";
import { useSelector } from "./use-selector";
function useElementId(elementKey) {
  const documentKey = useDocumentKey();
  return useSelector(
    (state) => documentKey == null || elementKey == null ? null : getElementId(state, documentKey, elementKey)
  );
}
export {
  useElementId
};
//# sourceMappingURL=use-element-id.js.map