Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/sandcastle-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: sandcastle-dev
on:
push:
branches:
- 'sandcastle-v2'
- 'cesium.com'
jobs:
deploy:
runs-on: ubuntu-latest
Expand All @@ -16,7 +16,7 @@ jobs:
GITHUB_REPO: ${{ github.repository }}
GITHUB_SHA: ${{ github.sha }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
- name: install node 22
uses: actions/setup-node@v4
with:
Expand Down
28 changes: 9 additions & 19 deletions Apps/Sandcastle/CesiumSandcastle.css
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,15 @@ body {
float: right;
}

#banner {
text-align: center;
background: #daf6ff;

a {
color: blue;
}
}

#codeContainer {
width: 40%;
}
Expand Down Expand Up @@ -186,25 +195,6 @@ a.linkButton:hover {
overflow: auto !important;
}

.feedback {
width: 250px;

.future-banner {
display: flex;
justify-content: center;
align-items: stretch;
text-align: center;
flex-direction: column;

h3 {
margin: 0 1em;
}
p {
margin: 1em 1.5em;
}
}
}

.claro .dijitTabContainerTop-tabs .dijitTabChecked .dijitTabContent {
background-position: 0 -103px;
}
Expand Down
37 changes: 9 additions & 28 deletions Apps/Sandcastle/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,15 @@
data-dojo-type="dijit.layout.BorderContainer"
data-dojo-props="design: 'headline', gutters: true, liveSplitters: true"
>
<div
id="banner"
data-dojo-type="dijit.layout.ContentPane"
data-dojo-props="region: 'top'"
>
<a href="https://dev-sandcastle.cesium.com"
>Try the new version of Sandcastle today!</a
>
</div>
<div
id="toolbar"
data-dojo-type="dijit.Toolbar"
Expand Down Expand Up @@ -341,36 +350,8 @@
</div>
</div>
</div>
<div
class="feedback"
data-dojo-type="dijit.layout.TabContainer"
data-dojo-props="region: 'right'"
>
<div
class="future-banner"
data-dojo-type="dijit.layout.ContentPane"
data-dojo-props="title: 'Feedback'"
>
<h3>Help needed</h3>
<p>
We're currently gathering user feedback to make Sandcastle even
better.
</p>
<button data-dojo-type="dijit/form/Button" type="button">
Please share your thoughts!
<script
type="dojo/on"
data-dojo-event="click"
data-dojo-args="evt"
>
window.open("https://community.cesium.com/t/upgrading-sandcastle-we-need-your-input/39715/", "_blank")
</script>
</button>
</div>
</div>
</div>
</div>

<div class="dijitTooltip dijitTooltipBelow" id="docPopup">
<div
class="dijitTooltipContainer dijitTooltipContents"
Expand Down
15 changes: 13 additions & 2 deletions packages/sandcastle/src/App.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,20 @@
height: 100vh;
--header-height: min-content;
--app-bar-width: 53px;
grid-template-rows: var(--header-height) auto;
grid-template-rows: min-content var(--header-height) auto;
grid-template-columns: var(--app-bar-width) auto;
grid-template-areas: "header header" "app-bar content";
grid-template-areas: "banner banner" "header header" "app-bar content";

.banner {
grid-area: banner;
background: var(--stratakit-color-bg-elevation-overlay);
padding: var(--stratakit-space-x2);
text-align: center;

a {
color: var(--stratakit-color-text-accent-base);
}
}

header {
grid-area: header;
Expand Down
29 changes: 27 additions & 2 deletions packages/sandcastle/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import { Allotment, AllotmentHandle } from "allotment";
import "allotment/dist/style.css";
import "./App.css";

import { Button, Divider, Tooltip } from "@stratakit/bricks";
import { Anchor, Button, Divider, Text, Tooltip } from "@stratakit/bricks";
import { Icon, Root } from "@stratakit/foundations";
import { decodeBase64Data, makeCompressedBase64String } from "./Helpers.ts";
import Gallery, { GalleryItem } from "./Gallery.js";
Expand All @@ -41,6 +41,7 @@ import { SettingsModal } from "./SettingsModal.tsx";
import { LeftPanel, SettingsContext } from "./SettingsContext.ts";
import { MetadataPopover } from "./MetadataPopover.tsx";
import { SharePopover } from "./SharePopover.tsx";
import { SandcastlePopover } from "./SandcastlePopover.tsx";

const defaultJsCode = `import * as Cesium from "cesium";

Expand Down Expand Up @@ -539,6 +540,11 @@ function App() {
colorScheme={settings.theme}
synchronizeColorScheme
>
<div className="banner">
<Anchor href="https://sandcastle.cesium.com" tone="accent">
Looking for the old Sandcastle? It's still here (for a little while) →
</Anchor>
</div>
<header className="header">
<a className="logo" href={getBaseUrl()}>
<img
Expand All @@ -557,6 +563,25 @@ function App() {
Standalone <Icon href={windowPopout} />
</Button>
<div className="flex-spacer"></div>
<SandcastlePopover
disclosure={
<Text variant="body-md" className="metadata">
Feedback & Issues
</Text>
}
autoFocus={false}
>
<p>
Help us continue to improve Sandcastle. Report a problem or share
your thoughts in{" "}
<Anchor
href="https://github.com/CesiumGS/cesium/issues/12857"
target="_blank"
>
this issue
</Anchor>
</p>
</SandcastlePopover>
<div className="version">
{versionString && <pre>{versionString}</pre>}
</div>
Expand Down Expand Up @@ -615,7 +640,7 @@ function App() {
</AppBarButton>
<SettingsModal open={settingsOpen} setOpen={setSettingsOpen} />
</div>
<Allotment defaultSizes={[40, 60]}>
<Allotment defaultSizes={[40, 60]} className="content">
<Allotment.Pane minSize={400} className="left-panel">
{leftPanel === "editor" && (
<SandcastleEditor
Expand Down