From ce23832988a27c74ecf4292fe3d06a6eea0967ee Mon Sep 17 00:00:00 2001 From: yheuhtozr <84892012+yheuhtozr@users.noreply.github.com> Date: Fri, 20 Jan 2023 07:25:03 +0900 Subject: [PATCH] I18nize views/pages (#18771) --- app/views/credits/_pricing.en.html.erb | 21 +++ app/views/credits/_pricing.fr.html.erb | 21 +++ app/views/credits/_purchase_faq.en.html.erb | 24 +++ app/views/credits/_purchase_faq.fr.html.erb | 24 +++ app/views/credits/new.html.erb | 50 +----- ...oc_text.html.erb => _coc_text.en.html.erb} | 0 app/views/pages/_coc_text.fr.html.erb | 51 ++++++ ...b => _editor_frontmatter_help.en.html.erb} | 0 .../_editor_frontmatter_help.fr.html.erb | 27 ++++ ....html.erb => _editor_guide_h3.en.html.erb} | 0 app/views/pages/_editor_guide_h3.fr.html.erb | 6 + ...tml.erb => _editor_guide_text.en.html.erb} | 0 .../pages/_editor_guide_text.fr.html.erb | 148 ++++++++++++++++++ ...ml.erb => _editor_liquid_help.en.html.erb} | 0 .../pages/_editor_liquid_help.fr.html.erb | 76 +++++++++ ....erb => _editor_markdown_help.en.html.erb} | 0 .../pages/_editor_markdown_help.fr.html.erb | 57 +++++++ ... => _liquid_tag_section_intro.en.html.erb} | 0 .../_liquid_tag_section_intro.fr.html.erb | 8 + ...lder.html.erb => _placeholder.en.html.erb} | 0 app/views/pages/_placeholder.fr.html.erb | 9 ++ ...ext.html.erb => _privacy_text.en.html.erb} | 0 app/views/pages/_privacy_text.fr.html.erb | 144 +++++++++++++++++ ..._supported_nonurl_embeds_list.en.html.erb} | 0 .../_supported_nonurl_embeds_list.fr.html.erb | 31 ++++ ...=> _supported_url_embeds_list.en.html.erb} | 0 .../_supported_url_embeds_list.fr.html.erb | 38 +++++ ..._text.html.erb => _terms_text.en.html.erb} | 0 app/views/pages/_terms_text.fr.html.erb | 140 +++++++++++++++++ ... => _v1_editor_guide_preamble.en.html.erb} | 0 .../_v1_editor_guide_preamble.fr.html.erb | 34 ++++ .../{about.html.erb => about.en.html.erb} | 0 app/views/pages/about.fr.html.erb | 1 + ...gs.html.erb => about_listings.en.html.erb} | 0 app/views/pages/about_listings.fr.html.erb | 1 + .../{bounty.html.erb => bounty.en.html.erb} | 0 app/views/pages/bounty.fr.html.erb | 1 + ...t.html.erb => code_of_conduct.en.html.erb} | 0 app/views/pages/code_of_conduct.fr.html.erb | 22 +++ ...l.erb => community_moderation.en.html.erb} | 0 .../pages/community_moderation.fr.html.erb | 1 + .../{contact.html.erb => contact.en.html.erb} | 0 app/views/pages/contact.fr.html.erb | 45 ++++++ ...uide.html.erb => editor_guide.en.html.erb} | 0 app/views/pages/editor_guide.fr.html.erb | 10 ++ .../pages/{faq.html.erb => faq.en.html.erb} | 0 app/views/pages/faq.fr.html.erb | 1 + ...rbidden.html.erb => forbidden.en.html.erb} | 0 app/views/pages/forbidden.fr.html.erb | 8 + ...s.html.erb => markdown_basics.en.html.erb} | 0 app/views/pages/markdown_basics.fr.html.erb | 62 ++++++++ ..._a_job.html.erb => post_a_job.en.html.erb} | 0 app/views/pages/post_a_job.fr.html.erb | 1 + .../{privacy.html.erb => privacy.en.html.erb} | 0 app/views/pages/privacy.fr.html.erb | 27 ++++ ... => publishing_from_rss_guide.en.html.erb} | 0 .../publishing_from_rss_guide.fr.html.erb | 46 ++++++ ...buse.html.erb => report_abuse.en.html.erb} | 0 app/views/pages/report_abuse.fr.html.erb | 29 ++++ .../pages/{show.html.erb => show.en.html.erb} | 0 app/views/pages/show.fr.html.erb | 44 ++++++ ...on.html.erb => tag_moderation.en.html.erb} | 0 app/views/pages/tag_moderation.fr.html.erb | 1 + .../{terms.html.erb => terms.en.html.erb} | 0 app/views/pages/terms.fr.html.erb | 27 ++++ config/locales/views/credits/en.yml | 3 + config/locales/views/credits/fr.yml | 3 + 67 files changed, 1196 insertions(+), 46 deletions(-) create mode 100644 app/views/credits/_pricing.en.html.erb create mode 100644 app/views/credits/_pricing.fr.html.erb create mode 100644 app/views/credits/_purchase_faq.en.html.erb create mode 100644 app/views/credits/_purchase_faq.fr.html.erb rename app/views/pages/{_coc_text.html.erb => _coc_text.en.html.erb} (100%) create mode 100644 app/views/pages/_coc_text.fr.html.erb rename app/views/pages/{_editor_frontmatter_help.html.erb => _editor_frontmatter_help.en.html.erb} (100%) create mode 100644 app/views/pages/_editor_frontmatter_help.fr.html.erb rename app/views/pages/{_editor_guide_h3.html.erb => _editor_guide_h3.en.html.erb} (100%) create mode 100644 app/views/pages/_editor_guide_h3.fr.html.erb rename app/views/pages/{_editor_guide_text.html.erb => _editor_guide_text.en.html.erb} (100%) create mode 100644 app/views/pages/_editor_guide_text.fr.html.erb rename app/views/pages/{_editor_liquid_help.html.erb => _editor_liquid_help.en.html.erb} (100%) create mode 100644 app/views/pages/_editor_liquid_help.fr.html.erb rename app/views/pages/{_editor_markdown_help.html.erb => _editor_markdown_help.en.html.erb} (100%) create mode 100644 app/views/pages/_editor_markdown_help.fr.html.erb rename app/views/pages/{_liquid_tag_section_intro.html.erb => _liquid_tag_section_intro.en.html.erb} (100%) create mode 100644 app/views/pages/_liquid_tag_section_intro.fr.html.erb rename app/views/pages/{_placeholder.html.erb => _placeholder.en.html.erb} (100%) create mode 100644 app/views/pages/_placeholder.fr.html.erb rename app/views/pages/{_privacy_text.html.erb => _privacy_text.en.html.erb} (100%) create mode 100644 app/views/pages/_privacy_text.fr.html.erb rename app/views/pages/{_supported_nonurl_embeds_list.html.erb => _supported_nonurl_embeds_list.en.html.erb} (100%) create mode 100644 app/views/pages/_supported_nonurl_embeds_list.fr.html.erb rename app/views/pages/{_supported_url_embeds_list.html.erb => _supported_url_embeds_list.en.html.erb} (100%) create mode 100644 app/views/pages/_supported_url_embeds_list.fr.html.erb rename app/views/pages/{_terms_text.html.erb => _terms_text.en.html.erb} (100%) create mode 100644 app/views/pages/_terms_text.fr.html.erb rename app/views/pages/{_v1_editor_guide_preamble.html.erb => _v1_editor_guide_preamble.en.html.erb} (100%) create mode 100644 app/views/pages/_v1_editor_guide_preamble.fr.html.erb rename app/views/pages/{about.html.erb => about.en.html.erb} (100%) create mode 100644 app/views/pages/about.fr.html.erb rename app/views/pages/{about_listings.html.erb => about_listings.en.html.erb} (100%) create mode 100644 app/views/pages/about_listings.fr.html.erb rename app/views/pages/{bounty.html.erb => bounty.en.html.erb} (100%) create mode 100644 app/views/pages/bounty.fr.html.erb rename app/views/pages/{code_of_conduct.html.erb => code_of_conduct.en.html.erb} (100%) create mode 100644 app/views/pages/code_of_conduct.fr.html.erb rename app/views/pages/{community_moderation.html.erb => community_moderation.en.html.erb} (100%) create mode 100644 app/views/pages/community_moderation.fr.html.erb rename app/views/pages/{contact.html.erb => contact.en.html.erb} (100%) create mode 100644 app/views/pages/contact.fr.html.erb rename app/views/pages/{editor_guide.html.erb => editor_guide.en.html.erb} (100%) create mode 100644 app/views/pages/editor_guide.fr.html.erb rename app/views/pages/{faq.html.erb => faq.en.html.erb} (100%) create mode 100644 app/views/pages/faq.fr.html.erb rename app/views/pages/{forbidden.html.erb => forbidden.en.html.erb} (100%) create mode 100644 app/views/pages/forbidden.fr.html.erb rename app/views/pages/{markdown_basics.html.erb => markdown_basics.en.html.erb} (100%) create mode 100644 app/views/pages/markdown_basics.fr.html.erb rename app/views/pages/{post_a_job.html.erb => post_a_job.en.html.erb} (100%) create mode 100644 app/views/pages/post_a_job.fr.html.erb rename app/views/pages/{privacy.html.erb => privacy.en.html.erb} (100%) create mode 100644 app/views/pages/privacy.fr.html.erb rename app/views/pages/{publishing_from_rss_guide.html.erb => publishing_from_rss_guide.en.html.erb} (100%) create mode 100644 app/views/pages/publishing_from_rss_guide.fr.html.erb rename app/views/pages/{report_abuse.html.erb => report_abuse.en.html.erb} (100%) create mode 100644 app/views/pages/report_abuse.fr.html.erb rename app/views/pages/{show.html.erb => show.en.html.erb} (100%) create mode 100644 app/views/pages/show.fr.html.erb rename app/views/pages/{tag_moderation.html.erb => tag_moderation.en.html.erb} (100%) create mode 100644 app/views/pages/tag_moderation.fr.html.erb rename app/views/pages/{terms.html.erb => terms.en.html.erb} (100%) create mode 100644 app/views/pages/terms.fr.html.erb diff --git a/app/views/credits/_pricing.en.html.erb b/app/views/credits/_pricing.en.html.erb new file mode 100644 index 000000000..b1c9ce033 --- /dev/null +++ b/app/views/credits/_pricing.en.html.erb @@ -0,0 +1,21 @@ +
+
1+
+ $5/per credit +
+
+
10+
+ $4/per credit
+
+
+ 100+ +
+ $3/per credit
+
+
+ 1000+ +
+ $2.50/per credit +
+
+ +

Contact <%= contact_link(additional_info: { subject: "Custom Bulk Pricing/Partnerships" }) %> for custom bulk pricing and partnerships.

diff --git a/app/views/credits/_pricing.fr.html.erb b/app/views/credits/_pricing.fr.html.erb new file mode 100644 index 000000000..b1c9ce033 --- /dev/null +++ b/app/views/credits/_pricing.fr.html.erb @@ -0,0 +1,21 @@ +
+
1+
+ $5/per credit +
+
+
10+
+ $4/per credit
+
+
+ 100+ +
+ $3/per credit
+
+
+ 1000+ +
+ $2.50/per credit +
+
+ +

Contact <%= contact_link(additional_info: { subject: "Custom Bulk Pricing/Partnerships" }) %> for custom bulk pricing and partnerships.

diff --git a/app/views/credits/_purchase_faq.en.html.erb b/app/views/credits/_purchase_faq.en.html.erb new file mode 100644 index 000000000..accd7b8b7 --- /dev/null +++ b/app/views/credits/_purchase_faq.en.html.erb @@ -0,0 +1,24 @@ +
+ + How many credits does one listing cost? + +
+

+ All listings cost 1 credit, except: +

+ +

+ Buying more credits upfront makes listings more cost-effective. +

+

+ 25 credits purchased today costs $100. 25 credits purchased individually will cost $125, etc. +

+
+
diff --git a/app/views/credits/_purchase_faq.fr.html.erb b/app/views/credits/_purchase_faq.fr.html.erb new file mode 100644 index 000000000..accd7b8b7 --- /dev/null +++ b/app/views/credits/_purchase_faq.fr.html.erb @@ -0,0 +1,24 @@ +
+ + How many credits does one listing cost? + +
+

+ All listings cost 1 credit, except: +

+ +

+ Buying more credits upfront makes listings more cost-effective. +

+

+ 25 credits purchased today costs $100. 25 credits purchased individually will cost $125, etc. +

+
+
diff --git a/app/views/credits/new.html.erb b/app/views/credits/new.html.erb index 31bf24ace..c5c943f92 100644 --- a/app/views/credits/new.html.erb +++ b/app/views/credits/new.html.erb @@ -24,54 +24,12 @@ -

Credits are used for <%= community_name %> listings as well as upcoming products and services.

+

<%= t("views.credits.new.hook.text_html", listings: link_to(t("views.credits.new.hook.listings", community: community_name), listings_path)) %>

-
-
1+
- $5/per credit -
-
-
10+
- $4/per credit
-
-
- 100+ -
- $3/per credit
-
-
- 1000+ -
- $2.50/per credit -
-
-
-

Contact <%= contact_link(additional_info: { subject: "Custom Bulk Pricing/Partnerships" }) %> for custom bulk pricing and partnerships.

-
- - How many credits does one listing cost? - -
-

- All listings cost 1 credit, except: -

- -

- Buying more credits upfront makes listings more cost-effective. -

-

- 25 credits purchased today costs $100. 25 credits purchased individually will cost $125, etc. -

-
-
+ <%= render "pricing" %> + + <%= render "purchase_faq" %>
<%= params[:organization_id].present? ? t("views.credits.new.status.subtitle.org", name: @purchaser.name) : t("views.credits.new.status.subtitle.user") %> diff --git a/app/views/pages/_coc_text.html.erb b/app/views/pages/_coc_text.en.html.erb similarity index 100% rename from app/views/pages/_coc_text.html.erb rename to app/views/pages/_coc_text.en.html.erb diff --git a/app/views/pages/_coc_text.fr.html.erb b/app/views/pages/_coc_text.fr.html.erb new file mode 100644 index 000000000..7a84a7051 --- /dev/null +++ b/app/views/pages/_coc_text.fr.html.erb @@ -0,0 +1,51 @@ +

All participants of <%= community_name %> are expected to abide by our Code of Conduct, both online and during in-person events that are hosted and/or associated with <%= community_name %>.

+

Our Pledge

+

In the interest of fostering an open and welcoming environment, we as moderators of +<% if creator_settings_form? %> + <%= community_name %> pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation. +<% else %> + <%= community_name %> pledge to make participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation. +<% end %> +

+

Our Standards

+

Examples of behavior that contributes to creating a positive environment include:

+ +

Examples of unacceptable behavior by participants include:

+ +

We pledge to prioritize marginalized people’s safety over privileged people’s comfort. We will not act on complaints regarding:

+ +

Enforcement

+

Violations of the Code of Conduct may be reported by contacting the team via the +<% if creator_settings_form? %> + abuse report form or by sending an email to <%= contact_link %>. All reports will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. Further details of specific enforcement policies may be posted separately. +<% else %> + ">abuse report form or by sending an email to <%= contact_link %>. All reports will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. Further details of specific enforcement policies may be posted separately. +<% end %> +

+

Moderators have the right and responsibility to remove comments or other contributions that are not aligned to this Code of Conduct, or to suspend temporarily or permanently any members for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

+

Attribution

+

This Code of Conduct is adapted from:

+ diff --git a/app/views/pages/_editor_frontmatter_help.html.erb b/app/views/pages/_editor_frontmatter_help.en.html.erb similarity index 100% rename from app/views/pages/_editor_frontmatter_help.html.erb rename to app/views/pages/_editor_frontmatter_help.en.html.erb diff --git a/app/views/pages/_editor_frontmatter_help.fr.html.erb b/app/views/pages/_editor_frontmatter_help.fr.html.erb new file mode 100644 index 000000000..03d4a141d --- /dev/null +++ b/app/views/pages/_editor_frontmatter_help.fr.html.erb @@ -0,0 +1,27 @@ +
+
+
+

We have two editor versions. If you'd prefer to edit title and tags etc. as separate fields, switch to the "rich + markdown" option in Settings » UX. Otherwise, continue...

+
+ +
    +
  • This editor is a markdown editor that uses Jekyll front matter.
  • +
  • Most of the time, you can write inline HTML directly into your posts.
  • +
  • We support native Liquid tags and created some fun custom ones, too! Trying embedding a Tweet or GitHub issue in your post.
  • +
  • Links to unpublished posts are shareable for feedback/review.
  • +
  • When you're ready to publish, set the published variable to true.
  • +
+ +

Front Matter

+

Custom variables set for each post, located between the triple-dashed lines in your editor. Here is a list of possibilities:

+
    +
  • title: the title of your article
  • +
  • published: boolean that determines whether or not your article is published
  • +
  • description: description area in Twitter cards and open graph cards
  • +
  • tags: max of four tags, needs to be comma-separated
  • +
  • canonical_url: link for the canonical version of the content
  • +
  • cover_image: cover image for post, accepts a URL.
    The best size is 1000 x 420.
  • +
  • series: post series name.
  • +
+
+
diff --git a/app/views/pages/_editor_guide_h3.html.erb b/app/views/pages/_editor_guide_h3.en.html.erb similarity index 100% rename from app/views/pages/_editor_guide_h3.html.erb rename to app/views/pages/_editor_guide_h3.en.html.erb diff --git a/app/views/pages/_editor_guide_h3.fr.html.erb b/app/views/pages/_editor_guide_h3.fr.html.erb new file mode 100644 index 000000000..e30b5ccd7 --- /dev/null +++ b/app/views/pages/_editor_guide_h3.fr.html.erb @@ -0,0 +1,6 @@ + diff --git a/app/views/pages/_editor_guide_text.html.erb b/app/views/pages/_editor_guide_text.en.html.erb similarity index 100% rename from app/views/pages/_editor_guide_text.html.erb rename to app/views/pages/_editor_guide_text.en.html.erb diff --git a/app/views/pages/_editor_guide_text.fr.html.erb b/app/views/pages/_editor_guide_text.fr.html.erb new file mode 100644 index 000000000..941b0d816 --- /dev/null +++ b/app/views/pages/_editor_guide_text.fr.html.erb @@ -0,0 +1,148 @@ + + +
+
+

Editor Guide 🤓

+ + <% if version == "1" %> + <%= render "pages/v1_editor_guide_preamble" %> + <% else %> +

+ + Our editor has two versions. + If you prefer Jekyll-style "frontmatter", switch to "basic markdown" in + Settings → Customization. + +

+ + +
    +
  • Use markdown to write and format <%= community_name %> posts.
  • +
  • Most of the time, you can write inline HTML directly into your posts.
  • +
  • You can use Liquid tags to make add rich content such as tweets and videos.
  • +
  • Links to unpublished posts are shareable for feedback/review.
  • +
  • The best size for your cover image is 1000 X 420.
  • +
+ <% end %> + + +

Below are some examples of commonly used markdown syntax. If you want to dive deeper, check out + this cheat sheet. +

+ + <%= render partial: "editor_guide_h3", locals: { id: "markdown-bold-and-italic", title: "Bold & Italic" } %> +

Italics: *asterisks* or _underscores_

+

Bold: **double asterisks** or __double underscores__

+ + <%= render partial: "editor_guide_h3", locals: { id: "markdown-links", title: "Links" } %> +

I'm an inline link: [I'm an inline link](put-link-here)

