fix pad.ma info page css

This commit is contained in:
rolux 2013-02-09 15:01:05 +05:30
parent 3bc4973017
commit 8e0024ae1d

View file

@ -6,6 +6,7 @@ pandora.ui.infoView = function(data) {
descriptions = [], descriptions = [],
canEdit = pandora.site.capabilities.canEditMetadata[pandora.user.level] || data.editable, canEdit = pandora.site.capabilities.canEditMetadata[pandora.user.level] || data.editable,
css = { css = {
display: 'inline-block',
marginTop: '4px', marginTop: '4px',
textAlign: 'justify', textAlign: 'justify',
MozUserSelect: 'text', MozUserSelect: 'text',
@ -185,12 +186,12 @@ pandora.ui.infoView = function(data) {
type: 'textarea', type: 'textarea',
value: data[key + 'description'] || '' value: data[key + 'description'] || ''
}) })
.css(css)
.bindEvent({ .bindEvent({
submit: function(event) { submit: function(event) {
editMetadata(key + 'description', event.value); editMetadata(key + 'description', event.value);
} }
}) })
.css(css)
).css({ ).css({
'margin-top': '8px', 'margin-top': '8px',
}) })
@ -273,7 +274,7 @@ pandora.ui.infoView = function(data) {
// Director, Cinematographer and Featuring --------------------------------- // Director, Cinematographer and Featuring ---------------------------------
if (canEdit) { if (canEdit) {
$div = $('<div>').css(css).css('clear', 'both').appendTo($center); $div = $('<div>').css(css).appendTo($center);
['director', 'cinematographer', 'featuring'].forEach(function(key, i) { ['director', 'cinematographer', 'featuring'].forEach(function(key, i) {
i && $('<div>').css({float: 'left'}).html(';&nbsp;').appendTo($div); i && $('<div>').css({float: 'left'}).html(';&nbsp;').appendTo($div);
$('<div>') $('<div>')
@ -317,7 +318,7 @@ pandora.ui.infoView = function(data) {
if (canEdit) { if (canEdit) {
var key = 'topic'; var key = 'topic';
$div = $('<div>').css(css).css('clear', 'both').appendTo($center); $div = $('<div>').css(css).appendTo($center);
$('<div>') $('<div>')
.css({float: 'left'}) .css({float: 'left'})
.html(formatKey('Topics').replace('</span>', '&nbsp;</span>')) .html(formatKey('Topics').replace('</span>', '&nbsp;</span>'))
@ -363,12 +364,12 @@ pandora.ui.infoView = function(data) {
value: data.summary || '', value: data.summary || '',
//width: 300 //width: 300
}) })
.css(css)
.bindEvent({ .bindEvent({
submit: function(event) { submit: function(event) {
editMetadata('summary', event.value); editMetadata('summary', event.value);
} }
}) })
.css(css)
) )
.appendTo($center); .appendTo($center);
} else if (data.summary) { } else if (data.summary) {