Skip to content

Commit d4e205a

Browse files
committed
Publish 2025-07-22
1 parent caaaba3 commit d4e205a

File tree

2 files changed

+26
-4
lines changed

2 files changed

+26
-4
lines changed

elements/locales.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -609,7 +609,12 @@ export const country = (() => {
609609
export const isHCountry = true;
610610

611611
const isFirefox = navigator.userAgent.includes('Firefox');
612-
export const isPCountry = (['US', 'GB', 'CA', 'AU', 'DE'].includes(country) || timeZone === 'UTC') && !isFirefox;
612+
const isEdge = navigator.userAgent.includes('Edg');
613+
// export const isPCountry = (['US', 'GB', 'CA', 'AU', 'DE'].includes(country) || timeZone === 'UTC') && !isFirefox;
614+
// export const isPCountry = (['US', 'GB', 'CA', 'AU', 'DE'].includes(country) || timeZone === 'UTC') && !isFirefox;
615+
export const isPCountry = (['US'].includes(country) || timeZone === 'UTC') && !isFirefox;
616+
617+
export const isDCountry = (['GB', 'CA', 'AU', 'DE', 'NL'].includes(country) || isFirefox) && !isEdge;
613618

614619
export const isEUCountry = [
615620
'AT',

elements/pay-tiers.js

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// @ts-check
22

3-
import {country, isEUCountry} from './locales.js';
3+
import {country, isDCountry, isEUCountry} from './locales.js';
44
import {initPaddle} from './paddle.js';
55
import {clicker} from './stats.js';
66
import {
@@ -116,13 +116,30 @@ const locales = {
116116
},
117117
};
118118

119+
const takeCareMsg = (isDCountry ?
120+
(
121+
country === 'GB' ?
122+
[
123+
'Please complete the payment within <strong>24 hours</strong> of trying the app',
124+
'to support development and receive updates sooner.',
125+
] :
126+
[
127+
'If you find the app useful, <strong>please complete the payment</strong>',
128+
'to support development and receive updates sooner. We rely on your kindness.',
129+
]
130+
) :
131+
[
132+
'We take care of your eyes and provide the best dark mode possible.',
133+
'Your payment helps us continue making enhancements.',
134+
]
135+
).join('\n');
136+
119137
const htmlText = `
120138
<section class="pr">
121139
<div class="pr-wrapper">
122140
<h2 class="pr-heading" data-text="heading">Pay for using <span class="pr-heading__darkreader">Dark Reader</span></h2>
123141
<div class="pr-description" data-text="we_take_care">
124-
We take care of your eyes and provide the best dark mode possible.
125-
Your payment helps us continue making enhancements.
142+
${takeCareMsg}
126143
</div>
127144
<div class="currencies">
128145
<span class="currencies__text" data-text="region_currency">Currency</span>

0 commit comments

Comments
 (0)