Skip to content

Commit bc85b35

Browse files
author
John Messerly
committed
Merge pull request flutter#6 from dart-lang/html
rename package to `html`
2 parents b2ecd40 + d97252a commit bc85b35

17 files changed

+46
-46
lines changed

CHANGELOG.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
# changelog
22

3-
This file contains highlights of what changes on each version of the html5lib
3+
This file contains highlights of what changes on each version of the html
44
package.
55

6+
#### Rename to package:html 0.12.0
7+
* package has been renamed to `html`
8+
69
#### Pub version 0.12.0
710
* switch from `source_maps`' `Span` class to `source_span`'s
811
`SourceSpan` class.

README.md

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
html5lib in Pure Dart
2-
=====================
1+
html5 parser in dart
2+
====================
33

44
This is a pure [Dart][dart] [html5 parser][html5parse]. It's a port of
55
[html5lib](http://code.google.com/p/html5lib/) from Python. Since it's 100%
@@ -14,7 +14,7 @@ Installation
1414
Add this to your `pubspec.yaml` (or create it):
1515
```yaml
1616
dependencies:
17-
html5lib: any
17+
html: any
1818
```
1919
Then run the [Pub Package Manager][pub] (comes with the Dart SDK):
2020
@@ -25,8 +25,8 @@ Usage
2525
2626
Parsing HTML is easy!
2727
```dart
28-
import 'package:html5lib/parser.dart' show parse;
29-
import 'package:html5lib/dom.dart';
28+
import 'package:html/parser.dart' show parse;
29+
import 'package:html/dom.dart';
3030

3131
main() {
3232
var document = parse(
@@ -43,10 +43,7 @@ Running Tests
4343
-------------
4444

4545
```bash
46-
# From Dart SVN checkout
47-
./tools/build.py -m release
48-
./tools/test.py -m release html5lib
49-
./tools/test.py -m release -r drt html5lib
46+
./test/run.sh
5047
```
5148

5249
[dart]: http://www.dartlang.org/

lib/parser.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
/// This library has a parser for HTML5 documents, that lets you parse HTML
22
/// easily from a script or server side application:
33
///
4-
/// import 'package:html5lib/parser.dart' show parse;
5-
/// import 'package:html5lib/dom.dart';
4+
/// import 'package:html/parser.dart' show parse;
5+
/// import 'package:html/dom.dart';
66
/// main() {
77
/// var document = parse(
88
/// '<body>Hello world! <a href="www.html5rocks.com">HTML5 rocks!');

lib/src/css_class_set.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33
// BSD-style license that can be found in the LICENSE file.
44

55
// TODO(jmesserly): everything in this file is copied straight from "dart:html".
6-
library html5lib.dom.src;
6+
library html.dom.src;
77

88
import 'dart:collection';
9-
import 'package:html5lib/dom.dart';
9+
import 'package:html/dom.dart';
1010

1111
class ElementCssClassSet extends CssClassSetImpl {
1212
final Element _element;

lib/src/inputstream.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ class HtmlInputStream {
8787
// Unfortunately dart:io InputStream is async only, which won't work.
8888
throw new ArgumentError("'source' must be a String or "
8989
"List<int> (of bytes). You can also pass a RandomAccessFile if you"
90-
"`import 'package:html5lib/parser_console.dart'` and call "
90+
"`import 'package:html/parser_console.dart'` and call "
9191
"`useConsole()`.");
9292
}
9393
}

lib/src/query_selector.dart

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
1-
/// Query selector implementation for html5lib's DOM.
2-
library html5lib.src.query;
1+
/// Query selector implementation for our DOM.
2+
library html.src.query;
33

44
import 'package:csslib/parser.dart' as css;
55
import 'package:csslib/parser.dart' show TokenKind;
66
import 'package:csslib/visitor.dart'; // the CSSOM
7-
import 'package:html5lib/dom.dart';
8-
import 'package:html5lib/src/constants.dart' show isWhitespaceCC;
7+
import 'package:html/dom.dart';
8+
import 'package:html/src/constants.dart' show isWhitespaceCC;
99

1010
bool matches(Node node, String selector) =>
1111
new SelectorEvaluator().matches(node, _parseSelectorList(selector));

lib/src/tokenizer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
library tokenizer;
22

33
import 'dart:collection';
4-
import 'package:html5lib/parser.dart' show HtmlParser;
4+
import 'package:html/parser.dart' show HtmlParser;
55
import 'constants.dart';
66
import 'inputstream.dart';
77
import 'token.dart';

lib/src/treebuilder.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
library treebuilder;
33

44
import 'dart:collection';
5-
import 'package:html5lib/dom.dart';
6-
import 'package:html5lib/parser.dart' show getElementNameTuple;
5+
import 'package:html/dom.dart';
6+
import 'package:html/parser.dart' show getElementNameTuple;
77
import 'package:source_span/source_span.dart';
88
import 'constants.dart';
99
import 'list_proxy.dart';

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: html5lib
1+
name: html
22
version: 0.12.1-dev
33
author: Dart Team <[email protected]>
44
description: A library for working with HTML documents.

test/dom_test.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
library dom_test;
33

44
import 'package:unittest/unittest.dart';
5-
import 'package:html5lib/dom.dart';
6-
import 'package:html5lib/parser.dart';
5+
import 'package:html/dom.dart';
6+
import 'package:html/parser.dart';
77

88
main() {
99
group('Element', () {

0 commit comments

Comments
 (0)