diff --git a/components/PointSummaries.js b/components/PointSummaries.js index 76adbdb5..3fd3cee9 100644 --- a/components/PointSummaries.js +++ b/components/PointSummaries.js @@ -315,9 +315,9 @@ class PointSummaries extends React.Component { Milestone {tier} )} - {/* Level numbers */} + {/* Level numbers up to 15 */} - {Object.entries(pointsToLevels).map((points, level) => + {Object.entries(pointsToLevels).slice(0, 15).map((points, level) => {level + 1} )} diff --git a/components/SnowflakeApp.js b/components/SnowflakeApp.js index 7b9a8b17..5f5b3716 100644 --- a/components/SnowflakeApp.js +++ b/components/SnowflakeApp.js @@ -18,6 +18,7 @@ import LevelSelector from '../components/LevelSelector' type SnowflakeAppState = { milestoneByTrack: MilestoneMap, name: string, + evaluator: string, title: string, level: number, focusedTrackId: TrackId, @@ -34,7 +35,7 @@ const hashToState = (hash: String): ?SnowflakeAppState => { if (hashValues[13]) result.level = decodeURI(hashValues[13]) if (hashValues[14]) result.name = decodeURI(hashValues[14]) if (hashValues[15]) result.cohort = decodeURI(hashValues[15]) - //if (hashValues[16]) result.title = decodeURI(hashValues[16]) + if (hashValues[16]) result.evaluator = decodeURI(hashValues[16]) return result } @@ -54,6 +55,7 @@ const coerceMilestone = (value: number): Milestone => { const emptyState = (): SnowflakeAppState => { return { name: '', + evaluator: '', cohort: '', title: '', level: 0, @@ -73,13 +75,14 @@ const emptyState = (): SnowflakeAppState => { 'BIZDEV': 0, }, focusedTrackId: 'HEADER_ONE', - version: "2.0.4" + version: "2.0.5" } } const defaultState = (): SnowflakeAppState => { return { name: 'Palantiri Name', + evaluator: 'Evaluator Name/Team', cohort: 'Project Management', title: 'Project Manager, III', level: 1, @@ -104,7 +107,7 @@ const defaultState = (): SnowflakeAppState => { const stateToHash = (state: SnowflakeAppState) => { if (!state || !state.milestoneByTrack) return null - const values = trackIds.map(trackId => state.milestoneByTrack[trackId]).concat(encodeURI(state.level), encodeURI(state.name), encodeURI(state.cohort)) + const values = trackIds.map(trackId => state.milestoneByTrack[trackId]).concat(encodeURI(state.level), encodeURI(state.name), encodeURI(state.cohort), encodeURI(state.evaluator)) return values.join(',') } @@ -176,7 +179,17 @@ class SnowflakeApp extends React.Component { margin-right: 50px; padding: .25em .125em; } - .name-input:hover, .name-input:focus, .name-input:active { + .evaluator-input { + border: 0; + background: transparent; + display: inline-block; + margin-right: 10px; + color: #fff; + font-size: 16px; + line-height: 20px; + padding: 1em .125em; + } + .name-input:hover, .name-input:focus, .name-input:active, .evaluator-input:hover, .evaluator-input:focus, .evaluator-input:active { border-color: #11a9a1; background-color: rgba(17, 169, 161, .125); outline: 0; @@ -201,6 +214,12 @@ class SnowflakeApp extends React.Component { background-color: rgba(17, 169, 161, .125); cursor: pointer; } + .input-wrapper { + display: inline-block; + height: 3em; + border-bottom: 2px solid #7e97a0; + margin-right: 10px; + } a { color: #109C95; text-decoration: none; @@ -249,6 +268,18 @@ class SnowflakeApp extends React.Component { onChange={e => this.setState({name: e.target.value})} placeholder="Name" /> +
+ + + this.setState({evaluator: e.target.value})} + placeholder="Evaluator" + /> + +
@@ -365,6 +396,10 @@ class SnowflakeApp extends React.Component { this.setState({ title }) } + setEvaluator(evaluator: string) { + this.setState({ evaluator }) + } + setLevel(level: number) { this.setState({ level }) } diff --git a/constants.js b/constants.js index e719ac0c..33a1b8bf 100644 --- a/constants.js +++ b/constants.js @@ -93,7 +93,7 @@ export const pointsToLevels = { '300': '13', '330': '14', '360': '15', - '10000' : '16', + '500': '16', } export const maxLevel = 360