somewhat better import-export tab + minor fixes
This commit is contained in:
parent
b3bf4fca75
commit
db73631459
7 changed files with 73 additions and 65 deletions
|
|
@ -23,6 +23,9 @@
|
||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.exporter {
|
.exporter {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
|
||||||
&-processing {
|
&-processing {
|
||||||
margin: 0.25em;
|
margin: 0.25em;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div class="importer">
|
<div class="importer btn-group">
|
||||||
<form>
|
<form>
|
||||||
<input
|
<input
|
||||||
ref="input"
|
ref="input"
|
||||||
|
|
@ -19,7 +19,7 @@
|
||||||
class="btn button-default"
|
class="btn button-default"
|
||||||
@click="submit"
|
@click="submit"
|
||||||
>
|
>
|
||||||
{{ submitButtonLabel || $t('importer.submit') }}
|
{{ submitButtonLabel || $t('importer.import') }}
|
||||||
</button>
|
</button>
|
||||||
<div v-if="success">
|
<div v-if="success">
|
||||||
<button
|
<button
|
||||||
|
|
|
||||||
|
|
@ -77,15 +77,14 @@
|
||||||
<div
|
<div
|
||||||
v-if="isLoggedIn"
|
v-if="isLoggedIn"
|
||||||
:label="$t('settings.mutes_and_blocks')"
|
:label="$t('settings.mutes_and_blocks')"
|
||||||
:fullHeight="true"
|
|
||||||
icon="eye-slash"
|
icon="eye-slash"
|
||||||
data-tab-name="mutesAndBlocks"
|
data-tab-name="mutesAndBlocks"
|
||||||
|
:full-width="true"
|
||||||
>
|
>
|
||||||
<MutesAndBlocksTab />
|
<MutesAndBlocksTab />
|
||||||
</div>
|
</div>
|
||||||
<div
|
<div
|
||||||
:label="$t('settings.clutter')"
|
:label="$t('settings.clutter')"
|
||||||
:fullHeight="true"
|
|
||||||
icon="broom"
|
icon="broom"
|
||||||
data-tab-name="clutter"
|
data-tab-name="clutter"
|
||||||
>
|
>
|
||||||
|
|
@ -96,6 +95,7 @@
|
||||||
:label="$t('settings.security_tab')"
|
:label="$t('settings.security_tab')"
|
||||||
icon="lock"
|
icon="lock"
|
||||||
data-tab-name="security"
|
data-tab-name="security"
|
||||||
|
:full-width="true"
|
||||||
>
|
>
|
||||||
<SecurityTab />
|
<SecurityTab />
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -113,6 +113,7 @@
|
||||||
icon="palette"
|
icon="palette"
|
||||||
data-tab-name="style"
|
data-tab-name="style"
|
||||||
:delay-render="true"
|
:delay-render="true"
|
||||||
|
:full-width="true"
|
||||||
>
|
>
|
||||||
<StyleTab />
|
<StyleTab />
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -122,6 +123,7 @@
|
||||||
icon="paint-brush"
|
icon="paint-brush"
|
||||||
data-tab-name="theme"
|
data-tab-name="theme"
|
||||||
:delay-render="true"
|
:delay-render="true"
|
||||||
|
:full-width="true"
|
||||||
>
|
>
|
||||||
<OldThemeTab />
|
<OldThemeTab />
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -2,4 +2,10 @@
|
||||||
h3 {
|
h3 {
|
||||||
margin-right: -2em;
|
margin-right: -2em;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.importer-exporter {
|
||||||
|
display: inline-flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0.5em;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,57 +4,57 @@
|
||||||
:label="$t('settings.data_import_export_tab')"
|
:label="$t('settings.data_import_export_tab')"
|
||||||
>
|
>
|
||||||
<div class="setting-item">
|
<div class="setting-item">
|
||||||
<h3>{{ $t('settings.follow_import') }}</h3>
|
<h3>{{ $t('settings.import_export.title') }}</h3>
|
||||||
<p>{{ $t('settings.import_followers_from_a_csv_file') }}</p>
|
<ul class="setting-list">
|
||||||
<Importer
|
<li>
|
||||||
:submit-handler="importFollows"
|
<h4>{{ $t('settings.import_export.follows') }}</h4>
|
||||||
:success-message="$t('settings.follows_imported')"
|
<p>{{ $t('settings.import_followers_from_a_csv_file') }}</p>
|
||||||
:error-message="$t('settings.follow_import_error')"
|
<div class="importer-exporter">
|
||||||
/>
|
<Importer
|
||||||
</div>
|
:submit-handler="importFollows"
|
||||||
<div class="setting-item">
|
:success-message="$t('settings.follows_imported')"
|
||||||
<h3>{{ $t('settings.follow_export') }}</h3>
|
:error-message="$t('settings.follow_import_error')"
|
||||||
<Exporter
|
/>
|
||||||
:get-content="getFollowsContent"
|
<Exporter
|
||||||
filename="friends.csv"
|
:get-content="getFollowsContent"
|
||||||
:export-button-label="$t('settings.follow_export_button')"
|
filename="friends.csv"
|
||||||
/>
|
:export-button-label="$t('settings.follow_export_button')"
|
||||||
</div>
|
/>
|
||||||
<div class="setting-item">
|
</div>
|
||||||
<h3>{{ $t('settings.block_import') }}</h3>
|
</li>
|
||||||
<p>{{ $t('settings.import_blocks_from_a_csv_file') }}</p>
|
<li>
|
||||||
<Importer
|
<h4>{{ $t('settings.import_export.mutes') }}</h4>
|
||||||
:submit-handler="importBlocks"
|
<p>{{ $t('settings.import_mutes_from_a_csv_file') }}</p>
|
||||||
:success-message="$t('settings.blocks_imported')"
|
<div class="importer-exporter">
|
||||||
:error-message="$t('settings.block_import_error')"
|
<Importer
|
||||||
/>
|
:submit-handler="importMutes"
|
||||||
</div>
|
:success-message="$t('settings.mutes_imported')"
|
||||||
<div class="setting-item">
|
:error-message="$t('settings.mute_import_error')"
|
||||||
<h3>{{ $t('settings.block_export') }}</h3>
|
/>
|
||||||
<Exporter
|
<Exporter
|
||||||
:get-content="getBlocksContent"
|
:get-content="getMutesContent"
|
||||||
filename="blocks.csv"
|
filename="friends.csv"
|
||||||
:export-button-label="$t('settings.block_export_button')"
|
:export-button-label="$t('settings.mute_export_button')"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div class="setting-item">
|
</li>
|
||||||
<h3>{{ $t('settings.mute_import') }}</h3>
|
<li>
|
||||||
<p>{{ $t('settings.import_mutes_from_a_csv_file') }}</p>
|
<h4>{{ $t('settings.import_export.blocks') }}</h4>
|
||||||
<Importer
|
<p>{{ $t('settings.import_blocks_from_a_csv_file') }}</p>
|
||||||
:submit-handler="importMutes"
|
<div class="importer-exporter">
|
||||||
:success-message="$t('settings.mutes_imported')"
|
<Importer
|
||||||
:error-message="$t('settings.mute_import_error')"
|
:submit-handler="importBlocks"
|
||||||
/>
|
:success-message="$t('settings.blocks_imported')"
|
||||||
</div>
|
:error-message="$t('settings.block_import_error')"
|
||||||
<div class="setting-item">
|
/>
|
||||||
<h3>{{ $t('settings.mute_export') }}</h3>
|
<Exporter
|
||||||
<Exporter
|
:get-content="getBlocksContent"
|
||||||
:get-content="getMutesContent"
|
filename="friends.csv"
|
||||||
filename="mutes.csv"
|
:export-button-label="$t('settings.block_export_button')"
|
||||||
:export-button-label="$t('settings.mute_export_button')"
|
/>
|
||||||
/>
|
</div>
|
||||||
</div>
|
</li>
|
||||||
<div class="setting-item">
|
</ul>
|
||||||
<h3>{{ $t('settings.account_backup') }}</h3>
|
<h3>{{ $t('settings.account_backup') }}</h3>
|
||||||
<p>{{ $t('settings.account_backup_description') }}</p>
|
<p>{{ $t('settings.account_backup_description') }}</p>
|
||||||
<table>
|
<table>
|
||||||
|
|
|
||||||
|
|
@ -68,16 +68,6 @@
|
||||||
&.-hidden {
|
&.-hidden {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.-full-height:not(.-hidden) {
|
|
||||||
height: 100%;
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
|
|
||||||
> *:not(.tab-content-label) {
|
|
||||||
flex: 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -132,6 +132,7 @@
|
||||||
},
|
},
|
||||||
"importer": {
|
"importer": {
|
||||||
"submit": "Submit",
|
"submit": "Submit",
|
||||||
|
"import": "Import",
|
||||||
"success": "Imported successfully.",
|
"success": "Imported successfully.",
|
||||||
"error": "An error occured while importing this file."
|
"error": "An error occured while importing this file."
|
||||||
},
|
},
|
||||||
|
|
@ -603,6 +604,12 @@
|
||||||
"follow_export_button": "Export your follows to a csv file",
|
"follow_export_button": "Export your follows to a csv file",
|
||||||
"follow_import": "Follow import",
|
"follow_import": "Follow import",
|
||||||
"follow_import_error": "Error importing followers",
|
"follow_import_error": "Error importing followers",
|
||||||
|
"import_export": {
|
||||||
|
"title": "Import / Export",
|
||||||
|
"follows": "List of users you follow",
|
||||||
|
"blocks": "List of users you block",
|
||||||
|
"mutes": "List of users you mute"
|
||||||
|
},
|
||||||
"follows_imported": "Follows imported! Processing them will take a while.",
|
"follows_imported": "Follows imported! Processing them will take a while.",
|
||||||
"accent": "Accent",
|
"accent": "Accent",
|
||||||
"foreground": "Foreground",
|
"foreground": "Foreground",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue