shinkansen-transmission 2.2.235 → 2.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 (38) hide show
  1. package/babel.config.cjs +1 -0
  2. package/eslint.config.mjs +28 -30
  3. package/index.d.mts +321 -16
  4. package/package.json +6 -6
  5. package/src/index.cjs +2 -0
  6. package/src/index.d.mts +10 -9
  7. package/src/transmission/common/index.d.mts +152 -87
  8. package/src/transmission/common/index.mjs +627 -193
  9. package/src/transmission/from-document-to-hash/array/index.mjs +20 -4
  10. package/src/transmission/from-document-to-hash/boolean/index.mjs +25 -9
  11. package/src/transmission/from-document-to-hash/index.d.mts +8 -19
  12. package/src/transmission/from-document-to-hash/index.mjs +102 -16
  13. package/src/transmission/from-document-to-hash/null/index.mjs +25 -9
  14. package/src/transmission/from-document-to-hash/number/index.mjs +25 -9
  15. package/src/transmission/from-document-to-hash/object/index.mjs +22 -6
  16. package/src/transmission/from-document-to-hash/string/index.mjs +25 -9
  17. package/src/transmission/from-hash-to-document/array/index.mjs +22 -5
  18. package/src/transmission/from-hash-to-document/boolean/index.mjs +21 -4
  19. package/src/transmission/from-hash-to-document/index.d.mts +24 -26
  20. package/src/transmission/from-hash-to-document/index.mjs +264 -142
  21. package/src/transmission/from-hash-to-document/null/index.mjs +21 -4
  22. package/src/transmission/from-hash-to-document/number/index.mjs +21 -4
  23. package/src/transmission/from-hash-to-document/object/index.mjs +22 -5
  24. package/src/transmission/from-hash-to-document/string/index.mjs +26 -4
  25. package/src/transmission/index.d.mts +4 -10
  26. package/src/transmission/to-zashiki/index.d.mts +5 -13
  27. package/src/transmission/to-zashiki/params/index.mjs +430 -0
  28. package/src/transmission/to-zashiki/render/array/index.mjs +737 -0
  29. package/src/transmission/to-zashiki/render/boolean/index.mjs +794 -0
  30. package/src/transmission/to-zashiki/render/index.mjs +157 -0
  31. package/src/transmission/to-zashiki/render/null/index.mjs +796 -0
  32. package/src/transmission/to-zashiki/render/number/index.mjs +940 -0
  33. package/src/transmission/to-zashiki/render/object/index.mjs +653 -0
  34. package/src/transmission/to-zashiki/render/string/index.mjs +910 -0
  35. package/src/transmission/to-zashiki/render-params/root-schema/index.mjs +212 -0
  36. package/src/transmission/to-zashiki/render-params/schema/index.mjs +731 -0
  37. package/src/transmission/to-zashiki/transform-root-schema.mjs +485 -421
  38. package/src/transmission/to-zashiki/transform-schema.mjs +1988 -4663
