@ng-doc/utils 16.6.0 → 16.6.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +3 -0
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -15235,6 +15235,9 @@ function codeBlockLinesPlugin() {
|
|
|
15235
15235
|
return tree => {
|
|
15236
15236
|
visit(tree, 'element', (node, _i, parent) => {
|
|
15237
15237
|
if (parent?.type === 'element' && parent.tagName === 'pre' && node.tagName === 'code') {
|
|
15238
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
15239
|
+
// @ts-ignore
|
|
15240
|
+
node.properties['className'] = [...(node.properties?.['className'] ?? []), 'code-lines'];
|
|
15238
15241
|
// Wraps each line in a span
|
|
15239
15242
|
node.children = addLines(node);
|
|
15240
15243
|
// Adds a line break to the end of each line
|