jshimko / meteor-autoform-selectize Goto Github PK
View Code? Open in Web Editor NEWCustom Selectize input type for the Autoform package for Meteor.
Custom Selectize input type for the Autoform package for Meteor.
I'm having issues with the subjected package overriding the bootstrap theme. Can you remove the inter-dependency? Or alternately, remove the default css from the jeremy:selectize pacakge.
Thanks!
I have created my selectize attribute as instructed in the docs however the form displays like so .
http://screencast.com/t/fB8yWzauiy .
Any advice will be greatly appreciated.
Thanks for publishing this package.
I apologize if this is an oversight on my part. I am using Autoform 5.0.3. I have a helper with:
Template.registerHelper( "ops_skills" , function () { return {
"Oracle EBS-GL": "Oracle EBS-GL",
"Oracle EBS-PO": "Oracle EBS-PO"
}; } );
schema definition:
skillTags: {type: [String], optional:true, maxCount:8, label:"Tags" }
template tag:
{{> afQuickField name="skillTags" label=false type="selectize" multiple=true options=ops_skills }}
in meteor mongo I get:
"skillTags" : { "0" : "Oracle EBS-PO", "1" : "Oracle EBS-GL" }
but on re-loading the page nothing appears in the input field. Is the value supposed to be a dict? I was expecting from the schema def to see an array of strings?
Side effects I also experienced, which may be relevant:
Cheers,
Does this package support HTML formatting for the list items? I tried the following code, however the tags do not get formatted:
order_tests: {
type: [String],
autoform: {
type: 'selectize',
placeholder: 'Click here to add tests...',
multiple: true,
label: false,
options: function() {
return _.map(tests.find({}, {sort: {test_name: 1}}).fetch(), function(item) {
return {value: item._id, label: function(){
return '<h1>' + item.test_name + '</h1> - Free'
}
}}
})
},
selectizeOptions: {
plugins: ['remove_button']
}
}
}
I was looking through the source code wondering how to handle reactive options and stumbled upon isReactiveOptions. At first it looked very promising but I haven't been able to get it working. I have the following in my template:
{{> afQuickField name="homeCourt" type="selectize" selectizeOptions=homeCourtOptions isReactiveOptions=true multiple=true placeholder="First choose your Home City above..."}}
The homeCourtOptions function then returns an object with its 'options' property set to an array which is computed using a reactive variable. I can see the reactivity triggering a re-compute of homeCourtOptions, however, it doesn't appear that the object being returned from homeCourtOptions is being used by the autoform-selectize package to re-compute the options. Is there something else I need to do?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.