mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-01-03 06:57:36 +01:00
5.6.2906
This commit is contained in:
parent
93e4e6ce36
commit
87f638a2d3
@ -157,7 +157,7 @@ Time:
|
||||
Unit: DAYS
|
||||
# Includes players online, tps and performance time series
|
||||
Remove_time_series_data_after:
|
||||
Time: 90
|
||||
Time: 3650
|
||||
Unit: DAYS
|
||||
Remove_ping_data_after:
|
||||
Time: 14
|
||||
|
@ -17,11 +17,13 @@
|
||||
"hong kong": "HKG",
|
||||
"armenia": "ARM",
|
||||
"vietnam": "VNM",
|
||||
"vatican city": "VAT",
|
||||
"australia": "AUS",
|
||||
"laos": "LAO",
|
||||
"aruba": "ABW",
|
||||
"solomon islands": "SLB",
|
||||
"turkey": "TUR",
|
||||
"türkiye": "TUR",
|
||||
"ukraine": "UKR",
|
||||
"austria": "AUT",
|
||||
"united states": "USA",
|
||||
@ -33,7 +35,8 @@
|
||||
"greece": "GRC",
|
||||
"paraguay": "PRY",
|
||||
"palau": "PLW",
|
||||
"congo, republic of the": "COG",
|
||||
"congo republic": "COD",
|
||||
"dr congo": "COG",
|
||||
"vanuatu": "VUT",
|
||||
"cyprus": "CYP",
|
||||
"colombia": "COL",
|
||||
@ -93,6 +96,7 @@
|
||||
"zimbabwe": "ZWE",
|
||||
"el salvador": "SLV",
|
||||
"macedonia": "MKD",
|
||||
"north macedonia": "MKD",
|
||||
"saint lucia": "LCA",
|
||||
"bolivia": "BOL",
|
||||
"china": "CHN",
|
||||
@ -187,6 +191,7 @@
|
||||
"tanzania": "TZA",
|
||||
"grenada": "GRD",
|
||||
"netherlands": "NLD",
|
||||
"the netherlands": "NLD",
|
||||
"sao tome and principe": "STP",
|
||||
"guam": "GUM",
|
||||
"eritrea": "ERI",
|
||||
@ -221,5 +226,30 @@
|
||||
"saint vincent and the grenadines": "VCT",
|
||||
"tonga": "TON",
|
||||
"barbados": "BRB",
|
||||
"new caledonia": "NCL"
|
||||
"new caledonia": "NCL",
|
||||
"réunion": "REU",
|
||||
"mayotte": "MYT",
|
||||
"martinique": "MTQ",
|
||||
"guadeloupe": "GLP",
|
||||
"french guiana": "GUF",
|
||||
"eswatini": "SWZ",
|
||||
"cocos (keeling) islands": "CCK",
|
||||
"macao": "MAC",
|
||||
"st kitts and nevis": "KNA",
|
||||
"saint barthélemy": "BLM",
|
||||
"st vincent and grenadines": "VCT",
|
||||
"bahamas": "BHS",
|
||||
"myanmar": "MMR",
|
||||
"tokelau": "TKL",
|
||||
"wallis and futuna": "WLF",
|
||||
"ivory coast": "CIV",
|
||||
"côte d'ivoire": "CIV",
|
||||
"gambia": "GMB",
|
||||
"nauru": "NRU",
|
||||
"federated states of micronesia": "FSM",
|
||||
"curaçao": "CUW",
|
||||
"são tomé and príncipe": "STP",
|
||||
"turks and caicos islands": "TCA",
|
||||
"norfolk island": "NFK",
|
||||
"pitcairn islands": "PCN"
|
||||
}
|
||||
|
@ -905,7 +905,7 @@ plugin:
|
||||
loadedServerInfo: "Identifiant de serveur chargé : ${0}"
|
||||
loadingServerInfo: "Chargement des informations d'identification du serveur"
|
||||
no: "Non"
|
||||
today: "Aujourd'hui"
|
||||
today: "'Aujourd''hui'"
|
||||
unavailable: "Indisponible"
|
||||
unknown: "Inconnu"
|
||||
yes: "Oui"
|
||||
|
@ -118,7 +118,7 @@ command:
|
||||
network: "> §2ネットワークページ"
|
||||
players: "> §2プレイヤー"
|
||||
search: "> §2${0} §f${1}§2 の検索結果:"
|
||||
serverList: "Minecraft id::名前::uuid::version"
|
||||
serverList: "Minecraft id::名前::uuid::バージョン"
|
||||
servers: "> §2サーバー"
|
||||
webUserList: "ユーザー名::別プレイヤーとのリンク::権限レベル"
|
||||
webUsers: "> §2${0} Webユーザー"
|
||||
@ -257,7 +257,7 @@ html:
|
||||
noServers: "データーベース内に登録されたサーバーが見つかりません"
|
||||
noServersLong: 'プランがどのゲーム サーバーにもインストールされていないか、同じデータベースに接続されていないようです。ネットワーク チュートリアルについては、<a href="https://github.com/plan-player-analytics/Plan/wiki">Wiki</a>を参考にしてください'
|
||||
noSpongeChunks: "Spongeではチャンクを利用できません"
|
||||
noUptimeCalculation: "Server is offline, or has never restarted with Plan installed."
|
||||
noUptimeCalculation: "サーバーがオフラインであるか、Plan がインストールされた状態で再起動されたことがありません。"
|
||||
performanceNoGameServers: "TPS、エンティティ、またはチャンクデータは、ゲーム ティックループがないため、プロキシサーバーから収集されません"
|
||||
predictedNewPlayerRetention: "これは以前のプレーヤーから基づいた予測値です"
|
||||
error:
|
||||
@ -290,19 +290,19 @@ html:
|
||||
active: "よくログインしている"
|
||||
activePlaytime: "アクティブなプレイ時間"
|
||||
activityIndex: "活動指数"
|
||||
addJoinAddressGroup: "Add address group"
|
||||
addressGroup: "Address group {{n}}"
|
||||
addJoinAddressGroup: "アドレスグループの追加"
|
||||
addressGroup: "{{n}} アドレスグループ"
|
||||
afk: "離席"
|
||||
afkTime: "離席時間"
|
||||
all: "全て"
|
||||
allTime: "全体"
|
||||
allowed: "Allowed"
|
||||
allowlist: "Allowlist"
|
||||
allowed: "許可された"
|
||||
allowlist: "許可リスト"
|
||||
allowlistBounces: "Allowlist Bounces"
|
||||
alphabetical: "アルファベット順"
|
||||
apply: "適用"
|
||||
asNumbers: "の情報"
|
||||
attempts: "Attempts"
|
||||
attempts: "試行回数"
|
||||
average: "平均の初回セッション時間"
|
||||
averageActivePlaytime: "平均アクティブプレイ時間"
|
||||
averageAfkTime: "平均AFK時間"
|
||||
@ -333,7 +333,7 @@ html:
|
||||
cpuUsage: "CPU使用率"
|
||||
currentPlayerbase: "ログインプレイヤー"
|
||||
currentUptime: "現状のアップタイム"
|
||||
currentlyInstalledPlugins: "Currently Installed Plugins"
|
||||
currentlyInstalledPlugins: "現在インストールされているプラグイン"
|
||||
dayByDay: "詳細情報"
|
||||
dayOfweek: "曜日"
|
||||
deadliestWeapon: "最もPvPで使用されている武器"
|
||||
@ -345,7 +345,7 @@ html:
|
||||
duringLowTps: "TPSの低下までの時間:"
|
||||
entities: "エンティティ数"
|
||||
errors: "Planエラーログ"
|
||||
export: "Export"
|
||||
export: "出力"
|
||||
exported: "データエクスポート時間"
|
||||
favoriteServer: "お気に入りのサーバー"
|
||||
firstSession: "初参加"
|
||||
@ -437,10 +437,10 @@ html:
|
||||
last24hours: "24時間"
|
||||
last30days: "1ヶ月"
|
||||
last7days: "1週間"
|
||||
lastAllowed: "Last Allowed"
|
||||
lastBlocked: "Last Blocked"
|
||||
lastAllowed: "直近の許可"
|
||||
lastBlocked: "直近の拒否"
|
||||
lastConnected: "直近の接続"
|
||||
lastKnownAttempt: "Last Known Attempt"
|
||||
lastKnownAttempt: "直近の試行"
|
||||
lastPeak: "直近のピークタイム"
|
||||
lastSeen: "直近のオンライン"
|
||||
latestJoinAddresses: "最後に参加したサーバーのアドレス"
|
||||
@ -489,7 +489,7 @@ html:
|
||||
name: "名前"
|
||||
network: "ネットワーク"
|
||||
networkAsNumbers: "ネットワーク数"
|
||||
networkCalendar: "Network Calendar"
|
||||
networkCalendar: "ネットワークカレンダー"
|
||||
networkOnlineActivity: "ネットワーク内の接続状況"
|
||||
networkOverview: "ネットワーク概要"
|
||||
networkPage: "ネットワークページ"
|
||||
@ -527,8 +527,8 @@ html:
|
||||
playersOnlineNow: "オンラインのプレイヤー(今)"
|
||||
playersOnlineOverview: "接続状況の概要"
|
||||
playtime: "プレイ時間"
|
||||
pluginHistory: "Plugin History"
|
||||
pluginVersionHistory: "Plugin Version History"
|
||||
pluginHistory: "プラグイン履歴"
|
||||
pluginVersionHistory: "プラグインバージョン履歴"
|
||||
plugins: "プラグイン"
|
||||
pluginsOverview: "プラグイン一覧"
|
||||
punchcard: "パンチカード"
|
||||
@ -679,7 +679,7 @@ html:
|
||||
page_network_playerbase_graphs: "プレイヤー層のグラフを表示"
|
||||
page_network_playerbase_overview: "プレイヤー層の概要番号を表示"
|
||||
page_network_players: "プレイヤーリストタブを表示"
|
||||
page_network_plugin_history: "See Plugin History across the network"
|
||||
page_network_plugin_history: "ネットワーク全体のプラグイン履歴を見る"
|
||||
page_network_plugins: "プロキシーのプラグインタブを表示"
|
||||
page_network_retention: "プレイヤー維持のタブを表示"
|
||||
page_network_server_list: "サーバーリストを表示"
|
||||
@ -722,7 +722,7 @@ html:
|
||||
page_server_playerbase_graphs: "プレイヤー層概要グラフを表示"
|
||||
page_server_playerbase_overview: "プレイヤー層概要番号を表示"
|
||||
page_server_players: "プレイヤーリストタブを表示"
|
||||
page_server_plugin_history: "See Plugin History"
|
||||
page_server_plugin_history: "プラグイン履歴を見る"
|
||||
page_server_plugins: "サーバーのプラグインタブを表示"
|
||||
page_server_retention: "プレイヤーの維持タブを表示"
|
||||
page_server_sessions: "セッションタブを表示"
|
||||
@ -835,7 +835,7 @@ html:
|
||||
success: "新規ユーザー登録が完了しました!ログインできるようになりました。"
|
||||
usernameTip: "ユーザー名は50文字以内で指定します"
|
||||
text:
|
||||
click: "Click for more"
|
||||
click: "ここをクリック"
|
||||
clickAndDrag: "Click and Drag for more"
|
||||
clickToExpand: "クリックして展開"
|
||||
comparing15days: "直近15日との比較"
|
||||
@ -888,8 +888,8 @@ plugin:
|
||||
emptyIP: "server.propertiesの設定で、IPの項目が設定されておらずAlternative IPが使用されていません。そのため誤ったリンクが表示されます!"
|
||||
geoDisabled: "位置情報サービスが有効ではありません。 (Data.Geolocations: false)"
|
||||
geoInternetRequired: "「Plan」は初回起動時、「GeoLite2」の位置情報データベースをダウンロードするためインターネットアクセスが必要です"
|
||||
proxyAddress: "Proxy server detected in the database - Proxy Webserver address is '${0}'."
|
||||
proxyDisabledWebserver: "Disabling Webserver on this server - You can override this behavior by setting '${0}' to false."
|
||||
proxyAddress: "データベースでプロキシサーバーが検出されました - プロキシウェブサーバーのアドレスは '${0}' です。"
|
||||
proxyDisabledWebserver: "ウェブサーバーを無効にする - '${0}' を false に設定することで、この動作をオーバーライドできます。"
|
||||
settingChange: "Note: Set '${0}' to ${1}"
|
||||
storeSessions: "前回のシャットダウン時に、保存されていたセッションを保存します"
|
||||
webserverDisabled: "Webサーバーの初期化に失敗しました (WebServer.DisableWebServer: true)"
|
||||
@ -910,7 +910,7 @@ plugin:
|
||||
unknown: "不明"
|
||||
yes: "はい"
|
||||
yesterday: "'昨日'"
|
||||
localeReloaded: "Custom locale.yml was modified so it was reloaded and is now in use."
|
||||
localeReloaded: "カスタムlocale.ymlが修正されたため、再読込されました。"
|
||||
version:
|
||||
checkFail: "新しいバージョンのチェックに失敗しました"
|
||||
checkFailGithub: "Github/versions.txtに存在するバージョン情報のロードに失敗しました"
|
||||
|
@ -7,42 +7,42 @@
|
||||
"proxy": "http://localhost:8800",
|
||||
"dependencies": {
|
||||
"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
|
||||
"@fortawesome/fontawesome-free": "^6.5.2",
|
||||
"@fortawesome/fontawesome-svg-core": "^6.5.2",
|
||||
"@fortawesome/free-brands-svg-icons": "^6.5.2",
|
||||
"@fortawesome/free-regular-svg-icons": "^6.5.2",
|
||||
"@fortawesome/free-solid-svg-icons": "^6.5.2",
|
||||
"@fortawesome/fontawesome-free": "^6.7.1",
|
||||
"@fortawesome/fontawesome-svg-core": "^6.7.1",
|
||||
"@fortawesome/free-brands-svg-icons": "^6.7.1",
|
||||
"@fortawesome/free-regular-svg-icons": "^6.7.1",
|
||||
"@fortawesome/free-solid-svg-icons": "^6.7.1",
|
||||
"@fortawesome/react-fontawesome": "^0.2.2",
|
||||
"@fullcalendar/bootstrap": "^6.1.11",
|
||||
"@fullcalendar/core": "^6.1.13",
|
||||
"@fullcalendar/daygrid": "^6.1.11",
|
||||
"@fullcalendar/interaction": "^6.1.11",
|
||||
"@fullcalendar/react": "^6.1.11",
|
||||
"@highcharts/map-collection": "^2.1.0",
|
||||
"@testing-library/jest-dom": "^6.4.5",
|
||||
"@testing-library/react": "^15.0.7",
|
||||
"@fullcalendar/bootstrap": "^6.1.15",
|
||||
"@fullcalendar/core": "^6.1.15",
|
||||
"@fullcalendar/daygrid": "^6.1.15",
|
||||
"@fullcalendar/interaction": "^6.1.15",
|
||||
"@fullcalendar/react": "^6.1.15",
|
||||
"@highcharts/map-collection": "^2.3.0",
|
||||
"@testing-library/jest-dom": "^6.6.3",
|
||||
"@testing-library/react": "^16.0.1",
|
||||
"@testing-library/user-event": "^14.5.2",
|
||||
"axios": "^1.7.2",
|
||||
"axios": "^1.7.8",
|
||||
"bootstrap": "^5.3.3",
|
||||
"export-to-csv": "^1.3.0",
|
||||
"highcharts": "^11.4.3",
|
||||
"i18next": "^23.11.5",
|
||||
"highcharts": "^11.4.8",
|
||||
"i18next": "^24.0.2",
|
||||
"i18next-chained-backend": "^4.6.2",
|
||||
"i18next-http-backend": "^2.5.2",
|
||||
"i18next-http-backend": "^3.0.1",
|
||||
"i18next-localstorage-backend": "^4.2.0",
|
||||
"masonry-layout": "^4.2.2",
|
||||
"moment": "^2.30.1",
|
||||
"react": "^18.3.1",
|
||||
"react-bootstrap": "^2.10.2",
|
||||
"react-bootstrap": "^2.10.6",
|
||||
"react-bootstrap-range-slider": "^3.0.8",
|
||||
"react-dom": "^18.3.1",
|
||||
"react-i18next": "^14.1.2",
|
||||
"react-i18next": "^15.1.3",
|
||||
"react-mcjsonchat": "^1.0.0",
|
||||
"react-router-dom": "^6.23.1",
|
||||
"sass": "^1.77.2",
|
||||
"react-router-dom": "^6.26.0",
|
||||
"sass": "^1.81.0",
|
||||
"source-map-explorer": "^2.5.2",
|
||||
"swagger-ui": "^5.17.12",
|
||||
"web-vitals": "^3.0.2"
|
||||
"swagger-ui": "^5.18.2",
|
||||
"web-vitals": "^4.2.4"
|
||||
},
|
||||
"scripts": {
|
||||
"start": "vite",
|
||||
@ -68,7 +68,7 @@
|
||||
]
|
||||
},
|
||||
"devDependencies": {
|
||||
"@vitejs/plugin-react": "^4.3.0",
|
||||
"vite": "^5.2.11"
|
||||
"@vitejs/plugin-react": "^4.3.4",
|
||||
"vite": "^6.0.1"
|
||||
}
|
||||
}
|
||||
|
@ -67,7 +67,7 @@ const PingGraphTab = ({identifier}) => {
|
||||
|
||||
const PerformanceGraphsCard = () => {
|
||||
const {t} = useTranslation();
|
||||
const {authRequired, hasPermission} = useAuth();
|
||||
const {authRequired, hasPermission, hasChildPermission} = useAuth();
|
||||
|
||||
const {identifier} = useParams();
|
||||
const {data, loadingError} = useDataRequest(fetchOptimizedPerformance, [identifier]);
|
||||
@ -115,33 +115,40 @@ const PerformanceGraphsCard = () => {
|
||||
}
|
||||
}, [pluginHistory, setPluginHistorySeries, t]);
|
||||
|
||||
const tabs = [
|
||||
{
|
||||
name: t('html.label.all'), icon: faGears, color: 'blue-grey', href: 'all',
|
||||
element: <AllGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>,
|
||||
permission: 'page.server.performance.graphs'
|
||||
}, {
|
||||
name: t('html.label.tps'), icon: faTachometerAlt, color: 'red', href: 'tps',
|
||||
element: <TpsGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>,
|
||||
permission: 'page.server.performance.graphs.tps'
|
||||
}, {
|
||||
name: t('html.label.cpuRam'), icon: faMicrochip, color: 'light-green', href: 'cpu-ram',
|
||||
element: <CpuRamGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>,
|
||||
permission: ['page.server.performance.graphs.cpu', 'page.server.performance.graphs.ram']
|
||||
}, {
|
||||
name: t('html.label.world'), icon: faMap, color: 'purple', href: 'world-load',
|
||||
element: <WorldGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>,
|
||||
permission: ['page.server.performance.graphs.entities', 'page.server.performance.graphs.chunks']
|
||||
}, {
|
||||
name: t('html.label.ping'), icon: faSignal, color: 'amber', href: 'ping',
|
||||
element: <PingGraphTab identifier={identifier}/>,
|
||||
permission: 'page.server.performance.graphs.ping'
|
||||
}, {
|
||||
name: t('html.label.diskSpace'), icon: faHdd, color: 'green', href: 'disk',
|
||||
element: <DiskGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>,
|
||||
permission: 'page.server.performance.graphs.disk'
|
||||
},
|
||||
].filter(tab => hasChildPermission(tab.permission));
|
||||
return <Card id={"performance-graphs"}>
|
||||
<CardTabs tabs={[
|
||||
{
|
||||
name: t('html.label.all'), icon: faGears, color: 'blue-grey', href: 'all',
|
||||
element: <AllGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>
|
||||
}, {
|
||||
name: t('html.label.tps'), icon: faTachometerAlt, color: 'red', href: 'tps',
|
||||
element: <TpsGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>
|
||||
}, {
|
||||
name: t('html.label.cpuRam'), icon: faMicrochip, color: 'light-green', href: 'cpu-ram',
|
||||
element: <CpuRamGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>
|
||||
}, {
|
||||
name: t('html.label.world'), icon: faMap, color: 'purple', href: 'world-load',
|
||||
element: <WorldGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>
|
||||
}, {
|
||||
name: t('html.label.ping'), icon: faSignal, color: 'amber', href: 'ping',
|
||||
element: <PingGraphTab identifier={identifier}/>
|
||||
}, {
|
||||
name: t('html.label.diskSpace'), icon: faHdd, color: 'green', href: 'disk',
|
||||
element: <DiskGraphTab data={data} dataSeries={parsedData} pluginHistorySeries={pluginHistorySeries}
|
||||
loadingError={loadingError || pluginHistoryLoadingError}/>
|
||||
},
|
||||
]}/>
|
||||
<CardTabs tabs={tabs}/>
|
||||
</Card>
|
||||
}
|
||||
|
||||
|
@ -8,6 +8,7 @@ import {useTheme} from "../../../hooks/themeHook";
|
||||
import {withReducedSaturation} from "../../../util/colors";
|
||||
import Accessibility from "highcharts/modules/accessibility";
|
||||
import {useMetadata} from "../../../hooks/metadataHook";
|
||||
import {useAuth} from "../../../hooks/authenticationHook.jsx";
|
||||
|
||||
const yAxis = [
|
||||
{
|
||||
@ -66,6 +67,7 @@ const AllPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
const {t} = useTranslation();
|
||||
const {graphTheming, nightModeEnabled} = useTheme();
|
||||
const {timeZoneOffsetMinutes} = useMetadata();
|
||||
const {hasPermission} = useAuth();
|
||||
|
||||
const onResize = useCallback(() => {
|
||||
let chartElement = document.getElementById(id);
|
||||
@ -74,14 +76,14 @@ const AllPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
|
||||
if (chart?.yAxis?.length) {
|
||||
const newWidth = window.innerWidth
|
||||
chart.yAxis[0].update({labels: {enabled: newWidth >= 900}});
|
||||
chart.yAxis[1].update({labels: {enabled: newWidth >= 900}});
|
||||
chart.yAxis[2].update({labels: {enabled: newWidth >= 1000}});
|
||||
chart.yAxis[3].update({labels: {enabled: newWidth >= 1000}});
|
||||
chart.yAxis[4].update({labels: {enabled: newWidth >= 1400}});
|
||||
chart.yAxis[5].update({labels: {enabled: newWidth >= 1400}});
|
||||
chart.yAxis[0].update({labels: {enabled: newWidth >= 900 && hasPermission('page.server.performance.graphs.players.online')}});
|
||||
chart.yAxis[1].update({labels: {enabled: newWidth >= 900 && hasPermission('page.server.performance.graphs.tps')}});
|
||||
chart.yAxis[2].update({labels: {enabled: newWidth >= 1000 && hasPermission('page.server.performance.graphs.cpu')}});
|
||||
chart.yAxis[3].update({labels: {enabled: newWidth >= 1000 && hasPermission('page.server.performance.graphs.ram')}});
|
||||
chart.yAxis[4].update({labels: {enabled: newWidth >= 1400 && hasPermission('page.server.performance.graphs.entities')}});
|
||||
chart.yAxis[5].update({labels: {enabled: newWidth >= 1400 && hasPermission('page.server.performance.graphs.chunks')}});
|
||||
}
|
||||
}, [id])
|
||||
}, [id, hasPermission])
|
||||
|
||||
useEffect(() => {
|
||||
window.addEventListener("resize", onResize);
|
||||
@ -107,14 +109,15 @@ const AllPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
const spline = 'spline'
|
||||
|
||||
const series = {
|
||||
playersOnline: {
|
||||
playersOnline: hasPermission('page.server.performance.graphs.players.online') ? {
|
||||
name: t('html.label.playersOnline'),
|
||||
type: 'areaspline',
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.playersOnline,
|
||||
color: data.colors.playersOnline,
|
||||
yAxis: 0
|
||||
}, tps: {
|
||||
} : {},
|
||||
tps: hasPermission('page.server.performance.graphs.tps') ? {
|
||||
name: t('html.label.tps'),
|
||||
type: spline,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.high) : data.colors.high,
|
||||
@ -122,35 +125,39 @@ const AllPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
tooltip: tooltip.twoDecimals,
|
||||
data: dataSeries.tps,
|
||||
yAxis: 1
|
||||
}, cpu: {
|
||||
} : {},
|
||||
cpu: hasPermission('page.server.performance.graphs.cpu') ? {
|
||||
name: t('html.label.cpu'),
|
||||
type: spline,
|
||||
tooltip: tooltip.twoDecimals,
|
||||
data: dataSeries.cpu,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.cpu) : data.colors.cpu,
|
||||
yAxis: 2
|
||||
}, ram: {
|
||||
} : {},
|
||||
ram: hasPermission('page.server.performance.graphs.ram') ? {
|
||||
name: t('html.label.ram'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.ram,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.ram) : data.colors.ram,
|
||||
yAxis: 3
|
||||
}, entities: {
|
||||
} : {},
|
||||
entities: hasPermission('page.server.performance.graphs.entities') ? {
|
||||
name: t('html.label.loadedEntities'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.entities,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.entities) : data.colors.entities,
|
||||
yAxis: 4
|
||||
}, chunks: {
|
||||
} : {},
|
||||
chunks: hasPermission('page.server.performance.graphs.chunks') ? {
|
||||
name: t('html.label.loadedChunks'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.chunks,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.chunks) : data.colors.chunks,
|
||||
yAxis: 5
|
||||
}
|
||||
} : {}
|
||||
};
|
||||
|
||||
NoDataDisplay(Highcharts);
|
||||
|
@ -8,38 +8,42 @@ import {useTheme} from "../../../hooks/themeHook";
|
||||
import {withReducedSaturation} from "../../../util/colors";
|
||||
import Accessibility from "highcharts/modules/accessibility";
|
||||
import {useMetadata} from "../../../hooks/metadataHook";
|
||||
import {useAuth} from "../../../hooks/authenticationHook.jsx";
|
||||
|
||||
const CpuRamPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
const {t} = useTranslation();
|
||||
const {graphTheming, nightModeEnabled} = useTheme();
|
||||
const {timeZoneOffsetMinutes} = useMetadata();
|
||||
const {hasPermission} = useAuth();
|
||||
|
||||
useEffect(() => {
|
||||
const spline = 'spline'
|
||||
|
||||
const series = {
|
||||
playersOnline: {
|
||||
playersOnline: hasPermission('page.server.performance.graphs.players.online') ? {
|
||||
name: t('html.label.playersOnline'),
|
||||
type: 'areaspline',
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.playersOnline,
|
||||
color: data.colors.playersOnline,
|
||||
yAxis: 0
|
||||
}, cpu: {
|
||||
} : {},
|
||||
cpu: hasPermission('page.server.performance.graphs.cpu') ? {
|
||||
name: t('html.label.cpu'),
|
||||
type: spline,
|
||||
tooltip: tooltip.twoDecimals,
|
||||
data: dataSeries.cpu,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.cpu) : data.colors.cpu,
|
||||
yAxis: 1
|
||||
}, ram: {
|
||||
} : {},
|
||||
ram: hasPermission('page.server.performance.graphs.ram') ? {
|
||||
name: t('html.label.ram'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.ram,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.ram) : data.colors.ram,
|
||||
yAxis: 2
|
||||
}
|
||||
} : {}
|
||||
};
|
||||
|
||||
NoDataDisplay(Highcharts);
|
||||
|
@ -8,11 +8,13 @@ import {useTheme} from "../../../hooks/themeHook";
|
||||
import {withReducedSaturation} from "../../../util/colors";
|
||||
import Accessibility from "highcharts/modules/accessibility";
|
||||
import {useMetadata} from "../../../hooks/metadataHook";
|
||||
import {useAuth} from "../../../hooks/authenticationHook.jsx";
|
||||
|
||||
const TpsPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
const {t} = useTranslation();
|
||||
const {graphTheming, nightModeEnabled} = useTheme();
|
||||
const {timeZoneOffsetMinutes} = useMetadata();
|
||||
const {hasPermission} = useAuth();
|
||||
|
||||
useEffect(() => {
|
||||
const zones = {
|
||||
@ -30,14 +32,15 @@ const TpsPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
|
||||
const spline = 'spline'
|
||||
const series = {
|
||||
playersOnline: {
|
||||
playersOnline: hasPermission('page.server.performance.graphs.players.online') ? {
|
||||
name: t('html.label.playersOnline'),
|
||||
type: 'areaspline',
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.playersOnline,
|
||||
color: data.colors.playersOnline,
|
||||
yAxis: 0
|
||||
}, tps: {
|
||||
} : {},
|
||||
tps: hasPermission('page.server.performance.graphs.tps') ? {
|
||||
name: t('html.label.tps'),
|
||||
type: spline,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.high) : data.colors.high,
|
||||
@ -45,7 +48,7 @@ const TpsPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
tooltip: tooltip.twoDecimals,
|
||||
data: dataSeries.tps,
|
||||
yAxis: 1
|
||||
}
|
||||
} : {}
|
||||
};
|
||||
|
||||
NoDataDisplay(Highcharts);
|
||||
|
@ -8,38 +8,42 @@ import {useTheme} from "../../../hooks/themeHook";
|
||||
import {withReducedSaturation} from "../../../util/colors";
|
||||
import Accessibility from "highcharts/modules/accessibility";
|
||||
import {useMetadata} from "../../../hooks/metadataHook";
|
||||
import {useAuth} from "../../../hooks/authenticationHook.jsx";
|
||||
|
||||
const WorldPerformanceGraph = ({id, data, dataSeries, pluginHistorySeries}) => {
|
||||
const {t} = useTranslation();
|
||||
const {graphTheming, nightModeEnabled} = useTheme();
|
||||
const {timeZoneOffsetMinutes} = useMetadata();
|
||||
const {hasPermission} = useAuth();
|
||||
|
||||
useEffect(() => {
|
||||
const spline = 'spline'
|
||||
|
||||
const series = {
|
||||
playersOnline: {
|
||||
playersOnline: hasPermission('page.server.performance.graphs.players.online') ? {
|
||||
name: t('html.label.playersOnline'),
|
||||
type: 'areaspline',
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.playersOnline,
|
||||
color: data.colors.playersOnline,
|
||||
yAxis: 0
|
||||
}, entities: {
|
||||
} : {},
|
||||
entities: hasPermission('page.server.performance.graphs.entities') ? {
|
||||
name: t('html.label.loadedEntities'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.entities,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.entities) : data.colors.entities,
|
||||
yAxis: 1
|
||||
}, chunks: {
|
||||
} : {},
|
||||
chunks: hasPermission('page.server.performance.graphs.chunks') ? {
|
||||
name: t('html.label.loadedChunks'),
|
||||
type: spline,
|
||||
tooltip: tooltip.zeroDecimals,
|
||||
data: dataSeries.chunks,
|
||||
color: nightModeEnabled ? withReducedSaturation(data.colors.chunks) : data.colors.chunks,
|
||||
yAxis: 2
|
||||
}
|
||||
} : {}
|
||||
};
|
||||
|
||||
NoDataDisplay(Highcharts);
|
||||
|
@ -1,6 +1,6 @@
|
||||
@import "../../node_modules/bootstrap/scss/bootstrap"
|
||||
|
||||
@import "src/components/calendar/calendar-fixes"
|
||||
@import "../components/calendar/calendar-fixes"
|
||||
|
||||
p, span, td, .h3, a, button
|
||||
.svg-inline--fa, .fa, .far, .fas, .fab
|
||||
|
@ -12,10 +12,10 @@ import ExtendableRow from "../../components/layout/extension/ExtendableRow";
|
||||
import {useAuth} from "../../hooks/authenticationHook";
|
||||
|
||||
const ServerPerformance = () => {
|
||||
const {hasPermission} = useAuth();
|
||||
const {hasPermission, hasChildPermission} = useAuth();
|
||||
const {identifier} = useParams();
|
||||
|
||||
const seeGraphs = hasPermission('page.server.performance.graphs');
|
||||
const seeGraphs = hasChildPermission('page.server.performance.graphs');
|
||||
const seeOverview = hasPermission('page.server.performance.overview');
|
||||
const {data, loadingError} = useDataRequest(fetchPerformanceOverview, [identifier], seeOverview);
|
||||
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user