diff options
author | Kristóf Marussy <kristof@marussy.com> | 2024-04-26 19:41:51 +0200 |
---|---|---|
committer | Kristóf Marussy <kristof@marussy.com> | 2024-04-26 19:41:51 +0200 |
commit | d75fa7a991a24e2c4fc3fbd66525acb02055727a (patch) | |
tree | a62b7a01081ce40cd15250d3619492525a27f49d | |
parent | fix(docs): missing license files (diff) | |
download | refinery-d75fa7a991a24e2c4fc3fbd66525acb02055727a.tar.gz refinery-d75fa7a991a24e2c4fc3fbd66525acb02055727a.tar.zst refinery-d75fa7a991a24e2c4fc3fbd66525acb02055727a.zip |
fix(docs): non-linear time regex
-rw-r--r-- | subprojects/docs/src/plugins/remarkPosix2Windows.ts | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/subprojects/docs/src/plugins/remarkPosix2Windows.ts b/subprojects/docs/src/plugins/remarkPosix2Windows.ts index 66baca30..784802f2 100644 --- a/subprojects/docs/src/plugins/remarkPosix2Windows.ts +++ b/subprojects/docs/src/plugins/remarkPosix2Windows.ts | |||
@@ -68,7 +68,10 @@ function createTabItem( | |||
68 | 68 | ||
69 | function transformNode(node: Code): MdxJsxFlowElement[] { | 69 | function transformNode(node: Code): MdxJsxFlowElement[] { |
70 | const posixCode = node.value; | 70 | const posixCode = node.value; |
71 | const windowsCode = posixCode.replaceAll(/(?<=^\w*)\.\//gm, '.\\'); | 71 | const windowsCode = posixCode.replaceAll( |
72 | /(^\w*)\.\//gm, | ||
73 | (_substring, prefix: string) => `${prefix}.\\`, | ||
74 | ); | ||
72 | return [ | 75 | return [ |
73 | { | 76 | { |
74 | type: 'mdxJsxFlowElement', | 77 | type: 'mdxJsxFlowElement', |