Skip to content
Snippets Groups Projects
Commit f42565fb authored by chris's avatar chris
Browse files

info tool

parent e2ef2264
No related branches found
No related tags found
1 merge request!429Move components
...@@ -6,7 +6,5 @@ export { default as Icon } from './src/helpers/Icon'; ...@@ -6,7 +6,5 @@ export { default as Icon } from './src/helpers/Icon';
export { default as ToolGroupComponent } from './src/components/ToolGroupComponent'; export { default as ToolGroupComponent } from './src/components/ToolGroupComponent';
export { default as ToolGroups } from './src/components/ToolGroups'; export { default as ToolGroups } from './src/components/ToolGroups';
export { default as EditorInfoTool } from './src/components/EditorInfo/CounterInfo/EditorInfoTool';
export { default as Tabs } from './src/ui/tabs/Tabs'; export { default as Tabs } from './src/ui/tabs/Tabs';
export { default as BlockLevelTools } from './src/ui/tabs/BlockLevelTools'; export { default as BlockLevelTools } from './src/ui/tabs/BlockLevelTools';
import React from 'react'; import React from 'react';
import { isEmpty } from 'lodash'; import { isEmpty } from 'lodash';
import { injectable } from 'inversify'; import { injectable } from 'inversify';
import { EditorInfoTool } from 'wax-prosemirror-components';
import { Tools } from 'wax-prosemirror-core'; import { Tools } from 'wax-prosemirror-core';
import EditorInfoTool from './components/EditorInfoTool';
@injectable() @injectable()
class CounterInfoTool extends Tools { class CounterInfoTool extends Tools {
title = 'Counter Info'; title = 'Counter Info';
icon = 'highlight';
name = 'CounterInfo'; name = 'CounterInfo';
get run() { get run() {
...@@ -15,7 +14,7 @@ class CounterInfoTool extends Tools { ...@@ -15,7 +14,7 @@ class CounterInfoTool extends Tools {
} }
get enable() { get enable() {
return state => { return () => {
return true; return true;
}; };
} }
...@@ -24,7 +23,7 @@ class CounterInfoTool extends Tools { ...@@ -24,7 +23,7 @@ class CounterInfoTool extends Tools {
if (isEmpty(view)) return null; if (isEmpty(view)) return null;
// eslint-disable-next-line no-underscore-dangle // eslint-disable-next-line no-underscore-dangle
return this._isDisplayed ? ( return this._isDisplayed ? (
<EditorInfoTool key="CounterInfo" item={this.toJSON()} view={view} /> <EditorInfoTool item={this.toJSON()} key="CounterInfo" view={view} />
) : null; ) : null;
} }
} }
......
...@@ -14,7 +14,7 @@ import { ...@@ -14,7 +14,7 @@ import {
DocumentHelpers, DocumentHelpers,
useOnClickOutside, useOnClickOutside,
} from 'wax-prosemirror-core'; } from 'wax-prosemirror-core';
import MenuButton from '../../../ui/buttons/MenuButton'; import { MenuButton } from 'wax-prosemirror-components';
const Wrapper = styled.div` const Wrapper = styled.div`
font-size: 0; font-size: 0;
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment