odaptos_design_system 1.4.23 → 1.4.25
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/dist/Interviews/Chat.d.ts +3 -2
- package/dist/Interviews/Task.d.ts +4 -2
- package/dist/odaptos_design_system.cjs.development.js +9 -3
- package/dist/odaptos_design_system.cjs.development.js.map +1 -1
- package/dist/odaptos_design_system.cjs.production.min.js +1 -1
- package/dist/odaptos_design_system.cjs.production.min.js.map +1 -1
- package/dist/odaptos_design_system.esm.js +9 -3
- package/dist/odaptos_design_system.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/Interviews/Chat.tsx +5 -1
- package/src/Interviews/Task.modules.scss +4 -3
- package/src/Interviews/Task.tsx +7 -2
- package/src/Tag/Tag.modules.scss +0 -1
|
@@ -19,12 +19,13 @@ export interface ChatProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
19
19
|
startInterviewIcon?: JSX.Element;
|
|
20
20
|
startInterview?: () => void;
|
|
21
21
|
tasks: TaskItem[];
|
|
22
|
-
sendTask: () => void;
|
|
22
|
+
sendTask: (taskIndex: number) => void;
|
|
23
|
+
validateTask: (taskIndex: number) => void;
|
|
23
24
|
currentTask: TaskItem;
|
|
24
25
|
chatInputPlaceholder?: string;
|
|
25
26
|
chatInputValue?: string;
|
|
26
27
|
chatInputonChange?: (message: string) => void;
|
|
27
28
|
className?: string;
|
|
28
29
|
}
|
|
29
|
-
export declare const Chat: ({ goBackText, goBack, chatTitle, welcomeTitle, welcomeDescription, startInterviewTitle, startInterviewBtnTitle, startInterviewIcon, startInterview, tasks, sendTask, currentTask, chatInputPlaceholder, chatInputValue, chatInputonChange, className, ...props }: ChatProps) => React.JSX.Element;
|
|
30
|
+
export declare const Chat: ({ goBackText, goBack, chatTitle, welcomeTitle, welcomeDescription, startInterviewTitle, startInterviewBtnTitle, startInterviewIcon, startInterview, tasks, sendTask, validateTask, currentTask, chatInputPlaceholder, chatInputValue, chatInputonChange, className, ...props }: ChatProps) => React.JSX.Element;
|
|
30
31
|
export {};
|
|
@@ -6,7 +6,9 @@ export interface TaskProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
6
6
|
notes?: string;
|
|
7
7
|
state: 'idle' | 'active' | 'disabled';
|
|
8
8
|
isDone: boolean;
|
|
9
|
-
|
|
9
|
+
taskIndex: number;
|
|
10
|
+
sendTask: (taskIndex: number) => void;
|
|
11
|
+
validateTask: (taskIndex: number) => void;
|
|
10
12
|
iconAction1?: JSX.Element;
|
|
11
13
|
iconAction2?: JSX.Element;
|
|
12
14
|
iconAction3?: JSX.Element;
|
|
@@ -16,4 +18,4 @@ export interface TaskProps extends HTMLAttributes<HTMLDivElement> {
|
|
|
16
18
|
mainActionText?: string;
|
|
17
19
|
mainAction?: () => void;
|
|
18
20
|
}
|
|
19
|
-
export declare const Task: ({ taskNumber, taskTitle, notes, className, sendTask, state, isDone, iconAction1, iconAction2, iconAction3, action1, action2, action3, mainActionText, mainAction, ...props }: TaskProps) => React.JSX.Element;
|
|
21
|
+
export declare const Task: ({ taskNumber, taskTitle, notes, className, taskIndex, sendTask, validateTask, state, isDone, iconAction1, iconAction2, iconAction3, action1, action2, action3, mainActionText, mainAction, ...props }: TaskProps) => React.JSX.Element;
|
|
@@ -4709,7 +4709,7 @@ const Button = ({
|
|
|
4709
4709
|
}), iconRight && iconRight);
|
|
4710
4710
|
};
|
|
4711
4711
|
|
|
4712
|
-
var css_248z$9 = ".Tag-modules_tag__H7-4Y{align-items:center;border-radius:.25rem;display:flex;gap:.25rem;
|
|
4712
|
+
var css_248z$9 = ".Tag-modules_tag__H7-4Y{align-items:center;border-radius:.25rem;display:flex;gap:.25rem;padding:0 .75rem;width:-moz-fit-content;width:fit-content}.Tag-modules_tag_idle__Fq6m8{background:var(--color-neutral-dark-shades-600,#717376)}.Tag-modules_tag_idle__Fq6m8 svg{stroke:#fff!important;fill:#fff!important}.Tag-modules_tag_info__aMPRZ{background:var(--color-primary-100,#e5f1ff)}.Tag-modules_tag_info__aMPRZ svg{stroke:#004799!important;fill:#004799!important}.Tag-modules_tag_success__2LvMD{background:var(--color-extended-green-100,#e8f5ea)}.Tag-modules_tag_success__2LvMD svg{stroke:#3c743d!important;fill:#3c743d!important}.Tag-modules_tag_warning__AIt1v{background:var(--color-extended-yellow-100,#fff3d6)}.Tag-modules_tag_warning__AIt1v svg{stroke:#6e4f00!important;fill:#6e4f00!important}.Tag-modules_tag_critical__LQoYS{background:var(--color-extended-red-100,#fddbdb)}.Tag-modules_tag_critical__LQoYS svg{stroke:#98312e!important;fill:#98312e!important}.Tag-modules_tag_sm__6woOo svg{height:.75rem;width:.75rem}.Tag-modules_tag_base__NFJol svg{height:1rem;width:1rem}";
|
|
4713
4713
|
var styles$9 = {"tag":"Tag-modules_tag__H7-4Y","tag_idle":"Tag-modules_tag_idle__Fq6m8","tag_info":"Tag-modules_tag_info__aMPRZ","tag_success":"Tag-modules_tag_success__2LvMD","tag_warning":"Tag-modules_tag_warning__AIt1v","tag_critical":"Tag-modules_tag_critical__LQoYS","tag_sm":"Tag-modules_tag_sm__6woOo","tag_base":"Tag-modules_tag_base__NFJol"};
|
|
4714
4714
|
styleInject(css_248z$9);
|
|
4715
4715
|
|
|
@@ -6337,6 +6337,7 @@ const Chat = ({
|
|
|
6337
6337
|
startInterview,
|
|
6338
6338
|
tasks,
|
|
6339
6339
|
sendTask,
|
|
6340
|
+
validateTask,
|
|
6340
6341
|
currentTask,
|
|
6341
6342
|
chatInputPlaceholder,
|
|
6342
6343
|
chatInputValue,
|
|
@@ -6376,7 +6377,9 @@ const Chat = ({
|
|
|
6376
6377
|
taskTitle: task.description,
|
|
6377
6378
|
notes: task.notes,
|
|
6378
6379
|
state: isCompletedTask ? 'disabled' : currentTaskIndex === index ? 'active' : 'idle',
|
|
6380
|
+
taskIndex: index,
|
|
6379
6381
|
sendTask: sendTask,
|
|
6382
|
+
validateTask: validateTask,
|
|
6380
6383
|
isDone: isCompletedTask
|
|
6381
6384
|
});
|
|
6382
6385
|
})), chatInputPlaceholder && typeof chatInputValue === 'string' && chatInputonChange && /*#__PURE__*/React__default.createElement(ChatInput, {
|
|
@@ -6481,7 +6484,7 @@ const GoBack = ({
|
|
|
6481
6484
|
}));
|
|
6482
6485
|
};
|
|
6483
6486
|
|
|
6484
|
-
var css_248z$C = ".Task-modules_task_container__Iaqc-{align-items:flex-start;
|
|
6487
|
+
var css_248z$C = ".Task-modules_task_container__Iaqc-{align-items:flex-start;background:var(--color-neutral-basics-white,#fff);border:1px solid var(--color-neutral-dark-shades-950,#26292e);border-radius:.5rem;display:flex;flex-direction:column;gap:.5rem;justify-content:center;max-width:100%;padding:0}.Task-modules_task_container__Iaqc- .Task-modules_header__f15OM{max-width:100%}.Task-modules_task_container__Iaqc- .Task-modules_header__f15OM .Task-modules_header_left__JJTGR:hover{background:var(--color-neutral-clear-shades-150,#eee);border-radius:.5rem 0 0 .5rem}.Task-modules_task_container__Iaqc- .Task-modules_header__f15OM .Task-modules_header_right__AymtU:hover{background:var(--color-neutral-clear-shades-150,#eee);border-radius:0 .5rem .5rem 0}.Task-modules_header__f15OM{align-items:center;display:flex;height:100%;justify-content:space-between;max-width:100%;width:100%}.Task-modules_header_left__JJTGR{align-items:flex-start;cursor:pointer;display:flex;flex-direction:column;justify-content:center;max-width:calc(100% - 3.5rem);min-width:calc(100% - 3.5rem);padding:.3125rem .3125rem .3125rem .62rem;width:100%}.Task-modules_header_left__JJTGR .Task-modules_title__-OmPh{max-width:98%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.Task-modules_header_right__AymtU{align-items:center;background:var(--color-neutral-basics-white,#fff);border:none;border-left:1px solid var(--color-neutral-dark-shades-950,#26292e);border-radius:0 .5rem .5rem 0;cursor:pointer;display:flex;gap:.5rem;height:100%;justify-content:center;max-width:calc(100% - 3.5rem);padding:1rem .75rem}.Task-modules_header_right__AymtU svg{fill:#000;height:1rem;width:1rem}.Task-modules_disabled_task__NI6LL{align-items:flex-start;background:var(--color-neutral-basics-white,#fff);border:1px solid var(--color-neutral-clear-shades-300,#d5d5d6);border-radius:.5rem;cursor:not-allowed;display:flex;flex-direction:column;gap:.5rem;justify-content:center;max-width:100%;padding:0}.Task-modules_disabled_task__NI6LL .Task-modules_header__f15OM{max-width:100%;width:100%}.Task-modules_disabled_task__NI6LL .Task-modules_header__f15OM .Task-modules_header_left__JJTGR{border-color:var(--color-neutral-clear-shades-300,#d5d5d6);cursor:not-allowed;opacity:.5;width:100%}.Task-modules_disabled_task__NI6LL .Task-modules_header__f15OM .Task-modules_header_right__AymtU{border-color:var(--color-neutral-clear-shades-300,#d5d5d6);cursor:not-allowed;opacity:.5}.Task-modules_active_task__l-n9Q{align-items:flex-start;background:var(--color-neutral-basics-white,#fff);border:1px solid #07f;border-radius:.5rem;display:flex;flex-direction:column;gap:.5rem;justify-content:center;max-width:100%;padding:0}.Task-modules_active_task__l-n9Q .Task-modules_header__f15OM{border-bottom:1px solid var(--color-neutral-clear-shades-300,#d5d5d6);max-width:100%;width:100%}.Task-modules_active_task__l-n9Q .Task-modules_header__f15OM .Task-modules_header_left__JJTGR,.Task-modules_active_task__l-n9Q .Task-modules_header__f15OM .Task-modules_header_right__AymtU{border-color:var(--color-neutral-clear-shades-300,#d5d5d6)}.Task-modules_active_task__l-n9Q .Task-modules_header__f15OM .Task-modules_header_right__AymtU:hover{background:var(--color-neutral-clear-shades-150,#eee)}.Task-modules_taskContent__v3Cm1{align-items:flex-start;align-self:stretch;display:flex;flex-direction:column;gap:.5rem;padding:.5rem .75rem .25rem}.Task-modules_taskPopover__S07XU{align-items:flex-start;background:var(--color-neutral-basics-white,#fff);border:1px solid var(--color-neutral-dark-shades-950,#26292e);border-radius:.5rem;display:flex;flex-direction:column;overflow:hidden;padding:.5rem .75rem .75rem;width:25.5625rem}.Task-modules_notesContainer__dz0Me{align-items:flex-start;align-self:stretch;border-top:1px solid var(--color-neutral-clear-shades-300,#d5d5d6);display:flex;flex-direction:column;gap:.25rem;padding-top:.5rem}.Task-modules_actionBtnsContainer__Dz-1j{align-items:flex-start;align-self:stretch;display:flex;gap:.5rem;justify-content:flex-end;padding-top:8px}.Task-modules_popover_paper__Re-kl .Task-modules_MuiPopover-paper__7p4Tk,.Task-modules_popover_paper__Re-kl .Task-modules_MuiPopover-root__w6O-O{background:transparent;border-radius:.5rem}";
|
|
6485
6488
|
var styles$C = {"task_container":"Task-modules_task_container__Iaqc-","header":"Task-modules_header__f15OM","header_left":"Task-modules_header_left__JJTGR","header_right":"Task-modules_header_right__AymtU","title":"Task-modules_title__-OmPh","disabled_task":"Task-modules_disabled_task__NI6LL","active_task":"Task-modules_active_task__l-n9Q","taskContent":"Task-modules_taskContent__v3Cm1","taskPopover":"Task-modules_taskPopover__S07XU","notesContainer":"Task-modules_notesContainer__dz0Me","actionBtnsContainer":"Task-modules_actionBtnsContainer__Dz-1j","popover_paper":"Task-modules_popover_paper__Re-kl","MuiPopover-root":"Task-modules_MuiPopover-root__w6O-O","MuiPopover-paper":"Task-modules_MuiPopover-paper__7p4Tk"};
|
|
6486
6489
|
styleInject(css_248z$C);
|
|
6487
6490
|
|
|
@@ -6500,7 +6503,9 @@ const Task = ({
|
|
|
6500
6503
|
taskTitle,
|
|
6501
6504
|
notes,
|
|
6502
6505
|
className,
|
|
6506
|
+
taskIndex,
|
|
6503
6507
|
sendTask,
|
|
6508
|
+
validateTask,
|
|
6504
6509
|
state = 'idle',
|
|
6505
6510
|
isDone,
|
|
6506
6511
|
iconAction1,
|
|
@@ -6545,7 +6550,8 @@ const Task = ({
|
|
|
6545
6550
|
})), /*#__PURE__*/React__default.createElement("button", {
|
|
6546
6551
|
className: styles$C.header_right,
|
|
6547
6552
|
onClick: () => {
|
|
6548
|
-
if (state === '
|
|
6553
|
+
if (state === 'idle') sendTask(taskIndex);
|
|
6554
|
+
if (state === 'active') validateTask(taskIndex);
|
|
6549
6555
|
},
|
|
6550
6556
|
disabled: state === 'disabled'
|
|
6551
6557
|
}, state === 'active' || isDone ? /*#__PURE__*/React__default.createElement(CheckedIcon, null) : /*#__PURE__*/React__default.createElement(SendIcon, null))), state === 'active' && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement("div", {
|