@seed-design/react 1.2.3 → 1.2.5

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.
@@ -37,6 +37,9 @@ const AspectRatio = React__namespace.forwardRef(
37
37
  {
38
38
  ref,
39
39
  className: clsx(aspectRatio$1, className),
40
+ position: "relative",
41
+ overflowX: "hidden",
42
+ overflowY: "hidden",
40
43
  style: {
41
44
  // NOTE: aspectRatio는 iOS 15+부터 지원하기 때문에 padding으로 ratio hack을 사용합니다.
42
45
  "--seed-aspect-ratio-padding": `${1 / ratio * 100}%`,
@@ -6,6 +6,18 @@ export interface AspectRatioProps extends BoxProps {
6
6
  * @default 4 / 3
7
7
  */
8
8
  ratio?: number;
9
+ /**
10
+ * @default "relative"
11
+ */
12
+ position?: BoxProps["position"];
13
+ /**
14
+ * @default "hidden"
15
+ */
16
+ overflowX?: BoxProps["overflowX"];
17
+ /**
18
+ * @default "hidden"
19
+ */
20
+ overflowY?: BoxProps["overflowY"];
9
21
  }
10
22
  export declare const AspectRatio: React.ForwardRefExoticComponent<AspectRatioProps & React.RefAttributes<HTMLDivElement>>;
11
23
  //# sourceMappingURL=AspectRatio.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"AspectRatio.d.ts","sourceRoot":"","sources":["../../../src/components/AspectRatio/AspectRatio.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEhD,MAAM,WAAW,gBAAiB,SAAQ,QAAQ;IAChD;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,WAAW,yFAsBvB,CAAC"}
1
+ {"version":3,"file":"AspectRatio.d.ts","sourceRoot":"","sources":["../../../src/components/AspectRatio/AspectRatio.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAO,KAAK,QAAQ,EAAE,MAAM,YAAY,CAAC;AAEhD,MAAM,WAAW,gBAAiB,SAAQ,QAAQ;IAChD;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAIf;;OAEG;IACH,QAAQ,CAAC,EAAE,QAAQ,CAAC,UAAU,CAAC,CAAC;IAChC;;OAEG;IACH,SAAS,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,CAAC;IAClC;;OAEG;IACH,SAAS,CAAC,EAAE,QAAQ,CAAC,WAAW,CAAC,CAAC;CACnC;AAED,eAAO,MAAM,WAAW,yFAyBvB,CAAC"}
@@ -14,6 +14,9 @@ const AspectRatio = React.forwardRef(
14
14
  {
15
15
  ref,
16
16
  className: clsx(aspectRatio$1, className),
17
+ position: "relative",
18
+ overflowX: "hidden",
19
+ overflowY: "hidden",
17
20
  style: {
18
21
  // NOTE: aspectRatio는 iOS 15+부터 지원하기 때문에 padding으로 ratio hack을 사용합니다.
19
22
  "--seed-aspect-ratio-padding": `${1 / ratio * 100}%`,
@@ -3,9 +3,12 @@
3
3
 
4
4
  Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
5
 
6
+ const jsxRuntime = require('react/jsx-runtime');
6
7
  const bottomSheet = require('@seed-design/css/recipes/bottom-sheet');
8
+ const domUtils = require('@seed-design/dom-utils');
7
9
  const reactDrawer = require('@seed-design/react-drawer');
8
10
  const reactPrimitive = require('@seed-design/react-primitive');
11
+ const React = require('react');
9
12
  const createSlotRecipeContext = require('../../utils/createSlotRecipeContext.cjs');
10
13
  const styled = require('../../utils/styled.cjs');
11
14
 
@@ -33,9 +36,13 @@ const BottomSheetHeader = withContext(
33
36
  "header"
34
37
  );
35
38
  const BottomSheetTitle = withContext(
36
- reactDrawer.Drawer.Title,
39
+ React.forwardRef((props, ref) => {
40
+ const { isCloseButtonRendered } = reactDrawer.useDrawerContext();
41
+ return /* @__PURE__ */ jsxRuntime.jsx(reactDrawer.Drawer.Title, { ref, "data-show-close-button": domUtils.dataAttr(isCloseButtonRendered), ...props });
42
+ }),
37
43
  "title"
38
44
  );
45
+ BottomSheetTitle.displayName = "BottomSheetTitle";
39
46
  const BottomSheetDescription = withContext(reactDrawer.Drawer.Description, "description");
40
47
  const BottomSheetBody = withContext(
41
48
  styled.withStyleProps(reactPrimitive.Primitive.div),
@@ -1 +1 @@
1
- {"version":3,"file":"BottomSheet.d.ts","sourceRoot":"","sources":["../../../src/components/BottomSheet/BottomSheet.tsx"],"names":[],"mappings":";;AAAA,OAAO,EAAe,KAAK,uBAAuB,EAAE,MAAM,uCAAuC,CAAC;AAClG,OAAO,EAAE,MAAM,EAAE,MAAM,2BAA2B,CAAC;AACnD,OAAO,EAAa,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAE9E,OAAO,EAAkB,KAAK,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAMrE,MAAM,WAAW,oBAAqB,SAAQ,uBAAuB,EAAE,MAAM,CAAC,SAAS;CAAG;AAE1F,eAAO,MAAM,eAAe,iEAI1B,CAAC;AAIH,MAAM,WAAW,uBAAwB,SAAQ,MAAM,CAAC,YAAY;CAAG;AAEvE,eAAO,MAAM,kBAAkB,mJAAiB,CAAC;AAIjD,MAAM,WAAW,0BAA2B,SAAQ,MAAM,CAAC,eAAe;CAAG;AAE7E,eAAO,MAAM,qBAAqB,uHAGjC,CAAC;AAIF,MAAM,WAAW,wBAAyB,SAAQ,MAAM,CAAC,aAAa;CAAG;AAEzE,eAAO,MAAM,mBAAmB,qHAG/B,CAAC;AAIF,MAAM,WAAW,uBAAwB,SAAQ,MAAM,CAAC,YAAY;CAAG;AAEvE,eAAO,MAAM,kBAAkB,oHAG9B,CAAC;AAIF,MAAM,WAAW,sBAAuB,SAAQ,MAAM,CAAC,WAAW;CAAG;AAErE,eAAO,MAAM,iBAAiB,mHAG7B,CAAC;AAIF,MAAM,WAAW,qBAAsB,SAAQ,MAAM,CAAC,UAAU;CAAG;AAEnE,eAAO,MAAM,gBAA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BAAyB,SAAQ,MAAM,CAAC,aAAa;CAAG;AAEzE,eAAO,MAAM,mBAAmB,qHAG/B,CAAC;AAIF,MAAM,WAAW,uBAAwB,SAAQ,MAAM,CAAC,YAAY;CAAG;AAEvE,eAAO,MAAM,kBAAkB,oHAG9B,CAAC;AAIF,MAAM,WAAW,sBAAuB,SAAQ,MAAM,CAAC,WAAW;CAAG;AAErE,eAAO,MAAM,iBAAiB,mHAG7B,CAAC;AAIF,MAAM,WAAW,qBAAsB,SAAQ,MAAM,CAAC,UAAU;CAAG;AAEnE,eAAO,MAAM,gBAAgB,sHAS5B,CAAC;AAMF,MAAM,WAAW,2BAA4B,SAAQ,MAAM,CAAC,gBAAgB;CAAG;AAE/E,eAAO,MAAM,sBAAsB,8HAGC,CAAC;AAIrC,MAAM,WAAW,oBACf,SAAQ,cAAc,EACpB,IAAI,CACF,UAAU,EACV,UAAU,GAAG,QAAQ,GAAG,WAAW,GAAG,WAAW,GAAG,gBAAgB,GAAG,YAAY,CACpF,EACD,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C,eAAO,MAAM,eAAe,iHAG3B,CAAC;AAIF,MAAM,WAAW,sBACf,SAAQ,cAAc,EACpB,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC;CAAG;AAE3C,eAAO,MAAM,iBAAiB,mHAG7B,CAAC;AAIF,MAAM,WAAW,2BAA4B,SAAQ,MAAM,CAAC,gBAAgB;CAAG;AAE/E,eAAO,MAAM,sBAAsB,2HAGlC,CAAC"}
@@ -1,7 +1,10 @@
1
1
  'use client';
2
+ import { jsx } from 'react/jsx-runtime';
2
3
  import { bottomSheet } from '@seed-design/css/recipes/bottom-sheet';
3
- import { Drawer } from '@seed-design/react-drawer';
4
+ import { dataAttr } from '@seed-design/dom-utils';
5
+ import { Drawer, useDrawerContext } from '@seed-design/react-drawer';
4
6
  import { Primitive } from '@seed-design/react-primitive';
7
+ import { forwardRef } from 'react';
5
8
  import { createSlotRecipeContext } from '../../utils/createSlotRecipeContext.js';
6
9
  import { withStyleProps } from '../../utils/styled.js';
7
10
 
@@ -29,9 +32,13 @@ const BottomSheetHeader = withContext(
29
32
  "header"
30
33
  );
31
34
  const BottomSheetTitle = withContext(
32
- Drawer.Title,
35
+ forwardRef((props, ref) => {
36
+ const { isCloseButtonRendered } = useDrawerContext();
37
+ return /* @__PURE__ */ jsx(Drawer.Title, { ref, "data-show-close-button": dataAttr(isCloseButtonRendered), ...props });
38
+ }),
33
39
  "title"
34
40
  );
41
+ BottomSheetTitle.displayName = "BottomSheetTitle";
35
42
  const BottomSheetDescription = withContext(Drawer.Description, "description");
36
43
  const BottomSheetBody = withContext(
37
44
  withStyleProps(Primitive.div),
@@ -40,8 +40,8 @@ const React__namespace = /*#__PURE__*/_interopNamespaceDefault(React);
40
40
  const ImageFrame = React__namespace.forwardRef(
41
41
  ({
42
42
  ratio = 4 / 3,
43
- rounded,
44
43
  stroke,
44
+ rounded,
45
45
  src,
46
46
  alt,
47
47
  fallback,
@@ -57,7 +57,7 @@ const ImageFrame = React__namespace.forwardRef(
57
57
  children,
58
58
  ...rest
59
59
  }, ref) => {
60
- return /* @__PURE__ */ jsxRuntime.jsx(AspectRatio.AspectRatio, { ref, ratio, className, ...rest, children: /* @__PURE__ */ jsxRuntime.jsxs(reactImage.Image.Root, { className: imageFrame.imageFrame({ rounded, stroke }), children: [
60
+ return /* @__PURE__ */ jsxRuntime.jsx(AspectRatio.AspectRatio, { ref, ratio, className, ...rest, children: /* @__PURE__ */ jsxRuntime.jsxs(reactImage.Image.Root, { className: imageFrame.imageFrame({ stroke, rounded }), children: [
61
61
  /* @__PURE__ */ jsxRuntime.jsx(
62
62
  reactImage.Image.Content,
63
63
  {
@@ -7,6 +7,12 @@ import { BadgeProps } from '../Badge/Badge';
7
7
  import { FloatProps } from '../Float/Float';
8
8
  import * as React from "react";
9
9
  export interface ImageFrameProps extends Omit<AspectRatioProps, "children">, ImageFrameVariantProps {
10
+ /**
11
+ * @deprecated Deprecated in @seed-design/react@1.2.x; will be removed in 1.3.0.
12
+ * Use borderRadius="r2" instead.
13
+ * Reason: 모서리 스타일은 borderRadius prop으로 통일합니다.
14
+ */
15
+ rounded?: ImageFrameVariantProps["rounded"];
10
16
  src: string;
11
17
  alt: string;
12
18
  fallback?: React.ReactNode;
@@ -1 +1 @@
1
- {"version":3,"file":"ImageFrame.d.ts","sourceRoot":"","sources":["../../../src/components/ImageFrame/ImageFrame.tsx"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,sBAAsB,EAC5B,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAEL,KAAK,0BAA0B,EAChC,MAAM,2CAA2C,CAAC;AACnD,OAAO,EAEL,KAAK,+BAA+B,EACrC,MAAM,gDAAgD,CAAC;AAIxD,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAEtE,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAe,KAAK,gBAAgB,EAAE,MAAM,4BAA4B,CAAC;AAChF,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,gBAAgB,CAAC;AACxD,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAGxD,MAAM,WAAW,eACf,SAAQ,IAAI,CAAC,gBAAgB,EAAE,UAAU,CAAC,EACxC,sBAAsB;IACxB,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,MAAM,CAAC;IACrC,WAAW,CAAC,EAAE,WAAW,GAAG,iBAAiB,GAAG,EAAE,CAAC;IACnD,cAAc,CAAC,EAAE,KAAK,CAAC,2BAA2B,CAAC;IACnD,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,MAAM,CAAC,EAAE,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;AAE3D,eAAO,MAAM,eAAe,8FAI3B,CAAC;AAMF,MAAM,WAAW,mBACf,SAAQ,0BAA0B,EAChC,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC,EAAE,UAAU,CAAC;IACzD,GAAG,EAAE,KAAK,CAAC,SAAS,CAAC;CACtB;AAED,eAAO,MAAM,cAAc,6FAQ1B,CAAC;AAMF,MAAM,WAAW,wBACf,SAAQ,+BAA+B,EACrC,KAAK,CAAC,cAAc,CAAC,eAAe,CAAC;IACvC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC3B;AAED,eAAO,MAAM,mBAAmB,kGAQ/B,CAAC;AA0CF,MAAM,WAAW,6BACf,SAAQ,IAAI,CAAC,eAAe,CAAC,SAAS,EAAE,UAAU,CAAC;CAAG;AAExD,eAAO,MAAM,wBAAwB,yGAcnC,CAAC"}
@@ -17,8 +17,8 @@ import { Icon } from '../Icon/Icon.js';
17
17
  const ImageFrame = React.forwardRef(
18
18
  ({
19
19
  ratio = 4 / 3,
20
- rounded,
21
20
  stroke,
21
+ rounded,
22
22
  src,
23
23
  alt,
24
24
  fallback,
@@ -34,7 +34,7 @@ const ImageFrame = React.forwardRef(
34
34
  children,
35
35
  ...rest
36
36
  }, ref) => {
37
- return /* @__PURE__ */ jsx(AspectRatio, { ref, ratio, className, ...rest, children: /* @__PURE__ */ jsxs(Image.Root, { className: imageFrame({ rounded, stroke }), children: [
37
+ return /* @__PURE__ */ jsx(AspectRatio, { ref, ratio, className, ...rest, children: /* @__PURE__ */ jsxs(Image.Root, { className: imageFrame({ stroke, rounded }), children: [
38
38
  /* @__PURE__ */ jsx(
39
39
  Image.Content,
40
40
  {
@@ -3,7 +3,7 @@ import { PullToRefreshVariantProps } from '@seed-design/css/recipes/pull-to-refr
3
3
  import { ForwardRefExoticComponent, RefAttributes } from 'react';
4
4
  export interface PullToRefreshRootProps extends PullToRefreshVariantProps, PullToRefreshPrimitive.RootProps {
5
5
  }
6
- export declare const PullToRefreshRoot: ForwardRefExoticComponent<PullToRefreshRootProps & RefAttributes<SVGSVGElement>>;
6
+ export declare const PullToRefreshRoot: ForwardRefExoticComponent<PullToRefreshRootProps & RefAttributes<HTMLDivElement>>;
7
7
  export interface PullToRefreshIndicatorProps extends PullToRefreshPrimitive.IndicatorProps {
8
8
  }
9
9
  export declare const PullToRefreshIndicator: ForwardRefExoticComponent<PullToRefreshIndicatorProps & RefAttributes<HTMLDivElement>>;
@@ -1 +1 @@
1
- {"version":3,"file":"PullToRefresh.d.ts","sourceRoot":"","sources":["../../../src/components/PullToRefresh/PullToRefresh.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,IAAI,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAC7F,OAAO,EAEL,KAAK,yBAAyB,EAC/B,MAAM,0CAA0C,CAAC;AAKlD,MAAM,WAAW,sBACf,SAAQ,yBAAyB,EAC/B,sBAAsB,CAAC,SAAS;CAAG;AAEvC,eAAO,MAAM,iBAAiB,kHAG7B,CAAC;AAEF,MAAM,WAAW,2BAA4B,SAAQ,sBAAsB,CAAC,cAAc;CAAG;AAE7F,eAAO,MAAM,sBAAsB,wHAGlC,CAAC;AAEF,MAAM,WAAW,yBAA0B,SAAQ,sBAAsB,CAAC,YAAY;CAAG;AAEzF,eAAO,MAAM,oBAAoB,gIAAiC,CAAC"}
1
+ {"version":3,"file":"PullToRefresh.d.ts","sourceRoot":"","sources":["../../../src/components/PullToRefresh/PullToRefresh.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,aAAa,IAAI,sBAAsB,EAAE,MAAM,oCAAoC,CAAC;AAC7F,OAAO,EAEL,KAAK,yBAAyB,EAC/B,MAAM,0CAA0C,CAAC;AAKlD,MAAM,WAAW,sBACf,SAAQ,yBAAyB,EAC/B,sBAAsB,CAAC,SAAS;CAAG;AAEvC,eAAO,MAAM,iBAAiB,mHAG7B,CAAC;AAEF,MAAM,WAAW,2BAA4B,SAAQ,sBAAsB,CAAC,cAAc;CAAG;AAE7F,eAAO,MAAM,sBAAsB,wHAGlC,CAAC;AAEF,MAAM,WAAW,yBAA0B,SAAQ,sBAAsB,CAAC,YAAY;CAAG;AAEzF,eAAO,MAAM,oBAAoB,gIAAiC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seed-design/react",
3
- "version": "1.2.3",
3
+ "version": "1.2.5",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/daangn/seed-design.git",
@@ -45,9 +45,9 @@
45
45
  "@seed-design/react-checkbox": "1.0.1",
46
46
  "@seed-design/react-collapsible": "0.1.0",
47
47
  "@seed-design/react-dialog": "1.0.2",
48
- "@seed-design/react-drawer": "1.0.8",
48
+ "@seed-design/react-drawer": "1.0.9",
49
49
  "@seed-design/react-field": "1.0.1",
50
- "@seed-design/react-image": "0.1.0",
50
+ "@seed-design/react-image": "0.1.1",
51
51
  "@seed-design/react-fieldset": "0.1.0",
52
52
  "@seed-design/react-field-button": "1.0.1",
53
53
  "@seed-design/react-popover": "1.0.3",
@@ -9,6 +9,21 @@ export interface AspectRatioProps extends BoxProps {
9
9
  * @default 4 / 3
10
10
  */
11
11
  ratio?: number;
12
+
13
+ // following 3 are just here for JSDoc purposes
14
+
15
+ /**
16
+ * @default "relative"
17
+ */
18
+ position?: BoxProps["position"];
19
+ /**
20
+ * @default "hidden"
21
+ */
22
+ overflowX?: BoxProps["overflowX"];
23
+ /**
24
+ * @default "hidden"
25
+ */
26
+ overflowY?: BoxProps["overflowY"];
12
27
  }
13
28
 
14
29
  export const AspectRatio = React.forwardRef<HTMLDivElement, AspectRatioProps>(
@@ -20,6 +35,9 @@ export const AspectRatio = React.forwardRef<HTMLDivElement, AspectRatioProps>(
20
35
  <Box
21
36
  ref={ref}
22
37
  className={clsx(aspectRatio, className)}
38
+ position="relative" // TODO: these are currently here but we might want to make AspectRatio just a Primitive.div which takes BoxProps
39
+ overflowX="hidden"
40
+ overflowY="hidden"
23
41
  style={
24
42
  {
25
43
  // NOTE: aspectRatio는 iOS 15+부터 지원하기 때문에 padding으로 ratio hack을 사용합니다.
@@ -1,6 +1,8 @@
1
1
  import { bottomSheet, type BottomSheetVariantProps } from "@seed-design/css/recipes/bottom-sheet";
2
- import { Drawer } from "@seed-design/react-drawer";
2
+ import { dataAttr } from "@seed-design/dom-utils";
3
+ import { Drawer, useDrawerContext } from "@seed-design/react-drawer";
3
4
  import { Primitive, type PrimitiveProps } from "@seed-design/react-primitive";
5
+ import { forwardRef } from "react";
4
6
  import { createSlotRecipeContext } from "../../utils/createSlotRecipeContext";
5
7
  import { withStyleProps, type StyleProps } from "../../utils/styled";
6
8
 
@@ -63,10 +65,18 @@ export const BottomSheetHeader = withContext<HTMLDivElement, BottomSheetHeaderPr
63
65
  export interface BottomSheetTitleProps extends Drawer.TitleProps {}
64
66
 
65
67
  export const BottomSheetTitle = withContext<HTMLHeadingElement, BottomSheetTitleProps>(
66
- Drawer.Title,
68
+ forwardRef<HTMLHeadingElement, BottomSheetTitleProps>((props, ref) => {
69
+ const { isCloseButtonRendered } = useDrawerContext();
70
+
71
+ return (
72
+ <Drawer.Title ref={ref} data-show-close-button={dataAttr(isCloseButtonRendered)} {...props} />
73
+ );
74
+ }),
67
75
  "title",
68
76
  );
69
77
 
78
+ BottomSheetTitle.displayName = "BottomSheetTitle";
79
+
70
80
  ////////////////////////////////////////////////////////////////////////////////////
71
81
 
72
82
  export interface BottomSheetDescriptionProps extends Drawer.DescriptionProps {}
@@ -24,6 +24,12 @@ import { Icon } from "../Icon/Icon";
24
24
  export interface ImageFrameProps
25
25
  extends Omit<AspectRatioProps, "children">,
26
26
  ImageFrameVariantProps {
27
+ /**
28
+ * @deprecated Deprecated in @seed-design/react@1.2.x; will be removed in 1.3.0.
29
+ * Use borderRadius="r2" instead.
30
+ * Reason: 모서리 스타일은 borderRadius prop으로 통일합니다.
31
+ */
32
+ rounded?: ImageFrameVariantProps["rounded"];
27
33
  src: string;
28
34
  alt: string;
29
35
  fallback?: React.ReactNode;
@@ -46,8 +52,8 @@ export const ImageFrame = React.forwardRef<HTMLDivElement, ImageFrameProps>(
46
52
  (
47
53
  {
48
54
  ratio = 4 / 3,
49
- rounded,
50
55
  stroke,
56
+ rounded,
51
57
  src,
52
58
  alt,
53
59
  fallback,
@@ -67,7 +73,7 @@ export const ImageFrame = React.forwardRef<HTMLDivElement, ImageFrameProps>(
67
73
  ) => {
68
74
  return (
69
75
  <AspectRatio ref={ref} ratio={ratio} className={className} {...rest}>
70
- <Image.Root className={imageFrameRecipe({ rounded, stroke })}>
76
+ <Image.Root className={imageFrameRecipe({ stroke, rounded })}>
71
77
  <Image.Content
72
78
  src={src}
73
79
  alt={alt}
@@ -11,7 +11,7 @@ export interface PullToRefreshRootProps
11
11
  extends PullToRefreshVariantProps,
12
12
  PullToRefreshPrimitive.RootProps {}
13
13
 
14
- export const PullToRefreshRoot = withProvider<SVGSVGElement, PullToRefreshRootProps>(
14
+ export const PullToRefreshRoot = withProvider<HTMLDivElement, PullToRefreshRootProps>(
15
15
  PullToRefreshPrimitive.Root,
16
16
  "root",
17
17
  );