@designbasekorea/ui 0.2.31 → 0.2.33

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -2526,6 +2526,8 @@
2526
2526
  };
2527
2527
  const RandomGradient = ({ scheme = 'primary', tone = 'vivid', width = '100%', height = '600px', blur = 60, colorCount = 4, animated = false, animationDuration = 10, overlay = true, overlayOpacity = 0.2, children, className, }) => {
2528
2528
  const [gradientStyle, setGradientStyle] = React.useState({});
2529
+ // 블러 최소값 60으로 제한
2530
+ const minBlur = Math.max(60, blur);
2529
2531
  // 그라데이션 생성 함수
2530
2532
  const generateGradient = React.useMemo(() => {
2531
2533
  return () => {
@@ -2542,11 +2544,11 @@
2542
2544
  const centerY = Math.random() * 100;
2543
2545
  return {
2544
2546
  background: `radial-gradient(circle at ${centerX}% ${centerY}%, ${gradientStops})`,
2545
- filter: `blur(${blur}px)`,
2547
+ filter: `blur(${minBlur}px)`,
2546
2548
  transition: `all ${animationDuration}s ease-in-out`,
2547
2549
  };
2548
2550
  };
2549
- }, [scheme, tone, colorCount, blur, animationDuration]);
2551
+ }, [scheme, tone, colorCount, minBlur, animationDuration]);
2550
2552
  // 초기 그라데이션 및 애니메이션
2551
2553
  React.useEffect(() => {
2552
2554
  setGradientStyle(generateGradient());
@@ -5452,6 +5454,10 @@
5452
5454
  onChange?.(formatted);
5453
5455
  // eslint-disable-next-line react-hooks/exhaustive-deps
5454
5456
  }, [formatted]); // onChange와 value를 의존성에서 제거
5457
+ /** formatted 변경시 colorInput 동기화 */
5458
+ React.useEffect(() => {
5459
+ setColorInput(formatted.toUpperCase());
5460
+ }, [formatted]);
5455
5461
  /** 드롭다운 외부 클릭 닫기 */
5456
5462
  React.useEffect(() => {
5457
5463
  const handler = (e) => {