+

Anchored links (For things like a Table of Contents)

+
+      ## Table Of Contents
+        * [Chapter 1](#chapter-1)
+        * [Chapter 2](#chapter-2)
+
+      ### Chapter 1 <%= "" %>
+    
+ + <%= render partial: "editor_guide_h3", locals: { id: "markdown-inline-images", title: "Inline Images" } %> +

+ When adding GIFs to posts and comments, please note that there is a limit of 200 megapixels per frame/page. + example image, with sloan +

+
![Image description](put-link-to-image-here)
+
+ example image, with sloan +
You can even add a caption using the HTML figcaption tag!
+
+ + <%= render partial: "editor_guide_h3", locals: { id: "markdown-headers", title: "Headings" } %> +

Add a heading to your post with this syntax:

+
# One '#' for a h1 heading
## Two '#'s for a h2 heading
...
###### Six '#'s for a h6 heading
+ + <%= render partial: "editor_guide_h3", locals: { id: "author-notes", title: "Author Notes/Comments" } %> +

Add some hidden notes/comments to your article with this syntax:

+
<!-- This won't show up in the content! -->
+ + +

People access online content in all kinds of different ways, and there are a few things you can do to make your posts more easily understood by a broad range of users. You can find out more about web accessibility at W3C's Introduction to Web Accessibility, but there are two main ways you can make your posts more accessible: providing alternative descriptions of any images you use, and adding appropriate headings.

+ + <%= render partial: "editor_guide_h3", locals: { id: "alt-text-for-images", title: "Providing alternative descriptions for images" } %> +

Some users might not be able to see or easily process images that you use in your posts. Providing an alternative description for an image helps make sure that everyone can understand your post, whether they can see the image or not.

+

When you upload an image in the editor, you will see the following text to copy and paste into your post:

+
![Image description](/file-path/my-image.png)
+

Replace the "Image description" in square brackets with a description of your image - for example:

+
![A pie chart showing 40% responded "Yes", 50% responded "No" and 10% responded "Not sure"](/file-path/my-image.png)
+

By doing this, if someone reads your post using an assistive device like a screen reader (which turns written content into spoken audio) they will hear the description you entered.

+ + <%= render partial: "editor_guide_h3", locals: { id: "accessible-headings", title: "Providing headings" } %> +

Headings provide an outline of your post to readers, including people who can't see the screen well. Many assistive technologies (like screen readers) allow users to skip directly to a particular heading, helping them find and understand the content of your post with ease.

+

Headings can be added in levels 1 - 6. Avoid using a level one heading (i.e., '# Heading text'). When you create a post, your post title automatically becomes a level one heading and serves a special role on the page, much like the headline of a newspaper article. Similar to how a newspaper article only has one headline, it can be confusing if multiple level one headings exist on a page.

+

In your post content, start with level two headings for each section (e.g. '## Section heading text'), and increase the heading level by one when you'd like to add a sub-section, for example:

+
## Fun facts about sloths

### Speed

Sloths move at a maximum speed of 0.27 km/h!
+ + <%= render partial: "liquid_tag_section_intro", locals: { styles: "font-size:2.8em;" } %> + + <%= render partial: "editor_guide_h3", locals: { id: "supported-url-embeds-list", title: "Supported URL Embeds" } %> + + <%= render partial: "supported_url_embeds_list" %> + + <%= render partial: "editor_guide_h3", locals: { id: "supported-nonurl-embeds-list", title: "Supported Non-URL Embeds" } %> + + <%= render partial: "supported_nonurl_embeds_list" %> + + <%= render partial: "editor_guide_h3", locals: { id: "parsing-liquid-tags-as-code-example", title: "Parsing Liquid Tags as a Code Example" } %> +

To parse Liquid tags as code, simply wrap it with a single backtick or triple backticks.

+
`{% mytag %}{{ site.SOMETHING }}{% endmytag %}`
+

One specific edge case is with using the raw tag. To properly escape it, use this format: +

+
`{% raw %}{{site.SOMETHING }} {% ``endraw`` %}`
+ + <%= render partial: "editor_guide_h3", locals: { id: "common-gotchas", title: "Common Gotchas" } %> +

+ Lists are written just like any other Markdown editor. + If you're adding an image in between numbered list, though, be sure to tab the image, + otherwise it'll restart the number of the list. + Here's an example of what to do: + example image of writing lists with images in Markdown +

+ +

+ + Here's the Markdown cheatsheet again for reference. + +

+ +

Happy posting! 📝

+
+
diff --git a/app/views/pages/_editor_liquid_help.html.erb b/app/views/pages/_editor_liquid_help.en.html.erb similarity index 100% rename from app/views/pages/_editor_liquid_help.html.erb rename to app/views/pages/_editor_liquid_help.en.html.erb diff --git a/app/views/pages/_editor_liquid_help.fr.html.erb b/app/views/pages/_editor_liquid_help.fr.html.erb new file mode 100644 index 000000000..37cff71a8 --- /dev/null +++ b/app/views/pages/_editor_liquid_help.fr.html.erb @@ -0,0 +1,76 @@ +
+
+

Supported URL Embeds

+ +
    +
  • <%= community_name %> Comment
  • +
  • <%= community_name %> Link
  • +
  • <%= community_name %> Link
  • +
  • <%= community_name %> Listing
  • +
  • <%= community_name %> Organization
  • +
  • <%= community_name %> Podcast Episode
  • +
  • <%= community_name %> Tag
  • +
  • <%= community_name %> User Profile
  • +
  • asciinema
  • +
  • CodePen
  • +
  • CodeSandbox
  • +
  • DotNetFiddle
  • +
  • GitHub Gist, Issue or Repository
  • +
  • Glitch
  • +
  • Instagram
  • +
  • JSFiddle
  • +
  • JSitor
  • +
  • Loom
  • +
  • Kotlin
  • +
  • Medium
  • +
  • Next Tech
  • +
  • Reddit
  • +
  • Replit
  • +
  • Slideshare
  • +
  • Speaker Deck
  • +
  • SoundCloud
  • +
  • Spotify
  • +
  • StackBlitz
  • +
  • Stackery
  • +
  • Stack Exchange or Stack Overflow
  • +
  • Twitch
  • +
  • Twitter
  • +
  • Twitter timeline
  • +
  • Wikipedia
  • +
  • Vimeo
  • +
  • YouTube
  • +
+ +
+ +

Supported Non-URL Embeds

+ +

Details

+

You can embed a details HTML element by using details, spoiler, or collapsible. The summary will be what the dropdown title displays. The content will be the text hidden behind the dropdown. This is great for when you want to hide text (i.e. answers to questions) behind a user action/intent (i.e. a click).

+

{% details summary %} content {% enddetails %}

+

{% spoiler summary %} content {% endspoiler %}

+

{% collapsible summary %} content {% endcollapsible %}

+ +

KaTex

+

Place your mathematical expression within a KaTeX liquid block, as follows:

+
{% katex %}
c = \pm\sqrt{a^2 + b^2}
{% endkatex %}
+

To render KaTeX inline add the "inline" option:

+
{% katex inline %}
c = \pm\sqrt{a^2 + b^2}
{% endkatex %}
+ +

RunKit

+

Put executable code within a runkit liquid block, as follows:

+
{% runkit
// hidden setup JavaScript code goes in this preamble area
const hiddenVar = 42
%}
// visible, reader-editable JavaScript code goes here
console.log(hiddenVar)
{% endrunkit %}
+ + <% if @user_approved_liquid_tags.include? UserSubscriptionTag %> +

<%= community_name %> User Subscriptions

+

This embed can only be created within posts by Admins.

+

You can add call-to-action text that will show above the subscribe button:

+ {% user_subscription If you'd like to receive future updates, subscribe below! %} +

+ If a reader is signed out, the button will prompt them to sign in first + to subscribe. If the reader is signed in, the button will prompt them + to subscribe. +

+ <% end %> +
+
diff --git a/app/views/pages/_editor_markdown_help.html.erb b/app/views/pages/_editor_markdown_help.en.html.erb similarity index 100% rename from app/views/pages/_editor_markdown_help.html.erb rename to app/views/pages/_editor_markdown_help.en.html.erb diff --git a/app/views/pages/_editor_markdown_help.fr.html.erb b/app/views/pages/_editor_markdown_help.fr.html.erb new file mode 100644 index 000000000..5749d6a97 --- /dev/null +++ b/app/views/pages/_editor_markdown_help.fr.html.erb @@ -0,0 +1,57 @@ +
+
+

Below are some examples of commonly used markdown syntax. If you want to dive deeper, check out + this cheat sheet. +

+ +

Bold & Italic

+

Italics: *asterisks* or _underscores_

+

Bold: **double asterisks** or __double underscores__

+ +

Links

+

I'm an inline link: [I'm an inline link](put-link-here)

+

Anchored links (For things like a Table of Contents)

+
+      ## Table Of Contents
+        * [Chapter 1](#chapter-1)
+        * [Chapter 2](#chapter-2)
+
+      ### Chapter 1 <%= "" %>
+    
+ +

Inline Images

+

+ When adding GIFs to posts and comments, please note that there is a limit of 200 megapixels per frame/page. + example image, with sloan +

+
![Image description](put-link-to-image-here)
+
You can even add a caption using the HTML figcaption tag!
+ +

Headers

+

Add a header to your post with this syntax:

+
# One '#' for a h1 header
## Two '#'s for a h2 header
...
###### Six '#'s for a h6 header
+

One '#' for a h1 header

+

Two '#'s for a h2 header

+

Three '#'s for a h3 header

+

Four '#'s for a h4 header

+
Five '#'s for a h5 header
+
Six '#'s for a h6 header
+ +

Author Notes/Comments

+

Add some hidden notes/comments to your article with this syntax:

+
<!-- This won't show up in the content! -->
+ +

Common Gotchas

+

+ Lists are written just like any other Markdown editor. + If you're adding an image in between numbered list, though, be sure to tab the image, + otherwise it'll restart the number of the list. + Here's an example of what to do: + example image of writing lists with images in Markdown +

+

+ Here's the Markdown cheatsheet again for reference. +

+
+
diff --git a/app/views/pages/_liquid_tag_section_intro.html.erb b/app/views/pages/_liquid_tag_section_intro.en.html.erb similarity index 100% rename from app/views/pages/_liquid_tag_section_intro.html.erb rename to app/views/pages/_liquid_tag_section_intro.en.html.erb diff --git a/app/views/pages/_liquid_tag_section_intro.fr.html.erb b/app/views/pages/_liquid_tag_section_intro.fr.html.erb new file mode 100644 index 000000000..5f2414fc0 --- /dev/null +++ b/app/views/pages/_liquid_tag_section_intro.fr.html.erb @@ -0,0 +1,8 @@ + +

+ We support native Liquid tags in our editor, but have created our own custom tags as well. A list of supported custom embeds appears below. To create a custom embed, use the complete URL:
+ {% embed https://... %} +

diff --git a/app/views/pages/_placeholder.html.erb b/app/views/pages/_placeholder.en.html.erb similarity index 100% rename from app/views/pages/_placeholder.html.erb rename to app/views/pages/_placeholder.en.html.erb diff --git a/app/views/pages/_placeholder.fr.html.erb b/app/views/pages/_placeholder.fr.html.erb new file mode 100644 index 000000000..c016f4edd --- /dev/null +++ b/app/views/pages/_placeholder.fr.html.erb @@ -0,0 +1,9 @@ +<% title "#{title} #{community_name}" %> + +
+
+

<%= title %>

+ +

The production <%= title %> page is a page generated at <%= admin_pages_path %>! This one is just a placeholder.

+
+
diff --git a/app/views/pages/_privacy_text.html.erb b/app/views/pages/_privacy_text.en.html.erb similarity index 100% rename from app/views/pages/_privacy_text.html.erb rename to app/views/pages/_privacy_text.en.html.erb diff --git a/app/views/pages/_privacy_text.fr.html.erb b/app/views/pages/_privacy_text.fr.html.erb new file mode 100644 index 000000000..6515311dc --- /dev/null +++ b/app/views/pages/_privacy_text.fr.html.erb @@ -0,0 +1,144 @@ +

Effective Dec 20, 2018

+

This policy covers <%= community_name %>.

+

What information <%= community_name %> collects and Why

+

In order to give you the best possible experience using <%= community_name %>, we collect information from your interactions with our network. We use common internet technologies, such as cookies and web server logs. We collect this basic information from everybody, whether they have an account or not.

+

The information we collect about all visitors to our website includes:

+ +

We use this information to:

+ +

In order for you to create an account on <%= community_name %> and use our Services, we need to collect and process certain information. Depending on your use of the Services, that may include:

+ +

Information Disclosure

+

We do not share, sell, rent, or trade User Personal Information with third parties for commercial purposes. +
+
+ We do share certain aggregated, non-personally identifying information with others about how our users, collectively, use <%= community_name %>. For example, we may share information pertaining to the popularity of different programming languages for advertising partners. +
+
+ We do host first-party advertising on <%= community_name %>. We do not run any code from advertisers and all ad images are hosted on managed <%= community_name %> servers. For more details, see our section on Advertising Details. +
+
+ We may use User Personal Information with your permission, so we can perform services you have authorized. +
+
+ We may share User Personal Information with a limited number of third party vendors who process it on our behalf to provide or improve our service, and who have agreed to privacy restrictions similar to our own Privacy Statement. Our third party vendors are listed below. +

+

Advertising Details

+

We target advertisements based solely upon:

+ +

We may place ads in:

+ +

All registered members have the ability to disable advertisements — where reasonable — through their Settings page. For instance, it’s not feasible to disable certain advertisements in the form of recognition posts, site-wide contests, dedicated sponsorship page, etc.

+

Third Party Vendors

+

+ We may share your account information with third parties in some circumstances, including: (1) with your consent; (2) to a service provider or partner who meets our data protection standards; (3) for survey or research purposes, after aggregation, anonymization, or pseudonymization; (4) when we have a good faith belief it is required by law, such as pursuant to a subpoena or other legal process; (5) when we have a good faith belief that doing so will help prevent imminent harm to someone. +

+

Data Storage +
+ <%= community_name %> uses third-party vendors and hosting partners for hardware, software, networking, storage, and related technology we need to run <%= community_name %>. By using <%= community_name %> Services, you authorize <%= community_name %> to transfer, store, and use your information in the United States and any other country where we operate. All service providers and third-party vendors are required to meet our data protection standards. +

+

Site monitoring +
+ <%= community_name %> uses a variety of third-party services to diagnose errors and improve the performance of our site. We aim to minimize the amount of personal information shared, but the information may include your IP address or other identifying information. All service providers and third-party vendors are required to meet our data protection standards. +

+

Payment processing +
+ <%= community_name %> does not process payments directly — we rely on third-party services such as Stripe, Shopify, and Paypal to receive payments and store any payment information. +

+

Third-Party Embeds +
+ Some of the content that you see displayed on <%= community_name %> is not hosted by <%= community_name %>. These + “embeds” are hosted by a third-party and embedded in <%= community_name %>. For example: YouTube videos, Codepens, + Twitter tweets, or GitHub code that appear within a <%= community_name %> post. These files send data to the hosted + site just as if you were visiting that site directly (for example, when you load a <%= community_name %> post page with + a YouTube video embedded in it, YouTube receives data about your activity). <%= community_name %> does not control what + data third parties collect in cases like this, or what they will do with it. Third-party embeds on <%= community_name %> + are not covered by this privacy policy; they are covered by the privacy policy of the third-party service. Be mindful + when interacting with these services. +

+

Tracking & Cookies +
+ We use browser cookies and similar technologies to recognize you when you return to our Services. Third-party vendors may also use cookies for various reasons. +
+
+ <%= community_name %> uses a specific cookie in order to facilitate the use of Google Universal Analytics for users + logged-in to the Applications or the Platforms (“Logged-In User). If you are a Logged-In User, <%= community_name %> + may use your <%= community_name %> user ID in combination with Google Universal Analytics and Google Analytics to track + and analyze the pages of the Services you visit. We do this only to better understand how you use the Website and the + other Services, with a view to offering improvements for all <%= community_name %> users; and to tailor our business + and marketing activities accordingly, both generally and specifically to you. Google Analytics cookies do not provide + <%= community_name %> with any Personal Information.You can prevent Google Analytics from recognizing you on return + visits to this site by disabling cookies on your browser. +
+
+ You may opt-out of this feature by installing the Google Analytics Opt-out Browser Add-on, by setting your web browser to refuse cookies, or by setting your browser to alert you when cookies are being sent. If you do so, note that some parts of the Site may not function properly. +

+

Data Security +
+ We use encryption (HTTPS/TLS) to protect data transmitted to and from our site. However, no data transmission over the Internet is 100% secure, so we can’t guarantee security. You use the Service at your own risk, and you’re responsible for taking reasonable measures to secure your account. +

+

Administrative Emails from <%= community_name %> +
+ Sometimes we’ll send you emails about your account, service changes or new policies. You can’t opt out of this type of “transactional” email (unless you delete your account). +
+
+ When you interact with a transactional email sent from <%= community_name %> (such as opening an email or clicking on a particular link in an email), we may receive information about that interaction. +

+

Non-administrative Emails from <%= community_name %> +
+ Upon creating a <%= community_name %> account, you will be opted into the <%= community_name %> Newsletter and other non-administrative email. Your email address and user profile information may be stored by a third-party email provider such as MailChimp or Sendgrid. You can opt out of non-administrative emails such as digests, newsletters, and activity notifications through your account’s “Settings” page and at the link of the footer in any non-administrative email you receive from us. +
+
+ When you interact with a non-administrative email sent from <%= community_name %> (such as opening an email or clicking on a particular link in an email), we may receive information about that interaction. +

+

Deleting Your Personal Information +
+ You may request deletion of your personal information and account by emailing <%= contact_link %>. +
+
+ To protect information from accidental or malicious destruction, we may maintain residual copies for a brief time period. But, if you delete your account, your information and content will be unrecoverable after that time. +

+

Data Portability +
+ If you would like to request a copy of your user data, please email <%= contact_link %>.

+

Business Transfers +
+ If we are involved in a merger, acquisition, bankruptcy, reorganization or sale of assets such that your information would be transferred or become subject to a different privacy policy, we’ll notify you in advance of any such change. +

+

Changes to this Policy +
+ We reserve the right to revise this Privacy Policy at any time. If we change this Privacy Policy in the future, we will post the revised Privacy Policy and update the “Effective Date,” above, to reflect the date of the changes. +

+

Questions +
+ We welcome feedback about this policy at <%= contact_link %>.

diff --git a/app/views/pages/_supported_nonurl_embeds_list.html.erb b/app/views/pages/_supported_nonurl_embeds_list.en.html.erb similarity index 100% rename from app/views/pages/_supported_nonurl_embeds_list.html.erb rename to app/views/pages/_supported_nonurl_embeds_list.en.html.erb diff --git a/app/views/pages/_supported_nonurl_embeds_list.fr.html.erb b/app/views/pages/_supported_nonurl_embeds_list.fr.html.erb new file mode 100644 index 000000000..910dc4486 --- /dev/null +++ b/app/views/pages/_supported_nonurl_embeds_list.fr.html.erb @@ -0,0 +1,31 @@ +<% @user_approved_liquid_tags = Users::ApprovedLiquidTags.call(@user) %> + +

Details

+

You can embed a details HTML element by using details, spoiler, or collapsible. The summary will be what the dropdown title displays. The content will be the text hidden behind the dropdown. This is great for when you want to hide text (i.e. answers to questions) behind a user action/intent (i.e. a click).

+
+  {% details summary %} content {% enddetails %}
+  {% spoiler summary %} content {% endspoiler %}
+  {% collapsible summary %} content {% endcollapsible %}
+
+ +

KaTex

+

Place your mathematical expression within a KaTeX liquid block, as follows:

+
{% katex %}
c = \pm\sqrt{a^2 + b^2}
{% endkatex %}
+

To render KaTeX inline add the "inline" option:

+
{% katex inline %}
c = \pm\sqrt{a^2 + b^2}
{% endkatex %}
+ +

RunKit

+

Put executable code within a runkit liquid block, as follows:

+
{% runkit
// hidden setup JavaScript code goes in this preamble area
const hiddenVar = 42
%}
// visible, reader-editable JavaScript code goes here
console.log(hiddenVar)
{% endrunkit %}
+ +<% if @user_approved_liquid_tags.include? UserSubscriptionTag %> +

<%= community_name %> User Subscriptions

+

This embed can only be created within posts by Admins.

+

You can add call-to-action text that will show above the subscribe button:

+ {% user_subscription If you'd like to receive future updates, subscribe below! %} +

+ If a reader is signed out, the button will prompt them to sign in first + to subscribe. If the reader is signed in, the button will prompt them + to subscribe. +

+<% end %> diff --git a/app/views/pages/_supported_url_embeds_list.html.erb b/app/views/pages/_supported_url_embeds_list.en.html.erb similarity index 100% rename from app/views/pages/_supported_url_embeds_list.html.erb rename to app/views/pages/_supported_url_embeds_list.en.html.erb diff --git a/app/views/pages/_supported_url_embeds_list.fr.html.erb b/app/views/pages/_supported_url_embeds_list.fr.html.erb new file mode 100644 index 000000000..66428143a --- /dev/null +++ b/app/views/pages/_supported_url_embeds_list.fr.html.erb @@ -0,0 +1,38 @@ + diff --git a/app/views/pages/_terms_text.html.erb b/app/views/pages/_terms_text.en.html.erb similarity index 100% rename from app/views/pages/_terms_text.html.erb rename to app/views/pages/_terms_text.en.html.erb diff --git a/app/views/pages/_terms_text.fr.html.erb b/app/views/pages/_terms_text.fr.html.erb new file mode 100644 index 000000000..234015de2 --- /dev/null +++ b/app/views/pages/_terms_text.fr.html.erb @@ -0,0 +1,140 @@ +

+ 1. Terms +

+ +

+ By accessing this web site, you are agreeing to be bound by these + web site Terms and Conditions of Use, our + ">Privacy Policy, all applicable laws and regulations, + and agree that you are responsible for compliance with any applicable local + laws. If you do not agree with any of these terms, you are prohibited from + using or accessing this site. The materials contained in this web site are + protected by applicable copyright and trade mark law. +

+ +

+ 2. Use License +

+ +
    +
  1. + Permission is granted to temporarily download one copy of the materials + (information or software) on <%= community_name %>'s web site for personal, + non-commercial transitory viewing only. This is the grant of a license, + not a transfer of title, and under this license you may not: + +
      +
    1. modify or copy the materials;
    2. +
    3. use the materials for any commercial purpose, or for any public display (commercial or non-commercial);
    4. +
    5. attempt to decompile or reverse engineer any software contained on <%= community_name %>'s web site;
    6. +
    7. remove any copyright or other proprietary notations from the materials; or
    8. +
    9. transfer the materials to another person or "mirror" the materials on any other server.
    10. +
    +
  2. +
  3. + This license shall automatically terminate if you violate any of these restrictions and may be terminated by <%= community_name %> at any time. Upon terminating your viewing of these materials or upon the termination of this license, you must destroy any downloaded materials in your possession whether in electronic or printed format. +
  4. +
+ +

+ 3. Disclaimer +

+ +
    +
  1. + The materials on <%= community_name %>'s web site are provided "as is". <%= community_name %> makes no warranties, expressed or implied, and hereby disclaims and negates all other warranties, including without limitation, implied warranties or conditions of merchantability, fitness for a particular purpose, or non-infringement of intellectual property or other violation of rights. + Further, <%= community_name %> does not warrant or make any representations concerning the accuracy, likely results, or reliability of the use of the materials on its Internet web site or otherwise relating to such materials or on any sites linked to this site. +
  2. +
+ +

+ 4. Limitations +

+ +

+ In no event shall <%= community_name %> or its suppliers be liable for any damages (including, without limitation, damages for loss of data or profit, or due to business interruption,) arising out of the use or inability to use the materials on <%= community_name %>'s Internet site, + even if <%= community_name %> or an authorized representative has been notified orally or in writing of the possibility of such damage. Because some jurisdictions do not allow limitations on implied warranties, or limitations of liability for consequential or incidental damages, these limitations may not apply to you. +

+ +

+ 5. Revisions and Errata +

+ +

+ The materials appearing on <%= community_name %>'s web site could include technical, typographical, or photographic errors. <%= community_name %> does not warrant that any of the materials on its web site are accurate, complete, or current. + <%= community_name %> may make changes to the materials contained on its web site at any time without notice. <%= community_name %> does not, however, make any commitment to update the materials. +

+ + + +

+ <%= community_name %> has not reviewed all of the sites linked to its Internet web site and is not responsible for the contents of any such linked site. The inclusion of any link does not imply endorsement by <%= community_name %> of the site. Use of any such linked web site is at the user's own risk. +

+ + + +

+ Users agree and certify that they have rights to share all content that they post on <%= community_name %> — including, but not limited to, information posted in articles, discussions, and comments. This rule applies to prose, code snippets, collections of links, etc. Regardless of citation, users may not post copy and pasted content that does not belong to them. Users assume all risk for the content they post, including someone else's reliance on its accuracy, claims relating to intellectual property, or other legal rights. If you believe that a user has plagiarized content, misrepresented their identity, misappropriated work, or otherwise run afoul of DMCA regulations, please email + <%= contact_link %>. <%= community_name %> may remove any content users post for any reason. +

+ +

+ 8. Site Terms of Use Modifications +

+ +

+ <%= community_name %> may revise these terms of use for its web site at any time without notice. By using this web site you are agreeing to be bound by the then current version of these Terms and Conditions of Use. +

+ +

+ 9. <%= community_name %> Trademarks and Logos Policy +

+ +

+ All uses of the <%= community_name %> logo, <%= community_name %> badges, brand slogans, iconography, and the like, may only be used with express permission from <%= community_name %>. + <%= community_name %> reserves all rights, even if certain assets are included in <%= community_name %> open source projects. Please contact <%= contact_link %> with any questions or to request permission. +

+ +

+ 10. Reserved Names +

+ +

+ <%= community_name %> has the right to maintain a list of reserved names which will not be made publicly available. These reserved names may be set aside for purposes of proactive trademark protection, avoiding user confusion, security measures, or any other reason (or no reason). +

+ +

+ Additionally, <%= community_name %> reserves the right to change any already-claimed name at its sole discretion. In such cases, <%= community_name %> will make reasonable effort to find a suitable alternative and assist with any transition-related concerns. +

+ +

+ 11. Content Policy +

+ +

+ The following policy applies to comments, articles, and all other works shared on the <%= community_name %> platform: +

+

+ +

+ <%= community_name %> reserves the right to remove any content that it deems to be in violation of this policy at its sole discretion. Additionally, <%= community_name %> reserves the right to restrict any user’s ability to participate on the platform at its sole discretion. +

+ +

+ 12. Governing Law +

+ +

+ Any claim relating to <%= community_name %>'s web site shall be governed by the laws of the State of New York without regard to its conflict of law provisions. +

+ +

+ General Terms and Conditions applicable to Use of a Web Site. +

diff --git a/app/views/pages/_v1_editor_guide_preamble.html.erb b/app/views/pages/_v1_editor_guide_preamble.en.html.erb similarity index 100% rename from app/views/pages/_v1_editor_guide_preamble.html.erb rename to app/views/pages/_v1_editor_guide_preamble.en.html.erb diff --git a/app/views/pages/_v1_editor_guide_preamble.fr.html.erb b/app/views/pages/_v1_editor_guide_preamble.fr.html.erb new file mode 100644 index 000000000..8d3cf65a7 --- /dev/null +++ b/app/views/pages/_v1_editor_guide_preamble.fr.html.erb @@ -0,0 +1,34 @@ + +

Things to Know<%= crayons_icon_tag("small-link", aria_hidden: true) %>

+ + +

We have two editor versions. If you'd prefer to edit title and tags etc. as separate fields, switch to the "rich + markdown" option in Settings → Customization. Otherwise, continue:

+ + +

Custom variables set for each post, located between the triple-dashed lines in your editor Here is a list of possibilities:

+ diff --git a/app/views/pages/about.html.erb b/app/views/pages/about.en.html.erb similarity index 100% rename from app/views/pages/about.html.erb rename to app/views/pages/about.en.html.erb diff --git a/app/views/pages/about.fr.html.erb b/app/views/pages/about.fr.html.erb new file mode 100644 index 000000000..3d645fb98 --- /dev/null +++ b/app/views/pages/about.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "About" } %> diff --git a/app/views/pages/about_listings.html.erb b/app/views/pages/about_listings.en.html.erb similarity index 100% rename from app/views/pages/about_listings.html.erb rename to app/views/pages/about_listings.en.html.erb diff --git a/app/views/pages/about_listings.fr.html.erb b/app/views/pages/about_listings.fr.html.erb new file mode 100644 index 000000000..a442e1e63 --- /dev/null +++ b/app/views/pages/about_listings.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "About #{community_name} Listings" } %> diff --git a/app/views/pages/bounty.html.erb b/app/views/pages/bounty.en.html.erb similarity index 100% rename from app/views/pages/bounty.html.erb rename to app/views/pages/bounty.en.html.erb diff --git a/app/views/pages/bounty.fr.html.erb b/app/views/pages/bounty.fr.html.erb new file mode 100644 index 000000000..5e6823716 --- /dev/null +++ b/app/views/pages/bounty.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "Reporting Vulnerabilities" } %> diff --git a/app/views/pages/code_of_conduct.html.erb b/app/views/pages/code_of_conduct.en.html.erb similarity index 100% rename from app/views/pages/code_of_conduct.html.erb rename to app/views/pages/code_of_conduct.en.html.erb diff --git a/app/views/pages/code_of_conduct.fr.html.erb b/app/views/pages/code_of_conduct.fr.html.erb new file mode 100644 index 000000000..e9f488238 --- /dev/null +++ b/app/views/pages/code_of_conduct.fr.html.erb @@ -0,0 +1,22 @@ +<% title "#{community_name} Code of Conduct" %> + +<%= content_for :page_meta do %> + + + <%= meta_keywords_default %> + + + + + + + "> + +<% end %> + +
+
+

Code of Conduct

+ <%= Page.render_safe_html_for(slug: Page::CODE_OF_CONDUCT_SLUG) { render "pages/coc_text" } %> +
+
diff --git a/app/views/pages/community_moderation.html.erb b/app/views/pages/community_moderation.en.html.erb similarity index 100% rename from app/views/pages/community_moderation.html.erb rename to app/views/pages/community_moderation.en.html.erb diff --git a/app/views/pages/community_moderation.fr.html.erb b/app/views/pages/community_moderation.fr.html.erb new file mode 100644 index 000000000..b44b9507d --- /dev/null +++ b/app/views/pages/community_moderation.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "Community Moderation Guide" } %> diff --git a/app/views/pages/contact.html.erb b/app/views/pages/contact.en.html.erb similarity index 100% rename from app/views/pages/contact.html.erb rename to app/views/pages/contact.en.html.erb diff --git a/app/views/pages/contact.fr.html.erb b/app/views/pages/contact.fr.html.erb new file mode 100644 index 000000000..778f802dc --- /dev/null +++ b/app/views/pages/contact.fr.html.erb @@ -0,0 +1,45 @@ +<% title "Contact #{community_name}" %> + +<%= content_for :page_meta do %> + " /> + + <%= meta_keywords_default %> + + + " /> + + + + + + + "> + + + +<% end %> + +
+
+

Contacts

+ +

+ <%= community_name %> would love to hear from you! +

+

+ Email: <%= contact_link %> 😁 +

+

+ Twitter: ">@<%= Settings::General.social_media_handles["twitter"] %> 👻 +

+

+ Report a vulnerability: dev.to/security 🐛 +

+

+ To report a bug, please create a bug report in our open source repository. +

+

+ To request a feature, please start a new GitHub Discussion in the Forem repo! +

+
+
diff --git a/app/views/pages/editor_guide.html.erb b/app/views/pages/editor_guide.en.html.erb similarity index 100% rename from app/views/pages/editor_guide.html.erb rename to app/views/pages/editor_guide.en.html.erb diff --git a/app/views/pages/editor_guide.fr.html.erb b/app/views/pages/editor_guide.fr.html.erb new file mode 100644 index 000000000..491b1c946 --- /dev/null +++ b/app/views/pages/editor_guide.fr.html.erb @@ -0,0 +1,10 @@ +<% title "Editor Guide" %> + +<%= content_for :page_meta do %> + " /> + + <%= meta_keywords_default %> +<% end %> + +
+<%= render "editor_guide_text", version: "1" %> diff --git a/app/views/pages/faq.html.erb b/app/views/pages/faq.en.html.erb similarity index 100% rename from app/views/pages/faq.html.erb rename to app/views/pages/faq.en.html.erb diff --git a/app/views/pages/faq.fr.html.erb b/app/views/pages/faq.fr.html.erb new file mode 100644 index 000000000..9f7a77c0a --- /dev/null +++ b/app/views/pages/faq.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "FAQ" } %> diff --git a/app/views/pages/forbidden.html.erb b/app/views/pages/forbidden.en.html.erb similarity index 100% rename from app/views/pages/forbidden.html.erb rename to app/views/pages/forbidden.en.html.erb diff --git a/app/views/pages/forbidden.fr.html.erb b/app/views/pages/forbidden.fr.html.erb new file mode 100644 index 000000000..5a13c529c --- /dev/null +++ b/app/views/pages/forbidden.fr.html.erb @@ -0,0 +1,8 @@ +

Forbidden

+ +

+ Your account has been suspended and has limited access. + Your ability to post and comment may be limited. +

+ +

For more information, you may send a message to <%= contact_link %>.

diff --git a/app/views/pages/markdown_basics.html.erb b/app/views/pages/markdown_basics.en.html.erb similarity index 100% rename from app/views/pages/markdown_basics.html.erb rename to app/views/pages/markdown_basics.en.html.erb diff --git a/app/views/pages/markdown_basics.fr.html.erb b/app/views/pages/markdown_basics.fr.html.erb new file mode 100644 index 000000000..0a8c8a391 --- /dev/null +++ b/app/views/pages/markdown_basics.fr.html.erb @@ -0,0 +1,62 @@ +<% title "Markdown Basics" %> + +<%= content_for :page_meta do %> + " /> + + <%= meta_keywords_default %> +<% end %> + +
+
+

Markdown Basics 🤓

+ +

Below are some examples of commonly used markdown syntax. If you want to dive deeper, check out + this cheat sheet. +

+ +

Bold & Italic

+

Italics: *asterisks* or _underscores_

+

Bold: **double asterisks** or __double underscores__

+ +

Links

+

I'm an inline link: [I'm an inline link](put-link-here)

