<template>
<div class="container-xxl flex-grow-1 container-p-y">
    <div class="row g-3">
    <div class="mt-8">
        <!-- 투표 작성  -->
        <router-link to="/voteboard/write"><WriteBtn /></router-link>

        <!-- 내가한 투표 보기  -->
        <div class="d-flex align-items-center">
        <div class="form-check me-3">
            <input class="form-check-input" type="checkbox" value="" id="deliveryAdd" checked="">
            <label class="form-check-label" for="deliveryAdd">내가 한 투표</label>
        </div>
        <!-- 투표마감/투표중  셀렉트 -->
        <FormSelect class="col-3" name="cate" :isLabel="false" title="투표상태" :data="categoryList" @update:data="category = $event" />
        </div>

        <!-- <QEditor @update:data="content = $event" @update:imageUrls="imageUrls = $event"  :is-alert="true" />
            <button type="button" class="btn btn-primary ms-1" @click="registerContent"><i class="bx bx-check"></i></button> -->

        <!-- 투표리스트 -->
        <vote-list />
        </div>

    </div>
        <!-- <div class="mt-8">
            <pagination />
        </div> -->
</div>
</template>
<script setup>
import { getCurrentInstance, onMounted, ref } from 'vue';
// import Pagination from '@/components/pagination/Pagination.vue';
import router from '@/router';
import FormSelect from '@c/input/FormSelect.vue';
import { useToastStore } from '@s/toastStore';
import QEditor from '@c/editor/QEditor.vue';
import $api from '@api';
import BoardCard from '@c/list/BoardCard.vue';
import Quill from 'quill';
import WriteBtn from '@c/button/WriteBtn.vue';
import voteList from '@c/voteboard/voteCardList.vue';

const toastStore = useToastStore();
const category = ref('0');
const categoryList = ['전체','투표마감', '투표중'];
const boardList = ref([]);
const titleAlert = ref(false);
const addContent = ref('');

onMounted(()=>{
    getBoardList();
})
const getBoardList = () =>{
    $api.get('worddict/getWordList').then((res)=>{
    boardList.value = res.data.data.data;
})
}


</script>

<style></style>
