mirror of https://gitlab.com/octtspacc/sitoctt
Update content/it/admin.md
This commit is contained in:
parent
a5cf31a5fd
commit
952833b3fa
|
@ -4,19 +4,22 @@ Hidden = true
|
|||
<form name="admin">
|
||||
<fieldset name="git" disabled>
|
||||
<legend>Git Configuration</legend>
|
||||
<p><label>Instance URL: <input type="url" name="InstanceUrl"/></label></p>
|
||||
<p><label>Repository Path: <input type="text" name="RepoThis"/></label></p>
|
||||
<p><label>Branch Name: <input type="text" name="BranchThis"/></label></p>
|
||||
<p><label>Access Token: <input type="password" name="token" placeholder="***"/></label></p>
|
||||
<p><label>Instance URL: <input type="url" name="GitInstanceUrl"/></label></p>
|
||||
<p><label>Repository Path: <input type="text" name="GitRepoThis"/></label></p>
|
||||
<p><label>Branch Name: <input type="text" name="GitBranchThis"/></label></p>
|
||||
<p><label>Access Token: <input type="password" name="GitToken" placeholder="***"/></label></p>
|
||||
</fieldset>
|
||||
</form>
|
||||
<style> form[name="admin"] input { float: right; } </style>
|
||||
<style>
|
||||
form[name="admin"] label { white-space: nowrap; }
|
||||
form[name="admin"] input { float: right; }
|
||||
</style>
|
||||
<script>(() => {
|
||||
const formEl = document.querySelector('form[name="admin"]');
|
||||
const gitEl = formEl.querySelector('fieldset[name="git"]');
|
||||
const gitData = (sitoctt.localStorage('gitAuth') || {});
|
||||
for (const fieldEl of gitEl.querySelectorAll('input')) {
|
||||
fieldEl.placeholder ||= sitoctt.Props[`Git${fieldEl.name}`];
|
||||
fieldEl.placeholder ||= sitoctt.Props[fieldEl.name];
|
||||
fieldEl.value = (gitData[fieldEl.name] || '');
|
||||
fieldEl.oninput = fieldEl.onchange = fieldEl.onpaste = () => {
|
||||
gitData[fieldEl.name] = fieldEl.value;
|
||||
|
|
Loading…
Reference in New Issue