Google Analytics Opt-Out - Version 2.2.5

Version Description

  • Corrected text domain for JS translations
  • State that plugin works with gtag.js, too.
Download this release

Release Info

Developer wp-buddy
Plugin Icon 128x128 Google Analytics Opt-Out
Version 2.2.5
Comparing to
See all releases

Code changes from version 2.2.4 to 2.2.5

.gitignore ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /node_modules/*
2
+ package-lock.json
blocks/opt-out.js CHANGED
@@ -7,7 +7,7 @@ const {TextControl} = wp.components;
7
  export default registerBlockType(
8
  'gaoop/opt-out-block',
9
  {
10
- title: __( 'Analytics Opt Out', 'gaoop' ),
11
  category: 'widgets',
12
  icon: <svg width="18" height="20"
13
  xmlns="http://www.w3.org/2000/svg">
@@ -22,14 +22,14 @@ export default registerBlockType(
22
  </svg>,
23
  keywords: [
24
  'gaoop',
25
- __( 'Analytics Opt Out', 'gaoop' ),
26
  ],
27
  attributes: {
28
  content: {
29
  source: 'text',
30
  selector: 'a',
31
- default: __( 'Click here to opt out', 'gaoop' ),
32
- },
33
  },
34
 
35
  transforms: {
@@ -39,10 +39,10 @@ export default registerBlockType(
39
  blocks: ['core/paragraph'],
40
  transform: ( {content} ) => {
41
  return createBlock( 'core/paragraph', {
42
- content,
43
  } );
44
- },
45
- },
46
  ],
47
  from: [
48
  {
@@ -50,23 +50,23 @@ export default registerBlockType(
50
  blocks: ['core/paragraph'],
51
  transform: ( {content} ) => {
52
  return createBlock( 'gaoop/opt-out-block', {
53
- content,
54
  } );
55
- },
56
- },
57
- ],
58
  },
59
 
60
  edit: props => {
61
  const {isSelected, setAttributes} = props;
62
 
63
  const content = '' === props.attributes.content
64
- ? __( 'Click here to opt out', 'gaoop' )
65
  : props.attributes.content;
66
 
67
  return isSelected
68
  ? <TextControl
69
- label={__( 'Enter a link text', 'gaoop' )}
70
  value={content}
71
  onChange={( value ) => setAttributes( {content: value} )}
72
  />
@@ -76,13 +76,13 @@ export default registerBlockType(
76
  save: props => {
77
 
78
  const content = '' === props.attributes.content
79
- ? __( 'Click here to opt out', 'gaoop' )
80
  : props.attributes.content;
81
 
82
  return (
83
  <a className="gaoop-block"
84
  href="javascript:gaoop_analytics_optout();">{content}</a>
85
  );
86
- },
87
- },
88
  );
7
  export default registerBlockType(
8
  'gaoop/opt-out-block',
9
  {
10
+ title: __( 'Analytics Opt Out', 'google-analytics-opt-out' ),
11
  category: 'widgets',
12
  icon: <svg width="18" height="20"
13
  xmlns="http://www.w3.org/2000/svg">
22
  </svg>,
23
  keywords: [
24
  'gaoop',
25
+ __( 'Analytics Opt Out', 'google-analytics-opt-out' )
26
  ],
27
  attributes: {
28
  content: {
29
  source: 'text',
30
  selector: 'a',
31
+ default: __( 'Click here to opt out', 'google-analytics-opt-out' )
32
+ }
33
  },
34
 
35
  transforms: {
39
  blocks: ['core/paragraph'],
40
  transform: ( {content} ) => {
41
  return createBlock( 'core/paragraph', {
42
+ content
43
  } );
44
+ }
45
+ }
46
  ],
47
  from: [
48
  {
50
  blocks: ['core/paragraph'],
51
  transform: ( {content} ) => {
52
  return createBlock( 'gaoop/opt-out-block', {
53
+ content
54
  } );
55
+ }
56
+ }
57
+ ]
58
  },
59
 
60
  edit: props => {
61
  const {isSelected, setAttributes} = props;
62
 
63
  const content = '' === props.attributes.content
64
+ ? __( 'Click here to opt out', 'google-analytics-opt-out' )
65
  : props.attributes.content;
66
 
67
  return isSelected
68
  ? <TextControl
69
+ label={__( 'Enter a link text', 'google-analytics-opt-out' )}
70
  value={content}
71
  onChange={( value ) => setAttributes( {content: value} )}
72
  />
76
  save: props => {
77
 
78
  const content = '' === props.attributes.content
79
+ ? __( 'Click here to opt out', 'google-analytics-opt-out' )
80
  : props.attributes.content;
81
 
82
  return (
83
  <a className="gaoop-block"
84
  href="javascript:gaoop_analytics_optout();">{content}</a>
85
  );
86
+ }
87
+ }
88
  );
google-analytics-opt-out.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Google Analytics Opt-Out
4
  Plugin URI: https://wp-buddy.com/products/plugins/google-analytics-opt-out
5
  Description: Provides an Opt-Out functionality for Google Analytics
6
- Version: 2.2.4
7
  Author: WP-Buddy
8
  Author URI: https://wp-buddy.com
9
  License: GPL2
3
  Plugin Name: Google Analytics Opt-Out
4
  Plugin URI: https://wp-buddy.com/products/plugins/google-analytics-opt-out
5
  Description: Provides an Opt-Out functionality for Google Analytics
6
+ Version: 2.2.5
7
  Author: WP-Buddy
8
  Author URI: https://wp-buddy.com
9
  License: GPL2
inc/admin.php CHANGED
@@ -119,6 +119,10 @@ function gaoop_gutenberg_init() {
119
  return;
120
  }
121
 
 
 
 
 
122
  add_action( 'enqueue_block_editor_assets', 'gaoop_gutenberg_editor_assets' );
123
  }
124
 
@@ -126,7 +130,7 @@ function gaoop_gutenberg_editor_assets() {
126
 
127
  $block_file = plugin_dir_path( GAOOP_FILE ) . 'js/opt-out-block.js';
128
 
129
- wp_enqueue_script(
130
  'gaoop-block',
131
  plugin_dir_url( GAOOP_FILE ) . 'js/opt-out-block.js',
132
  array( 'wp-blocks', 'wp-i18n', 'wp-element' ),
@@ -137,16 +141,16 @@ function gaoop_gutenberg_editor_assets() {
137
  if ( function_exists( 'gutenberg_get_jed_locale_data' ) ) {
138
  wp_add_inline_script(
139
  'gaoop-block',
140
- 'wp.i18n.setLocaleData( ' . wp_json_encode( gutenberg_get_jed_locale_data( 'gaoop' ) ) . ', "gaoop" );',
141
  'before'
142
  );
143
  } elseif ( function_exists( 'wp_get_jed_locale_data' ) ) {
144
  wp_add_inline_script(
145
  'gaoop-block',
146
- 'wp.i18n.setLocaleData( ' . wp_json_encode( wp_get_jed_locale_data( 'gaoop' ) ) . ', "gaoop" );',
147
  'before'
148
  );
149
  } elseif ( function_exists( 'wp_set_script_translations' ) ) {
150
- wp_set_script_translations( 'gaoop-block', 'gaoop' );
151
  }
152
  }
119
  return;
120
  }
121
 
122
+ register_block_type( 'gaoop/opt-out-block', [
123
+ 'editor_script' => 'gaoop-block',
124
+ ] );
125
+
126
  add_action( 'enqueue_block_editor_assets', 'gaoop_gutenberg_editor_assets' );
127
  }
128
 
130
 
131
  $block_file = plugin_dir_path( GAOOP_FILE ) . 'js/opt-out-block.js';
132
 
133
+ wp_register_script(
134
  'gaoop-block',
135
  plugin_dir_url( GAOOP_FILE ) . 'js/opt-out-block.js',
136
  array( 'wp-blocks', 'wp-i18n', 'wp-element' ),
141
  if ( function_exists( 'gutenberg_get_jed_locale_data' ) ) {
142
  wp_add_inline_script(
143
  'gaoop-block',
144
+ 'wp.i18n.setLocaleData( ' . wp_json_encode( gutenberg_get_jed_locale_data( 'google-analytics-opt-out' ) ) . ', "google-analytics-opt-out" );',
145
  'before'
146
  );
147
  } elseif ( function_exists( 'wp_get_jed_locale_data' ) ) {
148
  wp_add_inline_script(
149
  'gaoop-block',
150
+ 'wp.i18n.setLocaleData( ' . wp_json_encode( wp_get_jed_locale_data( 'google-analytics-opt-out' ) ) . ', "google-analytics-opt-out" );',
151
  'before'
152
  );
153
  } elseif ( function_exists( 'wp_set_script_translations' ) ) {
154
+ wp_set_script_translations( 'gaoop-block', 'google-analytics-opt-out' );
155
  }
156
  }
inc/settings.php CHANGED
@@ -32,7 +32,7 @@ function gaoop_settings_page() {
32
 
33
  <p class="description"><?php
34
  printf(
35
- __( 'This plugin provides an Opt-Out functionality for Google Analytics. You can show a banner to your users and/or you can use the following shortcode in any of your posts: %s. It integrates a link that allows a user to opt-out off Google Analytics. You can read more about the <a href="https://wp-buddy.com/documentation/plugins/google-analytics-opt/faq/#what-are-the-shortcodes-that-i-can-use" target="_blank">shortcodes here</a>.', 'google-analytics-opt-out' ),
36
  '<code>[google_analytics_optout]Your link text[/google_analytics_optout]</code>'
37
  ); ?></p>
38
 
@@ -73,7 +73,7 @@ function gaoop_register_theme_options_section() {
73
  add_settings_field( 'gaoop_yoast', __( 'Use Monster Insights Settings', 'google-analytics-opt-out' ), 'gaoop_options_yoast', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_yoast' ) );
74
  register_setting( 'gaoop_options_page', 'gaoop_yoast', 'intval' );
75
 
76
- add_settings_field( 'gaoop_property', __( 'UA-Code', 'google-analytics-opt-out' ), 'gaoop_options_property', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_property' ) );
77
  register_setting( 'gaoop_options_page', 'gaoop_property', 'sanitize_text_field' );
78
 
79
  add_settings_field( 'gaoop_editor_button', __( 'Show Editor button (Classic Editor)', 'google-analytics-opt-out' ), 'gaoop_options_editor_button', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_editor_button' ) );
@@ -129,7 +129,7 @@ function gaoop_options_yoast() {
129
  if ( $monster_insights_active ) {
130
  echo '<span style="color: #5EB95E;">' . __( 'Monster Insights Plugin has been detected.', 'google-analytics-opt-out' ) . '</span>';
131
  } else {
132
- echo '<span style="color: #DD514C;">' . __( 'Monster Insights Plugin has NOT been detected. Please enter your UA code manually and then check the sourcode of your website. Make sure that Analytics code appears AFTER the opt-out code (which starts with <code>/* Google Analytics Opt-Out</code>).', 'google-analytics-opt-out' ) . '</span>';
133
  }
134
  echo '</p>';
135
  }
@@ -152,7 +152,7 @@ function gaoop_options_property() {
152
  $value = sanitize_text_field( get_option( 'gaoop_property', '' ) );
153
  }
154
 
155
- echo '<input id="gaoop_options_property" placeholder="UA-XXXXXX-X" type="text" class="regular-text" value="' . $value . '" name="gaoop_property" /> ';
156
 
157
  }
158
 
32
 
33
  <p class="description"><?php
34
  printf(
35
+ __( 'This plugin provides an Opt-Out functionality for Google Analytics (Universal Tracking aka analytics.js and Global Site Tag aka gtag.js). You can show a banner to your users and/or you can use the following shortcode in any of your posts: %s. It integrates a link that allows a user to opt-out off Google Analytics. You can read more about the <a href="https://wp-buddy.com/documentation/plugins/google-analytics-opt/faq/#what-are-the-shortcodes-that-i-can-use" target="_blank">shortcodes here</a>.', 'google-analytics-opt-out' ),
36
  '<code>[google_analytics_optout]Your link text[/google_analytics_optout]</code>'
37
  ); ?></p>
38
 
73
  add_settings_field( 'gaoop_yoast', __( 'Use Monster Insights Settings', 'google-analytics-opt-out' ), 'gaoop_options_yoast', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_yoast' ) );
74
  register_setting( 'gaoop_options_page', 'gaoop_yoast', 'intval' );
75
 
76
+ add_settings_field( 'gaoop_property', __( 'UA- or GA-Code', 'google-analytics-opt-out' ), 'gaoop_options_property', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_property' ) );
77
  register_setting( 'gaoop_options_page', 'gaoop_property', 'sanitize_text_field' );
78
 
79
  add_settings_field( 'gaoop_editor_button', __( 'Show Editor button (Classic Editor)', 'google-analytics-opt-out' ), 'gaoop_options_editor_button', 'gaoop_options_page', 'gaoop_settings_section', array( 'label_for' => 'gaoop_options_editor_button' ) );
129
  if ( $monster_insights_active ) {
130
  echo '<span style="color: #5EB95E;">' . __( 'Monster Insights Plugin has been detected.', 'google-analytics-opt-out' ) . '</span>';
131
  } else {
132
+ echo '<span style="color: #DD514C;">' . __( 'Monster Insights Plugin has NOT been detected. Please enter your UA- or GA-code manually and then check the sourcode of your website. Make sure that Analytics code appears AFTER the opt-out code (which starts with <code>/* Google Analytics Opt-Out</code>).', 'google-analytics-opt-out' ) . '</span>';
133
  }
134
  echo '</p>';
135
  }
152
  $value = sanitize_text_field( get_option( 'gaoop_property', '' ) );
153
  }
154
 
155
+ echo '<input id="gaoop_options_property" placeholder="UA-XXXXXX-X | GA-XXXXXX-X" type="text" class="regular-text" value="' . $value . '" name="gaoop_property" /> ';
156
 
157
  }
158
 
js/opt-out-block.js CHANGED
@@ -68,7 +68,7 @@
68
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
69
 
70
  "use strict";
71
- eval("Object.defineProperty(__webpack_exports__, \"__esModule\", { value: true });\nvar __ = wp.i18n.__;\nvar _wp$blocks = wp.blocks,\n registerBlockType = _wp$blocks.registerBlockType,\n createBlock = _wp$blocks.createBlock;\nvar TextControl = wp.components.TextControl;\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = (registerBlockType('gaoop/opt-out-block', {\n title: __('Analytics Opt Out', 'gaoop'),\n category: 'widgets',\n icon: wp.element.createElement(\n 'svg',\n { width: '18', height: '20',\n xmlns: 'http://www.w3.org/2000/svg' },\n wp.element.createElement('path', {\n d: 'M15.61 16.086c.093.094.14.2.14.316 0 .118-.047.211-.14.282a2.763 2.763 0 0 1-2.075.878c-.82 0-1.512-.292-2.074-.878L7.383 12.64l-.88.879c.165.398.247.808.247 1.23 0 .938-.328 1.734-.984 2.39-.657.657-1.454.985-2.391.985-.938 0-1.734-.328-2.39-.984C.327 16.484 0 15.688 0 14.75c0-.937.328-1.734.984-2.39.657-.657 1.453-.985 2.391-.985.164 0 .316.012.457.035l1.16-1.16-1.16-1.16c-.14.023-.293.035-.457.035-.938 0-1.734-.328-2.39-.984C.327 7.484 0 6.688 0 5.75c0-.937.328-1.734.984-2.39.657-.657 1.453-.985 2.391-.985.937 0 1.734.328 2.39.984.657.657.985 1.454.985 2.391 0 .422-.082.832-.246 1.23l.879.88 4.078-4.044a2.763 2.763 0 0 1 2.074-.878c.82 0 1.512.293 2.074.878.094.07.141.164.141.282a.437.437 0 0 1-.14.316L9.772 10.25l5.836 5.836zM3.374 4.625c-.305 0-.568.111-.791.334a1.081 1.081 0 0 0-.334.791c0 .305.111.568.334.791.223.223.486.334.791.334.305 0 .568-.111.791-.334.223-.223.334-.486.334-.791 0-.305-.111-.568-.334-.791a1.081 1.081 0 0 0-.791-.334zm0 9c-.305 0-.568.111-.791.334a1.081 1.081 0 0 0-.334.791c0 .305.111.568.334.791.223.223.486.334.791.334.305 0 .568-.111.791-.334.223-.223.334-.486.334-.791 0-.305-.111-.568-.334-.791a1.081 1.081 0 0 0-.791-.334zm3.937-3.797a.407.407 0 0 0-.298.123.407.407 0 0 0-.123.299c0 .117.04.217.123.299a.407.407 0 0 0 .298.123.407.407 0 0 0 .3-.123.407.407 0 0 0 .122-.299.407.407 0 0 0-.123-.299.407.407 0 0 0-.299-.123z',\n fill: '#000' }),\n wp.element.createElement('path', { fill: '#196EEE', d: 'M16 0H18V4H16z' }),\n wp.element.createElement('path', { fill: '#D9442F', d: 'M16 4H18V8H16z' }),\n wp.element.createElement('path', { fill: '#FFBB04', d: 'M16 8H18V12H16z' }),\n wp.element.createElement('path', { fill: '#176CED', d: 'M16 12H18V16H16z' }),\n wp.element.createElement('path', { fill: '#03A25D', d: 'M16 16H18V20H16z' })\n ),\n keywords: ['gaoop', __('Analytics Opt Out', 'gaoop')],\n attributes: {\n content: {\n source: 'text',\n selector: 'a',\n default: __('Click here to opt out', 'gaoop')\n }\n },\n\n transforms: {\n to: [{\n type: 'block',\n blocks: ['core/paragraph'],\n transform: function transform(_ref) {\n var content = _ref.content;\n\n return createBlock('core/paragraph', {\n content: content\n });\n }\n }],\n from: [{\n type: 'block',\n blocks: ['core/paragraph'],\n transform: function transform(_ref2) {\n var content = _ref2.content;\n\n return createBlock('gaoop/opt-out-block', {\n content: content\n });\n }\n }]\n },\n\n edit: function edit(props) {\n var isSelected = props.isSelected,\n setAttributes = props.setAttributes;\n\n\n var content = '' === props.attributes.content ? __('Click here to opt out', 'gaoop') : props.attributes.content;\n\n return isSelected ? wp.element.createElement(TextControl, {\n label: __('Enter a link text', 'gaoop'),\n value: content,\n onChange: function onChange(value) {\n return setAttributes({ content: value });\n }\n }) : wp.element.createElement(\n 'a',\n { className: 'gaoop-block', href: '#' },\n content\n );\n },\n save: function save(props) {\n\n var content = '' === props.attributes.content ? __('Click here to opt out', 'gaoop') : props.attributes.content;\n\n return wp.element.createElement(\n 'a',\n { className: 'gaoop-block',\n href: 'javascript:gaoop_analytics_optout();' },\n content\n );\n }\n}));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMC5qcyIsInNvdXJjZXMiOlsid2VicGFjazovLy8uL2Jsb2Nrcy9vcHQtb3V0LmpzP2M4YzciXSwic291cmNlc0NvbnRlb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XG4vLyBXRUJQQUNLIEZPT1RFUlxuLy8gLi9ibG9ja3Mvb3B0LW91dC5qc1xuLy8gbW9kdWxlIGlkID0gMFxuLy8gbW9kdWxlIGNodW5rcyA9IDAiXSwibWFwcGluZ3MiOiJBQUFBO0FBQUE7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0E7QUFDQTtBQUNBO0FBQ0EiLCJzb3VyY2VSb290IjoiIn0=\n//# sourceURL=webpack-internal:///0\n");
72
 
73
  /***/ })
