{"id":26662828,"url":"https://github.com/speciesfilegroup/taxonpages","last_synced_at":"2026-03-03T18:03:57.956Z","repository":{"id":41490481,"uuid":"498895136","full_name":"SpeciesFileGroup/taxonpages","owner":"SpeciesFileGroup","description":"TaxonPages is a tool to serve TaxonPages.","archived":false,"fork":false,"pushed_at":"2025-10-15T17:13:10.000Z","size":1429,"stargazers_count":13,"open_issues_count":29,"forks_count":41,"subscribers_count":10,"default_branch":"setup","last_synced_at":"2025-10-16T15:56:36.333Z","etag":null,"topics":["species","speciespage","taxonomy","taxonpages"],"latest_commit_sha":null,"homepage":null,"language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SpeciesFileGroup.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2022-06-01T20:52:50.000Z","updated_at":"2025-10-15T17:13:14.000Z","dependencies_parsed_at":"2023-01-21T20:16:59.669Z","dependency_job_id":"7e965b9f-8d8c-4bcb-9e4f-8a6ffb71160f","html_url":"https://github.com/SpeciesFileGroup/taxonpages","commit_stats":{"total_commits":42,"total_committers":4,"mean_commits":10.5,"dds":"0.23809523809523814","last_synced_commit":"c972e419f793cc8340f862ce24005f4637513b91"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/SpeciesFileGroup/taxonpages","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpeciesFileGroup%2Ftaxonpages","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpeciesFileGroup%2Ftaxonpages/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpeciesFileGroup%2Ftaxonpages/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpeciesFileGroup%2Ftaxonpages/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SpeciesFileGroup","download_url":"https://codeload.github.com/SpeciesFileGroup/taxonpages/tar.gz/refs/heads/setup","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SpeciesFileGroup%2Ftaxonpages/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":281391761,"owners_count":26492903,"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","status":"online","status_checked_at":"2025-10-28T02:00:06.022Z","response_time":60,"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":["species","speciespage","taxonomy","taxonpages"],"created_at":"2025-03-25T14:18:39.505Z","updated_at":"2025-10-28T05:44:18.837Z","avatar_url":"https://github.com/SpeciesFileGroup.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TaxonPages\n\nTaxonPages is a tool to serve taxon pages. At present it draws data from TaxonWorks' API, however we seek to keep the TaxonPages platform agnostic therefor facilitating the modular addition of functionality that may reference data from any biodiversity data-serving API.\n\n## Status Warning\n\nTaxonPages software is in active development and changes are expected that will cause the early first-adopters' instances to require rebuilding by refreshing one's forked branch using `git pull`. A first _stable version_ is expected by Spring 2023.\n\n## Usage\n\n1. Click on \"Fork\" button to create your own repository from this.\n2. Uncheck `Copy the setup branch only` and press `Save`\n3. After create your repo, go to `Settings \u003e Pages`, on \"Build and deployment - Source\" select `GitHub Actions`.\n4. Go to `Actions` tab and press `I understand my workflows, go ahead and enable them` button\n5. Open `router.yml` file and change `base_url` to the name of your repository.\n6. After a couple of minutes, your public page should be available at `https://\u003cyour_user_name\u003e.github.io/\u003cyour_repo_name\u003e`\n\n### Setup\n\n1. Switch to `setup` branch in your TaxonPages repository.\n2. We provide some settings by default to setup your public pages, but API parameters are required and must be configured to get the data from your TaxonWorks project.\n\n```yaml\n# config/api.yml\n---\nurl: https://\u003cyour.taxonworks.server\u003e/api/v1\nproject_token: yourprojecttoken\n```\n\n3. Push the changes after update the configuration files inside `setup` branch\n4. GitHub actions will build TaxonPages with the current configuration in `setup` branch and publish it to the `gh-pages` branch\n\n# Install\n\nFollow this steps to run TaxonPages in your local machine.\n\n1. Install [NodeJS](https://nodejs.org/en/download/)\n2. We recommend you to fork this repository to keep getting updates. Use [GIT](https://git-scm.com/) to clone the repo.\n\n```\ngit clone https://github.com/\u003cyour_username\u003e/\u003cyour_repository_name\u003e.git\n```\n\nBut if you don't want to fork it, you can clone directly from this\n\n```\ngit clone https://github.com/SpeciesFileGroup/taxonpages.git\n```\n\n3. Go to `taxonpages` folder and enter the following commands to copy the software to your `setup` branch\n\n```\ngit checkout main\ngit checkout setup\ngit checkout main .\ngit reset\ngit checkout .\n```\n\n5. Setup `config/api.yml` with the API server configuration\n\n6. Install node dependencies\n\n```\nnpm install\n```\n\n## Start TaxonPages\n\n```\nnpm run dev\n```\n\nTaxonPages will be running at http://localhost:5173/\n\n# Customization\n\n## Pages\n\nTaxonPages out of the box support markdown and vue for content sites. Add your content pages inside `pages` folder. By default, TaxonPages use the file name to create the route.\nFor example, if the filename is \"contributors.md\" the route to access it will be http://yourtaxonpagessite/contributors\n\n### Markdown pages\n\nThis software use [vite-plugin-md](https://github.com/antfu/vite-plugin-md) to render pages in Markdown format, the engine of this plugin is [markdown-it](https://github.com/markdown-it/markdown-it). For plugins and other configuration you can refer to this section https://github.com/antfu/vite-plugin-md#configuration--options\n\nExample: `welcome.md` file\n\n```\n---\nname: 'Charles Darwin'\n---\n\n# Welcome, {{ name }}!\n```\n\nTo use TaxonPage internal variables in `config/*.yml`, you can either do so by adding the prefix {{ app:var_name }} or use the script tag in your markdown page and get them from the global object `__APP_ENV__`\n\n#### Prefix\n\n```markdown\n# Welcome to {{ app:project_name }}!\n```\n\n#### Script tag\n\n```javascript\n# Welcome to {{ project_name }}!\n\n\u003cscript setup\u003e\nconst { project_name } = __APP_ENV__\n\u003c/script\u003e\n```\n\n#### Components\n\nTaxonPages global components are enable in your markdown pages, by default we provide a set of global components that you don't need to import them to use it. You can see the list of this global components [here](#global-components)\n\n### Style\n\nIf you want to change the color palette, you can edit `/config/style/theme.css` file, colors must be in RGB format.\nTaxonPages use [TailwindCSS](https://tailwindcss.com/docs/configuration) framework for the style. We already provide default settings for colors and markdown. If you want to make any change to your configuration, you must do so in the `config/vendor/tailwind.config.js` file. This file uses the TaxonPages configuration as a default. It is possible to overwrite it as long as you use it as a preset.\n\n## Analytics\n\nTaxonPages has out-of-the-box support for the following list of analytics services:\n\n```yaml\nanalytics_services:\n  enableDev: false # Set true to work in development mode\n  analytics:   # Google Analytics\n    - id: 'G-XXXXX'\n  gtm:         # Google Tag Manager\n    - id: 'GTM-XXXXX'\n  pixel:       # Facebook Pixel\n    - id: 'XXXXXXX'\n  retargeting: # VK Retargeting\n    - id: 'VK-RTRG-XXXXXX-XXXXX',\n  linkedin:    # Linkedin Insight\n    - id: 'XXXXXXX'\n  tongji:      # Baidu Tongji\n    - id: 'XXXXXXX',\n  metrica:     # Yendex Metrica\n    - id: 'XXXXXXX',\n  microsoft:   # Microsoft Analytics\n    id: 'XXXXXXX'\n  hotjar:      # Hotjar Analytics\n    id: 'XXXXXXX',\n  fullStory:   # Full story Analytics\n    org: 'X-XXXXXX-XXX'\n  tiktok:      # TikTok Pixel Analytics\n    id: 'XXXXXXX'\n```\n\n# Deep dive into TaxonPages\n\n## Access internal configuration vars\n\nTo access the configuration in \\*.yml files, we provide a global object that contains all the configuration values. This variable can be used in either JavaScript, Vue, or Markdown files. To access these values you must use the `__APP_ENV__` variable:\n\n```javascript\nconst { project_name } = __APP_ENV__\n// or\nconst projectName = __APP_ENV__.project_name\n```\n\n\n## Taxa Page\n\n### Layout\n\nTo modify the position of the panels in the layout of the Taxa page, edit the `taxa_page.yml` file. There you can add/move/remove panels from the layout, also you can add new tabs and include new panels there. If you want to make some tabs visible or not depending the rank group, you can include `rankGroup`\n\n```yaml\ntaxa_page:\n  overview:\n    panels:\n      - - - panel:gallery\n          - panel:type\n          - panel:type-specimen\n          - panel:nomenclature\n          - panel:nomenclature-references\n\n        - - panel:map\n          - panel:descendants\n          - panel:content\n          - panel:statistics\n          - panel:keys\n          - panel:sounds\n#\n# An example of a new tab:\n#\n# type_specimens:\n#   rank_group: ['SpeciesGroup']\n#   panels:\n#     - - - panel:specimen-records\n```\n\n### Lifecycle hooks (Experimental feature)\n\nThe `onCreatePage` and `onSSRPageCreate` functions allow you to execute code at the time the taxa page is created. `onSSRPageCreate` will be executed only on the server side in SSR mode. To make use of them it is necessary to include them in a file object called `pages/otus.config.js`. Both functions accept `otu`, `taxon`, `route` and `router` objects as parameters. Since `onCreatePage` runs on Taxa page component, it is possible to use hooks like `onMounted` or `onBeforeMount` inside it\n\n```javascript\nexport default {\n  onSSRCreatePage: async ({ otu, taxon, route, router }) =\u003e {\n    // Your code here\n  },\n\n  onCreatePage: ({ otu, taxon, route, router }) =\u003e {\n    // Your code here\n  }\n}\n```\n\n### Customizing the Layout\n\nThe application comes with a default layout that includes a header and a footer. If you'd like to replace this layout with your own, you can do so by creating a custom layout file.\n\nSteps to replace the default layout\n\n1. In the root folder of your project, create a new folder called `layouts` (if it doesn't already exist).\n2. Inside this folder, create a file named default.vue.\n3. Define your custom layout structure inside this file as needed.\n\nExample of layouts/default.vue\n\n```vuejs\n\u003ctemplate\u003e\n  \u003cdiv\u003e\n    \u003cslot /\u003e\n  \u003c/div\u003e\n\u003c/template\u003e\n```\n\nThis custom layout will replace the default one and be applied throughout the application. You can include your own elements, such as a navigation bar or footer, as needed.\n\n#### Using Multiple Layouts\n\nIn addition to replacing the default layout, you can create multiple layouts by adding more .vue files inside the layout folder. You can then specify which layout to use for a specific page by setting the layout name in the meta property of the `\u003croute\u003e` tag in your Single File Component (SFC).\n\nJSON5:\n\n```js\n\u003croute\u003e\n{\n  meta: {\n    layout: 'custom'\n  }\n}\n\u003c/route\u003e\n```\n\nYAML:\n\n```yaml\n\u003croute lang=\"yaml\"\u003e\nmeta:\n  layout: custom\n\u003c/route\u003e\n```\n\n### External panels\n\nTo add panels in Taxa pages, create a folder called `panels` in your `setup` branch, and inside it create another folder for your panel. For example: `panels/PanelTest`\n\nIn `PanelTest` folder, create a `main.js` file, with the following structure:\n\n```javascript\nimport MyPanelComponent from './MyPanelComponent.vue'\n\nExport default {\n   id: 'panel:test', // ID to identify this panel\n   component: MyPanelComponent, // Vue component for your panel\n   rankGroup: ['HigherClassificationGroup', 'FamilyGroup', 'GenusGroup', 'SpeciesGroup'] // \u003c-- OPTIONAL: This will define for which rank group will be available, remove it if your panel will be available for all.\n}\n```\n\nThis file is used to load your panel component in taxa page. Use the `id` to include and define the position in the layout in `taxa_page.yml`\n\n```yaml\ntaxa_page_overview:\n  panels:\n    - - - panel:gallery\n        - panel:test # \u003c--- Your new panel\n        - panel:type\n        - panel:type-specimen\n        - panel:nomenclature\n        - panel:nomenclature-references\n\n      - - panel:map\n        - panel:descendants\n        - panel:content\n        - panel:statistics\n        - panel:keys\n        - panel:sounds\n```\n\n## Defining global components\n\nTaxonPages provides an auto-import component from `src/components` and `/components` folders using special extensions for it. Some objects and functions are only present in the browser and not in the NodeJs server environment. When you run code that is not supported by the server, it ends up crashing. Some JavaScript libraries like `Leaflet` use the `document` or `window` object, which do not exist in the node environment. To handle this problem, TaxonPages provides 2 ways to import the components.\n\n### Client Side only (CSR):\n\nThis auto import method will only load the component on the client side, while on the server it will create a fake empty component, which will be used later on the client side to be replaced by the original one when the hydration process occurs. To define this type of import, the component name must contain the word `.client.` before `.vue` extension.\n\nExample: `MyAmazingComponent.client.vue`\n\n### Global (CSR \u0026 SSR)\n\nThis auto-import method will load the component both client and server side. To define this type of import, the component must contain the word `.client.` before the `.vue` extension.\n\nExample: `MyAmazingComponent.global.vue`\n\n### Global components\n\nTaxonPages provides a set of global components that could be used to create your own panels or pages. Here is the complete list:\n\n| Component             | Description                                    | Props                                                                                                                    |\n| --------------------- | ---------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------ |\n| `\u003cAnimationOpacity/\u003e` | Add an opacity animation for a child component |                                                                                                                          |\n| `\u003cAutocomplete/\u003e`     | Used to perform searches in TaxonWorks         | [Link](https://github.com/SpeciesFileGroup/taxonpages/blob/main/src/components/Autocomplete/Autocomplete.global.vue#L42) |\n| `\u003cAutocompleteOtu/\u003e`  | A specific autocomplete for OTU search         |                                                                                                                          |\n| `\u003cClientOnly/\u003e`       | Render child components only from client side  |                                                                                                                          |\n| `\u003cVButton/\u003e`          | Button component                               |                                                                                                                          |\n| `\u003cVCard/\u003e`            | Card component style                           |                                                                                                                          |\n| `\u003cVCardContent/\u003e`     | Card content body                              |                                                                                                                          |\n| `\u003cVCardHeader/\u003e`      | Card Header                                    |                                                                                                                          |\n| `\u003cVClipboard/\u003e`       | Copy a text to clipboard                       |                                                                                                                          |\n| `\u003cDropdown/\u003e`         | Dropdown menu                                  |                                                                                                                          |\n| `\u003cGalleryImage/\u003e`     |                                                | [Link](https://github.com/SpeciesFileGroup/taxonpages/blob/main/src/components/Gallery/GalleryImage.global.vue#L40)      |\n| `\u003cImageViewer/\u003e`      |                                                |                                                                                                                          |\n| `\u003cTrackerReport/\u003e`    | Show trackers to report issues                 | [Link](https://github.com/SpeciesFileGroup/taxonpages/blob/main/src/components/TrackerReport.global.vue#L47)             |\n| `\u003cTabMenu/\u003e`          |                                                |                                                                                                                          |\n| `\u003cTabItem/\u003e`          |                                                |                                                                                                                          |\n| `\u003cVMap/\u003e`             | Interactive map that use Leaflet library       |                                                                                                                          |\n| `\u003cVModal/\u003e`           | Create lightboxes                              |                                                                                                                          |\n| `\u003cVSkeleton/\u003e`        | Content loading placeholder                    |                                                                                                                          |\n| `\u003cVSpinner/\u003e`         | Loading spinner                                |                                                                                                                          |\n| `\u003cVTable/\u003e`           |                                                |                                                                                                                          |\n| `\u003cVTableBody/\u003e`       |                                                |                                                                                                                          |\n| `\u003cVTableBodyCell/\u003e`   |                                                |                                                                                                                          |\n| `\u003cVTableBodyRow/\u003e`    |                                                |                                                                                                                          |\n| `\u003cVTableHeader/\u003e`     |                                                |                                                                                                                          |\n| `\u003cVTableHeaderCell/\u003e` |                                                |                                                                                                                          |\n| `\u003cVTableHeaderRow/\u003e`  |                                                |                                                                                                                          |\n\n| Icons                |\n| -------------------- |\n| `\u003cIconArrowDown/\u003e`   |\n| `\u003cIconArrowLeft/\u003e`   |\n| `\u003cIconArrowRight/\u003e`  |\n| `\u003cIconCheck/\u003e`       |\n| `\u003cIconClipboard/\u003e`   |\n| `\u003cIconClose/\u003e`       |\n| `\u003cIconDocument/\u003e`    |\n| `\u003cIconDownload/\u003e`    |\n| `\u003cIconHamburger/\u003e`   |\n| `\u003cIconJson/\u003e`        |\n| `\u003cIconMinusCircle/\u003e` |\n| `\u003cIconPlusCircle/\u003e`  |\n| `\u003cIconSearch/\u003e`      |\n| `\u003cIconTrash/\u003e`       |\n| `\u003cIconWarning/\u003e`     |\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspeciesfilegroup%2Ftaxonpages","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fspeciesfilegroup%2Ftaxonpages","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fspeciesfilegroup%2Ftaxonpages/lists"}