mirror of
https://github.com/nexu-io/openmotion.git
synced 2026-12-02 01:19:23 +08:00
* feat(studio): unify shell and editor opening loading into one seamless cover Host a single persistent opening cover inside MotionApp across shell route resolution, ArtifactViewer Suspense loading, and EditorAssetLoadingOverlay readiness so entering, refreshing, or switching projects never flickers between two loading screens or resets the brand mark animation. Unify pre-JS HTML splash and MotionLoading copy to 'Preparing project assets', move cover styles into frame-1 studio-shell.css with matching breathing motion, carry the 4s escape hatch timer across phases, and add unit regressions for single-node continuity, error suppression, and direct project switches. * Clean up unreachable EditorLoading fallback and duplicate cover animation --------- Co-authored-by: 罗高 <luogao@users.noreply.github.com>
107 lines
2.9 KiB
CSS
107 lines
2.9 KiB
CSS
/* Shared Studio shell & discovery presentation (loaded on first paint). */
|
|
@import "./tokens.css";
|
|
@import "./fonts.css";
|
|
@import "./controls.css";
|
|
@import "./material.css";
|
|
@import "./studio/control-recipes.css";
|
|
@import "./studio/adapter.css";
|
|
@import "./studio/control-states.css";
|
|
@import "./studio/feedback.css";
|
|
@import "./studio/application.css";
|
|
@import "./studio/primary-navigation.css";
|
|
@import "./studio/mcp.css";
|
|
@import "./studio/template-cards.css";
|
|
@import "./studio/discovery.css";
|
|
@import "./studio/media-detail.css";
|
|
@import "./studio/formFields.css";
|
|
@import "./studio/menuPanels.css";
|
|
@import "./studio/disclosure.css";
|
|
|
|
/* Asset geometry is shared; currentColor follows the application's selected theme. */
|
|
.motion-brand-lockup {
|
|
display: inline-block;
|
|
flex: none;
|
|
height: var(--motion-space-24);
|
|
aspect-ratio: 141.625 / 24;
|
|
vertical-align: middle;
|
|
background: currentColor;
|
|
mask: url("./brand/openmotion-logo.svg") center / contain no-repeat;
|
|
}
|
|
|
|
.motion-brand-lockup:where([data-brand="editor"]) {
|
|
color: var(--motion-strong);
|
|
aspect-ratio: 1705 / 291;
|
|
mask-image: url("./opendesign-dark.svg");
|
|
}
|
|
|
|
@container (max-width: 700px) {
|
|
.motion-brand-lockup--responsive {
|
|
aspect-ratio: 1;
|
|
mask-image: url("./brand/loading-mark.svg");
|
|
}
|
|
}
|
|
|
|
/* Unified solid full-cover editor opening gate (bundled in shell CSS so frame 1 is always styled). */
|
|
.motion-editor-cover {
|
|
position: absolute;
|
|
inset: 0;
|
|
z-index: 120;
|
|
display: grid;
|
|
place-items: center;
|
|
align-content: center;
|
|
width: 100%;
|
|
height: 100%;
|
|
box-sizing: border-box;
|
|
padding: var(--motion-space-24);
|
|
background: var(--motion-bg);
|
|
color: var(--motion-text);
|
|
user-select: none;
|
|
opacity: 1;
|
|
transition: opacity var(--motion-duration-normal) var(--motion-ease-out);
|
|
}
|
|
.motion-editor-cover[data-visible="false"] {
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
}
|
|
.motion-editor-cover-inner {
|
|
position: relative;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
gap: var(--motion-space-16);
|
|
text-align: center;
|
|
}
|
|
.motion-editor-cover-mark {
|
|
display: block;
|
|
width: var(--motion-space-40);
|
|
height: var(--motion-space-40);
|
|
background: var(--motion-accent);
|
|
-webkit-mask: url("./brand/loading-mark.svg") center / contain no-repeat;
|
|
mask: url("./brand/loading-mark.svg") center / contain no-repeat;
|
|
}
|
|
.motion-editor-cover-label {
|
|
margin: 0;
|
|
color: var(--motion-muted);
|
|
font: var(--motion-text-sm)/var(--motion-leading-body) var(--motion-font-sans);
|
|
}
|
|
.motion-editor-cover-escape {
|
|
position: absolute;
|
|
top: calc(100% + var(--motion-space-16));
|
|
left: 50%;
|
|
transform: translateX(-50%);
|
|
white-space: nowrap;
|
|
animation: motion-opening-fade-in var(--motion-duration-normal) var(--motion-ease-out) both;
|
|
}
|
|
@keyframes motion-opening-fade-in {
|
|
from { opacity: 0; }
|
|
to { opacity: 1; }
|
|
}
|
|
@media (prefers-reduced-motion: reduce) {
|
|
.motion-editor-cover {
|
|
transition: none;
|
|
}
|
|
.motion-editor-cover-escape {
|
|
animation: none;
|
|
}
|
|
}
|