Giter Site home page Giter Site logo

consbio / salcc_blueprint2 Goto Github PK

View Code? Open in Web Editor NEW
0.0 0.0 1.0 21.36 MB

South Atlantic Conservation Blueprint 2.2 Simple Viewer

Home Page: https://blueprint.southatlanticlcc.org/

License: MIT License

HTML 1.74% JavaScript 64.01% CSS 7.37% Python 26.88%

salcc_blueprint2's People

Contributors

anisimon avatar brendan-ward avatar estishay avatar

Watchers

 avatar  avatar  avatar

Forkers

astutespruce

salcc_blueprint2's Issues

Create pixel-level identify

Provide a specific mode for doing pixel level identify, and show crosshairs in middle of screen (possibly with magnifier).

  • use data tiling packed data approach (other issues)
  • update sidebar with only pixel level content, update a user pans or zooms

Implement first draft of report functionality

Minimum requirements:

Given an ID to a reporting unit:

  • fetch the correct JSON file from disk
  • render that into the template (mostly tables)

Map and charts will be handled in separate issues.

Fix blueprint justification

SALCC staff pointed out that the Blueprint 1.0 text doesn't match latest updates. Check that through the stack.

Search widget bugs

  • Search does not take into account clearing out input field by hitting backspace with keyboard.
  • Search also breaks when a unit is selected and the user tries to search.
  • Need to make sure that enter after typing triggers a full search, not autosuggest.

Fix PWA behavior

Need to get service worker and other PWA related functionality working again

Change SALCC to South Atlantic

For the credits: instead just say “South Atlantic Blueprint” (fix the broken link)
For citation: “The South Atlantic Blueprint Version 2.2 (2017)”

Add "high" and "low" labels to indicator tables

Per direction from SALCC, add a column on the left side of the indicator tables. This will have no column header.

the first (when sorted from highest value) row will have a value of (high) in this column, and the last row will have (low).

Add polyfills

Should be able to add from a babel plugin.

Also - test heavily on IE11

Migrate icons to Material design icons

Create draft report template

Leave all maps & images as TODOs.

The template will include boilerplate and links from SALCC.

Sections:

Priority

  • map (TODO)
  • priority categories (boilerplate)
  • priority chart (TODO)
  • priority table with caption. Table will include acres in each category and percent of summary unit (100 * acres / total acres of summary unit)

Indicators

Ecosystem specific indicators

  • Ecosystem chart (TODO)
  • Ecosystem table with caption
  • list of ecosystems (below)

Ecosystem

  • Ecosystem name and percent of summary unit (format: heading)
  • list of indicators in this ecosystem (below)
Indicator
  • Indicator name (format: italic gray text)
  • Indicator description
  • Indicator chart and caption (TODO)
  • Indicator table and caption

Threats

TODO: data is not yet prepared

Partners

Partner type (Regional Conservation Plans, Statewide Conservation Plans, Land Trusts)

  • list of plans (links)

Ownership

Conserved lands ownership

  • Ownership chart (TODO)
  • Ownership table and caption

Land protection status

  • protection chart
  • protection table and caption

Prevent tables from flowing across page break

Tables run across page breaks. It's possible to prevent this within MS Word by checking the "Keep with next" box in the Paragraph window, but setting that within document creation is still a mystery.

Incorporate threats data

Amy @ SALCC provided new threats data and direction on use of line charts for displaying these.

Text where ecosystem has no indicators

Decision needed: How should we indicate that a ecosystem has no indicators listed? Just listing the name and the % of area then moving on to the next ecosystem name (a heading of the same level) looks like something is missing/went wrong.

Currently I'm appending (No indicators for this ecosystem.) after the ecosystem name and %.

Add rows to indicator tables for "good" conditions

Some (but not all) indicators have a "good" condition threshold.

This is stored in the goodCondition key in the config/ecosystems.json file on master. This refers to the value of that indicator that is in good condition: any indicator values >= this value are considered in good condition.

See table on page 6 of the example report from SALCC for an example of how they'd like this used. We don't have to exactly replicate the styling of the "total in good condition" "total not in good condition" rows, but we need to add those rows to the table and style them so they stand out.

You will have to calculate the total in good condition and the total not in good condition.

I handled it this way in the frontend:

    const hasGoodThreshold = goodThreshold !== null
    let goodPercents = null
    let notGoodPercents = null
    let totalGoodPercent = 0
    let totalNotGoodPercent = 0
    if (hasGoodThreshold) {
        goodPercents = percents.filter(p => p.value >= goodThreshold)
        notGoodPercents = percents.filter(p => p.value < goodThreshold)
        totalGoodPercent = goodPercents.reduce((total, p) => total + p.percent, 0)
        totalNotGoodPercent = notGoodPercents.reduce((total, p) => total + p.percent, 0)
    }

Note: in this case, percents is an array of objects with a value, label, and description. You'll have to adapt to your particular data.
You only need to add these to the table if the goodThreshold key is present for an indicator.

Add eslintrc from ERST

Will requiring ejecting from create-react-app. Test this in a dedicated commit to make rollback easier.

Cleanup handling of setting the active tab

Adding in the Map tab for use in mobile means that we are doing some wonky things throughout the application, and this makes it harder to trace.

Ultimately, we need to find a better way of accessing info about isMobile from the main reducer. Either we leverage redux-thunk to do so: https://stackoverflow.com/questions/42239302/accessing-a-part-of-reducer-state-from-one-reducer-within-another-reducer

Or we better consolidate information about where we are bringing that tab in at all.

Apply mobile design to desktop version

Remaining tasks:

  • Make font 16px
  • make basemaps icon larger
  • bring back zoom controls on desktop version
  • add conditional rendering based on width. Store width in app as state, bind to browser resize.
  • add over or click interaction to indicators view
  • restructure ecosystems into scrollable list on desktop
  • add barcharts for ecosystems when on desktop?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.