mirror of
https://github.com/cool-team-official/cool-admin-vue.git
synced 2025-12-13 06:02:49 +00:00
优化
This commit is contained in:
parent
10a2c19cdf
commit
72f4c591ce
@ -13,6 +13,7 @@ export declare interface ModuleConfig {
|
|||||||
author?: string;
|
author?: string;
|
||||||
updateTime?: string;
|
updateTime?: string;
|
||||||
demo?: { name: string; component: Component }[] | string;
|
demo?: { name: string; component: Component }[] | string;
|
||||||
|
doc?: string;
|
||||||
options?: {
|
options?: {
|
||||||
[key: string]: any;
|
[key: string]: any;
|
||||||
};
|
};
|
||||||
|
|||||||
@ -45,6 +45,8 @@
|
|||||||
flex: 1;
|
flex: 1;
|
||||||
|
|
||||||
.tag {
|
.tag {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
margin-bottom: 10px;
|
margin-bottom: 10px;
|
||||||
|
|
||||||
.el-tag {
|
.el-tag {
|
||||||
@ -89,6 +91,11 @@
|
|||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
height: 30px;
|
height: 30px;
|
||||||
|
|
||||||
|
.el-button {
|
||||||
|
font-size: 12px;
|
||||||
|
height: 28px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&.is-add {
|
&.is-add {
|
||||||
|
|||||||
@ -47,17 +47,14 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="f">
|
<div class="f">
|
||||||
<el-button round @click="toDetail(item)">详情</el-button>
|
<cl-switch v-model="item.status" @change="onStatusChange(item)" />
|
||||||
<el-button type="danger" round @click="toDel(item, index)"
|
|
||||||
>卸载</el-button
|
|
||||||
>
|
|
||||||
|
|
||||||
<cl-flex1 />
|
<cl-flex1 />
|
||||||
|
|
||||||
<cl-switch
|
<el-button type="danger" round @click="toDel(item, index)"
|
||||||
v-model="item.status"
|
>卸载</el-button
|
||||||
@change="onStatusChange(item)"
|
>
|
||||||
></cl-switch>
|
<el-button round @click="toDetail(item)">详情</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
|||||||
@ -44,13 +44,18 @@
|
|||||||
|
|
||||||
<div class="f">
|
<div class="f">
|
||||||
<cl-flex1 />
|
<cl-flex1 />
|
||||||
<el-button
|
<el-button round @click="det.open(item)" v-if="item.demo">
|
||||||
v-if="item.demo && !isEmpty(item.demo)"
|
|
||||||
round
|
|
||||||
@click="det.open(item)"
|
|
||||||
>
|
|
||||||
示例
|
示例
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
round
|
||||||
|
@click="det.openDoc(item.doc)"
|
||||||
|
v-if="item.doc"
|
||||||
|
>
|
||||||
|
文档
|
||||||
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
@ -63,6 +68,7 @@
|
|||||||
:key="index"
|
:key="index"
|
||||||
:label="item.name"
|
:label="item.name"
|
||||||
:name="index"
|
:name="index"
|
||||||
|
:lazy="index != 0"
|
||||||
>
|
>
|
||||||
<component :is="item.component" />
|
<component :is="item.component" />
|
||||||
</el-tab-pane>
|
</el-tab-pane>
|
||||||
@ -140,6 +146,10 @@ const det = reactive({
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
openDoc(url: string) {
|
||||||
|
window.open(url);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@ -17,6 +17,7 @@ export default (): Merge<ModuleConfig, CrudOptions> => {
|
|||||||
version: '1.1.2',
|
version: '1.1.2',
|
||||||
updateTime: '2024-12-31',
|
updateTime: '2024-12-31',
|
||||||
demo: '/demo/crud',
|
demo: '/demo/crud',
|
||||||
|
doc: 'https://vue.cool-admin.com/src/guide/plugins/crud.html',
|
||||||
|
|
||||||
// 组件全注册
|
// 组件全注册
|
||||||
components: Object.values(import.meta.glob('./components/**/*.{vue,tsx}')),
|
components: Object.values(import.meta.glob('./components/**/*.{vue,tsx}')),
|
||||||
|
|||||||
@ -9,7 +9,7 @@ export default (): ModuleConfig => {
|
|||||||
author: 'COOL',
|
author: 'COOL',
|
||||||
version: '1.0.0',
|
version: '1.0.0',
|
||||||
updateTime: '2024-07-22',
|
updateTime: '2024-07-22',
|
||||||
demo: 'https://echarts.apache.org/examples/zh/index.html',
|
doc: 'https://echarts.apache.org/examples/zh/index.html',
|
||||||
install(app) {
|
install(app) {
|
||||||
app.component('v-chart', VueECharts);
|
app.component('v-chart', VueECharts);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,10 +13,10 @@ export default (): ModuleConfig => {
|
|||||||
component: () => import('./demo/base.vue')
|
component: () => import('./demo/base.vue')
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
doc: 'https://www.npmjs.com/package/monaco-editor',
|
||||||
|
|
||||||
components: [
|
components: [
|
||||||
// 依赖偏大,现用于“ai编码页面”,如不需要请注释组件
|
// 依赖偏大,现用于“ai编码页面”,如不需要请注释组件
|
||||||
// 代码编辑器 https://www.npmjs.com/package/monaco-editor
|
|
||||||
() => import('./components/monaco.vue')
|
() => import('./components/monaco.vue')
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|||||||
@ -2,8 +2,8 @@ import type { ModuleConfig } from '/@/cool';
|
|||||||
|
|
||||||
export default (): ModuleConfig => {
|
export default (): ModuleConfig => {
|
||||||
return {
|
return {
|
||||||
label: '富文本编辑器',
|
label: 'Wang 编辑器',
|
||||||
description: '基于 wangEditor 封装的富文本编辑器', // https://www.wangeditor.com
|
description: '基于 wangEditor 封装的富文本编辑器',
|
||||||
author: 'COOL',
|
author: 'COOL',
|
||||||
version: '1.0.0',
|
version: '1.0.0',
|
||||||
updateTime: '2024-02-01',
|
updateTime: '2024-02-01',
|
||||||
@ -13,7 +13,7 @@ export default (): ModuleConfig => {
|
|||||||
component: () => import('./demo/base.vue')
|
component: () => import('./demo/base.vue')
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
doc: 'https://www.wangeditor.com',
|
||||||
components: [() => import('./components/wang.vue')]
|
components: [() => import('./components/wang.vue')]
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@ -10,7 +10,7 @@ export default (): ModuleConfig => {
|
|||||||
author: 'COOL',
|
author: 'COOL',
|
||||||
version: '1.0.0',
|
version: '1.0.0',
|
||||||
updateTime: '2024-07-22',
|
updateTime: '2024-07-22',
|
||||||
demo: 'https://element-plus.org/zh-CN/component/overview.html',
|
doc: 'https://element-plus.org/zh-CN/component/overview.html',
|
||||||
install(app) {
|
install(app) {
|
||||||
app.use(ElementPlus);
|
app.use(ElementPlus);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user