@ganpatiinfo/gids-react-web 14.0.0 → 15.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (101) hide show
  1. package/dist/components/GidsBasicTableBody/GidsBasicTableBody.d.ts +29 -5
  2. package/dist/components/GidsBasicTableBody/GidsBasicTableBody.d.ts.map +1 -1
  3. package/dist/components/GidsBasicTableBody/GidsBasicTableBody.js +19 -3
  4. package/dist/components/GidsBasicTableBody/GidsBasicTableBody.js.map +1 -1
  5. package/dist/components/GidsBasicTableHead/GidsBasicTableHead.d.ts +25 -0
  6. package/dist/components/GidsBasicTableHead/GidsBasicTableHead.d.ts.map +1 -1
  7. package/dist/components/GidsBasicTableHead/GidsBasicTableHead.js +5 -0
  8. package/dist/components/GidsBasicTableHead/GidsBasicTableHead.js.map +1 -1
  9. package/dist/components/GidsBasicTableHeader/GidsBasicTableHeader.d.ts +23 -4
  10. package/dist/components/GidsBasicTableHeader/GidsBasicTableHeader.d.ts.map +1 -1
  11. package/dist/components/GidsBasicTableHeader/GidsBasicTableHeader.js +7 -2
  12. package/dist/components/GidsBasicTableHeader/GidsBasicTableHeader.js.map +1 -1
  13. package/dist/components/GidsBasicTableRow/GidsBasicTableRow.d.ts +20 -4
  14. package/dist/components/GidsBasicTableRow/GidsBasicTableRow.d.ts.map +1 -1
  15. package/dist/components/GidsBasicTableRow/GidsBasicTableRow.js +20 -5
  16. package/dist/components/GidsBasicTableRow/GidsBasicTableRow.js.map +1 -1
  17. package/dist/components/GidsBsTable/GidsBsTable.d.ts +29 -5
  18. package/dist/components/GidsBsTable/GidsBsTable.d.ts.map +1 -1
  19. package/dist/components/GidsBsTable/GidsBsTable.js +21 -5
  20. package/dist/components/GidsBsTable/GidsBsTable.js.map +1 -1
  21. package/dist/components/GidsColorSwatch/GidsColorSwatch.d.ts +7 -0
  22. package/dist/components/GidsColorSwatch/GidsColorSwatch.d.ts.map +1 -0
  23. package/dist/components/GidsColorSwatch/GidsColorSwatch.js +41 -0
  24. package/dist/components/GidsColorSwatch/GidsColorSwatch.js.map +1 -0
  25. package/dist/components/GidsMatrixTable/GidsMatrixTable.d.ts +12 -0
  26. package/dist/components/GidsMatrixTable/GidsMatrixTable.d.ts.map +1 -0
  27. package/dist/components/GidsMatrixTable/GidsMatrixTable.js +31 -0
  28. package/dist/components/GidsMatrixTable/GidsMatrixTable.js.map +1 -0
  29. package/dist/components/GidsMatrixTableBody/GidsMatrixTableBody.d.ts +12 -0
  30. package/dist/components/GidsMatrixTableBody/GidsMatrixTableBody.d.ts.map +1 -0
  31. package/dist/components/GidsMatrixTableBody/GidsMatrixTableBody.js +51 -0
  32. package/dist/components/GidsMatrixTableBody/GidsMatrixTableBody.js.map +1 -0
  33. package/dist/components/GidsPagination/GidsPagination.d.ts +9 -0
  34. package/dist/components/GidsPagination/GidsPagination.d.ts.map +1 -1
  35. package/dist/components/GidsPagination/GidsPagination.js +9 -15
  36. package/dist/components/GidsPagination/GidsPagination.js.map +1 -1
  37. package/dist/components/GidsPaginator/GidsPaginator.d.ts +7 -0
  38. package/dist/components/GidsPaginator/GidsPaginator.d.ts.map +1 -0
  39. package/dist/components/GidsPaginator/GidsPaginator.js +142 -0
  40. package/dist/components/GidsPaginator/GidsPaginator.js.map +1 -0
  41. package/dist/components/GidsPaginatorItem/GidsPaginatorItem.d.ts +7 -0
  42. package/dist/components/GidsPaginatorItem/GidsPaginatorItem.d.ts.map +1 -0
  43. package/dist/components/GidsPaginatorItem/GidsPaginatorItem.js +29 -0
  44. package/dist/components/GidsPaginatorItem/GidsPaginatorItem.js.map +1 -0
  45. package/dist/components/GidsTable/GidsTable.d.ts +16 -0
  46. package/dist/components/GidsTable/GidsTable.d.ts.map +1 -0
  47. package/dist/components/GidsTable/GidsTable.js +51 -0
  48. package/dist/components/GidsTable/GidsTable.js.map +1 -0
  49. package/dist/components/GidsTableBody/GidsTableBody.d.ts +12 -0
  50. package/dist/components/GidsTableBody/GidsTableBody.d.ts.map +1 -0
  51. package/dist/components/GidsTableBody/GidsTableBody.js +44 -0
  52. package/dist/components/GidsTableBody/GidsTableBody.js.map +1 -0
  53. package/dist/components/GidsTableCell/GidsTableCell.d.ts +22 -0
  54. package/dist/components/GidsTableCell/GidsTableCell.d.ts.map +1 -0
  55. package/dist/components/GidsTableCell/GidsTableCell.js +91 -0
  56. package/dist/components/GidsTableCell/GidsTableCell.js.map +1 -0
  57. package/dist/components/GidsTableEntry/GidsTableEntry.d.ts +10 -0
  58. package/dist/components/GidsTableEntry/GidsTableEntry.d.ts.map +1 -0
  59. package/dist/components/GidsTableEntry/GidsTableEntry.js +175 -0
  60. package/dist/components/GidsTableEntry/GidsTableEntry.js.map +1 -0
  61. package/dist/components/GidsTableFooter/GidsTableFooter.d.ts +12 -0
  62. package/dist/components/GidsTableFooter/GidsTableFooter.d.ts.map +1 -0
  63. package/dist/components/GidsTableFooter/GidsTableFooter.js +43 -0
  64. package/dist/components/GidsTableFooter/GidsTableFooter.js.map +1 -0
  65. package/dist/components/GidsTableFooterControl/GidsTableFooterControl.d.ts +8 -0
  66. package/dist/components/GidsTableFooterControl/GidsTableFooterControl.d.ts.map +1 -0
  67. package/dist/components/GidsTableFooterControl/GidsTableFooterControl.js +44 -0
  68. package/dist/components/GidsTableFooterControl/GidsTableFooterControl.js.map +1 -0
  69. package/dist/components/GidsTableHeader/GidsTableHeader.d.ts +10 -0
  70. package/dist/components/GidsTableHeader/GidsTableHeader.d.ts.map +1 -0
  71. package/dist/components/GidsTableHeader/GidsTableHeader.js +20 -0
  72. package/dist/components/GidsTableHeader/GidsTableHeader.js.map +1 -0
  73. package/dist/components/GidsTableRow/GidsTableRow.d.ts +10 -0
  74. package/dist/components/GidsTableRow/GidsTableRow.d.ts.map +1 -0
  75. package/dist/components/GidsTableRow/GidsTableRow.js +24 -0
  76. package/dist/components/GidsTableRow/GidsTableRow.js.map +1 -0
  77. package/dist/components/GidsTableToolbar/GidsTableToolbar.d.ts +15 -0
  78. package/dist/components/GidsTableToolbar/GidsTableToolbar.d.ts.map +1 -0
  79. package/dist/components/GidsTableToolbar/GidsTableToolbar.js +26 -0
  80. package/dist/components/GidsTableToolbar/GidsTableToolbar.js.map +1 -0
  81. package/dist/components/_GidsPaginationItem/GidsPaginationItem.d.ts +9 -0
  82. package/dist/components/_GidsPaginationItem/GidsPaginationItem.d.ts.map +1 -1
  83. package/dist/components/_GidsPaginationItem/GidsPaginationItem.js +4 -0
  84. package/dist/components/_GidsPaginationItem/GidsPaginationItem.js.map +1 -1
  85. package/dist/components/stencil-generated/components.d.ts +1 -0
  86. package/dist/components/stencil-generated/components.d.ts.map +1 -1
  87. package/dist/components/stencil-generated/components.js +1 -0
  88. package/dist/components/stencil-generated/components.js.map +1 -1
  89. package/dist/components/stencil-generated/gids-advanced-tooltip.d.ts +10 -0
  90. package/dist/components/stencil-generated/gids-advanced-tooltip.d.ts.map +1 -0
  91. package/dist/components/stencil-generated/gids-advanced-tooltip.js +13 -0
  92. package/dist/components/stencil-generated/gids-advanced-tooltip.js.map +1 -0
  93. package/dist/index.d.ts +15 -1
  94. package/dist/index.d.ts.map +1 -1
  95. package/dist/index.js +15 -1
  96. package/dist/index.js.map +1 -1
  97. package/package.json +9 -9
  98. package/dist/components/GidsBasicTableCell/GidsBasicTableCell.d.ts +0 -6
  99. package/dist/components/GidsBasicTableCell/GidsBasicTableCell.d.ts.map +0 -1
  100. package/dist/components/GidsBasicTableCell/GidsBasicTableCell.js +0 -22
  101. package/dist/components/GidsBasicTableCell/GidsBasicTableCell.js.map +0 -1
