@bds-web/ui 1.15.0 → 1.16.0

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.
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Dropdown/ui/index.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAM/C,eAAO,MAAM,QAAQ,GAAI,uDAMtB,aAAa,4CAsCf,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Dropdown/ui/index.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAM/C,eAAO,MAAM,QAAQ,GAAI,uDAMtB,aAAa,4CAoCf,CAAC"}
@@ -8,7 +8,7 @@ import { DropdownPortal } from "./DropdownPortal";
8
8
  export const Dropdown = ({ dropdownSize = "small", onSelect, options, selected, width = "auto", }) => {
9
9
  const { isOpen, closeDropdown, toggleDropdown } = useDropdown();
10
10
  const containerRef = useOutsideClick(isOpen, closeDropdown);
11
- return (_jsxs(S.Container, { ref: containerRef, "$size": dropdownSize, "$width": width, onClick: toggleDropdown, style: { position: "relative" }, children: [_jsxs(S.SelectedItem, { children: [_jsx(S.SelectedText, { children: selected ? selected.name : "선택해주세요." }), _jsx(TriangleIcon, {})] }), _jsx(DropdownPortal, { containerRef: containerRef, isOpen: isOpen, children: _jsx(S.OptionsList, { "$size": dropdownSize, "$isOpen": isOpen, children: options.map((option, idx) => (_jsx(S.OptionItem, { "$isSelected": selected?.value === option.value, "$size": dropdownSize, onClick: e => {
11
+ return (_jsxs(S.Container, { ref: containerRef, "$size": dropdownSize, "$width": width, onClick: toggleDropdown, style: { position: "relative" }, children: [_jsxs(S.SelectedItem, { children: [_jsx(S.SelectedText, { children: selected ? selected.name : "선택해주세요." }), _jsx(TriangleIcon, {})] }), _jsx(DropdownPortal, { containerRef: containerRef, isOpen: isOpen, children: _jsx(S.OptionsList, { "$isOpen": isOpen, children: options.map((option, idx) => (_jsx(S.OptionItem, { "$isSelected": selected?.value === option.value, "$size": dropdownSize, onClick: (e) => {
12
12
  e.stopPropagation();
13
13
  onSelect(option);
14
14
  closeDropdown();
@@ -18,7 +18,6 @@ export declare const OptionsList: import("@emotion/styled").StyledComponent<{
18
18
  theme?: import("@emotion/react").Theme;
19
19
  as?: React.ElementType;
20
20
  } & {
21
- $size: DropdownSize;
22
21
  $isOpen: boolean;
23
22
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, {}>;
24
23
  export declare const OptionItem: import("@emotion/styled").StyledComponent<{
@@ -1 +1 @@
1
- {"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../src/Dropdown/ui/style.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAK9C,eAAO,MAAM,SAAS;;;;WAAuB,YAAY;YAAU,MAAM;yGAWxE,CAAC;AAEF,eAAO,MAAM,YAAY;;;yGAQxB,CAAC;AAEF,eAAO,MAAM,YAAY;;;2GAIxB,CAAC;AAEF,eAAO,MAAM,WAAW;;;;WAAsB,YAAY;aAAW,OAAO;6GAiB3E,CAAC;AAEF,eAAO,MAAM,UAAU;;;;WACd,YAAY;iBACN,OAAO;yGAerB,CAAC"}
1
+ {"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../src/Dropdown/ui/style.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAK9C,eAAO,MAAM,SAAS;;;;WAAuB,YAAY;YAAU,MAAM;yGAWxE,CAAC;AAEF,eAAO,MAAM,YAAY;;;yGAQxB,CAAC;AAEF,eAAO,MAAM,YAAY;;;2GAIxB,CAAC;AAEF,eAAO,MAAM,WAAW;;;;aAAwB,OAAO;6GAUtD,CAAC;AAEF,eAAO,MAAM,UAAU;;;;WACd,YAAY;iBACN,OAAO;yGAerB,CAAC"}
@@ -35,13 +35,7 @@ export const OptionsList = styled.ul `
35
35
  overflow-y: scroll;
36
36
  background-color: ${colors.static.white};
37
37
  border-radius: ${shapes.large};
38
- ${({ $size }) => $size === "small"
39
- ? `
40
- border: 1px solid ${colors.greyScale[20]};
41
- `
42
- : `
43
- box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.05);
44
- `};
38
+ box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.05);
45
39
  position: static;
46
40
  box-sizing: border-box;
47
41
  z-index: ${({ $isOpen }) => ($isOpen ? 100 : -1)};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bds-web/ui",
3
- "version": "1.15.0",
3
+ "version": "1.16.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",