+ +

Inline Images

+

+ example image, with sloan + ![Image description](put-link-to-image-here) +

+ +

Headers

+

Add a header to your post with this syntax:

+
+      
#One '#' for a h1 header
##Two '#'s for a h2 header
...
######Six '#'s for a h6 header
+
+

One '#' for a h1 header

+

Two '#'s for a h2 header

+
Six '#'s for a h6 header
+ +
+ + <%= render partial: "liquid_tag_section_intro", locals: { styles: "font-size:2.4em;" } %> + + <%= render partial: "editor_guide_h3", locals: { id: "supported-url-embeds-list", title: "Supported URL Embeds" } %> + + <%= render partial: "supported_url_embeds_list" %> + + <%= render partial: "editor_guide_h3", locals: { id: "supported-nonurl-embeds-list", title: "Supported Non-URL Embeds" } %> + + <%= render partial: "supported_nonurl_embeds_list" %> + +

Parsing Liquid Tags as a Code Example

+

To parse Liquid tags as code, simply wrap it with a single backtick or triple backticks.

+

`{% mytag %}{{ site.SOMETHING }}{% endmytag %}`

+

One specific edge case is with using the raw tag. To properly escape it, use this format:

+

`{% raw %}{{site.SOMETHING }} {% ``endraw`` %}`

