diff --git a/.npmrc b/.npmrc deleted file mode 100644 index 3f56157..0000000 --- a/.npmrc +++ /dev/null @@ -1 +0,0 @@ -# "@michael-makes/shiki-colorized-brackets": "npm:@jsr/michael-makes__shiki-colorized-brackets", \ No newline at end of file diff --git a/bun.lockb b/bun.lockb index 0fb8be1..6806aa0 100644 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/docs/.vitepress/config.mts b/docs/.vitepress/config.mts index 8e16e25..c8d9d95 100644 --- a/docs/.vitepress/config.mts +++ b/docs/.vitepress/config.mts @@ -1,7 +1,12 @@ +// import shikiColorizedBrackets from "@michael-makes/shiki-colorized-brackets"; import { transformerTwoslash } from "@shikijs/vitepress-twoslash"; import presetIcons from "@unocss/preset-icons"; import Unocss from "unocss/vite"; import { defineConfig } from "vitepress"; +import { + groupIconMdPlugin, + groupIconVitePlugin, +} from "vitepress-plugin-group-icons"; import { localeEn, localeRu } from "./config/locales"; // https://vitepress.dev/reference/site-config @@ -11,7 +16,7 @@ export default defineConfig({ cleanUrls: true, vite: { publicDir: "../public", - plugins: [Unocss({ presets: [presetIcons()] })], + plugins: [Unocss({ presets: [presetIcons()] }), groupIconVitePlugin()], // TODO: remove when bun on windows out! // server: { // watch: { @@ -70,7 +75,11 @@ export default defineConfig({ ...localeRu, }, markdown: { - codeTransformers: [transformerTwoslash()], + codeTransformers: [transformerTwoslash() /**shikiColorizedBrackets()**/], + config: (md) => { + // @ts-ignore + md.use(groupIconMdPlugin); + }, }, lastUpdated: true, themeConfig: { diff --git a/docs/.vitepress/theme/index.ts b/docs/.vitepress/theme/index.ts index 7c274b0..e655dfa 100644 --- a/docs/.vitepress/theme/index.ts +++ b/docs/.vitepress/theme/index.ts @@ -1,6 +1,7 @@ import TwoslashFloatingVue from "@shikijs/vitepress-twoslash/client"; import "@shikijs/vitepress-twoslash/style.css"; import "virtual:uno.css"; +import "virtual:group-icons.css"; import "./style.css"; import type { EnhanceAppContext } from "vitepress"; import Theme from "vitepress/theme"; diff --git a/docs/files/media-upload.md b/docs/files/media-upload.md index 5ed74ae..907d825 100644 --- a/docs/files/media-upload.md +++ b/docs/files/media-upload.md @@ -87,7 +87,10 @@ Method for uploading Media File by Readable stream. // @errors: 2345 import { Bot, MessageContext } from "gramio"; import { MediaUpload } from "@gramio/files"; -import fs from "node:fs"; + +// import fs from "node:fs"; +// https://github.com/gramiojs/documentation/actions/runs/10424909870/job/28874689592 wtf +const fs = {} as any; const ctx = {} as InstanceType>; // ---cut--- diff --git a/docs/tma/index.md b/docs/tma/index.md index 63d8224..4258ec7 100644 --- a/docs/tma/index.md +++ b/docs/tma/index.md @@ -139,6 +139,7 @@ sudo echo "127.0.0.1 mini-app.local" >> /etc/hosts 4. Configure it in `vite.config.ts` ```ts + import fs from "node:fs"; import { defineConfig } from "vite"; diff --git a/package.json b/package.json index 6f8374d..8e5c218 100644 --- a/package.json +++ b/package.json @@ -1,9 +1,10 @@ { + "private": true, "devDependencies": { "@biomejs/biome": "1.8.3", "@fluent/bundle": "^0.18.0", "@gramio/auto-retry": "^0.0.3", - "@gramio/autoload": "^1.1.0", + "@gramio/autoload": "^1.0.1", "@gramio/files": "^0.0.12", "@gramio/format": "^0.1.3", "@gramio/i18n": "^0.0.4", @@ -11,19 +12,19 @@ "@gramio/keyboards": "^0.3.3", "@gramio/prompt": "^0.1.0", "@gramio/session": "^0.1.5", - "@gramio/types": "^7.9.0", - "@iconify-json/logos": "^1.1.44", - "@iconify-json/skill-icons": "^1.1.10", - - "@shikijs/vitepress-twoslash": "^1.13.0", - "@types/node": "^22.4.0", - "@unocss/preset-icons": "^0.62.2", - "elysia": "^1.1.6", - "gramio": "^0.0.48", - "grammy": "^1.29.0", - "undici": "^6.19.7", - "unocss": "^0.62.2", - "vitepress": "^1.3.2" + "@gramio/types": "^7.8.0", + "@iconify-json/logos": "^1.1.43", + "@iconify-json/skill-icons": "^1.1.9", + "@shikijs/vitepress-twoslash": "^1.12.1", + "@types/node": "^22.1.0", + "@unocss/preset-icons": "^0.61.9", + "elysia": "^1.1.5", + "gramio": "^0.0.47", + "grammy": "^1.28.0", + "undici": "^6.19.5", + "unocss": "^0.61.9", + "vitepress": "^1.3.0", + "vitepress-plugin-group-icons": "^1.0.3" }, "scripts": { "dev": "bunx vitepress dev docs",