@ynput/ayon-react-components 1.7.11 → 1.7.13

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,6 +1,6 @@
1
1
  import { FC } from 'react';
2
2
  import { DropdownProps } from './Dropdown';
3
- export interface DefaultValueTemplateProps extends Pick<DropdownProps, 'value' | 'isMultiple' | 'dropIcon' | 'onClear' | 'onClearNull' | 'nullPlaceholder' | 'placeholder' | 'clearTooltip' | 'clearNullTooltip' | 'editor'> {
3
+ export interface DefaultValueTemplateProps extends Pick<DropdownProps, 'value' | 'isMultiple' | 'dropIcon' | 'onClear' | 'onClearNull' | 'nullPlaceholder' | 'placeholder' | 'clearTooltip' | 'clearNullTooltip'> {
4
4
  displayIcon?: string;
5
5
  style?: React.CSSProperties;
6
6
  children?: React.ReactNode;
@@ -63,7 +63,6 @@ export interface DropdownProps extends Omit<React.HTMLAttributes<HTMLDivElement>
63
63
  buttonProps?: Styled.ButtonType['defaultProps'];
64
64
  activateKeys?: string[];
65
65
  startContent?: (value: string[], selected: string[], isOpen: boolean) => React.ReactNode;
66
- editor?: boolean;
67
66
  }
68
67
  export interface DropdownRef {
69
68
  getElement: () => HTMLDivElement | null;
@@ -8,13 +8,14 @@ export interface EnumTemplateProps extends Omit<DefaultValueTemplateProps, 'valu
8
8
  }
9
9
  export declare const EnumTemplate: ({ option, isSelected, isChanged, ...props }: EnumTemplateProps) => import("react/jsx-runtime").JSX.Element;
10
10
  export type EnumDropdownOption = {
11
- value: string;
11
+ value: string | number | boolean;
12
12
  label: string;
13
13
  icon?: IconType;
14
14
  color?: string;
15
15
  };
16
- export interface EnumDropdownProps extends Omit<DropdownProps, 'options' | 'valueTemplate' | 'itemTemplate' | 'ref'> {
16
+ export interface EnumDropdownProps extends Omit<DropdownProps, 'value' | 'options' | 'valueTemplate' | 'itemTemplate' | 'ref'> {
17
17
  options: EnumDropdownOption[];
18
18
  colorInverse?: boolean;
19
+ value: (string | number | boolean)[];
19
20
  }
20
21
  export declare const EnumDropdown: import("react").ForwardRefExoticComponent<EnumDropdownProps & import("react").RefAttributes<DropdownRef>>;
@@ -1,16 +1,10 @@
1
1
  import { HTMLAttributes, MouseEvent } from 'react';
2
2
  import { IconType } from '../Icon';
3
3
  import { User } from '../User/UserImagesStacked';
4
- import { DropdownProps } from '../Dropdowns/Dropdown';
4
+ import { EnumDropdownOption, EnumDropdownProps } from '../Dropdowns/EnumDropdown';
5
5
  import { AssigneeSelectProps } from '../Dropdowns/AssigneeSelect';
6
6
  import { Status, StatusSelectProps } from '../Dropdowns/StatusSelect';
7
- type NotificationType = 'comment' | 'due' | 'overdue';
8
- export type PriorityType = {
9
- label?: string;
10
- color?: string;
11
- icon: IconType;
12
- name: string;
13
- };
7
+ import { NotificationProps } from './Notification/Notification';
14
8
  type Section = 'title' | 'header' | 'users' | 'status' | 'priority';
15
9
  export interface EntityCardProps extends React.HTMLAttributes<HTMLDivElement> {
16
10
  header?: string;
@@ -24,12 +18,12 @@ export interface EntityCardProps extends React.HTMLAttributes<HTMLDivElement> {
24
18
  status?: Status;
25
19
  statusMiddle?: boolean;
26
20
  statusNameOnly?: boolean;
27
- priority?: PriorityType;
21
+ priority?: EnumDropdownOption;
28
22
  hidePriority?: boolean;
29
23
  imageUrl?: string;
30
24
  imageAlt?: string;
31
25
  imageIcon?: IconType;
32
- notification?: NotificationType;
26
+ notification?: NotificationProps['notification'];
33
27
  isActive?: boolean;
34
28
  isLoading?: boolean;
35
29
  loadingSections?: Section[];
@@ -42,7 +36,7 @@ export interface EntityCardProps extends React.HTMLAttributes<HTMLDivElement> {
42
36
  isCollapsed?: boolean;
43
37
  assigneeOptions?: User[];
44
38
  statusOptions?: Status[];
45
- priorityOptions?: PriorityType[];
39
+ priorityOptions?: EnumDropdownOption[];
46
40
  editOnHover?: boolean;
47
41
  editAutoClose?: boolean;
48
42
  onAssigneeChange?: (added: string[], removed: string[]) => void;
@@ -55,7 +49,7 @@ export interface EntityCardProps extends React.HTMLAttributes<HTMLDivElement> {
55
49
  image?: HTMLAttributes<HTMLImageElement>;
56
50
  assigneeSelect?: Partial<AssigneeSelectProps>;
57
51
  statusSelect?: Partial<StatusSelectProps>;
58
- prioritySelect?: Partial<DropdownProps>;
52
+ prioritySelect?: Partial<EnumDropdownProps>;
59
53
  title?: HTMLAttributes<HTMLDivElement>;
60
54
  topRow?: HTMLAttributes<HTMLDivElement>;
61
55
  playableTag?: HTMLAttributes<HTMLDivElement>;
@@ -63,6 +57,7 @@ export interface EntityCardProps extends React.HTMLAttributes<HTMLDivElement> {
63
57
  usersTag?: HTMLAttributes<HTMLDivElement>;
64
58
  statusTag?: HTMLAttributes<HTMLDivElement>;
65
59
  priorityTag?: HTMLAttributes<HTMLDivElement>;
60
+ notificationDot?: HTMLAttributes<HTMLDivElement>;
66
61
  };
67
62
  }
68
63
  export declare const EntityCard: import("react").ForwardRefExoticComponent<EntityCardProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,4 +1,5 @@
1
1
  /// <reference types="react" />
2
+ export declare const Wrapper: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
2
3
  type CardProps = {
3
4
  $statusColor?: string;
4
5
  };
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ export type Notification = {
3
+ comment?: boolean;
4
+ due?: boolean;
5
+ overdue?: boolean;
6
+ };
7
+ export interface NotificationProps extends React.HTMLAttributes<HTMLDivElement> {
8
+ notification?: Notification;
9
+ }
10
+ export declare const NotificationDot: import("react").ForwardRefExoticComponent<NotificationProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -0,0 +1,2 @@
1
+ /// <reference types="react" />
2
+ export declare const Notification: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
@@ -1,2 +1,3 @@
1
1
  export * from './EntityCard';
2
2
  export * from './EntityCard.styled';
3
+ export * from './Notification/Notification';