autocomplete_ui 0.2.0+1

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 43

dart-autocomplete-ui

A simple dart web ui component which provides a autocomplete input text field. (To autocomplete a single value)

Status

Currently it is nothing more than a POC which can display a auto complete field for a text input with a static list of strings.

Checkout an example at http://hpoul.github.com/dart-autocomplete-ui/examples/example.html

Usage

Take a look at the example - the basic idea is that you simply include the web component:

<link rel="import" href="lib/input_autocomplete.html">

and then include the input autocompletion whereever you want:

<tapo-input-autocomplete choices="{{exampleData.autocompleteChoices}}">
</tapo-input-autocomplete>

example dart code:

var exampleData = new ExampleData();
class ExampleData {
  List<String> get autocompleteChoices {
    return ['Test 1', 'Test 2', 'Misc', 'Abcdef', 'Haha'];
  }
}

It is also possible to use a custom datasource as well as a custom renderer. See the classes AutocompleteDatasource and AutocompleteChoiceRenderer for more details.

TODO write documentation.

Future

  • Support for lazy loading of choices
  • Support for object choices (which have a separate key / label attribute)
  • Support for formatting of choices (however this can work? the coolest would be to provide html fragments inside the <x-input-autocomplete> tag)
  • Helper methods to create a multi-value input (like input for tags)

Bitdeli Badge

0.2.0+1 (2014-09-05): Upgraded to polymer 0.13

0.2.0 (2014-07-05): Upgraded to polymer 0.11

  • 0.1.1 (2013-10-29): Upgraded to polymer 0.8.7
  • 0.1.0 (2013-10-24): Got it to work with polymer 0.8.5! ;-)
  • 0.0.6+4 (2013-09-05): simply removed upper version constraint for web_ui (there won't be too many new versions anyway) - should make it compatible with dart sdk 0.7.1
  • 0.0.6+3 (2013-08-20): compatibility to dart sdk 0.6.19 / web_ui 0.4.18
  • 0.0.6+2 (2013-08-12): compatibility to dart sdk 0.6.15 / web_ui 0.4.17
  • 0.0.6+1 (2013-07-25): compatibility to dart sdk 0.6.9 / web_ui 0.4.15
  • 0.0.6 (2013-07-12): compatibility to dart sdk 0.6.3 / web_ui 0.4.14
  • 0.0.5 (2013-07-03): added a way to bind for the latest selected value. (bind-selectedchoice="..")
  • 0.0.4+2 (2013-07-02): changed layout to wrap everything in a position: relative div, instead of trying to position autocompletion box absolute to the whole page.
  • 0.0.4 (2013-06-27): Fixed support for Latest Dart Libraries & Web UI (0.4.12+3)
  • 0.0.3: Support for Dart Libraries v2 (M3 preparation)
  • 0.0.2: support for custom datasources, formatting
  • 0.0.1: initial "release"

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  autocomplete_ui: "^0.2.0+1"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:autocomplete_ui/autocomplete_result.dart';

import 'package:autocomplete_ui/example/simple_autocomplete_example.dart';

import 'package:autocomplete_ui/input_autocomplete.dart';
        
Version Uploaded Documentation Archive
0.2.0+1 Sep 5, 2014 Go to the documentation of autocomplete_ui 0.2.0+1 Download autocomplete_ui 0.2.0+1 archive
0.2.0 Jul 5, 2014 Go to the documentation of autocomplete_ui 0.2.0 Download autocomplete_ui 0.2.0 archive
0.1.1+1 Nov 7, 2013 Go to the documentation of autocomplete_ui 0.1.1+1 Download autocomplete_ui 0.1.1+1 archive
0.1.0 Oct 23, 2013 Go to the documentation of autocomplete_ui 0.1.0 Download autocomplete_ui 0.1.0 archive
0.0.6+4 Sep 5, 2013 Go to the documentation of autocomplete_ui 0.0.6+4 Download autocomplete_ui 0.0.6+4 archive
0.0.6+3 Aug 20, 2013 Go to the documentation of autocomplete_ui 0.0.6+3 Download autocomplete_ui 0.0.6+3 archive
0.0.6+2 Aug 12, 2013 Go to the documentation of autocomplete_ui 0.0.6+2 Download autocomplete_ui 0.0.6+2 archive
0.0.6+1 Jul 25, 2013 Go to the documentation of autocomplete_ui 0.0.6+1 Download autocomplete_ui 0.0.6+1 archive
0.0.6 Jul 12, 2013 Go to the documentation of autocomplete_ui 0.0.6 Download autocomplete_ui 0.0.6 archive
0.0.5+1 Jul 5, 2013 Go to the documentation of autocomplete_ui 0.0.5+1 Download autocomplete_ui 0.0.5+1 archive

All 16 versions...

Analysis

This feature is new.
We welcome feedback.
More details: scoring.

We analyzed this package, and provided a score, details, and suggestions below.

  • tool failures on Jan 21, 2018
  • Dart: 2.0.0-dev.15.0
  • pana: 0.10.0

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
35 / 100
Health:
Code health derived from static analysis. [more]
85 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
0 / 100
Overall score:
Weighted score of the above. [more]
43

Platforms

Detected platforms: unsure

Error(s) prevent platform classification.

Suggestions

  • Fix lib/src/autocomplete_datasource.dart.

    Strong-mode analysis of lib/src/autocomplete_datasource.dart failed with the following error:

    line: 27 col: 3
    Invalid override. The type of 'SimpleStringDatasource.query' ('(String) → Future<Iterable<AutocompleteChoice>>') isn't a subtype of 'AutocompleteDatasource.query' ('(String) → Future<List<AutocompleteChoice>>').

  • Fix lib/autocomplete_result.dart.

    Strong-mode analysis of lib/autocomplete_result.dart failed with the following error:

    line: 6 col: 54
    The private name _changes, defined by Observable, conflicts with the same name defined by Observable.

  • Fix platform conflicts.

    Make sure none of the libraries use mutually exclusive dependendencies.

  • Fix issues reported by dartanalyzer.

    dartanalyzer reported 2 error(s) and 0 warning(s).

  • Use constrained dependencies.

    The pubspec.yaml contains 3 dependencies without version constraints. Specify version ranges for the following dependencies: browser, html5lib, logging.

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

  • Maintain an example.

    Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use autocomplete_ui.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
browser any 0.10.0+2
html5lib any 0.12.1
logging any 0.9.3 0.11.3+1
polymer >=0.11.0 <0.14.0 0.13.1 0.16.4+4
Transitive dependencies
analyzer 0.22.4 0.30.0+4
args 0.12.2+6 1.2.0
async 2.0.3
barback 0.15.2+14
charcode 1.1.1
cli_util 0.0.1+2 0.1.2+1
code_transformers 0.2.9+3 0.5.1+3
collection 1.14.5
csslib 0.13.7+1 0.14.1
html 0.12.2+2 0.13.2+2
observe 0.12.2+1 0.15.1
path 1.5.1
polymer_expressions 0.12.0+1 0.13.1+1
pool 1.3.4
smoke 0.2.1+1 0.3.6+3
source_maps 0.10.4
source_span 1.4.0
stack_trace 1.9.1
string_scanner 1.0.2
template_binding 0.12.1 0.14.0+6
utf 0.9.0+3
watcher 0.9.7+6
web_components 0.6.0+1 0.12.5
when 0.2.0
which 0.1.3
yaml 2.1.13