import { defineStore } from 'pinia'

export const useCountryStore = defineStore('country', {
  state: () => ({
    list: [], //国家列表
    selectedCountry: {}, //选中的国家
  }),
  actions: {
    setCountryList(data) {
      this.list = data
    },
    setCountry(country) {
      this.selectedCountry = country
    },
  },
})
