Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Fetching contributors…

Cannot retrieve contributors at this time

109 lines (101 sloc) 5.01 kB
- content_for :head_content do
:javascript
$(function() {
var wizard = $('#wizard');
$("ul.arrows", wizard).tabs("div.panes > div", function(event, index) {
if (index > 0) {
var url = $("#content_url");
if (url.val() == '') {
url.siblings("label").addClass("wizard-errors")
return false;
}
url.siblings("label").removeClass("wizard-errors");
}
});
var api = $("ul.arrows", wizard).data("tabs");
// "next tab" button
$("input.button-input.next", wizard).click(function(event) {
event.preventDefault();
api.next();
});
// "previous tab" button
$("input.button-input.prev", wizard).click(function() {
event.preventDefault();
api.prev();
});
$('.toggle-embed-video').click(function(event) {
event.preventDefault();
$('textarea.embed-video', $(this).parents('fieldset.inputs')).removeClass('hide').show();
$(this).remove();
});
$('.toggle-embed-audio').click(function(event) {
event.preventDefault();
$('textarea.embed-audio', $(this).parents('fieldset.inputs')).removeClass('hide').show();
$(this).remove();
});
});
- content_for :sub_nav do
- unless MENU['stories']['new_article'].nil? and MENU['articles'].nil?
= render :partial => 'shared/subnav/news_subnav'
#left-col
.panel-2
.panel-bar
%h2= t('new_story_header')
.form-wrap
#wizard
#flowplayer-block
%ul.arrows
%li
%a{:href => "#"}= t('wizard.url')
%li
%a{:href => "#"}= t('wizard.details')
%li
%a{:href => "#"}= t('wizard.images')
%li
%a{:href => "#"}= t('wizard.more')
= semantic_form_for @story, :url => stories_path, :html => { :multipart => true, :class => "post_story" } do |form|
.panes
.panel1
%h1= t('wizard.add_story.title')
%fieldset
%p= t('wizard.add_story.instructions')
= form.inputs do
= form.input :url
= form.buttons do
= form.commit_button t('wizard.continue'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input next' }
-# = form.commit_button t('wizard.post_now'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input' }
.panel2
%h1= t('wizard.add_story.details_title')
%fieldset
%p= t('wizard.add_story.details_instructions')
= form.inputs do
= form.input :title
- if @story.newswire.present?
= form.input :newswire_id, :as => :hidden
= form.input :caption, :input_html => { :rows => '10', :cols => '20' }
= form.input :tags_string, :required => false, :hint => t('tags_hint'), :as => :tags
= form.buttons do
= form.commit_button t('wizard.continue'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input next' }
= form.commit_button t('wizard.post_now'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input create' }
= form.commit_button t('wizard.back'), :wrapper_html => { :class => 'float-left' }, :button_html => { :class => 'button-input prev' }
.panel3
= render :partial => 'shared/forms/images_simple', :locals => { :form => form, :item => @story }
#scrollbox
%a.prev.browse.left_scroll
.scrollable
.items
%a.next.browse.right_scroll
= form.buttons do
= form.commit_button t('wizard.continue'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input next' }
= form.commit_button t('wizard.post_now'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input' }
= form.commit_button t('wizard.back'), :wrapper_html => { :class => 'float-left' }, :button_html => { :class => 'button-input prev' }
.panel4
= render :partial => 'shared/forms/media_items_simple', :locals => { :form => form, :item => @story }
= form.buttons do
= form.commit_button t('wizard.post_now'), :wrapper_html => { :class => 'float-right' }, :button_html => { :class => 'button-input' }
= form.commit_button t('wizard.back'), :wrapper_html => { :class => 'float-left' }, :button_html => { :class => 'button-input prev' }
#right-col
.panel-1
.panel-bar
%h2= t('.new_story_bookmarklet_intro')
= render :partial => 'shared/bookmarklet_panel'
Jump to Line
Something went wrong with that request. Please try again.