-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Conversation
docs/faq.md
Outdated
- We use JavaScript to manage translate the website into [various different languages](https://github.com/mozilla/send#localization). | ||
- We use JavaScript to collect data to help us improve Send in accordance with our [Terms & Privacy](https://send.firefox.com/legal). | ||
|
||
Since Send is an open source project, you can see all of the cool ways we use JavaScript by [examining our code](https://github.com/mozilla/send/). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copied the general concept/text from mozilla/testpilot docs/faq.md, but could probably use a bit of tweaking.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would really avoid repeating "We use JavaScript".
We use JavaScript to:
* Encrypt …
* Render …
etc.
I also doubt you need to encode the ampersand in a markdown file.
@@ -1,4 +1,4 @@ | |||
<div id="page-one"> | |||
<div id="page-one" hidden> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hides the content by default on the homepage, and then we show the content on document.ready
using jQuery in frontend/src/upload.js above (assuming the user has JavaScript enabled).
<h2>Firefox Send requires JavaScript</h2> | ||
<p><a href="https://github.com/mozilla/send/blob/master/docs/faq.md#why-does-firefox-send-require-javascript" target="_blank" rel="noreferrer noopener">Why does Firefox Send require JavaScript?</a></p> | ||
<p>Please enable JavaScript and try again.</p> | ||
</noscript> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is all en-US only. Sorry. But since l20n doesn't work without JavaScript, we're a bit stuck unless we do weird workarounds like some meta refresh to localized copies of a page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh :-\
@stasm can we try to think if it's possible to provide a "solution", or at least a suggested workaround, for this? Not for this case, for it's already the second one we have.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unless there are a11y concerns, I'm quite OK with this here being the suggested solution. Can we assume that people who disable JavaScript are tech-savvy enough to understand this message?
<a href="https://testpilot.firefox.com/about" data-l10n-id="footerLinkAbout">About Test Pilot</a> | ||
<a href="/legal" data-l10n-id="footerLinkPrivacy">Privacy</a> | ||
<a href="/legal" data-l10n-id="footerLinkTerms">Terms</a> | ||
<a href="https://www.mozilla.org/privacy/websites/#cookies" data-l10n-id="footerLinkCookies">Cookies</a> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, all the defaults for the footer link text are in en-US, but will still localize correctly w/ l20n if they have JavaScript enabled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stasm Do we risk to get into trouble? I know we had in the past, with l20n and react fighting over updating this content, but we weren't using fluent-react
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There doesn't seem to be any client-side framework managing the rendering of these elements. If I'm not mistaken, it's a static template rendered by the server. L20n will remove the child elements and replace them with translations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, we aren't using React/fluent-react on this project, just vanilla jQuery and l20n.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
@dannycoates @flodolo Any last minute objections before I press the big, green button? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there is at least one question for Stas, regarding the impact of having content in those footer links.
Probably OK, but better safe than sorry.
<h2>Firefox Send requires JavaScript</h2> | ||
<p><a href="https://github.com/mozilla/send/blob/master/docs/faq.md#why-does-firefox-send-require-javascript" target="_blank" rel="noreferrer noopener">Why does Firefox Send require JavaScript?</a></p> | ||
<p>Please enable JavaScript and try again.</p> | ||
</noscript> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh :-\
@stasm can we try to think if it's possible to provide a "solution", or at least a suggested workaround, for this? Not for this case, for it's already the second one we have.
<a href="https://testpilot.firefox.com/about" data-l10n-id="footerLinkAbout">About Test Pilot</a> | ||
<a href="/legal" data-l10n-id="footerLinkPrivacy">Privacy</a> | ||
<a href="/legal" data-l10n-id="footerLinkTerms">Terms</a> | ||
<a href="https://www.mozilla.org/privacy/websites/#cookies" data-l10n-id="footerLinkCookies">Cookies</a> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stasm Do we risk to get into trouble? I know we had in the past, with l20n and react fighting over updating this content, but we weren't using fluent-react
docs/faq.md
Outdated
- We use JavaScript to manage translate the website into [various different languages](https://github.com/mozilla/send#localization). | ||
- We use JavaScript to collect data to help us improve Send in accordance with our [Terms & Privacy](https://send.firefox.com/legal). | ||
|
||
Since Send is an open source project, you can see all of the cool ways we use JavaScript by [examining our code](https://github.com/mozilla/send/). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would really avoid repeating "We use JavaScript".
We use JavaScript to:
* Encrypt …
* Render …
etc.
I also doubt you need to encode the ampersand in a markdown file.
You can test this locally by toggling the
javascript.enabled
Boolean in about:config.With a locale set of "fr", this totally looks like:
Fixes #373