-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
818: update language for acs tooltips (remove puma references) and in…
…dicators methodology
- Loading branch information
1 parent
32f96a7
commit 41bc531
Showing
8 changed files
with
36 additions
and
59 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { helper } from '@ember/component/helper'; | ||
import { tooltipText } from '../tooltips/tooltip-text'; | ||
|
||
export function buildTooltip(data) { | ||
const { | ||
cd_short_title, | ||
} = data[0]; | ||
|
||
const communityDistrictTooltip = tooltipText.acs.communityDistrict(cd_short_title); | ||
|
||
return communityDistrictTooltip; | ||
} | ||
|
||
export default helper(buildTooltip); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 3 additions & 6 deletions
9
...ation/helpers/acs-puma-cd-tooltip-test.js → ...ntegration/helpers/acs-cd-tooltip-test.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,18 @@ | ||
|
||
import { moduleForComponent, test } from 'ember-qunit'; | ||
import { buildTooltip } from '../../../helpers/acs-puma-cd-tooltip'; | ||
import { buildTooltip } from '../../../helpers/acs-cd-tooltip'; | ||
|
||
moduleForComponent('acs-puma-cd-tooltip', 'helper:acs-puma-cd-tooltip', { | ||
moduleForComponent('acs-cd-tooltip', 'helper:acs-cd-tooltip', { | ||
integration: true, | ||
}); | ||
|
||
// Replace this with your real tests. | ||
test('returns tooltip correctly', function(assert) { | ||
const data = [{ | ||
puma: 444, | ||
cd_short_title: 'Manhattan CD 2', | ||
shared_puma: true, | ||
shared_puma_cd: 'Manhattan CD 3', | ||
}]; | ||
|
||
const tooltip = buildTooltip(data); | ||
|
||
assert.equal(tooltip, 'American Community Survey 2014-2018 5-Year Estimates for PUMA 444, which is an approximation of both Manhattan CD 2 and Manhattan CD 3.'); | ||
assert.equal(tooltip, 'American Community Survey 2014-2018 5-Year Estimates for Manhattan CD 2, approximated by aggregating data from blocks and block-groups.'); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters