Skip to content

ref: #597 TS conversions for some flag table related components - #2660

Merged
ajay-sentry merged 5 commits into
mainfrom
Ajay/597-part-1-ts-convert
Mar 8, 2024
Merged

ajay-sentry merged 5 commits into
mainfrom
Ajay/597-part-1-ts-convert

Conversation

@ajay-sentry

@ajay-sentry ajay-sentry commented Mar 6, 2024 •

Copy link
Copy Markdown
Contributor

Description

yak shaving around cleaning up some of the flag table component "innards" prior to converting the table itself to TS and tanstack table.

I find working from "out to in" helps me when doing refactors like this because I can see how a lot of stuff is building together to create these larger components

Code Example

Notable Changes

Nothing major, in the process of doing some of the conversions I did move things over from "Object.freeze" to generic consts, as well as explicitly declaring props in the areas we did some prop drilling; like for the progress and coverage progress components.

Screenshots

Screenshot 2024-03-06 at 3 12 38 PM

Manual Testing

  • Navigated to flags table and confirmed no regression
  • Clicked through the app and aside from my one accountDetails mis-step I think app looks to be functioning similarly

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

@codecov

codecov Bot commented Mar 6, 2024 •

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.43%. Comparing base (20c1adb) to head (b0ab80c).

Additional details and impacted files

Impacted file tree graph

@@          Coverage Diff          @@
##            main   #2660   +/-   ##
=====================================
  Coverage   98.43   98.43           
=====================================
  Files        854     854           
  Lines      11912   11918    +6     
  Branches    3127    3122    -5     
=====================================
+ Hits       11725   11731    +6     
  Misses       184     184           
  Partials       3       3           
Files Coverage Δ
...CommitsTab/CommitsTable/createCommitsTableData.tsx 100.00% <100.00%> (ø)
...c/pages/RepoPage/FlagsTab/BackfillBanners/hooks.ts 100.00% <ø> (ø)
src/services/repo/useRepoBackfilled.ts 100.00% <100.00%> (ø)
...ared/ListRepo/ReposTable/getReposColumnsHelper.tsx 100.00% <ø> (ø)
src/shared/utils/determineProgressColor.ts 100.00% <ø> (ø)
src/ui/CoverageProgress/CoverageProgress.tsx 100.00% <100.00%> (ø)
src/ui/Progress/Progress.tsx 100.00% <100.00%> (ø)
src/ui/Spinner/Spinner.tsx 100.00% <ø> (ø)
src/ui/TotalsNumber/TotalsNumber.tsx 100.00% <100.00%> (ø)
Components Coverage Δ
Assets 55.55% <ø> (ø)
Layouts 97.13% <ø> (ø)
Pages 99.33% <100.00%> (ø)
Services 99.57% <100.00%> (+<0.01%) ⬆️
Shared 99.83% <ø> (ø)
UI 94.17% <100.00%> (+0.01%) ⬆️

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 20c1adb...b0ab80c. Read the comment docs.

@codecov-staging

codecov-staging Bot commented Mar 6, 2024 •

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2660   +/-   ##
=======================================
  Coverage   98.43%   98.43%           
=======================================
  Files         854      854           
  Lines       11912    11918    +6     
  Branches     3127     3080   -47     
=======================================
+ Hits        11725    11731    +6     
  Misses        184      184           
  Partials        3        3           
Files Coverage Δ
...CommitsTab/CommitsTable/createCommitsTableData.tsx 100.00% <100.00%> (ø)
...c/pages/RepoPage/FlagsTab/BackfillBanners/hooks.ts 100.00% <ø> (ø)
src/services/repo/useRepoBackfilled.ts 100.00% <100.00%> (ø)
...ared/ListRepo/ReposTable/getReposColumnsHelper.tsx 100.00% <ø> (ø)
src/shared/utils/determineProgressColor.ts 100.00% <ø> (ø)
src/ui/CoverageProgress/CoverageProgress.tsx 100.00% <100.00%> (ø)
src/ui/Progress/Progress.tsx 100.00% <100.00%> (ø)
src/ui/Spinner/Spinner.tsx 100.00% <ø> (ø)
src/ui/TotalsNumber/TotalsNumber.tsx 100.00% <100.00%> (ø)
Components Coverage Δ
Assets 55.55% <ø> (ø)
Layouts 97.13% <ø> (ø)
Pages 99.33% <100.00%> (ø)
Services 99.57% <100.00%> (+<0.01%) ⬆️
Shared 99.83% <ø> (ø)
UI 94.17% <100.00%> (+0.01%) ⬆️

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 20c1adb...b0ab80c. Read the comment docs.

@codecov-public-qa

