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

[IOPLT-133] Implements NumberPad component #127

Merged
merged 9 commits into from
Nov 6, 2023
Merged

[IOPLT-133] Implements NumberPad component #127

merged 9 commits into from
Nov 6, 2023

Conversation

CrisTofani
Copy link
Contributor

@CrisTofani CrisTofani commented Nov 2, 2023

Short description

This PR creates the new NumberPad component

List of changes proposed in this pull request

  • Implements new NumberPad component

How to test

Check related screen in example app

Simulator.Screen.Recording.-.iPhone.14.Pro.-.2023-11-02.at.15.38.31.mp4

@CrisTofani CrisTofani requested review from dmnplb and a team as code owners November 2, 2023 14:40
import { IOIconSizeScale, IOIcons } from "../icons";
import { NumberButton } from "./NumberButton";

type BiometricAuthProps =
Copy link
Contributor

Choose a reason for hiding this comment

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

can this type be just :

type BiometricAuthProps = {
  biometricType?: BiometricsValidType;
  onBiometricPress?: () => void;
  biometricAccessibilityLabel?: string;
};

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Using the union type here defined we can handle the constraint of having all three props none of them defined at the same time: if we have a biometric option the tercet must be valorized correctly


type ButtonType = "biometric" | "delete";

const RowButtons = ({
Copy link
Contributor

Choose a reason for hiding this comment

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

Could this component be extracted as a standalone, reusable component, separate from the NumberPad?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually this should be only a local component avoiding code duplication to repeat button lines. Do you see any other possible usage of the component? 😄

Copy link
Collaborator

@dmnplb dmnplb left a comment

Choose a reason for hiding this comment

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

As I can see from the simulator (and now from the attached video), the component does not seem to respect the experimental design mode (in the disabled state)

@CrisTofani
Copy link
Contributor Author

As I can see from the simulator (and now from the attached video), the component does not seem to respect the experimental design mode (in the disabled state)

fixed in d684d67

@CrisTofani CrisTofani requested a review from dmnplb November 6, 2023 14:29
@CrisTofani CrisTofani merged commit c53995f into main Nov 6, 2023
2 checks passed
@CrisTofani CrisTofani deleted the IOPLT-133 branch November 6, 2023 16:53
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