@ai-matrx/records-ui 0.115.90 → 0.115.92
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/CHANGELOG.md +28 -1
- package/dist/helpers.d.cts +4 -0
- package/dist/helpers.d.ts +4 -0
- package/dist/index.cjs +2488 -1395
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +192 -4
- package/dist/index.d.ts +192 -4
- package/dist/index.js +2445 -1352
- package/dist/index.js.map +1 -1
- package/dist/pickers.cjs +5 -6
- package/dist/pickers.cjs.map +1 -1
- package/dist/pickers.js +5 -6
- package/dist/pickers.js.map +1 -1
- package/package.json +5 -5
package/dist/pickers.js
CHANGED
|
@@ -4566,13 +4566,10 @@ function formulaSourceArchived(field, document2) {
|
|
|
4566
4566
|
|
|
4567
4567
|
// src/values.tsx
|
|
4568
4568
|
import { autonumberPrefixOf as autonumberPrefixOf2, autonumberWords as autonumberWords2, isButtonField as isButtonField2, newerKindWords, sourceArchivedOf as sourceArchivedOf2 } from "@ai-matrx/records";
|
|
4569
|
+
import { isUuidShape as isUuidShape4 } from "@ai-matrx/kit/uuid";
|
|
4569
4570
|
|
|
4570
4571
|
// src/userIds.ts
|
|
4571
|
-
var UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
|
|
4572
4572
|
var PERSON_NOT_IN_ORGANIZATION = "A person no longer in this organization";
|
|
4573
|
-
function isUserId(value) {
|
|
4574
|
-
return typeof value === "string" && UUID.test(value);
|
|
4575
|
-
}
|
|
4576
4573
|
|
|
4577
4574
|
// src/personNames.ts
|
|
4578
4575
|
import { useSyncExternalStore } from "react";
|
|
@@ -4807,6 +4804,7 @@ function PersonPicker({ field, value, onChange, disabled, id, className, autoOpe
|
|
|
4807
4804
|
}
|
|
4808
4805
|
|
|
4809
4806
|
// src/memberNames.ts
|
|
4807
|
+
import { isUuidShape as isUuidShape3 } from "@ai-matrx/kit/uuid";
|
|
4810
4808
|
function memberWords(member) {
|
|
4811
4809
|
const name = member?.name?.trim();
|
|
4812
4810
|
if (name) return name;
|
|
@@ -5017,7 +5015,7 @@ function LivePersonChip({ id, name }) {
|
|
|
5017
5015
|
var NEVER_AN_ID_KINDS = /* @__PURE__ */ new Set(["member", "person", "number", "currency", "percent", "date", "datetime", "checkbox", "boolean"]);
|
|
5018
5016
|
function personWordsOf(kind, value) {
|
|
5019
5017
|
const items = Array.isArray(value) ? value : [value];
|
|
5020
|
-
const ids = items.filter(
|
|
5018
|
+
const ids = items.filter(isUuidShape4);
|
|
5021
5019
|
if (ids.length === 0) return null;
|
|
5022
5020
|
const wordsColumn = !NEVER_AN_ID_KINDS.has(kind);
|
|
5023
5021
|
const named = ids.map((id) => knownPerson(id));
|
|
@@ -5725,10 +5723,11 @@ import { tableShapeChanged as tableShapeChanged2, useRecordsClient as useRecords
|
|
|
5725
5723
|
import { Button as Button13, Select as Select4, SelectContent as SelectContent4, SelectItem as SelectItem4, SelectTrigger as SelectTrigger4, SelectValue as SelectValue4 } from "@ai-matrx/design-system";
|
|
5726
5724
|
|
|
5727
5725
|
// src/personRetype.ts
|
|
5726
|
+
import { isUuidShape as isUuidShape5 } from "@ai-matrx/kit/uuid";
|
|
5728
5727
|
var PAGE = 500;
|
|
5729
5728
|
var CEILING = 2e4;
|
|
5730
5729
|
function idsIn(value) {
|
|
5731
|
-
return (Array.isArray(value) ? value : [value]).filter(
|
|
5730
|
+
return (Array.isArray(value) ? value : [value]).filter(isUuidShape5);
|
|
5732
5731
|
}
|
|
5733
5732
|
async function readPersonColumn(client, tableId, key) {
|
|
5734
5733
|
const out = [];
|