syncfusion-blazor-smart-paste
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseSyncfusion Blazor Smart Paste Button
Syncfusion Blazor Smart Paste Button
The Syncfusion Blazor Smart Paste Button uses AI to intelligently read clipboard text and populate form fields automatically, eliminating manual data entry.
Syncfusion Blazor Smart Paste Button 借助AI技术智能读取剪贴板文本并自动填充表单字段,省去手动输入数据的步骤。
When to Use
适用场景
Use this skill when you need to:
- Add the Smart Paste Button to a Blazor form for AI-powered clipboard-to-field population
- Configure an AI backend (OpenAI, Azure OpenAI, Ollama, or custom)
- Add annotations to fine-tune field mapping
[SmartPasteField] - Customize button appearance, content, and behavior
- Integrate a custom implementation
IChatInferenceService - Troubleshoot Smart Paste integration or AI connectivity issues
在以下场景中可使用该工具:
- 为Blazor表单添加Smart Paste Button,实现AI驱动的剪贴板转字段填充功能
- 配置AI后端(OpenAI、Azure OpenAI、Ollama或自定义后端)
- 添加注解以优化字段映射
[SmartPasteField] - 自定义按钮的外观、内容与行为
- 集成自定义实现
IChatInferenceService - 排查Smart Paste集成或AI连接相关的故障
Prerequisites
前置条件
- .NET SDK 8.0 or later
- Visual Studio 2022 (17.0+) or Visual Studio Code
- Active OpenAI, Azure OpenAI, or Ollama account (or a custom AI backend)
- Basic knowledge of Blazor Web App (Server render mode)
- .NET SDK 8.0 或更高版本
- Visual Studio 2022(17.0及以上)或Visual Studio Code
- 有效的OpenAI、Azure OpenAI或Ollama账户(或自定义AI后端)
- 具备Blazor Web App(Server渲染模式)的基础知识
Quick Setup
快速设置
Follow these steps in order:
按以下步骤依次操作:
1. Initial Setup and NuGet Installation
1. 初始设置与NuGet安装
Start with getting-started.md to:
- Create a new Blazor Web App Server
- Install Syncfusion NuGet packages
- Register Syncfusion Blazor services
- Add necessary namespaces
参考getting-started.md完成:
- 创建新的Blazor Web App Server项目
- 安装Syncfusion NuGet包
- 注册Syncfusion Blazor服务
- 添加所需的命名空间
2. Configure AI Service
2. 配置AI服务
Proceed to ai-service-configuration.md to:
- Choose your AI provider (OpenAI, Azure OpenAI, or Ollama)
- Install AI service-specific NuGet packages
- Configure your AI backend in
Program.cs - Add theme stylesheets and script resources
参考ai-service-configuration.md完成:
- 选择AI提供商(OpenAI、Azure OpenAI或Ollama)
- 安装AI服务专属的NuGet包
- 在中配置AI后端
Program.cs - 添加主题样式表与脚本资源
3. Implement and Customize
3. 实现与自定义
Complete with implementation-and-customization.md to:
- Add the Smart Paste Button component to your form
- Run and test the application
- Add custom field annotations
- Customize button appearance
- Integrate custom AI services
- Troubleshoot common issues
参考implementation-and-customization.md完成:
- 为表单添加Smart Paste Button组件
- 运行并测试应用程序
- 添加自定义字段注解
- 自定义按钮外观
- 集成自定义AI服务
- 排查常见问题
Key Features
核心功能
| Feature | Details |
|---|---|
| AI-Powered Form Filling | Reads clipboard text and maps data to form fields automatically |
| Multiple AI Backends | OpenAI, Azure OpenAI, Ollama, and custom |
| Field Annotations | |
| Easy Integration | Single NuGet package + |
| Customizable UI | Inherits all |
| 功能 | 详情 |
|---|---|
| AI驱动的表单填充 | 读取剪贴板文本并自动将数据映射到表单字段 |
| 多AI后端支持 | 支持OpenAI、Azure OpenAI、Ollama及自定义 |
| 字段注解 | 使用 |
| 轻松集成 | 只需单个NuGet包 + |
| 可自定义UI | 继承 |
NuGet Packages
NuGet包
- (v28.1.33+)
Syncfusion.Blazor.SmartComponents Syncfusion.Blazor.Themes- AI provider package — see ai-service-configuration.md
- (v28.1.33+)
Syncfusion.Blazor.SmartComponents Syncfusion.Blazor.Themes- AI提供商包——详见ai-service-configuration.md
Reference Documents
参考文档
| Document | Purpose |
|---|---|
| getting-started.md | Project creation, NuGet installation, service registration |
| ai-service-configuration.md | AI provider setup (OpenAI, Azure OpenAI, Ollama) |
| implementation-and-customization.md | Component usage, field annotations, customization, troubleshooting |
| 文档 | 用途 |
|---|---|
| getting-started.md | 项目创建、NuGet安装、服务注册 |
| ai-service-configuration.md | AI提供商设置(OpenAI、Azure OpenAI、Ollama) |
| implementation-and-customization.md | 组件使用、字段注解、自定义、故障排查 |