Fixed Issue 138: Numbers should be right-justified

git-svn-id: http://google-refine.googlecode.com/svn/trunk@1404 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
David Huynh 2010-09-29 00:16:17 +00:00
parent 935355cb50
commit 3429595b0d
2 changed files with 12 additions and 0 deletions

View File

@ -32,6 +32,9 @@ DataTableCellUI.prototype._render = function() {
$('<span>').addClass("data-table-error").text(cell.e).appendTo(divContent);
} else if (!("r" in cell) || !cell.r) {
if (typeof cell.v !== "string") {
if (typeof cell.v == "number") {
divContent.addClass("data-table-cell-content-numeric");
}
$('<span>')
.addClass("data-table-value-nonstring")
.text(cell.v)

View File

@ -112,6 +112,10 @@ table.viewPanel-header td {
div.data-table-cell-content {
position: relative;
}
div.data-table-cell-content-numeric {
text-align: right;
}
a.data-table-cell-edit {
position: absolute;
top: 0px;
@ -128,6 +132,11 @@ a.data-table-cell-edit {
a.data-table-cell-edit:hover {
background-position: -30px 0px;
}
div.data-table-cell-content-numeric > a.data-table-cell-edit {
left: 0px;
right: auto;
}
.data-table-value-nonstring {
color: #880;
}