Skip to content

Commit

Permalink
chore: hide tracing introduce detail (#6049)
Browse files Browse the repository at this point in the history
  • Loading branch information
iamjoel authored Jul 8, 2024
1 parent 411e938 commit 6031873
Showing 1 changed file with 0 additions and 47 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import { useBoolean } from 'ahooks'
import type { LangFuseConfig, LangSmithConfig } from './type'
import { TracingProvider } from './type'
import TracingIcon from './tracing-icon'
import ToggleExpandBtn from './toggle-fold-btn'
import ConfigButton from './config-button'
import { LangfuseIcon, LangsmithIcon } from '@/app/components/base/icons/src/public/tracing'
import Indicator from '@/app/components/header/indicator'
Expand Down Expand Up @@ -134,46 +133,6 @@ const Panel: FC = () => {
)
}

if (!isFold && !hasConfiguredTracing) {
return (
<div className={cn('mb-3')}>
<Title />
<div className='mt-2 flex justify-between p-3 pr-4 items-center bg-white border-[0.5px] border-black/8 rounded-xl shadow-md'>
<div className='flex space-x-2'>
<TracingIcon size='lg' className='m-1' />
<div>
<div className='mb-0.5 leading-6 text-base font-semibold text-gray-900'>{t(`${I18N_PREFIX}.title`)}</div>
<div className='flex justify-between leading-4 text-xs font-normal text-gray-500'>
<span className='mr-2'>{t(`${I18N_PREFIX}.description`)}</span>
<div className='flex space-x-3'>
<LangsmithIcon className='h-4' />
<LangfuseIcon className='h-4' />
</div>
</div>
</div>
</div>

<div className='flex items-center space-x-1'>
<ConfigButton
appId={appId}
readOnly={readOnly}
hasConfigured={false}
enabled={enabled}
onStatusChange={handleTracingEnabledChange}
chosenProvider={inUseTracingProvider}
onChooseProvider={handleChooseProvider}
langSmithConfig={langSmithConfig}
langFuseConfig={langFuseConfig}
onConfigUpdated={handleTracingConfigUpdated}
onConfigRemoved={handleTracingConfigRemoved}
/>
<ToggleExpandBtn isFold={isFold} onFoldChange={setFold} />
</div>
</div>
</div>
)
}

return (
<div className={cn('mb-3 flex justify-between items-center')}>
<Title className='h-[41px]' />
Expand Down Expand Up @@ -214,12 +173,6 @@ const Panel: FC = () => {
controlShowPopup={controlShowPopup}
/>
</div>
{!hasConfiguredTracing && (
<div className='flex items-center' onClick={e => e.stopPropagation()}>
<div className='mx-2 w-px h-3.5 bg-gray-200'></div>
<ToggleExpandBtn isFold={isFold} onFoldChange={setFold} />
</div>
)}
</div>
</div>
)
Expand Down

0 comments on commit 6031873

Please sign in to comment.