@atlaskit/editor-plugin-help-dialog
Version:
Help Dialog plugin for @atlaskit/editor-core
19 lines (18 loc) • 553 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.openHelpCommand = exports.closeHelpCommand = void 0;
var _pluginKey = require("./plugin-key");
var openHelpCommand = exports.openHelpCommand = function openHelpCommand(tr, dispatch) {
tr = tr.setMeta(_pluginKey.pluginKey, true);
if (dispatch) {
dispatch(tr);
return true;
}
return false;
};
var closeHelpCommand = exports.closeHelpCommand = function closeHelpCommand(tr, dispatch) {
tr = tr.setMeta(_pluginKey.pluginKey, false);
dispatch(tr);
};