From 77950e48c76f4a3b29d01831d43039caba29888a Mon Sep 17 00:00:00 2001
From: wwf <1971391498@qq.com>
Date: 星期二, 18 十一月 2025 14:12:42 +0800
Subject: [PATCH] 修改
---
app/components/app/configuration/dataset-config/params-config/weighted-score.tsx | 13 ++++++-------
1 files changed, 6 insertions(+), 7 deletions(-)
diff --git a/app/components/app/configuration/dataset-config/params-config/weighted-score.tsx b/app/components/app/configuration/dataset-config/params-config/weighted-score.tsx
index 5f0ad94..87767c2 100644
--- a/app/components/app/configuration/dataset-config/params-config/weighted-score.tsx
+++ b/app/components/app/configuration/dataset-config/params-config/weighted-score.tsx
@@ -3,7 +3,6 @@
import './weighted-score.css'
import Slider from '@/app/components/base/slider'
import cn from '@/utils/classnames'
-import { noop } from 'lodash-es'
const formatNumber = (value: number) => {
if (value > 0 && value < 1)
@@ -24,15 +23,15 @@
}
const WeightedScore = ({
value,
- onChange = noop,
+ onChange = () => {},
}: WeightedScoreProps) => {
const { t } = useTranslation()
return (
<div>
- <div className='space-x-3 rounded-lg border border-components-panel-border px-3 pb-2 pt-5'>
+ <div className='px-3 pt-5 pb-2 space-x-3 rounded-lg border border-components-panel-border'>
<Slider
- className={cn('h-0.5 grow rounded-full !bg-util-colors-teal-teal-500')}
+ className={cn('grow h-0.5 !bg-util-colors-teal-teal-500 rounded-full')}
max={1.0}
min={0}
step={0.1}
@@ -40,14 +39,14 @@
onChange={v => onChange({ value: [v, (10 - v * 10) / 10] })}
trackClassName='weightedScoreSliderTrack'
/>
- <div className='mt-3 flex justify-between'>
- <div className='system-xs-semibold-uppercase flex w-[90px] shrink-0 items-center text-util-colors-blue-light-blue-light-500'>
+ <div className='flex justify-between mt-3'>
+ <div className='shrink-0 flex items-center w-[90px] system-xs-semibold-uppercase text-util-colors-blue-light-blue-light-500'>
<div className='mr-1 truncate uppercase' title={t('dataset.weightedScore.semantic') || ''}>
{t('dataset.weightedScore.semantic')}
</div>
{formatNumber(value.value[0])}
</div>
- <div className='system-xs-semibold-uppercase flex w-[90px] shrink-0 items-center justify-end text-util-colors-teal-teal-500'>
+ <div className='shrink-0 flex items-center justify-end w-[90px] system-xs-semibold-uppercase text-util-colors-teal-teal-500'>
{formatNumber(value.value[1])}
<div className='ml-1 truncate uppercase' title={t('dataset.weightedScore.keyword') || ''}>
{t('dataset.weightedScore.keyword')}
--
Gitblit v1.8.0