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

Accordion cleanup and release #2119

Merged
merged 3 commits into from
Nov 16, 2023
Merged

Accordion cleanup and release #2119

merged 3 commits into from
Nov 16, 2023

Conversation

nishasy
Copy link
Contributor

@nishasy nishasy commented Nov 16, 2023

Summary:

All that's left is some polishing, and the Accordion component should be ready for launch!

In this PR:

  • Prioritize children's values for overloaded props
  • Fix the issue where the bottom border radius was applying to non-last section content when it wasn't supposed to
  • Update the Uncontrolled AccordionSection story so it actually says it's uncontrolled
  • Add categories to prop tables
  • Fixed typo
  • Update comments and documentation accordingly
  • Make Accordion package.json say that the package is public! 🎉

Issue: https://khanacademy.atlassian.net/browse/WB-1585

Test plan:

yarn jest

Storybook

  • Confirm that Accordion's prop table has the props split up into sections now
  • Confirm that AccordionSection's prop table has the props split the sections now
  • Confirm that all the documentation says that the children override the parents' props
  • Go to Accordion's "React Element in Children" story and confirm that the corners don't have overflow.

@nishasy nishasy self-assigned this Nov 16, 2023
Copy link

changeset-bot bot commented Nov 16, 2023

🦋 Changeset detected

Latest commit: 358334d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@khanacademy/wonder-blocks-accordion Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link

codecov bot commented Nov 16, 2023

Codecov Report

Merging #2119 (358334d) into main (16d99bd) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2119   +/-   ##
=======================================
  Coverage   97.07%   97.07%           
=======================================
  Files         243      243           
  Lines       28238    28240    +2     
  Branches     2466     2420   -46     
=======================================
+ Hits        27411    27413    +2     
  Misses        827      827           
Files Coverage Δ
...cks-accordion/src/components/accordion-section.tsx 100.00% <100.00%> (ø)
...nder-blocks-accordion/src/components/accordion.tsx 100.00% <100.00%> (ø)

Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 16d99bd...358334d. Read the comment docs.

Copy link
Contributor

github-actions bot commented Nov 16, 2023

Size Change: +7 B (0%)

Total Size: 92.7 kB

Filename Size Change
packages/wonder-blocks-accordion/dist/es/index.js 3.67 kB +7 B (0%)
ℹ️ View Unchanged
Filename Size
packages/wonder-blocks-banner/dist/es/index.js 1.53 kB
packages/wonder-blocks-birthday-picker/dist/es/index.js 1.72 kB
packages/wonder-blocks-breadcrumbs/dist/es/index.js 1.13 kB
packages/wonder-blocks-button/dist/es/index.js 4.26 kB
packages/wonder-blocks-cell/dist/es/index.js 2.19 kB
packages/wonder-blocks-clickable/dist/es/index.js 3.23 kB
packages/wonder-blocks-color/dist/es/index.js 1.15 kB
packages/wonder-blocks-core/dist/es/index.js 3.67 kB
packages/wonder-blocks-data/dist/es/index.js 6.33 kB
packages/wonder-blocks-dropdown/dist/es/index.js 12 kB
packages/wonder-blocks-form/dist/es/index.js 5.34 kB
packages/wonder-blocks-grid/dist/es/index.js 1.36 kB
packages/wonder-blocks-i18n/dist/es/index.js 4.54 kB
packages/wonder-blocks-icon-button/dist/es/index.js 3.06 kB
packages/wonder-blocks-icon/dist/es/index.js 3.04 kB
packages/wonder-blocks-labeled-field/dist/es/index.js 72 B
packages/wonder-blocks-layout/dist/es/index.js 1.88 kB
packages/wonder-blocks-link/dist/es/index.js 2.54 kB
packages/wonder-blocks-modal/dist/es/index.js 5.04 kB
packages/wonder-blocks-pill/dist/es/index.js 1.03 kB
packages/wonder-blocks-popover/dist/es/index.js 4.33 kB
packages/wonder-blocks-progress-spinner/dist/es/index.js 1.51 kB
packages/wonder-blocks-search-field/dist/es/index.js 1.55 kB
packages/wonder-blocks-spacing/dist/es/index.js 158 B
packages/wonder-blocks-switch/dist/es/index.js 2.06 kB
packages/wonder-blocks-testing/dist/es/index.js 3.94 kB
packages/wonder-blocks-theming/dist/es/index.js 1.21 kB
packages/wonder-blocks-timing/dist/es/index.js 1.78 kB
packages/wonder-blocks-toolbar/dist/es/index.js 862 B
packages/wonder-blocks-tooltip/dist/es/index.js 5.05 kB
packages/wonder-blocks-typography/dist/es/index.js 1.49 kB

compressed-size-action

Copy link
Contributor

github-actions bot commented Nov 16, 2023

A new build was pushed to Chromatic! 🚀

undefined

Chromatic results:

Metric Total
Captured snapshots undefined
Tests with visual changes undefined
Total stories undefined
Inherited (not captured) snapshots [TurboSnap] undefined
Tests on the build undefined

…nt to be cut off when it wasn't in the last section of a rounded accordion
@nishasy nishasy changed the title WIP: Accordion cleanup and release Accordion cleanup and release Nov 16, 2023
@nishasy nishasy requested review from jandrade and a team November 16, 2023 07:38
@nishasy nishasy marked this pull request as ready for review November 16, 2023 07:44
@khan-actions-bot
Copy link
Contributor

Gerald

Required Reviewers
  • @Khan/wonder-blocks for changes to .changeset/wet-apricots-wait.md, __docs__/wonder-blocks-accordion/accordion-section.argtypes.tsx, __docs__/wonder-blocks-accordion/accordion-section.stories.tsx, __docs__/wonder-blocks-accordion/accordion.argtypes.tsx, __docs__/wonder-blocks-accordion/accordion.stories.tsx, packages/wonder-blocks-accordion/package.json, packages/wonder-blocks-accordion/src/components/accordion-section.tsx, packages/wonder-blocks-accordion/src/components/accordion.tsx, packages/wonder-blocks-accordion/src/components/__tests__/accordion-section.test.tsx, packages/wonder-blocks-accordion/src/components/__tests__/accordion.test.tsx

Don't want to be involved in this pull request? Comment #removeme and we won't notify you of further changes.

Copy link
Contributor

npm Snapshot: Published

🎉 Good news!! We've packaged up the latest commit from this PR (c8d86f5) and published all packages with changesets to npm.

You can install the packages in webapp by running:

./services/static/dev/tools/deploy_wonder_blocks.js --tag="PR2119"

Packages can also be installed manually by running:

yarn add @khanacademy/wonder-blocks-<package-name>@PR2119

Copy link
Member

@jandrade jandrade left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything looks great!! Congrats on finishing this complex component and taking care of all the considerations 👏 🚢 :shipit: 🚀

"publishConfig": {
"access": "restricted"
"access": "public"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@nishasy nishasy merged commit b13d432 into main Nov 16, 2023
46 checks passed
@nishasy nishasy deleted the accordion-cleanup branch November 16, 2023 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants