aboutsummaryrefslogtreecommitdiffstats
path: root/web_src/js/markup/codecopy.ts
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2024-11-11 12:13:57 +0100
committerGitHub <noreply@github.com>2024-11-11 11:13:57 +0000
commitf35e2b0cd1aaee389e4efda5a54976520b9bd4cb (patch)
tree46f9420ce0e1486f20c4733f184e005c2df09168 /web_src/js/markup/codecopy.ts
parentf888e45432ccb86b18e6709fbd25223e07f2c422 (diff)
downloadgitea-f35e2b0cd1aaee389e4efda5a54976520b9bd4cb.tar.gz
gitea-f35e2b0cd1aaee389e4efda5a54976520b9bd4cb.zip
Fix a number of typescript issues (#32459)
Fixes 69 typescript errors found in the `admin` and `markup` folders. --------- Co-authored-by: Giteabot <teabot@gitea.io>
Diffstat (limited to 'web_src/js/markup/codecopy.ts')
-rw-r--r--web_src/js/markup/codecopy.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/web_src/js/markup/codecopy.ts b/web_src/js/markup/codecopy.ts
index 0fac4a0a39..f45b7a8e04 100644
--- a/web_src/js/markup/codecopy.ts
+++ b/web_src/js/markup/codecopy.ts
@@ -1,13 +1,13 @@
import {svg} from '../svg.ts';
-export function makeCodeCopyButton() {
+export function makeCodeCopyButton(): HTMLButtonElement {
const button = document.createElement('button');
button.classList.add('code-copy', 'ui', 'button');
button.innerHTML = svg('octicon-copy');
return button;
}
-export function renderCodeCopy() {
+export function renderCodeCopy(): void {
const els = document.querySelectorAll('.markup .code-block code');
if (!els.length) return;