upstream: integrar Oasis 1.3.3
Diferencia 1.3.1 -> 1.3.3 del codigo de la APK oficial aplicada a tres bandas encima de la rama: karma en el perfil, salas con directo, fotos selladas, visibilidad de menciones, telefono por stream en Android y las traducciones nuevas. Sin dependencias nuevas. OasisMobile.css sigue siendo el del fork; del oficial solo se traen al final las reglas de las piezas nuevas (karma, directo a pantalla completa, salas en vivo, graphos).
This commit is contained in:
parent
bc64565e9c
commit
948b6460d9
95 changed files with 3613 additions and 1356 deletions
|
|
@ -162,8 +162,12 @@ async function listExchanges() {
|
|||
|
||||
const netVotes = (votes, key) => { const per = votes.get(key); if (!per) return 0; let n = 0; for (const v of per.values()) n += v; return n }
|
||||
|
||||
async function rankExchanges(question, { embed, cosine, k = 5 } = {}) {
|
||||
const { exchanges, votes } = await listExchanges()
|
||||
async function rankExchanges(question, { embed, cosine, k = 5, excludeAuthors = null } = {}) {
|
||||
const listed = await listExchanges()
|
||||
const votes = listed.votes
|
||||
const exchanges = excludeAuthors instanceof Set && excludeAuthors.size
|
||||
? listed.exchanges.filter(ex => !excludeAuthors.has(String(ex.author)))
|
||||
: listed.exchanges
|
||||
if (!exchanges.length) return []
|
||||
const scored = []
|
||||
if (typeof embed === 'function' && typeof cosine === 'function') {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue