Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
import React, { useState } from 'react';
import type React from 'react';
import { useState } from 'react';

import styles from '../styles.module.css';

// Custom component for button text
function ButtonText({ isLoading, isCopied }: { isLoading: boolean; isCopied: boolean }) {
if (isLoading) {
return <>Copying...</>;
return 'Copying...';
}
if (isCopied) {
return <>Copied!</>;
return 'Copied!';
}
return <>Copy for LLM</>;
return 'Copy for LLM';
}

export default function CopyForLLM() {
Expand Down
2 changes: 1 addition & 1 deletion apify-docs-theme/src/theme/MDXComponents/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import LLMButtons from '@site/src/components/LLMButtons';
import Admonition from '@theme/Admonition';
import LLMButtons from '@theme/LLMButtons';
import MDXA from '@theme/MDXComponents/A';
import MDXCode from '@theme/MDXComponents/Code';
import MDXDetails from '@theme/MDXComponents/Details';
Expand Down
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions src/theme/DocItem/Content/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@ import { useDoc } from '@docusaurus/plugin-content-docs/client';
import { useLocation } from '@docusaurus/router';
import { ThemeClassNames } from '@docusaurus/theme-common';
import Heading from '@theme/Heading';
import LLMButtons from '@theme/LLMButtons';
import MDXContent from '@theme/MDXContent';
import clsx from 'clsx';
import React from 'react';

import LLMButtons from '../../../components/LLMButtons';

function useSyntheticTitle() {
const { metadata, frontMatter, contentTitle } = useDoc();
const shouldRender = !frontMatter.hide_title && typeof contentTitle === 'undefined';
Expand Down
3 changes: 2 additions & 1 deletion tsconfig.eslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"src/**/*.js",
"src/**/*.ts",
"src/**/*.jsx",
"src/**/*.tsx"
"src/**/*.tsx",
"apify-docs-theme/**/*.tsx"
]
}