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

LF-4612c Fix margin on icons without checkbox #3612

Merged
merged 6 commits into from
Dec 12, 2024

Conversation

kathyavini
Copy link
Collaborator

@kathyavini kathyavini commented Dec 12, 2024

Description

Thank you @SayakaOno for remembering the checkbox-less view 🙏 🙏 🙏

Jira link: https://lite-farm.atlassian.net/browse/LF-4612

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Passes test case
  • UI components visually reviewed on desktop view
  • UI components visually reviewed on mobile view
  • Other (please explain)

Checklist:

  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • The precommit and linting ran successfully
  • I have added or updated language tags for text that's part of the UI
  • I have added "MISSING" for all new language tags to languages I don't speak
  • I have added the GNU General Public License to all new files

@kathyavini kathyavini added the bug Something isn't working label Dec 12, 2024
@kathyavini kathyavini self-assigned this Dec 12, 2024
@kathyavini kathyavini requested review from a team as code owners December 12, 2024 19:44
@kathyavini kathyavini requested review from antsgar and Duncan-Brain and removed request for a team December 12, 2024 19:44
className={clsx(
styles.tableCell,
dense && styles.dense,
shouldShowCheckbox && id === 'identification' && styles.afterCheckbox,
Copy link
Collaborator

Choose a reason for hiding this comment

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

It would be ideal if we could avoid bringing an animal specific column...
Is it possible to add the style to animalsColumns in Inventory container like we do for the arrow?

{
  id: showLinks ? 'path' : null,
  label: '',
  format: (d: AnimalInventoryItem) => (
    <Cell kind={CellKind.RIGHT_CHEVRON_LINK} path={d.path} />
  ),
  columnProps: {
    style: { width: '40px', padding: `0 ${isDesktop ? 12 : 8}px` },
  },
  sortable: false,
},

I hope the container knows if it needs to show checkboxes or not 🙏

Copy link
Collaborator Author

@kathyavini kathyavini Dec 12, 2024

Choose a reason for hiding this comment

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

@SayakaOno could you open a PR to demo what you're thinking?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Sorry, it can't be done with columnProps!! I realized it after looking at the code carefully...
Instead, I tried adding a className to the cell. Here's the test code: a889d3d

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's a much better solution and actually it probably would have saved me so prop passing to do that earlier, for removed! ❤️

Copy link
Collaborator

@SayakaOno SayakaOno left a comment

Choose a reason for hiding this comment

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

Let's test in on beta!

@SayakaOno SayakaOno added this pull request to the merge queue Dec 12, 2024
@kathyavini kathyavini merged commit 9cb0855 into integration Dec 12, 2024
5 checks passed
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

Successfully merging this pull request may close these issues.

2 participants