@fluidframework/fluid-static 2.0.0-dev-rc.3.0.0.250606 → 2.0.0-dev-rc.3.0.0.253463

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 (58) hide show
  1. package/api-report/fluid-static.api.md +9 -9
  2. package/dist/fluid-static-alpha.d.ts +9 -9
  3. package/dist/fluid-static-beta.d.ts +9 -9
  4. package/dist/fluid-static-public.d.ts +9 -9
  5. package/dist/fluid-static-untrimmed.d.ts +9 -9
  6. package/dist/fluidContainer.d.ts +2 -1
  7. package/dist/fluidContainer.d.ts.map +1 -1
  8. package/dist/fluidContainer.js +1 -0
  9. package/dist/fluidContainer.js.map +1 -1
  10. package/dist/rootDataObject.d.ts +1 -1
  11. package/dist/rootDataObject.d.ts.map +1 -1
  12. package/dist/rootDataObject.js +8 -8
  13. package/dist/rootDataObject.js.map +1 -1
  14. package/dist/serviceAudience.d.ts +1 -1
  15. package/dist/serviceAudience.d.ts.map +1 -1
  16. package/dist/serviceAudience.js.map +1 -1
  17. package/dist/types.d.ts +7 -7
  18. package/dist/types.d.ts.map +1 -1
  19. package/dist/types.js.map +1 -1
  20. package/dist/utils.d.ts +1 -1
  21. package/dist/utils.d.ts.map +1 -1
  22. package/dist/utils.js +2 -2
  23. package/dist/utils.js.map +1 -1
  24. package/lib/fluid-static-alpha.d.ts +9 -9
  25. package/lib/fluid-static-beta.d.ts +9 -9
  26. package/lib/fluid-static-public.d.ts +9 -9
  27. package/lib/fluid-static-untrimmed.d.ts +9 -9
  28. package/lib/fluidContainer.d.ts +2 -1
  29. package/lib/fluidContainer.d.ts.map +1 -1
  30. package/lib/fluidContainer.js +1 -0
  31. package/lib/fluidContainer.js.map +1 -1
  32. package/lib/rootDataObject.d.ts +1 -1
  33. package/lib/rootDataObject.d.ts.map +1 -1
  34. package/lib/rootDataObject.js +3 -3
  35. package/lib/rootDataObject.js.map +1 -1
  36. package/lib/serviceAudience.d.ts +1 -1
  37. package/lib/serviceAudience.d.ts.map +1 -1
  38. package/lib/serviceAudience.js.map +1 -1
  39. package/lib/tsdoc-metadata.json +11 -0
  40. package/lib/types.d.ts +7 -7
  41. package/lib/types.d.ts.map +1 -1
  42. package/lib/types.js.map +1 -1
  43. package/lib/utils.d.ts +1 -1
  44. package/lib/utils.d.ts.map +1 -1
  45. package/lib/utils.js +1 -1
  46. package/lib/utils.js.map +1 -1
  47. package/package.json +18 -30
  48. package/src/fluidContainer.ts +3 -1
  49. package/src/rootDataObject.ts +8 -8
  50. package/src/serviceAudience.ts +3 -1
  51. package/src/types.ts +7 -7
  52. package/src/utils.ts +3 -2
  53. package/lib/test/fluidContainer.spec.js +0 -21
  54. package/lib/test/fluidContainer.spec.js.map +0 -1
  55. package/lib/test/types/validateFluidStaticPrevious.generated.js +0 -42
  56. package/lib/test/types/validateFluidStaticPrevious.generated.js.map +0 -1
  57. package/lib/test/utils.spec.js +0 -86
  58. package/lib/test/utils.spec.js.map +0 -1
