@carlonicora/nextjs-jsonapi 3.2.0 → 3.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (65) hide show
  1. package/dist/{AssistantMessageInterface-Dh0BpbP2.d.ts → AssistantMessageInterface-0zyVingf.d.ts} +1 -1
  2. package/dist/{AssistantMessageInterface-Ce8FcllX.d.mts → AssistantMessageInterface-ddyG114R.d.mts} +1 -1
  3. package/dist/{BlockNoteEditor-RGOOSDA2.mjs → BlockNoteEditor-G5A34EXN.mjs} +4 -4
  4. package/dist/{BlockNoteEditor-G2OSGAKK.js → BlockNoteEditor-JLMXCPGB.js} +19 -19
  5. package/dist/{BlockNoteEditor-G2OSGAKK.js.map → BlockNoteEditor-JLMXCPGB.js.map} +1 -1
  6. package/dist/{auth.interface-COmBjh89.d.ts → auth.interface-B6ZQLGjS.d.ts} +1 -1
  7. package/dist/{auth.interface-CkmZqat3.d.mts → auth.interface-jYD8Gc4P.d.mts} +1 -1
  8. package/dist/billing/index.js +420 -399
  9. package/dist/billing/index.js.map +1 -1
  10. package/dist/billing/index.mjs +25 -4
  11. package/dist/billing/index.mjs.map +1 -1
  12. package/dist/{chunk-B6WAWPN3.js → chunk-5AKDE5UW.js} +755 -755
  13. package/dist/{chunk-B6WAWPN3.js.map → chunk-5AKDE5UW.js.map} +1 -1
  14. package/dist/{chunk-ZMYZFQN3.mjs → chunk-LCMVARSP.mjs} +2 -2
  15. package/dist/{chunk-RFOZWANP.mjs → chunk-O4LTJAAM.mjs} +4 -4
  16. package/dist/{chunk-CGJW7ZZM.mjs → chunk-PGARO3JT.mjs} +7 -1
  17. package/dist/chunk-PGARO3JT.mjs.map +1 -0
  18. package/dist/{chunk-H7DOSB7W.js → chunk-UYENG3GT.js} +7 -7
  19. package/dist/{chunk-H7DOSB7W.js.map → chunk-UYENG3GT.js.map} +1 -1
  20. package/dist/{chunk-YUXCJ35V.js → chunk-YKFXQOQA.js} +7 -1
  21. package/dist/chunk-YKFXQOQA.js.map +1 -0
  22. package/dist/client/index.d.mts +2 -2
  23. package/dist/client/index.d.ts +2 -2
  24. package/dist/client/index.js +4 -4
  25. package/dist/client/index.mjs +3 -3
  26. package/dist/components/index.d.mts +3 -3
  27. package/dist/components/index.d.ts +3 -3
  28. package/dist/components/index.js +4 -4
  29. package/dist/components/index.mjs +3 -3
  30. package/dist/contexts/index.d.mts +3 -3
  31. package/dist/contexts/index.d.ts +3 -3
  32. package/dist/contexts/index.js +4 -4
  33. package/dist/contexts/index.mjs +3 -3
  34. package/dist/core/index.d.mts +9 -7
  35. package/dist/core/index.d.ts +9 -7
  36. package/dist/core/index.js +2 -2
  37. package/dist/core/index.mjs +1 -1
  38. package/dist/features/help/index.js +37 -37
  39. package/dist/features/help/index.mjs +3 -3
  40. package/dist/features/tokenusage/index.js +101 -101
  41. package/dist/features/tokenusage/index.mjs +3 -3
  42. package/dist/index.d.mts +4 -4
  43. package/dist/index.d.ts +4 -4
  44. package/dist/index.js +3 -3
  45. package/dist/index.mjs +2 -2
  46. package/dist/{notification.interface-CG1vqoxg.d.mts → notification.interface-BWOCvKRP.d.mts} +6 -0
  47. package/dist/{notification.interface--27exGde.d.ts → notification.interface-DYF56CtE.d.ts} +6 -0
  48. package/dist/{s3.service-Dt6MfuHr.d.mts → s3.service-D_dswjgz.d.mts} +2 -2
  49. package/dist/{s3.service-CpwA3sl_.d.ts → s3.service-DserU9VK.d.ts} +2 -2
  50. package/dist/server/index.d.mts +3 -3
  51. package/dist/server/index.d.ts +3 -3
  52. package/dist/server/index.js +3 -3
  53. package/dist/server/index.mjs +1 -1
  54. package/dist/{useSocket-M3YY0aTS.d.mts → useSocket-BZG9oX-L.d.mts} +1 -1
  55. package/dist/{useSocket-DgGAQW6h.d.ts → useSocket-CiyTtYFj.d.ts} +1 -1
  56. package/package.json +1 -1
  57. package/src/features/billing/stripe-price/components/forms/PriceEditor.tsx +25 -1
  58. package/src/features/company/data/company.interface.ts +7 -0
  59. package/src/features/company/data/company.test.ts +40 -0
  60. package/src/features/company/data/company.ts +7 -0
  61. package/dist/chunk-CGJW7ZZM.mjs.map +0 -1
  62. package/dist/chunk-YUXCJ35V.js.map +0 -1
  63. /package/dist/{BlockNoteEditor-RGOOSDA2.mjs.map → BlockNoteEditor-G5A34EXN.mjs.map} +0 -0
  64. /package/dist/{chunk-ZMYZFQN3.mjs.map → chunk-LCMVARSP.mjs.map} +0 -0
  65. /package/dist/{chunk-RFOZWANP.mjs.map → chunk-O4LTJAAM.mjs.map} +0 -0
package/dist/index.d.ts CHANGED
@@ -6,15 +6,15 @@ import { A as AbstractApiData } from './AbstractApiData-DtitRWPz.js';
6
6
  import { A as AbstractService } from './AbstractService-Cew0PD0L.js';
7
7
  export { H as HttpMethod, N as NextRef, P as PreviousRef, S as SelfRef, T as TotalRef, b as clearLastApiMeta, c as clearLastApiTotal, d as getGlobalErrorHandler, a as getLastApiMeta, g as getLastApiTotal, s as setGlobalErrorHandler } from './AbstractService-Cew0PD0L.js';
8
8
  export { AppModuleDefinitions, Assistant, AssistantAction, AssistantActionInput, AssistantActionInterface, AssistantActionModule, AssistantActionService, AssistantActionStatus, AssistantMessage, AssistantMessageModule, AssistantMessageService, AssistantModule, AssistantService, AuditLog, AuditLogInterface, AuditLogModule, AuditLogService, Auth, AuthModule, AuthorModule, BackupCodeVerify, BackupCodeVerifyInput, BackupCodeVerifyModule, Billing, BillingModule, BillingService, BlockDiffOptions, BlockNoteDiffUtil, BlockNoteWordDiffRendererUtil, Chunk, ChunkInput, ChunkModule, ClientAbstractService, ClientHttpMethod, ClientNextRef, ClientPreviousRef, ClientSelfRef, ClientTotalRef, CodiceFiscaleValidationOptions, Company, CompanyFields, CompanyModule, Content, ContentModule, DataClass, DataClass as DataClassRegistry, DiffBlock, DiffResult, EndpointCreator, EndpointQuery, EntityAiStatus, EntityObject, Feature, FeatureModule, FormatOption, FoundationModuleDefinitions, HowTo, HowToFields, HowToModule, HowToService, InviteValidation, JsonApiDataFactory, MOBILE_BREAKPOINT, Module, ModuleDefinitions, ModuleModule, ModulePathsModule, ModuleRegistrar, ModuleRegistry, Modules, Notification, NotificationFields, NotificationModule, OAuthClient, OAuthModule, OAuthService, Passkey, PasskeyAuthenticationOptions, PasskeyAuthenticationOptionsInput, PasskeyAuthenticationOptionsInterface, PasskeyAuthenticationOptionsModule, PasskeyModule, PasskeyRegistrationOptions, PasskeyRegistrationOptionsInput, PasskeyRegistrationOptionsInterface, PasskeyRegistrationOptionsModule, PasskeyRegistrationVerify, PasskeyRegistrationVerifyInput, PasskeyRegistrationVerifyModule, PasskeyRename, PasskeyRenameInput, PasskeyRenameModule, PasskeyVerifyLogin, PasskeyVerifyLoginInput, PasskeyVerifyLoginModule, PaymentMethod, PermissionMappingModule, Push, PushInput, PushInterface, PushModule, RbacMatrixModule, ReferralModule, ReferralService, ReferralStats, ReferralStatsModule, RehydrationFactory, Role, RoleModule, S3, S3Module, SearchResultInterface, StripeCustomer, StripeCustomerModule, StripeCustomerService, StripeInvoice, StripeInvoiceModule, StripeInvoiceService, StripePaymentMethodModule, StripePrice, StripePriceFields, StripePriceModule, StripePriceService, StripeProduct, StripeProductFields, StripeProductModule, StripeProductService, StripePromotionCode, StripePromotionCodeModule, StripePromotionCodeService, StripeSubscription, StripeSubscriptionModule, StripeSubscriptionService, StripeUsage, StripeUsageModule, StripeUsageService, TableOptions, ToastOptions, TotpAuthenticator, TotpAuthenticatorModule, TotpSetup, TotpSetupInput, TotpSetupInterface, TotpSetupModule, TotpVerify, TotpVerifyInput, TotpVerifyLogin, TotpVerifyLoginInput, TotpVerifyLoginModule, TotpVerifyModule, TwoFactorChallenge, TwoFactorChallengeInput, TwoFactorChallengeModule, TwoFactorEnable, TwoFactorEnableInput, TwoFactorEnableModule, TwoFactorService, TwoFactorStatus, TwoFactorStatusInterface, TwoFactorStatusModule, User, UserModule, UserObject, VIEWPORT_COOKIE_NAME, Waitlist, WaitlistInput, WaitlistInterface, WaitlistModule, WaitlistService, WaitlistStats, WaitlistStatsInterface, WaitlistStatsModule, WaitlistStatus, WordDiff, checkPermissions, checkPermissionsFromServer, cn, composeRefs, dismissToast, entityObjectSchema, exists, formatCodiceFiscale, formatDate, formatLocalDate, formatPartitaIva, getBootstrapper, getClientGlobalErrorHandler, getTableComponents, getTableOptions, getValueFromPath, hasBootstrapper, isRemoteImageSrc, rehydrate, rehydrateList, resetBootstrapStore, setBootstrapper, setClientGlobalErrorHandler, showCustomToast, showError, showToast, translateData, translateResponse, tryBootstrap, useComposedRefs, useIsMobile, userObjectSchema, validateCodiceFiscale, validateItalianTaxCode, validatePartitaIva } from './core/index.js';