@@ -0,0 +1,91 @@
1
+ import React from 'react';
2
+ import { GidsTableCellWebUtils, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsDisplayTag } from '../GidsDisplayTag/GidsDisplayTag';
4
+ import { GidsIcon } from '../GidsIcon/GidsIcon';
5
+ import { getTableCellBtnIcon, isTableCellActionButtonVisible, } from '@ganpatiinfo/gids-core-shared/dist/components/GidsTableCell/GidsTableCellCommonUtils';
6
+ import { GidsButton } from '../GidsButton/GidsButton';
7
+ const { getGidsTableCellClassNames, getGidsTableCellLabelTypographyClass } = GidsTableCellWebUtils;
8
+ /**
9
+ * @deprecated
10
+ * Use `GidsTableEntry` and its props and functions
11
+ */
12
+ export const GidsTableCell = ({ id, uniqueKey, extraData, label, cellDataType = 'text', displayTags = [], width = 'full', appearance = 'none', borderSides = [], borderRadiusSides = [], textAlignment = 'center', labelTypography = 'label-medium', isHeaderCell = false, cellPrimaryActionButtons = [], cellSecondaryActionButtons = [], onClickCellActionBtn, className, ...restProps }) => {
13
+ const CellTag = isHeaderCell ? 'th' : 'td';
14
+ const makeCellActionBtnIcon = ({ cellActionBtn, neededIconType = 'leading', }) => {
15
+ const tableCellBtnIcon = getTableCellBtnIcon({
16
+ cellActionButton: cellActionBtn,
17
+ neededIconType,
18
+ });
19
+ return tableCellBtnIcon?.cellIconName &&
20
+ tableCellBtnIcon.cellIconName.toString() !== '' ? (React.createElement(GidsIcon, { name: tableCellBtnIcon.cellIconName, size: tableCellBtnIcon.cellIconSize, appearance: tableCellBtnIcon.cellIconAppearance })) : undefined;
21
+ };
22
+ const onActionBtnClick = ({ event, actionBtnIndex, actionBtnPosition, }) => {
23
+ if (onClickCellActionBtn) {
24
+ onClickCellActionBtn({
25
+ originalEvent: event,
26
+ details: {
27
+ appearance,
28
+ cellDataType,
29
+ displayTags,
30
+ label,
31
+ id,
32
+ extraData,
33
+ isHeaderCell,
34
+ uniqueKey,
35
+ actionBtnNumber: `action-btn-${actionBtnIndex + 1}`,
36
+ actionBtnIndex: actionBtnIndex,
37
+ actionBtnPosition: actionBtnPosition ?? 'secondary',
38
+ },
39
+ });
40
+ }
41
+ };
42
+ const makeCellActionButton = ({ cellActionBtn, actionBtnIndex, actionBtnPosition, }) => {
43
+ return (React.createElement(GidsButton, { as: "button", appearance: cellActionBtn?.appearance ?? 'default', size: cellActionBtn?.size ?? 'md', disabled: cellActionBtn?.disabled, destructive: cellActionBtn?.destructive, positive: cellActionBtn?.positive, loading: cellActionBtn?.loading, width: cellActionBtn?.width ?? 'intrinsic', type: "button", leadingIcon: makeCellActionBtnIcon({
44
+ cellActionBtn,
45
+ neededIconType: 'leading',
46
+ }), trailingIcon: makeCellActionBtnIcon({
47
+ cellActionBtn,
48
+ neededIconType: 'trailing',
49
+ }), onClick: (event) => onActionBtnClick({ event, actionBtnIndex, actionBtnPosition }) }, cellActionBtn?.buttonLabel ?? ''));
50
+ };
51
+ const makeCellActionBtns = (actionBtnPosition) => {
52
+ const cellActionBtns = actionBtnPosition === 'primary'
53
+ ? cellPrimaryActionButtons
54
+ : cellSecondaryActionButtons;
55
+ if (!cellActionBtns || cellActionBtns.length <= 0) {
56
+ return undefined;
57
+ }
58
+ return (React.createElement("div", { className: actionBtnPosition === 'primary'
59
+ ? 'gids-table-cell__primary-action-btn-container'
60
+ : 'gids-table-cell__secondary-action-btn-container' }, cellActionBtns.map((_, actionBtnIndex) => {
61
+ const cellActionBtnIndex = actionBtnPosition === 'primary'
62
+ ? cellActionBtns.length - actionBtnIndex - 1
63
+ : actionBtnIndex;
64
+ const cellActionBtn = cellActionBtns[cellActionBtnIndex];
65
+ const cellActionBtnVisible = isTableCellActionButtonVisible(cellActionBtn);
66
+ return cellActionBtnVisible
67
+ ? makeCellActionButton({
68
+ cellActionBtn,
69
+ actionBtnIndex: cellActionBtnIndex,
70
+ actionBtnPosition,
71
+ })
72
+ : undefined;
73
+ })));
74
+ };
75
+ return (React.createElement(CellTag, { ...restProps, className: getGidsTableCellClassNames({
76
+ borderSides,
77
+ borderRadiusSides,
78
+ appearance,
79
+ textAlignment,
80
+ width,
81
+ }, className), id: id, "unique-key": uniqueKey, "extra-data": JSON.stringify(extraData) },
82
+ makeCellActionBtns('primary'),
83
+ cellDataType === 'text' && label && label !== '' ? (React.createElement("span", { className: `${getGidsTableCellLabelTypographyClass(labelTypography)}` }, label)) : undefined,
84
+ cellDataType === 'display-tag' &&
85
+ displayTags &&
86
+ displayTags.length > 0 ? (React.createElement("div", { className: "gids-table-cell__display-tags-container" }, displayTags.map((displayTag) => {
87
+ return (React.createElement(GidsDisplayTag, { label: displayTag?.label ?? '', appearance: displayTag?.displayTagAppearance ?? 'subtle', size: displayTag?.displayTagSize ?? 'xs', icon: displayTag?.displayTagIcon ? (React.createElement(GidsIcon, { name: displayTag.displayTagIcon, size: displayTag?.displayTagSize ?? 'xs', appearance: displayTag?.displayTagIconAppearance ?? 'regular' })) : undefined, color: displayTag?.displayTagColor ?? 'accent-5' }));
88
+ }))) : undefined,
89
+ makeCellActionBtns('secondary')));
90
+ };
91
+ //# sourceMappingURL=GidsTableCell.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableCell.js","sourceRoot":"","sources":["../../../src/components/GidsTableCell/GidsTableCell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoD,MAAM,OAAO,CAAC;AACzE,OAAO,EAEN,qBAAqB,GAErB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAWhD,OAAO,EACN,mBAAmB,EACnB,8BAA8B,GAC9B,MAAM,sFAAsF,CAAC;AAC9F,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAEtD,MAAM,EAAE,0BAA0B,EAAE,oCAAoC,EAAE,GACzE,qBAAqB,CAAC;AA+BvB;;;GAGG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,EAC7B,EAAE,EACF,SAAS,EACT,SAAS,EACT,KAAK,EACL,YAAY,GAAG,MAAM,EACrB,WAAW,GAAG,EAAE,EAChB,KAAK,GAAG,MAAM,EACd,UAAU,GAAG,MAAM,EACnB,WAAW,GAAG,EAAE,EAChB,iBAAiB,GAAG,EAAE,EACtB,aAAa,GAAG,QAAQ,EACxB,eAAe,GAAG,cAAc,EAChC,YAAY,GAAG,KAAK,EACpB,wBAAwB,GAAG,EAAE,EAC7B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AC5B,oBAAC,QAAQ,IACR,IAAI,EAAE,UAAU,CAAC,cAAc,EAC/B,IAAI,EAAE,UAAU,EAAE,cAAc,IAAI,IAAI,EACxC,UAAU,EACT,UAAU,EAAE,wBAAwB,IAAI,SAAS,GAEjD,CACF,CAAC,CAAC,CAAC,SAAS,EAEd,KAAK,EAAE,UAAU,EAAE,eAAe,IAAI,UAAU,GAC/C,CACF,CAAC;QACH,CAAC,CAAC,CACG,CACN,CAAC,CAAC,CAAC,SAAS;QACZ,kBAAkB,CAAC,WAAW,CAAC,CACvB,CACV,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React, { MouseEvent, type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
+ import { GidsTableEntryTypographyStyle, type GidsTableEntryWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { IconAppearance, IconName } from '@ganpatiinfo/gids-web-theme-interface';
4
+ import { GidsTableEntryActionEvent } from '@ganpatiinfo/gids-core-shared';
5
+ export type GidsTableEntryActionBaseEvent = GidsTableEntryActionEvent<MouseEvent, GidsTableEntryTypographyStyle, IconName, IconAppearance>;
6
+ export interface GidsTableEntryProps extends GidsTableEntryWebProps<GidsTableEntryTypographyStyle, IconName, IconAppearance, ReactNode>, Omit<ComponentPropsWithoutRef<'td'> & ComponentPropsWithoutRef<'th'>, 'children' | 'width'> {
7
+ onEntryAction?: (event: GidsTableEntryActionBaseEvent) => void;
8
+ }
9
+ export declare const GidsTableEntry: ({ id, uniqueKey, extraData, label, entryDataTypes, displayTags, statusTags, badges, avatars, colorSwatches, progressBars, borderSides, borderRadiusSides, appearance, textAlignment, entryAlignment, labelTypography, entryType, leadingActions, trailingActions, onEntryAction, colorSwatchLabelColor, colorSwatchLabelPosition, colorSwatchLabelTypography, colorSwatchSize, colorSwatchShape, colorSwatchShadow, colorSwatchBorderRadius, colorSwatchApplyBorders, colorSwatchBorderWidth, progressBarSize, progressBarEndCap, avatarSize, avatarGroupAppearance, avatarGroupLayout, statusTagAppearance, statusTagSize, progressBarContainerMinWidth, displayTagsOrientation, statusTagsOrientation, progressBarsOrientation, colorSwatchesOrientation, badgesOrientation, children, colSpan, backgroundColor, contentColor, actionsBackgroundColor, actionsContentColor, className, ...restProps }: GidsTableEntryProps) => React.JSX.Element;
10
+ //# sourceMappingURL=GidsTableEntry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableEntry.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableEntry/GidsTableEntry.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,UAAU,EACV,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EACN,6BAA6B,EAG7B,KAAK,sBAAsB,EAC3B,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EACN,cAAc,EACd,QAAQ,EACR,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAEN,yBAAyB,EAIzB,MAAM,+BAA+B,CAAC;AAiBvC,MAAM,MAAM,6BAA6B,GAAG,yBAAyB,CACpE,UAAU,EACV,6BAA6B,EAC7B,QAAQ,EACR,cAAc,CACd,CAAC;AAEF,MAAM,WAAW,mBAChB,SACC,sBAAsB,CACrB,6BAA6B,EAC7B,QAAQ,EACR,cAAc,EACd,SAAS,CACT,EACD,IAAI,CACH,wBAAwB,CAAC,IAAI,CAAC,GAAG,wBAAwB,CAAC,IAAI,CAAC,EAC/D,UAAU,GAAG,OAAO,CACpB;IACF,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,6BAA6B,KAAK,IAAI,CAAC;CAC/D;AAED,eAAO,MAAM,cAAc,GAAI,y2BAoD5B,mBAAmB,sBA8ZrB,CAAC"}
@@ -0,0 +1,175 @@
1
+ import React from 'react';
2
+ import { GidsTableEntryWebUtils, isValidChildren, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsDisplayTag } from '../GidsDisplayTag/GidsDisplayTag';
4
+ import { GidsIcon } from '../GidsIcon/GidsIcon';
5
+ import { GidsTableEntryCommonUtils, } from '@ganpatiinfo/gids-core-shared';
6
+ import { GidsButton } from '../GidsButton/GidsButton';
7
+ import { GidsAvatarGroup } from '../GidsAvatarGroup/GidsAvatarGroup';
8
+ import { GidsAvatar } from '../GidsAvatar/GidsAvatar';
9
+ import { GidsBadge } from '../GidsBadge/GidsBadge';
10
+ import { GidsProgressBar } from '../GidsProgressBar/GidsProgressBar';
11
+ import { GidsStatusTag } from '../GidsStatusTag/GidsStatusTag';
12
+ import { GidsColorSwatch } from '../GidsColorSwatch/GidsColorSwatch';
13
+ const { getGidsTableEntryClassNames, getGidsTableEntryLabelTypographyClass, getTableEntryAlignment, } = GidsTableEntryWebUtils;
14
+ const { isTableEntryActionButtonVisible, getTableEntryActionBtnIcon } = GidsTableEntryCommonUtils;
15
+ export const GidsTableEntry = ({ id, uniqueKey, extraData, label, entryDataTypes = ['text'], displayTags = [], statusTags = [], badges = [], avatars = [], colorSwatches = [], progressBars = [], borderSides = [], borderRadiusSides = [], appearance = 'none', textAlignment = 'center', entryAlignment = 'center', labelTypography = 'label-medium', entryType = 'body', leadingActions = [], trailingActions = [], onEntryAction, colorSwatchLabelColor = 'default', colorSwatchLabelPosition = 'left', colorSwatchLabelTypography = 'label-medium', colorSwatchSize = 'sm', colorSwatchShape = 'oval', colorSwatchShadow = 'shadow-overlay', colorSwatchBorderRadius = 'none', colorSwatchApplyBorders = true, colorSwatchBorderWidth = 'thick', progressBarSize = 'sm', progressBarEndCap = true, avatarSize = 'sm', avatarGroupAppearance, avatarGroupLayout, statusTagAppearance = 'subtle', statusTagSize = 'sm', progressBarContainerMinWidth = 200, displayTagsOrientation = 'horizontal', statusTagsOrientation = 'horizontal', progressBarsOrientation = 'horizontal', colorSwatchesOrientation = 'horizontal', badgesOrientation = 'horizontal', children, colSpan, backgroundColor, contentColor, actionsBackgroundColor, actionsContentColor, className, ...restProps }) => {
16
+ let EntryTag = 'td';
17
+ if (entryType === 'header') {
18
+ EntryTag = 'th';
19
+ }
20
+ else if (entryType === 'footer') {
21
+ EntryTag = 'td';
22
+ }
23
+ function makeEntryActionBtnIcon({ entryActionBtn, neededIconType = 'leading', }) {
24
+ const tableEntryBtnIcon = getTableEntryActionBtnIcon({
25
+ entryActionButton: entryActionBtn,
26
+ neededIconType,
27
+ });
28
+ return tableEntryBtnIcon?.entryIconName &&
29
+ tableEntryBtnIcon.entryIconName.toString() !== '' ? (React.createElement(GidsIcon, { name: tableEntryBtnIcon.entryIconName, size: tableEntryBtnIcon.entryIconSize, appearance: tableEntryBtnIcon.entryIconAppearance })) : undefined;
30
+ }
31
+ function onActionBtnClick({ event, actionIndex, actionPosition, }) {
32
+ if (onEntryAction) {
33
+ onEntryAction({
34
+ originalEvent: event,
35
+ details: {
36
+ appearance,
37
+ entryDataTypes,
38
+ displayTags,
39
+ statusTags,
40
+ colorSwatches,
41
+ progressBars,
42
+ avatars,
43
+ badges,
44
+ label,
45
+ id,
46
+ extraData,
47
+ entryType,
48
+ uniqueKey,
49
+ actionNumber: `action-btn-${actionIndex + 1}`,
50
+ actionIndex: actionIndex,
51
+ actionPosition: actionPosition ?? 'trailing',
52
+ },
53
+ });
54
+ }
55
+ }
56
+ function makeEntryActionButton({ entryActionBtn, actionIndex, actionPosition, }) {
57
+ return (React.createElement(GidsButton, { key: `${actionIndex + 1}`, as: "button", appearance: entryActionBtn?.appearance ?? 'default', size: entryActionBtn?.size ?? 'md', disabled: entryActionBtn?.disabled, destructive: entryActionBtn?.destructive, positive: entryActionBtn?.positive, loading: entryActionBtn?.loading, width: entryActionBtn?.width ?? 'intrinsic', type: "button", leadingIcon: makeEntryActionBtnIcon({
58
+ entryActionBtn,
59
+ neededIconType: 'leading',
60
+ }), trailingIcon: makeEntryActionBtnIcon({
61
+ entryActionBtn,
62
+ neededIconType: 'trailing',
63
+ }), onClick: (event) => onActionBtnClick({ event, actionIndex, actionPosition }) }, entryActionBtn?.buttonLabel ?? ''));
64
+ }
65
+ function makeEntryActionBtns(actionPosition) {
66
+ const entryActionBtns = actionPosition === 'leading' ? leadingActions : trailingActions;
67
+ if (!entryActionBtns || entryActionBtns.length <= 0) {
68
+ return undefined;
69
+ }
70
+ return (React.createElement("div", { className: actionPosition === 'leading'
71
+ ? 'gids-table-entry__leading-actions-container'
72
+ : 'gids-table-entry__trailing-actions-container' }, entryActionBtns.map((_, actionIndex) => {
73
+ const entryActionBtnIndex = actionPosition === 'leading'
74
+ ? entryActionBtns.length - actionIndex - 1
75
+ : actionIndex;
76
+ const entryActionBtn = entryActionBtns[entryActionBtnIndex];
77
+ const entryActionBtnVisible = isTableEntryActionButtonVisible(entryActionBtn);
78
+ return entryActionBtnVisible
79
+ ? makeEntryActionButton({
80
+ entryActionBtn,
81
+ actionIndex: entryActionBtnIndex,
82
+ actionPosition,
83
+ })
84
+ : undefined;
85
+ })));
86
+ }
87
+ function makeEntryAvatars() {
88
+ if (entryDataTypes.includes('avatar') && avatars && avatars.length > 0) {
89
+ return (React.createElement(GidsAvatarGroup, { appearance: avatarGroupAppearance ? avatarGroupAppearance : 'spread', layout: avatarGroupLayout ? avatarGroupLayout : 'wrap' }, avatars.map((avatar, indexI) => {
90
+ return (React.createElement(GidsAvatar, { key: `${indexI + 1}`, size: avatarSize, alt: avatar?.avatarAlt ?? '', appearance: avatar?.avatarAppearance ?? 'icon', badge: React.createElement(GidsBadge, { appearance: avatar?.avatarBadge?.badgeAppearance ?? 'information', count: avatar?.avatarBadge?.badgeCount ?? undefined, accessibleText: avatar?.avatarBadge?.badgeAccessibleText ?? '', type: avatar?.avatarBadge?.badgeType ?? 'dot', outline: avatar?.avatarBadge?.badgeOutline ?? false }), color: avatar?.avatarColor ?? 'default', imageSrc: avatar?.avatarImageSrc ?? '', text: avatar?.avatarText ?? '' }));
91
+ })));
92
+ }
93
+ return undefined;
94
+ }
95
+ function makeEntryProgressBars() {
96
+ if (entryDataTypes.includes('progress-bar') &&
97
+ progressBars &&
98
+ progressBars.length > 0) {
99
+ return (React.createElement("div", { className: progressBarsOrientation === 'horizontal'
100
+ ? 'gids-table-entry__progress-bars-container-horizontal'
101
+ : 'gids-table-entry__progress-bars-container-vertical', style: (progressBarContainerMinWidth
102
+ ? {
103
+ '--gidsProgressBarContainer-min-width': `${progressBarContainerMinWidth}px`,
104
+ }
105
+ : {}) }, progressBars.map((progressBar, indexI) => {
106
+ return (React.createElement(GidsProgressBar, { key: `${indexI + 1}`, size: progressBarSize, color: progressBar?.progressBarColor ?? 'default', indeterminate: progressBar?.progressBarIndeterminate ?? true, value: progressBar?.progressBarValue, max: progressBar?.progressBarMax ?? 1, endCap: progressBarEndCap }));
107
+ })));
108
+ }
109
+ return undefined;
110
+ }
111
+ function makeEntryStatusTags() {
112
+ if (entryDataTypes.includes('status-tag') &&
113
+ statusTags &&
114
+ statusTags.length > 0) {
115
+ return (React.createElement("div", { className: statusTagsOrientation === 'horizontal'
116
+ ? 'gids-table-entry__common-items-container-horizontal'
117
+ : 'gids-table-entry__common-items-container-vertical' }, statusTags.map((statusTag, indexI) => {
118
+ return (React.createElement(GidsStatusTag, { key: `${indexI + 1}`, type: statusTag?.statusTagType ?? 'unknown', appearance: statusTagAppearance ?? 'subtle', size: statusTagSize ?? 'sm' }));
119
+ })));
120
+ }
121
+ return undefined;
122
+ }
123
+ function makeEntryColorSwatches() {
124
+ if (entryDataTypes.includes('color-swatch') &&
125
+ colorSwatches &&
126
+ colorSwatches.length > 0) {
127
+ return (React.createElement("div", { className: colorSwatchesOrientation === 'horizontal'
128
+ ? 'gids-table-entry__common-items-container-horizontal'
129
+ : 'gids-table-entry__common-items-container-vertical' }, colorSwatches.map((colorSwatch, indexI) => {
130
+ return (React.createElement(GidsColorSwatch, { key: `${indexI + 1}`, label: colorSwatch?.colorSwatchLabel, labelColor: colorSwatchLabelColor, labelTypography: colorSwatchLabelTypography, labelPosition: colorSwatchLabelPosition, swatchColor: colorSwatch?.colorSwatchColor, swatchSize: colorSwatchSize, swatchShape: colorSwatchShape, swatchShadow: colorSwatchShadow, borderRadius: colorSwatchBorderRadius, applyBorders: colorSwatchApplyBorders, borderColor: colorSwatch?.colorSwatchBorderColor, borderWidth: colorSwatchBorderWidth }));
131
+ })));
132
+ }
133
+ return undefined;
134
+ }
135
+ function makeEntryBadges() {
136
+ if (entryDataTypes.includes('badge') && badges && badges.length > 0) {
137
+ return (React.createElement("div", { className: badgesOrientation === 'horizontal'
138
+ ? 'gids-table-entry__common-items-container-horizontal'
139
+ : 'gids-table-entry__common-items-container-vertical' }, badges.map((badge, indexI) => {
140
+ return (React.createElement(GidsBadge, { key: `${indexI + 1}`, appearance: badge.badgeAppearance ?? 'information', count: badge?.badgeCount ?? undefined, accessibleText: badge?.badgeAccessibleText ?? '', type: badge?.badgeType ?? 'dot', outline: badge?.badgeOutline ?? true }));
141
+ })));
142
+ }
143
+ return undefined;
144
+ }
145
+ return (React.createElement(EntryTag, { ...restProps, className: getGidsTableEntryClassNames({
146
+ borderSides,
147
+ borderRadiusSides,
148
+ appearance,
149
+ textAlignment,
150
+ }, className), style: {
151
+ backgroundColor: backgroundColor,
152
+ color: contentColor,
153
+ '--gidsButton-color-default-text': actionsContentColor,
154
+ '--gidsButton-color-icon': actionsContentColor,
155
+ '--gidsButton-color-default-bg': actionsBackgroundColor,
156
+ '--gidsButton-color-primary-bg': actionsBackgroundColor,
157
+ '--gidsButton-color-subtle-bg': actionsBackgroundColor,
158
+ }, id: id, "unique-key": uniqueKey, "extra-data": JSON.stringify(extraData), colSpan: colSpan }, isValidChildren(children) ? (children) : (React.createElement("div", { className: getTableEntryAlignment({ entryAlignment }) },
159
+ makeEntryActionBtns('leading'),
160
+ entryDataTypes.includes('text') && label && label !== '' ? (React.createElement("span", { className: `${getGidsTableEntryLabelTypographyClass(labelTypography)}` }, label)) : undefined,
161
+ entryDataTypes.includes('display-tag') &&
162
+ displayTags &&
163
+ displayTags.length > 0 ? (React.createElement("div", { className: displayTagsOrientation === 'horizontal'
164
+ ? 'gids-table-entry__common-items-container-horizontal'
165
+ : 'gids-table-entry__common-items-container-vertical' }, displayTags.map((displayTag, indexI) => {
166
+ return (React.createElement(GidsDisplayTag, { key: `${indexI + 1}`, label: displayTag?.label ?? '', appearance: displayTag?.displayTagAppearance ?? 'subtle', size: displayTag?.displayTagSize ?? 'xs', icon: displayTag?.displayTagIcon ? (React.createElement(GidsIcon, { name: displayTag.displayTagIcon, size: displayTag?.displayTagSize ?? 'xs', appearance: displayTag?.displayTagIconAppearance ?? 'regular' })) : undefined, color: displayTag?.displayTagColor ?? 'accent-5' }));
167
+ }))) : undefined,
168
+ makeEntryAvatars(),
169
+ makeEntryProgressBars(),
170
+ makeEntryStatusTags(),
171
+ makeEntryColorSwatches(),
172
+ makeEntryBadges(),
173
+ makeEntryActionBtns('trailing')))));
174
+ };
175
+ //# sourceMappingURL=GidsTableEntry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableEntry.js","sourceRoot":"","sources":["../../../src/components/GidsTableEntry/GidsTableEntry.tsx"],"names":[],"mappings":"AAAA,OAAO,KAIN,MAAM,OAAO,CAAC;AACf,OAAO,EAEN,sBAAsB,EACtB,eAAe,GAEf,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAClE,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAKhD,OAAO,EAIN,yBAAyB,GAEzB,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AACtD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,oCAAoC,CAAC;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xC,UAAU,EACT,UAAU,EAAE,wBAAwB,IAAI,SAAS,GAEjD,CACF,CAAC,CAAC,CAAC,SAAS,EAEd,KAAK,EAAE,UAAU,EAAE,eAAe,IAAI,UAAU,GAC/C,CACF,CAAC;QACH,CAAC,CAAC,CACG,CACN,CAAC,CAAC,CAAC,SAAS;QACZ,gBAAgB,EAAE;QAClB,qBAAqB,EAAE;QACvB,mBAAmB,EAAE;QACrB,sBAAsB,EAAE;QACxB,eAAe,EAAE;QACjB,mBAAmB,CAAC,UAAU,CAAC,CAC3B,CACN,CACS,CACX,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import React, { type MouseEvent, type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
+ import { GidsTableEntryTypographyStyle, GidsTableFooterWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { IconAppearance, IconName } from '@ganpatiinfo/gids-web-theme-interface';
4
+ import { GidsTableFooterActionEvent } from '@ganpatiinfo/gids-core-shared';
5
+ export type GidsTableFooterNativeInputForwardedProps = Partial<Omit<ComponentPropsWithoutRef<'input'>, 'value' | 'readOnly' | 'name' | 'disabled'>>;
6
+ export type GidsTableFooterBaseWebProps = GidsTableFooterWebProps<GidsTableEntryTypographyStyle, IconName, IconAppearance, ReactNode, ReactNode, GidsTableFooterNativeInputForwardedProps, MouseEvent> & Omit<ComponentPropsWithoutRef<'tfoot'>, 'children'>;
7
+ export type GidsTableFooterActionBaseEvent = GidsTableFooterActionEvent<MouseEvent, GidsTableEntryTypographyStyle, IconName, IconAppearance>;
8
+ export interface GidsTableFooterProps extends GidsTableFooterBaseWebProps {
9
+ onFooterAction?: (event: GidsTableFooterActionBaseEvent) => void;
10
+ }
11
+ export declare const GidsTableFooter: ({ appearance, labelTypography, textAlignment, leadingActions, trailingActions, entryAlignment, colorSwatchLabelColor, colorSwatchLabelPosition, colorSwatchLabelTypography, colorSwatchSize, colorSwatchShape, colorSwatchShadow, colorSwatchBorderRadius, colorSwatchApplyBorders, colorSwatchBorderWidth, progressBarSize, progressBarEndCap, avatarSize, avatarGroupAppearance, avatarGroupLayout, statusTagAppearance, statusTagSize, progressBarContainerMinWidth, displayTagsOrientation, statusTagsOrientation, progressBarsOrientation, colorSwatchesOrientation, badgesOrientation, footerControlSettings, footerControlChildren, footerItems, onFooterAction, children, className, ...restProps }: GidsTableFooterProps) => React.JSX.Element;
12
+ //# sourceMappingURL=GidsTableFooter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableFooter.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableFooter/GidsTableFooter.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,KAAK,UAAU,EACf,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EACN,6BAA6B,EAC7B,uBAAuB,EAGvB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACN,cAAc,EACd,QAAQ,EACR,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,0BAA0B,EAAE,MAAM,+BAA+B,CAAC;AAO3E,MAAM,MAAM,wCAAwC,GAAG,OAAO,CAC7D,IAAI,CACH,wBAAwB,CAAC,OAAO,CAAC,EACjC,OAAO,GAAG,UAAU,GAAG,MAAM,GAAG,UAAU,CAC1C,CACD,CAAC;AAEF,MAAM,MAAM,2BAA2B,GAAG,uBAAuB,CAChE,6BAA6B,EAC7B,QAAQ,EACR,cAAc,EACd,SAAS,EACT,SAAS,EACT,wCAAwC,EACxC,UAAU,CACV,GACA,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAAC,EAAE,UAAU,CAAC,CAAC;AAErD,MAAM,MAAM,8BAA8B,GAAG,0BAA0B,CACtE,UAAU,EACV,6BAA6B,EAC7B,QAAQ,EACR,cAAc,CACd,CAAC;AAEF,MAAM,WAAW,oBAAqB,SAAQ,2BAA2B;IACxE,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,8BAA8B,KAAK,IAAI,CAAC;CACjE;AAED,eAAO,MAAM,eAAe,GAAI,6qBAuC7B,oBAAoB,sBAwFtB,CAAC"}
@@ -0,0 +1,43 @@
1
+ import React from 'react';
2
+ import { GidsTableFooterWebUtils, isValidChildren, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsTableRow } from '../GidsTableRow/GidsTableRow';
4
+ import { GidsTableEntry } from '../GidsTableEntry/GidsTableEntry';
5
+ import { GidsTableFooterControl } from '../GidsTableFooterControl/GidsTableFooterControl';
6
+ const { getGidsTableFooterClassNames } = GidsTableFooterWebUtils;
7
+ export const GidsTableFooter = ({
8
+ // Table Entry Props
9
+ appearance = 'none', labelTypography = 'label-medium', textAlignment = 'center', leadingActions = [], trailingActions = [], entryAlignment = 'center', colorSwatchLabelColor = 'default', colorSwatchLabelPosition = 'left', colorSwatchLabelTypography = 'label-medium', colorSwatchSize = 'sm', colorSwatchShape = 'oval', colorSwatchShadow = 'shadow-overlay', colorSwatchBorderRadius = 'none', colorSwatchApplyBorders = true, colorSwatchBorderWidth = 'thick', progressBarSize = 'sm', progressBarEndCap = true, avatarSize = 'sm', avatarGroupAppearance = 'spread', avatarGroupLayout = 'wrap', statusTagAppearance = 'subtle', statusTagSize = 'sm', progressBarContainerMinWidth = 200, displayTagsOrientation = 'horizontal', statusTagsOrientation = 'horizontal', progressBarsOrientation = 'horizontal', colorSwatchesOrientation = 'horizontal', badgesOrientation = 'horizontal',
10
+ // Footer Props
11
+ footerControlSettings, footerControlChildren, footerItems, onFooterAction, children, className, ...restProps }) => {
12
+ const renderFooterRow = () => {
13
+ if (isValidChildren(children)) {
14
+ return children;
15
+ }
16
+ else {
17
+ if (footerItems && footerItems.length > 0) {
18
+ return (React.createElement(GidsTableRow, { rows: footerItems, rowType: "footer", leadingActions: leadingActions, trailingActions: trailingActions, entryAlignment: entryAlignment, colorSwatchLabelColor: colorSwatchLabelColor, colorSwatchLabelPosition: colorSwatchLabelPosition, colorSwatchLabelTypography: colorSwatchLabelTypography, colorSwatchSize: colorSwatchSize, colorSwatchShape: colorSwatchShape, colorSwatchShadow: colorSwatchShadow, colorSwatchBorderRadius: colorSwatchBorderRadius, colorSwatchApplyBorders: colorSwatchApplyBorders, colorSwatchBorderWidth: colorSwatchBorderWidth, progressBarSize: progressBarSize, progressBarEndCap: progressBarEndCap, avatarSize: avatarSize, avatarGroupAppearance: avatarGroupAppearance, avatarGroupLayout: avatarGroupLayout, statusTagAppearance: statusTagAppearance, statusTagSize: statusTagSize, progressBarContainerMinWidth: progressBarContainerMinWidth, displayTagsOrientation: displayTagsOrientation, statusTagsOrientation: statusTagsOrientation, progressBarsOrientation: progressBarsOrientation, colorSwatchesOrientation: colorSwatchesOrientation, badgesOrientation: badgesOrientation, textAlignment: textAlignment, labelTypography: labelTypography, appearance: appearance, onRowAction: onFooterAction }));
19
+ }
20
+ }
21
+ return undefined;
22
+ };
23
+ const renderFooterControlRow = () => {
24
+ const isValidFooterChildren = isValidChildren(footerControlChildren);
25
+ const colSpan = footerItems?.length ?? 1;
26
+ if (isValidFooterChildren ||
27
+ (footerControlSettings && Object.keys(footerControlSettings).length > 0)) {
28
+ let resolvedFooterControlSettings = {};
29
+ if (footerControlSettings &&
30
+ Object.keys(footerControlSettings).length > 0) {
31
+ resolvedFooterControlSettings = footerControlSettings;
32
+ }
33
+ return (React.createElement(GidsTableRow, { rowType: "footer", appearance: appearance },
34
+ React.createElement(GidsTableEntry, { entryType: "footer", appearance: appearance, colSpan: colSpan },
35
+ React.createElement(GidsTableFooterControl, { ...resolvedFooterControlSettings }, footerControlChildren))));
36
+ }
37
+ return undefined;
38
+ };
39
+ return (React.createElement("tfoot", { className: getGidsTableFooterClassNames(className), ...restProps },
40
+ renderFooterRow(),
41
+ renderFooterControlRow()));
42
+ };
43
+ //# sourceMappingURL=GidsTableFooter.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableFooter.js","sourceRoot":"","sources":["../../../src/components/GidsTableFooter/GidsTableFooter.tsx"],"names":[],"mappings":"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qB,CACrB,CAAC;QACF,MAAM,OAAO,GAAG,WAAW,EAAE,MAAM,IAAI,CAAC,CAAC;QAEzC,IACC,qBAAqB;YACrB,CAAC,qBAAqB,IAAI,MAAM,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC,EACvE,CAAC;YACF,IAAI,6BAA6B,GAAG,EAAE,CAAC;YACvC,IACC,qBAAqB;gBACrB,MAAM,CAAC,IAAI,CAAC,qBAAqB,CAAC,CAAC,MAAM,GAAG,CAAC,EAC5C,CAAC;gBACF,6BAA6B,GAAG,qBAAqB,CAAC;YACvD,CAAC;YAED,OAAO,CACN,oBAAC,YAAY,IAAC,OAAO,EAAC,QAAQ,EAAC,UAAU,EAAE,UAAU;gBACpD,oBAAC,cAAc,IACd,SAAS,EAAC,QAAQ,EAClB,UAAU,EAAE,UAAU,EACtB,OAAO,EAAE,OAAO;oBAEhB,oBAAC,sBAAsB,OAAK,6BAA6B,IACvD,qBAAqB,CACE,CACT,CACH,CACf,CAAC;QACH,CAAC;QAED,OAAO,SAAS,CAAC;IAClB,CAAC,CAAC;IAEF,OAAO,CACN,+BAAO,SAAS,EAAE,4BAA4B,CAAC,SAAS,CAAC,KAAM,SAAS;QACtE,eAAe,EAAE;QACjB,sBAAsB,EAAE,CAClB,CACR,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ import React, { MouseEvent, type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
+ import { GidsTableFooterControlWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { IconName } from '@ganpatiinfo/gids-web-theme-interface';
4
+ export type TableFooterNativeInputForwardedProps = Omit<ComponentPropsWithoutRef<'input'>, 'disabled' | 'readOnly' | 'value' | 'name'>;
5
+ export type GidsTableFooterControlBaseWebProps = GidsTableFooterControlWebProps<IconName, ReactNode, TableFooterNativeInputForwardedProps, ReactNode, MouseEvent> & Omit<ComponentPropsWithoutRef<'div'>, 'children' | 'onChange' | 'onClick'>;
6
+ export type GidsTableFooterControlProps = GidsTableFooterControlBaseWebProps;
7
+ export declare const GidsTableFooterControl: ({ bulkStatus, rangeStatus, tableViewControllerSettings, paginatorSettings, tableViewControllerVisible, paginatorVisible, children, className, }: GidsTableFooterControlProps) => React.JSX.Element;
8
+ //# sourceMappingURL=GidsTableFooterControl.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableFooterControl.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableFooterControl/GidsTableFooterControl.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,UAAU,EACV,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EACN,8BAA8B,EAG9B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,QAAQ,EAAE,MAAM,uCAAuC,CAAC;AASjE,MAAM,MAAM,oCAAoC,GAAG,IAAI,CACtD,wBAAwB,CAAC,OAAO,CAAC,EACjC,UAAU,GAAG,UAAU,GAAG,OAAO,GAAG,MAAM,CAC1C,CAAC;AAEF,MAAM,MAAM,kCAAkC,GAAG,8BAA8B,CAC9E,QAAQ,EACR,SAAS,EACT,oCAAoC,EACpC,SAAS,EACT,UAAU,CACV,GACA,IAAI,CAAC,wBAAwB,CAAC,KAAK,CAAC,EAAE,UAAU,GAAG,UAAU,GAAG,SAAS,CAAC,CAAC;AAE5E,MAAM,MAAM,2BAA2B,GAAG,kCAAkC,CAAC;AAE7E,eAAO,MAAM,sBAAsB,GAAI,iJASpC,2BAA2B,sBAuF7B,CAAC"}
@@ -0,0 +1,44 @@
1
+ import React from 'react';
2
+ import { GidsTableFooterControlWebUtils, isValidChildren, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsPaginator } from '../GidsPaginator/GidsPaginator';
4
+ import { GidsDropdownField } from '../stencil-generated/gids-dropdown-field.js';
5
+ import { GidsDropdownMenuGroup } from '../GidsDropdownMenuGroup/GidsDropdownMenuGroup';
6
+ import { GidsDropdownMenu } from '../GidsDropdownMenu/GidsDropdownMenu';
7
+ import { GidsDropdownItem } from '../GidsDropdownItem/GidsDropdownItem';
8
+ const { getGidsTableFooterControlClassNames } = GidsTableFooterControlWebUtils;
9
+ export const GidsTableFooterControl = ({ bulkStatus, rangeStatus, tableViewControllerSettings, paginatorSettings, tableViewControllerVisible, paginatorVisible, children, className, }) => {
10
+ const renderTableViewController = () => {
11
+ if (tableViewControllerVisible &&
12
+ tableViewControllerSettings &&
13
+ Object.keys(tableViewControllerSettings).length > 0) {
14
+ const { tableViewControllerOptions, ...restTableViewControllerSettings } = tableViewControllerSettings;
15
+ const controllerOptions = tableViewControllerOptions ?? [];
16
+ if (controllerOptions && controllerOptions.length > 0) {
17
+ return (React.createElement(GidsDropdownField, { ...restTableViewControllerSettings,
18
+ // @ts-expect-error as this is a stencil component
19
+ inputProps: {
20
+ ...restTableViewControllerSettings.inputProps,
21
+ placeholder: restTableViewControllerSettings?.inputProps?.placeholder ??
22
+ 'Rows per page',
23
+ } },
24
+ React.createElement(GidsDropdownMenuGroup, { type: "default" }, controllerOptions.map((controllerOption, sectionIndex) => {
25
+ const items = controllerOption?.items ?? [];
26
+ return (React.createElement(GidsDropdownMenu, { key: `${sectionIndex + 1}`, sectionLabel: controllerOption?.label }, items.map((item, optionIndex) => {
27
+ return (React.createElement(GidsDropdownItem, { ...item, id: item?.id ?? `${optionIndex + 1}` }));
28
+ })));
29
+ }))));
30
+ }
31
+ }
32
+ return undefined;
33
+ };
34
+ return (React.createElement("div", { className: getGidsTableFooterControlClassNames(className) }, isValidChildren(children) ? (children) : (React.createElement("div", { className: "gids-table-footer-control__main-container" },
35
+ React.createElement("div", { className: "gids-table-footer-control__informative-container" },
36
+ renderTableViewController(),
37
+ React.createElement("span", { className: "gids-table-footer-control__range-status-label" }, rangeStatus),
38
+ React.createElement("span", { className: "gids-table-footer-control__bulk-status-label" }, bulkStatus)),
39
+ paginatorVisible &&
40
+ paginatorSettings &&
41
+ Object.keys(paginatorSettings).length > 0 ? (React.createElement("div", { className: "gids-table-footer-control__paginator-container" },
42
+ React.createElement(GidsPaginator, { ...paginatorSettings, size: paginatorSettings?.size ?? 'md', shape: paginatorSettings?.shape ?? 'rounded', variant: paginatorSettings?.variant ?? 'default', showFirstPageBtn: paginatorSettings?.showFirstPageBtn ?? true, showLastPageBtn: paginatorSettings?.showLastPageBtn ?? true, showNextBtn: paginatorSettings?.showNextBtn ?? true, showPreviousBtn: paginatorSettings?.showPreviousBtn ?? true }))) : undefined))));
43
+ };
44
+ //# sourceMappingURL=GidsTableFooterControl.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableFooterControl.js","sourceRoot":"","sources":["../../../src/components/GidsTableFooterControl/GidsTableFooterControl.tsx"],"names":[],"mappings":"AAAA,OAAO,KAIN,MAAM,OAAO,CAAC;AACf,OAAO,EAEN,8BAA8B,EAC9B,eAAe,GACf,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,6CAA6C,CAAC;AAChF,OAAO,EAAE,qBAAqB,EAAE,MAAM,gDAAgD,CAAC;AACvF,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AACxE,OAAO,EAAE,gBAAgB,EAAE,MAAM,sCAAsC,CAAC;AAExE,MAAM,EAAE,mCAAmC,EAAE,GAAG,8BAA8B,CAAC;AAkB/E,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,EACtC,UAAU,EACV,WAAW,EACX,2BAA2B,EAC3B,iBAAiB,EACjB,0BAA0B,EAC1B,gBAAgB,EAChB,QAAQ,EACR,SAAS,GACoB,EAAE,EAAE;IACjC,MAAM,yBAAyB,GAAG,GAAG,EAAE;QACtC,IACC,0BAA0B;YAC1B,2BAA2B;YAC3B,MAAM,CAAC,IAAI,CAAC,2BAA2B,CAAC,CAAC,MAAM,GAAG,CAAC,EAClD,CAA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,EAAC,kDAAkD;YAC/D,yBAAyB,EAAE;YAC5B,8BAAM,SAAS,EAAC,+CAA+C,IAC7D,WAAW,CACN;YACP,8BAAM,SAAS,EAAC,8CAA8C,IAC5D,UAAU,CACL,CACF;QACL,gBAAgB;YACjB,iBAAiB;YACjB,MAAM,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CAC3C,6BAAK,SAAS,EAAC,gDAAgD;YAC9D,oBAAC,aAAa,OACT,iBAAiB,EACrB,IAAI,EAAE,iBAAiB,EAAE,IAAI,IAAI,IAAI,EACrC,KAAK,EAAE,iBAAiB,EAAE,KAAK,IAAI,SAAS,EAC5C,OAAO,EAAE,iBAAiB,EAAE,OAAO,IAAI,SAAS,EAChD,gBAAgB,EAAE,iBAAiB,EAAE,gBAAgB,IAAI,IAAI,EAC7D,eAAe,EAAE,iBAAiB,EAAE,eAAe,IAAI,IAAI,EAC3D,WAAW,EAAE,iBAAiB,EAAE,WAAW,IAAI,IAAI,EACnD,eAAe,EAAE,iBAAiB,EAAE,eAAe,IAAI,IAAI,GAC1D,CACG,CACN,CAAC,CAAC,CAAC,SAAS,CACR,CACN,CACI,CACN,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React, { MouseEvent, type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
+ import { GidsTableEntryTypographyStyle, GidsTableHeaderWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsTableHeaderActionEvent } from '@ganpatiinfo/gids-core-shared';
4
+ import { IconAppearance, IconName } from '@ganpatiinfo/gids-web-theme-interface';
5
+ export type GidsTableHeaderActionBaseEvent = GidsTableHeaderActionEvent<MouseEvent, GidsTableEntryTypographyStyle, IconName, IconAppearance>;
6
+ export interface GidsTableHeaderProps extends GidsTableHeaderWebProps<GidsTableEntryTypographyStyle, IconName, IconAppearance, ReactNode>, Omit<ComponentPropsWithoutRef<'thead'>, 'children'> {
7
+ onHeaderAction?: (event: GidsTableHeaderActionBaseEvent) => void;
8
+ }
9
+ export declare const GidsTableHeader: ({ headerItems, appearance, labelTypography, textAlignment, leadingActions, trailingActions, onHeaderAction, entryAlignment, colorSwatchLabelColor, colorSwatchLabelPosition, colorSwatchLabelTypography, colorSwatchSize, colorSwatchShape, colorSwatchShadow, colorSwatchBorderRadius, colorSwatchApplyBorders, colorSwatchBorderWidth, progressBarSize, progressBarEndCap, avatarSize, avatarGroupAppearance, avatarGroupLayout, statusTagAppearance, statusTagSize, progressBarContainerMinWidth, displayTagsOrientation, statusTagsOrientation, progressBarsOrientation, colorSwatchesOrientation, badgesOrientation, children, className, ...restProps }: GidsTableHeaderProps) => React.JSX.Element;
10
+ //# sourceMappingURL=GidsTableHeader.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableHeader.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableHeader/GidsTableHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,UAAU,EACV,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EACN,6BAA6B,EAC7B,uBAAuB,EAGvB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EAAE,0BAA0B,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,EACN,cAAc,EACd,QAAQ,EACR,MAAM,uCAAuC,CAAC;AAI/C,MAAM,MAAM,8BAA8B,GAAG,0BAA0B,CACtE,UAAU,EACV,6BAA6B,EAC7B,QAAQ,EACR,cAAc,CACd,CAAC;AAEF,MAAM,WAAW,oBAChB,SACC,uBAAuB,CACtB,6BAA6B,EAC7B,QAAQ,EACR,cAAc,EACd,SAAS,CACT,EACD,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAAC,EAAE,UAAU,CAAC;IACpD,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,8BAA8B,KAAK,IAAI,CAAC;CACjE;AAED,eAAO,MAAM,eAAe,GAAI,+nBAkC7B,oBAAoB,sBAqDtB,CAAC"}
@@ -0,0 +1,20 @@
1
+ import React from 'react';
2
+ import { GidsTableHeaderWebUtils, isValidChildren, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsTableRow } from '../GidsTableRow/GidsTableRow';
4
+ const { getGidsTableHeaderClassNames } = GidsTableHeaderWebUtils;
5
+ export const GidsTableHeader = ({ headerItems = [], appearance = 'none', labelTypography = 'label-medium', textAlignment = 'center', leadingActions = [], trailingActions = [], onHeaderAction, entryAlignment = 'center', colorSwatchLabelColor = 'default', colorSwatchLabelPosition = 'left', colorSwatchLabelTypography = 'label-medium', colorSwatchSize = 'sm', colorSwatchShape = 'oval', colorSwatchShadow = 'shadow-overlay', colorSwatchBorderRadius = 'none', colorSwatchApplyBorders = true, colorSwatchBorderWidth = 'thick', progressBarSize = 'sm', progressBarEndCap = true, avatarSize = 'sm', avatarGroupAppearance = 'spread', avatarGroupLayout = 'wrap', statusTagAppearance = 'subtle', statusTagSize = 'sm', progressBarContainerMinWidth = 200, displayTagsOrientation = 'horizontal', statusTagsOrientation = 'horizontal', progressBarsOrientation = 'horizontal', colorSwatchesOrientation = 'horizontal', badgesOrientation = 'horizontal', children, className, ...restProps }) => {
6
+ const tableHeaderClassName = getGidsTableHeaderClassNames(className);
7
+ const renderChildrens = () => {
8
+ if (isValidChildren(children)) {
9
+ return children;
10
+ }
11
+ else {
12
+ if (headerItems && headerItems.length > 0) {
13
+ return (React.createElement(GidsTableRow, { rows: headerItems, rowType: "header", leadingActions: leadingActions, trailingActions: trailingActions, entryAlignment: entryAlignment, colorSwatchLabelColor: colorSwatchLabelColor, colorSwatchLabelPosition: colorSwatchLabelPosition, colorSwatchLabelTypography: colorSwatchLabelTypography, colorSwatchSize: colorSwatchSize, colorSwatchShape: colorSwatchShape, colorSwatchShadow: colorSwatchShadow, colorSwatchBorderRadius: colorSwatchBorderRadius, colorSwatchApplyBorders: colorSwatchApplyBorders, colorSwatchBorderWidth: colorSwatchBorderWidth, progressBarSize: progressBarSize, progressBarEndCap: progressBarEndCap, avatarSize: avatarSize, avatarGroupAppearance: avatarGroupAppearance, avatarGroupLayout: avatarGroupLayout, statusTagAppearance: statusTagAppearance, statusTagSize: statusTagSize, progressBarContainerMinWidth: progressBarContainerMinWidth, displayTagsOrientation: displayTagsOrientation, statusTagsOrientation: statusTagsOrientation, progressBarsOrientation: progressBarsOrientation, colorSwatchesOrientation: colorSwatchesOrientation, badgesOrientation: badgesOrientation, textAlignment: textAlignment, labelTypography: labelTypography, appearance: appearance, onRowAction: onHeaderAction }));
14
+ }
15
+ }
16
+ return undefined;
17
+ };
18
+ return (React.createElement("thead", { ...restProps, className: tableHeaderClassName }, renderChildrens()));
19
+ };
20
+ //# sourceMappingURL=GidsTableHeader.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableHeader.js","sourceRoot":"","sources":["../../../src/components/GidsTableHeader/GidsTableHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAIN,MAAM,OAAO,CAAC;AACf,OAAO,EAGN,uBAAuB,EACvB,eAAe,GACf,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAO5D,MAAM,EAAE,4BAA4B,EAAE,GAAG,uBAAuB,CAAC;AAqBjE,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,EAC/B,WAAW,GAAG,EAAE,EAChB,UAAU,GAAG,MAAM,EACnB,eAAe,GAAG,cAAc,EAChC,aAAa,GAAG,QAAQ,EACxB,cAAc,GAAG,EAAE,EACnB,eAAe,GAAG,EAAE,EACpB,cAAc,EACd,cAAc,GAAG,QAAQ,EACzB,qBAAqB,GAAG,SAAS,EACjC,wBAAwB,GAAG,MAAM,EACjC,0BAA0B,GAAG,cAAc,EAC3C,eAAe,GAAG,IAAI,EACtB,gBAAgB,GAAG,MAAM,EACzB,iBAAiB,GAAG,gBAAgB,EACpC,uBAAuB,GAAG,MAAM,EAChC,uBAAuB,GAA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,EAAE,iBAAiB,EACpC,mBAAmB,EAAE,mBAAmB,EACxC,aAAa,EAAE,aAAa,EAC5B,4BAA4B,EAAE,4BAA4B,EAC1D,sBAAsB,EAAE,sBAAsB,EAC9C,qBAAqB,EAAE,qBAAqB,EAC5C,uBAAuB,EAAE,uBAAuB,EAChD,wBAAwB,EAAE,wBAAwB,EAClD,iBAAiB,EAAE,iBAAiB,EACpC,aAAa,EAAE,aAAa,EAC5B,eAAe,EAAE,eAAe,EAChC,UAAU,EAAE,UAAU,EACtB,WAAW,EAAE,cAAc,GAC1B,CACF,CAAC;YACH,CAAC;QACF,CAAC;QACD,OAAO,SAAS,CAAC;IAClB,CAAC,CAAC;IAEF,OAAO,CACN,kCAAW,SAAS,EAAE,SAAS,EAAE,oBAAoB,IACnD,eAAe,EAAE,CACX,CACR,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ import React, { type MouseEvent, type ReactNode, type ComponentPropsWithoutRef } from 'react';
2
+ import { GidsTableEntryTypographyStyle, type GidsTableRowWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { IconAppearance, IconName } from '@ganpatiinfo/gids-web-theme-interface';
4
+ import { GidsTableRowActionEvent } from '@ganpatiinfo/gids-core-shared';
5
+ export type GidsTableRowActionBaseEvent = GidsTableRowActionEvent<MouseEvent, GidsTableEntryTypographyStyle, IconName, IconAppearance>;
6
+ export interface GidsTableRowProps extends GidsTableRowWebProps<GidsTableEntryTypographyStyle, IconName, IconAppearance, ReactNode>, Omit<ComponentPropsWithoutRef<'tr'>, 'children' | 'onChange'> {
7
+ onRowAction?: (event: GidsTableRowActionBaseEvent) => void;
8
+ }
9
+ export declare const GidsTableRow: ({ rows, rowType, leadingActions, trailingActions, onRowAction, entryAlignment, colorSwatchLabelColor, colorSwatchLabelPosition, colorSwatchLabelTypography, colorSwatchSize, colorSwatchShape, colorSwatchShadow, colorSwatchBorderRadius, colorSwatchApplyBorders, colorSwatchBorderWidth, progressBarSize, progressBarEndCap, avatarSize, avatarGroupAppearance, avatarGroupLayout, statusTagAppearance, statusTagSize, progressBarContainerMinWidth, displayTagsOrientation, statusTagsOrientation, progressBarsOrientation, colorSwatchesOrientation, badgesOrientation, textAlignment, labelTypography, appearance, actionsBackgroundColor, actionsContentColor, backgroundColor, contentColor, children, className, ...restProps }: GidsTableRowProps) => React.JSX.Element;
10
+ //# sourceMappingURL=GidsTableRow.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableRow.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableRow/GidsTableRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,KAAK,UAAU,EACf,KAAK,SAAS,EACd,KAAK,wBAAwB,EAC7B,MAAM,OAAO,CAAC;AACf,OAAO,EACN,6BAA6B,EAG7B,KAAK,oBAAoB,EACzB,MAAM,8BAA8B,CAAC;AAKtC,OAAO,EACN,cAAc,EACd,QAAQ,EACR,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;AAIxE,MAAM,MAAM,2BAA2B,GAAG,uBAAuB,CAChE,UAAU,EACV,6BAA6B,EAC7B,QAAQ,EACR,cAAc,CACd,CAAC;AAEF,MAAM,WAAW,iBAChB,SACC,oBAAoB,CACnB,6BAA6B,EAC7B,QAAQ,EACR,cAAc,EACd,SAAS,CACT,EACD,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,EAAE,UAAU,GAAG,UAAU,CAAC;IAC9D,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,2BAA2B,KAAK,IAAI,CAAC;CAC3D;AAED,eAAO,MAAM,YAAY,GAAI,0sBAuC1B,iBAAiB,sBA4EnB,CAAC"}
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ import { GidsTableRowWebUtils, isValidChildren, } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsTableEntry, } from '../GidsTableEntry/GidsTableEntry';
4
+ const { getGidsTableRowClassNames } = GidsTableRowWebUtils;
5
+ export const GidsTableRow = ({ rows = [], rowType = 'body', leadingActions, trailingActions, onRowAction, entryAlignment = 'center', colorSwatchLabelColor = 'default', colorSwatchLabelPosition = 'left', colorSwatchLabelTypography = 'label-medium', colorSwatchSize = 'sm', colorSwatchShape = 'oval', colorSwatchShadow = 'shadow-overlay', colorSwatchBorderRadius = 'none', colorSwatchApplyBorders = true, colorSwatchBorderWidth = 'thick', progressBarSize = 'sm', progressBarEndCap = true, avatarSize = 'sm', avatarGroupAppearance, avatarGroupLayout, statusTagAppearance = 'subtle', statusTagSize = 'sm', progressBarContainerMinWidth = 200, displayTagsOrientation = 'horizontal', statusTagsOrientation = 'horizontal', progressBarsOrientation = 'horizontal', colorSwatchesOrientation = 'horizontal', badgesOrientation = 'horizontal', textAlignment = 'center', labelTypography = 'label-medium', appearance = 'none', actionsBackgroundColor, actionsContentColor, backgroundColor, contentColor, children, className, ...restProps }) => {
6
+ const rowClassName = getGidsTableRowClassNames(className);
7
+ if (isValidChildren(children)) {
8
+ return (React.createElement("tr", { ...restProps, className: rowClassName }, children));
9
+ }
10
+ function onEntryActionBtnClick({ event, entryIndex, }) {
11
+ if (onRowAction) {
12
+ onRowAction({
13
+ ...event,
14
+ details: {
15
+ ...event.details,
16
+ entryIndex,
17
+ },
18
+ });
19
+ }
20
+ }
21
+ // Layout 2: Horizontal Layout (Standard single row mapping all cells)
22
+ return (React.createElement("tr", { ...restProps, className: rowClassName }, rows.map((row, indexJ) => (React.createElement(GidsTableEntry, { key: `row-h-${indexJ + 1}`, ...row, backgroundColor: backgroundColor, contentColor: contentColor, actionsBackgroundColor: actionsBackgroundColor, actionsContentColor: actionsContentColor, entryType: rowType, leadingActions: leadingActions, trailingActions: trailingActions, entryAlignment: entryAlignment, colorSwatchLabelColor: colorSwatchLabelColor, colorSwatchLabelPosition: colorSwatchLabelPosition, colorSwatchLabelTypography: colorSwatchLabelTypography, colorSwatchSize: colorSwatchSize, colorSwatchShape: colorSwatchShape, colorSwatchShadow: colorSwatchShadow, colorSwatchBorderRadius: colorSwatchBorderRadius, colorSwatchApplyBorders: colorSwatchApplyBorders, colorSwatchBorderWidth: colorSwatchBorderWidth, progressBarSize: progressBarSize, progressBarEndCap: progressBarEndCap, avatarSize: avatarSize, avatarGroupAppearance: avatarGroupAppearance, avatarGroupLayout: avatarGroupLayout, statusTagAppearance: statusTagAppearance, statusTagSize: statusTagSize, progressBarContainerMinWidth: progressBarContainerMinWidth, displayTagsOrientation: displayTagsOrientation, statusTagsOrientation: statusTagsOrientation, progressBarsOrientation: progressBarsOrientation, colorSwatchesOrientation: colorSwatchesOrientation, badgesOrientation: badgesOrientation, textAlignment: textAlignment, labelTypography: labelTypography, appearance: appearance, onEntryAction: (event) => onEntryActionBtnClick({ event, entryIndex: indexJ }) })))));
23
+ };
24
+ //# sourceMappingURL=GidsTableRow.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableRow.js","sourceRoot":"","sources":["../../../src/components/GidsTableRow/GidsTableRow.tsx"],"names":[],"mappings":"AAAA,OAAO,KAIN,MAAM,OAAO,CAAC;AACf,OAAO,EAEN,oBAAoB,EACpB,eAAe,GAEf,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACN,cAAc,GAEd,MAAM,kCAAkC,CAAC;AAO1C,MAAM,EAAE,yBAAyB,EAAE,GAAG,oBAAoB,CAAC;AAqB3D,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,EAC5B,IAAI,GAAG,EAAE,EACT,OAAO,GAAG,MAAM,EAChB,cAAc,EACd,eAAe,EACf,WAAW,EACX,cAAc,GAAG,QAAQ,EACzB,qBAAqB,GAAG,SAAS,EACjC,wBAAwB,GAAG,MAAM,EACjC,0BAA0B,GAAG,cAAc,EAC3C,eAAe,GAAG,IAAI,EACtB,gBAAgB,GAAG,MAAM,EACzB,iBAAiB,GAAG,gBAAgB,EACpC,uBAAuB,GAAG,MAAM,EAChC,uBAAuB,GAAG,IAAI,EAC9B,sBAAs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sBAAsB,EAC9C,mBAAmB,EAAE,mBAAmB,EACxC,SAAS,EAAE,OAAO,EAClB,cAAc,EAAE,cAAc,EAC9B,eAAe,EAAE,eAAe,EAChC,cAAc,EAAE,cAAc,EAC9B,qBAAqB,EAAE,qBAAqB,EAC5C,wBAAwB,EAAE,wBAAwB,EAClD,0BAA0B,EAAE,0BAA0B,EACtD,eAAe,EAAE,eAAe,EAChC,gBAAgB,EAAE,gBAAgB,EAClC,iBAAiB,EAAE,iBAAiB,EACpC,uBAAuB,EAAE,uBAAuB,EAChD,uBAAuB,EAAE,uBAAuB,EAChD,sBAAsB,EAAE,sBAAsB,EAC9C,eAAe,EAAE,eAAe,EAChC,iBAAiB,EAAE,iBAAiB,EACpC,UAAU,EAAE,UAAU,EACtB,qBAAqB,EAAE,qBAAqB,EAC5C,iBAAiB,EAAE,iBAAiB,EACpC,mBAAmB,EAAE,mBAAmB,EACxC,aAAa,EAAE,aAAa,EAC5B,4BAA4B,EAAE,4BAA4B,EAC1D,sBAAsB,EAAE,sBAAsB,EAC9C,qBAAqB,EAAE,qBAAqB,EAC5C,uBAAuB,EAAE,uBAAuB,EAChD,wBAAwB,EAAE,wBAAwB,EAClD,iBAAiB,EAAE,iBAAiB,EACpC,aAAa,EAAE,aAAa,EAC5B,eAAe,EAAE,eAAe,EAChC,UAAU,EAAE,UAAU,EACtB,aAAa,EAAE,CAAC,KAAoC,EAAE,EAAE,CACvD,qBAAqB,CAAC,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC,GAEpD,CACF,CAAC,CACE,CACL,CAAC;AACH,CAAC,CAAC"}
@@ -0,0 +1,15 @@
1
+ import React, { MouseEvent, type ComponentPropsWithoutRef, type ReactNode } from 'react';
2
+ import { GidsSearchBarWebProps, type GidsTableToolbarWebProps } from '@ganpatiinfo/gids-web-shared';
3
+ import { GidsTextField } from '../stencil-generated/gids-text-field.js';
4
+ type GidsTextFieldBaseProps = ComponentPropsWithoutRef<typeof GidsTextField>;
5
+ export type GidsTableToolbarTextFieldInputProps = GidsTextFieldBaseProps['inputProps'];
6
+ interface GidsTableToolbarBaseWebProps extends Omit<GidsTableToolbarWebProps<ReactNode, MouseEvent, ReactNode, Omit<ComponentPropsWithoutRef<'input'>, 'ref'>>, 'inputProps'>, Omit<GidsSearchBarWebProps<ReactNode, ComponentPropsWithoutRef<'input'>>, 'inputProps' | 'trailingIcon'>, Pick<GidsTextFieldBaseProps, 'onChange' | 'onInput' | 'onBlur' | 'onFocus'> {
7
+ }
8
+ export interface GidsTableToolbarProps extends GidsTableToolbarBaseWebProps {
9
+ onGidsSearchBarClear?: (event: CustomEvent<void>) => void;
10
+ inputProps?: GidsTableToolbarTextFieldInputProps;
11
+ className?: string;
12
+ }
13
+ export declare const GidsTableToolbar: ({ actionGroup, allFiltersTabVisible, moreFiltersTabVisible, clearAllFiltersVisible, clearAllFiltersButtonAppearance, primaryFilters, secondaryFilters, filterSize, filterAllIsDefaultSelected, dropdownDividerVisible, onToggleActionBarAllFilter, onToggleActionBarDropdownFilter, onToggleActionBarMoreFilter, onToggleActionBarNoneFilter, onDropdownSelectionActionBarFilterChange, onMoreSelectionActionBarFilterChange, onClearAllFiltersButton, actionBarDisabled, searchDisabled, allFiltersData, moreFiltersData, searchVisible, filtersVisible, childrenPosition, tabVisible, tabProps, borderSides, borderRadiusSides, leadingIcon, leadingLabel, trailingLabel, loading, readOnly, onGidsSearchBarClear, onChange, onInput, onFocus, onBlur, value, inputProps, className, tableToolbarAppearance, children, ...restProps }: GidsTableToolbarProps) => React.JSX.Element;
14
+ export {};
15
+ //# sourceMappingURL=GidsTableToolbar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GidsTableToolbar.d.ts","sourceRoot":"","sources":["../../../src/components/GidsTableToolbar/GidsTableToolbar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACb,UAAU,EACV,KAAK,wBAAwB,EAC7B,KAAK,SAAS,EACd,MAAM,OAAO,CAAC;AACf,OAAO,EAEN,qBAAqB,EACrB,KAAK,wBAAwB,EAC7B,MAAM,8BAA8B,CAAC;AAKtC,OAAO,EAAE,aAAa,EAAE,MAAM,yCAAyC,CAAC;AAIxE,KAAK,sBAAsB,GAAG,wBAAwB,CAAC,OAAO,aAAa,CAAC,CAAC;AAC7E,MAAM,MAAM,mCAAmC,GAC9C,sBAAsB,CAAC,YAAY,CAAC,CAAC;AAEtC,UAAU,4BACT,SACC,IAAI,CACH,wBAAwB,CACvB,SAAS,EACT,UAAU,EACV,SAAS,EACT,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAAC,EAAE,KAAK,CAAC,CAC9C,EACD,YAAY,CACZ,EACD,IAAI,CACH,qBAAqB,CAAC,SAAS,EAAE,wBAAwB,CAAC,OAAO,CAAC,CAAC,EACnE,YAAY,GAAG,cAAc,CAC7B,EACD,IAAI,CACH,sBAAsB,EACtB,UAAU,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,CAC7C;CAAG;AAEN,MAAM,WAAW,qBAAsB,SAAQ,4BAA4B;IAC1E,oBAAoB,CAAC,EAAE,CAAC,KAAK,EAAE,WAAW,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC;IAC1D,UAAU,CAAC,EAAE,mCAAmC,CAAC;IACjD,SAAS,CAAC,EAAE,MAAM,CAAC;CACnB;AAED,eAAO,MAAM,gBAAgB,GAAI,yyBA6C9B,qBAAqB,sBAgGvB,CAAC"}