Skip to content

Commit 4c960e4

Browse files
committed
chore: replace backer info
1 parent cea1535 commit 4c960e4

File tree

2 files changed

+37
-16
lines changed

2 files changed

+37
-16
lines changed

src/Info/defInfo.js

Lines changed: 36 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import detectBrowser from 'licia/detectBrowser'
22
import detectOs from 'licia/detectOs'
33
import escape from 'licia/escape'
4+
import map from 'licia/map'
45

56
const browser = detectBrowser()
67

@@ -36,22 +37,46 @@ export default [
3637
'</tbody></table>',
3738
].join(''),
3839
},
40+
{
41+
name: 'Sponsor this Project',
42+
val() {
43+
return (
44+
'<table><tbody>' +
45+
map(
46+
[
47+
{
48+
name: 'Open Collective',
49+
link: 'https://opencollective.com/eruda',
50+
},
51+
{
52+
name: 'Ko-fi',
53+
link: 'https://ko-fi.com/surunzi',
54+
},
55+
{
56+
name: 'Wechat Pay',
57+
link: 'https://surunzi.com/wechatpay.html',
58+
},
59+
],
60+
(item) => {
61+
return `<tr><td>${
62+
item.name
63+
}</td><td><a rel="noreferrer noopener" href="${
64+
item.link
65+
}" target="_blank">${item.link.replace(
66+
'https://',
67+
''
68+
)}</a></td></tr>`
69+
}
70+
).join(' ') +
71+
'</tbody></table>'
72+
)
73+
},
74+
},
3975
{
4076
name: 'About',
4177
val:
4278
'<a href="https://eruda.liriliri.io" target="_blank">Eruda v' +
4379
VERSION +
4480
'</a>',
4581
},
46-
{
47-
name: 'Backers',
48-
val() {
49-
return `
50-
<a rel="noreferrer noopener" href="https://opencollective.com/eruda" target="_blank">
51-
<img data-exclude="true" style="width: 100%;" loading="lazy" src="https://opencollective.com/eruda/backers.svg?width=${
52-
window.innerWidth * 1.5
53-
}&exclude=true">
54-
</a>`
55-
},
56-
},
5782
]

src/Network/Network.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,7 @@ export default class Network extends Tool {
9898
return ret
9999
}
100100
_updateDataGridHeight() {
101-
const height = this._$el.offset().height - this._$control.offset().height
102-
this._requestDataGrid.setOption({
103-
minHeight: height,
104-
maxHeight: height,
105-
})
101+
this._requestDataGrid.fit()
106102
}
107103
_reqWillBeSent = (params) => {
108104
if (!this._isRecording) {

0 commit comments

Comments
 (0)