odaptos_design_system 1.0.0 → 1.2.0

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.
Files changed (224) hide show
  1. package/README.md +8 -74
  2. package/package.json +24 -15
  3. package/src/Accordion/Accordion.modules.scss +41 -0
  4. package/src/Accordion/Accordion.tsx +55 -0
  5. package/src/Badge/Badge.modules.scss +83 -0
  6. package/src/Badge/Badge.tsx +69 -0
  7. package/src/Buttons/Button.modules.scss +235 -0
  8. package/src/Buttons/Button.tsx +55 -7
  9. package/src/Buttons/IconButton.modules.scss +185 -0
  10. package/src/Buttons/IconButton.tsx +53 -0
  11. package/src/Cards/Card.modules.scss +12 -0
  12. package/src/Cards/Card.tsx +14 -0
  13. package/src/Cards/CardButton.modules.scss +23 -0
  14. package/src/Cards/CardButton.tsx +14 -0
  15. package/src/Checkbox/Checkbox.module.scss +4 -0
  16. package/src/Checkbox/Checkbox.tsx +120 -0
  17. package/src/ColorGuide/colors.ts +99 -0
  18. package/src/Icons/Arrows/ArrowDoubleLineDownIcon.tsx +44 -0
  19. package/src/Icons/Arrows/ArrowDoubleLineLeftIcon.tsx +44 -0
  20. package/src/Icons/Arrows/ArrowDoubleLineRightIcon.tsx +44 -0
  21. package/src/Icons/Arrows/ArrowDoubleLineUpIcon.tsx +44 -0
  22. package/src/Icons/Arrows/ArrowFilledDownIcon.tsx +29 -0
  23. package/src/Icons/Arrows/ArrowFilledLeftIcon.tsx +29 -0
  24. package/src/Icons/Arrows/ArrowFilledRightIcon.tsx +29 -0
  25. package/src/Icons/Arrows/ArrowFilledUpIcon.tsx +29 -0
  26. package/src/Icons/Arrows/ArrowLineDownIcon.tsx +38 -0
  27. package/src/Icons/Arrows/ArrowLineLeftIcon.tsx +38 -0
  28. package/src/Icons/Arrows/ArrowLineRightIcon.tsx +38 -0
  29. package/src/Icons/Arrows/ArrowLineUpIcon.tsx +38 -0
  30. package/src/Icons/Arrows/ArrowPointerDown.tsx +44 -0
  31. package/src/Icons/Arrows/ArrowPointerDownLeft.tsx +37 -0
  32. package/src/Icons/Arrows/ArrowPointerDownRight.tsx +37 -0
  33. package/src/Icons/Arrows/ArrowPointerLeft.tsx +44 -0
  34. package/src/Icons/Arrows/ArrowPointerRight.tsx +44 -0
  35. package/src/Icons/Arrows/ArrowPointerUp.tsx +44 -0
  36. package/src/Icons/Arrows/ArrowPointerUpLeft.tsx +37 -0
  37. package/src/Icons/Arrows/ArrowPointerUpRight.tsx +37 -0
  38. package/src/Icons/Circled/AddCircledIcon.tsx +43 -0
  39. package/src/Icons/Circled/AlertCircledIcon.tsx +56 -0
  40. package/src/Icons/Circled/CheckedCircled.tsx +44 -0
  41. package/src/Icons/Circled/InfoCircledIcon.tsx +56 -0
  42. package/src/Icons/Circled/MinusCircledIcon.tsx +44 -0
  43. package/src/Icons/Circled/NavigationCircledIcon.tsx +50 -0
  44. package/src/Icons/Circled/QuestionCircledIcon.tsx +49 -0
  45. package/src/Icons/Circled/RemoveCircledIcon.tsx +43 -0
  46. package/src/Icons/Circled/SearchCircledIcon.tsx +50 -0
  47. package/src/Icons/Circled/SettingsCircledIcon.tsx +43 -0
  48. package/src/Icons/Equipment/CameraIcon.tsx +37 -0
  49. package/src/Icons/Equipment/LaptopIcon.tsx +66 -0
  50. package/src/Icons/Equipment/MicrophonePodcastIcon.tsx +31 -0
  51. package/src/Icons/Equipment/MobileIcon.tsx +73 -0
  52. package/src/Icons/Equipment/TvFlatScreenIcon.tsx +67 -0
  53. package/src/Icons/Equipment/TvIcon.tsx +43 -0
  54. package/src/Icons/Interaction/AccountIcon.tsx +31 -0
  55. package/src/Icons/Interaction/AddIcon.tsx +44 -0
  56. package/src/Icons/Interaction/AgendaIcon.tsx +68 -0
  57. package/src/Icons/Interaction/BillingIcon.tsx +67 -0
  58. package/src/Icons/Interaction/BinIcon.tsx +50 -0
  59. package/src/Icons/Interaction/CheckedIcon.tsx +31 -0
  60. package/src/Icons/Interaction/ClockIcon.tsx +50 -0
  61. package/src/Icons/Interaction/CopyPasteIcon.tsx +75 -0
  62. package/src/Icons/Interaction/DragDropIcon.tsx +34 -0
  63. package/src/Icons/Interaction/EditIcon.tsx +44 -0
  64. package/src/Icons/Interaction/EditTextIcon.tsx +56 -0
  65. package/src/Icons/Interaction/LogoutIcon.tsx +50 -0
  66. package/src/Icons/Interaction/MenuHorizontalIcon.tsx +28 -0
  67. package/src/Icons/Interaction/MenuVerticalIcon.tsx +40 -0
  68. package/src/Icons/Interaction/MinusIcon.tsx +26 -0
  69. package/src/Icons/Interaction/SearchIcon.tsx +44 -0
  70. package/src/Icons/Interaction/SearchRemoveIcon.tsx +56 -0
  71. package/src/Icons/Interaction/ShareIcon.tsx +55 -0
  72. package/src/Icons/Interaction/TeamIcon.tsx +68 -0
  73. package/src/Icons/Logos/LogoBeta.tsx +51 -0
  74. package/src/Icons/Logos/LogoNormal.tsx +37 -0
  75. package/src/Icons/Logos/LogoSmall.tsx +31 -0
  76. package/src/Icons/Logos/LogoSquare.tsx +71 -0
  77. package/src/Icons/Logos/LogoText.tsx +31 -0
  78. package/src/Icons/MediaControl/HangUpIcon.tsx +50 -0
  79. package/src/Icons/MediaControl/MeetingIcon.tsx +37 -0
  80. package/src/Icons/MediaControl/MicrophoneIcon.tsx +43 -0
  81. package/src/Icons/MediaControl/MoveInIcon.tsx +51 -0
  82. package/src/Icons/MediaControl/MuteIcon.tsx +43 -0
  83. package/src/Icons/MediaControl/PauseIcon.tsx +37 -0
  84. package/src/Icons/MediaControl/PlayIcon.tsx +30 -0
  85. package/src/Icons/MediaControl/PreviousIcon.tsx +39 -0
  86. package/src/Icons/MediaControl/RecordingIcon.tsx +74 -0
  87. package/src/Icons/MediaControl/VolumeIcon.tsx +49 -0
  88. package/src/Icons/Miscellaneous/AddSeatIcon.tsx +29 -0
  89. package/src/Icons/Miscellaneous/AddUsersIcon.tsx +62 -0
  90. package/src/Icons/Miscellaneous/BillPdfIcon.tsx +29 -0
  91. package/src/Icons/Miscellaneous/BinocularIcon.tsx +31 -0
  92. package/src/Icons/Miscellaneous/BrainIcon.tsx +98 -0
  93. package/src/Icons/Miscellaneous/ChatBubbleIcon.tsx +60 -0
  94. package/src/Icons/Miscellaneous/ChatIcon.tsx +29 -0
  95. package/src/Icons/Miscellaneous/CheckoutIcon.tsx +29 -0
  96. package/src/Icons/Miscellaneous/ClipIcon.tsx +49 -0
  97. package/src/Icons/Miscellaneous/CreditCardIcon.tsx +29 -0
  98. package/src/Icons/Miscellaneous/DownloadIcon.tsx +29 -0
  99. package/src/Icons/Miscellaneous/EarthIcon.tsx +50 -0
  100. package/src/Icons/Miscellaneous/FaceCenterIcon.tsx +34 -0
  101. package/src/Icons/Miscellaneous/FaceRecognitionIcon.tsx +80 -0
  102. package/src/Icons/Miscellaneous/FilesIcon.tsx +43 -0
  103. package/src/Icons/Miscellaneous/FillRecordIcon.tsx +29 -0
  104. package/src/Icons/Miscellaneous/FolderIcon.tsx +31 -0
  105. package/src/Icons/Miscellaneous/GoogleIcon.tsx +59 -0
  106. package/src/Icons/Miscellaneous/HardDriveIcon.tsx +50 -0
  107. package/src/Icons/Miscellaneous/HelpIcon.tsx +29 -0
  108. package/src/Icons/Miscellaneous/LanguageIcon.tsx +27 -0
  109. package/src/Icons/Miscellaneous/LinkIcon.tsx +34 -0
  110. package/src/Icons/Miscellaneous/MetaAnalyseIcon.tsx +67 -0
  111. package/src/Icons/Miscellaneous/ModeratedIcon.tsx +80 -0
  112. package/src/Icons/Miscellaneous/NbOfUsersIcon.tsx +56 -0
  113. package/src/Icons/Miscellaneous/NeutralBackgroudIcon.tsx +34 -0
  114. package/src/Icons/Miscellaneous/ReportIcon.tsx +62 -0
  115. package/src/Icons/Miscellaneous/SeatIcon.tsx +29 -0
  116. package/src/Icons/Miscellaneous/SendEmailIcon.tsx +43 -0
  117. package/src/Icons/Miscellaneous/SendIcon.tsx +38 -0
  118. package/src/Icons/Miscellaneous/SmartBrainIcon.tsx +44 -0
  119. package/src/Icons/Miscellaneous/TasksIcon.tsx +48 -0
  120. package/src/Icons/Miscellaneous/TestDetailsIcon.tsx +29 -0
  121. package/src/Icons/Miscellaneous/TestIcon.tsx +38 -0
  122. package/src/Icons/Miscellaneous/UnmoderatedIcon.tsx +55 -0
  123. package/src/Icons/Notifications/AlamBellIdleIcon.tsx +46 -0
  124. package/src/Icons/Notifications/AlarmBellStatusIcon.tsx +54 -0
  125. package/src/Icons/Notifications/NotifAlertIcon.tsx +33 -0
  126. package/src/Icons/index.ts +108 -0
  127. package/src/Interviews/Chat.modules.scss +29 -0
  128. package/src/Interviews/Chat.tsx +123 -0
  129. package/src/Interviews/ChatInput.modules.scss +29 -0
  130. package/src/Interviews/ChatInput.tsx +33 -0
  131. package/src/Interviews/CircleIconButton.modules.scss +44 -0
  132. package/src/Interviews/CircledIconButton.tsx +31 -0
  133. package/src/Interviews/ControlsBar.modules.scss +15 -0
  134. package/src/Interviews/ControlsBar.tsx +101 -0
  135. package/src/Interviews/GoBack.modules.scss +14 -0
  136. package/src/Interviews/GoBack.tsx +22 -0
  137. package/src/Interviews/InterviewButton.modules.scss +107 -0
  138. package/src/Interviews/InterviewButton.tsx +45 -0
  139. package/src/Interviews/MarkUpBar.modules.scss +33 -0
  140. package/src/Interviews/MarkUpBar.tsx +40 -0
  141. package/src/Interviews/StartInterview.modules.scss +14 -0
  142. package/src/Interviews/StartInterview.tsx +27 -0
  143. package/src/Interviews/Task.modules.scss +179 -0
  144. package/src/Interviews/Task.tsx +176 -0
  145. package/src/Interviews/WelcomeMessage.modules.scss +29 -0
  146. package/src/Interviews/WelcomeMessage.tsx +33 -0
  147. package/src/LateralMenu/LateralMenu.modules.scss +21 -0
  148. package/src/LateralMenu/LateralMenu.tsx +23 -0
  149. package/src/Modal/Modal.modules.scss +58 -0
  150. package/src/Modal/Modal.tsx +135 -0
  151. package/src/MultiSelect/MultiSelect.scss +66 -0
  152. package/src/MultiSelect/MultiSelect.tsx +226 -0
  153. package/src/MultiSelect/utils/textInputStyle.ts +78 -0
  154. package/src/Notifications/Banner.modules.scss +35 -0
  155. package/src/Notifications/Banner.tsx +103 -0
  156. package/src/Notifications/NotificationIcon.scss +0 -0
  157. package/src/Notifications/NotificationIcon.tsx +26 -0
  158. package/src/Notifications/Toast.modules.scss +87 -0
  159. package/src/Notifications/Toast.tsx +92 -0
  160. package/src/Popover/Popover.modules.scss +47 -0
  161. package/src/Popover/Popover.tsx +77 -0
  162. package/src/Radio/Radio.module.scss +9 -0
  163. package/src/Radio/Radio.tsx +82 -0
  164. package/src/Search/Search.tsx +25 -0
  165. package/src/SingleSelect/SingleSelect.scss +62 -0
  166. package/src/SingleSelect/SingleSelect.tsx +209 -0
  167. package/src/Step/Step.module.scss +54 -0
  168. package/src/Step/Step.tsx +88 -0
  169. package/src/Switch/Switch.module.scss +5 -0
  170. package/src/Switch/Switch.tsx +51 -0
  171. package/src/Table/header.modules.scss +20 -0
  172. package/src/Table/header.tsx +74 -0
  173. package/src/Table/index.tsx +53 -0
  174. package/src/Table/rows.modules.scss +16 -0
  175. package/src/Table/rows.tsx +74 -0
  176. package/src/Table/table-cell.modules.scss +12 -0
  177. package/src/Table/table-cell.tsx +40 -0
  178. package/src/Tabs/Tabs.tsx +83 -0
  179. package/src/Tabs/TabsUnderLine.tsx +90 -0
  180. package/src/Tabs/tabs.modules.scss +60 -0
  181. package/src/Tabs/tabsUnderline.modules.scss +29 -0
  182. package/src/Tag/Tag.modules.scss +58 -0
  183. package/src/Tag/Tag.tsx +63 -0
  184. package/src/TextInput/TextInput.scss +50 -0
  185. package/src/TextInput/TextInput.tsx +212 -0
  186. package/src/Textarea/Textarea.module.scss +19 -0
  187. package/src/Textarea/Textarea.tsx +88 -0
  188. package/src/Tooltip/Layout/TooltipCustomLayout.module.scss +24 -0
  189. package/src/Tooltip/Layout/TooltipCustomLayout.tsx +104 -0
  190. package/src/Tooltip/Tooltip.tsx +139 -0
  191. package/src/Typography/{Caption.css → Caption.modules.scss} +5 -5
  192. package/src/Typography/Caption.tsx +8 -4
  193. package/src/Typography/Link.modules.scss +140 -0
  194. package/src/Typography/Link.tsx +73 -0
  195. package/src/Typography/Text.modules.scss +277 -0
  196. package/src/Typography/Text.tsx +38 -8
  197. package/src/Typography/{TextForButton.css → TextForButton.modules.scss} +8 -8
  198. package/src/Typography/TextForButton.tsx +15 -5
  199. package/src/Typography/{TextForDropDownItem.css → TextForDropDownItem.modules.scss} +11 -14
  200. package/src/Typography/TextForDropDownItem.tsx +14 -4
  201. package/src/Typography/TextWithLink.modules.scss +281 -0
  202. package/src/Typography/TextWithLink.tsx +65 -0
  203. package/src/Typography/{Title.css → Title.modules.scss} +27 -25
  204. package/src/Typography/Title.tsx +114 -16
  205. package/src/hooks/useClickOutside.ts +31 -0
  206. package/src/index.ts +34 -0
  207. package/dist/Buttons/Button.d.ts +0 -6
  208. package/dist/Color Guide/colors.d.ts +0 -6
  209. package/dist/Typography/Caption.d.ts +0 -12
  210. package/dist/Typography/Text.d.ts +0 -15
  211. package/dist/Typography/TextForButton.d.ts +0 -13
  212. package/dist/Typography/TextForDropDownItem.d.ts +0 -13
  213. package/dist/Typography/Title.d.ts +0 -14
  214. package/dist/index.d.ts +0 -6
  215. package/dist/index.js +0 -8
  216. package/dist/odaptos_design_system.cjs.development.css +0 -5
  217. package/dist/odaptos_design_system.cjs.development.js +0 -108
  218. package/dist/odaptos_design_system.cjs.development.js.map +0 -1
  219. package/dist/odaptos_design_system.cjs.production.min.js +0 -2
  220. package/dist/odaptos_design_system.cjs.production.min.js.map +0 -1
  221. package/dist/odaptos_design_system.esm.js +0 -97
  222. package/dist/odaptos_design_system.esm.js.map +0 -1
  223. package/src/Color Guide/colors.ts +0 -89
  224. package/src/Typography/Text.css +0 -272
