(e)
| 91 | const query = useSubscribeStatusQuery() |
| 92 | |
| 93 | const handleSubList: React.EventHandler<any> = async (e) => { |
| 94 | if (!canSub) { |
| 95 | toast.error('订阅功能暂时没有开启哦') |
| 96 | return |
| 97 | } |
| 98 | preventDefault(e) |
| 99 | const { email, types } = state |
| 100 | await apiClient.subscribe.subscribe( |
| 101 | email, |
| 102 | // @ts-ignore |
| 103 | Object.keys(types).filter((name) => state.types[name]) as any[], |
| 104 | ) |
| 105 | |
| 106 | toast.success('订阅成功,谢谢你!') |
| 107 | dispatch({ type: 'reset' }) |
| 108 | onConfirm() |
| 109 | } |
| 110 | const title = useAggregationSelector((data) => data.seo.title) |
| 111 | |
| 112 | return ( |
nothing calls this directly
no test coverage detected