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

Add ability to customize accent colour #35

Closed
khuffie opened this issue Feb 20, 2021 · 6 comments
Closed

Add ability to customize accent colour #35

khuffie opened this issue Feb 20, 2021 · 6 comments
Labels
enhancement Feature request that enhances features and will be worked on good first issue Good for newcomers
Milestone

Comments

@khuffie
Copy link
Contributor

khuffie commented Feb 20, 2021

The default colour is blue for PermissionsSwiftUI, which doesn't quite work with my app's design.

For the permission images, I can pass in custom images and provide them with my preferred accent colour.

For the buttons, there seems to be no way to customize them. I see in the source code "ButtonStatusColor", but as it's not a public class I cannot extend it and over-ride it.

Being able to pass in an accent colour that when calling .JMModal would be great!

@khuffie khuffie added enhancement Feature request that enhances features and will be worked on good first issue Good for newcomers labels Feb 20, 2021
@jevonmao
Copy link
Owner

@khuffie Great suggestion. This feature will be added ASAP!

@jevonmao jevonmao added this to the 1.2.2 release milestone Feb 20, 2021
@jevonmao jevonmao added the open label Feb 20, 2021
@khuffie
Copy link
Contributor Author

khuffie commented Feb 21, 2021

@jevonmao that's great! Let me know, anxious to release it :)

(PS: it would be good if the accent colour also affects the images :)

@jevonmao jevonmao removed the open label Feb 21, 2021
@jevonmao
Copy link
Owner

@khuffie It's done! Worked on the project for the entire afternoon, and in the latest 1.2.2 release, you should be able to customize all the buttons, all the colors, for all states.
Use the setAllowButtonColor(to colors:AllButtonColors) view modifier

@jevonmao
Copy link
Owner

@khuffie Actually, looking at this new API, it's badly designed. I don't like it, too complicated and unnecessary. I will rework this feature, and use a single modifier to change accent color of buttons and the image icons.

@khuffie
Copy link
Contributor Author

khuffie commented Feb 21, 2021

@jevonmao no worries! Take your time :)

@jevonmao
Copy link
Owner

@khuffie The feature is ready!. Please update to v1.2.3, and reference README.md if needed.

@jevonmao jevonmao closed this as completed Mar 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature request that enhances features and will be worked on good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants