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

feat(datatrak): RN-1408: Move ProjectSelectForm to ui-components #5910

Open
wants to merge 5 commits into
base: dev
Choose a base branch
from

Conversation

tcaiger
Copy link
Contributor

@tcaiger tcaiger commented Sep 18, 2024

Issue #: feat(datatrak): RN-1408: Move ProjectSelectForm to ui-components

Changes:

  • Move ProjectSelectForm to ui-components so it can then be used in tupaia-web

Copy link
Contributor

@alexd-bes alexd-bes 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! A couple of minor ts comments but nothing major so pre-approving

@@ -21,6 +22,20 @@ const ListWrapper = styled.div`
}
`;

type ListItemType = Record<string, unknown> & {
Copy link
Contributor

Choose a reason for hiding this comment

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

Thoughts on adding this to ui-components too, since it's the same as another component uses?


// explicity set the types so that the overrides are applied, for the `button` prop
// explicitly set the types so that the overrides are applied, for the `button` prop
Copy link
Contributor

Choose a reason for hiding this comment

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

Whoops 😆

@@ -126,6 +116,7 @@ export const ListItem = ({ item, children, onSelect }: ListItemProps) => {

return (
<li>
{/*@ts-ignore*/}
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we still need this?

onRequestAccess: (projectCode: Project['code']) => void;
projects?: Project[];
isLoading: boolean;
onConfirm: (data: Record<string, any>) => void;
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
onConfirm: (data: Record<string, any>) => void;
onConfirm: (data: {projectId: string}) => void;

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