@natoora-libs/core 0.2.11-dev-doug-2 → 0.2.12-dev-doug-1
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.
|
@@ -30,6 +30,8 @@ interface AlertDialogProps {
|
|
|
30
30
|
rejectCopy?: string;
|
|
31
31
|
acceptCopy?: string;
|
|
32
32
|
disabledContentPadding?: boolean;
|
|
33
|
+
disableEnforceFocus?: boolean;
|
|
34
|
+
disableRestoreFocus?: boolean;
|
|
33
35
|
}
|
|
34
36
|
declare const AlertDialog: React.FC<AlertDialogProps>;
|
|
35
37
|
|
|
@@ -1072,4 +1074,4 @@ declare const SvgIconCompare: (props: SVGProps<SVGSVGElement>) => react_jsx_runt
|
|
|
1072
1074
|
|
|
1073
1075
|
declare const SvgIconChart: (props: SVGProps<SVGSVGElement>) => react_jsx_runtime.JSX.Element;
|
|
1074
1076
|
|
|
1075
|
-
export { ActiveFiltersIconButton, AlertDialog, AlertDialogFullScreen, AppLabel, AppliedTableFiltersDisplay, AutocompleteFilterMenuContent, BackHeader, BottomBar, _default$k as BoxButton, CheckboxFilterMenuContent, ClearFiltersConfirmationDialog, CompanyLogo, ConfirmationDialog, ControlledCheckbox, ControlledNumberInput, ControlledNumericField, ControlledSelectWithArray, ControlledSelectWithObject, ControlledValidTextInput, DataGrid, Date, _default$c as DeleteSubstitutionDialogContent, _default$b as DeleteUserDialogContent, DynamicOverflowTooltip, _default$j as ExtendedButton, FileCard, _default$i as FilledButton, _default$h as FilledButtonLg, _default$a as FilledLabel, FilterGroupSelector, FilterOptionsCheckboxes, FilterSimpleSelector, _default$9 as FixedFooter, HeadCell, Header, HeaderFilterObject, HeaderFilterOptions, HeaderFilters, SvgIconChart as IconChart, SvgIconCompare as IconCompare, _default$g as ImageButton, LabeledValueList, VirtualizedList as List, Loading, LocationsSectionInfo, Notes, Numpad, _default$8 as NumpadInput, NumpadPlus, Order, _default$f as OutlinedButton, _default$e as OutlinedButtonLg, PaginationForTable as Pagination, PhoneInput, _default$d as Pin, ActionButton as PinnedApp, PlusMinusInput, ProductBust, ProductImage, RenderAvatar, RenderContentList, RoundButton, RowId, RowProductCard, ScrollableDialog, SearchAndFilterHeader, _default$7 as SearchAndFilterHeaderForTable, SearchFieldDebounced, SearchHeader, _default$6 as SearchWithFilters, _default$5 as SearchWithFiltersForTable, SectionName, SmartMultipleSelect, SmartSelect, SmartTableHeader, SmartTableHeaderFilterMenu, SquareButton, _default$4 as SquareLabel, _default$3 as Switch, Table, TableDesktopCell, TableDesktopEditableField, TableEmptyResult, _default$2 as TableHeader, TableLoading, TextDivider, _default$1 as TheToolbar, ThemedDateRangePicker, ToastMessage, TwoButtonDialog, UploadButton, _default as UserBust, icons };
|
|
1077
|
+
export { ActiveFiltersIconButton, AlertDialog, AlertDialogFullScreen, AppLabel, AppliedTableFiltersDisplay, AutocompleteFilterMenuContent, BackHeader, BottomBar, _default$k as BoxButton, CheckboxFilterMenuContent, ClearFiltersConfirmationDialog, CompanyLogo, ConfirmationDialog, ControlledCheckbox, ControlledNumberInput, ControlledNumericField, ControlledSelectWithArray, ControlledSelectWithObject, ControlledValidTextInput, DataGrid, Date, _default$c as DeleteSubstitutionDialogContent, _default$b as DeleteUserDialogContent, DynamicOverflowTooltip, _default$j as ExtendedButton, FileCard, _default$i as FilledButton, _default$h as FilledButtonLg, _default$a as FilledLabel, FilterGroupSelector, FilterOptionsCheckboxes, FilterSimpleSelector, _default$9 as FixedFooter, HeadCell, Header, HeaderFilterObject, HeaderFilterOptions, HeaderFilters, SvgIconChart as IconChart, SvgIconCompare as IconCompare, _default$g as ImageButton, LabeledValueList, VirtualizedList as List, Loading, LocationsSectionInfo, Notes, Numpad, _default$8 as NumpadInput, NumpadPlus, type Option, Order, _default$f as OutlinedButton, _default$e as OutlinedButtonLg, PaginationForTable as Pagination, PhoneInput, _default$d as Pin, ActionButton as PinnedApp, PlusMinusInput, ProductBust, ProductImage, RenderAvatar, RenderContentList, RoundButton, RowId, RowProductCard, ScrollableDialog, SearchAndFilterHeader, _default$7 as SearchAndFilterHeaderForTable, SearchFieldDebounced, SearchHeader, _default$6 as SearchWithFilters, _default$5 as SearchWithFiltersForTable, SectionName, SmartMultipleSelect, SmartSelect, SmartTableHeader, SmartTableHeaderFilterMenu, SquareButton, _default$4 as SquareLabel, _default$3 as Switch, Table, TableDesktopCell, TableDesktopEditableField, TableEmptyResult, _default$2 as TableHeader, TableLoading, TextDivider, _default$1 as TheToolbar, ThemedDateRangePicker, ToastMessage, TwoButtonDialog, UploadButton, _default as UserBust, icons };
|
|
@@ -30,6 +30,8 @@ interface AlertDialogProps {
|
|
|
30
30
|
rejectCopy?: string;
|
|
31
31
|
acceptCopy?: string;
|
|
32
32
|
disabledContentPadding?: boolean;
|
|
33
|
+
disableEnforceFocus?: boolean;
|
|
34
|
+
disableRestoreFocus?: boolean;
|
|
33
35
|
}
|
|
34
36
|
declare const AlertDialog: React.FC<AlertDialogProps>;
|
|
35
37
|
|
|
@@ -1072,4 +1074,4 @@ declare const SvgIconCompare: (props: SVGProps<SVGSVGElement>) => react_jsx_runt
|
|
|
1072
1074
|
|
|
1073
1075
|
declare const SvgIconChart: (props: SVGProps<SVGSVGElement>) => react_jsx_runtime.JSX.Element;
|
|
1074
1076
|
|
|
1075
|
-
export { ActiveFiltersIconButton, AlertDialog, AlertDialogFullScreen, AppLabel, AppliedTableFiltersDisplay, AutocompleteFilterMenuContent, BackHeader, BottomBar, _default$k as BoxButton, CheckboxFilterMenuContent, ClearFiltersConfirmationDialog, CompanyLogo, ConfirmationDialog, ControlledCheckbox, ControlledNumberInput, ControlledNumericField, ControlledSelectWithArray, ControlledSelectWithObject, ControlledValidTextInput, DataGrid, Date, _default$c as DeleteSubstitutionDialogContent, _default$b as DeleteUserDialogContent, DynamicOverflowTooltip, _default$j as ExtendedButton, FileCard, _default$i as FilledButton, _default$h as FilledButtonLg, _default$a as FilledLabel, FilterGroupSelector, FilterOptionsCheckboxes, FilterSimpleSelector, _default$9 as FixedFooter, HeadCell, Header, HeaderFilterObject, HeaderFilterOptions, HeaderFilters, SvgIconChart as IconChart, SvgIconCompare as IconCompare, _default$g as ImageButton, LabeledValueList, VirtualizedList as List, Loading, LocationsSectionInfo, Notes, Numpad, _default$8 as NumpadInput, NumpadPlus, Order, _default$f as OutlinedButton, _default$e as OutlinedButtonLg, PaginationForTable as Pagination, PhoneInput, _default$d as Pin, ActionButton as PinnedApp, PlusMinusInput, ProductBust, ProductImage, RenderAvatar, RenderContentList, RoundButton, RowId, RowProductCard, ScrollableDialog, SearchAndFilterHeader, _default$7 as SearchAndFilterHeaderForTable, SearchFieldDebounced, SearchHeader, _default$6 as SearchWithFilters, _default$5 as SearchWithFiltersForTable, SectionName, SmartMultipleSelect, SmartSelect, SmartTableHeader, SmartTableHeaderFilterMenu, SquareButton, _default$4 as SquareLabel, _default$3 as Switch, Table, TableDesktopCell, TableDesktopEditableField, TableEmptyResult, _default$2 as TableHeader, TableLoading, TextDivider, _default$1 as TheToolbar, ThemedDateRangePicker, ToastMessage, TwoButtonDialog, UploadButton, _default as UserBust, icons };
|
|
1077
|
+
export { ActiveFiltersIconButton, AlertDialog, AlertDialogFullScreen, AppLabel, AppliedTableFiltersDisplay, AutocompleteFilterMenuContent, BackHeader, BottomBar, _default$k as BoxButton, CheckboxFilterMenuContent, ClearFiltersConfirmationDialog, CompanyLogo, ConfirmationDialog, ControlledCheckbox, ControlledNumberInput, ControlledNumericField, ControlledSelectWithArray, ControlledSelectWithObject, ControlledValidTextInput, DataGrid, Date, _default$c as DeleteSubstitutionDialogContent, _default$b as DeleteUserDialogContent, DynamicOverflowTooltip, _default$j as ExtendedButton, FileCard, _default$i as FilledButton, _default$h as FilledButtonLg, _default$a as FilledLabel, FilterGroupSelector, FilterOptionsCheckboxes, FilterSimpleSelector, _default$9 as FixedFooter, HeadCell, Header, HeaderFilterObject, HeaderFilterOptions, HeaderFilters, SvgIconChart as IconChart, SvgIconCompare as IconCompare, _default$g as ImageButton, LabeledValueList, VirtualizedList as List, Loading, LocationsSectionInfo, Notes, Numpad, _default$8 as NumpadInput, NumpadPlus, type Option, Order, _default$f as OutlinedButton, _default$e as OutlinedButtonLg, PaginationForTable as Pagination, PhoneInput, _default$d as Pin, ActionButton as PinnedApp, PlusMinusInput, ProductBust, ProductImage, RenderAvatar, RenderContentList, RoundButton, RowId, RowProductCard, ScrollableDialog, SearchAndFilterHeader, _default$7 as SearchAndFilterHeaderForTable, SearchFieldDebounced, SearchHeader, _default$6 as SearchWithFilters, _default$5 as SearchWithFiltersForTable, SectionName, SmartMultipleSelect, SmartSelect, SmartTableHeader, SmartTableHeaderFilterMenu, SquareButton, _default$4 as SquareLabel, _default$3 as Switch, Table, TableDesktopCell, TableDesktopEditableField, TableEmptyResult, _default$2 as TableHeader, TableLoading, TextDivider, _default$1 as TheToolbar, ThemedDateRangePicker, ToastMessage, TwoButtonDialog, UploadButton, _default as UserBust, icons };
|
package/dist/components/index.js
CHANGED
|
@@ -369,7 +369,9 @@ var AlertDialog = ({
|
|
|
369
369
|
rejectCopy,
|
|
370
370
|
acceptCopy,
|
|
371
371
|
content,
|
|
372
|
-
disabledContentPadding
|
|
372
|
+
disabledContentPadding,
|
|
373
|
+
disableEnforceFocus,
|
|
374
|
+
disableRestoreFocus
|
|
373
375
|
}) => {
|
|
374
376
|
const { classes } = useStyles();
|
|
375
377
|
return /* @__PURE__ */ jsx2(
|
|
@@ -380,6 +382,8 @@ var AlertDialog = ({
|
|
|
380
382
|
maxWidth,
|
|
381
383
|
fullScreen,
|
|
382
384
|
fullWidth,
|
|
385
|
+
disableEnforceFocus,
|
|
386
|
+
disableRestoreFocus,
|
|
383
387
|
children: /* @__PURE__ */ jsxs2(Box, { children: [
|
|
384
388
|
/* @__PURE__ */ jsxs2(Box, { className: classes.topSection, children: [
|
|
385
389
|
alertTitle ? /* @__PURE__ */ jsx2(Typography2, { variant: "h5", className: classes.title, children: alertTitle }) : null,
|
|
@@ -6250,7 +6254,7 @@ var RenderAvatar_default = RenderAvatar;
|
|
|
6250
6254
|
|
|
6251
6255
|
// src/components/RenderContentList/RenderContentList.tsx
|
|
6252
6256
|
import { useEffect as useEffect7, useState as useState11, useRef as useRef5 } from "react";
|
|
6253
|
-
import
|
|
6257
|
+
import WarningAmber from "@mui/icons-material/WarningAmber";
|
|
6254
6258
|
import {
|
|
6255
6259
|
List,
|
|
6256
6260
|
ListItemButton,
|
|
@@ -6288,8 +6292,32 @@ var RenderContentList = ({
|
|
|
6288
6292
|
const { classes } = useStyles35();
|
|
6289
6293
|
const [active, setActive] = useState11(activeSection);
|
|
6290
6294
|
const observer = useRef5(null);
|
|
6295
|
+
const isScrolling = useRef5(false);
|
|
6296
|
+
const timeoutScrolling = useRef5(null);
|
|
6291
6297
|
useEffect7(() => {
|
|
6292
|
-
|
|
6298
|
+
if (!activeSection) {
|
|
6299
|
+
return void 0;
|
|
6300
|
+
}
|
|
6301
|
+
isScrolling.current = true;
|
|
6302
|
+
const targetId = transformNameToID(activeSection);
|
|
6303
|
+
setActive(targetId);
|
|
6304
|
+
const element = document.getElementById(targetId);
|
|
6305
|
+
if (element) {
|
|
6306
|
+
element.scrollIntoView({
|
|
6307
|
+
behavior: "smooth",
|
|
6308
|
+
block: "start"
|
|
6309
|
+
});
|
|
6310
|
+
}
|
|
6311
|
+
if (timeoutScrolling.current) {
|
|
6312
|
+
clearTimeout(timeoutScrolling.current);
|
|
6313
|
+
}
|
|
6314
|
+
;
|
|
6315
|
+
timeoutScrolling.current = setTimeout(() => {
|
|
6316
|
+
isScrolling.current = false;
|
|
6317
|
+
}, 1e3);
|
|
6318
|
+
return () => {
|
|
6319
|
+
if (timeoutScrolling.current) clearTimeout(timeoutScrolling.current);
|
|
6320
|
+
};
|
|
6293
6321
|
}, [activeSection]);
|
|
6294
6322
|
useEffect7(() => {
|
|
6295
6323
|
const sections = items.map((item) => ({
|
|
@@ -6299,9 +6327,14 @@ var RenderContentList = ({
|
|
|
6299
6327
|
if (observer.current) {
|
|
6300
6328
|
observer.current.disconnect();
|
|
6301
6329
|
}
|
|
6302
|
-
if (sections.length === 0)
|
|
6330
|
+
if (sections.length === 0) {
|
|
6331
|
+
return void 0;
|
|
6332
|
+
}
|
|
6303
6333
|
observer.current = new IntersectionObserver(
|
|
6304
6334
|
(entries) => {
|
|
6335
|
+
if (isScrolling.current) {
|
|
6336
|
+
return;
|
|
6337
|
+
}
|
|
6305
6338
|
const visibleSection = entries.find((entry) => entry.isIntersecting);
|
|
6306
6339
|
if (visibleSection) {
|
|
6307
6340
|
setActive(visibleSection.target.id);
|
|
@@ -6320,6 +6353,21 @@ var RenderContentList = ({
|
|
|
6320
6353
|
observer.current?.disconnect();
|
|
6321
6354
|
};
|
|
6322
6355
|
}, [items]);
|
|
6356
|
+
const handleMenuClick = (id) => {
|
|
6357
|
+
isScrolling.current = true;
|
|
6358
|
+
setActive(id);
|
|
6359
|
+
const element = document.getElementById(id);
|
|
6360
|
+
if (element) {
|
|
6361
|
+
element.scrollIntoView({
|
|
6362
|
+
behavior: "smooth",
|
|
6363
|
+
block: "start"
|
|
6364
|
+
});
|
|
6365
|
+
}
|
|
6366
|
+
if (timeoutScrolling.current) clearTimeout(timeoutScrolling.current);
|
|
6367
|
+
timeoutScrolling.current = setTimeout(() => {
|
|
6368
|
+
isScrolling.current = false;
|
|
6369
|
+
}, 1e3);
|
|
6370
|
+
};
|
|
6323
6371
|
return /* @__PURE__ */ jsx105(
|
|
6324
6372
|
List,
|
|
6325
6373
|
{
|
|
@@ -6333,16 +6381,7 @@ var RenderContentList = ({
|
|
|
6333
6381
|
{
|
|
6334
6382
|
selected: active === id,
|
|
6335
6383
|
classes: { root: classes.root, selected: classes.selected },
|
|
6336
|
-
onClick: () =>
|
|
6337
|
-
setActive(id);
|
|
6338
|
-
const element = document.getElementById(id);
|
|
6339
|
-
if (element) {
|
|
6340
|
-
element.scrollIntoView({
|
|
6341
|
-
behavior: "smooth",
|
|
6342
|
-
block: "start"
|
|
6343
|
-
});
|
|
6344
|
-
}
|
|
6345
|
-
},
|
|
6384
|
+
onClick: () => handleMenuClick(id),
|
|
6346
6385
|
children: [
|
|
6347
6386
|
/* @__PURE__ */ jsx105(ListItemText4, { primary: item }),
|
|
6348
6387
|
(warningItems?.includes(item) || warningItems?.includes(id)) && /* @__PURE__ */ jsx105(Tooltip7, { title: warningMessage, children: /* @__PURE__ */ jsx105(WarningAmber, { color: "warning" }) })
|