@stainless-api/playgrounds 0.1.0-beta.41 → 0.1.0-beta.43

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/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @stainless-api/playgrounds
2
2
 
3
+ ## 0.1.0-beta.43
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [848cff4]
8
+ - Updated dependencies [ea2b90c]
9
+ - @stainless-api/ui-primitives@0.1.0-beta.50
10
+ - @stainless-api/docs-ui@0.1.0-beta.86
11
+
12
+ ## 0.1.0-beta.42
13
+
14
+ ### Patch Changes
15
+
16
+ - Updated dependencies [93a3767]
17
+ - @stainless-api/docs-ui@0.1.0-beta.85
18
+
3
19
  ## 0.1.0-beta.41
4
20
 
5
21
  ### Minor Changes
@@ -0,0 +1,277 @@
1
+ {
2
+ "src/Logs.tsx": {
3
+ "@typescript-eslint/no-floating-promises": {
4
+ "count": 1
5
+ },
6
+ "@typescript-eslint/no-unsafe-return": {
7
+ "count": 1
8
+ }
9
+ },
10
+ "src/build-py-types.ts": {
11
+ "@typescript-eslint/no-floating-promises": {
12
+ "count": 1
13
+ }
14
+ },
15
+ "src/codemirror/comlink.ts": {
16
+ "@typescript-eslint/no-floating-promises": {
17
+ "count": 2
18
+ },
19
+ "@typescript-eslint/no-unsafe-argument": {
20
+ "count": 7
21
+ },
22
+ "@typescript-eslint/no-unsafe-assignment": {
23
+ "count": 11
24
+ },
25
+ "@typescript-eslint/no-unsafe-call": {
26
+ "count": 4
27
+ },
28
+ "@typescript-eslint/no-unsafe-member-access": {
29
+ "count": 12
30
+ },
31
+ "@typescript-eslint/no-unsafe-return": {
32
+ "count": 7
33
+ }
34
+ },
35
+ "src/codemirror/curl.ts": {
36
+ "@typescript-eslint/no-floating-promises": {
37
+ "count": 1
38
+ },
39
+ "@typescript-eslint/no-misused-promises": {
40
+ "count": 1
41
+ },
42
+ "@typescript-eslint/require-await": {
43
+ "count": 1
44
+ }
45
+ },
46
+ "src/codemirror/fix-lsp-markdown.ts": {
47
+ "@typescript-eslint/no-unsafe-argument": {
48
+ "count": 1
49
+ },
50
+ "@typescript-eslint/no-unsafe-assignment": {
51
+ "count": 2
52
+ }
53
+ },
54
+ "src/codemirror/lsp.ts": {
55
+ "@typescript-eslint/no-unsafe-call": {
56
+ "count": 1
57
+ },
58
+ "@typescript-eslint/no-unsafe-member-access": {
59
+ "count": 2
60
+ }
61
+ },
62
+ "src/codemirror/python.ts": {
63
+ "@typescript-eslint/no-floating-promises": {
64
+ "count": 1
65
+ },
66
+ "@typescript-eslint/no-misused-promises": {
67
+ "count": 3
68
+ },
69
+ "@typescript-eslint/require-await": {
70
+ "count": 1
71
+ },
72
+ "@typescript-eslint/unbound-method": {
73
+ "count": 1
74
+ }
75
+ },
76
+ "src/codemirror/python/pyodide.ts": {
77
+ "@typescript-eslint/no-floating-promises": {
78
+ "count": 1
79
+ },
80
+ "@typescript-eslint/no-unsafe-assignment": {
81
+ "count": 9
82
+ },
83
+ "@typescript-eslint/no-unsafe-call": {
84
+ "count": 10
85
+ },
86
+ "@typescript-eslint/no-unsafe-member-access": {
87
+ "count": 6
88
+ },
89
+ "@typescript-eslint/no-unsafe-return": {
90
+ "count": 4
91
+ }
92
+ },
93
+ "src/codemirror/react.tsx": {
94
+ "@typescript-eslint/no-floating-promises": {
95
+ "count": 1
96
+ },
97
+ "@typescript-eslint/no-misused-promises": {
98
+ "count": 4
99
+ },
100
+ "@typescript-eslint/only-throw-error": {
101
+ "count": 1
102
+ },
103
+ "@typescript-eslint/restrict-plus-operands": {
104
+ "count": 4
105
+ },
106
+ "@typescript-eslint/unbound-method": {
107
+ "count": 5
108
+ }
109
+ },
110
+ "src/codemirror/shiki.ts": {
111
+ "@typescript-eslint/no-unsafe-assignment": {
112
+ "count": 4
113
+ },
114
+ "@typescript-eslint/no-unsafe-member-access": {
115
+ "count": 4
116
+ }
117
+ },
118
+ "src/codemirror/typescript.tsx": {
119
+ "@typescript-eslint/no-floating-promises": {
120
+ "count": 2
121
+ },
122
+ "@typescript-eslint/no-misused-promises": {
123
+ "count": 1
124
+ }
125
+ },
126
+ "src/codemirror/typescript/cdn-typescript.js": {
127
+ "@typescript-eslint/no-unsafe-call": {
128
+ "count": 1
129
+ }
130
+ },
131
+ "src/codemirror/typescript/console.ts": {
132
+ "@typescript-eslint/no-unsafe-argument": {
133
+ "count": 1
134
+ },
135
+ "@typescript-eslint/no-unsafe-assignment": {
136
+ "count": 6
137
+ },
138
+ "@typescript-eslint/no-unsafe-member-access": {
139
+ "count": 1
140
+ }
141
+ },
142
+ "src/codemirror/typescript/runner.ts": {
143
+ "@typescript-eslint/await-thenable": {
144
+ "count": 6
145
+ },
146
+ "@typescript-eslint/no-misused-promises": {
147
+ "count": 2
148
+ },
149
+ "@typescript-eslint/no-unsafe-argument": {
150
+ "count": 1
151
+ },
152
+ "@typescript-eslint/no-unsafe-assignment": {
153
+ "count": 5
154
+ },
155
+ "@typescript-eslint/no-unsafe-call": {
156
+ "count": 2
157
+ },
158
+ "@typescript-eslint/no-unsafe-member-access": {
159
+ "count": 2
160
+ },
161
+ "@typescript-eslint/no-unsafe-return": {
162
+ "count": 1
163
+ },
164
+ "@typescript-eslint/restrict-plus-operands": {
165
+ "count": 1
166
+ },
167
+ "@typescript-eslint/unbound-method": {
168
+ "count": 5
169
+ }
170
+ },
171
+ "src/codemirror/typescript/special-info.ts": {
172
+ "@typescript-eslint/no-floating-promises": {
173
+ "count": 1
174
+ },
175
+ "@typescript-eslint/no-unsafe-argument": {
176
+ "count": 5
177
+ },
178
+ "@typescript-eslint/no-unsafe-assignment": {
179
+ "count": 9
180
+ },
181
+ "@typescript-eslint/no-unsafe-call": {
182
+ "count": 1
183
+ },
184
+ "@typescript-eslint/no-unsafe-member-access": {
185
+ "count": 8
186
+ },
187
+ "@typescript-eslint/no-unsafe-return": {
188
+ "count": 1
189
+ },
190
+ "@typescript-eslint/unbound-method": {
191
+ "count": 1
192
+ }
193
+ },
194
+ "src/codemirror/typescript/worker.ts": {
195
+ "@typescript-eslint/no-unsafe-argument": {
196
+ "count": 1
197
+ },
198
+ "@typescript-eslint/no-unsafe-assignment": {
199
+ "count": 2
200
+ },
201
+ "@typescript-eslint/no-unsafe-call": {
202
+ "count": 1
203
+ },
204
+ "@typescript-eslint/require-await": {
205
+ "count": 1
206
+ },
207
+ "@typescript-eslint/restrict-template-expressions": {
208
+ "count": 1
209
+ }
210
+ },
211
+ "src/config.ts": {
212
+ "@typescript-eslint/no-unsafe-assignment": {
213
+ "count": 1
214
+ }
215
+ },
216
+ "src/create.tsx": {
217
+ "@typescript-eslint/unbound-method": {
218
+ "count": 1
219
+ }
220
+ },
221
+ "src/sandbox-worker/in-frame.js": {
222
+ "@typescript-eslint/no-unsafe-argument": {
223
+ "count": 6
224
+ },
225
+ "@typescript-eslint/no-unsafe-assignment": {
226
+ "count": 5
227
+ },
228
+ "@typescript-eslint/no-unsafe-call": {
229
+ "count": 3
230
+ },
231
+ "@typescript-eslint/no-unsafe-member-access": {
232
+ "count": 16
233
+ },
234
+ "@typescript-eslint/no-unsafe-return": {
235
+ "count": 1
236
+ }
237
+ },
238
+ "src/sandbox-worker/index.ts": {
239
+ "@typescript-eslint/no-unsafe-argument": {
240
+ "count": 1
241
+ },
242
+ "@typescript-eslint/no-unsafe-assignment": {
243
+ "count": 1
244
+ },
245
+ "@typescript-eslint/no-unsafe-member-access": {
246
+ "count": 7
247
+ },
248
+ "@typescript-eslint/restrict-plus-operands": {
249
+ "count": 3
250
+ }
251
+ },
252
+ "test/get-signature.test.ts": {
253
+ "@typescript-eslint/no-floating-promises": {
254
+ "count": 2
255
+ },
256
+ "@typescript-eslint/no-implied-eval": {
257
+ "count": 1
258
+ },
259
+ "@typescript-eslint/no-unsafe-assignment": {
260
+ "count": 1
261
+ },
262
+ "@typescript-eslint/no-unsafe-call": {
263
+ "count": 1
264
+ },
265
+ "@typescript-eslint/require-await": {
266
+ "count": 2
267
+ },
268
+ "@typescript-eslint/unbound-method": {
269
+ "count": 8
270
+ }
271
+ },
272
+ "test/use-storage.test.ts": {
273
+ "@typescript-eslint/no-floating-promises": {
274
+ "count": 3
275
+ }
276
+ }
277
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stainless-api/playgrounds",
3
- "version": "0.1.0-beta.41",
3
+ "version": "0.1.0-beta.43",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -39,20 +39,20 @@
39
39
  "js-tokens": "^9.0.1",
40
40
  "lines-and-columns": "^2.0.4",
41
41
  "lucide-react": "^0.574.0",
42
- "marked": "^17.0.3",
42
+ "marked": "^17.0.4",
43
43
  "shiki": "^4.0.2",
44
44
  "source-map": "^0.7.6",
45
- "type-fest": "^5.4.3",
45
+ "type-fest": "^5.4.4",
46
46
  "unenv": "^1.10.0",
47
47
  "vite-plugin-prebundle-workers": "^0.2.0",
48
48
  "vscode-languageserver-protocol": "^3.17.5",
49
- "@stainless-api/docs-ui": "0.1.0-beta.84",
50
- "@stainless-api/ui-primitives": "0.1.0-beta.49",
49
+ "@stainless-api/docs-ui": "0.1.0-beta.86",
50
+ "@stainless-api/ui-primitives": "0.1.0-beta.50",
51
51
  "@stainless/sdk-json": "^0.1.0-beta.9"
52
52
  },
