Radar chart example

Product: PowerShell Universal
Version: 3.9.3

Hey All!
It’s been a long time since I posted here, must be going on 2 years. I’ve been out of the PSU game and now I’m in a new job I’m excited to get back into it - I’ve been loving all the improvements.
Anyway, onto my issue.

I’ve just been throwing together a demo page with some components copy pasted from the examples within the docs.

I’ve tried using graph copied from here: radar graph

 $Data = Get-Process | Sort-Object -Property CPU -Descending | Select-Object -First 10 
 New-UDChartJS -Type 'radar' -Data $Data -DataProperty CPU -LabelProperty ProcessName

But I just get the following:

Error rendering component (ud-chartjs)

This error is not expected. Please report it to Ironman Software.

Full error as follows:

Error rendering component (ud-chartjs)
Error: "radialLinear" is not a registered scale.

    at ChartComponent (http://localhost:5000/dashboard/vendors-node_modules_chartjs-adapter-moment_dist_chartjs-adapter-moment_esm_js-node_modules_m-02eaf6.e4ef9477bfea9c97d03a.bundle.js:21471:11)
    at highOrderComponent (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:109221:55)
    at ErrorBoundary (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:80928:197)
    at Suspense
    at main
    at UDPage (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:77939:23)
    at highOrderComponent (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:109221:55)
    at Route (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:146241:29)
    at Switch (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:146447:29)
    at div
    at Suspense
    at highOrderComponent (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:109221:55)
    at Suspense
    at InnerThemeProvider (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:41224:70)
    at ThemeProvider (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:39562:5)
    at ThemeProvider (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:41244:5)
    at StyledEngineProvider (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:39747:5)
    at n (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:159613:58)
    at http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:159613:1060
    at Dashboard (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:108206:22)
    at Route (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:146241:29)
    at Switch (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:146447:29)
    at div
    at Router (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:145872:30)
    at BrowserRouter (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:145497:35)
    at App (http://localhost:5000/dashboard/index.807ba816bfab2d3934f9.bundle.js:79924:197)

Any ideas?

Edit: Spotted another potential issue here, the example given for option hides the legend, however when I tested this I saw no difference between legend set as $false or $true and in both cases could still see the legend above my graph.

Edit2: While I’m at it, the link on the code editor page for the monaco editor options, is broken. Should probably be updated to here

Edit3: While testing the transitions here
I could not get Slide, Grow or Zoom to work, some just fade in/out in situ. A note on this: I’m testing on a clean install of the 3.9.3 desktop version.

Edit4: The demo here for advanced card, seems to be missing a "@ on the end of the multi line string.

Edit5: The page regarding theming here, I’ve been trying to follow. I’ve got a page full of example components copied from the docs, lots of ud buttons.
I’ve copied the sand theme. I’m probbaly doing something wrong here, but all my buttons match primary color, even if i’m setting -color ‘default’ they do not go grey as in the sample image. I feel this this is my misunderstanding though.

Also, on another unrelated note, there’s a bug in this page when clicking ‘modules’ feature tab, it doesn’t load.



Thanks for QAing the docs. It looks like we have quite a few issues. Do note, the docs are open source so if you are inclined do to so, you can make tweaks and PRs here: GitHub - ironmansoftware/universal-docs: Documentation for PowerShell Universal

Even if it’s not something you’d like to PR, feel free to open an issue as well.

That said, I’m always updating the docs so if it’s easier just ping me and I can get them updated.

One thing to note for v4 is that we have live documentation for all the components built in. The problem we were always running into was either the docs were not up to date, not working or didn’t have a great screen shot to show exactly what the option or component did. We are also using the live docs for UI testing against the components. The docs themselves are also generated from the PSU module’s comment based help so we only need to update it in one place. I’d really recommend playing around with that since we are only a few weeks away from the v4 release.

1 Like

Also, you first error:

Error: "radialLinear" is not a registered scale.

That’s a bug. The new chartjs library requires that we register each feature that is necessary and it’s not been registered properly.

No prob! It’s only a few minor details, I can imagine how hard it is to keep on top of documentation when things have changed so much and so fast so it’s good youve got a more improved solution for v4, I’ll give it a go tomorrow!