mirror of https://github.com/halo-dev/halo-admin
				
				
				
			
				
					
						
							#### What type of PR is this?
/kind improvement
#### What this PR does / why we need it:
升级 `@halo-dev/richtext-editor`。重构编辑器的结构,目前可以在外部添加菜单项和指令,意味着可以被扩展。
添加 tiptap 拓展的方式:
```
pnpm install @tiptap/extension-character-count
```
然后在创建 Editor 实例的时候需要将拓展添加到 extensions 数组,如:
```ts
const editor = useEditor({
  content: props.modelValue,
  extensions: [
    ...
    ExtensionCharacterCount,
  ],
});
```
最终如果要通过我们的插件机制来拓展编辑器,那么就需要对 extensions 提供可拓展点。
#### Special notes for your reviewer:
/cc @halo-dev/sig-halo-console 
#### Does this PR introduce a user-facing change?
```release-note
None
```
						
					
				
			 | 
			||
|---|---|---|
| .changeset | ||
| .github | ||
| .husky | ||
| .vscode | ||
| cypress | ||
| docs | ||
| packages | ||
| public | ||
| src | ||
| .dockerignore | ||
| .editorconfig | ||
| .env.development | ||
| .env.production | ||
| .eslintrc.cjs | ||
| .gitignore | ||
| .gitpod.yml | ||
| .npmignore | ||
| .npmrc | ||
| Dockerfile | ||
| LICENSE | ||
| Makefile | ||
| OWNERS | ||
| README.md | ||
| cypress.json | ||
| env.d.ts | ||
| index.html | ||
| package.json | ||
| pnpm-lock.yaml | ||
| pnpm-workspace.yaml | ||
| postcss.config.js | ||
| prettier.config.js | ||
| tailwind.config.js | ||
| tsconfig.app.json | ||
| tsconfig.json | ||
| tsconfig.vite-config.json | ||
| tsconfig.vitest.json | ||
| vite.config.ts | ||
| vitest.config.ts | ||
		
			
				
				README.md
			
		
		
			
			
				
				
			
		
	
	README
Halo 2.0 的管理端项目(原 halo-admin)
注意
当前分支为 Halo 2.0 的 Console 端开发分支,目前 Halo 2.0 处于 Alpha 测试阶段,不建议从 1.5 直接升级,也不建议在生产环境使用。Console 端稳定版本(Halo 1.5)请查阅以下地址:
- 1.5 分支:https://github.com/halo-dev/console/tree/release-1.5
 - 1.6 分支:https://github.com/halo-dev/console/tree/release-1.6
 
当前仓库已经将
halo-admin改为了console。但对于 Halo 1.x 版本,依旧保持 halo-admin 的概念。
开发环境运行
# pnpm@7.0.0+
npm install -g pnpm
pnpm install 
pnpm build:packages
pnpm dev
生产构建
pnpm build