Skip to content
Snippets Groups Projects
Commit c9dc702e authored by David Siegfried's avatar David Siegfried
Browse files

fix vue-warnings, re #3829

Merge request studip/studip!2694
parent 10a6558a
Branches
No related tags found
No related merge requests found
...@@ -121,7 +121,7 @@ ...@@ -121,7 +121,7 @@
</td> </td>
<td class="document-icon"> <td class="document-icon">
<a :href="folder.url" :id="`folder-${folder.id}`"> <a :href="folder.url" :id="`folder-${folder.id}`">
<studip-icon :shape="folder.icon" role="clickable" size="26" class="text-bottom"></studip-icon> <studip-icon :shape="folder.icon" :size="26" class="text-bottom"></studip-icon>
</a> </a>
</td> </td>
<td :class="{'filter-match': valueMatchesFilter(folder.name)}"> <td :class="{'filter-match': valueMatchesFilter(folder.name)}">
...@@ -173,9 +173,9 @@ ...@@ -173,9 +173,9 @@
</td> </td>
<td class="document-icon"> <td class="document-icon">
<a v-if="file.download_url" :href="file.download_url" target="_blank" rel="noopener noreferrer"> <a v-if="file.download_url" :href="file.download_url" target="_blank" rel="noopener noreferrer">
<studip-icon :shape="file.icon" role="clickable" size="24" class="text-bottom"></studip-icon> <studip-icon :shape="file.icon" :size="24" class="text-bottom"></studip-icon>
</a> </a>
<studip-icon v-else :shape="file.icon" role="clickable" size="24"></studip-icon> <studip-icon v-else :shape="file.icon" :size="24"></studip-icon>
<a :href="file.download_url" <a :href="file.download_url"
v-if="file.download_url && file.mime_type.indexOf('image/') === 0" v-if="file.download_url && file.mime_type.indexOf('image/') === 0"
...@@ -188,7 +188,6 @@ ...@@ -188,7 +188,6 @@
<studip-icon v-if="file.isAccessible" <studip-icon v-if="file.isAccessible"
shape="accessibility" shape="accessibility"
role="info" role="info"
size="16"
style="vertical-align: text-bottom" style="vertical-align: text-bottom"
:title="$gettext('Diese Datei ist barrierefrei.')"></studip-icon> :title="$gettext('Diese Datei ist barrierefrei.')"></studip-icon>
</a> </a>
...@@ -196,7 +195,6 @@ ...@@ -196,7 +195,6 @@
<studip-icon v-if="file.restrictedTermsOfUse" <studip-icon v-if="file.restrictedTermsOfUse"
shape="lock-locked" shape="lock-locked"
role="info" role="info"
size="16"
:title="$gettext('Das Herunterladen dieser Datei ist nur eingeschränkt möglich.')"></studip-icon> :title="$gettext('Das Herunterladen dieser Datei ist nur eingeschränkt möglich.')"></studip-icon>
</td> </td>
......
...@@ -4,10 +4,10 @@ ...@@ -4,10 +4,10 @@
<label class="with-action"> <label class="with-action">
<input type="text" ref="searchInputField" v-model="searchTerm" :placeholder="$gettext('Suchen')" style="width: 260px;"> <input type="text" ref="searchInputField" v-model="searchTerm" :placeholder="$gettext('Suchen')" style="width: 260px;">
<a href="#" class="msp-btn" @click.prevent="search" :title="$gettext('Suche starten')"> <a href="#" class="msp-btn" @click.prevent="search" :title="$gettext('Suche starten')">
<studip-icon shape="search" role="clickable" size="16"></studip-icon> <studip-icon shape="search" />
</a> </a>
<a href="#" class="msp-btn" @click.prevent="resetSearch" :title="$gettext('Suche zurücksetzen')"> <a href="#" class="msp-btn" @click.prevent="resetSearch" :title="$gettext('Suche zurücksetzen')">
<studip-icon shape="decline" role="clickable" size="16"></studip-icon> <studip-icon shape="decline" />
</a> </a>
</label> </label>
<select multiple="multiple" :id="select_box_id" name="selectbox[]"></select> <select multiple="multiple" :id="select_box_id" name="selectbox[]"></select>
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
> >
<template #content> <template #content>
<div class="cw-keypoint-content" :class="['cw-keypoint-' + currentColor]"> <div class="cw-keypoint-content" :class="['cw-keypoint-' + currentColor]">
<studip-icon v-if="currentIcon" size="48" :shape="currentIcon" :role="currentRole" /> <studip-icon v-if="currentIcon" :size="48" :shape="currentIcon" :role="currentRole" />
<p class="cw-keypoint-sentence">{{ currentText }}</p> <p class="cw-keypoint-sentence">{{ currentText }}</p>
</div> </div>
</template> </template>
......
...@@ -50,7 +50,7 @@ export default { ...@@ -50,7 +50,7 @@ export default {
if (this.blocked && this.blockedByAnotherUser && this.userIsTeacher) { if (this.blocked && this.blockedByAnotherUser && this.userIsTeacher) {
menuItems.push({ menuItems.push({
id: 3, id: 4,
label: this.$gettext('Sperre aufheben'), label: this.$gettext('Sperre aufheben'),
icon: 'lock-unlocked', icon: 'lock-unlocked',
emit: 'removeLock', emit: 'removeLock',
......
...@@ -160,7 +160,7 @@ ...@@ -160,7 +160,7 @@
class="cw-container-item" class="cw-container-item"
/> />
</div> </div>
<div <div
v-if="isLink" v-if="isLink"
class="cw-container-wrapper" class="cw-container-wrapper"
...@@ -231,7 +231,7 @@ ...@@ -231,7 +231,7 @@
<studip-progress-indicator v-if="processing" :description="$gettext('Vorgang wird bearbeitet...')" /> <studip-progress-indicator v-if="processing" :description="$gettext('Vorgang wird bearbeitet...')" />
</div> </div>
</div> </div>
<courseware-toolbar v-if="canVisit && canEdit && !isLink" /> <courseware-toolbar v-if="canVisit && canEdit && !isLink" />
</div> </div>
<courseware-call-to-action-box <courseware-call-to-action-box
v-if="commentable" v-if="commentable"
...@@ -857,7 +857,7 @@ export default { ...@@ -857,7 +857,7 @@ export default {
if (this.parent) { if (this.parent) {
return this.childrenById(this.parent.id).length; return this.childrenById(this.parent.id).length;
} }
return 0; return 0;
}, },
...@@ -933,7 +933,7 @@ export default { ...@@ -933,7 +933,7 @@ export default {
return true; return true;
} }
} }
return false; return false;
}, },
...@@ -1125,13 +1125,13 @@ export default { ...@@ -1125,13 +1125,13 @@ export default {
menuItems() { menuItems() {
let menu = [ let menu = [
{ id: 4, label: this.$gettext('Informationen anzeigen'), icon: 'info', emit: 'showInfo' }, { id: 5, label: this.$gettext('Informationen anzeigen'), icon: 'info', emit: 'showInfo' },
{ id: 5, label: this.$gettext('Lesezeichen setzen'), icon: 'star', emit: 'setBookmark' }, { id: 6, label: this.$gettext('Lesezeichen setzen'), icon: 'star', emit: 'setBookmark' },
]; ];
if (this.isFeedbackActivated) { if (this.isFeedbackActivated) {
if (this.canCreateFeedbackElement && !this.hasFeedbackElement) { if (this.canCreateFeedbackElement && !this.hasFeedbackElement) {
menu.push({ menu.push({
id: 6, id: 7,
label: this.$gettext('Feedback aktivieren'), label: this.$gettext('Feedback aktivieren'),
icon: 'feedback', icon: 'feedback',
emit: 'showFeedbackCreate', emit: 'showFeedbackCreate',
...@@ -1139,7 +1139,7 @@ export default { ...@@ -1139,7 +1139,7 @@ export default {
} }
if (this.hasFeedbackElement) { if (this.hasFeedbackElement) {
menu.push({ menu.push({
id: 6, id: 7,
label: this.$gettext('Feedback anzeigen'), label: this.$gettext('Feedback anzeigen'),
icon: 'feedback', icon: 'feedback',
emit: 'showFeedback', emit: 'showFeedback',
...@@ -1149,14 +1149,14 @@ export default { ...@@ -1149,14 +1149,14 @@ export default {
if (this.oerEnableSuggestions && this.inCourse && this.userId !== this.structuralElement.relationships.owner.data.id) { if (this.oerEnableSuggestions && this.inCourse && this.userId !== this.structuralElement.relationships.owner.data.id) {
menu.push( menu.push(
{ id: 7, label: this.$gettext('Seite für OER Campus vorschlagen'), icon: 'oer-campus', { id: 8, label: this.$gettext('Seite für OER Campus vorschlagen'), icon: 'oer-campus',
emit: 'showSuggest' } emit: 'showSuggest' }
); );
} }
if (!document.documentElement.classList.contains('responsive-display')) { if (!document.documentElement.classList.contains('responsive-display')) {
menu.push( menu.push(
{ id: 8, label: this.$gettext('Als Vollbild anzeigen'), icon: 'screen-full', { id: 9, label: this.$gettext('Als Vollbild anzeigen'), icon: 'screen-full',
emit: 'activateFullscreen'}, emit: 'activateFullscreen'},
); );
} }
...@@ -1196,14 +1196,14 @@ export default { ...@@ -1196,14 +1196,14 @@ export default {
emit: 'removeLock', emit: 'removeLock',
}); });
} }
menu.push({ id: 3, label: this.$gettext('Seite hinzufügen'), icon: 'add', emit: 'addElement' }); menu.push({ id: 4, label: this.$gettext('Seite hinzufügen'), icon: 'add', emit: 'addElement' });
} }
if (this.context.type === 'users') { if (this.context.type === 'users') {
menu.push({ id: 9, label: this.$gettext('Öffentlichen Link erzeugen'), icon: 'group', emit: 'linkElement' }); menu.push({ id: 10, label: this.$gettext('Öffentlichen Link erzeugen'), icon: 'group', emit: 'linkElement' });
} }
if (this.deletable && this.canEdit && !this.isTask && !this.blocked) { if (this.deletable && this.canEdit && !this.isTask && !this.blocked) {
menu.push({ menu.push({
id: 10, id: 11,
label: this.$gettext('Seite löschen'), label: this.$gettext('Seite löschen'),
icon: 'trash', icon: 'trash',
emit: 'deleteCurrentElement', emit: 'deleteCurrentElement',
...@@ -1913,11 +1913,11 @@ export default { ...@@ -1913,11 +1913,11 @@ export default {
await this.loadFeedbackElement({ id: feedbackElementId, options: { include: 'entries' }}); await this.loadFeedbackElement({ id: feedbackElementId, options: { include: 'entries' }});
ratingPopupFeedbackElement = this.getFeedbackElementById({ id: feedbackElementId }); ratingPopupFeedbackElement = this.getFeedbackElementById({ id: feedbackElementId });
const hasUserEntry = this.feedbackEntries.filter( const hasUserEntry = this.feedbackEntries.filter(
(entry) => (entry) =>
parseInt(entry.relationships?.['feedback-element']?.data?.id) == feedbackElementId && parseInt(entry.relationships?.['feedback-element']?.data?.id) == feedbackElementId &&
this.currentUser.id === entry.relationships?.author?.data?.id this.currentUser.id === entry.relationships?.author?.data?.id
).length > 0; ).length > 0;
if (this.currentUser.id !== ratingPopupFeedbackElement?.relationships?.author?.data?.id && !hasUserEntry) { if (this.currentUser.id !== ratingPopupFeedbackElement?.relationships?.author?.data?.id && !hasUserEntry) {
showRatingPopup = true; showRatingPopup = true;
} else { } else {
...@@ -1938,7 +1938,7 @@ export default { ...@@ -1938,7 +1938,7 @@ export default {
return this.structuralElementById({ id: elem.id }); return this.structuralElementById({ id: elem.id });
} }
const parent = this.structuralElementById({ id: parentId }); const parent = this.structuralElementById({ id: parentId });
return this.findFirstLevelParent(parent); return this.findFirstLevelParent(parent);
}, },
submitFeedback() { submitFeedback() {
...@@ -2007,4 +2007,3 @@ export default { ...@@ -2007,4 +2007,3 @@ export default {
}), }),
}; };
</script> </script>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment