1.0.4 • Published 6 years ago

selection-popup v1.0.4

Weekly downloads
7
License
MIT
Repository
github
Last release
6 years ago

selection-popup Build Status


A library to add popup menus at text selections. Demo page


Installation

npm install selection-popup


Usage

const selectionPop = require('selection-popup)

selectionPop(['share', '<i class="fa fa-twitter" aria-hidden="true"></i>
', 'log'], [shareFunc, tweetFunc, function(e){
  console.log('selected item: ' + e)
} ],{style: 'background-color:yellow'});

API

selectionPop(items,funcs ,options)

add a popup menu to document

items (required)

Type: array, String(for single item)


funcs (required)

Type: array, String(for single item) functions for onClick actions of the appropriate items


options (optional)

Type: object style: String an override styles for customization


License

Copyright © 2017, Erdem Bircan. Released under the MIT License.

1.0.4

6 years ago

1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago