— bridge map (Record<Key, BridgeInterface>)
— configuration (bridges, initialKey, activated, owned)
const bridge1 = createPassBridge<number>({ source, target, activated: false });
const bridge2 = createPassBridge<number>({ source, target, activated: false });
const selector = createBridgeSelector({
bridges: { first: bridge1, second: bridge2 },
initialKey: 'first',
activated: true,
owned: false
});
selector.select('second'); // switches to the second bridge
Creates a BridgeSelector — a selector for a single bridge from a map.