+ +

+ Here's the Markdown cheatsheet again for reference. +

+ Happy posting! 📝 +
+
diff --git a/app/views/pages/post_a_job.html.erb b/app/views/pages/post_a_job.en.html.erb similarity index 100% rename from app/views/pages/post_a_job.html.erb rename to app/views/pages/post_a_job.en.html.erb diff --git a/app/views/pages/post_a_job.fr.html.erb b/app/views/pages/post_a_job.fr.html.erb new file mode 100644 index 000000000..cf8fb3447 --- /dev/null +++ b/app/views/pages/post_a_job.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "Posting a Job on #{community_name} Listings" } %> diff --git a/app/views/pages/privacy.html.erb b/app/views/pages/privacy.en.html.erb similarity index 100% rename from app/views/pages/privacy.html.erb rename to app/views/pages/privacy.en.html.erb diff --git a/app/views/pages/privacy.fr.html.erb b/app/views/pages/privacy.fr.html.erb new file mode 100644 index 000000000..ef46d9f1c --- /dev/null +++ b/app/views/pages/privacy.fr.html.erb @@ -0,0 +1,27 @@ +<% title("Privacy Policy for #{community_name}") %> + +<%= content_for :page_meta do %> + " /> + + <%= meta_keywords_default %> + + + " /> + + + + + + + "> + + + +<% end %> + +
+
+

