DASH: Numeric editor

15 views
Skip to first unread message

Tomasz Pluskiewicz

unread,
Jul 6, 2020, 2:48:52 PM7/6/20
to TopBraid Suite Users
I think a dash:NumberEditor should be added to the vocabulary.

I would define it to apply to properties where sh:datatype is xsd:float, xsd:double or any subtype of xsd:decimal.

Not sure, but I my gut tells me that a dedicated viewer type is not necessary

Best,
Tom

Holger Knublauch

unread,
Jul 6, 2020, 7:02:37 PM7/6/20
to topbrai...@googlegroups.com

Currently, editing numbers is covered by http://datashapes.org/forms.html#TextFieldEditor

The widget itself can for example activate <input type="number"> based on the provided datatype.

What other number editors that do not resemble text input fields exist?

Regards
Holger
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/7fb17e70-6f16-4ba8-a9db-aeb037e750b5n%40googlegroups.com.

Tomasz Pluskiewicz

unread,
Jul 8, 2020, 4:47:58 AM7/8/20
to TopBraid Suite Users
I see, although I find the fact that plain HTML uses <input type="number"> an implementation detail and would rather differentiate the editors based on intended lexical values they expect. Does the name TextFieldEditor suggest that it should be used for string exclusively?

And dates in plain HTML are also using <input type="date"> after all.

For me right now it is a little awkward as I load required editors dynamically by their (dash) identifier. With dash:TextFieldEditor being overloaded I have to load multiple components (separate for plain text and separate for numbers). It not a really big deal but something to consider

Holger Knublauch

unread,
Jul 8, 2020, 6:14:08 AM7/8/20
to topbrai...@googlegroups.com


On 8/07/2020 18:47, Tomasz Pluskiewicz wrote:
I see, although I find the fact that plain HTML uses <input type="number"> an implementation detail and would rather differentiate the editors based on intended lexical values they expect. Does the name TextFieldEditor suggest that it should be used for string exclusively?
For numeric editors I cannot quite think of other types of editors than text fields (and yes TextFieldEditor is supposed to work with all literal types). Could you elaborate which other editors exist? And where would this stop - separate editors for all xsd datatypes? SHACL-aware tools can and should collect the datatype info from the context, i.e. the property shapes.


And dates in plain HTML are also using <input type="date"> after all.
Right, but a date picker is quite different from a text field (which could potentially also work to enter yyyy-MM-dd format.


For me right now it is a little awkward as I load required editors dynamically by their (dash) identifier. With dash:TextFieldEditor being overloaded I have to load multiple components (separate for plain text and separate for numbers). It not a really big deal but something to consider

So you can not use sh:datatype? I guess you always have the option of defining your own editors then - no need to limit yourself to the built-in dash ones.

Holger



wtorek, 7 lipca 2020 o 01:02:37 UTC+2 Holger Knublauch napisał(a):

Currently, editing numbers is covered by http://datashapes.org/forms.html#TextFieldEditor

The widget itself can for example activate <input type="number"> based on the provided datatype.

What other number editors that do not resemble text input fields exist?

Regards
Holger


On 7/07/2020 04:48, Tomasz Pluskiewicz wrote:
I think a dash:NumberEditor should be added to the vocabulary.

I would define it to apply to properties where sh:datatype is xsd:float, xsd:double or any subtype of xsd:decimal.

Not sure, but I my gut tells me that a dedicated viewer type is not necessary

Best,
Tom
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/topbraid-users/7fb17e70-6f16-4ba8-a9db-aeb037e750b5n%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "TopBraid Suite Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to topbraid-user...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages