@elicecontents/content-ui 1.0.19 → 1.0.20-rc.1
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/cjs/components/chat/Chat.d.ts +4 -2
- package/cjs/components/chat/Chat.js +8 -3
- package/cjs/components/index.js +15 -2
- package/cjs/components/layout/Layout.d.ts +51 -33
- package/cjs/components/layout/Layout.js +298 -229
- package/cjs/components/layout/index.d.ts +33 -1
- package/cjs/components/layout/index.js +24 -2
- package/cjs/components/video/VideoPlayer.js +396 -104
- package/cjs/index.js +17 -4
- package/cjs/theme/createAIDTTheme.js +15 -1
- package/es/components/chat/Chat.d.ts +4 -2
- package/es/components/chat/Chat.js +8 -3
- package/es/components/index.js +2 -1
- package/es/components/layout/Layout.d.ts +51 -33
- package/es/components/layout/Layout.js +286 -227
- package/es/components/layout/index.d.ts +33 -1
- package/es/components/layout/index.js +16 -1
- package/es/components/video/VideoPlayer.js +388 -98
- package/es/index.js +2 -1
- package/es/theme/createAIDTTheme.js +15 -1
- package/package.json +1 -1
|
@@ -24,6 +24,7 @@ export interface EliceChatProps {
|
|
|
24
24
|
type?: string;
|
|
25
25
|
recorderType?: RecorderType;
|
|
26
26
|
isOnlyRecord: boolean;
|
|
27
|
+
isRecordDisabled?: boolean;
|
|
27
28
|
isResetDisabled?: boolean;
|
|
28
29
|
}
|
|
29
30
|
declare const EliceChat: {
|
|
@@ -39,7 +40,7 @@ declare const EliceChat: {
|
|
|
39
40
|
CustomAssistantAvatar: React.ReactNode;
|
|
40
41
|
CustomUserAvatar: React.ReactNode;
|
|
41
42
|
}): import("react/jsx-runtime").JSX.Element;
|
|
42
|
-
InputArea({ placeHolder, value, isDisabled, onChange, onSend, onReset, onRecord, onTranscribingChange, isOnlyRecord, isResetDisabled, }: {
|
|
43
|
+
InputArea({ placeHolder, value, isDisabled, onChange, onSend, onReset, onRecord, onTranscribingChange, isOnlyRecord, isResetDisabled, isRecordDisabled, }: {
|
|
43
44
|
placeHolder: string;
|
|
44
45
|
value: string;
|
|
45
46
|
isDisabled: boolean;
|
|
@@ -53,7 +54,8 @@ declare const EliceChat: {
|
|
|
53
54
|
type: RecorderType;
|
|
54
55
|
isOnlyRecord: boolean;
|
|
55
56
|
isResetDisabled: boolean;
|
|
57
|
+
isRecordDisabled: boolean;
|
|
56
58
|
}): import("react/jsx-runtime").JSX.Element;
|
|
57
59
|
};
|
|
58
|
-
declare const EliceChatContainer: ({ placeholder, messages, content, onReset, onSend, onChange, onRecord, onTranscribingChange, setAudioFile, onTransform, isLoadingMessage, CustomAssistantAvatar, CustomUserAvatar, isDisabled, backgroundImage, height, recorderType, isOnlyRecord, isResetDisabled, }: EliceChatProps) => import("react/jsx-runtime").JSX.Element;
|
|
60
|
+
declare const EliceChatContainer: ({ placeholder, messages, content, onReset, onSend, onChange, onRecord, onTranscribingChange, setAudioFile, onTransform, isLoadingMessage, CustomAssistantAvatar, CustomUserAvatar, isDisabled, backgroundImage, height, recorderType, isOnlyRecord, isResetDisabled, isRecordDisabled, }: EliceChatProps) => import("react/jsx-runtime").JSX.Element;
|
|
59
61
|
export default EliceChat;
|
|
@@ -58,7 +58,9 @@ var EliceChatContainer = function EliceChatContainer(_ref) {
|
|
|
58
58
|
_ref$isOnlyRecord = _ref.isOnlyRecord,
|
|
59
59
|
isOnlyRecord = _ref$isOnlyRecord === void 0 ? false : _ref$isOnlyRecord,
|
|
60
60
|
_ref$isResetDisabled = _ref.isResetDisabled,
|
|
61
|
-
isResetDisabled = _ref$isResetDisabled === void 0 ? false : _ref$isResetDisabled
|
|
61
|
+
isResetDisabled = _ref$isResetDisabled === void 0 ? false : _ref$isResetDisabled,
|
|
62
|
+
_ref$isRecordDisabled = _ref.isRecordDisabled,
|
|
63
|
+
isRecordDisabled = _ref$isRecordDisabled === void 0 ? false : _ref$isRecordDisabled;
|
|
62
64
|
var theme = material.useTheme();
|
|
63
65
|
var _useState = React.useState(content),
|
|
64
66
|
_useState2 = _rollupPluginBabelHelpers.slicedToArray(_useState, 2),
|
|
@@ -130,7 +132,8 @@ var EliceChatContainer = function EliceChatContainer(_ref) {
|
|
|
130
132
|
onTranscribingChange: onTranscribingChange,
|
|
131
133
|
isDisabled: isDisabled,
|
|
132
134
|
type: recorderType,
|
|
133
|
-
isResetDisabled: isResetDisabled
|
|
135
|
+
isResetDisabled: isResetDisabled,
|
|
136
|
+
isRecordDisabled: isRecordDisabled
|
|
134
137
|
})]
|
|
135
138
|
});
|
|
136
139
|
};
|
|
@@ -189,7 +192,8 @@ EliceChat.InputArea = function (_ref3) {
|
|
|
189
192
|
onRecord = _ref3.onRecord,
|
|
190
193
|
onTranscribingChange = _ref3.onTranscribingChange,
|
|
191
194
|
isOnlyRecord = _ref3.isOnlyRecord,
|
|
192
|
-
isResetDisabled = _ref3.isResetDisabled
|
|
195
|
+
isResetDisabled = _ref3.isResetDisabled,
|
|
196
|
+
isRecordDisabled = _ref3.isRecordDisabled;
|
|
193
197
|
var theme = material.useTheme();
|
|
194
198
|
var _useRecorder2 = RecorderContext.useRecorder(),
|
|
195
199
|
recorderState = _useRecorder2.state,
|
|
@@ -254,6 +258,7 @@ EliceChat.InputArea = function (_ref3) {
|
|
|
254
258
|
setIsRecording(true);
|
|
255
259
|
onTranscribingChange === null || onTranscribingChange === void 0 ? void 0 : onTranscribingChange(true);
|
|
256
260
|
},
|
|
261
|
+
disabled: isRecordDisabled,
|
|
257
262
|
children: jsxRuntime.jsx(Micro.default, {
|
|
258
263
|
color: theme.palette.secondary.main
|
|
259
264
|
})
|
package/cjs/components/index.js
CHANGED
|
@@ -6,7 +6,7 @@ var Button = require('./button/Button.js');
|
|
|
6
6
|
var Chat = require('./chat/Chat.js');
|
|
7
7
|
var Dialog = require('./dialog/Dialog.js');
|
|
8
8
|
var DottedPagination = require('./dotted-pagination/DottedPagination.js');
|
|
9
|
-
var
|
|
9
|
+
var index = require('./layout/index.js');
|
|
10
10
|
var Question = require('./question/Question.js');
|
|
11
11
|
var Selection = require('./selection/Selection.js');
|
|
12
12
|
var IconButton = require('./icon-button/IconButton.js');
|
|
@@ -26,6 +26,7 @@ var Audio = require('./audio/Audio.js');
|
|
|
26
26
|
var SoundVisualizer = require('./sound-visualizer/SoundVisualizer.js');
|
|
27
27
|
var RecorderContext = require('./recorder-step/RecorderContext.js');
|
|
28
28
|
var RecorderStep = require('./recorder-step/RecorderStep.js');
|
|
29
|
+
var Layout = require('./layout/Layout.js');
|
|
29
30
|
|
|
30
31
|
|
|
31
32
|
|
|
@@ -35,7 +36,7 @@ exports.EliceButton = Button.default;
|
|
|
35
36
|
exports.EliceChat = Chat.default;
|
|
36
37
|
exports.EliceDialog = Dialog.default;
|
|
37
38
|
exports.EliceDottedPagination = DottedPagination.default;
|
|
38
|
-
exports.EliceLayout =
|
|
39
|
+
exports.EliceLayout = index.EliceLayout;
|
|
39
40
|
exports.EliceQuestion = Question.default;
|
|
40
41
|
exports.EliceSelection = Selection.default;
|
|
41
42
|
exports.EliceIconButton = IconButton.default;
|
|
@@ -55,3 +56,15 @@ exports.EliceAudioPlayer = Audio.default;
|
|
|
55
56
|
exports.SoundVisualizer = SoundVisualizer.SoundVisualizer;
|
|
56
57
|
exports.RecorderProvider = RecorderContext.RecorderProvider;
|
|
57
58
|
exports.EliceRecorderStep = RecorderStep.default;
|
|
59
|
+
exports.Box = Layout.Box;
|
|
60
|
+
exports.Content = Layout.Content;
|
|
61
|
+
exports.ContentContainer = Layout.ContentContainer;
|
|
62
|
+
exports.FooterContainer = Layout.FooterContainer;
|
|
63
|
+
exports.FooterPaging = Layout.FooterPaging;
|
|
64
|
+
exports.FooterSubmit = Layout.FooterSubmit;
|
|
65
|
+
exports.HeaderContainer = Layout.HeaderContainer;
|
|
66
|
+
exports.HeaderSubTitle = Layout.HeaderSubTitle;
|
|
67
|
+
exports.HeaderTitle = Layout.HeaderTitle;
|
|
68
|
+
exports.Layout = Layout.Layout;
|
|
69
|
+
exports.Stack = Layout.Stack;
|
|
70
|
+
exports.Typography = Layout.Typography;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import type { SxProps, Theme } from "@mui/material";
|
|
2
|
+
import type { BoxProps, StackProps, SxProps, Theme, TypographyProps } from "@mui/material";
|
|
3
3
|
export interface EliceLayoutProps {
|
|
4
4
|
children: React.ReactNode;
|
|
5
5
|
backgroundImage?: string;
|
|
@@ -13,35 +13,53 @@ export interface EliceLayoutProps {
|
|
|
13
13
|
sx?: SxProps<Theme>;
|
|
14
14
|
}
|
|
15
15
|
type Alignment = "left" | "center" | "right";
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
};
|
|
47
|
-
export
|
|
16
|
+
interface EliceStepProps<T extends React.ElementType> {
|
|
17
|
+
step?: -1 | 0 | 1 | 2 | 3;
|
|
18
|
+
component?: T;
|
|
19
|
+
}
|
|
20
|
+
type EliceBoxProps<T extends React.ElementType> = BoxProps<T> & EliceStepProps<T>;
|
|
21
|
+
type EliceStackProps<T extends React.ElementType> = StackProps<T> & EliceStepProps<T>;
|
|
22
|
+
type EliceTypographyProps = TypographyProps & Omit<EliceStepProps<React.ElementType>, 'component'>;
|
|
23
|
+
/**
|
|
24
|
+
* @summary Alpha of Design System. Wrapper of MUI Box
|
|
25
|
+
* */
|
|
26
|
+
export declare const Box: React.ForwardRefExoticComponent<Omit<EliceBoxProps<React.ElementType<any, keyof React.JSX.IntrinsicElements>>, "ref"> & React.RefAttributes<unknown>>;
|
|
27
|
+
/**
|
|
28
|
+
* @summary Alpha of Design System. Wrapper of MUI Stack
|
|
29
|
+
* */
|
|
30
|
+
export declare const Stack: React.ForwardRefExoticComponent<Omit<EliceStackProps<React.ElementType<any, keyof React.JSX.IntrinsicElements>>, "ref"> & React.RefAttributes<unknown>>;
|
|
31
|
+
/**
|
|
32
|
+
* @summary Alpha of Design System. Wrapper of MUI Typography
|
|
33
|
+
* */
|
|
34
|
+
export declare function Typography({ step, sx, ...props }: EliceTypographyProps): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare const Layout: ({ children, onPrev, onNext, allowPrev, allowNext, backgroundImage, backgroundColor, onlyPage, enableScrollTracking, sx }: EliceLayoutProps) => import("react/jsx-runtime").JSX.Element;
|
|
36
|
+
export declare const HeaderContainer: ({ children, sx }: {
|
|
37
|
+
children: React.ReactNode;
|
|
38
|
+
sx?: SxProps<Theme> | undefined;
|
|
39
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
40
|
+
export declare const HeaderTitle: ({ children, titleComponent, sx }: import("./Header").LayoutHeaderTitleProps) => JSX.Element;
|
|
41
|
+
export declare const HeaderSubTitle: ({ children, sx }: import("./Header").LayoutHeaderSubTitleProps) => JSX.Element;
|
|
42
|
+
export declare const ContentContainer: ({ children, sx, scrollbarPostion }: {
|
|
43
|
+
children: React.ReactNode;
|
|
44
|
+
sx?: SxProps<Theme> | undefined;
|
|
45
|
+
scrollbarPostion?: number | undefined;
|
|
46
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
47
|
+
export declare const Subtitle: ({ children, alignment, justifyContent, sx }: {
|
|
48
|
+
children: React.ReactNode;
|
|
49
|
+
alignment?: Alignment | undefined;
|
|
50
|
+
justifyContent?: string | undefined;
|
|
51
|
+
sx?: SxProps<Theme> | undefined;
|
|
52
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
53
|
+
export declare const Content: ({ children, alignment, justifyContent, sx, }: {
|
|
54
|
+
children: React.ReactNode;
|
|
55
|
+
alignment?: Alignment | undefined;
|
|
56
|
+
justifyContent?: string | undefined;
|
|
57
|
+
sx?: SxProps<Theme> | undefined;
|
|
58
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
59
|
+
export declare const FooterContainer: ({ children, sx }: {
|
|
60
|
+
children: React.ReactNode;
|
|
61
|
+
sx?: SxProps<Theme> | undefined;
|
|
62
|
+
}) => import("react/jsx-runtime").JSX.Element;
|
|
63
|
+
export declare const FooterPaging: React.FC<import("./Footer").LayoutFooterPagingProps>;
|
|
64
|
+
export declare const FooterSubmit: ({ isRollback, isSubmit, disableRollback, disableSubmit, submitText, rollbackText, onSubmit, onRollback, sx, }: import("./Footer").LayoutFooterSubmitProps) => import("react/jsx-runtime").JSX.Element;
|
|
65
|
+
export {};
|