react-weekly-planning 1.0.29 → 1.0.31

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 (53) hide show
  1. package/__tests__/page.test.js +106 -46
  2. package/__tests__/page.test.tsx +117 -45
  3. package/babel.config.js +1 -0
  4. package/components/AddTask/index.js +17 -17
  5. package/components/AddTask/index.tsx +4 -0
  6. package/components/CalendarForWeek.js +50 -0
  7. package/components/{CalendarTable.tsx → CalendarForWeek.tsx} +49 -39
  8. package/components/CalendarForday.js +34 -0
  9. package/components/CalendarForday.tsx +130 -0
  10. package/components/DayContainer/index.js +15 -15
  11. package/components/DayContainer/index.tsx +1 -0
  12. package/components/GroupContainer/index.js +15 -15
  13. package/components/GroupContainer/index.tsx +1 -0
  14. package/components/GroupsHeadContainer/index.js +9 -9
  15. package/components/SumHoursContainer/index.js +16 -15
  16. package/components/SumHoursContainer/index.tsx +2 -1
  17. package/components/SumHoursHead/index.js +9 -9
  18. package/components/TaskContainer/index.js +35 -35
  19. package/components/TaskContainer/index.tsx +1 -1
  20. package/components/TaskList/index.js +5 -0
  21. package/components/TaskList/index.tsx +20 -0
  22. package/contexts/CalendarContext.js +12 -12
  23. package/contexts/CalendarContext.tsx +4 -0
  24. package/definitions/index.js +1 -1
  25. package/definitions/index.ts +644 -4
  26. package/docs/global.html +4982 -4982
  27. package/docs/index.html +474 -474
  28. package/docs/index.ts.html +121 -121
  29. package/docs/scripts/linenumber.js +26 -26
  30. package/docs/scripts/search.js +38 -38
  31. package/docs/styles/iframe.css +12 -12
  32. package/docs/styles/prettify-jsdoc.css +111 -111
  33. package/docs/styles/prettify-tomorrow.css +132 -132
  34. package/docs/styles/reset.css +44 -44
  35. package/hooks/useCalendarDateState.js +19 -13
  36. package/hooks/useCalendarDateState.ts +28 -8
  37. package/index.js +70 -52
  38. package/index.tsx +57 -41
  39. package/jest.config.js +9 -9
  40. package/lib/slyles.js +21 -21
  41. package/lib/slyles.ts +1 -1
  42. package/lib/utils.js +640 -317
  43. package/lib/utils.ts +588 -14
  44. package/out/index.html +128 -128
  45. package/out/scripts/linenumber.js +26 -26
  46. package/out/scripts/search.js +38 -38
  47. package/out/styles/iframe.css +12 -12
  48. package/out/styles/prettify-jsdoc.css +111 -111
  49. package/out/styles/prettify-tomorrow.css +132 -132
  50. package/out/styles/reset.css +44 -44
  51. package/package.json +81 -71
  52. package/style.css +26 -4
  53. package/components/CalendarTable.js +0 -48