9
- export { c as AssistantMessageInput, d as AssistantMessageInterface, A as AssistantMessageRole, b as AssistantMessageType, B as BreadcrumbItemData, e as ChunkInterface, C as ChunkRelationshipMeta, H as HowToInput, a as HowToInterface } from './AssistantMessageInterface-Dh0BpbP2.js';
9
+ export { c as AssistantMessageInput, d as AssistantMessageInterface, A as AssistantMessageRole, b as AssistantMessageType, B as BreadcrumbItemData, e as ChunkInterface, C as ChunkRelationshipMeta, H as HowToInput, a as HowToInterface } from './AssistantMessageInterface-0zyVingf.js';
10
10
  export { C as ContentFields, D as D3Link, a as D3Node, R as RoleFields, U as UserFields } from './content.fields-1AlHDtDb.js';
11
11
  export { ClassValue } from 'clsx';
12
12
  export { h as AiConnection, l as AiConnectionEnvDefaults, i as AiConnectionFields, n as AiConnectionInput, m as AiConnectionInterface, p as AiConnectionModule, o as AiConnectionService, j as AiProviderFieldDescriptor, k as AiProviderRegistry, A as AuthComponent, P as PasskeyInterface, T as TotpAuthenticatorInterface, b as getIcon, a as getIconByModule, c as getIconByModuleName, g as getInitials, d as getLucideIcon, e as getLucideIconByModule, f as getLucideIconByModuleName } from './ai-connection.module-Bqwh_DnR.js';
13
13
  export { A as Action, d as ModuleDefinition, a as ModuleFactory, c as ModulePermissionDefinition, M as ModuleWithPermissions, P as PageUrl, b as PermissionCheck, e as PermissionConfig, f as PermissionModule, g as PermissionUser } from './types-bsm8Fp55.js';
14
- export { A as AuthInput, b as AuthInterface, a as AuthQuery } from './auth.interface-COmBjh89.js';
15
- export { A as AuthService, C as CompanyService, a as ContentService, F as FeatureService, N as NotificationService, P as PushService, R as RoleService, b as S3Input, c as S3Interface, S as S3Service, T as TwoFactorChallengeInterface, U as UserService } from './s3.service-CpwA3sl_.js';
14
+ export { A as AuthInput, b as AuthInterface, a as AuthQuery } from './auth.interface-B6ZQLGjS.js';
15
+ export { A as AuthService, C as CompanyService, a as ContentService, F as FeatureService, N as NotificationService, P as PushService, R as RoleService, b as S3Input, c as S3Interface, S as S3Service, T as TwoFactorChallengeInterface, U as UserService } from './s3.service-DserU9VK.js';
16
16
  export { I as InvoiceStatus, M as MeterInterface, o as MeterSummaryInterface, P as PaymentMethodInterface, e as PriceRecurring, q as PromotionCodeValidationResult, c as ProrationLineItem, b as ProrationPreviewInterface, R as ReportUsageInput, S as StripeCustomerInterface, a as StripeInvoiceInterface, f as StripePriceInput, d as StripePriceInterface, h as StripeProductInput, g as StripeProductInterface, l as StripeSubscriptionCreateMeta, m as StripeSubscriptionCreateResponse, k as StripeSubscriptionInput, j as StripeSubscriptionInterface, n as StripeUsageInterface, i as SubscriptionStatus, p as UsageRecordInterface, U as UsageSummaryInterface } from './stripe-promotion-code.interface-C3qqh3mi.js';
17
- export { b as CompanyInput, c as CompanyInterface, a as ContentInput, C as ContentInterface, d as NotificationInput, N as NotificationInterface, R as RoleInput, e as RoleInterface, f as UserInput, U as UserInterface } from './notification.interface--27exGde.js';
17
+ export { b as CompanyInput, c as CompanyInterface, a as ContentInput, C as ContentInterface, d as NotificationInput, N as NotificationInterface, R as RoleInput, e as RoleInterface, f as UserInput, U as UserInterface } from './notification.interface-DYF56CtE.js';
18
18
  export { A as AssistantInput, a as AssistantInterface } from './AssistantInterface-DwdBzS9f.js';
19
19
  export { F as FeatureInterface, M as ModuleInterface } from './feature.interface-BO25VLlx.js';
20
20
  export { A as AVAILABLE_OAUTH_SCOPES, D as DEFAULT_GRANT_TYPES, g as OAUTH_SCOPE_DISPLAY, b as OAuthClientCreateRequest, c as OAuthClientCreateResponse, a as OAuthClientInput, O as OAuthClientInterface, f as OAuthConsentInfo, d as OAuthConsentRequest, e as OAuthScopeInfo } from './oauth.interface-CD90ycYz.js';
package/dist/index.js CHANGED
@@ -18,7 +18,7 @@
18
18
 
19
19
 
20
20
 
21
- var _chunkH7DOSB7Wjs = require('./chunk-H7DOSB7W.js');
21
+ var _chunkUYENG3GTjs = require('./chunk-UYENG3GT.js');
22
22
 
23
23
 
24
24
 
@@ -225,7 +225,7 @@ var _chunkH7DOSB7Wjs = require('./chunk-H7DOSB7W.js');
225
225
 
226
226
 
227
227
 
228
- var _chunkYUXCJ35Vjs = require('./chunk-YUXCJ35V.js');
228
+ var _chunkYKFXQOQAjs = require('./chunk-YKFXQOQA.js');
229
229
  require('./chunk-LXKSUWAV.js');
230
230
  require('./chunk-IBS6NI7D.js');
231
231
 
@@ -475,5 +475,5 @@ require('./chunk-7QVYU63E.js');
475
475
 
476
476
 
477
477
 
