dl.f3liz.casa/drop を読んでいます
find-tabs
見失ったタブを探す二行を、タブの右クリックに。いま見ているタブへ(並びは変えず、視界だけが動く)と、音の鳴っているタブへ(押すたびに次へ回る)
uuid 543365a4-a09d-48fd-9411-4696220ab53b
install
Press inside noraneko. It catches the link, opens its settings with this uuid, downloads the xpi, checks the sha256 and the registry's signature, and shows you everything below again before anything runs.
about:nora:settings in noraneko instead.
who
gh/nyanruswhat is served
find-tabs · find-tabs@noraneko.app · version 1.3.0 · 23035 bytes sha256 fc3eb50d53f0fbcc0cc50a2f551cd875c9c79a0e2ebf996e71d7c47b168df3dc built from drops/find-tabs/src @ 59b96c854c (2026-09-14T07:24:00Z) served at https://dl.f3liz.casa/drop/543365a4-a09d-48fd-9411-4696220ab53b/in the registry
drops/find-tabs/ @ 59b96c854c — この版が出てきた木 actors: find-tabsthe source, as it is
These come from source.json next to the manifest — the same text the xpi carries under source/, and dl checks its sha256 against the signed manifest before handing it over. Not a copy of the repository: what you read and what runs came out of the same build. 4 files; press one to open it.
_shared/defineActor.ts · 118 lines
// SPDX-License-Identifier: MPL-2.0
// Authoring surface for an "actor": a small xpi whose page side is a
// JSWindowActor (the same shape as Firefox's own about:newtab add-on). Each
// actor lives in one file that exports three things by name:
//
// export const meta = { id, namespace, matches, ... };
// export const parent = defineParent({ method(...) { ... } }); // main process (JSWindowActorParent)
// export const content = defineContent((parent, ctx) => { ... }); // page side (run by JSWindowActorChild)
//
// The page side is NOT a WebExtension content script: content scripts are not
// injected into about:* / chrome:* documents in stock Firefox (see README,
// "addon 式が駄目だった理由"). The child actor loads content.js into the page's
// process with `window` / `document` on the scope chain, so the hook is written
// the same way, but it runs with the child actor's privileges.
//
// Named exports (rather than one nested object) are deliberate: the build
// bundles `parent` and `content` into separate outputs, and named exports let
// the bundler tree-shake each side so the content bundle never drags in the
// parent's privileged code and vice versa.
//
// IMPORTANT: the module top level must be pure. Reference Firefox globals
// (Services, ChromeUtils, window, exportFunction, browser) only *inside* method
// or hook bodies — the build imports this file under Deno to read `meta`, and
// top-level use of those globals would throw there.
export interface ActorMeta {
/** Extension id, e.g. "settings-bridge@noraneko.app". */
id: string;
/** Extension version. */
version: string;
/** Experiment-API namespace, e.g. "noraSettings". Also the message channel. */
namespace: string;
/** Match patterns for the pages the content hook runs in (JSWindowActor `matches`). */
matches: string[];
/**
* When the content hook runs. Maps to a child actor event:
* document_start → DOMDocElementInserted, document_end → DOMContentLoaded,
* document_idle → load. Defaults to "document_end".
*/
runAt?: "document_start" | "document_end" | "document_idle";
/**
* JSWindowActor name. Defaults to "Nora" + PascalCase(<dir>), e.g. NoraNewtab.
* A drop with the same actor name replaces the built-in one (unregister → register).
*/
actor?: string;
/** Legacy JSActor (BrowserGlue) this one replaces; it is unregistered when this actor is registered. */
replaces?: string;
}
import type { Io } from "./io.ts";
type ParentMethods = Record<string, (...args: any[]) => unknown>;
export interface ContentCtx {
/** True in dev builds (import.meta.env.MODE === "dev"). */
dev: boolean;
/** Expose functions on the page window (via exportFunction). */
expose(funcs: Record<string, (...args: any[]) => unknown>): void;
/**
* Run when this actor goes away in this window (the drop is removed or
* replaced). Put back what the hook changed: DOM, observers, listeners.
*/
onDestroy(fn: () => void): void;
/**
* Place things through these (DOM, styles, listeners, pref observers) and
* they are taken out again by themselves: each verb puts its way back on
* the same ledger as onDestroy.
*/
io: Io;
/** This actor's own files: `${ctx.base}ops/x.tsubaki` and the like. */
base: string;
/**
* The actor's logic in Tsubaki (when it ships wasm/): run a .tsubaki file of
* its own with load("ops/x.tsubaki"), then call(name, ...args). Values cross
* as ordinary JS values; a Tsubaki error is a JS Error. undefined without wasm/.
*
* Every verb answers with a Promise, because for an actor of the browser
* WINDOW the logic lives a process away (wasm can't compile in the parent
* process, so it runs in a hidden page of this window instead). A drop never
* has to know which side it got.
*/
ops: Ops | undefined;
}
export interface Ops {
ready: Promise<void>;
call(name: string, ...args: unknown[]): Promise<unknown>;
}
/** Proxy to the parent methods; each call is forwarded to the main process. */
type ParentProxy<T extends ParentMethods> = {
[K in keyof T]: (...args: Parameters<T[K]>) => Promise<Awaited<ReturnType<T[K]>>>;
};
export type ContentHook<T extends ParentMethods = ParentMethods> = (
parent: ParentProxy<T>,
ctx: ContentCtx,
) => void;
// Identity helpers that pin types for authoring:
//
// export const parent = defineParent({ method(...) { ... } });
// export const content = defineContent<typeof parent>((parent, ctx) => { ... });
//
// They are listed in the build's treeshake.manualPureFunctions, so an unused
// call (e.g. defineContent in the parent bundle) is dropped along with anything
// it references (birpc). Without that, the bundler would keep the call for its
// possible side effects and the unused side would not tree-shake.
/** Pins the parent-method types so the content hook's proxy is typed. */
export const defineParent = <T extends ParentMethods>(methods: T): T => methods;
/** Pins the content hook against the parent's method types. */
export const defineContent = <T extends ParentMethods>(
hook: ContentHook<T>,
): ContentHook<T> => hook;
find-tabs/actor.ts · 29 lines
// SPDX-License-Identifier: MPL-2.0
// GENERATED by build.ts. この drop の actor は Tsubaki で書かれている:
// 直すのは ops/find-tabs.tsubaki と drop.toml の [actor]。
//
// 殻は lib の std-actor。logic が答える三つの door(setup / start / dispatch)
// を呼んで、返ってきた view を描き、effects を carry out する。殻の bytes は
// その lib に一枚だけあって、ここには入らない(この drop に残るのは、下の宣言だけ)。
import { defineContent, defineParent, type ActorMeta } from "../_shared/defineActor.ts";
import { runTsubakiActor } from "std-actor";
export const meta: ActorMeta = {
"id": "find-tabs@noraneko.app",
"version": "1.3.0",
"namespace": "noraFindTabs",
"matches": [
"chrome://browser/content/browser.xhtml"
],
"runAt": "document_end"
};
export const parent = defineParent({});
export const content = defineContent<typeof parent>((_parent, ctx) => {
runTsubakiActor(ctx, {"prefs":[],"keys":[],"commands":["scroll-to-selected-tab","show-playing-tab"],"browserPages":[],"menus":["tabContextMenu"],"tabs":"","tabMarks":false,"tabValues":false,"windowValues":false,"prompt":false,"currentUrl":false,"openUrl":false,"webFrame":false,"chromeStyle":false,"ownPrefix":"noraneko.find-tabs.","name":"find-tabs","uuid":"543365a4-a09d-48fd-9411-4696220ab53b","strings":{"en":{"current":"Scroll to current tab","playing":"Go to the tab that's playing"},"ja":{"current":"いま見ているタブへ","playing":"音の鳴っているタブへ"}}}).catch((e) =>
console.error("[find-tabs] failed:", e)
);
});
find-tabs/ops/find-tabs.tsubaki · 53 lines
# SPDX-License-Identifier: MPL-2.0
#
# find-tabs: 見失ったタブを、探しに行く二行。
#
# いま見ているタブへ 選ばれているタブが帯の先頭に来るまで、**視界のほうを**
# 動かす。タブは一枚も動かない。横なら左端、縦なら上端で、
# はみ出していなければ何も起きない
# 音の鳴っているタブへ 鳴っているタブを**選ぶ**。押すたびに次へ回るので、
# いくつ鳴っていても順に辿れる。黙らせたタブは飛ばす
#
# この drop の全部が、ここに書いてある。state も、pref も、style の一枚も無い
# (undo-closed-tab と同じ形)。押されたら命令を一つ。
#
# **右クリックされたタブは見ていない。** 殻は tabContextMenu の行から起きた
# action に、押されたタブを __event で入れてくる。この drop はそれを読まない --
# 用途が「見失ったから探しに行く」なので、行き先はいつも向こうにある。
setup() = Setup(
anchors = [Anchor(at = "menu", menu = "tabContextMenu", id = "nora-find-tabs")]
)
"いま見ているタブへ(視界が動く)"
struct Show end
"音の鳴っているタブへ(押すたびに次へ)"
struct Playing end
view() = el("fragment", Dict(), [
el("menuitem", Dict(
"id" => "nora-find-tabs-current",
"label" => t(:current),
"on:command" => Show()
)),
el("menuitem", Dict(
"id" => "nora-find-tabs-playing",
"label" => t(:playing),
"on:command" => Playing()
))
])
start(facts) = frame(view())
function dispatch(a)
kind = get(a, :__type, "")
if kind == "Show"
return frame(view(), [DoCommand("scroll-to-selected-tab")])
end
if kind == "Playing"
return frame(view(), [DoCommand("show-playing-tab")])
end
error("find-tabs: no action named " * kind)
end
find-tabs/strings.toml · 8 lines
[en]
current = "Scroll to current tab"
playing = "Go to the tab that's playing"
[ja]
current = "いま見ているタブへ"
playing = "音の鳴っているタブへ"
What a drop is, how it reaches you, and what it is not: f3liz.casa/noraneko/drops/. Served by https://dl.f3liz.casa/drop, signed by https://github.com/f3liz-casa/noraneko-registry/.github/workflows/verify-and-sign.yml@refs/heads/main.
This page is built when you ask for it, out of what https://dl.f3liz.casa/drop is serving right now (2026-09-23T08:38:28.032Z). Drafted by Shiro, an AI assistant, sitting next to nyanrus.