Migrate chart view editors to plugin architecture - #361
Conversation
johnny-hausman
left a comment
There was a problem hiding this comment.
Just a little reworking on the hard links and good to go.
|
|
||
| export default function FNAbviewchartEditor({ AB, ABViewEditorPlugin }) { | ||
| const FABViewContainer = | ||
| require("../../../rootPages/Designer/editors/views/ABViewContainer").default; |
There was a problem hiding this comment.
there is an FABViewContainer available in the passed in resources that is the /rootPages/Designer/properties/views/ABViewContainer.
instead of making a hard link like this:
- update the
ABDesigner/index.jsto include theeditors/views/ABViewContainerin the ABDesignResources variable. Make itFABViewContainerEditorto distinguish it from the current one. - reference that in the passed in resources.
There was a problem hiding this comment.
Yes, I've updated it.
| const ABViewContainer = FABViewContainer(AB); | ||
| const BASE_ID = "interface_editor_viewchart"; | ||
|
|
||
| const ABAbviewchartEditor = class ABAbviewchartEditor extends ABViewContainer { |
There was a problem hiding this comment.
can we remove the constant here and just define the class? They are both named the same thing.
| ABViewPropertiesPlugin, | ||
| }) { | ||
| const FABViewContainer = | ||
| require("../../../rootPages/Designer/properties/views/ABViewContainer").default; |
There was a problem hiding this comment.
this is already available in the passed in resources as FABViewContainer
| const ABViewContainer = FABViewContainer(AB); | ||
| const uiConfig = AB.Config.uiSettings(); | ||
| const L = ABViewContainer.L(); | ||
| const ABAbviewchartProperties = class ABAbviewchartProperties extends ABViewContainer { |
There was a problem hiding this comment.
can we not have 2 things named the same thing? lets just use the class definition and not the constant.
…odularity in chart editors and properties
Migrate chart view editors to plugin architecture