fix
Browse files80 unmodified lines81828384848586878889909192939414 unmodified lines10911011111211311411511611711811912012112212312412512612780 unmodified lines if js_fallback: files['index.js'] = js_fallback.group(1).strip() if css_fallback: files['style.css'] = css_fallback.group(1).strip() css_content = css_fallback.group(1).strip() files['style.css'] = css_content # Also normalize HTML to reference style.css (singular) if files['index.html'] and 'styles.css' in files['index.html']: print("[Parser] Normalizing styles.css reference to style.css in HTML") files['index.html'] = files['index.html'].replace('href="styles.css"', 'href="style.css"') files['index.html'] = files['index.html'].replace("href='styles.css'", "href='style.css'") # Additional fallback: extract from numbered sections or file headers if not (files['index.html'] and files['index.js'] and files['style.css']):14 unmodified lines content = re.sub(r'\n```\s*$', '', content) files[file_key] = content.strip() # Normalize filename references in HTML if files['index.html'] and files['style.css']: if 'styles.css' in files['index.html']: print("[Parser] Normalizing styles.css reference to style.css in HTML") files['index.html'] = files['index.html'].replace('href="styles.css"', 'href="style.css"') files['index.html'] = files['index.html'].replace("href='styles.css'", "href='style.css'") if files['index.html'] and files['index.js']: if 'app.js' in files['index.html']: print("[Parser] Normalizing app.js reference to index.js in HTML") files['index.html'] = files['index.html'].replace('src="app.js"', 'src="index.js"') files['index.html'] = files['index.html'].replace("src='app.js'", "src='index.js'") # Normalize transformers.js imports to use v3.8.0 CDN cdn_url = "https://cdn.jsdelivr.net/npm/@huggingface/transformers@3.8.0" backend_parsers.py+21-1