adjust server detail default and status layout
This commit is contained in:
@@ -35,11 +35,19 @@ describe("ServerDetailPage config write approval", () => {
|
||||
it("keeps the detail header focused on a single shared action row", () => {
|
||||
expect(serverDetailPageSource).not.toContain("Run 心跳");
|
||||
expect(serverDetailPageSource).not.toContain("已自动附着");
|
||||
expect(serverDetailPageSource).toContain('<span>返回列表</span>');
|
||||
expect(serverDetailPageSource).toContain('<span>刷新</span>');
|
||||
expect(serverDetailPageSource).toContain('<span>打开终端</span>');
|
||||
expect(serverDetailPageSource).toContain('<span>启动</span>');
|
||||
expect(serverDetailPageSource).toContain('<span>停止</span>');
|
||||
const headerSource = serverDetailPageSource.split('<header className="server-detail-header">')[1]?.split('</header>')[0] ?? "";
|
||||
expect(headerSource).toContain('<span>返回列表</span>');
|
||||
expect(headerSource).not.toContain('<span>刷新</span>');
|
||||
expect(headerSource).toContain('<span>打开终端</span>');
|
||||
expect(headerSource).toContain('<span>启动</span>');
|
||||
expect(headerSource).toContain('<span>停止</span>');
|
||||
const actionStripSource = headerSource.split('<div className="action-strip">')[1]?.split('</div>')[0] ?? "";
|
||||
expect(actionStripSource.indexOf('<span>停止</span>')).toBeLessThan(actionStripSource.indexOf('detailStateText'));
|
||||
});
|
||||
|
||||
it("opens the plugin user management page by default when available", () => {
|
||||
expect(serverDetailPageSource).toContain('page.key === "players"');
|
||||
expect(serverDetailPageSource).toContain('setSection(`plugin:${defaultPluginPage.key}`)');
|
||||
});
|
||||
|
||||
it("maps platform diff preview responses into the display diff without losing approval metadata", () => {
|
||||
|
||||
Reference in New Issue
Block a user