Commit Graph

76 Commits

Author SHA1 Message Date
sigmund@google.com f5e5bd9b54 Fix type error, add tests for it, get package ready for a patch release.
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//106083005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31174 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-16 21:03:46 +00:00
sigmund@google.com f809a49118 Add linter by default for polymer's pub-build, also cleans up the linter code.
Now that barback support listening for log messages, we can remove the logging
hooks we temporarily added in our linter.

R=jmesserly@google.com

Review URL: https://codereview.chromium.org//112843004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31110 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-12 21:04:19 +00:00
jmesserly@google.com 7d27c27ada fix linter on svg
R=sigmund@google.com

Review URL: https://codereview.chromium.org//114473002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31108 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-12 20:42:12 +00:00
jmesserly@google.com b17630d1af workaround for event handlers: don't return StreamSubscription as model
https://code.google.com/p/dart/issues/detail?id=15574

R=sigmund@google.com

Review URL: https://codereview.chromium.org//105493003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31092 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-11 23:52:09 +00:00
jmesserly@google.com a526b4ed3a update our CustomElement+Shadow DOM patch
https://github.com/dart-lang/CustomElements/pull/3
fixes https://code.google.com/p/dart/issues/detail?id=15354

R=blois@google.com

Review URL: https://codereview.chromium.org//112433002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31078 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-11 20:31:26 +00:00
whesse@google.com 4a1c80cde0 Change polymer tests to use internal test_controller, not unittest/test_controller.
BUG=
R=kustermann@google.com

Review URL: https://codereview.chromium.org//109893005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@31021 260f80e4-7a28-3924-810f-c04153c831b5
2013-12-10 15:33:49 +00:00
jmesserly@google.com 94c2d48c6c [polymer.dart] fix *Changed observers inheriting.
R=sigmund@google.com

Review URL: https://codereview.chromium.org//79353003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30561 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-22 03:04:25 +00:00
jmesserly@google.com 283c81ee64 "Reverting 30388"
This is a new TodoMVC based on Polymer's version, now fixed on IE. Also fixes two other bugs in how we were handling styles:
* scoped styles were broken unless browser supported them natively
* link rel=stylesheet for external styles was broken

(restore) https://code.google.com/p/dart/source/detail?r=30387
(revert) https://code.google.com/p/dart/source/detail?r=30388

R=sigmund@google.com

Review URL: https://codereview.chromium.org//77373002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30554 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-21 23:10:50 +00:00
sigmund@google.com 2eb07c48c5 Fix resolution of packages in pub-build to allow '../../packages/foo/bar'
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//79513002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30495 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-21 01:40:17 +00:00
jmesserly@google.com 873ea4fb9d fix script tags -- remove special case handling for polymer-element
also enforce one-dart-script-per-document rule
also fixes bug about inlining all content, not just polymer-element

R=sigmund@google.com

Review URL: https://codereview.chromium.org//78663004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30486 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-20 22:13:52 +00:00
jmesserly@google.com 9d6ecc1505 "Reverting 30387"
There are some issues on IE with pushState, Event.returnValue, and styles. Strangely, http://todomvc.com/architecture-examples/polymer/index.html which this was ported from has none of these issues. :|

Review URL: https://codereview.chromium.org//76013002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30388 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-19 05:16:12 +00:00
jmesserly@google.com 773917fa80 Update TodoMVC based on https://github.com/polymer/todomvc
Other than the TodoMVC changes, this has 2 polymer fixes:
* removes incorrect linter messages
* fix issue 12434 -- external stylesheets did not work

port is of d33386ccd4c84cb5b89391bd958e97c5de7c2a01

R=sigmund@google.com

Review URL: https://codereview.chromium.org//60353013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30387 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-19 04:28:45 +00:00
sigmund@google.com fcb74c7a3f Add a build filter (only necessary HTML files are emitted) and logic to use .min.js by default, but keeps it disabled until the dart2js/mirrors bugs are addressed (dartbug.com/14720).
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//61193002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30164 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-11 18:39:47 +00:00
sigmund@google.com 260edd95ea Switch to new main semantics (fixes issue 14797)
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//57423005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29870 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-05 01:51:58 +00:00
jmesserly@google.com d9709470cc "Reverting 29728"
I changed the test to avoid using mirrors. Somehow, import mirrors exposes a strange dart2js interceptor bug, but only in unchecked mode. (I only ran checked mode in my local tests :|. Doh)
Needs more investigation, but what seems to be happening:

