Initial commit: MangaReader iOS App
✨ Features: - App iOS completa para leer manga sin publicidad - Scraper con WKWebView para manhwaweb.com - Sistema de descargas offline - Lector con zoom y navegación - Favoritos y progreso de lectura - Compatible con iOS 15+ y Sideloadly/3uTools 📦 Contenido: - Backend Node.js con Puppeteer (opcional) - App iOS con SwiftUI - Scraper de capítulos e imágenes - Sistema de almacenamiento local - Testing completo - Documentación exhaustiva 🧪 Prueba: Capítulo 789 de One Piece descargado exitosamente - 21 páginas descargadas - 4.68 MB total - URLs verificadas y funcionales 🎉 Generated with Claude Code (https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
48
backend/node_modules/fast-fifo/index.js
generated
vendored
Normal file
48
backend/node_modules/fast-fifo/index.js
generated
vendored
Normal file
@@ -0,0 +1,48 @@
|
||||
const FixedFIFO = require('./fixed-size')
|
||||
|
||||
module.exports = class FastFIFO {
|
||||
constructor (hwm) {
|
||||
this.hwm = hwm || 16
|
||||
this.head = new FixedFIFO(this.hwm)
|
||||
this.tail = this.head
|
||||
this.length = 0
|
||||
}
|
||||
|
||||
clear () {
|
||||
this.head = this.tail
|
||||
this.head.clear()
|
||||
this.length = 0
|
||||
}
|
||||
|
||||
push (val) {
|
||||
this.length++
|
||||
if (!this.head.push(val)) {
|
||||
const prev = this.head
|
||||
this.head = prev.next = new FixedFIFO(2 * this.head.buffer.length)
|
||||
this.head.push(val)
|
||||
}
|
||||
}
|
||||
|
||||
shift () {
|
||||
if (this.length !== 0) this.length--
|
||||
const val = this.tail.shift()
|
||||
if (val === undefined && this.tail.next) {
|
||||
const next = this.tail.next
|
||||
this.tail.next = null
|
||||
this.tail = next
|
||||
return this.tail.shift()
|
||||
}
|
||||
|
||||
return val
|
||||
}
|
||||
|
||||
peek () {
|
||||
const val = this.tail.peek()
|
||||
if (val === undefined && this.tail.next) return this.tail.next.peek()
|
||||
return val
|
||||
}
|
||||
|
||||
isEmpty () {
|
||||
return this.length === 0
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user