From 0028a5baf84466f32c13e832172a57a0078b5995 Mon Sep 17 00:00:00 2001 From: Sami Keijonen Date: Wed, 18 Jan 2023 12:42:07 +0200 Subject: [PATCH] Update copy text. --- inc/filters.php | 12 ++++++------ languages/meom-cookiebot-embed-fi.mo | Bin 1130 -> 1286 bytes languages/meom-cookiebot-embed-fi.po | 25 +++++++++++++++++-------- languages/meom-cookiebot-embed.pot | 8 +++++--- 4 files changed, 28 insertions(+), 17 deletions(-) diff --git a/inc/filters.php b/inc/filters.php index b932e55..b279761 100644 --- a/inc/filters.php +++ b/inc/filters.php @@ -17,17 +17,17 @@ */ function render_block( $block_content, $block ) { /** - * Filters the condition when to add Cookiebot message to the embed block. - * - * @param string $condition Condition. - * @param string $block_content The block content about to be appended. + * Filters the condition when to add Cookiebot message to the embed block. + * + * @param string $condition Condition. + * @param string $block_content The block content about to be appended. * @param array $block The full block, including name and attributes. - */ + */ $condition = apply_filters( 'meom_cookiebot_embed_condition', 'core/embed' === $block['blockName'] && 'youtube' === $block['attrs']['providerNameSlug'], $block_content, $block ); if ( $condition ) { $cookie_text = '

'; - $cookie_text .= sprintf( __( 'Please accept marketing-cookies to watch this video.', 'meom-cookiebot-embed' ), 'javascript:Cookiebot.renew()' ); + $cookie_text .= sprintf( __( 'Oops! This video will not be shown because you have disabled the marketing cookies. To see the video, accept marketing cookies.', 'meom-cookiebot-embed' ), 'javascript:Cookiebot.renew()' ); $cookie_text .= '

'; $block_content = str_replace( '', $cookie_text . '', $block_content ); diff --git a/languages/meom-cookiebot-embed-fi.mo b/languages/meom-cookiebot-embed-fi.mo index 9276b03213425cbdaeb84408a5345b52031058bc..a5d76ca236ab849fe04b51be167d6b1be6ecd012 100644 GIT binary patch delta 377 zcmZusOHKko5N(i!8cjTbDG_%AI_kn0oFmAF#Kc|0lys+Ox((GpX2s5(3B)V3TQ??N zpbz04TzUcvl%18lRHZ)ez53dI+Fi8f3n7GLWQ=ddXI+T2CPd(Rry;~0=QqyW5?hQ- z@R|@k_ee+3SDIj|b96A%MFG}%7$A^xGt0$LP6(lL6Hs!BkZY2I0(0;Rp*)sjgI?Pa z44pF?sRMlngt#8BNt5O1aBnm2p2}?bI^Vx&pQY{e3exlI%k(|1J=ffjsgP77X9`_+dM68-vPYFodLkIc)-6 j32KZFH_a1jW~*IL6<@auRV+=!^8YZSUs-=SXx#q*IM98z delta 219 zcmZqUdc`q8#o3jCfgury?SObW5MO6vV0Z?kgMoM-GXq07kQQQLU|hE zrGlY>m5I^j8pd9xAdkwj!%MP@D-~=K6*7ua(`=PgiBP diff --git a/languages/meom-cookiebot-embed-fi.po b/languages/meom-cookiebot-embed-fi.po index 8348236..fd28358 100644 --- a/languages/meom-cookiebot-embed-fi.po +++ b/languages/meom-cookiebot-embed-fi.po @@ -1,8 +1,8 @@ msgid "" msgstr "" "Project-Id-Version: MEOM Cookiebot embed\n" -"POT-Creation-Date: 2022-12-09 10:41+0200\n" -"PO-Revision-Date: 2022-12-09 10:42+0200\n" +"POT-Creation-Date: 2023-01-18 12:39+0200\n" +"PO-Revision-Date: 2023-01-18 12:41+0200\n" "Last-Translator: \n" "Language-Team: \n" "Language: fi\n" @@ -16,18 +16,20 @@ msgstr "" "X-Poedit-WPHeader: meom-cookiebot-embed.php\n" "X-Poedit-SourceCharset: UTF-8\n" "X-Poedit-KeywordsList: __;_e;_n:1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;esc_attr__;" -"esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;_n_noop:1,2;" -"_nx_noop:3c,1,2;__ngettext_noop:1,2\n" +"esc_attr_e;esc_attr_x:1,2c;esc_html__;esc_html_e;esc_html_x:1,2c;" +"_n_noop:1,2;_nx_noop:3c,1,2;__ngettext_noop:1,2\n" "X-Poedit-SearchPath-0: .\n" "X-Poedit-SearchPathExcluded-0: *.min.js\n" "X-Poedit-SearchPathExcluded-1: vendor\n" -#: inc/filters.php:21 +#: inc/filters.php:30 #, php-format -msgid "Please accept marketing-cookies to watch this video." +msgid "" +"Oops! This video will not be shown because you have disabled the marketing " +"cookies. To see the video, accept marketing cookies." msgstr "" -"Hyväksy markkinointievästeet, jotta voit nähdä tämän " -"videon." +"Oho! Tämä video ei näy, koska olet kieltänyt markkinointievästeiden käytön. " +"Nähdäksesi videon, käy hyväksymässä markkinointievästeet." #. Plugin Name of the plugin/theme msgid "MEOM Cookiebot embed" @@ -46,3 +48,10 @@ msgstr "" #. Author URI of the plugin/theme msgid "https://www.meom.fi/" msgstr "" + +#, php-format +#~ msgid "" +#~ "Please accept marketing-cookies to watch this video." +#~ msgstr "" +#~ "Hyväksy markkinointievästeet, jotta voit nähdä tämän " +#~ "videon." diff --git a/languages/meom-cookiebot-embed.pot b/languages/meom-cookiebot-embed.pot index 0068ffd..b525abe 100644 --- a/languages/meom-cookiebot-embed.pot +++ b/languages/meom-cookiebot-embed.pot @@ -2,7 +2,7 @@ msgid "" msgstr "" "Project-Id-Version: MEOM Cookiebot embed\n" -"POT-Creation-Date: 2022-12-09 10:41+0200\n" +"POT-Creation-Date: 2023-01-18 12:39+0200\n" "PO-Revision-Date: 2022-12-08 16:43+0200\n" "Last-Translator: \n" "Language-Team: \n" @@ -22,9 +22,11 @@ msgstr "" "X-Poedit-SearchPathExcluded-0: *.min.js\n" "X-Poedit-SearchPathExcluded-1: vendor\n" -#: inc/filters.php:21 +#: inc/filters.php:30 #, php-format -msgid "Please accept marketing-cookies to watch this video." +msgid "" +"Oops! This video will not be shown because you have disabled the marketing " +"cookies. To see the video, accept marketing cookies." msgstr "" #. Plugin Name of the plugin/theme