mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2025-03-28 13:50:45 -04:00
feat(privacy banner): add l10n, better a11y
This commit is contained in:
parent
d7ca6dd6b2
commit
709dffb600
2 changed files with 36 additions and 28 deletions
src
|
@ -40,36 +40,43 @@ class PrivacyBanner extends React.Component {
|
|||
}
|
||||
render () {
|
||||
const showBanner = this.shouldShowBanner();
|
||||
const privacyPolicyLink = chunks => <a href="/privacy_policy">{chunks}</a>
|
||||
if (showBanner) {
|
||||
return (
|
||||
<TitleBanner className="privacy-banner">
|
||||
<div className="privacy-banner-container">
|
||||
<img
|
||||
aria-hidden="true"
|
||||
alt=""
|
||||
className="lightbulb-icon"
|
||||
src="/images/ideas/bulb-icon.svg"
|
||||
/>
|
||||
<div className="privacy-banner-centered">
|
||||
<p className="privacy-banner-text">
|
||||
The Scratch privacy policy has been updated, effective xx yy, 2023.
|
||||
You can see the new policy <a href="/privacy_policy">here</a>.
|
||||
</p>
|
||||
</div>
|
||||
<Button
|
||||
isCloseType
|
||||
className="privacy-close-button"
|
||||
key="closeButton"
|
||||
name="closeButton"
|
||||
type="button"
|
||||
onClick={this.handleCloseBanner}
|
||||
>
|
||||
<div className="action-button-text">
|
||||
<FormattedMessage id="general.close" />
|
||||
<aside>
|
||||
<TitleBanner className="privacy-banner">
|
||||
<div className="privacy-banner-container">
|
||||
<img
|
||||
aria-hidden="true"
|
||||
alt=""
|
||||
className="lightbulb-icon"
|
||||
src="/images/ideas/bulb-icon.svg"
|
||||
/>
|
||||
<div className="privacy-banner-centered">
|
||||
<p className="privacy-banner-text">
|
||||
<FormattedMessage
|
||||
id="privacyBanner.update"
|
||||
values={{
|
||||
a: privacyPolicyLink
|
||||
}}
|
||||
/>
|
||||
</p>
|
||||
</div>
|
||||
</Button>
|
||||
</div>
|
||||
</TitleBanner>
|
||||
<Button
|
||||
isCloseType
|
||||
className="privacy-close-button"
|
||||
key="closeButton"
|
||||
name="closeButton"
|
||||
type="button"
|
||||
onClick={this.handleCloseBanner}
|
||||
>
|
||||
<div className="action-button-text">
|
||||
<FormattedMessage id="general.close" />
|
||||
</div>
|
||||
</Button>
|
||||
</div>
|
||||
</TitleBanner>
|
||||
</aside>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
@ -451,5 +451,6 @@
|
|||
"extensions.otherComputerConnectedText": "Only one computer can be connected to a {deviceName} at a time. If you have another computer connected to your {deviceName}, disconnect the {deviceName} or close Scratch on that computer and try again.",
|
||||
|
||||
"bluetooth.enableLocationServicesTitle": "Make sure you have location services enabled on Chromebooks or Android tablets",
|
||||
"bluetooth.enableLocationServicesText": "Bluetooth can be used to provide location data to the app. In addition to granting the Scratch App permission to access location, location must be enabled in your general device settings. Search for 'Location' in your settings, and make sure it is on. On Chromebooks search for 'Location' in the Google Play Store Android preferences."
|
||||
"bluetooth.enableLocationServicesText": "Bluetooth can be used to provide location data to the app. In addition to granting the Scratch App permission to access location, location must be enabled in your general device settings. Search for 'Location' in your settings, and make sure it is on. On Chromebooks search for 'Location' in the Google Play Store Android preferences.",
|
||||
"privacyBanner.update": "The Scratch privacy policy has been updated, effective xx yy, 2023. You can see the new policy <a>here</a>."
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue