Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Polariz-Viz testing error within the package (in the createGradient utility) #1598

Open
LeonaTheDev opened this issue Oct 5, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@LeonaTheDev
Copy link

Bug summary

I have a partner who is creating an app and would like to know if we have any built-in visualization components in Polaris (graphs or bar charts, NOT data tables)? They have tried using Polariz viz, but got errors when testing it. Then they created a new 'Graph' component in React, which imported: 'import {PolarisVizProvider} from '@shopify/polaris-viz';'. They wrapped that specific component in the '' . The support team suggested that they can wrap the anywhere in the tree as long as it wraps the chart itself. It’s easiest to wrap the entire app in the provider so you only have to do it once, but i can go anywhere. Partner followed up saying they did as instructed and get this error: https://screenshot.click/03-44-73189-77784.png. They tried to install the d3-scale separately using npm. Whatever they try, the Polaris Viz still doesn't seem to be supported by the development environment

Expected behavior

Trying to determine if Polaris, a Shopify design system, includes any pre-built visualization components such as graphs or bar charts (excluding data tables).

Actual behavior

They tried to install the d3-scale separately using npm. Whatever they try, the Polaris Viz still doesn't seem to be supported by the development environment
https://screenshot.click/03-44-73189-77784.png

Steps to reproduce the problem

  1. Wrap the anywhere in the tree as long as it wraps the chart itself
  2. Internal team states that "It looks to be an import error within the package (in the createGradient utility) and not with the parter's app".

Reduced test case

The best way to get your bug fixed is to provide a reduced test case. This CodeSandbox template is a great starting point.

Specifications

  • Polaris-Viz version number:
  • Browser:
  • Device:
  • Operating System:

Or run npx envinfo --system --binaries --browsers --npmPackages react,react-dom,@shopify/polaris-viz to provide specifications on your environment including version numbers, browser, device, and operating system.

Paste the results here:

@LeonaTheDev LeonaTheDev added the bug Something isn't working label Oct 5, 2023
@boxedcode
Copy link

@LeonaTheDev Did you ever find a solution to this? I've just had the exact same issue trying to use Polaris Viz within a remix app.

@boxedcode
Copy link

@LeonaTheDev jfyi, in case you haven't found a solution yet, I found the solution here: #1425

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants