Compare commits
9 Commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
5ba36efcd2 | ||
![]() |
fd497ef105 | ||
![]() |
9c4a7bf94c | ||
![]() |
91f8adc138 | ||
![]() |
69fa2373cb | ||
![]() |
8b37fc4772 | ||
![]() |
81e4ed9591 | ||
![]() |
9cda89ec04 | ||
![]() |
fc180f030f |
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"name": "misskey",
|
||||
"author": "syuilo <i@syuilo.com>",
|
||||
"version": "8.5.0",
|
||||
"clientVersion": "1.0.8834",
|
||||
"version": "8.7.0",
|
||||
"clientVersion": "1.0.8840",
|
||||
"codename": "nighthike",
|
||||
"main": "./built/index.js",
|
||||
"private": true,
|
||||
|
@@ -1,8 +1,10 @@
|
||||
import Vue from 'vue';
|
||||
|
||||
Vue.filter('bytes', (v, digits = 0) => {
|
||||
const sizes = ['Bytes', 'KB', 'MB', 'GB', 'TB'];
|
||||
if (v == 0) return '0Byte';
|
||||
const sizes = ['B', 'KB', 'MB', 'GB', 'TB'];
|
||||
if (v == 0) return '0';
|
||||
const isMinus = v < 0;
|
||||
if (isMinus) v = -v;
|
||||
const i = Math.floor(Math.log(v) / Math.log(1024));
|
||||
return (v / Math.pow(1024, i)).toFixed(digits).replace(/\.0+$/, '') + sizes[i];
|
||||
return (isMinus ? '-' : '') + (v / Math.pow(1024, i)).toFixed(digits).replace(/\.0+$/, '') + sizes[i];
|
||||
});
|
||||
|
@@ -30,6 +30,11 @@ export default Vue.extend({
|
||||
type: 'time',
|
||||
distribution: 'series'
|
||||
}]
|
||||
},
|
||||
tooltips: {
|
||||
intersect: false,
|
||||
mode: 'x',
|
||||
position: 'nearest'
|
||||
}
|
||||
}, this.opts || {}));
|
||||
}
|
||||
|
@@ -102,12 +102,14 @@ export default Vue.extend({
|
||||
fill: false,
|
||||
borderColor: '#555',
|
||||
borderWidth: 2,
|
||||
borderDash: [4, 4],
|
||||
pointBackgroundColor: '#fff',
|
||||
lineTension: 0,
|
||||
data: data.map(x => ({ t: x.date, y: x.all }))
|
||||
}, {
|
||||
label: 'Normal',
|
||||
fill: false,
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(65, 221, 222, 0.1)',
|
||||
borderColor: '#41ddde',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -115,7 +117,8 @@ export default Vue.extend({
|
||||
data: data.map(x => ({ t: x.date, y: x.normal }))
|
||||
}, {
|
||||
label: 'Replies',
|
||||
fill: false,
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(247, 121, 108, 0.1)',
|
||||
borderColor: '#f7796c',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -123,7 +126,8 @@ export default Vue.extend({
|
||||
data: data.map(x => ({ t: x.date, y: x.reply }))
|
||||
}, {
|
||||
label: 'Renotes',
|
||||
fill: false,
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(161, 222, 65, 0.1)',
|
||||
borderColor: '#a1de41',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -143,6 +147,7 @@ export default Vue.extend({
|
||||
datasets: [{
|
||||
label: local ? 'Local Notes' : 'Remote Notes',
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(246, 88, 79, 0.1)',
|
||||
borderColor: '#f6584f',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -164,6 +169,7 @@ export default Vue.extend({
|
||||
datasets: [{
|
||||
label: local ? 'Local Users' : 'Remote Users',
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(246, 88, 79, 0.1)',
|
||||
borderColor: '#f6584f',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -185,6 +191,7 @@ export default Vue.extend({
|
||||
datasets: [{
|
||||
label: local ? 'Local Drive Usage' : 'Remote Drive Usage',
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(246, 88, 79, 0.1)',
|
||||
borderColor: '#f6584f',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -195,11 +202,18 @@ export default Vue.extend({
|
||||
scales: {
|
||||
yAxes: [{
|
||||
ticks: {
|
||||
callback: (value) => {
|
||||
callback: value => {
|
||||
return Vue.filter('bytes')(value);
|
||||
}
|
||||
}
|
||||
}]
|
||||
},
|
||||
tooltips: {
|
||||
callbacks: {
|
||||
label: tooltipItem => {
|
||||
return Vue.filter('bytes')(tooltipItem.yLabel);
|
||||
}
|
||||
}
|
||||
}
|
||||
}];
|
||||
},
|
||||
@@ -215,7 +229,8 @@ export default Vue.extend({
|
||||
return [{
|
||||
datasets: [{
|
||||
label: local ? 'Local Drive Files' : 'Remote Drive Files',
|
||||
fill: false,
|
||||
fill: true,
|
||||
backgroundColor: 'rgba(246, 88, 79, 0.1)',
|
||||
borderColor: '#f6584f',
|
||||
borderWidth: 2,
|
||||
pointBackgroundColor: '#fff',
|
||||
@@ -232,6 +247,9 @@ export default Vue.extend({
|
||||
@import '~const.styl'
|
||||
|
||||
.gkgckalzgidaygcxnugepioremxvxvpt
|
||||
*
|
||||
user-select none
|
||||
|
||||
> header
|
||||
display flex
|
||||
|
||||
|
@@ -40,7 +40,7 @@ async function save(path: string, name: string, type: string, hash: string, size
|
||||
const thumbnailKey = `${config.drive.prefix}/${uuid.v4()}/${name}.thumbnail.jpg`;
|
||||
|
||||
const baseUrl = config.drive.baseUrl
|
||||
|| `${ config.drive.config.secure ? 'https' : 'http' }://${ config.drive.config.endPoint }${ config.drive.config.port ? ':' + config.drive.config.port : '' }/${ config.drive.bucket }`;
|
||||
|| `${ config.drive.config.useSSL ? 'https' : 'http' }://${ config.drive.config.endPoint }${ config.drive.config.port ? ':' + config.drive.config.port : '' }/${ config.drive.bucket }`;
|
||||
|
||||
await minio.putObject(config.drive.bucket, key, fs.createReadStream(path), size, {
|
||||
'Content-Type': type,
|
||||
|
Reference in New Issue
Block a user