stackblitz / tutorialkit

TutorialKit by StackBlitz - Create interactive tutorials powered by the WebContainer API
https://tutorialkit.dev
MIT License
507 stars 49 forks source link

Warning `Property defaultPreviewTitleText is not allowed` in VSCode extension #337

Closed ycs77 closed 2 months ago

ycs77 commented 2 months ago

Describe the bug

Before adding a new i18n property defaultPreviewTitleText in #255, but now the warning Property defaultPreviewTitleText is not allowed remains in the VSCode.

Link to a StackBlitz project which shows the error

No response

Steps to reproduce

  1. create a new Tutorialkit project
  2. open VSCode and install Tutorialkit VSCode extension
  3. open src/content/tutorial/meta.md
  4. add below i18n content:
i18n:
  defaultPreviewTitleText: '預覽'
  1. see the warning Property defaultPreviewTitleText is not allowed when the mouse hovering defaultPreviewTitleText

Expected behavior

No show the Property defaultPreviewTitleText is not allowed warning.

Screenshots

螢幕擷取畫面 (214)

Platform

Additional context

The i18n contentSchema is in the @tutorialkit/types package:

https://github.com/stackblitz/tutorialkit/blob/5c1de69c0e4e233a25a2f9b70fbb1f6c93f12356/packages/types/src/schemas/i18n.ts#L109-L114

And this is code of load the contentSchema in the vscode extension:

https://github.com/stackblitz/tutorialkit/blob/5c1de69c0e4e233a25a2f9b70fbb1f6c93f12356/extensions/vscode/scripts/load-schema-worker.mjs#L2-L5

https://github.com/stackblitz/tutorialkit/blob/5c1de69c0e4e233a25a2f9b70fbb1f6c93f12356/extensions/vscode/scripts/build.mjs#L61-L71

So if rebuilding the vscode extension can this warning be resolved?

AriPerkkio commented 2 months ago

The extension bundles @tutorialkit/types. This means that we need to re-publish it every time we make changes to @tutorialkit/types.

So this should start working once we publish new version of extension.

AriPerkkio commented 2 months ago

There is now new version of the extension published that fixes this issue.