478
- exports.ACTION_TYPES = _chunkH7DOSB7Wjs.ACTION_TYPES; exports.AVAILABLE_OAUTH_SCOPES = _chunkYUXCJ35Vjs.AVAILABLE_OAUTH_SCOPES; exports.AbstractApiData = _chunkYUXCJ35Vjs.AbstractApiData; exports.AbstractService = _chunkYUXCJ35Vjs.AbstractService; exports.Action = _chunkYUXCJ35Vjs.Action; exports.AiConnection = _chunkYUXCJ35Vjs.AiConnection; exports.AiConnectionFields = _chunkYUXCJ35Vjs.AiConnectionFields; exports.AiConnectionModule = _chunkYUXCJ35Vjs.AiConnectionModule; exports.AiConnectionService = _chunkYUXCJ35Vjs.AiConnectionService; exports.Assistant = _chunkYUXCJ35Vjs.Assistant; exports.AssistantAction = _chunkYUXCJ35Vjs.AssistantAction; exports.AssistantActionModule = _chunkYUXCJ35Vjs.AssistantActionModule; exports.AssistantActionService = _chunkYUXCJ35Vjs.AssistantActionService; exports.AssistantMessage = _chunkYUXCJ35Vjs.AssistantMessage; exports.AssistantMessageModule = _chunkYUXCJ35Vjs.AssistantMessageModule; exports.AssistantMessageService = _chunkYUXCJ35Vjs.AssistantMessageService; exports.AssistantModule = _chunkYUXCJ35Vjs.AssistantModule; exports.AssistantService = _chunkYUXCJ35Vjs.AssistantService; exports.AuditLog = _chunkYUXCJ35Vjs.AuditLog; exports.AuditLogModule = _chunkYUXCJ35Vjs.AuditLogModule; exports.AuditLogService = _chunkYUXCJ35Vjs.AuditLogService; exports.Auth = _chunkYUXCJ35Vjs.Auth; exports.AuthComponent = _chunkYUXCJ35Vjs.AuthComponent; exports.AuthModule = _chunkYUXCJ35Vjs.AuthModule; exports.AuthService = _chunkYUXCJ35Vjs.AuthService; exports.AuthorModule = _chunkYUXCJ35Vjs.AuthorModule; exports.BackupCodeVerify = _chunkYUXCJ35Vjs.BackupCodeVerify; exports.BackupCodeVerifyModule = _chunkYUXCJ35Vjs.BackupCodeVerifyModule; exports.Billing = _chunkYUXCJ35Vjs.Billing; exports.BillingModule = _chunkYUXCJ35Vjs.BillingModule; exports.BillingService = _chunkYUXCJ35Vjs.BillingService; exports.BlockNoteDiffUtil = _chunkYUXCJ35Vjs.BlockNoteDiffUtil; exports.BlockNoteWordDiffRendererUtil = _chunkYUXCJ35Vjs.BlockNoteWordDiffRendererUtil; exports.COMPANY_ADMINISTRATOR_ROLE_ID = _chunkH7DOSB7Wjs.COMPANY_ADMINISTRATOR_ROLE_ID; exports.Chunk = _chunkYUXCJ35Vjs.Chunk; exports.ChunkModule = _chunkYUXCJ35Vjs.ChunkModule; exports.ClientAbstractService = _chunkYUXCJ35Vjs.ClientAbstractService; exports.ClientHttpMethod = _chunkYUXCJ35Vjs.ClientHttpMethod; exports.Company = _chunkYUXCJ35Vjs.Company; exports.CompanyFields = _chunkYUXCJ35Vjs.CompanyFields; exports.CompanyModule = _chunkYUXCJ35Vjs.CompanyModule; exports.CompanyService = _chunkYUXCJ35Vjs.CompanyService; exports.Content = _chunkYUXCJ35Vjs.Content; exports.ContentFields = _chunkYUXCJ35Vjs.ContentFields; exports.ContentModule = _chunkYUXCJ35Vjs.ContentModule; exports.ContentService = _chunkYUXCJ35Vjs.ContentService; exports.DEFAULT_GRANT_TYPES = _chunkYUXCJ35Vjs.DEFAULT_GRANT_TYPES; exports.DataClass = _chunkPFAZPP54js.DataClassRegistry; exports.DataClassRegistry = _chunkPFAZPP54js.DataClassRegistry; exports.EndpointCreator = _chunkYUXCJ35Vjs.EndpointCreator; exports.EntityAiStatus = _chunkYUXCJ35Vjs.EntityAiStatus; exports.Feature = _chunkYUXCJ35Vjs.Feature; exports.FeatureModule = _chunkYUXCJ35Vjs.FeatureModule; exports.FeatureService = _chunkYUXCJ35Vjs.FeatureService; exports.HowTo = _chunkYUXCJ35Vjs.HowTo; exports.HowToFields = _chunkYUXCJ35Vjs.HowToFields; exports.HowToModule = _chunkYUXCJ35Vjs.HowToModule; exports.HowToService = _chunkYUXCJ35Vjs.HowToService; exports.HttpMethod = _chunkYUXCJ35Vjs.HttpMethod; exports.InvoiceStatus = _chunkYUXCJ35Vjs.InvoiceStatus; exports.JsonApiDataFactory = _chunkPFAZPP54js.JsonApiDataFactory; exports.MOBILE_BREAKPOINT = _chunkYUXCJ35Vjs.MOBILE_BREAKPOINT; exports.Module = _chunkYUXCJ35Vjs.Module; exports.ModuleModule = _chunkYUXCJ35Vjs.ModuleModule; exports.ModulePaths = _chunkYUXCJ35Vjs.ModulePaths; exports.ModulePathsModule = _chunkYUXCJ35Vjs.ModulePathsModule; exports.ModuleRegistrar = _chunkYUXCJ35Vjs.ModuleRegistrar; exports.ModuleRegistry = _chunkYUXCJ35Vjs.ModuleRegistry; exports.Modules = _chunkYUXCJ35Vjs.Modules; exports.Notification = _chunkYUXCJ35Vjs.Notification; exports.NotificationFields = _chunkYUXCJ35Vjs.NotificationFields; exports.NotificationModule = _chunkYUXCJ35Vjs.NotificationModule; exports.NotificationService = _chunkYUXCJ35Vjs.NotificationService; exports.OAUTH_SCOPE_DISPLAY = _chunkYUXCJ35Vjs.OAUTH_SCOPE_DISPLAY; exports.OAuthClient = _chunkYUXCJ35Vjs.OAuthClient; exports.OAuthModule = _chunkYUXCJ35Vjs.OAuthModule; exports.OAuthService = _chunkYUXCJ35Vjs.OAuthService; exports.Passkey = _chunkYUXCJ35Vjs.Passkey; exports.PasskeyAuthenticationOptions = _chunkYUXCJ35Vjs.PasskeyAuthenticationOptions; exports.PasskeyAuthenticationOptionsModule = _chunkYUXCJ35Vjs.PasskeyAuthenticationOptionsModule; exports.PasskeyModule = _chunkYUXCJ35Vjs.PasskeyModule; exports.PasskeyRegistrationOptions = _chunkYUXCJ35Vjs.PasskeyRegistrationOptions; exports.PasskeyRegistrationOptionsModule = _chunkYUXCJ35Vjs.PasskeyRegistrationOptionsModule; exports.PasskeyRegistrationVerify = _chunkYUXCJ35Vjs.PasskeyRegistrationVerify; exports.PasskeyRegistrationVerifyModule = _chunkYUXCJ35Vjs.PasskeyRegistrationVerifyModule; exports.PasskeyRename = _chunkYUXCJ35Vjs.PasskeyRename; exports.PasskeyRenameModule = _chunkYUXCJ35Vjs.PasskeyRenameModule; exports.PasskeyVerifyLogin = _chunkYUXCJ35Vjs.PasskeyVerifyLogin; exports.PasskeyVerifyLoginModule = _chunkYUXCJ35Vjs.PasskeyVerifyLoginModule; exports.PaymentMethod = _chunkYUXCJ35Vjs.PaymentMethod; exports.PermissionMapping = _chunkYUXCJ35Vjs.PermissionMapping; exports.PermissionMappingModule = _chunkYUXCJ35Vjs.PermissionMappingModule; exports.Push = _chunkYUXCJ35Vjs.Push; exports.PushModule = _chunkYUXCJ35Vjs.PushModule; exports.PushService = _chunkYUXCJ35Vjs.PushService; exports.RbacMatrixModel = _chunkYUXCJ35Vjs.RbacMatrixModel; exports.RbacMatrixModule = _chunkYUXCJ35Vjs.RbacMatrixModule; exports.RbacService = _chunkH7DOSB7Wjs.RbacService; exports.ReferralModule = _chunkYUXCJ35Vjs.ReferralModule; exports.ReferralService = _chunkYUXCJ35Vjs.ReferralService; exports.ReferralStats = _chunkYUXCJ35Vjs.ReferralStats; exports.ReferralStatsModule = _chunkYUXCJ35Vjs.ReferralStatsModule; exports.RehydrationFactory = _chunkYUXCJ35Vjs.RehydrationFactory; exports.Role = _chunkYUXCJ35Vjs.Role; exports.RoleFields = _chunkYUXCJ35Vjs.RoleFields; exports.RoleModule = _chunkYUXCJ35Vjs.RoleModule; exports.RoleService = _chunkYUXCJ35Vjs.RoleService; exports.S3 = _chunkYUXCJ35Vjs.S3; exports.S3Module = _chunkYUXCJ35Vjs.S3Module; exports.S3Service = _chunkYUXCJ35Vjs.S3Service; exports.StripeCustomer = _chunkYUXCJ35Vjs.StripeCustomer; exports.StripeCustomerModule = _chunkYUXCJ35Vjs.StripeCustomerModule; exports.StripeCustomerService = _chunkYUXCJ35Vjs.StripeCustomerService; exports.StripeInvoice = _chunkYUXCJ35Vjs.StripeInvoice; exports.StripeInvoiceModule = _chunkYUXCJ35Vjs.StripeInvoiceModule; exports.StripeInvoiceService = _chunkYUXCJ35Vjs.StripeInvoiceService; exports.StripePaymentMethodModule = _chunkYUXCJ35Vjs.StripePaymentMethodModule; exports.StripePrice = _chunkYUXCJ35Vjs.StripePrice; exports.StripePriceFields = _chunkYUXCJ35Vjs.StripePriceFields; exports.StripePriceModule = _chunkYUXCJ35Vjs.StripePriceModule; exports.StripePriceService = _chunkYUXCJ35Vjs.StripePriceService; exports.StripeProduct = _chunkYUXCJ35Vjs.StripeProduct; exports.StripeProductFields = _chunkYUXCJ35Vjs.StripeProductFields; exports.StripeProductModule = _chunkYUXCJ35Vjs.StripeProductModule; exports.StripeProductService = _chunkYUXCJ35Vjs.StripeProductService; exports.StripePromotionCode = _chunkYUXCJ35Vjs.StripePromotionCode; exports.StripePromotionCodeModule = _chunkYUXCJ35Vjs.StripePromotionCodeModule; exports.StripePromotionCodeService = _chunkYUXCJ35Vjs.StripePromotionCodeService; exports.StripeSubscription = _chunkYUXCJ35Vjs.StripeSubscription; exports.StripeSubscriptionModule = _chunkYUXCJ35Vjs.StripeSubscriptionModule; exports.StripeSubscriptionService = _chunkYUXCJ35Vjs.StripeSubscriptionService; exports.StripeUsage = _chunkYUXCJ35Vjs.StripeUsage; exports.StripeUsageModule = _chunkYUXCJ35Vjs.StripeUsageModule; exports.StripeUsageService = _chunkYUXCJ35Vjs.StripeUsageService; exports.SubscriptionStatus = _chunkYUXCJ35Vjs.SubscriptionStatus; exports.TableOptions = _chunkYUXCJ35Vjs.TableOptions; exports.TokenUsageAdminBreakdownModule = _chunkYUXCJ35Vjs.TokenUsageAdminBreakdownModule; exports.TokenUsageAdminSummaryModule = _chunkYUXCJ35Vjs.TokenUsageAdminSummaryModule; exports.TokenUsageAdminTimelineModule = _chunkYUXCJ35Vjs.TokenUsageAdminTimelineModule; exports.TotpAuthenticator = _chunkYUXCJ35Vjs.TotpAuthenticator; exports.TotpAuthenticatorModule = _chunkYUXCJ35Vjs.TotpAuthenticatorModule; exports.TotpSetup = _chunkYUXCJ35Vjs.TotpSetup; exports.TotpSetupModule = _chunkYUXCJ35Vjs.TotpSetupModule; exports.TotpVerify = _chunkYUXCJ35Vjs.TotpVerify; exports.TotpVerifyLogin = _chunkYUXCJ35Vjs.TotpVerifyLogin; exports.TotpVerifyLoginModule = _chunkYUXCJ35Vjs.TotpVerifyLoginModule; exports.TotpVerifyModule = _chunkYUXCJ35Vjs.TotpVerifyModule; exports.TwoFactorChallenge = _chunkYUXCJ35Vjs.TwoFactorChallenge; exports.TwoFactorChallengeModule = _chunkYUXCJ35Vjs.TwoFactorChallengeModule; exports.TwoFactorEnable = _chunkYUXCJ35Vjs.TwoFactorEnable; exports.TwoFactorEnableModule = _chunkYUXCJ35Vjs.TwoFactorEnableModule; exports.TwoFactorService = _chunkYUXCJ35Vjs.TwoFactorService; exports.TwoFactorStatus = _chunkYUXCJ35Vjs.TwoFactorStatus; exports.TwoFactorStatusModule = _chunkYUXCJ35Vjs.TwoFactorStatusModule; exports.User = _chunkYUXCJ35Vjs.User; exports.UserFields = _chunkYUXCJ35Vjs.UserFields; exports.UserModule = _chunkYUXCJ35Vjs.UserModule; exports.UserService = _chunkYUXCJ35Vjs.UserService; exports.VIEWPORT_COOKIE_NAME = _chunkYUXCJ35Vjs.VIEWPORT_COOKIE_NAME; exports.Waitlist = _chunkYUXCJ35Vjs.Waitlist; exports.WaitlistModule = _chunkYUXCJ35Vjs.WaitlistModule; exports.WaitlistService = _chunkYUXCJ35Vjs.WaitlistService; exports.WaitlistStats = _chunkYUXCJ35Vjs.WaitlistStats; exports.WaitlistStatsModule = _chunkYUXCJ35Vjs.WaitlistStatsModule; exports.checkPermissions = _chunkYUXCJ35Vjs.checkPermissions; exports.checkPermissionsFromServer = _chunkYUXCJ35Vjs.checkPermissionsFromServer; exports.clearLastApiMeta = _chunkYUXCJ35Vjs.clearLastApiMeta; exports.clearLastApiTotal = _chunkYUXCJ35Vjs.clearLastApiTotal; exports.cn = _chunkYUXCJ35Vjs.cn; exports.composeRefs = _chunkYUXCJ35Vjs.composeRefs; exports.configureAuth = _chunkYUXCJ35Vjs.configureAuth; exports.configureI18n = _chunkH7DOSB7Wjs.configureI18n; exports.configureJsonApi = _chunkH7DOSB7Wjs.configureJsonApi; exports.configureLogin = _chunkH7DOSB7Wjs.configureLogin; exports.configureReferral = _chunkH7DOSB7Wjs.configureReferral; exports.configureRoles = _chunkH7DOSB7Wjs.configureRoles; exports.configureTokenUsage = _chunkYUXCJ35Vjs.configureTokenUsage; exports.configureWaitlist = _chunkH7DOSB7Wjs.configureWaitlist; exports.createJsonApiInclusion = _chunkYUXCJ35Vjs.createJsonApiInclusion; exports.dismissToast = _chunkYUXCJ35Vjs.dismissToast; exports.entityObjectSchema = _chunkYUXCJ35Vjs.entityObjectSchema; exports.exists = _chunkYUXCJ35Vjs.exists; exports.formatCodiceFiscale = _chunkYUXCJ35Vjs.formatCodiceFiscale; exports.formatDate = _chunkYUXCJ35Vjs.formatDate; exports.formatLocalDate = _chunkYUXCJ35Vjs.formatLocalDate; exports.formatPartitaIva = _chunkYUXCJ35Vjs.formatPartitaIva; exports.getApiUrl = _chunkH7DOSB7Wjs.getApiUrl; exports.getAppUrl = _chunkH7DOSB7Wjs.getAppUrl; exports.getBootstrapper = _chunkPFAZPP54js.getBootstrapper; exports.getClientGlobalErrorHandler = _chunkYUXCJ35Vjs.getClientGlobalErrorHandler; exports.getGlobalErrorHandler = _chunkYUXCJ35Vjs.getGlobalErrorHandler; exports.getIcon = _chunkYUXCJ35Vjs.getIcon; exports.getIconByModule = _chunkYUXCJ35Vjs.getIconByModule; exports.getIconByModuleName = _chunkYUXCJ35Vjs.getIconByModuleName; exports.getInitials = _chunkYUXCJ35Vjs.getInitials; exports.getLastApiMeta = _chunkYUXCJ35Vjs.getLastApiMeta; exports.getLastApiTotal = _chunkYUXCJ35Vjs.getLastApiTotal; exports.getLucideIcon = _chunkYUXCJ35Vjs.getLucideIcon; exports.getLucideIconByModule = _chunkYUXCJ35Vjs.getLucideIconByModule; exports.getLucideIconByModuleName = _chunkYUXCJ35Vjs.getLucideIconByModuleName; exports.getPublicApiUrl = _chunkH7DOSB7Wjs.getPublicApiUrl; exports.getReferralConfig = _chunkH7DOSB7Wjs.getReferralConfig; exports.getRoleId = _chunkH7DOSB7Wjs.getRoleId; exports.getStripePublishableKey = _chunkH7DOSB7Wjs.getStripePublishableKey; exports.getTableComponents = _chunkYUXCJ35Vjs.getTableComponents; exports.getTableOptions = _chunkYUXCJ35Vjs.getTableOptions; exports.getTokenHandler = _chunkYUXCJ35Vjs.getTokenHandler; exports.getTokenUsageCurrency = _chunkYUXCJ35Vjs.getTokenUsageCurrency; exports.getTrackablePages = _chunkH7DOSB7Wjs.getTrackablePages; exports.getValueFromPath = _chunkYUXCJ35Vjs.getValueFromPath; exports.getWaitlistConfig = _chunkH7DOSB7Wjs.getWaitlistConfig; exports.hasBootstrapper = _chunkPFAZPP54js.hasBootstrapper; exports.isReferralEnabled = _chunkH7DOSB7Wjs.isReferralEnabled; exports.isRemoteImageSrc = _chunkYUXCJ35Vjs.isRemoteImageSrc; exports.isRolesConfigured = _chunkH7DOSB7Wjs.isRolesConfigured; exports.rehydrate = _chunkYUXCJ35Vjs.rehydrate; exports.rehydrateList = _chunkYUXCJ35Vjs.rehydrateList; exports.resetBootstrapStore = _chunkPFAZPP54js.resetBootstrapStore; exports.setBootstrapper = _chunkPFAZPP54js.setBootstrapper; exports.setClientGlobalErrorHandler = _chunkYUXCJ35Vjs.setClientGlobalErrorHandler; exports.setGlobalErrorHandler = _chunkYUXCJ35Vjs.setGlobalErrorHandler; exports.showCustomToast = _chunkYUXCJ35Vjs.showCustomToast; exports.showError = _chunkYUXCJ35Vjs.showError; exports.showToast = _chunkYUXCJ35Vjs.showToast; exports.tokenUsageModules = _chunkYUXCJ35Vjs.tokenUsageModules; exports.translateData = _chunkPFAZPP54js.translateData; exports.translateResponse = _chunkPFAZPP54js.translateResponse; exports.tryBootstrap = _chunkPFAZPP54js.tryBootstrap; exports.useComposedRefs = _chunkYUXCJ35Vjs.useComposedRefs; exports.useIsMobile = _chunkYUXCJ35Vjs.useIsMobile; exports.userObjectSchema = _chunkYUXCJ35Vjs.userObjectSchema; exports.validateCodiceFiscale = _chunkYUXCJ35Vjs.validateCodiceFiscale; exports.validateItalianTaxCode = _chunkYUXCJ35Vjs.validateItalianTaxCode; exports.validatePartitaIva = _chunkYUXCJ35Vjs.validatePartitaIva;
478
+ exports.ACTION_TYPES = _chunkUYENG3GTjs.ACTION_TYPES; exports.AVAILABLE_OAUTH_SCOPES = _chunkYKFXQOQAjs.AVAILABLE_OAUTH_SCOPES; exports.AbstractApiData = _chunkYKFXQOQAjs.AbstractApiData; exports.AbstractService = _chunkYKFXQOQAjs.AbstractService; exports.Action = _chunkYKFXQOQAjs.Action; exports.AiConnection = _chunkYKFXQOQAjs.AiConnection; exports.AiConnectionFields = _chunkYKFXQOQAjs.AiConnectionFields; exports.AiConnectionModule = _chunkYKFXQOQAjs.AiConnectionModule; exports.AiConnectionService = _chunkYKFXQOQAjs.AiConnectionService; exports.Assistant = _chunkYKFXQOQAjs.Assistant; exports.AssistantAction = _chunkYKFXQOQAjs.AssistantAction; exports.AssistantActionModule = _chunkYKFXQOQAjs.AssistantActionModule; exports.AssistantActionService = _chunkYKFXQOQAjs.AssistantActionService; exports.AssistantMessage = _chunkYKFXQOQAjs.AssistantMessage; exports.AssistantMessageModule = _chunkYKFXQOQAjs.AssistantMessageModule; exports.AssistantMessageService = _chunkYKFXQOQAjs.AssistantMessageService; exports.AssistantModule = _chunkYKFXQOQAjs.AssistantModule; exports.AssistantService = _chunkYKFXQOQAjs.AssistantService; exports.AuditLog = _chunkYKFXQOQAjs.AuditLog; exports.AuditLogModule = _chunkYKFXQOQAjs.AuditLogModule; exports.AuditLogService = _chunkYKFXQOQAjs.AuditLogService; exports.Auth = _chunkYKFXQOQAjs.Auth; exports.AuthComponent = _chunkYKFXQOQAjs.AuthComponent; exports.AuthModule = _chunkYKFXQOQAjs.AuthModule; exports.AuthService = _chunkYKFXQOQAjs.AuthService; exports.AuthorModule = _chunkYKFXQOQAjs.AuthorModule; exports.BackupCodeVerify = _chunkYKFXQOQAjs.BackupCodeVerify; exports.BackupCodeVerifyModule = _chunkYKFXQOQAjs.BackupCodeVerifyModule; exports.Billing = _chunkYKFXQOQAjs.Billing; exports.BillingModule = _chunkYKFXQOQAjs.BillingModule; exports.BillingService = _chunkYKFXQOQAjs.BillingService; exports.BlockNoteDiffUtil = _chunkYKFXQOQAjs.BlockNoteDiffUtil; exports.BlockNoteWordDiffRendererUtil = _chunkYKFXQOQAjs.BlockNoteWordDiffRendererUtil; exports.COMPANY_ADMINISTRATOR_ROLE_ID = _chunkUYENG3GTjs.COMPANY_ADMINISTRATOR_ROLE_ID; exports.Chunk = _chunkYKFXQOQAjs.Chunk; exports.ChunkModule = _chunkYKFXQOQAjs.ChunkModule; exports.ClientAbstractService = _chunkYKFXQOQAjs.ClientAbstractService; exports.ClientHttpMethod = _chunkYKFXQOQAjs.ClientHttpMethod; exports.Company = _chunkYKFXQOQAjs.Company; exports.CompanyFields = _chunkYKFXQOQAjs.CompanyFields; exports.CompanyModule = _chunkYKFXQOQAjs.CompanyModule; exports.CompanyService = _chunkYKFXQOQAjs.CompanyService; exports.Content = _chunkYKFXQOQAjs.Content; exports.ContentFields = _chunkYKFXQOQAjs.ContentFields; exports.ContentModule = _chunkYKFXQOQAjs.ContentModule; exports.ContentService = _chunkYKFXQOQAjs.ContentService; exports.DEFAULT_GRANT_TYPES = _chunkYKFXQOQAjs.DEFAULT_GRANT_TYPES; exports.DataClass = _chunkPFAZPP54js.DataClassRegistry; exports.DataClassRegistry = _chunkPFAZPP54js.DataClassRegistry; exports.EndpointCreator = _chunkYKFXQOQAjs.EndpointCreator; exports.EntityAiStatus = _chunkYKFXQOQAjs.EntityAiStatus; exports.Feature = _chunkYKFXQOQAjs.Feature; exports.FeatureModule = _chunkYKFXQOQAjs.FeatureModule; exports.FeatureService = _chunkYKFXQOQAjs.FeatureService; exports.HowTo = _chunkYKFXQOQAjs.HowTo; exports.HowToFields = _chunkYKFXQOQAjs.HowToFields; exports.HowToModule = _chunkYKFXQOQAjs.HowToModule; exports.HowToService = _chunkYKFXQOQAjs.HowToService; exports.HttpMethod = _chunkYKFXQOQAjs.HttpMethod; exports.InvoiceStatus = _chunkYKFXQOQAjs.InvoiceStatus; exports.JsonApiDataFactory = _chunkPFAZPP54js.JsonApiDataFactory; exports.MOBILE_BREAKPOINT = _chunkYKFXQOQAjs.MOBILE_BREAKPOINT; exports.Module = _chunkYKFXQOQAjs.Module; exports.ModuleModule = _chunkYKFXQOQAjs.ModuleModule; exports.ModulePaths = _chunkYKFXQOQAjs.ModulePaths; exports.ModulePathsModule = _chunkYKFXQOQAjs.ModulePathsModule; exports.ModuleRegistrar = _chunkYKFXQOQAjs.ModuleRegistrar; exports.ModuleRegistry = _chunkYKFXQOQAjs.ModuleRegistry; exports.Modules = _chunkYKFXQOQAjs.Modules; exports.Notification = _chunkYKFXQOQAjs.Notification; exports.NotificationFields = _chunkYKFXQOQAjs.NotificationFields; exports.NotificationModule = _chunkYKFXQOQAjs.NotificationModule; exports.NotificationService = _chunkYKFXQOQAjs.NotificationService; exports.OAUTH_SCOPE_DISPLAY = _chunkYKFXQOQAjs.OAUTH_SCOPE_DISPLAY; exports.OAuthClient = _chunkYKFXQOQAjs.OAuthClient; exports.OAuthModule = _chunkYKFXQOQAjs.OAuthModule; exports.OAuthService = _chunkYKFXQOQAjs.OAuthService; exports.Passkey = _chunkYKFXQOQAjs.Passkey; exports.PasskeyAuthenticationOptions = _chunkYKFXQOQAjs.PasskeyAuthenticationOptions; exports.PasskeyAuthenticationOptionsModule = _chunkYKFXQOQAjs.PasskeyAuthenticationOptionsModule; exports.PasskeyModule = _chunkYKFXQOQAjs.PasskeyModule; exports.PasskeyRegistrationOptions = _chunkYKFXQOQAjs.PasskeyRegistrationOptions; exports.PasskeyRegistrationOptionsModule = _chunkYKFXQOQAjs.PasskeyRegistrationOptionsModule; exports.PasskeyRegistrationVerify = _chunkYKFXQOQAjs.PasskeyRegistrationVerify; exports.PasskeyRegistrationVerifyModule = _chunkYKFXQOQAjs.PasskeyRegistrationVerifyModule; exports.PasskeyRename = _chunkYKFXQOQAjs.PasskeyRename; exports.PasskeyRenameModule = _chunkYKFXQOQAjs.PasskeyRenameModule; exports.PasskeyVerifyLogin = _chunkYKFXQOQAjs.PasskeyVerifyLogin; exports.PasskeyVerifyLoginModule = _chunkYKFXQOQAjs.PasskeyVerifyLoginModule; exports.PaymentMethod = _chunkYKFXQOQAjs.PaymentMethod; exports.PermissionMapping = _chunkYKFXQOQAjs.PermissionMapping; exports.PermissionMappingModule = _chunkYKFXQOQAjs.PermissionMappingModule; exports.Push = _chunkYKFXQOQAjs.Push; exports.PushModule = _chunkYKFXQOQAjs.PushModule; exports.PushService = _chunkYKFXQOQAjs.PushService; exports.RbacMatrixModel = _chunkYKFXQOQAjs.RbacMatrixModel; exports.RbacMatrixModule = _chunkYKFXQOQAjs.RbacMatrixModule; exports.RbacService = _chunkUYENG3GTjs.RbacService; exports.ReferralModule = _chunkYKFXQOQAjs.ReferralModule; exports.ReferralService = _chunkYKFXQOQAjs.ReferralService; exports.ReferralStats = _chunkYKFXQOQAjs.ReferralStats; exports.ReferralStatsModule = _chunkYKFXQOQAjs.ReferralStatsModule; exports.RehydrationFactory = _chunkYKFXQOQAjs.RehydrationFactory; exports.Role = _chunkYKFXQOQAjs.Role; exports.RoleFields = _chunkYKFXQOQAjs.RoleFields; exports.RoleModule = _chunkYKFXQOQAjs.RoleModule; exports.RoleService = _chunkYKFXQOQAjs.RoleService; exports.S3 = _chunkYKFXQOQAjs.S3; exports.S3Module = _chunkYKFXQOQAjs.S3Module; exports.S3Service = _chunkYKFXQOQAjs.S3Service; exports.StripeCustomer = _chunkYKFXQOQAjs.StripeCustomer; exports.StripeCustomerModule = _chunkYKFXQOQAjs.StripeCustomerModule; exports.StripeCustomerService = _chunkYKFXQOQAjs.StripeCustomerService; exports.StripeInvoice = _chunkYKFXQOQAjs.StripeInvoice; exports.StripeInvoiceModule = _chunkYKFXQOQAjs.StripeInvoiceModule; exports.StripeInvoiceService = _chunkYKFXQOQAjs.StripeInvoiceService; exports.StripePaymentMethodModule = _chunkYKFXQOQAjs.StripePaymentMethodModule; exports.StripePrice = _chunkYKFXQOQAjs.StripePrice; exports.StripePriceFields = _chunkYKFXQOQAjs.StripePriceFields; exports.StripePriceModule = _chunkYKFXQOQAjs.StripePriceModule; exports.StripePriceService = _chunkYKFXQOQAjs.StripePriceService; exports.StripeProduct = _chunkYKFXQOQAjs.StripeProduct; exports.StripeProductFields = _chunkYKFXQOQAjs.StripeProductFields; exports.StripeProductModule = _chunkYKFXQOQAjs.StripeProductModule; exports.StripeProductService = _chunkYKFXQOQAjs.StripeProductService; exports.StripePromotionCode = _chunkYKFXQOQAjs.StripePromotionCode; exports.StripePromotionCodeModule = _chunkYKFXQOQAjs.StripePromotionCodeModule; exports.StripePromotionCodeService = _chunkYKFXQOQAjs.StripePromotionCodeService; exports.StripeSubscription = _chunkYKFXQOQAjs.StripeSubscription; exports.StripeSubscriptionModule = _chunkYKFXQOQAjs.StripeSubscriptionModule; exports.StripeSubscriptionService = _chunkYKFXQOQAjs.StripeSubscriptionService; exports.StripeUsage = _chunkYKFXQOQAjs.StripeUsage; exports.StripeUsageModule = _chunkYKFXQOQAjs.StripeUsageModule; exports.StripeUsageService = _chunkYKFXQOQAjs.StripeUsageService; exports.SubscriptionStatus = _chunkYKFXQOQAjs.SubscriptionStatus; exports.TableOptions = _chunkYKFXQOQAjs.TableOptions; exports.TokenUsageAdminBreakdownModule = _chunkYKFXQOQAjs.TokenUsageAdminBreakdownModule; exports.TokenUsageAdminSummaryModule = _chunkYKFXQOQAjs.TokenUsageAdminSummaryModule; exports.TokenUsageAdminTimelineModule = _chunkYKFXQOQAjs.TokenUsageAdminTimelineModule; exports.TotpAuthenticator = _chunkYKFXQOQAjs.TotpAuthenticator; exports.TotpAuthenticatorModule = _chunkYKFXQOQAjs.TotpAuthenticatorModule; exports.TotpSetup = _chunkYKFXQOQAjs.TotpSetup; exports.TotpSetupModule = _chunkYKFXQOQAjs.TotpSetupModule; exports.TotpVerify = _chunkYKFXQOQAjs.TotpVerify; exports.TotpVerifyLogin = _chunkYKFXQOQAjs.TotpVerifyLogin; exports.TotpVerifyLoginModule = _chunkYKFXQOQAjs.TotpVerifyLoginModule; exports.TotpVerifyModule = _chunkYKFXQOQAjs.TotpVerifyModule; exports.TwoFactorChallenge = _chunkYKFXQOQAjs.TwoFactorChallenge; exports.TwoFactorChallengeModule = _chunkYKFXQOQAjs.TwoFactorChallengeModule; exports.TwoFactorEnable = _chunkYKFXQOQAjs.TwoFactorEnable; exports.TwoFactorEnableModule = _chunkYKFXQOQAjs.TwoFactorEnableModule; exports.TwoFactorService = _chunkYKFXQOQAjs.TwoFactorService; exports.TwoFactorStatus = _chunkYKFXQOQAjs.TwoFactorStatus; exports.TwoFactorStatusModule = _chunkYKFXQOQAjs.TwoFactorStatusModule; exports.User = _chunkYKFXQOQAjs.User; exports.UserFields = _chunkYKFXQOQAjs.UserFields; exports.UserModule = _chunkYKFXQOQAjs.UserModule; exports.UserService = _chunkYKFXQOQAjs.UserService; exports.VIEWPORT_COOKIE_NAME = _chunkYKFXQOQAjs.VIEWPORT_COOKIE_NAME; exports.Waitlist = _chunkYKFXQOQAjs.Waitlist; exports.WaitlistModule = _chunkYKFXQOQAjs.WaitlistModule; exports.WaitlistService = _chunkYKFXQOQAjs.WaitlistService; exports.WaitlistStats = _chunkYKFXQOQAjs.WaitlistStats; exports.WaitlistStatsModule = _chunkYKFXQOQAjs.WaitlistStatsModule; exports.checkPermissions = _chunkYKFXQOQAjs.checkPermissions; exports.checkPermissionsFromServer = _chunkYKFXQOQAjs.checkPermissionsFromServer; exports.clearLastApiMeta = _chunkYKFXQOQAjs.clearLastApiMeta; exports.clearLastApiTotal = _chunkYKFXQOQAjs.clearLastApiTotal; exports.cn = _chunkYKFXQOQAjs.cn; exports.composeRefs = _chunkYKFXQOQAjs.composeRefs; exports.configureAuth = _chunkYKFXQOQAjs.configureAuth; exports.configureI18n = _chunkUYENG3GTjs.configureI18n; exports.configureJsonApi = _chunkUYENG3GTjs.configureJsonApi; exports.configureLogin = _chunkUYENG3GTjs.configureLogin; exports.configureReferral = _chunkUYENG3GTjs.configureReferral; exports.configureRoles = _chunkUYENG3GTjs.configureRoles; exports.configureTokenUsage = _chunkYKFXQOQAjs.configureTokenUsage; exports.configureWaitlist = _chunkUYENG3GTjs.configureWaitlist; exports.createJsonApiInclusion = _chunkYKFXQOQAjs.createJsonApiInclusion; exports.dismissToast = _chunkYKFXQOQAjs.dismissToast; exports.entityObjectSchema = _chunkYKFXQOQAjs.entityObjectSchema; exports.exists = _chunkYKFXQOQAjs.exists; exports.formatCodiceFiscale = _chunkYKFXQOQAjs.formatCodiceFiscale; exports.formatDate = _chunkYKFXQOQAjs.formatDate; exports.formatLocalDate = _chunkYKFXQOQAjs.formatLocalDate; exports.formatPartitaIva = _chunkYKFXQOQAjs.formatPartitaIva; exports.getApiUrl = _chunkUYENG3GTjs.getApiUrl; exports.getAppUrl = _chunkUYENG3GTjs.getAppUrl; exports.getBootstrapper = _chunkPFAZPP54js.getBootstrapper; exports.getClientGlobalErrorHandler = _chunkYKFXQOQAjs.getClientGlobalErrorHandler; exports.getGlobalErrorHandler = _chunkYKFXQOQAjs.getGlobalErrorHandler; exports.getIcon = _chunkYKFXQOQAjs.getIcon; exports.getIconByModule = _chunkYKFXQOQAjs.getIconByModule; exports.getIconByModuleName = _chunkYKFXQOQAjs.getIconByModuleName; exports.getInitials = _chunkYKFXQOQAjs.getInitials; exports.getLastApiMeta = _chunkYKFXQOQAjs.getLastApiMeta; exports.getLastApiTotal = _chunkYKFXQOQAjs.getLastApiTotal; exports.getLucideIcon = _chunkYKFXQOQAjs.getLucideIcon; exports.getLucideIconByModule = _chunkYKFXQOQAjs.getLucideIconByModule; exports.getLucideIconByModuleName = _chunkYKFXQOQAjs.getLucideIconByModuleName; exports.getPublicApiUrl = _chunkUYENG3GTjs.getPublicApiUrl; exports.getReferralConfig = _chunkUYENG3GTjs.getReferralConfig; exports.getRoleId = _chunkUYENG3GTjs.getRoleId; exports.getStripePublishableKey = _chunkUYENG3GTjs.getStripePublishableKey; exports.getTableComponents = _chunkYKFXQOQAjs.getTableComponents; exports.getTableOptions = _chunkYKFXQOQAjs.getTableOptions; exports.getTokenHandler = _chunkYKFXQOQAjs.getTokenHandler; exports.getTokenUsageCurrency = _chunkYKFXQOQAjs.getTokenUsageCurrency; exports.getTrackablePages = _chunkUYENG3GTjs.getTrackablePages; exports.getValueFromPath = _chunkYKFXQOQAjs.getValueFromPath; exports.getWaitlistConfig = _chunkUYENG3GTjs.getWaitlistConfig; exports.hasBootstrapper = _chunkPFAZPP54js.hasBootstrapper; exports.isReferralEnabled = _chunkUYENG3GTjs.isReferralEnabled; exports.isRemoteImageSrc = _chunkYKFXQOQAjs.isRemoteImageSrc; exports.isRolesConfigured = _chunkUYENG3GTjs.isRolesConfigured; exports.rehydrate = _chunkYKFXQOQAjs.rehydrate; exports.rehydrateList = _chunkYKFXQOQAjs.rehydrateList; exports.resetBootstrapStore = _chunkPFAZPP54js.resetBootstrapStore; exports.setBootstrapper = _chunkPFAZPP54js.setBootstrapper; exports.setClientGlobalErrorHandler = _chunkYKFXQOQAjs.setClientGlobalErrorHandler; exports.setGlobalErrorHandler = _chunkYKFXQOQAjs.setGlobalErrorHandler; exports.showCustomToast = _chunkYKFXQOQAjs.showCustomToast; exports.showError = _chunkYKFXQOQAjs.showError; exports.showToast = _chunkYKFXQOQAjs.showToast; exports.tokenUsageModules = _chunkYKFXQOQAjs.tokenUsageModules; exports.translateData = _chunkPFAZPP54js.translateData; exports.translateResponse = _chunkPFAZPP54js.translateResponse; exports.tryBootstrap = _chunkPFAZPP54js.tryBootstrap; exports.useComposedRefs = _chunkYKFXQOQAjs.useComposedRefs; exports.useIsMobile = _chunkYKFXQOQAjs.useIsMobile; exports.userObjectSchema = _chunkYKFXQOQAjs.userObjectSchema; exports.validateCodiceFiscale = _chunkYKFXQOQAjs.validateCodiceFiscale; exports.validateItalianTaxCode = _chunkYKFXQOQAjs.validateItalianTaxCode; exports.validatePartitaIva = _chunkYKFXQOQAjs.validatePartitaIva;
479
479
  //# sourceMappingURL=index.js.map