@@ -1,42 +0,0 @@
1
- use_current_InterfaceDeclaration_ContainerSchema(get_old_InterfaceDeclaration_ContainerSchema());
2
- use_old_InterfaceDeclaration_ContainerSchema(
3
- // @ts-expect-error compatibility expected to be broken
4
- get_current_InterfaceDeclaration_ContainerSchema());
5
- use_current_TypeAliasDeclaration_DataObjectClass(get_old_TypeAliasDeclaration_DataObjectClass());
6
- use_old_TypeAliasDeclaration_DataObjectClass(get_current_TypeAliasDeclaration_DataObjectClass());
7
- use_current_InterfaceDeclaration_IConnection(get_old_InterfaceDeclaration_IConnection());
8
- use_old_InterfaceDeclaration_IConnection(get_current_InterfaceDeclaration_IConnection());
9
- use_current_InterfaceDeclaration_IFluidContainer(get_old_InterfaceDeclaration_IFluidContainer());
10
- use_old_InterfaceDeclaration_IFluidContainer(get_current_InterfaceDeclaration_IFluidContainer());
11
- use_current_InterfaceDeclaration_IFluidContainerEvents(get_old_InterfaceDeclaration_IFluidContainerEvents());
12
- use_old_InterfaceDeclaration_IFluidContainerEvents(get_current_InterfaceDeclaration_IFluidContainerEvents());
13
- use_current_InterfaceDeclaration_IMember(get_old_InterfaceDeclaration_IMember());
14
- use_old_InterfaceDeclaration_IMember(get_current_InterfaceDeclaration_IMember());
15
- use_current_InterfaceDeclaration_IProvideRootDataObject(get_old_InterfaceDeclaration_IProvideRootDataObject());
16
- use_old_InterfaceDeclaration_IProvideRootDataObject(get_current_InterfaceDeclaration_IProvideRootDataObject());
17
- use_current_InterfaceDeclaration_IRootDataObject(get_old_InterfaceDeclaration_IRootDataObject());
18
- use_old_InterfaceDeclaration_IRootDataObject(get_current_InterfaceDeclaration_IRootDataObject());
19
- use_current_InterfaceDeclaration_IServiceAudience(get_old_InterfaceDeclaration_IServiceAudience());
20
- use_old_InterfaceDeclaration_IServiceAudience(get_current_InterfaceDeclaration_IServiceAudience());
21
- use_current_InterfaceDeclaration_IServiceAudienceEvents(get_old_InterfaceDeclaration_IServiceAudienceEvents());
22
- use_old_InterfaceDeclaration_IServiceAudienceEvents(get_current_InterfaceDeclaration_IServiceAudienceEvents());
23
- use_current_TypeAliasDeclaration_InitialObjects(get_old_TypeAliasDeclaration_InitialObjects());
24
- use_old_TypeAliasDeclaration_InitialObjects(get_current_TypeAliasDeclaration_InitialObjects());
25
- use_current_TypeAliasDeclaration_LoadableObjectClass(get_old_TypeAliasDeclaration_LoadableObjectClass());
26
- use_old_TypeAliasDeclaration_LoadableObjectClass(get_current_TypeAliasDeclaration_LoadableObjectClass());
27
- use_current_TypeAliasDeclaration_LoadableObjectClassRecord(get_old_TypeAliasDeclaration_LoadableObjectClassRecord());
28
- use_old_TypeAliasDeclaration_LoadableObjectClassRecord(get_current_TypeAliasDeclaration_LoadableObjectClassRecord());
29
- use_current_TypeAliasDeclaration_LoadableObjectRecord(get_old_TypeAliasDeclaration_LoadableObjectRecord());
30
- use_old_TypeAliasDeclaration_LoadableObjectRecord(get_current_TypeAliasDeclaration_LoadableObjectRecord());
31
- use_current_TypeAliasDeclaration_MemberChangedListener(get_old_TypeAliasDeclaration_MemberChangedListener());
32
- use_old_TypeAliasDeclaration_MemberChangedListener(get_current_TypeAliasDeclaration_MemberChangedListener());
33
- use_current_TypeAliasDeclaration_Myself(get_old_TypeAliasDeclaration_Myself());
34
- use_old_TypeAliasDeclaration_Myself(get_current_TypeAliasDeclaration_Myself());
35
- use_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory(get_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory());
36
- use_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory(get_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory());
37
- use_current_FunctionDeclaration_createFluidContainer(get_old_FunctionDeclaration_createFluidContainer());
38
- use_old_FunctionDeclaration_createFluidContainer(get_current_FunctionDeclaration_createFluidContainer());
39
- use_current_FunctionDeclaration_createServiceAudience(get_old_FunctionDeclaration_createServiceAudience());
40
- use_old_FunctionDeclaration_createServiceAudience(get_current_FunctionDeclaration_createServiceAudience());
41
- export {};
42
- //# sourceMappingURL=validateFluidStaticPrevious.generated.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"validateFluidStaticPrevious.generated.js","sourceRoot":"","sources":["../../../src/test/types/validateFluidStaticPrevious.generated.ts"],"names":[],"mappings":"AAgCA,gDAAgD,CAC5C,4CAA4C,EAAE,CAAC,CAAC;AAWpD,4CAA4C;AACxC,uDAAuD;AACvD,gDAAgD,EAAE,CAAC,CAAC;AAWxD,gDAAgD,CAC5C,4CAA4C,EAAE,CAAC,CAAC;AAWpD,4CAA4C,CACxC,gDAAgD,EAAE,CAAC,CAAC;AAWxD,4CAA4C,CACxC,wCAAwC,EAAE,CAAC,CAAC;AAWhD,wCAAwC,CACpC,4CAA4C,EAAE,CAAC,CAAC;AAWpD,gDAAgD,CAC5C,4CAA4C,EAAE,CAAC,CAAC;AAWpD,4CAA4C,CACxC,gDAAgD,EAAE,CAAC,CAAC;AAWxD,sDAAsD,CAClD,kDAAkD,EAAE,CAAC,CAAC;AAW1D,kDAAkD,CAC9C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,CAAC,CAAC;AAWxD,gDAAgD,CAC5C,oDAAoD,EAAE,CAAC,CAAC;AAW5D,qDAAqD,CACjD,iDAAiD,EAAE,CAAC,CAAC;AAWzD,iDAAiD,CAC7C,qDAAqD,EAAE,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n/*\n * THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.\n * Generated by fluid-type-test-generator in @fluidframework/build-tools.\n */\nimport type * as old from \"@fluidframework/fluid-static-previous\";\nimport type * as current from \"../../index.js\";\n\n\n// See 'build-tools/src/type-test-generator/compatibility.ts' for more information.\ntype TypeOnly<T> = T extends number\n\t? number\n\t: T extends string\n\t? string\n\t: T extends boolean | bigint | symbol\n\t? T\n\t: {\n\t\t\t[P in keyof T]: TypeOnly<T[P]>;\n\t };\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_ContainerSchema\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_ContainerSchema():\n TypeOnly<old.ContainerSchema>;\ndeclare function use_current_InterfaceDeclaration_ContainerSchema(\n use: TypeOnly<current.ContainerSchema>): void;\nuse_current_InterfaceDeclaration_ContainerSchema(\n get_old_InterfaceDeclaration_ContainerSchema());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_ContainerSchema\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_ContainerSchema():\n TypeOnly<current.ContainerSchema>;\ndeclare function use_old_InterfaceDeclaration_ContainerSchema(\n use: TypeOnly<old.ContainerSchema>): void;\nuse_old_InterfaceDeclaration_ContainerSchema(\n // @ts-expect-error compatibility expected to be broken\n get_current_InterfaceDeclaration_ContainerSchema());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_DataObjectClass\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_DataObjectClass():\n TypeOnly<old.DataObjectClass<any>>;\ndeclare function use_current_TypeAliasDeclaration_DataObjectClass(\n use: TypeOnly<current.DataObjectClass>): void;\nuse_current_TypeAliasDeclaration_DataObjectClass(\n get_old_TypeAliasDeclaration_DataObjectClass());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_DataObjectClass\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_DataObjectClass():\n TypeOnly<current.DataObjectClass>;\ndeclare function use_old_TypeAliasDeclaration_DataObjectClass(\n use: TypeOnly<old.DataObjectClass<any>>): void;\nuse_old_TypeAliasDeclaration_DataObjectClass(\n get_current_TypeAliasDeclaration_DataObjectClass());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IConnection\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IConnection():\n TypeOnly<old.IConnection>;\ndeclare function use_current_InterfaceDeclaration_IConnection(\n use: TypeOnly<current.IConnection>): void;\nuse_current_InterfaceDeclaration_IConnection(\n get_old_InterfaceDeclaration_IConnection());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IConnection\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IConnection():\n TypeOnly<current.IConnection>;\ndeclare function use_old_InterfaceDeclaration_IConnection(\n use: TypeOnly<old.IConnection>): void;\nuse_old_InterfaceDeclaration_IConnection(\n get_current_InterfaceDeclaration_IConnection());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidContainer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IFluidContainer():\n TypeOnly<old.IFluidContainer>;\ndeclare function use_current_InterfaceDeclaration_IFluidContainer(\n use: TypeOnly<current.IFluidContainer>): void;\nuse_current_InterfaceDeclaration_IFluidContainer(\n get_old_InterfaceDeclaration_IFluidContainer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidContainer\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IFluidContainer():\n TypeOnly<current.IFluidContainer>;\ndeclare function use_old_InterfaceDeclaration_IFluidContainer(\n use: TypeOnly<old.IFluidContainer>): void;\nuse_old_InterfaceDeclaration_IFluidContainer(\n get_current_InterfaceDeclaration_IFluidContainer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidContainerEvents\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IFluidContainerEvents():\n TypeOnly<old.IFluidContainerEvents>;\ndeclare function use_current_InterfaceDeclaration_IFluidContainerEvents(\n use: TypeOnly<current.IFluidContainerEvents>): void;\nuse_current_InterfaceDeclaration_IFluidContainerEvents(\n get_old_InterfaceDeclaration_IFluidContainerEvents());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IFluidContainerEvents\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IFluidContainerEvents():\n TypeOnly<current.IFluidContainerEvents>;\ndeclare function use_old_InterfaceDeclaration_IFluidContainerEvents(\n use: TypeOnly<old.IFluidContainerEvents>): void;\nuse_old_InterfaceDeclaration_IFluidContainerEvents(\n get_current_InterfaceDeclaration_IFluidContainerEvents());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IMember\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IMember():\n TypeOnly<old.IMember>;\ndeclare function use_current_InterfaceDeclaration_IMember(\n use: TypeOnly<current.IMember>): void;\nuse_current_InterfaceDeclaration_IMember(\n get_old_InterfaceDeclaration_IMember());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IMember\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IMember():\n TypeOnly<current.IMember>;\ndeclare function use_old_InterfaceDeclaration_IMember(\n use: TypeOnly<old.IMember>): void;\nuse_old_InterfaceDeclaration_IMember(\n get_current_InterfaceDeclaration_IMember());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideRootDataObject\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IProvideRootDataObject():\n TypeOnly<old.IProvideRootDataObject>;\ndeclare function use_current_InterfaceDeclaration_IProvideRootDataObject(\n use: TypeOnly<current.IProvideRootDataObject>): void;\nuse_current_InterfaceDeclaration_IProvideRootDataObject(\n get_old_InterfaceDeclaration_IProvideRootDataObject());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IProvideRootDataObject\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IProvideRootDataObject():\n TypeOnly<current.IProvideRootDataObject>;\ndeclare function use_old_InterfaceDeclaration_IProvideRootDataObject(\n use: TypeOnly<old.IProvideRootDataObject>): void;\nuse_old_InterfaceDeclaration_IProvideRootDataObject(\n get_current_InterfaceDeclaration_IProvideRootDataObject());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IRootDataObject\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IRootDataObject():\n TypeOnly<old.IRootDataObject>;\ndeclare function use_current_InterfaceDeclaration_IRootDataObject(\n use: TypeOnly<current.IRootDataObject>): void;\nuse_current_InterfaceDeclaration_IRootDataObject(\n get_old_InterfaceDeclaration_IRootDataObject());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IRootDataObject\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IRootDataObject():\n TypeOnly<current.IRootDataObject>;\ndeclare function use_old_InterfaceDeclaration_IRootDataObject(\n use: TypeOnly<old.IRootDataObject>): void;\nuse_old_InterfaceDeclaration_IRootDataObject(\n get_current_InterfaceDeclaration_IRootDataObject());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IServiceAudience\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IServiceAudience():\n TypeOnly<old.IServiceAudience<any>>;\ndeclare function use_current_InterfaceDeclaration_IServiceAudience(\n use: TypeOnly<current.IServiceAudience<any>>): void;\nuse_current_InterfaceDeclaration_IServiceAudience(\n get_old_InterfaceDeclaration_IServiceAudience());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IServiceAudience\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IServiceAudience():\n TypeOnly<current.IServiceAudience<any>>;\ndeclare function use_old_InterfaceDeclaration_IServiceAudience(\n use: TypeOnly<old.IServiceAudience<any>>): void;\nuse_old_InterfaceDeclaration_IServiceAudience(\n get_current_InterfaceDeclaration_IServiceAudience());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IServiceAudienceEvents\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_InterfaceDeclaration_IServiceAudienceEvents():\n TypeOnly<old.IServiceAudienceEvents<any>>;\ndeclare function use_current_InterfaceDeclaration_IServiceAudienceEvents(\n use: TypeOnly<current.IServiceAudienceEvents<any>>): void;\nuse_current_InterfaceDeclaration_IServiceAudienceEvents(\n get_old_InterfaceDeclaration_IServiceAudienceEvents());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"InterfaceDeclaration_IServiceAudienceEvents\": {\"backCompat\": false}\n*/\ndeclare function get_current_InterfaceDeclaration_IServiceAudienceEvents():\n TypeOnly<current.IServiceAudienceEvents<any>>;\ndeclare function use_old_InterfaceDeclaration_IServiceAudienceEvents(\n use: TypeOnly<old.IServiceAudienceEvents<any>>): void;\nuse_old_InterfaceDeclaration_IServiceAudienceEvents(\n get_current_InterfaceDeclaration_IServiceAudienceEvents());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_InitialObjects\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_InitialObjects():\n TypeOnly<old.InitialObjects<any>>;\ndeclare function use_current_TypeAliasDeclaration_InitialObjects(\n use: TypeOnly<current.InitialObjects<any>>): void;\nuse_current_TypeAliasDeclaration_InitialObjects(\n get_old_TypeAliasDeclaration_InitialObjects());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_InitialObjects\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_InitialObjects():\n TypeOnly<current.InitialObjects<any>>;\ndeclare function use_old_TypeAliasDeclaration_InitialObjects(\n use: TypeOnly<old.InitialObjects<any>>): void;\nuse_old_TypeAliasDeclaration_InitialObjects(\n get_current_TypeAliasDeclaration_InitialObjects());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectClass\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_LoadableObjectClass():\n TypeOnly<old.LoadableObjectClass<any>>;\ndeclare function use_current_TypeAliasDeclaration_LoadableObjectClass(\n use: TypeOnly<current.LoadableObjectClass>): void;\nuse_current_TypeAliasDeclaration_LoadableObjectClass(\n get_old_TypeAliasDeclaration_LoadableObjectClass());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectClass\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_LoadableObjectClass():\n TypeOnly<current.LoadableObjectClass>;\ndeclare function use_old_TypeAliasDeclaration_LoadableObjectClass(\n use: TypeOnly<old.LoadableObjectClass<any>>): void;\nuse_old_TypeAliasDeclaration_LoadableObjectClass(\n get_current_TypeAliasDeclaration_LoadableObjectClass());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectClassRecord\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_LoadableObjectClassRecord():\n TypeOnly<old.LoadableObjectClassRecord>;\ndeclare function use_current_TypeAliasDeclaration_LoadableObjectClassRecord(\n use: TypeOnly<current.LoadableObjectClassRecord>): void;\nuse_current_TypeAliasDeclaration_LoadableObjectClassRecord(\n get_old_TypeAliasDeclaration_LoadableObjectClassRecord());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectClassRecord\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_LoadableObjectClassRecord():\n TypeOnly<current.LoadableObjectClassRecord>;\ndeclare function use_old_TypeAliasDeclaration_LoadableObjectClassRecord(\n use: TypeOnly<old.LoadableObjectClassRecord>): void;\nuse_old_TypeAliasDeclaration_LoadableObjectClassRecord(\n get_current_TypeAliasDeclaration_LoadableObjectClassRecord());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"RemovedTypeAliasDeclaration_LoadableObjectCtor\": {\"forwardCompat\": false}\n*/\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"RemovedTypeAliasDeclaration_LoadableObjectCtor\": {\"backCompat\": false}\n*/\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectRecord\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_LoadableObjectRecord():\n TypeOnly<old.LoadableObjectRecord>;\ndeclare function use_current_TypeAliasDeclaration_LoadableObjectRecord(\n use: TypeOnly<current.LoadableObjectRecord>): void;\nuse_current_TypeAliasDeclaration_LoadableObjectRecord(\n get_old_TypeAliasDeclaration_LoadableObjectRecord());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_LoadableObjectRecord\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_LoadableObjectRecord():\n TypeOnly<current.LoadableObjectRecord>;\ndeclare function use_old_TypeAliasDeclaration_LoadableObjectRecord(\n use: TypeOnly<old.LoadableObjectRecord>): void;\nuse_old_TypeAliasDeclaration_LoadableObjectRecord(\n get_current_TypeAliasDeclaration_LoadableObjectRecord());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_MemberChangedListener\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_MemberChangedListener():\n TypeOnly<old.MemberChangedListener<any>>;\ndeclare function use_current_TypeAliasDeclaration_MemberChangedListener(\n use: TypeOnly<current.MemberChangedListener<any>>): void;\nuse_current_TypeAliasDeclaration_MemberChangedListener(\n get_old_TypeAliasDeclaration_MemberChangedListener());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_MemberChangedListener\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_MemberChangedListener():\n TypeOnly<current.MemberChangedListener<any>>;\ndeclare function use_old_TypeAliasDeclaration_MemberChangedListener(\n use: TypeOnly<old.MemberChangedListener<any>>): void;\nuse_old_TypeAliasDeclaration_MemberChangedListener(\n get_current_TypeAliasDeclaration_MemberChangedListener());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_Myself\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_TypeAliasDeclaration_Myself():\n TypeOnly<old.Myself>;\ndeclare function use_current_TypeAliasDeclaration_Myself(\n use: TypeOnly<current.Myself>): void;\nuse_current_TypeAliasDeclaration_Myself(\n get_old_TypeAliasDeclaration_Myself());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"TypeAliasDeclaration_Myself\": {\"backCompat\": false}\n*/\ndeclare function get_current_TypeAliasDeclaration_Myself():\n TypeOnly<current.Myself>;\ndeclare function use_old_TypeAliasDeclaration_Myself(\n use: TypeOnly<old.Myself>): void;\nuse_old_TypeAliasDeclaration_Myself(\n get_current_TypeAliasDeclaration_Myself());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"RemovedTypeAliasDeclaration_SharedObjectClass\": {\"forwardCompat\": false}\n*/\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"RemovedTypeAliasDeclaration_SharedObjectClass\": {\"backCompat\": false}\n*/\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createDOProviderContainerRuntimeFactory\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory():\n TypeOnly<typeof old.createDOProviderContainerRuntimeFactory>;\ndeclare function use_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory(\n use: TypeOnly<typeof current.createDOProviderContainerRuntimeFactory>): void;\nuse_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory(\n get_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createDOProviderContainerRuntimeFactory\": {\"backCompat\": false}\n*/\ndeclare function get_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory():\n TypeOnly<typeof current.createDOProviderContainerRuntimeFactory>;\ndeclare function use_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory(\n use: TypeOnly<typeof old.createDOProviderContainerRuntimeFactory>): void;\nuse_old_FunctionDeclaration_createDOProviderContainerRuntimeFactory(\n get_current_FunctionDeclaration_createDOProviderContainerRuntimeFactory());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createFluidContainer\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_FunctionDeclaration_createFluidContainer():\n TypeOnly<typeof old.createFluidContainer>;\ndeclare function use_current_FunctionDeclaration_createFluidContainer(\n use: TypeOnly<typeof current.createFluidContainer>): void;\nuse_current_FunctionDeclaration_createFluidContainer(\n get_old_FunctionDeclaration_createFluidContainer());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createFluidContainer\": {\"backCompat\": false}\n*/\ndeclare function get_current_FunctionDeclaration_createFluidContainer():\n TypeOnly<typeof current.createFluidContainer>;\ndeclare function use_old_FunctionDeclaration_createFluidContainer(\n use: TypeOnly<typeof old.createFluidContainer>): void;\nuse_old_FunctionDeclaration_createFluidContainer(\n get_current_FunctionDeclaration_createFluidContainer());\n\n/*\n* Validate forward compat by using old type in place of current type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createServiceAudience\": {\"forwardCompat\": false}\n*/\ndeclare function get_old_FunctionDeclaration_createServiceAudience():\n TypeOnly<typeof old.createServiceAudience>;\ndeclare function use_current_FunctionDeclaration_createServiceAudience(\n use: TypeOnly<typeof current.createServiceAudience>): void;\nuse_current_FunctionDeclaration_createServiceAudience(\n get_old_FunctionDeclaration_createServiceAudience());\n\n/*\n* Validate back compat by using current type in place of old type\n* If breaking change required, add in package.json under typeValidation.broken:\n* \"FunctionDeclaration_createServiceAudience\": {\"backCompat\": false}\n*/\ndeclare function get_current_FunctionDeclaration_createServiceAudience():\n TypeOnly<typeof current.createServiceAudience>;\ndeclare function use_old_FunctionDeclaration_createServiceAudience(\n use: TypeOnly<typeof old.createServiceAudience>): void;\nuse_old_FunctionDeclaration_createServiceAudience(\n get_current_FunctionDeclaration_createServiceAudience());\n"]}
@@ -1,86 +0,0 @@
1
- /*!
2
- * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
- * Licensed under the MIT License.
4
- */
5
- import { strict as assert } from "node:assert";
6
- import { DataObject, DataObjectFactory } from "@fluidframework/aqueduct";
7
- import { MapFactory, SharedMap } from "@fluidframework/map";
8
- import { SharedString, SharedStringFactory } from "@fluidframework/sequence";
9
- import { parseDataObjectsFromSharedObjects } from "../utils.js";
10
- class TestDataObject extends DataObject {
11
- }
12
- TestDataObject.Name = "@fluid-example/test-data-object";
13
- TestDataObject.factory = new DataObjectFactory(TestDataObject.Name, TestDataObject, [], {});
14
- describe("parseDataObjectsFromSharedObjects", () => {
15
- it("should be able to handle basic DDS types", () => {
16
- const schema = {
17
- initialObjects: {
18
- map: SharedMap,
19
- text: SharedString,
20
- },
21
- };
22
- const [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);
23
- assert.strictEqual(registryEntries.length, 0, "We should have no registry entries");
24
- assert.strictEqual(sharedObjects.length, 2, "We should have 2 shared objects");
25
- const types = sharedObjects.map((item) => item.type);
26
- assert.strictEqual(types[0], MapFactory.Type, "SharedMap should be included");
27
- assert.strictEqual(types[1], SharedStringFactory.Type, "SharedString should be included");
28
- });
29
- it("should be able to handle dup DDS types", () => {
30
- const schema = {
31
- initialObjects: {
32
- map: SharedMap,
33
- text: SharedString,
34
- text2: SharedString,
35
- },
36
- };
37
- const [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);
38
- assert.strictEqual(registryEntries.length, 0, "We should have no registry entries");
39
- assert.strictEqual(sharedObjects.length, 2, "We should have 2 shared objects");
40
- const types = sharedObjects.map((item) => item.type);
41
- assert.strictEqual(types[0], MapFactory.Type, "SharedMap should be included");
42
- assert.strictEqual(types[1], SharedStringFactory.Type, "SharedString should be included");
43
- });
44
- it("should be able to handle Data Objects", () => {
45
- const schema = {
46
- initialObjects: {
47
- map: SharedMap,
48
- do: TestDataObject,
49
- },
50
- };
51
- const [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);
52
- assert.strictEqual(registryEntries.length, 1, "We should have one registry entry");
53
- assert.strictEqual(sharedObjects.length, 1, "We should have 1 shared object");
54
- const types = registryEntries.map((item) => item[0]);
55
- assert.strictEqual(types[0], TestDataObject.Name, "TestDataObject should be included");
56
- });
57
- it("should be able to dedup Data Objects", () => {
58
- const schema = {
59
- initialObjects: {
60
- map: SharedMap,
61
- do: TestDataObject,
62
- do2: TestDataObject,
63
- },
64
- };
65
- const [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);
66
- assert.strictEqual(registryEntries.length, 1, "We should have one registry entry");
67
- assert.strictEqual(sharedObjects.length, 1, "We should have 1 shared object");
68
- const types = registryEntries.map((item) => item[0]);
69
- assert.strictEqual(types[0], TestDataObject.Name, "TestDataObject should be included");
70
- });
71
- it("should be able to dedup Data Objects even if passed as dynamic types", () => {
72
- const schema = {
73
- initialObjects: {
74
- map: SharedMap,
75
- do: TestDataObject,
76
- },
77
- dynamicObjectTypes: [SharedString, TestDataObject],
78
- };
79
- const [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);
80
- assert.strictEqual(registryEntries.length, 1, "We should have one registry entry");
81
- assert.strictEqual(sharedObjects.length, 2, "We should have 2 shared object");
82
- const types = registryEntries.map((item) => item[0]);
83
- assert.strictEqual(types[0], TestDataObject.Name, "TestDataObject should be included");
84
- });
85
- });
86
- //# sourceMappingURL=utils.spec.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"utils.spec.js","sourceRoot":"","sources":["../../src/test/utils.spec.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,MAAM,IAAI,MAAM,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AACzE,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AAE7E,OAAO,EAAE,iCAAiC,EAAE,MAAM,aAAa,CAAC;AAEhE,MAAM,cAAe,SAAQ,UAAU;;AACf,mBAAI,GAAG,iCAAiC,CAAC;AAEzC,sBAAO,GAAG,IAAI,iBAAiB,CACrD,cAAc,CAAC,IAAI,EACnB,cAAc,EACd,EAAE,EACF,EAAE,CACF,CAAC;AAGH,QAAQ,CAAC,mCAAmC,EAAE,GAAG,EAAE;IAClD,EAAE,CAAC,0CAA0C,EAAE,GAAG,EAAE;QACnD,MAAM,MAAM,GAAG;YACd,cAAc,EAAE;gBACf,GAAG,EAAE,SAAS;gBACd,IAAI,EAAE,YAAY;aAClB;SACyB,CAAC;QAC5B,MAAM,CAAC,eAAe,EAAE,aAAa,CAAC,GAAG,iCAAiC,CAAC,MAAM,CAAC,CAAC;QAEnF,MAAM,CAAC,WAAW,CAAC,eAAe,CAAC,MAAM,EAAE,CAAC,EAAE,oCAAoC,CAAC,CAAC;QACpF,MAAM,CAAC,WAAW,CAAC,aAAa,CAAC,MAAM,EAAE,CAAC,EAAE,iCAAiC,CAAC,CAAC;QAE/E,MAAM,KAAK,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IA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AE;gBACf,GAAG,EAAE,SAAS;gBACd,EAAE,EAAE,cAAc;aAClB;YACD,kBAAkB,EAAE,CAAC,YAAY,EAAE,cAAc,CAAC;SACxB,CAAC;QAC5B,MAAM,CAAC,eAAe,EAAE,aAAa,CAAC,GAAG,iCAAiC,CAAC,MAAM,CAAC,CAAC;QAEnF,MAAM,CAAC,WAAW,CAAC,eAAe,CAAC,MAAM,EAAE,CAAC,EAAE,mCAAmC,CAAC,CAAC;QACnF,MAAM,CAAC,WAAW,CAAC,aAAa,CAAC,MAAM,EAAE,CAAC,EAAE,gCAAgC,CAAC,CAAC;QAE9E,MAAM,KAAK,GAAG,eAAe,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;QACrD,MAAM,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,cAAc,CAAC,IAAI,EAAE,mCAAmC,CAAC,CAAC;IACxF,CAAC,CAAC,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { strict as assert } from \"node:assert\";\nimport { DataObject, DataObjectFactory } from \"@fluidframework/aqueduct\";\nimport { MapFactory, SharedMap } from \"@fluidframework/map\";\nimport { SharedString, SharedStringFactory } from \"@fluidframework/sequence\";\nimport { type ContainerSchema } from \"../types.js\";\nimport { parseDataObjectsFromSharedObjects } from \"../utils.js\";\n\nclass TestDataObject extends DataObject {\n\tpublic static readonly Name = \"@fluid-example/test-data-object\";\n\n\tpublic static readonly factory = new DataObjectFactory(\n\t\tTestDataObject.Name,\n\t\tTestDataObject,\n\t\t[],\n\t\t{},\n\t);\n}\n\ndescribe(\"parseDataObjectsFromSharedObjects\", () => {\n\tit(\"should be able to handle basic DDS types\", () => {\n\t\tconst schema = {\n\t\t\tinitialObjects: {\n\t\t\t\tmap: SharedMap,\n\t\t\t\ttext: SharedString,\n\t\t\t},\n\t\t} satisfies ContainerSchema;\n\t\tconst [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);\n\n\t\tassert.strictEqual(registryEntries.length, 0, \"We should have no registry entries\");\n\t\tassert.strictEqual(sharedObjects.length, 2, \"We should have 2 shared objects\");\n\n\t\tconst types = sharedObjects.map((item) => item.type);\n\t\tassert.strictEqual(types[0], MapFactory.Type, \"SharedMap should be included\");\n\t\tassert.strictEqual(types[1], SharedStringFactory.Type, \"SharedString should be included\");\n\t});\n\n\tit(\"should be able to handle dup DDS types\", () => {\n\t\tconst schema = {\n\t\t\tinitialObjects: {\n\t\t\t\tmap: SharedMap,\n\t\t\t\ttext: SharedString,\n\t\t\t\ttext2: SharedString,\n\t\t\t},\n\t\t} satisfies ContainerSchema;\n\t\tconst [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);\n\n\t\tassert.strictEqual(registryEntries.length, 0, \"We should have no registry entries\");\n\t\tassert.strictEqual(sharedObjects.length, 2, \"We should have 2 shared objects\");\n\n\t\tconst types = sharedObjects.map((item) => item.type);\n\t\tassert.strictEqual(types[0], MapFactory.Type, \"SharedMap should be included\");\n\t\tassert.strictEqual(types[1], SharedStringFactory.Type, \"SharedString should be included\");\n\t});\n\n\tit(\"should be able to handle Data Objects\", () => {\n\t\tconst schema = {\n\t\t\tinitialObjects: {\n\t\t\t\tmap: SharedMap,\n\t\t\t\tdo: TestDataObject,\n\t\t\t},\n\t\t} satisfies ContainerSchema;\n\t\tconst [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);\n\n\t\tassert.strictEqual(registryEntries.length, 1, \"We should have one registry entry\");\n\t\tassert.strictEqual(sharedObjects.length, 1, \"We should have 1 shared object\");\n\n\t\tconst types = registryEntries.map((item) => item[0]);\n\t\tassert.strictEqual(types[0], TestDataObject.Name, \"TestDataObject should be included\");\n\t});\n\n\tit(\"should be able to dedup Data Objects\", () => {\n\t\tconst schema = {\n\t\t\tinitialObjects: {\n\t\t\t\tmap: SharedMap,\n\t\t\t\tdo: TestDataObject,\n\t\t\t\tdo2: TestDataObject,\n\t\t\t},\n\t\t} satisfies ContainerSchema;\n\t\tconst [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);\n\n\t\tassert.strictEqual(registryEntries.length, 1, \"We should have one registry entry\");\n\t\tassert.strictEqual(sharedObjects.length, 1, \"We should have 1 shared object\");\n\n\t\tconst types = registryEntries.map((item) => item[0]);\n\t\tassert.strictEqual(types[0], TestDataObject.Name, \"TestDataObject should be included\");\n\t});\n\n\tit(\"should be able to dedup Data Objects even if passed as dynamic types\", () => {\n\t\tconst schema: ContainerSchema = {\n\t\t\tinitialObjects: {\n\t\t\t\tmap: SharedMap,\n\t\t\t\tdo: TestDataObject,\n\t\t\t},\n\t\t\tdynamicObjectTypes: [SharedString, TestDataObject],\n\t\t} satisfies ContainerSchema;\n\t\tconst [registryEntries, sharedObjects] = parseDataObjectsFromSharedObjects(schema);\n\n\t\tassert.strictEqual(registryEntries.length, 1, \"We should have one registry entry\");\n\t\tassert.strictEqual(sharedObjects.length, 2, \"We should have 2 shared object\");\n\n\t\tconst types = registryEntries.map((item) => item[0]);\n\t\tassert.strictEqual(types[0], TestDataObject.Name, \"TestDataObject should be included\");\n\t});\n});\n"]}