impact-ui 4.0.1-alpha.21 → 4.0.1-alpha.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Breadcrumbs/index.d.ts.map +1 -1
- package/dist/components/Breadcrumbs/index.js +3 -1
- package/dist/components/Chart/index.d.ts.map +1 -1
- package/dist/components/Chart/index.js +23 -27
- package/dist/components/Chatbot/bookMarkPanel.d.ts.map +1 -1
- package/dist/components/Chatbot/bookMarkPanel.js +8 -6
- package/dist/components/Chatbot/chatInput.d.ts.map +1 -1
- package/dist/components/Chatbot/chatInput.js +4 -2
- package/dist/components/Chatbot/chatbotModuleMenu.d.ts.map +1 -1
- package/dist/components/Chatbot/chatbotModuleMenu.js +5 -3
- package/dist/components/Chatbot/conversationScreen.d.ts.map +1 -1
- package/dist/components/Chatbot/conversationScreen.js +5 -3
- package/dist/components/Chatbot/historyPanel.d.ts.map +1 -1
- package/dist/components/Chatbot/historyPanel.js +18 -9
- package/dist/components/Chatbot/index.d.ts.map +1 -1
- package/dist/components/Chatbot/index.js +28 -11
- package/dist/components/Chatbot/newChatComponent.d.ts.map +1 -1
- package/dist/components/Chatbot/newChatComponent.js +11 -9
- package/dist/components/Chatbot/utils.d.ts +3 -1
- package/dist/components/Chatbot/utils.d.ts.map +1 -1
- package/dist/components/Chatbot/utils.js +4 -4
- package/dist/components/CommentsPanel/CommentsContext.d.ts.map +1 -1
- package/dist/components/CommentsPanel/CommentsContext.js +18 -15
- package/dist/components/CommentsPanel/CommentsPanel.impl.d.ts.map +1 -1
- package/dist/components/CommentsPanel/CommentsPanel.impl.js +25 -24
- package/dist/components/CreateItemFlow/index.d.ts.map +1 -1
- package/dist/components/CreateItemFlow/index.js +23 -8
- package/dist/components/DatePicker/datePickerFooter.d.ts.map +1 -1
- package/dist/components/DatePicker/datePickerFooter.js +5 -3
- package/dist/components/DatePicker/datePickerInput.d.ts.map +1 -1
- package/dist/components/DatePicker/datePickerInput.js +4 -2
- package/dist/components/DateRangePicker/dateRangePickerCustom.d.ts.map +1 -1
- package/dist/components/DateRangePicker/dateRangePickerCustom.js +5 -3
- package/dist/components/DateRangePicker/dateRangePickerFooter.d.ts.map +1 -1
- package/dist/components/DateRangePicker/dateRangePickerFooter.js +8 -8
- package/dist/components/DateRangePicker/dateRangePickerInput.d.ts.map +1 -1
- package/dist/components/DateRangePicker/dateRangePickerInput.js +4 -2
- package/dist/components/DateRangePicker/index.js +1 -1
- package/dist/components/DateRangePicker/showMonthYearSelect.d.ts.map +1 -1
- package/dist/components/DateRangePicker/showMonthYearSelect.js +4 -2
- package/dist/components/DateRangePicker/utils.d.ts +5 -0
- package/dist/components/DateRangePicker/utils.d.ts.map +1 -1
- package/dist/components/DateRangePicker/utils.js +13 -0
- package/dist/components/FileUpload/TemplatePreview.d.ts.map +1 -1
- package/dist/components/FileUpload/TemplatePreview.js +3 -1
- package/dist/components/FileUpload/index.d.ts.map +1 -1
- package/dist/components/FileUpload/index.js +26 -21
- package/dist/components/FiltersStrip/AppliedFilters.d.ts.map +1 -1
- package/dist/components/FiltersStrip/AppliedFilters.js +9 -7
- package/dist/components/FiltersStrip/FilterDropDown.d.ts.map +1 -1
- package/dist/components/FiltersStrip/FilterDropDown.js +6 -3
- package/dist/components/FiltersStrip/index.d.ts.map +1 -1
- package/dist/components/FiltersStrip/index.js +6 -3
- package/dist/components/Header/Header.types.d.ts +7 -0
- package/dist/components/Header/Header.types.d.ts.map +1 -1
- package/dist/components/Header/index.d.ts +1 -1
- package/dist/components/Header/index.d.ts.map +1 -1
- package/dist/components/Header/index.js +93 -5
- package/dist/components/HomePage/index.d.ts.map +1 -1
- package/dist/components/HomePage/index.js +44 -34
- package/dist/components/KeyboardShortCuts/ShortcutLandingPage.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/ShortcutLandingPage.js +36 -28
- package/dist/components/KeyboardShortCuts/ShortcutModal.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/ShortcutModal.js +4 -2
- package/dist/components/KeyboardShortCuts/allSetBox.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/allSetBox.js +8 -2
- package/dist/components/KeyboardShortCuts/index.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/index.js +7 -5
- package/dist/components/KeyboardShortCuts/screen2.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/screen2.js +4 -2
- package/dist/components/KeyboardShortCuts/screen3.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/screen3.js +4 -2
- package/dist/components/KeyboardShortCuts/tutorial.d.ts.map +1 -1
- package/dist/components/KeyboardShortCuts/tutorial.js +14 -12
- package/dist/components/Loader/index.d.ts.map +1 -1
- package/dist/components/Loader/index.js +5 -2
- package/dist/components/Menu/MenuHeaderInfo.d.ts.map +1 -1
- package/dist/components/Menu/MenuHeaderInfo.js +6 -4
- package/dist/components/Menu/index.d.ts.map +1 -1
- package/dist/components/Menu/index.js +18 -8
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/components/Modal/index.js +5 -3
- package/dist/components/MonthPicker/index.d.ts.map +1 -1
- package/dist/components/MonthPicker/index.js +17 -14
- package/dist/components/MonthRangePicker/index.d.ts +1 -1
- package/dist/components/MonthRangePicker/index.d.ts.map +1 -1
- package/dist/components/MonthRangePicker/index.js +17 -14
- package/dist/components/Notification/NotificationBody/NotificationList/NotificationList.d.ts.map +1 -1
- package/dist/components/Notification/NotificationBody/NotificationList/NotificationList.js +14 -10
- package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.d.ts.map +1 -1
- package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.js +28 -17
- package/dist/components/Notification/NotificationBody/NotificationPanelContent.d.ts.map +1 -1
- package/dist/components/Notification/NotificationBody/NotificationPanelContent.js +1 -1
- package/dist/components/Notification/NotificationBody/NotificationTaskList.d.ts.map +1 -1
- package/dist/components/Notification/NotificationBody/NotificationTaskList.js +7 -5
- package/dist/components/Notification/NotificationBody/index.d.ts.map +1 -1
- package/dist/components/Notification/NotificationBody/index.js +3 -1
- package/dist/components/Notification/index.d.ts.map +1 -1
- package/dist/components/Notification/index.js +1 -1
- package/dist/components/Select/SearchFilter.d.ts.map +1 -1
- package/dist/components/Select/SearchFilter.js +6 -4
- package/dist/components/Select/index.d.ts.map +1 -1
- package/dist/components/Select/index.js +14 -10
- package/dist/components/Select/menuList.d.ts.map +1 -1
- package/dist/components/Select/menuList.js +31 -20
- package/dist/components/Select/utils.d.ts +1 -1
- package/dist/components/Select/utils.d.ts.map +1 -1
- package/dist/components/Select/utils.js +2 -2
- package/dist/components/Sidebar/SidebarActions.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarActions.js +6 -3
- package/dist/components/Sidebar/SidebarMenus.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarMenus.js +3 -4
- package/dist/components/Sidebar/index.d.ts.map +1 -1
- package/dist/components/Sidebar/index.js +6 -4
- package/dist/components/Table/AdvanceSearchModalItem.d.ts.map +1 -1
- package/dist/components/Table/AdvanceSearchModalItem.js +7 -5
- package/dist/components/Table/AdvanceSortModal.d.ts.map +1 -1
- package/dist/components/Table/AdvanceSortModal.js +34 -30
- package/dist/components/Table/AgGridHeader.d.ts.map +1 -1
- package/dist/components/Table/AgGridHeader.js +5 -3
- package/dist/components/Table/CommentsPortal.d.ts +3 -5
- package/dist/components/Table/CommentsPortal.d.ts.map +1 -1
- package/dist/components/Table/CommentsPortal.js +8 -5
- package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModal.d.ts.map +1 -1
- package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModal.js +11 -9
- package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModalItem.d.ts.map +1 -1
- package/dist/components/Table/NewAdvanceSearchModal/NewAdvanceSearchModalItem.js +11 -6
- package/dist/components/Table/NoComments.d.ts.map +1 -1
- package/dist/components/Table/NoComments.js +5 -3
- package/dist/components/Table/actionBar.d.ts.map +1 -1
- package/dist/components/Table/actionBar.js +5 -1
- package/dist/components/Table/advanceSearchModal.d.ts.map +1 -1
- package/dist/components/Table/advanceSearchModal.js +14 -12
- package/dist/components/Table/index.d.ts.map +1 -1
- package/dist/components/Table/index.js +29 -21
- package/dist/components/Table/tableFunctions.d.ts +10 -12
- package/dist/components/Table/tableFunctions.d.ts.map +1 -1
- package/dist/components/Table/tableFunctions.js +59 -53
- package/dist/components/Table/tableHeader.d.ts.map +1 -1
- package/dist/components/Table/tableHeader.js +22 -13
- package/dist/components/Table/tableMoreOptions.d.ts.map +1 -1
- package/dist/components/Table/tableMoreOptions.js +10 -8
- package/dist/components/Table/tablePagination.d.ts.map +1 -1
- package/dist/components/Table/tablePagination.js +16 -6
- package/dist/components/Table/tableSettings.d.ts +1 -1
- package/dist/components/Table/tableSettings.d.ts.map +1 -1
- package/dist/components/Table/tableSettings.js +17 -14
- package/dist/components/Table/withCommentIcon.d.ts.map +1 -1
- package/dist/components/Table/withCommentIcon.js +5 -1
- package/dist/components/TableChat/TableChatSidePanel.d.ts.map +1 -1
- package/dist/components/TableChat/TableChatSidePanel.js +22 -22
- package/dist/components/TableChat/components/SkeletonList.d.ts +1 -1
- package/dist/components/TableChat/components/SkeletonList.d.ts.map +1 -1
- package/dist/components/TableChat/components/SkeletonList.js +6 -1
- package/dist/components/TableChat/components/TableChatLeftSection/AddChatContainer/AddChatContainer.d.ts +2 -1
- package/dist/components/TableChat/components/TableChatLeftSection/AddChatContainer/AddChatContainer.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/AddChatContainer/AddChatContainer.js +37 -29
- package/dist/components/TableChat/components/TableChatLeftSection/ChatChannelItem.d.ts +3 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatChannelItem.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatChannelItem.js +25 -27
- package/dist/components/TableChat/components/TableChatLeftSection/ChatChannelList.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatChannelList.js +45 -3
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderButton/ChatHeaderButton.d.ts +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderButton/ChatHeaderButton.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderButton/ChatHeaderButton.js +4 -2
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderNavigation.d.ts +1 -3
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderNavigation.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/ChatHeaderNavigation.js +5 -3
- package/dist/components/TableChat/components/TableChatLeftSection/TableChatChannelHeader.d.ts +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/TableChatChannelHeader.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatLeftSection/TableChatChannelHeader.js +6 -3
- package/dist/components/TableChat/components/TableChatRightSection/AvatarGroup/AvatarGroup.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/AvatarGroup/AvatarGroup.js +13 -4
- package/dist/components/TableChat/components/TableChatRightSection/ChatDefaultMessageType/ChatDefaultMessageType.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatDefaultMessageType/ChatDefaultMessageType.js +14 -5
- package/dist/components/TableChat/components/TableChatRightSection/ChatDeleteMessageType/ChatDeletedMessageType.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatDeleteMessageType/ChatDeletedMessageType.js +3 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatEditedMessageType /ChatEditedMessageType.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatEditedMessageType /ChatEditedMessageType.js +6 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeader.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeader.js +7 -5
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeaderAction.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeaderAction.js +6 -2
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeaderInfo.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatHeader/ChatHeaderInfo.js +3 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatInput/ChatInput.d.ts +2 -2
- package/dist/components/TableChat/components/TableChatRightSection/ChatInput/ChatInput.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatInput/ChatInput.js +27 -22
- package/dist/components/TableChat/components/TableChatRightSection/ChatMessageActions/ChatMessageActions.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatMessages/ChatMessage.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatMessages/ChatMessage.js +9 -7
- package/dist/components/TableChat/components/TableChatRightSection/ChatNotificationSettings/ChatNotificationSettings.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ChatNotificationSettings/ChatNotificationSettings.js +18 -20
- package/dist/components/TableChat/components/TableChatRightSection/DateSeparator/DateSeparator.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/DateSeparator/DateSeparator.js +5 -3
- package/dist/components/TableChat/components/TableChatRightSection/FileUploader/FileUploader.d.ts +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/FileUploader/FileUploader.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/FileUploader/FileUploader.js +26 -7
- package/dist/components/TableChat/components/TableChatRightSection/ImageUploader/ImageUploader.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/ImageUploader/ImageUploader.js +30 -4
- package/dist/components/TableChat/components/TableChatRightSection/PinedChatPanel/PinedChatPanel.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/PinedChatPanel/PinedChatPanel.js +13 -7
- package/dist/components/TableChat/components/TableChatRightSection/ReplyBadge/ReplyBadge.d.ts +2 -2
- package/dist/components/TableChat/components/TableChatRightSection/ReplyBadge/ReplyBadge.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/TableChatRightSection.d.ts.map +1 -1
- package/dist/components/TableChat/components/TableChatRightSection/TableChatRightSection.js +25 -23
- package/dist/components/TableChat/components/TextEditor/EditorToolbar.d.ts.map +1 -1
- package/dist/components/TableChat/components/TextEditor/EditorToolbar.js +19 -17
- package/dist/components/TableChat/components/TextEditor/Mention.d.ts +1 -2
- package/dist/components/TableChat/components/TextEditor/Mention.d.ts.map +1 -1
- package/dist/components/TableChat/components/TextEditor/Mention.js +6 -3
- package/dist/components/TableChat/components/TextEditor/MentionList.d.ts +1 -2
- package/dist/components/TableChat/components/TextEditor/MentionList.d.ts.map +1 -1
- package/dist/components/TableChat/components/TextEditor/MentionList.js +4 -2
- package/dist/components/TableOld/AgGridHeader.d.ts.map +1 -1
- package/dist/components/TableOld/AgGridHeader.js +5 -3
- package/dist/components/TableOld/actionBar.d.ts.map +1 -1
- package/dist/components/TableOld/actionBar.js +5 -1
- package/dist/components/TableOld/index.d.ts +1 -2
- package/dist/components/TableOld/index.d.ts.map +1 -1
- package/dist/components/TableOld/index.js +14 -8
- package/dist/components/TableOld/tableFunctions.d.ts +10 -12
- package/dist/components/TableOld/tableFunctions.d.ts.map +1 -1
- package/dist/components/TableOld/tableFunctions.js +65 -57
- package/dist/components/TableOld/tableHeader.d.ts.map +1 -1
- package/dist/components/TableOld/tableHeader.js +4 -2
- package/dist/components/TableOld/tablePagination.d.ts.map +1 -1
- package/dist/components/TableOld/tablePagination.js +17 -5
- package/dist/components/TableOld/tableSettings.d.ts.map +1 -1
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +18 -1
- package/dist/i18n/I18nContext.d.ts +23 -0
- package/dist/i18n/I18nContext.d.ts.map +1 -0
- package/dist/i18n/I18nContext.js +58 -0
- package/dist/i18n/index.d.ts +9 -0
- package/dist/i18n/index.d.ts.map +1 -0
- package/dist/i18n/translate.d.ts +15 -0
- package/dist/i18n/translate.d.ts.map +1 -0
- package/dist/i18n/translate.js +22 -0
- package/dist/i18n/types.d.ts +18 -0
- package/dist/i18n/types.d.ts.map +1 -0
- package/dist/i18n/useI18n.d.ts +10 -0
- package/dist/i18n/useI18n.d.ts.map +1 -0
- package/dist/i18n/useI18n.js +28 -0
- package/dist/i18n/useTranslation.d.ts +15 -0
- package/dist/i18n/useTranslation.d.ts.map +1 -0
- package/dist/i18n/useTranslation.js +8 -0
- package/dist/locales/de-DE.json.d.ts +559 -0
- package/dist/locales/de-DE.json.js +503 -0
- package/dist/locales/en-US.json.d.ts +554 -0
- package/dist/locales/en-US.json.js +500 -0
- package/dist/locales/index.d.ts +24 -0
- package/dist/locales/index.d.ts.map +1 -0
- package/dist/locales/index.js +32 -0
- package/dist/mcp-component-registry.json +1 -1
- package/dist/node_modules/moment/dist/locale/de.js +75 -0
- package/dist/node_modules/moment/dist/moment.js +3986 -0
- package/dist/stories/i18nDemo.d.ts +7 -0
- package/dist/stories/i18nDemo.d.ts.map +1 -0
- package/package.json +2 -1
|
@@ -8,10 +8,11 @@ import { Button } from "../Button/index.js";
|
|
|
8
8
|
import { Portal } from "../Portal/index.js";
|
|
9
9
|
import { Select } from "../Select/index.js";
|
|
10
10
|
|
|
11
|
+
import { useTranslation } from "../../i18n/useTranslation.js";
|
|
11
12
|
import IconButton from "../../node_modules/@mui/material/IconButton/IconButton.js";
|
|
12
13
|
const MonthRangePicker = ({
|
|
13
14
|
customYears,
|
|
14
|
-
locale
|
|
15
|
+
locale,
|
|
15
16
|
isMandatory = false,
|
|
16
17
|
displayFormat = "MM/YYYY",
|
|
17
18
|
focusedInput = null,
|
|
@@ -35,6 +36,8 @@ const MonthRangePicker = ({
|
|
|
35
36
|
id,
|
|
36
37
|
"data-testid": dataTestId
|
|
37
38
|
}) => {
|
|
39
|
+
const { t, locale: activeLocale } = useTranslation();
|
|
40
|
+
const effectiveLocale = locale || activeLocale;
|
|
38
41
|
const today = /* @__PURE__ */ new Date();
|
|
39
42
|
const currentYear = today.getFullYear();
|
|
40
43
|
const yrs = Array.from({ length: 10 }, (_, index) => {
|
|
@@ -157,8 +160,8 @@ const MonthRangePicker = ({
|
|
|
157
160
|
};
|
|
158
161
|
const formatDate = (date) => {
|
|
159
162
|
if (!date) return "";
|
|
160
|
-
const month = new Intl.DateTimeFormat(
|
|
161
|
-
const year = new Intl.DateTimeFormat(
|
|
163
|
+
const month = new Intl.DateTimeFormat(effectiveLocale, { month: "2-digit" }).format(date);
|
|
164
|
+
const year = new Intl.DateTimeFormat(effectiveLocale, { year: "numeric" }).format(date);
|
|
162
165
|
if (displayFormat === "YYYY/MM") {
|
|
163
166
|
return `${year}/${month}`;
|
|
164
167
|
}
|
|
@@ -193,7 +196,7 @@ const MonthRangePicker = ({
|
|
|
193
196
|
"button",
|
|
194
197
|
{
|
|
195
198
|
ref: (el) => panelRefs.current[month] = el,
|
|
196
|
-
"aria-label": new Intl.DateTimeFormat(
|
|
199
|
+
"aria-label": new Intl.DateTimeFormat(effectiveLocale, {
|
|
197
200
|
month: "long",
|
|
198
201
|
year: "numeric"
|
|
199
202
|
}).format(monthStart),
|
|
@@ -211,7 +214,7 @@ const MonthRangePicker = ({
|
|
|
211
214
|
},
|
|
212
215
|
onMouseEnter: () => !isDisabled && handleMonthHover(monthStart),
|
|
213
216
|
onMouseLeave: handleMonthLeave,
|
|
214
|
-
children: /* @__PURE__ */ jsx("span", { className: "ia-calendar-month", children: new Intl.DateTimeFormat(
|
|
217
|
+
children: /* @__PURE__ */ jsx("span", { className: "ia-calendar-month", children: new Intl.DateTimeFormat(effectiveLocale, { month: "short" }).format(monthStart) })
|
|
215
218
|
},
|
|
216
219
|
month
|
|
217
220
|
);
|
|
@@ -427,7 +430,7 @@ const MonthRangePicker = ({
|
|
|
427
430
|
"div",
|
|
428
431
|
{
|
|
429
432
|
ref: dropDownContainerRef,
|
|
430
|
-
"aria-label": "
|
|
433
|
+
"aria-label": t("monthRangePicker.ariaDialog"),
|
|
431
434
|
className: "ia-month-picker-container",
|
|
432
435
|
role: "dialog",
|
|
433
436
|
onKeyDown: handleCalendarKeyDown,
|
|
@@ -484,8 +487,8 @@ const MonthRangePicker = ({
|
|
|
484
487
|
] }),
|
|
485
488
|
/* @__PURE__ */ jsx("hr", { className: "ia-vertical-line" }),
|
|
486
489
|
/* @__PURE__ */ jsxs("div", { className: "ia-calendar-button", children: [
|
|
487
|
-
/* @__PURE__ */ jsx(Button, { variant: "tertiary", onClick: handleCancel, children: "
|
|
488
|
-
/* @__PURE__ */ jsx(Button, { onClick: handleApply, children: "
|
|
490
|
+
/* @__PURE__ */ jsx(Button, { variant: "tertiary", onClick: handleCancel, children: t("common.cancel") }),
|
|
491
|
+
/* @__PURE__ */ jsx(Button, { onClick: handleApply, children: t("common.apply") })
|
|
489
492
|
] })
|
|
490
493
|
]
|
|
491
494
|
}
|
|
@@ -498,7 +501,7 @@ const MonthRangePicker = ({
|
|
|
498
501
|
id,
|
|
499
502
|
children: [
|
|
500
503
|
/* @__PURE__ */ jsxs("div", { className: "monthRangePicker-label", children: [
|
|
501
|
-
"
|
|
504
|
+
t("monthPicker.label"),
|
|
502
505
|
isMandatory && /* @__PURE__ */ jsx("span", { style: { color: "red" }, children: "*" })
|
|
503
506
|
] }),
|
|
504
507
|
/* @__PURE__ */ jsxs(
|
|
@@ -516,9 +519,9 @@ const MonthRangePicker = ({
|
|
|
516
519
|
readOnly: true,
|
|
517
520
|
"aria-expanded": openCalendar,
|
|
518
521
|
"aria-haspopup": "dialog",
|
|
519
|
-
"aria-label": "
|
|
522
|
+
"aria-label": t("monthRangePicker.ariaStartMonth"),
|
|
520
523
|
className: `dateRangePicker-input-start-date ${startMonth ? "active" : ""} ${isError ? "error" : ""}`,
|
|
521
|
-
placeholder:
|
|
524
|
+
placeholder: t("monthRangePicker.startPlaceholder", { format: displayFormat }),
|
|
522
525
|
role: "button",
|
|
523
526
|
type: "text",
|
|
524
527
|
value: startMonth ? `${formatDate(startMonth)} -` : "",
|
|
@@ -538,11 +541,11 @@ const MonthRangePicker = ({
|
|
|
538
541
|
readOnly: true,
|
|
539
542
|
"aria-expanded": openCalendar,
|
|
540
543
|
"aria-haspopup": "dialog",
|
|
541
|
-
"aria-label": "
|
|
544
|
+
"aria-label": t("monthRangePicker.ariaEndMonth"),
|
|
542
545
|
className: `dateRangePicker-input-end-date ${isError ? "error" : ""}`,
|
|
543
546
|
label: "EndDate",
|
|
544
547
|
name: "endDate",
|
|
545
|
-
placeholder:
|
|
548
|
+
placeholder: t("monthRangePicker.endPlaceholder", { format: displayFormat }),
|
|
546
549
|
role: "button",
|
|
547
550
|
type: "text",
|
|
548
551
|
value: endMonth ? formatDate(endMonth) : "",
|
|
@@ -558,7 +561,7 @@ const MonthRangePicker = ({
|
|
|
558
561
|
(startMonth || endMonth) && /* @__PURE__ */ jsx(
|
|
559
562
|
"button",
|
|
560
563
|
{
|
|
561
|
-
"aria-label": "
|
|
564
|
+
"aria-label": t("monthRangePicker.ariaClose"),
|
|
562
565
|
className: "close-icon",
|
|
563
566
|
tabIndex: 0,
|
|
564
567
|
type: "button",
|
package/dist/components/Notification/NotificationBody/NotificationList/NotificationList.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationList.d.ts","sourceRoot":"","sources":["../../../../../src/components/Notification/NotificationBody/NotificationList/NotificationList.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NotificationList.d.ts","sourceRoot":"","sources":["../../../../../src/components/Notification/NotificationBody/NotificationList/NotificationList.tsx"],"names":[],"mappings":"AAQA,OAAO,gCAAgC,CAAC;AACxC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,KAAK,EAAE,wBAAwB,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAIhG,MAAM,WAAW,qBAAqB;IACpC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,gBAAgB,EAAE,wBAAwB,EAAE,CAAC;IAC7C,kBAAkB,EAAE,qBAAqB,EAAE,CAAC;IAC5C,qBAAqB,CAAC,EAAE,CAAC,MAAM,EAAE,qBAAqB,EAAE,KAAK,IAAI,CAAC;IAClE,eAAe,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,gBAAgB,CAAC,EAAE,wBAAwB,EAAE,KAAK,IAAI,CAAC;IACzF,iBAAiB,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,gBAAgB,CAAC,EAAE,wBAAwB,EAAE,KAAK,IAAI,CAAC;IAC3F,oBAAoB,CAAC,EAAE,CACrB,IAAI,CAAC,EAAE,MAAM,EACb,aAAa,CAAC,EAAE,wBAAwB,EAAE,EAC1C,cAAc,CAAC,EAAE,OAAO,KACrB,IAAI,CAAC;IACV,4BAA4B,CAAC,EAAE,YAAY,EAAE,CAAC;IAC9C,2BAA2B,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,aAAa,CAAC,EAAE,wBAAwB,EAAE,KAAK,IAAI,CAAC;IAClG,0BAA0B,CAAC,EAAE,OAAO,CAAC;IACrC,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,4BAA4B,CAAC,EAAE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC1D,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,qBAAqB,CAAC,EAAE,MAAM,CAAC;IAC/B,qBAAqB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACzC;AAQD,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,qBAAqB,GAAG,wBAAwB,EAAE,CAMjG;AAED,wBAAgB,gBAAgB,CAAC,EAC/B,MAAc,EACd,IAAI,EACJ,KAAU,EACV,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,2BAA2B,EAC3B,0BAAkC,EAClC,eAAuB,EACvB,aAAmB,EACnB,4BAA4B,EAC5B,eAAoB,EACpB,aAAqB,EACrB,qBAA6B,EAC7B,YAAoB,EACpB,eAAe,EACf,qBAAqB,EACrB,qBAAqB,GACtB,EAAE,qBAAqB,2CA+MvB"}
|
|
@@ -8,6 +8,7 @@ import { Button } from "../../../Button/index.js";
|
|
|
8
8
|
import { Loader } from "../../../Loader/index.js";
|
|
9
9
|
import { Select } from "../../../Select/index.js";
|
|
10
10
|
|
|
11
|
+
import { useTranslation } from "../../../../i18n/useTranslation.js";
|
|
11
12
|
const NotificationEmptyStateIcon = getAssetUrl("icons/notificationEmptyStateIcon.webp");
|
|
12
13
|
function isNotificationListData(value) {
|
|
13
14
|
return Array.isArray(value);
|
|
@@ -33,16 +34,19 @@ function NotificationList({
|
|
|
33
34
|
handleNotificationDeleteAll,
|
|
34
35
|
showNotificationListLoader = false,
|
|
35
36
|
showBadgeLoader = false,
|
|
36
|
-
displayFormat = "
|
|
37
|
+
displayFormat = "L",
|
|
37
38
|
onNotificationScrollToBottom,
|
|
38
39
|
scrollThreshold = 50,
|
|
39
40
|
isHoverOnCard = false,
|
|
40
41
|
isDeleteAlwaysVisible = false,
|
|
41
42
|
isEmptyState = false,
|
|
42
|
-
emptyStateTitle
|
|
43
|
-
emptyStateDescription
|
|
43
|
+
emptyStateTitle,
|
|
44
|
+
emptyStateDescription,
|
|
44
45
|
customNotificationJsx
|
|
45
46
|
}) {
|
|
47
|
+
const { t } = useTranslation();
|
|
48
|
+
const resolvedEmptyStateTitle = emptyStateTitle ?? t("notification.emptyStateTitle");
|
|
49
|
+
const resolvedEmptyStateDescription = emptyStateDescription ?? t("notification.emptyStateDescription");
|
|
46
50
|
const isLoading = useRef(false);
|
|
47
51
|
const [moveToPendingOpen, setMoveToPendingOpen] = useState(false);
|
|
48
52
|
const [currentOptions, setCurrentOptions] = useState(
|
|
@@ -74,14 +78,14 @@ function NotificationList({
|
|
|
74
78
|
/* @__PURE__ */ jsx(
|
|
75
79
|
"img",
|
|
76
80
|
{
|
|
77
|
-
alt: "notification
|
|
81
|
+
alt: t("notification.emptyStateAlt"),
|
|
78
82
|
className: "impact-notification-list-empty-state-icon",
|
|
79
83
|
src: NotificationEmptyStateIcon
|
|
80
84
|
}
|
|
81
85
|
),
|
|
82
86
|
/* @__PURE__ */ jsxs("div", { className: "impact-notification-list-empty-state-content", children: [
|
|
83
|
-
/* @__PURE__ */ jsx("span", { className: "impact-notification-list-empty-state-title", children:
|
|
84
|
-
/* @__PURE__ */ jsx("span", { className: "impact-notification-list-empty-state-description", children:
|
|
87
|
+
/* @__PURE__ */ jsx("span", { className: "impact-notification-list-empty-state-title", children: resolvedEmptyStateTitle }),
|
|
88
|
+
/* @__PURE__ */ jsx("span", { className: "impact-notification-list-empty-state-description", children: resolvedEmptyStateDescription })
|
|
85
89
|
] })
|
|
86
90
|
] });
|
|
87
91
|
}
|
|
@@ -105,7 +109,7 @@ function NotificationList({
|
|
|
105
109
|
}));
|
|
106
110
|
handleSelectAll(type, updatedNotificationList);
|
|
107
111
|
},
|
|
108
|
-
children: notificationList.length > 0 && notificationList.every((item) => item.selected) ? "
|
|
112
|
+
children: notificationList.length > 0 && notificationList.every((item) => item.selected) ? t("notification.deselectAll") : t("notification.selectAll")
|
|
109
113
|
}
|
|
110
114
|
),
|
|
111
115
|
handleMarkReadAll && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
@@ -118,14 +122,14 @@ function NotificationList({
|
|
|
118
122
|
onClick: () => {
|
|
119
123
|
handleMarkReadAll(type, notificationList);
|
|
120
124
|
},
|
|
121
|
-
children: "
|
|
125
|
+
children: t("notification.markAllAsRead")
|
|
122
126
|
}
|
|
123
127
|
)
|
|
124
128
|
] }),
|
|
125
129
|
handleMoveAllPending && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
126
130
|
/* @__PURE__ */ jsx("span", { className: "impact-notification-separator" }),
|
|
127
131
|
moveToPendingDropdownOptions ? /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
128
|
-
/* @__PURE__ */ jsx("p", { style: { fontSize: "12px" }, children: "
|
|
132
|
+
/* @__PURE__ */ jsx("p", { style: { fontSize: "12px" }, children: t("notification.moveTo") }),
|
|
129
133
|
/* @__PURE__ */ jsx(
|
|
130
134
|
Select,
|
|
131
135
|
{
|
|
@@ -162,7 +166,7 @@ function NotificationList({
|
|
|
162
166
|
notificationList.filter((item) => item.selected)
|
|
163
167
|
);
|
|
164
168
|
},
|
|
165
|
-
children: "
|
|
169
|
+
children: t("notification.moveToPending")
|
|
166
170
|
}
|
|
167
171
|
)
|
|
168
172
|
] }),
|
package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationListItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/Notification/NotificationBody/NotificationList/NotificationListItem.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NotificationListItem.d.ts","sourceRoot":"","sources":["../../../../../src/components/Notification/NotificationBody/NotificationList/NotificationListItem.tsx"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EACV,wBAAwB,EAExB,qBAAqB,EACtB,MAAM,0BAA0B,CAAC;AAiGlC,UAAU,yBAAyB;IACjC,IAAI,EAAE,wBAAwB,CAAC;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,kBAAkB,EAAE,qBAAqB,EAAE,CAAC;IAC5C,qBAAqB,CAAC,EAAE,CAAC,MAAM,EAAE,qBAAqB,EAAE,KAAK,IAAI,CAAC;IAClE,aAAa,EAAE,MAAM,CAAC;IACtB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,qBAAqB,CAAC,EAAE,OAAO,CAAC;CACjC;AAmDD,wBAAgB,oBAAoB,CAAC,EACnC,IAAI,EACJ,IAAI,EACJ,kBAAkB,EAClB,qBAAqB,EACrB,aAAa,EACb,aAAqB,EACrB,qBAA6B,GAC9B,EAAE,yBAAyB,2CA0Z3B"}
|
package/dist/components/Notification/NotificationBody/NotificationList/NotificationListItem.js
CHANGED
|
@@ -10,6 +10,7 @@ import { Badge } from "../../../Badge/index.js";
|
|
|
10
10
|
import { Button } from "../../../Button/index.js";
|
|
11
11
|
import { Checkbox } from "../../../Checkbox/index.js";
|
|
12
12
|
import { Tooltip } from "../../../Tooltip/index.js";
|
|
13
|
+
import { useTranslation } from "../../../../i18n/useTranslation.js";
|
|
13
14
|
const OpenInNewIcon = getAssetUrl("icons/OpenInNew.svg");
|
|
14
15
|
const SyncReloadIcon = getAssetUrl("icons/SyncReload.svg");
|
|
15
16
|
const NOTIFICATION_DESCRIPTION_VISIBLE_MAX = 150;
|
|
@@ -135,6 +136,7 @@ function NotificationListItem({
|
|
|
135
136
|
isHoverOnCard = false,
|
|
136
137
|
isDeleteAlwaysVisible = false
|
|
137
138
|
}) {
|
|
139
|
+
const { t } = useTranslation();
|
|
138
140
|
const [showMore, setShowMore] = useState(false);
|
|
139
141
|
const titleRef = useRef(null);
|
|
140
142
|
const [isTitleTruncated, setIsTitleTruncated] = useState(false);
|
|
@@ -198,6 +200,7 @@ function NotificationListItem({
|
|
|
198
200
|
return /* @__PURE__ */ jsxs(
|
|
199
201
|
"div",
|
|
200
202
|
{
|
|
203
|
+
"aria-label": t("notification.itemAriaLabel"),
|
|
201
204
|
className: `impact-notification-list-item ${list.selected ? "list-item-selected" : ""} ${!list.read ? "list-item-read" : ""} ${isHoverOnCard ? "impact-notification-list-item-hover-on-card" : ""}`,
|
|
202
205
|
role: "button",
|
|
203
206
|
tabIndex: 0,
|
|
@@ -296,26 +299,34 @@ function NotificationListItem({
|
|
|
296
299
|
list.titleIconsContent
|
|
297
300
|
] }),
|
|
298
301
|
showHeaderIcons && /* @__PURE__ */ jsx("span", { className: "impact-notification-separator" }),
|
|
299
|
-
list.showNOverdueIcon && /* @__PURE__ */ jsx(Tooltip, { orientation: "top", title: "
|
|
302
|
+
list.showNOverdueIcon && /* @__PURE__ */ jsx(Tooltip, { orientation: "top", title: t("notification.noOverdue"), variant: "tertiary", children: /* @__PURE__ */ jsx(
|
|
300
303
|
NotificationRead_default,
|
|
301
304
|
{
|
|
302
305
|
"aria-hidden": void 0,
|
|
303
|
-
"aria-label": "notification
|
|
306
|
+
"aria-label": t("notification.readAlt"),
|
|
304
307
|
height: 16,
|
|
305
308
|
role: "img",
|
|
306
309
|
width: 16
|
|
307
310
|
}
|
|
308
311
|
) }),
|
|
309
|
-
list.showFastApproachingIcon && /* @__PURE__ */ jsx(
|
|
310
|
-
|
|
312
|
+
list.showFastApproachingIcon && /* @__PURE__ */ jsx(
|
|
313
|
+
Tooltip,
|
|
311
314
|
{
|
|
312
|
-
"
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
315
|
+
orientation: "top",
|
|
316
|
+
title: t("notification.fastApproaching"),
|
|
317
|
+
variant: "tertiary",
|
|
318
|
+
children: /* @__PURE__ */ jsx(
|
|
319
|
+
NotificationBookmark_default,
|
|
320
|
+
{
|
|
321
|
+
"aria-hidden": void 0,
|
|
322
|
+
"aria-label": t("notification.bookmarkAlt"),
|
|
323
|
+
height: 16,
|
|
324
|
+
role: "img",
|
|
325
|
+
width: 16
|
|
326
|
+
}
|
|
327
|
+
)
|
|
317
328
|
}
|
|
318
|
-
)
|
|
329
|
+
)
|
|
319
330
|
]
|
|
320
331
|
}
|
|
321
332
|
),
|
|
@@ -401,14 +412,14 @@ function NotificationListItem({
|
|
|
401
412
|
/* @__PURE__ */ jsxs("div", { className: "impact-notification-list-item-schedule", children: [
|
|
402
413
|
/* @__PURE__ */ jsx("div", { className: "impact-notification-list-item-date", children: moment(list.date).format(displayFormat) }),
|
|
403
414
|
/* @__PURE__ */ jsx("div", { className: "impact-notification-list-item-separator", children: "-" }),
|
|
404
|
-
/* @__PURE__ */ jsx("div", { className: "impact-notification-list-item-date", children: moment(list.time).format("
|
|
415
|
+
/* @__PURE__ */ jsx("div", { className: "impact-notification-list-item-date", children: moment(list.time).format("LTS") }),
|
|
405
416
|
list.bookMarked && /* @__PURE__ */ jsx(
|
|
406
417
|
Badge,
|
|
407
418
|
{
|
|
408
419
|
isIcon: true,
|
|
409
420
|
color: "info",
|
|
410
421
|
icon: /* @__PURE__ */ jsx(default_1$1, {}),
|
|
411
|
-
label: "
|
|
422
|
+
label: t("notification.bookmarked"),
|
|
412
423
|
size: "small",
|
|
413
424
|
variant: "subtle"
|
|
414
425
|
}
|
|
@@ -441,7 +452,7 @@ function NotificationListItem({
|
|
|
441
452
|
setShowMore((prev) => !prev);
|
|
442
453
|
}
|
|
443
454
|
},
|
|
444
|
-
children: "
|
|
455
|
+
children: t("notification.readMore")
|
|
445
456
|
}
|
|
446
457
|
)
|
|
447
458
|
] }) : /* @__PURE__ */ jsx(
|
|
@@ -460,7 +471,7 @@ function NotificationListItem({
|
|
|
460
471
|
setShowMore((prev) => !prev);
|
|
461
472
|
}
|
|
462
473
|
},
|
|
463
|
-
children: "
|
|
474
|
+
children: t("notification.readLess")
|
|
464
475
|
}
|
|
465
476
|
)
|
|
466
477
|
] }) : /* @__PURE__ */ jsx(
|
|
@@ -486,7 +497,7 @@ function NotificationListItem({
|
|
|
486
497
|
list
|
|
487
498
|
);
|
|
488
499
|
},
|
|
489
|
-
children: "
|
|
500
|
+
children: t("notification.markAsCompleted")
|
|
490
501
|
}
|
|
491
502
|
),
|
|
492
503
|
list.handleMoveToPending && /* @__PURE__ */ jsx(
|
|
@@ -504,7 +515,7 @@ function NotificationListItem({
|
|
|
504
515
|
list
|
|
505
516
|
);
|
|
506
517
|
},
|
|
507
|
-
children: list.moveToPendingText ?? "
|
|
518
|
+
children: list.moveToPendingText ?? t("notification.moveToPending")
|
|
508
519
|
}
|
|
509
520
|
),
|
|
510
521
|
list.customActionContent,
|
|
@@ -523,7 +534,7 @@ function NotificationListItem({
|
|
|
523
534
|
list
|
|
524
535
|
);
|
|
525
536
|
},
|
|
526
|
-
children: !list.read ? "
|
|
537
|
+
children: !list.read ? t("notification.markAsRead") : t("notification.markAsUnread")
|
|
527
538
|
}
|
|
528
539
|
)
|
|
529
540
|
] })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationPanelContent.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/NotificationPanelContent.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAEnE,KAAK,6BAA6B,GAAG,qBAAqB,GAAG;IAC3D,KAAK,EAAE,qBAAqB,CAAC;CAC9B,CAAC;AAEF,wBAAgB,wBAAwB,CAAC,EACvC,KAAK,EACL,MAAc,EACd,UAAU,EACV,kBAAkB,EAClB,qBAAqB,EACrB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,2BAA2B,EAC3B,0BAA0B,EAC1B,eAAe,EACf,
|
|
1
|
+
{"version":3,"file":"NotificationPanelContent.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/NotificationPanelContent.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AACtE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAEnE,KAAK,6BAA6B,GAAG,qBAAqB,GAAG;IAC3D,KAAK,EAAE,qBAAqB,CAAC;CAC9B,CAAC;AAEF,wBAAgB,wBAAwB,CAAC,EACvC,KAAK,EACL,MAAc,EACd,UAAU,EACV,kBAAkB,EAClB,qBAAqB,EACrB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,4BAA4B,EAC5B,2BAA2B,EAC3B,0BAA0B,EAC1B,eAAe,EACf,aAAmB,EACnB,4BAA4B,EAC5B,eAAe,EACf,YAAY,EACZ,iBAAiB,EACjB,aAAa,EACb,qBAAqB,EACrB,YAAY,EACZ,eAAe,EACf,qBAAqB,EACrB,qBAAqB,EACrB,WAAW,GACZ,EAAE,6BAA6B,2CA2C/B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NotificationTaskList.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/NotificationTaskList.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"NotificationTaskList.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/NotificationTaskList.tsx"],"names":[],"mappings":"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"}
|
|
@@ -7,6 +7,7 @@ import { Button } from "../../Button/index.js";
|
|
|
7
7
|
import { Input } from "../../Input/index.js";
|
|
8
8
|
import { NotificationChipsList } from "./NotificationList/NotificationChipsList.js";
|
|
9
9
|
import { NotificationList } from "./NotificationList/NotificationList.js";
|
|
10
|
+
import { useTranslation } from "../../../i18n/useTranslation.js";
|
|
10
11
|
function NotificationTaskList({
|
|
11
12
|
expand = false,
|
|
12
13
|
type,
|
|
@@ -27,7 +28,7 @@ function NotificationTaskList({
|
|
|
27
28
|
showBadgeLoader,
|
|
28
29
|
showNotificationListLoader,
|
|
29
30
|
selectedFilterChip,
|
|
30
|
-
displayFormat = "
|
|
31
|
+
displayFormat = "L",
|
|
31
32
|
onNotificationScrollToBottom,
|
|
32
33
|
scrollThreshold,
|
|
33
34
|
isWithSearch = true,
|
|
@@ -40,6 +41,7 @@ function NotificationTaskList({
|
|
|
40
41
|
customNotificationJsx
|
|
41
42
|
}) {
|
|
42
43
|
var _a;
|
|
44
|
+
const { t } = useTranslation();
|
|
43
45
|
const [list, setList] = useState(listTypes);
|
|
44
46
|
const [currActiveListType, setCurrActiveListType] = useState(
|
|
45
47
|
activeBadge ?? ((_a = listTypes[0]) == null ? void 0 : _a.label) ?? ""
|
|
@@ -143,7 +145,7 @@ function NotificationTaskList({
|
|
|
143
145
|
Input,
|
|
144
146
|
{
|
|
145
147
|
ref: searchInputRef,
|
|
146
|
-
placeholder: "
|
|
148
|
+
placeholder: t("notification.searchPlaceholder"),
|
|
147
149
|
rightIcon: /* @__PURE__ */ jsx(default_1, {}),
|
|
148
150
|
rightIconClick: () => {
|
|
149
151
|
if (expandList) {
|
|
@@ -172,8 +174,8 @@ function NotificationTaskList({
|
|
|
172
174
|
),
|
|
173
175
|
showFilter && filterChip && filterChip.length > 0 && /* @__PURE__ */ jsxs("div", { className: "impact-notification-task-list-filter-container", children: [
|
|
174
176
|
/* @__PURE__ */ jsxs("div", { className: "impact-notification-task-list-title", children: [
|
|
175
|
-
/* @__PURE__ */ jsx("span", { className: "impact-notification-task-list-title-text", children: "
|
|
176
|
-
/* @__PURE__ */ jsx("span", { className: "impact-notification-task-list-title-text-sub", children: isMultiSelectFilter ? "
|
|
177
|
+
/* @__PURE__ */ jsx("span", { className: "impact-notification-task-list-title-text", children: t("notification.selectFilter") }),
|
|
178
|
+
/* @__PURE__ */ jsx("span", { className: "impact-notification-task-list-title-text-sub", children: isMultiSelectFilter ? t("notification.multiSelect") : t("notification.singleSelect") })
|
|
177
179
|
] }),
|
|
178
180
|
/* @__PURE__ */ jsx("div", { className: "impact-notification-task-list-filter-item", children: filterChip.map((item) => {
|
|
179
181
|
const isSelected = isMultiSelectFilter ? Array.isArray(selectedFilter) && selectedFilter.some((filter) => filter.value === item.value) : (selectedFilter == null ? void 0 : selectedFilter.value) === item.value;
|
|
@@ -209,7 +211,7 @@ function NotificationTaskList({
|
|
|
209
211
|
handleApplyFilter == null ? void 0 : handleApplyFilter(selectedFilter);
|
|
210
212
|
setShowFilter(false);
|
|
211
213
|
},
|
|
212
|
-
children: "
|
|
214
|
+
children: t("common.apply")
|
|
213
215
|
}
|
|
214
216
|
)
|
|
215
217
|
] })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/Notification/NotificationBody/index.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAItE,YAAY,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AAEtE;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,MAAc,EACd,gBAAgB,EAChB,kBAAkB,EAClB,oBAAoB,EACpB,eAAe,EACf,aAAa,EACb,WAAW,EACX,GAAG,UAAU,EACd,EAAE,qBAAqB,2CAoEvB;yBA7Ee,gBAAgB"}
|
|
@@ -4,6 +4,7 @@ import default_1 from "../../../node_modules/@mui/icons-material/SettingsOutline
|
|
|
4
4
|
import { NotificationPanelContent } from "./NotificationPanelContent.js";
|
|
5
5
|
import { Button } from "../../Button/index.js";
|
|
6
6
|
import { Tabs } from "../../Tabs/index.js";
|
|
7
|
+
import { useTranslation } from "../../../i18n/useTranslation.js";
|
|
7
8
|
function NotificationBody({
|
|
8
9
|
expand = false,
|
|
9
10
|
notificationTabs,
|
|
@@ -15,6 +16,7 @@ function NotificationBody({
|
|
|
15
16
|
...panelProps
|
|
16
17
|
}) {
|
|
17
18
|
var _a;
|
|
19
|
+
const { t } = useTranslation();
|
|
18
20
|
const tabs = notificationTabs.length > 0 ? notificationTabs : [{ label: "All", value: "all" }];
|
|
19
21
|
const panels = notificationPanels.length > 0 ? notificationPanels : [{ id: 0, value: "all" }];
|
|
20
22
|
const [activeTab, setActiveTab] = useState(((_a = tabs[0]) == null ? void 0 : _a.value) ?? "");
|
|
@@ -71,7 +73,7 @@ function NotificationBody({
|
|
|
71
73
|
size: "medium",
|
|
72
74
|
variant: "text",
|
|
73
75
|
onClick: onSettingButtonClick,
|
|
74
|
-
children: "
|
|
76
|
+
children: t("notification.settingAndHelp")
|
|
75
77
|
}
|
|
76
78
|
)
|
|
77
79
|
] })
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Notification/index.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,iBAAiB,EAAgB,MAAM,sBAAsB,CAAC;AAC5E,OAAO,4BAA4B,CAAC;AAEpC,YAAY,EAAE,iBAAiB,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAC5E,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,MAAgB,EAChB,MAAM,EACN,SAAS,EACT,SAAS,EACT,WAAW,EACX,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,2BAA2B,EAC3B,UAAU,EACV,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,eAA0B,EAC1B,4BAA4B,EAC5B,aAAa,EACb,WAAW,EACX,eAAe,EACf,0BAA0B,EAC1B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Notification/index.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,iBAAiB,EAAgB,MAAM,sBAAsB,CAAC;AAC5E,OAAO,4BAA4B,CAAC;AAEpC,YAAY,EAAE,iBAAiB,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAC5E,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1D,OAAO,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE1D,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,MAAgB,EAChB,MAAM,EACN,SAAS,EACT,SAAS,EACT,WAAW,EACX,oBAAoB,EACpB,sBAAsB,EACtB,kBAAkB,EAClB,oBAAoB,EACpB,oBAAoB,EACpB,eAAe,EACf,iBAAiB,EACjB,oBAAoB,EACpB,2BAA2B,EAC3B,UAAU,EACV,gBAAgB,EAChB,kBAAkB,EAClB,qBAAqB,EACrB,eAA0B,EAC1B,4BAA4B,EAC5B,aAAa,EACb,WAAW,EACX,eAAe,EACf,0BAA0B,EAC1B,aAAmB,EACnB,4BAA4B,EAC5B,eAAe,EACf,YAAmB,EACnB,aAAqB,EACrB,iBAAyB,EACzB,qBAA6B,EAC7B,YAAY,EACZ,eAAe,EACf,qBAAqB,EACrB,qBAAqB,EACrB,yBAAyB,GAC1B,EAAE,iBAAiB,2CA6EnB;yBAnHe,YAAY"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SearchFilter.d.ts","sourceRoot":"","sources":["../../../src/components/Select/SearchFilter.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAExD,QAAA,MAAM,YAAY,
|
|
1
|
+
{"version":3,"file":"SearchFilter.d.ts","sourceRoot":"","sources":["../../../src/components/Select/SearchFilter.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAExD,QAAA,MAAM,YAAY,gHAyLjB,CAAC;AAIF,eAAe,YAAY,CAAC"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef, useEffect, useCallback } from "react";
|
|
3
3
|
import { Checkbox } from "../Checkbox/index.js";
|
|
4
|
+
import { useTranslation } from "../../i18n/useTranslation.js";
|
|
4
5
|
const SearchFilter = forwardRef(
|
|
5
6
|
({
|
|
6
7
|
isClearable,
|
|
@@ -26,6 +27,7 @@ const SearchFilter = forwardRef(
|
|
|
26
27
|
highlightedIndex = -1,
|
|
27
28
|
isSelectAllHighlighted = false
|
|
28
29
|
}, ref) => {
|
|
30
|
+
const { t } = useTranslation();
|
|
29
31
|
const selectedArr = Array.isArray(selectedOptions) ? selectedOptions : [];
|
|
30
32
|
const hasSelectAll = !!(isMulti && toggleSelectAll && !isLoading);
|
|
31
33
|
useEffect(() => {
|
|
@@ -117,7 +119,7 @@ const SearchFilter = forwardRef(
|
|
|
117
119
|
"input",
|
|
118
120
|
{
|
|
119
121
|
ref,
|
|
120
|
-
"aria-label": searchPlaceholder ?? "
|
|
122
|
+
"aria-label": searchPlaceholder ?? t("select.searchAriaLabel"),
|
|
121
123
|
autoComplete: "off",
|
|
122
124
|
className: "ia-select-search-box",
|
|
123
125
|
placeholder: searchPlaceholder,
|
|
@@ -141,7 +143,7 @@ const SearchFilter = forwardRef(
|
|
|
141
143
|
checked: isSelectAll,
|
|
142
144
|
className: "select-selectAll-checkbox",
|
|
143
145
|
id: "select-all",
|
|
144
|
-
label: isSelectAll ? selectionLabels.deselectAll ?? "
|
|
146
|
+
label: isSelectAll ? selectionLabels.deselectAll ?? t("select.deselectAllLabel") : selectionLabels.selectAll ?? t("select.selectAllLabel"),
|
|
145
147
|
name: "select-all",
|
|
146
148
|
onChange: onSelectAll
|
|
147
149
|
}
|
|
@@ -149,7 +151,7 @@ const SearchFilter = forwardRef(
|
|
|
149
151
|
isClearable && selectedArr.length > 0 && /* @__PURE__ */ jsx(
|
|
150
152
|
"button",
|
|
151
153
|
{
|
|
152
|
-
"aria-label": "
|
|
154
|
+
"aria-label": t("select.ariaClearAll"),
|
|
153
155
|
className: "ia-select-clear-all-button",
|
|
154
156
|
type: "button",
|
|
155
157
|
onClick: () => {
|
|
@@ -162,7 +164,7 @@ const SearchFilter = forwardRef(
|
|
|
162
164
|
onClearAll();
|
|
163
165
|
}
|
|
164
166
|
},
|
|
165
|
-
children: "
|
|
167
|
+
children: t("common.clear")
|
|
166
168
|
}
|
|
167
169
|
)
|
|
168
170
|
]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Select/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Select/index.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4D,MAAM,OAAO,CAAC;AA0BjF,OAAO,KAAK,EAAE,WAAW,EAAkC,MAAM,gBAAgB,CAAC;AAClF,OAAO,sBAAsB,CAAC;AAE9B,YAAY,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAgBhE,eAAO,MAAM,MAAM,yCAy2CjB,CAAC"}
|