@sanity/react-loader
Advanced tools
Comparing version 0.3.3-pink-lizard to 0.3.4-pink-lizard
# Changelog | ||
## [0.3.4-pink-lizard](https://github.com/sanity-io/visual-editing/compare/react-loader-v0.3.3-pink-lizard...react-loader-v0.3.4-pink-lizard) (2023-11-02) | ||
### Bug Fixes | ||
* export `encodeSanityNodeData` ([4d78837](https://github.com/sanity-io/visual-editing/commit/4d78837a5d29466ba714eecf50e4b88f1a8b7647)) | ||
## [0.3.3-pink-lizard](https://github.com/sanity-io/visual-editing/compare/react-loader-v0.3.2-pink-lizard...react-loader-v0.3.3-pink-lizard) (2023-11-02) | ||
@@ -4,0 +11,0 @@ |
import cjs from './jsx.cjs'; | ||
export const encodeSanityNodeData = cjs.encodeSanityNodeData; | ||
export const sanity = cjs.sanity; | ||
@@ -4,0 +5,0 @@ export const unwrapData = cjs.unwrapData; |
@@ -0,21 +1,50 @@ | ||
import { Any } from '@sanity/client/csm' | ||
import { ContentSourceMap } from '@sanity/client/csm' | ||
import { ContentSourceMapDocument } from '@sanity/client/csm' | ||
import { ContentSourceMapDocumentBase } from '@sanity/client/csm' | ||
import { ContentSourceMapDocuments } from '@sanity/client/csm' | ||
import { ContentSourceMapDocumentValueSource } from '@sanity/client/csm' | ||
import { ContentSourceMapLiteralSource } from '@sanity/client/csm' | ||
import { ContentSourceMapMapping } from '@sanity/client/csm' | ||
import { ContentSourceMapMappings } from '@sanity/client/csm' | ||
import { ContentSourceMapPaths } from '@sanity/client/csm' | ||
import { ContentSourceMapRemoteDocument } from '@sanity/client/csm' | ||
import { ContentSourceMapSource } from '@sanity/client/csm' | ||
import { ContentSourceMapUnknownSource } from '@sanity/client/csm' | ||
import { ContentSourceMapValueMapping } from '@sanity/client/csm' | ||
import type { ForwardRefExoticComponent } from 'react' | ||
import type { HTMLProps } from 'react' | ||
import { KeyedSegment } from '@sanity/client/csm' | ||
import { PathSegment } from '@sanity/client/csm' | ||
import { SanityDocument } from '@sanity/client/csm' | ||
import type { SVGProps } from 'react' | ||
/** | ||
* Transforms sanity data from multiple formats into sanity node data | ||
* @param str - Sanity data as a string of unknown format | ||
*/ | ||
export declare function decodeSanityNodeData( | ||
str: string, | ||
): SanityNode | SanityNodeLegacy | undefined | ||
export { Any } | ||
/** | ||
* Transforms a sanity data string into sanity node data | ||
* @param str - An encoded string of sanity data | ||
*/ | ||
export declare function decodeSanityString(str: string): SanityNode | undefined | ||
export { ContentSourceMap } | ||
export { ContentSourceMapDocument } | ||
export { ContentSourceMapDocumentBase } | ||
export { ContentSourceMapDocuments } | ||
export { ContentSourceMapDocumentValueSource } | ||
export { ContentSourceMapLiteralSource } | ||
export { ContentSourceMapMapping } | ||
export { ContentSourceMapMappings } | ||
export { ContentSourceMapPaths } | ||
export { ContentSourceMapRemoteDocument } | ||
export { ContentSourceMapSource } | ||
export { ContentSourceMapUnknownSource } | ||
export { ContentSourceMapValueMapping } | ||
/** | ||
@@ -148,25 +177,10 @@ * Transforms sanity node data into an encoded string | ||
export declare function isValidSanityLegacyNode( | ||
node: Partial<SanityNodeLegacy>, | ||
): node is SanityNodeLegacy | ||
export { KeyedSegment } | ||
export declare function isValidSanityNode( | ||
node: Partial<SanityNode>, | ||
): node is SanityNode | ||
export { PathSegment } | ||
export declare function resolvedKeyedSourcePath(options: { | ||
keyedResultPath: PathSegment[] | ||
pathSuffix?: string | ||
sourceBasePath: string | ||
}): PathSegment[] | ||
export declare const sanity: SanityElements | ||
export declare function resolveSanityNode( | ||
context: SanityNodeContext, | ||
csm: ContentSourceMap, | ||
resultPath: PathSegment[], | ||
keyedResultPath: PathSegment[], | ||
): SanityNode | undefined | ||
export { SanityDocument } | ||
export declare const sanity: SanityElements | ||
declare interface SanityElementProps { | ||
@@ -223,12 +237,2 @@ children?: SourceNode | null | ||
/** | ||
* Data resolved from a (legacy) Sanity node | ||
* @public | ||
*/ | ||
export declare type SanityNodeLegacy = { | ||
origin: string | ||
href: string | ||
data?: string | ||
} | ||
/** @public */ | ||
@@ -235,0 +239,0 @@ export declare type SanityPrimitive = string | number | boolean | null |
@@ -588,3 +588,3 @@ import { forwardRef, createElement } from 'react'; | ||
}); | ||
export { sanity, unwrapData, wrapData }; | ||
export { encodeSanityNodeData, sanity, unwrapData, wrapData }; | ||
//# sourceMappingURL=jsx.js.map |
{ | ||
"name": "@sanity/react-loader", | ||
"version": "0.3.3-pink-lizard", | ||
"version": "0.3.4-pink-lizard", | ||
"homepage": "https://github.com/sanity-io/visual-editing/tree/main/packages/react-loader#readme", | ||
@@ -5,0 +5,0 @@ "bugs": { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
386014
1669