fixed mail UI for redesign
parent
b822a74c53
commit
52c7ba860d
|
@ -11,6 +11,7 @@
|
||||||
<link rel='shortcut icon' type='image/ico' href='/shared/images/favicon.ico'>
|
<link rel='shortcut icon' type='image/ico' href='/shared/images/favicon.ico'>
|
||||||
<link rel='stylesheet' href='/shared/main/bulma.min.css'>
|
<link rel='stylesheet' href='/shared/main/bulma.min.css'>
|
||||||
<link rel="stylesheet" href="/shared/main/styles-new.css">
|
<link rel="stylesheet" href="/shared/main/styles-new.css">
|
||||||
|
<link rel="stylesheet" href="/shared/mail.css">
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
@ -50,7 +51,7 @@
|
||||||
Mail
|
Mail
|
||||||
</h1>
|
</h1>
|
||||||
<h2 class="subtitle">
|
<h2 class="subtitle">
|
||||||
Send email style messages to persons
|
Send email style messages
|
||||||
</h2>
|
</h2>
|
||||||
</div>
|
</div>
|
||||||
<div class="column is-7">
|
<div class="column is-7">
|
||||||
|
@ -81,7 +82,45 @@
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
|
<div id='messageDisplay' class='overlay'>
|
||||||
|
<div class='overlayContent'>
|
||||||
|
<span class='closeOverlay' overlay='messageDisplay'></span>
|
||||||
|
<div>
|
||||||
|
From: <input type='text' id='fromUser' readonly> Signature: <span id='sigValid'></span> <span
|
||||||
|
id='addUnknownContact'><button class='button is-primary'>Add to Contacts</button></span>
|
||||||
|
</div>
|
||||||
|
<div class='break-up'>
|
||||||
|
Subject: <span id='subjectView'></span>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<button id='replyBtn' class='primaryBtn break-up'>Reply</button>
|
||||||
|
</div>
|
||||||
|
<div id='signatureValidity'></div>
|
||||||
|
<div id='threadDisplay' class='pre messageContent'>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id='sentboxDisplay' class='overlay'>
|
||||||
|
<div class='overlayContent'>
|
||||||
|
<span class='closeOverlay' overlay='sentboxDisplay'></span>
|
||||||
|
To: <input id='toID' readonly type='text'>
|
||||||
|
<div id='sentboxDisplayText' class='pre messageContent'>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id='sendMessage' class='overlay'>
|
||||||
|
<div class='overlayContent'>
|
||||||
|
<label>Select friend: <select id='friendSelect'></select></label>
|
||||||
|
<form method='post' action='' id='sendForm' enctype="application/x-www-form-urlencoded">
|
||||||
|
<span class='closeOverlay' overlay='sendMessage'></span>
|
||||||
|
To: <input id='draftID' type='text' name='to' placeholder='pubkey' required>
|
||||||
|
Subject: <input name='subject' id='draftSubject' maxlength=25 type='text'
|
||||||
|
placeholder='message subject'>
|
||||||
|
<textarea name='message' placeholder='type your message...' id='draftText' required></textarea>
|
||||||
|
<input type='submit' value='Send' class='successBtn'>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<!--Start of content-->
|
<!--Start of content-->
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="tabs" id="tabBtns">
|
<div class="tabs" id="tabBtns">
|
||||||
|
@ -103,58 +142,18 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
<div class='content'>
|
||||||
|
<div class='mailPing'>
|
||||||
|
API server either shutdown, has disabled mail, or has experienced a bug.
|
||||||
|
</div>
|
||||||
|
<div id='threads' class='threads'>
|
||||||
|
<div id='threadPlaceholder'>Nothing here yet 😞</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<div id="infoOverlay" class='overlay'>
|
<div id="infoOverlay" class='overlay'>
|
||||||
</div>
|
</div>
|
||||||
<div class='content'>
|
|
||||||
<div class='mailPing'>
|
|
||||||
API server either shutdown, has disabled mail, or has experienced a bug.
|
|
||||||
</div>
|
|
||||||
<div id='threads' class='threads'>
|
|
||||||
<div id='threadPlaceholder'>Nothing here yet 😞</div>
|
|
||||||
</div>
|
|
||||||
<div id='messageDisplay' class='overlay'>
|
|
||||||
<div class='overlayContent'>
|
|
||||||
<span class='closeOverlay' overlay='messageDisplay'></span>
|
|
||||||
<div>
|
|
||||||
From: <input type='text' id='fromUser' readonly> Signature: <span id='sigValid'></span> <span
|
|
||||||
id='addUnknownContact'><button>Add to Contacts</button></span>
|
|
||||||
</div>
|
|
||||||
<div class='break-up'>
|
|
||||||
Subject: <span id='subjectView'></span>
|
|
||||||
</div>
|
|
||||||
<div>
|
|
||||||
<button id='replyBtn' class='primaryBtn break-up'>Reply</button>
|
|
||||||
</div>
|
|
||||||
<div id='signatureValidity'></div>
|
|
||||||
<div id='threadDisplay' class='pre messageContent'>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div id='sentboxDisplay' class='overlay'>
|
|
||||||
<div class='overlayContent'>
|
|
||||||
<span class='closeOverlay' overlay='sentboxDisplay'></span>
|
|
||||||
To: <input id='toID' readonly type='text'>
|
|
||||||
<div id='sentboxDisplayText' class='pre messageContent'>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div id='sendMessage' class='overlay'>
|
|
||||||
<div class='overlayContent'>
|
|
||||||
<label>Select friend: <select id='friendSelect'></select></label>
|
|
||||||
<form method='post' action='' id='sendForm' enctype="application/x-www-form-urlencoded">
|
|
||||||
<span class='closeOverlay' overlay='sendMessage'></span>
|
|
||||||
To: <input id='draftID' type='text' name='to' placeholder='pubkey' required>
|
|
||||||
Subject: <input name='subject' id='draftSubject' maxlength=25 type='text'
|
|
||||||
placeholder='message subject'>
|
|
||||||
<textarea name='message' placeholder='type your message...' id='draftText' required></textarea>
|
|
||||||
<input type='submit' value='Send' class='successBtn'>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<script src='/shared/misc.js'></script>
|
<script src='/shared/misc.js'></script>
|
||||||
<script src='/mail/mail.js'></script>
|
<script src='/mail/mail.js'></script>
|
||||||
<script src='/mail/sendmail.js'></script>
|
<script src='/mail/sendmail.js'></script>
|
||||||
|
|
|
@ -182,7 +182,7 @@ function loadInboxEntries(bHash){
|
||||||
}
|
}
|
||||||
entry.setAttribute('data-nameSet', true)
|
entry.setAttribute('data-nameSet', true)
|
||||||
if (senderInput.value == ''){
|
if (senderInput.value == ''){
|
||||||
senderInput.value = resp['meta']['signer']
|
senderInput.value = resp['meta']['signer'] || 'Anonymous'
|
||||||
entry.setAttribute('data-nameSet', false)
|
entry.setAttribute('data-nameSet', false)
|
||||||
}
|
}
|
||||||
bHashDisplay.innerText = bHash.substring(0, 10)
|
bHashDisplay.innerText = bHash.substring(0, 10)
|
||||||
|
@ -190,8 +190,7 @@ function loadInboxEntries(bHash){
|
||||||
entry.setAttribute('data-pubkey', resp['meta']['signer'])
|
entry.setAttribute('data-pubkey', resp['meta']['signer'])
|
||||||
senderInput.readOnly = true
|
senderInput.readOnly = true
|
||||||
dateStr.innerText = humanDate.substring(0, humanDate.indexOf('('))
|
dateStr.innerText = humanDate.substring(0, humanDate.indexOf('('))
|
||||||
deleteBtn.innerText = 'X'
|
deleteBtn.classList.add('delete', 'deleteBtn')
|
||||||
deleteBtn.classList.add('dangerBtn', 'deleteBtn')
|
|
||||||
if (metadata['subject'] === undefined || metadata['subject'] === null) {
|
if (metadata['subject'] === undefined || metadata['subject'] === null) {
|
||||||
subjectLine.innerText = '()'
|
subjectLine.innerText = '()'
|
||||||
}
|
}
|
||||||
|
@ -268,8 +267,7 @@ function getSentbox(){
|
||||||
var preview = document.createElement('span')
|
var preview = document.createElement('span')
|
||||||
var deleteBtn = document.createElement('button')
|
var deleteBtn = document.createElement('button')
|
||||||
var message = resp[i]['message']
|
var message = resp[i]['message']
|
||||||
deleteBtn.classList.add('deleteBtn', 'dangerBtn')
|
deleteBtn.classList.add('deleteBtn', 'delete')
|
||||||
deleteBtn.innerText = 'X'
|
|
||||||
toEl.readOnly = true
|
toEl.readOnly = true
|
||||||
sentDate.innerText = humanDate.substring(0, humanDate.indexOf('('))
|
sentDate.innerText = humanDate.substring(0, humanDate.indexOf('('))
|
||||||
if (resp[i]['name'] == null || resp[i]['name'].toLowerCase() == 'anonymous'){
|
if (resp[i]['name'] == null || resp[i]['name'].toLowerCase() == 'anonymous'){
|
||||||
|
@ -279,6 +277,7 @@ function getSentbox(){
|
||||||
toEl.value = resp[i]['name']
|
toEl.value = resp[i]['name']
|
||||||
}
|
}
|
||||||
preview.innerText = '(' + resp[i]['subject'] + ')'
|
preview.innerText = '(' + resp[i]['subject'] + ')'
|
||||||
|
entry.classList.add('sentboxList')
|
||||||
entry.setAttribute('data-hash', resp[i]['hash'])
|
entry.setAttribute('data-hash', resp[i]['hash'])
|
||||||
entry.appendChild(deleteBtn)
|
entry.appendChild(deleteBtn)
|
||||||
entry.appendChild(toLabel)
|
entry.appendChild(toLabel)
|
||||||
|
|
|
@ -0,0 +1,32 @@
|
||||||
|
.threadEntry{
|
||||||
|
margin-bottom: 2%;
|
||||||
|
}
|
||||||
|
.threadEntry button{
|
||||||
|
margin-right: 1%;
|
||||||
|
}
|
||||||
|
.threadEntry span, .sentboxList span{
|
||||||
|
padding-left: 1%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.overlayContent{
|
||||||
|
background-color: lightgray;
|
||||||
|
border: 3px solid black;
|
||||||
|
border-radius: 3px;
|
||||||
|
color: black;
|
||||||
|
font-family: Verdana, Geneva, Tahoma, sans-serif;
|
||||||
|
min-height: 100%;
|
||||||
|
padding: 1em;
|
||||||
|
margin: 1em;
|
||||||
|
}
|
||||||
|
|
||||||
|
#draftText{
|
||||||
|
margin-top: 1em;
|
||||||
|
margin-bottom: 1em;
|
||||||
|
display: block;
|
||||||
|
width: 50%;
|
||||||
|
height: 75%;
|
||||||
|
min-width: 2%;
|
||||||
|
min-height: 5%;
|
||||||
|
background: white;
|
||||||
|
color: black;
|
||||||
|
}
|
Loading…
Reference in New Issue