summaryrefslogtreecommitdiff
path: root/packages/frontend/src/components/MkCaptcha.vue
diff options
context:
space:
mode:
authorsyuilo <4439005+syuilo@users.noreply.github.com>2025-03-20 19:00:09 +0900
committersyuilo <4439005+syuilo@users.noreply.github.com>2025-03-20 19:00:09 +0900
commit6015254e59ba0526efbfa139c89546458663ccbd (patch)
tree97adc609448eb3ce96730051193042c9eec470db /packages/frontend/src/components/MkCaptcha.vue
parentUpdate eslint.config.js (diff)
downloadmisskey-6015254e59ba0526efbfa139c89546458663ccbd.tar.gz
misskey-6015254e59ba0526efbfa139c89546458663ccbd.tar.bz2
misskey-6015254e59ba0526efbfa139c89546458663ccbd.zip
lint fixes
Diffstat (limited to 'packages/frontend/src/components/MkCaptcha.vue')
-rw-r--r--packages/frontend/src/components/MkCaptcha.vue6
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/frontend/src/components/MkCaptcha.vue b/packages/frontend/src/components/MkCaptcha.vue
index e4f953bda8..30940a34a9 100644
--- a/packages/frontend/src/components/MkCaptcha.vue
+++ b/packages/frontend/src/components/MkCaptcha.vue
@@ -112,7 +112,7 @@ watch(() => [props.instanceUrl, props.sitekey, props.secretKey], async () => {
if (loaded || props.provider === 'mcaptcha' || props.provider === 'testcaptcha') {
available.value = true;
} else if (src.value !== null) {
- (document.getElementById(scriptId.value) ?? document.head.appendChild(Object.assign(document.createElement('script'), {
+ (window.document.getElementById(scriptId.value) ?? window.document.head.appendChild(Object.assign(window.document.createElement('script'), {
async: true,
id: scriptId.value,
src: src.value,
@@ -149,7 +149,7 @@ async function requestRender() {
if (captcha.value.render && captchaEl.value instanceof Element && props.sitekey) {
// reCAPTCHAのレンダリング重複判定を回避するため、captchaEl配下に仮のdivを用意する.
// (同じdivに対して複数回renderを呼び出すとreCAPTCHAはエラーを返すので)
- const elem = document.createElement('div');
+ const elem = window.document.createElement('div');
captchaEl.value.appendChild(elem);
captchaWidgetId.value = captcha.value.render(elem, {
@@ -174,7 +174,7 @@ async function requestRender() {
function clearWidget() {
if (props.provider === 'mcaptcha') {
- const container = document.getElementById('mcaptcha__widget-container');
+ const container = window.document.getElementById('mcaptcha__widget-container');
if (container) {
container.innerHTML = '';
}