Changes:
- adds a couple of radio buttons to the drawer menu list.
- makes menu items support being tapped and reporting the tap.
- hooks up the checkbox to actually support being checked.
- changes the drawer menu items to make more sense in a stock app.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1137373004
This exposes most methods from Skia's C canvas API to Dart. For now, SkRect and
SkMatrix are represented simply as an array of floats, which requires a
conversion at the bindings layer. More complex types like SkPath are still TODO.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1144483002
This adds a new abstract 'Canvas' which is similar to SkCanvas.
PaintContext implements Canvas while still having its
own commit() method to cause the paint actions to apply to
the Element for the next frame.
This adds a new PictureRecorder which also implements Canvas
and has an endRecording() method which returns a Picture
(another new interface) which can be held from Dart.
There is also now a rootPicture setter on Document which takes
a Picture and will then make the Document draw that Picture
until changed.
This piggybacks on the existing custom painting system
which adds the painting at background-and-borders paint
time so technically if you both set rootPicture as well as
construct a DOM you will draw the DOM on top of your picture. :)
R=mpcomplete@chromium.org
Review URL: https://codereview.chromium.org/1122423009
- add a checkbox to the stock app, so that we're testing the checkbox widget
(it's not currently wired up to anything, that can come later)
- make InkSplash use FlexContainer so that we can use flex in the popup menu items
- make effen's Text be more similar to Image and Container, so that it can be styled
- make layout.dart's RenderCSSText correctly support being styled
- also fixes a bug with the stock list where we were rendering one too few a row when scrolling
- check in the code to dump the DOM so I don't have to keep remembering how to do this
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1134163003
- make the ScrollBehavior instance long-lived, rather than recreating
it each time we update the list contents.
- have OverscrollBehavior track the total height of the contents and
the height of the scrollable region, so that it can determine when
to stop scrolling down.
- teach OverscrollBehavior about how to determine when to stop
scrolling down, and how to bounce when it's too far down.
- replace the 'energy' concept in Particles with a method that sets
the energy and direction at the same time, instead of assuming that
the direction is always positive when setting energy.
- make FixedHeightScrollable lists track the number of items in the
list and have them update their ScrollBehavior regarding this
information as it changes.
- track how many items are currently showing in the list stock list.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1097373002
Currently, if you then scroll down N items with a filter set, we select which
stock to show by taking the entire list of stocks, skipping the first N, then
filtering the list, then selecting as many stocks as needed to fill the list.
So suppose the list is A, B, Cx, Dx, Ex, F, and the filter is "x", and you've
scrolled down 1 item.
Currently we'd show Cx, Dx, Ex.
Scroll down 1 again.
We still show Cx, Dx, Ex.
What we _should_ show is Dx, Ex if you've scrolled down 1, and just Ex if you've
scrolled two.
This patch fixes this. We now skip rows _after_ filtering. This fixes
the bug whereby if you set a filter then fling the list, we show the
same item over and over as if in a loop.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1057603006
Text can only only inside paragraphs and inlines. This patch makes it
so we stop putting such text nodes in the render tree at all if their
parent is not a paragraph or an inline.
This is the final step in making it so that we don't create anonymous
renderers, which fixes a crash in the new custom layout code.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1077473002
-Make display:flex, flex-direction: column, flex-shrink: 1 the default.
-Simplify StyleAdjuster::adjustStyleForAlignment to remove special cases we
won't need as we make flex the default and remove absolute positioning.
-Fix a bug this exposed in column flexboxes where we'd apply the wrong edge
of border/padding/margin.
-For now leave the default of align-items:stretch. The main change here is
that iframe/img will do width:auto the same as blocks (i.e. the width of
the parent). I think this is a good change, but we'll have to see how it feels
in practice.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1061163002
Flights is not longer a good example of something you can build wity Sky.
Restore the flights-app-pixel test and move the assets needed for the test into
the tests directory.
R=ojan@chromium.org
Review URL: https://codereview.chromium.org/1034953003
When the StocksApp menu is showing, the user shouldn't be able to interact with
the rest of the app. Instead, taps outside the menu should dismiss the menu.
This CL makes that happen by adding a ModalOverlay on top of the app. We might
want to do something fancier in the future using event delegation, but this
works for now.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/1031093002
This CL teaches PopupMenu how to animate out as well as in. Also, I've changed
the PopupMenuItem animations to be driven from the PopupMenu itself, which
makes it easier to run the animation in reverse when closing the menu.
TBR=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/1033913002
This CL cleans up stock_app.dart to better separate concerns now that we have
StyleNode. Also, this CL introduces IconButton, which will grow to include an
ink effect in the future, and makes the background of the search bar white.
R=ojan@chromium.org
Review URL: https://codereview.chromium.org/1007893005
Previously we would spend a lot of time during startup processing all 3k stocks
in the data set. This CL breaks the data up into 100 stock chunks and loads
them incrementally off the network. A future CL will switch to loading them on
demand.
R=ojan@chromium.org
Review URL: https://codereview.chromium.org/1038533002
It's especially crappy since it doesn't actually do much/any error
handling.
Use:
$ sky/tools/skydb start out/Debug \
'sky/examples/terminal/index.sky?url=mojo:netcat?host=localhost%26port=80'
(Note: We don't have a resolver yet, so the host either has to be
"localhost" or an IPv4 address in the form N1.N2.N3.N4.)
R=erg@chromium.org
Review URL: https://codereview.chromium.org/1032743002
Instead of hard-coding the stock data in the Dart file, this CL moves the data
to a JSON file and loads that file over the network. This change improves load
time for the Stocks app from 3 seconds to 2 seconds.
Also, this CL removes shake-to-reload from the Stocks app because that also
slows down load time (due to the two module systems fighting each other).
R=rafaelw@chromium.org, ojan@chromium.org
Review URL: https://codereview.chromium.org/1021723005
StockMenu was creating a container for the sole purpose of applying style to
PopupMenu. Now we just use a StyleNode.
Also, I've reverted the change to make box-sizing default to border-box. It
turns out that CL wasn't effective because we didn't use the initialBoxSizing
function to initialize box sizing. I've made us use initialBoxSizing but switch
the default back to content-box because actually using border-box breaks a
bunch of stuff.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1024083003
This patch adds a new (non-Render) StyleNode which takes two arguments: A (content) node, which it wraps and a Style object.
This allows for styles to be applied to Nodes which are constructed elsewhere (e.g. passed in as arguments).
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1027653002
This CL adds just enough custom painting to Sky to make
sky/examples/painting/circle.sky draw a circle. Over time, we should be able to
elaborate this system into something interesting and to make it actually work
in a reasonable way.
R=ojan@chromium.org
Review URL: https://codereview.chromium.org/1017593005
1) Factors InkWell out of Material so that components can use an ink well
without needing the shadow/level machinery.
2) Makes the ink effect move at a different velocity once the tap has actually
occurred, converging with the spec. We don't have the right speeds yet, but
at least we're approaching the right shape.
3) To support (2), added a primaryPointer attribute to GestureEvents to let
authors coorelate gesturetapdown events with later gesturetap events.
4) To support (2), modernized SplashAnimation to used AnimatedValue and friends.
5) Added more constants to view-configuration.dart that match Android.
I've also removed the cancelling of the ink effect on scroll. The proper way to
do that is to notice that someone in the event chain is listening for
scrollstart and delay the beginning of the ink effect for some period of time.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1019023003
This patch removes the mutable API to event handling (Nodes no longer have a events object with which to add listeners).
Instead, a new (non-Render) Node is introduced: EventTarget. This node represents a location in the Effen tree which can handle events as they bubble.
Note that this also changes the implementation to use event delegation (one set of listeners at the sky.document level) rather than direct listeners on leaf nodes.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1019633004
We're now doing all of the elements of the popup menu entrance animation from
the material design spec, but our timing and curves might not be exactly right
yet. I haven't started on the exit animation.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1017193004
Before this change Sky would hit 404s when trying to
load examples from domokit.github.io.
I also added a separate sky_home and updated the default
url to point to sky_home instead of home.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/1016143002
This CL also refactors how animations work, particularly for the Drawer. I've
renamed DrawerAnimation to DrawerController and switched it from being an
Animation to having an Animation. I've also renamed Animation to AnimatedValue
to capture the idea that the class actually presents the value being animated.
Finally, I've factored AnimatedValueListener out of Drawer so that it can be
used by PopupMenuItem as well.
Finally, I've added a scheduleBuild convienence function to Component instead
of having to call setState(() {}), which has come up a couple times.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1016093002
This CL is a warmup for using a more sophisticated gesture disambiguation.
1) Use gesturetap instead of click. We should probably remove click events
because folks should use gesturetap to integrate with the gesture system.
2) Handle the case where you swipe the drawer during an animation. Previously
we had an assert which triggered in some multitouch scenarios. We'll
eventually move this over to gestureswipe.
3) Remove an extra container for ink splashes. There's no need to group all the
ink splashes in a container. They can all just be children of the Material
component itself. This structure is left over from when Material was a base
class.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1013713005
This CL cleans up the sky/framework/animation as follows:
1) I've moved code that's used only by the custom elements framework into
sky/framework/elements/animation. This code is based on AnimationDelegates
rather than Streams.
2) Rename ScrollCurve to ScrollBehavior because it encapsulates more behavior
than just a curve.
3) Make the Generator interface explicit and mark subclasses as actual
subclasses.
4) Move Simulation into generators.dart because it implements the Generator
interface.
5) Move Animation out of generators.dart because it does not implement the
Generator interface.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1001373002
When using OverscrollCurve, we continue to scroll beyond the top of the
scrollable area but the scroll delta is reduced by 2x. A future CL will add an
animation at gesturescrollend to relax back to scroll position 0.0.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1002953003
Intead of hard-coding the notion of bounded scrolling into Scrollable, this CL
factors out a ScrollCurve class that applies the bounds. In the future, we'll
refine this mechanism to implement overflow scrolling.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/1005633002
Also:
* Fix consecutive spaces (don't collapse them).
* Add support for ^L.
Still doesn't work:
* Totally blank lines. (I know why, but I don't know why I can't seem to
fix it.)
R=erg@chromium.org
Review URL: https://codereview.chromium.org/997873004
To accomplish this, I made the following changes:
1) Material is now in charge of drawing the material shadows.
2) In order to mix in the style for the shadow, Element now takes a list of
Styles instead of a single style.
3) Update all clients of Element#style to understand that we now have a list.
4) Update components that drawer shadows to have Material do that work instead.
a) One exception: FloatingActionButton draws its own shadow because of its
crazy clip requirements. We'll probably want to find a better way for
FloatingActionButton to clip in the future.
I've also added a widgets-fn example to demo the fn material widgets.
This CL introduces a bug into Drawer whereby you can get ink splashes
everywhere in the drawer. In the future, we'll need to separate out the
different material aspects to get non-splashable materials.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/1003553002
Instead of MaterialComponent being a base class, components that want material
behavior simply create a MaterialComponent during their render function. This
approach gives the component more flexibility as to its structure and gives
MaterialComponent more flexibility has to how the components it generates are
related to the existing children.
Also, I've improved some of the event delegation code. There's no reason to
attach event handlers to the root component you emit during |render| because
the framework already delegates events from your root component to you.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/983903003
This CL factors EditableString out of EditableText and implements more of the
InputConnection functions. As a result, EditableText now basically works.
This CL also paves the way to make EditableText stateless by using
EditableString as its state object. However, there's still a bit more work to
do to make that a reality (e.g., factoring out the cursor blink timer and the
connection to the keyboard).
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/995073002
This patch allows for an initial delay before an animation begins and also adds an Animation class which encapsulates a value which is long-lived, can be explicitly set and also animated from its current value to another value.
BUG=
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/994143002
This patch changes the timing of the unmount call until after the component is removed (and marked as such) and allows setState to be called after this point. If this happens, setState will still invoke the closer to do any neccesary cleanup, but doesn't schedule the component for render
R=eseidel@chromium.org, eseidel
BUG=
Review URL: https://codereview.chromium.org/985853002
To test:
sky/tools/shelldb analyze sky/examples/stocks-fn/stocksapp.dart
It prints 600+ warnings about the "native" keyword, and after
this change only a couple warnings about missing library names
which I don't fully understand.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/987613002
It's awkward to work on fn.dart in the examples directory so this CL moves it
to /sky/framework. Also, I've merged the whole library into one file instead of
using the |part| mechanism. The whole thing isn't that big.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/987463002
- Removed out-of-date README.md
- Moved fling-curve into the animation directory because it's part of the
animation behavior of the system.
- Moved view-configuration into the theme directory because it's a collection
of constants similar in flavor to the colors and the shadows. Eventually
we'll want to make the theme configurable and have these all together will
hopefully make that easier.
- Moved dom-serializer into tests/resources because it is used only by tests.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/980423002
Previously, the two versions of this sample app had separate copies of the
stock data. This CL moves the common data to the common data directory so that
they can share. Also, I've switched the data files to be |dart| files rather
than |sky| files to make them easier to use from fn examples.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/980953002
This CL removes a bunch of examples that don't actually work in the current
engine. I've also renamed example-element to custom-element and
example-scrollable to scrolling because the word "example" in the name is
redundant with the name of the directory.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/980323003
This CL changes how events work in fn. Previously, event listeners were passed
in as constructor arguments. Now Nodes hold an |events| object, which contains
all the event registrations. When a Component renders, all its |events| are
copied onto the Node it produces. When an Element syncs, it walks its |events|
and adds them as event listeners on the underlying sky.Element.
The net result of this change is increased flexibility in how events are
registered. Now components don't need to enumerate all the possible events that
they support. Instead, the parent component can listen for whatever events it
likes.
Also, I've cleaned up the association between DrawerAnimation and Drawer. Now
the constructor for Drawer accepts an |animation| object and wires up its
internal event handlers itself instead of requiring the constructor to do all
the wiring.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/975863003
This CL adds license blocks and cleans up a number of Dart idioms in fn.
Specifically, I've marked several fields as |final| and used Map#putIfAbsent in
some appropriate places.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/973613004
If there is jank, we might not get a frame time that's just after the last
frame, which means we'll stop generating animation frames before hitting 1.0
exactly.
In this CL, we introduce state to takeWhile to cancel the stream after emitting the
1.0.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/975153002
This is just a proof of concept. If we like this direction, it will move out of the examples directory (likely re-written) and be committed in smaller pieces with unit tests and formal reviews.
TBR=abarth
BUG=
Review URL: https://codereview.chromium.org/971183002
I removed the green background and added display
of percent change (which is random for now).
I also display a random assortment of stocks every time
instead of always the top 100.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/950073002
This CL updates sky-box, sky-button, sky-checkbox, sky-input, and sky-radio to
work in Dart. We don't have a data binding system yet, so there's a bit more
plumbing in the code.
This CL adds support for sky-element@attributes, which lets you specify which
attributes your element supports. We use this information to synthesize getters
and setters for those attributes and to dispatch to mumbleChanged methods when
the attributes change.
I've also wrapped the widgets demo itself in a sky-scrollable so the whole
thing scrolls.
R=eseidel@chromium.org
Review URL: https://codereview.chromium.org/946813005
After this CL, you can use <sky-element> to describe custom elements. The
current iteration is very basic and is hardcoded to "example", but its a start.
This CL renames the |init| function to |_init| to prevent importers from
calling it directly. Also, we now pass the <script> element to |_init| to give
some context.
R=ojan@chromium.org, eseidel@chromium.org
Review URL: https://codereview.chromium.org/950493003
These now appear on internals as takeServicesProvidedToEmbedder and
takeServicesProvidedByEmbedder. When you call these functions, you get back the
raw int that represents the handle. We'll need to wrap them up inside the Dart
VM with the appropriate types. We can create a nice wrapper for that in a
future CL.
R=hansmuller@google.com, hansmuller@chromium.org
Review URL: https://codereview.chromium.org/944733002
two components: color-wheel, and color-picker which adds
a div that displays the selected color. Data binding is
used to connect the color-wheel's "color" property to the
sample div's background-color.
BUG=
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/872993006
Commit efc3afd428bd85fd3d12e0dc941b5eb7248ca30b broke it because
we'd computed an empty foreground layer. Now that background
painting is part of the foreground phase, we need to use the
background rect for clipping. As best I can tell, the
background rect is always >= the size of the foreground
rect, so it should be safe to use.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/876243002
Per the spec in modules.md the exports property should default to an
empty object. We lazy allocate it so that modules that just replace it
don't create the empty object and then throw it away.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/872043003
Instead of having a separate directory for every Sky element, we should just
put them in the general framework directory. Once the framework is more
complicated, we'll probably want to organize it a bit better, but for now there
aren't enough files to justify having so many directories.
R=esprehn@chromium.org
Review URL: https://codereview.chromium.org/874303003
We now only preserve the whitespace inside a <t> element inside
the parser. This removes the known n^2 from reattaching whitespace
which should make parsing and appending nodes faster. I also
removed the dead WhitespaceMode code from the parser, and made
the dom-seralizer.sky auto indent the markup so the test output
would be readable.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/867963006
We were cloning elements with all the attributes that contained
expressions like attrName="{{ foo }}" which meant we'd go through the
reflection process converting that value and also call the
attrNameChanged() callback and the attributeChanged() with the braced
string which the element didn't really want to know about.
After this patch we create a "clone source node" which is a copy of the
original element without the attributes that have the expressions and
use that when cloning, then we assign the properties using data binding
later.
R=abarth@chromium.org, ojan@chromium.org
Review URL: https://codereview.chromium.org/868973002
Previously, if you had a generated background image and a translucent (or
rounded) border, we would draw the image nine times because we would inflate
the fill rect to draw behind the border. With no-repeat, we only draw the image
once.
This saves 4.5% of record time on flights-app.
R=esprehn@chromium.org
Review URL: https://codereview.chromium.org/844193009
Instead of storing primitive values which makes the data
binding system throw away DOM each time we update each slot
lets just use objects and shift + pop. This means very little
data binding churn.
R=abarth@chromium.org
Review URL: https://codereview.chromium.org/802153004
All reflected attributes two way bind on SkyElement, so now doing
<sky-element name="sky-input" attributes="value:string"> is enough
to get two way binding on the value attribute so users doing
<sky-input value="{{ inputValue }}"> will get the inputValue property
updated as the user types.
R=abarth@chromium.org, ojan@chromium.org
Review URL: https://codereview.chromium.org/850383002
Specs: introduce layoutDescendants() to avoid work when a layout
manager is unaffected by its childrens' intrinsic dimensions
Examples: update for layoutDescendants() change
Specs: add "lifetime" to resolver settings so that a transition can
avoid having to dirty every consumer of the property every frame when
it only needs to update the objects that are changing that frame
Specs: expose the parents on AbstractStyleDeclarationList subclasses
Specs: fix documentation around autoreap
Specs: fix definition of setProperty()
Specs: clean up the dimension-related logic of layout managers
Review URL: https://codereview.chromium.org/850593003
Log an error whenever an element has an unknown attribute in a template.
This means you can't use generic attributes like Polymer, but we
probably want to discourage that anyway since attribute selectors should
be avoided for most things.
R=ojan@chromium.org
Review URL: https://codereview.chromium.org/845523004
Prior to this change the magic sequence was '#!mojo:' and the url of the content handler app included mojo:. This works only for mojo: urls, but we want
other schemes. So, the magic sequence is now '#!mojo ' and 'mojo ' is not part of the resulting url.
R=aa@chromium.org
Review URL: https://codereview.chromium.org/821403003
Now inside the <template> of a SkyElement you can use
on-eventName="method" on any element to add event listeners.
For example you can write <sky-button on-click="handleClick">
and then define handleClick(event) on the element class that
contains the button.
In adding this and tests I also realized that property bindings
were not setup on the initial call to bind(), which is now
fixed in this patch (See change to Node.prototype.bind).
R=eseidel@google.com, rafaelw@chromium.org
Review URL: https://codereview.chromium.org/812713005
Eventually we'll want to replace these with something
fancier like polymer, but this exercise helped us
find several bugs in the engine as well as
removed one more blocker from using Sky to
replace mojo/views usage in mojo/examples.
R=esprehn@chromium.org
BUG=443439
Review URL: https://codereview.chromium.org/809233002
The syntax for implementing a SkyElement is now:
<sky-element name="element-name">
<template>
<!-- template here -->
</template>
<script>
module.exports = class extends SkyElement {
attached() {
// ...
}
// .. methods here ..
}.register();
</script>
</sky-element>
The register() static method on SkyElement subclasses calls
document.registerElement() and returns the generated constructor.
It uses the parent <sky-element>'s name attribute to set the name
of the element.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/788943003
actually telling your child to paint, you just say where it would
paint. The platform then takes care of making sure all the dirty nodes
have their paint() methods called.
Review URL: https://codereview.chromium.org/744843003
-Add RenderParagraph and display:paragraph. This is the only
render type that's allowed to contain inlines or text.
-If you put text nodes directly in a non-paragraph, wrap them
in an anonymous paragraph. This may not be the place we want
to end up, but it's a good stopgap to make it so we don't
crash in this case.
-Make StyleAdjuster force that non-paragraph blocks only contain
RenderBlock subclasses and that paragraphs and inlines only contain
inlines.
-Considerably simplify addChildIgnoringAnonymousColumnBlocks
now that we only create anonymous blocks for the case of
text nodes in non-paragraphs. Also get rid of the behavior
where we try to group multiple nodes into a single
anonymous block.
R=esprehn@chromium.org
Review URL: https://codereview.chromium.org/729693003
element; an example that uses that example to define some HTMLy
elements; and an example to use those HTMLy elements to display a
hello world doc. Highly incomplete WIP.
Review URL: https://codereview.chromium.org/698293003
that uses it looks nicer; this moves the complexity to places that
register elements without using 'class' (e.g. the internals of
frameworks that create elements for defining elements)
Review URL: https://codereview.chromium.org/699083005
parsed' callback; pass the element's module to the constructor when
constructing a custom element (these are rather experimental changes
and we may want to go a different way on this stuff)
Review URL: https://codereview.chromium.org/701873004
In mojom, there's a notion of a request/response pair. This CL teaches the JS
bindings not to GC a message pipe after a request has been issued but before
the response has been received.
R=hansmuller@chromium.org
Review URL: https://codereview.chromium.org/696373003
This has the following implications:
- There's no createElement() function any more. If you want to create
an element from script, you have to use its constructor.
- There's no async element registration. The parser will block until
all the imports are imported when you use a tag name of a custom
element that hasn't been registered yet, in case one of the imports
defines it.
- If you try to construct a non-registered element in markup, it
turns into an <error> element.
- <div>, <span>, and <error> are new built-in elements.
R=esprehn@chromium.org
Review URL: https://codereview.chromium.org/695423004
Previously we were using string concatenation to build up the directory
listing. Now we fetch some JSON from the server and use data binding to inflate
a directory listing.
This exmaple doesn't work yet because we're missing support for
template@repeat, but hopefully we'll get that soon.
Also, added support for setRequestHeader to XMLHttpRequest.
R=rafaelw@chromium.org
Review URL: https://codereview.chromium.org/688413005
I had to also register for the text/plain mime-type
which turned out to be harder than expected.
Mostly due to my confusion with mojo_shell
using last-argument-wins argument parsing.
R=ianh@google.com
Review URL: https://codereview.chromium.org/672363002