mirror of
https://github.com/ppy/osu.git
synced 2025-01-06 07:42:55 +08:00
use wiki article page when failed fetch
This commit is contained in:
parent
5ee77925e4
commit
4cf3381d0b
@ -11,7 +11,6 @@ using osu.Game.Online.API;
|
|||||||
using osu.Game.Online.API.Requests;
|
using osu.Game.Online.API.Requests;
|
||||||
using osu.Game.Online.API.Requests.Responses;
|
using osu.Game.Online.API.Requests.Responses;
|
||||||
using osu.Game.Overlays.Wiki;
|
using osu.Game.Overlays.Wiki;
|
||||||
using osu.Game.Overlays.Wiki.Markdown;
|
|
||||||
|
|
||||||
namespace osu.Game.Overlays
|
namespace osu.Game.Overlays
|
||||||
{
|
{
|
||||||
@ -139,20 +138,8 @@ namespace osu.Game.Overlays
|
|||||||
|
|
||||||
private void onFail()
|
private void onFail()
|
||||||
{
|
{
|
||||||
LoadDisplay(new WikiMarkdownContainer
|
LoadDisplay(articlePage = new WikiArticlePage($@"{api.WebsiteRootUrl}/wiki/",
|
||||||
{
|
$"Something went wrong when trying to fetch page \"{path.Value}\".\n\n[Return to the main page](Main_Page)."));
|
||||||
RelativeSizeAxes = Axes.X,
|
|
||||||
AutoSizeAxes = Axes.Y,
|
|
||||||
CurrentPath = $@"{api.WebsiteRootUrl}/wiki/",
|
|
||||||
Text = $"Something went wrong when trying to fetch page \"{path.Value}\".\n\n[Return to the main page](Main_Page).",
|
|
||||||
DocumentMargin = new MarginPadding(0),
|
|
||||||
DocumentPadding = new MarginPadding
|
|
||||||
{
|
|
||||||
Vertical = 20,
|
|
||||||
Left = 30,
|
|
||||||
Right = 50,
|
|
||||||
},
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void showParentPage()
|
private void showParentPage()
|
||||||
|
Loading…
Reference in New Issue
Block a user