Skip to content

Commit

Permalink
Merge pull request #1033 from colouring-cities/feature/new-categories…
Browse files Browse the repository at this point in the history
…-menu

Feature/new categories menu (+ other fixes)
  • Loading branch information
mdsimpson42 authored Jan 18, 2023
2 parents ba869fe + 3aa2bd5 commit 8c9dab3
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 45 deletions.
62 changes: 20 additions & 42 deletions app/src/frontend/building/data-containers/age.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,9 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
/>
</DataEntryGroup>
<DataEntryGroup name="Lifespan and Site History" collapsed={true} >
<button className="map-switcher-inline btn btn-outline btn-outline-dark" onClick={historicDataSwitchOnClick}>
{(historicData === 'enabled')?'Click here to hide historical maps':'Click here to show historical maps'}
</button>
<DataEntryGroup collapsed={false} name="Constructions and demolitions on this site" showCount={false}>
<DynamicsBuildingPane>
<label>Current building (age data <Link to={ageLinkUrl}>editable here</Link>)</label>
Expand Down Expand Up @@ -216,26 +219,6 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
</>
}
</DataEntryGroup>
<DataEntryGroup name="Future planned data collection" collapsed={false} showCount={false}>
<DataEntry
title="Historical land use change"
slug=""
value=""
mode='view'
/>
<DataEntry
title="Longitudinal historical footprints (raster) link"
slug=""
value=""
mode='view'
/>
<DataEntry
title="Longitudinal historical footprints (vector) link"
slug=""
value=""
mode='view'
/>
</DataEntryGroup>
<InfoBox>
This section is under development in collaboration with the historic environment sector.
Please let us know your suggestions on the <a href="https://discuss.colouring.london/t/dynamics-category-discussion/107">discussion forum</a>! (external link - save your edits first)
Expand All @@ -245,8 +228,8 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
<InfoBox>
This section is under development.
</InfoBox>
<button className="map-switcher-inline btn btn-outline btn-outline-dark" /*onClick={}*/>
{'Click here for historical maps'}
<button className="map-switcher-inline btn btn-outline btn-outline-dark" onClick={historicDataSwitchOnClick}>
{(historicData === 'enabled')?'Click here to hide historical maps':'Click here to show historical maps'}
</button>
<SelectDataEntry
title={dataFields.historical_status.title}
Expand All @@ -258,6 +241,12 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
copy={props.copy}
onChange={props.onChange}
/>
<DataEntry
title="Historical land use change"
slug=""
value=""
mode='view'
/>
</DataEntryGroup>
</Fragment>
);
Expand Down Expand Up @@ -415,6 +404,9 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
/>
</DataEntryGroup>
<DataEntryGroup name="Lifespan and Site History" collapsed={true} >
<button className="map-switcher-inline btn btn-outline btn-outline-dark" onClick={historicDataSwitchOnClick}>
{(historicData === 'enabled')?'Click here to hide historical maps':'Click here to show historical maps'}
</button>
<DataEntryGroup collapsed={false} name="Constructions and demolitions on this site" showCount={false}>
<DynamicsBuildingPane>
<label>Current building (age data <Link to={ageLinkUrl}>editable here</Link>)</label>
Expand Down Expand Up @@ -496,26 +488,6 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
</>
}
</DataEntryGroup>
<DataEntryGroup name="Future planned data collection" collapsed={false} showCount={false}>
<DataEntry
title="Historical land use change"
slug=""
value=""
mode='view'
/>
<DataEntry
title="Longitudinal historical footprints (raster) link"
slug=""
value=""
mode='view'
/>
<DataEntry
title="Longitudinal historical footprints (vector) link"
slug=""
value=""
mode='view'
/>
</DataEntryGroup>
<InfoBox>
This section is under development in collaboration with the historic environment sector.
Please let us know your suggestions on the <a href="https://discuss.colouring.london/t/dynamics-category-discussion/107">discussion forum</a>! (external link - save your edits first)
Expand All @@ -538,6 +510,12 @@ const AgeView: React.FunctionComponent<CategoryViewProps> = (props) => {
copy={props.copy}
onChange={props.onChange}
/>
<DataEntry
title="Historical land use change"
slug=""
value=""
mode='view'
/>
</DataEntryGroup>
</Fragment>
);
Expand Down
2 changes: 1 addition & 1 deletion app/src/frontend/building/data-containers/planning.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ const PlanningView: React.FunctionComponent<CategoryViewProps> = (props) => {
<DataEntryGroup name="Active application info (crowdsourced)" collapsed={true} >
{/* will be titled "Other active application info (crowdsourced data)" once active" */}
<InfoBox type='warning'>
This category is not yet activated.
This category is not yet activated - Until this section is activated please report inaccuracies or problems on the <a href=" https://github.com/colouring-cities/colouring-london/discussions/categories/planning-section-comments">Discussion Forum</a>.
</InfoBox>
{/* that is placeholder display, will be replaced by actual code */}
<div className="data-title">
Expand Down
10 changes: 8 additions & 2 deletions app/src/frontend/header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,17 @@ function getCurrentMenuLinks(username: string): MenuLink[][] {
text: "Access open code",
external: true
},
{
to: "https://github.com/colouring-cities/manual/wiki",
text: "Colouring Cities Open Manual/Wiki",
disabled: false,
external: true
},
{
to: "/showcase.html",
text: "View Data Showcase",
text: "Case Study Showcase",
disabled: true,
note: "Coming soon"
note: "Not Yet Activated"
},
],
[
Expand Down

0 comments on commit 8c9dab3

Please sign in to comment.