<template>
  <view>
    <up-checkbox-group v-model="selectedWeek" :options="week">
      <up-checkbox
      :customStyle="customStyle"
      :shape="shape"
        v-for="item in week"
        :key="item.value"
        :value="item.value"
        :name="item.value"
        :label="item.value"
        >{{ item.name }}</up-checkbox>
    </up-checkbox-group>
  </view>
</template>
<script setup>
import { ref } from "vue";

const customStyle={
  marginRight: '40rpx',
  marginBottom: '16rpx',
}
const props = defineProps({
  shape: {
    type: String,
    default: 'square' // circle
  },
});
const selectedWeek=defineModel({
  type: Array,
  default: () => [],
});
const week = ref([
  {
    name: "周一",
    value:"周一",
  },
  {
    name: "周二",
    value:"周二",
  },
  {
    name: "周三",
    value:"周三",
  },
  {
    name: "周四",
    value:"周四",
  },
  {
    name: "周五",
    value:"周五",
  },
  {
    name: "周六",
    value:"周六",
  },
  {
    name: "周日",
    value:"周日",
  },
]);
</script>