in-app-payments-react-native-plugin icon indicating copy to clipboard operation
in-app-payments-react-native-plugin copied to clipboard

saveButtonTextColor doesn't seem to affect anything

Open mrpritchett opened this issue 6 years ago • 4 comments

Describe the issue

We are attempting to set the color of the Save Button in app payments for the "Pay" button for iOS. saveButtonTextColor is the object used to do so from the documentation. I've tried copying the documentation and adjusting values, writing it myself, and it won't take any of my changes. I've gotten all the other settings in that object to update things correctly, but text color doesn't seem to work.

To Reproduce

      await SQIPCardEntry.setIOSCardEntryTheme({
        saveButtonFont: {
            size: 30,
          },
          saveButtonTitle: 'Pay 💳 ',
          keyboardAppearance: 'Light',
          saveButtonTextColor: {
            r: 255,
            g: 0,
            b: 0,
            a: 1.0,
          },
      });
    }

Expected behavior

The color should update where it says "Pay" to be the color I specify. Screen Shot 2020-01-10 at 11 37 31 AM

Environment (please complete the following information):

  • platform: iOS
  • OS and version: iOS11+
  • dev environment: MacOS
  • In-App Payments Plugin version: 1.3.0
System:
   OS: macOS 10.15.2
   CPU: (8) x64 Intel(R) Core(TM) i5-8279U CPU @ 2.40GHz
   Memory: 59.94 MB / 16.00 GB
   Shell: 5.0.11 - /usr/local/bin/bash
 Binaries:
   Node: 12.10.0 - ~/.nvm/versions/node/v12.10.0/bin/node
   Yarn: 1.16.0 - ~/.yarn/bin/yarn
   npm: 6.10.3 - ~/.nvm/versions/node/v12.10.0/bin/npm
   Watchman: 4.9.0 - /usr/local/bin/watchman
 SDKs:
   iOS SDK:
     Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1
 IDEs:
   Xcode: 11.3/11C29 - /usr/bin/xcodebuild
 npmPackages:
   @react-native-community/cli: ^3.0.4 => 3.0.4 
   react: 16.9.0 => 16.9.0 
   react-native: 0.61.5 => 0.61.5

mrpritchett avatar Jan 10 '20 16:01 mrpritchett

More research, this is the initial state. The provided option sets the color once the data is filled in, but no the initial state.

mrpritchett avatar Jan 10 '20 16:01 mrpritchett

This is intended. According to the documentation: "The text color of the save button when enabled." (https://developer.squareup.com/docs/api/in-app-payment/ios/Classes/SQIPTheme.html#/c:objc(cs)SQIPTheme(py)saveButtonTextColor) Enabled, implying when it's clickable. There's no way to change the initial (disabled) text color at this time.

StephenJosey avatar Jan 16 '20 23:01 StephenJosey

I'd say that's not a great user experience, even if intended. Instead of closing this @StephenJosey, can we label this as a feature request and keep it open?

mrpritchett avatar Jan 16 '20 23:01 mrpritchett

Sure thing, of course!

StephenJosey avatar Jan 16 '20 23:01 StephenJosey

Thank you for your feedback. We have shared the feedback with our team.

CharmisG avatar Dec 09 '22 09:12 CharmisG