Added custom suggest for types as well. Styled property and type suggest panes to be wider to accommodate long IDs.
Fixed event wiring bugs in recon dialog. Made cell edit popup wider and position it relative to the whole cell rather than to the edit link. git-svn-id: http://google-refine.googlecode.com/svn/trunk@212 7d457c2a-affb-35e4-300a-418c747d4874
This commit is contained in:
parent
f1bf446019
commit
7697365180
@ -1 +1 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Gridworks</title>
<link type="text/css" rel="stylesheet" href="externals/suggest/css/suggest-1.0.3.min.css" />
<link type="text/css" rel="stylesheet" href="externals/jquery-ui/css/ui-lightness/jquery-ui-1.7.2.custom.css" />
<link rel="stylesheet" href="/styles/common.css" />
<link rel="stylesheet" href="/styles/menu.css" />
<link rel="stylesheet" href="/styles/dialog.css" />
<link rel="stylesheet" href="/styles/project.css" />
<link rel="stylesheet" href="/styles/data-table-view.css" />
<link rel="stylesheet" href="/styles/history.css" />
<link rel="stylesheet" href="/styles/browsing.css" />
<link rel="stylesheet" href="/styles/process.css" />
<link rel="stylesheet" href="/styles/menu-bar.css" />
<link rel="stylesheet" href="/styles/expression-preview-dialog.css" />
<link rel="stylesheet" href="/styles/schema-alignment-dialog.css" />
<link rel="stylesheet" href="/styles/recon-dialog.css" />
<link rel="stylesheet" href="/styles/facet-based-edit-dialog.css" />
<script type="text/javascript" src="externals/jquery-1.4.1.min.js"></script>
<script type="text/javascript" src="externals/suggest/suggest-1.0.3.min.js"></script>
<script type="text/javascript" src="externals/jquery-ui/jquery-ui-1.7.2.custom.min.js"></script>
<script type="text/javascript" src="externals/date.js"></script>
<script type="text/javascript" src="scripts/util/misc.js"></script>
<script type="text/javascript" src="scripts/util/url.js"></script>
<script type="text/javascript" src="scripts/util/string.js"></script>
<script type="text/javascript" src="scripts/util/ajax.js"></script>
<script type="text/javascript" src="scripts/util/menu.js"></script>
<script type="text/javascript" src="scripts/util/dialog.js"></script>
<script type="text/javascript" src="scripts/util/dom.js"></script>
<script type="text/javascript" src="scripts/util/property-suggest.js"></script>
<script type="text/javascript" src="scripts/project.js"></script>
<script type="text/javascript" src="scripts/project/history-widget.js"></script>
<script type="text/javascript" src="scripts/project/process-widget.js"></script>
<script type="text/javascript" src="scripts/project/menu-bar.js"></script>
<script type="text/javascript" src="scripts/project/browsing-engine.js"></script>
<script type="text/javascript" src="scripts/project/scripting.js"></script>
<script type="text/javascript" src="scripts/facets/list-facet.js"></script>
<script type="text/javascript" src="scripts/facets/range-facet.js"></script>
<script type="text/javascript" src="scripts/facets/text-search-facet.js"></script>
<script type="text/javascript" src="scripts/views/data-table-view.js"></script>
<script type="text/javascript" src="scripts/views/data-table-cell-ui.js"></script>
<script type="text/javascript" src="scripts/views/data-table-column-header-ui.js"></script>
<script type="text/javascript" src="scripts/dialogs/recon-dialog.js"></script>
<script type="text/javascript" src="scripts/dialogs/expression-preview-dialog.js"></script>
<script type="text/javascript" src="scripts/dialogs/facet-based-edit-dialog.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment-ui-node.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment-ui-link.js"></script>
</head>
<body>
<div id="header">
<div id="path"><a class="app-path-section" href="./index.html">Gridworks</a> » </div>
</div>
<div id="body">
<div id="loading-message"><img src="images/large-spinner.gif" /> starting up ...</div>
</div>
</body>
</html>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Gridworks</title>
<link type="text/css" rel="stylesheet" href="externals/suggest/css/suggest-1.0.3.min.css" />
<link type="text/css" rel="stylesheet" href="externals/jquery-ui/css/ui-lightness/jquery-ui-1.7.2.custom.css" />
<link rel="stylesheet" href="/styles/common.css" />
<link rel="stylesheet" href="/styles/menu.css" />
<link rel="stylesheet" href="/styles/dialog.css" />
<link rel="stylesheet" href="/styles/project.css" />
<link rel="stylesheet" href="/styles/data-table-view.css" />
<link rel="stylesheet" href="/styles/history.css" />
<link rel="stylesheet" href="/styles/browsing.css" />
<link rel="stylesheet" href="/styles/process.css" />
<link rel="stylesheet" href="/styles/menu-bar.css" />
<link rel="stylesheet" href="/styles/expression-preview-dialog.css" />
<link rel="stylesheet" href="/styles/schema-alignment-dialog.css" />
<link rel="stylesheet" href="/styles/recon-dialog.css" />
<link rel="stylesheet" href="/styles/facet-based-edit-dialog.css" />
<link rel="stylesheet" href="/styles/custom-suggest.css" />
<script type="text/javascript" src="externals/jquery-1.4.1.min.js"></script>
<script type="text/javascript" src="externals/suggest/suggest-1.0.3.min.js"></script>
<script type="text/javascript" src="externals/jquery-ui/jquery-ui-1.7.2.custom.min.js"></script>
<script type="text/javascript" src="externals/date.js"></script>
<script type="text/javascript" src="scripts/util/misc.js"></script>
<script type="text/javascript" src="scripts/util/url.js"></script>
<script type="text/javascript" src="scripts/util/string.js"></script>
<script type="text/javascript" src="scripts/util/ajax.js"></script>
<script type="text/javascript" src="scripts/util/menu.js"></script>
<script type="text/javascript" src="scripts/util/dialog.js"></script>
<script type="text/javascript" src="scripts/util/dom.js"></script>
<script type="text/javascript" src="scripts/util/custom-suggest.js"></script>
<script type="text/javascript" src="scripts/project.js"></script>
<script type="text/javascript" src="scripts/project/history-widget.js"></script>
<script type="text/javascript" src="scripts/project/process-widget.js"></script>
<script type="text/javascript" src="scripts/project/menu-bar.js"></script>
<script type="text/javascript" src="scripts/project/browsing-engine.js"></script>
<script type="text/javascript" src="scripts/project/scripting.js"></script>
<script type="text/javascript" src="scripts/facets/list-facet.js"></script>
<script type="text/javascript" src="scripts/facets/range-facet.js"></script>
<script type="text/javascript" src="scripts/facets/text-search-facet.js"></script>
<script type="text/javascript" src="scripts/views/data-table-view.js"></script>
<script type="text/javascript" src="scripts/views/data-table-cell-ui.js"></script>
<script type="text/javascript" src="scripts/views/data-table-column-header-ui.js"></script>
<script type="text/javascript" src="scripts/dialogs/recon-dialog.js"></script>
<script type="text/javascript" src="scripts/dialogs/expression-preview-dialog.js"></script>
<script type="text/javascript" src="scripts/dialogs/facet-based-edit-dialog.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment-ui-node.js"></script>
<script type="text/javascript" src="scripts/protograph/schema-alignment-ui-link.js"></script>
</head>
<body>
<div id="header">
<div id="path"><a class="app-path-section" href="./index.html">Gridworks</a> » </div>
</div>
<div id="body">
<div id="loading-message"><img src="images/large-spinner.gif" /> starting up ...</div>
</div>
</body>
</html>
|
@ -171,8 +171,10 @@ ReconDialog.prototype._populateDialog = function() {
|
||||
};
|
||||
|
||||
ReconDialog.prototype._wireEvents = function() {
|
||||
var self = this;
|
||||
|
||||
this._elmts.heuristicTypeInput
|
||||
.suggest({ type : '/type/type' })
|
||||
.suggestT({ type : '/type/type' })
|
||||
.bind("fb-select", function(e, data) {
|
||||
$('input[name="recon-dialog-type-choice"][value=""]').attr("checked", "true");
|
||||
|
||||
|
@ -435,7 +435,7 @@ SchemaAlignmentDialog.UINode.prototype._showNodeConfigDialog = function() {
|
||||
|
||||
elmts.anonymousNodeTypeInput
|
||||
.bind("focus", function() { elmts.radioNodeTypeAnonymous[0].checked = true; })
|
||||
.suggest({ type: "/type/type" });
|
||||
.suggestT({ type: "/type/type" });
|
||||
|
||||
elmts.topicNodeTypeInput
|
||||
.bind("focus", function() { elmts.radioNodeTypeTopic[0].checked = true; })
|
||||
@ -459,7 +459,7 @@ SchemaAlignmentDialog.UINode.prototype._showNodeConfigDialog = function() {
|
||||
elmts.radioNodeTypeCellAs[0].checked = true;
|
||||
elmts.radioNodeTypeCellAsTopic[0].checked = true;
|
||||
})
|
||||
.suggest({ type: "/type/type" });
|
||||
.suggestT({ type: "/type/type" });
|
||||
|
||||
elmts.cellAsValueTypeSelect
|
||||
.bind("focus", function() {
|
||||
|
@ -3,6 +3,9 @@
|
||||
response: $.suggest.suggest.prototype.response
|
||||
};
|
||||
|
||||
/*
|
||||
* Property suggest
|
||||
*/
|
||||
$.suggest(
|
||||
"suggestP",
|
||||
$.extend(
|
||||
@ -60,6 +63,52 @@
|
||||
true,
|
||||
{},
|
||||
$.suggest.suggest.defaults, {
|
||||
css: { pane: "fbs-pane fbs-pane-property" }
|
||||
}
|
||||
)
|
||||
}
|
||||
);
|
||||
|
||||
/*
|
||||
* Type suggest
|
||||
*/
|
||||
$.suggest(
|
||||
"suggestT",
|
||||
$.extend(
|
||||
true,
|
||||
{},
|
||||
$.suggest.suggest.prototype,
|
||||
{
|
||||
create_item: function(data, response_data) {
|
||||
var css = this.options.css;
|
||||
|
||||
var li = $("<li>").addClass(css.item);
|
||||
|
||||
var name = $("<div>")
|
||||
.addClass(css.item_name)
|
||||
.append(
|
||||
$("<label>")
|
||||
.append($.suggest.strongify(data.name || data.guid, response_data.prefix)));
|
||||
|
||||
data.name = name.text(); // this converts html escaped strings like "&" back to "&"
|
||||
li.append(name);
|
||||
|
||||
name.prepend($("<div>").addClass(css.item_type).text(data.id));
|
||||
|
||||
return li;
|
||||
}
|
||||
}
|
||||
)
|
||||
);
|
||||
|
||||
$.extend(
|
||||
$.suggest.suggestT,
|
||||
{
|
||||
defaults: $.extend(
|
||||
true,
|
||||
{},
|
||||
$.suggest.suggest.defaults, {
|
||||
css: { pane: "fbs-pane fbs-pane-type" }
|
||||
}
|
||||
)
|
||||
}
|
@ -288,7 +288,7 @@ DataTableCellUI.prototype._previewCandidateTopic = function(id, elmt) {
|
||||
DataTableCellUI.prototype._startEdit = function(elmt) {
|
||||
self = this;
|
||||
|
||||
var menu = MenuSystem.createMenu().width("300px");
|
||||
var menu = MenuSystem.createMenu().width("350px");
|
||||
menu.html(
|
||||
'<textarea class="data-table-cell-edit-editor" bind="textarea" />' +
|
||||
'<table class="data-table-cell-edit-layout">' +
|
||||
@ -308,7 +308,7 @@ DataTableCellUI.prototype._startEdit = function(elmt) {
|
||||
var elmts = DOM.bind(menu);
|
||||
|
||||
MenuSystem.showMenu(menu, function(){});
|
||||
MenuSystem.positionMenuLeftRight(menu, $(elmt));
|
||||
MenuSystem.positionMenuLeftRight(menu, $(this._td));
|
||||
|
||||
var commit = function() {
|
||||
var type = $('input["data-table-cell-edit-type"]:checked')[0].value;
|
||||
|
3
src/main/webapp/styles/custom-suggest.css
Normal file
3
src/main/webapp/styles/custom-suggest.css
Normal file
@ -0,0 +1,3 @@
|
||||
.fbs-pane-property, .fbs-pane-type {
|
||||
width: 400px;
|
||||
}
|
Loading…
Reference in New Issue
Block a user