Add Japanese translations from @mitixx

Co-Authored-By: 未知 <mitixx@users.noreply.github.com>
i18n
Jed Fox 7 years ago
parent 0873162a7a
commit ace8f4775d

@ -1,55 +1,100 @@
error = (title, text = '', links = '') ->
text = """<p class="_error-text">#{text}</p>""" if text
links = """<p class="_error-links">#{links}</p>""" if links
"""<div class="_error"><h1 class="_error-title">#{title}</h1>#{text}#{links}</div>"""
text = """<p class="_error-text">#{_ text}</p>""" if text
links = """<p class="_error-links">#{_ links}</p>""" if links
"""<div class="_error"><h1 class="_error-title">#{_ title}</h1>#{text}#{links}</div>"""
back = '<a href="#" data-behavior="back" class="_error-link">Go back</a>'
back = -> "<a href='#' data-behavior='back' class='_error-link'>#{_ en: 'Go back', ja: '戻る'}</a>"
app.templates.notFoundPage = ->
error """ Page not found. """,
""" It may be missing from the source documentation or this could be a bug. """,
back
error(
en: """ Page not found. """
ja: """ ページが見つかりません。 """,
,
en: """ It may be missing from the source documentation or this could be a bug. """
ja: """ ドキュメントソースを誤っているか、バグかもしれません。 """,
,
back()
)
app.templates.pageLoadError = ->
error """ The page failed to load. """,
""" It may be missing from the server (try reloading the app) or you could be offline.<br>
If you keep seeing this, you're likely behind a proxy or firewall that blocks cross-domain requests. """,
""" #{back} &middot; <a href="/##{location.pathname}" target="_top" class="_error-link">Reload</a>
&middot; <a href="#" class="_error-link" data-retry>Retry</a> """
error(
en: """ The page failed to load. """
ja: """ ページの読み込みが失敗しました。 """
,
en: """ It may be missing from the server (try reloading the app) or you could be offline.<br>
If you keep seeing this, you're likely behind a proxy or firewall that blocks cross-domain requests. """
ja: """ サーバーを誤っています。(アプリを再度読み込んでください)または、オフラインです。<br>
"""
,
""" #{back()}
&middot;
<a href="/##{location.pathname}" target="_top" class="_error-link">
#{_ en: 'Reload', ja: '再読み込み'}
</a>
&middot;
<a href="#" class="_error-link" data-retry>Retry</a> """
)
app.templates.bootError = ->
error """ The app failed to load. """,
""" Check your Internet connection and try <a href="#" data-behavior="reload">reloading</a>.<br>
error(
en: """ The app failed to load. """
ja: """ アプリの読み込みに失敗しました。 """
,
en: """ Check your Internet connection and try <a href="#" data-behavior="reload">reloading</a>.<br>
If you keep seeing this, you're likely behind a proxy or firewall that blocks cross-domain requests. """
ja: """ インターネット接続を確認してください。<a href="#" data-behavior="reload">再読み込み</a>してください。<br>
"""
)
app.templates.offlineError = (reason, exception) ->
if reason is 'cookie_blocked'
return error """ Cookies must be enabled to use offline mode. """
return error(
en: """ Cookies must be enabled to use offline mode. """
ja: """ オフラインモードを使用してクッキーを有効にする必要があります。 """
)
reason = switch reason
when 'not_supported'
""" DevDocs requires IndexedDB to cache documentations for offline access.<br>
en: """ DevDocs requires IndexedDB to cache documentations for offline access.<br>
Unfortunately your browser either doesn't support IndexedDB or doesn't make it available. """
ja: """DevDocsはオフラインアクセスのために、IndexedDBにキャッシュすることを要求しています。<br>
使IndexedDB"""
when 'buggy'
""" DevDocs requires IndexedDB to cache documentations for offline access.<br>
en: """ DevDocs requires IndexedDB to cache documentations for offline access.<br>
Unfortunately your browser's implementation of IndexedDB contains bugs that prevent DevDocs from using it. """
ja: """ DevDocsはオフラインアクセスのために、IndexedDBにキャッシュすることを要求しています。<br>
使IndexedDB contains"""
when 'private_mode'
""" Your browser appears to be running in private mode.<br>
en: """ Your browser appears to be running in private mode.<br>
This prevents DevDocs from caching documentations for offline access."""
ja: """ ブラウザのプライベートモードで表示しています。<br>
"""
when 'exception', 'cant_open'
""" An error occurred when trying to open the IndexedDB database:<br>
<code class="_label">#{exception.name}: #{exception.message}</code>#{"""<br>
en: """ An error occurred when trying to open the IndexedDB database:<br>
<code class="_label">#{exception.name}: #{exception.message}</code>
#{if reason is 'cant_open' then """<br>
This could be because you're browsing in private mode or have disallowed offline storage on the domain.
""" if reason is 'cant_open' else ''} """
""" else ''} """
ja: """ IndexDBデータベースを開く際にエラーが起きています:<br>
<code class="_label">#{exception.name}: #{exception.message}</code>
#{if reason is 'cant_open' then """<br>
使
""" else ''} """
when 'version'
""" The IndexedDB database was modified with a newer version of the app.<br>
en: """ The IndexedDB database was modified with a newer version of the app.<br>
<a href="#" data-behavior="reload">Reload the page</a> to use offline mode. """
ja: """ IndexedDBデータベースはアプリの新しいバージョンに修正されています。<br>
<a href="#" data-behavior="reload"></a> 使 """
when 'empty'
""" The IndexedDB database appears to be corrupted. Try <a href="#" data-behavior="reset">resetting the app</a>. """
en: """ The IndexedDB database appears to be corrupted. Try <a href="#" data-behavior="reset">resetting the app</a>. """
ja: """IndexedDBデータベースに誤りがあります。 <a href="#" data-behavior="reset">アプリをリセット</a>してみてください。 """
error 'Offline mode is unavailable.', reason
app.templates.unsupportedBrowser = """
app.templates.unsupportedBrowser =
en: """
<div class="_fail">
<h1 class="_fail-title">Your browser is unsupported, sorry.</h1>
<p class="_fail-text">DevDocs is an API documentation browser which supports the following browsers:
@ -71,4 +116,27 @@ app.templates.unsupportedBrowser = """
<p class="_fail-text">
&mdash; Thibaut <a href="https://twitter.com/DevDocs" class="_fail-link">@DevDocs</a>
</div>
"""
"""
ja: """
<div class="_fail">
<h1 class="_fail-title">使</h1>
<p class="_fail-text">DevDocs:
<ul class="_fail-list">
<li>Chrome Firefox 
<li>Safari 5.1
<li>Opera 12.1 
<li>Internet Explorer 10 
<li>iOS 6
<li>Android 4.1
<li>Windows Phone 8 
</ul>
<p class="_fail-text">
<p class="_fail-text">
使
<p class="_fail-text">
&mdash; Thibaut <a href="https://twitter.com/DevDocs" class="_fail-link">@DevDocs</a>
</div>
"""

