@synerise/ds-subject 0.9.97 → 0.10.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.
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
+ # [0.10.0](https://github.com/Synerise/synerise-design/compare/@synerise/ds-subject@0.9.98...@synerise/ds-subject@0.10.0) (2024-05-29)
7
+
8
+
9
+ ### Features
10
+
11
+ * **list-item:** added prefix, suffix, ordered props ([3927035](https://github.com/Synerise/synerise-design/commit/39270352b6a681f3ac402edb6c2fb7a245883304))
12
+
13
+
14
+
15
+
16
+
17
+ ## [0.9.98](https://github.com/Synerise/synerise-design/compare/@synerise/ds-subject@0.9.97...@synerise/ds-subject@0.9.98) (2024-05-23)
18
+
19
+ **Note:** Version bump only for package @synerise/ds-subject
20
+
21
+
22
+
23
+
24
+
6
25
  ## [0.9.97](https://github.com/Synerise/synerise-design/compare/@synerise/ds-subject@0.9.96...@synerise/ds-subject@0.9.97) (2024-05-16)
7
26
 
8
27
  **Note:** Version bump only for package @synerise/ds-subject
@@ -1,18 +1,18 @@
1
- import * as React from 'react';
1
+ import type { ReactNode, ReactText } from 'react';
2
2
  export declare const ALL_TYPES: readonly ["event", "parameter", "context"];
3
3
  export type SubjectType = typeof ALL_TYPES[number] | string;
4
4
  export type SubjectItem = {
5
- id: React.ReactText;
5
+ id: ReactText;
6
6
  name: string;
7
- icon: React.ReactNode;
7
+ icon: ReactNode;
8
8
  };
9
9
  export type SubjectProps = {
10
10
  onShowPreview?: () => void;
11
11
  onActivate?: (fieldType: string) => void;
12
12
  onDeactivate?: () => void;
13
13
  getPopupContainerOverride?: (trigger: HTMLElement | null) => HTMLElement;
14
- placeholder: string | React.ReactNode;
15
- iconPlaceholder: React.ReactNode;
14
+ placeholder: ReactNode;
15
+ iconPlaceholder: ReactNode;
16
16
  onSelectItem: (item: SubjectItem) => void;
17
17
  selectedItem?: SubjectItem | undefined;
18
18
  type?: SubjectType;
@@ -1,4 +1,3 @@
1
- import Menu from '@synerise/ds-menu';
2
1
  export declare const SearchResult: import("styled-components").StyledComponent<"span", any, {}, never>;
3
2
  export declare const SearchResultHighlight: import("styled-components").StyledComponent<"span", any, {}, never>;
4
- export declare const ItemsList: import("styled-components").StyledComponent<typeof Menu, any, {}, never>;
3
+ export declare const ItemsList: import("styled-components").StyledComponent<"div", any, {}, never>;
@@ -1,5 +1,4 @@
1
1
  import styled from 'styled-components';
2
- import Menu from '@synerise/ds-menu';
3
2
  export var SearchResult = styled.span.withConfig({
4
3
  displayName: "SubjectListstyles__SearchResult",
5
4
  componentId: "sc-1b94el7-0"
@@ -12,7 +11,7 @@ export var SearchResultHighlight = styled.span.withConfig({
12
11
  })(["font-weight:500;color:", ";"], function (props) {
13
12
  return props.theme.palette['grey-700'];
14
13
  });
15
- export var ItemsList = styled(Menu).withConfig({
14
+ export var ItemsList = styled.div.withConfig({
16
15
  displayName: "SubjectListstyles__ItemsList",
17
16
  componentId: "sc-1b94el7-2"
18
17
  })(["width:100%;"]);
@@ -1,12 +1,12 @@
1
1
  import * as React from 'react';
2
2
  import { SubjectItem } from '../Subject.types';
3
- interface Props {
3
+ type Props = {
4
4
  item: SubjectItem;
5
5
  clearSearch: () => void;
6
6
  searchQuery: string;
7
7
  hideDropdown: () => void;
8
8
  select: (item: SubjectItem) => void;
9
9
  className: string;
10
- }
11
- declare const SubjectListItem: React.FC<Props>;
10
+ };
11
+ declare const SubjectListItem: ({ item, clearSearch, searchQuery, hideDropdown, select, className }: Props) => React.JSX.Element;
12
12
  export default SubjectListItem;
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import Icon from '@synerise/ds-icon';
3
- import Menu from '@synerise/ds-menu';
3
+ import ListItem from '@synerise/ds-list-item';
4
4
 
5
5
  var SubjectListItem = function SubjectListItem(_ref) {
6
6
  var item = _ref.item,
@@ -9,7 +9,7 @@ var SubjectListItem = function SubjectListItem(_ref) {
9
9
  hideDropdown = _ref.hideDropdown,
10
10
  select = _ref.select,
11
11
  className = _ref.className;
12
- return /*#__PURE__*/React.createElement(Menu.Item, {
12
+ return /*#__PURE__*/React.createElement(ListItem, {
13
13
  className: className,
14
14
  highlight: searchQuery,
15
15
  onClick: function onClick() {
package/dist/index.d.ts CHANGED
@@ -1 +1,2 @@
1
1
  export { default } from './Subject';
2
+ export type { SubjectProps, SubjectItem, SubjectListProps, SubjectTriggerProps, SubjectType } from './Subject.types';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synerise/ds-subject",
3
- "version": "0.9.97",
3
+ "version": "0.10.0",
4
4
  "description": "Subject UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "Synerise/synerise-design",
@@ -33,13 +33,13 @@
33
33
  ],
34
34
  "types": "dist/index.d.ts",
35
35
  "dependencies": {
36
- "@synerise/ds-button": "^0.20.0",
37
- "@synerise/ds-dropdown": "^0.17.110",
38
- "@synerise/ds-icon": "^0.61.0",
39
- "@synerise/ds-menu": "^0.18.23",
40
- "@synerise/ds-result": "^0.6.55",
41
- "@synerise/ds-scrollbar": "^0.10.5",
42
- "@synerise/ds-utils": "^0.26.6",
36
+ "@synerise/ds-button": "^0.20.1",
37
+ "@synerise/ds-dropdown": "^0.18.0",
38
+ "@synerise/ds-icon": "^0.62.0",
39
+ "@synerise/ds-list-item": "^0.1.0",
40
+ "@synerise/ds-result": "^0.6.56",
41
+ "@synerise/ds-scrollbar": "^0.11.0",
42
+ "@synerise/ds-utils": "^0.27.0",
43
43
  "uuid": "^8.3.2"
44
44
  },
45
45
  "peerDependencies": {
@@ -52,5 +52,5 @@
52
52
  "@testing-library/react": "10.0.1",
53
53
  "@testing-library/user-event": "^10.3.1"
54
54
  },
55
- "gitHead": "fc089bbf34c691a313b3fa648851d7831a23e3d0"
55
+ "gitHead": "6bd94c78745df68ee3b853120a863ab24fc233ef"
56
56
  }