feat(ui-flow): composer focus after bot install IPC (Phase 539)
Restore message composer focus in guild mode after create-bot-install-token and install-bot-token handlers complete. Co-authored-by: Cursor <[email protected]>
This commit is contained in:
@@ -753,6 +753,12 @@ async function dispatchUiMessage (platform, msg, hooks = {}) {
|
||||
})
|
||||
send({ type: 'bot-install-token', token: out.token, bot: out.bot, expiresAt: out.expiresAt })
|
||||
pushState()
|
||||
if (platform.mode === 'guild' && platform.activeChannelId) {
|
||||
send({
|
||||
type: 'composer-focus-channel',
|
||||
channelId: platform.activeChannelId
|
||||
})
|
||||
}
|
||||
return true
|
||||
}
|
||||
if (t === 'install-bot-token') {
|
||||
@@ -763,6 +769,12 @@ async function dispatchUiMessage (platform, msg, hooks = {}) {
|
||||
bot: out?.bot || null
|
||||
})
|
||||
pushState()
|
||||
if (platform.mode === 'guild' && platform.activeChannelId) {
|
||||
send({
|
||||
type: 'composer-focus-channel',
|
||||
channelId: platform.activeChannelId
|
||||
})
|
||||
}
|
||||
return true
|
||||
}
|
||||
if (t === 'send-message') {
|
||||
|
||||
Reference in New Issue
Block a user