feat(orchestrator): hub requirements 066 to 082 and 084
Radio footer, rules page, schedules editor (System timers and Claude tasks through signed runner jobs), account usage bar, usage explorer with a streamed usage.jsonl, queue Controls tab and override, running tasks on the board, stale task prune with the generic dial, greyed card stamps, commit-tree diffs from the runner preview, VS Code path links, expired asks and decisions that stay as EXPIRED cards (asks keyed by a call digest; an async PostToolUse hook closes those answered in the terminal), the Match refresh hourglass, attachments by paste, drop and paperclip in every text field (page CSP gains img-src blob: for the thumbnails) and the limits board with profiles and a passkey to loosen. Fixes: one red accept on a red-gate commit and no release while a risk is open, the send bar footer segments share one height, the mic button survives a redraw, new Match cards queue before the release card. E2E specs were still running at commit time (operator order); their failures follow as separate fixes. 🎯 Fix: 88 % 💥 Break: 8 % 💸 Tokens: – ⏱️ Velocity: – 🛡️ Security: 100 % 🏆 Score: 81 🚦 Gate: ⛔ fix 88 % < 90, break 8 % > 5 (committed on the operator's word) Created-with: https://s.veen.world/skills Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
dc0d578eca
commit
f356083a24
149 files changed
+10646
-963
No files matched your search
@@ -1,62 +1,50 @@
|
||||
const DIAL_MAX = 60;
|
||||
const DIAL_PAGE = 5;
|
||||
const DIAL_SIZE = 140;
|
||||
const DIAL_RADIUS = 58;
|
||||
|
||||
/**
|
||||
* @param {number} second a value on the dial, 0 to DIAL_MAX.
|
||||
* @param {number} radius how far from the centre.
|
||||
* @returns {number[]} the point [x, y] for that second, 0 and 60 at the top, clockwise.
|
||||
* @param {Object} options value: the whole value the dial starts at; label: the slider's accessible name; name: the
|
||||
* root's own class; min, max: the ends, max a full turn; page: the Page Up and Down step and the long-tick spacing;
|
||||
* unit: the readout's unit; spoken: (value) => the aria-valuetext; readonly: true for a dial only the caller moves.
|
||||
* @returns {root, value, set}: an analog clock face with Dial.TICKS ticks and one hand, an ARIA slider: dragging the
|
||||
* hand or clicking a tick sets it, the arrows step 1, Page Up and Down page, Home and End the ends; set(value) moves it.
|
||||
*/
|
||||
function dialPoint(second, radius) {
|
||||
const angle = (second / DIAL_MAX) * 2 * Math.PI;
|
||||
const centre = DIAL_SIZE / 2;
|
||||
return [centre + Math.sin(angle) * radius, centre - Math.cos(angle) * radius];
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {number} value the undo window in whole seconds the dial starts at.
|
||||
* @param {string} label the slider's accessible name.
|
||||
* @returns {root, value}: an analog clock face with 60 ticks and one hand, an ARIA slider:
|
||||
* dragging the hand or clicking a tick sets it, the arrows step 1 s, Page Up and Down 5 s, Home and End the ends.
|
||||
*/
|
||||
function undoDial(value, label) {
|
||||
let seconds = value;
|
||||
const ticks = Array.from({length: DIAL_MAX}, (_, second) => {
|
||||
const long = second % DIAL_PAGE === 0;
|
||||
const [x1, y1] = dialPoint(second, DIAL_RADIUS - (long ? 10 : 5));
|
||||
const [x2, y2] = dialPoint(second, DIAL_RADIUS);
|
||||
function dial(options) {
|
||||
let current = options.value;
|
||||
const centre = Dial.SIZE / 2;
|
||||
const ticks = Dial.ticks(options.page).map(({at, long}) => {
|
||||
const [x1, y1] = Dial.point(at, Dial.TICKS, Dial.RADIUS - (long ? 10 : 5));
|
||||
const [x2, y2] = Dial.point(at, Dial.TICKS, Dial.RADIUS);
|
||||
return s("line", {class: `dial-tick${long ? " long" : ""}`, x1: fixed(x1), y1: fixed(y1), x2: fixed(x2), y2: fixed(y2)});
|
||||
});
|
||||
const centre = DIAL_SIZE / 2;
|
||||
const hand = s("line", {class: "dial-hand", x1: centre, y1: centre});
|
||||
const face = s("svg", {class: "dial-face", viewBox: `0 0 ${DIAL_SIZE} ${DIAL_SIZE}`, "aria-hidden": "true", focusable: "false"},
|
||||
s("circle", {class: "dial-rim", cx: centre, cy: centre, r: DIAL_RADIUS + 4}), ticks, hand, s("circle", {class: "dial-pin", cx: centre, cy: centre, r: 4}));
|
||||
const face = s("svg", {class: "dial-face", viewBox: `0 0 ${Dial.SIZE} ${Dial.SIZE}`, "aria-hidden": "true", focusable: "false"},
|
||||
s("circle", {class: "dial-rim", cx: centre, cy: centre, r: Dial.RADIUS + 4}), ticks, hand, s("circle", {class: "dial-pin", cx: centre, cy: centre, r: 4}));
|
||||
const readout = h("output", {class: "dial-readout"});
|
||||
const root = h("div", {class: "undo-dial", role: "slider", tabindex: "0", "aria-label": label, "aria-valuemin": "0", "aria-valuemax": String(DIAL_MAX)}, face, readout);
|
||||
const root = h("div", {class: `dial ${options.name}`, role: "slider", tabindex: "0", "aria-label": options.label, "aria-valuemin": String(options.min), "aria-valuemax": String(options.max),
|
||||
"aria-readonly": options.readonly ? "true" : null}, face, readout);
|
||||
const set = (next) => {
|
||||
seconds = Math.max(0, Math.min(DIAL_MAX, Math.round(next)));
|
||||
const [x2, y2] = dialPoint(seconds, DIAL_RADIUS - 14);
|
||||
current = Dial.clamp(next, options);
|
||||
const [x2, y2] = Dial.point(current, options.max, Dial.RADIUS - 14);
|
||||
hand.setAttribute("x2", fixed(x2));
|
||||
hand.setAttribute("y2", fixed(y2));
|
||||
readout.textContent = `${seconds} s`;
|
||||
root.setAttribute("aria-valuenow", String(seconds));
|
||||
root.setAttribute("aria-valuetext", seconds ? `${seconds} seconds to undo` : "0 seconds: takes effect at once");
|
||||
readout.textContent = `${current} ${options.unit}`;
|
||||
root.setAttribute("aria-valuenow", String(current));
|
||||
root.setAttribute("aria-valuetext", options.spoken(current));
|
||||
};
|
||||
set(current);
|
||||
if (options.readonly) {
|
||||
return {root, value: () => current, set};
|
||||
}
|
||||
const pointed = (event) => {
|
||||
const box = face.getBoundingClientRect();
|
||||
const degrees = (Math.atan2(event.clientX - box.left - box.width / 2, box.top + box.height / 2 - event.clientY) * 180) / Math.PI;
|
||||
set(((degrees + 360) % 360) / (360 / DIAL_MAX));
|
||||
set(Dial.fromAngle((Math.atan2(event.clientX - box.left - box.width / 2, box.top + box.height / 2 - event.clientY) * 180) / Math.PI, options.max));
|
||||
};
|
||||
root.addEventListener("keydown", (event) => {
|
||||
const steps = {ArrowRight: 1, ArrowUp: 1, ArrowLeft: -1, ArrowDown: -1, PageUp: DIAL_PAGE, PageDown: -DIAL_PAGE};
|
||||
if (event.key in steps) {
|
||||
set(seconds + steps[event.key]);
|
||||
} else if (event.key === "Home" || event.key === "End") {
|
||||
set(event.key === "Home" ? 0 : DIAL_MAX);
|
||||
} else {
|
||||
const next = Dial.stepped(event.key, current, options);
|
||||
if (next === null) {
|
||||
return;
|
||||
}
|
||||
set(next);
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
});
|
||||
@@ -70,6 +58,15 @@
|
||||
pointed(event);
|
||||
}
|
||||
});
|
||||
set(seconds);
|
||||
return {root, value: () => seconds};
|
||||
return {root, value: () => current, set};
|
||||
}
|
||||
|
||||
/**
|
||||
* @param {number} value the undo window in whole seconds the dial starts at.
|
||||
* @param {string} label the slider's accessible name.
|
||||
* @returns {root, value, set}: dial() over 0 to DIAL_MAX seconds, Page Up and Down 5 s.
|
||||
*/
|
||||
function undoDial(value, label) {
|
||||
const spoken = (seconds) => (seconds ? `${seconds} seconds to undo` : "0 seconds: takes effect at once");
|
||||
return dial({value, label, name: "undo-dial", min: 0, max: DIAL_MAX, page: DIAL_PAGE, unit: "s", spoken, readonly: false});
|
||||
}
|
||||
Reference in new issue
Block a user