Index: editor/frontend/src/main/java/org/hippoecm/frontend/editor/plugins/ValueTemplatePlugin.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- editor/frontend/src/main/java/org/hippoecm/frontend/editor/plugins/ValueTemplatePlugin.java	(revision 57721)
+++ editor/frontend/src/main/java/org/hippoecm/frontend/editor/plugins/ValueTemplatePlugin.java	(revision )
@@ -21,16 +21,21 @@
 import org.apache.wicket.util.string.Strings;
 import org.hippoecm.frontend.model.IModelReference;
 import org.hippoecm.frontend.model.properties.JcrPropertyValueModel;
+import org.hippoecm.frontend.model.properties.LongConverter;
 import org.hippoecm.frontend.model.properties.StringConverter;
 import org.hippoecm.frontend.plugin.IPluginContext;
 import org.hippoecm.frontend.plugin.config.IPluginConfig;
 import org.hippoecm.frontend.plugins.standards.diff.TextDiffModel;
 import org.hippoecm.frontend.service.IEditor;
 import org.hippoecm.frontend.service.render.RenderPlugin;
+import org.hippoecm.frontend.widgets.AjaxUpdatingWidget;
+import org.hippoecm.frontend.widgets.NumberFieldWidget;
 import org.hippoecm.frontend.widgets.TextFieldWidget;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import javax.jcr.PropertyType;
+
 public class ValueTemplatePlugin extends RenderPlugin<String> {
 
     private static final long serialVersionUID = 1L;
@@ -44,13 +49,26 @@
         final IEditor.Mode mode = IEditor.Mode.fromString(config.getString("mode"), IEditor.Mode.VIEW);
         switch (mode) {
             case EDIT:
-                TextFieldWidget widget = new TextFieldWidget("value", stringModel);
+                AjaxUpdatingWidget widget;
+                if (((JcrPropertyValueModel) getModel()).getType() == PropertyType.LONG) {
+                    final LongConverter longModel = new LongConverter((JcrPropertyValueModel) getModel());
+
+                    widget = new NumberFieldWidget("value", longModel);
+
+                } else {
+
+                    TextFieldWidget textFieldWidget = new TextFieldWidget("value", stringModel);
+
-                if (config.getString("size") != null) {
+                    if (config.getString("size") != null) {
-                    widget.setSize(config.getString("size"));
+                        textFieldWidget.setSize(config.getString("size"));
-                }
-                if (config.getString("maxlength") != null) {
+                    }
+                    if (config.getString("maxlength") != null) {
-                    widget.setMaxlength(config.getString("maxlength"));
+                        textFieldWidget.setMaxlength(config.getString("maxlength"));
-                }
+                    }
+
+                    widget = textFieldWidget;
+                }
+
                 add(widget);
                 break;
             case COMPARE:
Index: api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.java	(revision )
+++ api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.java	(revision )
@@ -0,0 +1,48 @@
+/*
+ *  Copyright 2008-2015 Hippo B.V. (http://www.onehippo.com)
+ *
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ *
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.hippoecm.frontend.widgets;
+
+import org.apache.wicket.markup.ComponentTag;
+import org.apache.wicket.markup.html.form.NumberTextField;
+import org.apache.wicket.markup.html.form.TextField;
+import org.apache.wicket.model.IModel;
+import org.apache.wicket.util.time.Duration;
+import org.hippoecm.frontend.model.properties.StringConverter;
+
+public class NumberFieldWidget extends AjaxUpdatingWidget<Long> {
+
+    public NumberFieldWidget(String id, IModel<Long> model) {
+        this(id, model, null);
+    }
+
+    public NumberFieldWidget(String id, IModel<Long> model, IModel<String> labelModel) {
+        this(id, model, labelModel, null);
+    }
+
+    public NumberFieldWidget(String id, IModel<Long> model, IModel<String> labelModel, Duration throttleDelay) {
+        super(id, model, throttleDelay);
+
+        final NumberTextField<Long>  numberField = new NumberTextField<Long>("widget", model) {
+            {
+                setFlag(FLAG_CONVERT_EMPTY_INPUT_STRING_TO_NULL, false);
+            }
+        };
+        addFormField(numberField);
+        if (labelModel != null) {
+           numberField.setLabel(labelModel);
+        }
+    }
+}
Index: api/src/main/java/org/hippoecm/frontend/model/properties/LongConverter.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- api/src/main/java/org/hippoecm/frontend/model/properties/LongConverter.java	(revision )
+++ api/src/main/java/org/hippoecm/frontend/model/properties/LongConverter.java	(revision )
@@ -0,0 +1,66 @@
+/*
+ *  Copyright 2008-2013 Hippo B.V. (http://www.onehippo.com)
+ * 
+ *  Licensed under the Apache License, Version 2.0 (the "License");
+ *  you may not use this file except in compliance with the License.
+ *  You may obtain a copy of the License at
+ * 
+ *       http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ *  Unless required by applicable law or agreed to in writing, software
+ *  distributed under the License is distributed on an "AS IS" BASIS,
+ *  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ *  See the License for the specific language governing permissions and
+ *  limitations under the License.
+ */
+package org.hippoecm.frontend.model.properties;
+
+import org.apache.wicket.model.IModel;
+import org.hippoecm.frontend.session.UserSession;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import javax.jcr.PropertyType;
+import javax.jcr.RepositoryException;
+import javax.jcr.Value;
+import javax.jcr.ValueFactory;
+
+public class LongConverter implements IModel<Long> {
+
+    private static final long serialVersionUID = 1L;
+    static final Logger log = LoggerFactory.getLogger(LongConverter.class);
+    private JcrPropertyValueModel decorated;
+
+    public LongConverter(JcrPropertyValueModel valueModel) {
+        decorated = valueModel;
+    }
+
+    public Long getObject() {
+        try {
+            if (decorated != null && decorated.getValue() != null) {
+                return decorated.getValue().getLong();
+            } else {
+                log.debug("LongConverter: JcrPropertyValueModel decorated equals null");
+            }
+        } catch (RepositoryException ex) {
+            log.info(ex.getMessage());
+        }
+        return null;
+    }
+
+    public void setObject(Long object) {
+        try {
+            long longValue = object == null ? 0l : object;
+            ValueFactory factory = UserSession.get().getJcrSession().getValueFactory();
+            Value value = factory.createValue(longValue);
+            decorated.setValue(value);
+        } catch (RepositoryException ex) {
+            log.info(ex.getMessage());
+        }
+    }
+
+    public void detach() {
+        decorated.detach();
+    }
+
+}
Index: api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.html
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.html	(revision )
+++ api/src/main/java/org/hippoecm/frontend/widgets/NumberFieldWidget.html	(revision )
@@ -0,0 +1,20 @@
+<!--
+ * Copyright 2007-2013 Hippo B.V. (http://www.onehippo.com)
+ *
+ * Licensed under the Apache License, Version 2.0 (the  "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+-->
+<html xmlns:wicket="http://wicket.apache.org/">
+  <wicket:panel>
+    <input wicket:id="widget" type="number"></input>
+  </wicket:panel>
+</html>
\ No newline at end of file
