mirror of
https://github.com/snapotter-hq/SnapOtter.git
synced 2026-08-03 07:46:42 +02:00
fix: editor native layout, UI polish, meme templates auth, pipeline export, install queuing
- Remove editor from AppLayout so it owns the full viewport with no sidebar/padding - Add back-arrow in menu bar for navigation, restyle menu bar to match native app feel - Slim left toolbar from 48px to 36px with smaller icons and subtler dividers - Fix options bar overlapping canvas via shrink-0 and overflow-hidden - Fix opacity/blend controls clipping in right panel with min-w-0 on flex children - Add global range slider CSS for consistent thin-track + round-thumb styling - Make meme template routes public so img tags can load without Bearer auth - Show pipeline export buttons in default compact view, not just expanded hover - Queue individual AI feature installs instead of erroring when one is active
This commit is contained in:
@@ -184,6 +184,36 @@ export const useFeaturesStore = create<FeaturesState>((set, get) => {
|
||||
},
|
||||
|
||||
installBundle: async (bundleId: string) => {
|
||||
const activeIds = Object.keys(get().installing);
|
||||
if (activeIds.length > 0 && !activeIds.includes(bundleId)) {
|
||||
const alreadyQueued = get().queued.includes(bundleId);
|
||||
if (!alreadyQueued) {
|
||||
set({ queued: [...get().queued, bundleId] });
|
||||
}
|
||||
const errors = { ...get().errors };
|
||||
delete errors[bundleId];
|
||||
set({ errors });
|
||||
|
||||
await new Promise<void>((resolve) => {
|
||||
const check = () => {
|
||||
const current = get().installing;
|
||||
if (Object.keys(current).length === 0 || Object.keys(current).includes(bundleId)) {
|
||||
resolve();
|
||||
} else {
|
||||
setTimeout(check, 500);
|
||||
}
|
||||
};
|
||||
check();
|
||||
});
|
||||
|
||||
set({ queued: get().queued.filter((id) => id !== bundleId) });
|
||||
const currentBundle = get().bundles.find((b) => b.id === bundleId);
|
||||
if (currentBundle?.status === "installed") {
|
||||
resolveCompletion(bundleId);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
const errors = { ...get().errors };
|
||||
delete errors[bundleId];
|
||||
set({
|
||||
|
||||
Reference in New Issue
Block a user