Skip to content

Conversation

@pavelpashkovsky
Copy link
Contributor

@pavelpashkovsky pavelpashkovsky commented Sep 8, 2022

@github-actions
Copy link
Contributor

github-actions bot commented Sep 8, 2022

size-limit report 📦

Path Size Loading time (3g) Running time (snapdragon) Total time
webapp/public/assets/app.js 420.97 KB (+0.12% 🔺) 8.5 s (+0.12% 🔺) 4.6 s (+5.57% 🔺) 13 s
webapp/public/assets/app.css 15.87 KB (+1.24% 🔺) 318 ms (+1.24% 🔺) 0 ms (+100% 🔺) 318 ms
webapp/public/assets/styles.css 9.47 KB (0%) 190 ms (0%) 0 ms (+100% 🔺) 190 ms
packages/pyroscope-flamegraph/dist/index.js 92.08 KB (+0.32% 🔺) 1.9 s (+0.32% 🔺) 1.4 s (-28.81% 🔽) 3.2 s
packages/pyroscope-flamegraph/dist/index.node.js 91.97 KB (+0.35% 🔺) 1.9 s (+0.35% 🔺) 559 ms (-27.96% 🔽) 2.4 s
packages/pyroscope-flamegraph/dist/index.css 7.32 KB (+2.78% 🔺) 147 ms (+2.78% 🔺) 0 ms (+100% 🔺) 147 ms

@codecov
Copy link

codecov bot commented Sep 8, 2022

Codecov Report

Merging #1474 (5d47380) into main (b8f0296) will increase coverage by 0.01%.
The diff coverage is 30.00%.

@@            Coverage Diff             @@
##             main    #1474      +/-   ##
==========================================
+ Coverage   68.66%   68.66%   +0.01%     
==========================================
  Files         131      131              
  Lines        4316     4342      +26     
  Branches     1166     1175       +9     
==========================================
+ Hits         2963     2981      +18     
- Misses       1347     1355       +8     
  Partials        6        6              
Impacted Files Coverage Δ
webapp/javascript/ui/Box.module.scss 61.54% <0.00%> (+7.70%) ⬆️
webapp/javascript/ui/Box.tsx 63.89% <40.00%> (+3.89%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@pavelpashkovsky
Copy link
Contributor Author

/create-server

Copy link
Collaborator

@eh-am eh-am left a comment

Choose a reason for hiding this comment

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

Looks good!

Few thoughts:

  1. Would be nice to have a storybook example since this is effectively a new, reusable component. This is so that new devs can refer to this "library of components"

  2. Behaviour is weird when title is empty:
    https://user-images.githubusercontent.com/6951209/189142078-7e9999dc-9881-4aa1-9dfa-7742c83b3e39.mp4

  • if a title MUST not be empty, then we should add least document this invariant
  • also if we are supporting empty title, chevron should always be on the right, this is so that the user can immediately develop familiarity (if i know one CollapsibleBox then I know all of them)
  1. Another thing I have strong opinions is to ALWAYS show the chevron. Reason is for discoverability. I want to be able to figure out what the component does immediately, I shouldn't need to hover. Specially because not all people interact with a hover. (yeah i know, we also have tooltips, but still)

</div>
</Box>
<Box>
<CollapseBox title={`${appName.unwrapOr('')} Descriptive Statistics`}>
Copy link
Collaborator

Choose a reason for hiding this comment

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

When appName is empty, this renders

 Descriptive Statistics

Notice the space at the beginning.

Suggested change
<CollapseBox title={`${appName.unwrapOr('')} Descriptive Statistics`}>
<CollapseBox
title={`${appName
.map((a) => `${a} Descriptive Statistics`)
.unwrapOr('')}`}
>

Map only runs if it's a Just, ie. there's an appName defined.

@pavelpashkovsky
Copy link
Contributor Author

updated! @eh-am

@eh-am eh-am merged commit 6595794 into main Sep 9, 2022
@eh-am eh-am deleted the collapse-box branch September 9, 2022 16:59
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.

2 participants