Privacy Policy

+ <%= render "privacy_text" %> +
+
diff --git a/app/views/pages/publishing_from_rss_guide.html.erb b/app/views/pages/publishing_from_rss_guide.en.html.erb similarity index 100% rename from app/views/pages/publishing_from_rss_guide.html.erb rename to app/views/pages/publishing_from_rss_guide.en.html.erb diff --git a/app/views/pages/publishing_from_rss_guide.fr.html.erb b/app/views/pages/publishing_from_rss_guide.fr.html.erb new file mode 100644 index 000000000..d923e9da6 --- /dev/null +++ b/app/views/pages/publishing_from_rss_guide.fr.html.erb @@ -0,0 +1,46 @@ +<% title "Editor Guide - Publishing from RSS or Atom" %> + +<%= content_for :page_meta do %> + + + <%= meta_keywords_default %> +<% end %> + +
+
+

Publishing from RSS or Atom

+
+ +
+

Front Matter

+ +

Our feed reader converts some elements from the RSS or Atom feeds to tags for the editor's front matter:

+
    +
  • + <title>: title, the title of the post +
  • + +
  • + <category>: tags, only the first four <category> elements + can be used in a post on <%= community_name %> per each item in the feed. +
  • + +
  • + <link>: canonical_url, only used if the "Mark the RSS source as canonical URL by default" + option is enabled in the <%= link_to "RSS Settings", user_settings_path(:extensions) %>. +
  • +
