lenape-timetree
Source code for the CDH-sponsored Lunaapahkiing Princeton Timetree research project
Science Score: 75.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
✓DOI references
Found 3 DOI reference(s) in README -
✓Academic publication links
Links to: zenodo.org -
○Academic email domains
-
✓Institutional organization owner
Organization princeton-cdh has institutional domain (cdh.princeton.edu) -
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (13.5%) to scientific vocabulary
Keywords
Repository
Source code for the CDH-sponsored Lunaapahkiing Princeton Timetree research project
Basic Info
- Host: GitHub
- Owner: Princeton-CDH
- License: apache-2.0
- Language: JavaScript
- Default Branch: main
- Homepage: https://lenapetimetree.indigenous.princeton.edu/
- Size: 70.3 MB
Statistics
- Stars: 4
- Watchers: 2
- Forks: 1
- Open Issues: 4
- Releases: 2
Topics
Metadata Files
README.md
Lunaapahkiing Princeton Timetree
This repository includes source code for the CDH-sponsored Lunaapahkiing Princeton Timetree (LPT) research project. It consists of a custom Hugo theme, with HTML and JSON templates, JavaScript, SCSS, and other assets. It is used with Princeton-CDH/lenape-timetree-content to build the Lunaapahkiing Princeton Timetree web application.
The timetree javascript code in v1.0.1 of this codebase was reviewed by Cole Crawford (Senior Software Engineer, Harvard Arts and Humanities Research Computing) and Raff Viglianti (Senior Research Software Developer, Maryland Institute for Technology in the Humanities) via DHTech Community Code Review; review was faciliated by Julia Damerow (Lead Scientific Software Engineer, Arizona State University).
Note: this project was originally developed in a single git repository; in September 2023 the repository was split out to separate content and code to simplify maintenance and ownership. An archive of the original git repository with the combined history up to that point is available at Princeton-CDH/lenape-timetree-archive.
License
The software for this project is licensed under the Apache 2.0 License.
Developer + contributor setup instructions
For instructions on editing site content, refer to CONTRIBUTING. Local setup is not required for content editing.
Hugo setup
To set the site up locally for development or content editing, first follow the instructions to install Hugo. You can check that Hugo is installed with:
sh
hugo version
This should result in output something like this:
hugo v0.101.0+extended darwin/amd64 BuildDate=unknown
Make sure the version you installed is at least as new as the version shown in the Hugo badge at the top of the project readme (this file).
Once hugo is installed, you'll need to install the javascript dependencies that are used to compile the site's javascript and scss resource files. To check if you have node installed:
sh
node --version
This should output a version string that is at least as new as the version shown in the node badge at the top of this file. To install dependencies, run npm in the project's root directory:
sh
npm install
If the install completes without errors, you're ready to run the site locally.
Serving locally
To run a development server with auto-reload:
sh
hugo server
You should see some debug output, followed by:
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1) Press Ctrl+C to stop
Open a web browser to the above address to see a local version of the site. When you make changes and save files locally, hugo will automatically refresh the page.
Install pre-commmit hooks
Anyone planning to do development on the site (i.e., contributing to javascript, scss, or templates), you need to install pre-commit hooks to automatically ensure that code is consistently formatted. This step is not required for anyone who is working on site content and not modifying code or templates.
Commit hooks are managed with pre-commit. To install, run:
{bash}
pre-commit install
Current hooks include Black for python code formatting, isort for standardized python imports, and Prettier for javascript, css, markdown, and other supported file types.
Standardized code styles were instituted after some development was done on this project.
To configure git blame to ignore the styling commit, use the following:
{bash}
git blame <FILE> --ignore-revs-file .git-blame-ignore-revs
Or configure git to always ignore the styling revision commit:
{bash}
git config blame.ignoreRevsFile .git-blame-ignore-revs
Developing and testing with timetree content
To do development work on this theme with the corresponding content from this project, check out a copy of the timetree content repository Princeton-CDH/lenape-timetree-content. Modify (but do not change) your go modules configuration to run from your local copy of the theme as follows:
{bash}
go mod edit -replace github.com/Princeton-CDH/lenape-timetree=../lenape-timetree
And then run hugo from the content repository to build the site.
Shortcodes
The timetree theme includes the following custom short codes.
audio
A shortcode for including audio, which takes src and caption arguments, e.g.
{{<audio src="/audio/lunaapahkiing-pronunciation-mosko.mp3" caption="Listen to a pronunciation of *Lunaapahkiing* by Karen Mosko (Lunaape Language Teacher, Munsee-Delaware Nation)" >}}
figure
This is a customized version of Hugo's default figure shortcode, adapted from Startwords that rescales raster images using custom breakpoints and displays them with a caption.
It's highly recommended to use figure rather than simple images via Markdown, so that images can be automatically sized and properly styled. Non-figure images may not display in a consistent manner.
You can optionally provide an attr to add an attribution to the caption, and attrlink will make the attribution a link pointing to the given URL. If you need extra control over the height of the image, you can pass any valid CSS measurement to max-height, which will be applied via an inline style.
For assistive technology, an alt is required to describe the image. Optionally, you can associate the image with another element containing a visually hidden long description using desc-id, which will be the value used for aria-describedby.
Simple example:
{{< figure src="images/duck.jpg" alt="Rubber duck sitting in a bathtub." >}}
Example use for a photograph with attribution:
{{< figure src="images/duck.jpg" alt="Rubber duck sitting in a bathtub." caption="Gerald relaxing in the bath." attr="Photo by me." attrlink="http://example.com/" >}}
Example use for a chart or graph, with long description:
{{< figure src="images/chart.svg" alt="Bar chart showing sales growth for Q1 2020." caption="Sales are improving for our industry." desc-id="chart-desc" >}}
{{< wrap class="sr-only" id="chart-desc">}}Four different economic sectors are represented. The sector showing the most sales growth is the rubber duck industry, with growth approaching 25%.{{</ wrap >}}
parameters
src, URL of the image in the figure.alt, text used by assistive technology to describe the content of the figure.caption, optional: descriptive text to be shown underneath the figure.attr, optional: attribution text to be shown underneath the figure.attrlink, optional: URL for makingattrtext a hyperlink.desc-id, optional: html id of an element containing longer descriptive text.
project citation
A shortcode for generating a project citation based on publication information in the site and theme config files. Project citation can be generated with or without authors:
``` {{< project_citation noAuthors=true >}}
{{< project_citation >}} ```
The citation uses the site title, and authors, version, publisher, publication date, and citation url from the site config. Authors should be listed in "Lastname, Firstname" format. For example:
yaml
authors:
- Lastname, First
- Lastname, First
- Lastname, First
publisher: Some group
publication_date: 2023
citation_url: https://project.example.edu/
panel legend
This is a custom shortcode used to generate the branch legend in the opening panel of the timetree. Branches must be configured in site parameters.
Owner
- Name: Center for Digital Humanities at Princeton
- Login: Princeton-CDH
- Kind: organization
- Email: cdh-info@princeton.edu
- Location: Princeton, New Jersey
- Website: https://cdh.princeton.edu/
- Twitter: princetondh
- Repositories: 59
- Profile: https://github.com/Princeton-CDH
Citation (CITATION.cff)
# YAML 1.2
# Metadata for citation of this software according to the CFF format (https://citation-file-format.github.io/)
cff-version: 1.0.3
message: If you use this software, please cite it using these metadata.
title: 'lenape-timetree'
doi: 10.5281/zenodo.8040363
authors:
- given-names: Rebecca Sutton
family-names: Koeser
affiliation: Center for Digital Humanities, Princeton University
orcid: https://orcid.org/0000-0002-8762-8057
- given-names: Gissoo
family-names: Doroudian
affiliation: Center for Digital Humanities, Princeton University
orcid: https://orcid.org/0000-0002-6702-6964
- given-names: Ryan
family-names: Heuser
affiliation: Center for Digital Humanities, Princeton University
orcid: https://orcid.org/0000-0002-4155-4961
version: '1.0'
date-released: 2023-06-14
repository-code: https://github.com/Princeton-CDH/lenape-timetree
license: Apache-2.0
references:
- type: website
title: Lunaapahkiing Princeton Timetree
year: 2022
authors:
- name: The Center for Digital Humanities at Princeton
website: https://cdh.princeton.edu
url: https://lenapetimetree.indigenous.princeton.edu/
keywords:
- digital humanities
- data visualization
- indigenous peoples
- indigenous knowledge
- hugo static site
- d3.js
GitHub Events
Total
Last Year
Issues and Pull Requests
Last synced: 10 months ago
All Time
- Total issues: 57
- Total pull requests: 90
- Average time to close issues: 22 days
- Average time to close pull requests: 1 day
- Total issue authors: 3
- Total pull request authors: 2
- Average comments per issue: 1.91
- Average comments per pull request: 3.04
- Merged pull requests: 74
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- rlskoeser (17)
- gissoo (8)
- jhimpele (3)
Pull Request Authors
- rlskoeser (37)
- jhimpele (20)
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 2
- Total downloads: unknown
-
Total dependent packages: 0
(may contain duplicates) -
Total dependent repositories: 0
(may contain duplicates) - Total versions: 6
proxy.golang.org: github.com/Princeton-CDH/lenape-timetree
- Documentation: https://pkg.go.dev/github.com/Princeton-CDH/lenape-timetree#section-documentation
- License: apache-2.0
-
Latest release: v1.0.5
published over 2 years ago
Rankings
proxy.golang.org: github.com/princeton-cdh/lenape-timetree
- Documentation: https://pkg.go.dev/github.com/princeton-cdh/lenape-timetree#section-documentation
- License: apache-2.0
-
Latest release: v1.0.5
published over 2 years ago
Rankings
Dependencies
- actions/checkout v3 composite
- actions/configure-pages v1 composite
- actions/deploy-pages v1 composite
- actions/upload-pages-artifact v1 composite
- python-slugify *
- pyyaml *
- actions/cache v3 composite
- actions/checkout v3 composite
- actions/setup-node v3 composite
- actions/upload-artifact v3 composite
- peaceiris/actions-hugo v2 composite
- treosh/lighthouse-ci-action v9 composite
- actions/cache v2 composite
- actions/checkout v3 composite
- actions/setup-node v3 composite
- codecov/codecov-action v3 composite
- 527 dependencies
- @babel/core ^7.20.12 development
- @babel/preset-env ^7.20.2 development
- @percy/cli ^1.19.1-alpha.0 development
- babel-jest ^29.4.2 development
- jest ^29.4.2 development
- jest-environment-jsdom ^29.4.3 development
- jest-fetch-mock ^3.0.3 development
- d3 ^7.8.4
- sass ^1.56.1
- the-new-css-reset ^1.7.3