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

Nada/p2 ps 234/buy sell ads message #8273

Merged

Conversation

nada-deriv
Copy link
Contributor

Changes:

Please include a summary of the change and which issue is fixed below:

  • ... content change in my-ads page for empty ads.

When you need to add unit test

  • If this change disrupt current flow
  • If this change is adding new flow

When you need to add integration test

  • If components from external libraries are being used to define the flow, e.g. @deriv/components
  • If it relies on a very specific set of props with no default behavior for the current component.

Test coverage checklist (for reviewer)

  • Ensure utility / function has a test case
  • Ensure all the tests are passing

Type of change

  • Bug fix
  • New feature
  • Update feature
  • Refactor code
  • Translation to code
  • Translation to crowdin
  • Script configuration
  • Improve performance
  • Style only
  • Dependency update
  • Documentation update
  • Release

@boring-cyborg boring-cyborg bot added the P2P label Apr 17, 2023
@vercel
Copy link

vercel bot commented Apr 17, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
deriv-app ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 11, 2023 9:53am

@github-actions
Copy link
Contributor

github-actions bot commented Apr 17, 2023

A production App ID was automatically generated for this PR. (log)

Click here to copy & paste above information.
- **PR**: [https://github.com/binary-com/deriv-app/pull/8273](https://github.com/binary-com/deriv-app/pull/8273)
- **URLs**:
    - **w/ App ID + Server**: https://deriv-app-git-fork-nada-deriv-nada-p2ps-234buy-sell-ads-message.binary.sx?qa_server=red.binaryws.com&app_id=32206
    - **Original**: https://deriv-app-git-fork-nada-deriv-nada-p2ps-234buy-sell-ads-message.binary.sx
- **App ID**: `32206`

@github-actions
Copy link
Contributor

github-actions bot commented Apr 17, 2023

🚨 Lighthouse report for the changes in this PR:

Category Score
🔺 Performance 18
🟧 Accessibility 75
🟢 Best practices 92
🟧 SEO 85
🟢 PWA 90

Lighthouse ran with https://deriv-app-git-fork-nada-deriv-nada-p2ps-234buy-sell-ads-message.binary.sx/

@codecov-commenter
Copy link

codecov-commenter commented Apr 17, 2023

Codecov Report

Merging #8273 (9267743) into master (d5c38a0) will increase coverage by 20.67%.
Report is 192 commits behind head on master.
The diff coverage is 0.00%.

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

@@             Coverage Diff             @@
##           master    #8273       +/-   ##
===========================================
+ Coverage    0.05%   20.73%   +20.67%     
===========================================
  Files         117     1538     +1421     
  Lines        3425    35927    +32502     
  Branches      893     7029     +6136     
===========================================
+ Hits            2     7449     +7447     
- Misses       3423    27732    +24309     
- Partials        0      746      +746     
Files Changed Coverage Δ
...ages/p2p/src/components/buy-sell/no-ads/no-ads.jsx 0.00% <0.00%> (ø)
...ackages/p2p/src/components/my-ads/my-ads-table.jsx 0.00% <0.00%> (ø)

... and 1575 files with indirect coverage changes

@@ -26,7 +33,9 @@ const NoAds = () => {
size='s'
weight='bold'
>
<Localize i18n_default_text='No ads for this currency 😞' />
<Localize
i18n_default_text={is_ads_page ? 'You have no ads.' : 'No ads for this currency 😞'}
Copy link
Contributor

Choose a reason for hiding this comment

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

So just FYI you can't use ternaries wihin the localize as this will cause issues with translations, so make sure to separate it 👍

Suggested change
i18n_default_text={is_ads_page ? 'You have no ads.' : 'No ads for this currency 😞'}
{ is_ads_page ?
<Localize i18n_default_text='You have no ads.' />
: <Localize i18n_default_text='No ads for this currency 😞' />
}

>
<Localize i18n_default_text='Create ad' />
<Localize i18n_default_text={is_ads_page ? 'Create new ad' : 'Create ad'} />
Copy link
Contributor

Choose a reason for hiding this comment

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

same here ☝️

</Button>
</Empty>
);
return <NoAds is_ads_page={true} />;
Copy link
Contributor

Choose a reason for hiding this comment

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

Could you try this? Cause this usually works as well, if not, can ignore my comment

Suggested change
return <NoAds is_ads_page={true} />;
return <NoAds is_ads_page/>;

@sonarcloud
Copy link

sonarcloud bot commented Apr 17, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

Copy link
Contributor

@ameerul-deriv ameerul-deriv left a comment

Choose a reason for hiding this comment

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

LGTM

farrah-deriv
farrah-deriv previously approved these changes Apr 17, 2023
@github-actions
Copy link
Contributor

This PR is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@gitguardian
Copy link

gitguardian bot commented Jul 3, 2023

⚠️ GitGuardian has uncovered 2 secrets following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secrets in your pull request
GitGuardian id Secret Commit Filename
- Generic High Entropy Secret 837852c packages/account/src/Components/currency-selector/tests/currency-selector.spec.tsx View secret
- Generic High Entropy Secret 837852c packages/account/src/Components/currency-selector/tests/currency-selector.spec.tsx View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secrets safely. Learn here the best practices.
  3. Revoke and rotate these secrets.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

Our GitHub checks need improvements? Share your feedbacks!

@sonarcloud
Copy link

sonarcloud bot commented Jul 3, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
2.5% 2.5% Duplication

@github-actions
Copy link
Contributor

github-actions bot commented Aug 3, 2023

Generating Lighthouse report...

@coveralls
Copy link

coveralls commented Aug 3, 2023

Coverage Status

coverage: 9.857% (+0.2%) from 9.643% when pulling 80f6814 on nada-deriv:nada/P2PS-234/buy-sell-ads-message into 419bc1b on binary-com:master.

useStores: jest.fn(() => mock_store_values),
}));

jest.mock('@sendbird/chat', () => ({
Copy link
Contributor

Choose a reason for hiding this comment

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

Non-blocking: Can we update jest.config instead? So we dont need to refactor these test files in the future 🙏

farrah-deriv
farrah-deriv previously approved these changes Aug 8, 2023
@sonarcloud
Copy link

sonarcloud bot commented Aug 11, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@DerivFE DerivFE merged commit e9f5fc4 into binary-com:master Sep 18, 2023
4 of 5 checks passed
@DerivFE
Copy link
Collaborator

DerivFE commented Sep 18, 2023

✨ PR has been merged by Paimon the Release Bot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
7 participants