+ +

Post Content

+ +

+ The post content is prioritized in this order: <content>, <summary>, or + <description>. +

+ +

The HTML will be converted to Markdown as the body of the <%= community_name %> post.

+ +

If you're using Medium RSS feed all its tweet links, YouTube, and Gist iframes will be converted to Liquid tags.

+
+
+
diff --git a/app/views/pages/report_abuse.html.erb b/app/views/pages/report_abuse.en.html.erb similarity index 100% rename from app/views/pages/report_abuse.html.erb rename to app/views/pages/report_abuse.en.html.erb diff --git a/app/views/pages/report_abuse.fr.html.erb b/app/views/pages/report_abuse.fr.html.erb new file mode 100644 index 000000000..76c78a109 --- /dev/null +++ b/app/views/pages/report_abuse.fr.html.erb @@ -0,0 +1,29 @@ +<% title t("core.report_abuse") %> +<%= content_for :page_meta do %> + " /> + "> + <%= meta_keywords_default %> + + + " /> + " /> + + + "> + "> +<% end %> + +
+
+

<%= t("core.report_abuse") %>

+ +

+ Thank you for reporting any abuse that violates our code of conduct or + terms and conditions. We continue to try to make this environment a great one for everybody. +

+ +
+ <%= render "feedback_messages/form", feedback_message: @feedback_message %> +
+
+
diff --git a/app/views/pages/show.html.erb b/app/views/pages/show.en.html.erb similarity index 100% rename from app/views/pages/show.html.erb rename to app/views/pages/show.en.html.erb diff --git a/app/views/pages/show.fr.html.erb b/app/views/pages/show.fr.html.erb new file mode 100644 index 000000000..52f122524 --- /dev/null +++ b/app/views/pages/show.fr.html.erb @@ -0,0 +1,44 @@ +<% title @page.title %> +<%= content_for :page_meta do %> + + + <%= meta_keywords_default %> + + + + + + + + + + "> + + + +<% end %> + +
+ <% if @page.template == "contained" %> +
+
+

