Skip to content

Commit

Permalink
Merge branch 'dev' into pss-dev
Browse files Browse the repository at this point in the history
  • Loading branch information
ajolipa committed Aug 13, 2024
2 parents 8e32d76 + d182834 commit 322d10c
Show file tree
Hide file tree
Showing 16 changed files with 165 additions and 107 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Deploy to GitHub Pages

on:
# Trigger the workflow every time you push to the `main` branch
# Using a different branch name? Replace `main` with your branch’s name
push:
branches: [ main ]
# Allows you to run this workflow manually from the Actions tab on GitHub.
workflow_dispatch:

# Allow this job to clone the repo and create a page deployment
permissions:
contents: read
pages: write
id-token: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout your repository using git
uses: actions/checkout@v4
- name: Install, build, and upload your site
uses: withastro/action@v2
with:
path: ./astro-web # The root location of your Astro project inside the repository. (optional)
# node-version: 20 # The specific version of Node that should be used to build your site. Defaults to 20. (optional)
# package-manager: pnpm@latest # The Node package manager that should be used to install dependencies and build your site. Automatically detected based on your lockfile. (optional)

deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
2 changes: 1 addition & 1 deletion .github/workflows/storybook.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ jobs:
with:
branch: gh-pages # The branch the action should deploy to.
folder: editioncrafter/storybook-static # The folder that the build-storybook script generates files.
clean: true # Automatically remove deleted files from the deploy branch
clean: true # Automatically remove deleted files from the deploy branch
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ __tests__/integration/editioncrafter/css/
.cache/
storybook-static
.DS_Store
.github
.github
1 change: 1 addition & 0 deletions astro-web/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,4 @@ pnpm-debug.log*

# github workflows
.github
.github/workflows
2 changes: 1 addition & 1 deletion astro-web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"@astrojs/mdx": "^2.1.1",
"@astrojs/react": "^3.0.10",
"@astrojs/tailwind": "^5.1.0",
"@cu-mkp/editioncrafter": "^1.0.1",
"@cu-mkp/editioncrafter": "^1.0.2",
"@fontsource/dm-sans": "^5.0.19",
"@fontsource/martel": "^5.0.12",
"@fontsource/source-code-pro": "^5.0.17",
Expand Down
Binary file added astro-web/src/assets/footer/footer_logo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion astro-web/src/components/FeatureTabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const FeatureTabs = () => {
Supports multiple transcriptions and translations
</h3>
<p className="text-neutral-gray">
An edition can comprise multiple renditions of a source text, including transcriptions, normalized transcriptions, and translations. Through styling, it supports discontinuous text, inline figures, and special characters, EditionCrafter provides tools for precise transcription and translation.
An edition can comprise multiple renditions of a source text, including transcriptions, normalized transcriptions, and translations. Through styling, it supports discontinuous text, inline figures, and special characters. EditionCrafter provides tools for precise transcription and translation.
</p>
</div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions astro-web/src/components/Footer.astro
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import Container from "./Container.astro";
import logo from "../assets/footer/editioncrafterlogo.svg";
import gh from "../assets/footer/github.svg";
import twitter from "../assets/footer/twitter.svg";
import lizard from "../assets/footer/MKLizard.png";
import lizard from "../assets/footer/footer_logo.png";
import nsf from "../assets/footer/NSF.png";
import pss from "../assets/footer/Performant_Logo.svg";
import { Image } from "astro:assets";
Expand All @@ -17,7 +17,7 @@ import { Image } from "astro:assets";
<p class="text-5xl font-serif self-center">EditionCrafter</p>
</div>
<p class="text-center">
Developed by the Making and Knowing Project at the Center for Science and Society at Columbia University and Performant Software Solutions LLC. Funded by a grant from the National Science Foundation.
Developed by the Making and Knowing Project at the Center for Science and Society at Columbia University and Performant Software Solutions LLC. Funded by Grant SES-2218218 from the National Science Foundation.
</p>
<div class="flex flex-row justify-center gap-4 object-contain">
<a href="https://www.makingandknowing.org/">
Expand Down
8 changes: 4 additions & 4 deletions astro-web/src/pages/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ import elygreen from '../assets/projects/thumbnails/elygreen.png';
<Hero>
<div class="flex flex-col gap-y-6">
<h1 class="font-serif text-5xl">
A simple digital critical edition publication tool
A simple digital edition publication tool
</h1>
<p class="text-neutral-gray">
EditionCrafter is an easy-to-use tool for scholars, educators, and research institutions to publish digital critical editions in a low-cost and sustainable manner.
EditionCrafter is an easy-to-use tool for scholars, educators, and research institutions to publish digital editions in a low-cost and sustainable manner.
</p>
<div class="flex flex-row w-full justify-between">
<Button href="/editioncrafter/getting-started">
Expand All @@ -43,15 +43,15 @@ import elygreen from '../assets/projects/thumbnails/elygreen.png';
About EditionCrafter
</h2>
<p class="text-2xl">
An open source and customizable publishing tool, EditionCrafter allows users to easily publish digital critical editions as feature-rich and sustainable static sites.
An open source and customizable publishing tool, EditionCrafter allows users to easily publish digital editions as feature-rich and sustainable static sites.
</p>
<div class="md:flex gap-12 text-neutral-gray">
<div class="md:w-1/2 flex flex-col gap-y-6">
<p>
EditionCrafter was developed as a collaboration between the Making and Knowing Project and Performant Software Solutions to address the need for a scholarly publication tool that integrates primary sources, commentary, and textual analysis.
</p>
<p>
As a publication tool, EditionCrafter facilitates the dissemination of original research through the creation of a digital critical edition of a text. Researchers, students, and institutions such as libraries, historical societies, archives, and community groups can grant public access to valuable textual sources across disciplines.
As a publication tool, EditionCrafter facilitates the dissemination of original research through the creation of a digital edition of a text. Researchers, students, and institutions such as libraries, historical societies, archives, and community groups can grant public access to valuable textual sources across disciplines.
</p>
</div>
<div class="md:w-1/2 flex flex-col gap-y-6">
Expand Down
2 changes: 1 addition & 1 deletion editioncrafter-umd/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cu-mkp/editioncrafter-umd",
"version": "1.0.1",
"version": "1.0.3",
"homepage": "https://cu-mkp.github.io/editioncrafter/",
"description": "A simple digital critical edition publication tool",
"private": false,
Expand Down
27 changes: 12 additions & 15 deletions editioncrafter/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions editioncrafter/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@cu-mkp/editioncrafter",
"version": "1.0.1",
"version": "1.0.3",
"description": "A simple digital critical edition publication tool",
"homepage": "https://cu-mkp.github.io/editioncrafter/",
"private": false,
Expand All @@ -27,7 +27,6 @@
"@material-ui/core": "^4.12.4",
"@material-ui/icons": "^4.11.3",
"@recogito/annotorious-openseadragon": "^2.7.11",
"axios": "^1.3.4",
"history": "^5.3.0",
"html-react-parser": "^4.2.2",
"openseadragon": "^4.1.0",
Expand Down
26 changes: 17 additions & 9 deletions editioncrafter/src/component/DocumentView.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,11 @@ const DocumentView = (props) => {
const navigate = useNavigate();
const location = useLocation();

//"reload" the page if the config props change
useEffect(() => {
dispatchAction(props, 'RouteListenerSaga.userNavigatation', location);
}, [props.config]);

useEffect(() => {
setSinglePaneMode(props.containerWidth < 960);
}, [props.containerWidth]);
Expand Down Expand Up @@ -62,19 +67,21 @@ const DocumentView = (props) => {
}
};
}

const leftFolioID = folioID;
const leftFolioValid = Object.keys(document.folioIndex).includes(folioID);
const leftFolioID = leftFolioValid ? folioID : '-1';
let leftTranscriptionType; let rightFolioID; let
rightTranscriptionType; let thirdFolioID; let thirdTranscriptionType;
if (folioID2) {
// route /ec/:folioID/:transcriptionType/:folioID2/:transcriptionType2
leftTranscriptionType = transcriptionType;
rightFolioID = folioID2;
rightTranscriptionType = transcriptionType2 || firstTranscriptionType;
const rightFolioValid = Object.keys(document.folioIndex).includes(folioID2);
leftTranscriptionType = leftFolioValid ? transcriptionType : 'g';
rightFolioID = rightFolioValid ? folioID2 : '-1';
rightTranscriptionType = rightFolioValid ? transcriptionType2 ? transcriptionType2 : firstTranscriptionType : 'g';
if (folioID3) {
// route /ec/:folioID/:transcriptionType/:folioID2/:transcriptionType2/:folioID3/:transcriptionType3
thirdFolioID = folioID3;
thirdTranscriptionType = transcriptionType3 || firstTranscriptionType;
const thirdFolioValid = Object.keys(document.folioIndex).includes(folioID3);
thirdFolioID = thirdFolioValid ? folioID3 : '-1';
thirdTranscriptionType = thirdFolioValid ? transcriptionType3 ? transcriptionType3 : firstTranscriptionType : 'g';
} else {
thirdFolioID = '-1';
thirdTranscriptionType = 'g';
Expand All @@ -83,8 +90,8 @@ const DocumentView = (props) => {
// route /ec/:folioID
// route /ec/:folioID/:transcriptionType
leftTranscriptionType = 'f';
rightFolioID = folioID;
rightTranscriptionType = transcriptionType || firstTranscriptionType;
rightFolioID = leftFolioValid ? folioID : '-1';
rightTranscriptionType = leftFolioValid ? transcriptionType ? transcriptionType : firstTranscriptionType : 'g';
thirdFolioID = '-1';
thirdTranscriptionType = 'g';
}
Expand Down Expand Up @@ -504,6 +511,7 @@ const DocumentView = (props) => {
function mapStateToProps(state) {
return {
document: state.document,
glossary: state.glossary
};
}

Expand Down
Loading

0 comments on commit 322d10c

Please sign in to comment.