@vuu-ui/vuu-utils 2.1.11 → 2.1.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/cjs/packages/vuu-utils/src/data-editing/edit-utils.js +1 -1
- package/cjs/packages/vuu-utils/src/data-editing/edit-utils.js.map +1 -1
- package/esm/packages/vuu-utils/src/data-editing/edit-utils.js +1 -1
- package/esm/packages/vuu-utils/src/data-editing/edit-utils.js.map +1 -1
- package/package.json +6 -6
|
@@ -9,7 +9,7 @@ const isInlineEditingSession = (editSessionMode) => editSessionMode.startsWith("
|
|
|
9
9
|
const timeFormatter = formatter.formatDate({ time: "hh:mm:ss" });
|
|
10
10
|
const getVuuEditMessage = (dataRow, column, originalValue) => {
|
|
11
11
|
const vuuMsg = dataRow.vuuMsg;
|
|
12
|
-
if (vuuMsg) {
|
|
12
|
+
if (typeof vuuMsg === "string" && vuuMsg !== "") {
|
|
13
13
|
const columnMessages = vuuMsg.split(",");
|
|
14
14
|
const msgForCol = columnMessages.find(
|
|
15
15
|
(msg) => msg.startsWith(`${column.name}:`)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"edit-utils.js","sources":["../../../../../../../packages/vuu-utils/src/data-editing/edit-utils.tsx"],"sourcesContent":["import { EditSessionMode, InlineEditSessionMode } from \"@vuu-ui/vuu-data-types\";\nimport { DataRow, RuntimeColumnDescriptor } from \"@vuu-ui/vuu-table-types\";\nimport { formatDate } from \"../date\";\n\nexport const isInlineEditingSession = (\n editSessionMode: EditSessionMode,\n): editSessionMode is InlineEditSessionMode =>\n editSessionMode.startsWith(\"inline\");\n\nconst timeFormatter = formatDate({ time: \"hh:mm:ss\" });\n\nexport const getVuuEditMessage = (\n dataRow: DataRow,\n column: RuntimeColumnDescriptor,\n originalValue: string,\n) => {\n const vuuMsg = dataRow.vuuMsg as string;\n if (vuuMsg) {\n const columnMessages = vuuMsg.split(\",\");\n const msgForCol = columnMessages.find((msg) =>\n msg.startsWith(`${column.name}:`),\n );\n if (msgForCol) {\n const [, value, updatedValue, ts] = msgForCol.split(\":\");\n const updateTime = timeFormatter(new Date(parseInt(ts as string)));\n return (\n <span>\n {\"Update rejected. Original value \"}\n <b>{originalValue}</b>\n {\" could not be updated to \"}\n <b>{value}</b>\n {\". It was updated to \"}\n <b>{updatedValue}</b>\n {\" at \"}\n {updateTime}\n {\".\"}\n </span>\n );\n }\n }\n};\n"],"names":["formatDate","jsx"],"mappings":";;;;;;;AAIO,MAAM,sBAAyB,GAAA,CACpC,eAEA,KAAA,eAAA,CAAgB,WAAW,QAAQ;AAErC,MAAM,aAAgB,GAAAA,oBAAA,CAAW,EAAE,IAAA,EAAM,YAAY,CAAA;AAE9C,MAAM,iBAAoB,GAAA,CAC/B,OACA,EAAA,MAAA,EACA,aACG,KAAA;AACH,EAAA,MAAM,SAAS,OAAQ,CAAA,MAAA;AACvB,EAAA,IAAI,
|
|
1
|
+
{"version":3,"file":"edit-utils.js","sources":["../../../../../../../packages/vuu-utils/src/data-editing/edit-utils.tsx"],"sourcesContent":["import { EditSessionMode, InlineEditSessionMode } from \"@vuu-ui/vuu-data-types\";\nimport { DataRow, RuntimeColumnDescriptor } from \"@vuu-ui/vuu-table-types\";\nimport { formatDate } from \"../date\";\n\nexport const isInlineEditingSession = (\n editSessionMode: EditSessionMode,\n): editSessionMode is InlineEditSessionMode =>\n editSessionMode.startsWith(\"inline\");\n\nconst timeFormatter = formatDate({ time: \"hh:mm:ss\" });\n\nexport const getVuuEditMessage = (\n dataRow: DataRow,\n column: RuntimeColumnDescriptor,\n originalValue: string,\n) => {\n const vuuMsg = dataRow.vuuMsg as string;\n if (typeof vuuMsg === \"string\" && vuuMsg !== \"\") {\n const columnMessages = vuuMsg.split(\",\");\n const msgForCol = columnMessages.find((msg) =>\n msg.startsWith(`${column.name}:`),\n );\n if (msgForCol) {\n const [, value, updatedValue, ts] = msgForCol.split(\":\");\n const updateTime = timeFormatter(new Date(parseInt(ts as string)));\n return (\n <span>\n {\"Update rejected. Original value \"}\n <b>{originalValue}</b>\n {\" could not be updated to \"}\n <b>{value}</b>\n {\". It was updated to \"}\n <b>{updatedValue}</b>\n {\" at \"}\n {updateTime}\n {\".\"}\n </span>\n );\n }\n }\n};\n"],"names":["formatDate","jsx"],"mappings":";;;;;;;AAIO,MAAM,sBAAyB,GAAA,CACpC,eAEA,KAAA,eAAA,CAAgB,WAAW,QAAQ;AAErC,MAAM,aAAgB,GAAAA,oBAAA,CAAW,EAAE,IAAA,EAAM,YAAY,CAAA;AAE9C,MAAM,iBAAoB,GAAA,CAC/B,OACA,EAAA,MAAA,EACA,aACG,KAAA;AACH,EAAA,MAAM,SAAS,OAAQ,CAAA,MAAA;AACvB,EAAA,IAAI,OAAO,MAAA,KAAW,QAAY,IAAA,MAAA,KAAW,EAAI,EAAA;AAC/C,IAAM,MAAA,cAAA,GAAiB,MAAO,CAAA,KAAA,CAAM,GAAG,CAAA;AACvC,IAAA,MAAM,YAAY,cAAe,CAAA,IAAA;AAAA,MAAK,CAAC,GACrC,KAAA,GAAA,CAAI,WAAW,CAAG,EAAA,MAAA,CAAO,IAAI,CAAG,CAAA,CAAA;AAAA,KAClC;AACA,IAAA,IAAI,SAAW,EAAA;AACb,MAAM,MAAA,GAAG,KAAO,EAAA,YAAA,EAAc,EAAE,CAAI,GAAA,SAAA,CAAU,MAAM,GAAG,CAAA;AACvD,MAAA,MAAM,aAAa,aAAc,CAAA,IAAI,KAAK,QAAS,CAAA,EAAY,CAAC,CAAC,CAAA;AACjE,MAAA,0EACG,MACE,EAAA,EAAA,QAAA,EAAA;AAAA,QAAA,kCAAA;AAAA,wBACDC,iDAAA,CAAC,OAAG,QAAc,EAAA,aAAA,EAAA,CAAA;AAAA,QACjB,2BAAA;AAAA,wBACDA,iDAAA,CAAC,OAAG,QAAM,EAAA,KAAA,EAAA,CAAA;AAAA,QACT,sBAAA;AAAA,wBACDA,iDAAA,CAAC,OAAG,QAAa,EAAA,YAAA,EAAA,CAAA;AAAA,QAChB,MAAA;AAAA,QACA,UAAA;AAAA,QACA;AAAA,OACH,EAAA,CAAA;AAAA;AAEJ;AAEJ;;;;;"}
|
|
@@ -7,7 +7,7 @@ const isInlineEditingSession = (editSessionMode) => editSessionMode.startsWith("
|
|
|
7
7
|
const timeFormatter = formatDate({ time: "hh:mm:ss" });
|
|
8
8
|
const getVuuEditMessage = (dataRow, column, originalValue) => {
|
|
9
9
|
const vuuMsg = dataRow.vuuMsg;
|
|
10
|
-
if (vuuMsg) {
|
|
10
|
+
if (typeof vuuMsg === "string" && vuuMsg !== "") {
|
|
11
11
|
const columnMessages = vuuMsg.split(",");
|
|
12
12
|
const msgForCol = columnMessages.find(
|
|
13
13
|
(msg) => msg.startsWith(`${column.name}:`)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"edit-utils.js","sources":["../../../../../../../packages/vuu-utils/src/data-editing/edit-utils.tsx"],"sourcesContent":["import { EditSessionMode, InlineEditSessionMode } from \"@vuu-ui/vuu-data-types\";\nimport { DataRow, RuntimeColumnDescriptor } from \"@vuu-ui/vuu-table-types\";\nimport { formatDate } from \"../date\";\n\nexport const isInlineEditingSession = (\n editSessionMode: EditSessionMode,\n): editSessionMode is InlineEditSessionMode =>\n editSessionMode.startsWith(\"inline\");\n\nconst timeFormatter = formatDate({ time: \"hh:mm:ss\" });\n\nexport const getVuuEditMessage = (\n dataRow: DataRow,\n column: RuntimeColumnDescriptor,\n originalValue: string,\n) => {\n const vuuMsg = dataRow.vuuMsg as string;\n if (vuuMsg) {\n const columnMessages = vuuMsg.split(\",\");\n const msgForCol = columnMessages.find((msg) =>\n msg.startsWith(`${column.name}:`),\n );\n if (msgForCol) {\n const [, value, updatedValue, ts] = msgForCol.split(\":\");\n const updateTime = timeFormatter(new Date(parseInt(ts as string)));\n return (\n <span>\n {\"Update rejected. Original value \"}\n <b>{originalValue}</b>\n {\" could not be updated to \"}\n <b>{value}</b>\n {\". It was updated to \"}\n <b>{updatedValue}</b>\n {\" at \"}\n {updateTime}\n {\".\"}\n </span>\n );\n }\n }\n};\n"],"names":[],"mappings":";;;;;AAIO,MAAM,sBAAyB,GAAA,CACpC,eAEA,KAAA,eAAA,CAAgB,WAAW,QAAQ;AAErC,MAAM,aAAgB,GAAA,UAAA,CAAW,EAAE,IAAA,EAAM,YAAY,CAAA;AAE9C,MAAM,iBAAoB,GAAA,CAC/B,OACA,EAAA,MAAA,EACA,aACG,KAAA;AACH,EAAA,MAAM,SAAS,OAAQ,CAAA,MAAA;AACvB,EAAA,IAAI,
|
|
1
|
+
{"version":3,"file":"edit-utils.js","sources":["../../../../../../../packages/vuu-utils/src/data-editing/edit-utils.tsx"],"sourcesContent":["import { EditSessionMode, InlineEditSessionMode } from \"@vuu-ui/vuu-data-types\";\nimport { DataRow, RuntimeColumnDescriptor } from \"@vuu-ui/vuu-table-types\";\nimport { formatDate } from \"../date\";\n\nexport const isInlineEditingSession = (\n editSessionMode: EditSessionMode,\n): editSessionMode is InlineEditSessionMode =>\n editSessionMode.startsWith(\"inline\");\n\nconst timeFormatter = formatDate({ time: \"hh:mm:ss\" });\n\nexport const getVuuEditMessage = (\n dataRow: DataRow,\n column: RuntimeColumnDescriptor,\n originalValue: string,\n) => {\n const vuuMsg = dataRow.vuuMsg as string;\n if (typeof vuuMsg === \"string\" && vuuMsg !== \"\") {\n const columnMessages = vuuMsg.split(\",\");\n const msgForCol = columnMessages.find((msg) =>\n msg.startsWith(`${column.name}:`),\n );\n if (msgForCol) {\n const [, value, updatedValue, ts] = msgForCol.split(\":\");\n const updateTime = timeFormatter(new Date(parseInt(ts as string)));\n return (\n <span>\n {\"Update rejected. Original value \"}\n <b>{originalValue}</b>\n {\" could not be updated to \"}\n <b>{value}</b>\n {\". It was updated to \"}\n <b>{updatedValue}</b>\n {\" at \"}\n {updateTime}\n {\".\"}\n </span>\n );\n }\n }\n};\n"],"names":[],"mappings":";;;;;AAIO,MAAM,sBAAyB,GAAA,CACpC,eAEA,KAAA,eAAA,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
|
5
5
|
"types": "types/index.d.ts",
|
|
@@ -7,14 +7,14 @@
|
|
|
7
7
|
"@salt-ds/core": "1.54.1"
|
|
8
8
|
},
|
|
9
9
|
"devDependencies": {
|
|
10
|
-
"@vuu-ui/vuu-data-types": "2.1.
|
|
11
|
-
"@vuu-ui/vuu-table-types": "2.1.
|
|
12
|
-
"@vuu-ui/vuu-filter-types": "2.1.
|
|
13
|
-
"@vuu-ui/vuu-protocol-types": "2.1.
|
|
10
|
+
"@vuu-ui/vuu-data-types": "2.1.12",
|
|
11
|
+
"@vuu-ui/vuu-table-types": "2.1.12",
|
|
12
|
+
"@vuu-ui/vuu-filter-types": "2.1.12",
|
|
13
|
+
"@vuu-ui/vuu-protocol-types": "2.1.12"
|
|
14
14
|
},
|
|
15
15
|
"peerDependencies": {
|
|
16
16
|
"@internationalized/date": "^3.0.0",
|
|
17
|
-
"@vuu-ui/vuu-filter-parser": "2.1.
|
|
17
|
+
"@vuu-ui/vuu-filter-parser": "2.1.12",
|
|
18
18
|
"clsx": "^2.0.0",
|
|
19
19
|
"react": "^19.2.3",
|
|
20
20
|
"react-dom": "^19.2.3"
|