Skip to content
This repository has been archived by the owner on Dec 19, 2017. It is now read-only.

Commit

Permalink
Merge pull request #113 from dart-lang/0.4.1
Browse files Browse the repository at this point in the history
update to 0.4.1 js versions
  • Loading branch information
jakemac53 committed Sep 25, 2014
2 parents abfb382 + 4261189 commit 25cbec9
Show file tree
Hide file tree
Showing 253 changed files with 7,442 additions and 3,189 deletions.
36 changes: 23 additions & 13 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,38 @@
## Pub version 0.2.2+1
## version 0.3.0

* Update elements to the 0.4.1 js versions.
* **Breaking Change** `core-dropdown` has been renamed to
`core-dropdown-menu`, `core-popup-menu` has been renamed to
`core-dropdown`, and `core-popup-overlay` has been renamed to
`core-dropdown-overlay`.
* **New** `core-a11y-keys` element, which helps when dealing with key
events.

## version 0.2.2+1

* Upgrade `custom_element_apigen` to a real dependency as its required in the
wrappers.

## Pub version 0.2.2
## version 0.2.2

* Update all elements so they can be built from code using a normal factory
constructor, such as `new CoreInput()`. It is still necessary however to
include the html import for each element you wish to create this way.

## Pub version 0.2.1+2
## version 0.2.1+2

* Fix for [107](https://github.com/dart-lang/core-elements/issues/107).
The `core-ajax-dart` element no longer throws exception in checked mode, and
the `content-type` header will have the proper default.

## Pub version 0.2.1+1
## version 0.2.1+1

* Update `core-input` element to
[88cbe6f](https://github.com/Polymer/core-input/commit/88cbe6f). This
removes the need to use js interop for many methods that are forwarded to
the underlying input element.

## Pub version 0.2.1
## version 0.2.1

* Update all elements to the 0.4.0 js versions.
* **New** Added new element core_popup_menu.
Expand All @@ -31,11 +41,11 @@
* Removed platform.js from all tests and examples.
* Upgrade dependency on web_components to >=0.7.0.

## Pub version 0.2.0+1
## version 0.2.0+1

Upgrade polymer dependency to >=0.13.0

## Pub version 0.2.0
## version 0.2.0

Updated all elements to the 0.3.5 js versions.

Expand All @@ -49,31 +59,31 @@ Updated all elements to the 0.3.5 js versions.
20648](https://code.google.com/p/dart/issues/detail?id=20648)
* Expanded polymer version constraint to <0.14.0.

## Pub version 0.1.1+2
## version 0.1.1+2

Fix for https://dartbug.com/20265, core-ajax-dart no longer throws an exception
when handling errors.

## Pub version 0.1.1+1
## version 0.1.1+1

Fix for https://github.com/dart-lang/core-elements/issues/84, core-ajax-dart no
longer fails if no params attribute is supplied.

## Pub version 0.1.1
## version 0.1.1

Fix for https://github.com/dart-lang/core-elements/issues/39, added missing
togglePanel method to core-drawer-panel.

## Pub version 0.1.0+1
## version 0.1.0+1

Updated all elements to the 0.3.4 js version.

## Pub version 0.0.4
## version 0.0.4

New generated wrappers for core-elements. This completely replaces and is
incompatible with earlier version of the package.

## Pub version 0.0.3 and earlier
## version 0.0.3 and earlier

This was an attempt to port the core-elements to Dart. This version of the
package is deprecated.
6 changes: 3 additions & 3 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
],
"private": true,
"dependencies": {
"polymer": "polymer/polymer#0.4.0",
"core-elements": "polymer/core-elements#0.4.0",
"core-input": "polymer/core-input#master"
"polymer": "polymer/polymer#0.4.1",
"core-elements": "polymer/core-elements#0.4.1",
"core-a11y-keys": "polymer/core-a11y-keys#0.4.1"
}
}
5 changes: 3 additions & 2 deletions core_elements_config.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Configuration for running tool/generate_dart_api.dart
files_to_generate:
- core-a11y-keys/core-a11y-keys.html
- core-animated-pages/core-animated-pages.html:
# subdir imports don't work.
omit_imports:
Expand All @@ -14,6 +15,8 @@ files_to_generate:
- core-drag-drop/core-drag-drop.html
- core-drawer-panel/core-drawer-panel.html
- core-dropdown/core-dropdown.html
- core-dropdown/core-dropdown-overlay.html
- core-dropdown-menu/core-dropdown-menu.html
- core-field/core-field.html
- core-header-panel/core-header-panel.html
- core-icon/core-icon.html
Expand Down Expand Up @@ -47,8 +50,6 @@ files_to_generate:
- core-overlay/core-overlay.html
- core-overlay/core-overlay-layer.html
- core-pages/core-pages.html
- core-popup-menu/core-popup-menu.html
- core-popup-menu/core-popup-overlay.html
- core-range/core-range.html
- core-scaffold/core-scaffold.html
- core-scroll-header-panel/core-scroll-header-panel.html
Expand Down
60 changes: 60 additions & 0 deletions example/core_a11y_keys.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
<!doctype html>
<!--
Copyright (c) 2014 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
Code distributed by Google as part of the polymer project is also
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
-->
<html>
<head>
<title>core-a11y-keys</title>

