blob: 5e0539547b9c76202228e9025ca952dbae6f4800 [file] [log] [blame]
<!DOCTYPE html>
<!--
Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
for details. All rights reserved. Use of this source code is governed by a
BSD-style license that can be found in the LICENSE file.
-->
<html lang="en" manifest="ssl.appcache" itemscope itemtype="http://schema.org/Product">
<head>
<meta charset="utf-8">
<title>Try Dart!</title>
<meta http-equiv="Content-type" content="text/html;charset=UTF-8">
<!--
TODO(ahe): Reduce the number of fonts used based on actual usage.
See: http://www.google.com/fonts#UsePlace:use/Collection:Open+Sans:400,600,700,800,300
-->
<link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet">
<link href='//fonts.googleapis.com/css?family=Open+Sans:400,600,700,800,300' rel='stylesheet' type='text/css'>
<link rel="stylesheet" type="text/css" href="dartlang-style.css">
<link rel="alternate stylesheet" type="text/css" href="line_numbers.css" title="line_numbers">
<style>
a.diagnostic {
color: inherit;
border-bottom: 2px dotted red;
}
a:hover.diagnostic {
text-decoration: none;
}
a.diagnostic>span {
display: none;
max-width: 70%;
}
a:hover.diagnostic>span.diagnostic, a:hover.diagnostic>span.alert {
display: block;
position: absolute;
/* left: 1em; */
/* top: 2em; */
right: 1%;
}
.offline {
transition: opacity 10s;
-webkit-transition: opacity 10s;
}
.offlineyay {
font-weight: bolder;
opacity: 0.0;
}
.dart-code-completion-holder {
position: relative;
display: inline-block;
}
.dart-code-completion-holder /deep/ *.dart-code-completion {
display: none;
position: absolute;
left: 0px;
min-width: 200px;
background: white;
foreground: black;
border: 1px solid black;
z-index: 10;
padding-left: 5px;
}
.dart-code-completion-holder.active /deep/ *.dart-code-completion {
display: block;
}
body /deep/ .dart-static {
width: 198px;
overflow: auto;
}
/*
* TODO(ahe): There are problems with scroll bars on Macs, see:
* http://stackoverflow.com/questions/7855590/how-can-i-prevent-scroll-bars-from-being-hidden-for-os-x-trackpad-users-in-webki
* .dart-static::-webkit-scrollbar {
* -webkit-appearance: none;
* }
*
* .dart-static::-webkit-scrollbar:vertical {
* width: 11px;
* }
*
* .dart-static::-webkit-scrollbar:horizontal {
* height: 11px;
* }
*
* .dart-static::-webkit-scrollbar-thumb {
* border-radius: 8px;
* border: 2px solid white; /* should match background, can't be transparent * /
* background-color: rgba(0, 0, 0, .5);
* }
*
* .dart-static::-webkit-scrollbar-track {
* background-color: #fff;
* border-radius: 8px;
* }
*/
body /deep/ .dart-limited-height {
/* TODO(ahe): Make sure to compute this height to avoid jumping in the UI. */
max-height: 66px;
}
body /deep/ .dart-server {
width: 198px;
border-top: 1px solid black;
}
body /deep/ .activeEntry {
background: #86b4bf;
}
body /deep/ .doubleplusgood {
font-weight: 700;
}
body /deep/ .dart-entry {
max-width: 198px;
overflow: hidden;
white-space: nowrap;
}
body /deep/ .hazed-suggestion {
color: #aaa;
}
body /deep/ .hazed-suggestion:after {
content: " ";
}
.slider {
overflow-y: hidden;
height: 0;
max-height: 9999px;
transition-property: height;
transition-duration: .5s;
transition-timing-function: cubic-bezier(0.4, 0.0, 0.2, 1);
/* cubic-bezier(0, 1, 0.5, 1);*/
}
.myhidden {
position: absolute;
visibility: hidden;
height: auto;
}
.mainEditorPane {
white-space: pre;
/* Extra padding at the bottom to ensure display of error messages. */
padding: 19px 19px 70px 19px;
}
.lineNumber {
}
</style>
<meta itemprop="name" content="Try Dart!">
<meta itemprop="description" content="Write and run Dart code in your browser. Dart is a class-based, object-oriented language with lexical scoping, closures, and optional static typing.">
<meta name="description" content="Write and run Dart code in your browser. Dart is a class-based, object-oriented language with lexical scoping, closures, and optional static typing.">
<meta itemprop="image" content="try-dart-screenshot.png">
<link rel="dart-sdk" href="sdk.json">
<link rel="benchmark-DeltaBlue" href="benchmarks/DeltaBlue.dart">
<link rel="benchmark-Richards" href="benchmarks/Richards.dart">
<link rel="benchmark-base" href="benchmarks/benchmark_base.dart">
<link href="favicon.ico" rel="icon" type="image/x-icon">
<meta name="viewport" content="initial-scale=1.0">
<!-- Chrome Mobile (Android) "Add to home screen" support -->
<meta name="mobile-web-app-capable" content="yes">
<link rel="shortcut icon" sizes="196x196" href="dart-icon-196px.png">
<!-- iOS "Add to Home Screen" support -->
<meta name="apple-mobile-web-app-capable" content="yes">
<link rel="apple-touch-icon" href="dart-icon-196px.png">
<meta names="apple-mobile-web-app-status-bar-style" content="black">
<link rel="apple-touch-startup-image"
media="(device-width: 320px)
and (device-height: 568px)
and (-webkit-device-pixel-ratio: 2)"
href="dart-iphone5.png">
<!-- Enable Google Analytics -->
<script type="text/javascript">
if (document.cookie.split(new RegExp('; *')).indexOf('org-trydart-AutomatedTest=true') == -1) {
window.parent && window.parent.postMessage('Enabling Analytics.', '*');
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-26406144-2']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
}
</script>
</head>
<body>
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<a class="brand" href="//www.dartlang.org/" title="Dart Homepage" target="_blank">
<img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABUAAAAVCAMAAACeyVWkAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAJxQTFRFAAAAAIvMdsvDAIvMdsvDAIvMdsvDLaTJAIvMOqnHdsvDAIvMdsvDAIvMKaLJdsvDAIvMAIvMdsvDAIvMdsvDdsvDAIvMAIvMAZnFdsvDAILHAIPHAITIAIXJAIfKAIjKAIrLAIrMAIvMAJXHAJjFC5i/I6HENr2yOb6zPr+0TsK4UsO5WbnEWcW8Xsa9Yse+Zsi/asjAc8rCdsvDdt4SRQAAABp0Uk5TABAQICAwMFBgYGBwcICAgI+vr7+/z9/v7+97IXGnAAAAqUlEQVQYV13QxxaCQBBE0VZkjBgAGVEBaVEUM/P//yaTGg5vV3dZANTCZ9BvFAoR93kVC9FnthW6uIPTJ7UkdHaXvS2LXKNBURInyDXPsShbzjU7XCpxhooDVGo5QcQAJmjUco64AY/UcIrowYCTaj5KBZeTaj5JBTc6l11OlQKMf497y1ahefFb3TQfcqtM/fipJF/X9gnDon6/ah/aDDfNOgosNA2b8QdGciZlh/U93AAAAABJRU5ErkJggg==" alt="Dart">
</a>
<ul class="nav pull-right"><li><a href="https://code.google.com/p/dart/issues/entry?template=Try+Dart+Bug" target="_blank"><i class="fa fa-bug"></i></a></li><li><a href="#" id="settings"><i class="icon-cog"></i></a></li></ul>
<ul class="nav hidden-phone">
<li class="active"><a>Try Dart!</a></li>
<li><a href="//api.dartlang.org/" target="_blank">API Reference</a></li>
</ul>
<form class="navbar-search pull-right hidden-phone" action="//www.dartlang.org/search.html" id="cse-search-box" target="_blank">
<input type="hidden" name="ie" value="UTF-8">
<input type="hidden" name="hl" value="en">
<input type="search" name="q" class="search-query" id="q" autocomplete="off" placeholder="Search">
</form>
<ul class="nav pull-right"><li><a><span id="appcache-status" class="offline">offline status</span></a></li></ul>
</div>
</div>
</div>
<div id="settings-dialog" class="myhidden container-fluid">
<div class="row-fluid">
<div class="span12">
<div>
<h3>Settings</h3>
<div id="settings-body">
</div>
<div>
<a href="#" class="btn btn-primary" id="settings-done">Close</a>
</div>
</div>
</div>
</div>
</div>
<div class="container-fluid">
<article class="homepage">
<section>
<div class="callouts row-fluid">
<div class="span6" id="try-dart-column">
<h2><i class="icon-play"></i> Try Dart! <select id="code-picker"></select></h2>
</div>
<div class="span6" id="run-dart-column">
<h2><i class="icon-cogs"></i> See Dart</h2>
</div>
</div>
</section>
</article>
</div>
<footer>
<div class="container">
<div class="row copyright">
<div class="span8 offset2">
<p>
Except as otherwise <a href="http://code.google.com/policies.html#restrictions">noted</a>, the content of this page is licensed under the <a href="http://creativecommons.org/licenses/by/3.0/">Creative Commons Attribution 3.0 License</a>, and code samples are licensed under the <a href="http://code.google.com/google_bsd_license.html">BSD License</a>.
</p>
<p>
<a href="//www.dartlang.org/tos.html">Terms of Service</a>
<a href="http://www.google.com/intl/en/policies/privacy/">Privacy Policy</a>
</p>
</div>
</div>
</div>
</footer>
<!--
<script type="application/javascript" src="https://dart.googlecode.com/svn/branches/bleeding_edge/dart/pkg/browser/lib/dart.js"></script>
<script type="application/dart" src="leap.dart"></script>
-->
<script type="application/javascript">
if (self.localStorage &&
!Object.prototype.hasOwnProperty.call(
self.localStorage, 'hasSelectionModify')) {
self.localStorage.hasSelectionModify =
typeof window.getSelection().modify != 'undefined';
}
</script>
<script type="application/javascript" src="leap.dart.js"></script>
</body>
</html>