allaw-ui 0.0.18 → 0.0.293

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 (162) hide show
  1. package/README.md +51 -2
  2. package/dist/app/globals.css +5 -0
  3. package/dist/components/atoms/buttons/ActionCircleButton.css +143 -0
  4. package/dist/components/atoms/buttons/ActionCircleButton.d.ts +9 -0
  5. package/dist/components/atoms/buttons/ActionCircleButton.js +23 -0
  6. package/dist/components/atoms/buttons/AgendaSlot.css +116 -0
  7. package/dist/components/atoms/buttons/AgendaSlot.d.ts +10 -0
  8. package/dist/components/atoms/buttons/AgendaSlot.js +7 -0
  9. package/dist/components/atoms/buttons/FavoriteToggle.css +35 -0
  10. package/dist/components/atoms/buttons/FavoriteToggle.d.ts +8 -0
  11. package/dist/components/atoms/buttons/FavoriteToggle.js +11 -0
  12. package/dist/components/atoms/buttons/FilterButton.css +55 -0
  13. package/dist/components/atoms/buttons/FilterButton.d.ts +9 -0
  14. package/dist/components/atoms/buttons/FilterButton.js +9 -0
  15. package/dist/components/atoms/buttons/GhostButton.css +63 -0
  16. package/dist/components/atoms/buttons/GhostButton.d.ts +14 -0
  17. package/dist/components/atoms/buttons/GhostButton.js +11 -0
  18. package/dist/components/atoms/buttons/IconButton.css +111 -0
  19. package/dist/components/atoms/buttons/IconButton.d.ts +10 -0
  20. package/dist/components/atoms/buttons/IconButton.js +14 -0
  21. package/dist/components/atoms/buttons/PendingDocuments.css +53 -0
  22. package/dist/components/atoms/buttons/PendingDocuments.d.ts +10 -0
  23. package/dist/components/atoms/buttons/PendingDocuments.js +13 -0
  24. package/dist/components/{buttons/ButtonPrimary.css → atoms/buttons/PrimaryButton.css} +11 -7
  25. package/dist/components/atoms/buttons/PrimaryButton.d.ts +15 -0
  26. package/dist/components/atoms/buttons/PrimaryButton.js +11 -0
  27. package/dist/components/atoms/buttons/SecondaryButton.css +123 -0
  28. package/dist/components/atoms/buttons/SecondaryButton.d.ts +14 -0
  29. package/dist/components/atoms/buttons/SecondaryButton.js +11 -0
  30. package/dist/components/atoms/buttons/TabNavigation.css +43 -0
  31. package/dist/components/atoms/buttons/TabNavigation.d.ts +13 -0
  32. package/dist/components/atoms/buttons/TabNavigation.js +10 -0
  33. package/dist/components/atoms/buttons/TertiaryButton.css +63 -0
  34. package/dist/components/atoms/buttons/TertiaryButton.d.ts +10 -0
  35. package/dist/components/atoms/buttons/TertiaryButton.js +10 -0
  36. package/dist/components/atoms/buttons/index.d.ts +18 -0
  37. package/dist/components/atoms/buttons/index.js +9 -0
  38. package/dist/components/atoms/checkboxes/Checkbox.css +50 -0
  39. package/dist/components/atoms/checkboxes/Checkbox.d.ts +10 -0
  40. package/dist/components/atoms/checkboxes/Checkbox.js +19 -0
  41. package/dist/components/atoms/checkboxes/index.d.ts +2 -0
  42. package/dist/components/atoms/checkboxes/index.js +1 -0
  43. package/dist/components/atoms/inputs/Input.css +185 -0
  44. package/dist/components/atoms/inputs/Input.d.ts +22 -0
  45. package/dist/components/atoms/inputs/Input.js +86 -0
  46. package/dist/components/atoms/inputs/SearchBar.css +54 -0
  47. package/dist/components/atoms/inputs/SearchBar.d.ts +12 -0
  48. package/dist/components/atoms/inputs/SearchBar.js +20 -0
  49. package/dist/components/atoms/inputs/index.d.ts +4 -0
  50. package/dist/components/atoms/inputs/index.js +2 -0
  51. package/dist/components/atoms/progressBars/ProgressBar.css +108 -0
  52. package/dist/components/atoms/progressBars/ProgressBar.d.ts +15 -0
  53. package/dist/components/atoms/progressBars/ProgressBar.js +17 -0
  54. package/dist/components/atoms/progressBars/index.d.ts +2 -0
  55. package/dist/components/atoms/progressBars/index.js +1 -0
  56. package/dist/components/atoms/radios/RadioButton.css +98 -0
  57. package/dist/components/atoms/radios/RadioButton.d.ts +11 -0
  58. package/dist/components/atoms/radios/RadioButton.js +10 -0
  59. package/dist/components/atoms/radios/index.d.ts +2 -0
  60. package/dist/components/atoms/radios/index.js +1 -0
  61. package/dist/components/atoms/selects/Select.css +103 -0
  62. package/dist/components/atoms/selects/Select.d.ts +22 -0
  63. package/dist/components/atoms/selects/Select.js +86 -0
  64. package/dist/components/atoms/selects/index.d.ts +2 -0
  65. package/dist/components/atoms/selects/index.js +1 -0
  66. package/dist/components/atoms/tags/AppointementStatusTag.css +158 -0
  67. package/dist/{tags → components/atoms/tags}/AppointementStatusTag.d.ts +1 -1
  68. package/dist/components/atoms/tags/FolderStatusTag.css +26 -0
  69. package/dist/components/atoms/tags/FolderStatusTag.d.ts +7 -0
  70. package/dist/components/atoms/tags/FolderStatusTag.js +8 -0
  71. package/dist/components/atoms/tags/OtherStatusTag.css +72 -0
  72. package/dist/components/atoms/tags/OtherStatusTag.d.ts +10 -0
  73. package/dist/components/atoms/tags/OtherStatusTag.js +10 -0
  74. package/dist/components/atoms/tags/index.d.ts +6 -0
  75. package/dist/components/atoms/tags/index.js +3 -0
  76. package/dist/components/atoms/typography/Heading.css +68 -0
  77. package/dist/components/atoms/typography/Heading.d.ts +9 -0
  78. package/dist/components/atoms/typography/Heading.js +7 -0
  79. package/dist/components/atoms/typography/Paragraph.css +43 -0
  80. package/dist/components/atoms/typography/Paragraph.d.ts +9 -0
  81. package/dist/components/atoms/typography/Paragraph.js +7 -0
  82. package/dist/components/atoms/typography/SmallTitle.css +53 -0
  83. package/dist/components/atoms/typography/SmallTitle.d.ts +9 -0
  84. package/dist/components/atoms/typography/SmallTitle.js +7 -0
  85. package/dist/components/atoms/typography/Subtitle.css +40 -0
  86. package/dist/components/atoms/typography/Subtitle.d.ts +9 -0
  87. package/dist/components/atoms/typography/Subtitle.js +7 -0
  88. package/dist/components/atoms/typography/TinyInfo.css +56 -0
  89. package/dist/components/atoms/typography/TinyInfo.d.ts +9 -0
  90. package/dist/components/atoms/typography/TinyInfo.js +8 -0
  91. package/dist/components/atoms/typography/index.d.ts +10 -0
  92. package/dist/components/atoms/typography/index.js +5 -0
  93. package/dist/components/atoms/uiVariables/BorderRadius.d.ts +6 -0
  94. package/dist/components/atoms/uiVariables/BorderRadius.js +12 -0
  95. package/dist/components/atoms/uiVariables/BorderRadiusExample.css +31 -0
  96. package/dist/components/atoms/uiVariables/Shadows.d.ts +6 -0
  97. package/dist/components/atoms/uiVariables/Shadows.js +11 -0
  98. package/dist/components/atoms/uiVariables/ShadowsExample.css +27 -0
  99. package/dist/components/atoms/uiVariables/Strokes.d.ts +6 -0
  100. package/dist/components/atoms/uiVariables/Strokes.js +10 -0
  101. package/dist/components/atoms/uiVariables/StrokesExample.css +22 -0
  102. package/dist/components/atoms/uiVariables/index.d.ts +3 -0
  103. package/dist/components/atoms/uiVariables/index.js +3 -0
  104. package/dist/components/molecules/appointmentSlot/AppointmentSlot.css +366 -0
  105. package/dist/components/molecules/appointmentSlot/AppointmentSlot.d.ts +25 -0
  106. package/dist/components/molecules/appointmentSlot/AppointmentSlot.js +109 -0
  107. package/dist/components/molecules/appointmentSlot/TestClic.css +19 -0
  108. package/dist/components/molecules/appointmentSlot/TestClic.d.ts +4 -0
  109. package/dist/components/molecules/appointmentSlot/TestClic.js +28 -0
  110. package/dist/components/molecules/appointmentSlot/index.d.ts +2 -0
  111. package/dist/components/molecules/appointmentSlot/index.js +1 -0
  112. package/dist/components/molecules/caseCard/CaseCard.css +119 -0
  113. package/dist/components/molecules/caseCard/CaseCard.d.ts +14 -0
  114. package/dist/components/molecules/caseCard/CaseCard.js +20 -0
  115. package/dist/components/molecules/caseCard/index.d.ts +2 -0
  116. package/dist/components/molecules/caseCard/index.js +1 -0
  117. package/dist/components/molecules/checkboxForm/CheckboxForm.css +22 -0
  118. package/dist/components/molecules/checkboxForm/CheckboxForm.d.ts +11 -0
  119. package/dist/components/molecules/checkboxForm/CheckboxForm.js +15 -0
  120. package/dist/components/molecules/checkboxForm/index.d.ts +2 -0
  121. package/dist/components/molecules/checkboxForm/index.js +1 -0
  122. package/dist/components/molecules/contactCard/ContactCard.css +386 -0
  123. package/dist/components/molecules/contactCard/ContactCard.d.ts +17 -0
  124. package/dist/components/molecules/contactCard/ContactCard.js +80 -0
  125. package/dist/components/molecules/contactCard/index.d.ts +2 -0
  126. package/dist/components/molecules/contactCard/index.js +1 -0
  127. package/dist/components/molecules/documentCard/DocumentCard.css +130 -0
  128. package/dist/components/molecules/documentCard/DocumentCard.d.ts +14 -0
  129. package/dist/components/molecules/documentCard/DocumentCard.js +59 -0
  130. package/dist/components/molecules/documentCard/index.d.ts +2 -0
  131. package/dist/components/molecules/documentCard/index.js +1 -0
  132. package/dist/components/molecules/employeeCard/EmployeeCard.css +187 -0
  133. package/dist/components/molecules/employeeCard/EmployeeCard.d.ts +15 -0
  134. package/dist/components/molecules/employeeCard/EmployeeCard.js +34 -0
  135. package/dist/components/molecules/employeeCard/index.d.ts +2 -0
  136. package/dist/components/molecules/employeeCard/index.js +1 -0
  137. package/dist/components/molecules/stepper/Stepper.css +80 -0
  138. package/dist/components/molecules/stepper/Stepper.d.ts +27 -0
  139. package/dist/components/molecules/stepper/Stepper.js +66 -0
  140. package/dist/components/molecules/stepper/index.d.ts +2 -0
  141. package/dist/components/molecules/stepper/index.js +1 -0
  142. package/dist/index.d.ts +36 -2
  143. package/dist/index.js +52 -2
  144. package/dist/styles/colors.css +2 -0
  145. package/dist/styles/global.css +9 -0
  146. package/dist/styles/ui-variables/border-radius.css +6 -0
  147. package/dist/styles/ui-variables/shadows.css +5 -0
  148. package/dist/styles/ui-variables/stroke.css +4 -0
  149. package/dist/utils/regex.d.ts +5 -0
  150. package/dist/utils/regex.js +7 -0
  151. package/package.json +36 -16
  152. package/dist/buttons/ButtonPrimary.d.ts +0 -10
  153. package/dist/buttons/ButtonPrimary.js +0 -10
  154. package/dist/components/buttons/ButtonPrimary.d.ts +0 -11
  155. package/dist/components/buttons/ButtonPrimary.js +0 -11
  156. package/dist/components/tags/AppointementStatusTag.css +0 -58
  157. package/dist/components/tags/AppointementStatusTag.d.ts +0 -8
  158. package/dist/stories/button.css +0 -30
  159. package/dist/stories/header.css +0 -32
  160. package/dist/stories/page.css +0 -69
  161. package/dist/tags/AppointementStatusTag.js +0 -41
  162. /package/dist/components/{tags → atoms/tags}/AppointementStatusTag.js +0 -0
