carbon-website icon indicating copy to clipboard operation
carbon-website copied to clipboard

docs(progress-bar): add component live demo

Open janhassel opened this issue 2 years ago • 1 comments

Adds a component live demo of the ProgressBar to its "Code" page and the "Usage" page.

Changelog

New

  • Added ProgressBar component demo

Changed

  • Updated react-docgen.json to include ProgressBar props

janhassel avatar Oct 01 '22 08:10 janhassel

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
carbondesignsystem ✅ Ready (Inspect) Visit Preview Oct 6, 2022 at 3:16PM (UTC)

vercel[bot] avatar Oct 01 '22 08:10 vercel[bot]

Noticed that the styles don't seem to be loading properly when the status is changed

Screen Shot 2022-10-03 at 1 16 05 PM

tw15egan avatar Oct 03 '22 17:10 tw15egan

@tw15egan That's weird. It works in the gatsby dev build, but I can reproduce this issue in the production build. Looking at the generated stylesheet, the status style rules are missing even though they are present in the progress-bar.scss source from @carbon/styles (https://unpkg.com/browse/@carbon/[email protected]/scss/components/progress-bar/_progress-bar.scss, lines 96-126).

The styles were included since the v11.3.0 release: https://github.com/carbon-design-system/carbon/commit/c7521ed5a06e7dd53a0d843471fcc0a31f9b8513#diff-0445797061c6a9508f633c1ac24f253522e6e5a2de18b9ef115ca5b9b6717d5c

Do you have an idea why they might not be picked up (or thrown out) in the gatsby production build?

janhassel avatar Oct 04 '22 08:10 janhassel

@janhassel hmm very strange. Could it possibly be resolving to a previous version of the package?

After looking at the yarn.lock I'm seeing that the gatsby-theme-carbon package is resolving to @carbon/[email protected]

Screen Shot 2022-10-04 at 9 31 08 AM

tw15egan avatar Oct 04 '22 13:10 tw15egan

@janhassel hope you don't mind, pushed up a commit that adds a specific resolution. We can take a look and see if the solves it and if there are any other issues by overriding the gatsby theme package resolution version

tw15egan avatar Oct 04 '22 13:10 tw15egan

Hmm that also didn't seem to work, we might need to update the gatsby-theme-carbon package directly

tw15egan avatar Oct 04 '22 14:10 tw15egan

@tw15egan Ah, that makes more sense. Thank you! I noticed gatsby-theme-carbon already updated @carbon/react to v1.11.0 a few weeks back but it hasn't been released yet.

@sstrubberg @tay1orjones Any chance you could push a 3.0.0-next.13 release so that we can pull in the newer Carbon version?

janhassel avatar Oct 05 '22 06:10 janhassel

@janhassel Yes! I just published v3.0.0-next.13

tay1orjones avatar Oct 05 '22 14:10 tay1orjones

Thanks, @tay1orjones! Pushed up a commit that updates the package and it seems to be working 🎉

tw15egan avatar Oct 05 '22 15:10 tw15egan