Have editor options survive across followed links

pull/237/head
Alex Dima 9 years ago
parent 4dfa2b4d44
commit c78c7308a8

@ -300,7 +300,7 @@ gulp.task('generate-test-samples', function() {
'',
'/*----------------------------------------SAMPLE CSS END*/',
'</style>',
'<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>',
'<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>',
'THIS IS A GENERATED FILE VIA gulp generate-test-samples',
'',
'<div id="bar" style="margin-bottom: 6px;"></div>',
@ -341,13 +341,16 @@ gulp.task('generate-test-samples', function() {
'<!-- THIS IS A GENERATED FILE VIA gulp generate-test-samples -->',
'<html>',
'<head>',
' <base href="..">',
'</head>',
'<body>',
'<a href="../index.html">[&lt;&lt; BACK]</a><br/>',
'<a class="loading-opts" href="index.html">[&lt;&lt; BACK]</a><br/>',
'THIS IS A GENERATED FILE VIA gulp generate-test-samples<br/><br/>',
locations.map(function(location) {
return '<a href="' + location.path + '">' + location.name + '</a>';
return '<a class="loading-opts" href="playground.generated/' + location.path + '">' + location.name + '</a>';
}).join('<br/>\n'),
'<script src="../metadata.js"></script>',
'<script src="dev-setup.js"></script>',
'</body>',
'</html>',
]

@ -136,6 +136,14 @@
div.innerHTML = '<ul><li>' + allComponents.map(function(component) { return component.renderLoadingOptions(); }).join('</li><li>') + '</li></ul>';
document.body.appendChild(div);
var aElements = document.getElementsByTagName('a');
for (var i = 0; i < aElements.length; i++) {
var aElement = aElements[i];
if (aElement.className === 'loading-opts') {
aElement.href += window.location.search
}
}
})();

@ -8,21 +8,21 @@
<body>
Jump to:
<a href="./smoketest.html?editor=releaseMin">[SMOKETEST]</a>
<a class="loading-opts" href="./smoketest.html">[SMOKETEST]</a>
&nbsp;|&nbsp;
<a href="./playground.generated/index.html">[PLAYGROUND]</a>
<a class="loading-opts" href="./playground.generated/index.html">[PLAYGROUND]</a>
&nbsp;|&nbsp;
<a href="./mouse-fixed.html">[fixed element]</a>
<a class="loading-opts" href="./mouse-fixed.html">[fixed element]</a>
&nbsp;|&nbsp;
<a href="./mouse-scrollable-body.html">[scrollable body]</a>
<a class="loading-opts" href="./mouse-scrollable-body.html">[scrollable body]</a>
&nbsp;|&nbsp;
<a href="./mouse-scrollable-element.html">[scrollable element]</a>
<a class="loading-opts" href="./mouse-scrollable-element.html">[scrollable element]</a>
&nbsp;|&nbsp;
<a href="./colorize.html">[colorize element]</a>
<a class="loading-opts" href="./colorize.html">[colorize element]</a>
&nbsp;|&nbsp;
<a href="./cross-origin-broken.html">[cross origin broken]</a>
<a class="loading-opts" href="./cross-origin-broken.html">[cross origin broken]</a>
&nbsp;|&nbsp;
<a href="./cross-origin-good.html">[cross origin good]</a>
<a class="loading-opts" href="./cross-origin-good.html">[cross origin good]</a>
<br/><br/>
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -15,7 +15,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -46,7 +46,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -24,7 +24,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -24,7 +24,7 @@ b) inspecting the dom elements rendered by the editor;
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -29,7 +29,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -2,33 +2,36 @@
<!-- THIS IS A GENERATED FILE VIA gulp generate-test-samples -->
<html>
<head>
<base href="..">
</head>
<body>
<a href="../index.html">[&lt;&lt; BACK]</a><br/>
<a class="loading-opts" href="index.html">[&lt;&lt; BACK]</a><br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples<br/><br/>
<a href="creating-the-editor-hello-world.html">Creating the editor &gt; Hello world!</a><br/>
<a href="creating-the-editor-editor-basic-options.html">Creating the editor &gt; Editor basic options</a><br/>
<a href="creating-the-editor-hard-wrapping.html">Creating the editor &gt; Hard wrapping</a><br/>
<a href="creating-the-editor-syntax-highlighting-for-html-elements.html">Creating the editor &gt; Syntax highlighting for HTML elements</a><br/>
<a href="interacting-with-the-editor-adding-a-command-to-an-editor-instance.html">Interacting with the editor &gt; Adding a command to an editor instance</a><br/>
<a href="interacting-with-the-editor-adding-an-action-to-an-editor-instance.html">Interacting with the editor &gt; Adding an action to an editor instance</a><br/>
<a href="interacting-with-the-editor-revealing-a-position.html">Interacting with the editor &gt; Revealing a position</a><br/>
<a href="interacting-with-the-editor-rendering-glyphs-in-the-margin.html">Interacting with the editor &gt; Rendering glyphs in the margin</a><br/>
<a href="interacting-with-the-editor-line-and-inline-decorations.html">Interacting with the editor &gt; Line and Inline decorations</a><br/>
<a href="interacting-with-the-editor-customizing-the-line-numbers.html">Interacting with the editor &gt; Customizing the line numbers</a><br/>
<a href="interacting-with-the-editor-listening-to-mouse-events.html">Interacting with the editor &gt; Listening to mouse events</a><br/>
<a href="interacting-with-the-editor-listening-to-key-events.html">Interacting with the editor &gt; Listening to key events</a><br/>
<a href="customizing-the-appearence-exposed-css-classes.html">Customizing the appearence &gt; Exposed CSS classes</a><br/>
<a href="customizing-the-appearence-scrollbars.html">Customizing the appearence &gt; Scrollbars</a><br/>
<a href="customizing-the-appearence-tokens-and-colors.html">Customizing the appearence &gt; Tokens and colors</a><br/>
<a href="creating-the-diffeditor-hello-diff-world.html">Creating the DiffEditor &gt; Hello diff world!</a><br/>
<a href="creating-the-diffeditor-multi-line-example.html">Creating the DiffEditor &gt; Multi-line example</a><br/>
<a href="creating-the-diffeditor-inline-diff-example.html">Creating the DiffEditor &gt; Inline Diff Example</a><br/>
<a href="creating-the-diffeditor-navigating-a-diff.html">Creating the DiffEditor &gt; Navigating a Diff</a><br/>
<a href="extending-language-services-custom-languages.html">Extending Language Services &gt; Custom languages</a><br/>
<a href="extending-language-services-completion-provider-example.html">Extending Language Services &gt; Completion provider example</a><br/>
<a href="extending-language-services-hover-provider-example.html">Extending Language Services &gt; Hover provider example</a><br/>
<a href="extending-language-services-configure-javascript-defaults.html">Extending Language Services &gt; Configure JavaScript defaults</a><br/>
<a href="extending-language-services-configure-json-defaults.html">Extending Language Services &gt; Configure JSON defaults</a>
<a class="loading-opts" href="playground.generated/creating-the-editor-hello-world.html">Creating the editor &gt; Hello world!</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-editor-editor-basic-options.html">Creating the editor &gt; Editor basic options</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-editor-hard-wrapping.html">Creating the editor &gt; Hard wrapping</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-editor-syntax-highlighting-for-html-elements.html">Creating the editor &gt; Syntax highlighting for HTML elements</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-adding-a-command-to-an-editor-instance.html">Interacting with the editor &gt; Adding a command to an editor instance</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-adding-an-action-to-an-editor-instance.html">Interacting with the editor &gt; Adding an action to an editor instance</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-revealing-a-position.html">Interacting with the editor &gt; Revealing a position</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-rendering-glyphs-in-the-margin.html">Interacting with the editor &gt; Rendering glyphs in the margin</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-line-and-inline-decorations.html">Interacting with the editor &gt; Line and Inline decorations</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-customizing-the-line-numbers.html">Interacting with the editor &gt; Customizing the line numbers</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-listening-to-mouse-events.html">Interacting with the editor &gt; Listening to mouse events</a><br/>
<a class="loading-opts" href="playground.generated/interacting-with-the-editor-listening-to-key-events.html">Interacting with the editor &gt; Listening to key events</a><br/>
<a class="loading-opts" href="playground.generated/customizing-the-appearence-exposed-css-classes.html">Customizing the appearence &gt; Exposed CSS classes</a><br/>
<a class="loading-opts" href="playground.generated/customizing-the-appearence-scrollbars.html">Customizing the appearence &gt; Scrollbars</a><br/>
<a class="loading-opts" href="playground.generated/customizing-the-appearence-tokens-and-colors.html">Customizing the appearence &gt; Tokens and colors</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-diffeditor-hello-diff-world.html">Creating the DiffEditor &gt; Hello diff world!</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-diffeditor-multi-line-example.html">Creating the DiffEditor &gt; Multi-line example</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-diffeditor-inline-diff-example.html">Creating the DiffEditor &gt; Inline Diff Example</a><br/>
<a class="loading-opts" href="playground.generated/creating-the-diffeditor-navigating-a-diff.html">Creating the DiffEditor &gt; Navigating a Diff</a><br/>
<a class="loading-opts" href="playground.generated/extending-language-services-custom-languages.html">Extending Language Services &gt; Custom languages</a><br/>
<a class="loading-opts" href="playground.generated/extending-language-services-completion-provider-example.html">Extending Language Services &gt; Completion provider example</a><br/>
<a class="loading-opts" href="playground.generated/extending-language-services-hover-provider-example.html">Extending Language Services &gt; Hover provider example</a><br/>
<a class="loading-opts" href="playground.generated/extending-language-services-configure-javascript-defaults.html">Extending Language Services &gt; Configure JavaScript defaults</a><br/>
<a class="loading-opts" href="playground.generated/extending-language-services-configure-json-defaults.html">Extending Language Services &gt; Configure JSON defaults</a>
<script src="../metadata.js"></script>
<script src="dev-setup.js"></script>
</body>
</html>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -15,7 +15,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -26,7 +26,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -15,7 +15,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -20,7 +20,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -20,7 +20,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

@ -14,7 +14,7 @@
/*----------------------------------------SAMPLE CSS END*/
</style>
<a href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
<a class="loading-opts" href="playground.generated/index.html">[&lt;&lt; BACK]</a> <br/>
THIS IS A GENERATED FILE VIA gulp generate-test-samples
<div id="bar" style="margin-bottom: 6px;"></div>

Loading…
Cancel
Save