mario-education 2.4.487-feedback → 2.4.488-feedback

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.
@@ -0,0 +1,4 @@
1
+ declare const ArrowBackIcon: ({ color }: {
2
+ color?: string | undefined;
3
+ }) => JSX.Element;
4
+ export default ArrowBackIcon;
@@ -0,0 +1,2 @@
1
+ declare const ArrowRightIcon: () => JSX.Element;
2
+ export default ArrowRightIcon;
@@ -0,0 +1,4 @@
1
+ declare const DarkIcon: ({ color }: {
2
+ color?: string | undefined;
3
+ }) => JSX.Element;
4
+ export default DarkIcon;
@@ -0,0 +1,2 @@
1
+ declare const IdentifyIcon: () => JSX.Element;
2
+ export default IdentifyIcon;
@@ -0,0 +1,4 @@
1
+ declare const LightIcon: ({ color }: {
2
+ color?: string | undefined;
3
+ }) => JSX.Element;
4
+ export default LightIcon;
@@ -0,0 +1,2 @@
1
+ declare const MarioAIIcon: () => JSX.Element;
2
+ export default MarioAIIcon;
@@ -0,0 +1,2 @@
1
+ declare const MoreIcon: () => JSX.Element;
2
+ export default MoreIcon;
@@ -0,0 +1,2 @@
1
+ declare const SummarizeIcon: () => JSX.Element;
2
+ export default SummarizeIcon;
@@ -0,0 +1,2 @@
1
+ declare const UnderstandIcon: () => JSX.Element;
2
+ export default UnderstandIcon;
@@ -1,2 +1,15 @@
1
- import { IOptionDate } from "./type";
1
+ import { ICardAI, IOptionDate } from "./type";
2
2
  export declare const CALENDAR_OPTIONS: IOptionDate[];
