(options)
| 2518 | }; |
| 2519 | |
| 2520 | function readOptions(options) { |
| 2521 | options = options || {}; |
| 2522 | return _.extend({}, standardOptions, options, { |
| 2523 | customStyleMap: readStyleMap(options.styleMap), |
| 2524 | readStyleMap: function() { |
| 2525 | var styleMap = this.customStyleMap; |
| 2526 | if (this.includeEmbeddedStyleMap) { |
| 2527 | styleMap = styleMap.concat(readStyleMap(this.embeddedStyleMap)); |
| 2528 | } |
| 2529 | if (this.includeDefaultStyleMap) { |
| 2530 | styleMap = styleMap.concat(defaultStyleMap); |
| 2531 | } |
| 2532 | return styleMap; |
| 2533 | } |
| 2534 | }); |
| 2535 | } |
| 2536 | |
| 2537 | function readStyleMap(styleMap) { |
| 2538 | if (!styleMap) { |
no test coverage detected