Skip to content

Commit 853a2a7

Browse files
committed
lint
1 parent a7e9399 commit 853a2a7

File tree

1 file changed

+4
-7
lines changed
  • apps/sim/app/workspace/[workspaceId]/files/components/file-viewer

1 file changed

+4
-7
lines changed

apps/sim/app/workspace/[workspaceId]/files/components/file-viewer/file-viewer.tsx

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -716,13 +716,10 @@ function PptxPreview({
716716

717717
function toggleMarkdownCheckbox(markdown: string, targetIndex: number, checked: boolean): string {
718718
let currentIndex = 0
719-
return markdown.replace(
720-
/^(\s*(?:[-*+]|\d+[.)]) +)\[([ xX])\]/gm,
721-
(match, prefix: string) => {
722-
if (currentIndex++ !== targetIndex) return match
723-
return `${prefix}[${checked ? 'x' : ' '}]`
724-
}
725-
)
719+
return markdown.replace(/^(\s*(?:[-*+]|\d+[.)]) +)\[([ xX])\]/gm, (match, prefix: string) => {
720+
if (currentIndex++ !== targetIndex) return match
721+
return `${prefix}[${checked ? 'x' : ' '}]`
722+
})
726723
}
727724

728725
const UnsupportedPreview = memo(function UnsupportedPreview({

0 commit comments

Comments
 (0)