Aesthetic UI updates
This commit is contained in:
parent
d02f474fd1
commit
1fde82bd81
|
@ -24,14 +24,16 @@
|
||||||
$: upgradeUrl = `${$admin.accountPortalUrl}/portal/upgrade`
|
$: upgradeUrl = `${$admin.accountPortalUrl}/portal/upgrade`
|
||||||
|
|
||||||
// LICENSE KEY
|
// LICENSE KEY
|
||||||
|
|
||||||
$: activateDisabled = !licenseKey || licenseKeyDisabled
|
$: activateDisabled = !licenseKey || licenseKeyDisabled
|
||||||
let licenseKeyDisabled = false
|
let licenseKeyDisabled = false
|
||||||
let licenseKeyType = "text"
|
let licenseKeyType = "text"
|
||||||
let licenseKey = ""
|
let licenseKey = ""
|
||||||
let deleteLicenseKeyModal
|
let deleteLicenseKeyModal
|
||||||
|
|
||||||
// OFFLINE LICENSE
|
// OFFLINE
|
||||||
let installationIdentifier = undefined
|
|
||||||
|
let installationIdentifier = "aW5zdGFsbGF0aW9uSWQ9M2MwYmYyZjMtOGJlZi00YTBkLTllN2UtZTU4NmUxMDg2ZjVhLGluc3RhbGxhdGlvblRlbmFudElkPWU5ZWUwNDI0LTE4N2UtNDNhMS1hMDY1LTNiODhmZmE4YzJhZg==\n"
|
||||||
let offlineLicense = undefined
|
let offlineLicense = undefined
|
||||||
const offlineLicenseExtensions = [
|
const offlineLicenseExtensions = [
|
||||||
".txt",
|
".txt",
|
||||||
|
@ -108,9 +110,9 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async function activateOfflineLicense(offlineLicense) {
|
async function activateOfflineLicense(offlineLicenseToken) {
|
||||||
try {
|
try {
|
||||||
await API.activateOfflineLicense({ offlineLicense })
|
await API.activateOfflineLicense({ offlineLicenseToken })
|
||||||
await auth.getSelf()
|
await auth.getSelf()
|
||||||
await getOfflineLicense()
|
await getOfflineLicense()
|
||||||
notifications.success("Successfully activated")
|
notifications.success("Successfully activated")
|
||||||
|
@ -134,10 +136,16 @@
|
||||||
|
|
||||||
async function onOfflineLicenseChange(event) {
|
async function onOfflineLicenseChange(event) {
|
||||||
if (event.detail) {
|
if (event.detail) {
|
||||||
|
// prevent file preview jitter by assigning constant
|
||||||
|
// as soon as possible
|
||||||
|
offlineLicense = {
|
||||||
|
name: "license"
|
||||||
|
}
|
||||||
const reader = new FileReader()
|
const reader = new FileReader()
|
||||||
reader.readAsText(event.detail)
|
reader.readAsText(event.detail)
|
||||||
reader.onload = () => activateOfflineLicense(reader.result)
|
reader.onload = () => activateOfflineLicense(reader.result)
|
||||||
} else {
|
} else {
|
||||||
|
offlineLicense = undefined
|
||||||
await deleteOfflineLicense()
|
await deleteOfflineLicense()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -178,6 +186,7 @@
|
||||||
{:else}
|
{:else}
|
||||||
To manage your plan visit your
|
To manage your plan visit your
|
||||||
<Link size="L" href={upgradeUrl}>account</Link>
|
<Link size="L" href={upgradeUrl}>account</Link>
|
||||||
|
<div> </div>
|
||||||
{/if}
|
{/if}
|
||||||
</Body>
|
</Body>
|
||||||
</Layout>
|
</Layout>
|
||||||
|
@ -270,7 +279,7 @@
|
||||||
}
|
}
|
||||||
.field {
|
.field {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: 100px 1fr;
|
grid-template-columns: 300px 1fr;
|
||||||
grid-gap: var(--spacing-l);
|
grid-gap: var(--spacing-l);
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue