You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ckan-metadata-publisher-widget/src/main/java/org/gcube/portlets/widgets/ckandatapublisherwidget/client/ui/EditMetadataForm.ui.xml

229 lines
7.3 KiB
XML

<!DOCTYPE ui:UiBinder SYSTEM "http://dl.google.com/gwt/DTD/xhtml.ent">
<ui:UiBinder xmlns:ui="urn:ui:com.google.gwt.uibinder"
xmlns:g="urn:import:com.google.gwt.user.client.ui" xmlns:b="urn:import:com.github.gwtbootstrap.client.ui">
<ui:style>
.form-main-style {
margin-left: 10px;
}
.fieldset-border-style {
border: 1px groove #444;
-webkit-box-shadow: 0px 0px 0px 0px #000;
box-shadow: 0px 0px 0px 0px #000;
padding: 10px;
}
.legend-style {
width: auto;
padding: 10px;
margin-bottom: 0px;
}
@external .form-horizontal .input-large;
.form-horizontal .input-large {
width: 95%;
margin-bottom: 15px;
}
.block-alert-style {
margin-top: 10px;
padding: 10px;
}
</ui:style>
<g:HTMLPanel>
<b:Form type="HORIZONTAL" styleName="{style.form-main-style}"
ui:field="form">
<b:Fieldset styleName="{style.fieldset-border-style}">
<b:Legend styleName="{style.legend-style}">
Insert Dataset Metadata
<small>* is required</small>
</b:Legend>
<b:ControlGroup>
<b:ControlLabel for="title" title="Dataset title">
<font color="red">*</font>
Title :
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="Dataset title"
b:id="title" title="Dataset title" ui:field="titleTextBox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="url" title="Dataset url">
<font color="red">*</font>
URL:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="Dataset URL"
b:id="url" title="Dataset URL" ui:field="urlTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="description" title="Dataset description">
Description:
</b:ControlLabel>
<b:Controls>
<b:TextArea placeholder="eg. Some useful notes about the data"
alternateSize="LARGE" b:id="description" title="Dataset description"
ui:field="descriptionTextarea"></b:TextArea>
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="tags" title="Dataset tags">
Tags:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE"
placeholder="eg. economy, mental health, government" b:id="tags"
title="Dataset tags" ui:field="tagsTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="licenses" title="License">License:</b:ControlLabel>
<b:Controls>
<b:ListBox b:id="licenses" title="Dataset license"
width="70%" ui:field="licenseListbox">
</b:ListBox>
<span style="float:right; width:256px; color: #aaaaaa;">
<b:Icon type="INFO_SIGN" size="TWO_TIMES" />
License definitions and additional information can be found at
<a href="http://opendefinition.org/licenses/">opendefinition.org</a>
</span>
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="visibility" title="Visibility">Visibility:</b:ControlLabel>
<b:Controls>
<b:ListBox b:id="visibility" title="Dataset visibility"
width="70%" ui:field="visibilityListbox">
<g:item title="private">Private</g:item>
<g:item enabled="true" title="public">Public</g:item>
</b:ListBox>
<span style="float:right; width:256px; color: #aaaaaa;">
<b:Icon type="INFO_SIGN" size="TWO_TIMES" />
Private datasets can only be accessed by certain users, while
public datasets can be accessed by anyone.
</span>
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="searchable" title="Searchable">Searchable:</b:ControlLabel>
<b:Controls>
<b:ListBox b:id="searchable" title="Dataset searchable"
width="70%" ui:field="searchableListbox">
<g:item enabled="true" title="true">true</g:item>
<g:item title="false">false</g:item>
</b:ListBox>
<span style="float:right; width:256px;color: #aaaaaa;">
<b:Icon type="INFO_SIGN" size="TWO_TIMES" />
Searchable datasets can be searched by anyone, while
not-searchable datasets can only be accessed by entering directly
its URL.
</span>
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="source" title="Dataset source">
Source:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE"
placeholder="http://example.com/dataset.json" b:id="source"
title="Dataset source" ui:field="sourceTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="version" title="Dataset version">
Version:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="1.0" b:id="version"
title="Dataset version" ui:field="versionTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="author" title="Dataset author">
Author:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="Joe Bloggs"
b:id="author" title="Dataset author" ui:field="authorTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="email" title="Dataset author's email">
Author Email:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="joe.bloggs@example.com"
b:id="email" title="Dataset author" ui:field="authorEmailTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="maintainer" title="Dataset maintainer">
Maintainer:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="Joe Bloggs"
b:id="maintainer" title="Dataset maintainer" ui:field="maintainerTextbox" />
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:ControlLabel for="emailMaintaner" title="Dataset author's email">
Maintainer Email:
</b:ControlLabel>
<b:Controls>
<b:TextBox alternateSize="LARGE" placeholder="maintainer@example.com"
b:id="emailMaintaner" title="Dataset author" ui:field="maintainerEmailTextbox" />
</b:Controls>
</b:ControlGroup>
<!-- Custom fields can be dinamically added -->
<b:ControlGroup ui:field="customFields">
<b:ControlLabel>Custom Field:</b:ControlLabel>
<b:Controls>
<b:InputAddOn prependText="Key:">
<b:TextBox ui:field="keyField" />
</b:InputAddOn>
<b:InputAddOn prependText="Value:">
<b:TextBox ui:field="valueField" />
</b:InputAddOn>
</b:Controls>
</b:ControlGroup>
<b:ControlGroup>
<b:Controls>
<b:Button icon="PLUS_SIGN" title="Add Custom Field"
ui:field="addCustomFieldButton"></b:Button>
</b:Controls>
</b:ControlGroup>
<b:Button title="Create dataset" ui:field="createButton"
type="PRIMARY" block="true">Create</b:Button>
<b:Button title="Reset" ui:field="resetButton" block="true">Reset</b:Button>
<b:AlertBlock type="ERROR" close="false" animation="true"
visible="false" ui:field="errorBlock" styleName="{style.block-alert-style}"></b:AlertBlock>
<b:AlertBlock type="SUCCESS" close="false" animation="true"
visible="false" ui:field="successBlock" styleName="{style.block-alert-style}"></b:AlertBlock>
</b:Fieldset>
</b:Form>
</g:HTMLPanel>
</ui:UiBinder>