import { Component, h, Host, Prop, State } from '@stencil/core';
export class MentornityWcBridge {
  componentWillLoad() {
    // these variables are explicitly initialised for enabling TypeScript type checking
    const { accessToken, sessionToken, organisationId, organisationDomain, role, userId, groupId, language, timeZone, timeFormat, dateFormat, weekStartDay, isZoomAuthenticated, isGoogleAuthenticated, isMicrosoftAuthenticated, isMicrosoftBusinessAuthenticated } = this;
    this.contextParams = {
      accessToken,
      sessionToken,
      organisationId,
      organisationDomain,
      role,
      userId,
      groupId,
      language,
      timeZone,
      timeFormat,
      dateFormat,
      weekStartDay,
      isZoomAuthenticated,
      isGoogleAuthenticated,
      isMicrosoftAuthenticated,
      isMicrosoftBusinessAuthenticated
    };
  }
  render() {
    const Tag = this.component;
    const extraProps = {};
    if (this.extraProps) {
      this.extraProps.split('&').forEach(keyValuePair => {
        const [key, value] = keyValuePair.split('=');
        extraProps[key] = value;
      });
    }
    return (h(Host, { class: "d-flex flex-grow-1", style: { overflow: 'hidden' } },
      h("mentornity-root-wrapper", null,
        h(Tag, { contextParams: this.contextParams, extraProps: extraProps }))));
  }
  static get is() { return "mentornity-wc-bridge"; }
  static get properties() { return {
    "accessToken": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": "Passed by Mentornity web-client."
      },
      "attribute": "access-token",
      "reflect": false
    },
    "sessionToken": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "session-token",
      "reflect": false
    },
    "organisationId": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "organisation-id",
      "reflect": false
    },
    "organisationDomain": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "organisation-domain",
      "reflect": false
    },
    "role": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "role",
      "reflect": false
    },
    "userId": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "user-id",
      "reflect": false
    },
    "groupId": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "group-id",
      "reflect": false
    },
    "language": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "language",
      "reflect": false
    },
    "timeZone": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "time-zone",
      "reflect": false
    },
    "timeFormat": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "time-format",
      "reflect": false
    },
    "dateFormat": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "date-format",
      "reflect": false
    },
    "weekStartDay": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "'monday' | 'saturday' | 'sunday'",
        "resolved": "\"monday\" | \"saturday\" | \"sunday\"",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "week-start-day",
      "reflect": false
    },
    "isZoomAuthenticated": {
      "type": "boolean",
      "mutable": false,
      "complexType": {
        "original": "boolean",
        "resolved": "boolean",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "is-zoom-authenticated",
      "reflect": false
    },
    "isGoogleAuthenticated": {
      "type": "boolean",
      "mutable": false,
      "complexType": {
        "original": "boolean",
        "resolved": "boolean",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "is-google-authenticated",
      "reflect": false
    },
    "isMicrosoftAuthenticated": {
      "type": "boolean",
      "mutable": false,
      "complexType": {
        "original": "boolean",
        "resolved": "boolean",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "is-microsoft-authenticated",
      "reflect": false
    },
    "isMicrosoftBusinessAuthenticated": {
      "type": "boolean",
      "mutable": false,
      "complexType": {
        "original": "boolean",
        "resolved": "boolean",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "is-microsoft-business-authenticated",
      "reflect": false
    },
    "extraProps": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": true,
      "docs": {
        "tags": [],
        "text": ""
      },
      "attribute": "extra-props",
      "reflect": false
    },
    "component": {
      "type": "string",
      "mutable": false,
      "complexType": {
        "original": "string",
        "resolved": "string",
        "references": {}
      },
      "required": false,
      "optional": false,
      "docs": {
        "tags": [],
        "text": "Component tag to render."
      },
      "attribute": "component",
      "reflect": false
    }
  }; }
  static get states() { return {
    "sessionContext": {},
    "error": {}
  }; }
}
