refinerycms 0.9.6.11 → 0.9.6.12

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.9.6.11
1
+ 0.9.6.12
@@ -980,7 +980,7 @@ WYMeditor.editor.prototype.exec = function(cmd) {
980
980
  case WYMeditor.APPLY_CLASS:
981
981
  wym = this;
982
982
  $(wym._box).find(this._options.classUnhiddenSelector).toggleClass(this._options.classHiddenSelector.substring(1)); // substring(1) to remove the . at the start
983
- $(wym._box).find("a[name=" + WYMeditor.APPLY_CLASS +"]").toggleClass('selected');
983
+ $(wym._box).find("a[name=" + WYMeditor.APPLY_CLASS +"]").toggleClass('selected').parent().toggleClass('activated');
984
984
  // determine whether any classes are already selected and add the enabled class to them.
985
985
  $(wym._box).find(this._options.classUnhiddenSelector).find("a[name]").each(function(index, rule){
986
986
  if ($(wym.selected()).hasClass($(rule).attr('name'))) {
@@ -8,7 +8,7 @@
8
8
  .wym_skin_refinery .wym_area_right { display: block; }
9
9
 
10
10
 
11
- /*TYPO*/
11
+ /*TYPO*/
12
12
  .wym_skin_refinery { font-size: 62.5%; font-family: Verdana, Arial, sans-serif; }
13
13
  .wym_skin_refinery h2 { font-size: 110%; /* = 11px */}
14
14
  .wym_skin_refinery h3 { font-size: 100%; /* = 10px */}
@@ -31,7 +31,7 @@
31
31
  /*WYM_IFRAME*/
32
32
  .wym_skin_refinery .wym_iframe { width: 100%;}
33
33
  .wym_skin_refinery .wym_iframe iframe { width: 99%; border: 1px solid gray; background: white }
34
-
34
+
35
35
  /* adjust for two rows of icons */
36
36
  .wym_two_column .wym_skin_refinery .wym_iframe iframe, .wym_two_column .wym_skin_refinery .wym_html textarea { height: 376px; }
37
37
 
@@ -55,7 +55,7 @@
55
55
  /*hide section titles by default*/
56
56
  .wym_skin_refinery .wym_section h2 { display: none; }
57
57
  /*disable any margin-collapse*/
58
- .wym_skin_refinery .wym_section { padding: 0px;}
58
+ .wym_skin_refinery .wym_section { padding: 0px;}
59
59
  /*auto-clear sections*/
60
60
  .wym_skin_refinery .wym_section ul:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
61
61
  * html .wym_skin_refinery .wym_section ul { height: 1%;}
@@ -74,7 +74,7 @@
74
74
  .wym_skin_refinery .wym_buttons li { float:left;}
75
75
  .wym_skin_refinery .wym_buttons a { width: 20px; height: 20px; overflow: hidden; padding: 2px }
76
76
  /*image replacements*/
77
- .wym_skin_refinery .wym_buttons li a { background: url('/images/wymeditor/skins/refinery/icons.png') no-repeat; text-indent: -9999px;}
77
+ .wym_skin_refinery .wym_buttons li a { background: url('/images/wymeditor/skins/refinery/icons.png') no-repeat; text-indent: -9999px;}
78
78
  .wym_skin_refinery .wym_buttons li.wym_tools_strong a { background-position: 0 -382px;}
79
79
  .wym_skin_refinery .wym_buttons li.wym_tools_emphasis a { background-position: 0 -22px;}
80
80
  .wym_skin_refinery .wym_buttons li.wym_tools_superscript a { background-position: 0 -430px;}
@@ -94,13 +94,13 @@
94
94
  .wym_skin_refinery .wym_buttons li.wym_tools_preview a { background-position: 0 -408px;}
95
95
 
96
96
  /* make tools and containers play nicely next to eachother */
97
-
97
+
98
98
  .wym_skin_refinery .wym_tools, .wym_skin_refinery .wym_containers { float: left; margin: 0px 0px 5px 0px; }
99
-
99
+
100
100
  /* image replacements for containers */
101
101
  .wym_skin_refinery .wym_containers li { float: left; }
102
102
  .wym_skin_refinery .wym_containers li a, .wym_skin_refinery li.wym_tools_class a {background-repeat: no-repeat; background-position: center center;width: 20px; height: 20px; overflow: hidden; padding: 2px; border: 0px none;}
103
-
103
+
104
104
  .wym_skin_refinery li.wym_containers_h1 a { background-image: url('/images/wymeditor/skins/refinery/h1.png'); }
105
105
  .wym_skin_refinery li.wym_containers_h2 a { background-image: url('/images/wymeditor/skins/refinery/h2.png');}
106
106
  .wym_skin_refinery li.wym_containers_h3 a { background-image: url('/images/wymeditor/skins/refinery/h3.png');}
@@ -113,24 +113,24 @@
113
113
  /*DECORATION*/
114
114
  .wym_skin_refinery .wym_section h2 { background: #DDD; border: solid gray; border-width: 0 0 1px;}
115
115
  .wym_skin_refinery .wym_section h2 span { color: gray;}
116
- .wym_skin_refinery .wym_panel { padding: 0; border: solid gray; border-width: 1px; background: white;}
117
- .wym_skin_refinery .wym_panel ul { margin: 2px 0 5px; }
116
+ .wym_skin_refinery .wym_panel { padding: 0; border: solid gray; border-width: 1px; background: white;}
117
+ .wym_skin_refinery .wym_panel ul { margin: 2px 0 5px; }
118
118
  .wym_skin_refinery .wym_dropdown { padding: 0; border: solid gray; border-width: 1px 1px 0 1px; }
119
119
  .wym_skin_refinery .wym_dropdown ul { border: solid gray; border-width: 0 1px 1px 1px; margin-left: -1px; padding: 5px 10px 5px 3px;}
120
-
120
+
121
121
  /*DIALOGS*/
122
122
  .wym_dialog div.row { margin-bottom: 5px;}
123
123
  .wym_dialog div.row input { margin-right: 5px;}
124
124
  .wym_dialog div.row label { float: left; width: 150px; display: block; text-align: right; margin-right: 10px; }
125
125
  .wym_dialog div.row-indent { padding-left: 160px; }
126
- /*autoclearing*/
126
+ /*autoclearing*/
127
127
  .wym_dialog div.row:after { content: "."; display: block; height: 0; clear: both; visibility: hidden; }
128
128
  .wym_dialog div.row { display: inline-block; }
129
129
  /* Hides from IE-mac \*/
130
130
  * html .wym_dialog div.row { height: 1%; }
131
131
  .wym_dialog div.row { display: block; }
132
- /* End hide from IE-mac */
133
-
132
+ /* End hide from IE-mac */
133
+
134
134
  /*WYMEDITOR_LINK*/
135
135
  a.wym_wymeditor_link { text-indent: -9999px; float: right; display: block; width: 50px; height: 15px; background: url(../wymeditor_icon.png); overflow: hidden; text-decoration: none; }
136
136
 
@@ -175,7 +175,7 @@
175
175
  .wym_classes_hidden {
176
176
  display: none;
177
177
  }
178
- .wym_tools_class {
178
+ .wym_tools_class.activated {
179
179
  position: relative;
180
180
  }
181
181
  .wym_skin_refinery .wym_buttons .wym_tools_class .wym_classes li {
@@ -198,10 +198,10 @@
198
198
  font-style: italic;
199
199
  margin: 3px 0px 0px 6px;
200
200
  background: #EDEEDE;
201
-
201
+
202
202
  }
203
203
  .wym_skin_refinery .wym_tools_class .wym_tools_class_multiple_rules ul li {
204
-
204
+
205
205
  }
206
206
  .wym_skin_refinery .wym_tools_class .wym_classes .wym_tools_class_multiple_rules ul li a {
207
207
  width: 167px;
@@ -1,7 +1,7 @@
1
1
  # Allow the metal piece to run in isolation
2
2
  require(File.dirname(__FILE__) + "/../../config/environment") unless defined?(Rails)
3
3
 
4
- # Servers theme files from the them directory without touching Rails too much
4
+ # Serves theme files from the theme directory without touching Rails too much
5
5
  class ThemeServer
6
6
 
7
7
  def initialize(app)
@@ -9,26 +9,17 @@ class ThemeServer
9
9
  end
10
10
 
11
11
  def call(env)
12
- if env["PATH_INFO"] =~ /^\/theme/
13
- relative_path = env["PATH_INFO"].gsub(/^\/theme\//, '')
14
-
15
- if (file_path = Rails.root.join("themes", RefinerySetting[:theme], relative_path)).exist?
16
- # generate an etag for client-side caching.
17
- etag = Digest::MD5.hexdigest("#{file_path.to_s}#{file_path.mtime}")
18
- unless (env["HTTP_IF_NONE_MATCH"] == etag and RefinerySetting.find_or_set(:themes_use_etags, false))
19
- [200, {
20
- "Content-Type" => Rack::Mime.mime_type(file_path.extname),
21
- "ETag" => etag
22
- }, file_path.open]
23
- else
24
- [304, {"Content-Type" => Rack::Mime.mime_type(file_path.extname)}, "Not Modified"]
25
- end
12
+ relative_path = env["PATH_INFO"].gsub(/^\/theme\//, '')
13
+ if (env["PATH_INFO"]) =~ /^\/theme/ and (file_path=Rails.root.join("themes", RefinerySetting[:theme], relative_path)).exist?
14
+ unless ((etag = Digest::MD5.hexdigest("#{file_path.to_s}#{file_path.mtime}")) == env["HTTP_IF_NONE_MATCH"])
15
+ env["PATH_INFO"] = relative_path
16
+ status, headers, body = Rack::File.new(Rails.root.join("themes", RefinerySetting[:theme])).call(env)
17
+ [status, headers.update({"ETag" => etag}), body]
26
18
  else
27
- [404, {"Content-Type" => "text/html"}, ["Not Found"]]
19
+ [304, {"ETag" => etag}, []]
28
20
  end
29
21
  else
30
- status, headers, response = @app.call(env)
31
- [status, headers, response]
22
+ @app.call(env)
32
23
  end
33
24
  end
34
25
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: refinerycms
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.6.11
4
+ version: 0.9.6.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Resolve Digital