codecov-public-qa Bot commented Mar 6, 2024 •

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (20c1adb) 98.43% compared to head (b0ab80c) 98.43%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2660   +/-   ##
=======================================
  Coverage   98.43%   98.43%           
=======================================
  Files         854      854           
  Lines       11912    11918    +6     
  Branches     3127     3078   -49     
=======================================
+ Hits        11725    11731    +6     
  Misses        184      184           
  Partials        3        3           
Files Coverage Δ
...CommitsTab/CommitsTable/createCommitsTableData.tsx 100.00% <100.00%> (ø)
...c/pages/RepoPage/FlagsTab/BackfillBanners/hooks.ts 100.00% <ø> (ø)
src/services/repo/useRepoBackfilled.ts 100.00% <100.00%> (ø)
...ared/ListRepo/ReposTable/getReposColumnsHelper.tsx 100.00% <ø> (ø)
src/shared/utils/determineProgressColor.ts 100.00% <ø> (ø)
src/ui/CoverageProgress/CoverageProgress.tsx 100.00% <100.00%> (ø)
src/ui/Progress/Progress.tsx 100.00% <100.00%> (ø)
src/ui/Spinner/Spinner.tsx 100.00% <ø> (ø)
src/ui/TotalsNumber/TotalsNumber.tsx 100.00% <100.00%> (ø)
Components Coverage Δ
Assets 55.55% <ø> (ø)
Layouts 97.13% <ø> (ø)
Pages 99.33% <100.00%> (ø)
Services 99.57% <100.00%> (+<0.01%) ⬆️
Shared 99.83% <ø> (ø)
UI 94.17% <100.00%> (+0.01%) ⬆️

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 20c1adb...b0ab80c. Read the comment docs.

@codecov-qa

codecov-qa Bot commented Mar 6, 2024 •

Copy link
Copy Markdown

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 98.43%. Comparing base (20c1adb) to head (d15ab72).

❗ Current head d15ab72 differs from pull request most recent head b0ab80c. Consider uploading reports for the commit b0ab80c to get more accurate results

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2660      +/-   ##
==========================================
+ Coverage   89.61%   98.43%   +8.81%     
==========================================
  Files         852      854       +2     
  Lines       11907    11918      +11     
  Branches     3119     3113       -6     
==========================================
+ Hits        10670    11731    +1061     
+ Misses       1211      184    -1027     
+ Partials       26        3      -23     
Files Coverage Δ
...CommitsTab/CommitsTable/createCommitsTableData.tsx 100.00% <100.00%> (ø)
...c/pages/RepoPage/FlagsTab/BackfillBanners/hooks.ts 100.00% <ø> (ø)
src/services/repo/useRepoBackfilled.ts 100.00% <100.00%> (ø)
...ared/ListRepo/ReposTable/getReposColumnsHelper.tsx 100.00% <ø> (ø)
src/shared/utils/determineProgressColor.ts 100.00% <ø> (ø)
src/ui/CoverageProgress/CoverageProgress.tsx 100.00% <100.00%> (ø)
src/ui/Progress/Progress.tsx 100.00% <100.00%> (ø)
src/ui/Spinner/Spinner.tsx 100.00% <ø> (ø)
src/ui/TotalsNumber/TotalsNumber.tsx 100.00% <100.00%> (ø)

... and 87 files with indirect coverage changes

Components Coverage Δ
Assets 55.55% <ø> (+2.61%) ⬆️
Layouts 97.13% <ø> (+77.38%) ⬆️
Pages 99.33% <100.00%> (+10.55%) ⬆️
Services 99.57% <100.00%> (+0.04%) ⬆️
Shared 99.83% <ø> (ø)
UI 94.17% <100.00%> (+0.18%) ⬆️

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 20c1adb...b0ab80c. Read the comment docs.

currentPeriodEnd: z.number(),
customer: z
.object({
discount: z.number(),

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

this is unrelated but is a regression I need to merge with one of my upcoming PRs

@codecov-releaser

Copy link
Copy Markdown
Collaborator

@codecov-releaser

codecov-releaser commented Mar 7, 2024 •

Copy link
Copy Markdown
Collaborator

✅ Deploy preview for gazebo ready!

Previews expire after 1 month automatically.

Commit Created Cloud Enterprise
1a6bb12 Thu, 07 Mar 2024 23:34:38 GMT Expired Expired
b0ab80c Fri, 08 Mar 2024 19:42:40 GMT Cloud Enterprise

Comment thread src/services/repo/useRepoBackfilled.ts Resolved
Comment thread src/ui/Progress/Progress.tsx Resolved
@ajay-sentry
ajay-sentry merged commit 9f3692f into main Mar 8, 2024
@ajay-sentry
ajay-sentry deleted the Ajay/597-part-1-ts-convert branch March 8, 2024 19:45
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