Skip to content

Commit

Permalink
Merge pull request #532 from NASA-IMPACT/develop
Browse files Browse the repository at this point in the history
Prod deployment
  • Loading branch information
sunu authored Aug 3, 2023
2 parents 3e2f39b + 22d4483 commit 2d30968
Show file tree
Hide file tree
Showing 5 changed files with 128 additions and 62 deletions.
159 changes: 108 additions & 51 deletions app/assets/scripts/components/about/index.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React from 'react';
import styled from 'styled-components';

import App from '../common/app';
import {
Expand All @@ -12,6 +13,14 @@ import { ContentBlock } from '../../styles/content-block';
import Prose from '../../styles/typography/prose';
import { Link } from '../../styles/clean/link';

const DisclosureHeader = styled.h3`
display: inline;
`;

const DisclosureContent = styled.p`
padding: 1rem 0rem 0rem 0rem;
`;

function About() {
return (
<App pageTitle='About'>
Expand All @@ -27,10 +36,10 @@ function About() {
<h1>The Algorithm Publication Tool (APT)</h1>
<p>
APT is a prototype environment for use in writing, submitting,
and discovering Algorithm Theoretical Basis Documents (ATBDs).
The tool has been designed to make it easier to create and edit
new ATBDs for which all content is searchable. We welcome your
feedback.
discovering and accessing Algorithm Theoretical Basis Documents
(ATBDs). The tool has been designed to make it easier to create
and edit new ATBDs and discover ATBDs from within APT&apos;s
centralized repository.
</p>

<p>
Expand All @@ -46,65 +55,113 @@ function About() {
<a
href='https://developmentseed.org/'
rel='noopener'
title='Visit Development Seed webpage'
title='Visit the Development Seed webpage'
>
Development Seed
</a>
. Please use the <FeedbackLink>feedback form</FeedbackLink> to
send us your questions, thoughts, and comments.
send us your questions, thoughts, and comments. We welcome
feedback from all users!
</p>

<h2>FAQs</h2>
<h3>What is the APT?</h3>
<p>
APT is an authoring tool that streamlines the writing,
publishing and maintenance process of ATBDs for NASA’s Earth
Science Division. APT is also a centralized repository of
submitted ATBDs for Earth Science users. Researchers and
scientists are required to use the tool to standardize ATBD
content and make it searchable for all interested data users.
</p>
<h3>Why should I use the APT?</h3>
<p>
If you are looking for an algorithm description, this is where
you will find publicly available ATBDs. The general public can
view all completed ATBDs without a user account and download
PDFs of the ATBDs. Historical ATBDs are not available at this
time.
</p>
<p>
If you are a researcher responsible for producing an ATBD, this
tool is used to write and submit your algorithm description so
that it can be located by others. APT has been designed to aid
with submitting your ATBD to a journal.
</p>
<h3>Can the public use the APT?</h3>
<p>
The public can freely view and download any completed ATBD as
HTML or PDF. No user account is needed. Only users required to
author or review an ATBD can obtain an authorized user account.
</p>
<h3>How does the APT work?</h3>
<p>
APT uses a standardized ATBD template that sets content
expectations for ATBDs and improves communication. A review
process is used to ensure all content quality. ATBD content is
stored as metadata making it completely machine readable,
searchable, and useful in other tools and services.
The available processes for ATBD creation are described on the{' '}
<a
href='/new-atbd'
rel='noopener'
title='Create a new ATBD page'
>
Create a new ATBD page
</a>
. Authors and collaborators have a choice to construct an ATBD
either using the APT authoring environment or using Google Docs,
Microsoft Word, or LaTeX templates. The process is slightly
different for each method.
</p>

<h2>FAQs</h2>
<details open>
<summary>
<DisclosureHeader>What is the APT?</DisclosureHeader>
</summary>
<DisclosureContent>
APT is an authoring tool that streamlines the writing,
publishing and maintenance process of ATBDs for NASA&apos;s
Earth Science Division. APT is also a centralized repository
of completed and submitted ATBDs for Earth Science users.
Researchers and scientists are required to use the tool or
templates to ensure creation of standardized ATBD content and
to provide searchable documents for all interested data and
algorithm users.
</DisclosureContent>
</details>
<details>
<summary>
<DisclosureHeader>Why should I use the APT?</DisclosureHeader>
</summary>
<DisclosureContent>
If you are looking for an algorithm description, this is where
you will find publicly available ATBDs for NASA&apos;s Earth
Science Division. The general public can view and download all
completed ATBDs without a user account. Historical ATBDs are
not available at this time but will be added over time once
the interface is adapted to receive the documents. All APT
ATBDs have a DOI that can be used as metadata in data products
pertaining to the algorithm.
</DisclosureContent>
<DisclosureContent>
If you are a researcher responsible for producing an ATBD,
this tool is used to write and submit your algorithm
description so that it can be located by others. The APT
environment has been designed to aid with creating and
submitting your ATBD to a journal, if you choose. Use of the
APT templates for document creation ensures content is
standardized to improve discoverability and automated document
use.
</DisclosureContent>
</details>
<details>
<summary>
<DisclosureHeader>
Can the public use the APT?
</DisclosureHeader>
</summary>
<DisclosureContent>
The public can freely view and download any completed ATBD as
a PDF file. No user account is needed. Only users required to
author, submit or review an ATBD can obtain an authorized user
account.
</DisclosureContent>
</details>
<details>
<summary>
<DisclosureHeader>How does the APT work?</DisclosureHeader>
</summary>
<DisclosureContent>
APT uses a standardized ATBD template that sets content
expectations for ATBDs and improves communication and
completed document discoverability. A review process is used
to ensure that all content meets quality requirements. Within
the APT authoring environment, all ATBD content is stored as
metadata making it completely machine readable, searchable,
and useful in other tools and services.
</DisclosureContent>
<DisclosureContent>
If an author chooses to use APT templates for ATBD creation,
only the completed and approved PDF is submitted to APT. From
the APT environment, authors will provide needed metadata
about the document to ensure discovery of the document.
</DisclosureContent>
</details>
<p>
For more detailed information about APT, please visit the{' '}
<Link to='/user-guide'>
User Guide for Authoring ATBDs using the Algorithm Publication
Tool (APT)
</Link>
.
For more detailed information about APT, check out the{' '}
<Link to='/user-guide'>User Guide </Link>
with the Algorithm Publication Tool (APT) .
</p>

<p>
If you have questions, please submit them through the{' '}
<FeedbackLink>feedback form</FeedbackLink>.
If you have questions, please use the{' '}
<FeedbackLink>feedback form </FeedbackLink>
to communicate with the APT Curator.
</p>
</Prose>
</ContentBlock>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,9 @@ export default function DocumentDownloadMenu(props) {
const result = await response.json();

saveAs(result.pdf_url, pdfFileName);
processToast.success('PDF downloaded successfully!');
processToast.success(
'PDF downloaded successfully! If the PDF did not open automatically, your browser may have blocked the download. Please make sure that popups are allowed on this site.'
);
return;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ export default function ReferencesManager(props) {
<FieldArray
name='document.publication_references'
render={(arrayHelpers) => {
const { remove, push, form, name } = arrayHelpers;
const { remove, push, form, name, move } = arrayHelpers;
const values = get(form.values, name);

// Update the refs list. See note above
Expand Down Expand Up @@ -172,6 +172,9 @@ export default function ReferencesManager(props) {
{ meta: e.metaKey || e.ctrlKey, shift: e.shiftKey }
);
setRefsEditing(newSelection);

// This is a hack to force the field to re-render
move(index, index);
}}
onDeleteClick={async () => {
// If the reference is in use prompt the user for
Expand Down Expand Up @@ -205,6 +208,9 @@ export default function ReferencesManager(props) {
{ meta: true, shift: e.shiftKey }
);
setRefsSelected(newSelection);

// This is a hack to force the field to re-render
move(index, index);
}}
/>
))}
Expand Down
17 changes: 9 additions & 8 deletions app/assets/scripts/components/home/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -232,9 +232,10 @@ function Home() {
</FocusBoxTitle>
<div>
Easily create compliant and complete ATBDs using a
standardized template. The APT&apos;s centralized
location makes it simple to collaborate with the writing
team.
standardized template. Choose whether to create ATBDs
within the APT user interface or use familiar software
and word processors to create ATBDs using one of
APT&apos;s provided standardized templates.
</div>
</FocusBox>
</li>
Expand All @@ -246,8 +247,8 @@ function Home() {
</FocusBoxTitle>
<div>
Easily format text and add equations, tables, figures
and references using the APT&apos;s rich text editor,
LaTex tools and Bibtex citation manager.
and references using APT&apos;s rich text editor, LaTeX
tools and BibTeX citation manager.
</div>
</FocusBox>
</li>
Expand All @@ -268,9 +269,9 @@ function Home() {
Straightforward journal submission
</FocusBoxTitle>
<div>
Use a streamlined ATBD journal submission process with
AGU&apos;s Earth and Space Science, a gold open access
journal.
APT has a partnership with AGU&apos;s Earth and Space
Science, a gold open access journal, to simplify the
journal submission process of ATBDs.
</div>
</FocusBox>
</li>
Expand Down
2 changes: 1 addition & 1 deletion app/assets/scripts/utils/references.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ export const formatReference = (reference, type = 'jsx') => {
if (type === 'jsx') {
return (
<span>
{authorsStr} {yearStr} <em>{titleStr}</em> <em> {seriesStr} </em>{' '}
{authorsStr} {yearStr} {titleStr} <em> {seriesStr} </em>{' '}
<em> {volIssueStr}</em> {pagesStr} {doiStr}
</span>
);
Expand Down

0 comments on commit 2d30968

Please sign in to comment.