@ctgh/a2ui-arco 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +58 -0
- package/dist/a2ui-arco.css +3 -0
- package/dist/catalog/index.d.ts +23 -0
- package/dist/index.cjs +2 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +2776 -0
- package/dist/index.js.map +1 -0
- package/dist/plugin.d.ts +16 -0
- package/dist/renderers/iconMap.d.ts +2 -0
- package/dist/renderers/index.d.ts +20 -0
- package/dist/renderers/utils.d.ts +79 -0
- package/dist/surface/A2uiArcoSurface.d.ts +31 -0
- package/dist/theme/A2uiArcoProvider.vue.d.ts +18 -0
- package/package.json +50 -0
package/README.md
ADDED
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
# @ctgh/a2ui-arco
|
|
2
|
+
|
|
3
|
+
[A2UI](https://a2ui.org) Basic Catalog renderer using [Arco Design Vue](https://arco.design/vue).
|
|
4
|
+
|
|
5
|
+
Uses the same catalog schema as `@ctgh/a2ui-vue` (headless HTML); only the render layer is swapped to Arco components.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install @ctgh/a2ui-arco @arco-design/web-vue vue
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
Import Arco styles in your app entry:
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
import '@arco-design/web-vue/dist/arco.css';
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Usage
|
|
20
|
+
|
|
21
|
+
```ts
|
|
22
|
+
import { createApp } from 'vue';
|
|
23
|
+
import { A2uiArcoPlugin, arcoCatalog, MessageProcessor } from '@ctgh/a2ui-arco';
|
|
24
|
+
import '@arco-design/web-vue/dist/arco.css';
|
|
25
|
+
|
|
26
|
+
const app = createApp(App);
|
|
27
|
+
app.use(A2uiArcoPlugin);
|
|
28
|
+
|
|
29
|
+
const processor = new MessageProcessor([arcoCatalog]);
|
|
30
|
+
processor.processMessages([/* A2UI messages with basic catalogId */]);
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
Optional theme wrapper:
|
|
34
|
+
|
|
35
|
+
```vue
|
|
36
|
+
<script setup lang="ts">
|
|
37
|
+
import { A2uiArcoProvider, A2uiSurface, arcoCatalog, MessageProcessor } from '@ctgh/a2ui-arco';
|
|
38
|
+
</script>
|
|
39
|
+
|
|
40
|
+
<template>
|
|
41
|
+
<A2uiArcoProvider theme="light" primary-color="#165DFF">
|
|
42
|
+
<A2uiSurface :surface="surface" />
|
|
43
|
+
</A2uiArcoProvider>
|
|
44
|
+
</template>
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Component coverage
|
|
48
|
+
|
|
49
|
+
| A2UI | Renderer |
|
|
50
|
+
| --- | --- |
|
|
51
|
+
| Button, TextField, CheckBox, Modal, Tabs | Arco |
|
|
52
|
+
| ChoicePicker, Slider, DateTimeInput | Arco |
|
|
53
|
+
| Row, Column, Card, Divider, Text, Icon | Arco |
|
|
54
|
+
| Image, Video, AudioPlayer, List | Headless (`@ctgh/a2ui-vue`) |
|
|
55
|
+
|
|
56
|
+
## Playground
|
|
57
|
+
|
|
58
|
+
Monorepo playground → **Arco** tab compares gallery examples with Arco styling.
|