Skip to content

settings: ja locale config #35

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jan 19, 2021
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion src/.vuepress/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ module.exports = {
postcss: require('./config/postcss'),
locales: {
'/': require('./config/languages/en/localeConfig'),
'/pt/': require('./config/languages/pt/localeConfig')
'/pt/': require('./config/languages/pt/localeConfig'),
'/jp/': require('./config/languages/jp/localeConfig')
},
themeConfig: require('./config/themeConfig'),
markdown: {
Expand Down
40 changes: 38 additions & 2 deletions src/.vuepress/config/languages/jp/blog.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,42 @@
const posts = {}
const posts = {
id: 'post',
title: 'すべての投稿',
layout: 'Posts',
itemLayout: 'Post',
dirname: 'jp/posts',
path: '/jp/posts/',
itemPermalink: '/posts/:slug',
frontmatter: {
meta: [
{
name: 'description',
content: 'Vue.js 開発を中心としたアクセシビリティに関するコミュニティの投稿'
}
]
},
pagination: {
layout: 'Posts',
prevText: '<<',
nextText: '>>',
getPaginationPageTitle (pageNumber) {
return `すべての投稿 - ${pageNumber}ページ目`
}
}
}

const categories = {}
const categories = {
id: 'categories',
keys: ['category', 'categories'],
title: 'カテゴリ',
scopeLayout: 'Posts',
path: '/jp/category/',
pagination: {
layout: 'Posts',
getPaginationPageTitle (pageNumber, key) {
return `カテゴリ: ${key} - ${pageNumber}ページ目`
}
}
}

module.exports = {
posts,
Expand Down
2 changes: 1 addition & 1 deletion src/.vuepress/config/languages/jp/localeConfig.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module.exports = {
lang: 'ja',
title: 'Vue A11y',
description: ''
description: 'Web アクセシビリティ向上のための Vue.js コミュニティの取り組み'
}
97 changes: 94 additions & 3 deletions src/.vuepress/config/languages/jp/sidebarStructure.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,96 @@
module.exports = {
project: [],
posts: [],
recipes: []
project: [
{
title: 'プロジェクト',
children: [
'',
['ロードマップ', 'https://github.com/vue-a11y/vue-a11y.com/projects/2'],
['参加者', 'people'],
['コントリビュート', 'how-to-contribute'],
]
},
{
title: 'アクセシビリティ',
children: [
['リソース', 'resources'],
['Vue A11Y チェックリスト', 'vue-a11y-checklist'],
]
},
{
title: 'コミュニティ',
children: [
['パッケージ', 'https://github.com/vue-a11y/awesome-a11y-vue#components-and-plugins'],
['UI プロジェクト', 'https://github.com/vue-a11y/awesome-a11y-vue#accessible-libraries'],
['Awesome', 'https://github.com/vue-a11y/awesome-a11y-vue']
]
}
],

posts: [
{
title: 'カテゴリ',
type: 'manual',
children: [
['ニュース', '/jp/category/news/'],
['HTML', '/jp/category/html/'],
['ARIA', '/jp/category/aria/'],
['WCAG', '/jp/category/wcag/'],
['ツール', '/jp/category/tools/'],
['パッケージ', '/jp/category/packages/'],
['Single Page App', '/jp/category/spa/']
]
},
// SOON
// {
// title: '24 Vue A11y',
// type: 'manual',
// children: [
// ['2020', '/category/24-vue-a11y-2020/']
// ]
// },
{
title: 'Twitter でフォローする',
children: [
['Sarah Drasner', 'https://twitter.com/sarah_edo'],
['Maria Lamardo', 'https://twitter.com/MariaLamardo'],
['Alan Ktquez', 'https://twitter.com/ktquez'],
['Jinjiang', 'https://twitter.com/zhaojinjiang'],
['Marcus Herrmann', 'https://twitter.com/_marcusherrmann'],
['Austin Gil', 'https://twitter.com/Stegosource'],
['Callum Macrae', 'https://twitter.com/callumacrae'],
['Kevin Deisz', 'https://twitter.com/kddeisz'],
['Victoria Bergquist', 'https://twitter.com/vicbergquist']
]
}
],

recipes: [
{
title: 'レシピ',
children: [
''
]
},
{
title: 'ウィジェット',
children: [
['アコーディオン', 'widgets/accordion'],
['アラート', 'widgets/alert'],
['パンくず', 'widgets/breadcrumbs'],
['カード', 'widgets/card'],
['カルーセル', 'widgets/carousel'],
['ダイアログ', 'widgets/dialog'],
['モバイルナビゲーション', 'widgets/mobile-navigation'],
['スキップリンク', 'widgets/skip-links'],
['タブ', 'widgets/tabs'],
['トースト', 'widgets/toast']
]
},
{
title: 'ヒント',
children: [
['Vue における ARIA 属性', 'tips/aria-attributes-in-vue']
]
}
]
}
82 changes: 80 additions & 2 deletions src/.vuepress/config/languages/jp/themeLocaleConfig.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,83 @@
const sidebar = require('./sidebarStructure')

module.exports = {
enabled: false,
enabled: true,
label: '日本語',
nav: []
editLinkText: 'GitHub で編集する',
lastUpdatedText: '最終更新',
backToTopText: 'ページトップに戻る',
backToText: '戻る',
shareLinksText: 'シェア',
externalLinkText: '新しいタブで開く',
skipTo: {
label: 'コンテンツにスキップする',
to: '#main'
},
newsletter: {
title: 'ニュースレターを購読する',
label: 'Eメールアドレス',
description: 'メールアドレスを入力すると、記事、ビデオ、アップデート、イベントの情報を Vue.js アクセシビリティコミュニティから受け取ることができます。',
textButton: '購読する'
},
toc: {
title: '目次'
},
nav: [
{
text: 'プロジェクト',
link: '/jp/project/'
},
{
text: '投稿',
link: '/jp/posts/'
},
{
text: 'レシピ',
link: '/jp/recipes/'
},
{
text: '設定',
link: '/jp/settings/'
}
],
sidebar: {
'/jp/project/': sidebar.project,
'/jp/posts/': sidebar.posts,
'/jp/category/': '/jp/posts/',
'/jp/recipes/': sidebar.recipes
},
a11y: {
codeSnippet: {
copy: {
text: 'クリップボードにコピーしました',
ariaLabel: 'コードスニペットをクリップボードにコピー',
textCopied: 'コードをコピーしました!'
},
skip: {
text: 'スキップ',
ariaLabel: 'スニペットコードをスキップ'
}
},
labels: {
menuButton: {
open: 'サブナビゲーションを開く',
close: 'サブナビゲーションを閉じる'
}
},
settings: {
theme: {
altText: 'ブラウザテーマのイラスト'
}
},
landmarks: {
nav: {
main: 'メインナビゲーション',
secondary: 'サブナビゲーション'
},
post: {
summary: 'Summary',
content: 'Content post'
}
}
}
}
9 changes: 6 additions & 3 deletions src/.vuepress/config/plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@ const resolve = pathName => path.join(__dirname, pathName)

const blogConfig = {
en: require('./languages/en/blog'),
pt: require('./languages/pt/blog')
pt: require('./languages/pt/blog'),
jp: require('./languages/jp/blog'),
}

const customBlock = {
Expand Down Expand Up @@ -45,11 +46,13 @@ module.exports = [
},
directories: [
blogConfig.en.posts,
blogConfig.pt.posts
blogConfig.pt.posts,
blogConfig.jp.posts
],
frontmatters: [
blogConfig.en.categories,
blogConfig.pt.categories
blogConfig.pt.categories,
blogConfig.jp.categories
]
}
],
Expand Down
3 changes: 2 additions & 1 deletion src/.vuepress/config/themeConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ module.exports = {
authors: require('./authors'),
locales: {
'/': require('./languages/en/themeLocaleConfig'),
'/pt/': require('./languages/pt/themeLocaleConfig')
'/pt/': require('./languages/pt/themeLocaleConfig'),
'/jp/': require('./languages/jp/themeLocaleConfig'),
}
}
22 changes: 22 additions & 0 deletions src/jp/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
layout: Full
view: Home

actionText: Get Started
actionLink: /project/

heroImage: /hero-accessibility.svg
heroImageAlternativeText: Illustration of a visually impaired man standing and a woman in a wheelchair

sponsorsText: Sponsors
supportersText: Supporters

features:
- title: Examples
details: Several examples of how to apply ARIA, the techniques of WCAG and the best practices in your Vue.js components.
- title: Packages
details: Developing and helping the most used Vue.js components to keep their components accessible.
- title: A11y contents
details: Useful links, articles, videos, Web accessibility events, both in the context of Vue.js and in others.

---
56 changes: 56 additions & 0 deletions src/jp/posts/2020-09-01-post-test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
title: 'Example post: The first post'
description: Description test page
summary: Summary test page

categories: [news, aria, wcag, tools, packages, spa, html]
author: ktquez

date: 2020-09-01 16:00:00
---

## Test post (please ignore)

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer risus nulla, viverra a porttitor eu, euismod eget nisl. Pellentesque pharetra diam orci, id blandit metus pretium ac.

Suspendisse rhoncus mauris a sapien gravida, ut pulvinar urna ultrices. Aenean semper nisi vitae laoreet semper. Sed convallis massa ut commodo gravida.

Praesent vehicula pharetra tincidunt. Proin nec elit volutpat, lobortis dui eu, hendrerit sapien. Donec sapien quam, dictum sit amet neque eu, malesuada ultrices libero. Morbi blandit augue in turpis porttitor porta.

:::: fig code
::: headerCode index.html
```html
<small>
<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">
Creative Commons Attribution Share-alike license
</a>
</small>
```
:::
::: figcap
Using &lt;small&gt; around a [Creative Commons license](http://creativecommons.org/choose/) link with `rel="license"`
:::
::::

Nullam aliquet quam a eros mollis, eu rhoncus magna imperdiet. Donec quis scelerisque nulla.

Donec auctor, neque eget imperdiet consequat, sapien massa suscipit orci, quis condimentum dolor nisl dapibus nisl.

:::: fig bq
::: bq
VuePress is composed of two parts: a minimalistic static site generator with a Vue-powered theming system and Plugin API, and a default theme optimized for writing technical documentation.
:::
::: figcap
[W3C, HTML draft documentation 2020](https://google.com)
:::
::::

Praesent mollis ornare felis vel egestas. Ut sit amet ex imperdiet, suscipit urna vel, vestibulum ex.

Nam iaculis nisl at diam suscipit tincidunt. Nam sit amet magna vitae velit sodales feugiat.

Donec feugiat sagittis metus, non rutrum turpis. Fusce turpis dolor, feugiat sit amet interdum nec, ultrices eget metus.

::: alert warning
This is a warning
:::
Loading