74
  /******/ ]);
68
  /***/ (function(module, __webpack_exports__, __webpack_require__) {
69
 
70
  "use strict";
71
+ eval("Object.defineProperty(__webpack_exports__, \"__esModule\", { value: true });\nvar __ = wp.i18n.__;\nvar _wp$blocks = wp.blocks,\n registerBlockType = _wp$blocks.registerBlockType,\n createBlock = _wp$blocks.createBlock;\nvar TextControl = wp.components.TextControl;\n\n\n/* harmony default export */ __webpack_exports__[\"default\"] = (registerBlockType('gaoop/opt-out-block', {\n title: __('Analytics Opt Out', 'google-analytics-opt-out'),\n category: 'widgets',\n icon: wp.element.createElement(\n 'svg',\n { width: '18', height: '20',\n xmlns: 'http://www.w3.org/2000/svg' },\n wp.element.createElement('path', {\n d: 'M15.61 16.086c.093.094.14.2.14.316 0 .118-.047.211-.14.282a2.763 2.763 0 0 1-2.075.878c-.82 0-1.512-.292-2.074-.878L7.383 12.64l-.88.879c.165.398.247.808.247 1.23 0 .938-.328 1.734-.984 2.39-.657.657-1.454.985-2.391.985-.938 0-1.734-.328-2.39-.984C.327 16.484 0 15.688 0 14.75c0-.937.328-1.734.984-2.39.657-.657 1.453-.985 2.391-.985.164 0 .316.012.457.035l1.16-1.16-1.16-1.16c-.14.023-.293.035-.457.035-.938 0-1.734-.328-2.39-.984C.327 7.484 0 6.688 0 5.75c0-.937.328-1.734.984-2.39.657-.657 1.453-.985 2.391-.985.937 0 1.734.328 2.39.984.657.657.985 1.454.985 2.391 0 .422-.082.832-.246 1.23l.879.88 4.078-4.044a2.763 2.763 0 0 1 2.074-.878c.82 0 1.512.293 2.074.878.094.07.141.164.141.282a.437.437 0 0 1-.14.316L9.772 10.25l5.836 5.836zM3.374 4.625c-.305 0-.568.111-.791.334a1.081 1.081 0 0 0-.334.791c0 .305.111.568.334.791.223.223.486.334.791.334.305 0 .568-.111.791-.334.223-.223.334-.486.334-.791 0-.305-.111-.568-.334-.791a1.081 1.081 0 0 0-.791-.334zm0 9c-.305 0-.568.111-.791.334a1.081 1.081 0 0 0-.334.791c0 .305.111.568.334.791.223.223.486.334.791.334.305 0 .568-.111.791-.334.223-.223.334-.486.334-.791 0-.305-.111-.568-.334-.791a1.081 1.081 0 0 0-.791-.334zm3.937-3.797a.407.407 0 0 0-.298.123.407.407 0 0 0-.123.299c0 .117.04.217.123.299a.407.407 0 0 0 .298.123.407.407 0 0 0 .3-.123.407.407 0 0 0 .122-.299.407.407 0 0 0-.123-.299.407.407 0 0 0-.299-.123z',\n fill: '#000' }),\n wp.element.createElement('path', { fill: '#196EEE', d: 'M16 0H18V4H16z' }),\n wp.element.createElement('path', { fill: '#D9442F', d: 'M16 4H18V8H16z' }),\n wp.element.createElement('path', { fill: '#FFBB04', d: 'M16 8H18V12H16z' }),\n wp.element.createElement('path', { fill: '#176CED', d: 'M16 12H18V16H16z' }),\n wp.element.createElement('path', { fill: '#03A25D', d: 'M16 16H18V20H16z' })\n ),\n keywords: ['gaoop', __('Analytics Opt Out', 'google-analytics-opt-out')],\n attributes: {\n content: {\n source: 'text',\n selector: 'a',\n default: __('Click here to opt out', 'google-analytics-opt-out')\n }\n },\n\n transforms: {\n to: [{\n type: 'block',\n blocks: ['core/paragraph'],\n transform: function transform(_ref) {\n var content = _ref.content;\n\n return createBlock('core/paragraph', {\n content: content\n });\n }\n }],\n from: [{\n type: 'block',\n blocks: ['core/paragraph'],\n transform: function transform(_ref2) {\n var content = _ref2.content;\n\n return createBlock('gaoop/opt-out-block', {\n content: content\n });\n }\n }]\n },\n\n edit: function edit(props) {\n var isSelected = props.isSelected,\n setAttributes = props.setAttributes;\n\n\n var content = '' === props.attributes.content ? __('Click here to opt out', 'google-analytics-opt-out') : props.attributes.content;\n\n return isSelected ? wp.element.createElement(TextControl, {\n label: __('Enter a link text', 'google-analytics-opt-out'),\n value: content,\n onChange: function onChange(value) {\n return setAttributes({ content: value });\n }\n }) : wp.element.createElement(\n 'a',\n { className: 'gaoop-block', href: '#' },\n content\n );\n },\n save: function save(props) {\n\n var content = '' === props.attributes.content ? __('Click here to opt out', 'google-analytics-opt-out') : props.attributes.content;\n\n return wp.element.createElement(\n 'a',\n { className: 'gaoop-block',\n href: 'javascript:gaoop_analytics_optout();' },\n content\n );\n }\n}));//# sourceURL=[module]\n//# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMC5qcyIsInNvdXJjZXMiOlsid2VicGFjazovLy8uL2Jsb2Nrcy9vcHQtb3V0LmpzP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+2,36 @@
2
  msgid ""
3
  msgstr ""
4
  "Project-Id-Version: Google Analytics Opt-Out\n"
5
- "POT-Creation-Date: 2018-05-24 12:45+0200\n"
6
  "PO-Revision-Date: 2013-11-12 09:04+0100\n"
7
  "Last-Translator: WP-Buddy <info@wp-buddy.com>\n"
8
  "Language-Team: \n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "X-Generator: Poedit 2.0.7\n"
13
  "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
14
  "_n_noop:1,2;_c;_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;_ex:1,2c;"
15
  "esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
- "X-Poedit-Basepath: .\n"
18
- "X-Poedit-SearchPath-0: ..\n"
 
 
19
 
20
- #: ../google-analytics-opt-out.php:53
 
 
 
 
 
 
 
 
 
 
 
 
21
  #, php-format
22
  msgid ""
23
  "You are using PHP in version %s. This version is outdated and cannot be used "
@@ -26,116 +40,117 @@ msgid ""
26
  "this."
27
  msgstr ""
28
 
29
- #: ../inc/admin.php:12
30
  msgid ""
31
  "To use the Google Analytics Opt-Out Plugin please enter an UA-Code on the "
32
  "settings page."
33
  msgstr ""
34
 
35
- #: ../inc/admin.php:32
36
  msgid "Settings"
37
  msgstr ""
38
 
39
- #: ../inc/admin.php:33
40
  msgid "More by WP-Buddy"
41
  msgstr ""
42
 
43
- #: ../inc/frontend.php:20
44
  msgid "Google Analytics Opt-Out Information"
45
  msgstr ""
46
 
47
- #: ../inc/frontend.php:20
48
  msgid "Close"
49
  msgstr ""
50
 
51
- #: ../inc/frontend.php:22
52
  msgid "Close this and do not ask me again"
53
  msgstr ""
54
 
55
- #: ../inc/frontend.php:39
56
  msgid ""
57
  "This website is using Google Analytics. Please click here if you want to opt-"
58
  "out."
59
  msgstr ""
60
 
61
- #: ../inc/frontend.php:43
62
  msgid "Click here to opt-out."
63
  msgstr ""
64
 
65
- #: ../inc/functions.php:113 ../inc/settings.php:231
66
  msgid ""
67
  "Thanks. We have set a cookie so that Google Analytics data collection will "
68
  "be disabled on your next visit."
69
  msgstr ""
70
 
71
- #: ../inc/settings.php:11 ../inc/settings.php:14
72
  msgid "Analytics Opt-Out"
73
  msgstr ""
74
 
75
- #: ../inc/settings.php:14 ../inc/settings.php:71
76
  msgid "Opt-Out Settings"
77
  msgstr ""
78
 
79
- #: ../inc/settings.php:35
80
  #, php-format
81
  msgid ""
82
- "This plugin provides an Opt-Out functionality for Google Analytics. You can "
83
- "show a banner to your users and/or you can use the following shortcode in "
84
- "any of your posts: %s. It integrates a link that allows a user to opt-out "
 
85
  "off Google Analytics. You can read more about the <a href=\"https://wp-buddy."
86
  "com/documentation/plugins/google-analytics-opt/faq/#what-are-the-shortcodes-"
87
  "that-i-can-use\" target=\"_blank\">shortcodes here</a>."
88
  msgstr ""
89
 
90
- #: ../inc/settings.php:73
91
  msgid "Use Monster Insights Settings"
92
  msgstr ""
93
 
94
- #: ../inc/settings.php:76
95
- msgid "UA-Code"
96
  msgstr ""
97
 
98
- #: ../inc/settings.php:79
99
- msgid "Show Editor button"
100
  msgstr ""
101
 
102
- #: ../inc/settings.php:82
103
  msgid "Opt-Out Successful"
104
  msgstr ""
105
 
106
- #: ../inc/settings.php:85
107
  msgid "Use Banner"
108
  msgstr ""
109
 
110
- #: ../inc/settings.php:88
111
  msgid "Opt-Out Banner-Text"
112
  msgstr ""
113
 
114
- #: ../inc/settings.php:91
115
  msgid "Integrate Shortcode"
116
  msgstr ""
117
 
118
- #: ../inc/settings.php:94
119
  msgid "Hide banner after closing"
120
  msgstr ""
121
 
122
- #: ../inc/settings.php:97
123
  msgid "Custom CSS"
124
  msgstr ""
125
 
126
- #: ../inc/settings.php:130
127
  msgid "Monster Insights Plugin has been detected."
128
  msgstr ""
129
 
130
- #: ../inc/settings.php:132
131
  msgid ""
132
- "Monster Insights Plugin has NOT been detected. Please enter your UA code "
133
- "manually and then check the sourcode of your website. Make sure that "
134
  "Analytics code appears AFTER the opt-out code (which starts with <code>/* "
135
  "Google Analytics Opt-Out</code>)."
136
  msgstr ""
137
 
138
- #: ../inc/settings.php:186
139
  msgid ""
140
  "Some users reported problems with the editor button. So you can deactivate "
141
  "it here. Read more about the <a target=\"_blank\" href=\"https://wp-buddy."
@@ -143,28 +158,28 @@ msgid ""
143
  "that-i-can-use\">shortcodes</a> that can be used instead."
144
  msgstr ""
145
 
146
- #: ../inc/settings.php:206
147
  msgid "Please integrate the shortcode so that the user can opt-out."
148
  msgstr ""
149
 
150
- #: ../inc/settings.php:220
151
  msgid "If the shortcode was not detected, it will be added automatically."
152
  msgstr ""
153
 
154
- #: ../inc/settings.php:244
155
  msgid ""
156
  "This will hide the opt-out box after the user has clicked the close-button. "
157
  "Otherwise a little info-button will be fixed to the bottom-right."
158
  msgstr ""
159
 
160
- #: ../inc/shortcodes.php:54
161
  msgid "Click here to opt out."
162
  msgstr ""
163
 
164
- #: ../inc/shortcodes.php:60
165
  msgid "No UA-Code has been entered. Please ask the admin to solve this issue!"
166
  msgstr ""
167
 
168
- #: ../inc/shortcodes.php:81
169
  msgid "OK"
170
  msgstr ""
2
  msgid ""
3
  msgstr ""
4
  "Project-Id-Version: Google Analytics Opt-Out\n"
5
+ "POT-Creation-Date: 2019-02-18 11:03+0000\n"
6
  "PO-Revision-Date: 2013-11-12 09:04+0100\n"
7
  "Last-Translator: WP-Buddy <info@wp-buddy.com>\n"
8
  "Language-Team: \n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
+ "X-Generator: Poedit 2.2.1\n"
13
  "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
14
  "_n_noop:1,2;_c;_nc:4c,1,2;_x:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;_ex:1,2c;"
15
  "esc_attr__;esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
+ "X-Poedit-Basepath: ..\n"
18
+ "X-Poedit-SearchPath-0: .\n"
19
+ "X-Poedit-SearchPathExcluded-0: node_modules\n"
20
+ "X-Poedit-SearchPathExcluded-1: js\n"
21
 
22
+ #: blocks/opt-out.js:10
23
+ msgid "Analytics Opt Out"
24
+ msgstr ""
25
+
26
+ #: blocks/opt-out.js:64 blocks/opt-out.js:79
27
+ msgid "Click here to opt out"
28
+ msgstr ""
29
+
30
+ #: blocks/opt-out.js:69
31
+ msgid "Enter a link text"
32
+ msgstr ""
33
+
34
+ #: google-analytics-opt-out.php:53
35
  #, php-format
36
  msgid ""
37
  "You are using PHP in version %s. This version is outdated and cannot be used "
40
  "this."
41
  msgstr ""
42
 
43
+ #: inc/admin.php:12
44
  msgid ""
45
  "To use the Google Analytics Opt-Out Plugin please enter an UA-Code on the "
46
  "settings page."
47
  msgstr ""
48
 
49
+ #: inc/admin.php:32
50
  msgid "Settings"
51
  msgstr ""
52
 
53
+ #: inc/admin.php:33
54
  msgid "More by WP-Buddy"
55
  msgstr ""
56
 
57
+ #: inc/frontend.php:20
58
  msgid "Google Analytics Opt-Out Information"
59
  msgstr ""
60
 
61
+ #: inc/frontend.php:20
62
  msgid "Close"
63
  msgstr ""
64
 
65
+ #: inc/frontend.php:22
66
  msgid "Close this and do not ask me again"
67
  msgstr ""
68
 
69
+ #: inc/frontend.php:39
70
  msgid ""
71
  "This website is using Google Analytics. Please click here if you want to opt-"
72
  "out."
73
  msgstr ""
74
 
75
+ #: inc/frontend.php:43
76
  msgid "Click here to opt-out."
77
  msgstr ""
78
 
79
+ #: inc/functions.php:113 inc/settings.php:231
80
  msgid ""
81
  "Thanks. We have set a cookie so that Google Analytics data collection will "
82
  "be disabled on your next visit."
83
  msgstr ""
84
 
85
+ #: inc/settings.php:11 inc/settings.php:14
86
  msgid "Analytics Opt-Out"
87
  msgstr ""
88
 
89
+ #: inc/settings.php:14 inc/settings.php:71
90
  msgid "Opt-Out Settings"
91
  msgstr ""
92
 
93
+ #: inc/settings.php:35
94
  #, php-format
95
  msgid ""
96
+ "This plugin provides an Opt-Out functionality for Google Analytics "
97
+ "(Universal Tracking aka analytics.js and Global Site Tag aka gtag.js). You "
98
+ "can show a banner to your users and/or you can use the following shortcode "
99
+ "in any of your posts: %s. It integrates a link that allows a user to opt-out "
100
  "off Google Analytics. You can read more about the <a href=\"https://wp-buddy."
101
  "com/documentation/plugins/google-analytics-opt/faq/#what-are-the-shortcodes-"
102
  "that-i-can-use\" target=\"_blank\">shortcodes here</a>."
103
  msgstr ""
104
 
105
+ #: inc/settings.php:73
106
  msgid "Use Monster Insights Settings"
107
  msgstr ""
108
 
109
+ #: inc/settings.php:76
110
+ msgid "UA- or GA-Code"
111
  msgstr ""
112
 
113
+ #: inc/settings.php:79
114
+ msgid "Show Editor button (Classic Editor)"
115
  msgstr ""
116
 
117
+ #: inc/settings.php:82
118
  msgid "Opt-Out Successful"
119
  msgstr ""
120
 
121
+ #: inc/settings.php:85
122
  msgid "Use Banner"
123
  msgstr ""
124
 
125
+ #: inc/settings.php:88
126
  msgid "Opt-Out Banner-Text"
127
  msgstr ""
128
 
129
+ #: inc/settings.php:91
130
  msgid "Integrate Shortcode"
131
  msgstr ""
132
 
133
+ #: inc/settings.php:94
134
  msgid "Hide banner after closing"
135
  msgstr ""
136
 
137
+ #: inc/settings.php:97
138
  msgid "Custom CSS"
139
  msgstr ""
140
 
141
+ #: inc/settings.php:130
142
  msgid "Monster Insights Plugin has been detected."
143
  msgstr ""
144
 
145
+ #: inc/settings.php:132
146
  msgid ""
147
+ "Monster Insights Plugin has NOT been detected. Please enter your UA- or GA-"
148
+ "code manually and then check the sourcode of your website. Make sure that "
149
  "Analytics code appears AFTER the opt-out code (which starts with <code>/* "
150
  "Google Analytics Opt-Out</code>)."
151
  msgstr ""
152
 
153
+ #: inc/settings.php:186
154
  msgid ""
155
  "Some users reported problems with the editor button. So you can deactivate "
156
  "it here. Read more about the <a target=\"_blank\" href=\"https://wp-buddy."
158
  "that-i-can-use\">shortcodes</a> that can be used instead."
159
  msgstr ""
160
 
161
+ #: inc/settings.php:206
162
  msgid "Please integrate the shortcode so that the user can opt-out."
163
  msgstr ""
164
 
165
+ #: inc/settings.php:220
166
  msgid "If the shortcode was not detected, it will be added automatically."
167
  msgstr ""
168
 
169
+ #: inc/settings.php:244
170
  msgid ""
171
  "This will hide the opt-out box after the user has clicked the close-button. "
172
  "Otherwise a little info-button will be fixed to the bottom-right."
173
  msgstr ""
174
 
175
+ #: inc/shortcodes.php:54
176
  msgid "Click here to opt out."
177
  msgstr ""
178
 
179
+ #: inc/shortcodes.php:60
180
  msgid "No UA-Code has been entered. Please ask the admin to solve this issue!"
181
  msgstr ""
182
 
183
+ #: inc/shortcodes.php:81
184
  msgid "OK"
185
  msgstr ""
readme.txt CHANGED
@@ -2,11 +2,11 @@
2
  Contributors: wp-buddy, floriansimeth
3
  Donate link: https://wp-buddy.com/products/plugins/google-analytics-opt-out/
4
  Tags: google analytics opt-out, monster insights, gdpr
5
- Version: 2.2.4
6
- Stable tag: 2.2.4
7
  Requires at least: 4.8.0
8
  Requires PHP: 5.6.0
9
- Tested up to: 5.0
10
  License: GPLv2
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
@@ -15,16 +15,16 @@ Provides an Opt-Out functionality for Google Analytics
15
 
16
  == Description ==
17
 
18
- This plugin provides an Opt-Out functionality for Google Analytics by setting a cookie that prevents analytics.js to collect data. The new GDPR rules requier an opt-out.
19
 
20
- Works perfectly together with the [Google Analytics by MonsterInsights Plugin](http://wordpress.org/plugins/google-analytics-for-wordpress/ "Google Analytics by MonsterInsights Plugin"). However the plugin is not necessary to configure the opt-out feature. Just enter your UA-Code manually. That's it!
21
 
22
  The free and the pro version have now been merged together. So you now can have the option to activate a banner, too! Enjoy!
23
 
24
  == Installation ==
25
 
26
  * Install and activate the plugin via your WordPress Administration panel
27
- * Go the "Settings" -> "Analytics Opt Out" and enter your UA-code (you don't need this step if MonsterInsights plugin is active).
28
  * [Read the FAQ for more information.](https://wp-buddy.com/documentation/plugins/google-analytics-opt/faq/)
29
 
30
  == Frequently Asked Questions ==
@@ -42,6 +42,10 @@ The free and the pro version have now been merged together. So you now can have
42
 
43
  == Changelog ==
44
 
 
 
 
 
45
  = 2.2.4 =
46
  * Gutenberg block content was not translated correctly in WordPress 5.0
47
 
2
  Contributors: wp-buddy, floriansimeth
3
  Donate link: https://wp-buddy.com/products/plugins/google-analytics-opt-out/
4
  Tags: google analytics opt-out, monster insights, gdpr
5
+ Version: 2.2.5
6
+ Stable tag: 2.2.5
7
  Requires at least: 4.8.0
8
  Requires PHP: 5.6.0
9
+ Tested up to: 5.1
10
  License: GPLv2
11
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
12
 
15
 
16
  == Description ==
17
 
18
+ This plugin provides an Opt-Out functionality for Google Analytics by setting a cookie that prevents analytics.js or gtag.js to collect data. The new GDPR rules requires an opt-out.
19
 
20
+ Works perfectly together with the [Google Analytics by MonsterInsights Plugin](http://wordpress.org/plugins/google-analytics-for-wordpress/ "Google Analytics by MonsterInsights Plugin"). However the plugin is not necessary to configure the opt-out feature. Just enter your UA- or GA-Code manually. That's it!
21
 
22
  The free and the pro version have now been merged together. So you now can have the option to activate a banner, too! Enjoy!
23
 
24
  == Installation ==
25
 
26
  * Install and activate the plugin via your WordPress Administration panel
27
+ * Go the "Settings" -> "Analytics Opt Out" and enter your UA- or GA-code (you don't need this step if MonsterInsights plugin is active).
28
  * [Read the FAQ for more information.](https://wp-buddy.com/documentation/plugins/google-analytics-opt/faq/)
29
 
30
  == Frequently Asked Questions ==
42
 
43
  == Changelog ==
44
 
45
+ = 2.2.5 =
46
+ * Corrected text domain for JS translations
47
+ * State that plugin works with gtag.js, too.
48
+
49
  = 2.2.4 =
50
  * Gutenberg block content was not translated correctly in WordPress 5.0
51