Fixed ESLINT error
This commit is contained in:
parent
403106c48a
commit
bab17d47e0
|
@ -335,6 +335,7 @@ query getLibraryItem($slug: String, $language_code: String) {
|
|||
subtype {
|
||||
data {
|
||||
attributes {
|
||||
slug
|
||||
titles(
|
||||
filters: { language: { code: { eq: $language_code } } }
|
||||
) {
|
||||
|
|
|
@ -486,6 +486,7 @@ export type GetLibraryItemQuery = {
|
|||
__typename: "VideoSubtypeEntity";
|
||||
attributes: {
|
||||
__typename: "VideoSubtype";
|
||||
slug: string;
|
||||
titles: Array<{
|
||||
__typename: "ComponentTranslationsSimpleTitle";
|
||||
title: string;
|
||||
|
|
|
@ -65,8 +65,10 @@ export default function Editor(props: EditorProps): JSX.Element {
|
|||
paste = paste.replace(/<\!--.*?-->/g, "");
|
||||
paste = turndownService.turndown(paste);
|
||||
paste = paste.replace(/<\!--.*?-->/g, "");
|
||||
event.target.value = paste;
|
||||
event.target.select();
|
||||
|
||||
const target = event.target as HTMLTextAreaElement;
|
||||
target.value = paste;
|
||||
target.select();
|
||||
event.preventDefault();
|
||||
}}
|
||||
className="bg-mid rounded-xl p-8 w-full font-monospace"
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import {
|
||||
GetLibraryItemQuery,
|
||||
GetLibraryItemsPreviewQuery,
|
||||
GetWebsiteInterfaceQuery,
|
||||
} from "graphql/operations-types";
|
||||
|
@ -49,7 +50,9 @@ export function prettyinlineTitle(
|
|||
}
|
||||
|
||||
export function prettyItemType(
|
||||
metadata: GetLibraryItemsPreviewQuery["libraryItems"]["data"][number]["attributes"]["metadata"][number],
|
||||
metadata: {
|
||||
__typename: GetLibraryItemsPreviewQuery["libraryItems"]["data"][number]["attributes"]["metadata"][number]["__typename"]
|
||||
},
|
||||
langui: GetWebsiteInterfaceQuery["websiteInterfaces"]["data"][number]["attributes"]
|
||||
): string {
|
||||
const type = metadata.__typename;
|
||||
|
|
Loading…
Reference in New Issue