noodall-ui 0.1.8 → 0.1.9

Sign up to get free protection for your applications and to get access to all the features.
@@ -49,70 +49,81 @@
49
49
  <fieldset>
50
50
  <legend class="advanced">Advanced</legend>
51
51
  <div id="advanced">
52
- <p class="published">
53
- <%= f.label :published_at, "Publish at" %><br/>
54
- <span class="input-wrap"><%= f.datetime_select :published_at, :include_blank => true %></span>
55
- </p>
56
-
57
- <p class="published">
58
- <%= f.label :published_to, "Publish until" %><br/>
59
- <%
60
- # Remove select for far future dates
61
- @node.published_to = nil unless @node.published_to.nil? or @node.published_to < 5.years.from_now
62
- %>
63
- <span class="input-wrap"><%= f.datetime_select :published_to, :include_blank => true %></span>
64
- </p>
65
- <% unless @node.in_site_map? %>
66
- <p>
67
- <span class="node-mover">Parent Content</span>
68
- <span class="input-wrap" id="parent-title">
69
- <%= @node.root? ? "Root" : @node.parent.title %>
70
- <a href="#" class="edit-item">Edit</a>
71
- </span>
72
- <%= f.hidden_field :parent, :value => @node.parent_id %>
73
- <%= hidden_field_tag :parent_types, @node.class.parent_classes.join(','), :disabled => true %>
74
- </p>
75
- <p>
76
- <span class="tooltip" title="Enter a custom url or leave it as the default value shown.">&nbsp;</span>
77
- <%= f.label :permalink, 'Page Url' %><br/>
78
- <span class="input-wrap"><%= f.text_field :permalink %></span>
79
- </p>
80
- <% end %>
81
-
82
- <% if current_user.admin? -%>
83
- <fieldset>
84
- <span class="tooltip" title="User Permissions">&nbsp;</span>
85
- <legend>User Permission</legend>
86
- <span class="input-wrap">
87
- <table>
88
- <thead>
89
- <tr>
90
- <th width="85">Action</th>
91
- <th width="90%">Groups</th>
92
- </tr>
93
- </thead>
94
- <tbody>
95
- <tr>
96
- <th><%= f.label :updatable_groups_list, "Update" %></th>
97
- <td><%= f.text_field :updatable_groups_list, :class => "groups-completer" %></td>
98
- </tr>
99
- <tr>
100
- <th><%= f.label :publishable_groups_list, "Publish" %></th>
101
- <td><%= f.text_field :publishable_groups_list, :class => "groups-completer" %></td>
102
- </tr>
103
- <tr>
104
- <th><%= f.label :destroyable_groups_list, "Delete" %></th>
105
- <td><%= f.text_field :destroyable_groups_list, :class => "groups-completer" %></td>
106
- </tr>
107
- <tr>
108
- <th><%= f.label :viewable_groups_list, "View" %></th>
109
- <td><%= f.text_field :viewable_groups_list, :class => "groups-completer" %></td>
110
- </tr>
111
- </tbody>
112
- </table>
113
- </span>
114
- </fieldset>
115
- <% end -%>
52
+
53
+ <div class="published-section">
54
+ <p class="published">
55
+ <%= f.label :published_at, "Publish at" %><br/>
56
+ <span class="input-wrap"><%= f.datetime_select :published_at, :include_blank => true %></span>
57
+ </p>
58
+
59
+ <p class="published">
60
+ <%= f.label :published_to, "Publish until" %><br/>
61
+ <%
62
+ # Remove select for far future dates
63
+ @node.published_to = nil unless @node.published_to.nil? or @node.published_to < 5.years.from_now
64
+ %>
65
+ <span class="input-wrap"><%= f.datetime_select :published_to, :include_blank => true %></span>
66
+ </p>
67
+ </div>
68
+
69
+ <% if current_user.admin? -%>
70
+ <div class="permissions-section">
71
+ <fieldset>
72
+ <span class="tooltip" title="User Permissions">&nbsp;</span>
73
+ <legend>User Permission</legend>
74
+ <span class="input-wrap">
75
+ <table>
76
+ <thead>
77
+ <tr>
78
+ <th width="85">Action</th>
79
+ <th width="90%">Groups</th>
80
+ </tr>
81
+ </thead>
82
+ <tbody>
83
+ <tr>
84
+ <th><%= f.label :updatable_groups_list, "Update" %></th>
85
+ <td><%= f.text_field :updatable_groups_list, :class => "groups-completer" %></td>
86
+ </tr>
87
+ <tr>
88
+ <th><%= f.label :publishable_groups_list, "Publish" %></th>
89
+ <td><%= f.text_field :publishable_groups_list, :class => "groups-completer" %></td>
90
+ </tr>
91
+ <tr>
92
+ <th><%= f.label :destroyable_groups_list, "Delete" %></th>
93
+ <td><%= f.text_field :destroyable_groups_list, :class => "groups-completer" %></td>
94
+ </tr>
95
+ <tr>
96
+ <th><%= f.label :viewable_groups_list, "View" %></th>
97
+ <td><%= f.text_field :viewable_groups_list, :class => "groups-completer" %></td>
98
+ </tr>
99
+ </tbody>
100
+ </table>
101
+ </span>
102
+ </fieldset>
103
+ </div>
104
+ <% end -%>
105
+
106
+
107
+
108
+
109
+ <div class="position-section">
110
+ <% unless @node.in_site_map? %>
111
+ <p>
112
+ <span class="node-mover">Parent Content</span>
113
+ <span class="input-wrap" id="parent-title">
114
+ <%= @node.root? ? "Root" : @node.parent.title %>
115
+ <a href="#" class="edit-item">Edit</a>
116
+ </span>
117
+ <%= f.hidden_field :parent, :value => @node.parent_id %>
118
+ <%= hidden_field_tag :parent_types, @node.class.parent_classes.join(','), :disabled => true %>
119
+ </p>
120
+ <p>
121
+ <span class="tooltip" title="Enter a custom url or leave it as the default value shown.">&nbsp;</span>
122
+ <%= f.label :permalink, 'Page Url' %><br/>
123
+ <span class="input-wrap"><%= f.text_field :permalink %></span>
124
+ </p>
125
+ <% end %>
126
+ </div>
116
127
  </div>
