Riot.js implementation of Material Design
Installation
You can install it via nodejs
npm install riot-material
or download one of the bundled file
/**
* `dist/index.js`
* `dist/index.min.js`
* `dist/index+libs.js`
* `dist/index+libs.min.js`
*/
requirejs.config({
paths: {
// "what-input": "path/to/what-input // if you do not use +libs bundle
"riot-material": "path/to/riot-material",
},
});
require(['riot-material'], function (riotMaterial) {
// ...
});
/**
* `dist/index.es.js`
* npm installation
*/
import * as riotMaterial from "riot-material";
otherwise you can include the script in your project html
<!-- if you want to use the what-input library elsewhere -->
<script src="path/to/what-input.umd.js"></script>
<script src="riot-material/index.js"></script>
<!-- <script src="riot-material/index.min.js"></script> -->
<!-- or, if you want to use only riotMaterial -->
<script src="riot-material/index+libs.js"></script>
<!-- <script src="riot-material/index+libs.min.js"></script> -->
and access it via
window.riotMaterial;
Note: "riot" dependency is treated as external, be sure to have it when installing manually or including via html
Documentation
Importing this package will occur in register
ing all the components globally in riot
Refer to each sub-package documentation:
-
components.appBar
rm-app-bar tag - Not yet available components.button
rm-button tagcomponents.checkbox
rm-checkbox tagcomponents.dialog
rm-dialog tag-
components.divider
rm-divider tag - Not yet available components.icon
rm-icon tagcomponents.listItem
rm-list-item tagcomponents.menuItem
rm-menu-item tagcomponents.menu
rm-menu tagcomponents.radio
rm-radio tagcomponents.select
rm-select tagcomponents.tabbedPages
rm-tabbed-pages tagcomponents.textfieldContainer
rm-textfield-container tagcomponents.textfield
rm-textfield tagcomponents.visibilityTrigger
rm-visibility-trigger tag
appBarUtils
app-bar-utils sub-package-
background
background sub-package - Not yet available -
elevation
elevation sub-package - Not yet available positionController
position-controller sub-package-
beforeFocusListener
before-focus-listener sub-package - Not yet available ripple
ripple sub-package-
surfaces
surfaces sub-package - Not yet available