SHA256
Вынести дефолтный сервер в конфиг UI и оживить счетчик пароля
This commit is contained in:
@@ -56,12 +56,12 @@
|
||||
<h2>Данные сервера</h2>
|
||||
<div class="field">
|
||||
<label>Логин сервера</label>
|
||||
<input type="text" id="login" placeholder="shineupme" maxlength="20" />
|
||||
<input type="text" id="login" placeholder="Логин сервера" maxlength="20" />
|
||||
<div class="hint">Только a-z, 0-9, _ · без точки · макс. 20 символов</div>
|
||||
</div>
|
||||
<div class="field">
|
||||
<label>Адрес сервера (URL)</label>
|
||||
<input type="text" id="serverAddress" placeholder="shineup.me" />
|
||||
<input type="text" id="serverAddress" placeholder="Адрес сервера" />
|
||||
</div>
|
||||
<div class="field">
|
||||
<label>Серверы синхронизации (sync_servers)</label>
|
||||
|
||||
@@ -16,6 +16,7 @@ import {
|
||||
validateLoginOrThrow,
|
||||
wireDeviceAddressPreview,
|
||||
} from './server-ui-shared.js';
|
||||
import { defaultServerAddress, defaultServerLogin } from '../../js/deploy-config.js';
|
||||
|
||||
const fieldMap = {
|
||||
masterSecret: 'masterSecret',
|
||||
@@ -34,6 +35,8 @@ const fieldMap = {
|
||||
setupPasswordEye($('btnEye'), $('password'));
|
||||
wireDeviceAddressPreview(fieldMap);
|
||||
$('password').value = '';
|
||||
$('login').placeholder = defaultServerLogin;
|
||||
$('serverAddress').placeholder = defaultServerAddress;
|
||||
|
||||
$('btnTopupDevnet').addEventListener('click', () => {
|
||||
try {
|
||||
|
||||
@@ -22,6 +22,7 @@ import {
|
||||
validateLoginOrThrow,
|
||||
wireDeviceAddressPreview,
|
||||
} from './server-ui-shared.js';
|
||||
import { defaultServerAddress, defaultServerLogin } from '../../js/deploy-config.js';
|
||||
|
||||
const fieldMap = {
|
||||
masterSecret: 'masterSecret',
|
||||
@@ -97,6 +98,8 @@ function renderComparisonStatus() {
|
||||
setupPasswordEye($('btnEye'), $('password'));
|
||||
wireDeviceAddressPreview(fieldMap);
|
||||
$('password').value = '';
|
||||
$('login').placeholder = defaultServerLogin;
|
||||
$('serverAddress').placeholder = defaultServerAddress;
|
||||
resetExpectedKeysUi();
|
||||
|
||||
$('btnTopupDevnet').addEventListener('click', () => {
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
<h2>Загрузить существующую PDA</h2>
|
||||
<div class="field">
|
||||
<label>Логин сервера</label>
|
||||
<input type="text" id="login" placeholder="shineupme" maxlength="20" />
|
||||
<input type="text" id="login" placeholder="Логин сервера" maxlength="20" />
|
||||
</div>
|
||||
<div class="btn-row">
|
||||
<button class="btn-secondary" id="btnLoad">Загрузить PDA</button>
|
||||
@@ -86,7 +86,7 @@
|
||||
<h2>Новые параметры сервера</h2>
|
||||
<div class="field">
|
||||
<label>Новый адрес сервера (URL)</label>
|
||||
<input type="text" id="serverAddress" placeholder="shineup.me" />
|
||||
<input type="text" id="serverAddress" placeholder="Адрес сервера" />
|
||||
</div>
|
||||
<div class="field">
|
||||
<label>Новые серверы синхронизации (sync_servers)</label>
|
||||
|
||||
Reference in New Issue
Block a user