presentation-widget

3.0.0 • Public • Published

presentation-widget

Augmented.js Presentation Widget Module

API

Table of Contents

Widget

Widgets and small presentation modules

List

List widget - renders a standard list

Parameters

  • id string The id of the parent to attach the list
  • data Array The data to render
  • ordered boolean True if the list should be ordered
  • binding string The binding (used for decorator and optional)

Returns Element Returns a DOM element as a list

DescriptionList

DescriptionList widget - renders a description list

Parameters

  • id string The id of the parent to attach the list
  • data Object The data to render
  • binding string The binding (used for decorator and optional)

Returns Element Returns a DOM element as a description list

DataList

DataList widget - renders a data list

Parameters

  • id string The id of the parent to attach the list
  • data Array The data to render
  • binding string The binding (used for decorator and optional)

Returns Element Returns a DOM element as a data list

Input

Input widget - renders an input or simular based on type

Parameters

  • field object Field property object (required)
  • name string The name of the field
  • value string The value to preset
  • id string The id of the field
  • required boolean If the field is required
  • binding string The binding (used for decorator and optional)

Examples

field object format:
{
  "description": "Something",
  "type": "string", // string, number, integer, boolean, object (can be an array), email, uri, date-time
  "minimum": 0,
  "maximum": 85,
  "format": "email", // optional
  "pattern": "[A-Za-z]", // any regex
  "value": "bubba",
  "enum": [ "something", ... ]
}

Returns Element Returns a DOM element as an input

Package Sidebar

Install

npm i presentation-widget

Weekly Downloads

18

Version

3.0.0

License

Apache-2.0

Unpacked Size

38.5 kB

Total Files

5

Last publish

Collaborators

  • thedocbwarren