GfSE / SpecIF

Specification Integration Facility - schema, constraint checker and examples
Apache License 2.0
15 stars 6 forks source link

Icon can be a link/URL #23

Closed odungern closed 4 years ago

odungern commented 5 years ago

So far, an icon is a (short) string (e.g. allowing to specify UTF-8 characters), but @oalt proposes to allow a link to a graphical icon.

odungern commented 5 years ago

... what about a dataURL, such as:

So, if the value attributed to icon is a dataURL, then it is decoded and shown. If it is not a dataURL, then it is taken as a string like in the past. It can still be a UTF-8 character, for example.

@oalt : What do you think?

oalt commented 4 years ago

Hello @odungern ! Your proposal is ok for me.

By thinking about the icons: Would it be helpful to have the possibility to specify an icon not just in the type definitions, but also in the instances (Resources and Statements)? So it would be possible to specify specific icons for a concrete data element. @odungern What do you think?

odungern commented 4 years ago

If we allow a dataURL, we could also allow an absolute or relative URL, which in case of HTML can be used in the same places as a dataURL.

But I suggest not to allow XHTML constructs such as <img src="URL" />.

Further Questions:

odungern commented 4 years ago

An icon can be string, URL or dataURL, there will be no regex. Description updated with schema v1.0.0.