@capillarytech/blaze-ui 6.0.0 → 6.0.4
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/CapActionBar/styles.module.scss.js +1 -1
- package/CapAdvancedIcon/styles.module.scss.js +1 -1
- package/CapAlert/styles.module.scss.js +1 -1
- package/CapAppNotEnabled/styles.module.scss.js +1 -1
- package/CapAskAira/AudienceFilterBot/styles.module.scss.js +1 -1
- package/CapAskAira/CapAiMediaGeneration/styles.module.scss.js +1 -1
- package/CapAskAira/ConfigurationBot/PromptAttachmentButton.js +1 -1
- package/CapAskAira/ConfigurationBot/styles.module.scss.js +1 -1
- package/CapAskAira/ContentGenerationBot/styles.module.scss.js +1 -1
- package/CapAskAira/DocumentationBot/styles.module.scss.js +1 -1
- package/CapAskAira/DocumentationChatBot/styles.module.scss.js +1 -1
- package/CapAskAira/RuleGenerationBot/styles.module.scss.js +1 -1
- package/CapAskAira/RuleSummarizationBot/styles.module.scss.js +1 -1
- package/CapAskAira/styles.module.scss.js +1 -1
- package/CapBanner/styles.module.scss.js +1 -1
- package/CapBlock/styles.module.scss.js +1 -1
- package/CapButton/styles.module.scss.js +1 -1
- package/CapCSVFileUploader/styles.module.scss.js +1 -1
- package/CapCalendarDatePicker/styles.module.scss.js +1 -1
- package/CapCard/styles.module.scss.js +1 -1
- package/CapCardBox/styles.module.scss.js +1 -1
- package/CapCarousel/styles.module.scss.js +1 -1
- package/CapCheckbox/styles.module.scss.js +1 -1
- package/CapColorPicker/styles.module.scss.js +1 -1
- package/CapColoredTag/styles.module.scss.js +1 -1
- package/CapColumn/styles.module.scss.js +1 -1
- package/CapConditionPreview/styles.module.scss.js +1 -1
- package/CapCustomCard/styles.module.scss.js +1 -1
- package/CapCustomCarousel/styles.module.scss.js +1 -1
- package/CapCustomCheckboxList/styles.module.scss.js +1 -1
- package/CapCustomList/styles.module.scss.js +1 -1
- package/CapCustomSelect/styles.module.scss.js +1 -1
- package/CapDatePicker/styles.module.scss.js +1 -1
- package/CapDateRangePicker/styles.module.scss.js +1 -1
- package/CapDateTimePicker/styles.module.scss.js +1 -1
- package/CapDateTimeRangePicker/styles.module.scss.js +1 -1
- package/CapDnDGraph/reportingBlock.js +1 -1
- package/CapDropdown/styles.module.scss.js +1 -1
- package/CapEmptyDivWithBorder/styles.module.scss.js +1 -1
- package/CapError/styles.module.scss.js +1 -1
- package/CapErrorBoundary/styles.module.scss.js +1 -1
- package/CapErrorStateIllustration/styles.module.scss.js +1 -1
- package/CapEventCalendar/CalendarCanvas/calendarCanvasStyles.css +21 -0
- package/CapEventCalendar/CalendarCanvas/calendarCanvasStyles.module.scss.js +8 -0
- package/CapEventCalendar/CalendarCanvas/calendarCanvasStyles.scss +17 -0
- package/CapEventCalendar/CalendarCanvas/index.d.ts +3 -52
- package/CapEventCalendar/CalendarCanvas/index.d.ts.map +1 -1
- package/CapEventCalendar/CalendarCanvas/index.js +31 -50
- package/CapEventCalendar/CalendarCanvas/utils.d.ts +5 -9
- package/CapEventCalendar/CalendarCanvas/utils.d.ts.map +1 -1
- package/CapEventCalendar/CalendarCanvas/utils.js +6 -6
- package/CapEventCalendar/components/DayDropdown/index.d.ts +3 -13
- package/CapEventCalendar/components/DayDropdown/index.d.ts.map +1 -1
- package/CapEventCalendar/components/DayDropdown/index.js +32 -14
- package/CapEventCalendar/components/MonthHeader/index.d.ts +3 -9
- package/CapEventCalendar/components/MonthHeader/index.d.ts.map +1 -1
- package/CapEventCalendar/components/MonthHeader/index.js +4 -9
- package/CapEventCalendar/components/MonthHeader/monthHeaderStyles.css +20 -0
- package/CapEventCalendar/components/MonthHeader/monthHeaderStyles.module.scss.js +7 -0
- package/CapEventCalendar/components/MonthHeader/monthHeaderStyles.scss +15 -0
- package/CapEventCalendar/drawUtils.d.ts +9 -71
- package/CapEventCalendar/drawUtils.d.ts.map +1 -1
- package/CapEventCalendar/drawUtils.js +12 -4
- package/CapEventCalendar/index.d.ts +4 -80
- package/CapEventCalendar/index.d.ts.map +1 -1
- package/CapEventCalendar/index.js +60 -85
- package/CapEventCalendar/messages.d.ts +25 -0
- package/CapEventCalendar/messages.d.ts.map +1 -0
- package/CapEventCalendar/messages.js +28 -0
- package/CapEventCalendar/styles.css +9 -81
- package/CapEventCalendar/styles.module.scss.js +12 -0
- package/CapEventCalendar/styles.scss +34 -107
- package/CapEventCalendar/tests/types.d.ts +26 -0
- package/CapEventCalendar/tests/types.d.ts.map +1 -0
- package/CapEventCalendar/types.d.ts +188 -0
- package/CapEventCalendar/types.d.ts.map +1 -0
- package/CapEventCalendar/types.js +1 -0
- package/CapEventCalendar/utils.d.ts +11 -9
- package/CapEventCalendar/utils.d.ts.map +1 -1
- package/CapEventCalendar/utils.js +10 -7
- package/CapExpressionEditor/styles.module.scss.js +1 -1
- package/CapForm/styles.module.scss.js +1 -1
- package/CapFormItem/styles.module.scss.js +1 -1
- package/CapGraph/styles.module.scss.js +1 -1
- package/CapHamburgerMenu/styles.module.scss.js +1 -1
- package/CapHeader/styles.module.scss.js +1 -1
- package/CapHeading/styles.module.scss.js +1 -1
- package/CapIcon/styles.module.scss.js +1 -1
- package/CapIllustration/styles.module.scss.js +1 -1
- package/CapImage/styles.module.scss.js +1 -1
- package/CapImportMFEComponent/styles.module.scss.js +1 -1
- package/CapInfoNote/styles.module.scss.js +1 -1
- package/CapInput/styles.module.scss.js +1 -1
- package/CapLabel/styles.module.scss.js +1 -1
- package/CapLanguageProvider/index.d.ts +0 -1
- package/CapLanguageProvider/index.d.ts.map +1 -1
- package/CapLanguageProvider/index.js +0 -3
- package/CapLevelGraphRenderer/styles.module.scss.js +1 -1
- package/CapLink/styles.module.scss.js +1 -1
- package/CapList/styles.module.scss.js +1 -1
- package/CapListLayout/styles.module.scss.js +1 -1
- package/CapLogin/styles.module.scss.js +1 -1
- package/CapMenu/styles.module.scss.js +1 -1
- package/CapModal/styles.module.scss.js +1 -1
- package/CapMultiSelect/styles.module.scss.js +1 -1
- package/CapMultiSelectDatePicker/styles.module.scss.js +1 -1
- package/CapNavigation/styles.module.scss.js +1 -1
- package/CapNotification/styles.module.scss.js +1 -1
- package/CapNotificationDropdown/styles.module.scss.js +1 -1
- package/CapPopover/styles.module.scss.js +1 -1
- package/CapProgress/styles.module.scss.js +1 -1
- package/CapRadio/styles.module.scss.js +1 -1
- package/CapRadioButton/styles.module.scss.js +1 -1
- package/CapRadioCard/styles.module.scss.js +1 -1
- package/CapRadioGroup/styles.module.scss.js +1 -1
- package/CapReorderComponent/styles.module.scss.js +1 -1
- package/CapRoadMap/styles.module.scss.js +1 -1
- package/CapRow/styles.module.scss.js +1 -1
- package/CapSKUUploader/styles.module.scss.js +1 -1
- package/CapSecondaryTopBar/styles.module.scss.js +1 -1
- package/CapSelect/styles.module.scss.js +1 -1
- package/CapSelectFilter/{styles.module.css → styles.css} +3 -3
- package/CapSelectFilter/styles.module.scss.js +1 -1
- package/CapSelectFilter/styles.scss +3 -3
- package/CapShape/styles.module.scss.js +1 -1
- package/CapSideBar/_menuSearch.module.scss.js +1 -1
- package/CapSideBar/styles.module.scss.js +1 -1
- package/CapSlideBox/styles.module.scss.js +1 -1
- package/CapSlider/styles.module.scss.js +1 -1
- package/CapSnackBar/styles.module.scss.js +1 -1
- package/CapSomethingWentWrong/styles.module.scss.js +1 -1
- package/CapSplit/styles.module.scss.js +1 -1
- package/CapStatisticCard/styles.module.scss.js +1 -1
- package/CapStatus/styles.module.scss.js +1 -1
- package/CapSteps/styles.module.scss.js +1 -1
- package/CapStepsAccordian/styles.module.scss.js +1 -1
- package/CapSupportVideosWrapper/index.js +1 -1
- package/CapSupportVideosWrapper/styles.module.scss.js +1 -1
- package/CapSwitch/styles.module.scss.js +1 -1
- package/CapTab/styles.module.scss.js +1 -1
- package/CapTabV3/styles.module.scss.js +1 -1
- package/CapTabV3/tests/CapTabV3.mockData.d.ts +26 -26
- package/CapTabV3/tests/CapTabV3.mockData.d.ts.map +1 -1
- package/CapTable/styles.module.scss.js +1 -1
- package/CapTag/styles.module.scss.js +1 -1
- package/CapTagDropdown/styles.module.scss.js +1 -1
- package/CapTimePicker/styles.module.scss.js +1 -1
- package/CapTooltip/styles.module.scss.js +1 -1
- package/CapTooltipWithInfo/styles.module.scss.js +1 -1
- package/CapTopBar/CapOrgSelect.module.scss.js +1 -1
- package/CapTopBar/styles.module.scss.js +1 -1
- package/CapTree/styles.module.scss.js +1 -1
- package/CapTreeSelect/styles.module.scss.js +1 -1
- package/CapUnifiedSelect/styles.module.scss.js +1 -1
- package/CapUploader/styles.module.scss.js +1 -1
- package/CapUserProfile/styles.module.scss.js +1 -1
- package/assets/HOCs/ComponentWithLabelHOC/styles.module.scss.js +1 -1
- package/index.d.ts +2 -0
- package/index.d.ts.map +1 -1
- package/index.js +223 -221
- package/package.json +1 -2
- package/utils/dayjs.d.ts +1 -0
- package/utils/dayjs.d.ts.map +1 -1
- package/utils/dayjs.js +1 -0
- /package/CapActionBar/{styles.module.css → styles.css} +0 -0
- /package/CapAdvancedIcon/{styles.module.css → styles.css} +0 -0
- /package/CapAlert/{styles.module.css → styles.css} +0 -0
- /package/CapAppNotEnabled/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/AudienceFilterBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/CapAiMediaGeneration/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/ConfigurationBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/ContentGenerationBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/DocumentationBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/DocumentationChatBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/RuleGenerationBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/RuleSummarizationBot/{styles.module.css → styles.css} +0 -0
- /package/CapAskAira/{styles.module.css → styles.css} +0 -0
- /package/CapBanner/{styles.module.css → styles.css} +0 -0
- /package/CapBlock/{styles.module.css → styles.css} +0 -0
- /package/CapButton/{styles.module.css → styles.css} +0 -0
- /package/CapCSVFileUploader/{styles.module.css → styles.css} +0 -0
- /package/CapCalendarDatePicker/{styles.module.css → styles.css} +0 -0
- /package/CapCard/{styles.module.css → styles.css} +0 -0
- /package/CapCardBox/{styles.module.css → styles.css} +0 -0
- /package/CapCarousel/{styles.module.css → styles.css} +0 -0
- /package/CapCheckbox/{styles.module.css → styles.css} +0 -0
- /package/CapColorPicker/{styles.module.css → styles.css} +0 -0
- /package/CapColoredTag/{styles.module.css → styles.css} +0 -0
- /package/CapColumn/{styles.module.css → styles.css} +0 -0
- /package/CapConditionPreview/{styles.module.css → styles.css} +0 -0
- /package/CapCustomCard/{styles.module.css → styles.css} +0 -0
- /package/CapCustomCarousel/{styles.module.css → styles.css} +0 -0
- /package/CapCustomCheckboxList/{styles.module.css → styles.css} +0 -0
- /package/CapCustomList/{styles.module.css → styles.css} +0 -0
- /package/CapCustomSelect/{styles.module.css → styles.css} +0 -0
- /package/CapDatePicker/{styles.module.css → styles.css} +0 -0
- /package/CapDateRangePicker/{styles.module.css → styles.css} +0 -0
- /package/CapDateTimePicker/{styles.module.css → styles.css} +0 -0
- /package/CapDateTimeRangePicker/{styles.module.css → styles.css} +0 -0
- /package/CapDropdown/{styles.module.css → styles.css} +0 -0
- /package/CapEmptyDivWithBorder/{styles.module.css → styles.css} +0 -0
- /package/CapError/{styles.module.css → styles.css} +0 -0
- /package/CapErrorBoundary/{styles.module.css → styles.css} +0 -0
- /package/CapErrorStateIllustration/{styles.module.css → styles.css} +0 -0
- /package/CapExpressionEditor/{styles.module.css → styles.css} +0 -0
- /package/CapForm/{styles.module.css → styles.css} +0 -0
- /package/CapFormItem/{styles.module.css → styles.css} +0 -0
- /package/CapGraph/{styles.module.css → styles.css} +0 -0
- /package/CapHamburgerMenu/{styles.module.css → styles.css} +0 -0
- /package/CapHeader/{styles.module.css → styles.css} +0 -0
- /package/CapHeading/{styles.module.css → styles.css} +0 -0
- /package/CapIcon/{styles.module.css → styles.css} +0 -0
- /package/CapIllustration/{styles.module.css → styles.css} +0 -0
- /package/CapImage/{styles.module.css → styles.css} +0 -0
- /package/CapImportMFEComponent/{styles.module.css → styles.css} +0 -0
- /package/CapInfoNote/{styles.module.css → styles.css} +0 -0
- /package/CapInput/{styles.module.css → styles.css} +0 -0
- /package/CapLabel/{styles.module.css → styles.css} +0 -0
- /package/CapLevelGraphRenderer/{styles.module.css → styles.css} +0 -0
- /package/CapLink/{styles.module.css → styles.css} +0 -0
- /package/CapList/{styles.module.css → styles.css} +0 -0
- /package/CapListLayout/{styles.module.css → styles.css} +0 -0
- /package/CapLogin/{styles.module.css → styles.css} +0 -0
- /package/CapModal/{styles.module.css → styles.css} +0 -0
- /package/CapMultiSelect/{styles.module.css → styles.css} +0 -0
- /package/CapMultiSelectDatePicker/{styles.module.css → styles.css} +0 -0
- /package/CapNavigation/{styles.module.css → styles.css} +0 -0
- /package/CapNotification/{styles.module.css → styles.css} +0 -0
- /package/CapNotificationDropdown/{styles.module.css → styles.css} +0 -0
- /package/CapPopover/{styles.module.css → styles.css} +0 -0
- /package/CapProgress/{styles.module.css → styles.css} +0 -0
- /package/CapRadio/{styles.module.css → styles.css} +0 -0
- /package/CapRadioButton/{styles.module.css → styles.css} +0 -0
- /package/CapRadioCard/{styles.module.css → styles.css} +0 -0
- /package/CapRadioGroup/{styles.module.css → styles.css} +0 -0
- /package/CapReorderComponent/{styles.module.css → styles.css} +0 -0
- /package/CapRoadMap/{styles.module.css → styles.css} +0 -0
- /package/CapRow/{styles.module.css → styles.css} +0 -0
- /package/CapSKUUploader/{styles.module.css → styles.css} +0 -0
- /package/CapSecondaryTopBar/{styles.module.css → styles.css} +0 -0
- /package/CapSelect/{styles.module.css → styles.css} +0 -0
- /package/CapShape/{styles.module.css → styles.css} +0 -0
- /package/CapSideBar/{_menuSearch.module.css → _menuSearch.css} +0 -0
- /package/CapSideBar/{styles.module.css → styles.css} +0 -0
- /package/CapSlideBox/{styles.module.css → styles.css} +0 -0
- /package/CapSlider/{styles.module.css → styles.css} +0 -0
- /package/CapSnackBar/{styles.module.css → styles.css} +0 -0
- /package/CapSomethingWentWrong/{styles.module.css → styles.css} +0 -0
- /package/CapSplit/{styles.module.css → styles.css} +0 -0
- /package/CapStatisticCard/{styles.module.css → styles.css} +0 -0
- /package/CapStatus/{styles.module.css → styles.css} +0 -0
- /package/CapSteps/{styles.module.css → styles.css} +0 -0
- /package/CapStepsAccordian/{styles.module.css → styles.css} +0 -0
- /package/CapSupportVideosWrapper/{styles.module.css → styles.css} +0 -0
- /package/CapSwitch/{styles.module.css → styles.css} +0 -0
- /package/CapTab/{styles.module.css → styles.css} +0 -0
- /package/CapTabV3/{styles.module.css → styles.css} +0 -0
- /package/CapTable/{styles.module.css → styles.css} +0 -0
- /package/CapTag/{styles.module.css → styles.css} +0 -0
- /package/CapTagDropdown/{styles.module.css → styles.css} +0 -0
- /package/CapTimePicker/{styles.module.css → styles.css} +0 -0
- /package/CapTooltip/{styles.module.css → styles.css} +0 -0
- /package/CapTooltipWithInfo/{styles.module.css → styles.css} +0 -0
- /package/CapTopBar/{CapOrgSelect.module.css → CapOrgSelect.css} +0 -0
- /package/CapTopBar/{styles.module.css → styles.css} +0 -0
- /package/CapTree/{styles.module.css → styles.css} +0 -0
- /package/CapTreeSelect/{styles.module.css → styles.css} +0 -0
- /package/CapUnifiedSelect/{styles.module.css → styles.css} +0 -0
- /package/CapUploader/{styles.module.css → styles.css} +0 -0
- /package/CapUserProfile/{styles.module.css → styles.css} +0 -0
- /package/assets/HOCs/ComponentWithLabelHOC/{styles.module.css → styles.css} +0 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare const scope = "app.commonUtils.capUiLibrary.CapEventCalendar";
|
|
2
|
+
declare const _default: {
|
|
3
|
+
calendarGridLineLabel: {
|
|
4
|
+
id: string;
|
|
5
|
+
defaultMessage: string;
|
|
6
|
+
};
|
|
7
|
+
emptyStateTitle: {
|
|
8
|
+
id: string;
|
|
9
|
+
defaultMessage: string;
|
|
10
|
+
};
|
|
11
|
+
emptyStateDescription: {
|
|
12
|
+
id: string;
|
|
13
|
+
defaultMessage: string;
|
|
14
|
+
};
|
|
15
|
+
emptyStateButtonLabel: {
|
|
16
|
+
id: string;
|
|
17
|
+
defaultMessage: string;
|
|
18
|
+
};
|
|
19
|
+
todayLabel: {
|
|
20
|
+
id: string;
|
|
21
|
+
defaultMessage: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export default _default;
|
|
25
|
+
//# sourceMappingURL=messages.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"messages.d.ts","sourceRoot":"","sources":["../../components/CapEventCalendar/messages.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK,kDAAkD,CAAC;;;;;;;;;;;;;;;;;;;;;;;AAErE,wBAqBG"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { defineMessages } from "react-intl";
|
|
2
|
+
const scope = "app.commonUtils.capUiLibrary.CapEventCalendar";
|
|
3
|
+
const messages = defineMessages({
|
|
4
|
+
calendarGridLineLabel: {
|
|
5
|
+
id: `${scope}.calendarGridLineLabel`,
|
|
6
|
+
defaultMessage: "Calendar Grid Line"
|
|
7
|
+
},
|
|
8
|
+
emptyStateTitle: {
|
|
9
|
+
id: `${scope}.emptyStateTitle`,
|
|
10
|
+
defaultMessage: "You have no events for this quarter"
|
|
11
|
+
},
|
|
12
|
+
emptyStateDescription: {
|
|
13
|
+
id: `${scope}.emptyStateDescription`,
|
|
14
|
+
defaultMessage: "Please create an event to view it here"
|
|
15
|
+
},
|
|
16
|
+
emptyStateButtonLabel: {
|
|
17
|
+
id: `${scope}.emptyStateButtonLabel`,
|
|
18
|
+
defaultMessage: "Create Event"
|
|
19
|
+
},
|
|
20
|
+
todayLabel: {
|
|
21
|
+
id: `${scope}.todayLabel`,
|
|
22
|
+
defaultMessage: "Today"
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
export {
|
|
26
|
+
messages as default,
|
|
27
|
+
scope
|
|
28
|
+
};
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
/* Transition */
|
|
8
8
|
/* Timezones Footer */
|
|
9
9
|
.event-calendar {
|
|
10
|
-
height:
|
|
10
|
+
height: 50rem;
|
|
11
11
|
}
|
|
12
12
|
.event-calendar__header {
|
|
13
13
|
display: flex;
|
|
@@ -19,94 +19,22 @@
|
|
|
19
19
|
padding-top: 0.571rem;
|
|
20
20
|
}
|
|
21
21
|
.event-calendar__header__left .quarter-label {
|
|
22
|
-
width:
|
|
22
|
+
width: fit-content;
|
|
23
23
|
height: 1.428rem;
|
|
24
|
-
margin:
|
|
25
|
-
|
|
26
|
-
font-weight: 500;
|
|
27
|
-
font-stretch: normal;
|
|
28
|
-
font-style: normal;
|
|
29
|
-
line-height: 1.25;
|
|
30
|
-
letter-spacing: normal;
|
|
31
|
-
color: #091e42;
|
|
24
|
+
margin: 0.142rem 0 0.142rem 0.571rem;
|
|
25
|
+
gap: 0.857rem;
|
|
32
26
|
}
|
|
33
|
-
.event-calendar__header__left .quarter-
|
|
34
|
-
|
|
27
|
+
.event-calendar__header__left .quarter-label__text {
|
|
28
|
+
font-size: 1.143rem;
|
|
35
29
|
}
|
|
36
30
|
.event-calendar__header__left .disable-left {
|
|
37
|
-
color:
|
|
31
|
+
color: #97a0af !important;
|
|
38
32
|
cursor: not-allowed;
|
|
39
33
|
pointer-events: none;
|
|
40
34
|
}
|
|
41
35
|
.event-calendar__header__left .carousel-icon {
|
|
42
36
|
cursor: pointer;
|
|
43
37
|
}
|
|
44
|
-
.event-calendar__header__right
|
|
45
|
-
|
|
46
|
-
height: 1.428rem;
|
|
47
|
-
margin: 9px 0.571rem 11px 0;
|
|
48
|
-
font-size: 1rem;
|
|
49
|
-
font-weight: 500;
|
|
50
|
-
font-stretch: normal;
|
|
51
|
-
font-style: normal;
|
|
52
|
-
line-height: 1.43;
|
|
53
|
-
letter-spacing: normal;
|
|
54
|
-
color: #091e42;
|
|
55
|
-
}
|
|
56
|
-
.event-calendar__header .ant-btn-flat {
|
|
57
|
-
width: 140px !important;
|
|
58
|
-
height: 2.857rem !important;
|
|
59
|
-
margin: 0 0 0 0.571rem !important;
|
|
60
|
-
padding: 0.571rem !important;
|
|
61
|
-
border-radius: 0.285rem !important;
|
|
62
|
-
border: solid 1px #b3bac5 !important;
|
|
63
|
-
color: #091e42;
|
|
64
|
-
font-weight: normal;
|
|
65
|
-
}
|
|
66
|
-
.event-calendar__header .ant-btn-flat .cap-button-v2-suffix {
|
|
67
|
-
position: absolute;
|
|
68
|
-
right: 0.571rem;
|
|
69
|
-
}
|
|
70
|
-
.event-calendar__header .flat-btn:hover {
|
|
71
|
-
background-color: #ffffff !important;
|
|
72
|
-
}
|
|
73
|
-
.event-calendar__month-header {
|
|
74
|
-
display: flex;
|
|
75
|
-
justify-content: center;
|
|
76
|
-
position: relative;
|
|
77
|
-
text-align: center;
|
|
78
|
-
top: 0;
|
|
79
|
-
margin-bottom: 10px;
|
|
80
|
-
margin-top: 25px;
|
|
81
|
-
}
|
|
82
|
-
.event-calendar__month-header__label {
|
|
83
|
-
width: 33.33%;
|
|
84
|
-
height: 1.428rem;
|
|
85
|
-
text-align: center;
|
|
86
|
-
color: #091e42;
|
|
87
|
-
font-size: 1rem;
|
|
88
|
-
font-weight: 500;
|
|
89
|
-
font-stretch: normal;
|
|
90
|
-
font-style: normal;
|
|
91
|
-
line-height: 1.43;
|
|
92
|
-
letter-spacing: normal;
|
|
93
|
-
}
|
|
94
|
-
.ant-dropdown-placement-bottomCenter .ant-dropdown-menu-item {
|
|
95
|
-
height: 2.857rem !important;
|
|
96
|
-
padding: 9px 0.571rem 11px 1.142rem !important;
|
|
97
|
-
background-color: #ffffff !important;
|
|
98
|
-
color: #091e42 !important;
|
|
99
|
-
font-size: 1rem;
|
|
100
|
-
}
|
|
101
|
-
.ant-dropdown-placement-bottomCenter .ant-dropdown-menu-item:hover {
|
|
102
|
-
background-color: #fefcf0 !important;
|
|
103
|
-
}
|
|
104
|
-
.ant-dropdown-placement-bottomCenter .ant-dropdown-menu-item-selected {
|
|
105
|
-
background-color: #e9f0fe !important;
|
|
106
|
-
border-left: 1px solid #2466ea !important;
|
|
107
|
-
color: #091e42 !important;
|
|
108
|
-
}
|
|
109
|
-
.ant-dropdown-placement-bottomCenter .ant-dropdown-menu-vertical {
|
|
110
|
-
width: 140px !important;
|
|
111
|
-
margin-left: 35px !important;
|
|
38
|
+
.event-calendar__header__right {
|
|
39
|
+
gap: 0.857rem;
|
|
112
40
|
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import './styles.css';const styles = {
|
|
2
|
+
"event-calendar__header": "event-calendar__header",
|
|
3
|
+
"event-calendar__header__left": "event-calendar__header__left",
|
|
4
|
+
"quarter-label": "quarter-label",
|
|
5
|
+
"quarter-label__text": "quarter-label__text",
|
|
6
|
+
"disable-left": "disable-left",
|
|
7
|
+
"carousel-icon": "carousel-icon",
|
|
8
|
+
"event-calendar__header__right": "event-calendar__header__right"
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
styles as default
|
|
12
|
+
};
|
|
@@ -1,114 +1,41 @@
|
|
|
1
|
+
@import '../styles/_variables.scss';
|
|
1
2
|
|
|
2
|
-
|
|
3
|
+
.event-calendar {
|
|
4
|
+
height: 50rem;
|
|
3
5
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
line-height: 1.25;
|
|
22
|
-
letter-spacing: normal;
|
|
23
|
-
color: $FONT_COLOR_01;
|
|
24
|
-
span{
|
|
25
|
-
margin-right: 10px;
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
.disable-left{
|
|
29
|
-
color:grey;
|
|
30
|
-
cursor: not-allowed;
|
|
31
|
-
pointer-events: none;
|
|
32
|
-
}
|
|
33
|
-
.carousel-icon{
|
|
34
|
-
cursor: pointer;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
&__right{
|
|
38
|
-
.grid-label{
|
|
39
|
-
width: 111px;
|
|
40
|
-
height: $CAP_SPACE_20;
|
|
41
|
-
margin: 9px $CAP_SPACE_08 11px 0;
|
|
42
|
-
font-size: $FONT_SIZE_M;
|
|
43
|
-
font-weight: $FONT_WEIGHT_MEDIUM;
|
|
44
|
-
font-stretch: normal;
|
|
45
|
-
font-style: normal;
|
|
46
|
-
line-height: 1.43;
|
|
47
|
-
letter-spacing: normal;
|
|
48
|
-
color: $FONT_COLOR_01;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
.ant-btn-flat{
|
|
52
|
-
width: 140px !important;
|
|
53
|
-
height: $CAP_SPACE_40 !important;
|
|
54
|
-
margin: 0 0 0 $CAP_SPACE_08 !important;
|
|
55
|
-
padding: $CAP_SPACE_08 !important;
|
|
56
|
-
border-radius: $CAP_SPACE_04 !important;
|
|
57
|
-
border: solid 1px $CAP_G06 !important;
|
|
58
|
-
color: $FONT_COLOR_01;
|
|
59
|
-
font-weight: normal;
|
|
60
|
-
.cap-button-v2-suffix{
|
|
61
|
-
position: absolute;
|
|
62
|
-
right: $CAP_SPACE_08;
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
.flat-btn:hover{
|
|
66
|
-
background-color: $CAP_WHITE!important;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
&__month-header{
|
|
70
|
-
display: flex;
|
|
71
|
-
justify-content: center;
|
|
72
|
-
position: relative;
|
|
73
|
-
text-align: center;
|
|
74
|
-
top: 0;
|
|
75
|
-
margin-bottom: 10px;
|
|
76
|
-
margin-top: 25px;
|
|
77
|
-
&__label{
|
|
78
|
-
width: 33.33%;
|
|
79
|
-
height: $CAP_SPACE_20;
|
|
80
|
-
text-align: center;
|
|
81
|
-
color: $FONT_COLOR_01;
|
|
82
|
-
font-size:$FONT_SIZE_M ;
|
|
83
|
-
font-weight: $FONT_WEIGHT_MEDIUM;
|
|
84
|
-
font-stretch: normal;
|
|
85
|
-
font-style: normal;
|
|
86
|
-
line-height: 1.43;
|
|
87
|
-
letter-spacing: normal;
|
|
6
|
+
&__header {
|
|
7
|
+
display: flex;
|
|
8
|
+
position: relative;
|
|
9
|
+
justify-content: space-between;
|
|
10
|
+
|
|
11
|
+
&__left {
|
|
12
|
+
display: flex;
|
|
13
|
+
padding-top: $CAP_SPACE_08;
|
|
14
|
+
|
|
15
|
+
.quarter-label {
|
|
16
|
+
width: fit-content;
|
|
17
|
+
height: $CAP_SPACE_20;
|
|
18
|
+
margin: 0.142rem 0 0.142rem $CAP_SPACE_08;
|
|
19
|
+
gap: $CAP_SPACE_12;
|
|
20
|
+
|
|
21
|
+
&__text {
|
|
22
|
+
font-size: $FONT_SIZE_L;
|
|
88
23
|
}
|
|
89
|
-
|
|
90
|
-
}
|
|
24
|
+
}
|
|
91
25
|
|
|
92
|
-
.
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
background-color: $BG_02 !important;
|
|
102
|
-
}
|
|
103
|
-
.ant-dropdown-menu-item-selected{
|
|
104
|
-
background-color: $CAP_PALE_GREY !important;
|
|
105
|
-
border-left: 1px solid $FONT_COLOR_05 !important;
|
|
106
|
-
color: $FONT_COLOR_01 !important;
|
|
26
|
+
.disable-left {
|
|
27
|
+
color: $FONT_COLOR_03 !important;
|
|
28
|
+
cursor: not-allowed;
|
|
29
|
+
pointer-events: none;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.carousel-icon {
|
|
33
|
+
cursor: pointer;
|
|
34
|
+
}
|
|
107
35
|
}
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
36
|
+
|
|
37
|
+
&__right {
|
|
38
|
+
gap: $CAP_SPACE_12;
|
|
111
39
|
}
|
|
40
|
+
}
|
|
112
41
|
}
|
|
113
|
-
|
|
114
|
-
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
export type MockCanvasContext = {
|
|
2
|
+
beginPath: jest.Mock;
|
|
3
|
+
closePath: jest.Mock;
|
|
4
|
+
fillStyle: string;
|
|
5
|
+
strokeStyle: string;
|
|
6
|
+
textAlign: string;
|
|
7
|
+
measureText: jest.Mock<(text: string) => {
|
|
8
|
+
width: number;
|
|
9
|
+
actualBoundingBoxAscent?: number;
|
|
10
|
+
actualBoundingBoxDescent?: number;
|
|
11
|
+
}>;
|
|
12
|
+
fillRect: jest.Mock;
|
|
13
|
+
fillText: jest.Mock;
|
|
14
|
+
arc: jest.Mock;
|
|
15
|
+
fill: jest.Mock;
|
|
16
|
+
setLineDash: jest.Mock;
|
|
17
|
+
moveTo: jest.Mock;
|
|
18
|
+
lineTo: jest.Mock;
|
|
19
|
+
stroke: jest.Mock;
|
|
20
|
+
quadraticCurveTo: jest.Mock;
|
|
21
|
+
rect: jest.Mock;
|
|
22
|
+
isPointInPath: jest.Mock<() => boolean>;
|
|
23
|
+
font: string;
|
|
24
|
+
};
|
|
25
|
+
export declare const createMockContext: () => MockCanvasContext;
|
|
26
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../components/CapEventCalendar/tests/types.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,iBAAiB,GAAG;IAC9B,SAAS,EAAE,IAAI,CAAC,IAAI,CAAC;IACrB,SAAS,EAAE,IAAI,CAAC,IAAI,CAAC;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,IAAI,CAAC,IAAI,CACpB,CAAC,IAAI,EAAE,MAAM,KAAK;QAChB,KAAK,EAAE,MAAM,CAAC;QACd,uBAAuB,CAAC,EAAE,MAAM,CAAC;QACjC,wBAAwB,CAAC,EAAE,MAAM,CAAC;KACnC,CACF,CAAC;IACF,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC;IACpB,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC;IACpB,GAAG,EAAE,IAAI,CAAC,IAAI,CAAC;IACf,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC;IAChB,WAAW,EAAE,IAAI,CAAC,IAAI,CAAC;IACvB,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC;IAClB,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC;IAClB,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC;IAClB,gBAAgB,EAAE,IAAI,CAAC,IAAI,CAAC;IAC5B,IAAI,EAAE,IAAI,CAAC,IAAI,CAAC;IAChB,aAAa,EAAE,IAAI,CAAC,IAAI,CAAC,MAAM,OAAO,CAAC,CAAC;IACxC,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAGF,eAAO,MAAM,iBAAiB,QAAO,iBAuBnC,CAAC"}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
import type { PopoverProps } from 'antd-v5';
|
|
2
|
+
import type { Dayjs } from 'dayjs';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import type { MutableRefObject } from 'react';
|
|
5
|
+
import type { Root } from 'react-dom/client';
|
|
6
|
+
import { WrappedComponentProps } from 'react-intl';
|
|
7
|
+
export interface CapEventCalendarEvent {
|
|
8
|
+
event_id: string | number;
|
|
9
|
+
start: string;
|
|
10
|
+
end: string;
|
|
11
|
+
title: string;
|
|
12
|
+
backgroundColor: string;
|
|
13
|
+
popoverProps?: Record<string, unknown>;
|
|
14
|
+
}
|
|
15
|
+
export interface CapEventCalendarProps extends WrappedComponentProps {
|
|
16
|
+
calendarDate?: string;
|
|
17
|
+
events?: CapEventCalendarEvent[];
|
|
18
|
+
popoverContent?: React.ComponentType<Record<string, unknown>>;
|
|
19
|
+
onQuarterChange?: (quarterNum: number, date: Dayjs) => void;
|
|
20
|
+
selectedQuarter?: 'JFM' | 'AMJ' | 'JAS' | 'OND';
|
|
21
|
+
calendarGridLineLabel?: string;
|
|
22
|
+
dayLabels?: string[];
|
|
23
|
+
allQuartersLabel?: string[];
|
|
24
|
+
monthLabels?: string[];
|
|
25
|
+
todayTooltipProps?: Record<string, unknown>;
|
|
26
|
+
dashLineOffsetY?: number;
|
|
27
|
+
eventHeight?: number;
|
|
28
|
+
eventRowGap?: number;
|
|
29
|
+
textPadding?: number;
|
|
30
|
+
eventStartYOffset?: number;
|
|
31
|
+
minCanvasHeight?: number;
|
|
32
|
+
canvasFont?: string;
|
|
33
|
+
popoverPlacement?: PopoverProps['placement'];
|
|
34
|
+
emptyState?: boolean;
|
|
35
|
+
emptyStateTitle?: string;
|
|
36
|
+
emptyStateDescription?: string;
|
|
37
|
+
emptyStateButtonLabel?: string;
|
|
38
|
+
onEmptyStateButtonClick?: () => void;
|
|
39
|
+
isButtonDisabled?: boolean;
|
|
40
|
+
}
|
|
41
|
+
export interface MonthDisplayItem {
|
|
42
|
+
name: string;
|
|
43
|
+
start: string;
|
|
44
|
+
end: string;
|
|
45
|
+
daysInMonth: number;
|
|
46
|
+
month: number;
|
|
47
|
+
}
|
|
48
|
+
export interface FormattedEvent {
|
|
49
|
+
event_id: string | number;
|
|
50
|
+
start: string;
|
|
51
|
+
end: string;
|
|
52
|
+
title: string;
|
|
53
|
+
backgroundColor: string;
|
|
54
|
+
popoverProps?: Record<string, unknown>;
|
|
55
|
+
}
|
|
56
|
+
export interface CalendarCanvasProps {
|
|
57
|
+
displayMonths: MonthDisplayItem[];
|
|
58
|
+
dayGrid: number;
|
|
59
|
+
formattedEvents: FormattedEvent[][];
|
|
60
|
+
todayTooltipProps?: Record<string, unknown>;
|
|
61
|
+
dashLineOffsetY?: number;
|
|
62
|
+
eventHeight?: number;
|
|
63
|
+
eventRowGap?: number;
|
|
64
|
+
textPadding?: number;
|
|
65
|
+
eventStartYOffset?: number;
|
|
66
|
+
minCanvasHeight?: number;
|
|
67
|
+
canvasFont?: string;
|
|
68
|
+
popoverPlacement?: PopoverProps['placement'];
|
|
69
|
+
carouselDate: string;
|
|
70
|
+
popoverContent?: React.ComponentType<Record<string, unknown>>;
|
|
71
|
+
}
|
|
72
|
+
export interface DayDropdownProps {
|
|
73
|
+
fetchDay: (day: number) => void;
|
|
74
|
+
day: number;
|
|
75
|
+
dayLabels: string[];
|
|
76
|
+
}
|
|
77
|
+
export interface MonthHeaderProps {
|
|
78
|
+
displayMonths: MonthDisplayItem[];
|
|
79
|
+
}
|
|
80
|
+
export interface DayRectObject {
|
|
81
|
+
x: number;
|
|
82
|
+
y: number;
|
|
83
|
+
midX: number;
|
|
84
|
+
width: number;
|
|
85
|
+
height: number;
|
|
86
|
+
isCont?: boolean;
|
|
87
|
+
}
|
|
88
|
+
export interface DrawState {
|
|
89
|
+
day: Record<string, DayRectObject>;
|
|
90
|
+
}
|
|
91
|
+
export interface HoverEvent {
|
|
92
|
+
event: FormattedEvent;
|
|
93
|
+
startRect: DayRectObject;
|
|
94
|
+
endRect: DayRectObject;
|
|
95
|
+
eventStartY: number;
|
|
96
|
+
eventHeight: number;
|
|
97
|
+
isNewEvent: boolean;
|
|
98
|
+
}
|
|
99
|
+
export interface MouseCoords {
|
|
100
|
+
mouseX?: number;
|
|
101
|
+
mouseY?: number;
|
|
102
|
+
}
|
|
103
|
+
export interface ToggleTooltipArgs {
|
|
104
|
+
visible: unknown;
|
|
105
|
+
isTooltipVisible: MutableRefObject<boolean | null>;
|
|
106
|
+
todayTooltipProps: Record<string, unknown>;
|
|
107
|
+
rootTooltipRef: MutableRefObject<Root | null>;
|
|
108
|
+
}
|
|
109
|
+
export interface TogglePopoverArgs {
|
|
110
|
+
visible: boolean;
|
|
111
|
+
rootPopoverRef: MutableRefObject<Root | null>;
|
|
112
|
+
isPopoverVisible: MutableRefObject<boolean | null>;
|
|
113
|
+
popoverContent?: React.ComponentType<Record<string, unknown>>;
|
|
114
|
+
popoverPlacement?: PopoverProps['placement'];
|
|
115
|
+
popoverContentProps?: Record<string, unknown>;
|
|
116
|
+
}
|
|
117
|
+
export interface DrawHeadingTextParams {
|
|
118
|
+
context: CanvasRenderingContext2D;
|
|
119
|
+
x: number;
|
|
120
|
+
y: number;
|
|
121
|
+
height: number;
|
|
122
|
+
text: string;
|
|
123
|
+
}
|
|
124
|
+
export interface DrawCircleParams {
|
|
125
|
+
context: CanvasRenderingContext2D;
|
|
126
|
+
x: number;
|
|
127
|
+
y: number;
|
|
128
|
+
radius: number;
|
|
129
|
+
color: string;
|
|
130
|
+
}
|
|
131
|
+
export interface DrawDashedLinesParams {
|
|
132
|
+
context: CanvasRenderingContext2D;
|
|
133
|
+
x: number;
|
|
134
|
+
y: number;
|
|
135
|
+
x1: number;
|
|
136
|
+
y1: number;
|
|
137
|
+
}
|
|
138
|
+
export interface DrawTodayLineParams {
|
|
139
|
+
context: CanvasRenderingContext2D;
|
|
140
|
+
x: number;
|
|
141
|
+
y: number;
|
|
142
|
+
x1: number;
|
|
143
|
+
y1: number;
|
|
144
|
+
mouseX?: number;
|
|
145
|
+
mouseY?: number;
|
|
146
|
+
}
|
|
147
|
+
export interface DrawLineSeperatorParams {
|
|
148
|
+
context: CanvasRenderingContext2D;
|
|
149
|
+
x: number;
|
|
150
|
+
y: number;
|
|
151
|
+
x1: number;
|
|
152
|
+
y1: number;
|
|
153
|
+
}
|
|
154
|
+
export interface DrawRoundRectParams {
|
|
155
|
+
context: CanvasRenderingContext2D;
|
|
156
|
+
x: number;
|
|
157
|
+
y: number;
|
|
158
|
+
width: number;
|
|
159
|
+
height: number;
|
|
160
|
+
radius: number;
|
|
161
|
+
openLeft?: boolean;
|
|
162
|
+
openRight?: boolean;
|
|
163
|
+
fillStyle: string;
|
|
164
|
+
mouseX?: number;
|
|
165
|
+
mouseY?: number;
|
|
166
|
+
}
|
|
167
|
+
export interface DoEllipsisParams {
|
|
168
|
+
context: CanvasRenderingContext2D;
|
|
169
|
+
text: string;
|
|
170
|
+
maxWidth: number;
|
|
171
|
+
}
|
|
172
|
+
export interface DrawRoundRectWithTextParams {
|
|
173
|
+
context: CanvasRenderingContext2D;
|
|
174
|
+
x: number;
|
|
175
|
+
y: number;
|
|
176
|
+
width: number;
|
|
177
|
+
height: number;
|
|
178
|
+
bgColor: string;
|
|
179
|
+
borderRadius?: number;
|
|
180
|
+
text: string;
|
|
181
|
+
color: string;
|
|
182
|
+
textPadding: number;
|
|
183
|
+
openLeft?: boolean;
|
|
184
|
+
openRight?: boolean;
|
|
185
|
+
mouseX?: number;
|
|
186
|
+
mouseY?: number;
|
|
187
|
+
}
|
|
188
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../components/CapEventCalendar/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AACnC,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,OAAO,CAAC;AAC9C,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAC7C,OAAO,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AAEnD,MAAM,WAAW,qBAAqB;IACpC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAC;IAC1B,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,eAAe,EAAE,MAAM,CAAC;IACxB,YAAY,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACxC;AAED,MAAM,WAAW,qBAAsB,SAAQ,qBAAqB;IAClE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,E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AC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,wBAAwB,CAAC;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,2BAA2B;IAC1C,OAAO,EAAE,wBAAwB,CAAC;IAClC,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
import type { Dayjs } from 'dayjs';
|
|
2
|
+
import type { CapEventCalendarEvent, FormattedEvent, MonthDisplayItem } from './types';
|
|
3
|
+
export declare const getQuarterForDate: (date: string | Dayjs) => number;
|
|
4
|
+
export declare const splitMonthsArrayToQuarterChunks: (monthLabels?: string[]) => string[][];
|
|
3
5
|
/**
|
|
4
6
|
* The start and end of the months is calculated along with other information needed for month
|
|
5
7
|
* This is being used for drawing the canvas via the displayMonths state value in CapEventCalendar
|
|
@@ -7,13 +9,13 @@ export declare const splitMonthsArrayToQuarterChunks: (monthLabels?: string[]) =
|
|
|
7
9
|
* @param {*} monthNames this is for localization of month strings when displaying the month names in the header
|
|
8
10
|
* @returns
|
|
9
11
|
*/
|
|
10
|
-
export declare const getMonthsForQuarter: (quarter:
|
|
12
|
+
export declare const getMonthsForQuarter: (quarter: number, monthNames: string[][]) => MonthDisplayItem[];
|
|
11
13
|
/**
|
|
12
14
|
* To display the dates in the header and caculate the rectangles to be drawn in the canvas
|
|
13
15
|
* @param {*} date
|
|
14
16
|
* @returns
|
|
15
17
|
*/
|
|
16
|
-
export declare const getDaysOfMonth: (date:
|
|
18
|
+
export declare const getDaysOfMonth: (date: string | Dayjs) => string[];
|
|
17
19
|
/**
|
|
18
20
|
* Checks if the date lies between start and end or
|
|
19
21
|
* if it is same as start date or end date
|
|
@@ -24,7 +26,7 @@ export declare const getDaysOfMonth: (date: any) => string[];
|
|
|
24
26
|
* @param {*} end
|
|
25
27
|
* @returns
|
|
26
28
|
*/
|
|
27
|
-
export declare const checkIfDateIsInRange: (date:
|
|
29
|
+
export declare const checkIfDateIsInRange: (date: string | Dayjs, start: string | Dayjs, end: string | Dayjs) => boolean;
|
|
28
30
|
/**
|
|
29
31
|
* This is to check if the given event spans a longer duration( quarter long or spans multiple quarter)
|
|
30
32
|
* So as to create a new array for such events
|
|
@@ -32,7 +34,7 @@ export declare const checkIfDateIsInRange: (date: any, start: any, end: any) =>
|
|
|
32
34
|
* @param {*} newEvent
|
|
33
35
|
* @returns
|
|
34
36
|
*/
|
|
35
|
-
export declare const isEventLong: (eventInRow:
|
|
37
|
+
export declare const isEventLong: (eventInRow: CapEventCalendarEvent | FormattedEvent, newEvent: CapEventCalendarEvent | FormattedEvent) => boolean;
|
|
36
38
|
/**
|
|
37
39
|
* In order to decide if events are to be displayed in new row, we follow rules
|
|
38
40
|
* 1- event start and end dates should not be in-between/same of any existing event in the row
|
|
@@ -41,8 +43,8 @@ export declare const isEventLong: (eventInRow: any, newEvent: any) => boolean;
|
|
|
41
43
|
* @param {Number} chosenQuarter
|
|
42
44
|
* @returns
|
|
43
45
|
*/
|
|
44
|
-
export declare const formatDataToSuitCanvas: (events:
|
|
45
|
-
export declare const getFirstDateOfQuarter: (quarter:
|
|
46
|
+
export declare const formatDataToSuitCanvas: (events: CapEventCalendarEvent[]) => FormattedEvent[][];
|
|
47
|
+
export declare const getFirstDateOfQuarter: (quarter: number, year: number) => string;
|
|
46
48
|
/**
|
|
47
49
|
* Check if the year needs to be incremented/decremented based on the following rules
|
|
48
50
|
* For decrement:
|
|
@@ -59,5 +61,5 @@ export declare const getFirstDateOfQuarter: (quarter: any, year: any) => string;
|
|
|
59
61
|
* @param {String} referenceDate
|
|
60
62
|
* @returns
|
|
61
63
|
*/
|
|
62
|
-
export declare const handleYearChange: (quarter:
|
|
64
|
+
export declare const handleYearChange: (quarter: number, date: string, increment: boolean, referenceDate?: string) => [number, string, boolean?] | false;
|
|
63
65
|
//# sourceMappingURL=utils.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../components/CapEventCalendar/utils.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../components/CapEventCalendar/utils.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,OAAO,CAAC;AAMnC,OAAO,KAAK,EAAE,qBAAqB,EAAE,cAAc,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEvF,eAAO,MAAM,iBAAiB,GAAI,MAAM,MAAM,GAAG,KAAK,KAAG,MAA+B,CAAC;AAEzF,eAAO,MAAM,+BAA+B,GAC1C,cAAa,MAAM,EAAiB,KACnC,MAAM,EAAE,EAQV,CAAC;AAEF;;;;;;GAMG;AACH,eAAO,MAAM,mBAAmB,GAC9B,SAAS,MAAM,EACf,YAAY,MAAM,EAAE,EAAE,KACrB,gBAAgB,EAwClB,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,cAAc,GAAI,MAAM,MAAM,GAAG,KAAK,KAAG,MAAM,EAgB3D,CAAC;AAEF;;;;;;;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