@stndrds/schema 0.1.0-alpha.21 → 0.1.0-alpha.23

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 (63) hide show
  1. package/dist/chunk-7GLSGSUP.mjs +9456 -0
  2. package/dist/chunk-AZTBTKHP.mjs +9861 -0
  3. package/dist/chunk-B74KNXDP.mjs +9457 -0
  4. package/dist/chunk-CVFKFFCX.mjs +9912 -0
  5. package/dist/chunk-DXVIUNQT.mjs +9881 -0
  6. package/dist/chunk-EJB2V42F.mjs +9778 -0
  7. package/dist/chunk-GP2BONBI.mjs +9493 -0
  8. package/dist/chunk-H2KOC7F5.mjs +9549 -0
  9. package/dist/chunk-HXLOIN36.mjs +9893 -0
  10. package/dist/chunk-HYW67ZP6.mjs +9500 -0
  11. package/dist/chunk-IKUIWNHZ.mjs +9460 -0
  12. package/dist/chunk-JAWKNHY6.mjs +9553 -0
  13. package/dist/chunk-KT4UPBZR.mjs +9892 -0
  14. package/dist/chunk-NBCCRCJB.mjs +9547 -0
  15. package/dist/chunk-NN7Y3B3A.mjs +9859 -0
  16. package/dist/chunk-SBEZDUNH.mjs +9549 -0
  17. package/dist/chunk-TTZ3TWYP.mjs +9583 -0
  18. package/dist/chunk-UTZTDUIK.mjs +9818 -0
  19. package/dist/index.d.mts +172 -17
  20. package/dist/index.d.ts +172 -17
  21. package/dist/index.js +977 -512
  22. package/dist/index.mjs +71 -23
  23. package/dist/runtime-BFOdkIqK.d.mts +7644 -0
  24. package/dist/runtime-BFOdkIqK.d.ts +7644 -0
  25. package/dist/runtime-BI_wXiVl.d.mts +8043 -0
  26. package/dist/runtime-BI_wXiVl.d.ts +8043 -0
  27. package/dist/runtime-BZZRu7A1.d.mts +7083 -0
  28. package/dist/runtime-BZZRu7A1.d.ts +7083 -0
  29. package/dist/runtime-BlcFbbeG.d.mts +8035 -0
  30. package/dist/runtime-BlcFbbeG.d.ts +8035 -0
  31. package/dist/runtime-BleOubTG.d.mts +7236 -0
  32. package/dist/runtime-BleOubTG.d.ts +7236 -0
  33. package/dist/runtime-CC4VRtUK.d.mts +7422 -0
  34. package/dist/runtime-CC4VRtUK.d.ts +7422 -0
  35. package/dist/runtime-CKLGO3Jk.d.mts +7632 -0
  36. package/dist/runtime-CKLGO3Jk.d.ts +7632 -0
  37. package/dist/runtime-CjhnsVyg.d.mts +7668 -0
  38. package/dist/runtime-CjhnsVyg.d.ts +7668 -0
  39. package/dist/runtime-CmYcicVr.d.mts +7083 -0
  40. package/dist/runtime-CmYcicVr.d.ts +7083 -0
  41. package/dist/runtime-D01tNFxT.d.mts +7418 -0
  42. package/dist/runtime-D01tNFxT.d.ts +7418 -0
  43. package/dist/runtime-DWCd3xCL.d.mts +7632 -0
  44. package/dist/runtime-DWCd3xCL.d.ts +7632 -0
  45. package/dist/runtime-DbryZGqb.d.mts +8037 -0
  46. package/dist/runtime-DbryZGqb.d.ts +8037 -0
  47. package/dist/runtime-DdkNFkKd.d.mts +7185 -0
  48. package/dist/runtime-DdkNFkKd.d.ts +7185 -0
  49. package/dist/runtime-DnnW72ZF.d.mts +7451 -0
  50. package/dist/runtime-DnnW72ZF.d.ts +7451 -0
  51. package/dist/runtime-DrrCWvBr.d.mts +7451 -0
  52. package/dist/runtime-DrrCWvBr.d.ts +7451 -0
  53. package/dist/runtime-UYkiPdud.d.mts +8047 -0
  54. package/dist/runtime-UYkiPdud.d.ts +8047 -0
  55. package/dist/runtime-g7XZnqGw.d.mts +7452 -0
  56. package/dist/runtime-g7XZnqGw.d.ts +7452 -0
  57. package/dist/runtime-jnV5WCS6.d.mts +8047 -0
  58. package/dist/runtime-jnV5WCS6.d.ts +8047 -0
  59. package/dist/runtime.d.mts +1 -1
  60. package/dist/runtime.d.ts +1 -1
  61. package/dist/runtime.js +855 -466
  62. package/dist/runtime.mjs +29 -3
  63. package/package.json +2 -2
