import/export settings to file

This commit is contained in:
Áron Hegymegi-Kiss
2022-01-08 19:03:46 +01:00
parent 90eaab4e50
commit dc560cd73e
3 changed files with 102 additions and 34 deletions

View File

@@ -460,6 +460,15 @@
"exportOptions": {
"message": "Import/Export All Options"
},
"exportOptionsCopy": {
"message": "Edit/copy"
},
"exportOptionsDownload": {
"message": "Save to file"
},
"exportOptionsUpload": {
"message": "Load from file"
},
"whatExportOptions": {
"message": "This is your entire configuration in JSON. This includes your userID, so be sure to share this wisely."
},

View File

@@ -355,8 +355,19 @@
</div>
<div data-type="private-text-change" data-sync="*" data-confirm-message="exportOptionsWarning">
<div class="option-button trigger-button">
__MSG_exportOptions__
<h2>__MSG_exportOptions__</h2>
<div>
<div class="option-button trigger-button inline">
__MSG_exportOptionsCopy__
</div>
<div class="option-button download-button inline">
__MSG_exportOptionsDownload__
</div>
<label for="importOptions" class="option-button inline">
__MSG_exportOptionsUpload__
</label>
<input id="importOptions" type="file" class="upload-button hidden" />
</div>
<div class="small-description">__MSG_whatExportOptions__</div>