chuigda / Project-705

中国式家长 - 山寨版
7 stars 1 forks source link

增加艰难的撅择对话框 #31

Closed flaribbit closed 2 years ago

flaribbit commented 2 years ago

使用例

<TBDDialog title="艰难的撅择" :text="text" :result="result" :choices="choices" />
import TBDDialog from '@app/components/tbd_dialog.vue'

const text = '你在使用 Agda 语言证明一个简单命题的时候遇到了意料之外的困难:虽然所有人都告诉你这个命题很容易证明,但你就是找不到合适的 Induction。此时你撅腚:'
const result = ref('')
const choices = [
   { text: '找锤哥帮忙', action: () => { } },
   { text: '找千里冰封帮忙', action: () => { } },
   {
      text: '今晚不AC我直播倒立洗头', danger:true, action: () => {
         result.value = '最后还是没做出来(智商 -200)'
      }
   },
]