mirror of
https://github.com/sehugg/8bitworkshop.git
synced 2024-12-26 22:31:14 +00:00
embed=1, fixed top bar styles
This commit is contained in:
parent
02d189b1d9
commit
6134f90b13
@ -438,7 +438,8 @@ div.markdown th {
|
||||
background-color:#333;
|
||||
}
|
||||
.logo-gradient {
|
||||
font-size: 1.5em;
|
||||
font-size: 1.25em;
|
||||
margin-top: 0.15em;
|
||||
background: linear-gradient(to right, #ff9999, #ffff99, #99ff99, #99ffff);
|
||||
background-clip: text;
|
||||
-webkit-background-clip: text;
|
||||
|
@ -262,9 +262,9 @@ if (window.location.host.endsWith('8bitworkshop.com')) {
|
||||
|
||||
<!-- BOOKS menu -->
|
||||
<span class="dropdown pull-right">
|
||||
<a class="btn dropdown-toggle hidden-xs toolbarMenuButton" id="booksMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<a class="btn dropdown-toggle hidden-xs hiddem-sm toolbarMenuButton" id="booksMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
||||
<span class="glyphicon glyphicon-book" aria-hidden="true"></span>
|
||||
Get Books <span class="caret"></span>
|
||||
Books <span class="caret"></span>
|
||||
</a>
|
||||
<ul class="dropdown-menu dropdown-menu-right" aria-labelledby="booksMenuButton">
|
||||
<li>
|
||||
@ -294,7 +294,7 @@ if (window.location.host.endsWith('8bitworkshop.com')) {
|
||||
</ul>
|
||||
</span>
|
||||
<!-- 8bitworkshop logo -->
|
||||
<span class="logo-gradient hidden-xs hidden-sm hidden-md pull-right" style="margin-left:auto" onclick="window.open('/','_8bitws');">8bitworkshop</span>
|
||||
<span class="logo-gradient hidden-xs hidden-sm pull-right" style="margin-left:auto" onclick="window.open('/','_8bitws');">8bitworkshop</span>
|
||||
|
||||
</div><!-- controls_dynamic -->
|
||||
</div><!-- controls_top -->
|
||||
|
@ -2041,13 +2041,24 @@ async function startPlatform() {
|
||||
await initProject();
|
||||
await loadProject(qs['file']);
|
||||
setupDebugControls();
|
||||
updateSelector();
|
||||
addPageFocusHandlers();
|
||||
showInstructions();
|
||||
updateBooksMenu();
|
||||
if (qs['embed']) {
|
||||
hideControlsForEmbed();
|
||||
} else {
|
||||
updateSelector();
|
||||
updateBooksMenu();
|
||||
showWelcomeMessage();
|
||||
}
|
||||
revealTopBar();
|
||||
}
|
||||
|
||||
function hideControlsForEmbed() {
|
||||
$('#dropdownMenuButton').hide();
|
||||
$('#platformsMenuButton').hide();
|
||||
$('#booksMenuButton').hide();
|
||||
}
|
||||
|
||||
function updateBooksMenu() {
|
||||
if (getRootBasePlatform(platform_id) == 'nes') $(".book-nes").addClass("book-active");
|
||||
else if (getRootBasePlatform(platform_id) == 'vcs') $(".book-vcs").addClass("book-active");
|
||||
@ -2062,7 +2073,7 @@ function revealTopBar() {
|
||||
export function setupSplits() {
|
||||
const splitName = 'workspace-split3-' + platform_id;
|
||||
var sizes = [0, 50, 50];
|
||||
if (!platform_id.startsWith('vcs'))
|
||||
if (!platform_id.startsWith('vcs') && !qs['embed'])
|
||||
sizes = [12, 44, 44];
|
||||
var sizesStr = hasLocalStorage && localStorage.getItem(splitName);
|
||||
if (sizesStr) {
|
||||
@ -2210,7 +2221,6 @@ async function loadAndStartPlatform() {
|
||||
console.log("starting platform", platform_id); // loaded required <platform_id>.js file
|
||||
try {
|
||||
await startPlatform();
|
||||
showWelcomeMessage();
|
||||
document.title = document.title + " [" + platform_id + "] - " + (repo_id?('['+repo_id+'] - '):'') + current_project.mainPath;
|
||||
} finally {
|
||||
revealTopBar();
|
||||
|
@ -86,6 +86,7 @@ export class WaveformView {
|
||||
wlc.tabIndex = -1; // make it focusable
|
||||
//wlc.style = "overflow-x: hidden"; // TODO?
|
||||
this.toolbar = new Toolbar(this.parent, this.parent);
|
||||
this.toolbar.span.css('display','inline-block');
|
||||
$(this.parent).append(wlc);
|
||||
var down = false;
|
||||
var selfn = (e) => {
|
||||
|
Loading…
Reference in New Issue
Block a user