{"id":20749724,"url":"https://github.com/tilde-lab/cifplayer","last_synced_at":"2025-04-28T12:51:58.107Z","repository":{"id":61947541,"uuid":"39165197","full_name":"tilde-lab/cifplayer","owner":"tilde-lab","description":"Minimalistic and fast HTML5 visualization of chemical structures in CIF, POSCAR, and OPTIMADE formats","archived":false,"fork":false,"pushed_at":"2025-04-03T19:12:15.000Z","size":6953,"stargazers_count":26,"open_issues_count":5,"forks_count":8,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-12T09:26:16.833Z","etag":null,"topics":["cif","cifs","crystal-structure","crystallography","optimade","poscar","symmetry","threejs"],"latest_commit_sha":null,"homepage":"http://nanoshow.mpds.io/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tilde-lab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2015-07-15T22:59:04.000Z","updated_at":"2025-04-01T09:50:36.000Z","dependencies_parsed_at":"2023-01-22T07:02:05.586Z","dependency_job_id":"89ae6cc4-be10-498f-a331-9b899dd3a1ec","html_url":"https://github.com/tilde-lab/cifplayer","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tilde-lab%2Fcifplayer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tilde-lab%2Fcifplayer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tilde-lab%2Fcifplayer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tilde-lab%2Fcifplayer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tilde-lab","download_url":"https://codeload.github.com/tilde-lab/cifplayer/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251318423,"owners_count":21570354,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["cif","cifs","crystal-structure","crystallography","optimade","poscar","symmetry","threejs"],"created_at":"2024-11-17T08:24:18.625Z","updated_at":"2025-04-28T12:51:58.056Z","avatar_url":"https://github.com/tilde-lab.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"HTML5 CIF player\n======\n[![DOI](https://zenodo.org/badge/18811/tilde-lab/cifplayer.svg)](https://doi.org/10.5281/zenodo.7692709)\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Ftilde-lab%2Fcifplayer.svg?type=shield)](https://app.fossa.com/projects/git%2Bgithub.com%2Ftilde-lab%2Fcifplayer?ref=badge_shield)\n\nIn-browser ultra-fast and lightweight renderer of the [crystallographic information files (CIF)](https://en.wikipedia.org/wiki/Crystallographic_Information_File), [OPTIMADE JSON](https://github.com/Materials-Consortia/OPTIMADE/blob/master/optimade.rst#entry-list), and VASP [POSCAR](https://www.vasp.at/wiki/index.php/POSCAR) atomic structures, written in a pure JavaScript.\n\nIn a compiled form it is only one standalone embeddable file `web.js` of 300 Kb (gzipped). See it [online](https://tilde-lab.github.io/cifplayer). Only a web-browser is required. After the code is loaded, no internet connection is needed.\n\n\nTechnical details\n------\n\nThis app is written in the `$mol` framework and employs [three.js](https://github.com/mrdoob/three.js) for 3d-rendering and [tween.js](https://github.com/tweenjs/tween.js) for phonon animation. Scientific formats conversion is done with `matinfio.js`.\n\nCompilation is done as follows. Note that, unlike many other frontend frameworks, `$mol` provides the same single environment for all its projects, under the standard namespace scheme. That is, all your `$mol`-based code lives inside the same directory `$MOL_HOME`. So if you don't have `$MOL_HOME` yet, please create it and navigate there:\n\n```bash\nmkdir $MOL_HOME \u0026\u0026 cd $MOL_HOME\n```\n\nThen build with\n\n```bash\nnpm exec mam optimade/cifplayer/player\n```\n\nThis will fetch the MAM server (MAM stands for the `$mol` abstract modules), clone this project, and compile it inside `optimade/cifplayer/player/-/` subfolder. You will need the `web.js` bundle, that's it.\n\nDevelopment is similar to above: inside the `$MOL_HOME`, start the MAM dev-server with\n\n```bash\nnpm exec mam\n```\n\nand navigate to http://localhost:9080, there select `optimade` namespace, then `cifplayer`, then `app`. As you go through the folder structure, the selected project is being cloned and compiled on the fly, inside the corresponding subfolder of `$MOL_HOME`.\n\n\nIntegration with the other software\n------\n\nThe compiled bundle `web.js` defines a web-component `optimade-cifplayer-player`. It can be controlled in a standard way with e.g.\n\n```js\nconst player = document.getElementsByTagName('optimade-cifplayer-player')[0].view;\nplayer.data(structure);\n```\n\nOr in another `$mol` application natively, using a tree markup:\n\n```\n    \u003c= Your_block_name $optimade_cifplayer_player\n        data \u003c= your_data_string null\n```\n\n\nComparison with the other open-source plugin-free engines\n------\n\nSee a detailed [comparison](https://github.com/blokhin/cif-js-engines) as well as the [blog post](https://blog.tilde.pro/in-browser-plugin-free-cif-visualization-comparison-of-open-source-engines-a3d0b4098660), written in 2015. As of now, it is unfortunately severely outdated.\n\n\n## License\n[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Ftilde-lab%2Fcifplayer.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Ftilde-lab%2Fcifplayer?ref=badge_large)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftilde-lab%2Fcifplayer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftilde-lab%2Fcifplayer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftilde-lab%2Fcifplayer/lists"}