@ -1,9 +1,15 @@
notice = (text) -> """<p class="_notice-text">#{_ text}</p>"""
app.templates.singleDocNotice = (doc) ->
notice """ You're browsing the #{doc.fullName} documentation. To browse all docs, go to
notice
en: """ You're browsing the #{doc.fullName} documentation. To browse all docs, go to
<a href="//#{app.config.production_host}" target="_top">#{app.config.production_host}</a> (or press <code>esc</code>). """
ja: """ #{doc.fullName} をブラウズしています。すべてのドキュメントを見るには
<a href="//#{app.config.production_host}" target="_top">#{app.config.production_host}</a> (<code>esc</code>) """
app.templates.disabledDocNotice = ->
notice """ <strong>This documentation is disabled.</strong>
notice
en: """ <strong>This documentation is disabled.</strong>
To enable it, go to <a href="/settings" class="_notice-link">Preferences</a>. """
ja: """ <strong>このドキュメントは無効です。</strong>
<a href="/settings" class="_notice-link"></a>."""

@ -1,38 +1,66 @@
notif = (title, html) ->
close = _ en: 'Close', ja: '閉じる'
html = html.replace /<a /g, '<a class="_notif-link" '
""" <h5 class="_notif-title">#{_ title}</h5>
#{html}
<button type="button" class="_notif-close" title="Close"><svg><use xlink:href="#icon-close"/></svg>Close</a>
<button type="button" class="_notif-close" title="#{close}"><svg><use xlink:href="#icon-close"/></svg>#{close}</a>
"""
textNotif = (title, message) ->
notif title, """<p class="_notif-text">#{_ message}"""
app.templates.notifUpdateReady = ->
textNotif """<span data-behavior="reboot">DevDocs has been updated.</span>""",
"""<span data-behavior="reboot"><a href="#" data-behavior="reboot">Reload the page</a> to use the new version.</span>"""
textNotif
en: """<span data-behavior="reboot">DevDocs has been updated.</span>"""
ja: """<span data-behavior="reboot">DevDocsはアップデートされました。</span>"""
,
en: """<span data-behavior="reboot"><a href="#" data-behavior="reboot">Reload the page</a> to use the new version.</span>"""
ja: """<span data-behavior="reboot"><a href="#" data-behavior="reboot">ページ再読み込み</a> すると新しいバージョンが使用できます。</span>"""
app.templates.notifError = ->
textNotif """ Oops, an error occurred. """,
""" Try <a href="#" data-behavior="hard-reload">reloading</a>, and if the problem persists,
textNotif
en: """ Oops, an error occurred. """
ja: """ しまった、エラーが発生しました。 """
,
en: """ Try <a href="#" data-behavior="hard-reload">reloading</a>, and if the problem persists,
<a href="#" data-behavior="reset">resetting the app</a>.<br>
You can also report this issue on <a href="https://github.com/freeCodeCamp/devdocs/issues/new" target="_blank" rel="noopener">GitHub</a>. """
ja: """ <a href="#" data-behavior="hard-reload">再読み込み</a>してみてください。それでも問題が起きる場合は、
<a href="#" data-behavior="reset"></a><br>
<a href="https://github.com/freeCodeCamp/devdocs/issues/new" target="_blank" rel="noopener">GitHub</a> """
app.templates.notifQuotaExceeded = ->
textNotif """ The offline database has exceeded its size limitation. """,
""" Unfortunately this quota can't be detected programmatically, and the database can't be opened while over the quota, so it had to be reset. """
textNotif
en: """ The offline database has exceeded its size limitation. """
ja: """ オフラインデータベースはサイズ制限を超過しました。 """
,
en: """ Unfortunately this quota can't be detected programmatically, and the database can't be opened while over the quota, so it had to be reset. """
ja: """ あいにく、この制限を検出するようプログラムできません。また、データベースは制限を超えて開くことができません。そのため、リセットを行ってください。"""
app.templates.notifCookieBlocked = ->
textNotif """ Please enable cookies. """,
""" DevDocs will not work properly if cookies are disabled. """
textNotif
en: """ Please enable cookies. """
ja: """ クッキーを有効にしてください。"""
,
en: """ DevDocs will not work properly if cookies are disabled. """
ja: """ クッキーが無効な場合、DevDocsは正確に動きません。"""
app.templates.notifInvalidLocation = ->
textNotif """ DevDocs must be loaded from #{app.config.production_host} """,
""" Otherwise things are likely to break. """
textNotif
en: """ DevDocs must be loaded from #{app.config.production_host} """
ja: """ DevDocsは#{app.config.production_host}から読み込む必要があります。 """
,
en: """ Otherwise things are likely to break. """
ja: """ さもないと故障してしまうかもしれません。"""
app.templates.notifImportInvalid = ->
textNotif """ Oops, an error occurred. """,
""" The file you selected is invalid. """
textNotif
en: """ Oops, an error occurred. """
ja: """ しまった、エラーが発生しました。"""
,
en: """ The file you selected is invalid. """
ja: """ 選択したファイルは無効です。 """
app.templates.notifNews = (news) ->
notif 'Changelog', """<div class="_notif-content _notif-news">#{app.templates.newsList(news, years: false)}</div>"""
@ -60,11 +88,21 @@ app.templates.notifUpdates = (docs, disabledDocs) ->
notif 'Updates', "#{html}</div>"
app.templates.notifShare = ->
textNotif """ Hi there! """,
""" Like DevDocs? Help us reach more developers by sharing the link with your friends on
textNotif
en: """ Hi there! """
ja: """ ようこそ! """
,
en: """ Like DevDocs? Help us reach more developers by sharing the link with your friends on
<a href="https://out.devdocs.io/s/tw" target="_blank" rel="noopener">Twitter</a>, <a href="https://out.devdocs.io/s/fb" target="_blank" rel="noopener">Facebook</a>,
<a href="https://out.devdocs.io/s/re" target="_blank" rel="noopener">Reddit</a>, etc.<br>Thanks :) """
ja: """ DevDocsは気に入りましたか? さらに開発者に知ってもらえるよう、友人などにシェアしていただけませんか。
<a href="https://out.devdocs.io/s/tw" target="_blank" rel="noopener">Twitter</a>, <a href="https://out.devdocs.io/s/fb" target="_blank" rel="noopener">Facebook</a>,
<a href="https://out.devdocs.io/s/re" target="_blank" rel="noopener">Reddit</a><br>:) """
app.templates.notifUpdateDocs = ->
textNotif """ Documentation updates available. """,
""" <a href="/offline">Install them</a> as soon as possible to avoid broken pages. """
textNotif
en: """ Documentation updates available. """
ja: """ ドキュメントのアップデートが入手可能です。 """
,
en: """ <a href="/offline">Install them</a> as soon as possible to avoid broken pages. """
ja: """ <a href="/offline">インストールする</a> aとすぐに可能になり、壊れたページを回避できます。 """

@ -1,4 +1,5 @@
app.templates.aboutPage = -> """
app.templates.aboutPage =
en: """
<nav class="_toc" role="directory">
<h3 class="_toc-title">Table of Contents</h3>
<ul class="_toc-list">
@ -70,7 +71,7 @@ app.templates.aboutPage = -> """
<th>Documentation
<th>Copyright
<th>License
#{("<tr><td>#{c[0]}<td>&copy; #{c[1]}<td><a href=\"#{c[3]}\">#{c[2]}</a>" for c in credits).join('')}
#{credit_table}
</table>
</div>
@ -83,7 +84,86 @@ app.templates.aboutPage = -> """
<li>By using the app, you signify your acceptance of this policy. If you do not agree to this policy, please do not use the app.
<li>If you have any questions regarding privacy, please email <a href="mailto:thibaut@devdocs.io">thibaut@devdocs.io</a>.
</ul>
"""
"""
ja: """
<nav class="_toc" role="directory">
<h3 class="_toc-title"></h3>
<ul class="_toc-list">
<li><a href="#copyright"></a>
<li><a href="#plugins"></a>
<li><a href="#faq">FAQ</a>
<li><a href="#credits">Credits</a>
<li><a href="#privacy"></a>
</ul>
</nav>
<h1 class="_lined-heading">DevDocs: API  </h1>
<p>DevDocs便APIwebUI</p>
<p>DevDocs combines multiple API documentations in a clean and organized web UI with instant search, offline support, mobile version, dark theme, keyboard shortcuts, and more.
<ul>
<li> <a href="https://thibaut.me">Thibaut Courouble</a>
<li><a href="https://github.com/freeCodeCamp/devdocs"></a>
<iframe class="_github-btn" src="https://ghbtns.com/github-btn.html?user=freeCodeCamp&repo=devdocs&type=watch&count=true" allowtransparency="true" frameborder="0" scrolling="0" width="100" height="20" tabindex="-1"></iframe>
</ul>
<p>:
<ul>
<li><a href="https://twitter.com/DevDocs">@DevDocs</a>twitter
<li><a href="https://github.com/freeCodeCamp/devdocs/subscription">GitHub</a>watch
<li><a href="https://groups.google.com/d/forum/devdocs"></a>
</ul>
<h2 class="_block-heading" id="copyright"></h2>
<p class="_note">
<strong>Copyright 2013&ndash;2018 Thibaut Courouble and <a href="https://github.com/freeCodeCamp/devdocs/graphs/contributors">other contributors</a></strong><br>
Mozilla Public License v2.0<br>
You may obtain a copy of the source code at <a href="https://github.com/freeCodeCamp/devdocs">github.com/freeCodeCamp/devdocs</a>.<br>
<a href="https://github.com/freeCodeCamp/devdocs/blob/master/COPYRIGHT"></a>
<a href="https://github.com/freeCodeCamp/devdocs/blob/master/LICENSE"></a>
<h2 class="_block-heading" id="plugins"></h2>
<ul>
<li><a href="https://chrome.google.com/webstore/detail/devdocs/mnfehgbmkapmjnhcnbodoamcioleeooe">Chrome web </a>
<li><a href="https://github.com/egoist/devdocs-app"> </a>
<li><a href="https://sublime.wbond.net/packages/DevDocs">Sublime Text </a>
<li><a href="https://atom.io/packages/devdocs">Atom e</a>
<li><a href="https://marketplace.visualstudio.com/items?itemName=deibit.devdocs">Visual Studio Code </a>
<li><a href="https://github.com/yannickglt/alfred-devdocs">Alfred workflow</a>
<li><a href="https://github.com/search?q=topic%3Adevdocs&type=Repositories"></a>
</ul>
<h2 class="_block-heading" id="faq">Q&A</h2>
<dl>
<dt>
<dd><a href="https://trello.com/b/6BmTulfx/devdocs-documentation">Trello</a><br>
If you have a specific feature request, add it to the <a href="https://github.com/freeCodeCamp/devdocs/issues">issue tracker</a>.<br>
Otherwise use the <a href="https://groups.google.com/d/forum/devdocs">mailing list</a>.
<dt>
<dd><a href="https://github.com/freeCodeCamp/devdocs/issues">issue tracker</a>!
</dl>
<p>For anything else, feel free to email me at <a href="mailto:thibaut@devdocs.io">thibaut@devdocs.io</a>.
<h2 class="_block-heading" id="credits"></h2>
<p><strong>:</strong>
<ul>
<li><a href="https://out.devdocs.io/s/maxcdn">MaxCDN</a>, <a href="https://sentry.io/">Sentry</a> and <a href="https://get.gaug.es/?utm_source=devdocs&utm_medium=referral&utm_campaign=sponsorships" title="Real Time Web Analytics">Gauges</a> for offering a free account to DevDocs
<li><a href="https://out.devdocs.io/s/maxcdn">MaxCDN</a>, <a href="https://out.devdocs.io/s/shopify">Shopify</a>, <a href="https://out.devdocs.io/s/jetbrains">JetBrains</a> and <a href="https://out.devdocs.io/s/code-school">Code School</a> for sponsoring DevDocs in the past
<li><a href="https://www.heroku.com">Heroku</a> and <a href="https://newrelic.com/">New Relic</a> for providing awesome free service
<li><a href="https://www.jeremykratz.com/">Jeremy Kratz</a> for the C/C++ logo
</ul>
<div class="_table">
<table class="_credits">
<tr>
<th>Documentation
<th>Copyright
<th>License
#{credit_table}
</table>
</div>
<h2 class="_block-heading" id="privacy">Privacy Policy</h2>
<ul>
<li><a href="https://devdocs.io">devdocs.io</a> ("App") is operated by Thibaut Courouble ("We").
<li>We do not collect personal information.
<li>We use Google Analytics, Gauges and Sentry to collect anonymous traffic information and improve the app.
<li>The app uses cookies to store user preferences.
<li>By using the app, you signify your acceptance of this policy. If you do not agree to this policy, please do not use the app.
<li>If you have any questions regarding privacy, please email <a href="mailto:thibaut@devdocs.io">thibaut@devdocs.io</a>.
</ul>
"""
credits = [
[ 'Angular<br>Angular.js',
@ -687,3 +767,5 @@ credits = [
'https://raw.githubusercontent.com/yiisoft/yii/master/LICENSE'
]
]
credit_table = ("<tr><td>#{c[0]}<td>&copy; #{c[1]}<td><a href=\"#{c[3]}\">#{c[2]}</a>" for c in credits).join('')

@ -9,7 +9,14 @@ app.templates.helpPage = ->
for key, i in keys
(if i > middle then aliases_two else aliases_one)[key] = app.models.Entry.ALIASES[key]
"""
_ app.templates.helpPage, {
aliases_one: ("<tr><td class=\"_code\">#{key}<td class=\"_code\">#{value}" for key, value of aliases_one).join(''),
aliases_two: ("<tr><td class=\"_code\">#{key}<td class=\"_code\">#{value}" for key, value of aliases_two).join(''),
ctrlKey,
navKey
}
app.templates.helpPage.en = """
<nav class="_toc" role="directory">
<h3 class="_toc-title">Table of Contents</h3>
<ul class="_toc-list">
@ -77,7 +84,7 @@ app.templates.helpPage = ->
<code class="_shortcut-code">enter</code>
<dd class="_shortcuts-dd">Open selection
<dt class="_shortcuts-dt">
<code class="_shortcut-code">#{ctrlKey} + enter</code>
<code class="_shortcut-code">{ctrlKey} + enter</code>
<dd class="_shortcuts-dd">Open selection in a new tab
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + r</code>
@ -86,8 +93,8 @@ app.templates.helpPage = ->
<h3 class="_shortcuts-title">Browsing</h3>
<dl class="_shortcuts-dl">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">#{navKey} + &larr;</code>
<code class="_shortcut-code">#{navKey} + &rarr;</code>
<code class="_shortcut-code">{navKey} + &larr;</code>
<code class="_shortcut-code">{navKey} + &rarr;</code>
<dd class="_shortcuts-dd">Go back/forward
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + &darr;</code>
@ -101,8 +108,8 @@ app.templates.helpPage = ->
<code class="_shortcut-code">shift + space</code>
<dd class="_shortcuts-dd">Scroll screen by screen
<dt class="_shortcuts-dt">
<code class="_shortcut-code">#{ctrlKey} + &uarr;</code>
<code class="_shortcut-code">#{ctrlKey} + &darr;</code>
<code class="_shortcut-code">{ctrlKey} + &uarr;</code>
<code class="_shortcut-code">{ctrlKey} + &darr;</code>
<dd class="_shortcuts-dd">Scroll to the top/bottom
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + f</code>
@ -142,14 +149,167 @@ app.templates.helpPage = ->
<tr>
<th>Word
<th>Alias
#{("<tr><td class=\"_code\">#{key}<td class=\"_code\">#{value}" for key, value of aliases_one).join('')}
{aliases_one}
</table>
<table>
<tr>
<th>Word
<th>Alias
{aliases_two}
</table>
</div>
<p>Feel free to suggest new aliases on <a href="https://github.com/freeCodeCamp/devdocs/issues/new">GitHub</a>.
"""
app.templates.helpPage.ja = """
<nav class="_toc" role="directory">
<h3 class="_toc-title"></h3>
<ul class="_toc-list">
<li><a href="#managing-documentations"></a>
<li><a href="#search"></a>
<li><a href="#shortcuts"></a>
<li><a href="#aliases"></a>
</ul>
</nav>
<h1 class="_lined-heading"></h1>
<h2 class="_block-heading" id="managing-documentations"></h2>
<p>
<a href="/settings"></a>
 使
For faster and better search, only enable the documentations you plan on actively using.
<p>
--<a href="/offline"></a>
Once a documentation is enabled, it becomes part of the search and its content can be downloaded for offline access and faster page loads when online in the <a href="/offline">Offline</a> area.
<h2 class="_block-heading" id="search"></h2>
<p>
The search is case-insensitive and ignores whitespace. It supports fuzzy matching
(e.g. <code class="_label">bgcp</code> matches <code class="_label">background-clip</code>)
as well as aliases (full list <a href="#aliases">below</a>).
<dl>
<dt id="doc_search">
<dd>
The search can be scoped to a single documentation by typing its name (or an abbreviation)
<code class="_label"></code> (<code class="_label"></code>&nbsp;)
and pressing <code class="_label">tab</code> (<code class="_label">space</code>&nbsp;on mobile).
JavaScript<code class="_label">javascript</code>
<code class="_label">js</code><code class="_label"></code><br>
For example, to search the JavaScript documentation, enter <code class="_label">javascript</code>
or <code class="_label">js</code>, then <code class="_label">tab</code>.<br>
<code class="_label"></code>
<code class="_label">esc</code>
To clear the current scope, empty the search field and hit <code class="_label">backspace</code> or
<code class="_label">esc</code>.
<dt id="url_search">Prefilling the search field
<dd>
The search can be prefilled from the URL by visiting <a href="/#q=keyword" target="_top">devdocs.io/#q=keyword</a>.
<code class="_label">#q=</code>使
<a href="/#q=js%20date" target="_top">devdocs.io/#q=js date</a>.
<dt id="browser_search">使
<dd>
DevDocsweb
<ul>
<li>Chromedevdocs.io
<li>On Chrome, the setup is done automatically. Simply press <code class="_label">tab</code> when devdocs.io is autocompleted
in the omnibox (to set a custom keyword, click <em>Manage search engines\u2026</em> in Chrome's settings).
<li>On Firefox, right-click the DevDocs search field and select <em>Add a Keyword for this Search</em>. Then, type the added keyword followed by a query in the address bar to search DevDocs.
</dl>
<p>
<i></i>
<i>Note: the above search features only work for documentations that are enabled.</i>
<h2 class="_block-heading" id="shortcuts"></h2>
<h3 class="_shortcuts-title"></h3>
<dl class="_shortcuts-dl">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">&darr;</code>
<code class="_shortcut-code">&uarr;</code>
<dd class="_shortcuts-dd">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">&rarr;</code>
<code class="_shortcut-code">&larr;</code>
<dd class="_shortcuts-dd">/
<dt class="_shortcuts-dt">
<code class="_shortcut-code">enter</code>
<dd class="_shortcuts-dd">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">{ctrlKey} + enter</code>
<dd class="_shortcuts-dd">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + r</code>
<dd class="_shortcuts-dd">Reveal current page in sidebar
</dl>
<h3 class="_shortcuts-title"></h3>
<dl class="_shortcuts-dl">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">{navKey} + &larr;</code>
<code class="_shortcut-code">{navKey} + &rarr;</code>
<dd class="_shortcuts-dd">/
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + &darr;</code>
<code class="_shortcut-code">alt + &uarr;</code>
<br>
<code class="_shortcut-code">shift + &darr;</code>
<code class="_shortcut-code">shift + &uarr;</code>
<dd class="_shortcuts-dd"><br><br>
<dt class="_shortcuts-dt">
<code class="_shortcut-code">space</code>
<code class="_shortcut-code">shift + space</code>
<dd class="_shortcuts-dd">Scroll screen by screen
<dt class="_shortcuts-dt">
<code class="_shortcut-code">{ctrlKey} + &uarr;</code>
<code class="_shortcut-code">{ctrlKey} + &darr;</code>
<dd class="_shortcuts-dd">/
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + f</code>
<dd class="_shortcuts-dd"><br>(press tab to focus the other links)
</dl>
<h3 class="_shortcuts-title"></h3>
<dl class="_shortcuts-dl">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">ctrl + ,</code>
<dd class="_shortcuts-dd">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">esc</code>
<dd class="_shortcuts-dd">/UI
<dt class="_shortcuts-dt">
<code class="_shortcut-code">?</code>
<dd class="_shortcuts-dd">
</dl>
<h3 class="_shortcuts-title"></h3>
<dl class="_shortcuts-dl">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + o</code>
<dd class="_shortcuts-dd">
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + g</code>
<dd class="_shortcuts-dd">Google
<dt class="_shortcuts-dt">
<code class="_shortcut-code">alt + s</code>
<dd class="_shortcuts-dd">Stack Overflow
</dl>
<p class="_note _note-green">
<strong>Tip:</strong>サーチフィールドでカーソルが たら、<code class="_label">/</code>
<strong>Tip:</strong> If the cursor is no longer in the search field, press <code class="_label">/</code> or
continue to type and it will refocus the search field and start showing new results.
<h2 class="_block-heading" id="aliases">Search Aliases</h2>
<div class="_aliases">
<table>
<tr>
<th>Word
<th>Alias
{aliases_one}
</table>
<table>
<tr>
<th>Word
<th>Alias
#{("<tr><td class=\"_code\">#{key}<td class=\"_code\">#{value}" for key, value of aliases_two).join('')}
{aliases_two}
</table>
</div>
<p><a href="https://github.com/freeCodeCamp/devdocs/issues/new">GitHub</a></p>
<p>Feel free to suggest new aliases on <a href="https://github.com/freeCodeCamp/devdocs/issues/new">GitHub</a>.
"""

