{"id":48536153,"url":"https://github.com/dknauss/wp-bibliography-block","last_synced_at":"2026-04-08T02:01:06.356Z","repository":{"id":349673333,"uuid":"1203393463","full_name":"dknauss/wp-bibliography-block","owner":"dknauss","description":"WordPress block plugin: DOI/BibTeX to semantically rich, auto-sorted bibliography.","archived":false,"fork":false,"pushed_at":"2026-04-07T04:02:39.000Z","size":816,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-07T04:24:40.094Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dknauss.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":"docs/supported-input-style-matrix.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-04-07T02:13:32.000Z","updated_at":"2026-04-07T04:02:48.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/dknauss/wp-bibliography-block","commit_stats":null,"previous_names":["dknauss/wp-bibliography-block"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/dknauss/wp-bibliography-block","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dknauss%2Fwp-bibliography-block","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dknauss%2Fwp-bibliography-block/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dknauss%2Fwp-bibliography-block/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dknauss%2Fwp-bibliography-block/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dknauss","download_url":"https://codeload.github.com/dknauss/wp-bibliography-block/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dknauss%2Fwp-bibliography-block/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31536473,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-07T16:28:08.000Z","status":"online","status_checked_at":"2026-04-08T02:00:06.127Z","response_time":54,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-08T02:00:50.454Z","updated_at":"2026-04-08T02:01:06.290Z","avatar_url":"https://github.com/dknauss.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# A Bibliography Block for WordPress\n\n[![License: GPL v2+](https://img.shields.io/badge/License-GPLv2%2B-blue.svg)](https://www.gnu.org/licenses/gpl-2.0.html)\n[![WordPress tested](https://img.shields.io/badge/WordPress-6.4%E2%80%93latest-21759b.svg?logo=wordpress\u0026logoColor=white)](https://github.com/dknauss/wp-bibliography-block/actions/workflows/runtime-matrix.yml)\n[![PHP tested](https://img.shields.io/badge/PHP-7.4%E2%80%938.4-777bb4.svg?logo=php\u0026logoColor=white)](https://github.com/dknauss/wp-bibliography-block/actions/workflows/runtime-matrix.yml)\n[![CI](https://github.com/dknauss/wp-bibliography-block/actions/workflows/ci.yml/badge.svg)](https://github.com/dknauss/wp-bibliography-block/actions/workflows/ci.yml)\n[![Runtime matrix](https://github.com/dknauss/wp-bibliography-block/actions/workflows/runtime-matrix.yml/badge.svg)](https://github.com/dknauss/wp-bibliography-block/actions/workflows/runtime-matrix.yml)\n[![CodeQL](https://github.com/dknauss/wp-bibliography-block/actions/workflows/codeql.yml/badge.svg)](https://github.com/dknauss/wp-bibliography-block/actions/workflows/codeql.yml)\n[![Codecov](https://codecov.io/gh/dknauss/wp-bibliography-block/branch/main/graph/badge.svg)](https://codecov.io/gh/dknauss/wp-bibliography-block)\n[![WordPress Playground](https://img.shields.io/badge/WordPress%20Playground-Try%20it-3858e9.svg?logo=wordpress\u0026logoColor=white)](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/dknauss/wp-bibliography-block/main/playground/blueprint.json)\n\nThe only all-in-one bibliography block for the WordPress editor that transforms pasted scholarly references — DOI numbers/URLs, BibTeX entries, and supported formatted citations — into a semantically rich, auto-sorted bibliography with static saved output. Export your work as CSL-JSON, BibTeX, and RIS.\n\nNo shortcodes. No database storage. Static HTML output survives plugin deactivation.\n\nJust write out your citations or paste DOIs and BibTeX code, up to 50 at a time. Easily build a formatted, auto-sorted bibliography in any style. \n\n## Try it in WordPress Playground\n\nLaunch a disposable WordPress instance with the plugin preinstalled: [Try the Bibliography Block in WordPress Playground](https://playground.wordpress.net/?blueprint-url=https://raw.githubusercontent.com/dknauss/wp-bibliography-block/main/playground/blueprint.json). Playground installs the plugin from the latest GitHub Release zip artifact.\n\n![](.wordpress-org/banner-1544x500.png)\n\n## Screenshots\n\n| Editor with citations | Front-end output |\n|---|---|\n| ![](.wordpress-org/screenshot-4.png) | ![](.wordpress-org/screenshot-5.png) |\n\n| Block inserter | Empty-state form | Manual entry |\n|---|---|---|\n| ![](.wordpress-org/screenshot-1.png) | ![](.wordpress-org/screenshot-2.png) | ![](.wordpress-org/screenshot-3.png) |\n\n## Installation\n\n1. Upload the plugin files to `/wp-content/plugins/scholarly-bibliography/`, or install directly through the WordPress plugin screen.\n2. Activate the plugin through the **Plugins** screen in WordPress.\n3. Add the **Bibliography** block to any post or page.\n4. Paste DOI(s), BibTeX entries, or supported citations.\n\n## Compatibility\n\n- **WordPress** 6.4–7.0 (block.json v3 requires 6.4+)\n- **PHP** 7.4+ (minimal PHP runtime — the plugin registers a block and REST endpoints only)\n- **Multisite** — expected to work (block registration is site-local by default), but not yet tested\n\nThe GitHub Actions runtime matrix covers PHP 7.4 through 8.4 and WordPress 6.4 through latest on both Apache and Nginx. Multisite-specific and SQLite runtime e2e tests are on the backlog.\n\n## Features\n\n- **Multiple input paths** — add bare DOIs, DOI URLs, BibTeX entries, and supported formatted citations\n- **Nine citation styles** — Chicago Notes-Bibliography by default, with Chicago Author-Date, APA 7, Harvard, Vancouver, IEEE, MLA 9, OSCOLA, and ABNT selectable\n- **Structured editing** — plain-text editing plus per-field editing for heuristic or warning-marked citations\n- **Semantic output** — DPUB-ARIA bibliography roles, `\u003ccite\u003e` wrappers, `lang` attributes, and hanging-indent styling\n- **JSON-LD** — Schema.org structured data for search engines, AI systems, and semantic consumers (on by default)\n- **COinS** — optional OpenURL spans for browser-based citation manager detection (useful for Zotero and similar tools)\n- **CSL-JSON output** — optional machine-readable metadata for tool interoperability (useful for scholarly services that consume structured data)\n- **Export** — download the current bibliography as CSL-JSON, BibTeX, or RIS; copy individual citations or the full bibliography as plain text\n- **Static save** — bibliography HTML and metadata are baked into post content at save time\n- **Accessible editor UX** — focus management, block-local Gutenberg notices, keyboard escape/cancel flows, and row action controls\n\n## Supported Input\n\n### First-class inputs\n\n- **Bare DOI** — `10.1000/xyz123`\n- **DOI URL** — `https://doi.org/10.1000/xyz123`\n- **BibTeX** — `@article{key, title={...}, ...}`\n\n### Supported formatted citation coverage\n\nThe free-text parser currently supports a growing set of formatted citations for:\n\n- books\n- journal articles\n- chapters\n- webpages and social media posts\n- reviews\n- theses and dissertations\n\nSupport is heuristic rather than universal. Unsupported inputs fail closed with a block-local inline Gutenberg notice. Manual entry is now available as a fallback for unsupported formats.\n\n## API\n\nThe plugin exposes a read-only REST endpoint for bibliography data:\n\n- `GET /wp-json/scholarly-bibliography/v1/posts/\u003cpost_id\u003e/bibliographies`\n- `GET /wp-json/scholarly-bibliography/v1/posts/\u003cpost_id\u003e/bibliographies/\u003cindex\u003e`\n\nBehavior:\n\n- published posts are readable publicly\n- non-public posts require permission to edit the post\n- the collection route returns each bibliography block found in the post, including style settings and citation data\n- the single-bibliography route supports `?format=json`, `?format=text`, and `?format=csl-json`\n\n## External Services\n\nThis plugin connects to the [CrossRef REST API](https://api.crossref.org/) when you paste a DOI to resolve citation metadata. No account or API key is required. Requests are made only when you explicitly add a DOI in the block editor — no data is sent automatically or in the background.\n\n- [CrossRef](https://www.crossref.org/)\n- [CrossRef REST API documentation](https://api.crossref.org/swagger-ui/index.html)\n- [CrossRef privacy policy](https://www.crossref.org/privacy/)\n- [CrossRef terms of service](https://www.crossref.org/terms/)\n\n## Development\n\nRequires Node.js 18+, npm 9+, and Composer.\n\n```bash\nnpm install                  # Install dependencies\ncomposer install             # Install PHP tooling\nnpm run build                # Production build\nnpm run start                # Development mode with file watching\nnpm run lint:js              # ESLint\nnpm run lint:css             # Stylelint\nnpm run lint:php             # WPCS/PHPCS\nnpm run test                 # Unit tests\nnpm run test:js:coverage     # JS coverage for Codecov\nnpm run test:rest:local      # Local REST endpoint smoke test (Studio site)\nnpm run test:e2e             # Playwright smoke suite against local site\nnpm run test:e2e:playground  # Playground-based Playwright smoke suite\nnpm run test:e2e:lifecycle   # Plugin lifecycle e2e tests (activate/deactivate/delete)\nnpm run test:runtime:local   # Docker-based runtime smoke environment\ncomposer test:php            # PHPUnit REST and bootstrap tests\ncomposer test:php:coverage   # PHP coverage for Codecov\ncomposer analyze:php         # Psalm static analysis\n```\n\nGitHub Actions currently runs:\n\n- Node quality/build checks\n- PHPUnit across PHP 7.4, 8.1, and 8.3\n- Psalm static analysis\n- CodeQL for JavaScript and PHP\n- Codecov uploads from JS + PHP coverage\n- Playwright smoke and lifecycle tests against WordPress Playground\n\nThe GitHub Actions runtime matrix currently covers:\n\n- Apache + PHP 7.4 + WordPress 6.4\n- Apache + PHP 8.1 + WordPress 6.4\n- Apache + PHP 8.1 + WordPress 6.7\n- Apache + PHP 8.2 + latest WordPress\n- Apache + PHP 8.3 + latest WordPress\n- Apache + PHP 8.4 + latest WordPress\n- Nginx + PHP 8.1 + WordPress 6.7\n- Nginx + PHP 8.2 + latest WordPress\n- Nginx + PHP 8.3 + latest WordPress\n\nEach runtime smoke job uploads artifacts, including Docker logs, service status, HTTP responses, and environment summaries under `output/runtime-matrix/\u003cmatrix-name\u003e`.\n\nSQLite runtime smoke remains a planned follow-up while the CI bootstrap path is stabilized.\n\n### File structure\n\n```text\nscholarly-bibliography/\n├── scholarly-bibliography.php    # Plugin bootstrap\n├── block.json                    # Block metadata \u0026 attributes\n├── src/\n│   ├── index.js                  # Block registration\n│   ├── edit.js                   # Editor component\n│   ├── save.js                   # Static save entrypoint\n│   ├── save-markup.js            # Shared static save markup\n│   ├── editor.scss               # Editor-only styles\n│   ├── style.scss                # Frontend bibliography styles\n│   └── lib/\n│       ├── parser.js             # Input detection \u0026 parsing orchestration\n│       ├── sorter.js             # Style-family bibliography sort comparator\n│       ├── coins.js              # CSL-JSON → COinS builder\n│       ├── jsonld.js             # CSL-JSON → Schema.org JSON-LD mapper\n│       └── formatting/           # Style registry + CSL-backed formatting\n├── package.json\n└── readme.txt                    # WordPress.org readme\n```\n\nSee [SPEC.md](SPEC.md) for the authoritative behavior specification and future plans.\n\n## Contributing\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md) for development setup, coding standards, and PR process.\n\n## Security\n\nSee [SECURITY.md](SECURITY.md) for reporting vulnerabilities.\n\n## License\n\nGPL-2.0-or-later. See [LICENSE](LICENSE) for the full text.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdknauss%2Fwp-bibliography-block","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdknauss%2Fwp-bibliography-block","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdknauss%2Fwp-bibliography-block/lists"}