@@ -1,35 +1,33 @@
1
- declare module '#transmission/transmission/from-hash-to-document' {
2
- type ObjectLiteralType = ZashikiTypes.ObjectLiteralType
3
- type ObjectType = ZashikiTypes.ObjectType
4
- type ArrayLiteralType = ZashikiTypes.ArrayLiteralType
5
- type ArrayType = ZashikiTypes.ArrayType
1
+ type ObjectLiteralType = TransmissionTypes.ObjectLiteralType
2
+ type ObjectType = TransmissionTypes.ObjectType
3
+ type ArrayLiteralType = TransmissionTypes.ArrayLiteralType
4
+ type ArrayType = TransmissionTypes.ArrayType
6
5
 
7
- type SchemaType = ZashikiTypes.SchemaType
6
+ type SchemaType = TransmissionTypes.SchemaType
8
7
 
9
- type DocumentType = ZashikiTypes.DocumentType
10
- type HashType = ZashikiTypes.HashType
8
+ type DocumentType = TransmissionTypes.DocumentType
9
+ type HashType = TransmissionTypes.HashType
11
10
 
12
- export function transformValueFor (document: DocumentType, array: ArrayType | ArrayLiteralType | undefined): DocumentType
11
+ export function toNull (v: unknown): null
12
+ export function toBoolean (v: unknown): boolean
13
+ export function toString (v: unknown): string
14
+ export function toNumber (v: unknown): number
13
15
 
14
- export function getArrayFor (hash: HashType, array: ArrayType | ArrayLiteralType | undefined, uri: string | undefined): ArrayType | ArrayLiteralType
16
+ export function transformValueFor (document: DocumentType, array: ArrayLiteralType | ArrayType | undefined): DocumentType
15
17
 
16
- export function transformArrayFor (hash: HashType, schema: SchemaType, parentUri: string | undefined, uri: string | undefined): ArrayType | ArrayLiteralType
17
- export function transformObjectFor (hash: HashType, schema: SchemaType, parentUri: string | undefined, uri: string | undefined): ObjectType | ObjectLiteralType
18
+ export function getArrayFor (hash: HashType, array: ArrayLiteralType | ArrayType | undefined, uri?: string): ArrayLiteralType | ArrayType
18
19
 
19
- export function transformItemsArrayFor (hash: HashType, items: ArrayType | ArrayLiteralType | undefined, parentUri: string | undefined, uri: string | undefined): ArrayType | ArrayLiteralType | undefined
20
- export function transformItemsObjectFor (hash: HashType, items: ObjectType | ObjectLiteralType | undefined, parentUri: string | undefined, uri: string | undefined): ArrayType | ArrayLiteralType | undefined
20
+ export function transformArrayFor (hash: HashType, schema: SchemaType, parentUri?: string, uri?: string): ArrayLiteralType | ArrayType
21
+ export function transformObjectFor (hash: HashType, schema: SchemaType, parentUri?: string, uri?: string): ObjectLiteralType | ObjectType
21
22
 
22
- export function transformNull (hash: HashType, schema: SchemaType, parentUri: string, uri: string): null | undefined
23
- export function transformBoolean (hash: HashType, schema: SchemaType, parentUri: string, uri: string): boolean | undefined
24
- export function transformObject (hash: HashType, schema: SchemaType, parentUri: string, uri: string): ObjectType | ObjectLiteralType
25
- export function transformArray (hash: HashType, schema: SchemaType, parentUri: string, uri: string): ArrayType | ArrayLiteralType
26
- export function transformNumber (hash: HashType, schema: SchemaType, parentUri: string, uri: string): number | undefined
27
- export function transformString (hash: HashType, schema: SchemaType, parentUri: string, uri: string): string | undefined
23
+ export function transformItemsArrayFor (hash: HashType, items: ArrayLiteralType | ArrayType | undefined, parentUri?: string, uri?: string): ArrayLiteralType | ArrayType | undefined
24
+ export function transformItemsObjectFor (hash: HashType, items: ObjectLiteralType | ObjectType | undefined, parentUri?: string, uri?: string): ArrayLiteralType | ArrayType | undefined
28
25
 
29
- export default function transform (hash: HashType | undefined, rootSchema: SchemaType | undefined, parentUri: string | undefined, uri: string | undefined): DocumentType | undefined
30
- }
26
+ export function transformNull (hash: HashType, schema: SchemaType, parentUri: string, uri: string): null | undefined
27
+ export function transformBoolean (hash: HashType, schema: SchemaType, parentUri: string, uri: string): boolean | undefined
28
+ export function transformObject (hash: HashType, schema: SchemaType, parentUri: string, uri: string): ObjectLiteralType | ObjectType
29
+ export function transformArray (hash: HashType, schema: SchemaType, parentUri: string, uri: string): ArrayLiteralType | ArrayType
30
+ export function transformNumber (hash: HashType, schema: SchemaType, parentUri: string, uri: string): number | undefined
31
+ export function transformString (hash: HashType, schema: SchemaType, parentUri: string, uri: string): string | undefined
31
32
 
32
- declare module 'shinkansen-transmission/transmission/from-hash-to-document' {
33
- export { default } from '#transmission/transmission/from-hash-to-document'
34
- export * from '#transmission/transmission/from-hash-to-document'
35
- }
33
+ export default function transform (hash?: HashType, rootSchema?: SchemaType, parentUri?: string, uri?: string): DocumentType | undefined