fmt(js): npm run fix on merge (#110575)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
4e3e520584
commit
5eb99eb284
@@ -88,7 +88,13 @@ import { ComposerTriggerPopover } from './trigger-popover'
|
||||
import type { ChatBarProps } from './types'
|
||||
import { isRedoShortcut, isUndoShortcut } from './undo-history'
|
||||
import { UrlDialog } from './url-dialog'
|
||||
import { chipTypedUrlOnSpace, linkifyUrls, markdownLinkFor, resolveExactLinkPaste, selectionLinkLabel } from './url-refs'
|
||||
import {
|
||||
chipTypedUrlOnSpace,
|
||||
linkifyUrls,
|
||||
markdownLinkFor,
|
||||
resolveExactLinkPaste,
|
||||
selectionLinkLabel
|
||||
} from './url-refs'
|
||||
import { VoiceActivity, VoicePlaybackActivity } from './voice-activity'
|
||||
|
||||
export function ChatBar({
|
||||
|
||||
@@ -2,7 +2,13 @@ import type { KeyboardEvent } from 'react'
|
||||
import { describe, expect, it } from 'vitest'
|
||||
|
||||
import { composerPlainText, refChipElement, RICH_INPUT_SLOT } from './rich-editor'
|
||||
import { chipTypedUrlOnSpace, linkifyUrls, markdownLinkFor, resolveExactLinkPaste, selectionLinkLabel } from './url-refs'
|
||||
import {
|
||||
chipTypedUrlOnSpace,
|
||||
linkifyUrls,
|
||||
markdownLinkFor,
|
||||
resolveExactLinkPaste,
|
||||
selectionLinkLabel
|
||||
} from './url-refs'
|
||||
|
||||
/** An editor holding `text` with a collapsed caret at `caret`, plus the space
|
||||
* keydown the composer would hand `chipTypedUrlOnSpace`. */
|
||||
|
||||
@@ -32,10 +32,9 @@ export function isRouteSessionMismatch(
|
||||
storedSessionId === routedSessionId ||
|
||||
Boolean(
|
||||
storedSessionId &&
|
||||
sessions.some(
|
||||
session =>
|
||||
sessionMatchesStoredId(session, routedSessionId) && sessionMatchesStoredId(session, storedSessionId)
|
||||
)
|
||||
sessions.some(
|
||||
session => sessionMatchesStoredId(session, routedSessionId) && sessionMatchesStoredId(session, storedSessionId)
|
||||
)
|
||||
)
|
||||
|
||||
// The selected view already owns the routed conversation: a profile or
|
||||
|
||||
@@ -4171,6 +4171,7 @@ describe('openNewSessionTile workspace target', () => {
|
||||
|
||||
throw new Error(`Unexpected ambient RPC: ${method}`)
|
||||
})
|
||||
|
||||
vi.mocked(requestGatewayForProfile).mockResolvedValue({ control: {} } as never)
|
||||
|
||||
let handle: HarnessHandle | null = null
|
||||
@@ -4219,6 +4220,7 @@ describe('openNewSessionTile workspace target', () => {
|
||||
|
||||
throw new Error(`Unexpected ambient RPC: ${method}`)
|
||||
})
|
||||
|
||||
vi.mocked(requestGatewayForProfile).mockResolvedValue({ control: {} } as never)
|
||||
|
||||
let handle: HarnessHandle | null = null
|
||||
|
||||
@@ -776,8 +776,9 @@ export function useSessionActions({
|
||||
const requestedProfile = normalizeProfileKey(
|
||||
typeof options?.profile === 'string' && options.profile
|
||||
? options.profile
|
||||
: ($newChatProfile.get() || $activeGatewayProfile.get())
|
||||
: $newChatProfile.get() || $activeGatewayProfile.get()
|
||||
)
|
||||
|
||||
const legacyOwnerProfile =
|
||||
options?.route === undefined &&
|
||||
!capturedRoute &&
|
||||
|
||||
@@ -6,7 +6,10 @@
|
||||
* inside a menu — Radix menu items are `div[role=menuitem]`, so the tag check
|
||||
* alone would let Space both activate the item and toggle playback.
|
||||
*/
|
||||
export function shouldIgnorePlaybackHotkey(e: Pick<KeyboardEvent, 'code' | 'defaultPrevented' | 'key' | 'target'>, activeElement: Element | null): boolean {
|
||||
export function shouldIgnorePlaybackHotkey(
|
||||
e: Pick<KeyboardEvent, 'code' | 'defaultPrevented' | 'key' | 'target'>,
|
||||
activeElement: Element | null
|
||||
): boolean {
|
||||
if (e.code !== 'Space' && e.key !== ' ') {
|
||||
return true
|
||||
}
|
||||
|
||||
@@ -11,7 +11,13 @@ import {
|
||||
workspaceScopeKey
|
||||
} from '@/components/pane-shell/workspace-scope'
|
||||
import { $activeGatewayProfile } from '@/store/profile'
|
||||
import { $activeSessionId, $connection, $selectedStoredSessionId, setSessionOwnerHint, setSessions } from '@/store/session'
|
||||
import {
|
||||
$activeSessionId,
|
||||
$connection,
|
||||
$selectedStoredSessionId,
|
||||
setSessionOwnerHint,
|
||||
setSessions
|
||||
} from '@/store/session'
|
||||
import type { SessionProfileRoute } from '@/store/session-request-router'
|
||||
import type { SessionTile } from '@/store/session-states'
|
||||
import type * as SessionStatesModule from '@/store/session-states'
|
||||
|
||||
Reference in New Issue
Block a user