<%= @page.title %>

+ + <%= @page.processed_html.html_safe %> +
+
+ <% elsif @page.template == "nav_bar_included" %> +
+ +
+

<%= @page.title %>

+ <%= @page.processed_html.html_safe %> +
+
+ <% else %> + <%= @page.processed_html.html_safe %> + <% end %> +
+
diff --git a/app/views/pages/tag_moderation.html.erb b/app/views/pages/tag_moderation.en.html.erb similarity index 100% rename from app/views/pages/tag_moderation.html.erb rename to app/views/pages/tag_moderation.en.html.erb diff --git a/app/views/pages/tag_moderation.fr.html.erb b/app/views/pages/tag_moderation.fr.html.erb new file mode 100644 index 000000000..c6aba09e2 --- /dev/null +++ b/app/views/pages/tag_moderation.fr.html.erb @@ -0,0 +1 @@ +<%= render partial: "placeholder", locals: { title: "Tag Moderation Guide" } %> diff --git a/app/views/pages/terms.html.erb b/app/views/pages/terms.en.html.erb similarity index 100% rename from app/views/pages/terms.html.erb rename to app/views/pages/terms.en.html.erb diff --git a/app/views/pages/terms.fr.html.erb b/app/views/pages/terms.fr.html.erb new file mode 100644 index 000000000..2906b84ab --- /dev/null +++ b/app/views/pages/terms.fr.html.erb @@ -0,0 +1,27 @@ +<% title("Terms of Use for #{community_name}") %> + +<%= content_for :page_meta do %> + " /> + + <%= meta_keywords_default %> + + + " /> + + + + + + + "> + + + +<% end %> + +
+
+

Web Site Terms and Conditions of Use

+ <%= Page.render_safe_html_for(slug: Page::TERMS_SLUG) { render "terms_text" } %> +
+
diff --git a/config/locales/views/credits/en.yml b/config/locales/views/credits/en.yml index 4a6a23f1a..620b6befb 100644 --- a/config/locales/views/credits/en.yml +++ b/config/locales/views/credits/en.yml @@ -19,6 +19,9 @@ en: meta: title: Purchase Credits heading: Purchase credits for @%{name} + hook: + text_html: Credits are used for %{listings} as well as upcoming products and services. + listings: "%{community} listings" form: amount: label: Amount to Purchase diff --git a/config/locales/views/credits/fr.yml b/config/locales/views/credits/fr.yml index a208419fe..111ea9a39 100644 --- a/config/locales/views/credits/fr.yml +++ b/config/locales/views/credits/fr.yml @@ -19,6 +19,9 @@ fr: meta: title: Purchase Credits heading: Purchase credits for @%{name} + hook: + text_html: Credits are used for %{listings} as well as upcoming products and services. + listings: "%{community} listings" form: amount: label: Amount to Purchase