Remove redundant editor tool hint
This commit is contained in:
parent
f5f7349e78
commit
f2a8c75704
3 changed files with 0 additions and 16 deletions
|
|
@ -99,7 +99,6 @@ const middleVizLabel = byId<HTMLDivElement>("middleVizLabel");
|
|||
const rightVizLabel = byId<HTMLDivElement>("rightVizLabel");
|
||||
const metricsPanel = byId<HTMLDivElement>("metricsPanel");
|
||||
const paintSwatch = byId<HTMLDivElement>("paintSwatch");
|
||||
const toolMode = byId<HTMLSpanElement>("toolMode");
|
||||
const zoomInput = byId<HTMLInputElement>("zoomInput");
|
||||
const zoomValue = byId<HTMLSpanElement>("zoomValue");
|
||||
const gridToggle = byId<HTMLInputElement>("gridToggle");
|
||||
|
|
@ -195,10 +194,6 @@ function setPaintColor(color: [number, number, number, number]): void {
|
|||
paintSwatch.style.background = `rgba(${color[0]}, ${color[1]}, ${color[2]}, ${color[3] / 255})`;
|
||||
}
|
||||
|
||||
function updateToolMode(): void {
|
||||
toolMode.textContent = state.altHeld ? "Eyedropper armed. Sample a pixel." : "Pencil. Hold Alt for eyedropper.";
|
||||
}
|
||||
|
||||
function addLog(label: string, detail: string): void {
|
||||
state.eventLog.unshift({ label, detail });
|
||||
state.eventLog = state.eventLog.slice(0, 8);
|
||||
|
|
@ -898,14 +893,12 @@ for (const input of Object.values(paintInputs)) {
|
|||
window.addEventListener("keydown", (event) => {
|
||||
if (event.key === "Alt") {
|
||||
state.altHeld = true;
|
||||
updateToolMode();
|
||||
}
|
||||
});
|
||||
|
||||
window.addEventListener("keyup", (event) => {
|
||||
if (event.key === "Alt") {
|
||||
state.altHeld = false;
|
||||
updateToolMode();
|
||||
}
|
||||
});
|
||||
|
||||
|
|
@ -918,7 +911,6 @@ editorCanvas.addEventListener("pointerdown", (event) => {
|
|||
editorCanvas.setPointerCapture(event.pointerId);
|
||||
if (event.altKey || state.altHeld) {
|
||||
samplePaintColor(pixel.x, pixel.y);
|
||||
updateToolMode();
|
||||
return;
|
||||
}
|
||||
painting = true;
|
||||
|
|
@ -931,7 +923,6 @@ editorCanvas.addEventListener("pointermove", (event) => {
|
|||
return;
|
||||
}
|
||||
if (event.altKey || state.altHeld) {
|
||||
updateToolMode();
|
||||
if (event.buttons === 1) {
|
||||
samplePaintColor(pixel.x, pixel.y);
|
||||
}
|
||||
|
|
@ -959,7 +950,6 @@ downloadButton.addEventListener("click", () => {
|
|||
});
|
||||
|
||||
setPaintColor(state.paintColor);
|
||||
updateToolMode();
|
||||
zoomValue.textContent = `${state.zoom}x`;
|
||||
renderEventLog();
|
||||
void renderEverything();
|
||||
|
|
|
|||
|
|
@ -174,7 +174,6 @@
|
|||
<p class="copy-tag">Pencil the stragglers. Hold Alt to steal color straight from the panel.</p>
|
||||
</div>
|
||||
<div class="editor-actions">
|
||||
<span id="toolMode" class="tool-hint">Pencil. Hold Alt for eyedropper.</span>
|
||||
<button id="resetEditorButton" class="button button-small button-secondary" type="button">Reset Output</button>
|
||||
<button id="downloadButton" class="button button-small" type="button">Export PNG</button>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -648,11 +648,6 @@ p {
|
|||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.tool-hint {
|
||||
color: var(--ui-text-muted);
|
||||
font-size: 1rem;
|
||||
}
|
||||
|
||||
.editor-toolbar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
|
|||
Loading…
Reference in a new issue