File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed
Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 1+ import { EditV2 } from './editv2.js' ;
2+ import { Transactor } from './Transactor.js' ;
3+
4+ /**
5+ * OpenSCD core communicates the data necessary for editing SCL documents by setting the
6+ * following [properties](https://developer.mozilla.org/en-US/docs/Glossary/Property/JavaScript) on
7+ * the plugin's [DOM Element](https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement)
8+ *
9+ * @property docs - A map of document names to their loaded XMLDocument instances.
10+ * @property doc - The XMLDocument currently being edited, if any.
11+ * @property docName - The name of the currently edited document, if any.
12+ * @property docsState - changes value when the document is modified or documents are added/removed.
13+ * @property locale - The end user's selected locale.
14+ */
15+ export interface Plugin {
16+ editor : Transactor < EditV2 > ;
17+ docs : Record < string , XMLDocument > ;
18+ doc ?: XMLDocument ; // the document currently being edited
19+ docName ?: string ; // the current doc's name
20+ docsState : unknown ; // current doc's state indicator
21+ locale : string ; // the end user's chosen locale
22+ }
You can’t perform that action at this time.
0 commit comments