import c from "./index-extends.js";
import u from "./index-defineProperty.js";
import a, { forwardRef as w, PureComponent as C } from "react";
import P from "./index-Parser.js";
import g from "./index-getCurrentHref.js";
class n extends C {
  componentDidUpdate() {
    const {
      handleParse: e
    } = this.props;
    e();
  }
  render() {
    const {
      style: e,
      href: d = g(),
      tabs: r,
      hideCover: i,
      width: h,
      height: o,
      showFacepile: f,
      hideCTA: s,
      smallHeader: l,
      adaptContainerWidth: p,
      children: m
    } = this.props;
    return a.createElement("div", {
      className: "fb-page",
      style: e,
      "data-tabs": r,
      "data-hide-cover": i,
      "data-show-facepile": f,
      "data-hide-cta": s,
      "data-href": d,
      "data-small-header": l,
      "data-adapt-container-width": p,
      "data-height": o,
      "data-width": h
    }, m);
  }
}
u(n, "defaultProps", {
  width: void 0,
  height: void 0,
  tabs: void 0,
  hideCover: void 0,
  showFacepile: void 0,
  hideCTA: void 0,
  smallHeader: void 0,
  adaptContainerWidth: void 0,
  children: void 0,
  style: void 0,
  href: void 0
});
w((t, e) => a.createElement(P, null, ({
  handleParse: d
}) => a.createElement(n, c({}, t, {
  handleParse: d,
  ref: e
}))));