@@ -0,0 +1,123 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './Chat.modules.scss';
3
+ import {
4
+ Text,
5
+ ChatInput,
6
+ StartInterview,
7
+ WelcomeMessage,
8
+ GoBack,
9
+ Task,
10
+ } from '../';
11
+ import Grid from '@mui/material/Grid';
12
+
13
+ interface TaskItem {
14
+ _id: string;
15
+ description: string;
16
+ notes: string;
17
+ timedTask: boolean;
18
+ totalSeconds: number;
19
+ successSeconds: number;
20
+ failureSeconds: number;
21
+ }
22
+
23
+ export interface ChatProps extends HTMLAttributes<HTMLDivElement> {
24
+ goBackText?: string;
25
+ goBack?: () => void;
26
+ chatTitle?: string;
27
+ welcomeTitle?: string;
28
+ welcomeDescription?: string;
29
+ startInterviewTitle?: string;
30
+ startInterviewBtnTitle?: string;
31
+ startInterviewIcon?: JSX.Element;
32
+ startInterview?: () => void;
33
+ tasks: TaskItem[];
34
+ sendTask: () => void;
35
+ currentTask: TaskItem;
36
+ chatInputPlaceholder?: string;
37
+ chatInputValue?: string;
38
+ chatInputonChange?: (message: string) => void;
39
+ className?: string;
40
+ }
41
+
42
+ export const Chat = ({
43
+ goBackText,
44
+ goBack,
45
+ chatTitle,
46
+ welcomeTitle,
47
+ welcomeDescription,
48
+ startInterviewTitle,
49
+ startInterviewBtnTitle,
50
+ startInterviewIcon,
51
+ startInterview,
52
+ tasks,
53
+ sendTask,
54
+ currentTask,
55
+ chatInputPlaceholder,
56
+ chatInputValue,
57
+ chatInputonChange,
58
+ className,
59
+ ...props
60
+ }: ChatProps) => {
61
+ return (
62
+ <Grid
63
+ container
64
+ item
65
+ xs={3}
66
+ direction="column"
67
+ className={`${className ?? ''} ${styles.chatContainer}`}
68
+ {...props}
69
+ >
70
+ {goBackText && goBack && <GoBack text={goBackText} onClick={goBack} />}
71
+ <div className={`${styles.scrolling_content} ${styles.no_scrollbar}`}>
72
+ {chatTitle && <Text text={chatTitle} weight="bold" size="lg" />}
73
+ {welcomeTitle && welcomeDescription && (
74
+ <WelcomeMessage
75
+ title={welcomeTitle}
76
+ description={welcomeDescription}
77
+ />
78
+ )}
79
+ {startInterviewTitle && startInterview && startInterviewBtnTitle && (
80
+ <StartInterview
81
+ title={startInterviewTitle}
82
+ buttonText={startInterviewBtnTitle}
83
+ buttonIcon={startInterviewIcon}
84
+ onClick={startInterview}
85
+ />
86
+ )}
87
+
88
+ {tasks.map((task, index) => {
89
+ const currentTaskIndex = tasks.findIndex(
90
+ (task) => task._id === currentTask._id
91
+ );
92
+ const isCompletedTask = index < currentTaskIndex;
93
+ return (
94
+ <Task
95
+ key={task._id}
96
+ taskNumber={`Task #${index + 1}`}
97
+ taskTitle={task.description}
98
+ notes={task.notes}
99
+ state={
100
+ isCompletedTask
101
+ ? 'disabled'
102
+ : currentTaskIndex === index
103
+ ? 'active'
104
+ : 'idle'
105
+ }
106
+ sendTask={sendTask}
107
+ isDone={isCompletedTask}
108
+ />
109
+ );
110
+ })}
111
+ </div>
112
+ {chatInputPlaceholder &&
113
+ typeof chatInputValue === 'string' &&
114
+ chatInputonChange && (
115
+ <ChatInput
116
+ placeholder={chatInputPlaceholder}
117
+ value={chatInputValue}
118
+ onChange={chatInputonChange}
119
+ />
120
+ )}
121
+ </Grid>
122
+ );
123
+ };
@@ -0,0 +1,29 @@
1
+ .chat_input_container {
2
+ margin-top: auto;
3
+ display: flex;
4
+ padding: 0.625rem 0.75rem;
5
+ flex-direction: row;
6
+ align-items: flex-start;
7
+ gap: 0.5rem;
8
+ align-self: stretch;
9
+ border-radius: 0.5rem;
10
+ background: var(--color-neutral-clear-shades-150, #eee);
11
+ input {
12
+ width: 100%;
13
+ background: var(--color-neutral-clear-shades-150, #eee);
14
+ border: none;
15
+ color: var(--color-neutral-dark-shades-950, #26292e);
16
+ font-family: Open Sans;
17
+ font-size: 1rem;
18
+ font-style: normal;
19
+ font-weight: 400;
20
+ line-height: 1.5rem;
21
+ }
22
+ input:focus {
23
+ outline: none;
24
+ }
25
+ input::placeholder {
26
+ color: var(--color-neutral-dark-shades-550, #8a8b8e);
27
+ opacity: 1;
28
+ }
29
+ }
@@ -0,0 +1,33 @@
1
+ import { SendEmailIcon } from '../';
2
+ import styles from './ChatInput.modules.scss';
3
+ interface ChatInputProps {
4
+ className?: string;
5
+ value: string;
6
+ placeholder: string;
7
+ onKeyDown?: () => void;
8
+ onChange: (event: any) => void;
9
+ }
10
+
11
+ export const ChatInput = ({
12
+ className,
13
+ value,
14
+ onChange,
15
+ onKeyDown,
16
+ placeholder,
17
+ }: ChatInputProps) => {
18
+ return (
19
+ <div className={`${styles.chat_input_container} ${className ?? ''}`}>
20
+ <input
21
+ placeholder={placeholder}
22
+ value={value ? value : ''}
23
+ onChange={onChange}
24
+ onKeyPress={(e) => {
25
+ if (e.key === 'Enter' && onKeyDown) {
26
+ onKeyDown();
27
+ }
28
+ }}
29
+ />
30
+ <SendEmailIcon fill="#8A8B8E" stroke="#8A8B8E" />
31
+ </div>
32
+ );
33
+ };
@@ -0,0 +1,44 @@
1
+ .circle_icon_button {
2
+ display: inline-flex;
3
+ padding: 0.5rem;
4
+ align-items: flex-start;
5
+ gap: 0.5rem;
6
+ border-radius: 1.5rem;
7
+ background: var(--color-neutral-dark-shades-700, #64666a);
8
+ box-shadow: 0px 4px 8px 3px rgba(0, 0, 0, 0.08),
9
+ 0px 1px 3px 0px rgba(0, 0, 0, 0.15);
10
+ border: none;
11
+ position: relative;
12
+ cursor: pointer;
13
+ svg {
14
+ width: 1.5rem;
15
+ height: 1.5rem;
16
+ stroke: #ffffff;
17
+ fill: #ffffff;
18
+ }
19
+
20
+ &:hover {
21
+ background: var(--color-neutral-dark-shades-550, #8a8b8e);
22
+ }
23
+ &:active {
24
+ background: var(--color-neutral-dark-shades-700, #64666a);
25
+ }
26
+ }
27
+
28
+ .active {
29
+ background: var(--color-primary-300, #66adff);
30
+ svg {
31
+ width: 1.5rem;
32
+ height: 1.5rem;
33
+ stroke: #00040a;
34
+ fill: #00040a;
35
+ }
36
+ }
37
+
38
+ .notif_icon {
39
+ position: absolute;
40
+ right: 0;
41
+ top: 0;
42
+ width: 0.75rem !important;
43
+ height: 0.75rem !important;
44
+ }
@@ -0,0 +1,31 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './CircleIconButton.modules.scss';
3
+ import { MeetingIcon, NotifAlertIcon } from '../';
4
+
5
+ export interface CircledIconButtonProps
6
+ extends HTMLAttributes<HTMLButtonElement> {
7
+ icon: JSX.Element;
8
+ className?: string;
9
+ isActive?: boolean;
10
+ isNotif?: boolean;
11
+ }
12
+
13
+ export const CircledIconButton = ({
14
+ icon,
15
+ className,
16
+ isActive = false,
17
+ isNotif = false,
18
+ ...props
19
+ }: CircledIconButtonProps) => {
20
+ return (
21
+ <button
22
+ className={`${styles.circle_icon_button} ${className ?? ''} ${
23
+ isActive ? styles.active : ''
24
+ }`}
25
+ {...props}
26
+ >
27
+ {icon ?? <MeetingIcon />}
28
+ {isNotif && <NotifAlertIcon className={styles.notif_icon} />}
29
+ </button>
30
+ );
31
+ };
@@ -0,0 +1,15 @@
1
+ .control_bar {
2
+ display: inline-flex;
3
+ align-items: center;
4
+ gap: 0.5rem;
5
+ .separator {
6
+ width: 0.0625rem;
7
+ height: 1rem;
8
+ background: var(--color-neutral-dark-shades-700, #64666a);
9
+ }
10
+ }
11
+ .chatBubbleIcon {
12
+ svg {
13
+ fill: transparent !important;
14
+ }
15
+ }
@@ -0,0 +1,101 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './ControlsBar.modules.scss';
3
+ import {
4
+ CircledIconButton,
5
+ ChatBubbleIcon,
6
+ InterviewButton,
7
+ MeetingIcon,
8
+ MicrophoneIcon,
9
+ TasksIcon,
10
+ TvFlatScreenIcon,
11
+ HangUpIcon,
12
+ } from '../';
13
+
14
+ export interface ControlsBarProps extends HTMLAttributes<HTMLDivElement> {
15
+ className?: string;
16
+ isInterviewer?: boolean;
17
+ isScreenShare?: boolean;
18
+ endInterview?: () => void;
19
+ enableScreenSharing?: () => void;
20
+ enableMicrophone?: () => void;
21
+ enableCamera?: () => void;
22
+ displayChat?: () => void;
23
+ displayTasks?: () => void;
24
+ isChatOpen?: boolean;
25
+ areTasksOpen?: boolean;
26
+ isNewTask?: boolean;
27
+ isNewMessage?: boolean;
28
+ }
29
+
30
+ export const ControlsBar = ({
31
+ className,
32
+ isInterviewer,
33
+ isScreenShare,
34
+ endInterview,
35
+ enableScreenSharing,
36
+ enableMicrophone,
37
+ enableCamera,
38
+ displayTasks,
39
+ isChatOpen,
40
+ areTasksOpen,
41
+ isNewTask,
42
+ isNewMessage,
43
+ ...props
44
+ }: ControlsBarProps) => {
45
+ return (
46
+ <div className={`${styles.control_bar} ${className ?? ''}`} {...props}>
47
+ <CircledIconButton
48
+ icon={<MicrophoneIcon />}
49
+ onClick={() => enableMicrophone()}
50
+ />
51
+ <CircledIconButton
52
+ icon={<MeetingIcon />}
53
+ onClick={() => enableCamera()}
54
+ />
55
+ <div className={styles.separator} />
56
+ {isInterviewer && (
57
+ <InterviewButton
58
+ text="End Interview"
59
+ variant="end-interview"
60
+ onClick={() => endInterview()}
61
+ icon={<HangUpIcon />}
62
+ />
63
+ )}
64
+ {!isInterviewer && !isScreenShare && (
65
+ <InterviewButton
66
+ text="ScreenShare"
67
+ variant="screenshare"
68
+ icon={<TvFlatScreenIcon />}
69
+ onClick={() => enableScreenSharing()}
70
+ />
71
+ )}
72
+ <div className={styles.separator} />
73
+ {isInterviewer ? (
74
+ <InterviewButton
75
+ text="Protocol"
76
+ variant="protocol"
77
+ icon={<TasksIcon />}
78
+ onClick={() => displayTasks()}
79
+ isActive={areTasksOpen}
80
+ isNotif={isNewTask}
81
+ />
82
+ ) : (
83
+ <InterviewButton
84
+ text="My Tasks"
85
+ variant="protocol"
86
+ icon={<TasksIcon />}
87
+ onClick={() => displayTasks()}
88
+ isActive={areTasksOpen}
89
+ isNotif={isNewTask}
90
+ />
91
+ )}
92
+ <CircledIconButton
93
+ icon={<ChatBubbleIcon />}
94
+ className={styles.chatBubbleIcon}
95
+ onClick={() => displayChat()}
96
+ isActive={isChatOpen}
97
+ isNotif={isNewMessage}
98
+ />
99
+ </div>
100
+ );
101
+ };
@@ -0,0 +1,14 @@
1
+ .go_back_btn {
2
+ display: flex;
3
+ align-items: center;
4
+ gap: 0.5rem;
5
+ border: none;
6
+ background-color: transparent;
7
+ cursor: pointer;
8
+ svg {
9
+ width: 0.75rem;
10
+ height: 0.75rem;
11
+ stroke: #8a8b8e;
12
+ fill: #8a8b8e;
13
+ }
14
+ }
@@ -0,0 +1,22 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './GoBack.modules.scss';
3
+ import { ArrowLineLeftIcon, Text } from '../';
4
+
5
+ export interface GoBackProps extends HTMLAttributes<HTMLButtonElement> {
6
+ text: string;
7
+ className?: string;
8
+ onClick: () => void;
9
+ }
10
+
11
+ export const GoBack = ({ text, onClick, className, ...props }: GoBackProps) => {
12
+ return (
13
+ <button
14
+ className={`${styles.go_back_btn} ${className ?? ''}`}
15
+ {...props}
16
+ onClick={onClick}
17
+ >
18
+ <ArrowLineLeftIcon />
19
+ <Text text={text} size="xs" weight="regular" color="#8A8B8E" />
20
+ </button>
21
+ );
22
+ };
@@ -0,0 +1,107 @@
1
+ .interview_button {
2
+ display: inline-flex;
3
+ padding: 0.375rem 0.75rem;
4
+ align-items: center;
5
+ gap: 0.5rem;
6
+ border-radius: 1.5rem;
7
+ box-shadow: 0px 4px 8px 3px rgba(0, 0, 0, 0.08),
8
+ 0px 1px 3px 0px rgba(0, 0, 0, 0.15);
9
+ border: none;
10
+ cursor: pointer;
11
+ position: relative;
12
+
13
+ svg {
14
+ height: 1.5rem;
15
+ width: 1.5rem;
16
+ }
17
+ }
18
+
19
+ .interview_button_screenshare {
20
+ background: var(--color-primary-500, #07f);
21
+
22
+ &:hover {
23
+ background: var(--color-primary-400, #3392ff);
24
+ }
25
+ &:active {
26
+ background: var(--color-primary-600, #005fcc);
27
+ }
28
+
29
+ p {
30
+ color: white !important;
31
+ }
32
+ svg {
33
+ stroke: white !important;
34
+ fill: white !important;
35
+ }
36
+ }
37
+
38
+ .interview_button_protocol {
39
+ background: var(--color-neutral-dark-shades-700, #64666a);
40
+ p {
41
+ color: white !important;
42
+ }
43
+ svg {
44
+ stroke: white !important;
45
+ fill: white !important;
46
+ }
47
+ &:hover {
48
+ background: var(--color-neutral-dark-shades-550, #8a8b8e);
49
+ p {
50
+ color: white !important;
51
+ }
52
+ svg {
53
+ stroke: white !important;
54
+ fill: white !important;
55
+ }
56
+ }
57
+ &:active {
58
+ background: var(--color-neutral-dark-shades-700, #64666a);
59
+
60
+ p {
61
+ color: var(--color-neutral-basics-black, #00040a) !important;
62
+ }
63
+ svg {
64
+ stroke: var(--color-neutral-basics-black, #00040a) !important;
65
+ fill: var(--color-neutral-basics-black, #00040a) !important;
66
+ }
67
+ }
68
+ }
69
+
70
+ .active {
71
+ background: var(--color-primary-300, #66adff);
72
+ p {
73
+ color: #00040a !important;
74
+ }
75
+ svg {
76
+ width: 1.5rem;
77
+ height: 1.5rem;
78
+ stroke: #00040a !important;
79
+ fill: #00040a !important;
80
+ }
81
+ }
82
+
83
+ .interview_button_end_interview {
84
+ background: var(--color-extended-red-500, #f54c4c);
85
+ &:hover {
86
+ background: var(--color-extended-red-400, #f77070);
87
+ }
88
+ &:active {
89
+ background: var(--color-extended-red-600, #c73f3d);
90
+ }
91
+
92
+ p {
93
+ color: var(--color-neutral-basics-black, #00040a) !important;
94
+ }
95
+ svg {
96
+ stroke: var(--color-neutral-basics-black, #00040a) !important;
97
+ fill: var(--color-neutral-basics-black, #00040a) !important;
98
+ }
99
+ }
100
+
101
+ .notif_icon {
102
+ position: absolute;
103
+ right: 0;
104
+ top: 0;
105
+ width: 0.75rem !important;
106
+ height: 0.75rem !important;
107
+ }
@@ -0,0 +1,45 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './InterviewButton.modules.scss';
3
+ import { MeetingIcon, NotifAlertIcon, Text } from '../';
4
+
5
+ export interface InterviewButtonProps
6
+ extends HTMLAttributes<HTMLButtonElement> {
7
+ icon: JSX.Element;
8
+ variant: 'screenshare' | 'end-interview' | 'protocol';
9
+ text: string;
10
+ isNotif?: boolean;
11
+ isActive?: boolean;
12
+ className?: string;
13
+ }
14
+
15
+ export const InterviewButton = ({
16
+ icon,
17
+ className,
18
+ variant,
19
+ text,
20
+ isNotif = false,
21
+ isActive = false,
22
+ ...props
23
+ }: InterviewButtonProps) => {
24
+ const defineVariantStyle = () => {
25
+ if (variant === 'protocol') return styles.interview_button_protocol;
26
+ else if (variant === 'screenshare')
27
+ return styles.interview_button_screenshare;
28
+ else if (variant === 'end-interview')
29
+ return styles.interview_button_end_interview;
30
+ else return;
31
+ };
32
+
33
+ return (
34
+ <button
35
+ className={`${styles.interview_button} ${defineVariantStyle()} ${
36
+ className ?? ''
37
+ } ${isActive ? styles.active : ''}`}
38
+ {...props}
39
+ >
40
+ {icon ?? <MeetingIcon />}
41
+ <Text text={text} size="base" weight="semi-bold" />
42
+ {isNotif && <NotifAlertIcon className={styles.notif_icon} />}
43
+ </button>
44
+ );
45
+ };
@@ -0,0 +1,33 @@
1
+ .markup_bar {
2
+ display: flex;
3
+ width: 27.5625rem;
4
+ justify-content: center;
5
+ align-items: flex-start;
6
+ gap: 0.75rem;
7
+
8
+ .smiley_list {
9
+ display: flex;
10
+ padding: 0.25rem 0.3125rem;
11
+ align-items: flex-start;
12
+ gap: 0.5rem;
13
+ border-radius: 1.5rem;
14
+ background: var(--color-neutral-dark-shades-900, #32353a);
15
+ }
16
+ .smiley_btn {
17
+ display: flex;
18
+ padding: 0.375rem;
19
+ align-items: center;
20
+ justify-content: center;
21
+ gap: 0.5rem;
22
+ border: none;
23
+ border-radius: 100%;
24
+ height: 2.25rem;
25
+ width: 2.25rem;
26
+ cursor: pointer;
27
+ background: var(--color-neutral-dark-shades-900, #32353a);
28
+ font-size: 1.5rem;
29
+ &:hover {
30
+ background: var(--color-neutral-dark-shades-800, #4b4e52);
31
+ }
32
+ }
33
+ }
@@ -0,0 +1,40 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './MarkUpBar.modules.scss';
3
+ import { MeetingIcon } from '../';
4
+
5
+ export interface MarkUpBarProps extends HTMLAttributes<HTMLButtonElement> {
6
+ className?: string;
7
+ onClick: (code: string) => void;
8
+ }
9
+
10
+ /**
11
+ * TODO : Be sure that we want to keep the 'QWERTY' selection system
12
+ */
13
+ export const MarkUpBar = ({ className, onClick, ...props }: MarkUpBarProps) => {
14
+ return (
15
+ <div className={`${styles.markup_bar} ${className ?? ''}`}>
16
+ <div className={styles.smiley_list}>
17
+ <button className={styles.smiley_btn} onClick={() => onClick('Y')}>
18
+ 🏳
19
+ </button>
20
+ </div>
21
+ <div className={styles.smiley_list}>
22
+ <button className={styles.smiley_btn} onClick={() => onClick('Q')}>
23
+ 😍
24
+ </button>
25
+ <button className={styles.smiley_btn} onClick={() => onClick('W')}>
26
+ 😮
27
+ </button>
28
+ <button className={styles.smiley_btn} onClick={() => onClick('E')}>
29
+ 😡
30
+ </button>
31
+ <button className={styles.smiley_btn} onClick={() => onClick('R')}>
32
+ 👍🏼
33
+ </button>
34
+ <button className={styles.smiley_btn} onClick={() => onClick('T')}>
35
+ 👎🏼
36
+ </button>
37
+ </div>
38
+ </div>
39
+ );
40
+ };
@@ -0,0 +1,14 @@
1
+ .start_interview_container {
2
+ display: flex;
3
+ padding: 0.5rem 0.75rem;
4
+ flex-direction: column;
5
+ align-items: flex-start;
6
+ align-self: stretch;
7
+ border-radius: 0.5rem;
8
+ border: 1px solid #66adff;
9
+ background: #e5f1ff;
10
+ gap: 0.5rem;
11
+ button {
12
+ width: 100%;
13
+ }
14
+ }
@@ -0,0 +1,27 @@
1
+ import { HTMLAttributes } from 'react';
2
+ import styles from './StartInterview.modules.scss';
3
+ import { Button, Text, SendIcon } from '../';
4
+
5
+ export interface StartInterviewProps extends HTMLAttributes<HTMLDivElement> {
6
+ title: string;
7
+ buttonText: string;
8
+ buttonIcon?: JSX.Element;
9
+ onClick: () => void;
10
+ className?: string;
11
+ }
12
+
13
+ export const StartInterview = ({
14
+ title,
15
+ buttonText,
16
+ buttonIcon,
17
+ onClick,
18
+ className,
19
+ ...props
20
+ }: StartInterviewProps) => {
21
+ return (
22
+ <div className={styles.start_interview_container} {...props}>
23
+ <Text text={title} weight="bold" />
24
+ <Button text={buttonText} iconRight={buttonIcon ?? <SendIcon />} />
25
+ </div>
26
+ );
27
+ };