zafu 0.8.3 → 0.8.4
Sign up to get free protection for your applications and to get access to all the features.
- data/History.txt +5 -0
- data/lib/zafu/info.rb +1 -1
- data/lib/zafu/node_context.rb +2 -1
- data/lib/zafu/parser.rb +1 -0
- data/lib/zafu/process/ajax.rb +0 -6
- data/test/node_context_test.rb +11 -0
- data/zafu.gemspec +2 -2
- metadata +5 -5
data/History.txt
CHANGED
data/lib/zafu/info.rb
CHANGED
data/lib/zafu/node_context.rb
CHANGED
@@ -52,6 +52,7 @@ module Zafu
|
|
52
52
|
def as_main(after_class = nil)
|
53
53
|
klass = after_class ? master_class(after_class) : single_class
|
54
54
|
res = self.class.new("@#{klass.to_s.underscore}", single_class, nil)
|
55
|
+
res.propagate_dom_scope! if @dom_scope
|
55
56
|
res.dom_prefix = self.dom_prefix
|
56
57
|
res
|
57
58
|
end
|
@@ -176,7 +177,7 @@ module Zafu
|
|
176
177
|
protected
|
177
178
|
# List of scopes defined in ancestry (used to generate dom_id).
|
178
179
|
def dom_scopes
|
179
|
-
return [@saved_dom_id] if @saved_dom_id
|
180
|
+
return [@saved_dom_id] if @dom_scope && @saved_dom_id
|
180
181
|
if @up
|
181
182
|
scopes = @up.dom_scopes
|
182
183
|
if @dom_scope
|
data/lib/zafu/parser.rb
CHANGED
data/lib/zafu/process/ajax.rb
CHANGED
@@ -36,12 +36,6 @@ module Zafu
|
|
36
36
|
end
|
37
37
|
|
38
38
|
if need_ajax?(each_block)
|
39
|
-
#node.dom_prefix = dom_name
|
40
|
-
# We need to build the templates for ajax rendering.
|
41
|
-
# HACK to avoid changing dom_prefix in drag&drop
|
42
|
-
|
43
|
-
# The bug with wrong prefix between drop inline and ajax result comes from
|
44
|
-
# here (see selenium test drop1 and drop2).
|
45
39
|
node.dom_prefix = dom_name
|
46
40
|
|
47
41
|
# 1. Render inline
|
data/test/node_context_test.rb
CHANGED
@@ -317,6 +317,17 @@ class NodeContextTest < Test::Unit::TestCase
|
|
317
317
|
end
|
318
318
|
end
|
319
319
|
end
|
320
|
+
|
321
|
+
context 'with a saved dom_id' do
|
322
|
+
setup do
|
323
|
+
@c.saved_dom_id = '#{ndom_id(@foo)}'
|
324
|
+
end
|
325
|
+
|
326
|
+
should 'not use saved id in scope' do
|
327
|
+
# We did not ask for dom_scope to propagate.
|
328
|
+
assert_equal '<%= %Q{b_#{var3.zip}} %>', subject.dom_id
|
329
|
+
end
|
330
|
+
end
|
320
331
|
|
321
332
|
context 'with ancestors and self as dom_scopes' do
|
322
333
|
setup do
|
data/zafu.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{zafu}
|
8
|
-
s.version = "0.8.
|
8
|
+
s.version = "0.8.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Gaspard Bucher"]
|
12
|
-
s.date = %q{2011-07-
|
12
|
+
s.date = %q{2011-07-17}
|
13
13
|
s.description = %q{Provides a powerful templating language based on xhtml for rails}
|
14
14
|
s.email = %q{gaspard@teti.ch}
|
15
15
|
s.extra_rdoc_files = [
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: zafu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 55
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 8
|
9
|
-
-
|
10
|
-
version: 0.8.
|
9
|
+
- 4
|
10
|
+
version: 0.8.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Gaspard Bucher
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-07-
|
18
|
+
date: 2011-07-17 00:00:00 +02:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -150,7 +150,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
150
150
|
requirements: []
|
151
151
|
|
152
152
|
rubyforge_project:
|
153
|
-
rubygems_version: 1.6.
|
153
|
+
rubygems_version: 1.6.2
|
154
154
|
signing_key:
|
155
155
|
specification_version: 3
|
156
156
|
summary: Provides a powerful templating language based on xhtml for rails
|