* setInnerHtml creates a document
* it tries to append <base> to the <head>
* interceptor gets "Document" instead of "HtmlDocument"
* so the `document.head` fails

The bug seems to require Shadow DOM+unchecked+mirrors. Anyway, since it's totally unrelated to this test or the bug fix for 14700, I'm just working around it for now. Will open a separate issue.

R=sigmund@google.com

Review URL: https://codereview.chromium.org//54983011

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29767 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-01 19:59:45 +00:00
kasperl@google.com 68ff3d28cc Revert "fix nested bindings"
This reverts r29722.

R=jmesserly@google.com
BUG=

Review URL: https://codereview.chromium.org//54603008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29728 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-01 08:47:49 +00:00
jmesserly@google.com 6179df0ad5 fix nested bindings
R=sigmund@google.com

Review URL: https://codereview.chromium.org//51953012

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29722 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-01 02:15:15 +00:00
floitsch@google.com 7006de6f23 Remove deprecated parts of dart:async.
Attempt to fix most uses of the deprecated features.

R=floitsch@google.com, nweiz@google.com, rnystrom@google.com

Review URL: https://codereview.chromium.org//48483002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29628 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-31 02:24:29 +00:00
ahe@google.com 36e2df1a1d Mirrors overhaul.
R=johnniwinther@google.com

Review URL: https://codereview.chromium.org//23455028

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29551 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-30 14:58:58 +00:00
jmesserly@google.com c574e860ec polymer warning clean
R=sigmund@google.com

Review URL: https://codereview.chromium.org//50703009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29505 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-30 00:48:07 +00:00
jmesserly@google.com 7b3123e02a Update our TemplateBinding port
https://github.com/Polymer/TemplateBinding/tree/ed3266266e751b5ab1f75f8e0509d0d5f0ef35d8

R=sigmund@google.com

Review URL: https://codereview.chromium.org//50203004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29500 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-29 23:26:20 +00:00
sigmund@google.com a04c9c1359 Add test for @published with noscript
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//47603017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29489 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-29 20:56:38 +00:00
sigmund@google.com 3336d7d194 Inherit @published from base class (fix issue 13937)
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//49793004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29412 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-29 03:40:47 +00:00
sigmund@google.com c70f1f7cf5 Build fixes: adds arguments to the pub-build plugin to configure whether 'js'
and 'csp' options. Ensure we can call main in the generated code (no need to
export init.dart anymore).

R=jmesserly@google.com

Review URL: https://codereview.chromium.org//47933006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29409 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-29 02:50:58 +00:00
sigmund@google.com ba1b2e34d6 Fix suggestions about using init.dart
R=vsm@google.com

Review URL: https://codereview.chromium.org//46563002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29336 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-27 23:50:56 +00:00
blois@google.com 36258e823c Fixing merge issue of removal of polymer/platform.dart
Some additional references came in from Siggi's change that I missed on the merge.

TBR
BUG=

Review URL: https://codereview.chromium.org//46863003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29312 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-26 17:08:21 +00:00
blois@google.com 18ea023a9d Fixes from polymer.dart API review
Primary breaking changes are:
 - polymer/platform.dart is removed
 - Rather than platform.flush, use scheduleMicrotask(Observable.dirtyCheck)
 - Rather than endOfMicrotask, use either scheduleMicrotask or Future.value
 - Polymer.job removed, use Timer instead (and upvote bug 14414 for timer.restart if you really want the job semantics)

This change is bringing up some really weird timing issues in the tests- I don't think any are inherent to the change itself but is more indicative of larger issues.

BUG=13666
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//41293002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29311 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-26 16:33:25 +00:00
sigmund@google.com 68386823d1 Update polymer to commit b7200854b2441a22ce89f6563963f36c50f5150d
This brings over the changes to event dispatching.

R=blois@google.com

