@synerise/ds-icon-picker 2.0.4 → 2.0.6
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/CHANGELOG.md +19 -0
- package/CLAUDE.md +1 -1
- package/dist/IconPicker.js +1 -1
- package/dist/IconPicker.types.d.ts +1 -1
- package/dist/components/List/List.js +1 -1
- package/dist/components/ListItem/ListItem.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/utils/typeguards.utils.d.ts +1 -1
- package/package.json +10 -10
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,25 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [2.0.6](https://github.com/Synerise/synerise-design/compare/@synerise/ds-icon-picker@2.0.5...@synerise/ds-icon-picker@2.0.6) (2026-09-22)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Bug Fixes
|
|
10
|
+
|
|
11
|
+
* **core:** move test helpers to a ./testing subpath export ([b38cd82](https://github.com/Synerise/synerise-design/commit/b38cd82c956111d2331d5c1e0efd1935366f1139))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
## [2.0.5](https://github.com/Synerise/synerise-design/compare/@synerise/ds-icon-picker@2.0.4...@synerise/ds-icon-picker@2.0.5) (2026-09-18)
|
|
18
|
+
|
|
19
|
+
**Note:** Version bump only for package @synerise/ds-icon-picker
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
6
25
|
## [2.0.4](https://github.com/Synerise/synerise-design/compare/@synerise/ds-icon-picker@2.0.3...@synerise/ds-icon-picker@2.0.4) (2026-09-16)
|
|
7
26
|
|
|
8
27
|
**Note:** Version bump only for package @synerise/ds-icon-picker
|
package/CLAUDE.md
CHANGED
|
@@ -152,4 +152,4 @@ Flattens `FilterElement[]` into `GroupedFilterElement[]` for react-window. Each
|
|
|
152
152
|
- **`ListItem` has a fragile Avatar check** — `(element.item as any).type.name === 'Avatar'` detects Avatar items by component name. Minification or renaming will break this.
|
|
153
153
|
- **Deep import for DS icons** — `import * as medium from '@synerise/ds-icon/dist/icons/M'` is a fragile path that may break if `@synerise/ds-icon` restructures its dist output.
|
|
154
154
|
- **Uses Vitest** — `package.json` has `"test": "jest"`. Spec also uses `vi.fn()`. Not yet migrated.
|
|
155
|
-
- **`react-intl` is required** — `IntlProvider` must be present for the default `noResultMsg`. Tests use `renderWithProvider` from `@synerise/ds-core`.
|
|
155
|
+
- **`react-intl` is required** — `IntlProvider` must be present for the default `noResultMsg`. Tests use `renderWithProvider` from `@synerise/ds-core/testing`.
|
package/dist/IconPicker.js
CHANGED
|
@@ -6,9 +6,9 @@ import Dropdown from "@synerise/ds-dropdown";
|
|
|
6
6
|
import Icon, { AddM, Close3S } from "@synerise/ds-icon";
|
|
7
7
|
import Tooltip from "@synerise/ds-tooltip";
|
|
8
8
|
import { useOnClickOutside } from "@synerise/ds-utils";
|
|
9
|
-
import { ClearIcon, Overlay } from "./IconPicker.styles.js";
|
|
10
9
|
import Overlay$1 from "./components/Overlay/Overlay.js";
|
|
11
10
|
import { useIconSourceLoader } from "./hooks/useIconSourceLoader.js";
|
|
11
|
+
import { ClearIcon, Overlay } from "./IconPicker.styles.js";
|
|
12
12
|
import { matchesSearchQuery } from "./utils/matchesSearchQuery.js";
|
|
13
13
|
const IconPicker = ({
|
|
14
14
|
button,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { CSSProperties, ReactElement, ReactNode } from 'react';
|
|
2
1
|
import { IconName, IconPrefix } from '@fortawesome/fontawesome-svg-core';
|
|
2
|
+
import { CSSProperties, ReactElement, ReactNode } from 'react';
|
|
3
3
|
import { PopoverTriggerType } from '@synerise/ds-popover';
|
|
4
4
|
export type IconMetadata = {
|
|
5
5
|
name?: string;
|
|
@@ -4,9 +4,9 @@ import { FormattedMessage } from "react-intl";
|
|
|
4
4
|
import { useTheme } from "@synerise/ds-core";
|
|
5
5
|
import Icon, { SearchNoResultsM } from "@synerise/ds-icon";
|
|
6
6
|
import Scrollbar from "@synerise/ds-scrollbar";
|
|
7
|
+
import { useGroupItems } from "../../hooks/useGroupItems.js";
|
|
7
8
|
import { ITEMS_PER_ROW, ELEMENT_HEIGHT } from "../../IconPicker.const.js";
|
|
8
9
|
import { OverlayWrapper, NoResults, Content, NoResultIcon, VirtualList } from "../../IconPicker.styles.js";
|
|
9
|
-
import { useGroupItems } from "../../hooks/useGroupItems.js";
|
|
10
10
|
import { createItemData } from "../../utils/createItemData.js";
|
|
11
11
|
import { RowItem } from "../RowItem.js";
|
|
12
12
|
const List = ({
|
|
@@ -11,7 +11,7 @@ const ListItem = ({
|
|
|
11
11
|
const selectIcon = () => {
|
|
12
12
|
onSelect(element.value, element.metadata ?? {});
|
|
13
13
|
};
|
|
14
|
-
return /* @__PURE__ */ jsx(ListItem$1, { itemsPerRow, children: typeof element.item !== "string" && //
|
|
14
|
+
return /* @__PURE__ */ jsx(ListItem$1, { itemsPerRow, children: typeof element.item !== "string" && // biome-ignore lint/suspicious/noExplicitAny: upstream type is not expressible here
|
|
15
15
|
element.item.type.name === "Avatar" ? /* @__PURE__ */ jsx(IconTrigger, { onMouseUp: selectIcon, "data-testid": `icon-${index}`, children: element.item }) : /* @__PURE__ */ jsx(Tooltip, { title: element.keywords, children: /* @__PURE__ */ jsx(Button, { type: "ghost", mode: "single-icon", onClick: selectIcon, children: /* @__PURE__ */ jsx(IconTrigger, { "data-testid": `icon-${index}`, children: /* @__PURE__ */ jsx("div", { className: "icon-wrapper", children: typeof element.item === "string" ? /* @__PURE__ */ jsx(FontIcon, { children: element.item }) : element.item }) }) }) }) });
|
|
16
16
|
};
|
|
17
17
|
export {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { default } from './IconPicker';
|
|
2
|
-
export type {
|
|
2
|
+
export type { DataSource, DSSource, FASource, FAValue, FilterElement, FilterItem, IconMetadata, IconPickerProps, SourceType, } from './IconPicker.types';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Category,
|
|
1
|
+
import { Category, DataSource, DSSource, FASource, GroupedFilterElement, SourceType } from '../IconPicker.types';
|
|
2
2
|
export declare const isFASourceType: (data: SourceType) => data is FASource;
|
|
3
3
|
export declare const isDSSourceType: (data: SourceType) => data is DSSource;
|
|
4
4
|
export declare const isData: (data: SourceType) => data is DataSource[];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synerise/ds-icon-picker",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.6",
|
|
4
4
|
"description": "IconPicker UI Component for the Synerise Design System",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"repository": "Synerise/synerise-design",
|
|
@@ -39,14 +39,14 @@
|
|
|
39
39
|
"sideEffects": false,
|
|
40
40
|
"types": "dist/index.d.ts",
|
|
41
41
|
"dependencies": {
|
|
42
|
-
"@synerise/ds-button": "^2.0
|
|
43
|
-
"@synerise/ds-button-group": "^2.0.
|
|
44
|
-
"@synerise/ds-dropdown": "^2.1.
|
|
45
|
-
"@synerise/ds-icon": "^2.1.
|
|
46
|
-
"@synerise/ds-popover": "^2.0.
|
|
47
|
-
"@synerise/ds-scrollbar": "^2.0.
|
|
48
|
-
"@synerise/ds-tooltip": "^2.0.
|
|
49
|
-
"@synerise/ds-utils": "^2.
|
|
42
|
+
"@synerise/ds-button": "^2.1.0",
|
|
43
|
+
"@synerise/ds-button-group": "^2.0.5",
|
|
44
|
+
"@synerise/ds-dropdown": "^2.1.2",
|
|
45
|
+
"@synerise/ds-icon": "^2.1.3",
|
|
46
|
+
"@synerise/ds-popover": "^2.0.3",
|
|
47
|
+
"@synerise/ds-scrollbar": "^2.0.4",
|
|
48
|
+
"@synerise/ds-tooltip": "^2.0.5",
|
|
49
|
+
"@synerise/ds-utils": "^2.2.0",
|
|
50
50
|
"memoize-one": "^5.1.1",
|
|
51
51
|
"react-window": "^1.8.11"
|
|
52
52
|
},
|
|
@@ -62,5 +62,5 @@
|
|
|
62
62
|
"styled-components": "^5.3.3",
|
|
63
63
|
"vitest": "4"
|
|
64
64
|
},
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "5e795fa4fd23f6b07277edb517a84bb9b5b6d256"
|
|
66
66
|
}
|