Provided property value types

 

TypeDescription
stringPlain string property
tagstring

String property that can contain %%tags%% or i18n keys.
Will be pre-processed before being provided to web component

Hello %%name%%

or

 i18n:com.mycompany.mykey
color

String color value

#FFFFFF
point

Point representation

{
	x: 10, 
	y: 20
}
dimension

Dimension representation

{
	width: 100, 
	height: 20
}
insets 
fontCSS font string
borderCSS border string
booleanBoolean value, either true or false
styleclass

String with space separated CSS classnames.Possible values supported by the component can be specified as hint for the developer

{
	type:'styleclass', 
	values:[
		'btn',
		'btn-default',
		'btn-lg',
		'btn-sm',
		'btn-xs'
	]
}
doubleA floating point number
floatA floating point number
intAn integer number
longA number, size is twice an integer
shortA number, 16 bit
byteA number, 8 bit unsigned
dataprovider

Reference to a dataprovider, either a record or scope variable. Can be a complex object for supporting onDataChange

{ 
	type:'dataprovider', 
	ondatachange: { 
		onchange: 'onDataChangeMethodID', 
		callback: 'onDataChangeCallback'
	}
}
valuelistReference to a ValueList
formURL string pointing to a form (like tab in tabpanel)
format

Format string. Requires to be specified as object to specify which dataprovider property to map this format property on

{
	for: 'dataProviderID',
	type: 'format'
}
relationReference to a Relation
mediaReference to a Media entry
dateDate value
scrollbars..
tabSeq..

 

Property value type modifiers:

ModifierDescriptionApplicable for type
scopeRestricts the model property to either 'design' or 'runtime' 
values

Fixed values, can have real/display values.

[{"LEFT":2}, {"CENTER":0},{"RIGHT":4}]
[
    'btn',
    'btn-default',
    'btn-lg',
    'btn-sm',
    'btn-xs'
]
 
defaultDefines the default value being used. 
onDataChangeSee dataprovider typedataprovider
forSee format typeformat

Note: defaults now also get applied to the model. This might change. Best practice is to initialize the model properties with values in the directive's link method and specify the same values as defaults in the .spec file for proper display in Servoy Developer. 

 

See also: