Closed daniel-dumortier closed 1 year ago
Sorry, after re-reading the doc, I noticed my implementation lacked a feature : optional action should be triggerable when tapping the snackbar. I added that in this last commit. Can you just review this last point ? (I hope I did not made new typos, I carefully read my comments and docs, sorry in advance if i missed again some typos) Thanks !
Sorry, but after further testing, noticed that the maxWidth did not work properly.
Furthermore, with the new signature on UIViewController
's extension, the declaration of maxWidth was not clear, because it could be done on VitaminSnackbar
or as method parameter, and both had not the same meaning, so purpose of each maxWidth
was not really clear.
I changed :
preferredMaxLayoutWidth
refreshing when maxWidth changesUIViewController
's method signature to remove maxWidth parameterAfter that, I needed to rearrange the code, to remain under the limit of 400 lines per file, to please Swiflint ;)
Hope this will be the last version, sorry for all this back and forth ;)
Kudos, SonarCloud Quality Gate passed!
0 Bugs
0 Vulnerabilities
0 Security Hotspots
0 Code Smells
No Coverage information
0.0% Duplication
Changes description
Implementation of the Vitamin snackbar for UIKit
Context
The snackbar is a component that allows to display a short message on the screen, this PR aims to provide this component. fixes #21
It provides two way of displaying a Snackbar :
Checklist
Does this introduce a breaking change?
Screenshots
iPhone
iPad
Other information
This component has been asked by Domyos team for an upcoming feature