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: dynamic messaging #2349

Merged
merged 9 commits into from Apr 12, 2024
Merged

feat: dynamic messaging #2349

merged 9 commits into from Apr 12, 2024

Conversation

danzhaaspaypal
Copy link
Contributor

@danzhaaspaypal danzhaaspaypal commented Feb 29, 2024

Description

Adds dynamic messaging components to Buttons by leveraging assets from paypal-messaging-components.

Why are we making these changes? Include references to any related Jira tasks or GitHub Issues

  • Provides dynamic messaging (Pay Later, Rewards, and more) to be coupled with button integrations that inform customers of the benefits of choosing PayPal as their way to pay.
  • Provide merchants with more flexibility with dynamic messaging integrations that cover additional use cases where we currently have gaps.
  • Do not negatively impact the performance that merchants demand when integrating PayPal solutions in their website or mobile apps.

Reproduction Steps (if applicable)

Starting with a paypal.Buttons component, pass into the param object a message object with props including any of the following: amount, offer, color, position, align.

Accepted values:

  • Amount: any positive number
  • Offer: pay_later_short_term or pay_later_long_term
  • Color: black or white
  • Position: top or bottom
  • Align: left or center or right

Screenshots (if applicable)

Screenshot 2024-04-09 at 10 12 01 AM

Screenshot 2024-04-09 at 10 12 19 AM

Dependent Changes (if applicable)

  • Internal dependencies; contact @danzhaaspaypal for details.
  • paypal-messaging-components (contextual_components PRs, already merged and deployed)

Groups who should review (if applicable)

❤️ Thank you!

Copy link

codecov bot commented Apr 1, 2024

Codecov Report

Attention: Patch coverage is 43.47826% with 221 lines in your changes are missing coverage. Please review.

Project coverage is 51.75%. Comparing base (cb69c02) to head (3435784).
Report is 2 commits behind head on main.

❗ Current head 3435784 differs from pull request most recent head 0548174. Consider uploading reports for the commit 0548174 to get more accurate results

Files Patch % Lines
src/zoid/buttons/component.jsx 15.12% 101 Missing ⚠️
src/ui/buttons/props.js 50.96% 51 Missing ⚠️
src/zoid/buttons/util.js 50.94% 26 Missing ⚠️
src/ui/buttons/util.js 47.22% 19 Missing ⚠️
src/ui/buttons/buttons.jsx 45.45% 12 Missing ⚠️
src/ui/buttons/message.jsx 61.29% 12 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2349      +/-   ##
==========================================
- Coverage   52.03%   51.75%   -0.29%     
==========================================
  Files         148      149       +1     
  Lines       11953    12338     +385     
  Branches      673      703      +30     
==========================================
+ Hits         6220     6385     +165     
- Misses       5628     5848     +220     
  Partials      105      105              
Flag Coverage Δ
jest 31.08% <26.56%> (-0.34%) ⬇️
karma 54.11% <91.35%> (+2.01%) ⬆️
vitest 45.53% <25.06%> (-0.68%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Seavenly Seavenly changed the title Feat: Dynamic messaging feat: dynamic messaging Apr 11, 2024
@Seavenly Seavenly marked this pull request as ready for review April 11, 2024 15:35
@Seavenly Seavenly requested a review from a team as a code owner April 11, 2024 15:35
@@ -5,7 +5,7 @@
"path": "size.min.js",
"compression": "gzip",
"maxPercentIncrease": 3.6,
"maxSize": "77kb"
"maxSize": "79kb"
Copy link
Member

Choose a reason for hiding this comment

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

👍

@Seavenly Seavenly merged commit 4b3d77a into main Apr 12, 2024
3 checks passed
@Seavenly Seavenly deleted the feature/dynamic-messaging branch April 12, 2024 18:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants