32 lines
1.3 KiB
JavaScript
32 lines
1.3 KiB
JavaScript
export default OakComponent({
|
||
entity: 'articleMenu',
|
||
isList: true,
|
||
methods: {
|
||
gotoDoc() {
|
||
const { onMenuView } = this.props;
|
||
onMenuView && onMenuView();
|
||
},
|
||
gotoArticleDetail(oakId) {
|
||
const { onArticleView } = this.props;
|
||
onArticleView && onArticleView(oakId);
|
||
},
|
||
},
|
||
properties: {
|
||
entity: '',
|
||
entityId: '',
|
||
show: 'edit', // edit为编辑,doc为查看,preview为预览
|
||
articleMenuId: '', // 菜单id
|
||
articleId: '', //文章id
|
||
tocPosition: 'none', //文章目录显示位置,none为不显示目录
|
||
highlightBgColor: 'none', //点击文章目录时标题高亮背景色,none为不显示高亮背景色
|
||
onMenuView: () => undefined, //查看全部菜单
|
||
onMenuViewById: (articleMenuId) => undefined, //查看指定id菜单
|
||
onArticleView: (oakId) => undefined, //查看文章
|
||
onArticlePreview: (content, title) => undefined, //预览文章
|
||
onArticleEdit: (oakId) => undefined, //编辑文章
|
||
setCopyArticleUrl: (id) => '',
|
||
origin: 'qiniu', // cos origin默认七牛云
|
||
scrollId: '', // 滚动条所在容器id,不传默认页面编辑器容器id
|
||
},
|
||
});
|