🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
TypeScript agentagent-collaborationagent-harnessloop-engineeringmcppersonal-assistantproactive-agentskillssuper-agenttask-management
💄 style: compact device guard alert (#15776)
Arvin Xuebe8411e7e00
diff --git a/src/routes/(main)/agent/features/Conversation/HeterogeneousChatInput/index.tsx b/src/routes/(main)/agent/features/Conversation/HeterogeneousChatInput/index.tsxindex 3eab8a7c704..ee3f90cd1e4 100644--- a/src/routes/(main)/agent/features/Conversation/HeterogeneousChatInput/index.tsx+++ b/src/routes/(main)/agent/features/Conversation/HeterogeneousChatInput/index.tsx@@ -92,13 +92,14 @@ const HeterogeneousChatInput = memo(() => {}return (- <Flexbox paddingBlock={'0 6px'} paddingInline={12}>- <Alert- title={title}- type={'warning'}- description={- <Flexbox horizontal align={'center'} gap={8} justify={'space-between'}>- <span>{desc}</span>+ <WideScreenContainer>+ <Flexbox align={'center'} paddingBlock={'0 8px'} paddingInline={12}>+ <Alert+ description={desc}+ style={{ maxWidth: 880, width: '100%' }}+ title={title}+ type={'warning'}+ action={<Flexbox horizontal gap={6}><Button size={'small'} onClick={refresh}>{t('platformAgent.deviceGuard.refresh')}@@ -107,44 +108,50 @@ const HeterogeneousChatInput = memo(() => {{t('platformAgent.deviceGuard.configure')}</Button></Flexbox>- </Flexbox>- }- />- </Flexbox>+ }+ />+ </Flexbox>+ </WideScreenContainer>+ );+ };++ const renderCloudConfigGuard = () => {+ if (isDeviceExecution || isConfigured) return null;++ return (+ <WideScreenContainer>+ <Flexbox align={'center'} paddingBlock={'0 8px'} paddingInline={12}>+ <Alert+ description={t('heteroAgent.cloudNotConfigured.desc')}+ style={{ maxWidth: 880, width: '100%' }}+ title={t('heteroAgent.cloudNotConfigured.title')}+ type={'warning'}+ action={+ <Button size={'small'} type={'primary'} onClick={goToConfig}>+ {t('heteroAgent.cloudNotConfigured.action')}+ </Button>+ }+ />+ </Flexbox>+ </WideScreenContainer>);};// Device execution doesn't use the cloud sandbox, so it doesn't need cloud// credentials — only the sandbox path gates on `isConfigured`.const inputDisabled = (!isConfigured && !isDeviceExecution) || deviceBlocked;+ const hasGuard = deviceBlocked || (!isConfigured && !isDeviceExecution);return (<Flexbox>- {!isDeviceExecution && !isConfigured && (- <WideScreenContainer>- <Flexbox paddingBlock={'0 6px'} paddingInline={12}>- <Alert- title={t('heteroAgent.cloudNotConfigured.title')}- type={'warning'}- description={- <Flexbox horizontal align={'center'} gap={8} justify={'space-between'}>- <span>{t('heteroAgent.cloudNotConfigured.desc')}</span>- <Button size={'small'} type={'primary'} onClick={goToConfig}>- {t('heteroAgent.cloudNotConfigured.action')}- </Button>- </Flexbox>- }- />- </Flexbox>- </WideScreenContainer>- )}+ {renderCloudConfigGuard()}{renderDeviceGuard()}<ChatInput- skipScrollMarginWithListcontrolBarSlot={<HeteroControlBar />}leftActions={leftActions}rightActions={rightActions}sendButtonProps={{ disabled: inputDisabled, shape: 'round' }}+ skipScrollMarginWithList={!hasGuard}onEditorReady={(instance) => {// Sync to global ChatStore for compatibility with other featuresuseChatStore.setState({ mainInputEditor: instance });