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

GH-1774/In-App Insights Promo #460

Merged
merged 40 commits into from Oct 24, 2019
Merged
Changes from 1 commit
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
0f49440
Created modal UI
benstrumeyer Sep 26, 2019
5f92023
Change feature language. Add exit button.
benstrumeyer Sep 27, 2019
b229c9d
Add insights modal that will appear if a user clicks 3x per day for 3…
benstrumeyer Oct 8, 2019
3d24d70
Refactor insights modal into a component. Reshow modal after prompted…
benstrumeyer Oct 8, 2019
d57c5b3
Clean up insights modal code
benstrumeyer Oct 9, 2019
2f7fcbc
Show plus promo modal on first view of Home view of each Hub session
wlycdgr Sep 16, 2019
e94a749
Stub out intro hub plus promo modal layout and implement its buttons
wlycdgr Sep 16, 2019
894d742
Remove some unnecessary plus promo modal related CSS
wlycdgr Sep 17, 2019
ab4c58a
Continue adding styling for plus promo modal
wlycdgr Sep 17, 2019
3cd79ce
Continue styling plus promo modal
wlycdgr Sep 18, 2019
b476ce1
Refactor plus promo modal CSS to improve alignment of elements
wlycdgr Sep 20, 2019
4666877
Continue CSS work for plus promo modal
wlycdgr Sep 20, 2019
ff4d455
Implement recommended gold banner in plus promo modal
wlycdgr Sep 23, 2019
446d137
Update and tweak plus promo modal design
wlycdgr Sep 27, 2019
5afd2ce
Fix path bug in i18n-checker tool. Consolidate redundant entries in m…
wlycdgr Oct 1, 2019
475143c
Additional consolidation of redundant and unused entries in messages
wlycdgr Oct 2, 2019
2f912b7
Factor plus promo modal rendering out to shared component. Implement …
wlycdgr Oct 6, 2019
6e7be93
Move Plus Promo modal rendering to a PlusPromoModal shared component.…
wlycdgr Oct 7, 2019
41a08b1
Create ModalPromos background class responsible for modal promo relat…
wlycdgr Oct 7, 2019
75fa2da
Add local state to Panel to make sure component rerenders after user …
wlycdgr Oct 8, 2019
4329146
Make PromoModals code more robust
wlycdgr Oct 8, 2019
66c1490
Factor PlusPromoModal rendering out to helper in Panel. Extend condit…
wlycdgr Oct 8, 2019
bb5d74d
Mark PromoModals methods as static. Refine PlusPromoModal implementat…
wlycdgr Oct 8, 2019
dd808b5
Add logic to hide plus promo modal from Insights subscribers. Cleanup…
wlycdgr Oct 9, 2019
a143c18
Clean up. Finish string localization in PlusPromoModal
wlycdgr Oct 9, 2019
3795b25
Plug in insights modal into promo modal class
benstrumeyer Oct 16, 2019
cd467c8
GH-1777 and GH-1776 Plus Promo modals (#458)
wlycdgr Oct 16, 2019
178ebf0
Consolidate insights promo with plus promo
benstrumeyer Oct 18, 2019
4b7b84a
GH-1814/promo toggle (#453)
benstrumeyer Oct 18, 2019
7fb7744
User can opt out of promotions
benstrumeyer Oct 18, 2019
3697774
Remove empty SCSS class
benstrumeyer Oct 18, 2019
2abb7cd
Add newlines
benstrumeyer Oct 18, 2019
be57477
Merge 8.4.5
benstrumeyer Oct 18, 2019
b0aa51b
Add hover effects
benstrumeyer Oct 21, 2019
8231933
Refactor insights promo to use redux. Remove summary component code. …
benstrumeyer Oct 23, 2019
3478857
Refactor hasEngagedFrequently to update in recordEngaged
benstrumeyer Oct 23, 2019
b490d7c
Refactor recordEngaged
benstrumeyer Oct 24, 2019
0edc57c
Fix recordEngaged bug
benstrumeyer Oct 24, 2019
14936c6
Fix font paths
wlycdgr Oct 24, 2019
1d905aa
Remove unused font asset
wlycdgr Oct 24, 2019
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

Additional consolidation of redundant and unused entries in messages

  • Loading branch information
wlycdgr authored and benstrumeyer committed Oct 18, 2019
commit 475143c516951186b6f05012acab2979e9c420c7
@@ -22,16 +22,9 @@
}
}
},
"all": {
"description": "Default setting in the 'filter by type' dropdown for the tag browser. Doesn't filter anything out. Should read as 'Show all'.",
"message": "all"
},
"banner_check_your_email_title": {
"message": "Please check your email shortly for a link to reset your password."
},
"banner_no_such_account_message": {
"message": "Looks like we can't find this email and password combo. Give it another shot."
},
"banner_email_not_in_system_message": {
"message": "Sorry, that email isn't in our system."
},
@@ -41,10 +34,6 @@
"blacklist_error_whitelist_url": {
"message": "This site has been removed from your Trusted Sites list and added to your Restricted Sites list"
},
"blocked": {
"description": "Select this to show only blocked (checked) tags in the tag browser. Should read as 'Show blocked'.",
"message": "blocked"
},
"blocked_redirect_action_always_title": {
"description": "Title for the 'Allow always and reload' button on the blocked redirect page.",
"message": "Always allow and reload."
@@ -375,25 +364,6 @@
}
}
},
"copyright": {
"description": "Copyright message, shown in page footers.",
"message": "$C$ $YEAR$ $GHOSTERY$, a part of $COMPANY_ADDRESS$",
"placeholders": {
"c": {
"content": "©"
},
"company_address": {
"content": "$1",
"example": "GHOSTERY, Inc., Such-and-such Street, Such-and-such Floor, New York, NY, Zip Code"
},
"ghostery": {
"content": "<a href='https://www.ghostery.com' target='_blank'>Ghostery</a>"
},
"year": {
"content": "2015"
}
}
},
"error_email_forgot": {
"message": "Hmm, I can’t find that email. Maybe try another?"
},
@@ -415,15 +385,6 @@
"password_field_label_required": {
"message": "Password required."
},
"name": {
"description": "The title of this extension (Ghostery).",
"message": "$EXTENSION_NAME$ – Privacy Ad Blocker",
"placeholders": {
"extension_name": {
"content": "Ghostery"
}
}
},
"none": {
"description": "Used to say that this item does not belong to any of the groups, as in \"Groups: None\" (as opposed to \"Groups: Group A, Group B, Group C\").",
"message": "None"
@@ -1099,51 +1060,6 @@
"blocking_category_tracker_found": {
"message": "Found"
},
"drawer_title_enable_anti_tracking": {
"message": "Enhanced Anti-Tracking"
},
"drawer_tooltip_enable_anti_tracking": {
"message": "Anonymize unblocked and unknown trackers for greater browsing protection"
},
"drawer_label_enable_anti_tracking": {
"message": "Trackers Anonymized"
},
"drawer_desc_enable_anti_tracking": {
"message": "Private data points have been removed."
},
"drawer_status_enable_anti_tracking": {
"message": "Anti-Tracking is"
},
"drawer_title_enable_ad_block": {
"message": "Enhanced Ad Blocking"
},
"drawer_tooltip_enable_ad_block": {
"message": "Block advertisements on websites you visit"
},
"drawer_label_enable_ad_block": {
"message": "Ads Blocked"
},
"drawer_desc_enable_ad_block": {
"message": "Ad spots have been blocked."
},
"drawer_status_enable_ad_block": {
"message": "Ad Blocking is"
},
"drawer_title_enable_smart_block": {
"message": "Smart Blocking"
},
"drawer_tooltip_enable_smart_block": {
"message": "Automatically block and unblock trackers to optimize page performance"
},
"drawer_label_enable_smart_block": {
"message": "Trackers Adjusted"
},
"drawer_desc_enable_smart_block": {
"message": "Trackers have been temporarily blocked or unblocked."
},
"drawer_status_enable_smart_block": {
"message": "Smart Blocking is"
},
"blocking_unblock_all": {
"message": "Unblock All"
},
@@ -1213,34 +1129,16 @@
"alert_site_restricted_off": {
"message": "Site no longer blacklisted."
},
"tooltip_anti_track": {
"message": "Enhanced Anti-Tracking"
},
"tooltip_anti_track_body": {
"message": "Anonymize personal data for greater protection."
},
"tooltip_anti_track_body_on": {
"tooltip_anti_track_on": {
"message": "Personal data points anonymized."
},
"tooltip_body_in_cliqz": {
"message": "Feature already active in Cliqz by default."
},
"tooltip_ad_block": {
"message": "Enhanced Ad Blocking"
},
"tooltip_ad_block_body": {
"message": "Block advertisements."
},
"tooltip_ad_block_body_on": {
"tooltip_ad_block_on": {
"message": "Advertisements have been blocked."
},
"tooltip_smart_block": {
"message": "Smart Blocking"
},
"tooltip_smart_block_body": {
"message": "Automatically block and unblock trackers to optimize page performance."
},
"tooltip_smart_block_body_on": {
"tooltip_smart_block_on": {
"message": "Tracker blocking adjusted to optimize page performance."
},
"tooltip_trust": {
@@ -1442,24 +1340,9 @@
"hub_setup_blocking_description_custom": {
"message": "Choose which trackers to block"
},
"hub_setup_antisuite_name_antitracking": {
"message": "Enhanced Anti-Tracking"
},
"hub_setup_antisuite_description_antitracking": {
"message": "Anonymize unblocked and unknown trackers for greater browsing protection."
},
"hub_setup_adblock_name_adblocking": {
"message": "Enhanced Ad Blocking"
},
"hub_setup_adblock_description_adblocking": {
"message": "Block advertisements on websites you visit."
},
"hub_setup_smartblocking_name_smartblocking": {
"message": "Smart Blocking"
},
"hub_setup_smartblocking_description_smartblocking": {
"message": "Automatically block and unblock trackers to optimize page performance."
},
"hub_setup_feature_already_active": {
"message": "This feature is already active in Cliqz by default. $LINK_LM_START$Learn More$LINK_LM_END$",
"placeholders": {
@@ -1590,24 +1473,9 @@
"hub_tutorial_antisuite_title": {
"message": "Get extra protection and automated control with our enhanced privacy features:"
},
"hub_tutorial_antisuite_antitracking_title": {
"message": "Enhanced Anti-Tracking"
},
"hub_tutorial_antisuite_antitracking_description": {
"message": "Remove data points that websites can use to identify you."
},
"hub_tutorial_antisuite_adblocking_title": {
"message": "Enhanced Ad Blocking"
},
"hub_tutorial_antisuite_adblocking_description": {
"message": "Block advertisements on the pages you visit."
},
"hub_tutorial_antisuite_smartblocking_title": {
"message": "Smart Blocking"
},
"hub_tutorial_antisuite_smartblocking_description": {
"message": "Automatically block and unblock trackers to optimize page performance."
},
"hub_products_page_title" : {
"message": "Ghostery Hub - Try Other Ghostery Products"
},
@@ -1745,9 +1613,6 @@
"hub_login_toast_success": {
"message": "Sign in successful! Your account settings have been imported."
},
"hub_login_toast_error": {
"message": "Looks like we can't find this email and password combo. Give it another shot."
},
"hub_create_account_header_title": {
"message": "Would you like to create a Ghostery account to sync settings across browsers and devices?"
},
@@ -2236,5 +2101,23 @@
},
"off": {
"message": "Off"
},
"enhanced_ad_blocking": {
"message": "Enhanced Ad Blocking"
},
"smart_blocking": {
"message": "Smart Blocking"
},
"smart_blocking_DESC": {
"message": "Automatically block and unblock trackers to optimize page performance."
},
"ad_blocking_DESC": {
"message": "Block advertisements on the pages you visit."
},
"anti_tracking_DESC": {
"message": "Anonymize personal data for greater protection."
},
"no_such_email_password_combo": {
"message": "Looks like we can't find this email and password combo. Give it another shot."
}
}
@@ -109,7 +109,7 @@ class LogInViewContainer extends Component {
this.props.history.push('/');
} else {
this.props.actions.setToast({
toastMessage: t('hub_login_toast_error'),
toastMessage: t('no_such_email_password_combo'),
toastClass: 'alert'
});
}
@@ -103,7 +103,7 @@ class SetupAntiSuiteViewContainer extends Component {
const features = [
{
id: 'anti-tracking',
name: t('hub_setup_antisuite_name_antitracking'),
name: t('enhanced_anti_tracking'),
enabled: anti_tracking_enabled,
locked: IS_CLIQZ,
toggle: IS_CLIQZ ?
@@ -113,20 +113,20 @@ class SetupAntiSuiteViewContainer extends Component {
},
{
id: 'ad-block',
name: t('hub_setup_adblock_name_adblocking'),
name: t('enhanced_ad_blocking'),
enabled: ad_block_enabled,
locked: IS_CLIQZ,
toggle: IS_CLIQZ ?
() => {} :
() => this._handleToggle('ad-block'),
description: IS_CLIQZ ? t('hub_setup_feature_already_active') : t('hub_setup_adblock_description_adblocking'),
description: IS_CLIQZ ? t('hub_setup_feature_already_active') : t('ad_blocking_DESC'),
},
{
id: 'smart-blocking',
name: t('hub_setup_smartblocking_name_smartblocking'),
name: t('smart_blocking'),
enabled: enable_smart_block,
toggle: () => this._handleToggle('smart-blocking'),
description: t('hub_setup_smartblocking_description_smartblocking'),
description: t('smart_blocking_DESC'),
}
];

@@ -48,7 +48,7 @@ const TutorialAntiSuiteView = () => (
<div className="TutorialView__keyImage anti-track" />
<div>
<div className="TutorialView__keyTitle">
{t('hub_tutorial_antisuite_antitracking_title')}
{t('enhanced_anti_tracking')}
</div>
<div className="TutorialView__keyText">
{t('hub_tutorial_antisuite_antitracking_description')}
@@ -59,21 +59,21 @@ const TutorialAntiSuiteView = () => (
<div className="TutorialView__keyImage ad-block" />
<div>
<div className="TutorialView__keyTitle">
{t('hub_tutorial_antisuite_adblocking_title')}
{t('enhanced_ad_blocking')}
</div>
<div className="TutorialView__keyText">
{t('hub_tutorial_antisuite_adblocking_description')}
{t('ad_blocking_DESC')}
</div>
</div>
</div>
<div className="TutorialView__keyItem flex-container align-middle">
<div className="TutorialView__keyImage smart-block" />
<div>
<div className="TutorialView__keyTitle">
{t('hub_tutorial_antisuite_smartblocking_title')}
{t('smart_blocking')}
</div>
<div className="TutorialView__keyText">
{t('hub_tutorial_antisuite_smartblocking_description')}
{t('smart_blocking_DESC')}
</div>
</div>
</div>
@@ -57,13 +57,44 @@ class CliqzFeature extends React.Component {
_getTooltipBodyText(active, isTooltipBody, type) {
if (!isTooltipBody) return false;

return active ?
t(`tooltip_${type}_body_on`) :
t(`tooltip_${type}_body`);
if (active) {
switch (type) {
case 'ad_block':
return t('tooltip_ad_block_on');
case 'anti_track':
return t('tooltip_anti_track_on');
case 'smart_block':
return t('tooltip_smart_block_on');
default:
return false;
}
} else {
switch (type) {
case 'ad_block':
return t('ad_blocking_DESC');
case 'anti_track':
return t('anti_tracking_DESC');
case 'smart_block':
return t('smart_blocking_DESC');
default:
return false;
}
}
}

_getTooltipHeaderText(isTooltipHeader, type) {
return isTooltipHeader ? t(`tooltip_${type}`) : false;
if (!isTooltipHeader) return false;

switch (type) {
case 'ad_block':
return t('enhanced_ad_blocking');
case 'anti_track':
return t('enhanced_anti_tracking');
case 'smart_block':
return t('smart_blocking');
default:
return false;
}
}

_getAlertText(active, type) {
@@ -103,7 +134,14 @@ class CliqzFeature extends React.Component {
const iconClassNames = ClassNames('CliqzFeature__icon', cssTypeName, 'g-tooltip');

const featureType = type === 'anti_track' ? 'anti_tracking' : type;
const featureName = t(`drawer_title_enable_${featureType}`);
let featureName;
if (featureType === 'anti_tracking') {
featureName = t('enhanced_anti_tracking');
} else if (featureType === 'ad_block') {
featureName = t('enhanced_ad_blocking');
} else if (featureType === 'smart_block') {
featureName = t('smart_blocking');
}

return (
<div className={cliqzFeatureClassNames} onClick={this.clickCliqzFeature}>
@@ -108,7 +108,7 @@ export default (state = initialState, action) => {
switch (err.code) {
case '10050':
case '10110':
errorText = t('banner_no_such_account_message');
errorText = t('no_such_email_password_combo');
break;
default:
errorText = t('server_error_message');
ProTip! Use n and p to navigate between commits in a pull request.