Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>BBCode (NGA)New to Visual Studio Code? Get it now.
BBCode (NGA)

BBCode (NGA)

stone5265

|
56 installs
| (0) | Free
支持 [NGA](https://bbs.nga.cn/) BBCode 语法 的 VSCode 插件
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

BBCode (NGA)

支持 NGA (艾泽拉斯国家地理) BBCode 语法 的 VSCode 插件。自动识别后缀为 .nga 和 .bbsnga 的文件。

覆盖 NGA 常用 BBCode 的语法高亮、代码片段。

该插件为 Sublime 插件 BBCode (NGA) 的 VSCode 移植版,详细功能更新日志请查看 BBCode (NGA)

特性

  • 语法高亮

    • BBCode 代码块高亮提示

    • 包裹光标的代码块高亮提示

    • 未闭合的代码块警告提示

  • 代码片段

    • BBCode 代码块 ( 对应 tag 并双写其首字母,比如 bb 对应 [b][/b] )

    • 专楼模板 ( 前缀为 template )

      • template_character: 角色模块

      • template_video: 视频模块

      • template_episode_preview: 先行情报模块

      • template_overall: 整体模块

  • 快捷键

    • ctrl+b: 在选中区域两侧 添加/去除 [b][/b]

    • ctrl+i: 在选中区域两侧 添加/去除 [i][/i]

    • ctrl+u: 在选中区域两侧 添加/去除 [u][/u]

    • ctrl+q: 在选中区域两侧 添加/去除 [quote][/quote]

  • 右键菜单

    • BBCode转纯文本: 使选中区域内 BBCode 失去效果, 显示为纯文本

      示例
      (转换前) [b]加粗[/b] [i]斜体[/i]`
      (转换后) [[size=0%][/size]b]加粗[[size=0%][/size]/b] [[size=0%][/size]i]斜体[[size=0%][/size]/i]
      
    • url精简: 精简选中区域中的url代码块中的NGA域名和B站链接

      示例-NGA域名
      (1:转换前) [url]https://bbs.nga.cn/read.php?tid=43417488[/url]
      (1:转换后) [url]/read.php?tid=43417488[/url]
      
      (2:转换前) [url=https://ngabbs.com/thread.php?fid=-447601]猴区[/url]
      (2:转换后) [url=/thread.php?fid=-447601]猴区[/url]
      
      示例-B站链接
      (转换前) [url=https://www.bilibili.com/bangumi/play/ep1642068?season_id=90684&season_type=1&aid=114424941643282&season_cover=https%3A%2f%2fi0.hdslb.com%2fbfs%2fbangumi%2fimage%2f2f5946880c07914d1cccd112702884f232b647e0.png&title=7&long_title=%E9%9E%A0%E8%BA%AC%E8%A6%81%E6%B7%B1%20%E5%BF%97%E5%90%91%E8%A6%81%E9%AB%98&player_width=1920&player_height=1080&player_rotate=0&ep_status=13&is_preview=0&spm_id_from=333.1365.list.card_pgc.click]末日后酒店EP7[/url]
      (转换后) [url=https://www.bilibili.com/bangumi/play/ep1642068]末日后酒店EP7[/url]
      
    • img转占位符: 将选中区域中的img代码块替换为"_图_"

      示例
      (转换前) [quote][img]./mon_202505/22/-9lddQ1aa-axbtK2aT1kSac-ac.png[/img][/quote]
      (转换后) [quote]__图__[/quote]
      
    • table转Markdown格式: 将选中区域中的table代码块转换为Markdown格式, 仅支持基础表格 (加粗/斜体/删除线/代码/url/补全NGA图床图片的完整URL)

      示例
      (转换前)
      
      [table]
      [tr][td15][b]功能[/b][/td][td35][b]展示[/b][/td][td15][b]功能[/b][/td][td35][b]展示[/b][/td][/tr]
      [tr]
      [td]加粗[/td][td][b]加粗[/b][/td]
      [td]斜体[/td][td][i]斜体[/i][/td]
      [/tr]
      [tr]
      [td]删除线[/td][td][del]删除线[/del][/td]
      [td]换行[/td][td]第一段
      第二段[/td]
      [/tr]
      [tr]
      [td]代码[/td][td][code]代码[/code][/td]
      [td]图片[/td][td][quote][img]./mon_202505/22/-9lddQ1aa-axbtK2aT1kSac-ac.png[/img][/quote][/td]
      [/tr]
      [tr]
      [td]链接1[/td][td][url]/thread.php?fid=-447601[/url][/td]
      [td]链接2[/td][td][url=/thread.php?fid=-447601]猴区[/url][/td]
      [/tr]
      [/table]
      
      (转换后)
      
      | **功能** | **展示**                                  | **功能** | **展示**                                                                                 |
      | :------- | :---------------------------------------- | :------- | :--------------------------------------------------------------------------------------- |
      | 加粗     | **加粗**                                  | 斜体     | *斜体*                                                                                   |
      | 删除线   | ~~删除线~~                                | 换行     | 第一段<br>第二段                                                                         |
      | 代码     | `代码`                                    | 图片     | ![IMG](https://img.nga.178.com/attachments/mon_202505/22/-9lddQ1aa-axbtK2aT1kSac-ac.png) |
      | 链接1    | https://bbs.nga.cn/thread.php?fid=-447601 | 链接2    | [猴区](https://bbs.nga.cn/thread.php?fid=-447601)                                        |
      

安装

VSCode 扩展市场 搜索 BBCode (NGA)

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft