Changeset 416

Show
Ignore:
Timestamp:
04/30/07 23:11:55 (1 year ago)
Author:
danshep
Message:

facets: merged changes from the mental branch r357:406

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/facets/radiant/CONTRIBUTORS

    r335 r416  
    88* Alexander Horn 
    99* Adam Williams 
     10* Sean Santry 
    1011* Sean Cribbs 
    1112* Brian Gernhardt 
     
    1415* Jesse Newland 
    1516* Josh Ferguson 
    16 * Adam Williams 
    17 * Daniel Shepherd 
     17* Daniel Sheppard 
     18* Matte Edens 
     19* Jacob Burkhart 
     20* Chris Parrish 
    1821 
    1922=== 0.5.1 Gemdust 
    20 * Daniel Shepherd 
     23* Daniel Sheppard 
    2124* Paul Smith 
    2225* Bodhi Philpot 
  • branches/facets/radiant/app/controllers/admin/page_controller.rb

    r363 r416  
    11class Admin::PageController < Admin::AbstractModelController 
    22  model_class Page 
    3    
     3  before_filter :initialize_meta_rows_and_buttons, :only => [:new, :edit] 
     4 
    45  attr_accessor :cache 
    56 
     
    8081      end 
    8182    end 
    82      
     83 
     84    def initialize_meta_rows_and_buttons 
     85      @buttons_partials ||= [] 
     86      @meta ||= [] 
     87      @meta << {:field => "slug", :type => "text_field", :args => [{:class => 'textbox', :maxlength => 100}]} 
     88      @meta << {:field => "breadcrumb", :type => "text_field", :args => [{:class => 'textbox', :maxlength => 160}]} 
     89    end 
     90      
    8391    def announce_cache_cleared 
    8492      flash[:notice] = "The page cache was successfully cleared." 
     
    8694     
    8795    def save 
    88       original_names = @page.parts.map { |part| part.name } 
    89       new_names = (params[:part] || {}).values.map { |part| part[:name]
    90       names_to_remove = (original_names - new_names) 
     96      parts = @page.parts 
     97      parts_to_update = {
     98      (params[:part]||{}).each {|k,v| parts_to_update[v[:name]] = v } 
    9199       
    92       parts_to_update = [] 
    93       (params[:part] || {}).values.each do |v| 
    94         if part = @page.parts.find_by_name(v[:name]) 
    95           part.attributes = part.attributes.merge(v) 
    96           parts_to_update << part 
     100      parts_to_remove = [] 
     101      @page.parts.each do |part| 
     102        if(attrs = parts_to_update.delete(part.name)) 
     103          part.attributes = part.attributes.merge(attrs) 
    97104        else 
    98           @page.parts.build(v) 
     105          parts_to_remove << part 
    99106        end 
    100107      end 
     108      parts_to_update.values.each do |attrs| 
     109        @page.parts.build(attrs) 
     110      end 
    101111      if result = @page.save 
    102         names_to_remove.each { |name| @page.parts.find_by_name(name).destroy } 
    103         parts_to_update.each { |part| part.save } 
     112        new_parts = @page.parts - parts_to_remove 
     113        new_parts.each {|x| x.save} 
     114        @page.parts = new_parts 
    104115      end 
    105116      result 
  • branches/facets/radiant/app/controllers/site_controller.rb

    r358 r416  
    2929    end 
    3030 
     31    def process_page(page) 
     32      page.process(request, response) 
     33    end 
     34     
    3135    def show_uncached_page(url) 
    3236      @page = find_page(url) 
    3337      unless @page.nil? 
    34         @page.process(request, response) 
     38        process_page(@page) 
    3539        @cache.cache_response(url, response) if live? and @page.cache? 
    3640        @performed_render = true 
  • branches/facets/radiant/app/models/radiant/config.rb

    r358 r416  
    5151      end 
    5252    end 
     53     
     54    def value=(param) 
     55      write_attribute :value, param.to_s 
     56    end 
     57     
     58    def value 
     59      if key.ends_with? "?" 
     60        read_attribute(:value) == "true" 
     61      else 
     62        read_attribute(:value) 
     63      end 
     64    end 
    5365  end 
    5466end 
  • branches/facets/radiant/app/models/standard_tags.rb

    r358 r416  
    312312   
    313313  desc %{  
    314     Renders the date that a page was published (or in the event that it has 
    315     not been modified yet, the date that it was created). The format attribute 
    316     uses the same formating codes used by the Ruby @strftime@ function. By 
    317     default it's set to @%A, %B %d, %Y@. 
     314    Renders the date based on the current page (by default when it was published or created).  
     315    The format attribute uses the same formating codes used by the Ruby @strftime@ function. By 
     316    default it's set to @%A, %B %d, %Y@.  The @for@ attribute selects which date to render.  Valid 
     317    options are @published_at@, @created_at@, @updated_at@, and @now@. @now@ will render the 
     318    current date/time, regardless of the  page. 
    318319    
    319320    *Usage:*   
    320     <pre><code><r:date [format="format_string"] /></code></pre> 
     321    <pre><code><r:date [format="%A, %B %d, %Y"] [when="published_at"]/></code></pre> 
    321322  } 
    322323  tag 'date' do |tag| 
    323324    page = tag.locals.page 
    324325    format = (tag.attr['format'] || '%A, %B %d, %Y') 
    325     if date = page.published_at || page.created_at 
    326       date.strftime(format) 
    327     end 
     326    time_attr = tag.attr['for'] 
     327    date = if time_attr 
     328      case 
     329      when time_attr == 'now' 
     330        Time.now 
     331      when ['published_at', 'created_at', 'updated_at'].include?(time_attr) 
     332        page[time_attr] 
     333      else 
     334        raise TagError, "Invalid value for 'when' attribute." 
     335      end 
     336    else 
     337      page.published_at || page.created_at 
     338    end 
     339    date.strftime(format)  
    328340  end 
    329341   
  • branches/facets/radiant/app/views/admin/layout/edit.rhtml

    r363 r416  
    1515      <table class="fieldset" cellpadding="0" cellspacing="0" border="0"> 
    1616        <tr> 
    17           <td><label for="layout_content_type">Content-Type</label></td> 
     17          <td class="label"><label for="layout_content_type">Content&#8209;Type</label></td> 
    1818          <td class="field"><%= text_field "layout", "content_type", :class => 'textbox', :maxlength => 40 %></td> 
    1919        </tr> 
  • branches/facets/radiant/app/views/admin/page/_edit_buttons.rhtml

    r315 r416  
    11  <p class="buttons"> 
     2    <% @buttons_partials.each do |partial| %> 
     3      <%= render :partial => partial %> 
     4    <% end %>   
    25    <%= save_model_button(@page) %>  
    36    <%= save_model_and_continue_editing_button(@page) %>  
  • branches/facets/radiant/app/views/admin/page/_edit_extended_metadata.rhtml

    r315 r416  
     1<% content_for :page_css do %> 
     2      #content #extended-metadata .fieldset { 
     3        margin-left: 0; 
     4        margin-right: 0; 
     5        margin-bottom: .5em; 
     6        padding: 0; 
     7      } 
     8      #content #extended-metadata .fieldset td.label { 
     9        text-align: left; 
     10        width: 15%; 
     11      } 
     12      #content #extended-metadata .fieldset td.field .textbox { 
     13        width: 90%; 
     14      } 
     15<% end %> 
     16 
    117<div id="extended-metadata" class="row"<%= meta_visible(:meta) %>> 
    218    <table class="fieldset" cellpadding="0" cellspacing="0" border="0"> 
    3       <tr> 
    4         <td><label for="page_slug">Slug</label></td> 
    5         <td class="field"><%= text_field "page", "slug", :class => 'textbox', :maxlength => 100 %></td> 
    6       </tr> 
    7       <tr> 
    8         <td><label for="page_breadcrumb">Breadcrumb</label></td> 
    9         <td class="field"><%= text_field "page", "breadcrumb", :class => 'textbox', :maxlength => 160 %></td> 
    10       </tr> 
     19      <% for meta in @meta %> 
     20        <%= render :partial => "meta_row", :object => meta %> 
     21      <% end %> 
    1122      <%= render_region :extended_metadata %> 
    1223    </table> 
     
    2233        $old_title = $title.value; 
    2334      } 
    24       Event.observe('page_title', 'keyup', title_updated); 
     35      new Form.Element.Observer('page_title', 0.15, title_updated); 
    2536    // ]]> 
    2637    </script> 
  • branches/facets/radiant/app/views/admin/page/_edit_popups.rhtml

    r358 r416  
    11<% include_javascript "tag_reference_search" %>  
    22 
    3 <div id="popups"
    4   <div class="popup" id="add-part-popup" style="display:none;"> 
     3<% content_for :popups do %
     4  <div class="popup" id="add-part-popup" style="display: none"> 
    55    <div id="busy" class="busy" style="display: none"><%= image 'spinner.gif' %></div> 
    66    <h3>Add Part</h3> 
     
    2222  </div> 
    2323  <div class="popup" id="tag-reference-popup" style="display:none;"> 
    24     <div style="float:right">search tags:<input type="text" id="search-tag-reference"></div>  
    25        <%= javascript_tag "new Form.Element.Observer('search-tag-reference', 0.5, observeTagSearch);" %>   
     24    <div style="float:right">Search Tags: <input type="text" id="search-tag-reference"></div> 
     25    <%= javascript_tag "new Form.Element.Observer('search-tag-reference', 0.5, observeTagSearch);" %> 
    2626    <h3>Available Tags for <span id="page-type"><%= @page.class.display_name %></span></h3> 
    2727    <div id="tag-reference"><%= tag_reference(@page.class.name) %></div> 
     
    2929  </div> 
    3030  <div class="popup" id="filter-reference-popup" style="display:none;"> 
    31     <h3>Reference for <span id="filter-type"><%= default_filter_name %></span> Filter</h3> 
     31    <h3><span id="filter-type"><%= default_filter_name %></span> Reference</h3> 
    3232    <div id="filter-reference"><%= filter_reference(default_filter_name) %></div> 
    3333    <p><%= link_to_function 'Close', "Element.hide('filter-reference-popup')", :class => 'close-link' %></p> 
    3434  </div> 
    3535  <%= render_region :popups %> 
    36 </div
     36<% end -%
  • branches/facets/radiant/app/views/admin/page/_edit_scripts_and_styles.rhtml

    r317 r416  
    33        var header = $('header') 
    44        element = $(element); 
    5         element.style.position = 'fixed' 
    6         var dim = Element.getDimensions(element) 
    7         element.style.top = '200px'; 
     5        element.style.position = 'absolute'; 
     6        var dim = Element.getDimensions(element); 
     7        var top = document.documentElement.scrollTop ? document.documentElement 
     8.scrollTop : document.body.scrollTop; 
     9        element.style.top = (top + 200) + 'px'; 
    810        element.style.left = ((header.offsetWidth - dim.width) / 2) + 'px'; 
    911      } 
  • branches/facets/radiant/app/views/admin/user/edit.rhtml

    r363 r416  
    2929    </tr> 
    3030    <tr> 
    31       <td class="label"><label for="user_password_confirmation">Confirm Password</label></td> 
     31      <td class="label"><label for="user_password_confirmation">Confirm&nbsp;Password</label></td> 
    3232      <td class="field"><%= password_field "user", "password_confirmation", :class => 'textbox', :value => '', :maxlength => 40 %></td> 
    3333    </tr> 
  • branches/facets/radiant/app/views/layouts/application.rhtml

    r296 r416  
    2828  </head> 
    2929  <body> 
    30     <div id="header"> 
    31       <div id="site-title"><%= link_to_unless_current title, admin_url %></div> 
    32       <div id="site-subtitle"><%= subtitle %></div> 
     30    <div id="page"> 
     31      <div id="header"> 
     32        <div id="site-title"><%= link_to_unless_current title, admin_url %></div> 
     33        <div id="site-subtitle"><%= subtitle %></div> 
    3334<% if logged_in? -%> 
    34       <div id="navigation"> 
    35         <%= links_for_navigation %> 
     35        <div id="navigation"> 
     36          <%= links_for_navigation %> 
     37        </div> 
     38<% end -%> 
    3639      </div> 
    37 <% end -%> 
    38     </div> 
    39     <hr class="hidden" /> 
    40     <div id="main"> 
     40      <hr class="hidden" /> 
     41      <div id="main"> 
    4142<% if flash[:notice] -%> 
    42       <div id="notice"> 
    43         <p><%= flash[:notice] %></p> 
    44       </div> 
     43        <div id="notice"> 
     44          <p><%= flash[:notice] %></p> 
     45        </div> 
    4546<% end -%> 
    4647<% if flash[:error] -%> 
    47       <div id="error"> 
    48         <p><%= flash[:error] %></p> 
     48        <div id="error"> 
     49          <p><%= flash[:error] %></p> 
     50        </div> 
     51<% end -%> 
     52        <div id="content"> 
     53<%= yield %> 
     54        </div> 
    4955      </div> 
     56      <hr class="hidden" /> 
     57      <div id="footer"> 
     58        <p>This site was made with Ruby and is powered by <a href="http://radiantcms.org">Radiant CMS</a> 
     59          version <%= Radiant::Version %><% if Radiant.loaded_via_gem? %> (gem)<% end %>.</p> 
     60        <p id="site-links"> 
     61<% if logged_in? -%> 
     62  <% if admin? -%> 
     63          <%= nav_link_to 'Users', user_index_url %> 
     64          <span class="separator"> | </span> 
     65          <%= nav_link_to 'Extensions', extension_index_url %> 
     66  <% else -%> 
     67          <%= nav_link_to 'Preferences', user_preferences_url %> 
     68  <% end -%> 
     69          <span class="separator"> | </span> 
     70          <%= nav_link_to 'Log Out', logout_url %> 
     71          <span class="separator"> | </span> 
    5072<% end -%> 
    51       <div id="content"
    52 <%= yield%
     73          <%= link_to image('view-site.gif', :alt => 'View Site', :title => '', :align => 'center'), homepage_url %
     74        </p
    5375      </div> 
    5476    </div> 
    55     <hr class="hidden" /> 
    56     <div id="footer"> 
    57       <p>This site was made with Ruby and is powered by <a href="http://radiantcms.org">Radiant CMS</a> 
    58         version <%= Radiant::Version %><% if Radiant.loaded_via_gem? %> (gem)<% end %>.</p> 
    59       <p id="site-links"> 
    60 <% if logged_in? -%> 
    61   <% if admin? -%> 
    62         <%= nav_link_to 'Users', user_index_url %> 
    63         <span class="separator"> | </span> 
    64         <%= nav_link_to 'Extensions', extension_index_url %> 
    65   <% else -%> 
    66         <%= nav_link_to 'Preferences', user_preferences_url %> 
    67   <% end -%> 
    68         <span class="separator"> | </span> 
    69         <%= nav_link_to 'Log Out', logout_url %> 
    70         <span class="separator"> | </span> 
     77<% if @content_for_popups -%> 
     78    <div id="popups"> 
     79<%= yield :popups %> 
     80    </div> 
    7181<% end -%> 
    72         <%= link_to image('view-site.gif', :alt => 'View Site', :title => '', :align => 'center'), homepage_url %> 
    73       </p> 
    74     </div> 
    7582  </body> 
    7683</html> 
  • branches/facets/radiant/db/migrate/010_merge_behaviors_and_pages.rb

    r126 r416  
    11class MergeBehaviorsAndPages < ActiveRecord::Migration 
     2  class OldPage < ActiveRecord::Base 
     3    set_table_name 'pages' 
     4  end 
     5   
    26  @@page_map = { 
    37    "Page Missing" => "FileNotFoundPage" 
     
    1923  def self.down 
    2024    rename_column :pages, :type, :behavior_id 
    21     Page.reset_column_information 
     25    OldPage.reset_column_information 
    2226    announce "converting class names back to behavior names" 
    23     Page.find(:all).each do |page| 
     27    OldPage.find(:all).each do |page| 
    2428      unless page.behavior_id.blank? 
    2529        page.behavior_id = behavior_name(page.behavior_id) 
     
    4953    end 
    5054  end 
     55   
     56 
    5157end 
  • branches/facets/radiant/db/schema.rb

    r358 r416  
    33# then regenerate this schema definition. 
    44 
    5 ActiveRecord::Schema.define(:version => 14) do 
     5ActiveRecord::Schema.define(:version => 15) do 
    66 
    77  create_table "attachments", :force => true do |t| 
     
    4444    t.column "updated_by",   :integer 
    4545    t.column "content_type", :string,   :limit => 40 
     46    t.column "lock_version", :integer,                 :default => 0 
    4647  end 
    4748 
     
    6768    t.column "updated_by",   :integer 
    6869    t.column "virtual",      :boolean,                 :default => false, :null => false 
     70    t.column "lock_version", :integer,                 :default => 0 
    6971  end 
    7072 
    7173  create_table "snippets", :force => true do |t| 
    72     t.column "name",       :string,   :limit => 100, :default => "", :null => false 
    73     t.column "filter_id",  :string,   :limit => 25 
    74     t.column "content",    :text 
    75     t.column "created_at", :datetime 
    76     t.column "updated_at", :datetime 
    77     t.column "created_by", :integer 
    78     t.column "updated_by", :integer 
     74    t.column "name",         :string,   :limit => 100, :default => "", :null => false 
     75    t.column "filter_id",    :string,   :limit => 25 
     76    t.column "content",      :text 
     77    t.column "created_at",   :datetime 
     78    t.column "updated_at",   :datetime 
     79    t.column "created_by",   :integer 
     80    t.column "updated_by",   :integer 
     81    t.column "lock_version", :integer,                 :default => 0 
    7982  end 
    8083 
     
    8285 
    8386  create_table "users", :force => true do |t| 
    84     t.column "name",       :string,   :limit => 100 
    85     t.column "email",      :string 
    86     t.column "login",      :string,   :limit => 40,  :default => "",    :null => false 
    87     t.column "password",   :string,   :limit => 40 
    88     t.column "created_at", :datetime 
    89     t.column "updated_at", :datetime 
    90     t.column "created_by", :integer 
    91     t.column "updated_by", :integer 
    92     t.column "admin",      :boolean,                 :default => false, :null => false 
    93     t.column "developer",  :boolean,                 :default => false, :null => false 
    94     t.column "notes",      :text 
     87    t.column "name",         :string,   :limit => 100 
     88    t.column "email",        :string 
     89    t.column "login",        :string,   :limit => 40,  :default => "",    :null => false 
     90    t.column "password",     :string,   :limit => 40 
     91    t.column "created_at",   :datetime 
     92    t.column "updated_at",   :datetime 
     93    t.column "created_by",   :integer 
     94    t.column "updated_by",   :integer 
     95    t.column "admin",        :boolean,                 :default => false, :null => false 
     96    t.column "developer",    :boolean,                 :default => false, :null => false 
     97    t.column "notes",        :text 
     98    t.column "lock_version", :integer,                 :default => 0 
    9599  end 
    96100 
  • branches/facets/radiant/lib/generators/extension/extension_generator.rb

    r188 r416  
    11class ExtensionGenerator < Rails::Generator::NamedBase 
    22  attr_reader :extension_path, :extension_file_name 
    3  
     3   
    44  def initialize(runtime_args, runtime_options = {}) 
    55    super 
     
    77    @extension_path = "vendor/extensions/#{file_name}" 
    88  end 
    9  
     9   
    1010  def manifest 
    1111    record do |m| 
     
    1616      m.directory "#{extension_path}/db/migrate" 
    1717      m.directory "#{extension_path}/lib/tasks" 
     18      m.directory "#{extension_path}/test/fixtures" 
    1819      m.directory "#{extension_path}/test/functional" 
    1920      m.directory "#{extension_path}/test/unit" 
     
    2122      m.template 'README',              "#{extension_path}/README" 
    2223      m.template 'Rakefile',            "#{extension_path}/Rakefile" 
    23       m.template "extension.rb",        "#{extension_path}/#{extension_file_name}.rb" 
    24       m.template "migration.rb",        "#{extension_path}/db/migrate/001_create_#{extension_file_name}_schema.rb" 
     24      m.template 'extension.rb',        "#{extension_path}/#{extension_file_name}.rb" 
    2525      m.template 'tasks.rake',          "#{extension_path}/lib/tasks/#{extension_file_name}_tasks.rake" 
    2626      m.template 'test_helper.rb',      "#{extension_path}/test/test_helper.rb" 
  • branches/facets/radiant/lib/generators/extension/templates/functional_test.rb

    r358 r416  
    99   
    1010  def test_initialization 
    11     assert_equal File.join(File.expand_path(RADIANT_ROOT), 'vendor', 'extensions', '<%= file_name %>'), <%= class_name %>.root 
     11    assert_equal File.join(File.expand_path(RAILS_ROOT), 'vendor', 'extensions', '<%= file_name %>'), <%= class_name %>.root 
    1212    assert_equal '<%= extension_name %>', <%= class_name %>.extension_name 
    1313  end 
  • branches/facets/radiant/lib/generators/extension/templates/test_helper.rb

    r358 r416  
    1 require File.dirname(__FILE__) + "/../../../../test/test_helper" unless defined? TEST_ROOT 
     1# Load the the environment 
     2unless defined? RADIANT_ROOT 
     3  ENV["RAILS_ENV"] = "test" 
     4  require "#{File.expand_path(File.dirname(__FILE__) + "/../../../../")}/config/boot" 
     5end 
     6require "#{RADIANT_ROOT}/test/test_helper" 
    27 
    3 class <%= class_name %>Test < Test::Unit::TestCase 
    4   test_helper :extension_fixtures, :extension_tags 
    5   self.extension_fixture_path = File.dirname(__FILE__) + "/fixtures" 
     8class Test::Unit::TestCase 
     9   
     10  # Include a helper to make testing Radius tags easier 
     11  test_helper :extension_tags 
     12   
     13  # Add the fixture directory to the fixture path 
     14  self.fixture_path << File.dirname(__FILE__) + "/fixtures" 
     15   
     16  # Add more helper methods to be used by all extension tests here... 
     17   
    618end 
  • branches/facets/radiant/lib/plugins/extension_patches/init.rb

    r164 r416  
    22require 'view_paths_extension' 
    33require 'mailer_view_paths_extension' 
     4require 'generator_base_extension' 
     5require 'fixture_loading_extension' 
  • branches/facets/radiant/lib/radiant/setup.rb

    r358 r416  
    151151       
    152152      def model(model_name) 
    153         Object.const_get(model_name.to_s.singularize) 
     153        model_name.to_s.singularize.constantize 
    154154      end 
    155155       
  • branches/facets/radiant/lib/tasks/extensions.rake

    r299 r416  
    1212 
    1313namespace :test do 
    14   Rake::TestTask.new(:extensions => "db:test:prepare") do |t| 
    15     t.libs << "test" 
    16     t.pattern = 'vendor/extensions/**/test/**/*_test.rb' 
    17     t.verbose = true 
     14  desc "Runs tests on all available Radiant extensions" 
     15  task :extensions => "db:test:prepare" do 
     16    Dir["#{RAILS_ROOT}/vendor/extensions/*"].sort.select { |f| File.directory?(f) }.each do |directory| 
     17      chdir directory do 
     18        system "rake test" 
     19      end 
     20    end 
    1821  end 
    19   Rake::Task["test:extensions"].comment = "Runs tests on all available Radiant extensions" 
    2022end 
    2123 
  • branches/facets/radiant/public/stylesheets/admin/main.css

    r358 r416  
    2121  color: red; 
    2222} 
     23 
    2324 
    2425/* main layout */ 
     
    227228  text-decoration: none; 
    228229} 
    229  
    230230#content table.index .node.virtual .page a .title, #content table.index .node.virtual .page a:visited .title { 
    231231  color: #9eb3bf; 
    232232} 
    233  
    234233#content table.index .node .page a:hover .title, #content table.index .node .page a:visited:hover .title, 
    235234#content table.index .node .snippet a:hover, #content table.index .node .snippet a:visited:hover, 
     
    267266  padding-bottom: 6px; 
    268267} 
     268 
    269269 
    270270/* form elements */ 
     
    277277  padding-top: 15px; 
    278278  padding-bottom: 10px; 
     279  width:100%; 
    279280} 
    280281#content .form-area h3 { 
     
    296297#content .form-area .title { 
    297298  margin-bottom: 0; 
     299  width:100%; 
    298300} 
    299301#content .form-area .title label { 
    300302  display: block; 
     303  position: relative; 
    301304} 
    302305#content .form-area .title .textbox { 
     
    311314#content .form-area .row { 
    312315  clear: both; 
    313   margin-top: 1em
    314 
    315 #content .form-area .row p, 
    316 #content .form-area .row .fieldset
     316  margin: 1em 0
     317  width: 100%; 
     318
     319#content .form-area .row p
    317320  float: left; 
    318321  margin-right: 2em; 
     
    327330#content .form-area .fieldset { 
    328331  margin-right: .5em; 
    329 } 
    330 #content .form-area .fieldset td { 
    331   padding-right: .5em; 
    332332} 
    333333#content .form-area .error-with-field .error { 
     
    346346#content table.fieldset { 
    347347  border-bottom: 1px solid #DFD3C3; 
    348   margin-bottom: 1.5em; 
     348  margin-bottom: .3em; 
    349349  width: 100%; 
    350350} 
     
    356356#content table.fieldset td.label { 
    357357  padding-top: 10px; 
     358  padding-right: 8px; 
    358359  vertical-align: top; 
    359   text-align: right; 
    360   width: 20%; 
     360  whitespace: nowrap; 
     361  width: 1%; 
     362  text-align: left; 
     363
     364#content .fieldset label { 
     365  font-weight: normal; 
    361366} 
    362367#content table.fieldset td.label .optional { 
    363368  color: #929488; 
    364369} 
    365 #content table.fieldset td.field .textbox { 
    366   width: 100%; 
     370#content table.fieldset td.field { 
     371  padding-left: 0px; 
     372  padding-right: 10px; 
     373  text-align: right; 
     374
     375#content #extended-metadata .fieldset td.field { 
     376  width: 100%; 
     377
     378#content table.fieldset td.field .textbox, 
     379#content table.fieldset td.field textarea { 
     380  width: 99.5%; 
     381  margin-right: -5px; 
    367382} 
    368383#content table.fieldset td.help { 
    369384  background-color: #F5F1E2; 
    370385  font-size: 80%; 
    371   padding-left: 10px; 
    372   width: 40%; 
     386  padding: 0 10px; 
     387  width: 31%; 
    373388} 
    374389#content table.fieldset input { 
     
    379394  float: left; 
    380395  padding-top: 4px; 
     396  padding-left: 10px; 
    381397  width: 10em; 
     398  text-align: left; 
    382399} 
    383400#content table.fieldset textarea { 
     
    392409  color: red; 
    393410} 
     411 
    394412 
    395413/* tabs */ 
     
    440458  border-top-width: 0; 
    441459} 
    442 #content textarea { 
     460#content .textarea { 
    443461  height: 280px; 
    444462  border: 1px solid #cdc295; 
     
    454472/* popups */ 
    455473 
    456 #content .popup { 
     474#popups .popup { 
    457475  background-color: white; 
    458476  border: 5px solid silver; 
     
    461479  padding-bottom: .5em; 
    462480} 
    463 #content .popup .busy { 
     481#popups .popup .busy { 
    464482  float: right; 
    465483} 
    466 #content .popup h3 { 
     484#popups .popup h3 { 
    467485  margin-top: 0; 
    468486} 
    469 #content .popup .close-link { 
     487#popups .popup .close-link { 
    470488  font-size: 85%; 
    471489} 
    472490