Translate federation components
This commit is contained in:
parent
be3e6d70a3
commit
eb1c4ff1b2
|
@ -7,41 +7,39 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<span class="right floated" v-if="following">
|
<span class="right floated" v-if="following">
|
||||||
<i class="check icon"></i> Following
|
<i class="check icon"></i><i18next path="Following"/>
|
||||||
</span>
|
</span>
|
||||||
<span class="right floated" v-else-if="manuallyApprovesFollowers">
|
<span class="right floated" v-else-if="manuallyApprovesFollowers">
|
||||||
<i class="lock icon"></i> Followers only
|
<i class="lock icon"></i><i18next path="Followers only"/>
|
||||||
</span>
|
</span>
|
||||||
<span class="right floated" v-else>
|
<span class="right floated" v-else>
|
||||||
<i class="open lock icon"></i> Open
|
<i class="open lock icon"></i><i18next path="Open"/>
|
||||||
</span>
|
</span>
|
||||||
<span v-if="totalItems">
|
<span v-if="totalItems">
|
||||||
<i class="music icon"></i>
|
<i class="music icon"></i>
|
||||||
{{ totalItems }} tracks
|
<i18next path="{%0%} tracks">
|
||||||
|
{{ totalItems }}
|
||||||
|
</i18next>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="extra content">
|
<div class="extra content">
|
||||||
<template v-if="awaitingApproval">
|
<template v-if="awaitingApproval">
|
||||||
<i class="clock icon"></i>
|
<i class="clock icon"></i>
|
||||||
Follow request pending approval
|
<i18next path="Follow request pending approval"/>
|
||||||
</template>
|
</template>
|
||||||
<div
|
<div
|
||||||
v-if="!library"
|
v-if="!library"
|
||||||
@click="follow"
|
@click="follow"
|
||||||
:disabled="isLoading"
|
:disabled="isLoading"
|
||||||
:class="['ui', 'basic', {loading: isLoading}, 'green', 'button']">
|
:class="['ui', 'basic', {loading: isLoading}, 'green', 'button']">
|
||||||
<template v-if="manuallyApprovesFollowers">
|
<i18next v-if="manuallyApprovesFollowers" path="Send a follow request"/>
|
||||||
Send a follow request
|
<i18next v-else path="Follow">
|
||||||
</template>
|
|
||||||
<template v-else>
|
|
||||||
Follow
|
|
||||||
</template>
|
|
||||||
</div>
|
</div>
|
||||||
<router-link
|
<router-link
|
||||||
v-else
|
v-else
|
||||||
class="ui basic button"
|
class="ui basic button"
|
||||||
:to="{name: 'federation.libraries.detail', params: {id: library.uuid }}">
|
:to="{name: 'federation.libraries.detail', params: {id: library.uuid }}">
|
||||||
Detail
|
<i18next path="Detail"/>
|
||||||
</router-link>
|
</router-link>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -8,7 +8,7 @@
|
||||||
<div class="ui four wide inline field">
|
<div class="ui four wide inline field">
|
||||||
<div class="ui checkbox">
|
<div class="ui checkbox">
|
||||||
<input v-model="pending" type="checkbox">
|
<input v-model="pending" type="checkbox">
|
||||||
<label>Pending approval</label>
|
<label><i18next path="Pending approval"/></label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -17,10 +17,10 @@
|
||||||
<table v-if="result" class="ui very basic single line unstackable table">
|
<table v-if="result" class="ui very basic single line unstackable table">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Actor</th>
|
<i18next tag="th" path="Actor"/>
|
||||||
<th>Creation date</th>
|
<i18next tag="th" path="Creation date"/>
|
||||||
<th>Status</th>
|
<i18next tag="th" path="Status"/>
|
||||||
<th>Actions</th>
|
<i18next tag="th" path="Actions"/>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
@ -33,27 +33,36 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<template v-if="follow.approved === true">
|
<template v-if="follow.approved === true">
|
||||||
<i class="check icon"></i> Approved
|
<i class="check icon"></i><i18next path="Approved"/>
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="follow.approved === false">
|
<template v-else-if="follow.approved === false">
|
||||||
<i class="x icon"></i> Refused
|
<i class="x icon"></i><i18next path="Refused"/>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<i class="clock icon"></i> Pending
|
<i class="clock icon"></i><i18next path="Pending"/>
|
||||||
</template>
|
</template>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<dangerous-button v-if="follow.approved !== false" class="tiny basic labeled icon" color='red' @confirm="updateFollow(follow, false)">
|
<dangerous-button v-if="follow.approved !== false" class="tiny basic labeled icon" color='red' @confirm="updateFollow(follow, false)">
|
||||||
<i class="x icon"></i> Deny
|
<i class="x icon"></i><i18next path="Deny"/>
|
||||||
<p slot="modal-header">Deny access?</p>
|
<p slot="modal-header"><i18next path="Deny access?"/></p>
|
||||||
<p slot="modal-content">By confirming, {{ follow.actor.preferred_username }}@{{ follow.actor.domain }} will be denied access to your library.</p>
|
<p slot="modal-content">
|
||||||
<p slot="modal-confirm">Deny</p>
|
<i18next path="By confirming, {%0%}@{%1%} will be denied access to your library.">
|
||||||
|
{{ follow.actor.preferred_username }}
|
||||||
|
{{ follow.actor.domain }}
|
||||||
|
</i18next>
|
||||||
|
</p>
|
||||||
|
<p slot="modal-confirm"><i18next path="Deny"/></p>
|
||||||
</dangerous-button>
|
</dangerous-button>
|
||||||
<dangerous-button v-if="follow.approved !== true" class="tiny basic labeled icon" color='green' @confirm="updateFollow(follow, true)">
|
<dangerous-button v-if="follow.approved !== true" class="tiny basic labeled icon" color='green' @confirm="updateFollow(follow, true)">
|
||||||
<i class="x icon"></i> Approve
|
<i class="x icon"></i> <i18next path="Approve"/>
|
||||||
<p slot="modal-header">Approve access?</p>
|
<p slot="modal-header"><i18next path="Approve access?"/></p>
|
||||||
<p slot="modal-content">By confirming, {{ follow.actor.preferred_username }}@{{ follow.actor.domain }} will be granted access to your library.</p>
|
<p slot="modal-content">
|
||||||
<p slot="modal-confirm">Approve</p>
|
<i18next path="By confirming, {%0%}@{%1%} will be granted access to your library.">
|
||||||
|
{{ follow.actor.preferred_username }}
|
||||||
|
{{ follow.actor.domain }}
|
||||||
|
</i18next>
|
||||||
|
<p slot="modal-confirm"><i18next path="Approve"/></p>
|
||||||
</dangerous-button>
|
</dangerous-button>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -71,7 +80,12 @@
|
||||||
></pagination>
|
></pagination>
|
||||||
</th>
|
</th>
|
||||||
<th v-if="result && result.results.length > 0">
|
<th v-if="result && result.results.length > 0">
|
||||||
Showing results {{ ((page-1) * paginateBy) + 1 }}-{{ ((page-1) * paginateBy) + result.results.length }} on {{ result.count }}</th>
|
<i18next path="Showing results {%0%}-{%1%} on {%2%}">
|
||||||
|
{{ ((page-1) * paginateBy) + 1 }}
|
||||||
|
{{ ((page-1) * paginateBy) + result.results.length }}
|
||||||
|
{{ result.count }}
|
||||||
|
</i18next>
|
||||||
|
</th>
|
||||||
<th></th>
|
<th></th>
|
||||||
<th></th>
|
<th></th>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
<template>
|
<template>
|
||||||
<form class="ui form" @submit.prevent="fetchInstanceInfo">
|
<form class="ui form" @submit.prevent="fetchInstanceInfo">
|
||||||
<h3 class="ui header">Federate with a new instance</h3>
|
<h3 class="ui header"><i18next path="Federate with a new instance"/></h3>
|
||||||
<p>Use this form to scan an instance and setup federation.</p>
|
<p><i18next path="Use this form to scan an instance and setup federation."/></p>
|
||||||
<div v-if="errors.length > 0 || scanErrors.length > 0" class="ui negative message">
|
<div v-if="errors.length > 0 || scanErrors.length > 0" class="ui negative message">
|
||||||
<div class="header">Error while scanning library</div>
|
<div class="header"><i18next path="Error while scanning library"/></div>
|
||||||
<ul class="list">
|
<ul class="list">
|
||||||
<li v-for="error in errors">{{ error }}</li>
|
<li v-for="error in errors">{{ error }}</li>
|
||||||
<li v-for="error in scanErrors">{{ error }}</li>
|
<li v-for="error in scanErrors">{{ error }}</li>
|
||||||
|
@ -11,7 +11,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="ui two fields">
|
<div class="ui two fields">
|
||||||
<div class="ui field">
|
<div class="ui field">
|
||||||
<label>Library name</label>
|
<label><i18next path="Library name"/></label>
|
||||||
<input v-model="libraryUsername" type="text" placeholder="library@demo.funkwhale.audio" />
|
<input v-model="libraryUsername" type="text" placeholder="library@demo.funkwhale.audio" />
|
||||||
</div>
|
</div>
|
||||||
<div class="ui field">
|
<div class="ui field">
|
||||||
|
@ -21,7 +21,7 @@
|
||||||
:disabled="isLoading"
|
:disabled="isLoading"
|
||||||
:class="['ui', 'icon', {loading: isLoading}, 'button']">
|
:class="['ui', 'icon', {loading: isLoading}, 'button']">
|
||||||
<i class="search icon"></i>
|
<i class="search icon"></i>
|
||||||
Launch scan
|
<i18next path="Launch scan"/>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -14,11 +14,11 @@
|
||||||
:checked="result.results.length === checked.length"><label> </label>
|
:checked="result.results.length === checked.length"><label> </label>
|
||||||
</div>
|
</div>
|
||||||
</th>
|
</th>
|
||||||
<th>Title</th>
|
<i18next tag="th" path="Title"/>
|
||||||
<th>Artist</th>
|
<i18next tag="th" path="Artist"/>
|
||||||
<th>Album</th>
|
<i18next tag="th" path="Album"/>
|
||||||
<th>Published date</th>
|
<i18next tag="th" path="Published date"/>
|
||||||
<th v-if="showLibrary">Library</th>
|
<i18next tag="th" v-if="showLibrary" path="Library"/>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
@ -31,7 +31,7 @@
|
||||||
:checked="checked.indexOf(track.id) > -1"><label> </label>
|
:checked="checked.indexOf(track.id) > -1"><label> </label>
|
||||||
</div>
|
</div>
|
||||||
<div v-else class="ui label">
|
<div v-else class="ui label">
|
||||||
In library
|
<i18next path="In library"/>
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
|
@ -65,17 +65,22 @@
|
||||||
|
|
||||||
</th>
|
</th>
|
||||||
<th v-if="result && result.results.length > 0">
|
<th v-if="result && result.results.length > 0">
|
||||||
Showing results {{ ((page-1) * paginateBy) + 1 }}-{{ ((page-1) * paginateBy) + result.results.length }} on {{ result.count }}</th>
|
<i18next path="Showing results {%0%}-{%1%} on {%2%}">
|
||||||
|
{{ ((page-1) * paginateBy) + 1 }}
|
||||||
|
{{ ((page-1) * paginateBy) + result.results.length }}
|
||||||
|
{{ result.count }}
|
||||||
|
</i18next>
|
||||||
<th>
|
<th>
|
||||||
<button
|
<button
|
||||||
@click="launchImport"
|
@click="launchImport"
|
||||||
:disabled="checked.length === 0 || isImporting"
|
:disabled="checked.length === 0 || isImporting"
|
||||||
:class="['ui', 'green', {loading: isImporting}, 'button']">Import {{ checked.length }} tracks
|
:class="['ui', 'green', {loading: isImporting}, 'button']">
|
||||||
|
<i18next path="Import {%count%} tracks" :count="checked.length"/>
|
||||||
</button>
|
</button>
|
||||||
<router-link
|
<router-link
|
||||||
v-if="importBatch"
|
v-if="importBatch"
|
||||||
:to="{name: 'library.import.batches.detail', params: {id: importBatch.id }}">
|
:to="{name: 'library.import.batches.detail', params: {id: importBatch.id }}">
|
||||||
Import #{{ importBatch.id }} launched
|
<i18next path="Import #{%id%} launched" :id="importBatch.id"/>
|
||||||
</router-link>
|
</router-link>
|
||||||
</th>
|
</th>
|
||||||
<th></th>
|
<th></th>
|
||||||
|
|
Loading…
Reference in New Issue