53
53
  "devDependencies": {
54
54
  "@types/is-callable": "^1.1.2",
55
- "@types/node": "24.10.13",
55
+ "@types/node": "24.12.0",
56
56
  "@types/react": "19.2.14",
57
57
  "@types/react-dom": "^19.2.3",
58
58
  "is-callable": "^1.2.7",
@@ -64,7 +64,7 @@
64
64
  "@stainless/eslint-config": "0.1.0-beta.1"
65
65
  },
66
66
  "scripts": {
67
- "lint": "eslint .",
67
+ "lint": "eslint --flag unstable_native_nodejs_ts_config .",
68
68
  "check:types": "tsc --noEmit && tsc -p ./tsconfig.test.json",
69
69
  "test": "node --test"
70
70
  }
@@ -489,7 +489,7 @@ function releaseEndpoint(epWithPendingListeners: EndpointWithPendingListeners) {
489
489
 
490
490
  interface FinalizationRegistry<T> {
491
491
  new (cb: (heldValue: T) => void): FinalizationRegistry<T>;
492
- register(weakItem: object, heldValue: T, unregisterToken?: object | undefined): void;
492
+ register(weakItem: object, heldValue: T, unregisterToken?: object): void;
493
493
  unregister(unregisterToken: object): void;
494
494
  }
495
495
  declare let FinalizationRegistry: FinalizationRegistry<EndpointWithPendingListeners>;
@@ -6,7 +6,7 @@ const indexURL = 'https://cdn.jsdelivr.net/pyodide/v0.28.1/full';
6
6
  const pyodidePromise = (
7
7
  import(
8
8
  /* @vite-ignore */
9
- (indexURL + '/pyodide.mjs') as string
9
+ indexURL + '/pyodide.mjs'
10
10
  ) as Promise<typeof import('pyodide')>
11
11
  ).then((mod) =>
12
12
  mod.loadPyodide({
@@ -367,8 +367,6 @@ export const Editor = ({
367
367
  return clone;
368
368
  }, [container]);
369
369
  const editor = useCodeMirror(async ({ signal }) => {
370
- let _never: never;
371
- void _never!;
372
370
  switch (lang) {
373
371
  case 'python': {
374
372
  const { createPyright } = await import('./python');
@@ -386,7 +384,8 @@ export const Editor = ({
386
384
  return await createCurl(signal, doc);
387
385
  }
388
386
  default:
389
- throw (_never = lang);
387
+ // exhaustiveness check
388
+ throw lang satisfies never;
390
389
  }
391
390
  });
392
391
  const logs = useContext(LogsContext);
@@ -126,7 +126,6 @@ function format(args: unknown[]): (string | Part)[] {
126
126
  value: first.slice(appendedChars),
127
127
  type: 'string',
128
128
  });
129
- css = undefined;
130
129
  }
131
130
 
132
131
  for (; a < args.length; a++) {
@@ -19,17 +19,17 @@ function escapeRegExp(text: string) {
19
19
  let realpathRe;
20
20
  const realpath = (typescriptTypes: TypescriptTypes, path: string) => {
21
21
  realpathRe ??= new RegExp(
22
- `^(${typescriptTypes!.links.map((e, i) => `(?<_${i}>${escapeRegExp(e[0])})`).join('|')})(/|$)`,
22
+ `^(${typescriptTypes.links.map((e, i) => `(?<_${i}>${escapeRegExp(e[0])})`).join('|')})(/|$)`,
23
23
  );
24
24
  let match;
25
25
  while ((match = path.match(realpathRe))) {
26
26
  const entry =
27
- typescriptTypes!.links[
27
+ typescriptTypes.links[
28
28
  Object.entries(match.groups!)
29
29
  .find((e) => e[1])![0]
30
30
  .slice(1) as `${number}`
31
31
  ]!;
32
- path = entry[1] + (match[2 + typescriptTypes!.links.length] ?? '') + path.slice(match[0].length);
32
+ path = entry[1] + (match[2 + typescriptTypes.links.length] ?? '') + path.slice(match[0].length);
33
33
  }
34
34
  return path;
35
35
  };
@@ -157,7 +157,7 @@ const worker: {
157
157
  } = createWorker({
158
158
  env: (async () => {
159
159
  const { typescriptTypes, suggestedEnv } = await initData.promise;
160
- fsMap = new Map<string, string>(typescriptTypes.files as [string, string][]);
160
+ fsMap = new Map<string, string>(typescriptTypes.files);
161
161
  fsMap.set(
162
162
  '/node_modules/@types/stl-play/package.json',
163
163
  JSON.stringify({
package/tsconfig.json CHANGED
@@ -8,5 +8,5 @@
8
8
  "outDir": "dist",
9
9
  "jsx": "react-jsx"
10
10
  },
11
- "include": ["src", "*.config.*"]
11
+ "include": ["src", "*.config.*", "test"]
12
12
  }
File without changes