@sanity/vision 6.21.0-next.64 → 6.21.0-next.68
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.
- package/lib/{CodeDiff-Bj_o50Qy.js → CodeDiff-MkS3Q87A.js} +14 -13
- package/lib/CodeDiff-MkS3Q87A.js.map +1 -0
- package/lib/{SanityVision-BPTjMcT_.js → SanityVision-DOH_LzRg.js} +88 -93
- package/lib/SanityVision-DOH_LzRg.js.map +1 -0
- package/lib/{VistaGui-CFsbMx2g.js → VistaGui-C6cdsk92.js} +111 -110
- package/lib/VistaGui-C6cdsk92.js.map +1 -0
- package/lib/bundle.css +221 -210
- package/lib/index.js +1 -1
- package/package.json +9 -8
- package/lib/CodeDiff-Bj_o50Qy.js.map +0 -1
- package/lib/SanityVision-BPTjMcT_.js.map +0 -1
- package/lib/VistaGui-CFsbMx2g.js.map +0 -1
package/lib/index.js
CHANGED
|
@@ -12,7 +12,7 @@ const visionTool = definePlugin((options) => {
|
|
|
12
12
|
name: name || "vision",
|
|
13
13
|
title: title || "Vision",
|
|
14
14
|
icon: icon || EyeOpenIcon,
|
|
15
|
-
component: lazy(() => import("./SanityVision-
|
|
15
|
+
component: lazy(() => import("./SanityVision-DOH_LzRg.js").then((n) => n.t)),
|
|
16
16
|
options: config,
|
|
17
17
|
router: route.create("/*"),
|
|
18
18
|
__internalApplicationType: "sanity/vision"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sanity/vision",
|
|
3
|
-
"version": "6.21.0-next.
|
|
3
|
+
"version": "6.21.0-next.68",
|
|
4
4
|
"description": "Sanity plugin for running/debugging GROQ-queries against Sanity datasets",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"admin",
|
|
@@ -59,11 +59,10 @@
|
|
|
59
59
|
"@sanity/color": "^3.0.9",
|
|
60
60
|
"@sanity/icons": "^5.2.3",
|
|
61
61
|
"@sanity/lezer-groq": "^1.0.4",
|
|
62
|
-
"@sanity/schema": "6.21.0-next.
|
|
62
|
+
"@sanity/schema": "6.21.0-next.68+209fafb0fb",
|
|
63
63
|
"@sanity/ui": "^4.4.9",
|
|
64
64
|
"@sanity/uuid": "^3.0.3",
|
|
65
65
|
"@uiw/react-codemirror": "^4.25.12",
|
|
66
|
-
"@vanilla-extract/dynamic": "^2.1.5",
|
|
67
66
|
"@xstate/react": "^6.1.0",
|
|
68
67
|
"cobe": "^2.0.1",
|
|
69
68
|
"dequal": "^2.0.3",
|
|
@@ -82,22 +81,23 @@
|
|
|
82
81
|
"xstate": "^5.33.2"
|
|
83
82
|
},
|
|
84
83
|
"devDependencies": {
|
|
85
|
-
"@
|
|
84
|
+
"@repo/css-modules-kit": "6.19.0",
|
|
86
85
|
"@repo/package.bundle": "6.9.2",
|
|
86
|
+
"@repo/pandacss": "6.9.2",
|
|
87
87
|
"@repo/test-config": "6.9.2",
|
|
88
88
|
"@repo/tsconfig": "6.9.2",
|
|
89
89
|
"@repo/tsdown.config": "6.9.2",
|
|
90
|
-
"@sanity/vanilla-extract-vite-plugin": "^0.3.1",
|
|
91
90
|
"@testing-library/react": "^16.3.3",
|
|
91
|
+
"@tsdown/css": "^0.23.1",
|
|
92
92
|
"@types/lodash-es": "^4.17.12",
|
|
93
93
|
"@types/react": "^19.3.0",
|
|
94
|
-
"@vanilla-extract/css": "^1.21.3",
|
|
95
94
|
"@vitejs/plugin-react": "^6.1.2",
|
|
96
95
|
"jsdom": "^29.1.1",
|
|
96
|
+
"lightningcss": "^1.33.0",
|
|
97
97
|
"oxc-transform-react": "^0.155.0",
|
|
98
98
|
"react": "^19.3.1",
|
|
99
99
|
"react-dom": "^19.3.1",
|
|
100
|
-
"sanity": "6.21.0-next.
|
|
100
|
+
"sanity": "6.21.0-next.68+209fafb0fb",
|
|
101
101
|
"styled-components": "^6.6.0",
|
|
102
102
|
"tsdown": "^0.23.1",
|
|
103
103
|
"typescript": "^7.0.2",
|
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
},
|
|
107
107
|
"peerDependencies": {
|
|
108
108
|
"react": "^19.2.2",
|
|
109
|
-
"sanity": "^6.21.0-next.
|
|
109
|
+
"sanity": "^6.21.0-next.68+209fafb0fb"
|
|
110
110
|
},
|
|
111
111
|
"browserslist": [
|
|
112
112
|
"node >=22.12",
|
|
@@ -118,6 +118,7 @@
|
|
|
118
118
|
"scripts": {
|
|
119
119
|
"build": "tsdown",
|
|
120
120
|
"build:bundle": "vite build --configLoader runner --config package.bundle.ts",
|
|
121
|
+
"prebuild": "pnpm --filter @repo/css-modules-kit run generate:vision",
|
|
121
122
|
"test": "vitest",
|
|
122
123
|
"watch": "tsdown --watch"
|
|
123
124
|
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CodeDiff-Bj_o50Qy.js","names":["{previous, next, lang}: CodeDiffProps","{name: `diff.${lang}`, contents: previous, lang}","`diff.${lang}`","useMemo<FileContents>(\n () => ({name: `diff.${lang}`, contents: previous, lang}),\n [lang, previous],\n )","{name: `diff.${lang}`, contents: next, lang}","useMemo<FileContents>(\n () => ({name: `diff.${lang}`, contents: next, lang}),\n [lang, next],\n )","() => {\n const wrapper = wrapperRef.current\n if (!wrapper) return undefined\n const diff = new FileDiff({\n diffStyle: 'unified',\n // Thrown from `render` in this effect, a failure reaches the History panel's error\n // boundary and its Retry, rather than being drawn as a stack trace inside the diff\n disableErrorHandling: true,\n disableFileHeader: true,\n lineDiffType: 'word',\n overflow: 'wrap',\n themeType,\n })\n diff.render({containerWrapper: wrapper, newFile, oldFile})\n return () => diff.cleanUp()\n }","[newFile, oldFile, themeType]","assignInlineVars({\n '--diffs-font-family': font.code.family,\n '--diffs-font-size': `${codeSize.fontSize}px`,\n '--diffs-line-height': `${codeSize.lineHeight}px`,\n })","family","`${codeSize.fontSize}px`","`${codeSize.lineHeight}px`","<div\n ref={wrapperRef}\n style={assignInlineVars({\n '--diffs-font-family': font.code.family,\n '--diffs-font-size': `${codeSize.fontSize}px`,\n '--diffs-line-height': `${codeSize.lineHeight}px`,\n })}\n />","_c","useThemeV2"],"sources":["../src/vista/components/response/CodeDiff.tsx"],"sourcesContent":["import {type FileContents, FileDiff} from '@pierre/diffs'\nimport {useTheme_v2 as useThemeV2} from '@sanity/ui'\nimport {assignInlineVars} from '@vanilla-extract/dynamic'\nimport {useEffect, useMemo, useRef} from 'react'\n\nexport interface CodeDiffProps {\n previous: string\n next: string\n lang: 'json' | 'text'\n}\n\n/**\n * Line diff of two texts, rendered by `@pierre/diffs` (Shiki highlighting in a shadow root).\n * Only loaded through `lazy()` once a history entry's changes are expanded.\n */\nexport default function CodeDiff({previous, next, lang}: CodeDiffProps) {\n const {color, font} = useThemeV2()\n const codeSize = font.code.sizes[1]\n const wrapperRef = useRef<HTMLDivElement>(null)\n const oldFile = useMemo<FileContents>(\n () => ({name: `diff.${lang}`, contents: previous, lang}),\n [lang, previous],\n )\n const newFile = useMemo<FileContents>(\n () => ({name: `diff.${lang}`, contents: next, lang}),\n [lang, next],\n )\n const themeType = color._dark ? 'dark' : 'light'\n\n // The library's React components keep their container and hydrate whatever markup a previous\n // instance left in it, so after StrictMode detaches and re-attaches their ref they render\n // nothing. An instance per effect run with a container of its own (removed on clean up) has no\n // such markup to find\n useEffect(() => {\n const wrapper = wrapperRef.current\n if (!wrapper) return undefined\n const diff = new FileDiff({\n diffStyle: 'unified',\n // Thrown from `render` in this effect, a failure reaches the History panel's error\n // boundary and its Retry, rather than being drawn as a stack trace inside the diff\n disableErrorHandling: true,\n disableFileHeader: true,\n lineDiffType: 'word',\n overflow: 'wrap',\n themeType,\n })\n diff.render({containerWrapper: wrapper, newFile, oldFile})\n return () => diff.cleanUp()\n }, [newFile, oldFile, themeType])\n\n return (\n <div\n ref={wrapperRef}\n style={assignInlineVars({\n '--diffs-font-family': font.code.family,\n '--diffs-font-size': `${codeSize.fontSize}px`,\n '--diffs-line-height': `${codeSize.lineHeight}px`,\n })}\n />\n )\n}\n"],"mappings":";;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