<script src="packages/web_components/dart_support.js"></script>
<link rel="import" href="packages/core_elements/core_a11y_keys.html">
<link rel="import" href="packages/polymer/polymer.html">
</head>
<body unresolved>
<template id="myTemplate" is="auto-binding-dart">
<style>
div {
height: 100px;
width: 100px;
background: gray;
}
</style>
<core-a11y-keys id="a11y" keys="* pageup pagedown left right down up shift+a alt+a home end" on-keys-pressed="{{printKey}}"></core-a11y-keys>
<div id="target" tabindex="0">focus this</div>
<pre id="output"></pre>
</template>

<script type="application/dart">
import 'dart:async';
import 'dart:html';
import 'dart:js';
import 'package:core_elements/core_a11y_keys.dart';
import 'package:polymer/polymer.dart';

class MyModel {
printKey(e) {
var detail = new JsObject.fromBrowserObject(e)['detail'];
querySelector('#output').text += '${detail['key']} pressed!\n';
}
}

main() {
initPolymer().run(() {
Polymer.onReady.then((_) {
AutoBindingElement template = querySelector('#myTemplate');
template.model = new MyModel();
template.on['template-bound'].listen((_) {
CoreA11yKeys keys = querySelector('#a11y');
keys.target = querySelector('#target');
});
});
});
}
</script>
</body>
</html>
37 changes: 32 additions & 5 deletions example/core_dropdown.dart
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,38 @@
*/
library core_elements.example.core_dropdown;

import 'dart:html';
import 'package:polymer/polymer.dart';
export 'package:polymer/init.dart';

class Country {
final String name;
final String code;
const Country(this.name, this.code);
}

@CustomTag('dropdown-demo')
class DropdownDemo extends PolymerElement {
@published
@CustomTag('drop-down')
class DropDown extends PolymerElement {
@published bool opened = false;
@published var halign;
@published var valign;

DropDown.created() : super.created();

toggle() => this.opened = !this.opened;
}

@CustomTag('drop-down-2')
class DropDown2 extends PolymerElement {
@published bool opened = false;
@published var halign;
@published var valign;

DropDown2.created() : super.created();

toggle() => this.opened = !this.opened;
}

class MyModel {
final List<Country> countries = [
const Country('Afghanistan','AF'),
const Country('Åland Islands','AX'),
Expand Down Expand Up @@ -265,6 +285,13 @@ class DropdownDemo extends PolymerElement {
const Country('Zambia','ZM'),
const Country('Zimbabwe','ZW'),
];
}

DropdownDemo.created() : super.created();
main () {
initPolymer().run(() {
Polymer.onReady.then((_) {
var template = querySelector('#myTemplate');
template.model = new MyModel();
});
});
}
Loading

0 comments on commit 25cbec9

Please sign in to comment.