oraclejet-demo-card

0.4.0 • Public • Published

oraclejet-demo-card

sample of a composite component to test delivery via nmp

Installation and use

npm install oraclejet-demo-card

Add the following to the HTML view that you want to load the card into.

<div id="card-holder">
  <oj-bind-for-each data="[[employees]]">
    <template>
      <oraclejet-demo-card
        name="[[$current.data.name]]"
        avatar="[[$current.data.avatar]]"
        work-title="[[$current.data.title]]"
        work-number="[[$current.data.work]]"
        email="[[$current.data.email]]"
      >
      </oraclejet-demo-card>
    </template>
  </oj-bind-for-each>
</div>

In your viewmodel provide an array named "employees" that contains the following fields.

[{
    name: 'Fred Flintstone',
    avatar: 'css/images/avatar_24px_2x.png', <== optional
    title: 'Purchasing Director',
    work: 5171278899,
    email: 'fred.flintstone@example.com',
    backgroundImage: 'images/background.png' <== optional
}]

In the viewmodel add a reference to the "loader.js" module from the oraclejet-demo-card installation folder

'oraclejet-demo-card/loader'

Readme

Keywords

Package Sidebar

Install

npm i oraclejet-demo-card

Weekly Downloads

2

Version

0.4.0

License

UPL

Unpacked Size

11 kB

Total Files

9

Last publish

Collaborators

  • peppertech