@@ -0,0 +1,130 @@
1
+ @import "../../../styles/colors.css";
2
+
3
+ .document-card {
4
+ display: flex;
5
+ width: 404px;
6
+ padding: 16px;
7
+ justify-content: space-between;
8
+ align-items: flex-start;
9
+ border-radius: 8px;
10
+ border: 1px solid var(--venom-grey, #e6edf5);
11
+ background: var(--Primary-Blanc, #fff);
12
+ box-shadow: 0px 1px 9px 0px rgba(15, 133, 168, 0.08);
13
+ }
14
+
15
+ .document-card-left {
16
+ display: flex;
17
+ align-items: center;
18
+ gap: 8px;
19
+ align-self: stretch;
20
+ }
21
+
22
+ .document-card-info {
23
+ display: flex;
24
+ flex-direction: column;
25
+ align-items: flex-start;
26
+ gap: 11px;
27
+ align-self: stretch;
28
+ }
29
+
30
+ .document-card-type {
31
+ color: var(--Tags-Mid-grey, var(--light-grey, #728ea7));
32
+ font-family: "Open Sans", sans-serif;
33
+ font-size: 12px;
34
+ font-style: normal;
35
+ font-weight: 600;
36
+ line-height: 8px;
37
+ text-transform: uppercase;
38
+ }
39
+
40
+ .document-card-title {
41
+ color: var(--Primary-Mid-black, var(--primary-black, #171e25));
42
+ font-family: "Open Sans", sans-serif;
43
+ font-size: 16px;
44
+ font-style: normal;
45
+ font-weight: 600;
46
+ line-height: normal;
47
+ }
48
+
49
+ .document-card-date {
50
+ color: var(--Tags-Mid-grey, var(--light-grey, #728ea7));
51
+ font-family: Inter, sans-serif;
52
+ font-size: 14px;
53
+ font-style: normal;
54
+ font-weight: 600;
55
+ line-height: 10px;
56
+ }
57
+
58
+ .document-card-right {
59
+ display: flex;
60
+ height: 64px;
61
+ flex-direction: column;
62
+ justify-content: space-between;
63
+ align-items: flex-end;
64
+ }
65
+
66
+ /* Styles spécifiques pour le type "waiting" */
67
+ .document-card.waiting {
68
+ width: 425px;
69
+ padding: 16px 16px 12px 16px;
70
+ }
71
+
72
+ .document-card.waiting .document-card-left {
73
+ flex-direction: column;
74
+ align-items: flex-start;
75
+ gap: 11px;
76
+ }
77
+
78
+ .document-card.waiting .document-card-title {
79
+ font-weight: 400;
80
+ line-height: 16px;
81
+ padding-top: 10px;
82
+ }
83
+
84
+ .document-card.waiting .document-list {
85
+ display: flex;
86
+ flex-direction: column;
87
+ align-items: flex-start;
88
+ padding-left: 8px;
89
+ /* padding-top:; */
90
+ }
91
+
92
+ .document-card.waiting .document-bullet {
93
+ display: inline-block;
94
+ width: 4px;
95
+ height: 4px;
96
+ border-radius: 50%;
97
+ background-color: var(--Primary-Mid-black, var(--primary-black, #171e25));
98
+ margin-right: 8px;
99
+ vertical-align: middle;
100
+ }
101
+
102
+ .document-card.waiting .document-label {
103
+ color: var(--Primary-Mid-black, var(--primary-black, #171e25));
104
+ font-family: "Open Sans", sans-serif;
105
+ font-size: 14px;
106
+ font-style: normal;
107
+ font-weight: 400;
108
+ line-height: 16px;
109
+ letter-spacing: -0.03px;
110
+ margin-bottom: 1px;
111
+ display: flex;
112
+ align-items: center;
113
+ }
114
+
115
+ .document-card.waiting .document-card-right {
116
+ display: flex;
117
+ flex-direction: row;
118
+ align-items: center;
119
+ gap: 8px;
120
+ height: auto;
121
+ }
122
+
123
+ .document-card.waiting .document-count {
124
+ color: var(--Tags-Rouge, #e15151);
125
+ font-family: Inter, sans-serif;
126
+ font-size: 14px;
127
+ font-style: normal;
128
+ font-weight: 600;
129
+ line-height: normal;
130
+ }
@@ -0,0 +1,14 @@
1
+ import React from "react";
2
+ import "./DocumentCard.css";
3
+ export interface DocumentCardProps {
4
+ type: "document" | "note" | "invoice" | "waiting";
5
+ title: string;
6
+ date: Date;
7
+ status: "sent" | "received";
8
+ documents?: {
9
+ [key: string]: boolean;
10
+ };
11
+ documentCount?: string;
12
+ }
13
+ declare const DocumentCard: React.FC<DocumentCardProps>;
14
+ export default DocumentCard;
@@ -0,0 +1,59 @@
1
+ import React from "react";
2
+ import "./DocumentCard.css";
3
+ import IconButton from "../../atoms/buttons/IconButton";
4
+ import OtherStatusTag from "../../atoms/tags/OtherStatusTag";
5
+ var DocumentCard = function (_a) {
6
+ var type = _a.type, title = _a.title, date = _a.date, status = _a.status, _b = _a.documents, documents = _b === void 0 ? {} : _b, _c = _a.documentCount, documentCount = _c === void 0 ? "" : _c;
7
+ var getIconName = function () {
8
+ switch (type) {
9
+ case "document":
10
+ return "allaw-icon-edit-2";
11
+ case "note":
12
+ return "allaw-icon-document";
13
+ case "invoice":
14
+ return "allaw-icon-file";
15
+ case "waiting":
16
+ return "allaw-icon-clock";
17
+ default:
18
+ return "allaw-icon-document";
19
+ }
20
+ };
21
+ var getDisplayType = function (type) {
22
+ if (type === "invoice") {
23
+ return "FACTURE";
24
+ }
25
+ return type.toUpperCase();
26
+ };
27
+ var formatDate = function (date) {
28
+ return date.toLocaleDateString("fr-FR", {
29
+ day: "2-digit",
30
+ month: "2-digit",
31
+ year: "2-digit",
32
+ });
33
+ };
34
+ if (type === "waiting") {
35
+ var documentList = Object.keys(documents);
36
+ return (React.createElement("div", { className: "document-card waiting" },
37
+ React.createElement("div", { className: "document-card-left" },
38
+ React.createElement(OtherStatusTag, { type: "information", label: "Documents demand\u00E9s pour ce rendez-vous" }),
39
+ React.createElement("h3", { className: "document-card-title" }, title),
40
+ React.createElement("div", { className: "document-list" },
41
+ React.createElement("ul", null, documentList.map(function (doc, index) { return (React.createElement("li", { key: index, className: "document-label" },
42
+ React.createElement("span", { className: "document-bullet" }),
43
+ " ",
44
+ doc)); })))),
45
+ React.createElement("div", { className: "document-card-right" },
46
+ React.createElement(IconButton, { style: "smallFilled", iconName: "allaw-icon-document" }),
47
+ React.createElement("span", { className: "document-count" }, documentCount))));
48
+ }
49
+ return (React.createElement("div", { className: "document-card" },
50
+ React.createElement("div", { className: "document-card-left" },
51
+ React.createElement(IconButton, { style: "largeFilled", iconName: getIconName() }),
52
+ React.createElement("div", { className: "document-card-info" },
53
+ React.createElement("span", { className: "document-card-type" }, getDisplayType(type)),
54
+ React.createElement("h3", { className: "document-card-title" }, title),
55
+ React.createElement("span", { className: "document-card-date" }, formatDate(date)))),
56
+ React.createElement("div", { className: "document-card-right" },
57
+ React.createElement(OtherStatusTag, { type: "information", label: status === "sent" ? "ENVOYÉ" : "REÇU" }))));
58
+ };
59
+ export default DocumentCard;
@@ -0,0 +1,2 @@
1
+ export { default as DocumentCard } from "./DocumentCard";
2
+ export type { DocumentCardProps } from "./DocumentCard";
@@ -0,0 +1 @@
1
+ export { default as DocumentCard } from "./DocumentCard";
@@ -0,0 +1,187 @@
1
+ @import "../../../styles/colors.css";
2
+
3
+ .employee-card {
4
+ font-family: "Open Sans", sans-serif;
5
+ border-radius: 16px;
6
+ border: 1px solid var(--venom-grey, #e6edf5);
7
+ background: var(--Primary-Blanc, #fff);
8
+ }
9
+
10
+ .employee-card.small {
11
+ display: flex;
12
+ width: 260px;
13
+ padding: 14px;
14
+ justify-content: space-between;
15
+ align-items: flex-end;
16
+ }
17
+
18
+ .employee-card.large {
19
+ display: flex;
20
+ flex-direction: row;
21
+ justify-content: space-between;
22
+ width: 1143px;
23
+ padding: 24px;
24
+ align-items: flex-start;
25
+ gap: 56px;
26
+ }
27
+
28
+ .employee-card .content {
29
+ display: flex;
30
+ align-items: center;
31
+ gap: 16px;
32
+ align-self: stretch;
33
+ }
34
+
35
+ .employee-card .profile-image-container {
36
+ position: relative;
37
+ display: flex;
38
+ justify-content: center;
39
+ align-items: center;
40
+ }
41
+
42
+ .employee-card.small .profile-image {
43
+ width: 66px;
44
+ height: 66px;
45
+ border-radius: 64px;
46
+ border: 2.37px solid var(--venom-grey, #e6edf5);
47
+ }
48
+
49
+ .employee-card.large .profile-image {
50
+ width: 94px;
51
+ height: 94px;
52
+ border-radius: 94px;
53
+ border: 2px solid var(--venom-grey, #e6edf5);
54
+ }
55
+
56
+ .employee-card .verified-icon {
57
+ position: absolute;
58
+ width: 35px;
59
+ height: 35px;
60
+ font-size: 28px;
61
+ color: var(--bleu-allaw);
62
+ }
63
+
64
+ .employee-card.small .verified-icon {
65
+ left: 46px;
66
+ top: 42px;
67
+ }
68
+
69
+ .employee-card.large .verified-icon {
70
+ left: 65px;
71
+ top: 71px;
72
+ }
73
+
74
+ .content-main-container {
75
+ display: flex;
76
+ flex-direction: column;
77
+ align-items: flex-start;
78
+ justify-content: flex-start;
79
+ align-self: stretch;
80
+ padding-left: 38px;
81
+ }
82
+
83
+ .employee-card .name-tag-container {
84
+ display: flex;
85
+ flex-direction: column;
86
+ justify-content: center;
87
+ align-items: flex-start;
88
+ gap: 12px;
89
+ padding-bottom: 6px;
90
+ }
91
+
92
+ .employee-card.large .name-tag-container {
93
+ display: flex;
94
+ flex-direction: row;
95
+ justify-content: center;
96
+ align-items: flex-start;
97
+ gap: 12px;
98
+ padding-bottom: 6px;
99
+ }
100
+
101
+ .employee-card.small .name {
102
+ color: var(--Primary-Mid-black, #171e25);
103
+ font-family: "Open Sans";
104
+ font-size: 16px;
105
+ font-style: normal;
106
+ font-weight: 600;
107
+ line-height: normal;
108
+ }
109
+
110
+ .employee-card.large .name {
111
+ color: var(--Primary-Mid-black, #171e25);
112
+ font-family: Poppins;
113
+ font-size: 24px;
114
+ font-style: normal;
115
+ font-weight: 600;
116
+ line-height: 30px;
117
+ }
118
+
119
+ .role-container {
120
+ display: flex;
121
+ flex-direction: row;
122
+ align-items: center;
123
+ justify-content: center;
124
+ padding-left: 14px;
125
+ }
126
+
127
+ .employee-card.large .content-container {
128
+ display: flex;
129
+ flex-direction: column;
130
+ justify-content: center;
131
+ align-items: flex-start;
132
+ gap: 24px;
133
+ flex: 1 0 0;
134
+ align-self: stretch;
135
+ padding-top: 6px;
136
+ }
137
+
138
+ .employee-card.large .contact-container {
139
+ display: flex;
140
+ flex-direction: column;
141
+ align-items: flex-start;
142
+ gap: 14px;
143
+ align-self: stretch;
144
+ }
145
+
146
+ .employee-card.large .contact-label {
147
+ color: var(--Tags-Mid-grey, #728ea7);
148
+ font-family: "Open Sans";
149
+ font-size: 12px;
150
+ font-style: normal;
151
+ font-weight: 600;
152
+ line-height: 0px;
153
+ padding-top: 12px;
154
+ }
155
+
156
+ .employee-card.large .phone-email-container {
157
+ display: flex;
158
+ flex-direction: row;
159
+ align-items: flex-start;
160
+ justify-content: center;
161
+ padding-top: 8px;
162
+ padding-left: 32px;
163
+ gap: 52px;
164
+ line-height: 16px;
165
+ }
166
+
167
+ .employee-card.large .phone-number {
168
+ color: var(--Primary-Dark-grey, #456073);
169
+ font-family: Inter;
170
+ font-size: 16px;
171
+ font-style: normal;
172
+ font-weight: 500;
173
+ line-height: 21px;
174
+ }
175
+
176
+ .employee-card.large .email {
177
+ color: var(--Primary-Dark-grey, #456073);
178
+ font-family: "Open Sans";
179
+ font-size: 16px;
180
+ font-style: normal;
181
+ font-weight: 400;
182
+ line-height: 22px;
183
+ display: flex;
184
+ flex-direction: row;
185
+ padding-bottom: 0px;
186
+ justify-content: center;
187
+ }
@@ -0,0 +1,15 @@
1
+ import React from "react";
2
+ import "./EmployeeCard.css";
3
+ export interface EmployeeCardProps {
4
+ name: string;
5
+ role: string;
6
+ contactNumber: string;
7
+ email1: string;
8
+ email2: string;
9
+ profileImage: string;
10
+ isVerified: boolean;
11
+ size: "small" | "large";
12
+ onEdit: () => void;
13
+ }
14
+ declare const EmployeeCard: React.FC<EmployeeCardProps>;
15
+ export default EmployeeCard;
@@ -0,0 +1,34 @@
1
+ import React from "react";
2
+ import "./EmployeeCard.css";
3
+ import OtherStatusTag from "../../atoms/tags/OtherStatusTag";
4
+ import IconButton from "../../atoms/buttons/IconButton";
5
+ import Image from "next/image";
6
+ var NoPhoto = "/assets/NoPhoto.png";
7
+ var EmployeeCard = function (_a) {
8
+ var name = _a.name, role = _a.role, contactNumber = _a.contactNumber, email1 = _a.email1, email2 = _a.email2, profileImage = _a.profileImage, isVerified = _a.isVerified, size = _a.size, onEdit = _a.onEdit;
9
+ var renderProfileImage = function () { return (React.createElement("div", { className: "profile-image-container" },
10
+ React.createElement(Image, { src: profileImage || NoPhoto, alt: name, width: size === "small" ? 64 : 94, height: size === "small" ? 64 : 94, className: "profile-image" }),
11
+ isVerified && (React.createElement("span", { className: "verified-icon allaw-icon-verified" })))); };
12
+ var renderNameAndRole = function () { return (React.createElement("div", { className: "name-tag-container" },
13
+ React.createElement("h3", { className: "name" }, name),
14
+ React.createElement("div", { className: "role-container" },
15
+ React.createElement(OtherStatusTag, { label: role, type: "information" })))); };
16
+ var renderContactInfo = function () { return (React.createElement("div", { className: "contact-container" },
17
+ React.createElement("span", { className: "contact-label" }, "CONTACT"),
18
+ React.createElement("div", { className: "phone-email-container" },
19
+ React.createElement("span", { className: "phone-number" }, contactNumber),
20
+ React.createElement("span", { className: "email" }, email1),
21
+ React.createElement("span", { className: "email" }, email2)))); };
22
+ var renderSmallCard = function () { return (React.createElement("div", { className: "content" },
23
+ renderProfileImage(),
24
+ renderNameAndRole())); };
25
+ var renderLargeCard = function () { return (React.createElement(React.Fragment, null,
26
+ React.createElement("div", { className: "content" },
27
+ renderProfileImage(),
28
+ React.createElement("div", { className: "content-main-container" },
29
+ renderNameAndRole(),
30
+ React.createElement("div", { className: "content-container" }, renderContactInfo()))),
31
+ React.createElement(IconButton, { style: "largeFilled", iconName: "allaw-icon-edit-2", onClick: onEdit }))); };
32
+ return (React.createElement("div", { className: "employee-card ".concat(size) }, size === "small" ? renderSmallCard() : renderLargeCard()));
33
+ };
34
+ export default EmployeeCard;
@@ -0,0 +1,2 @@
1
+ export { default as EmployeeCard } from "./EmployeeCard";
2
+ export type { EmployeeCardProps } from "./EmployeeCard";
@@ -0,0 +1 @@
1
+ export { default as EmployeeCard } from "./EmployeeCard";
@@ -0,0 +1,80 @@
1
+ .stepper-container {
2
+ display: flex;
3
+ width: 559px;
4
+ padding: 48px;
5
+ flex-direction: column;
6
+ justify-content: center;
7
+ align-items: center;
8
+ gap: 16px;
9
+ border-radius: 16px;
10
+ background: #fff;
11
+ box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
12
+ position: relative;
13
+ z-index: 1001;
14
+ }
15
+
16
+ .stepper-content {
17
+ margin: 20px 0;
18
+ width: 100%;
19
+ }
20
+
21
+ .stepper-buttons {
22
+ display: flex;
23
+ flex-direction: row;
24
+ justify-content: space-between;
25
+ align-items: center;
26
+ width: 100%;
27
+ gap: 16px;
28
+ }
29
+
30
+ .stepper-buttons.no-buttons {
31
+ display: none;
32
+ }
33
+
34
+ .stepper-button-container {
35
+ display: flex;
36
+ justify-content: center;
37
+ align-items: center;
38
+ }
39
+
40
+ .secondary-button-container {
41
+ width: 38.2%;
42
+ }
43
+
44
+ .secondary-button-container.hidden,
45
+ .primary-button-container.hidden {
46
+ display: none;
47
+ }
48
+
49
+ .primary-button-container {
50
+ width: 61.8%;
51
+ }
52
+
53
+ .stepper-buttons .primary-button-container:only-child {
54
+ width: 100%;
55
+ }
56
+
57
+ .stepper-overlay {
58
+ position: fixed;
59
+ top: 0;
60
+ left: 0;
61
+ width: 100%;
62
+ height: 100%;
63
+ background: rgba(0, 0, 0, 0.5);
64
+ z-index: 1000;
65
+ display: flex;
66
+ justify-content: center;
67
+ align-items: center;
68
+ }
69
+
70
+ .stepper-content {
71
+ width: 100%;
72
+ display: flex;
73
+ justify-content: center;
74
+ align-items: center;
75
+ font-family: "Open Sans", sans-serif;
76
+ font-size: 16px;
77
+ font-weight: 400;
78
+ line-height: 24px;
79
+ letter-spacing: 0em;
80
+ }
@@ -0,0 +1,27 @@
1
+ import React from "react";
2
+ import "./Stepper.css";
3
+ import "../../../styles/global.css";
4
+ import "../../../styles/icons.css";
5
+ export interface StepperProps {
6
+ steps: number;
7
+ currentStep: number;
8
+ startIcon?: boolean[];
9
+ endIcon?: boolean;
10
+ children: React.ReactNode[];
11
+ secondaryButton?: {
12
+ show: boolean;
13
+ label: string;
14
+ icon: string;
15
+ onSecondaryButtonClick?: (step: number) => void;
16
+ }[];
17
+ primaryButton?: {
18
+ show: boolean;
19
+ label: string;
20
+ onPrimaryButtonClick?: (step: number) => void;
21
+ }[];
22
+ showProgressBar?: boolean[];
23
+ onClose?: () => void;
24
+ validateStep?: (step: number) => boolean;
25
+ }
26
+ declare const Stepper: React.FC<StepperProps>;
27
+ export default Stepper;
@@ -0,0 +1,66 @@
1
+ import React, { useState, useEffect, useCallback } from "react";
2
+ import ReactDOM from "react-dom";
3
+ import "./Stepper.css";
4
+ import "../../../styles/global.css";
5
+ import "../../../styles/icons.css";
6
+ import ProgressBar from "../../atoms/progressBars/ProgressBar";
7
+ import PrimaryButton from "../../atoms/buttons/PrimaryButton";
8
+ import SecondaryButton from "../../atoms/buttons/SecondaryButton";
9
+ var Stepper = function (_a) {
10
+ var steps = _a.steps, currentStep = _a.currentStep, _b = _a.startIcon, startIcon = _b === void 0 ? [] : _b, _c = _a.endIcon, endIcon = _c === void 0 ? true : _c, children = _a.children, _d = _a.secondaryButton, secondaryButton = _d === void 0 ? [] : _d, _e = _a.primaryButton, primaryButton = _e === void 0 ? [] : _e, _f = _a.showProgressBar, showProgressBar = _f === void 0 ? [] : _f, onClose = _a.onClose, validateStep = _a.validateStep;
11
+ var _g = useState(currentStep), step = _g[0], setStep = _g[1];
12
+ var _h = useState(null), portalContainer = _h[0], setPortalContainer = _h[1];
13
+ useEffect(function () {
14
+ var container = document.createElement("div");
15
+ document.body.appendChild(container);
16
+ setPortalContainer(container);
17
+ return function () {
18
+ document.body.removeChild(container);
19
+ };
20
+ }, []);
21
+ useEffect(function () {
22
+ setStep(currentStep);
23
+ }, [currentStep]);
24
+ var handleNext = useCallback(function () {
25
+ console.log("Stepper: Validating current step");
26
+ var currentPrimaryButton = primaryButton[step - 1];
27
+ if (currentPrimaryButton === null || currentPrimaryButton === void 0 ? void 0 : currentPrimaryButton.onPrimaryButtonClick) {
28
+ currentPrimaryButton.onPrimaryButtonClick(step);
29
+ }
30
+ if (validateStep) {
31
+ var isValid = validateStep(step);
32
+ console.log("Stepper: Step ".concat(step, " validation result - ").concat(isValid ? "valid" : "invalid"));
33
+ if (!isValid) {
34
+ return;
35
+ }
36
+ }
37
+ if (step < steps) {
38
+ setStep(step + 1);
39
+ }
40
+ else if (step === steps && onClose) {
41
+ onClose();
42
+ }
43
+ }, [step, steps, validateStep, primaryButton, onClose]);
44
+ var handlePrevious = useCallback(function () {
45
+ if (step > 1) {
46
+ setStep(step - 1);
47
+ }
48
+ }, [step]);
49
+ var currentSecondaryButton = secondaryButton[step - 1];
50
+ var currentPrimaryButton = primaryButton[step - 1];
51
+ var currentShowProgressBar = showProgressBar[step - 1] !== false;
52
+ var currentShowStartIcon = startIcon[step - 1];
53
+ var stepperContent = (React.createElement("div", { className: "stepper-overlay", onClick: onClose },
54
+ React.createElement("div", { className: "stepper-container", onClick: function (e) { return e.stopPropagation(); } },
55
+ React.createElement(ProgressBar, { steps: steps, currentStep: step, startIcon: currentShowStartIcon, endIcon: endIcon, onStartIconClick: handlePrevious, onEndIconClick: onClose, showProgressBar: currentShowProgressBar }),
56
+ React.createElement("div", { className: "stepper-content" }, children[step - 1]),
57
+ React.createElement("div", { className: "stepper-buttons ".concat(!(currentSecondaryButton === null || currentSecondaryButton === void 0 ? void 0 : currentSecondaryButton.show) && !(currentPrimaryButton === null || currentPrimaryButton === void 0 ? void 0 : currentPrimaryButton.show) ? "no-buttons" : "") },
58
+ (currentSecondaryButton === null || currentSecondaryButton === void 0 ? void 0 : currentSecondaryButton.show) && (React.createElement("div", { className: "stepper-button-container secondary-button-container" },
59
+ React.createElement(SecondaryButton, { label: currentSecondaryButton.label, startIcon: currentSecondaryButton.icon, onClick: function () { var _a; return (_a = currentSecondaryButton.onSecondaryButtonClick) === null || _a === void 0 ? void 0 : _a.call(currentSecondaryButton, step); } }))),
60
+ (currentPrimaryButton === null || currentPrimaryButton === void 0 ? void 0 : currentPrimaryButton.show) && (React.createElement("div", { className: "stepper-button-container primary-button-container" },
61
+ React.createElement(PrimaryButton, { label: currentPrimaryButton.label, onClick: handleNext })))))));
62
+ return portalContainer
63
+ ? ReactDOM.createPortal(stepperContent, portalContainer)
64
+ : null;
65
+ };
66
+ export default Stepper;
@@ -0,0 +1,2 @@
1
+ export { default as Stepper } from "./Stepper";
2
+ export type { StepperProps } from "./Stepper";
@@ -0,0 +1 @@
1
+ export { default as Stepper } from "./Stepper";
package/dist/index.d.ts CHANGED
@@ -1,2 +1,36 @@
1
- export { default as Button } from "./components/buttons/ButtonPrimary";
2
- export { default as Tag } from "./components/tags/AppointementStatusTag";
1
+ export { default as Button } from "./components/atoms/buttons/PrimaryButton";
2
+ export { default as FavoriteToggle } from "./components/atoms/buttons/FavoriteToggle";
3
+ export { default as FilterButton } from "./components/atoms/buttons/FilterButton";
4
+ export { default as GhostButton } from "./components/atoms/buttons/GhostButton";
5
+ export { default as IconButton } from "./components/atoms/buttons/IconButton";
6
+ export { default as PendingDocuments } from "./components/atoms/buttons/PendingDocuments";
7
+ export { default as PrimaryButton } from "./components/atoms/buttons/PrimaryButton";
8
+ export { default as SecondaryButton } from "./components/atoms/buttons/SecondaryButton";
9
+ export { default as TabNavigation } from "./components/atoms/buttons/TabNavigation";
10
+ export { default as TertiaryButton } from "./components/atoms/buttons/TertiaryButton";
11
+ export { default as Checkbox } from "./components/atoms/checkboxes/Checkbox";
12
+ export { default as Input } from "./components/atoms/inputs/Input";
13
+ export type { InputProps, InputRef } from "./components/atoms/inputs/Input";
14
+ export { default as SearchBar } from "./components/atoms/inputs/SearchBar";
15
+ export { default as ProgressBar } from "./components/atoms/progressBars/ProgressBar";
16
+ export { default as RadioButton } from "./components/atoms/radios/RadioButton";
17
+ export { default as Select } from "./components/atoms/selects/Select";
18
+ export type { SelectItem, SelectProps, SelectRef, } from "./components/atoms/selects/Select";
19
+ export { default as AppointementStatusTag } from "./components/atoms/tags/AppointementStatusTag";
20
+ export { default as FolderStatusTag } from "./components/atoms/tags/FolderStatusTag";
21
+ export { default as OtherStatusTag } from "./components/atoms/tags/OtherStatusTag";
22
+ export { default as Heading } from "./components/atoms/typography/Heading";
23
+ export { default as Paragraph } from "./components/atoms/typography/Paragraph";
24
+ export { default as SmallTitle } from "./components/atoms/typography/SmallTitle";
25
+ export { default as Subtitle } from "./components/atoms/typography/Subtitle";
26
+ export { default as TinyInfo } from "./components/atoms/typography/TinyInfo";
27
+ export { default as BorderRadius } from "./components/atoms/uiVariables/BorderRadius";
28
+ export { default as Shadows } from "./components/atoms/uiVariables/Shadows";
29
+ export { default as Strokes } from "./components/atoms/uiVariables/Strokes";
30
+ export { default as AppointmentSlot } from "./components/molecules/appointmentSlot/AppointmentSlot";
31
+ export { default as CaseCard } from "./components/molecules/caseCard/CaseCard";
32
+ export { default as ContactCard } from "./components/molecules/contactCard/ContactCard";
33
+ export { default as DocumentCard } from "./components/molecules/documentCard/DocumentCard";
34
+ export { default as EmployeeCard } from "./components/molecules/employeeCard/EmployeeCard";
35
+ export { default as Stepper } from "./components/molecules/stepper/Stepper";
36
+ export { default as CheckboxForm } from "./components/molecules/checkboxForm/CheckboxForm";