UNPKG

@uiw/react-md-editor

Version:

A markdown editor with preview, implemented with React.js and TypeScript.

24 lines (22 loc) 530 B
import * as React from 'react'; export var title2 = { name: 'title2', keyCommand: 'title2', buttonProps: { 'aria-label': 'Insert title2' }, icon: /*#__PURE__*/React.createElement("div", { style: { fontSize: 16, textAlign: 'left' } }, "Title 2"), execute: function execute(state, api) { var modifyText = "## ".concat(state.selectedText, "\n"); if (!state.selectedText) { modifyText = "## "; } api.replaceSelection(modifyText); } }; //# sourceMappingURL=title2.js.map