pixelize-design-library 2.3.10 → 2.3.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Components/NoteTextArea/NoteTextAreaProps.d.ts +2 -2
- package/dist/Components/NoteTextArea/NoteTextAreaProps.d.ts.map +1 -1
- package/dist/Components/Timeline/Timeline.d.ts +1 -1
- package/dist/Components/Timeline/Timeline.d.ts.map +1 -1
- package/dist/Components/Timeline/Timeline.js +31 -13
- package/dist/Components/Timeline/TimelineProps.d.ts +2 -0
- package/dist/Components/Timeline/TimelineProps.d.ts.map +1 -1
- package/package.json +1 -1
- package/.claude/settings.local.json +0 -51
- package/coverage/clover.xml +0 -405
- package/coverage/coverage-final.json +0 -16
- package/coverage/coverage-summary.json +0 -50
- package/coverage/lcov-report/Button/Button.tsx.html +0 -244
- package/coverage/lcov-report/Button/index.html +0 -116
- package/coverage/lcov-report/Checkbox/Checkbox.tsx.html +0 -433
- package/coverage/lcov-report/Checkbox/index.html +0 -116
- package/coverage/lcov-report/Common/ErrorMessage.tsx.html +0 -148
- package/coverage/lcov-report/Common/FormLabel.tsx.html +0 -331
- package/coverage/lcov-report/Common/HelperText.tsx.html +0 -124
- package/coverage/lcov-report/Common/index.html +0 -146
- package/coverage/lcov-report/Components/Button/Button.tsx.html +0 -244
- package/coverage/lcov-report/Components/Button/index.html +0 -116
- package/coverage/lcov-report/Components/Checkbox/Checkbox.tsx.html +0 -433
- package/coverage/lcov-report/Components/Checkbox/index.html +0 -116
- package/coverage/lcov-report/Components/Common/ErrorMessage.tsx.html +0 -148
- package/coverage/lcov-report/Components/Common/FormLabel.tsx.html +0 -331
- package/coverage/lcov-report/Components/Common/HelperText.tsx.html +0 -124
- package/coverage/lcov-report/Components/Common/index.html +0 -146
- package/coverage/lcov-report/Components/CustomModulesTable/CustomModulesTable.tsx.html +0 -712
- package/coverage/lcov-report/Components/CustomModulesTable/DeleteModuleModal.tsx.html +0 -343
- package/coverage/lcov-report/Components/CustomModulesTable/EditModuleModal.tsx.html +0 -313
- package/coverage/lcov-report/Components/CustomModulesTable/index.html +0 -146
- package/coverage/lcov-report/Components/Divider/Divider.tsx.html +0 -133
- package/coverage/lcov-report/Components/Divider/index.html +0 -116
- package/coverage/lcov-report/Components/Dropdown/DropDown.tsx.html +0 -994
- package/coverage/lcov-report/Components/Dropdown/index.html +0 -116
- package/coverage/lcov-report/Components/EmptyState/EmptyState.tsx.html +0 -466
- package/coverage/lcov-report/Components/EmptyState/index.html +0 -116
- package/coverage/lcov-report/Components/Header/HeaderActions.tsx.html +0 -373
- package/coverage/lcov-report/Components/Header/index.html +0 -116
- package/coverage/lcov-report/Components/Input/TextInput.tsx.html +0 -487
- package/coverage/lcov-report/Components/Input/index.html +0 -116
- package/coverage/lcov-report/Components/Input/textInputIconSize.ts.html +0 -205
- package/coverage/lcov-report/Components/KanbanBoard/AccountCard.tsx.html +0 -547
- package/coverage/lcov-report/Components/KanbanBoard/AccountRow.tsx.html +0 -190
- package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/KanbanActions.tsx.html +0 -247
- package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/index.html +0 -116
- package/coverage/lcov-report/Components/KanbanBoard/KanbanBoard.tsx.html +0 -3598
- package/coverage/lcov-report/Components/KanbanBoard/MeasuredItem.tsx.html +0 -283
- package/coverage/lcov-report/Components/KanbanBoard/index.html +0 -161
- package/coverage/lcov-report/Components/OrganizationDetails/CreateOrgModal.tsx.html +0 -511
- package/coverage/lcov-report/Components/OrganizationDetails/DeleteOrgModal.tsx.html +0 -334
- package/coverage/lcov-report/Components/OrganizationDetails/OrganizationDetails.tsx.html +0 -1519
- package/coverage/lcov-report/Components/OrganizationDetails/index.html +0 -146
- package/coverage/lcov-report/Components/RolesPermission/DeleteRoleModal.tsx.html +0 -328
- package/coverage/lcov-report/Components/RolesPermission/RolesPermission.tsx.html +0 -1732
- package/coverage/lcov-report/Components/RolesPermission/index.html +0 -131
- package/coverage/lcov-report/Components/SearchSelect/SearchSelect.tsx.html +0 -2575
- package/coverage/lcov-report/Components/SearchSelect/SelectTruncatedLabel.tsx.html +0 -202
- package/coverage/lcov-report/Components/SearchSelect/index.html +0 -146
- package/coverage/lcov-report/Components/SearchSelect/searchSelectSize.ts.html +0 -496
- package/coverage/lcov-report/Components/Select/Select.tsx.html +0 -361
- package/coverage/lcov-report/Components/Select/index.html +0 -116
- package/coverage/lcov-report/Components/SideBar/components/OtherApps.tsx.html +0 -562
- package/coverage/lcov-report/Components/SideBar/components/OverflowTooltipText.tsx.html +0 -346
- package/coverage/lcov-report/Components/SideBar/components/index.html +0 -116
- package/coverage/lcov-report/Components/SignInActivityTable/SignInActivityTable.tsx.html +0 -490
- package/coverage/lcov-report/Components/SignInActivityTable/index.html +0 -116
- package/coverage/lcov-report/Components/Table/components/TableActions.tsx.html +0 -595
- package/coverage/lcov-report/Components/Table/components/TableBody.tsx.html +0 -2212
- package/coverage/lcov-report/Components/Table/components/TableGroupRow.tsx.html +0 -358
- package/coverage/lcov-report/Components/Table/components/TableLoading.tsx.html +0 -358
- package/coverage/lcov-report/Components/Table/components/index.html +0 -161
- package/coverage/lcov-report/Components/Table/settings/ManageColumns.tsx.html +0 -856
- package/coverage/lcov-report/Components/Table/settings/index.html +0 -116
- package/coverage/lcov-report/Components/Tag/Tag.styles.tsx.html +0 -331
- package/coverage/lcov-report/Components/Tag/Tag.tsx.html +0 -256
- package/coverage/lcov-report/Components/Tag/index.html +0 -131
- package/coverage/lcov-report/Components/ToolTip/ToolTip.tsx.html +0 -286
- package/coverage/lcov-report/Components/ToolTip/index.html +0 -116
- package/coverage/lcov-report/Components/UserDetails/AddUserModal.tsx.html +0 -709
- package/coverage/lcov-report/Components/UserDetails/ChangeRoleModal.tsx.html +0 -505
- package/coverage/lcov-report/Components/UserDetails/DeactivateConfirmModal.tsx.html +0 -379
- package/coverage/lcov-report/Components/UserDetails/UserDetails.tsx.html +0 -1900
- package/coverage/lcov-report/Components/UserDetails/index.html +0 -161
- package/coverage/lcov-report/EmptyState/EmptyState.tsx.html +0 -466
- package/coverage/lcov-report/EmptyState/index.html +0 -116
- package/coverage/lcov-report/Hooks/index.html +0 -116
- package/coverage/lcov-report/Hooks/usePreferences.ts.html +0 -421
- package/coverage/lcov-report/Input/TextInput.tsx.html +0 -487
- package/coverage/lcov-report/Input/index.html +0 -131
- package/coverage/lcov-report/Input/textInputIconSize.ts.html +0 -205
- package/coverage/lcov-report/KanbanBoard.tsx.html +0 -3481
- package/coverage/lcov-report/OrganizationDetails/CreateOrgModal.tsx.html +0 -511
- package/coverage/lcov-report/OrganizationDetails/DeleteOrgModal.tsx.html +0 -334
- package/coverage/lcov-report/OrganizationDetails/OrganizationDetails.tsx.html +0 -1519
- package/coverage/lcov-report/OrganizationDetails/index.html +0 -146
- package/coverage/lcov-report/RolesPermission/DeleteRoleModal.tsx.html +0 -328
- package/coverage/lcov-report/RolesPermission/RolesPermission.tsx.html +0 -1732
- package/coverage/lcov-report/RolesPermission/index.html +0 -116
- package/coverage/lcov-report/SearchSelect/SearchSelect.tsx.html +0 -2575
- package/coverage/lcov-report/SearchSelect/SelectTruncatedLabel.tsx.html +0 -202
- package/coverage/lcov-report/SearchSelect/index.html +0 -146
- package/coverage/lcov-report/SearchSelect/searchSelectSize.ts.html +0 -496
- package/coverage/lcov-report/Table/CompactSelect.tsx.html +0 -379
- package/coverage/lcov-report/Table/Components/ActiveFilters.tsx.html +0 -514
- package/coverage/lcov-report/Table/Components/HeaderActions.tsx.html +0 -373
- package/coverage/lcov-report/Table/Components/Pagination.tsx.html +0 -574
- package/coverage/lcov-report/Table/Components/TableActions.tsx.html +0 -574
- package/coverage/lcov-report/Table/Components/TableBody.tsx.html +0 -1027
- package/coverage/lcov-report/Table/Components/TableFilters.tsx.html +0 -397
- package/coverage/lcov-report/Table/Components/TableHeader.tsx.html +0 -1060
- package/coverage/lcov-report/Table/Components/TableLoading.tsx.html +0 -361
- package/coverage/lcov-report/Table/Components/TableSearch.tsx.html +0 -337
- package/coverage/lcov-report/Table/Components/index.html +0 -266
- package/coverage/lcov-report/Table/Components/useDebounce.ts.html +0 -178
- package/coverage/lcov-report/Table/Components/useTable.ts.html +0 -778
- package/coverage/lcov-report/Table/LeftFilterPane.tsx.html +0 -1810
- package/coverage/lcov-report/Table/SelectOperationControls.tsx.html +0 -178
- package/coverage/lcov-report/Table/Table.tsx.html +0 -1567
- package/coverage/lcov-report/Table/TableProps.tsx.html +0 -658
- package/coverage/lcov-report/Table/TableSettings/ManageColumns.tsx.html +0 -619
- package/coverage/lcov-report/Table/TableSettings/TableFilters.tsx.html +0 -229
- package/coverage/lcov-report/Table/TableSettings/TableSettings.tsx.html +0 -532
- package/coverage/lcov-report/Table/TableSettings/index.html +0 -146
- package/coverage/lcov-report/Table/TableToDo.tsx.html +0 -973
- package/coverage/lcov-report/Table/TextOperationControls.tsx.html +0 -271
- package/coverage/lcov-report/Table/filterTypes.ts.html +0 -97
- package/coverage/lcov-report/Table/index.html +0 -176
- package/coverage/lcov-report/Table/settings/ManageColumns.tsx.html +0 -856
- package/coverage/lcov-report/Table/settings/index.html +0 -116
- package/coverage/lcov-report/Tag/Tag.tsx.html +0 -256
- package/coverage/lcov-report/Tag/index.html +0 -116
- package/coverage/lcov-report/Theme/buildBrandTokens.ts.html +0 -175
- package/coverage/lcov-report/Theme/chartColorsFromTheme.ts.html +0 -214
- package/coverage/lcov-report/Theme/index.html +0 -131
- package/coverage/lcov-report/Theme/useCustomTheme.ts.html +0 -100
- package/coverage/lcov-report/ToolTip/ToolTip.tsx.html +0 -286
- package/coverage/lcov-report/ToolTip/index.html +0 -116
- package/coverage/lcov-report/UserDetails/AddUserModal.tsx.html +0 -709
- package/coverage/lcov-report/UserDetails/ChangeRoleModal.tsx.html +0 -505
- package/coverage/lcov-report/UserDetails/index.html +0 -116
- package/coverage/lcov-report/Utils/functions.ts.html +0 -106
- package/coverage/lcov-report/Utils/index.html +0 -116
- package/coverage/lcov-report/Utils/table.ts.html +0 -1189
- package/coverage/lcov-report/base.css +0 -224
- package/coverage/lcov-report/block-navigation.js +0 -87
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +0 -251
- package/coverage/lcov-report/prettify.css +0 -1
- package/coverage/lcov-report/prettify.js +0 -2
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +0 -210
- package/coverage/lcov.info +0 -981
- package/dist/Assets/defaultLogo.tsx +0 -30
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { LegacyRef } from "react";
|
|
2
2
|
export type NoteTextAreaProps = {
|
|
3
|
-
width
|
|
3
|
+
width?: number | string;
|
|
4
4
|
handleSubmit: (noteValue: string, titleValue: string, file: File[], resetState: void) => void;
|
|
5
5
|
value?: string;
|
|
6
6
|
title?: string;
|
|
7
7
|
file?: File[];
|
|
8
8
|
isEditable?: boolean;
|
|
9
9
|
handleCancel?: (isActive: boolean) => void;
|
|
10
|
-
saveButtonLoading
|
|
10
|
+
saveButtonLoading?: boolean;
|
|
11
11
|
maxFileSize?: number;
|
|
12
12
|
maxFilesSizeError?: string;
|
|
13
13
|
maxNoteWordCount?: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NoteTextAreaProps.d.ts","sourceRoot":"","sources":["../../../src/Components/NoteTextArea/NoteTextAreaProps.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC,MAAM,MAAM,iBAAiB,GAAG;IAC9B,KAAK,EAAE,MAAM,GAAG,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"NoteTextAreaProps.d.ts","sourceRoot":"","sources":["../../../src/Components/NoteTextArea/NoteTextAreaProps.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAElC,MAAM,MAAM,iBAAiB,GAAG;IAC9B,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,YAAY,EAAE,CACZ,SAAS,EAAE,MAAM,EACjB,UAAU,EAAE,MAAM,EAClB,IAAI,EAAE,IAAI,EAAE,EACZ,UAAU,EAAE,IAAI,KACb,IAAI,CAAC;IACV,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,IAAI,EAAE,CAAC;IACd,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,CAAC;IAC3C,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC,GAAG,CAAC,EAAE,SAAS,CAAC,gBAAgB,CAAC,CAAC;IAClC,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { TimelineProps } from "./TimelineProps";
|
|
2
|
-
declare const Timeline: ({ timelineEvents, onEventClick }: TimelineProps) => import("react/jsx-runtime").JSX.Element;
|
|
2
|
+
declare const Timeline: ({ timelineEvents, onEventClick, onAddNote, showAddNote }: TimelineProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export default Timeline;
|
|
4
4
|
//# sourceMappingURL=Timeline.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../../src/Components/Timeline/Timeline.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAAkB,aAAa,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"Timeline.d.ts","sourceRoot":"","sources":["../../../src/Components/Timeline/Timeline.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAAkB,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAMhE,QAAA,MAAM,QAAQ,GAAI,0DAAkE,aAAa,4CAijBhG,CAAC;AAEF,eAAe,QAAQ,CAAC"}
|
|
@@ -1,15 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
2
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
6
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
4
7
|
const react_1 = require("@chakra-ui/react");
|
|
5
8
|
const lucide_react_1 = require("lucide-react");
|
|
6
9
|
const useCustomTheme_1 = require("../../Theme/useCustomTheme");
|
|
7
10
|
const functions_1 = require("../../Utils/functions");
|
|
8
|
-
const
|
|
11
|
+
const NoteTextArea_1 = __importDefault(require("../NoteTextArea/NoteTextArea"));
|
|
12
|
+
const react_2 = require("react");
|
|
13
|
+
const Timeline = ({ timelineEvents, onEventClick, onAddNote, showAddNote = false }) => {
|
|
9
14
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
10
15
|
const theme = (0, useCustomTheme_1.useCustomTheme)();
|
|
11
16
|
const colors = (_a = theme.colors) !== null && _a !== void 0 ? _a : {};
|
|
12
17
|
const isMobile = (0, react_1.useBreakpointValue)({ base: true, md: false });
|
|
18
|
+
const [activeNoteEventIndex, setActiveNoteEventIndex] = (0, react_2.useState)(null);
|
|
13
19
|
const formatTimestamp = (timestamp, type) => {
|
|
14
20
|
if (typeof timestamp === "string" && !timestamp.match(/^\d+$/)) {
|
|
15
21
|
const date = new Date(timestamp);
|
|
@@ -139,18 +145,28 @@ const Timeline = ({ timelineEvents, onEventClick }) => {
|
|
|
139
145
|
// The colored event card (shared by both the desktop "tree" and mobile rail).
|
|
140
146
|
// `accent` decides which edge carries the colored bar (pointing toward the spine).
|
|
141
147
|
const EventCard = ({ event, index, accent, }) => {
|
|
142
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y;
|
|
148
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0;
|
|
143
149
|
const scale = getEventScale(event.title);
|
|
144
150
|
const changes = parseChanges(event.changes);
|
|
145
151
|
const clickable = typeof onEventClick === "function";
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
152
|
+
const isActiveNote = activeNoteEventIndex === index;
|
|
153
|
+
const [isHovered, setIsHovered] = (0, react_2.useState)(false);
|
|
154
|
+
return ((0, jsx_runtime_1.jsxs)(react_1.Box, { onMouseEnter: () => setIsHovered(true), onMouseLeave: () => setIsHovered(false), children: [(0, jsx_runtime_1.jsxs)(react_1.Box, { position: "relative", zIndex: 1, bg: (_a = colors.white) !== null && _a !== void 0 ? _a : "#fff", border: `0.063rem solid ${(_c = (_b = colors.boxborder) === null || _b === void 0 ? void 0 : _b[300]) !== null && _c !== void 0 ? _c : (_d = colors.gray) === null || _d === void 0 ? void 0 : _d[200]}`, borderInlineStartWidth: accent === "left" ? "0.1875rem" : undefined, borderInlineEndWidth: accent === "right" ? "0.1875rem" : undefined, borderInlineStartColor: accent === "left" ? scale === null || scale === void 0 ? void 0 : scale[400] : undefined, borderInlineEndColor: accent === "right" ? scale === null || scale === void 0 ? void 0 : scale[400] : undefined, borderRadius: "0.625rem", px: 3.5, py: 2.5, transition: "all 0.15s ease", cursor: clickable ? "pointer" : "default", onClick: clickable ? () => onEventClick(event, index) : undefined, _hover: {
|
|
155
|
+
borderColor: (_e = scale === null || scale === void 0 ? void 0 : scale[300]) !== null && _e !== void 0 ? _e : (_f = colors.gray) === null || _f === void 0 ? void 0 : _f[300],
|
|
156
|
+
boxShadow: (_g = theme.shadows) === null || _g === void 0 ? void 0 : _g.md,
|
|
157
|
+
transform: clickable ? "translateY(-1px)" : undefined,
|
|
158
|
+
}, children: [(0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", justify: "space-between", gap: 2, flexWrap: "wrap", children: [(0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", gap: 2, minW: 0, children: [(0, jsx_runtime_1.jsx)(react_1.Text, { fontSize: "0.8125rem", fontWeight: 600, color: (_j = (_h = colors.text) === null || _h === void 0 ? void 0 : _h[800]) !== null && _j !== void 0 ? _j : (_k = colors.gray) === null || _k === void 0 ? void 0 : _k[800], noOfLines: 1, children: event.action_from }), (0, jsx_runtime_1.jsx)(react_1.Box, { as: "span", fontSize: "0.6875rem", fontWeight: 600, lineHeight: "1", textTransform: "capitalize", color: (_l = scale === null || scale === void 0 ? void 0 : scale[700]) !== null && _l !== void 0 ? _l : scale === null || scale === void 0 ? void 0 : scale[600], bg: scale === null || scale === void 0 ? void 0 : scale[50], border: `0.063rem solid ${(_m = scale === null || scale === void 0 ? void 0 : scale[200]) !== null && _m !== void 0 ? _m : (_o = colors.gray) === null || _o === void 0 ? void 0 : _o[200]}`, borderRadius: "full", px: 2, py: 1, children: event.title })] }), (0, jsx_runtime_1.jsx)(react_1.Text, { fontSize: "0.6875rem", color: (_p = colors.gray) === null || _p === void 0 ? void 0 : _p[500], whiteSpace: "nowrap", children: formatTimestamp(event.created_at, "time") })] }), changes.length > 0 && ((0, jsx_runtime_1.jsx)(react_1.Flex, { direction: "column", gap: 1, mt: 2, children: changes.map((c, i) => {
|
|
159
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
160
|
+
return ((0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", gap: 1.5, fontSize: "0.6875rem", lineHeight: "1.4", flexWrap: "wrap", children: [(0, jsx_runtime_1.jsx)(react_1.Text, { fontWeight: 600, color: (_b = (_a = colors.text) === null || _a === void 0 ? void 0 : _a[700]) !== null && _b !== void 0 ? _b : (_c = colors.gray) === null || _c === void 0 ? void 0 : _c[700], children: (0, functions_1.toWords)(c.field) }), c.from !== null && c.from !== undefined && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(react_1.Box, { as: "span", color: (_d = colors.gray) === null || _d === void 0 ? void 0 : _d[500], bg: (_e = colors.gray) === null || _e === void 0 ? void 0 : _e[50], borderRadius: "0.25rem", px: 1.5, textDecoration: "line-through", maxW: "10rem", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: String(c.from) }), (0, jsx_runtime_1.jsx)(react_1.Box, { as: "span", color: (_f = colors.gray) === null || _f === void 0 ? void 0 : _f[400], display: "inline-flex", children: (0, jsx_runtime_1.jsx)(lucide_react_1.ArrowRight, { size: 11 }) })] })), (0, jsx_runtime_1.jsx)(react_1.Box, { as: "span", color: (_j = (_h = (_g = colors.semantic) === null || _g === void 0 ? void 0 : _g.success) === null || _h === void 0 ? void 0 : _h[700]) !== null && _j !== void 0 ? _j : (_k = colors.green) === null || _k === void 0 ? void 0 : _k[700], bg: (_o = (_m = (_l = colors.semantic) === null || _l === void 0 ? void 0 : _l.success) === null || _m === void 0 ? void 0 : _m[50]) !== null && _o !== void 0 ? _o : (_p = colors.green) === null || _p === void 0 ? void 0 : _p[50], borderRadius: "0.25rem", px: 1.5, maxW: "12rem", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", children: String(c.to) })] }, `${c.field}-${i}`));
|
|
161
|
+
}) })), (0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", justify: "space-between", gap: 2, mt: 2, children: [(0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", gap: 2, children: [(0, jsx_runtime_1.jsx)(react_1.Tooltip, { label: (0, functions_1.toWords)(event.action_by), placement: "top", hasArrow: true, children: (0, jsx_runtime_1.jsx)(react_1.Flex, { align: "center", justify: "center", boxSize: "1.25rem", minW: "1.25rem", borderRadius: "full", bg: (_s = (_r = (_q = colors.primary) === null || _q === void 0 ? void 0 : _q.opacity) === null || _r === void 0 ? void 0 : _r[16]) !== null && _s !== void 0 ? _s : (_t = colors.primary) === null || _t === void 0 ? void 0 : _t[50], color: (_u = colors.primary) === null || _u === void 0 ? void 0 : _u[600], fontSize: "0.5625rem", fontWeight: 700, children: initials((0, functions_1.toWords)(event.action_by)) }) }), (0, jsx_runtime_1.jsxs)(react_1.Text, { fontSize: "0.6875rem", color: (_v = colors.gray) === null || _v === void 0 ? void 0 : _v[500], children: ["by", " ", (0, jsx_runtime_1.jsx)(react_1.Box, { as: "span", color: (_x = (_w = colors.text) === null || _w === void 0 ? void 0 : _w[700]) !== null && _x !== void 0 ? _x : (_y = colors.gray) === null || _y === void 0 ? void 0 : _y[700], fontWeight: 500, children: (0, functions_1.toWords)(event.action_by) })] })] }), showAddNote && (isHovered || isActiveNote) && ((0, jsx_runtime_1.jsx)(react_1.Box, { as: "button", type: "button", onClick: (e) => {
|
|
162
|
+
e.stopPropagation();
|
|
163
|
+
setActiveNoteEventIndex(isActiveNote ? null : index);
|
|
164
|
+
}, px: 2, py: 1, borderRadius: "0.375rem", fontSize: "0.75rem", fontWeight: 600, color: (_z = colors.primary) === null || _z === void 0 ? void 0 : _z[700], bg: "transparent", cursor: "pointer", _hover: {
|
|
165
|
+
bg: (_0 = colors.primary) === null || _0 === void 0 ? void 0 : _0[50],
|
|
166
|
+
}, children: isActiveNote ? "Hide note" : "Add note" }))] })] }), isActiveNote && ((0, jsx_runtime_1.jsx)(react_1.Box, { mt: 2, children: (0, jsx_runtime_1.jsx)(NoteTextArea_1.default, { handleSubmit: (note, title, files) => {
|
|
167
|
+
onAddNote === null || onAddNote === void 0 ? void 0 : onAddNote(note, title, files, event, index);
|
|
168
|
+
setActiveNoteEventIndex(null);
|
|
169
|
+
}, handleCancel: () => setActiveNoteEventIndex(null) }) }))] }));
|
|
154
170
|
};
|
|
155
171
|
const NODE = "1.875rem"; // 30px node, centered on the spine
|
|
156
172
|
const NODE_RADIUS = "0.9375rem";
|
|
@@ -159,12 +175,13 @@ const Timeline = ({ timelineEvents, onEventClick }) => {
|
|
|
159
175
|
// Mobile: single left rail (alternating doesn't read well on narrow widths)
|
|
160
176
|
// -------------------------------------------------------------------------
|
|
161
177
|
if (isMobile) {
|
|
162
|
-
return ((0, jsx_runtime_1.jsx)(react_1.Box, { maxW: "100%", px: 2, py: 2, children: Object.keys(groupedEvents).map((date) => {
|
|
178
|
+
return ((0, jsx_runtime_1.jsx)(react_1.Box, { position: "relative", maxW: "100%", px: 2, py: 2, children: Object.keys(groupedEvents).map((date) => {
|
|
163
179
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
|
|
164
180
|
return ((0, jsx_runtime_1.jsxs)(react_1.Box, { mb: 2, children: [(0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "center", gap: 3, mb: 4, mt: 2, children: [(0, jsx_runtime_1.jsx)(react_1.Text, { fontSize: "0.75rem", fontWeight: 600, textTransform: "uppercase", letterSpacing: "0.02em", color: (_a = colors.gray) === null || _a === void 0 ? void 0 : _a[500], bg: (_b = colors.gray) === null || _b === void 0 ? void 0 : _b[50], border: `0.063rem solid ${(_d = (_c = colors.boxborder) === null || _c === void 0 ? void 0 : _c[200]) !== null && _d !== void 0 ? _d : (_e = colors.gray) === null || _e === void 0 ? void 0 : _e[200]}`, borderRadius: "full", px: 3, py: 1, whiteSpace: "nowrap", children: date }), (0, jsx_runtime_1.jsx)(react_1.Box, { flex: "1", h: "0.063rem", bg: (_g = (_f = colors.boxborder) === null || _f === void 0 ? void 0 : _f[200]) !== null && _g !== void 0 ? _g : (_h = colors.gray) === null || _h === void 0 ? void 0 : _h[200] })] }), (0, jsx_runtime_1.jsxs)(react_1.Box, { position: "relative", children: [(0, jsx_runtime_1.jsx)(react_1.Box, { position: "absolute", left: NODE_RADIUS, top: "0.5rem", bottom: "0.5rem", w: "0.1875rem", borderRadius: "full", bg: (_k = (_j = colors.gray) === null || _j === void 0 ? void 0 : _j[300]) !== null && _k !== void 0 ? _k : (_l = colors.boxborder) === null || _l === void 0 ? void 0 : _l[400], transform: "translateX(-50%)" }), groupedEvents[date].map((event, index) => {
|
|
165
181
|
var _a, _b, _c, _d;
|
|
166
182
|
const scale = getEventScale(event.title);
|
|
167
|
-
|
|
183
|
+
const globalIndex = timelineEvents.indexOf(event);
|
|
184
|
+
return ((0, jsx_runtime_1.jsxs)(react_1.Flex, { align: "flex-start", gap: 3, mb: index === groupedEvents[date].length - 1 ? 0 : 3, children: [(0, jsx_runtime_1.jsx)(react_1.Flex, { align: "center", justify: "center", boxSize: NODE, minW: NODE, borderRadius: "full", bg: scale === null || scale === void 0 ? void 0 : scale[50], color: scale === null || scale === void 0 ? void 0 : scale[600], border: `0.125rem solid ${(_a = colors.white) !== null && _a !== void 0 ? _a : "#fff"}`, boxShadow: `0 0 0 0.063rem ${(_b = scale === null || scale === void 0 ? void 0 : scale[200]) !== null && _b !== void 0 ? _b : (_c = colors.gray) === null || _c === void 0 ? void 0 : _c[200]}`, zIndex: 1, children: getIcon(event, 14) }), (0, jsx_runtime_1.jsx)(react_1.Box, { flex: "1", minW: 0, children: (0, jsx_runtime_1.jsx)(EventCard, { event: event, index: globalIndex, accent: "left" }) })] }, `${(_d = event.logs_id) !== null && _d !== void 0 ? _d : date}-${index}`));
|
|
168
185
|
})] })] }, date));
|
|
169
186
|
}) }));
|
|
170
187
|
}
|
|
@@ -177,9 +194,10 @@ const Timeline = ({ timelineEvents, onEventClick }) => {
|
|
|
177
194
|
var _a, _b, _c, _d, _e, _f;
|
|
178
195
|
const isLeft = index % 2 === 0;
|
|
179
196
|
const scale = getEventScale(event.title);
|
|
197
|
+
const globalIndex = timelineEvents.indexOf(event);
|
|
180
198
|
return ((0, jsx_runtime_1.jsxs)(react_1.Box, { position: "relative", mb: index === groupedEvents[date].length - 1 ? 0 : 5, minH: NODE, children: [(0, jsx_runtime_1.jsx)(react_1.Box, { position: "absolute", top: "1.375rem", h: "0.125rem", w: "0.8125rem", bg: (_a = scale === null || scale === void 0 ? void 0 : scale[300]) !== null && _a !== void 0 ? _a : (_b = colors.gray) === null || _b === void 0 ? void 0 : _b[300], left: isLeft
|
|
181
199
|
? `calc(50% - ${SPINE_GAP})`
|
|
182
|
-
: `calc(50% + ${NODE_RADIUS})`, zIndex: 0 }), (0, jsx_runtime_1.jsx)(react_1.Flex, { position: "absolute", left: "50%", top: "0.5rem", transform: "translateX(-50%)", align: "center", justify: "center", boxSize: NODE, borderRadius: "full", bg: scale === null || scale === void 0 ? void 0 : scale[50], color: scale === null || scale === void 0 ? void 0 : scale[600], border: `0.125rem solid ${(_c = colors.white) !== null && _c !== void 0 ? _c : "#fff"}`, boxShadow: `0 0 0 0.063rem ${(_d = scale === null || scale === void 0 ? void 0 : scale[200]) !== null && _d !== void 0 ? _d : (_e = colors.gray) === null || _e === void 0 ? void 0 : _e[200]}`, zIndex: 2, children: getIcon(event, 15) }), (0, jsx_runtime_1.jsx)(react_1.Box, { position: "relative", zIndex: 1, w: `calc(50% - ${SPINE_GAP})`, ml: isLeft ? 0 : `calc(50% + ${SPINE_GAP})`, children: (0, jsx_runtime_1.jsx)(EventCard, { event: event, index:
|
|
200
|
+
: `calc(50% + ${NODE_RADIUS})`, zIndex: 0 }), (0, jsx_runtime_1.jsx)(react_1.Flex, { position: "absolute", left: "50%", top: "0.5rem", transform: "translateX(-50%)", align: "center", justify: "center", boxSize: NODE, borderRadius: "full", bg: scale === null || scale === void 0 ? void 0 : scale[50], color: scale === null || scale === void 0 ? void 0 : scale[600], border: `0.125rem solid ${(_c = colors.white) !== null && _c !== void 0 ? _c : "#fff"}`, boxShadow: `0 0 0 0.063rem ${(_d = scale === null || scale === void 0 ? void 0 : scale[200]) !== null && _d !== void 0 ? _d : (_e = colors.gray) === null || _e === void 0 ? void 0 : _e[200]}`, zIndex: 2, children: getIcon(event, 15) }), (0, jsx_runtime_1.jsx)(react_1.Box, { position: "relative", zIndex: 1, w: `calc(50% - ${SPINE_GAP})`, ml: isLeft ? 0 : `calc(50% + ${SPINE_GAP})`, children: (0, jsx_runtime_1.jsx)(EventCard, { event: event, index: globalIndex, accent: isLeft ? "right" : "left" }) })] }, `${(_f = event.logs_id) !== null && _f !== void 0 ? _f : date}-${index}`));
|
|
183
201
|
})] }, date));
|
|
184
202
|
})] }));
|
|
185
203
|
};
|
|
@@ -2,6 +2,8 @@ export interface TimelineProps {
|
|
|
2
2
|
events?: TimelineEvent[];
|
|
3
3
|
timelineEvents: TimelineEvents[];
|
|
4
4
|
onEventClick?: (event: TimelineEvents, index: number) => void;
|
|
5
|
+
onAddNote?: (note: string, title: string, files: File[], event: TimelineEvents, index: number) => void;
|
|
6
|
+
showAddNote?: boolean;
|
|
5
7
|
}
|
|
6
8
|
export interface TimelineEvent {
|
|
7
9
|
title: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TimelineProps.d.ts","sourceRoot":"","sources":["../../../src/Components/Timeline/TimelineProps.tsx"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC5B,MAAM,CAAC,EAAE,aAAa,EAAE,CAAC;IACzB,cAAc,EAAE,cAAc,EAAE,CAAC;IACjC,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"TimelineProps.d.ts","sourceRoot":"","sources":["../../../src/Components/Timeline/TimelineProps.tsx"],"names":[],"mappings":"AAAA,MAAM,WAAW,aAAa;IAC5B,MAAM,CAAC,EAAE,aAAa,EAAE,CAAC;IACzB,cAAc,EAAE,cAAc,EAAE,CAAC;IACjC,YAAY,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAC9D,SAAS,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,EAAE,KAAK,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACvG,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB;AAED,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;CAClB"}
|
package/package.json
CHANGED
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"permissions": {
|
|
3
|
-
"allow": [
|
|
4
|
-
"Bash(git ls-tree *)",
|
|
5
|
-
"Bash(npx --no-install tsc --noEmit)",
|
|
6
|
-
"Bash(git fsck *)",
|
|
7
|
-
"Bash(npx tsc *)",
|
|
8
|
-
"Bash(curl -s http://localhost:5174/ -o /dev/null -w \"HTTP %{http_code}\\\\n\")",
|
|
9
|
-
"Bash(curl -s \"http://localhost:5174/src/Components/Table/Components/TableBody.tsx\" -o /dev/null -w \"transform TableBody: HTTP %{http_code}\\\\n\")",
|
|
10
|
-
"Read(//private/tmp/**)",
|
|
11
|
-
"Bash(npx jest *)",
|
|
12
|
-
"Bash(pkill -f \"vite\")",
|
|
13
|
-
"Bash(grep -rln -E \"import\\\\s+\\\\w+\\\\s*\\(,\\\\s*\\\\{[^}]*\\\\}\\)?\\\\s*from\\\\s+['\\\\\"]pixelize-design-library['\\\\\"]\" src)",
|
|
14
|
-
"Bash(ps -p 44521 60411 -o pid,command)",
|
|
15
|
-
"Bash(node -e \"const p=require\\('./package.json'\\); console.log\\(JSON.stringify\\(p.scripts,null,2\\)\\)\")",
|
|
16
|
-
"Bash(echo \"=== total errors: $\\(npx tsc --noEmit -p tsconfig.json 2>&1)",
|
|
17
|
-
"Bash(echo \"=== total: $\\(npx tsc --noEmit -p tsconfig.json 2>&1)",
|
|
18
|
-
"Bash(echo \"exit=$?\")",
|
|
19
|
-
"Read(//tmp/**)",
|
|
20
|
-
"Bash(git mv *)",
|
|
21
|
-
"Bash(git rm *)",
|
|
22
|
-
"Bash(node -e \"console.log\\(require\\('@emotion/react/package.json'\\).version\\)\")",
|
|
23
|
-
"Bash(node -e \"console.log\\('jodit-react', require\\('jodit-react/package.json'\\).version\\); try{console.log\\('jodit', require\\('jodit/package.json'\\).version\\)}catch\\(e\\){}\")",
|
|
24
|
-
"Bash(node -e \"console.log\\('playwright', require\\('playwright/package.json'\\).version\\)\")",
|
|
25
|
-
"Bash(node -e \"console.log\\('puppeteer', require\\('puppeteer/package.json'\\).version\\)\")",
|
|
26
|
-
"Bash(node -e \"console.log\\('ws', require\\('ws/package.json'\\).version\\)\")",
|
|
27
|
-
"Bash(node -e \"console.log\\('node', process.version\\)\")",
|
|
28
|
-
"Bash(grep -E \"\\\\.tsx?$\")",
|
|
29
|
-
"Bash(node -e \"console.log\\(require.resolve\\('@chakra-ui/styled-system'\\)\\)\")",
|
|
30
|
-
"Bash(node -e \"const p=require.resolve\\('@chakra-ui/react'\\);console.log\\(p\\)\")",
|
|
31
|
-
"Bash(sed -n '31,45p' src/Pages/table.tsx)",
|
|
32
|
-
"Bash(perl -0pi -e 's/\\\\n\\\\s*content: \\\\\\(\\\\\\) => <>Hello<\\\\/>,?//' src/Pages/table.tsx)",
|
|
33
|
-
"Bash(cd /Users/mahesh/Applications/Pixelize/CRM/Micro-Components *)",
|
|
34
|
-
"Bash(node -e \"console.log\\(require\\('./node_modules/pixelize-design-library/package.json'\\).version\\)\")",
|
|
35
|
-
"Bash(node -e \"console.log\\(JSON.stringify\\(require\\('./node_modules/pixelize-authenticator/package.json'\\).dependencies\\)\\)\")",
|
|
36
|
-
"Bash(node -e \"console.log\\(require\\('./node_modules/pixelize-authenticator/package.json'\\).version\\)\")",
|
|
37
|
-
"Bash(node -e \"console.log\\(require\\('./node_modules/pixelize-authenticator/node_modules/pixelize-design-library/package.json'\\).version\\)\")",
|
|
38
|
-
"Bash(echo \"tsc exit code: $?\")",
|
|
39
|
-
"Bash(./node_modules/.bin/tsc --noEmit --skipLibCheck)",
|
|
40
|
-
"Bash(./node_modules/.bin/tsc --noEmit)",
|
|
41
|
-
"Bash(echo \"tsc exit: $?\")",
|
|
42
|
-
"Bash(echo \"local tsc exit: $?\")",
|
|
43
|
-
"Bash(ls -la src/pages/Tasks/TaskComponent/)",
|
|
44
|
-
"Bash(wc -l src/pages/Tasks/TaskComponent/*.tsx)"
|
|
45
|
-
],
|
|
46
|
-
"additionalDirectories": [
|
|
47
|
-
"/private/tmp",
|
|
48
|
-
"/tmp"
|
|
49
|
-
]
|
|
50
|
-
}
|
|
51
|
-
}
|