package/dist/index.mjs CHANGED
@@ -18,7 +18,7 @@ import {
18
18
  getWaitlistConfig,
19
19
  isReferralEnabled,
20
20
  isRolesConfigured
21
- } from "./chunk-ZMYZFQN3.mjs";
21
+ } from "./chunk-LCMVARSP.mjs";
22
22
  import {
23
23
  AVAILABLE_OAUTH_SCOPES,
24
24
  AbstractApiData,
@@ -225,7 +225,7 @@ import {
225
225
  validateCodiceFiscale,
226
226
  validateItalianTaxCode,
227
227
  validatePartitaIva
228
- } from "./chunk-CGJW7ZZM.mjs";
228
+ } from "./chunk-PGARO3JT.mjs";
229
229
  import "./chunk-AUXK7QSA.mjs";
230
230
  import "./chunk-C7C7VY4F.mjs";
231
231
  import {
@@ -9,6 +9,7 @@ type CompanyInput = {
9
9
  monthlyCredits?: number;
10
10
  availableMonthlyCredits?: number;
11
11
  availableExtraCredits?: number;
12
+ aiEnabled?: boolean;
12
13
  featureIds?: string[];
13
14
  moduleIds?: string[];
14
15
  legal_address?: string;
@@ -31,6 +32,11 @@ interface CompanyInterface extends ApiDataInterface {
31
32
  get monthlyCredits(): number;
32
33
  get availableMonthlyCredits(): number;
33
34
  get availableExtraCredits(): number;
35
+ /**
36
+ * Whether this company's plan carries AI. Non-optional: `rehydrate()`
37
+ * defaults an absent attribute to `true`, so the getter always has a value.
38
+ */
39
+ get aiEnabled(): boolean;
34
40
  get features(): FeatureInterface[];
35
41
  get modules(): ModuleInterface[];
36
42
  get legal_address(): string | undefined;
@@ -9,6 +9,7 @@ type CompanyInput = {
9
9
  monthlyCredits?: number;
10
10
  availableMonthlyCredits?: number;
11
11
  availableExtraCredits?: number;
12
+ aiEnabled?: boolean;
12
13
  featureIds?: string[];
13
14
  moduleIds?: string[];
14
15
  legal_address?: string;
@@ -31,6 +32,11 @@ interface CompanyInterface extends ApiDataInterface {
31
32
  get monthlyCredits(): number;
32
33
  get availableMonthlyCredits(): number;
33
34
  get availableExtraCredits(): number;
35
+ /**
36
+ * Whether this company's plan carries AI. Non-optional: `rehydrate()`
37
+ * defaults an absent attribute to `true`, so the getter always has a value.
38
+ */
39
+ get aiEnabled(): boolean;
34
40
  get features(): FeatureInterface[];
35
41
  get modules(): ModuleInterface[];
36
42
  get legal_address(): string | undefined;
@@ -1,8 +1,8 @@
1
1
  import { A as AbstractService, N as NextRef, P as PreviousRef } from './AbstractService-B0T7h8fX.mjs';
2
2
  import { F as FeatureInterface } from './feature.interface-CXb1-vNq.mjs';
3
- import { e as RoleInterface, U as UserInterface, f as UserInput, c as CompanyInterface, b as CompanyInput, C as ContentInterface, N as NotificationInterface } from './notification.interface-CG1vqoxg.mjs';
3
+ import { e as RoleInterface, U as UserInterface, f as UserInput, c as CompanyInterface, b as CompanyInput, C as ContentInterface, N as NotificationInterface } from './notification.interface-BWOCvKRP.mjs';
4
4
  import { A as ApiDataInterface, J as JsonApiHydratedDataInterface } from './ApiDataInterface-BcZeXy5X.mjs';
5
- import { A as AuthInput, b as AuthInterface } from './auth.interface-CkmZqat3.mjs';
5
+ import { A as AuthInput, b as AuthInterface } from './auth.interface-jYD8Gc4P.mjs';
6
6
 
7
7
  declare class FeatureService extends AbstractService {
8
8
  static findMany(params: {
@@ -1,8 +1,8 @@
1
1
  import { A as AbstractService, N as NextRef, P as PreviousRef } from './AbstractService-Cew0PD0L.js';
2
2
  import { F as FeatureInterface } from './feature.interface-BO25VLlx.js';
3
- import { e as RoleInterface, U as UserInterface, f as UserInput, c as CompanyInterface, b as CompanyInput, C as ContentInterface, N as NotificationInterface } from './notification.interface--27exGde.js';
3
+ import { e as RoleInterface, U as UserInterface, f as UserInput, c as CompanyInterface, b as CompanyInput, C as ContentInterface, N as NotificationInterface } from './notification.interface-DYF56CtE.js';
4
4
  import { A as ApiDataInterface, J as JsonApiHydratedDataInterface } from './ApiDataInterface-BcZeXy5X.js';
5
- import { A as AuthInput, b as AuthInterface } from './auth.interface-COmBjh89.js';
5
+ import { A as AuthInput, b as AuthInterface } from './auth.interface-B6ZQLGjS.js';
6
6
 
7
7
  declare class FeatureService extends AbstractService {
8
8
  static findMany(params: {
@@ -2,13 +2,13 @@ import { A as ApiData } from '../ApiData-DPKNfY-9.mjs';
2
2
  import { M as ModuleWithPermissions, A as Action } from '../types-Bq_UA8Lg.mjs';
3
3
  import { A as ApiRequestDataTypeInterface } from '../ApiRequestDataTypeInterface-CYEcRUrh.mjs';
4
4
  import { A as ApiResponseInterface } from '../ApiResponseInterface-rsXRL_Hn.mjs';
5
- export { A as ServerAuthService, C as ServerCompanyService, a as ServerContentService, F as ServerFeatureService, N as ServerNotificationService, P as ServerPushService, R as ServerRoleService, S as ServerS3Service, U as ServerUserService } from '../s3.service-Dt6MfuHr.mjs';
5
+ export { A as ServerAuthService, C as ServerCompanyService, a as ServerContentService, F as ServerFeatureService, N as ServerNotificationService, P as ServerPushService, R as ServerRoleService, S as ServerS3Service, U as ServerUserService } from '../s3.service-D_dswjgz.mjs';
6
6
  import 'lucide-react';
7
7
  import '../ApiDataInterface-BcZeXy5X.mjs';
8
8
  import '../AbstractService-B0T7h8fX.mjs';
9
9
  import '../feature.interface-CXb1-vNq.mjs';
10
- import '../notification.interface-CG1vqoxg.mjs';
11
- import '../auth.interface-CkmZqat3.mjs';
10
+ import '../notification.interface-BWOCvKRP.mjs';
11
+ import '../auth.interface-jYD8Gc4P.mjs';
12
12
 
13
13
  type CacheProfile = "seconds" | "minutes" | "hours" | "days" | "weeks" | "max" | "default";
14
14
  /**
@@ -2,13 +2,13 @@ import { A as ApiData } from '../ApiData-DPKNfY-9.js';
2
2
  import { M as ModuleWithPermissions, A as Action } from '../types-bsm8Fp55.js';
3
3
  import { A as ApiRequestDataTypeInterface } from '../ApiRequestDataTypeInterface-CYEcRUrh.js';
4
4
  import { A as ApiResponseInterface } from '../ApiResponseInterface-CWLvSCvS.js';
5
- export { A as ServerAuthService, C as ServerCompanyService, a as ServerContentService, F as ServerFeatureService, N as ServerNotificationService, P as ServerPushService, R as ServerRoleService, S as ServerS3Service, U as ServerUserService } from '../s3.service-CpwA3sl_.js';
5
+ export { A as ServerAuthService, C as ServerCompanyService, a as ServerContentService, F as ServerFeatureService, N as ServerNotificationService, P as ServerPushService, R as ServerRoleService, S as ServerS3Service, U as ServerUserService } from '../s3.service-DserU9VK.js';
6
6
  import 'lucide-react';
7
7
  import '../ApiDataInterface-BcZeXy5X.js';
8
8
  import '../AbstractService-Cew0PD0L.js';
9
9
  import '../feature.interface-BO25VLlx.js';
10
- import '../notification.interface--27exGde.js';
11
- import '../auth.interface-COmBjh89.js';
10
+ import '../notification.interface-DYF56CtE.js';
11
+ import '../auth.interface-B6ZQLGjS.js';
12
12
 
13
13
  type CacheProfile = "seconds" | "minutes" | "hours" | "days" | "weeks" | "max" | "default";
14
14
  /**
@@ -15,7 +15,7 @@ var _chunkIOLU4ASDjs = require('../chunk-IOLU4ASD.js');
15
15
 
16
16
 
17
17
 
18
- var _chunkYUXCJ35Vjs = require('../chunk-YUXCJ35V.js');
18
+ var _chunkYKFXQOQAjs = require('../chunk-YKFXQOQA.js');
19
19
  require('../chunk-LXKSUWAV.js');
20
20
  require('../chunk-IBS6NI7D.js');
21
21
 
@@ -86,7 +86,7 @@ var ServerSession = class {
86
86
  if (!rawModules) return false;
87
87
  const modules = JSON.parse(_pako.ungzip.call(void 0, Buffer.from(rawModules, "base64"), { toText: true }));
88
88
  const selectedModule = modules.find((module) => module.id === params.module.moduleId);
89
- return _chunkYUXCJ35Vjs.checkPermissionsFromServer.call(void 0, {
89
+ return _chunkYKFXQOQAjs.checkPermissionsFromServer.call(void 0, {
90
90
  module: params.module,
91
91
  action: params.action,
92
92
  data: params.data,
@@ -296,5 +296,5 @@ _chunk7QVYU63Ejs.__name.call(void 0, ServerJsonApiDelete, "ServerJsonApiDelete")
296
296
 
297
297
 
298
298
 
299
- exports.ServerAuthService = _chunkYUXCJ35Vjs.AuthService; exports.ServerCompanyService = _chunkYUXCJ35Vjs.CompanyService; exports.ServerContentService = _chunkYUXCJ35Vjs.ContentService; exports.ServerFeatureService = _chunkYUXCJ35Vjs.FeatureService; exports.ServerJsonApiDelete = ServerJsonApiDelete; exports.ServerJsonApiGet = ServerJsonApiGet; exports.ServerJsonApiPatch = ServerJsonApiPatch; exports.ServerJsonApiPost = ServerJsonApiPost; exports.ServerJsonApiPut = ServerJsonApiPut; exports.ServerNotificationService = _chunkYUXCJ35Vjs.NotificationService; exports.ServerPushService = _chunkYUXCJ35Vjs.PushService; exports.ServerRoleService = _chunkYUXCJ35Vjs.RoleService; exports.ServerS3Service = _chunkYUXCJ35Vjs.S3Service; exports.ServerSession = ServerSession; exports.ServerUserService = _chunkYUXCJ35Vjs.UserService; exports.configureServerJsonApi = configureServerJsonApi; exports.getServerApiUrl = getServerApiUrl; exports.getServerAppUrl = getServerAppUrl; exports.getServerToken = _chunkYUO55Q5Ajs.getServerToken; exports.getServerTrackablePages = getServerTrackablePages; exports.invalidateCacheTag = invalidateCacheTag; exports.invalidateCacheTags = invalidateCacheTags; exports.serverRequest = _chunkIOLU4ASDjs.serverRequest;
299
+ exports.ServerAuthService = _chunkYKFXQOQAjs.AuthService; exports.ServerCompanyService = _chunkYKFXQOQAjs.CompanyService; exports.ServerContentService = _chunkYKFXQOQAjs.ContentService; exports.ServerFeatureService = _chunkYKFXQOQAjs.FeatureService; exports.ServerJsonApiDelete = ServerJsonApiDelete; exports.ServerJsonApiGet = ServerJsonApiGet; exports.ServerJsonApiPatch = ServerJsonApiPatch; exports.ServerJsonApiPost = ServerJsonApiPost; exports.ServerJsonApiPut = ServerJsonApiPut; exports.ServerNotificationService = _chunkYKFXQOQAjs.NotificationService; exports.ServerPushService = _chunkYKFXQOQAjs.PushService; exports.ServerRoleService = _chunkYKFXQOQAjs.RoleService; exports.ServerS3Service = _chunkYKFXQOQAjs.S3Service; exports.ServerSession = ServerSession; exports.ServerUserService = _chunkYKFXQOQAjs.UserService; exports.configureServerJsonApi = configureServerJsonApi; exports.getServerApiUrl = getServerApiUrl; exports.getServerAppUrl = getServerAppUrl; exports.getServerToken = _chunkYUO55Q5Ajs.getServerToken; exports.getServerTrackablePages = getServerTrackablePages; exports.invalidateCacheTag = invalidateCacheTag; exports.invalidateCacheTags = invalidateCacheTags; exports.serverRequest = _chunkIOLU4ASDjs.serverRequest;
300
300
  //# sourceMappingURL=index.js.map
@@ -15,7 +15,7 @@ import {
15
15
  S3Service,
16
16
  UserService,
17
17
  checkPermissionsFromServer
18
- } from "../chunk-CGJW7ZZM.mjs";
18
+ } from "../chunk-PGARO3JT.mjs";
19
19
  import "../chunk-AUXK7QSA.mjs";
20
20
  import "../chunk-C7C7VY4F.mjs";
21
21
  import {
@@ -1,4 +1,4 @@
1
- import { N as NotificationInterface } from './notification.interface-CG1vqoxg.mjs';
1
+ import { N as NotificationInterface } from './notification.interface-BWOCvKRP.mjs';
2
2
 
3
3
  interface UseSocketOptions {
4
4
  token: string;
@@ -1,4 +1,4 @@
1
- import { N as NotificationInterface } from './notification.interface--27exGde.js';
1
+ import { N as NotificationInterface } from './notification.interface-DYF56CtE.js';
2
2
 
3
3
  interface UseSocketOptions {
4
4
  token: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@carlonicora/nextjs-jsonapi",
3
- "version": "3.2.0",
3
+ "version": "3.3.0",
4
4
  "description": "Next.js JSON:API client with server/client support and caching",
5
5
  "author": "Carlo Nicora",
6
6
  "license": "GPL-3.0-or-later",
@@ -74,7 +74,31 @@ function PriceEditorInternal({
74
74
  isTrial: z.boolean(),
75
75
  description: z.string().optional(),
76
76
  features: z.array(z.string()),
77
- token: z.string(),
77
+ // Normalised, not a bare `z.string()`: the field renders as
78
+ // `<FormInput type="number">`, which hands back a number, so a plain
79
+ // string schema rejects every value with "expected string, received
80
+ // number".
81
+ //
82
+ // Normalised by hand rather than with `z.coerce.string()`, because
83
+ // zod 4's coercion is `String(input)` — a cleared number input yields
84
+ // NaN, which would become the TRUTHY string "NaN" and reach
85
+ // `parseInt` as a NaN token.
86
+ //
87
+ // Deliberately NOT converted to the `z.preprocess(... z.number())`
88
+ // idiom used by unitAmount/intervalCount above. The whole token
89
+ // pipeline is string-based — seeded with `.toString()` and read back
90
+ // with `values.token ? parseInt(...)` on both submit branches — and a
91
+ // number pipeline would make `0` FALSY, silently dropping the token
92
+ // from the payload. A price with no token is "tokens not configured"
93
+ // (AI stays enabled), so that would make a zero-token / no-AI plan
94
+ // impossible to create from this form.
95
+ token: z.preprocess(
96
+ (value) =>
97
+ value === undefined || value === null || value === "" || (typeof value === "number" && Number.isNaN(value))
98
+ ? ""
99
+ : String(value),
100
+ z.string(),
101
+ ),
78
102
  featureIds: z.array(z.string()),
79
103
  }),
80
104
  [t],
@@ -11,6 +11,7 @@ export type CompanyInput = {
11
11
  monthlyCredits?: number;
12
12
  availableMonthlyCredits?: number;
13
13
  availableExtraCredits?: number;
14
+ aiEnabled?: boolean;
14
15
 
15
16
  featureIds?: string[];
16
17
  moduleIds?: string[];
@@ -38,6 +39,12 @@ export interface CompanyInterface extends ApiDataInterface {
38
39
  get availableMonthlyCredits(): number;
39
40
  get availableExtraCredits(): number;
40
41
 
42
+ /**
43
+ * Whether this company's plan carries AI. Non-optional: `rehydrate()`
44
+ * defaults an absent attribute to `true`, so the getter always has a value.
45
+ */
46
+ get aiEnabled(): boolean;
47
+
41
48
  get features(): FeatureInterface[];
42
49
  get modules(): ModuleInterface[];
43
50
  get legal_address(): string | undefined;
@@ -0,0 +1,40 @@
1
+ import { beforeAll, describe, expect, it } from "vitest";
2
+ import { ApiRequestDataTypeInterface } from "../../../core/interfaces/ApiRequestDataTypeInterface";
3
+ import { ModuleRegistry } from "../../../core/registry/ModuleRegistry";
4
+ import { Company } from "./company";
5
+
6
+ // ---------------------------------------------------------------------------
7
+ // Setup — Company.rehydrate() resolves Modules.Feature / Modules.Module
8
+ // through the real ModuleRegistry (for `_readIncluded`), so both must be
9
+ // registered even though this suite's fixtures carry no included data.
10
+ // ---------------------------------------------------------------------------
11
+ const registerIfAbsent = (key: string, module: ApiRequestDataTypeInterface) => {
12
+ try {
13
+ ModuleRegistry.get(key as any);
14
+ } catch {
15
+ ModuleRegistry.register(key, module);
16
+ }
17
+ };
18
+
19
+ beforeAll(() => {
20
+ registerIfAbsent("Company", { name: "companies", model: Company } as any);
21
+ registerIfAbsent("Feature", { name: "features", model: class {} } as any);
22
+ registerIfAbsent("Module", { name: "modules", model: class {} } as any);
23
+ });
24
+
25
+ describe("Company.aiEnabled", () => {
26
+ it("defaults to true when the attribute is absent", () => {
27
+ const company = new Company().rehydrate({ jsonApi: { attributes: {} } } as any);
28
+ expect(company.aiEnabled).toBe(true);
29
+ });
30
+
31
+ it("is false only when explicitly false", () => {
32
+ const company = new Company().rehydrate({ jsonApi: { attributes: { aiEnabled: false } } } as any);
33
+ expect(company.aiEnabled).toBe(false);
34
+ });
35
+
36
+ it("is true when explicitly true", () => {
37
+ const company = new Company().rehydrate({ jsonApi: { attributes: { aiEnabled: true } } } as any);
38
+ expect(company.aiEnabled).toBe(true);
39
+ });
40
+ });
@@ -14,6 +14,7 @@ export class Company extends AbstractApiData implements CompanyInterface {
14
14
  private _monthlyCredits: number = 0;
15
15
  private _availableMonthlyCredits: number = 0;
16
16
  private _availableExtraCredits: number = 0;
17
+ private _aiEnabled?: boolean;
17
18
 
18
19
  private _features?: FeatureInterface[];
19
20
  private _modules?: ModuleInterface[];
@@ -58,6 +59,10 @@ export class Company extends AbstractApiData implements CompanyInterface {
58
59
  return this._availableExtraCredits ?? 0;
59
60
  }
60
61
 
62
+ get aiEnabled(): boolean {
63
+ return this._aiEnabled ?? true;
64
+ }
65
+
61
66
  get features(): FeatureInterface[] {
62
67
  return this._features ?? [];
63
68
  }
@@ -123,6 +128,7 @@ export class Company extends AbstractApiData implements CompanyInterface {
123
128
  this._monthlyCredits = data.jsonApi.attributes.monthlyCredits ?? 0;
124
129
  this._availableMonthlyCredits = data.jsonApi.attributes.availableMonthlyCredits ?? 0;
125
130
  this._availableExtraCredits = data.jsonApi.attributes.availableExtraCredits ?? 0;
131
+ this._aiEnabled = data.jsonApi.attributes.aiEnabled ?? true;
126
132
 
127
133
  this._legal_address = data.jsonApi.attributes.legal_address;
128
134
  this._street_number = data.jsonApi.attributes.street_number;
@@ -161,6 +167,7 @@ export class Company extends AbstractApiData implements CompanyInterface {
161
167
  response.data.attributes.availableMonthlyCredits = data.availableMonthlyCredits;
162
168
  if (data.availableExtraCredits !== undefined)
163
169
  response.data.attributes.availableExtraCredits = data.availableExtraCredits;
170
+ if (data.aiEnabled !== undefined) response.data.attributes.aiEnabled = data.aiEnabled;
164
171
 
165
172
  if (data.legal_address !== undefined) response.data.attributes.legal_address = data.legal_address;
166
173
  if (data.street_number !== undefined) response.data.attributes.street_number = data.street_number;