• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Yoast / wordpress-seo / facc8f018e2384ec4943ce98eecb050104439f58

27 Aug 2025 02:15PM UTC coverage: 53.206% (-0.07%) from 53.276%
facc8f018e2384ec4943ce98eecb050104439f58

push

github

web-flow
Merge pull request #22535 from Yoast/feature/bf-2025-c

Feature/bf 2025 c

8344 of 15215 branches covered (54.84%)

Branch coverage included in aggregate %.

34 of 172 new or added lines in 36 files covered. (19.77%)

9 existing lines in 6 files now uncovered.

31641 of 59937 relevant lines covered (52.79%)

39836.33 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/packages/js/src/components/contentAnalysis/MultipleKeywordsUpsell.js
1
/* global wpseoAdminL10n */
2
import { __ } from "@wordpress/i18n";
3
import { addQueryArgs } from "@wordpress/url";
4
import { useToggleState } from "@yoast/ui-library";
5
import { MultiKeyphraseUpsellModal } from "../modals/MultiKeyphraseUpsellModal";
6

7
/**
8
 *
9
 * @param {string} location The location where the upsell is used. Either "sidebar" or "metabox".
10
 * @param {string} locationContext The context of the location where the upsell is used
11
 *
12
 * @returns {JSX.Element} The Multiple Keywords upsell component.
13
 */
NEW
14
export const MultipleKeywordsUpsell = ( { location, locationContext } ) => {
×
NEW
15
        const [ isOpen, , , openModal, closeModal ] = useToggleState( false );
×
NEW
16
        const buyLink = location.toLowerCase() === "sidebar"
×
17
                ? "shortlinks.upsell.sidebar.focus_keyword_additional_button"
18
                : "shortlinks.upsell.metabox.focus_keyword_additional_button";
19

NEW
20
        const upsellLink = addQueryArgs( wpseoAdminL10n[ buyLink ], { context: locationContext } );
×
NEW
21
        return <>
×
22
                <button
23
                        type="button"
24
                        onClick={ openModal }
25
                        className="button-link yst-block"
26
                        id={ `yoast-keyword-related-keyphrase-button-${location}` }
27
                >
28
                        { `+ ${ __( "Add related keyphrase", "wordpress-seo" ) }` }
29
                </button>
30
                <MultiKeyphraseUpsellModal
31
                        isOpen={ isOpen }
32
                        closeModal={ closeModal }
33
                        id={ `yoast-related-keyphrase-upsell-modal-${location}` }
34
                        upsellLink={ upsellLink }
35
                />
36
        </>;
37
};
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc