allure2 icon indicating copy to clipboard operation
allure2 copied to clipboard

Are we able to remove widgets from overview page?

Open JoviHuang opened this issue 6 years ago • 5 comments

Hello, I would like to know how to remove widgets from overview page. Like removing the trend widget from the page. I know I could add widgets into the page, but I am not sure if I could remove the existing widgets from the page, and I don't know how to do that. Need help !!! Thank you in advance.

JoviHuang avatar Mar 09 '18 14:03 JoviHuang

Just to stir the pot on this...

We store Allure output for every build we run onto an Intranet website. For builds on master/main branches, we use and keep the history to give us trends. For builds on feature branches we don't use or keep the history. This means that depending on which build you're looking at, it might have history, or it might not (with no way to know from the Allure output itself). It's a little confusing to see a box that isn't used right on the top of the overview page - to avoid the confusion (and the support questions), I'd like to remove the box if we're not using history.

coofercat avatar Mar 03 '22 10:03 coofercat

@coofercat @JoviHuang since I had this need recently myself, and it still might be a suitable workaround for you: you can create a dummy plugin with just a single js file that would remove the widget from page upon opening and delete them from rendering queue so they won't appear after navigating to other pages. my working example:

window.onload = function () {
    document.querySelector('div[data-id="environment"]').remove();
    document.querySelector('div[data-id="executors"]').remove();
    delete allure.api.widgets.widgets.environment;
    delete allure.api.widgets.widgets.executors;
}

YuraIvanskyi avatar May 04 '23 14:05 YuraIvanskyi

+1

iklimchuk avatar Dec 12 '23 15:12 iklimchuk

+1

NikolaQAautomation avatar Dec 18 '23 10:12 NikolaQAautomation

+1

kumarkrish85 avatar Dec 18 '23 13:12 kumarkrish85