0.0.7 • Published 4 years ago
sidamojs v0.0.7
Sidamo
Sidamo is a collection of pure webcomponents
elements list: 1. pure navigator bar 2. navigator bar with arrow 3. coming soon
Demo
online demo: https://momoko8443.github.io/sidamojs/dist/
Development ENV Setup
npm install
npm run serve
Installation
npm install sidamojs
Usage
...
<script src="https://momoko8443.github.io/sidamojs/dist/sidamo.js"></script>
...
<body>
...
<serai-navigator-arrow id="navigatorArrow"></serai-navigator-arrow>
...
</body>
...
<script>
const navItems = [
{
title: 'aaaaaaaaaa'
},
{
title: 'bbbbb'
},
{
title: 'ccccccc'
},
{
title: 'dddddddddddd'
},
{
title: 'eeeeeeeeee'
},
{
title: 'ffffffff'
},
{
title: 'ggg'
},
{
title: 'hhhhhh'
}];
const navDOM = document.getElementById('navigatorArrow');
navDOM.source = navItems;
navDOM.addEventListener('itemclick', (e) => {
//alert(e.detail.title);
console.log(e.detail.title);
})
</script>
Contributing
- Fork it!
- Create your feature branch:
git checkout -b my-new-feature
- Commit your changes:
git commit -am 'Add some feature'
- Push to the branch:
git push origin my-new-feature
- Submit a pull request :D
History
v0.0.1: new components: navigator bar
Credits
Owner: Huibin Zheng (momoko8443)
License
MIT