@selfcommunity/react-ui 0.7.50-events.92 → 0.7.50-events.93
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/lib/cjs/components/AcceptRequestUserEventButton/AcceptRequestUserEventButton.d.ts +57 -0
- package/lib/cjs/components/AcceptRequestUserEventButton/AcceptRequestUserEventButton.js +75 -0
- package/lib/cjs/components/AcceptRequestUserEventButton/index.d.ts +3 -0
- package/lib/cjs/components/AcceptRequestUserEventButton/index.js +5 -0
- package/lib/cjs/components/Composer/Layer/AudienceLayer/AudienceLayer.d.ts +1 -1
- package/lib/cjs/components/Composer/Layer/CategoryLayer/CategoryLayer.d.ts +1 -1
- package/lib/cjs/components/Composer/Layer/CloseLayer/CloseLayer.d.ts +1 -1
- package/lib/cjs/components/Composer/Layer/LocationLayer/LocationLayer.d.ts +1 -1
- package/lib/cjs/components/ComposerIconButton/ComposerIconButton.d.ts +1 -1
- package/lib/cjs/components/EventMembersWidget/EventMembersWidget.js +36 -5
- package/lib/cjs/components/EventMembersWidget/Skeleton.js +1 -1
- package/lib/cjs/components/EventMembersWidget/TabContentComponent.d.ts +6 -2
- package/lib/cjs/components/EventMembersWidget/TabContentComponent.js +53 -8
- package/lib/cjs/components/Events/Events.d.ts +1 -1
- package/lib/cjs/components/InviteUserEventButton/InviteUserEventButton.d.ts +2 -5
- package/lib/cjs/components/InviteUserEventButton/InviteUserEventButton.js +5 -4
- package/lib/cjs/index.d.ts +4 -3
- package/lib/cjs/index.js +13 -11
- package/lib/cjs/shared/ConfirmDialog/ConfirmDialog.js +7 -7
- package/lib/cjs/shared/Media/File/PreviewComponent.d.ts +1 -1
- package/lib/cjs/shared/Media/Link/LayerComponent.d.ts +1 -1
- package/lib/cjs/shared/Media/Link/PreviewComponent.d.ts +1 -1
- package/lib/esm/components/AcceptRequestUserEventButton/AcceptRequestUserEventButton.d.ts +57 -0
- package/lib/esm/components/AcceptRequestUserEventButton/AcceptRequestUserEventButton.js +72 -0
- package/lib/esm/components/AcceptRequestUserEventButton/index.d.ts +3 -0
- package/lib/esm/components/AcceptRequestUserEventButton/index.js +2 -0
- package/lib/esm/components/Composer/Layer/AudienceLayer/AudienceLayer.d.ts +1 -1
- package/lib/esm/components/Composer/Layer/CategoryLayer/CategoryLayer.d.ts +1 -1
- package/lib/esm/components/Composer/Layer/CloseLayer/CloseLayer.d.ts +1 -1
- package/lib/esm/components/Composer/Layer/LocationLayer/LocationLayer.d.ts +1 -1
- package/lib/esm/components/ComposerIconButton/ComposerIconButton.d.ts +1 -1
- package/lib/esm/components/EventMembersWidget/EventMembersWidget.js +36 -5
- package/lib/esm/components/EventMembersWidget/Skeleton.js +1 -1
- package/lib/esm/components/EventMembersWidget/TabContentComponent.d.ts +6 -2
- package/lib/esm/components/EventMembersWidget/TabContentComponent.js +54 -9
- package/lib/esm/components/Events/Events.d.ts +1 -1
- package/lib/esm/components/InviteUserEventButton/InviteUserEventButton.d.ts +2 -5
- package/lib/esm/components/InviteUserEventButton/InviteUserEventButton.js +5 -4
- package/lib/esm/index.d.ts +4 -3
- package/lib/esm/index.js +7 -6
- package/lib/esm/shared/ConfirmDialog/ConfirmDialog.js +7 -7
- package/lib/esm/shared/Media/File/PreviewComponent.d.ts +1 -1
- package/lib/esm/shared/Media/Link/LayerComponent.d.ts +1 -1
- package/lib/esm/shared/Media/Link/PreviewComponent.d.ts +1 -1
- package/lib/umd/react-ui.js +1 -1
- package/package.json +7 -7
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
import { __rest } from "tslib";
|
|
2
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { LoadingButton } from '@mui/lab';
|
|
4
|
+
import { styled } from '@mui/material/styles';
|
|
5
|
+
import { useThemeProps } from '@mui/system';
|
|
6
|
+
import { EventService } from '@selfcommunity/api-services';
|
|
7
|
+
import { useSCFetchEvent, useSCFetchUser } from '@selfcommunity/react-core';
|
|
8
|
+
import { Logger } from '@selfcommunity/utils';
|
|
9
|
+
import classNames from 'classnames';
|
|
10
|
+
import { useCallback, useState } from 'react';
|
|
11
|
+
import { FormattedMessage } from 'react-intl';
|
|
12
|
+
import { SCOPE_SC_UI } from '../../constants/Errors';
|
|
13
|
+
import ConfirmDialog from '../../shared/ConfirmDialog/ConfirmDialog';
|
|
14
|
+
const PREFIX = 'SCAcceptRequestUserEventButton';
|
|
15
|
+
const classes = {
|
|
16
|
+
root: `${PREFIX}-root`
|
|
17
|
+
};
|
|
18
|
+
const AcceptButton = styled(LoadingButton, {
|
|
19
|
+
name: PREFIX,
|
|
20
|
+
slot: 'Root',
|
|
21
|
+
overridesResolver: (_props, styles) => styles.root
|
|
22
|
+
})(() => ({}));
|
|
23
|
+
/**
|
|
24
|
+
* > API documentation for the Community-JS Accept Request User Event Button component. Learn about the available props and the CSS API.
|
|
25
|
+
|
|
26
|
+
#### Import
|
|
27
|
+
|
|
28
|
+
```jsx
|
|
29
|
+
import {AcceptRequestUserEventButton} from '@selfcommunity/react-ui';
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
#### Component Name
|
|
33
|
+
|
|
34
|
+
The name `SCAcceptRequestUserEventButton` can be used when providing style overrides in the theme.
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
#### CSS
|
|
38
|
+
|
|
39
|
+
|Rule Name|Global class|Description|
|
|
40
|
+
|---|---|---|
|
|
41
|
+
|root|.SCAcceptRequestUserEventButton-root|Styles applied to the root element.|
|
|
42
|
+
|
|
43
|
+
* @param inProps
|
|
44
|
+
*/
|
|
45
|
+
export default function AcceptRequestUserEventButton(inProps) {
|
|
46
|
+
// PROPS
|
|
47
|
+
const props = useThemeProps({
|
|
48
|
+
props: inProps,
|
|
49
|
+
name: PREFIX
|
|
50
|
+
});
|
|
51
|
+
const { className, eventId, event, userId, user, handleConfirm = null } = props, rest = __rest(props, ["className", "eventId", "event", "userId", "user", "handleConfirm"]);
|
|
52
|
+
// STATE
|
|
53
|
+
const [loading, setLoading] = useState(false);
|
|
54
|
+
const [openDialog, setOpenDialog] = useState(false);
|
|
55
|
+
// HOOKS
|
|
56
|
+
const { scEvent } = useSCFetchEvent({ id: eventId, event });
|
|
57
|
+
const { scUser } = useSCFetchUser({ id: userId, user });
|
|
58
|
+
const handleConfirmAction = useCallback(() => {
|
|
59
|
+
setLoading(true);
|
|
60
|
+
EventService.inviteOrAcceptEventRequest(scEvent.id, { users: [scUser.id] })
|
|
61
|
+
.then(() => {
|
|
62
|
+
handleConfirm === null || handleConfirm === void 0 ? void 0 : handleConfirm(scUser.id);
|
|
63
|
+
setLoading(false);
|
|
64
|
+
setOpenDialog(false);
|
|
65
|
+
})
|
|
66
|
+
.catch((error) => {
|
|
67
|
+
handleConfirm === null || handleConfirm === void 0 ? void 0 : handleConfirm(null);
|
|
68
|
+
Logger.error(SCOPE_SC_UI, error);
|
|
69
|
+
});
|
|
70
|
+
}, [scEvent, scUser]);
|
|
71
|
+
return (_jsxs(_Fragment, { children: [_jsx(AcceptButton, Object.assign({ size: "small", variant: "outlined", onClick: () => setOpenDialog(true), loading: loading, className: classNames(classes.root, className) }, rest, { children: _jsx(FormattedMessage, { defaultMessage: "ui.acceptRequestUserEventButton.accept", id: "ui.acceptRequestUserEventButton.accept" }) })), openDialog && (_jsx(ConfirmDialog, { open: openDialog, title: _jsx(FormattedMessage, { id: "ui.acceptRequestUserEventButton.dialog.title", defaultMessage: "ui.acceptRequestUserEventButton.dialog.title" }), content: _jsx(FormattedMessage, { id: "ui.acceptRequestUserEventButton.dialog.msg", defaultMessage: "ui.acceptRequestUserEventButton.dialog.msg" }), btnConfirm: _jsx(FormattedMessage, { id: "ui.acceptRequestUserEventButton.dialog.confirm", defaultMessage: "ui.acceptRequestUserEventButton.dialog.confirm" }), isUpdating: loading, onConfirm: handleConfirmAction, onClose: () => setOpenDialog(false) }))] }));
|
|
72
|
+
}
|
|
@@ -14,5 +14,5 @@ export interface AudienceLayerProps extends Omit<BoxProps, 'defaultValue'>, Comp
|
|
|
14
14
|
defaultValue: SCTagType[] | SCGroupType | any;
|
|
15
15
|
TextFieldProps?: TextFieldProps;
|
|
16
16
|
}
|
|
17
|
-
declare const AudienceLayer: React.ForwardRefExoticComponent<Pick<AudienceLayerProps, "id" | "role" | "
|
|
17
|
+
declare const AudienceLayer: React.ForwardRefExoticComponent<Pick<AudienceLayerProps, "id" | "role" | "className" | "style" | "classes" | "p" | "slot" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "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-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "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" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "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" | "onClick" | "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" | "sx" | "component" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxShadow" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "zIndex" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "onClose" | "TextFieldProps" | "onSave"> & React.RefAttributes<unknown>>;
|
|
18
18
|
export default AudienceLayer;
|
|
@@ -5,5 +5,5 @@ import { ComposerLayerProps } from '../../../../types/composer';
|
|
|
5
5
|
export interface CategoryLayerProps extends Omit<BoxProps, 'defaultValue'>, ComposerLayerProps {
|
|
6
6
|
defaultValue: SCCategoryType[];
|
|
7
7
|
}
|
|
8
|
-
declare const CategoryLayer: React.ForwardRefExoticComponent<Pick<CategoryLayerProps, "id" | "role" | "
|
|
8
|
+
declare const CategoryLayer: React.ForwardRefExoticComponent<Pick<CategoryLayerProps, "id" | "role" | "className" | "style" | "classes" | "p" | "slot" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "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-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "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" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "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" | "onClick" | "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" | "sx" | "component" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxShadow" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "zIndex" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "onClose" | "onSave"> & React.RefAttributes<unknown>>;
|
|
9
9
|
export default CategoryLayer;
|
|
@@ -3,5 +3,5 @@ import { BoxProps } from '@mui/material';
|
|
|
3
3
|
import { ComposerLayerProps } from '../../../../types/composer';
|
|
4
4
|
export interface CloseLayerProps extends Omit<BoxProps, 'defaultValue'>, ComposerLayerProps {
|
|
5
5
|
}
|
|
6
|
-
declare const CloseLayer: React.ForwardRefExoticComponent<Pick<CloseLayerProps, "id" | "role" | "
|
|
6
|
+
declare const CloseLayer: React.ForwardRefExoticComponent<Pick<CloseLayerProps, "id" | "role" | "className" | "style" | "classes" | "p" | "slot" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "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-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "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" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "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" | "onClick" | "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" | "sx" | "component" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxShadow" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "zIndex" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "onClose" | "onSave"> & React.RefAttributes<unknown>>;
|
|
7
7
|
export default CloseLayer;
|
|
@@ -5,5 +5,5 @@ import { ComposerLayerProps } from '../../../../types/composer';
|
|
|
5
5
|
export interface LocationLayerProps extends Omit<BoxProps, 'defaultValue'>, Omit<ComposerLayerProps, 'defaultValue'> {
|
|
6
6
|
defaultValue: SCContributionLocation;
|
|
7
7
|
}
|
|
8
|
-
declare const LocationLayer: React.ForwardRefExoticComponent<Pick<LocationLayerProps, "id" | "role" | "
|
|
8
|
+
declare const LocationLayer: React.ForwardRefExoticComponent<Pick<LocationLayerProps, "id" | "role" | "className" | "style" | "classes" | "p" | "slot" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "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-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "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" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "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" | "onClick" | "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" | "sx" | "component" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxShadow" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "height" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "width" | "zIndex" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "onClose" | "onSave"> & React.RefAttributes<unknown>>;
|
|
9
9
|
export default LocationLayer;
|
|
@@ -30,5 +30,5 @@ export interface ComposerIconButtonProps extends IconButtonProps {
|
|
|
30
30
|
|
|
31
31
|
* @param inProps
|
|
32
32
|
*/
|
|
33
|
-
declare const _default: React.ForwardRefExoticComponent<Pick<ComposerIconButtonProps, "id" | "role" | "
|
|
33
|
+
declare const _default: React.ForwardRefExoticComponent<Pick<ComposerIconButtonProps, "id" | "role" | "className" | "style" | "classes" | "form" | "slot" | "title" | "key" | "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "placeholder" | "spellCheck" | "tabIndex" | "translate" | "radioGroup" | "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-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "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" | "onFocus" | "onFocusCapture" | "onBlur" | "onBlurCapture" | "onChange" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "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" | "onClick" | "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" | "sx" | "component" | "name" | "type" | "autoFocus" | "disabled" | "formAction" | "formEncType" | "formMethod" | "formNoValidate" | "formTarget" | "value" | "action" | "size" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "disableFocusRipple" | "edge" | "ComposerProps"> & React.RefAttributes<HTMLButtonElement>>;
|
|
34
34
|
export default _default;
|
|
@@ -52,7 +52,16 @@ export default function EventMembersWidget(inProps) {
|
|
|
52
52
|
cacheStrategy,
|
|
53
53
|
visibleItems: limit
|
|
54
54
|
}, stateWidgetInitializer);
|
|
55
|
-
const [
|
|
55
|
+
const [requests, dispatchRequests] = useReducer(dataWidgetReducer, {
|
|
56
|
+
isLoadingNext: false,
|
|
57
|
+
next: null,
|
|
58
|
+
cacheKey: SCCache.getWidgetStateCacheKey(SCCache.USER_REQUESTS_EVENTS_STATE_CACHE_PREFIX_KEY, eventId || event.id),
|
|
59
|
+
cacheStrategy,
|
|
60
|
+
visibleItems: limit
|
|
61
|
+
}, stateWidgetInitializer);
|
|
62
|
+
const [invitedCount, setInvitedCount] = useState(0);
|
|
63
|
+
const [requestsCount, setRequestsCount] = useState(0);
|
|
64
|
+
const [requestsUsers, setRequestsUsers] = useState([]);
|
|
56
65
|
const [tabValue, setTabValue] = useState('1');
|
|
57
66
|
const [refresh, setRefresh] = useState(false);
|
|
58
67
|
// CONTEXT
|
|
@@ -82,7 +91,7 @@ export default function EventMembersWidget(inProps) {
|
|
|
82
91
|
EventService.getEventInvitedUsers(scEvent.id, Object.assign({}, endpointQueryParams))
|
|
83
92
|
.then((payload) => {
|
|
84
93
|
dispatchInvited({ type: actionWidgetTypes.LOAD_NEXT_SUCCESS, payload: Object.assign(Object.assign({}, payload), { initialized: true }) });
|
|
85
|
-
|
|
94
|
+
setInvitedCount(payload.count);
|
|
86
95
|
})
|
|
87
96
|
.catch((error) => {
|
|
88
97
|
dispatchInvited({ type: actionWidgetTypes.LOAD_NEXT_FAILURE, payload: { errorLoadNext: error } });
|
|
@@ -90,6 +99,21 @@ export default function EventMembersWidget(inProps) {
|
|
|
90
99
|
});
|
|
91
100
|
}
|
|
92
101
|
}, [invited.isLoadingNext, invited.initialized, dispatchInvited, scUserContext.user, scEvent]);
|
|
102
|
+
const _initRequests = useCallback(() => {
|
|
103
|
+
if (!requests.initialized && !requests.isLoadingNext && hasAllow) {
|
|
104
|
+
dispatchRequests({ type: actionWidgetTypes.LOADING_NEXT });
|
|
105
|
+
EventService.getEventWaitingApprovalSubscribers(scEvent.id, Object.assign({}, endpointQueryParams))
|
|
106
|
+
.then((payload) => {
|
|
107
|
+
dispatchRequests({ type: actionWidgetTypes.LOAD_NEXT_SUCCESS, payload: Object.assign(Object.assign({}, payload), { initialized: true }) });
|
|
108
|
+
setRequestsCount(payload.count);
|
|
109
|
+
setRequestsUsers(payload.results);
|
|
110
|
+
})
|
|
111
|
+
.catch((error) => {
|
|
112
|
+
dispatchRequests({ type: actionWidgetTypes.LOAD_NEXT_FAILURE, payload: { errorLoadNext: error } });
|
|
113
|
+
Logger.error(SCOPE_SC_UI, error);
|
|
114
|
+
});
|
|
115
|
+
}
|
|
116
|
+
}, [requests.isLoadingNext, requests.initialized, dispatchRequests, scUserContext.user, scEvent]);
|
|
93
117
|
// EFFECTS
|
|
94
118
|
useEffect(() => {
|
|
95
119
|
let _t;
|
|
@@ -102,6 +126,7 @@ export default function EventMembersWidget(inProps) {
|
|
|
102
126
|
else {
|
|
103
127
|
_initParticipants();
|
|
104
128
|
_initInvited();
|
|
129
|
+
_initRequests();
|
|
105
130
|
}
|
|
106
131
|
});
|
|
107
132
|
return () => {
|
|
@@ -120,8 +145,14 @@ export default function EventMembersWidget(inProps) {
|
|
|
120
145
|
if (!scEvent) {
|
|
121
146
|
return _jsx(HiddenPlaceholder, {});
|
|
122
147
|
}
|
|
123
|
-
return (_jsx(Root, Object.assign({ className: classes.root }, rest, { children: _jsxs(CardContent, Object.assign({ className: classes.content }, { children: [_jsx(Typography, Object.assign({ variant: "h5", className: classes.title }, { children: _jsx(FormattedMessage, { id: title, defaultMessage: title }) })), _jsxs(TabContext, Object.assign({ value: tabValue }, { children: [_jsxs(TabList, Object.assign({ className: classes.tabsWrapper, onChange: handleTabChange, textColor: "primary", indicatorColor: "primary", variant: "fullWidth" }, { children: [_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Typography, Object.assign({ variant: "h3" }, { children: participants.count })), _jsx(Typography, Object.assign({ variant: "subtitle2" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.participants", defaultMessage: "ui.eventMembersWidget.participants" }) }))] })), value: "1" }), hasAllow && (_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Typography, Object.assign({ variant: "h3" }, { children:
|
|
148
|
+
return (_jsx(Root, Object.assign({ className: classes.root }, rest, { children: _jsxs(CardContent, Object.assign({ className: classes.content }, { children: [_jsx(Typography, Object.assign({ variant: "h5", className: classes.title }, { children: _jsx(FormattedMessage, { id: title, defaultMessage: title }) })), _jsxs(TabContext, Object.assign({ value: tabValue }, { children: [_jsxs(TabList, Object.assign({ className: classes.tabsWrapper, onChange: handleTabChange, textColor: "primary", indicatorColor: "primary", variant: "fullWidth" }, { children: [_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Typography, Object.assign({ variant: "h3" }, { children: participants.count })), _jsx(Typography, Object.assign({ variant: "subtitle2" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.participants", defaultMessage: "ui.eventMembersWidget.participants" }) }))] })), value: "1" }), hasAllow && (_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Typography, Object.assign({ variant: "h3" }, { children: invitedCount })), _jsx(Typography, Object.assign({ variant: "subtitle2" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.invited", defaultMessage: "ui.eventMembersWidget.invited" }) }))] })), value: "2" })), hasAllow && (_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Typography, Object.assign({ variant: "h3" }, { children: requestsCount })), _jsx(Typography, Object.assign({ variant: "subtitle2" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.requests", defaultMessage: "ui.eventMembersWidget.requests" }) }))] })), value: "3" }))] })), _jsx(TabPanel, Object.assign({ value: "1", className: classes.tabPanel }, { children: _jsx(TabContentComponent, { tabValue: "1", state: participants, dispatch: dispatchParticipants, userProps: userProps, dialogProps: dialogProps }) })), hasAllow && (_jsx(TabPanel, Object.assign({ value: "2", className: classes.tabPanel }, { children: _jsx(TabContentComponent, { tabValue: "2", state: invited, dispatch: dispatchInvited, userProps: userProps, dialogProps: dialogProps, actionProps: {
|
|
149
|
+
scEvent,
|
|
150
|
+
setCount: setInvitedCount
|
|
151
|
+
}, setRefresh: setRefresh }) }))), hasAllow && (_jsx(TabPanel, Object.assign({ value: "3", className: classes.tabPanel }, { children: _jsx(TabContentComponent, { tabValue: "3", state: requests, dispatch: dispatchRequests, userProps: userProps, dialogProps: dialogProps, actionProps: {
|
|
124
152
|
scEvent,
|
|
125
|
-
|
|
126
|
-
|
|
153
|
+
count: requestsCount,
|
|
154
|
+
setCount: setRequestsCount,
|
|
155
|
+
users: requestsUsers,
|
|
156
|
+
setUsers: setRequestsUsers
|
|
157
|
+
} }) })))] }))] })) })));
|
|
127
158
|
}
|
|
@@ -21,5 +21,5 @@ const Root = styled(Widget, {
|
|
|
21
21
|
overridesResolver: (_props, styles) => styles.skeletonRoot
|
|
22
22
|
})(() => ({}));
|
|
23
23
|
export default function EventMembersWidgetSkeleton() {
|
|
24
|
-
return (_jsx(Root, Object.assign({ className: classes.root }, { children: _jsxs(CardContent, Object.assign({ className: classes.content }, { children: [_jsx(Skeleton, { animation: "wave", width: "53px", height: "25px", className: classes.title }), _jsxs(TabContext, Object.assign({ value: "1" }, { children: [_jsx(Box, Object.assign({ className: classes.tabsWrapper }, { children:
|
|
24
|
+
return (_jsx(Root, Object.assign({ className: classes.root }, { children: _jsxs(CardContent, Object.assign({ className: classes.content }, { children: [_jsx(Skeleton, { animation: "wave", width: "53px", height: "25px", className: classes.title }), _jsxs(TabContext, Object.assign({ value: "1" }, { children: [_jsx(Box, Object.assign({ className: classes.tabsWrapper }, { children: _jsx(TabList, Object.assign({ variant: "fullWidth" }, { children: [1, 2, 3].map((_element, i) => (_jsx(Tab, { label: _jsxs(Stack, Object.assign({ className: classes.tabLabelWrapper }, { children: [_jsx(Skeleton, { animation: "wave", width: "26px", height: "24px" }), _jsx(Skeleton, { animation: "wave", width: "106px", height: "19px" })] })), value: `${i + 1}` }, i))) })) })), _jsx(TabPanel, Object.assign({ value: "1", className: classes.tabPanel }, { children: _jsxs(List, { children: [[1, 2, 3, 4].map((_element, i) => (_jsx(ListItem, { children: _jsx(UserSkeleton, {}) }, i))), _jsx(Skeleton, { className: classes.actionButton, animation: "wave", width: "52px", height: "20px" })] }) })), _jsx(TabPanel, { value: "2", className: classes.tabPanel }), _jsx(TabPanel, { value: "3", className: classes.tabPanel })] }))] })) })));
|
|
25
25
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { SCEventType } from '@selfcommunity/types';
|
|
1
|
+
import { SCEventType, SCUserType } from '@selfcommunity/types';
|
|
2
2
|
import { Dispatch, SetStateAction } from 'react';
|
|
3
3
|
import { BaseDialogProps } from '../../shared/BaseDialog';
|
|
4
4
|
import { UserProps } from '../User';
|
|
5
5
|
interface TabComponentProps {
|
|
6
|
+
tabValue: '1' | '2' | '3';
|
|
6
7
|
state: any;
|
|
7
8
|
dispatch: Dispatch<any>;
|
|
8
9
|
/**
|
|
@@ -17,7 +18,10 @@ interface TabComponentProps {
|
|
|
17
18
|
dialogProps?: BaseDialogProps;
|
|
18
19
|
actionProps?: {
|
|
19
20
|
scEvent?: SCEventType;
|
|
20
|
-
|
|
21
|
+
count?: number;
|
|
22
|
+
setCount?: Dispatch<SetStateAction<number>>;
|
|
23
|
+
users?: SCUserType[];
|
|
24
|
+
setUsers?: Dispatch<SetStateAction<SCUserType[]>>;
|
|
21
25
|
};
|
|
22
26
|
setRefresh?: Dispatch<SetStateAction<boolean>>;
|
|
23
27
|
}
|
|
@@ -2,12 +2,14 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
|
|
|
2
2
|
import { Button, List, ListItem, styled, Typography } from '@mui/material';
|
|
3
3
|
import { Endpoints, http } from '@selfcommunity/api-services';
|
|
4
4
|
import { Logger } from '@selfcommunity/utils';
|
|
5
|
-
import {
|
|
5
|
+
import { useSnackbar } from 'notistack';
|
|
6
|
+
import { useCallback, useMemo, useState } from 'react';
|
|
6
7
|
import { FormattedMessage } from 'react-intl';
|
|
7
8
|
import { SCOPE_SC_UI } from '../../constants/Errors';
|
|
8
9
|
import BaseDialog from '../../shared/BaseDialog';
|
|
9
10
|
import InfiniteScroll from '../../shared/InfiniteScroll';
|
|
10
11
|
import { actionWidgetTypes } from '../../utils/widget';
|
|
12
|
+
import AcceptRequestUserEventButton from '../AcceptRequestUserEventButton';
|
|
11
13
|
import EventInviteButton from '../EventInviteButton';
|
|
12
14
|
import InviteUserEventButton from '../InviteUserEventButton';
|
|
13
15
|
import User, { UserSkeleton } from '../User';
|
|
@@ -26,9 +28,13 @@ const DialogRoot = styled(BaseDialog, {
|
|
|
26
28
|
})(() => ({}));
|
|
27
29
|
export default function TabContentComponent(props) {
|
|
28
30
|
// PROPS
|
|
29
|
-
const { state, dispatch, userProps, dialogProps, actionProps, setRefresh } = props;
|
|
31
|
+
const { state, dispatch, userProps, dialogProps, actionProps, setRefresh, tabValue } = props;
|
|
30
32
|
// STATE
|
|
31
33
|
const [openDialog, setOpenDialog] = useState(false);
|
|
34
|
+
// HOOKS
|
|
35
|
+
const { enqueueSnackbar } = useSnackbar();
|
|
36
|
+
// CONSTS
|
|
37
|
+
const users = useMemo(() => (tabValue === '3' ? actionProps === null || actionProps === void 0 ? void 0 : actionProps.users : state.results), [tabValue, actionProps, state]);
|
|
32
38
|
// HANDLERS
|
|
33
39
|
/**
|
|
34
40
|
* Handles pagination
|
|
@@ -50,12 +56,51 @@ export default function TabContentComponent(props) {
|
|
|
50
56
|
const handleToggleDialogOpen = useCallback(() => {
|
|
51
57
|
setOpenDialog((prev) => !prev);
|
|
52
58
|
}, []);
|
|
53
|
-
const getActionsComponent = useCallback((userId) =>
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
59
|
+
const getActionsComponent = useCallback((userId) => {
|
|
60
|
+
if (tabValue === '2' && actionProps) {
|
|
61
|
+
const handleInvitations = (invited) => {
|
|
62
|
+
var _a, _b;
|
|
63
|
+
if (invited) {
|
|
64
|
+
(_a = actionProps.setCount) === null || _a === void 0 ? void 0 : _a.call(actionProps, (prev) => prev - 1);
|
|
65
|
+
}
|
|
66
|
+
else {
|
|
67
|
+
(_b = actionProps.setCount) === null || _b === void 0 ? void 0 : _b.call(actionProps, (prev) => prev + 1);
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
return _jsx(InviteUserEventButton, { event: actionProps.scEvent, userId: userId, handleInvitations: handleInvitations });
|
|
58
71
|
}
|
|
59
|
-
|
|
60
|
-
|
|
72
|
+
else if (tabValue === '3' && actionProps) {
|
|
73
|
+
const handleConfirm = (id) => {
|
|
74
|
+
if (id) {
|
|
75
|
+
actionProps.setCount((prev) => prev - 1);
|
|
76
|
+
actionProps.setUsers((prev) => prev.filter((user) => user.id !== id));
|
|
77
|
+
enqueueSnackbar(_jsx(FormattedMessage, { id: "ui.acceptRequestUserEventButton.snackbar.success", defaultMessage: "ui.acceptRequestUserEventButton.snackbar.success" }), {
|
|
78
|
+
variant: 'success',
|
|
79
|
+
autoHideDuration: 3000
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
else {
|
|
83
|
+
enqueueSnackbar(_jsx(FormattedMessage, { id: "ui.common.error.action", defaultMessage: "ui.common.error.action" }), {
|
|
84
|
+
variant: 'error',
|
|
85
|
+
autoHideDuration: 3000
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
return _jsx(AcceptRequestUserEventButton, { event: actionProps.scEvent, userId: userId, handleConfirm: handleConfirm });
|
|
90
|
+
}
|
|
91
|
+
return undefined;
|
|
92
|
+
}, [tabValue, actionProps, dispatch, setRefresh]);
|
|
93
|
+
if (tabValue === '2' && state.count === 0 && actionProps) {
|
|
94
|
+
const handleInvitations = (invited) => {
|
|
95
|
+
if (invited) {
|
|
96
|
+
dispatch({ type: actionWidgetTypes.RESET });
|
|
97
|
+
setRefresh(true);
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
return _jsx(EventInviteButton, { event: actionProps.scEvent, className: classes.eventButton, handleInvitations: handleInvitations });
|
|
101
|
+
}
|
|
102
|
+
if (tabValue === '3' && (actionProps === null || actionProps === void 0 ? void 0 : actionProps.count) === 0) {
|
|
103
|
+
return (_jsx(Typography, Object.assign({ variant: "body1" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.noOtherRequests", defaultMessage: "ui.eventMembersWidget.noOtherRequests" }) })));
|
|
104
|
+
}
|
|
105
|
+
return (_jsxs(_Fragment, { children: [_jsx(List, { children: users === null || users === void 0 ? void 0 : users.map((user) => (_jsx(ListItem, { children: _jsx(User, Object.assign({ elevation: 0, user: user }, userProps, { actions: getActionsComponent(user.id) })) }, user.id))) }), state.count > state.visibleItems && (_jsx(Button, Object.assign({ onClick: handleToggleDialogOpen, className: classes.actionButton }, { children: _jsx(Typography, Object.assign({ variant: "caption" }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.showAll", defaultMessage: "ui.eventMembersWidget.showAll" }) })) }))), openDialog && (_jsx(DialogRoot, Object.assign({ className: classes.dialogRoot, title: _jsx(FormattedMessage, { defaultMessage: "ui.eventMembersWidget.title", id: "ui.eventMembersWidget.title" }), onClose: handleToggleDialogOpen, open: openDialog }, dialogProps, { children: _jsx(InfiniteScroll, Object.assign({ dataLength: state.results.length, next: handleNext, hasMoreNext: Boolean(state.next), loaderNext: _jsx(UserSkeleton, Object.assign({ elevation: 0 }, userProps)), className: classes.infiniteScroll, endMessage: _jsx(Typography, Object.assign({ className: classes.endMessage }, { children: _jsx(FormattedMessage, { id: "ui.eventMembersWidget.noMoreResults", defaultMessage: "ui.eventMembersWidget.noMoreResults" }) })) }, { children: _jsx(List, { children: state.results.map((user) => (_jsx(ListItem, { children: _jsx(User, Object.assign({ elevation: 0, user: user }, userProps)) }, user.id))) }) })) })))] }));
|
|
61
106
|
}
|
|
@@ -5,7 +5,7 @@ import { EventProps, EventSkeletonProps } from '../Event';
|
|
|
5
5
|
import { EventsSkeletonProps } from '../Events/Skeleton';
|
|
6
6
|
export declare const EventsChipRoot: import("@emotion/styled").StyledComponent<import("@mui/material").ChipOwnProps & import("@mui/material/OverridableComponent").CommonProps & Omit<Pick<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "key" | keyof React.HTMLAttributes<HTMLDivElement>> & {
|
|
7
7
|
ref?: React.Ref<HTMLDivElement>;
|
|
8
|
-
}, "avatar" | "
|
|
8
|
+
}, "avatar" | "className" | "style" | "classes" | "label" | "tabIndex" | "color" | "children" | "sx" | "variant" | "disabled" | "size" | "icon" | "clickable" | "deleteIcon" | "onDelete" | "skipFocusWhenDisabled"> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme>, {}, {}>;
|
|
9
9
|
export interface EventsProps {
|
|
10
10
|
/**
|
|
11
11
|
* Overrides or extends the styles applied to the component.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { SCEventType, SCUserType } from '@selfcommunity/types';
|
|
2
|
-
import {
|
|
2
|
+
import { HTMLAttributes } from 'react';
|
|
3
3
|
export interface InviteUserEventButtonProps {
|
|
4
4
|
/**
|
|
5
5
|
* Overrides or extends the styles applied to the component.
|
|
@@ -26,10 +26,7 @@ export interface InviteUserEventButtonProps {
|
|
|
26
26
|
* @default null
|
|
27
27
|
*/
|
|
28
28
|
user?: SCUserType;
|
|
29
|
-
|
|
30
|
-
* setInvitedNumber set state action
|
|
31
|
-
*/
|
|
32
|
-
setInvitedNumber?: Dispatch<SetStateAction<number>>;
|
|
29
|
+
handleInvitations?: ((invited: boolean) => void) | null;
|
|
33
30
|
/**
|
|
34
31
|
* Others properties
|
|
35
32
|
*/
|