mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-23 05:17:02 -04:00
[skip ci] Revert "add react linting"
doesnt work properly :(
This reverts commit 18fdc33ee7
.
This commit is contained in:
parent
18fdc33ee7
commit
584885acf5
37 changed files with 97 additions and 884 deletions
|
@ -46,7 +46,7 @@ export const Code = ({
|
|||
.split("\n")
|
||||
.map((line, i) => <span key={i} dangerouslySetInnerHTML={{ __html: line }} />);
|
||||
} catch {
|
||||
lines = content.split("\n").map((line, i) => <span key={i}>{line}</span>);
|
||||
lines = content.split("\n").map(line => <span>{line}</span>);
|
||||
}
|
||||
} else {
|
||||
const renderTokens =
|
||||
|
@ -55,11 +55,11 @@ export const Code = ({
|
|||
.split("\n")
|
||||
.map(line => [{ color: theme.plainColor, content: line } as IThemedToken]);
|
||||
|
||||
lines = renderTokens.map((line, i) => {
|
||||
lines = renderTokens.map(line => {
|
||||
// [Cynthia] this makes it so when you highlight the codeblock
|
||||
// empty lines are also selected and copied when you Ctrl+C.
|
||||
if (line.length === 0) {
|
||||
return <span key={i}>{"\n"}</span>;
|
||||
return <span>{"\n"}</span>;
|
||||
}
|
||||
|
||||
return (
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
import ErrorBoundary from "@components/ErrorBoundary";
|
||||
import { useAwaiter, useIntersection } from "@utils/react";
|
||||
import { hljs } from "@webpack/common";
|
||||
import { hljs, React } from "@webpack/common";
|
||||
|
||||
import { resolveLang } from "../api/languages";
|
||||
import { shiki } from "../api/shiki";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue