Skip to content

Commit

Permalink
two levels deep translations
Browse files Browse the repository at this point in the history
  • Loading branch information
eboye committed Sep 28, 2019
1 parent 7b03ffa commit 7963ca2
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
2 changes: 1 addition & 1 deletion dist/js/tool.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

15 changes: 13 additions & 2 deletions resources/js/components/Tool.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
<th class="text-left">String</th>
</tr>
</thead>
<tbody>
<tr v-for="(t_object, t_path) in translation">
<tbody v-for="(t_object, t_path) in translation">
<tr v-if="typeof t_object == 'string'">
<td class="text-left">{{t_path}}</td>
<td class="text-left">
<ClickToEdit
Expand All @@ -32,6 +32,17 @@
></ClickToEdit>
</td>
</tr>
<tr v-else v-for="(t_item_object, t_item_path) in t_object">
<td class="text-left">{{t_path + '.' + t_item_path}}</td>
<td class="text-left">
<ClickToEdit
:value="t_item_object"
:group="translation_file"
:value_key="t_path + '.' + t_item_path"
:locale="active_locale"
></ClickToEdit>
</td>
</tr>
</tbody>
</table>
</div>
Expand Down

0 comments on commit 7963ca2

Please sign in to comment.