Commit 77296354 authored by Steffen van Bergerem's avatar Steffen van Bergerem Committed by Benjamin Neff

Replace publisher_textarea_wrapper with publisher-textarea-wrapper

parent caeaf23d
......@@ -36,7 +36,7 @@ app.views.Publisher = Backbone.View.extend({
// init shortcut references to the various elements
this.inputEl = this.$("#status_message_text");
this.wrapperEl = this.$("#publisher_textarea_wrapper");
this.wrapperEl = this.$("#publisher-textarea-wrapper");
this.submitEl = this.$("input[type=submit], button#submit");
this.photozoneEl = this.$("#photodropzone");
......@@ -87,7 +87,7 @@ app.views.Publisher = Backbone.View.extend({
},
initSubviews: function() {
this.mention = new app.views.PublisherMention({ el: this.$("#publisher_textarea_wrapper") });
this.mention = new app.views.PublisherMention({ el: this.$("#publisher-textarea-wrapper") });
if(this.prefillMention) {
this.mention.prefillMention([this.prefillMention]);
}
......
......@@ -33,7 +33,7 @@ function createUploader(){
$("#fileInfo-publisher").text(fileName + " " + progress + "%");
},
onSubmit: function() {
$("#publisher_textarea_wrapper").addClass("with_attachments");
$("#publisher-textarea-wrapper").addClass("with_attachments");
$("#photodropzone").append(
"<li class='publisher_photo loading' style='position:relative;'>" +
"<img alt='Ajax-loader2' src='" + ImagePaths.get("ajax-loader2.gif") + "' />" +
......@@ -50,7 +50,7 @@ function createUploader(){
url = responseJSON.data.photo.unprocessed_image.url,
currentPlaceholder = $("li.loading").first();
$("#publisher_textarea_wrapper").addClass("with_attachments");
$("#publisher-textarea-wrapper").addClass("with_attachments");
$("#new_status_message").append("<input type='hidden' value='" + id + "' name='photos[]' />");
// replace image placeholders
......@@ -76,7 +76,7 @@ function createUploader(){
photo.fadeOut(400, function() {
photo.remove();
if ($(".publisher_photo").length === 0) {
$("#publisher_textarea_wrapper").removeClass("with_attachments");
$("#publisher-textarea-wrapper").removeClass("with_attachments");
}
});
}
......
/* Raw CSS */
body {
#publisher_textarea_wrapper > #button_container > span.markdownIndications > a {
#publisher-textarea-wrapper > #button_container > span.markdownIndications > a {
color: fade-out($link-color, 0.4);
}
......
......@@ -3,7 +3,7 @@
body {
.publisher {
form {
#publisher_textarea_wrapper { background-color: $gray; }
#publisher-textarea-wrapper { background-color: $gray; }
.btn.btn-link.question_mark:hover .entypo-cog { color: $gray-light; }
}
.publisher-buttonbar .btn.btn-link:hover i { color: $gray-light; }
......
......@@ -694,7 +694,7 @@ select#aspect_ids_ {
.entypo-camera { margin-right: 0; }
}
#publisher_textarea_wrapper {
#publisher-textarea-wrapper {
border-radius: 2px;
margin: 12px 0px;
background: $framed-background;
......
......@@ -14,7 +14,7 @@
display: none !important;
}
#publisher_textarea_wrapper { border: 1px solid $border-grey !important; }
#publisher-textarea-wrapper { border: 1px solid $border-grey !important; }
}
.container-fluid{ padding: 0; }
......@@ -64,7 +64,7 @@
}
}
#publisher_textarea_wrapper {
#publisher-textarea-wrapper {
background-color: white;
border-radius: 3px;
border: 1px solid $border-dark-grey;
......
......@@ -3,7 +3,7 @@
= form_for(StatusMessage.new) do |status|
= status.error_messages
%params
.publisher-textarea-wrapper#publisher_textarea_wrapper
.publisher-textarea-wrapper#publisher-textarea-wrapper
- if current_user.getting_started?
= status.text_area :text, :rows => 2, :value => h(publisher_formatted_text),
:tabindex => 1, :placeholder => "#{t('contacts.index.start_a_conversation')}...",
......
......@@ -27,7 +27,7 @@
= #{aspect.name}"
.clear
#publisher_textarea_wrapper
#publisher-textarea-wrapper
%ul#photodropzone
#fileInfo-publisher
......
......@@ -73,7 +73,7 @@ Then /^the publisher should be expanded$/ do
end
Then /^the text area wrapper mobile should be with attachments$/ do
find("#publisher_textarea_wrapper")["class"].should include("with_attachments")
find("#publisher-textarea-wrapper")["class"].should include("with_attachments")
end
And /^I want to mention (?:him|her) from the profile$/ do
......
......@@ -12,7 +12,7 @@ module PublishingCukeHelpers
def upload_file_with_publisher(path)
page.execute_script(%q{$("input[name='qqfile']").css("opacity", '1');})
with_scope("#publisher_textarea_wrapper") do
with_scope("#publisher-textarea-wrapper") do
attach_file("qqfile", Rails.root.join(path).to_s)
# wait for the image to be ready
page.assert_selector(".publisher_photo.loading", count: 0)
......
......@@ -10,7 +10,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we are signed in
expect(response.body).not_to match(/a class="login"/)
expect(response.body).to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
it "displays the publisher for people path" do
......@@ -19,7 +19,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we are signed in
expect(response.body).not_to match(/a class="login"/)
expect(response.body).to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
it "doesn't display the publisher for people photos path" do
......@@ -28,7 +28,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we are signed in
expect(response.body).not_to match(/a class="login"/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
end
......@@ -43,7 +43,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we are signed in
expect(response.body).not_to match(/a class="login"/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
it "doesn't display the publisher for people path" do
......@@ -52,7 +52,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we are signed in
expect(response.body).not_to match(/a class="login"/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
end
......@@ -63,7 +63,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we aren't signed in
expect(response.body).to match(/a class="login"/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
it "doesn't display the publisher for people path" do
......@@ -72,7 +72,7 @@ describe PeopleController, type: :request do
expect(response.status).to eq(200)
# make sure we aren't signed in
expect(response.body).to match(/a class="login"/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/)
expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher-textarea-wrapper'/)
end
end
end
......@@ -519,7 +519,7 @@ describe("app.views.Publisher", function() {
setFixtures(
'<div id="publisher">'+
' <div class="content_creation"><form>'+
' <div id="publisher_textarea_wrapper"></div>'+
' <div id="publisher-textarea-wrapper"></div>'+
' <div id="photodropzone"></div>'+
' <input type="submit" />'+
' </form></div>'+
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment