Code Monkey home page Code Monkey logo

meteor-autoform-selectize's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

meteor-autoform-selectize's Issues

Remove dependency on jeremy:selectize

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!

Input field inserts but does not re-populate on re-render.

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:

  • the field is not respecting maxCount.
  • a nuanced error: if I select two items and save, I get {"0":"Item0", "1":"Item1"} . If I immediately click on Item0 and delete it, then save, I end up with {"0":"Item1", "1":"Item1"}.

Cheers,

HTML support

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']
            }
        }
    }

isReactiveOptions usage is unclear

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?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.