117
128
  </fieldset>
118
129
  </div>
@@ -1,4 +1,4 @@
1
- <div id="<%%= slot_code %>" class="component <%= file_name.gsub(/_/ig, '-') %> <%%= 'double' if expand %> <%%= additional_classes %>">
1
+ <div id="<%%= slot_code %>" class="component <%= file_name.gsub(/_/, '-') %> <%%= 'double' if expand %> <%%= additional_classes %>">
2
2
  <% unless attributes.empty? %>
3
3
  <dl>
4
4
  <% for attribute in attributes -%>
@@ -2,9 +2,10 @@ module Noodall
2
2
  module Permalinks
3
3
  # Handy place for all the permalink methods
4
4
  def node_path(node, options = {})
5
- node_permalink_path node.permalink.to_s, options
5
+ node = node.is_a?(String) ? node : node.permalink.to_s
6
+ node_permalink_path node, options
6
7
  end
7
-
8
+
8
9
  def node_url(node, options = {})
9
10
  node_path(node, options.merge(:only_path => false))
10
11
  end
@@ -1,5 +1,5 @@
1
1
  module Noodall
2
2
  module UI
3
- VERSION = "0.1.8"
3
+ VERSION = "0.1.9"
4
4
  end
5
5
  end
@@ -704,6 +704,43 @@ li.multi-file span.file-title {
704
704
 
705
705
  li.multi-file .file-detail img {clear:both;float:left;}
706
706
 
707
+ /*Advanced Sections*/
708
+ .published-section {
709
+ width: 356px;
710
+ float:left;
711
+ }
712
+
713
+ .position-section {
714
+ width: 356px;
715
+ float:left;
716
+ margin: 0 0 0 10px;
717
+ }
718
+
719
+ .permissions-section {
720
+ width: 356px;
721
+ float:left;
722
+ margin: 0 0 0 10px;
723
+ }
724
+
725
+ .permissions-section legend {padding-bottom: 5px;}
726
+
727
+ .permissions-section fieldset {
728
+ margin: 0 !important;
729
+ min-width: 300px !important;
730
+ padding: 0 !important;
731
+ }
732
+
733
+ .permissions-section fieldset input {
734
+ margin-left:5px !important;
735
+ width: 98% !important;
736
+ }
737
+
738
+ #content form .position-section p {
739
+ min-width: 356px;
740
+ padding: 0 !important;
741
+ }
742
+
743
+
707
744
 
708
745
 
709
746
  /* -------------- CLEARFIX -------------- */
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: noodall-ui
3
3
  version: !ruby/object:Gem::Version
4
- hash: 11
4
+ hash: 9
5
5
  prerelease:
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 8
10
- version: 0.1.8
9
+ - 9
10
+ version: 0.1.9
11
11
  platform: ruby
12
12
  authors:
13
13
  - Steve England
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-01-21 00:00:00 +00:00
18
+ date: 2011-01-25 00:00:00 +00:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency