melhorando a leitura de projetos no mmpCreator
Deploy / Deploy (push) Successful in 2m4s Details

This commit is contained in:
JotaChina 2025-12-23 21:23:06 -03:00
parent a0e0342fe6
commit a1422a2ad5
3 changed files with 12 additions and 4 deletions

View File

@ -352,9 +352,9 @@ body.sidebar-hidden .sample-browser { width: 0; min-width: 0; border-right: none
.track-name { color: var(--accent-red); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .track-name { color: var(--accent-red); font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.audio-track-lane .track-controls { display: flex; justify-content: flex-start; gap: 15px; border-left: none; padding-left: 0; margin: 0; } .audio-track-lane .track-controls { display: flex; justify-content: flex-start; gap: 15px; border-left: none; padding-left: 0; margin: 0; }
.timeline-container { flex-grow: 1; position: relative; overflow-x: hidden; overflow-y: hidden; } .timeline-container { flex-grow: 1; position: relative; overflow-x: hidden; overflow-y: hidden; height: 100%;}
.spectrogram-view-grid { .spectrogram-view-grid {
height: 100%; position: relative; display: block; height: 100%; min-height: 100%; position: relative; display: block;
--step-width: 32px; --beat-width: 128px; --bar-width: 512px; --step-width: 32px; --beat-width: 128px; --bar-width: 512px;
background-size: var(--bar-width) 100%, var(--beat-width) 100%, var(--step-width) 100%; background-size: var(--bar-width) 100%, var(--beat-width) 100%, var(--step-width) 100%;
background-image: background-image:

View File

@ -19,7 +19,7 @@ import {
getBeatsPerBar, getBeatsPerBar,
getSecondsPerStep, getSecondsPerStep,
} from "../utils.js"; } from "../utils.js";
import { sendAction } from "../socket.js"; import { sendAction, sendActionSafe } from "../socket.js";
export function renderAudioEditor() { export function renderAudioEditor() {
const audioEditor = document.querySelector(".audio-editor"); const audioEditor = document.querySelector(".audio-editor");
@ -262,7 +262,7 @@ export function renderAudioEditor() {
const newTrackContainer = existingTrackContainer.cloneNode(false); const newTrackContainer = existingTrackContainer.cloneNode(false);
tracksParent.replaceChild(newTrackContainer, existingTrackContainer); tracksParent.replaceChild(newTrackContainer, existingTrackContainer);
// ✅ único scroller horizontal/vertical do editor // ✅ único scroller horizontal/vertical do editor
const scrollEl = newTrackContainer; const scrollEl = existingTrackContainer; // #audio-track-container
// === RENDERIZAÇÃO DAS PISTAS (LANES) === // === RENDERIZAÇÃO DAS PISTAS (LANES) ===

View File

@ -128,6 +128,14 @@ export function setUserName(name) {
USER_NAME = name; USER_NAME = name;
} }
export function sendActionSafe(action) {
try {
sendAction(action);
} catch (err) {
console.warn("[SYNC] Falha ao emitir ação:", action?.type, err);
}
}
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------
// CONEXÃO / JOIN / LOGS // CONEXÃO / JOIN / LOGS
// ----------------------------------------------------------------------------- // -----------------------------------------------------------------------------