Review URL: https://codereview.chromium.org//44573005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29303 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-26 00:42:21 +00:00
jmesserly@google.com 34085ccdb5 port Node.bind to bd0a0591920da9091b326627a46a104a92c7efe7
the first step to fix https://code.google.com/p/dart/issues/detail?id=13950

R=sigmund@google.com

Review URL: https://codereview.chromium.org//42433002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29294 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-25 21:39:06 +00:00
jmesserly@google.com d93cbb1e41 fix binding to $ from polymer templates
https://code.google.com/p/dart/issues/detail?id=14172
there were two issues:

* "$" needs to be reflectable
* the Map needs to be observable so templates can detect when keys get added (happens after template instantiation)

R=sigmund@google.com

Review URL: https://codereview.chromium.org//41383002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29208 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-24 21:12:29 +00:00
jmesserly@google.com e96d31a4cd port polymer - 00e2982c78fcd396adaebff3118e94029a2b9fb0
we're still missing a few commits (such as https://github.com/Polymer/polymer/pull/328) but this gets us pretty close to fixing https://code.google.com/p/dart/issues/detail?id=14377

R=sigmund@google.com

Review URL: https://codereview.chromium.org//30183005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29192 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-24 18:45:43 +00:00
sigmund@google.com 9424a70d30 Switch to lookup declaration by tag name. This fixes issue 14274.
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//37793004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29186 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-24 17:31:54 +00:00
jmesserly@google.com 0acc931fc4 port polymer data binding tests
R=sigmund@google.com

Review URL: https://codereview.chromium.org//25740006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29139 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-24 00:59:31 +00:00
jmesserly@google.com 7382a5ef78 add test for polymer custom events
I thought I would need to fix something, but it seems to be working :)

R=sigmund@google.com

Review URL: https://codereview.chromium.org//23447017

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29119 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-23 20:53:43 +00:00
jmesserly@google.com 360ea42322 Rename mdv -> template_binding, remove experiemntal apis from dart:html
essentially, we trade off reduce dart:html API surface area for more annoying usage of these APIs. Since Polymer hides most of this, I suspect it won't be too annoying in practice.

Sample usage:

    nodeBind(node).bind(...)

    templateBind(node).model = ...;

R=sigmund@google.com

Review URL: https://codereview.chromium.org//34453003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29057 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-23 02:11:49 +00:00
jmesserly@google.com eb72738cc9 remove xtag from Polymer
R=blois@google.com

Review URL: https://codereview.chromium.org//34533004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29025 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-22 19:04:39 +00:00
blois@google.com bcf24e3c00 Fixing polymer element registration when extending tag extensions
BUG=14127
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//33903003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29006 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-22 16:20:04 +00:00
sigmund@google.com 357af01f40 Fix prop_attr_reflection_test in drt/dartium (fixes issue 14295)
R=jmesserly@google.com

Review URL: https://codereview.chromium.org//34213002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@29005 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-22 16:18:14 +00:00
sigmund@google.com 4d357c5148 Improves how to initialize polymer apps and fixes polymer build and linter to
match Dartium semantics (Issue 14238). In particular:
  - only one script tag is allowed per document
  - initPolymer can be call from init.dart or the users main method, the build
    process knows how to call the user's main given the new Dartium semantics.

R=jmesserly@google.com

Review URL: https://codereview.chromium.org//27903006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28971 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-21 23:30:23 +00:00
jmesserly@google.com 0145636d89 fix analyzer issue in listorder_test
also fix polymer test/run.sh to test analyzer again

Review URL: https://codereview.chromium.org//32253003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28962 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-21 22:08:20 +00:00
jmesserly@google.com 821e6fec2a Several fixes here to fix bugs and get our tests into a reliable state:
* customElementsReady future. We don't fire Polymer.onReady until custom elements are ready too

* deploy without dart.js by default. This is the expected deployment mode for real apps. Also make sure we test this on DRT and compiler==js, so Pete can change Dartium without causing build breaks :)

* stop using "package:observe" test "performMicrotaskCheckpoint" hack in Polymer. This was too blunt; it affected timing of all async operations. Instead we only trigger Observable.dirtyCheck. It's using the latest Zone API as well.

