zotero: remove zotero API key textbox

COOL is now capable of handling and storing zotero key
This PR only removes the textbox because the actual zotero
key will be reused and transferred to COOL

removing all the zotero fields will require user to reenter the key
relevant COOL PRs:
https://github.com/CollaboraOnline/online/pull/12694
https://github.com/CollaboraOnline/online/pull/13091

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
This commit is contained in:
Pranam Lashkari 2025-10-06 10:26:47 +05:30
parent 5c793da393
commit ef5009aa5b

View file

@ -34,47 +34,6 @@
</em>
</p>
<!-- Zotero -->
<div class="zotero-section">
<p><strong>{{ t('richdocuments', 'Zotero') }}</strong></p>
<template v-if="hasZoteroSupport">
<div class="input-wrapper">
<div class="zotero-inline">
<div class="zotero-input-wrapper">
<NcTextField id="zoteroAPIKeyField"
:value="zoteroAPIKey"
:label="t('richdocuments', 'Enter Zotero API Key')"
@update:value="setZoteroAPIKey" />
</div>
<NcButton id="zoteroAPIKeySave"
type="secondary"
@click="saveZoteroAPIKey">
{{ t('richdocuments', 'Save') }}
</NcButton>
<NcButton id="zoteroAPIKeyRemove"
type="secondary"
:title="t('richdocuments', 'Remove Zotero API Key')"
@click="resetZoteroAPI">
<DeleteIcon :size="20" />
</NcButton>
</div>
<p>
<em>
{{ t('richdocuments', 'To use Zotero specify your API key here. You can create your API key in your') }}
<a href="https://www.zotero.org/settings/keys" target="_blank">
{{ t('richdocuments', 'Zotero account API settings.') }}
</a>
</em>
</p>
</div>
</template>
<p v-else>
<em>
{{ t('richdocuments', 'This instance does not support Zotero, because the feature is missing or disabled. Please contact the administration.') }}
</em>
</p>
</div>
<!-- Document signing -->
<div class="docsign-section">
<p class="doc_sign_head">
@ -158,7 +117,6 @@ export default {
data() {
return {
templateFolder: this.initial.templateFolder || '',
hasZoteroSupport: this.initial.hasZoteroSupport || false,
hasSettingIframeSupport: this.initial.hasSettingIframeSupport || false,
settingIframeUrl: this.initial.setting_iframe_url || '',
zoteroAPIKey: this.initial.zoteroAPIKey || '',
@ -202,9 +160,6 @@ export default {
console.error('Failed to generate token for admin settings')
}
},
setZoteroAPIKey(newVal) {
this.zoteroAPIKey = newVal
},
async onTemplateSelectButtonClick() {
OC.dialogs.filepicker(
this.t('richdocuments', 'Select a personal template folder'),
@ -226,15 +181,6 @@ export default {
this.templateFolder = ''
}
},
async saveZoteroAPIKey() {
await this.updateSetting({ zoteroAPIKeyInput: this.zoteroAPIKey })
},
async resetZoteroAPI() {
const success = await this.updateSetting({ zoteroAPIKeyInput: '' })
if (success) {
this.zoteroAPIKey = ''
}
},
async setDocumentSigningCert(val) {
const success = await this.updateSetting({ documentSigningCertInput: val })
if (success) {
@ -296,16 +242,6 @@ export default {
gap: 1rem;
}
.zotero-section p {
margin-top: 5px !important;
}
.zotero-inline {
display: flex;
align-items: center;
gap: 1rem;
}
.doc_sign_head {
padding-top: 10px;
padding-bottom: 5px;