Add digest to theme images to not keep rebuilding them
The digest is based on the colors of theme, so will change when the colors change
This commit is contained in:
1 parent
403a791c94
commit
511718e973
24 files changed
+23
-10
No files matched your search
@@ -4,8 +4,9 @@ title: Slack Themes
|
||||
|
||||
<% data.themes.each do |theme| %>
|
||||
<% theme_slug = theme[:name].parameterize.underscore %>
|
||||
<% digest = Digest::MD5.new.hexdigest(theme[:colors]) %>
|
||||
<label class="radio theme_label theme_<%= theme[:name].parameterize.underscore %>">
|
||||
<img src="/images/theme/<%= theme_slug %>.png" class="theme_thumb"><br>
|
||||
<img src="/images/theme/<%= theme_slug %>-<%= digest %>.png" class="theme_thumb"><br>
|
||||
<input name="sidebar_theme_rd" type="radio" value="<%= theme[:colors] %>" ng-model="theme" ng-change="setTheme()"> <%= theme[:name] %>
|
||||
</label>
|
||||
<% end %>
|
||||
Reference in new issue
Block a user