@@ -1,132 +1,132 @@
1
- /* Tomorrow Theme */
2
- /* Original theme - https://github.com/chriskempson/tomorrow-theme */
3
- /* Pretty printing styles. Used with prettify.js. */
4
- /* SPAN elements with the classes below are added by prettyprint. */
5
- /* plain text */
6
- .pln {
7
- color: #4d4d4c; }
8
-
9
- @media screen {
10
- /* string content */
11
- .str {
12
- color: #718c00; }
13
-
14
- /* a keyword */
15
- .kwd {
16
- color: #8959a8; }
17
-
18
- /* a comment */
19
- .com {
20
- color: #8e908c; }
21
-
22
- /* a type name */
23
- .typ {
24
- color: #4271ae; }
25
-
26
- /* a literal value */
27
- .lit {
28
- color: #f5871f; }
29
-
30
- /* punctuation */
31
- .pun {
32
- color: #4d4d4c; }
33
-
34
- /* lisp open bracket */
35
- .opn {
36
- color: #4d4d4c; }
37
-
38
- /* lisp close bracket */
39
- .clo {
40
- color: #4d4d4c; }
41
-
42
- /* a markup tag name */
43
- .tag {
44
- color: #c82829; }
45
-
46
- /* a markup attribute name */
47
- .atn {
48
- color: #f5871f; }
49
-
50
- /* a markup attribute value */
51
- .atv {
52
- color: #3e999f; }
53
-
54
- /* a declaration */
55
- .dec {
56
- color: #f5871f; }
57
-
58
- /* a variable name */
59
- .var {
60
- color: #c82829; }
61
-
62
- /* a function name */
63
- .fun {
64
- color: #4271ae; } }
65
- /* Use higher contrast and text-weight for printable form. */
66
- @media print, projection {
67
- .str {
68
- color: #060; }
69
-
70
- .kwd {
71
- color: #006;
72
- font-weight: bold; }
73
-
74
- .com {
75
- color: #600;
76
- font-style: italic; }
77
-
78
- .typ {
79
- color: #404;
80
- font-weight: bold; }
81
-
82
- .lit {
83
- color: #044; }
84
-
85
- .pun, .opn, .clo {
86
- color: #440; }
87
-
88
- .tag {
89
- color: #006;
90
- font-weight: bold; }
91
-
92
- .atn {
93
- color: #404; }
94
-
95
- .atv {
96
- color: #060; } }
97
- /* Style */
98
- /*
99
- pre.prettyprint {
100
- background: white;
101
- font-family: Consolas, Monaco, 'Andale Mono', monospace;
102
- font-size: 12px;
103
- line-height: 1.5;
104
- border: 1px solid #ccc;
105
- padding: 10px; }
106
- */
107
-
108
- /* Specify class=linenums on a pre to get line numbering */
109
- ol.linenums {
110
- margin-top: 0;
111
- margin-bottom: 0; }
112
-
113
- /* IE indents via margin-left */
114
- li.L0,
115
- li.L1,
116
- li.L2,
117
- li.L3,
118
- li.L4,
119
- li.L5,
120
- li.L6,
121
- li.L7,
122
- li.L8,
123
- li.L9 {
124
- /* */ }
125
-
126
- /* Alternate shading for lines */
127
- li.L1,
128
- li.L3,
129
- li.L5,
130
- li.L7,
131
- li.L9 {
132
- /* */ }
1
+ /* Tomorrow Theme */
2
+ /* Original theme - https://github.com/chriskempson/tomorrow-theme */
3
+ /* Pretty printing styles. Used with prettify.js. */
4
+ /* SPAN elements with the classes below are added by prettyprint. */
5
+ /* plain text */
6
+ .pln {
7
+ color: #4d4d4c; }
8
+
9
+ @media screen {
10
+ /* string content */
11
+ .str {
12
+ color: #718c00; }
13
+
14
+ /* a keyword */
15
+ .kwd {
16
+ color: #8959a8; }
17
+
18
+ /* a comment */
19
+ .com {
20
+ color: #8e908c; }
21
+
22
+ /* a type name */
23
+ .typ {
24
+ color: #4271ae; }
25
+
26
+ /* a literal value */
27
+ .lit {
28
+ color: #f5871f; }
29
+
30
+ /* punctuation */
31
+ .pun {
32
+ color: #4d4d4c; }
33
+
34
+ /* lisp open bracket */
35
+ .opn {
36
+ color: #4d4d4c; }
37
+
38
+ /* lisp close bracket */
39
+ .clo {
40
+ color: #4d4d4c; }
41
+
42
+ /* a markup tag name */
43
+ .tag {
44
+ color: #c82829; }
45
+
46
+ /* a markup attribute name */
47
+ .atn {
48
+ color: #f5871f; }
49
+
50
+ /* a markup attribute value */
51
+ .atv {
52
+ color: #3e999f; }
53
+
54
+ /* a declaration */
55
+ .dec {
56
+ color: #f5871f; }
57
+
58
+ /* a variable name */
59
+ .var {
60
+ color: #c82829; }
61
+
62
+ /* a function name */
63
+ .fun {
64
+ color: #4271ae; } }
65
+ /* Use higher contrast and text-weight for printable form. */
66
+ @media print, projection {
67
+ .str {
68
+ color: #060; }
69
+
70
+ .kwd {
71
+ color: #006;
72
+ font-weight: bold; }
73
+
74
+ .com {
75
+ color: #600;
76
+ font-style: italic; }
77
+
78
+ .typ {
79
+ color: #404;
80
+ font-weight: bold; }
81
+
82
+ .lit {
83
+ color: #044; }
84
+
85
+ .pun, .opn, .clo {
86
+ color: #440; }
87
+
88
+ .tag {
89
+ color: #006;
90
+ font-weight: bold; }
91
+
92
+ .atn {
93
+ color: #404; }
94
+
95
+ .atv {
96
+ color: #060; } }
97
+ /* Style */
98
+ /*
99
+ pre.prettyprint {
100
+ background: white;
101
+ font-family: Consolas, Monaco, 'Andale Mono', monospace;
102
+ font-size: 12px;
103
+ line-height: 1.5;
104
+ border: 1px solid #ccc;
105
+ padding: 10px; }
106
+ */
107
+
108
+ /* Specify class=linenums on a pre to get line numbering */
109
+ ol.linenums {
110
+ margin-top: 0;
111
+ margin-bottom: 0; }
112
+
113
+ /* IE indents via margin-left */
114
+ li.L0,
115
+ li.L1,
116
+ li.L2,
117
+ li.L3,
118
+ li.L4,
119
+ li.L5,
120
+ li.L6,
121
+ li.L7,
122
+ li.L8,
123
+ li.L9 {
124
+ /* */ }
125
+
126
+ /* Alternate shading for lines */
127
+ li.L1,
128
+ li.L3,
129
+ li.L5,
130
+ li.L7,
131
+ li.L9 {
132
+ /* */ }
@@ -1,44 +1,44 @@
1
- /* reset css */
2
- html, body, div, span, applet, object, iframe,
3
- h1, h2, h3, h4, h5, h6, p, blockquote, pre,
4
- a, abbr, acronym, address, big, cite, code,
5
- del, dfn, em, img, ins, kbd, q, s, samp,
6
- small, strike, strong, sub, sup, tt, var,
7
- b, u, i, center,
8
- dl, dt, dd, ol, ul, li,
9
- fieldset, form, label, legend,
10
- table, caption, tbody, tfoot, thead, tr, th, td,
11
- article, aside, canvas, details, embed,
12
- figure, figcaption, footer, header, hgroup,
13
- menu, nav, output, ruby, section, summary,
14
- time, mark, audio, video {
15
- margin: 0;
16
- padding: 0;
17
- border: 0;
18
- font-size: 100%;
19
- font: inherit;
20
- vertical-align: baseline;
21
- }
22
- /* HTML5 display-role reset for older browsers */
23
- article, aside, details, figcaption, figure,
24
- footer, header, hgroup, menu, nav, section {
25
- display: block;
26
- }
27
- body {
28
- line-height: 1;
29
- }
30
- ol, ul {
31
- list-style: none;
32
- }
33
- blockquote, q {
34
- quotes: none;
35
- }
36
- blockquote:before, blockquote:after,
37
- q:before, q:after {
38
- content: '';
39
- content: none;
40
- }
41
- table {
42
- border-collapse: collapse;
43
- border-spacing: 0;
44
- }
1
+ /* reset css */
2
+ html, body, div, span, applet, object, iframe,
3
+ h1, h2, h3, h4, h5, h6, p, blockquote, pre,
4
+ a, abbr, acronym, address, big, cite, code,
5
+ del, dfn, em, img, ins, kbd, q, s, samp,
6
+ small, strike, strong, sub, sup, tt, var,
7
+ b, u, i, center,
8
+ dl, dt, dd, ol, ul, li,
9
+ fieldset, form, label, legend,
10
+ table, caption, tbody, tfoot, thead, tr, th, td,
11
+ article, aside, canvas, details, embed,
12
+ figure, figcaption, footer, header, hgroup,
13
+ menu, nav, output, ruby, section, summary,
14
+ time, mark, audio, video {
15
+ margin: 0;
16
+ padding: 0;
17
+ border: 0;
18
+ font-size: 100%;
19
+ font: inherit;
20
+ vertical-align: baseline;
21
+ }
22
+ /* HTML5 display-role reset for older browsers */
23
+ article, aside, details, figcaption, figure,
24
+ footer, header, hgroup, menu, nav, section {
25
+ display: block;
26
+ }
27
+ body {
28
+ line-height: 1;
29
+ }
30
+ ol, ul {
31
+ list-style: none;
32
+ }
33
+ blockquote, q {
34
+ quotes: none;
35
+ }
36
+ blockquote:before, blockquote:after,
37
+ q:before, q:after {
38
+ content: '';
39
+ content: none;
40
+ }
41
+ table {
42
+ border-collapse: collapse;
43
+ border-spacing: 0;
44
+ }
@@ -1,13 +1,19 @@
1
- import { useEffect, useState } from "react";
2
- import { calculerEcartSemaine, getDayHourly, getWeekDays } from "../lib/utils";
3
- function useCalendarDateState(date, weekOffset) {
4
- const [calendarDateState, setCalendarDateState] = useState({ dailyHours: [], weekDays: [] });
5
- useEffect(() => {
6
- const weekOffsetByDate = calculerEcartSemaine(date);
7
- const weekDays = getWeekDays(weekOffsetByDate || weekOffset || 0);
8
- const dailyHours = getDayHourly(weekOffsetByDate || weekOffset || 0);
9
- setCalendarDateState({ dailyHours: dailyHours, weekDays });
10
- }, [date, weekOffset]);
11
- return Object.assign({}, calendarDateState);
12
- }
13
- export default useCalendarDateState;
1
+ import { useEffect, useState } from "react";
2
+ import { calculerEcartSemaine, getDateObjectInTimeZone, getDayHourly, getWeekDays, } from "../lib/utils";
3
+ function useCalendarDateState(date, weekOffset, timeZone) {
4
+ const [calendarDateState, setCalendarDateState] = useState({ dailyHours: [], weekDays: [] });
5
+ useEffect(() => {
6
+ const weekOffsetByDate = timeZone
7
+ ? calculerEcartSemaine(getDateObjectInTimeZone(timeZone))
8
+ : calculerEcartSemaine(date);
9
+ const weekDays = getWeekDays(weekOffsetByDate || weekOffset || 0);
10
+ const dailyHours = getDayHourly(weekOffsetByDate || weekOffset || 0);
11
+ const calData = {
12
+ dailyHours: dailyHours,
13
+ weekDays,
14
+ };
15
+ setCalendarDateState(calData);
16
+ }, [date, weekOffset]);
17
+ return Object.assign({}, calendarDateState);
18
+ }
19
+ export default useCalendarDateState;
@@ -1,24 +1,44 @@
1
1
  import { useEffect, useState } from "react";
2
- import { calculerEcartSemaine, getDayHourly, getWeekDays } from "../lib/utils";
3
- import { dailyHoursType, weekDaysType } from "../definitions";
2
+ import {
3
+ calculerEcartSemaine,
4
+ getDateObjectInTimeZone,
5
+ getDayHourly,
6
+ getWeekDays,
7
+ saveTasksToLocalStorage,
8
+ } from "../lib/utils";
9
+ import {
10
+ dailyHoursType,
11
+ TasksType,
12
+ TimeZone,
13
+ weekDaysType,
14
+ } from "../definitions";
4
15
 
5
- function useCalendarDateState(date: Date, weekOffset: number | undefined) {
16
+ function useCalendarDateState(
17
+ date: Date,
18
+ weekOffset: number | undefined,
19
+ timeZone: TimeZone | undefined
20
+ ) {
6
21
  const [calendarDateState, setCalendarDateState] = useState<{
7
22
  weekDays: weekDaysType;
8
23
  dailyHours: dailyHoursType;
9
24
  }>({ dailyHours: [], weekDays: [] });
10
25
 
11
26
  useEffect(() => {
12
-
13
- const weekOffsetByDate = calculerEcartSemaine(date);
27
+ const weekOffsetByDate = timeZone
28
+ ? calculerEcartSemaine(getDateObjectInTimeZone(timeZone))
29
+ : calculerEcartSemaine(date);
30
+
14
31
  const weekDays = getWeekDays(weekOffsetByDate || weekOffset || 0);
15
32
  const dailyHours = getDayHourly(weekOffsetByDate || weekOffset || 0);
16
- setCalendarDateState({ dailyHours: dailyHours, weekDays });
17
-
33
+ const calData = {
34
+ dailyHours: dailyHours,
35
+ weekDays,
36
+ };
37
+
38
+ setCalendarDateState(calData);
18
39
  }, [date, weekOffset]);
19
40
 
20
41
  return { ...calendarDateState };
21
42
  }
22
43
 
23
44
  export default useCalendarDateState;
24
-
package/index.js CHANGED
@@ -1,52 +1,70 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
2
- import "./style.css";
3
- import CalendarTable from "./components/CalendarTable";
4
- /**
5
- * Calendar component to display tasks and groups in a weekly view.
6
- *
7
- * @param {Object} props - The props for the Calendar component.
8
- * @param {React.CSSProperties} [props.style] - Additional styles for the calendar component.
9
- * @param {string} [props.className] - Additional class names for the calendar component.
10
- * @param {Array} props.groups - Array of group data to be displayed in the calendar.
11
- * @param {number} [props.weekOffset] - Offset for the week (e.g., -1 for last week, 0 for current week, 1 for next week).
12
- * @param {Date} props.date - The current date to display in the calendar.
13
- * @param {Function} [props.groupRender] - Custom render function for a group.
14
- * @param {Function} [props.dayRender] - Custom render function for a day.
15
- * @param {React.CSSProperties} [props.rowsStyle] - Additional styles for the rows.
16
- * @param {React.CSSProperties} [props.groupsColsStyle] - Additional styles for the group columns.
17
- * @param {React.CSSProperties} [props.daysColsStyle] - Additional styles for the day columns.
18
- * @param {Function} [props.addTaskRender] - Custom render function for the add task button.
19
- * @param {Function} [props.handleAddTask] - Handler function for adding a new task.
20
- * @param {string} [props.dayClassName] - Additional class names for the days.
21
- * @param {React.CSSProperties} [props.dayStyle] - Additional styles for the days.
22
- * @param {string} [props.groupClassName] - Additional class names for the groups.
23
- * @param {React.CSSProperties} [props.groupStyle] - Additional styles for the groups.
24
- * @param {string} [props.addTaskClassName] - Additional class names for the add task button.
25
- * @param {React.CSSProperties} [props.addTaskStyle] - Additional styles for the add task button.
26
- * @param {Array} props.tasks - Array of tasks to be displayed in the calendar.
27
- * @param {Function} [props.handleDragTask] - Handler function for dragging a task.
28
- * @param {Function} [props.handleDropTask] - Handler function for dropping a task.
29
- * @param {Function} [props.taskRender] - Custom render function for a task.
30
- * @param {Function} [props.groupsHeadRender] - Custom render function for the groups header.
31
- * @param {Function} [props.sumHoursRender] - Custom render function for the sum of hours.
32
- * @param {Function} [props.sumHoursHeadRender] - Custom render function for the sum of hours header.
33
- * @param {Function} [props.handleDragTaskEnd] - Handler function for ending the drag of a task.
34
- * @param {string} [props.rowsClassName] - Additional class names for the rows.
35
- * @param {string} [props.daysColsClassName] - Additional class names for the day columns.
36
- * @param {string} [props.sumHoursContainerClassName] - Additional class names for the sum hours container.
37
- * @param {React.CSSProperties} [props.sumHoursContainerStyle] - Additional styles for the sum hours container.
38
- * @param {string} [props.groupHeadContainerClassName] - Additional class names for the group head container.
39
- * @param {React.CSSProperties} [props.groupHeadContainerStyle] - Additional styles for the group head container.
40
- * @param {string} [props.groupsColsClassName] - Additional class names for the group columns.
41
- * @param {string} [props.taskContainerClassName] - Additional class names for the task container.
42
- * @param {React.CSSProperties} [props.taskContainerStyle] - Additional styles for the task container.
43
- * @param {string} [props.sumHoursHeadClassName] - Additional class names for the sum hours header.
44
- * @param {React.CSSProperties} [props.sumHoursHeadStyle] - Additional styles for the sum hours header.
45
- * @param {Function} [props.handleClickGroup] - Handler function for clicking a group.
46
- * @param {Function} [props.handleClickTask] - Handler function for clicking a task.
47
- * @returns {JSX.Element} The rendered Calendar component.
48
- */
49
- const Calendar = (props) => {
50
- return (_jsx(CalendarTable, Object.assign({}, props)));
51
- };
52
- export default Calendar;
1
+ import { jsx as _jsx, Fragment as _Fragment } from "react/jsx-runtime";
2
+ import "./style.css";
3
+ import CalendarForWeek from "./components/CalendarForWeek";
4
+ import CalendarForDay from "./components/CalendarForday";
5
+ /**
6
+ * Calendar component to display tasks and groups in a weekly view.
7
+ *
8
+ * @param {CalendarPropsType} props - The props for the Calendar component.
9
+ * @param {number} [props.weekOffset] - Offset for the week (e.g., -7 for last week, 0 for current week, 7 for next week).
10
+ * @param {GroupFeildsType[]} props.groups - Array of group data to be displayed in the calendar.
11
+ * @param {string} [props.className] - Additional class names for the calendar component.
12
+ * @param {React.CSSProperties} [props.style] - Additional styles for the calendar component.
13
+ * @param {Date} props.date - The current date to display in the calendar.
14
+ * @param {(currentGroup: { currentGroup: GroupFeildsType }) => React.ReactNode} [props.groupRender] - Custom render function for a group.
15
+ * @param {({ dayIndex, day, dayOfTheMonth, dayMonth, dayYear }: { dayIndex: number; day: string; dayOfTheMonth: number; dayMonth: string; dayYear: number }) => React.ReactNode} [props.dayRender] - Custom render function for a day.
16
+ * @param {(currentTask: { currentTask: TaskFeildsType }) => React.ReactNode} [props.taskRender] - Custom render function for a task.
17
+ * @param {React.CSSProperties} [props.rowsStyle] - Additional styles for the rows.
18
+ * @param {string} [props.rowsClassName] - Additional class names for the rows.
19
+ * @param {React.CSSProperties} [props.groupsColsStyle] - Additional styles for the group columns.
20
+ * @param {string} [props.groupsColsClassName] - Additional class names for the group columns.
21
+ * @param {React.CSSProperties} [props.daysColsStyle] - Additional styles for the day columns.
22
+ * @param {string} [props.daysColsClassName] - Additional class names for the day columns.
23
+ * @param {string} [props.addTaskClassName] - Additional class names for the add-task button.
24
+ * @param {React.CSSProperties} [props.addTaskStyle] - Additional styles for the add-task button.
25
+ * @param {string} [props.groupContainerClassName] - Additional class names for the group containers.
26
+ * @param {React.CSSProperties} [props.groupContainerStyle] - Additional styles for the group containers.
27
+ * @param {string} [props.dayClassName] - Additional class names for the day elements.
28
+ * @param {React.CSSProperties} [props.dayStyle] - Additional styles for the day elements.
29
+ * @param {React.CSSProperties} [props.taskContainerStyle] - Additional styles for the task container.
30
+ * @param {string} [props.taskContainerClassName] - Additional class names for the task container.
31
+ * @param {React.CSSProperties} [props.groupHeadContainerStyle] - Additional styles for the group header container.
32
+ * @param {string} [props.groupHeadContainerClassName] - Additional class names for the group header container.
33
+ * @param {React.CSSProperties} [props.sumHoursContainerStyle] - Additional styles for the sum-of-hours container.
34
+ * @param {string} [props.sumHoursContainerClassName] - Additional class names for the sum-of-hours container.
35
+ * @param {React.CSSProperties} [props.sumHoursHeadStyle] - Additional styles for the sum-of-hours header.
36
+ * @param {string} [props.sumHoursHeadClassName] - Additional class names for the sum-of-hours header.
37
+ * @param {(currentGroup: GroupFeildsType, dayInfo: dayInfoType) => void} [props.handleAddTask] - Handler function for adding a new task.
38
+ * @param {({ currentGroup, dayInfo }: { currentGroup: GroupFeildsType; dayInfo: dayInfoType }) => React.ReactNode} [props.addTaskRender] - Custom render function for adding a task.
39
+ * @param {TasksType} props.tasks - Array of tasks to be displayed in the calendar.
40
+ * @param {(event: React.DragEvent<HTMLDivElement>, currentTask: TaskFeildsType) => void} [props.handleDragTask] - Handler function for dragging a task.
41
+ * @param {(event: React.DragEvent<HTMLDivElement>, taskStart: number, taskEnd: number, taskDate: Date, groupId: string, dayIndex: number, newTask: TaskFeildsType, newTasks: TasksType) => void} [props.handleDropTask] - Handler function for dropping a task.
42
+ * @param {(event: React.DragEvent<HTMLDivElement>) => void} [props.handleDragTaskEnd] - Handler function for ending the drag of a task.
43
+ * @param {() => React.ReactNode} [props.groupsHeadRender] - Custom render function for the groups header.
44
+ * @param {({
45
+ * groupId,
46
+ * tasks,
47
+ * weekOffset,
48
+ * calendarDate,
49
+ * sumHoursByGroups
50
+ * }: {
51
+ * groupId: string;
52
+ * tasks: TasksType;
53
+ * weekOffset: number;
54
+ * calendarDate: Date;
55
+ * sumHoursByGroups: number;
56
+ * }) => React.ReactNode} [props.sumHoursRender] - Custom render function for the sum of hours.
57
+ * @param {() => React.ReactNode} [props.sumHoursHeadRender] - Custom render function for the sum-of-hours header.
58
+ * @param {(currentTask: TaskFeildsType) => void} [props.handleClickTask] - Handler function for clicking a task.
59
+ * @param {(currentGroup: GroupFeildsType) => void} [props.handleClickGroup] - Handler function for clicking a group.
60
+ * @param {0|1|2|3|4|5|6} [props.dayOffset] - Offset index for the day column (0 = first day of week, …, 6 = last day).
61
+ * @param {React.CSSProperties} [props.dayColsStyle] - Additional styles for the day columns.
62
+ * @param {string} [props.dayColsClassName] - Additional class names for the day columns.
63
+ * @param {React.CSSProperties} [props.hoursColsStyle] - Additional styles for the hours columns.
64
+ * @param {string} [props.hoursColsClassName] - Additional class names for the hours columns.
65
+ */
66
+ const Calendar = (props) => {
67
+ return (_jsx(_Fragment, { children: _jsx(CalendarForWeek, Object.assign({}, props)) }));
68
+ };
69
+ export default Calendar;
70
+ export { CalendarForDay };