magic_locales 0.0.11 → 0.0.12

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f5429c8f9b2a7639b79866c00e201a2e4198b355
4
- data.tar.gz: f15f1cb3f856515553f968c860c09e3af623901a
3
+ metadata.gz: bc0bd6d726e3ee3d3805cab459dda4bfd9165c3b
4
+ data.tar.gz: 1e09f257d6868b0a7fff0e880d0bfda904d1b322
5
5
  SHA512:
6
- metadata.gz: c8b1de91503e62d4564500ee78678e9205f5c61fc4a8a6201cb9a96804356d75959cc8d8bea3d493dc0ef36373c96598ed24f145e88cb947771e68574b73b14a
7
- data.tar.gz: a9aaaff814e61f626f3b751dbc81898e056821e82dca8d20c2a54660ed3c6fbac364a87ca50b34d1d9302bc40f8359cd73011f3f115aadbf728a9c10005ee96c
6
+ metadata.gz: a2748464ee5fda360ab1ed60004eb3324df26752955a6d5ee9e8daa66fb2e8d5a91aaa5e4a3828611daade34cca49a7c2150366332176c269bdda48a7327fc23
7
+ data.tar.gz: 917f13d0634dc9498a673b816bfa2dac7bdf70361fbf08605ff9b628deb9c9dd0e0d7995d570a1ef5e550e07bbd1081476c476f763f75ff5840f234f6c4e874d
@@ -0,0 +1 @@
1
+ <%= link_to raw("<i class='icomoon-pencil'></i>"), url_for( controller: "magic_locales/locales", action: :edit, id: locale), class: "btn btn-default btn-sm", data: { toggle: "modal", target: "#appModal" }, title: t("magic_locales.edit") %>
@@ -0,0 +1,9 @@
1
+ <% icns = {"activate": "checkmark", "deactivate": "close", "release": "earth"} %>
2
+ <% clss = {"activate": "success", "deactivate": "danger", "release": "info"} %>
3
+
4
+
5
+ <% %w(activate release deactivate).each do |state| %>
6
+ <% if locale.state.trigger?(state.to_sym) %>
7
+ <%= link_to raw("<i class='icomoon-#{clss[state]}'></i>"), url_for( controller: "magic_locales/locales", action: :trigger, id: locale, state: state), class: "btn btn-#{clss[state]} btn-sm", title: t("magic_locales.triggers.#{state}") %>
8
+ <% end %>
9
+ <% end %>
@@ -86,14 +86,10 @@
86
86
  <% end %>
87
87
  </td>
88
88
  <td>
89
- <% %w(activate release deactivate).each do |state| %>
90
- <% if locale.state.trigger?(state.to_sym) %>
91
- <%= link_to t("magic_locales.triggers.#{state}"), url_for( controller: "magic_locales/locales", action: :trigger, id: locale, state: state), class: "btn btn-default btn-sm" %>
92
- <% end %>
93
- <% end %>
89
+ <%= render "magic_locales/admin_triggers", locale: locale %>
94
90
  </td>
95
91
  <td>
96
- <%= link_to t("magic_locales.edit"), url_for( controller: "magic_locales/locales", action: :edit, id: locale), class: "btn btn-default btn-sm", data: { toggle: "modal", target: "#appModal" } %>
92
+ <%= render "magic_locales/admin_actions", locale: locale %>
97
93
  </td>
98
94
  </tr>
99
95
  <% end %>
@@ -1,3 +1,3 @@
1
1
  module MagicLocales
2
- VERSION = "0.0.11"
2
+ VERSION = "0.0.12"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: magic_locales
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Torsten Wetzel
@@ -113,7 +113,9 @@ files:
113
113
  - lib/app/models/magic_locales/association.rb
114
114
  - lib/app/models/magic_locales/language.rb
115
115
  - lib/app/models/magic_locales/locale.rb
116
+ - lib/app/views/magic_locales/_admin_actions.html.erb
116
117
  - lib/app/views/magic_locales/_admin_template.html.erb
118
+ - lib/app/views/magic_locales/_admin_triggers.html.erb
117
119
  - lib/app/views/magic_locales/_locale_switch.html.erb
118
120
  - lib/app/views/magic_locales/locales/_globalized_name_fields.html.erb
119
121
  - lib/app/views/magic_locales/locales/form.html.erb