Skip to content
This repository has been archived by the owner on Dec 3, 2020. It is now read-only.

#302: Remove links to deleted SUMO page. #304

Merged
merged 1 commit into from
Jan 28, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/METRICS.md
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,7 @@ Some `extra_keys` are sent with every telemetry event recorded by the extension:
- `'best_buy_link'`: Sends the user to Best Buy.
- `'ebay_link'`: Sends the user to eBay.
- `'feedback_button'`: Sends the user to a feedback Survey.
- `'help_button'`: Sends the user to a Price Wise support.mozilla.org page.
- `'home_depot_link'`: Sends the user to Home Depot.
- `'learn_more_link'`: Sends the user to a Price Wise support.mozilla.org page.
- `'walmart_link'`: Sends the user to Walmart.
- `'extraction_id'`: A unique identifier to associate an extraction attempt to an extraction completion event for a given page.
- `'is_bg_update'`: 'true' if the extraction is associated with a background price check; otherwise 'false'.
Expand Down
9 changes: 6 additions & 3 deletions src/browser_action/components/BrowserActionApp.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,19 @@
/** Top-level components for the toolbar panel */

.title-bar {
align-items: center;
border-bottom: 1px solid var(--grey-30);
display: flex;
height: 42px;
justify-content: space-between;
margin: 0;
overflow: hidden;
padding: 0 8px;
}

.title-bar .feedback {
position: absolute;
top: 5px;
left: 5px;
}

.title-bar .title {
font-size: 13px;
font-weight: bold;
Expand Down
17 changes: 0 additions & 17 deletions src/browser_action/components/BrowserActionApp.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,15 +70,6 @@ export default class BrowserActionApp extends React.Component {
await recordEvent('open_popup', 'toolbar_button', null, {badge_type: await getBadgeType()});
}

/**
* Open the support page and close the panel when the help icon is clicked.
*/
async handleClickHelp() {
browser.tabs.create({url: await config.get('supportUrl')});
await recordEvent('open_nonproduct_page', 'ui_element', null, {element: 'help_button'});
window.close();
}

/**
* Open the feedback page and close the panel when the help icon is clicked.
*/
Expand Down Expand Up @@ -138,14 +129,6 @@ export default class BrowserActionApp extends React.Component {
/>
</button>
<h1 className="title">Products</h1>
<button
className="ghost help button"
type="button"
onClick={this.handleClickHelp}
title="Help"
>
<img className="icon" src={browser.extension.getURL('img/help.svg')} alt="Help" />
</button>
</div>
{products.length < 1
? (
Expand Down
20 changes: 0 additions & 20 deletions src/browser_action/components/EmptyOnboarding.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import autobind from 'autobind-decorator';
import React from 'react';

import TrackProductButton from 'commerce/browser_action/components/TrackProductButton';
import config from 'commerce/config';
import {extractedProductShape} from 'commerce/state/products';
import {recordEvent} from 'commerce/telemetry/extension';

Expand All @@ -26,23 +25,6 @@ export default class EmptyOnboarding extends React.Component {
extractedProduct: null,
}

constructor(props) {
super(props);
this.state = {
learnMoreHref: null,
};
}

/**
* Fetch the link to the support page on mount, since we can't fetch it async
* during the render.
*/
async componentDidMount() {
this.setState({
learnMoreHref: await config.get('supportUrl'),
});
}

/**
* Open a new tab and close the popup when links are clicked.
*/
Expand All @@ -57,7 +39,6 @@ export default class EmptyOnboarding extends React.Component {

render() {
const {extractedProduct} = this.props;
const {learnMoreHref} = this.state;
return (
<div className="empty-onboarding" onClick={this.handleClick}>
<img className="hero" src={browser.extension.getURL('img/shopping-welcome.svg')} alt="" />
Expand All @@ -83,7 +64,6 @@ export default class EmptyOnboarding extends React.Component {
Price Wise keeps track of your saved products by occasionally loading their webpages in
the background while Firefox is open.
</p>
<a data-telemetry-id="learn_more" href={learnMoreHref} className="learn-more">Learn More</a>
<TrackProductButton className="button" extractedProduct={extractedProduct} />
</div>
);
Expand Down
3 changes: 0 additions & 3 deletions src/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,6 @@ const CONFIG = {
/** Color of the toolbar badge when a product on the current page is trackable. */
badgeDetectBackground: new StringValue('#33F70C'),

/** URL for the add-on's page on support.mozilla.org */
supportUrl: new StringValue('https://support.mozilla.org/kb/new-test-pilot-experiments'),

/** URL for the add-on's feedback form */
feedbackUrl: new StringValue('https://qsurvey.mozilla.com/s3/price-wise'),

Expand Down