3
+ export declare const promptIcons: (() => JSX.Element)[];
4
+ export declare const CARD_AI_HEADER: ICardAI[];
5
+ export declare const THEME: {
6
+ LIGHT: string;
7
+ DARK: string;
8
+ };
9
+ export declare enum MessageRole {
10
+ System = 0,
11
+ User = 1,
12
+ Model = 2
13
+ }
14
+ export declare const DEFAULT_START_DATE: number;
15
+ export declare const DEFAULT_END_DATE: number;
@@ -1,3 +1,4 @@
1
+ import { MessageRole } from "./constants";
1
2
  export interface ISummarizeResponse {
2
3
  studentName: string;
3
4
  answer: string;
@@ -11,3 +12,96 @@ export interface IOptionDate {
11
12
  startDate: number;
12
13
  endDate: number;
13
14
  }
15
+ export interface ICardAI {
16
+ title: string;
17
+ description: string;
18
+ icon: any;
19
+ link?: string;
20
+ id: number;
21
+ }
22
+ export interface ICardHeader {
23
+ id: number;
24
+ name: string;
25
+ description: string;
26
+ goToChat: Function;
27
+ icon: any;
28
+ }
29
+ export interface IChat {
30
+ message: string;
31
+ text?: string;
32
+ time: string;
33
+ isUser: boolean;
34
+ options?: IOptionDate[];
35
+ }
36
+ export interface IPrompt {
37
+ name: string;
38
+ description: string;
39
+ temperature: number;
40
+ maxOutputTokens: number;
41
+ stopSequences: string;
42
+ topP: number;
43
+ topK: number;
44
+ frequencyPenalty: number;
45
+ presencePenalty: number;
46
+ aiModel: string;
47
+ messages: IMessage[];
48
+ id: number;
49
+ instruction: instructionType;
50
+ sampleData: string;
51
+ question: string;
52
+ }
53
+ export interface IMessage {
54
+ role: MessageRole;
55
+ message: string;
56
+ }
57
+ export declare enum instructionType {
58
+ CheckIn = 0,
59
+ OneToOne = 1,
60
+ Conference = 2,
61
+ CheckInAndOneToOne = 3
62
+ }
63
+ export interface IHeaderAi {
64
+ prompts: IPrompt[];
65
+ goToChat: Function;
66
+ generateIcons: Function;
67
+ }
68
+ export interface IHistoryPrompt {
69
+ name: string;
70
+ description: string;
71
+ temperature: number;
72
+ maxOutputTokens: number;
73
+ stopSequences: string;
74
+ topP: number;
75
+ topK: number;
76
+ frequencyPenalty: number;
77
+ presencePenalty: number;
78
+ aiModel: string;
79
+ messages: IChat[];
80
+ id?: number;
81
+ instruction: instructionType;
82
+ question: string;
83
+ startTime?: number;
84
+ endTime?: number;
85
+ startDate?: string;
86
+ endDate?: string;
87
+ grade: string;
88
+ promptId: number;
89
+ output: string;
90
+ calendar: string;
91
+ createdAt: string;
92
+ }
93
+ export interface IPromptParams {
94
+ schoolId?: number;
95
+ startDate?: number;
96
+ endDate?: number;
97
+ grade?: string;
98
+ question?: string;
99
+ calendar?: string;
100
+ instruction?: instructionType;
101
+ }
102
+ export interface IAnswer {
103
+ answer: string;
104
+ fullName: string;
105
+ grade: string;
106
+ question: string;
107
+ }
@@ -0,0 +1,4 @@
1
+ import { FC } from 'react';
2
+ import { ICardHeader } from '../cofigs/type';
3
+ declare const CardHeader: FC<ICardHeader>;
4
+ export default CardHeader;
@@ -0,0 +1,9 @@
1
+ import { FC } from 'react';
2
+ import { IChat } from '../cofigs/type';
3
+ interface ChatContentProps {
4
+ theme: string;
5
+ chats: IChat[];
6
+ onSelectTime?: Function;
7
+ }
8
+ declare const ChatContent: FC<ChatContentProps>;
9
+ export default ChatContent;
@@ -0,0 +1,10 @@
1
+ import { FC } from 'react';
2
+ interface ChatHeaderProps {
3
+ theme: string;
4
+ setTheme: (theme: string) => void;
5
+ goBack: () => void;
6
+ isOpenSideBar: boolean;
7
+ name: string;
8
+ }
9
+ declare const ChatHeader: FC<ChatHeaderProps>;
10
+ export default ChatHeader;
@@ -0,0 +1,8 @@
1
+ interface IChatMessage {
2
+ isUser: boolean;
3
+ message: string;
4
+ options?: string[];
5
+ time?: string;
6
+ }
7
+ declare const ChatMessage: ({ isUser, message, options, time }: IChatMessage) => JSX.Element;
8
+ export default ChatMessage;
@@ -0,0 +1,3 @@
1
+ import { IHeaderAi } from '../cofigs/type';
2
+ declare const HeaderAI: ({ prompts, goToChat, generateIcons }: IHeaderAi) => JSX.Element;
3
+ export default HeaderAI;
@@ -0,0 +1,17 @@
1
+ import { FC } from 'react';
2
+ import { IHistoryPrompt } from '../cofigs/type';
3
+ interface IProps {
4
+ maxHeight: number;
5
+ historyPrompts: IHistoryPrompt[];
6
+ handleClickAction: Function;
7
+ handleCloseAction: Function;
8
+ anchorEl: HTMLButtonElement | null;
9
+ popoverId?: string;
10
+ openPopover: boolean;
11
+ removeData: Function;
12
+ selectId: number | null;
13
+ goToViewHistory: Function;
14
+ generateIcons: Function;
15
+ }
16
+ declare const ListPrompts: FC<IProps>;
17
+ export default ListPrompts;
@@ -0,0 +1,12 @@
1
+ /// <reference types="react" />
2
+ import { IChat, IOptionDate, IPrompt } from "../cofigs/type";
3
+ declare const useAIChat: () => {
4
+ theme: string;
5
+ setTheme: import("react").Dispatch<import("react").SetStateAction<string>>;
6
+ goBack: () => void;
7
+ isOpenSideBar: any;
8
+ prompt: IPrompt | undefined;
9
+ chats: IChat[];
10
+ handleSelectTime: (value: IOptionDate) => void;
11
+ };
12
+ export default useAIChat;
@@ -0,0 +1,19 @@
1
+ /// <reference types="react" />
2
+ import { IHistoryPrompt, IPrompt } from "../cofigs/type";
3
+ declare const useAIMario: () => {
4
+ handleClickAction: (event: React.MouseEvent<HTMLButtonElement>, id: number) => void;
5
+ handleCloseAction: () => void;
6
+ anchorEl: HTMLButtonElement | null;
7
+ popoverId: string | undefined;
8
+ openPopover: boolean;
9
+ goToChat: (id: number) => void;
10
+ isOpenSideBar: any;
11
+ height: number;
12
+ aiMarioRef: import("react").RefObject<HTMLDivElement>;
13
+ prompts: IPrompt[];
14
+ historyPrompts: IHistoryPrompt[];
15
+ removeData: (id: number) => Promise<void>;
16
+ selectId: number | null;
17
+ goToViewHistory: (id: number) => void;
18
+ };
19
+ export default useAIMario;
@@ -0,0 +1,10 @@
1
+ /// <reference types="react" />
2
+ import { IHistoryPrompt } from "../cofigs/type";
3
+ declare const useHistoryPrompt: () => {
4
+ theme: string;
5
+ setTheme: import("react").Dispatch<import("react").SetStateAction<string>>;
6
+ goBack: () => void;
7
+ isOpenSideBar: any;
8
+ prompt: IHistoryPrompt | undefined;
9
+ };
10
+ export default useHistoryPrompt;
@@ -0,0 +1,2 @@
1
+ declare const AIMario: () => JSX.Element;
2
+ export default AIMario;
@@ -0,0 +1,2 @@
1
+ declare const ChatWithAI: () => JSX.Element;
2
+ export default ChatWithAI;
@@ -0,0 +1,2 @@
1
+ declare const ViewHistoryPrompt: () => JSX.Element;
2
+ export default ViewHistoryPrompt;
@@ -0,0 +1,8 @@
1
+ import { IHistoryPrompt, IPromptParams } from "../containers/MarioAi/cofigs/type";
2
+ export declare const getPrompt: () => Promise<import("axios").AxiosResponse<any>>;
3
+ export declare const getById: (id: number) => Promise<import("axios").AxiosResponse<any>>;
4
+ export declare const getHistoryPrompt: () => Promise<import("axios").AxiosResponse<any>>;
5
+ export declare const getSessionAnswer: (params: IPromptParams) => Promise<import("axios").AxiosResponse<any>>;
6
+ export declare const createHistory: (data: IHistoryPrompt) => Promise<import("axios").AxiosResponse<any>>;
7
+ export declare const removeHistory: (id: number) => Promise<import("axios").AxiosResponse<any>>;
8
+ export declare const getHistoryById: (id: number) => Promise<import("axios").AxiosResponse<any>>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mario-education",
3
- "version": "2.4.487-feedback",
3
+ "version": "2.4.488-feedback",
4
4
  "description": "Contains education components && functions for BRSS Mario project",
5
5
  "author": "brss",
6
6
  "license": "MIT",
@@ -95,7 +95,7 @@
95
95
  "grapesjs-preset-webpage": "^0.1.11",
96
96
  "html2canvas": "^1.4.1",
97
97
  "jspdf": "^2.5.1",
98
- "mario-core": "2.9.370-release",
98
+ "mario-core": "2.9.372-release",
99
99
  "react-apexcharts": "^1.3.9",
100
100
  "react-datepicker": "^3.8.0",
101
101
  "react-icons": "^4.2.0",