@adactive/adsum-wayfindingcontrols-asia
Advanced tools
Comparing version 2.6.1 to 2.6.2
{ | ||
"name": "@adactive/adsum-wayfindingcontrols-asia", | ||
"version": "2.6.1", | ||
"version": "2.6.2", | ||
"description": "Adsum Way Finding Controls Component", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -140,3 +140,5 @@ // @flow | ||
&& wayfindingState.currentSectionIndex === (pathSection.length - 1)) { | ||
this.addArrivalLabel(finalLabelText, pathSection); | ||
if (wayFindingControlsState.isArrivedLabel) { | ||
this.addArrivalLabel(finalLabelText, pathSection); | ||
} | ||
@@ -169,4 +171,5 @@ // If it is Interchange Label(s) | ||
const changeFloorLabelText = `${icLabelText + icDestinationFloorPosition + icDestinationFloor.replace('_', ' ')} `; | ||
this.addInterchangeLabel(changeFloorLabelText, pathSection); | ||
if (wayFindingControlsState.isInterchangeLabel) { | ||
this.addInterchangeLabel(changeFloorLabelText, pathSection); | ||
} | ||
} | ||
@@ -173,0 +176,0 @@ } |
@@ -13,3 +13,5 @@ // @flow | ||
export const ARRIVED_LABEL = 'ARRIVED_LABEL'; | ||
export const ARRIVED_LABEL_VISIBILITY = 'ARRIVED_LABEL_VISIBILITY'; | ||
export const INTERCHANGE_LABEL = 'INTERCHANGE_LABEL'; | ||
export const INTERCHANGE_LABEL_VISIBILITY = 'INTERCHANGE_LABEL_VISIBILITY'; | ||
export const RESET_ARRIVAL_LABEL = 'RESET_ARRIVAL_LABEL'; | ||
@@ -75,2 +77,11 @@ export const RESET_INTERCHANGE_LABEL = 'RESET_INTERCHANGE_LABEL'; | ||
export function showArrivedLabel(value) { | ||
return (dispatch) => { | ||
dispatch({ | ||
type: ARRIVED_LABEL_VISIBILITY, | ||
payload: value | ||
}); | ||
}; | ||
} | ||
export function interchangeLabel(label) { | ||
@@ -85,2 +96,11 @@ return (dispatch) => { | ||
export function showInterchangeLabel(value) { | ||
return (dispatch) => { | ||
dispatch({ | ||
type: INTERCHANGE_LABEL_VISIBILITY, | ||
payload: value | ||
}); | ||
}; | ||
} | ||
export function resetArrivalLabel(value) { | ||
@@ -87,0 +107,0 @@ return (dispatch) => { |
@@ -9,6 +9,8 @@ // @flow | ||
ARRIVED_LABEL, | ||
ARRIVED_LABEL_VISIBILITY, | ||
INTERCHANGE_LABEL, | ||
INTERCHANGE_LABEL_VISIBILITY, | ||
RESET_ARRIVAL_LABEL, | ||
RESET_INTERCHANGE_LABEL, | ||
RESET_MAP_AND_WAY_FINDING | ||
RESET_MAP_AND_WAY_FINDING, | ||
} from './WayFindingControlsActions'; | ||
@@ -21,2 +23,4 @@ | ||
placeDestination: null, | ||
isArrivedLabel: true, | ||
isInterchangeLabel: true, | ||
arrivedLabel: [], | ||
@@ -54,2 +58,6 @@ interchangeLabel: [], | ||
}); | ||
case ARRIVED_LABEL_VISIBILITY: | ||
return Object.assign({}, state, { | ||
isArrivedLabel: action.payload | ||
}); | ||
case INTERCHANGE_LABEL: | ||
@@ -59,2 +67,6 @@ return Object.assign({}, state, { | ||
}); | ||
case INTERCHANGE_LABEL_VISIBILITY: | ||
return Object.assign({}, state, { | ||
isInterchangeLabel: action.payload | ||
}); | ||
case RESET_INTERCHANGE_LABEL: | ||
@@ -61,0 +73,0 @@ return Object.assign({}, state, { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
27664
562