Merge branch 'master' of https://github.com/mathuo/dockview into 100-docs

This commit is contained in:
mathuo 2022-05-29 17:50:19 +01:00
commit 28f77ac3ae
No known key found for this signature in database
GPG Key ID: C6EEDEFD6CA07281
2 changed files with 29 additions and 1 deletions

View File

@ -12,7 +12,7 @@ console.log(`isCI: ${process.env.CI}`);
const config = {
title: 'Dockview',
tagline: 'Zero dependency layout manager for React',
url: 'https://your-docusaurus-test-site.com',
url: 'https://dockview.dev',
baseUrl: process.env.CI ? `/` : '/',
onBrokenLinks: 'throw',
onBrokenMarkdownLinks: 'warn',
@ -87,6 +87,28 @@ const config = {
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
metadata: [
{
name: 'keywords',
content: [
'react',
'components',
'typescript',
'drag-and-drop',
'reactjs',
'layout',
'drag',
'drop',
'tabs',
'dock',
'docking',
'splitter',
'docking-library',
'layout-manager',
'docking-layout',
].join(' ,'),
},
],
navbar: {
title: 'Dockview',
logo: {

View File

@ -98,12 +98,18 @@ export const ContextMenuDockview = () => {
});
};
const onContextMenu = (event: TabContextMenuEvent) => {
event.event.preventDefault();
alert(`Content appear event fired for panel ${event.panel.id}`);
};
return (
<DockviewReact
components={components}
tabComponents={tabComponents}
onReady={onReady}
className="dockview-theme-dark"
onTabContextMenu={onContextMenu}
/>
);
};