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: Add Mirai Switch #207

Merged
merged 6 commits into from
Sep 30, 2023

Conversation

kushalmahapatro
Copy link
Contributor

Description

Add support for switch in Mirai.

This basically takes up an initial value and a listener onChanged.
The state of the switch is being handled by MiraiSwitchCubit.

This is a draft PR raised to confirm that we are following the right practices and to verify if this is the correct approach for handling the state.

TBD

  1. Type of switch (Material/Cupertino/ adaptive)
  2. Override colors (Is this required, or it would be always forced to adapt to the theme)
  3. Additional action onChanged. (network call / updating value in shared preference or storage etc.)

Related Issues

feat: Add support for Switch in Mirai #168

Type of Change

  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Code refactor
  • Build configuration change
  • Documentation
  • Chore

@kushalmahapatro
Copy link
Contributor Author

Hi @divyanshub024 , @i-asimkhan.

First of all, it was great working on MIRAI and with no due time I was able to adde the support to have a Switch components.

This is not the full implementation, there are some more addition, which has been added in the TBD section and also need to discuss on those points.

@kushalmahapatro kushalmahapatro marked this pull request as draft September 16, 2023 16:48
Copy link
Contributor

@i-asimkhan i-asimkhan left a comment

Choose a reason for hiding this comment

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

Thank you very much for this @kushalmahapatro I have a few suggestions in the comments comparing other parts of the widgets parsers in MIrai.

Copy link
Contributor

@divyanshub024 divyanshub024 left a comment

Choose a reason for hiding this comment

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

Thanks a lot, @kushalmahapatro for this PR. Please check my comments.

@kushalmahapatro kushalmahapatro changed the title [DRAFT] feat: Add Mirai Switch feat: Add Mirai Switch Sep 24, 2023
@kushalmahapatro kushalmahapatro marked this pull request as ready for review September 24, 2023 20:01
Copy link
Contributor

@i-asimkhan i-asimkhan 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, I have only one more comment. 👍 👍 👍

examples/mirai_gallery/assets/json/home_screen.json Outdated Show resolved Hide resolved
Copy link
Contributor

@i-asimkhan i-asimkhan left a comment

Choose a reason for hiding this comment

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

Blocked by review from @divyanshub024

Copy link
Contributor

@divyanshub024 divyanshub024 left a comment

Choose a reason for hiding this comment

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

@kushalmahapatro Thank you so much for this valuable PR. 💯 🙏🏻

@divyanshub024 divyanshub024 merged commit 1591c7b into Securrency-OSS:main Sep 30, 2023
3 checks passed
@kushalmahapatro kushalmahapatro deleted the feature/add-switch branch October 5, 2023 21:52
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