Changeset 5529
- Timestamp:
- 08/06/14 15:00:04 (10 years ago)
- Location:
- VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main
- Files:
-
- 1 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/TooltipBehavior.java
r5526 r5529 2 2 3 3 import org.apache.wicket.ResourceReference; 4 import org.apache.wicket.markup.html.resources.JavascriptResourceReference; 4 5 import org.apache.wicket.model.IModel; 5 6 import org.odlabs.wiquery.core.behavior.WiQueryAbstractBehavior; … … 17 18 public class TooltipBehavior extends WiQueryAbstractBehavior { 18 19 19 p rivate static final ResourceReferenceJAVASCRIPT_RESOURCE20 = new ResourceReference(TooltipBehavior.class, "jquery.qtip-1.0.0-rc3.min.js");20 public static final ResourceReference QTIP_JAVASCRIPT_RESOURCE 21 = new JavascriptResourceReference(TooltipBehavior.class, "jquery.qtip-1.0.0-rc3.min.js"); 21 22 22 23 private final IModel<String> tooltipModel; … … 28 29 @Override 29 30 public void contribute(WiQueryResourceManager wiQueryResourceManager) { 30 wiQueryResourceManager.addJavaScriptResource( JAVASCRIPT_RESOURCE);31 wiQueryResourceManager.addJavaScriptResource(QTIP_JAVASCRIPT_RESOURCE); 31 32 } 32 33 -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/wizard/CreateVirtualCollectionWizard$CreatorsStep.html
r5522 r5529 11 11 <div class="fieldset"> 12 12 <label>Creators<br /> 13 <a href="#" wicket:id="add" class="add"><span>[add]</span></a><br />14 <a href="#" wicket:id="addme" class="add"><span>[add me]</span></a>13 <a id="add" href="#" wicket:id="add" class="add tooltipparent"><span>[add]</span><span class="tooltip">Add a new creator</span></a><br /> 14 <a id="addme" href="#" wicket:id="addme" class="add tooltipparent"><span>[add me]</span><span class="tooltip">Add a new creator with the available user details already filled in</span></a> 15 15 </label> 16 16 <table wicket:id="creatorsTable" class="creatorsTable"></table> -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/wizard/CreateVirtualCollectionWizard$GeneralStep.html
r5436 r5529 1 1 <?xml version="1.0" encoding="UTF-8"?> 2 2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 3 3 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 4 4 <html xmlns="http://www.w3.org/1999/xhtml" xmlns:wicket="http://wicket.apache.org/"> 5 5 <head /> 6 <body> 7 <wicket:panel> 8 <div style="display: none" wicket:id="addKeywordDialog"></div> 9 <div style="display: none" wicket:id="deleteKeywordDialog"></div> 10 <fieldset> 11 <div class="notes"> 12 <h4>Some Notes</h4> 13 <p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem.</p> 14 <p class="last">Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo.</p> 15 </div> 16 <div class="required"> 17 <label for="gen_vc_name">Name</label> 18 <input wicket:id="name" 19 id="gen_vc_name" type="text" size="64" maxlength="255"/> 20 </div> 21 <div class="required"> 22 <label for="gen_vc_type">Type</label> 23 <select wicket:id="type" id="gen_vc_type"></select> 24 </div> 25 <div class="optional"> 26 <label for="gen_vc_desc">Description</label> 27 <textarea wicket:id="description" 28 id="gen_vc_desc" cols="80" rows="8"></textarea> 29 </div> 30 <div class="optional"> 31 <label for="gen_vc_purpose">Purpose</label> 32 <select wicket:id="purpose" id="gen_vc_purpose"></select> 33 </div> 34 <div class="optional"> 35 <label for="gen_vc_reproducibility">Reproducibility</label> 36 <select wicket:id="reproducibility" 37 id="gen_vc_reproducibility"></select> 38 </div> 39 <div class="optional"> 40 <label for="gen_vc_reproducibility_notice">Reproducibility Notice</label> 41 <textarea wicket:id="reproducibilityNotice" 42 id="gen_vc_reproducibility_notice" cols="80" rows="5"></textarea> 43 </div> 44 <div class="optional"> 45 <label>Keywords<br /><a href="#" 46 wicket:id="keywordsAdd" class="add"><span>[add]</span></a></label> 47 <div wicket:id="keywordsList" class="keywordsList"> 48 <ul> 49 <li wicket:id="keywords"> 50 <span wicket:id="itemText">item text</span> 51 <a wicket:id="itemRemove" href="#"><span class="delete">[delete]</span></a> 52 </li> 53 </ul> 54 </div> 55 </div> 56 </fieldset> 57 </wicket:panel> 58 </body> 6 <body> 7 <wicket:panel> 8 <div style="display: none" wicket:id="addKeywordDialog"></div> 9 <div style="display: none" wicket:id="deleteKeywordDialog"></div> 10 <fieldset> 11 <div class="notes"> 12 <h4>Provide general information</h4> 13 <p> 14 Use the form to fill in the general information for this virtual collection. 15 Name and type are mandatory. It is highly recommended to write a short description, 16 add one or more keywords and select a purpose and a reproducibility indication. 17 </p> 18 <p class="last"> 19 Hover over the labels of the individual fields to get more information. 20 </p> 21 </div> 22 <div class="required"> 23 <label id="namelabel" class="tooltipparent" for="gen_vc_name">Name 24 <span class="tooltip"> 25 A short but descriptive name of the virtual collection for listings and views 26 </span> 27 </label> 28 <input wicket:id="name" 29 id="gen_vc_name" type="text" size="64" maxlength="255"/> 30 </div> 31 <div class="required"> 32 <label id="typelabel" class="tooltipparent" for="gen_vc_type">Type 33 <span class="tooltip"> 34 Type of Virtual Collection, either intensional or extensional<br /><br /> 35 Extensional: Type of virtual collection that explicitly enumerates the references to resources or metadata documents that make up the collection<br /><br /> 36 Intensional: Type of virtual collection that defines a query by which the items of the collection can be retrieved ad-hoc from a secondary service <em>(experimental, use at own risk!)</em> 37 </span> 38 </label> 39 <select wicket:id="type" id="gen_vc_type"></select> 40 </div> 41 42 <div class="optional"> 43 <label id="descriptionlabel" class="tooltipparent" for="gen_vc_desc">Description 44 <span class="tooltip"> 45 A prose description of this virtual collection 46 </span> 47 </label> 48 <textarea wicket:id="description" 49 id="gen_vc_desc" cols="80" rows="8"></textarea> 50 </div> 51 <div class="optional"> 52 <label id="purposelabel" class="tooltipparent" for="gen_vc_purpose">Purpose 53 <span class="tooltip"> 54 An indication of the intended usage of the present virtual collection<br /><br /> 55 Research: The virtual collection bundles resources that are relevant to a specific research (question).<br /><br /> 56 Reference: The virtual collection bundles resources, that are to be cited in a publication.<br /><br /> 57 Sample: This virtual collection bundles is intended to serve as an sample for research data<br /><br /> 58 Future-use: The purpose of this virtual collection is not specified yet. Used in published collection is advised against. 59 </span> 60 </label> 61 <select wicket:id="purpose" id="gen_vc_purpose"></select> 62 </div> 63 <div class="optional"> 64 <label id="reproducibilitylabel" class="tooltipparent" for="gen_vc_reproducibility">Reproducibility 65 <span class="tooltip"> 66 An indication of the degree to which results obtained from processing of the present collection can be expected to be stable<br /><br /> 67 Intended: Processing results can be expected to remain stable<br /><br /> 68 Fluctuating: Processing results may vary<br /><br /> 69 Untended: No claims with respect to the stability of the processing results are made 70 </span> 71 </label> 72 <select wicket:id="reproducibility" 73 id="gen_vc_reproducibility"></select> 74 </div> 75 <div class="optional"> 76 <label id="repronotelabel" class="tooltipparent" for="gen_vc_reproducibility_notice">Reproducibility Notice 77 <span class="tooltip"> 78 Optional note describing the expected reproducibility of processing results in more detail 79 </span> 80 </label> 81 <textarea wicket:id="reproducibilityNotice" 82 id="gen_vc_reproducibility_notice" cols="80" rows="5"></textarea> 83 </div> 84 <div class="optional"> 85 <label id="keywordslabel" class="tooltipparent" >Keywords<br /><a href="#" 86 wicket:id="keywordsAdd" class="add"><span>[add]</span></a> 87 <span class="tooltip"> 88 A set of words or short phrases, each signifying a salient facet of the present virtual collection 89 </span> 90 </label> 91 <div wicket:id="keywordsList" class="keywordsList"> 92 <ul> 93 <li wicket:id="keywords"> 94 <span wicket:id="itemText">item text</span> 95 <a wicket:id="itemRemove" href="#"><span class="delete">[delete]</span></a> 96 </li> 97 </ul> 98 </div> 99 </div> 100 </fieldset> 101 </wicket:panel> 102 </body> 59 103 </html> -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/wizard/CreateVirtualCollectionWizard$GeneratedByStep.html
r5436 r5529 15 15 </div> 16 16 <div class="required"> 17 <label for="gen_desc">Description</label> 17 <label id="descriptionlabel" class="tooltipparent" for="gen_desc">Description 18 <span class="tooltip"> 19 A prose description of the procedure by which the collection items can be retrieved from the external service. 20 </span> 21 </label> 18 22 <textarea wicket:id="generatedBy.description" 19 23 id="gen_desc" rows="5" cols="80"></textarea> 20 24 </div> 21 25 <div class="optional"> 22 <label for="gen_uri">URI</label> 26 <label id="urilabel" class="tooltipparent" for="gen_uri">URI 27 <span class="tooltip"> 28 The location of the service from which the items should be retrieved. This value may be a persistent identifier, but could also be a plain URI although this is advised against for published collections. 29 </span> 30 </label> 23 31 <input wicket:id="generatedBy.uri" 24 32 id="gen_uri" type="text" size="64" maxlength="255" /> 25 33 </div> 26 34 <div class="optional"> 27 <label for="gen_query_profile">Query Profile</label> 35 <label id="profilelabel" class="tooltipparent" for="gen_query_profile">Query Profile 36 <span class="tooltip"> 37 Identifier of the mechanism, i.e. the protocol to be used, by which the members of the virtual collection should be retrieved. A application exploiting the query can use this to use a proper driver to talk to the service. Example: In case of CLARIN-FCS access the endpoint by FCS-compatible means. 38 </span> 39 </label> 28 40 <input wicket:id="generatedBy.query.profile" 29 41 id="gen_query_profile" type="text" size="64" maxlength="255" /> 30 42 </div> 31 43 <div class="optional"> 32 <label for="gen_query_value">Query value</label> 44 <label id="valuelabel" class="tooltipparent" for="gen_query_value">Query value 45 <span class="tooltip"> 46 The query that should be passed on to the service by which it can look up the items that are part of this collection. This value should be in the query language supported by the service. Example: In case of CLARIN-FCS, this value is the CQL query to be send to the endpoint. 47 </span> 48 </label> 33 49 <textarea wicket:id="generatedBy.query.value" 34 50 id="gen_query_value" rows="5" cols="80"></textarea> -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/wizard/CreateVirtualCollectionWizard$ResourcesStep.html
r5494 r5529 11 11 <div style="display: none" wicket:id="addResourcesDialog"></div> 12 12 <div wicket:id="resourcesContainer" class="fieldset"> 13 <label class="required">Resources<br /><a wicket:id="add" href="#" class="add"><span>[add]</span></a><br /><a wicket:id="addMore" href="#" class="addMore"><span>[add more]</span></a></label> 13 <label class="required">Resources<br /> 14 <a id="add" wicket:id="add" href="#" class="add tooltipparent"><span>[add]</span><span class="tooltip">Add a single new resource or metadata reference with an optional label and/or description</span></a><br /> 15 <a id="addmore" wicket:id="addMore" href="#" class="addMore tooltipparent"><span>[add more]</span><span class="tooltip">Add one or reference of the same type</span></a> 16 </label> 14 17 <table wicket:id="resourcesTable" class="resourcesTable"></table> 15 18 </div> -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/java/eu/clarin/cmdi/virtualcollectionregistry/gui/wizard/CreateVirtualCollectionWizard.java
r5527 r5529 2 2 3 3 import eu.clarin.cmdi.virtualcollectionregistry.gui.ApplicationSession; 4 import eu.clarin.cmdi.virtualcollectionregistry.gui.TooltipBehavior; 4 5 import eu.clarin.cmdi.virtualcollectionregistry.gui.VolatileEntityModel; 5 6 import eu.clarin.cmdi.virtualcollectionregistry.gui.dialog.ConfirmationDialog; … … 13 14 import java.util.List; 14 15 import org.apache.wicket.Component; 16 import org.apache.wicket.ResourceReference; 15 17 import org.apache.wicket.Session; 16 18 import org.apache.wicket.ajax.AjaxRequestTarget; … … 39 41 import org.apache.wicket.markup.html.form.TextField; 40 42 import org.apache.wicket.markup.html.form.validation.AbstractFormValidator; 43 import org.apache.wicket.markup.html.internal.HtmlHeaderContainer; 41 44 import org.apache.wicket.markup.html.list.ListItem; 42 45 import org.apache.wicket.markup.html.list.ListView; 43 46 import org.apache.wicket.markup.html.list.OddEvenListItem; 44 47 import org.apache.wicket.markup.html.panel.Panel; 48 import org.apache.wicket.markup.html.resources.JavascriptResourceReference; 45 49 import org.apache.wicket.markup.repeater.Item; 46 50 import org.apache.wicket.model.AbstractReadOnlyModel; … … 53 57 import org.apache.wicket.validation.validator.StringValidator; 54 58 import org.apache.wicket.validation.validator.UrlValidator; 59 import org.odlabs.wiquery.core.commons.CoreJavaScriptResourceReference; 55 60 56 61 @SuppressWarnings("serial") … … 59 64 @SpringBean 60 65 private CreatorProvider creatorProvider; 61 66 67 private final static ResourceReference TOOLTIP_JAVASCRIPT_REFERENCE = 68 new JavascriptResourceReference(CreateVirtualCollectionWizard.class, "tooltips.js"); 69 70 @Override 71 public void renderHead(HtmlHeaderContainer container) { 72 super.renderHead(container); 73 // Javascript dependencies for this page (jQuery tooltips) 74 container.getHeaderResponse().renderJavascriptReference(CoreJavaScriptResourceReference.get()); 75 container.getHeaderResponse().renderJavascriptReference(TooltipBehavior.QTIP_JAVASCRIPT_RESOURCE); 76 container.getHeaderResponse().renderJavascriptReference(TOOLTIP_JAVASCRIPT_REFERENCE); 77 } 78 62 79 private final class GeneralStep extends DynamicWizardStep { 63 80 … … 133 150 nameField.add(new StringValidator.MaximumLengthValidator(255)); 134 151 add(nameField); 152 135 153 final DropDownChoice<VirtualCollection.Type> typeChoice 136 154 = new DropDownChoice<VirtualCollection.Type>("type", … … 138 156 new EnumChoiceRenderer<VirtualCollection.Type>(this)); 139 157 typeChoice.setRequired(true); 158 // typeChoice.add(new TooltipBehavior(new StringResourceModel("type.tooltip", CreateVirtualCollectionWizard.this, null))); 140 159 add(typeChoice); 160 141 161 add(new TextArea<String>("description")); 142 162 final DropDownChoice<VirtualCollection.Purpose> purposeChoice -
VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/webapp/css/vcr.css
r5505 r5529 965 965 } 966 966 967 .tooltipparent .tooltip { 968 display: none; 969 }
Note: See TracChangeset
for help on using the changeset viewer.