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

Add ability to toggle smart blocking on Cliqz browser #455

Merged
merged 2 commits into from Sep 25, 2019
Merged
Changes from 1 commit
Commits
File filter
Filter file types
Jump to
Jump to file
Failed to load files.

Always

Just for now

Prev

Refactor code to separate smart blocking inactive behavior

  • Loading branch information
benstrumeyer committed Sep 25, 2019
commit 7ae7a2d255e33a766766f6a4c738b0f5fe0d3c51
@@ -418,6 +418,13 @@ class Summary extends React.Component {
const { paused_blocking, sitePolicy } = this.props;
const { disableBlocking } = this.state;

return paused_blocking || sitePolicy || disableBlocking || IS_CLIQZ;
}

_isSmartBlockingInactive() {
const { paused_blocking, sitePolicy } = this.props;
const { disableBlocking } = this.state;

return paused_blocking || sitePolicy || disableBlocking;
}

@@ -672,7 +679,7 @@ class Summary extends React.Component {
clickButton={this.clickCliqzFeature}
type="smart_block"
active={enable_smart_block}
cliqzInactive={this._isCliqzInactive()}
cliqzInactive={this._isSmartBlockingInactive()}
isSmaller={is_expert && !isCondensed}
isCondensed={isCondensed}
isTooltipHeader={is_expert}
ProTip! Use n and p to navigate between commits in a pull request.