package/dist/index.d.mts CHANGED
@@ -1,5 +1,5 @@
1
- import { A as Attribute, S as SystemResource, a as SystemAction, O as ObjectAction, T as TextAttribute, b as TextAreaAttribute, N as NumberAttribute, C as CheckboxAttribute, D as DateAttribute, P as PhoneAttribute, c as CurrencyAttribute, d as Option, e as StatusAttribute, f as SelectAttribute, M as MultiselectAttribute, L as LocationAttribute, g as TimestampAttribute, F as FileAttribute, U as UserAttribute, h as SingleRelationAttribute, i as MultiRelationAttribute, R as RelationTarget, j as RatingAttribute, k as FormulaAttribute, l as FormulaReturnType, m as RollupAttribute, n as RollupFunction, o as FlowDefinition, p as FlowPage, q as FlowRow, I as InferAttributeValue, r as ObjectDefinition, s as Field, t as AttributeGroupField, G as Group, V as ViewDefinition, u as Tab } from './runtime-0gaIqXql.mjs';
2
- export { bx as ActivityTab, aV as AddAttribute, dJ as AddAttributeInput, as as AdvancedFilterState, bn as AssignRoleInput, dh as AttributeChange, x as AttributeGroup, aU as AttributeMap, aQ as AttributeSchema, v as AttributeType, dr as AttributesRepository, a0 as AuditAction, a1 as AuditActorType, a2 as AuditChange, a5 as AuditListOptions, a3 as AuditLogEntry, dx as AuditRepository, $ as AuditResourceType, dA as AuditService, a6 as AuditServiceOptions, B as BaseAttribute, ae as CheckboxFilterOperator, bb as CompletionStatus, a4 as CreateAuditLogInput, dI as CreateCustomObjectInput, ex as CreateDBAttribute, eL as CreateDBFlow, et as CreateDBObject, eH as CreateDBView, aa as CreateFile, dD as CreateFlowInput, eA as CreateObjectRecord, bm as CreatePermissionInput, bk as CreateRoleInput, br as CreateUserProfile, e6 as CreateViewInput, J as Currency, al as CurrencyFilterValue, aZ as CustomAttributeValue, bw as CustomTab, ew as DBAttribute, eK as DBFlow, es as DBObject, eG as DBView, en as DEFAULT_LABEL_FALLBACK, cy as DatabaseAdapter, af as DateFilterOperator, z as DateFormat, E as DateValue, X as DocumentFace, W as DocumentType, Y as DocumentTypeConfig, bh as EffectivePermissions, b8 as ExtractAttributes, b2 as ExtractRecord, b4 as ExtractRecordInput, b5 as ExtractRecordInputStrict, b3 as ExtractRecordStrict, b6 as ExtractRecordUpdate, b7 as ExtractRecordUpdateStrict, cz as FetchResult, a9 as File, e9 as FileContent, eF as FileListOptions, dC as FileService, dB as FileServiceOptions, Z as FileVerificationConfig, a8 as FileVisibility, dt as FilesRepository, ap as FilterCombinator, ar as FilterGroup, aj as FilterOperator, ao as FilterRule, aq as FilterState, an as FilterValue, aF as FlowRelation, aE as FlowRowField, dF as FlowService, aD as FlowSlot, aG as FlowStatus, dw as FlowsRepository, bu as FormTab, cA as FormattedRecord, c$ as FormulaResult, el as FullSyncOptions, ek as FullSyncResult, aO as GeocodingAdapter, aL as GeocodingAutocompleteParams, aN as GeocodingParams, dG as GeocodingService, aK as GeocodingSuggestion, dV as GetRelationOptionsParams, eD as GlobalSearchOptions, eE as GlobalSearchResultItem, dH as GlobalSearchService, cB as GroupedFetchResult, di as HookContext, dj as HookDefinition, dk as HookHandler, dn as HookRegistry, dl as HookType, aW as InferRecord, aR as InferRecordFromSchema, aX as InferRecordInput, aY as InferRecordUpdate, aS as InferRecordWithRequirements, cC as InsertOptions, d3 as InvalidPathError, eB as ListOptions, K as Location, Q as LocationGranularity, d4 as MaxDepthExceededError, ah as MultiselectFilterOperator, aB as NO_VALUE_OPERATORS, aA as NoValueOperator, aP as NoopGeocodingAdapter, dm as NoopHookRegistry, ad as NumberFilterOperator, y as NumberUnit, az as OPERATORS_BY_TYPE, ba as ObjectAttribute, bi as ObjectPermissions, bc as ObjectRecord, du as ObjectRecordsRepository, dM as ObjectSchemaService, dL as ObjectSchemaServiceOptions, dq as ObjectsRepository, eN as OperationResult, d8 as PathCardinality, d9 as PathSegment, da as PathSegmentType, bf as Permission, bd as PermissionScope, dO as PermissionService, dN as PermissionServiceOptions, dy as PermissionsRepository, H as Phone, am as PhoneFilterValue, cO as QueryBuilder, cD as QueryBuilderState, cK as QueryMultipleResultsError, cL as QueryNoResultError, ay as QueryState, a$ as RecordMetadata, dQ as RecordService, dP as RecordServiceOptions, cE as RegistryMap, cF as RegistryObjectNames, _ as RelationAttribute, ai as RelationFilterOperator, dT as RelationOption, dU as RelationOptionsResponse, dY as RelationResolverService, dW as RelationService, dS as RelationValidationError, dR as RelationValidationResult, ak as RelativeDateValue, dX as ResolvedRelations, aM as ReverseGeocodingParams, be as Role, dZ as RollupResult, e0 as RollupScheduler, d$ as RollupSchedulerOptions, d_ as RollupService, cM as SHORTCUT_TO_FILTER_OPERATOR, b1 as SYSTEM_FIELD_NAMES, db as SchemaResolver, eC as SearchOptions, ag as SelectFilterOperator, cG as ShortcutOperator, ec as SignedUrlOptions, aw as SortDirection, ax as SortRule, w as StatusGroup, ed as StorageAdapter, a7 as StorageProvider, ea as StorageUploadInput, eb as StorageUploadResult, eg as SyncOptions, ef as SyncResult, b0 as SystemFields, bj as SystemPermissions, bt as TabType, bv as TableTab, bD as TenantId, ac as TextFilterOperator, b9 as Timestamps, df as TraversalOptions, dg as TraversalResult, aT as TypedAttribute, ey as UpdateDBAttribute, eM as UpdateDBFlow, eu as UpdateDBObject, eI as UpdateDBView, ab as UpdateFile, dE as UpdateFlowInput, dK as UpdateObjectInput, bl as UpdateRoleInput, bs as UpdateUserProfile, e7 as UpdateViewInput, ee as UploadFileInput, ez as UpsertDBAttribute, ev as UpsertDBObject, eJ as UpsertDBView, bq as UserProfile, e2 as UserProfileService, e1 as UserProfileServiceOptions, ds as UserProfilesRepository, bo as UserRole, bg as UserRoleAssignment, e5 as UserService, bp as UserStatus, e4 as UserValidationError, e3 as UserValidationResult, bC as Uuid, co as ValidationResult, e8 as ViewService, eP as ViewSyncOptions, eO as ViewSyncResult, dv as ViewsRepository, a_ as WithCustomAttributes, b_ as attributeConfigSchemas, dz as buildAuditChanges, bL as checkboxConfigSchema, cx as computeRecordStatus, cm as createAttributeValidator, c5 as createCheckboxValidator, c8 as createCurrencyValidator, c6 as createDateValidator, cH as createDefaultState, cs as createDraftValidator, ce as createFileValidator, ck as createFormulaValidator, cc as createLocationValidator, dp as createMockAdapter, ch as createMultiRelationValidator, cb as createMultiselectValidator, c4 as createNumberValidator, cn as createObjectValidator, c7 as createPhoneValidator, cN as createQueryBuilder, cj as createRatingValidator, ci as createRelationValidator, cl as createRollupValidator, ca as createSelectValidator, cg as createSingleRelationValidator, c9 as createStatusValidator, c3 as createTextValidator, cd as createTimestampValidator, cf as createUserValidator, bO as currencyConfigSchema, bM as dateConfigSchema, er as enrichValuesWithSelectLabels, cP as evaluateFormula, cQ as evaluateFormulaAttribute, cR as evaluateFormulaAttributeWithRelations, cS as evaluateFormulaWithRelations, cT as evaluateFormulaWithResult, eq as extractAttributeNames, cU as extractFormulaVariables, cV as extractRelationNames, cW as extractRelationReferences, bU as fileConfigSchema, cX as flattenRelationsForEval, cY as formatFormulaResult, cI as formatRecord, cJ as formatRecords, bY as formulaConfigSchema, bE as generateId, bF as generatePrefixedId, b$ as getAttributeConfigSchema, cv as getMissingRequiredAttributes, d0 as getPathDepth, d1 as getRelationPath, ej as getSyncPreview, d2 as getTargetAttributeName, eS as getViewSyncPreview, cZ as hasRelationReferences, bB as isActivityTab, at as isAdvancedFilterState, bA as isCustomTab, aH as isFlowDefinition, aI as isFlowPublished, by as isFormTab, ep as isLabelExpression, aC as isNoValueOperator, cw as isRecordComplete, aJ as isSystemFlow, bz as isTableTab, bQ as locationConfigSchema, bT as multiselectConfigSchema, bK as numberConfigSchema, c1 as parseAttributeConfig, d5 as parsePath, d6 as pathHasManyCardinality, bN as phoneConfigSchema, bX as ratingConfigSchema, bG as registry, bW as relationConfigSchema, eo as renderLabelExpression, dc as resolveMultiplePaths, dd as resolveSingleValue, bZ as rollupConfigSchema, c2 as safeParseAttributeConfig, bS as selectConfigSchema, bP as statusConfigSchema, em as syncAll, eh as syncNativeObjects, eQ as syncNativeViews, bI as textConfigSchema, bJ as textareaConfigSchema, bR as timestampConfigSchema, au as toAdvancedFilterState, av as toSimpleFilterState, de as traversePath, bV as userConfigSchema, cp as validateAttribute, c0 as validateAttributeConfig, ct as validateDraft, cu as validateDraftOrThrow, c_ as validateFormulaExpression, cq as validateObject, cr as validateObjectOrThrow, d7 as validatePath, ei as verifyNativeObjectsSync, eR as verifyNativeViewsSync, bH as viewRegistry } from './runtime-0gaIqXql.mjs';
1
+ import { D as DateAttribute, U as UserAttribute, A as Attribute, S as SystemResource, a as SystemAction, O as ObjectAction, T as TextAttribute, b as TextAreaAttribute, R as RichtextAttribute, c as RichtextFeature, N as NumberAttribute, C as CheckboxAttribute, P as PhoneAttribute, d as CurrencyAttribute, e as Option, f as StatusAttribute, g as SelectAttribute, M as MultiselectAttribute, L as LocationAttribute, F as FileAttribute, h as SingleRelationAttribute, i as MultiRelationAttribute, j as RelationTarget, k as RatingAttribute, l as FormulaAttribute, m as FormulaReturnType, n as RollupAttribute, o as RollupFunction, p as FlowDefinition, q as FlowPage, r as FlowRow, I as InferAttributeValue, s as ObjectDefinition, t as Field, u as AttributeGroupField, G as Group, V as ViewDefinition, v as Tab, B as BlockNoteContent } from './runtime-UYkiPdud.mjs';
2
+ export { bV as ActivityTab, bb as AddAttribute, eo as AddAttributeInput, aK as AdvancedFilterState, bI as AssignRoleInput, dU as AttributeChange, y as AttributeGroup, ba as AttributeMap, b6 as AttributeSchema, w as AttributeType, e4 as AttributesRepository, ah as AuditAction, ai as AuditActorType, aj as AuditChange, am as AuditListOptions, ak as AuditLogEntry, ea as AuditRepository, ag as AuditResourceType, ed as AuditService, an as AuditServiceOptions, z as BaseAttribute, $ as BlockNoteBlock, a0 as BlockNoteCustomInlineContent, a1 as BlockNoteDefaultProps, a2 as BlockNoteInlineContent, a3 as BlockNoteLink, a4 as BlockNoteStyledText, a5 as BlockNoteStyles, a6 as BlockNoteTableCell, a7 as BlockNoteTableCellProps, a8 as BlockNoteTableContent, av as CheckboxFilterOperator, bw as CompletionStatus, al as CreateAuditLogInput, en as CreateCustomObjectInput, fc as CreateDBAttribute, fq as CreateDBFlow, f8 as CreateDBObject, fm as CreateDBView, ar as CreateFile, ei as CreateFlowInput, ff as CreateObjectRecord, bH as CreatePermissionInput, bF as CreateRoleInput, bP as CreateUserProfile, eN as CreateViewInput, Q as Currency, aC as CurrencyFilterValue, bf as CustomAttributeValue, bU as CustomTab, fb as DBAttribute, fp as DBFlow, f7 as DBObject, fl as DBView, f2 as DEFAULT_LABEL_FALLBACK, d0 as DatabaseAdapter, aw as DateFilterOperator, H as DateFormat, J as DateValue, bC as EffectivePermissions, aG as ExtendedFilterRule, bp as ExtractAttributes, bj as ExtractRecord, bl as ExtractRecordInput, bm as ExtractRecordInputStrict, bk as ExtractRecordStrict, bn as ExtractRecordUpdate, bo as ExtractRecordUpdateStrict, d1 as FetchResult, aq as File, eQ as FileContent, fk as FileListOptions, eh as FileService, eg as FileServiceOptions, ap as FileVisibility, e6 as FilesRepository, aH as FilterCombinator, aJ as FilterGroup, aA as FilterOperator, aF as FilterRule, aI as FilterState, aE as FilterValue, aX as FlowRelation, aW as FlowRowField, ek as FlowService, aV as FlowSlot, aY as FlowStatus, e9 as FlowsRepository, bS as FormTab, d2 as FormattedRecord, dC as FormulaResult, f0 as FullSyncOptions, e$ as FullSyncResult, b4 as GeocodingAdapter, b1 as GeocodingAutocompleteParams, b3 as GeocodingParams, el as GeocodingService, b0 as GeocodingSuggestion, eA as GetRelationOptionsParams, fi as GlobalSearchOptions, fj as GlobalSearchResultItem, em as GlobalSearchService, d3 as GroupedFetchResult, dV as HookContext, dW as HookDefinition, dX as HookHandler, d_ as HookRegistry, dY as HookType, bc as InferRecord, b7 as InferRecordFromSchema, bd as InferRecordInput, be as InferRecordUpdate, b8 as InferRecordWithRequirements, d4 as InsertOptions, dG as InvalidPathError, fg as ListOptions, W as Location, X as LocationGranularity, dH as MaxDepthExceededError, ay as MultiselectFilterOperator, aT as NO_VALUE_OPERATORS, aS as NoValueOperator, b5 as NoopGeocodingAdapter, dZ as NoopHookRegistry, bW as NotesTab, au as NumberFilterOperator, E as NumberUnit, aR as OPERATORS_BY_TYPE, bv as ObjectAttribute, bD as ObjectPermissions, bx as ObjectRecord, e7 as ObjectRecordsRepository, er as ObjectSchemaService, eq as ObjectSchemaServiceOptions, e3 as ObjectsRepository, fs as OperationResult, a9 as PartialBlockNoteBlock, aa as PartialBlockNoteContent, ab as PartialBlockNoteInlineContent, ac as PartialBlockNoteLink, ad as PartialBlockNoteStyledText, ae as PartialBlockNoteTableCell, af as PartialBlockNoteTableContent, dL as PathCardinality, dM as PathSegment, dN as PathSegmentType, bA as Permission, by as PermissionScope, et as PermissionService, es as PermissionServiceOptions, eb as PermissionsRepository, K as Phone, aD as PhoneFilterValue, bJ as PolicyContext, e1 as PolicyRegistry, bL as PolicyViolationError, dg as QueryBuilder, d5 as QueryBuilderState, dc as QueryMultipleResultsError, dd as QueryNoResultError, aQ as QueryState, Y as RELATION_TARGET_ANY, bq as RESERVED_ATTRIBUTE_NAMES, bh as RecordMetadata, bK as RecordPolicy, ev as RecordService, eu as RecordServiceOptions, d6 as RegistryMap, d7 as RegistryObjectNames, Z as RelationAttribute, az as RelationFilterOperator, ey as RelationOption, ez as RelationOptionsResponse, eD as RelationResolverService, eB as RelationService, ex as RelationValidationError, ew as RelationValidationResult, aB as RelativeDateValue, bs as ReservedAttributeName, eC as ResolvedRelations, b2 as ReverseGeocodingParams, bz as Role, eE as RollupResult, eH as RollupScheduler, eG as RollupSchedulerOptions, eF as RollupService, de as SHORTCUT_TO_FILTER_OPERATOR, br as SYSTEM_FIELD_NAMES, dO as SchemaResolver, fh as SearchOptions, ax as SelectFilterOperator, d8 as ShortcutOperator, eT as SignedUrlOptions, aO as SortDirection, aP as SortRule, x as StatusGroup, eU as StorageAdapter, ao as StorageProvider, eR as StorageUploadInput, eS as StorageUploadResult, eX as SyncOptions, eW as SyncResult, bt as SystemFieldName, bi as SystemFields, bE as SystemPermissions, bR as TabType, bT as TableTab, ef as TenantAwareRepository, ee as TenantAwareService, dp as TenantContext, dh as TenantContextError, c1 as TenantId, at as TextFilterOperator, bu as Timestamps, dS as TraversalOptions, dT as TraversalResult, b9 as TypedAttribute, fd as UpdateDBAttribute, fr as UpdateDBFlow, f9 as UpdateDBObject, fn as UpdateDBView, as as UpdateFile, ej as UpdateFlowInput, ep as UpdateObjectInput, bG as UpdateRoleInput, bQ as UpdateUserProfile, eO as UpdateViewInput, eV as UploadFileInput, fe as UpsertDBAttribute, fa as UpsertDBObject, fo as UpsertDBView, c2 as UserId, bO as UserProfile, eJ as UserProfileService, eI as UserProfileServiceOptions, e5 as UserProfilesRepository, bM as UserRole, bB as UserRoleAssignment, eM as UserService, bN as UserStatus, eL as UserValidationError, eK as UserValidationResult, c0 as Uuid, cS as ValidationResult, eP as ViewService, fu as ViewSyncOptions, ft as ViewSyncResult, e8 as ViewsRepository, bg as WithCustomAttributes, c3 as asTenantId, c4 as asUserId, cr as attributeConfigSchemas, ec as buildAuditChanges, cd as checkboxConfigSchema, c$ as computeRecordStatus, cQ as createAttributeValidator, cy as createCheckboxValidator, cB as createCurrencyValidator, cz as createDateValidator, d9 as createDefaultState, cW as createDraftValidator, cG as createFileValidator, cM as createFormulaValidator, cF as createLocationValidator, d$ as createMockAdapter, cJ as createMultiRelationValidator, cE as createMultiselectValidator, cx as createNumberValidator, cR as createObjectValidator, cA as createPhoneValidator, df as createQueryBuilder, cL as createRatingValidator, cK as createRelationValidator, cP as createRichtextValidator, cN as createRollupValidator, cD as createSelectValidator, cI as createSingleRelationValidator, cC as createStatusValidator, cO as createTextAreaValidator, cw as createTextValidator, cH as createUserValidator, cg as currencyConfigSchema, ce as dateConfigSchema, e0 as defaultPolicyRegistry, f6 as enrichValuesWithSelectLabels, dq as evaluateFormula, dr as evaluateFormulaAttribute, ds as evaluateFormulaAttributeWithRelations, dt as evaluateFormulaWithRelations, du as evaluateFormulaWithResult, f5 as extractAttributeNames, dv as extractFormulaVariables, dw as extractRelationNames, dx as extractRelationReferences, cl as fileConfigSchema, dy as flattenRelationsForEval, dz as formatFormulaResult, da as formatRecord, db as formatRecords, cp as formulaConfigSchema, c5 as generateId, c6 as generatePrefixedId, cs as getAttributeConfigSchema, di as getContext, cZ as getMissingRequiredAttributes, dD as getPathDepth, dE as getRelationPath, e_ as getSyncPreview, dF as getTargetAttributeName, dj as getTenantId, dk as getUserId, fx as getViewSyncPreview, dl as hasContext, dA as hasRelationReferences, b_ as isActivityTab, aL as isAdvancedFilterState, bZ as isCustomTab, aZ as isFlowDefinition, a_ as isFlowPublished, bX as isFormTab, f4 as isLabelExpression, aU as isNoValueOperator, b$ as isNotesTab, c_ as isRecordComplete, a$ as isSystemFlow, bY as isTableTab, _ as isUniversalRelation, ci as locationConfigSchema, ck as multiselectConfigSchema, e2 as notesPolicy, cc as numberConfigSchema, cu as parseAttributeConfig, dI as parsePath, dJ as pathHasManyCardinality, cf as phoneConfigSchema, co as ratingConfigSchema, c7 as registry, cn as relationConfigSchema, f3 as renderLabelExpression, dP as resolveMultiplePaths, dQ as resolveSingleValue, cb as richtextConfigSchema, cq as rollupConfigSchema, dm as runWithContext, cv as safeParseAttributeConfig, cj as selectConfigSchema, ch as statusConfigSchema, f1 as syncAll, eY as syncNativeObjects, fv as syncNativeViews, c9 as textConfigSchema, ca as textareaConfigSchema, aM as toAdvancedFilterState, aN as toSimpleFilterState, dR as traversePath, cm as userConfigSchema, cT as validateAttribute, ct as validateAttributeConfig, cX as validateDraft, cY as validateDraftOrThrow, dB as validateFormulaExpression, cU as validateObject, cV as validateObjectOrThrow, dK as validatePath, eZ as verifyNativeObjectsSync, fw as verifyNativeViewsSync, c8 as viewRegistry, dn as withTenantContext } from './runtime-UYkiPdud.mjs';
3
3
  import { IconName, CountryIso3, CurrencyCode, MimeType, ColorId } from '@stndrds/constants';
