-
Notifications
You must be signed in to change notification settings - Fork 2
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
MOB-428 : add custom amount to price triggers screen #140
MOB-428 : add custom amount to price triggers screen #140
Conversation
0c667e2
to
29ed2c1
Compare
@@ -1,5 +1,5 @@ | |||
{ | |||
"originHash" : "e085067eee7983e4ba42c06fd96e9ea3884445575db37e125bed61bde5eeb3f1", | |||
"originHash" : "3cd7346cace16cf660f9c22302c5ca6770335c67902f3fd155011356a9d43929", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ruixhuang any chance you know why my package resolved file just keeps updating? It's all over the place
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah.. it happens to me, I'd just revert it without checking it in.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i might remove
@@ -524,7 +524,7 @@ open class PlatformBooleanInputViewModel: PlatformValueInputViewModel { | |||
if let label = label, label.length > 0 { | |||
return Text(label) | |||
.themeColor(foreground: isEnabled ? .textSecondary : .textTertiary) | |||
.themeFont(fontSize: .smaller) | |||
.themeFont(fontSize: .medium) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tested this in other places (trade input view)
|
||
@objc private func sliderValueChanged(sender: UISlider) { | ||
guard let stepSizeDecimals else { return } | ||
let roundedValue = dydxFormatter.shared.raw(number: NSNumber(value: sender.value), digits: stepSizeDecimals) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Markets like Shiba have stepSize like 100, 1000, 10000, so we'd need to round the size with something like
size = Int(size / stepSize) * stepSize
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah, i thought the raw function did that, looks like it does in some implementations, I will update in this PR
}() | ||
|
||
private var sliderBackground: some View { | ||
GeometryReader { geometry in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Nice trick!
* bump 1.6.36 -> 1.6.38 * some ui * add label accessory to platform input, split out input views into view models * clean up * add cta button * hook up button and button states * abacus? * clean up * pause * clean up * clean up * fix rounding
* bump 1.6.36 -> 1.6.38 * some ui * add label accessory to platform input, split out input views into view models * clean up * add cta button * hook up button and button states * abacus? * clean up * pause * clean up * clean up * fix rounding
* bump 1.6.36 -> 1.6.38 * some ui * add label accessory to platform input, split out input views into view models * clean up * add cta button * hook up button and button states * abacus? * clean up * pause * clean up * clean up * fix rounding
Links (dYdX Internal Use Only)
Linear Ticket: MOB-428 : add custom amount to price triggers screen
Figma Design: https://www.figma.com/file/mKevZOfE9nj6MZpiolKYW1/dYdX-%E2%80%BA-Mobile?type=design&node-id=5621-14695&mode=design&t=eTjSvS2SdkstNDMd-4
Description / Intuition
size
fieldBefore/After Screenshots or Videos
Simulator.Screen.Recording.-.iPhone.15.-.2024-04-11.at.21.00.31.mp4
Simulator.Screen.Recording.-.iPhone.15.-.2024-04-12.at.18.02.56.mp4
Type of Change