import { a as Ctx, L as Loading } from "./index.js";
import React__default from "react";
import { s as styles } from "./URLGenerator.module.js";
import "./validator.js";
import "./dateFns.js";
import "./reactPlayer.js";
import "react-router-dom";
import "./reactSlick.js";
class InvitationURLGenerator extends React__default.Component {
  constructor(props) {
    super(props);
    this.tryInvite = () => {
      const { invitationId } = this.props;
      const invitationURL = Ctx.getAppState().getSdk().IAM.UserAuthorization().createLoginURL(null, `invitation/${invitationId}`);
      window.location.replace(invitationURL);
    };
  }
  componentDidMount() {
    this.tryInvite();
  }
  render() {
    return /* @__PURE__ */ React__default.createElement("div", {
      className: styles.invitationURLGenerator
    }, /* @__PURE__ */ React__default.createElement("div", {
      className: "loadingContainer"
    }, /* @__PURE__ */ React__default.createElement(Loading, null)));
  }
}
export { InvitationURLGenerator as default };
