feat: add AI command suggestions extension for Tiptap editor

- Implemented Commands plugin to handle command suggestions triggered by '@' character.
- Created suggestion configuration to filter and render command items.
- Added various command items including date, time, formatting, templates, and task management commands.
- Introduced CSS styles for the Tiptap editor to enhance UI.
- Configured TypeScript settings and Vite build for the project.
This commit is contained in:
2025-12-17 13:48:51 +08:00
commit 8ca7efcf6d
28 changed files with 4412 additions and 0 deletions

67
package.json Normal file
View File

@@ -0,0 +1,67 @@
{
"name": "@kevisual/kv-md",
"version": "0.0.1",
"description": "",
"basename": "/root/kv-md",
"scripts": {
"dev": "vite",
"build": "vite build",
"build:lib": "vite build --config vite.config.lib.ts",
"prepub": "rm -rf ./dist && rimraf ./pack-dist && pnpm run build:test",
"pub": "envision deploy ./dist -k kv-md -v 0.0.1"
},
"keywords": [],
"author": "abearxiong <xiongxiao@xiongxiao.me> (https://www.xiongxiao.me)",
"license": "MIT",
"packageManager": "pnpm@10.25.0",
"type": "module",
"files": [
"dist",
"mod.ts",
"src"
],
"dependencies": {
"@kevisual/app": "^0.0.1",
"@kevisual/context": "^0.0.4",
"@tiptap/core": "^3.13.0",
"@tiptap/extension-code-block-lowlight": "^3.13.0",
"@tiptap/extension-dropcursor": "^3.13.0",
"@tiptap/extension-highlight": "^3.13.0",
"@tiptap/extension-placeholder": "^3.13.0",
"@tiptap/extension-typography": "^3.13.0",
"@tiptap/pm": "^3.13.0",
"@tiptap/starter-kit": "^3.13.0",
"@tiptap/suggestion": "^3.13.0",
"dayjs": "^1.11.19",
"highlight.js": "^11.11.1",
"lit-html": "^3.3.1",
"lowlight": "^3.3.0",
"nanoid": "^5.1.6",
"react": "^19.2.1",
"react-dom": "^19.2.1",
"tiptap-markdown": "^0.9.0",
"zustand": "^5.0.9"
},
"devDependencies": {
"@kevisual/query": "0.0.31",
"@kevisual/types": "^0.0.10",
"@tailwindcss/vite": "^4.1.17",
"@types/bun": "^1.3.4",
"@types/node": "^24.10.2",
"@types/react": "^19.2.7",
"@types/react-dom": "^19.2.3",
"@vitejs/plugin-react": "^5.1.2",
"dotenv": "^17.2.3",
"tailwindcss": "^4.1.17",
"vite": "^7.2.7"
},
"publishConfig": {
"access": "public"
},
"exports": {
".": "./dist/kv-md.js",
"./kv-md.js": "./dist/kv-md.js",
"./kv-md.css": "./dist/kv-md.css",
"./mod.ts": "./mod.ts"
}
}