Merge branch 'master' of https://github.com/r888888888/danbooru
This commit is contained in:
@@ -315,7 +315,7 @@ Danbooru.Note = {
|
|||||||
set_text: function($note_body, $note_box, text) {
|
set_text: function($note_body, $note_box, text) {
|
||||||
Danbooru.Note.Body.display_text($note_body, text);
|
Danbooru.Note.Body.display_text($note_body, text);
|
||||||
if (Danbooru.Note.embed) {
|
if (Danbooru.Note.embed) {
|
||||||
Danbooru.Note.Body.display_text($note_box.children("div"), text);
|
Danbooru.Note.Body.display_text($note_box.children("div.note-box-inner-border"), text);
|
||||||
}
|
}
|
||||||
Danbooru.Note.Body.resize($note_body);
|
Danbooru.Note.Body.resize($note_body);
|
||||||
Danbooru.Note.Body.bound_position($note_body);
|
Danbooru.Note.Body.bound_position($note_body);
|
||||||
@@ -475,6 +475,7 @@ Danbooru.Note = {
|
|||||||
Danbooru.Note.Body.set_text($note_body, $note_box, "Loading...");
|
Danbooru.Note.Body.set_text($note_body, $note_box, "Loading...");
|
||||||
$.get("/note_previews.json", {body: text}).success(function(data) {
|
$.get("/note_previews.json", {body: text}).success(function(data) {
|
||||||
Danbooru.Note.Body.set_text($note_body, $note_box, data.body);
|
Danbooru.Note.Body.set_text($note_body, $note_box, data.body);
|
||||||
|
Danbooru.Note.Box.resize_inner_border($note_box);
|
||||||
$note_body.show();
|
$note_body.show();
|
||||||
});
|
});
|
||||||
$this.dialog("close");
|
$this.dialog("close");
|
||||||
@@ -721,7 +722,7 @@ Danbooru.Note = {
|
|||||||
Danbooru.Note.Box.scale($note_box);
|
Danbooru.Note.Box.scale($note_box);
|
||||||
Danbooru.Note.Body.display_text($note_body, text);
|
Danbooru.Note.Body.display_text($note_body, text);
|
||||||
if (Danbooru.Note.embed) {
|
if (Danbooru.Note.embed) {
|
||||||
Danbooru.Note.Body.display_text($note_box.children("div"), text);
|
Danbooru.Note.Body.display_text($note_box.children("div.note-box-inner-border"), text);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
@@ -2,126 +2,126 @@
|
|||||||
<div id="a-new">
|
<div id="a-new">
|
||||||
<h1>Upload</h1>
|
<h1>Upload</h1>
|
||||||
|
|
||||||
<div id="upload-guide-notice">
|
<% if CurrentUser.user.can_upload? %>
|
||||||
<p>Before uploading, please read the <%= link_to "how to upload guide", wiki_pages_path(:title => "howto:upload") %>.</p>
|
<div id="upload-guide-notice">
|
||||||
</div>
|
<p>Before uploading, please read the <%= link_to "how to upload guide", wiki_pages_path(:title => "howto:upload") %>.</p>
|
||||||
|
|
||||||
<% unless CurrentUser.user.can_upload? %>
|
|
||||||
<h2 style="margin-bottom: 1em;">You <%= CurrentUser.user.upload_limited_reason %></h2>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<%= render "image" %>
|
|
||||||
<%= render "post", :post => @post %>
|
|
||||||
<%= render "sources/info", :source => @source %>
|
|
||||||
|
|
||||||
<%= error_messages_for "upload" %>
|
|
||||||
|
|
||||||
<%= form_for(@upload, :html => {:multipart => true, :class => "simple_form", :id => "form"}) do |f| %>
|
|
||||||
<%= hidden_field_tag :normalized_url, @normalized_url %>
|
|
||||||
|
|
||||||
<% if CurrentUser.is_contributor? %>
|
|
||||||
<div class="input">
|
|
||||||
<label for="upload_as_pending">
|
|
||||||
<%= f.check_box :as_pending %>
|
|
||||||
Upload for approval
|
|
||||||
</label>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<div class="input">
|
|
||||||
<%= f.label :file %>
|
|
||||||
<%= f.file_field :file, :size => 50 %>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="input">
|
<%= render "image" %>
|
||||||
<%= f.label :source %>
|
<%= render "post", :post => @post %>
|
||||||
<% if params[:url].present? %>
|
<%= render "sources/info", :source => @source %>
|
||||||
<%= f.text_field :source, :size => 50, :value => params[:url] %>
|
|
||||||
<% else %>
|
|
||||||
<%= f.text_field :source, :size => 50 %>
|
|
||||||
<% end %>
|
|
||||||
<%= button_tag "Similar", :id => "similar-button", :type => "button" %>
|
|
||||||
<%= button_tag "Artist", :id => "find-artist-button", :type => "button" %>
|
|
||||||
<span class="hint">You can enter a URL to have <%= Danbooru.config.app_name %> automatically download and process it</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="input">
|
<%= error_messages_for "upload" %>
|
||||||
<%= f.label :rating %>
|
|
||||||
|
|
||||||
<fieldset class="ratings">
|
<%= form_for(@upload, :html => {:multipart => true, :class => "simple_form", :id => "form"}) do |f| %>
|
||||||
<%= f.radio_button :rating, :e %>
|
<%= hidden_field_tag :normalized_url, @normalized_url %>
|
||||||
<%= f.label :rating_e, "Explicit", :title => "Hardcore porn, visible genitals" %>
|
|
||||||
|
|
||||||
<%= f.radio_button :rating, :q %>
|
<% if CurrentUser.is_contributor? %>
|
||||||
<%= f.label :rating_q, "Questionable", :title => "Nudity, anything erotic" %>
|
<div class="input">
|
||||||
|
<label for="upload_as_pending">
|
||||||
<%= f.radio_button :rating, :s %>
|
<%= f.check_box :as_pending %>
|
||||||
<%= f.label :rating_s, "Safe", :title => "Everything else" %>
|
Upload for approval
|
||||||
</fieldset>
|
</label>
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="input">
|
|
||||||
<%= f.label :parent_id, "Parent ID" %>
|
|
||||||
<%= f.text_field :parent_id %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<% if @upload.has_artist_commentary? %>
|
|
||||||
<div class="input">
|
|
||||||
<%= f.label :artist_commentary_title, "Artist Commentary Title" %>
|
|
||||||
<%= f.text_field :artist_commentary_title, :value => @upload.artist_commentary_title %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="input">
|
|
||||||
<%= f.label :artist_commentary_desc, "Artist Commentary" %>
|
|
||||||
<%= f.text_area :artist_commentary_desc, :value => @upload.artist_commentary_desc, :size => "60x5" %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="input">
|
|
||||||
<label for="upload_include_artist_commentary">
|
|
||||||
<%= f.check_box :include_artist_commentary %>
|
|
||||||
Include Commentary
|
|
||||||
</label>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<% if Danbooru.config.iqdb_hostname_and_port %>
|
|
||||||
<% if params[:url] %>
|
|
||||||
<div class="input" id="iqdb-similar">
|
|
||||||
<p><em>Loading similar...</em></p>
|
|
||||||
</div>
|
</div>
|
||||||
<% else %>
|
|
||||||
<div class="input" id="iqdb-similar" style="display: none;"></div>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :file %>
|
||||||
|
<%= f.file_field :file, :size => 50 %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :source %>
|
||||||
|
<% if params[:url].present? %>
|
||||||
|
<%= f.text_field :source, :size => 50, :value => params[:url] %>
|
||||||
|
<% else %>
|
||||||
|
<%= f.text_field :source, :size => 50 %>
|
||||||
|
<% end %>
|
||||||
|
<%= button_tag "Similar", :id => "similar-button", :type => "button" %>
|
||||||
|
<%= button_tag "Artist", :id => "find-artist-button", :type => "button" %>
|
||||||
|
<span class="hint">You can enter a URL to have <%= Danbooru.config.app_name %> automatically download and process it</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :rating %>
|
||||||
|
|
||||||
|
<fieldset class="ratings">
|
||||||
|
<%= f.radio_button :rating, :e %>
|
||||||
|
<%= f.label :rating_e, "Explicit", :title => "Hardcore porn, visible genitals" %>
|
||||||
|
|
||||||
|
<%= f.radio_button :rating, :q %>
|
||||||
|
<%= f.label :rating_q, "Questionable", :title => "Nudity, anything erotic" %>
|
||||||
|
|
||||||
|
<%= f.radio_button :rating, :s %>
|
||||||
|
<%= f.label :rating_s, "Safe", :title => "Everything else" %>
|
||||||
|
</fieldset>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :parent_id, "Parent ID" %>
|
||||||
|
<%= f.text_field :parent_id %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<% if @upload.has_artist_commentary? %>
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :artist_commentary_title, "Artist Commentary Title" %>
|
||||||
|
<%= f.text_field :artist_commentary_title, :value => @upload.artist_commentary_title %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= f.label :artist_commentary_desc, "Artist Commentary" %>
|
||||||
|
<%= f.text_area :artist_commentary_desc, :value => @upload.artist_commentary_desc, :size => "60x5" %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<label for="upload_include_artist_commentary">
|
||||||
|
<%= f.check_box :include_artist_commentary %>
|
||||||
|
Include Commentary
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if Danbooru.config.iqdb_hostname_and_port %>
|
||||||
|
<% if params[:url] %>
|
||||||
|
<div class="input" id="iqdb-similar">
|
||||||
|
<p><em>Loading similar...</em></p>
|
||||||
|
</div>
|
||||||
|
<% else %>
|
||||||
|
<div class="input" id="iqdb-similar" style="display: none;"></div>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<div>
|
||||||
|
<%= f.label :tag_string, "Tags" %>
|
||||||
|
<%= f.text_area :tag_string, :size => "60x5" %>
|
||||||
|
<span id="open-edit-dialog" class="ui-icon ui-icon-arrow-1-ne" title="detach" style="display: none;"/>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<%= button_tag "Related tags", :id => "related-tags-button", :type => "button" %>
|
||||||
|
<%= button_tag "Artists", :id => "related-artists-button", :type => "button" %>
|
||||||
|
<%= button_tag "Characters", :id => "related-characters-button", :type => "button" %>
|
||||||
|
<%= button_tag "Copyrights", :id => "related-copyrights-button", :type => "button" %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="input">
|
||||||
|
<%= submit_tag "Submit", :class => "large" %>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="artist-tags-container">
|
||||||
|
<h1>Artist</h1>
|
||||||
|
<div id="artist-tags" class="related-tags">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div id="related-tags-container">
|
||||||
|
<h1>Related Tags <a href="#" id="toggle-related-tags-link" style="display: none;">«</a></h1>
|
||||||
|
<div id="related-tags" class="related-tags">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% else %>
|
||||||
<div class="input">
|
<h2 style="margin-bottom: 1em;">You <%= CurrentUser.user.upload_limited_reason %></h2>
|
||||||
<div>
|
|
||||||
<%= f.label :tag_string, "Tags" %>
|
|
||||||
<%= f.text_area :tag_string, :size => "60x5" %>
|
|
||||||
<span id="open-edit-dialog" class="ui-icon ui-icon-arrow-1-ne" title="detach" style="display: none;"/>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<%= button_tag "Related tags", :id => "related-tags-button", :type => "button" %>
|
|
||||||
<%= button_tag "Artists", :id => "related-artists-button", :type => "button" %>
|
|
||||||
<%= button_tag "Characters", :id => "related-characters-button", :type => "button" %>
|
|
||||||
<%= button_tag "Copyrights", :id => "related-copyrights-button", :type => "button" %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="input">
|
|
||||||
<%= submit_tag "Submit", :class => "large" %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="artist-tags-container">
|
|
||||||
<h1>Artist</h1>
|
|
||||||
<div id="artist-tags" class="related-tags">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div id="related-tags-container">
|
|
||||||
<h1>Related Tags <a href="#" id="toggle-related-tags-link" style="display: none;">«</a></h1>
|
|
||||||
<div id="related-tags" class="related-tags">
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user