4
4
  import 'zod';
5
5
 
@@ -107,6 +107,49 @@ declare class ObjectReferencedError extends Error {
107
107
  constructor(objectName: string, referencingObjects: string[]);
108
108
  }
109
109
 
110
+ /**
111
+ * System attribute union type
112
+ */
113
+ type SystemAttribute = DateAttribute | UserAttribute;
114
+ /**
115
+ * System attributes available on all records.
116
+ * These are managed automatically by the system and cannot be edited by users.
117
+ *
118
+ * They use the same types as regular attributes so they work seamlessly
119
+ * with the UI (mapAttributeToCellOpts, DataGrid columns, etc.).
120
+ *
121
+ * @example
122
+ * ```typescript
123
+ * import { SYSTEM_ATTRIBUTES, getSystemAttributeList } from "@stndrds/schema";
124
+ *
125
+ * // Get all attributes including system ones
126
+ * const allAttributes = [
127
+ * ...object.attributes,
128
+ * ...getSystemAttributeList(),
129
+ * ];
130
+ * ```
131
+ */
132
+ declare const SYSTEM_ATTRIBUTES: Record<string, SystemAttribute>;
133
+ /**
134
+ * Get all system attributes as an array
135
+ * Use this to append system attributes to an object's attribute list
136
+ */
137
+ declare function getSystemAttributeList(): SystemAttribute[];
138
+ /**
139
+ * System attribute names as a union type
140
+ */
141
+ type SystemAttributeName = keyof typeof SYSTEM_ATTRIBUTES;
142
+ /**
143
+ * Check if an attribute name is a system attribute
144
+ */
145
+ declare function isSystemAttribute(name: string): name is SystemAttributeName;
146
+ /**
147
+ * Check if an attribute is a system attribute by its properties
148
+ */
149
+ declare function isSystemAttributeObject(attr: {
150
+ system?: boolean;
151
+ }): boolean;
152
+
110
153
  /**
111
154
  * Default empty value placeholder
112
155
  */
@@ -463,6 +506,56 @@ declare class TextAreaAttributeBuilder<TName extends string, TRequired extends b
463
506
  optional(): TextAreaAttributeBuilder<TName, false>;
464
507
  }
465
508
  declare function textarea<TName extends string>(config: TypedBuilderConfig<TName>): TextAreaAttributeBuilder<TName, false>;
