Sha256: 6c870694a29003815ab8ba9024d034da7f891dfa26b178e4059e8e1c417862c8
Contents?: true
Size: 625 Bytes
Versions: 2
Compression:
Stored size: 625 Bytes
Contents
import Picker from './picker'; class IconPicker extends Picker { constructor(select, icons) { super(select); this.container.classList.add('ql-icon-picker'); [].forEach.call(this.container.querySelectorAll('.ql-picker-item'), (item) => { item.innerHTML = icons[item.getAttribute('data-value') || '']; }); this.defaultItem = this.container.querySelector('.ql-selected'); this.selectItem(this.defaultItem); } selectItem(item, trigger) { super.selectItem(item, trigger); item = item || this.defaultItem; this.label.innerHTML = item.innerHTML; } } export default IconPicker;
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
rails_modular_admin-1.0.0 | app/assets/node_modules/quill/ui/icon-picker.js |
rails_modular_admin-0.4.0 | app/assets/node_modules/quill/ui/icon-picker.js |