@vlprojects-chat/chat 0.0.51 → 0.0.54

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.
@@ -28,7 +28,8 @@ export default class Chat extends Chat_base {
28
28
  createUserRef(id: string): Ref<User>;
29
29
  updateUser(payload: {
30
30
  userId: number;
31
- name: string;
31
+ displayName?: string;
32
+ avatarUrl?: string;
32
33
  }): void;
33
34
  addUsers(users?: IRUser[]): void;
34
35
  addChannels(channels: IRChannel[]): void;
@@ -12,7 +12,7 @@ declare const Poll_base: import("mobx-keystone")._Model<unknown, {
12
12
  createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
13
13
  stoppedAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
14
14
  status: import("mobx-keystone").ModelProp<IPollStatus, IPollStatus | null | undefined, IPollStatus, IPollStatus | null | undefined, string, false, string>;
15
- votes: import("mobx-keystone").MaybeOptionalModelProp<IServerPollVote[]>;
15
+ votes: import("mobx-keystone").OptionalModelProp<IServerPollVote[]>;
16
16
  }, import("mobx-keystone").SnapshotInOfObject<import("mobx-keystone").ModelPropsToCreationData<{
17
17
  id: import("mobx-keystone").MaybeOptionalModelProp<string>;
18
18
  question: import("mobx-keystone").OptionalModelProp<string>;
@@ -25,7 +25,7 @@ declare const Poll_base: import("mobx-keystone")._Model<unknown, {
25
25
  createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
26
26
  stoppedAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
27
27
  status: import("mobx-keystone").ModelProp<IPollStatus, IPollStatus | null | undefined, IPollStatus, IPollStatus | null | undefined, string, false, string>;
28
- votes: import("mobx-keystone").MaybeOptionalModelProp<IServerPollVote[]>;
28
+ votes: import("mobx-keystone").OptionalModelProp<IServerPollVote[]>;
29
29
  }>>, import("mobx-keystone").SnapshotOutOfObject<import("mobx-keystone").ModelPropsToData<{
30
30
  id: import("mobx-keystone").MaybeOptionalModelProp<string>;
31
31
  question: import("mobx-keystone").OptionalModelProp<string>;
@@ -38,7 +38,7 @@ declare const Poll_base: import("mobx-keystone")._Model<unknown, {
38
38
  createdAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
39
39
  stoppedAt: import("mobx-keystone").MaybeOptionalModelProp<string>;
40
40
  status: import("mobx-keystone").ModelProp<IPollStatus, IPollStatus | null | undefined, IPollStatus, IPollStatus | null | undefined, string, false, string>;
41
- votes: import("mobx-keystone").MaybeOptionalModelProp<IServerPollVote[]>;
41
+ votes: import("mobx-keystone").OptionalModelProp<IServerPollVote[]>;
42
42
  }>>>;
43
43
  export default class Poll extends Poll_base {
44
44
  changeStatus(status: IPollStatus): void;
@@ -42,6 +42,7 @@ export declare const COLOURS: {
42
42
  GREEN: string;
43
43
  ORANGE: string;
44
44
  ERROR: string;
45
+ ACTIVE: string;
45
46
  AVATAR1_BURGUNDY: string;
46
47
  AVATAR2_RED: string;
47
48
  AVATAR3_DARK_PINK: string;
@@ -0,0 +1,19 @@
1
+ import { InputUnstyledProps } from '@mui/base/InputUnstyled';
2
+ import React, { KeyboardEvent } from 'react';
3
+ interface IProps extends Omit<InputUnstyledProps, 'onChange'> {
4
+ placeholder?: string;
5
+ onChange?: (v: string) => void;
6
+ onKeyDown?: (e: KeyboardEvent<HTMLInputElement>) => void;
7
+ className?: string;
8
+ type?: string;
9
+ value?: string;
10
+ id?: string;
11
+ variant?: 'text' | 'outlined';
12
+ size?: 'medium' | 'large';
13
+ fullWidth?: boolean;
14
+ rightIcon?: React.ReactNode;
15
+ inputProps?: Record<string, string | number>;
16
+ errorText?: React.ReactNode | string;
17
+ }
18
+ declare const CustomInput: React.ForwardRefExoticComponent<Pick<IProps, "aria-describedby" | "aria-label" | "aria-labelledby" | "autoComplete" | "autoFocus" | "className" | "components" | "componentsProps" | "endAdornment" | "id" | "multiline" | "name" | "onKeyDown" | "onKeyUp" | "placeholder" | "readOnly" | "rows" | "startAdornment" | "minRows" | "maxRows" | "type" | "value" | "defaultValue" | "disabled" | "error" | "onBlur" | "onClick" | "onChange" | "onFocus" | "required" | "slot" | "style" | "title" | "key" | "defaultChecked" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "children" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture" | "component" | "variant" | "size" | "fullWidth" | "rightIcon" | "inputProps" | "errorText"> & React.RefAttributes<HTMLDivElement>>;
19
+ export default CustomInput;
@@ -0,0 +1,11 @@
1
+ /// <reference types="react" />
2
+ import { Theme } from '@mui/system';
3
+ declare const StyledInputElement: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<Theme> & {
4
+ theme: Theme;
5
+ error: boolean;
6
+ }, import("react").DetailedHTMLProps<import("react").InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, {}>;
7
+ declare const StyledTextareaElement: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<Theme> & {
8
+ theme: Theme;
9
+ maxRows: number;
10
+ }, import("react").DetailedHTMLProps<import("react").TextareaHTMLAttributes<HTMLTextAreaElement>, HTMLTextAreaElement>, {}>;
11
+ export { StyledInputElement, StyledTextareaElement };
@@ -1,15 +1 @@
1
- import React, { KeyboardEvent } from 'react';
2
- interface IProps {
3
- placeholder?: string;
4
- onChange?: (v: string) => void;
5
- onKeyDown?: (e: KeyboardEvent<HTMLInputElement>) => void;
6
- className?: string;
7
- type?: string;
8
- value?: string;
9
- id?: string;
10
- variant?: 'text' | 'outlined';
11
- size?: 'medium' | 'large';
12
- fullWidth?: boolean;
13
- }
14
- declare const Input: React.FC<IProps>;
15
- export default Input;
1
+ export { default } from './Input';
@@ -1,2 +1,2 @@
1
- declare const _default: (props?: any) => import("@mui/styles").ClassNameMap<"input" | "medium" | "text" | "large" | "fullWidth" | "outlined">;
1
+ declare const _default: (props?: any) => import("@mui/styles").ClassNameMap<"medium" | "text" | "large" | "input" | "fullWidth" | "outlined">;
2
2
  export default _default;
@@ -0,0 +1,10 @@
1
+ import { CSSProperties, ReactElement } from 'react';
2
+ interface IProps {
3
+ className?: string;
4
+ width?: number;
5
+ height?: number;
6
+ fill?: string;
7
+ style?: CSSProperties;
8
+ }
9
+ declare const _default: (props: IProps) => ReactElement;
10
+ export default _default;
@@ -0,0 +1,10 @@
1
+ import { CSSProperties, ReactElement } from 'react';
2
+ interface IProps {
3
+ className?: string;
4
+ width?: number;
5
+ height?: number;
6
+ fill?: string;
7
+ style?: CSSProperties;
8
+ }
9
+ declare const _default: (props: IProps) => ReactElement;
10
+ export default _default;
@@ -2,7 +2,8 @@ export declare enum ListenerEventEnum {
2
2
  App = "app"
3
3
  }
4
4
  export declare enum EventBusEventEnum {
5
- MessageSent = "MessageSent"
5
+ MessageSent = "MessageSent",
6
+ ChatLoaded = "ChatLoaded"
6
7
  }
7
8
  export interface IEvents {
8
9
  event: EventBusEventEnum;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vlprojects-chat/chat",
3
3
  "author": "vlprojects",
4
- "version": "0.0.51",
4
+ "version": "0.0.54",
5
5
  "description": "chat",
6
6
  "license": "ISC",
7
7
  "main": "dist/index.js",
@@ -1,2 +0,0 @@
1
- declare const _default: (props?: any) => import("@mui/styles").ClassNameMap<"root" | "inputSearch" | "userCounter" | "userListWrapper">;
2
- export default _default;