509
+ /**
510
+ * Builder for richtext attributes (Tiptap editor)
511
+ */
512
+ declare class RichtextAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<RichtextAttribute> {
513
+ readonly _types: {
514
+ name: TName;
515
+ attribute: RichtextAttribute;
516
+ required: TRequired;
517
+ };
518
+ constructor(name: TName, label: string);
519
+ /**
520
+ * Set enabled features for the richtext editor
521
+ * If not called, all features are enabled by default
522
+ *
523
+ * @param list - Array of features to enable
524
+ *
525
+ * @example
526
+ * ```typescript
527
+ * richtext({ name: "content", label: "Content" })
528
+ * .features(["headings", "bold", "italic", "lists", "links"])
529
+ * ```
530
+ */
531
+ features(list: RichtextFeature[]): this;
532
+ required(): RichtextAttributeBuilder<TName, true>;
533
+ optional(): RichtextAttributeBuilder<TName, false>;
534
+ }
535
+ /**
536
+ * Create a richtext attribute builder for Tiptap-based rich text content
537
+ *
538
+ * @example Basic usage
539
+ * ```typescript
540
+ * richtext({ name: "content", label: "Content" })
541
+ * .required()
542
+ * ```
543
+ *
544
+ * @example With specific features
545
+ * ```typescript
546
+ * richtext({ name: "description", label: "Description" })
547
+ * .features(["headings", "bold", "italic", "lists", "links"])
548
+ * .placeholder("Write something...")
549
+ * ```
550
+ *
551
+ * @example Full-featured (notes, articles)
552
+ * ```typescript
553
+ * richtext({ name: "body", label: "Body" })
554
+ * .features(["headings", "bold", "italic", "lists", "links", "images", "codeBlocks", "tables"])
555
+ * .required()
556
+ * ```
557
+ */
558
+ declare function richtext<TName extends string>(config: TypedBuilderConfig<TName>): RichtextAttributeBuilder<TName, false>;
466
559
  declare class NumberAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<NumberAttribute> {
467
560
  readonly _types: {
468
561
  name: TName;
@@ -600,18 +693,6 @@ declare class LocationAttributeBuilder<TName extends string, TRequired extends b
600
693
  optional(): LocationAttributeBuilder<TName, false>;
601
694
  }
602
695
  declare function location<TName extends string>(config: TypedBuilderConfig<TName>): LocationAttributeBuilder<TName, false>;
603
- declare class TimestampAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<TimestampAttribute> {
604
- readonly _types: {
605
- name: TName;
606
- attribute: TimestampAttribute;
607
- required: TRequired;
608
- };
609
- constructor(name: TName, label: string);
610
- autoUpdate(): this;
611
- required(): TimestampAttributeBuilder<TName, true>;
612
- optional(): TimestampAttributeBuilder<TName, false>;
613
- }
614
- declare function timestamp<TName extends string>(config: TypedBuilderConfig<TName>): TimestampAttributeBuilder<TName, false>;
615
696
  declare class FileAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<FileAttribute> {
616
697
  readonly _types: {
617
698
  name: TName;
@@ -622,7 +703,6 @@ declare class FileAttributeBuilder<TName extends string, TRequired extends boole
622
703
  maxFiles(value: number): this;
623
704
  maxSize(bytes: number): this;
624
705
  allowedTypes(types: MimeType[] | readonly MimeType[]): this;
625
- verification(config: FileAttribute["verification"]): this;
626
706
  /**
627
707
  * Allow multiple files to be uploaded
628
708
  */
@@ -679,6 +759,18 @@ declare class SingleRelationAttributeBuilder<TName extends string, TRequired ext
679
759
  * @param options - Display template and filter options
680
760
  */
681
761
  to(objectName: string, options?: RelationTargetOptions): this;
762
+ /**
763
+ * Allow linking to any object in the tenant (universal polymorphic)
764
+ * Creates a relation with `targets: [{ object: "*" }]`
765
+ *
766
+ * @example
767
+ * ```typescript
768
+ * relation({ name: "linkedTo", label: "Linked To" })
769
+ * .toAny()
770
+ * .hidden()
771
+ * ```
772
+ */
773
+ toAny(): this;
682
774
  /**
683
775
  * Convert to a multi-relation (cardinality: "many")
684
776
  */
@@ -702,6 +794,18 @@ declare class MultiRelationAttributeBuilder<TName extends string, TRequired exte
702
794
  * @param options - Display template and filter options
703
795
  */
704
796
  to(objectName: string, options?: RelationTargetOptions): this;
797
+ /**
798
+ * Allow linking to any object in the tenant (universal polymorphic)
799
+ * Creates a relation with `targets: [{ object: "*" }]`
800
+ *
801
+ * @example
802
+ * ```typescript
803
+ * relation({ name: "linkedItems", label: "Linked Items" })
804
+ * .toAny()
805
+ * .many()
806
+ * ```
807
+ */
808
+ toAny(): this;
705
809
  /**
706
810
  * Set minimum number of relations required
707
811
  */
@@ -868,7 +972,7 @@ declare function rollup<TName extends string>(config: TypedBuilderConfig<TName>)
868
972
  /**
869
973
  * Union of all attribute builder types
870
974
  */
871
- type AnyAttributeBuilder = TextAttributeBuilder<string, boolean> | TextAreaAttributeBuilder<string, boolean> | NumberAttributeBuilder<string, boolean> | CheckboxAttributeBuilder<string, boolean> | DateAttributeBuilder<string, boolean> | PhoneAttributeBuilder<string, boolean> | CurrencyAttributeBuilder<string, boolean> | StatusAttributeBuilder<string, readonly Option[], boolean> | SelectAttributeBuilder<string, readonly Option[], boolean> | MultiselectAttributeBuilder<string, readonly Option[], boolean> | LocationAttributeBuilder<string, boolean> | TimestampAttributeBuilder<string, boolean> | FileAttributeBuilder<string, boolean> | UserAttributeBuilder<string, boolean> | SingleRelationAttributeBuilder<string, boolean> | MultiRelationAttributeBuilder<string, boolean> | RatingAttributeBuilder<string, boolean> | FormulaAttributeBuilder<string> | RollupAttributeBuilder<string>;
975
+ type AnyAttributeBuilder = TextAttributeBuilder<string, boolean> | TextAreaAttributeBuilder<string, boolean> | RichtextAttributeBuilder<string, boolean> | NumberAttributeBuilder<string, boolean> | CheckboxAttributeBuilder<string, boolean> | DateAttributeBuilder<string, boolean> | PhoneAttributeBuilder<string, boolean> | CurrencyAttributeBuilder<string, boolean> | StatusAttributeBuilder<string, readonly Option[], boolean> | SelectAttributeBuilder<string, readonly Option[], boolean> | MultiselectAttributeBuilder<string, readonly Option[], boolean> | LocationAttributeBuilder<string, boolean> | FileAttributeBuilder<string, boolean> | UserAttributeBuilder<string, boolean> | SingleRelationAttributeBuilder<string, boolean> | MultiRelationAttributeBuilder<string, boolean> | RatingAttributeBuilder<string, boolean> | FormulaAttributeBuilder<string> | RollupAttributeBuilder<string>;
872
976
  /**
873
977
  * Extract the attribute name from a builder
874
978
  */
@@ -1591,4 +1695,55 @@ declare function view(name: string, label: string): ViewBuilder;
1591
1695
  */
1592
1696
  declare function group(id: string, label: string): GroupBuilder;
1593
1697
 
1594
- export { ALL_SYSTEM_RESOURCES, type AnyAttributeBuilder, Attribute, AttributeGroupField, AttributeInUseError, AttributeNotFoundError, type AttributeUsage, type BuilderConfig, CheckboxAttribute, CurrencyAttribute, CustomTabConfig, DEFAULT_ROLES, DEFAULT_ROLE_DESCRIPTIONS, DEFAULT_ROLE_LABELS, DEFAULT_ROLE_PERMISSIONS, DateAttribute, type DefaultRoleName, type DefaultRolePermissionConfig, DuplicateError, EMPTY_VALUE_PLACEHOLDER, type ExtractAttributeName, type ExtractAttributeRequired, Field, FileAttribute, FileNotFoundError, FlowBuilder, FlowDefinition, FlowPage, FlowPageBuilder, FlowRow, FlowRowBuilder, ForbiddenError, FormulaAttribute, FormulaReturnType, Group, GroupBuilder, InferAttributeValue, LocationAttribute, MultiRelationAttribute, MultiselectAttribute, NotFoundError, NotSystemObjectError, NumberAttribute, ObjectAction, ObjectBuilder, ObjectDefinition, ObjectNotFoundError, ObjectReferencedError, Option, PhoneAttribute, ProtectedResourceError, ProtectedRoleError, RatingAttribute, RecordNotFoundError, type RecordReference, RecordReferencedError, RelationTarget, RoleNotFoundError, RollupAttribute, RollupFunction, SYSTEM_RESOURCES, SYSTEM_RESOURCE_LABELS, SchemaError, SchemaErrorCode, SelectAttribute, SingleRelationAttribute, StatusAttribute, SyncError, SystemAction, SystemResource, Tab, TabBuilder, TableTabConfig, TextAreaAttribute, TextAttribute, TimestampAttribute, type TypedBuilderConfig, UserAttribute, UserProfileNotFoundError, ValidationError, type ValidationErrorDetail, ViewBuilder, ViewDefinition, checkbox, currency, date, file, flow, formatAttributeValue, formula, group, isDefaultRole, isForbiddenError, isNotFoundError, isProtectedResourceError, isSchemaError, isValidationError, location, multiselect, number, object, phone, rating, relation, rollup, select, status, text, textarea, timestamp, user, view };
1698
+ /**
1699
+ * Native Notes Object
1700
+ *
1701
+ * A Notion-like notes system that can be attached to any record or used globally.
1702
+ * Notes support rich text content via Tiptap editor.
1703
+ *
1704
+ * Features:
1705
+ * - Polymorphic linking to any object/record via `linkedTo` relation
1706
+ * - Private (createdBy-only) or shared (tenant-wide) visibility
1707
+ * - Rich text content with BlockNote
1708
+ * - Extensible via custom attributes
1709
+ *
1710
+ * The author of a note is determined by the system field `createdBy`,
1711
+ * which is automatically set when a record is created.
1712
+ *
1713
+ * Access control is enforced by NotesPolicy:
1714
+ * - Private notes: only visible/editable by createdBy
1715
+ * - Shared notes: visible/editable by all tenant members
1716
+ * - Delete: only createdBy can delete any note
1717
+ *
1718
+ * @example Linked to a record
1719
+ * ```typescript
1720
+ * const note = {
1721
+ * title: "Meeting notes",
1722
+ * content: { type: "doc", content: [...] },
1723
+ * visibility: "shared",
1724
+ * linkedTo: "rec-456" // Can be any record from any object
1725
+ * };
1726
+ * // createdBy is set automatically by RecordService
1727
+ * ```
1728
+ *
1729
+ * @example Global note (not linked)
1730
+ * ```typescript
1731
+ * const note = {
1732
+ * title: "My private thoughts",
1733
+ * content: { type: "doc", content: [...] },
1734
+ * visibility: "private",
1735
+ * linkedTo: null
1736
+ * };
1737
+ * ```
1738
+ */
1739
+ /**
1740
+ * Notes object definition
1741
+ */
1742
+ declare const NOTES: ObjectBuilder<{
1743
+ visibility: "private" | "shared";
1744
+ title: string;
1745
+ content: BlockNoteContent;
1746
+ linkedTo?: string | undefined;
1747
+ }>;
1748
+
1749
+ export { ALL_SYSTEM_RESOURCES, type AnyAttributeBuilder, Attribute, AttributeGroupField, AttributeInUseError, AttributeNotFoundError, type AttributeUsage, BlockNoteContent, type BuilderConfig, CheckboxAttribute, CurrencyAttribute, CustomTabConfig, DEFAULT_ROLES, DEFAULT_ROLE_DESCRIPTIONS, DEFAULT_ROLE_LABELS, DEFAULT_ROLE_PERMISSIONS, DateAttribute, type DefaultRoleName, type DefaultRolePermissionConfig, DuplicateError, EMPTY_VALUE_PLACEHOLDER, type ExtractAttributeName, type ExtractAttributeRequired, Field, FileAttribute, FileNotFoundError, FlowBuilder, FlowDefinition, FlowPage, FlowPageBuilder, FlowRow, FlowRowBuilder, ForbiddenError, FormulaAttribute, FormulaReturnType, Group, GroupBuilder, InferAttributeValue, LocationAttribute, MultiRelationAttribute, MultiselectAttribute, NOTES, NotFoundError, NotSystemObjectError, NumberAttribute, ObjectAction, ObjectBuilder, ObjectDefinition, ObjectNotFoundError, ObjectReferencedError, Option, PhoneAttribute, ProtectedResourceError, ProtectedRoleError, RatingAttribute, RecordNotFoundError, type RecordReference, RecordReferencedError, RelationTarget, RichtextAttribute, RichtextFeature, RoleNotFoundError, RollupAttribute, RollupFunction, SYSTEM_ATTRIBUTES, SYSTEM_RESOURCES, SYSTEM_RESOURCE_LABELS, SchemaError, SchemaErrorCode, SelectAttribute, SingleRelationAttribute, StatusAttribute, SyncError, SystemAction, type SystemAttribute, type SystemAttributeName, SystemResource, Tab, TabBuilder, TableTabConfig, TextAreaAttribute, TextAttribute, type TypedBuilderConfig, UserAttribute, UserProfileNotFoundError, ValidationError, type ValidationErrorDetail, ViewBuilder, ViewDefinition, checkbox, currency, date, file, flow, formatAttributeValue, formula, getSystemAttributeList, group, isDefaultRole, isForbiddenError, isNotFoundError, isProtectedResourceError, isSchemaError, isSystemAttribute, isSystemAttributeObject, isValidationError, location, multiselect, number, object, phone, rating, relation, richtext, rollup, select, status, text, textarea, user, view };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { A as Attribute, S as SystemResource, a as SystemAction, O as ObjectAction, T as TextAttribute, b as TextAreaAttribute, N as NumberAttribute, C as CheckboxAttribute, D as DateAttribute, P as PhoneAttribute, c as CurrencyAttribute, d as Option, e as StatusAttribute, f as SelectAttribute, M as MultiselectAttribute, L as LocationAttribute, g as TimestampAttribute, F as FileAttribute, U as UserAttribute, h as SingleRelationAttribute, i as MultiRelationAttribute, R as RelationTarget, j as RatingAttribute, k as FormulaAttribute, l as FormulaReturnType, m as RollupAttribute, n as RollupFunction, o as FlowDefinition, p as FlowPage, q as FlowRow, I as InferAttributeValue, r as ObjectDefinition, s as Field, t as AttributeGroupField, G as Group, V as ViewDefinition, u as Tab } from './runtime-0gaIqXql.js';
2
- export { bx as ActivityTab, aV as AddAttribute, dJ as AddAttributeInput, as as AdvancedFilterState, bn as AssignRoleInput, dh as AttributeChange, x as AttributeGroup, aU as AttributeMap, aQ as AttributeSchema, v as AttributeType, dr as AttributesRepository, a0 as AuditAction, a1 as AuditActorType, a2 as AuditChange, a5 as AuditListOptions, a3 as AuditLogEntry, dx as AuditRepository, $ as AuditResourceType, dA as AuditService, a6 as AuditServiceOptions, B as BaseAttribute, ae as CheckboxFilterOperator, bb as CompletionStatus, a4 as CreateAuditLogInput, dI as CreateCustomObjectInput, ex as CreateDBAttribute, eL as CreateDBFlow, et as CreateDBObject, eH as CreateDBView, aa as CreateFile, dD as CreateFlowInput, eA as CreateObjectRecord, bm as CreatePermissionInput, bk as CreateRoleInput, br as CreateUserProfile, e6 as CreateViewInput, J as Currency, al as CurrencyFilterValue, aZ as CustomAttributeValue, bw as CustomTab, ew as DBAttribute, eK as DBFlow, es as DBObject, eG as DBView, en as DEFAULT_LABEL_FALLBACK, cy as DatabaseAdapter, af as DateFilterOperator, z as DateFormat, E as DateValue, X as DocumentFace, W as DocumentType, Y as DocumentTypeConfig, bh as EffectivePermissions, b8 as ExtractAttributes, b2 as ExtractRecord, b4 as ExtractRecordInput, b5 as ExtractRecordInputStrict, b3 as ExtractRecordStrict, b6 as ExtractRecordUpdate, b7 as ExtractRecordUpdateStrict, cz as FetchResult, a9 as File, e9 as FileContent, eF as FileListOptions, dC as FileService, dB as FileServiceOptions, Z as FileVerificationConfig, a8 as FileVisibility, dt as FilesRepository, ap as FilterCombinator, ar as FilterGroup, aj as FilterOperator, ao as FilterRule, aq as FilterState, an as FilterValue, aF as FlowRelation, aE as FlowRowField, dF as FlowService, aD as FlowSlot, aG as FlowStatus, dw as FlowsRepository, bu as FormTab, cA as FormattedRecord, c$ as FormulaResult, el as FullSyncOptions, ek as FullSyncResult, aO as GeocodingAdapter, aL as GeocodingAutocompleteParams, aN as GeocodingParams, dG as GeocodingService, aK as GeocodingSuggestion, dV as GetRelationOptionsParams, eD as GlobalSearchOptions, eE as GlobalSearchResultItem, dH as GlobalSearchService, cB as GroupedFetchResult, di as HookContext, dj as HookDefinition, dk as HookHandler, dn as HookRegistry, dl as HookType, aW as InferRecord, aR as InferRecordFromSchema, aX as InferRecordInput, aY as InferRecordUpdate, aS as InferRecordWithRequirements, cC as InsertOptions, d3 as InvalidPathError, eB as ListOptions, K as Location, Q as LocationGranularity, d4 as MaxDepthExceededError, ah as MultiselectFilterOperator, aB as NO_VALUE_OPERATORS, aA as NoValueOperator, aP as NoopGeocodingAdapter, dm as NoopHookRegistry, ad as NumberFilterOperator, y as NumberUnit, az as OPERATORS_BY_TYPE, ba as ObjectAttribute, bi as ObjectPermissions, bc as ObjectRecord, du as ObjectRecordsRepository, dM as ObjectSchemaService, dL as ObjectSchemaServiceOptions, dq as ObjectsRepository, eN as OperationResult, d8 as PathCardinality, d9 as PathSegment, da as PathSegmentType, bf as Permission, bd as PermissionScope, dO as PermissionService, dN as PermissionServiceOptions, dy as PermissionsRepository, H as Phone, am as PhoneFilterValue, cO as QueryBuilder, cD as QueryBuilderState, cK as QueryMultipleResultsError, cL as QueryNoResultError, ay as QueryState, a$ as RecordMetadata, dQ as RecordService, dP as RecordServiceOptions, cE as RegistryMap, cF as RegistryObjectNames, _ as RelationAttribute, ai as RelationFilterOperator, dT as RelationOption, dU as RelationOptionsResponse, dY as RelationResolverService, dW as RelationService, dS as RelationValidationError, dR as RelationValidationResult, ak as RelativeDateValue, dX as ResolvedRelations, aM as ReverseGeocodingParams, be as Role, dZ as RollupResult, e0 as RollupScheduler, d$ as RollupSchedulerOptions, d_ as RollupService, cM as SHORTCUT_TO_FILTER_OPERATOR, b1 as SYSTEM_FIELD_NAMES, db as SchemaResolver, eC as SearchOptions, ag as SelectFilterOperator, cG as ShortcutOperator, ec as SignedUrlOptions, aw as SortDirection, ax as SortRule, w as StatusGroup, ed as StorageAdapter, a7 as StorageProvider, ea as StorageUploadInput, eb as StorageUploadResult, eg as SyncOptions, ef as SyncResult, b0 as SystemFields, bj as SystemPermissions, bt as TabType, bv as TableTab, bD as TenantId, ac as TextFilterOperator, b9 as Timestamps, df as TraversalOptions, dg as TraversalResult, aT as TypedAttribute, ey as UpdateDBAttribute, eM as UpdateDBFlow, eu as UpdateDBObject, eI as UpdateDBView, ab as UpdateFile, dE as UpdateFlowInput, dK as UpdateObjectInput, bl as UpdateRoleInput, bs as UpdateUserProfile, e7 as UpdateViewInput, ee as UploadFileInput, ez as UpsertDBAttribute, ev as UpsertDBObject, eJ as UpsertDBView, bq as UserProfile, e2 as UserProfileService, e1 as UserProfileServiceOptions, ds as UserProfilesRepository, bo as UserRole, bg as UserRoleAssignment, e5 as UserService, bp as UserStatus, e4 as UserValidationError, e3 as UserValidationResult, bC as Uuid, co as ValidationResult, e8 as ViewService, eP as ViewSyncOptions, eO as ViewSyncResult, dv as ViewsRepository, a_ as WithCustomAttributes, b_ as attributeConfigSchemas, dz as buildAuditChanges, bL as checkboxConfigSchema, cx as computeRecordStatus, cm as createAttributeValidator, c5 as createCheckboxValidator, c8 as createCurrencyValidator, c6 as createDateValidator, cH as createDefaultState, cs as createDraftValidator, ce as createFileValidator, ck as createFormulaValidator, cc as createLocationValidator, dp as createMockAdapter, ch as createMultiRelationValidator, cb as createMultiselectValidator, c4 as createNumberValidator, cn as createObjectValidator, c7 as createPhoneValidator, cN as createQueryBuilder, cj as createRatingValidator, ci as createRelationValidator, cl as createRollupValidator, ca as createSelectValidator, cg as createSingleRelationValidator, c9 as createStatusValidator, c3 as createTextValidator, cd as createTimestampValidator, cf as createUserValidator, bO as currencyConfigSchema, bM as dateConfigSchema, er as enrichValuesWithSelectLabels, cP as evaluateFormula, cQ as evaluateFormulaAttribute, cR as evaluateFormulaAttributeWithRelations, cS as evaluateFormulaWithRelations, cT as evaluateFormulaWithResult, eq as extractAttributeNames, cU as extractFormulaVariables, cV as extractRelationNames, cW as extractRelationReferences, bU as fileConfigSchema, cX as flattenRelationsForEval, cY as formatFormulaResult, cI as formatRecord, cJ as formatRecords, bY as formulaConfigSchema, bE as generateId, bF as generatePrefixedId, b$ as getAttributeConfigSchema, cv as getMissingRequiredAttributes, d0 as getPathDepth, d1 as getRelationPath, ej as getSyncPreview, d2 as getTargetAttributeName, eS as getViewSyncPreview, cZ as hasRelationReferences, bB as isActivityTab, at as isAdvancedFilterState, bA as isCustomTab, aH as isFlowDefinition, aI as isFlowPublished, by as isFormTab, ep as isLabelExpression, aC as isNoValueOperator, cw as isRecordComplete, aJ as isSystemFlow, bz as isTableTab, bQ as locationConfigSchema, bT as multiselectConfigSchema, bK as numberConfigSchema, c1 as parseAttributeConfig, d5 as parsePath, d6 as pathHasManyCardinality, bN as phoneConfigSchema, bX as ratingConfigSchema, bG as registry, bW as relationConfigSchema, eo as renderLabelExpression, dc as resolveMultiplePaths, dd as resolveSingleValue, bZ as rollupConfigSchema, c2 as safeParseAttributeConfig, bS as selectConfigSchema, bP as statusConfigSchema, em as syncAll, eh as syncNativeObjects, eQ as syncNativeViews, bI as textConfigSchema, bJ as textareaConfigSchema, bR as timestampConfigSchema, au as toAdvancedFilterState, av as toSimpleFilterState, de as traversePath, bV as userConfigSchema, cp as validateAttribute, c0 as validateAttributeConfig, ct as validateDraft, cu as validateDraftOrThrow, c_ as validateFormulaExpression, cq as validateObject, cr as validateObjectOrThrow, d7 as validatePath, ei as verifyNativeObjectsSync, eR as verifyNativeViewsSync, bH as viewRegistry } from './runtime-0gaIqXql.js';
1
+ import { D as DateAttribute, U as UserAttribute, A as Attribute, S as SystemResource, a as SystemAction, O as ObjectAction, T as TextAttribute, b as TextAreaAttribute, R as RichtextAttribute, c as RichtextFeature, N as NumberAttribute, C as CheckboxAttribute, P as PhoneAttribute, d as CurrencyAttribute, e as Option, f as StatusAttribute, g as SelectAttribute, M as MultiselectAttribute, L as LocationAttribute, F as FileAttribute, h as SingleRelationAttribute, i as MultiRelationAttribute, j as RelationTarget, k as RatingAttribute, l as FormulaAttribute, m as FormulaReturnType, n as RollupAttribute, o as RollupFunction, p as FlowDefinition, q as FlowPage, r as FlowRow, I as InferAttributeValue, s as ObjectDefinition, t as Field, u as AttributeGroupField, G as Group, V as ViewDefinition, v as Tab, B as BlockNoteContent } from './runtime-UYkiPdud.js';
2
+ export { bV as ActivityTab, bb as AddAttribute, eo as AddAttributeInput, aK as AdvancedFilterState, bI as AssignRoleInput, dU as AttributeChange, y as AttributeGroup, ba as AttributeMap, b6 as AttributeSchema, w as AttributeType, e4 as AttributesRepository, ah as AuditAction, ai as AuditActorType, aj as AuditChange, am as AuditListOptions, ak as AuditLogEntry, ea as AuditRepository, ag as AuditResourceType, ed as AuditService, an as AuditServiceOptions, z as BaseAttribute, $ as BlockNoteBlock, a0 as BlockNoteCustomInlineContent, a1 as BlockNoteDefaultProps, a2 as BlockNoteInlineContent, a3 as BlockNoteLink, a4 as BlockNoteStyledText, a5 as BlockNoteStyles, a6 as BlockNoteTableCell, a7 as BlockNoteTableCellProps, a8 as BlockNoteTableContent, av as CheckboxFilterOperator, bw as CompletionStatus, al as CreateAuditLogInput, en as CreateCustomObjectInput, fc as CreateDBAttribute, fq as CreateDBFlow, f8 as CreateDBObject, fm as CreateDBView, ar as CreateFile, ei as CreateFlowInput, ff as CreateObjectRecord, bH as CreatePermissionInput, bF as CreateRoleInput, bP as CreateUserProfile, eN as CreateViewInput, Q as Currency, aC as CurrencyFilterValue, bf as CustomAttributeValue, bU as CustomTab, fb as DBAttribute, fp as DBFlow, f7 as DBObject, fl as DBView, f2 as DEFAULT_LABEL_FALLBACK, d0 as DatabaseAdapter, aw as DateFilterOperator, H as DateFormat, J as DateValue, bC as EffectivePermissions, aG as ExtendedFilterRule, bp as ExtractAttributes, bj as ExtractRecord, bl as ExtractRecordInput, bm as ExtractRecordInputStrict, bk as ExtractRecordStrict, bn as ExtractRecordUpdate, bo as ExtractRecordUpdateStrict, d1 as FetchResult, aq as File, eQ as FileContent, fk as FileListOptions, eh as FileService, eg as FileServiceOptions, ap as FileVisibility, e6 as FilesRepository, aH as FilterCombinator, aJ as FilterGroup, aA as FilterOperator, aF as FilterRule, aI as FilterState, aE as FilterValue, aX as FlowRelation, aW as FlowRowField, ek as FlowService, aV as FlowSlot, aY as FlowStatus, e9 as FlowsRepository, bS as FormTab, d2 as FormattedRecord, dC as FormulaResult, f0 as FullSyncOptions, e$ as FullSyncResult, b4 as GeocodingAdapter, b1 as GeocodingAutocompleteParams, b3 as GeocodingParams, el as GeocodingService, b0 as GeocodingSuggestion, eA as GetRelationOptionsParams, fi as GlobalSearchOptions, fj as GlobalSearchResultItem, em as GlobalSearchService, d3 as GroupedFetchResult, dV as HookContext, dW as HookDefinition, dX as HookHandler, d_ as HookRegistry, dY as HookType, bc as InferRecord, b7 as InferRecordFromSchema, bd as InferRecordInput, be as InferRecordUpdate, b8 as InferRecordWithRequirements, d4 as InsertOptions, dG as InvalidPathError, fg as ListOptions, W as Location, X as LocationGranularity, dH as MaxDepthExceededError, ay as MultiselectFilterOperator, aT as NO_VALUE_OPERATORS, aS as NoValueOperator, b5 as NoopGeocodingAdapter, dZ as NoopHookRegistry, bW as NotesTab, au as NumberFilterOperator, E as NumberUnit, aR as OPERATORS_BY_TYPE, bv as ObjectAttribute, bD as ObjectPermissions, bx as ObjectRecord, e7 as ObjectRecordsRepository, er as ObjectSchemaService, eq as ObjectSchemaServiceOptions, e3 as ObjectsRepository, fs as OperationResult, a9 as PartialBlockNoteBlock, aa as PartialBlockNoteContent, ab as PartialBlockNoteInlineContent, ac as PartialBlockNoteLink, ad as PartialBlockNoteStyledText, ae as PartialBlockNoteTableCell, af as PartialBlockNoteTableContent, dL as PathCardinality, dM as PathSegment, dN as PathSegmentType, bA as Permission, by as PermissionScope, et as PermissionService, es as PermissionServiceOptions, eb as PermissionsRepository, K as Phone, aD as PhoneFilterValue, bJ as PolicyContext, e1 as PolicyRegistry, bL as PolicyViolationError, dg as QueryBuilder, d5 as QueryBuilderState, dc as QueryMultipleResultsError, dd as QueryNoResultError, aQ as QueryState, Y as RELATION_TARGET_ANY, bq as RESERVED_ATTRIBUTE_NAMES, bh as RecordMetadata, bK as RecordPolicy, ev as RecordService, eu as RecordServiceOptions, d6 as RegistryMap, d7 as RegistryObjectNames, Z as RelationAttribute, az as RelationFilterOperator, ey as RelationOption, ez as RelationOptionsResponse, eD as RelationResolverService, eB as RelationService, ex as RelationValidationError, ew as RelationValidationResult, aB as RelativeDateValue, bs as ReservedAttributeName, eC as ResolvedRelations, b2 as ReverseGeocodingParams, bz as Role, eE as RollupResult, eH as RollupScheduler, eG as RollupSchedulerOptions, eF as RollupService, de as SHORTCUT_TO_FILTER_OPERATOR, br as SYSTEM_FIELD_NAMES, dO as SchemaResolver, fh as SearchOptions, ax as SelectFilterOperator, d8 as ShortcutOperator, eT as SignedUrlOptions, aO as SortDirection, aP as SortRule, x as StatusGroup, eU as StorageAdapter, ao as StorageProvider, eR as StorageUploadInput, eS as StorageUploadResult, eX as SyncOptions, eW as SyncResult, bt as SystemFieldName, bi as SystemFields, bE as SystemPermissions, bR as TabType, bT as TableTab, ef as TenantAwareRepository, ee as TenantAwareService, dp as TenantContext, dh as TenantContextError, c1 as TenantId, at as TextFilterOperator, bu as Timestamps, dS as TraversalOptions, dT as TraversalResult, b9 as TypedAttribute, fd as UpdateDBAttribute, fr as UpdateDBFlow, f9 as UpdateDBObject, fn as UpdateDBView, as as UpdateFile, ej as UpdateFlowInput, ep as UpdateObjectInput, bG as UpdateRoleInput, bQ as UpdateUserProfile, eO as UpdateViewInput, eV as UploadFileInput, fe as UpsertDBAttribute, fa as UpsertDBObject, fo as UpsertDBView, c2 as UserId, bO as UserProfile, eJ as UserProfileService, eI as UserProfileServiceOptions, e5 as UserProfilesRepository, bM as UserRole, bB as UserRoleAssignment, eM as UserService, bN as UserStatus, eL as UserValidationError, eK as UserValidationResult, c0 as Uuid, cS as ValidationResult, eP as ViewService, fu as ViewSyncOptions, ft as ViewSyncResult, e8 as ViewsRepository, bg as WithCustomAttributes, c3 as asTenantId, c4 as asUserId, cr as attributeConfigSchemas, ec as buildAuditChanges, cd as checkboxConfigSchema, c$ as computeRecordStatus, cQ as createAttributeValidator, cy as createCheckboxValidator, cB as createCurrencyValidator, cz as createDateValidator, d9 as createDefaultState, cW as createDraftValidator, cG as createFileValidator, cM as createFormulaValidator, cF as createLocationValidator, d$ as createMockAdapter, cJ as createMultiRelationValidator, cE as createMultiselectValidator, cx as createNumberValidator, cR as createObjectValidator, cA as createPhoneValidator, df as createQueryBuilder, cL as createRatingValidator, cK as createRelationValidator, cP as createRichtextValidator, cN as createRollupValidator, cD as createSelectValidator, cI as createSingleRelationValidator, cC as createStatusValidator, cO as createTextAreaValidator, cw as createTextValidator, cH as createUserValidator, cg as currencyConfigSchema, ce as dateConfigSchema, e0 as defaultPolicyRegistry, f6 as enrichValuesWithSelectLabels, dq as evaluateFormula, dr as evaluateFormulaAttribute, ds as evaluateFormulaAttributeWithRelations, dt as evaluateFormulaWithRelations, du as evaluateFormulaWithResult, f5 as extractAttributeNames, dv as extractFormulaVariables, dw as extractRelationNames, dx as extractRelationReferences, cl as fileConfigSchema, dy as flattenRelationsForEval, dz as formatFormulaResult, da as formatRecord, db as formatRecords, cp as formulaConfigSchema, c5 as generateId, c6 as generatePrefixedId, cs as getAttributeConfigSchema, di as getContext, cZ as getMissingRequiredAttributes, dD as getPathDepth, dE as getRelationPath, e_ as getSyncPreview, dF as getTargetAttributeName, dj as getTenantId, dk as getUserId, fx as getViewSyncPreview, dl as hasContext, dA as hasRelationReferences, b_ as isActivityTab, aL as isAdvancedFilterState, bZ as isCustomTab, aZ as isFlowDefinition, a_ as isFlowPublished, bX as isFormTab, f4 as isLabelExpression, aU as isNoValueOperator, b$ as isNotesTab, c_ as isRecordComplete, a$ as isSystemFlow, bY as isTableTab, _ as isUniversalRelation, ci as locationConfigSchema, ck as multiselectConfigSchema, e2 as notesPolicy, cc as numberConfigSchema, cu as parseAttributeConfig, dI as parsePath, dJ as pathHasManyCardinality, cf as phoneConfigSchema, co as ratingConfigSchema, c7 as registry, cn as relationConfigSchema, f3 as renderLabelExpression, dP as resolveMultiplePaths, dQ as resolveSingleValue, cb as richtextConfigSchema, cq as rollupConfigSchema, dm as runWithContext, cv as safeParseAttributeConfig, cj as selectConfigSchema, ch as statusConfigSchema, f1 as syncAll, eY as syncNativeObjects, fv as syncNativeViews, c9 as textConfigSchema, ca as textareaConfigSchema, aM as toAdvancedFilterState, aN as toSimpleFilterState, dR as traversePath, cm as userConfigSchema, cT as validateAttribute, ct as validateAttributeConfig, cX as validateDraft, cY as validateDraftOrThrow, dB as validateFormulaExpression, cU as validateObject, cV as validateObjectOrThrow, dK as validatePath, eZ as verifyNativeObjectsSync, fw as verifyNativeViewsSync, c8 as viewRegistry, dn as withTenantContext } from './runtime-UYkiPdud.js';
3
3
  import { IconName, CountryIso3, CurrencyCode, MimeType, ColorId } from '@stndrds/constants';
4
4
  import 'zod';
5
5
 
@@ -107,6 +107,49 @@ declare class ObjectReferencedError extends Error {
107
107
  constructor(objectName: string, referencingObjects: string[]);
108
108
  }
109
109
 
110
+ /**
111
+ * System attribute union type
112
+ */
113
+ type SystemAttribute = DateAttribute | UserAttribute;
114
+ /**
115
+ * System attributes available on all records.
116
+ * These are managed automatically by the system and cannot be edited by users.
117
+ *
118
+ * They use the same types as regular attributes so they work seamlessly
119
+ * with the UI (mapAttributeToCellOpts, DataGrid columns, etc.).
120
+ *
121
+ * @example
122
+ * ```typescript
123
+ * import { SYSTEM_ATTRIBUTES, getSystemAttributeList } from "@stndrds/schema";
124
+ *
125
+ * // Get all attributes including system ones
126
+ * const allAttributes = [
127
+ * ...object.attributes,
128
+ * ...getSystemAttributeList(),
129
+ * ];
130
+ * ```
131
+ */
132
+ declare const SYSTEM_ATTRIBUTES: Record<string, SystemAttribute>;
133
+ /**
134
+ * Get all system attributes as an array
135
+ * Use this to append system attributes to an object's attribute list
136
+ */
137
+ declare function getSystemAttributeList(): SystemAttribute[];
138
+ /**
139
+ * System attribute names as a union type
140
+ */
141
+ type SystemAttributeName = keyof typeof SYSTEM_ATTRIBUTES;
142
+ /**
143
+ * Check if an attribute name is a system attribute
144
+ */
145
+ declare function isSystemAttribute(name: string): name is SystemAttributeName;
146
+ /**
147
+ * Check if an attribute is a system attribute by its properties
148
+ */
149
+ declare function isSystemAttributeObject(attr: {
150
+ system?: boolean;
151
+ }): boolean;
152
+
110
153
  /**
111
154
  * Default empty value placeholder
112
155
  */
@@ -463,6 +506,56 @@ declare class TextAreaAttributeBuilder<TName extends string, TRequired extends b
463
506
  optional(): TextAreaAttributeBuilder<TName, false>;
464
507
  }
465
508
  declare function textarea<TName extends string>(config: TypedBuilderConfig<TName>): TextAreaAttributeBuilder<TName, false>;
509
+ /**
510
+ * Builder for richtext attributes (Tiptap editor)
511
+ */
512
+ declare class RichtextAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<RichtextAttribute> {
513
+ readonly _types: {
514
+ name: TName;
515
+ attribute: RichtextAttribute;
516
+ required: TRequired;
517
+ };
518
+ constructor(name: TName, label: string);
519
+ /**
520
+ * Set enabled features for the richtext editor
521
+ * If not called, all features are enabled by default
522
+ *
523
+ * @param list - Array of features to enable
524
+ *
525
+ * @example
526
+ * ```typescript
527
+ * richtext({ name: "content", label: "Content" })
528
+ * .features(["headings", "bold", "italic", "lists", "links"])
529
+ * ```
530
+ */
531
+ features(list: RichtextFeature[]): this;
532
+ required(): RichtextAttributeBuilder<TName, true>;
533
+ optional(): RichtextAttributeBuilder<TName, false>;
534
+ }
535
+ /**
536
+ * Create a richtext attribute builder for Tiptap-based rich text content
537
+ *
538
+ * @example Basic usage
539
+ * ```typescript
540
+ * richtext({ name: "content", label: "Content" })
541
+ * .required()
542
+ * ```
543
+ *
544
+ * @example With specific features
545
+ * ```typescript
546
+ * richtext({ name: "description", label: "Description" })
547
+ * .features(["headings", "bold", "italic", "lists", "links"])
548
+ * .placeholder("Write something...")
549
+ * ```
550
+ *
551
+ * @example Full-featured (notes, articles)
552
+ * ```typescript
553
+ * richtext({ name: "body", label: "Body" })
554
+ * .features(["headings", "bold", "italic", "lists", "links", "images", "codeBlocks", "tables"])
555
+ * .required()
556
+ * ```
557
+ */
558
+ declare function richtext<TName extends string>(config: TypedBuilderConfig<TName>): RichtextAttributeBuilder<TName, false>;
466
559
  declare class NumberAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<NumberAttribute> {
467
560
  readonly _types: {
468
561
  name: TName;
@@ -600,18 +693,6 @@ declare class LocationAttributeBuilder<TName extends string, TRequired extends b
600
693
  optional(): LocationAttributeBuilder<TName, false>;
601
694
  }
602
695
  declare function location<TName extends string>(config: TypedBuilderConfig<TName>): LocationAttributeBuilder<TName, false>;
603
- declare class TimestampAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<TimestampAttribute> {
604
- readonly _types: {
605
- name: TName;
606
- attribute: TimestampAttribute;
607
- required: TRequired;
608
- };
609
- constructor(name: TName, label: string);
610
- autoUpdate(): this;
611
- required(): TimestampAttributeBuilder<TName, true>;
612
- optional(): TimestampAttributeBuilder<TName, false>;
613
- }
614
- declare function timestamp<TName extends string>(config: TypedBuilderConfig<TName>): TimestampAttributeBuilder<TName, false>;
615
696
  declare class FileAttributeBuilder<TName extends string, TRequired extends boolean = false> extends BaseAttributeBuilder<FileAttribute> {
616
697
  readonly _types: {
617
698
  name: TName;
@@ -622,7 +703,6 @@ declare class FileAttributeBuilder<TName extends string, TRequired extends boole
622
703
  maxFiles(value: number): this;
623
704
  maxSize(bytes: number): this;
624
705
  allowedTypes(types: MimeType[] | readonly MimeType[]): this;
625
- verification(config: FileAttribute["verification"]): this;
626
706
  /**
627
707
  * Allow multiple files to be uploaded
628
708
  */
@@ -679,6 +759,18 @@ declare class SingleRelationAttributeBuilder<TName extends string, TRequired ext
679
759
  * @param options - Display template and filter options
680
760
  */
681
761
  to(objectName: string, options?: RelationTargetOptions): this;
762
+ /**
763
+ * Allow linking to any object in the tenant (universal polymorphic)
764
+ * Creates a relation with `targets: [{ object: "*" }]`
765
+ *
766
+ * @example
767
+ * ```typescript
768
+ * relation({ name: "linkedTo", label: "Linked To" })
769
+ * .toAny()
770
+ * .hidden()
771
+ * ```
772
+ */
773
+ toAny(): this;
682
774
  /**
683
775
  * Convert to a multi-relation (cardinality: "many")
684
776
  */
@@ -702,6 +794,18 @@ declare class MultiRelationAttributeBuilder<TName extends string, TRequired exte
702
794
  * @param options - Display template and filter options
703
795
  */
704
796
  to(objectName: string, options?: RelationTargetOptions): this;
797
+ /**
798
+ * Allow linking to any object in the tenant (universal polymorphic)
799
+ * Creates a relation with `targets: [{ object: "*" }]`
800
+ *
801
+ * @example
802
+ * ```typescript
803
+ * relation({ name: "linkedItems", label: "Linked Items" })
804
+ * .toAny()
805
+ * .many()
806
+ * ```
807
+ */
808
+ toAny(): this;
705
809
  /**
706
810
  * Set minimum number of relations required
707
811
  */
@@ -868,7 +972,7 @@ declare function rollup<TName extends string>(config: TypedBuilderConfig<TName>)
868
972
  /**
869
973
  * Union of all attribute builder types
870
974
  */
871
- type AnyAttributeBuilder = TextAttributeBuilder<string, boolean> | TextAreaAttributeBuilder<string, boolean> | NumberAttributeBuilder<string, boolean> | CheckboxAttributeBuilder<string, boolean> | DateAttributeBuilder<string, boolean> | PhoneAttributeBuilder<string, boolean> | CurrencyAttributeBuilder<string, boolean> | StatusAttributeBuilder<string, readonly Option[], boolean> | SelectAttributeBuilder<string, readonly Option[], boolean> | MultiselectAttributeBuilder<string, readonly Option[], boolean> | LocationAttributeBuilder<string, boolean> | TimestampAttributeBuilder<string, boolean> | FileAttributeBuilder<string, boolean> | UserAttributeBuilder<string, boolean> | SingleRelationAttributeBuilder<string, boolean> | MultiRelationAttributeBuilder<string, boolean> | RatingAttributeBuilder<string, boolean> | FormulaAttributeBuilder<string> | RollupAttributeBuilder<string>;
975
+ type AnyAttributeBuilder = TextAttributeBuilder<string, boolean> | TextAreaAttributeBuilder<string, boolean> | RichtextAttributeBuilder<string, boolean> | NumberAttributeBuilder<string, boolean> | CheckboxAttributeBuilder<string, boolean> | DateAttributeBuilder<string, boolean> | PhoneAttributeBuilder<string, boolean> | CurrencyAttributeBuilder<string, boolean> | StatusAttributeBuilder<string, readonly Option[], boolean> | SelectAttributeBuilder<string, readonly Option[], boolean> | MultiselectAttributeBuilder<string, readonly Option[], boolean> | LocationAttributeBuilder<string, boolean> | FileAttributeBuilder<string, boolean> | UserAttributeBuilder<string, boolean> | SingleRelationAttributeBuilder<string, boolean> | MultiRelationAttributeBuilder<string, boolean> | RatingAttributeBuilder<string, boolean> | FormulaAttributeBuilder<string> | RollupAttributeBuilder<string>;
872
976
  /**
873
977
  * Extract the attribute name from a builder
874
978
  */
@@ -1591,4 +1695,55 @@ declare function view(name: string, label: string): ViewBuilder;
1591
1695
  */
1592
1696
  declare function group(id: string, label: string): GroupBuilder;
1593
1697
 
1594
- export { ALL_SYSTEM_RESOURCES, type AnyAttributeBuilder, Attribute, AttributeGroupField, AttributeInUseError, AttributeNotFoundError, type AttributeUsage, type BuilderConfig, CheckboxAttribute, CurrencyAttribute, CustomTabConfig, DEFAULT_ROLES, DEFAULT_ROLE_DESCRIPTIONS, DEFAULT_ROLE_LABELS, DEFAULT_ROLE_PERMISSIONS, DateAttribute, type DefaultRoleName, type DefaultRolePermissionConfig, DuplicateError, EMPTY_VALUE_PLACEHOLDER, type ExtractAttributeName, type ExtractAttributeRequired, Field, FileAttribute, FileNotFoundError, FlowBuilder, FlowDefinition, FlowPage, FlowPageBuilder, FlowRow, FlowRowBuilder, ForbiddenError, FormulaAttribute, FormulaReturnType, Group, GroupBuilder, InferAttributeValue, LocationAttribute, MultiRelationAttribute, MultiselectAttribute, NotFoundError, NotSystemObjectError, NumberAttribute, ObjectAction, ObjectBuilder, ObjectDefinition, ObjectNotFoundError, ObjectReferencedError, Option, PhoneAttribute, ProtectedResourceError, ProtectedRoleError, RatingAttribute, RecordNotFoundError, type RecordReference, RecordReferencedError, RelationTarget, RoleNotFoundError, RollupAttribute, RollupFunction, SYSTEM_RESOURCES, SYSTEM_RESOURCE_LABELS, SchemaError, SchemaErrorCode, SelectAttribute, SingleRelationAttribute, StatusAttribute, SyncError, SystemAction, SystemResource, Tab, TabBuilder, TableTabConfig, TextAreaAttribute, TextAttribute, TimestampAttribute, type TypedBuilderConfig, UserAttribute, UserProfileNotFoundError, ValidationError, type ValidationErrorDetail, ViewBuilder, ViewDefinition, checkbox, currency, date, file, flow, formatAttributeValue, formula, group, isDefaultRole, isForbiddenError, isNotFoundError, isProtectedResourceError, isSchemaError, isValidationError, location, multiselect, number, object, phone, rating, relation, rollup, select, status, text, textarea, timestamp, user, view };
1698
+ /**
1699
+ * Native Notes Object
1700
+ *
1701
+ * A Notion-like notes system that can be attached to any record or used globally.
1702
+ * Notes support rich text content via Tiptap editor.
1703
+ *
1704
+ * Features:
1705
+ * - Polymorphic linking to any object/record via `linkedTo` relation
1706
+ * - Private (createdBy-only) or shared (tenant-wide) visibility
1707
+ * - Rich text content with BlockNote
1708
+ * - Extensible via custom attributes
1709
+ *
1710
+ * The author of a note is determined by the system field `createdBy`,
1711
+ * which is automatically set when a record is created.
1712
+ *
1713
+ * Access control is enforced by NotesPolicy:
1714
+ * - Private notes: only visible/editable by createdBy
1715
+ * - Shared notes: visible/editable by all tenant members
1716
+ * - Delete: only createdBy can delete any note
1717
+ *
1718
+ * @example Linked to a record
1719
+ * ```typescript
1720
+ * const note = {
1721
+ * title: "Meeting notes",
1722
+ * content: { type: "doc", content: [...] },
1723
+ * visibility: "shared",
1724
+ * linkedTo: "rec-456" // Can be any record from any object
1725
+ * };
1726
+ * // createdBy is set automatically by RecordService
1727
+ * ```
1728
+ *
1729
+ * @example Global note (not linked)
1730
+ * ```typescript
1731
+ * const note = {
1732
+ * title: "My private thoughts",
1733
+ * content: { type: "doc", content: [...] },
1734
+ * visibility: "private",
1735
+ * linkedTo: null
1736
+ * };
1737
+ * ```
1738
+ */
1739
+ /**
1740
+ * Notes object definition
1741
+ */
1742
+ declare const NOTES: ObjectBuilder<{
1743
+ visibility: "private" | "shared";
1744
+ title: string;
1745
+ content: BlockNoteContent;
1746
+ linkedTo?: string | undefined;
1747
+ }>;
1748
+
1749
+ export { ALL_SYSTEM_RESOURCES, type AnyAttributeBuilder, Attribute, AttributeGroupField, AttributeInUseError, AttributeNotFoundError, type AttributeUsage, BlockNoteContent, type BuilderConfig, CheckboxAttribute, CurrencyAttribute, CustomTabConfig, DEFAULT_ROLES, DEFAULT_ROLE_DESCRIPTIONS, DEFAULT_ROLE_LABELS, DEFAULT_ROLE_PERMISSIONS, DateAttribute, type DefaultRoleName, type DefaultRolePermissionConfig, DuplicateError, EMPTY_VALUE_PLACEHOLDER, type ExtractAttributeName, type ExtractAttributeRequired, Field, FileAttribute, FileNotFoundError, FlowBuilder, FlowDefinition, FlowPage, FlowPageBuilder, FlowRow, FlowRowBuilder, ForbiddenError, FormulaAttribute, FormulaReturnType, Group, GroupBuilder, InferAttributeValue, LocationAttribute, MultiRelationAttribute, MultiselectAttribute, NOTES, NotFoundError, NotSystemObjectError, NumberAttribute, ObjectAction, ObjectBuilder, ObjectDefinition, ObjectNotFoundError, ObjectReferencedError, Option, PhoneAttribute, ProtectedResourceError, ProtectedRoleError, RatingAttribute, RecordNotFoundError, type RecordReference, RecordReferencedError, RelationTarget, RichtextAttribute, RichtextFeature, RoleNotFoundError, RollupAttribute, RollupFunction, SYSTEM_ATTRIBUTES, SYSTEM_RESOURCES, SYSTEM_RESOURCE_LABELS, SchemaError, SchemaErrorCode, SelectAttribute, SingleRelationAttribute, StatusAttribute, SyncError, SystemAction, type SystemAttribute, type SystemAttributeName, SystemResource, Tab, TabBuilder, TableTabConfig, TextAreaAttribute, TextAttribute, type TypedBuilderConfig, UserAttribute, UserProfileNotFoundError, ValidationError, type ValidationErrorDetail, ViewBuilder, ViewDefinition, checkbox, currency, date, file, flow, formatAttributeValue, formula, getSystemAttributeList, group, isDefaultRole, isForbiddenError, isNotFoundError, isProtectedResourceError, isSchemaError, isSystemAttribute, isSystemAttributeObject, isValidationError, location, multiselect, number, object, phone, rating, relation, richtext, rollup, select, status, text, textarea, user, view };