@ -24,7 +24,8 @@ app.templates.intro = """
</div></div>
"""
<% else %>
app.templates.intro = """
app.templates.intro =
en: """
<div class="_intro"><div class="_intro-message">
<a href="#" class="_intro-hide" data-hide-intro>Stop showing this message</a>
<h2 class="_intro-title">Welcome!</h2>
@ -44,7 +45,28 @@ app.templates.intro = """
</ol>
<p>Happy coding!
</div></div>
"""
"""
ja: """
<div class="_intro"><div class="_intro-message">
<a href="#" class="_intro-hide" data-hide-intro>このメッセージを表示しない</a>
<h2 class="_intro-title">ようこそ!</h2>
<p>DevDocs combines multiple API documentations in a fast, organized, and searchable interface.
ここを使う前に知っておくべきこと:
<ol class="_intro-list">
<li> <a href="/settings">設定</a>を開くとドキュメントやUIのカスタマイズができます。
<li>マウスを使用する必要はありません &mdash; <a href="/help#shortcuts">キーボードショートカット</a>のリストを見てください。
<li>The search supports fuzzy matching (e.g. "bgcp" brings up "background-clip").
<li>To search a specific documentation, type its name (or an abbr.), then Tab.
<li>ブラウザのアドレスバーで検索できます &mdash; <a href="/help#browser_search">方法を学ぶ</a>
<li>DevDocsは<a href="/offline">オフライン</a>でも動きます。 on mobile, and can be installed on <a href="https://chrome.google.com/webstore/detail/devdocs/mnfehgbmkapmjnhcnbodoamcioleeooe">Chrome</a>.
<li>最新のお知らせは<a href="https://twitter.com/DevDocs">@DevDocs</a>をフォローしてください。
<li>DevDocsは無料で<a href="https://github.com/freeCodeCamp/devdocs">オープンソース</a>です。
<iframe class="_github-btn" src="//ghbtns.com/github-btn.html?user=freeCodeCamp&repo=devdocs&type=watch&count=true" allowtransparency="true" frameborder="0" scrolling="0" width="100" height="20"></iframe>
<li>新たなコーディングを始めるなら、<a href="https://www.freecodecamp.org/">freeCodeCampのオープンソースカリキュラム</a>をチェックしてみてください。
</ol>
<p>楽しいコーディングを!
</div></div>
"""
<% end %>
app.templates.mobileIntro = """

