slick-table 1.1.57 → 1.1.58
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/index.cjs.js +93 -93
- package/dist/index.es.js +5372 -5418
- package/dist/types/entities/popup-summary/lib/hooks/index.d.ts +3 -0
- package/dist/types/entities/popup-summary/lib/hooks/index.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/lib/hooks/useOpenPopup.d.ts +2 -0
- package/dist/types/entities/popup-summary/lib/hooks/useOpenPopup.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/lib/hooks/useSubscribeToEvent.d.ts +4 -0
- package/dist/types/entities/popup-summary/lib/hooks/useSubscribeToEvent.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/lib/index.d.ts +2 -1
- package/dist/types/entities/popup-summary/lib/index.d.ts.map +1 -1
- package/dist/types/entities/popup-summary/lib/total/getTotals.d.ts +4 -0
- package/dist/types/entities/popup-summary/lib/total/getTotals.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/lib/total/index.d.ts +2 -0
- package/dist/types/entities/popup-summary/lib/total/index.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/model/consts/id.d.ts +2 -0
- package/dist/types/entities/popup-summary/model/consts/id.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/model/consts/index.d.ts +2 -0
- package/dist/types/entities/popup-summary/model/consts/index.d.ts.map +1 -0
- package/dist/types/entities/popup-summary/model/index.d.ts +1 -0
- package/dist/types/entities/popup-summary/model/index.d.ts.map +1 -1
- package/dist/types/entities/popup-summary/ui/PopupSummary.d.ts.map +1 -1
- package/dist/types/entities/popup-summary/ui/PopupSummary.style.d.ts +9 -6
- package/dist/types/entities/popup-summary/ui/PopupSummary.style.d.ts.map +1 -1
- package/dist/types/features/column-filters/model/consts/id.d.ts +1 -1
- package/dist/types/features/column-filters/ui/ButtonReset/ButtonReset.style.d.ts +1 -1
- package/dist/types/features/context-menu/model/consts/id.d.ts +1 -1
- package/dist/types/features/context-menu/ui/ButtonSummary/ButtonSummary.d.ts.map +1 -1
- package/dist/types/features/header-context-menu/ui/Item/Item.style.d.ts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/shared/lib/slickgrid/model/events/eventSummary.d.ts +2 -0
- package/dist/types/shared/lib/slickgrid/model/events/eventSummary.d.ts.map +1 -1
- package/dist/types/shared/ui/ContextSelect/ContextSelect.style.d.ts +1 -1
- package/package.json +1 -1
- package/src/entities/popup-summary/lib/hooks/index.ts +2 -0
- package/src/entities/popup-summary/lib/hooks/useOpenPopup.ts +16 -0
- package/src/entities/popup-summary/lib/hooks/useSubscribeToEvent.ts +31 -0
- package/src/entities/popup-summary/lib/index.ts +2 -1
- package/src/entities/popup-summary/lib/{getTotals.ts → total/getTotals.ts} +3 -2
- package/src/entities/popup-summary/lib/total/index.ts +1 -0
- package/src/entities/popup-summary/model/consts/id.ts +1 -0
- package/src/entities/popup-summary/model/consts/index.ts +1 -0
- package/src/entities/popup-summary/model/index.ts +1 -0
- package/src/entities/popup-summary/ui/PopupSummary.style.ts +20 -11
- package/src/entities/popup-summary/ui/PopupSummary.tsx +23 -37
- package/src/features/column-filters/model/consts/id.ts +1 -1
- package/src/features/context-menu/model/consts/id.ts +1 -1
- package/src/features/context-menu/ui/ButtonSummary/ButtonSummary.tsx +2 -0
- package/src/index.ts +0 -1
- package/src/shared/lib/slickgrid/model/events/eventSummary.ts +2 -0
- package/dist/types/entities/popup-summary/lib/getTotals.d.ts +0 -4
- package/dist/types/entities/popup-summary/lib/getTotals.d.ts.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/lib/hooks/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,gBAAgB,CAAC;AAChD,OAAO,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useOpenPopup.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/lib/hooks/useOpenPopup.ts"],"names":[],"mappings":"AAMA,wBAAgB,cAAc,CAAC,QAAQ,EAAE,OAAO,QAS/C"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Dispatch, SetStateAction } from 'react';
|
|
2
|
+
import { ITotal } from '../../model';
|
|
3
|
+
export declare function useSubscribeToEvent(setIsOpened: Dispatch<SetStateAction<boolean>>, setRowsNumber: Dispatch<SetStateAction<number>>, setTotals: Dispatch<SetStateAction<ITotal>>, tableId: string): void;
|
|
4
|
+
//# sourceMappingURL=useSubscribeToEvent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useSubscribeToEvent.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/lib/hooks/useSubscribeToEvent.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,cAAc,EAAa,MAAM,OAAO,CAAC;AAK5D,OAAO,EAAE,MAAM,EAAE,MAAM,8BAA8B,CAAC;AAEtD,wBAAgB,mBAAmB,CAClC,WAAW,EAAE,QAAQ,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,EAC9C,aAAa,EAAE,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,EAC/C,SAAS,EAAE,QAAQ,CAAC,cAAc,CAAC,MAAM,CAAC,CAAC,EAC3C,OAAO,EAAE,MAAM,QAmBf"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/lib/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AACpC,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getTotals.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/lib/total/getTotals.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAErC,wBAAgB,SAAS,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,MAAM,CAuChE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/lib/total/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"id.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/model/consts/id.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB,0BAA0B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/entities/popup-summary/model/consts/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,MAAM,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/model/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/model/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AACjD,YAAY,EAAE,MAAM,EAAE,MAAM,SAAS,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PopupSummary.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/ui/PopupSummary.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PopupSummary.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/ui/PopupSummary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,EAAE,EAAsB,MAAM,OAAO,CAAC;AAY/C,eAAO,MAAM,YAAY,EAAE,EAAE,CAAC,KAAK,CAyClC,CAAC;AAEF,UAAU,KAAK;IACd,OAAO,EAAE,MAAM,CAAC;CAChB"}
|
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
Button: import('@emotion/styled').StyledComponent<import('@mui/material').ButtonOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
3
3
|
ref?: ((instance: HTMLButtonElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLButtonElement> | null | undefined;
|
|
4
|
-
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "disabled" | "action" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "href" | "disableElevation" | "disableFocusRipple" | "endIcon" | "fullWidth" | "size" | "startIcon"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
|
+
ButtonContainer: import('@emotion/styled').StyledComponent<import('@mui/system').BoxOwnProps<import('@mui/material').Theme> & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
6
|
+
ref?: ((instance: HTMLDivElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
7
|
+
}, keyof import('@mui/system').BoxOwnProps<import('@mui/material').Theme>> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
8
|
+
RowsNumber: import('@emotion/styled').StyledComponent<import('@mui/system').BoxOwnProps<import('@mui/material').Theme> & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
9
|
+
ref?: ((instance: HTMLDivElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLDivElement> | null | undefined;
|
|
10
|
+
}, keyof import('@mui/system').BoxOwnProps<import('@mui/material').Theme>> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
11
|
+
Title: import('@emotion/styled').StyledComponent<import('@mui/material').TypographyOwnProps & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, "ref"> & {
|
|
7
12
|
ref?: ((instance: HTMLSpanElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLSpanElement> | null | undefined;
|
|
8
13
|
}, "className" | "style" | "classes" | "p" | "color" | "children" | "height" | "sx" | "variant" | "width" | "alignContent" | "alignItems" | "alignSelf" | "bottom" | "boxShadow" | "boxSizing" | "columnGap" | "display" | "flexBasis" | "flexDirection" | "flexGrow" | "flexShrink" | "flexWrap" | "fontFamily" | "fontSize" | "fontStyle" | "fontWeight" | "gridAutoColumns" | "gridAutoFlow" | "gridAutoRows" | "gridTemplateAreas" | "gridTemplateColumns" | "gridTemplateRows" | "justifyContent" | "justifyItems" | "justifySelf" | "left" | "letterSpacing" | "lineHeight" | "marginBlockEnd" | "marginBlockStart" | "marginBottom" | "marginInlineEnd" | "marginInlineStart" | "marginLeft" | "marginRight" | "marginTop" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "order" | "paddingBlockEnd" | "paddingBlockStart" | "paddingBottom" | "paddingInlineEnd" | "paddingInlineStart" | "paddingLeft" | "paddingRight" | "paddingTop" | "position" | "right" | "rowGap" | "textAlign" | "textOverflow" | "textTransform" | "top" | "visibility" | "whiteSpace" | "zIndex" | "border" | "borderBottom" | "borderColor" | "borderLeft" | "borderRadius" | "borderRight" | "borderTop" | "flex" | "gap" | "gridArea" | "gridColumn" | "gridRow" | "margin" | "marginBlock" | "marginInline" | "overflow" | "padding" | "paddingBlock" | "paddingInline" | "bgcolor" | "m" | "mt" | "mr" | "mb" | "ml" | "mx" | "marginX" | "my" | "marginY" | "pt" | "pr" | "pb" | "pl" | "px" | "paddingX" | "py" | "paddingY" | "typography" | "displayPrint" | "align" | "gutterBottom" | "noWrap" | "paragraph" | "variantMapping"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
9
|
-
|
|
10
|
-
ref?: ((instance: HTMLUListElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLUListElement> | null | undefined;
|
|
11
|
-
}, "className" | "style" | "classes" | "children" | "sx" | "dense" | "disablePadding" | "subheader"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
14
|
+
Ul: import('@emotion/styled').StyledComponent<import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLUListElement>, HTMLUListElement>, {}>;
|
|
12
15
|
};
|
|
13
16
|
export default _default;
|
|
14
17
|
//# sourceMappingURL=PopupSummary.style.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PopupSummary.style.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/ui/PopupSummary.style.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PopupSummary.style.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/ui/PopupSummary.style.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AA8BA,wBAME"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const COLUMN_FILTERS = "
|
|
1
|
+
export declare const COLUMN_FILTERS = "column-filters";
|
|
2
2
|
//# sourceMappingURL=id.d.ts.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
Button: import('@emotion/styled').StyledComponent<import('@mui/material').ButtonOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
3
3
|
ref?: ((instance: HTMLButtonElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLButtonElement> | null | undefined;
|
|
4
|
-
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "
|
|
4
|
+
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "disabled" | "action" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "href" | "disableElevation" | "disableFocusRipple" | "endIcon" | "fullWidth" | "size" | "startIcon"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
5
|
};
|
|
6
6
|
export default _default;
|
|
7
7
|
//# sourceMappingURL=ButtonReset.style.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const CONTEXT_MENU = "
|
|
1
|
+
export declare const CONTEXT_MENU = "context-menu";
|
|
2
2
|
//# sourceMappingURL=id.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ButtonSummary.d.ts","sourceRoot":"","sources":["../../../../../../src/features/context-menu/ui/ButtonSummary/ButtonSummary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAMrD,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,MAAM,
|
|
1
|
+
{"version":3,"file":"ButtonSummary.d.ts","sourceRoot":"","sources":["../../../../../../src/features/context-menu/ui/ButtonSummary/ButtonSummary.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AAMrD,eAAO,MAAM,aAAa,EAAE,EAAE,CAAC,MAAM,CAyBpC,CAAC;AAEF,UAAU,MAAM;IACf,WAAW,EAAE,QAAQ,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;CAC/C"}
|
|
@@ -3,7 +3,7 @@ declare const _default: {
|
|
|
3
3
|
Checkbox: import('@emotion/styled').StyledComponent<CheckboxProps & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
4
4
|
Button: import('@emotion/styled').StyledComponent<import('@mui/material').ButtonOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
|
|
5
5
|
ref?: ((instance: HTMLButtonElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLButtonElement> | null | undefined;
|
|
6
|
-
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "
|
|
6
|
+
}, "className" | "style" | "classes" | "tabIndex" | "color" | "children" | "sx" | "variant" | "disabled" | "action" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "href" | "disableElevation" | "disableFocusRipple" | "endIcon" | "fullWidth" | "size" | "startIcon"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
7
7
|
};
|
|
8
8
|
export default _default;
|
|
9
9
|
//# sourceMappingURL=Item.style.d.ts.map
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { Skeleton } from './entities/skeleton';
|
|
2
|
-
export { Autocomplete, ColumnPicker, ColumnSorter, DecoratorColumnFilter, DecoratorFilter, DefaultHotKeys, DefaultPrinter, DeletedRowsFilter, EditorAutocomplete, FORMATTER_NUMBER, Filter, HotKeysDecorator, PreventCopying, RedoUndoOnly, SlickTable, SlickgridTable, TotalCalculator, WithSummary, WithoutHotKeys, columnIsEdited, columnCheckboxSelector, commitCurrentEdit, copySelectedRows, eventContextMenu, formatterGroupTotals, formatterCheckMark, getDisplayedRows, getFormatterNumber, getNextId, handleHeaderButtons, headerButtons, highlightCell, highlightColumns, hotKeysCopy, hotKeysDelete, hotKeysRedo, hotKeysUndo, openColumnFilter,
|
|
2
|
+
export { Autocomplete, ColumnPicker, ColumnSorter, DecoratorColumnFilter, DecoratorFilter, DefaultHotKeys, DefaultPrinter, DeletedRowsFilter, EditorAutocomplete, FORMATTER_NUMBER, Filter, HotKeysDecorator, PreventCopying, RedoUndoOnly, SlickTable, SlickgridTable, TotalCalculator, WithSummary, WithoutHotKeys, columnIsEdited, columnCheckboxSelector, commitCurrentEdit, copySelectedRows, eventContextMenu, formatterGroupTotals, formatterCheckMark, getDisplayedRows, getFormatterNumber, getNextId, handleHeaderButtons, headerButtons, highlightCell, highlightColumns, hotKeysCopy, hotKeysDelete, hotKeysRedo, hotKeysUndo, openColumnFilter, printerCheckMark, useListenIfTablesWereEdited, } from './shared/lib/slickgrid';
|
|
3
3
|
export { formatNumber } from './shared/lib/format';
|
|
4
4
|
export type { IColumn, IFilter, IFilterArguments, IFormatterNumberOptions, IHotKeysBehavior, IPrinter, ISlickTable, ITotalCalculator, } from './shared/model/types';
|
|
5
5
|
export { BOLD, WINK } from './shared/model/consts';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EACN,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,qBAAqB,EACrB,eAAe,EACf,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,kBAAkB,EAClB,gBAAgB,EAChB,MAAM,EACN,gBAAgB,EAChB,cAAc,EACd,YAAY,EACZ,UAAU,EACV,cAAc,EACd,eAAe,EACf,WAAW,EACX,cAAc,EACd,cAAc,EACd,sBAAsB,EACtB,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,SAAS,EACT,mBAAmB,EACnB,aAAa,EACb,aAAa,EACb,gBAAgB,EAChB,WAAW,EACX,aAAa,EACb,WAAW,EACX,WAAW,EACX,gBAAgB,EAChB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EACN,YAAY,EACZ,YAAY,EACZ,YAAY,EACZ,qBAAqB,EACrB,eAAe,EACf,cAAc,EACd,cAAc,EACd,iBAAiB,EACjB,kBAAkB,EAClB,gBAAgB,EAChB,MAAM,EACN,gBAAgB,EAChB,cAAc,EACd,YAAY,EACZ,UAAU,EACV,cAAc,EACd,eAAe,EACf,WAAW,EACX,cAAc,EACd,cAAc,EACd,sBAAsB,EACtB,iBAAiB,EACjB,gBAAgB,EAChB,gBAAgB,EAChB,oBAAoB,EACpB,kBAAkB,EAClB,gBAAgB,EAChB,kBAAkB,EAClB,SAAS,EACT,mBAAmB,EACnB,aAAa,EACb,aAAa,EACb,gBAAgB,EAChB,WAAW,EACX,aAAa,EACb,WAAW,EACX,WAAW,EACX,gBAAgB,EAChB,gBAAgB,EAChB,2BAA2B,GAC3B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,YAAY,EACX,OAAO,EACP,OAAO,EACP,gBAAgB,EAChB,uBAAuB,EACvB,gBAAgB,EAChB,QAAQ,EACR,WAAW,EACX,gBAAgB,GAChB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AACjD,OAAO,EACN,aAAa,EACb,mBAAmB,EACnB,SAAS,GACT,MAAM,oBAAoB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"eventSummary.d.ts","sourceRoot":"","sources":["../../../../../../../src/shared/lib/slickgrid/model/events/eventSummary.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,cAAM,YAAa,SAAQ,OAAO;IACjC,OAAO,CAAC,KAAK,CAAS;IACtB,OAAO,CAAC,MAAM,CAA0B;
|
|
1
|
+
{"version":3,"file":"eventSummary.d.ts","sourceRoot":"","sources":["../../../../../../../src/shared/lib/slickgrid/model/events/eventSummary.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,cAAM,YAAa,SAAQ,OAAO;IACjC,OAAO,CAAC,KAAK,CAAS;IACtB,OAAO,CAAC,MAAM,CAA0B;IACxC,CAAC,SAAK;IACN,CAAC,SAAK;IAEN,IAAI,IAAI,YAEP;IACD,IAAI,IAAI,CAAC,IAAI,SAAA,EAGZ;IAED,IAAI,KAAK,4BAER;IACD,IAAI,KAAK,CAAC,KAAK,yBAAA,EAEd;CACD;AAED,eAAO,MAAM,YAAY,cAAqB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
declare const _default: {
|
|
2
2
|
MenuItem: import('@emotion/styled').StyledComponent<import('@mui/material').MenuItemOwnProps & Omit<import('@mui/material').ButtonBaseOwnProps, "classes"> & import('@mui/material/OverridableComponent').CommonProps & Omit<Omit<import('react').DetailedHTMLProps<import('react').LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, "ref"> & {
|
|
3
3
|
ref?: ((instance: HTMLLIElement | null) => void | import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES[keyof import('react').DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES]) | import('react').RefObject<HTMLLIElement> | null | undefined;
|
|
4
|
-
}, "className" | "style" | "classes" | "autoFocus" | "tabIndex" | "children" | "sx" | "
|
|
4
|
+
}, "className" | "style" | "classes" | "autoFocus" | "tabIndex" | "children" | "sx" | "disabled" | "action" | "centerRipple" | "disableRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "onFocusVisible" | "TouchRippleProps" | "touchRippleRef" | "selected" | "dense" | "disableGutters" | "divider"> & import('@mui/system').MUIStyledCommonProps<import('@mui/material').Theme>, {}, {}>;
|
|
5
5
|
};
|
|
6
6
|
export default _default;
|
|
7
7
|
//# sourceMappingURL=ContextSelect.style.d.ts.map
|
package/package.json
CHANGED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { useEffect } from "react";
|
|
2
|
+
|
|
3
|
+
import { eventSummary } from "shared/lib/slickgrid";
|
|
4
|
+
|
|
5
|
+
import { SELECTED_ROWS_SUMMARY } from "../../model";
|
|
6
|
+
|
|
7
|
+
export function useMakeVisible(isOpened: boolean) {
|
|
8
|
+
useEffect(() => {
|
|
9
|
+
if (!isOpened) return;
|
|
10
|
+
const popup = document.getElementById(SELECTED_ROWS_SUMMARY);
|
|
11
|
+
if (!popup) return;
|
|
12
|
+
popup.style.visibility = "visible";
|
|
13
|
+
popup.style.left = `${eventSummary.x}px`;
|
|
14
|
+
popup.style.top = `${eventSummary.y}px`;
|
|
15
|
+
}, [isOpened]);
|
|
16
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Dispatch, SetStateAction, useEffect } from "react";
|
|
2
|
+
|
|
3
|
+
import { eventSummary } from "shared/lib/slickgrid";
|
|
4
|
+
|
|
5
|
+
import { getTotals } from "entities/popup-summary/lib";
|
|
6
|
+
import { ITotal } from "entities/popup-summary/model";
|
|
7
|
+
|
|
8
|
+
export function useSubscribeToEvent(
|
|
9
|
+
setIsOpened: Dispatch<SetStateAction<boolean>>,
|
|
10
|
+
setRowsNumber: Dispatch<SetStateAction<number>>,
|
|
11
|
+
setTotals: Dispatch<SetStateAction<ITotal>>,
|
|
12
|
+
tableId: string,
|
|
13
|
+
) {
|
|
14
|
+
useEffect(() => {
|
|
15
|
+
function callback() {
|
|
16
|
+
const { open, table } = eventSummary;
|
|
17
|
+
if (table?.id !== tableId) return;
|
|
18
|
+
if (open) {
|
|
19
|
+
const table = eventSummary.table;
|
|
20
|
+
const grid = table?.grid;
|
|
21
|
+
setRowsNumber(grid?.getSelectedRows().length || 0);
|
|
22
|
+
setTotals(getTotals(table));
|
|
23
|
+
}
|
|
24
|
+
setIsOpened(open);
|
|
25
|
+
}
|
|
26
|
+
eventSummary.subscribe(callback);
|
|
27
|
+
return () => {
|
|
28
|
+
eventSummary.unsubscribe(callback);
|
|
29
|
+
};
|
|
30
|
+
}, [tableId]);
|
|
31
|
+
}
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
export { getTotals } from "./
|
|
1
|
+
export { getTotals } from "./total";
|
|
2
|
+
export { useMakeVisible, useSubscribeToEvent } from "./hooks";
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { SlickDataView } from "slickgrid";
|
|
2
2
|
|
|
3
|
+
import { formatNumber } from "shared/lib/format";
|
|
3
4
|
import { ISlickTable } from "shared/model/types";
|
|
4
5
|
|
|
5
|
-
import { ITotal } from "
|
|
6
|
+
import { ITotal } from "../../model";
|
|
6
7
|
|
|
7
8
|
export function getTotals(table: ISlickTable | undefined): ITotal {
|
|
8
9
|
const result: ITotal = {};
|
|
@@ -39,7 +40,7 @@ export function getTotals(table: ISlickTable | undefined): ITotal {
|
|
|
39
40
|
item,
|
|
40
41
|
grid,
|
|
41
42
|
)
|
|
42
|
-
: `${result[id].total}`;
|
|
43
|
+
: `${formatNumber(result[id].total)}`;
|
|
43
44
|
});
|
|
44
45
|
});
|
|
45
46
|
return result;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { getTotals } from "./getTotals";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const SELECTED_ROWS_SUMMARY = "selected-rows-summary";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { SELECTED_ROWS_SUMMARY } from "./id";
|
|
@@ -1,17 +1,25 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Box, Button, Typography, styled } from "@mui/material";
|
|
2
2
|
|
|
3
|
-
const
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
const Title = styled(Typography)({
|
|
4
|
+
color: "#1E456F",
|
|
5
|
+
marginBottom: "0.5em",
|
|
6
|
+
fontWeight: "600",
|
|
7
|
+
fontSize: "1.3rem",
|
|
8
|
+
letterSpacing: "-2%",
|
|
9
|
+
minWidth: "14em",
|
|
7
10
|
});
|
|
8
11
|
|
|
9
|
-
const
|
|
12
|
+
const RowsNumber = styled(Box)({
|
|
10
13
|
color: "#1E456F",
|
|
11
14
|
});
|
|
12
15
|
|
|
13
|
-
const
|
|
14
|
-
|
|
16
|
+
const Ul = styled("ul")({
|
|
17
|
+
paddingLeft: "1.5em",
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
const ButtonContainer = styled(Box)({
|
|
21
|
+
display: "flex",
|
|
22
|
+
justifyContent: "end",
|
|
15
23
|
});
|
|
16
24
|
|
|
17
25
|
const StyledButton = styled(Button)({
|
|
@@ -22,7 +30,8 @@ const StyledButton = styled(Button)({
|
|
|
22
30
|
|
|
23
31
|
export default {
|
|
24
32
|
Button: StyledButton,
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
33
|
+
ButtonContainer,
|
|
34
|
+
RowsNumber,
|
|
35
|
+
Title,
|
|
36
|
+
Ul,
|
|
28
37
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { FC, useEffect, useState } from "react";
|
|
1
|
+
import { FC, Fragment, useState } from "react";
|
|
3
2
|
|
|
4
3
|
import { eventSummary } from "shared/lib/slickgrid";
|
|
5
4
|
|
|
6
|
-
import {
|
|
7
|
-
|
|
5
|
+
import { Overlay, Popup } from "entities/popup";
|
|
6
|
+
|
|
7
|
+
import { useMakeVisible, useSubscribeToEvent } from "../lib";
|
|
8
|
+
import { ITotal, SELECTED_ROWS_SUMMARY } from "../model";
|
|
8
9
|
import { TotalByColumn } from "./TotalByColumn";
|
|
9
|
-
import { StyledDialogContentText } from "./styles";
|
|
10
10
|
|
|
11
11
|
import Styled from "./PopupSummary.style";
|
|
12
12
|
|
|
@@ -19,51 +19,37 @@ export const PopupSummary: FC<Props> = ({ tableId }) => {
|
|
|
19
19
|
eventSummary.open = false;
|
|
20
20
|
}
|
|
21
21
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
const { open, table } = eventSummary;
|
|
25
|
-
if (table?.id !== tableId) return;
|
|
26
|
-
if (open) {
|
|
27
|
-
const table = eventSummary.table;
|
|
28
|
-
const grid = table?.grid;
|
|
29
|
-
setRowsNumber(grid?.getSelectedRows().length || 0);
|
|
30
|
-
setTotals(getTotals(table));
|
|
31
|
-
}
|
|
32
|
-
setIsOpened(open);
|
|
33
|
-
}
|
|
34
|
-
eventSummary.subscribe(callback);
|
|
35
|
-
return () => {
|
|
36
|
-
eventSummary.unsubscribe(callback);
|
|
37
|
-
};
|
|
38
|
-
}, [tableId]);
|
|
22
|
+
useMakeVisible(isOpened);
|
|
23
|
+
useSubscribeToEvent(setIsOpened, setRowsNumber, setTotals, tableId);
|
|
39
24
|
|
|
40
25
|
if (!isOpened) return null;
|
|
41
26
|
|
|
42
27
|
return (
|
|
43
|
-
<
|
|
44
|
-
<
|
|
45
|
-
<
|
|
46
|
-
<Styled.
|
|
47
|
-
|
|
28
|
+
<Fragment>
|
|
29
|
+
<Overlay setIsOpened={setIsOpened} />
|
|
30
|
+
<Popup id={SELECTED_ROWS_SUMMARY}>
|
|
31
|
+
<Styled.Title variant={"h6"}>Selected rows summary</Styled.Title>
|
|
32
|
+
<Styled.RowsNumber>{`Number of selected rows: ${rowsNumber}`}</Styled.RowsNumber>
|
|
33
|
+
<Styled.Ul>
|
|
48
34
|
{Object.entries(totals).map(
|
|
49
35
|
([id, { label, total, totalFormatted }]) => (
|
|
50
|
-
<
|
|
36
|
+
<li key={id}>
|
|
51
37
|
<TotalByColumn
|
|
52
38
|
label={label}
|
|
53
39
|
total={total}
|
|
54
40
|
totalFormatted={totalFormatted}
|
|
55
41
|
/>
|
|
56
|
-
</
|
|
42
|
+
</li>
|
|
57
43
|
),
|
|
58
44
|
)}
|
|
59
|
-
</Styled.
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
</Styled.
|
|
65
|
-
</
|
|
66
|
-
</
|
|
45
|
+
</Styled.Ul>
|
|
46
|
+
<Styled.ButtonContainer>
|
|
47
|
+
<Styled.Button variant={"outlined"} onClick={onClose}>
|
|
48
|
+
Close
|
|
49
|
+
</Styled.Button>
|
|
50
|
+
</Styled.ButtonContainer>
|
|
51
|
+
</Popup>
|
|
52
|
+
</Fragment>
|
|
67
53
|
);
|
|
68
54
|
};
|
|
69
55
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const COLUMN_FILTERS = "
|
|
1
|
+
export const COLUMN_FILTERS = "column-filters";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const CONTEXT_MENU = "
|
|
1
|
+
export const CONTEXT_MENU = "context-menu";
|
|
@@ -14,6 +14,8 @@ export const ButtonSummary: FC<IProps> = ({ setIsOpened }) => {
|
|
|
14
14
|
setIsOpened(false);
|
|
15
15
|
eventSummary.table = table;
|
|
16
16
|
eventSummary.open = true;
|
|
17
|
+
eventSummary.x = eventContextMenu.x;
|
|
18
|
+
eventSummary.y = eventContextMenu.y;
|
|
17
19
|
}
|
|
18
20
|
|
|
19
21
|
if (!table?.summaryColumnIds.length || Number(selectedRows?.length) < 2)
|
package/src/index.ts
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"getTotals.d.ts","sourceRoot":"","sources":["../../../../../src/entities/popup-summary/lib/getTotals.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAElC,wBAAgB,SAAS,CAAC,KAAK,EAAE,WAAW,GAAG,SAAS,GAAG,MAAM,CAuChE"}
|