Просмотр исходного кода

modify translations for template pages

Yuki Takei 7 лет назад
Родитель
Сommit
e724fd7cf9

+ 21 - 18
lib/locales/en-US/translation.json

@@ -42,7 +42,7 @@
 
   "Management Wiki": "Management Wiki",
 
-  "Create/Edit Template": "Create/Edit Template",
+  "Create/Edit Template": "Create/Edit Template Page",
 
   "Unportalize": "Unportalize",
 
@@ -80,11 +80,7 @@
   "Input page name": "Input page name",
   "Input page name (optional)": "Input page name (optional)",
   "New Page": "New Page",
-  "Create under": "Create page under: <code>%s</code>",
-  "Create template under": "Create template under: <code>%s</code>",
-  "Option select template": "Select template type",
-  "Option local template": "Local Template(/__template) - Applies only to immediate decendant pages",
-  "Option global template": "Global Template(/_template) - Applies to all decendant pages",
+  "Create under": "Create page under below:",
 
   "Table of Contents": "Table of Contents",
 
@@ -194,18 +190,6 @@
     }
   },
 
-  "modal_template": {
-    "label": {
-      "Create template": "Create a new template for <code>%s</code>",
-      "Local template": "Local Template",
-      "Global template": "Global Template"
-    },
-    "help": {
-      "Local template": "Applies only to immediate decendant pages",
-      "Global template": "Applies to all decendant pages"
-    }
-  },
-
   "modal_duplicate": {
     "label": {
       "Duplicate page": "Duplicate page",
@@ -238,6 +222,25 @@
               }
   },
 
+  "template": {
+    "modal_label": {
+      "Create/Edit Template Page": "Create/Edit Template Page",
+      "Create template under": "Create template page under: <code>%s</code>"
+    },
+    "option_label": {
+      "create/edit": "Create/Edit Template page..",
+      "select": "Select template page type"
+    },
+    "local": {
+      "label": "Template for children",
+      "desc": "Applies only to the same level pages which the template exists"
+    },
+    "global": {
+      "label": "Template for descendants",
+      "desc": "Applies to all decendant pages"
+    }
+  },
+
   "admin_top": {
     "Management Wiki": "Management Wiki",
     "System Information": "System Information",

+ 21 - 20
lib/locales/ja/translation.json

@@ -40,7 +40,7 @@
   "Share Link": "共有用リンク",
   "Markdown Link": "Markdown形式のリンク",
 
-  "Create/Edit Template": "テンプレートの作成/編集",
+  "Create/Edit Template": "テンプレートページの作成/編集",
 
   "Unportalize": "ポータル解除",
 
@@ -79,13 +79,7 @@
   "Input page name": "ページ名を入力",
   "Input page name (optional)": "ページ名を入力(空欄OK)",
   "New Page": "新規ページ",
-  "Create under": "ページを<code>%s</code>以下に作成",
-  "Create template under": "テンプレートを<code>%s</code>以下に作成",
-  "Option select template": "テンプレートタイプを選択してください",
-  "Option local template": "ローカルテンプレート(/__template) - 指定されたパス直下のページにのみ適応されます",
-  "Option global template": "グローバルテンプレート(/_template) - 指定されたパス以下すべてのページに適応されます",
-
-
+  "Create under": "ページを以下に作成",
 
   "Table of Contents": "目次",
   "Management Wiki Home": "Wiki管理トップ",
@@ -214,18 +208,6 @@
     }
   },
 
-  "modal_template": {
-    "label": {
-      "Create template": "<code>%s</code> にテンプレートを作成します",
-      "Local template": "ローカルテンプレート",
-      "Global template": "グローバルテンプレート"
-    },
-    "help": {
-      "Local template": "指定されたパス直下のページにのみ<br>適応されます。",
-      "Global template": "指定されたパス以下すべてのページに<br>適応されます。"
-    }
-  },
-
   "modal_duplicate": {
     "label": {
       "Duplicate page": "ページを複製する",
@@ -255,6 +237,25 @@
     }
   },
 