@ -1,4 +1,5 @@
app.templates.settingsPage = (settings) -> """
app.templates.settingsPage = (settings) -> _
en: """
<h1 class="_lined-heading">Preferences</h1>
<div class="_settings-fieldset">
@ -41,4 +42,42 @@ app.templates.settingsPage = (settings) -> """
<p>
<button type="button" class="_btn-link _reset-btn" data-behavior="reset">Reset all preferences and data</button>
"""
"""
ja: """
<h1 class="_lined-heading"></h1>
<div class="_settings-fieldset">
<h2 class="_settings-legend">:</h2>
<div class="_settings-inputs">
<label class="_settings-label">
<input type="checkbox" form="settings" name="dark" value="1"#{if settings.dark then ' checked' else ''}>
</label>
<label class="_settings-label _setting-max-width">
<input type="checkbox" form="settings" name="layout" value="_max-width"#{if settings['_max-width'] then ' checked' else ''}>fixed-width
</label>
<label class="_settings-label _hide-on-mobile">
<input type="checkbox" form="settings" name="layout" value="_sidebar-hidden"#{if settings['_sidebar-hidden'] then ' checked' else ''}>
<small>Tip:調</small>
</label>
</div>
</div>
<div class="_settings-fieldset _hide-on-mobile">
<h2 class="_settings-legend">:</h2>
<div class="_settings-inputs">
<label class="_settings-label">
<input type="checkbox" form="settings" name="smoothScroll" value="1"#{if settings.smoothScroll then ' checked' else ''}>使
</label>
<label class="_settings-label _setting-native-scrollbar">
<input type="checkbox" form="settings" name="layout" value="_native-scrollbars"#{if settings['_native-scrollbars'] then ' checked' else ''}>使
</label>
<label class="_settings-label">
<input type="checkbox" form="settings" name="arrowScroll" value="1"#{if settings.arrowScroll then ' checked' else ''}>使
<small>With this checked, use <code class="_label">alt</code> + <code class="_label">&uarr;</code><code class="_label">&darr;</code><code class="_label">&larr;</code><code class="_label">&rarr;</code> to navigate the sidebar.</small>
</label>
</div>
</div>
<p class="_hide-on-mobile">
<button type="button" class="_btn" data-action="export"></button>
<label class="_btn _file-btn"><input type="file" form="settings" name="import" accept=".json"></label>
<p>
<button type="button" class="_btn-link _reset-btn" data-behavior="reset"></button>
"""

@ -23,21 +23,26 @@ templates.sidebarEntry = (entry) ->
templates.sidebarResult = (entry) ->
addons = if entry.isIndex() and app.disabledDocs.contains(entry.doc)
"""<span class="_list-enable" data-enable="#{entry.doc.slug}">Enable</span>"""
"""<span class="_list-enable" data-enable="#{entry.doc.slug}">#{_ en: "Enable", ja: "有効"}</span>"""
else
"""<span class="_list-reveal" data-reset-list title="Reveal in list"></span>"""
addons += """<span class="_list-count">#{entry.doc.short_version}</span>""" if entry.doc.version and not entry.isIndex()
"""<a href="#{entry.fullPath()}" class="_list-item _list-hover _list-result _icon-#{entry.doc.icon}" tabindex="-1">#{addons}<span class="_list-text">#{$.escape entry.name}</span></a>"""
templates.sidebarNoResults = ->
html = """ <div class="_list-note">No results.</div> """
html += """
html = """ <div class="_list-note">#{_ en: "No results.", ja: "ヒットしませんでした。"}</div> """
html += _(
en: """
<div class="_list-note">Note: documentations must be <a href="/settings" class="_list-note-link">enabled</a> to appear in the search.</div>
""" unless app.isSingleDoc() or app.disabledDocs.isEmpty()
"""
ja: """
<div class="_list-note">: <a href="/settings" class="_list-note-link"></a> </div>
"""
) unless app.isSingleDoc() or app.disabledDocs.isEmpty()
html
templates.sidebarPageLink = (count) ->
"""<span role="link" class="_list-item _list-pagelink">Show more\u2026 (#{count})</span>"""
"""<span role="link" class="_list-item _list-pagelink">#{_ en: "Show more", ja: "もっと見る"}\u2026 (#{count})</span>"""
templates.sidebarLabel = (doc, options = {}) ->
label = """<label class="_list-item"""
@ -52,7 +57,8 @@ templates.sidebarVersionedDoc = (doc, versions, options = {}) ->
html + """" tabindex="0">#{arrow}#{doc.name}</div><div class="_list _list-sub">#{versions}</div>"""
templates.sidebarDisabled = (options) ->
"""<h6 class="_list-title">#{arrow}Disabled (#{options.count}) <a href="/settings" class="_list-title-link" tabindex="-1">Customize</a></h6>"""
disabled = _ en: "Disabled", ja: "カスタマイズ"
"""<h6 class="_list-title">#{arrow}Disabled (#{options.count}) <a href="/settings" class="_list-title-link" tabindex="-1">#{disabled}</a></h6>"""
templates.sidebarDisabledList = (html) ->
"""<div class="_disabled-list">#{html}</div>"""
@ -60,9 +66,16 @@ templates.sidebarDisabledList = (html) ->
templates.sidebarDisabledVersionedDoc = (doc, versions) ->
"""<a class="_list-item _list-dir _icon-#{doc.icon} _list-disabled" data-slug="#{doc.slug_without_version}" tabindex="-1">#{arrow}#{doc.name}</a><div class="_list _list-sub">#{versions}</div>"""
templates.docPickerHeader = """<div class="_list-picker-head"><span>Documentation</span> <span>Enable</span></div>"""
templates.docPickerHeader =
en: """<div class="_list-picker-head"><span>Documentation</span> <span>Enable</span></div>"""
ja: """<div class="_list-picker-head"><span>ドキュメント</span> <span>Enable</span></div>"""
templates.docPickerNote = """
templates.docPickerNote =
en: """
<div class="_list-note">Tip: for faster and better search results, select only the docs you need.</div>
<a href="https://trello.com/b/6BmTulfx/devdocs-documentation" class="_list-link" target="_blank" rel="noopener">Vote for new documentation</a>
"""
ja: """
<div class="_list-note">Tip: </div>
<a href="https://trello.com/b/6BmTulfx/devdocs-documentation" class="_list-link" target="_blank" rel="noopener"></a>
"""

@ -1,4 +1,5 @@
app.templates.tipKeyNav = """
app.templates.tipKeyNav =
en: """
<p class="_notif-text">
<strong>ProTip</strong>
<span class="_notif-info">(click to dismiss)</span>
@ -7,4 +8,14 @@ app.templates.tipKeyNav = """
Hit <code class="_label">space / shift space</code>, <code class="_label">alt &darr;/&uarr;</code> or <code class="_label">shift &darr;/&uarr;</code> to scroll the page.
<p class="_notif-text">
<a href="/help#shortcuts" class="_notif-link">See all keyboard shortcuts</a>
"""
"""
ja: """
<p class="_notif-text">
<strong>ProTip</strong>
<span class="_notif-info">(退)</span>
<p class="_notif-text">
Hit <code class="_label">&darr;</code> <code class="_label">&uarr;</code> <code class="_label">&larr;</code> <code class="_label">&rarr;</code> <br>
Hit <code class="_label">space / shift space</code>, <code class="_label">alt &darr;/&uarr;</code> または <code class="_label">shift &darr;/&uarr;</code>
<p class="_notif-text">
<a href="/help#shortcuts" class="_notif-link"></a>
"""

Loading…
Cancel
Save