From 6e60de420528d475d40618a87e0e5c78d86c90a9 Mon Sep 17 00:00:00 2001 From: KinfeMichael Tariku <65047246+Kinfe123@users.noreply.github.com> Date: Mon, 8 Sep 2025 19:15:49 +0300 Subject: [PATCH] docs: remove copy button from disabled code blocks (#4516) --- docs/components/api-method.tsx | 2 ++ docs/components/ui/dynamic-code-block.tsx | 11 ++++++++++- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/docs/components/api-method.tsx b/docs/components/api-method.tsx index bb918cd8..bc498b6e 100644 --- a/docs/components/api-method.tsx +++ b/docs/components/api-method.tsx @@ -144,6 +144,7 @@ export const APIMethod = ({ noResult ? "" : `const ${resultVariable} = ` }await auth.api.${functionName}(${serverBody});${code_suffix}`} lang="ts" + allowCopy={!isClientOnly} /> ); @@ -243,6 +244,7 @@ export const APIMethod = ({ }, error } = ` }await authClient.${authClientMethodPath}(${clientBody});${code_suffix}`} lang="ts" + allowCopy={!isServerOnly} /> {isServerOnly ? (