Update copyright
This commit is contained in:
@@ -14,13 +14,14 @@ import Application from './main/Application'
|
||||
import ApplicationMenu from "./main/ApplicationMenu";
|
||||
|
||||
export type PackageJson = typeof import('../package.json');
|
||||
import { homepage } from '../package.json'
|
||||
import { author, homepage } from '../package.json'
|
||||
import TheDeskInfo from '../info.json'
|
||||
export type TheDeskInfoObject = typeof TheDeskInfo;
|
||||
|
||||
ipcMain.on('thedesk-info', (event: Event) => {
|
||||
event.returnValue = Object.assign({
|
||||
productName: app.getName(),
|
||||
author: author,
|
||||
homePage: homepage,
|
||||
versions: Object.assign(pick(process.versions, ["chrome", "electron", "node"]), { internal: app.getVersion() }),
|
||||
}, TheDeskInfo)
|
||||
|
@@ -15,8 +15,13 @@
|
||||
<dd :key="'ver-'+i">{{ version }}</dd>
|
||||
</template>
|
||||
</dl>
|
||||
<div id="copyright">
|
||||
<small>{{ copyright }}</small>
|
||||
<div id="credits">
|
||||
<p id="copyright">
|
||||
<small>
|
||||
Copyright © {{ copyrightYear }}
|
||||
<a :href="author.url">{{ author.name }}</a>
|
||||
</small>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -25,27 +30,43 @@
|
||||
import { Component, Vue } from "vue-property-decorator"
|
||||
import { ipcRenderer } from "electron"
|
||||
|
||||
type Versions = {[key: string]: string}
|
||||
type Versions = { [key: string]: string }
|
||||
|
||||
interface Maintainer {
|
||||
name: string
|
||||
url: string
|
||||
email: string
|
||||
}
|
||||
interface TheDeskInfo {
|
||||
productName: string
|
||||
author: Maintainer
|
||||
homePage: string
|
||||
copyrightYear: string
|
||||
codeName: string
|
||||
versions: Versions
|
||||
}
|
||||
|
||||
@Component
|
||||
export default class About extends Vue {
|
||||
public productName: string
|
||||
public author: Maintainer
|
||||
public homePage: string
|
||||
public copyright: string
|
||||
public copyrightYear: string
|
||||
public versions: Versions
|
||||
|
||||
constructor() {
|
||||
super()
|
||||
let { productName, homePage, copyright, codeName, versions } = ipcRenderer.sendSync('thedesk-info')
|
||||
this.productName = productName
|
||||
this.homePage = homePage
|
||||
this.copyright = copyright
|
||||
const thedeskInfo: TheDeskInfo = ipcRenderer.sendSync('thedesk-info')
|
||||
this.productName = thedeskInfo.productName
|
||||
this.author = thedeskInfo.author
|
||||
this.homePage = thedeskInfo.homePage
|
||||
this.copyrightYear = thedeskInfo.copyrightYear
|
||||
this.versions = {
|
||||
"Code Name": codeName,
|
||||
"Internal Version": versions.internal,
|
||||
"Chromium": versions.chrome,
|
||||
"Electron": versions.electron,
|
||||
"Node.js": versions.node,
|
||||
"Code Name": thedeskInfo.codeName,
|
||||
"Internal Version": thedeskInfo.versions.internal,
|
||||
"Chromium": thedeskInfo.versions.chrome,
|
||||
"Electron": thedeskInfo.versions.electron,
|
||||
"Node.js": thedeskInfo.versions.node,
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -76,6 +97,11 @@ body {
|
||||
-webkit-app-region: no-drag;
|
||||
user-select: auto;
|
||||
}
|
||||
#credits {
|
||||
p {
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
dl.version {
|
||||
margin: 0;
|
||||
display: grid;
|
||||
|
Reference in New Issue
Block a user