+  "template": {
+    "modal_label": {
+      "Create/Edit Template Page": "テンプレートページの作成/編集",
+      "Create template under": "<code>%s</code> にテンプレートページを作成"
+    },
+    "option_label": {
+      "select": "テンプレートタイプを選択してください",
+      "create/edit": "テンプレートページの作成/編集.."
+    },
+    "local": {
+      "label": "同一階層テンプレート",
+      "desc": "テンプレートページが存在する階層にのみ適応されます"
+    },
+    "global": {
+      "label": "下位層テンプレート",
+      "desc": "テンプレートページが存在する下位層のすべてのページに適応されます"
+    }
+  },
+
   "admin_top": {
     "Management Wiki": "Wiki管理",
     "System Information": "システム情報",

+ 5 - 5
lib/views/modal/create_page.html

@@ -28,7 +28,7 @@
 
         <form class="row form-horizontal m-t-15" id="create-page-under-tree" role="form">
           <fieldset class="col-xs-12">
-            <legend>{{ t('Create under', parentPath(path)) }}</legend>
+            <legend>{{ t('Create under') }}</legend>
             <div class="d-flex create-page-input-container">
               <div class="create-page-input-row d-flex align-items-center">
                 {% if searchConfigured() %}
@@ -46,13 +46,13 @@
 
         <div id = "template-form" class="row form-horizontal m-t-15">
           <fieldset class="col-xs-12">
-            <legend>{{ t('Create template under', parentPath(path)) }}</legend>
+            <legend>{{ t('template.modal_label.Create template under', parentPath(path)) }}</legend>
             <div class="d-flex create-page-input-container">
               <div class="create-page-input-row d-flex align-items-center">
                 <select id="template-type" class="page-name-input form-control">
-                  <option value="" disabled selected>{{ t('Option select template') }}</option>
-                  <option value="local">{{ t('Option local template', parentPath(path)) }}</option>
-                  <option value="global">{{ t('Option global template', parentPath(path)) }}</option>
+                  <option value="" disabled selected>{{ t('template.option_label.select') }}</option>
+                  <option value="local">{{ t('template.local.label') }}(__template) - {{ t('template.local.desc') }}</option>
+                  <option value="global">{{ t('template.global.label') }}(_template) - {{ t('template.global.desc') }}</option>
                 </select>
               </div>
               <div class="create-page-button-container">

+ 6 - 6
lib/views/modal/create_template.html

@@ -4,18 +4,18 @@
 
       <div class="modal-header bg-primary">
         <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
-        <div class="modal-title">{{ t('Create/Edit Template') }}</div>
+        <div class="modal-title">{{ t('template.modal_label.Create/Edit Template Page') }}</div>
       </div>
       <div class="modal-body">
         <div class="form-group">
-          <label class="mb-4">{{ t('modal_template.label.Create template', page.path) }}</label>
+          <label class="mb-4">{{ t('template.modal_label.Create template under', page.path ) }}</label>
           <div class="row">
             <div class="col-sm-6">
               <div class="panel panel-default">
-                <div class="panel-heading">{{ t('modal_template.label.Local template') }}</div>
+                <div class="panel-heading">{{ t('template.local.label') }}</div>
                 <div class="panel-body">
                   <p class="text-center"><code>__template</code></p>
-                  <p class="help-block text-center"><small>{{ t('modal_template.help.Local template') }}</small></p>
+                  <p class="help-block text-center"><small>{{ t('template.local.desc') }}</small></p>
                 </div>
                 <div class="panel-footer text-center">
                   {% if localTemplateExists %}
@@ -28,10 +28,10 @@
             </div>
             <div class="col-sm-6">
               <div class="panel panel-default">
-                <div class="panel-heading">{{ t('modal_template.label.Global template') }}</div>
+                <div class="panel-heading">{{ t('template.global.label') }}</div>
                 <div class="panel-body">
                   <p class="text-center"><code>_template</code></p>
-                  <p class="help-block text-center"><small>{{ t('modal_template.help.Global template') }}</small></p>
+                  <p class="help-block text-center"><small>{{ t('template.global.desc') }}</small></p>
                 </div>
                 <div class="panel-footer text-center">
                   {% if globalTemplateExists %}

+ 3 - 3
lib/views/widget/page_tabs.html

@@ -29,12 +29,12 @@
       </a>
       <ul class="dropdown-menu">
         <li><a href="#" data-target="#renamePage" data-toggle="modal"><i class="icon-fw icon-action-redo"></i> {{ t('Move') }}</a></li>
-        <li class="divider"></li>
-        <li class=""><a href="#" data-target="#create-template" data-toggle="modal"><i class="icon-fw icon-docs"></i> {{ t('Create/Edit Template') }}</a></li>
         <li><a href="#" data-target="#duplicatePage" data-toggle="modal"><i class="icon-fw icon-docs"></i> {{ t('Duplicate') }}</a></li>
+        <li class="divider"></li>
+        <li><a href="#" data-target="#create-template" data-toggle="modal"><i class="icon-fw icon-magic-wand"></i> {{ t('template.option_label.create/edit') }}</a></li>
         {% if isDeletablePage() %}
         <li class="divider"></li>
-        <li class=""><a href="#" data-target="#deletePage" data-toggle="modal"><i class="icon-fw icon-fire text-danger"></i> {{ t('Delete') }}</a></li>
+        <li><a href="#" data-target="#deletePage" data-toggle="modal"><i class="icon-fw icon-fire text-danger"></i> {{ t('Delete') }}</a></li>
         {% endif %}
       </ul>
     </li>