* mixin ChangeNotifier explicitly. This is mainly to fix a quirk of our test environment (test server loads "packages/polymer" in untransformed mode, causing it to pick up Observable instead of ChangeNotifier).

* fix change watchers to blacklist "attributeChanged" :)

* fix serializeValue to only use the runtime value

* fix deserializeValue to get the right Type for dart:core types

* cleanup prop_attr_reflection_test to use mutation observer

R=blois@google.com, sigmund@google.com

Review URL: https://codereview.chromium.org//29823005

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28956 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-21 21:49:51 +00:00
sigmund@google.com 580d807b66 Transformer plugin for polymer. This will make it possible (one day) to use
polymer transformers in pub-build and pub-serve by writing:

transformers:
  - polymer:
      entry_points: web/index.html

I say one day because there are still a few pending bugs on the vm and the pub
side of things that need to be resolved before this works.

R=jmesserly@google.com

Review URL: https://codereview.chromium.org//28053008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28942 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-21 19:21:52 +00:00
sigmund@google.com 728114e4c6 Update status on browser-only tests.
Review URL: https://codereview.chromium.org//26967009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28779 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-17 04:27:45 +00:00
jmesserly@google.com 38c4cd1f6b package:observe fix various api issues
in particular:
provide oldValue/newValue/target in PropertyChangeRecord -- https://code.google.com/p/dart/issues/detail?id=12075
use == in notifyPropertyChange -- https://code.google.com/p/dart/issues/detail?id=12463
remove Mixin/Base suffix -- https://code.google.com/p/dart/issues/detail?id=13353
remove ChangeRecord.changes -- https://code.google.com/p/dart/issues/detail?id=14128

other changes:
rename PropertyChangeRecord.field to .name (it's not just fields)
PathObserver rethrows errors from inside the getter/setter to help debug those
PathObserver now looks up Map keys using Strings instead of Symbols.
generic type on PropertyChangeRecord, MapChangeRecord

I stopped short of adding "target" to List/Map change record but am interested in a follow up to address that: https://code.google.com/p/dart/issues/detail?id=14157

R=sigmund@google.com

Review URL: https://codereview.chromium.org//27618002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28774 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-17 03:32:40 +00:00
sigmund@google.com 6c4e38b81e Practically remove boot.js, adds the initialization from the Dart side of
things, and fixes examples to work this way.

R=jmesserly@google.com

Review URL: https://codereview.chromium.org//27518006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28773 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-17 02:43:50 +00:00
jmesserly@google.com d583f16e4f add @MirrorsUsed to observe/polymer/polymer_exprs pkgs
Fairly straightforward. @observable and @CustomTag are metaTargets, so no changes needed for types that use those. The only other changes are for data binding to objects with built in change notification. In that case, we add package:observe's @reflectable annotation. Other than that, just a few other things in mirrors that are now locked down appropriately to only reflect on the things they need.

R=sigmund@google.com

Review URL: https://codereview.chromium.org//26967004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28689 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-15 22:55:47 +00:00
jmesserly@google.com ceb15d891c fix PolymerElement.bind to call reflectPropertyToAttribute w/ prop name
This is the fix for issue 14060
Polymer.js fix is at: https://github.com/Polymer/polymer/pull/319

R=sigmund@google.com

Review URL: https://codereview.chromium.org//27417002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28688 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-15 22:41:19 +00:00
blois@google.com f2573b0a0a Converting Polymer's WebComponentsLoaded to an onReady future
This avoids double-firing of the event when the CustomElements polyfill is present and allows tests to wait for the future without worrying about missing the event.

BUG=
R=sigmund@google.com

Review URL: https://codereview.chromium.org//27307004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28665 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-15 17:37:24 +00:00
blois@google.com 43d834bae9 Updating todomvc for some polymer changes
Should have caught some earlier, but I just added the base class validation.

TBR
BUG=

Review URL: https://codereview.chromium.org//26660004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28624 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-15 00:52:15 +00:00
blois@google.com 1cb69bc901 Fixing bots after Polymer element integration
TBR
BUG=

Review URL: https://codereview.chromium.org//27274002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@28621 260f80e4-7a28-3924-810f-c04153c831b5
2013-10-14 23:46:17 +00:00