var VPProfile = (function () {
    let vt_template = `

    <div class="row">
    <!-- <div class="col-xxl-9 col-lg-8"> -->
        <div class="col-xxl-12 col-lg-12">
            <me :tinymcekey="tinymcekey" ref="el_me"/>
            <!-- end card -->
            <div v-if="false" class="card-style mb-30">
                <div class="
                    title
                    d-flex
                    align-items-center
                    justify-content-between
                    flex-wrap
                  ">
                    <h6 class="mb-20">Featured</h6>
                    <a href="#0" class="main-btn btn-sm primary-btn btn-hover mb-20">
                        <i class="lni lni-plus mr-10"></i>
                        Add new feature
                    </a>
                </div>
                <div class="row">
                    <div class="col-md-6 col-lg-12 col-xl-6">
                        <div class="card-style-6 mb-30">
                            <div class="card-meta mb-25">
                                <div class="d-flex align-items-center flex-wrap mb-10">
                                    <h5 class="text-bold mr-20">
                                        <a href="#0" class="title">Lindy Uikit</a>
                                    </h5>
                                    <span>11 Jun, 2022</span>
                                </div>
                                <p>I will Design Landing page, UI/UX ...</p>
                            </div>
                            <div class="card-image">
                                <a href="#0">
                                    <img src="https://demo.plainadmin.com/assets/images/cards/card-style-6/card-1.jpg" alt="">
                                </a>
                            </div>
                            <div class="card-action">
                                <div class="action mr-20">
                                    <button><i class="lni lni-thumbs-up"></i></button>
                                    <a href="#0">434 Like</a>
                                </div>
                                <div class="action">
                                    <button><i class="lni lni-comments"></i></button>
                                    <a href="#0">43 Comments</a>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-6 col-lg-12 col-xl-6">
                        <div class="card-style-6 mb-30">
                            <div class="card-meta mb-25">
                                <div class="d-flex align-items-center flex-wrap mb-10">
                                    <h5 class="text-bold mr-20">
                                        <a href="#0" class="title">EcommaerceHTML</a>
                                    </h5>
                                    <span>11 Jun, 2022</span>
                                </div>
                                <p>I will Design Landing page, UI/UX ...</p>
                            </div>
                            <div class="card-image">
                                <a href="#0">
                                    <img src="https://demo.plainadmin.com/assets/images/cards/card-style-6/card-2.jpg" alt="">
                                </a>
                            </div>
                            <div class="card-action">
                                <div class="action mr-20">
                                    <button><i class="lni lni-thumbs-up"></i></button>
                                    <a href="#0">434 Like</a>
                                </div>
                                <div class="action">
                                    <button><i class="lni lni-comments"></i></button>
                                    <a href="#0">43 Comments</a>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-6 col-lg-12 col-xl-6">
                        <div class="card-style-6 mb-30">
                            <div class="card-meta mb-25">
                                <div class="d-flex align-items-center flex-wrap mb-10">
                                    <h5 class="text-bold mr-20">
                                        <a href="#0" class="title">Cripto Template</a>
                                    </h5>
                                    <span>11 Jun, 2022</span>
                                </div>
                                <p>I will Design Landing page, UI/UX ...</p>
                            </div>
                            <div class="card-image">
                                <a href="#0">
                                    <img src="https://demo.plainadmin.com/assets/images/cards/card-style-6/card-3.jpg" alt="">
                                </a>
                            </div>
                            <div class="card-action">
                                <div class="action mr-20">
                                    <button><i class="lni lni-thumbs-up"></i></button>
                                    <a href="#0">434 Like</a>
                                </div>
                                <div class="action">
                                    <button><i class="lni lni-comments"></i></button>
                                    <a href="#0">43 Comments</a>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-6 col-lg-12 col-xl-6">
                        <div class="card-style-6 mb-30">
                            <div class="card-meta mb-25">
                                <div class="d-flex align-items-center flex-wrap mb-10">
                                    <h5 class="text-bold mr-20">
                                        <a href="#0" class="title">Plain Bootstrap Template</a>
                                    </h5>
                                    <span>11 Jun, 2022</span>
                                </div>
                                <p>I will Design Landing page, UI/UX ...</p>
                            </div>
                            <div class="card-image">
                                <a href="#0">
                                    <img src="https://demo.plainadmin.com/assets/images/cards/card-style-6/card-4.jpg" alt="">
                                </a>
                            </div>
                            <div class="card-action">
                                <div class="action mr-20">
                                    <button><i class="lni lni-thumbs-up"></i></button>
                                    <a href="#0">434 Like</a>
                                </div>
                                <div class="action">
                                    <button><i class="lni lni-comments"></i></button>
                                    <a href="#0">43 Comments</a>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="col-12">
                        <div class="text-center mb-10">
                            <a href="#0" class="main-btn primary-btn btn-hover">See All</a>
                        </div>
                    </div>
                </div>
            </div>
            <!-- end card -->
        </div>
        <!-- end col -->
        <div v-if="false" class="col-xxl-3 col-lg-4">
            <div class="card-style chat-list-card">
                <div class="
                    title
                    mb-20
                    d-flex
                    justify-content-between
                    align-items-center
                  ">
                    <h6>Messages</h6>
                    <div class="more-btn-wrapper">
                        <button class="more-btn dropdown-toggle" id="moreAction" data-bs-toggle="dropdown" aria-expanded="false">
                            <i class="lni lni-more-alt"></i>
                        </button>
                        <ul class="dropdown-menu dropdown-menu-end" aria-labelledby="moreAction">
                            <li class="dropdown-item">
                                <a href="#0" class="text-gray">Mark as Read</a>
                            </li>
                            <li class="dropdown-item">
                                <a href="#0" class="text-gray">Reply</a>
                            </li>
                        </ul>
                    </div>
                </div>
                <form action="#">
                    <div class="input-style-3">
                        <input type="text" placeholder="Search....">
                        <span class="icon">
                            <i class="lni lni-search-alt"></i>
                        </span>
                    </div>
                </form>
                <!-- end search form -->
                <div class="chat-list-wrapper">
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-6.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Jacob Jones</h6>
                                    <div class="d-flex align-items-center">
                                        <span>20m</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">I cam across your profile and...</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-4.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Ronald Richards</h6>
                                    <div class="d-flex align-items-center">
                                        <span>25m</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">I like your confidence 💪</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-1.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Esther Howard</h6>
                                    <div class="d-flex align-items-center">
                                        <span>30m</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">Can you share your offer?</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-2.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Cody Fisher</h6>
                                    <div class="d-flex align-items-center">
                                        <span>32m</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">When you available for talk?</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-3.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Devon Lane</h6>
                                    <div class="d-flex align-items-center">
                                        <span>40m</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">I’m waiting for you response?</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-4.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Robert Fox</h6>
                                    <div class="d-flex align-items-center">
                                        <span>1h</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">Can you share your brief and...</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-5.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Jenny Wilson</h6>
                                    <div class="d-flex align-items-center">
                                        <span>2h</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">💪💪💪💪</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                    <a href="#0" class="chat-list d-block">
                        <div class="chat-list-item">
                            <div class="image">
                                <img src="https://demo.plainadmin.com/assets/images/lead/lead-6.png" alt="">
                                <span class="status"></span>
                            </div>
                            <div class="content">
                                <div class="title">
                                    <h6 class="text-sm text-medium">Kathryn Murphy</h6>
                                    <div class="d-flex align-items-center">
                                        <span>2d</span>
                                        <button><i class="lni lni-star"></i></button>
                                    </div>
                                </div>
                                <p class="text-sm">I cam across your profile and...</p>
                            </div>
                        </div>
                    </a>
                    <!-- end chat-list -->
                </div>
            </div>
        </div>
        <!-- end col -->
    </div>
`;

    return {
        name: "profile",
        template: vt_template,
        props: ['tinymcekey'],
        data() {
            return {

                errMsg: '',
            }
        },
        mounted() {
        },
        methods: {
            loadData() {
                this.errMsg = '';
                this.loading = true;
                let data = {
                    [this.$store.state.config.csrf.name]: this.$store.state.config.csrf.value,
                    username: this.username,
                    password: this.password
                };
                axios({
                    method: 'POST',
                    data: data,
                    url: window.location.href,
                }).then((response) => {
                    if (!isObject(response.data)) return Swal.fire('Error', gaem({ response }, response.data), 'error');
                    window.location.href = response.data.redirect_url;
                }, (error) => {
                    this.errorMessage = gaem(error);
                    try {
                        if (typeof error.response.data.messages.csrf != 'undefined') this.$store.state.config.csrf.value = error.response.data.messages.csrf;
                    } catch (error) {

                    }
                }).finally(() => this.loading = false);
            }
        }
    }
})();
