5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-15 04:51:43 +00:00
panel/app/views/i18n/_recursive.haml

9 lines
333 B
Text
Raw Normal View History

2018-02-09 21:28:27 +00:00
- data.each_pair do |key, value|
- keys = [superkeys, key].flatten
- if value.is_a? String
= render 'i18n/text_field', keys: keys, value: value
- elsif value.is_a? Hash
= render 'i18n/recursive', data: value, superkeys: keys
2018-02-09 21:36:28 +00:00
- elsif value.is_a? Array
= render 'i18n/recursive_array', data: value, superkeys: keys