1 | 'use strict';
|
2 |
|
3 | Object.defineProperty(exports, "__esModule", {
|
4 | value: true
|
5 | });
|
6 |
|
7 | var _options = require('./options');
|
8 |
|
9 | var _options2 = _interopRequireDefault(_options);
|
10 |
|
11 | var _utils = require('./utils');
|
12 |
|
13 | var _changes = require('./changes');
|
14 |
|
15 | var _validation = require('./validation');
|
16 |
|
17 | function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 | function core(optsParam) {
|
24 | var opts = new _options2.default(optsParam);
|
25 |
|
26 | return {
|
27 | schema: (0, _validation.schema)(opts),
|
28 |
|
29 | changes: {
|
30 | unwrapCodeBlockByKey: _changes.unwrapCodeBlockByKey.bind(null, opts),
|
31 | wrapCodeBlockByKey: _changes.wrapCodeBlockByKey.bind(null, opts),
|
32 | wrapCodeBlock: _changes.wrapCodeBlock.bind(null, opts),
|
33 | unwrapCodeBlock: _changes.unwrapCodeBlock.bind(null, opts),
|
34 | toggleCodeBlock: _changes.toggleCodeBlock.bind(null, opts)
|
35 | },
|
36 |
|
37 | utils: {
|
38 | isInCodeBlock: _utils.isInCodeBlock.bind(null, opts),
|
39 | deserializeCode: _utils.deserializeCode.bind(null, opts)
|
40 | }
|
41 | };
|
42 | }
|
43 |
|
44 | exports.default = core; |
\ | No newline at end of file |