@flarehr/apollo-super-selection 5.24.54264 → 5.25.54575
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/apollo-super-selection/apollo-super-selection.css +1 -1
- package/dist/lib/apollo-super-selection/apollo-super-selection.esm.js +1 -1
- package/dist/lib/apollo-super-selection/p-64e00db6.entry.js +14 -0
- package/dist/lib/apollo-super-selection/p-bdcfc026.system.js +1 -1
- package/dist/lib/apollo-super-selection/p-cf19c194.system.entry.js +69 -0
- package/dist/lib/cjs/apollo-super-selection.cjs.js +1 -1
- package/dist/lib/cjs/loader.cjs.js +1 -1
- package/dist/lib/cjs/{sss-button_43.cjs.entry.js → sss-button_31.cjs.entry.js} +947 -2250
- package/dist/lib/collection/apollo-super-selection.css +1 -1
- package/dist/lib/collection/collection-manifest.json +1 -25
- package/dist/lib/collection/components/super-campaign/super-campaign.js +8 -16
- package/dist/lib/collection/components/super-selection-app/api/super-selection.api.dto.js +26 -25
- package/dist/lib/collection/components/super-selection-app/api/super-selection.api.js +0 -9
- package/dist/lib/collection/components/super-selection-app/existing-choice/existing-choice.js +5 -9
- package/dist/lib/collection/components/super-selection-app/footer-section/footer-section.js +9 -13
- package/dist/lib/collection/components/super-selection-app/funds/slate-super/api/slate.js +4 -0
- package/dist/lib/collection/components/super-selection-app/prefill-fund/prefill-invalid-my-own-fund.js +3 -3
- package/dist/lib/collection/components/super-selection-app/prefill-fund/prefill-invalid-smsf.js +2 -2
- package/dist/lib/collection/components/super-selection-app/prefill-fund/prefill-my-own-fund.js +3 -3
- package/dist/lib/collection/components/super-selection-app/prefill-fund/prefill-smsf.js +3 -3
- package/dist/lib/collection/components/super-selection-app/prefill-fund/prefill.js +1 -1
- package/dist/lib/collection/components/super-selection-app/services/existing-super-choice-info.service.js +4 -16
- package/dist/lib/collection/components/super-selection-app/services/super-selection-app.routes.js +1 -9
- package/dist/lib/collection/components/super-selection-app/services/super-selection-app.service.js +1 -35
- package/dist/lib/collection/components/super-selection-app/services/super-selection.store.js +1 -3
- package/dist/lib/collection/components/super-selection-app/standard-choice/standard-choice-form.js +16 -13
- package/dist/lib/collection/components/super-selection-app/super-selection-app.js +3 -17
- package/dist/lib/esm/apollo-super-selection.js +1 -1
- package/dist/lib/esm/loader.js +1 -1
- package/dist/lib/esm/{sss-button_43.entry.js → sss-button_31.entry.js} +948 -2239
- package/dist/lib/esm-es5/apollo-super-selection.js +1 -1
- package/dist/lib/esm-es5/loader.js +1 -1
- package/dist/lib/esm-es5/sss-button_31.entry.js +69 -0
- package/dist/lib/types/components/super-campaign/super-campaign-types.d.ts +4 -0
- package/dist/lib/types/components/super-campaign/super-campaign.d.ts +0 -1
- package/dist/lib/types/components/super-selection-app/api/super-selection.api.d.ts +1 -2
- package/dist/lib/types/components/super-selection-app/api/super-selection.api.dto.d.ts +1 -10
- package/dist/lib/types/components/super-selection-app/footer-section/footer-section.d.ts +1 -2
- package/dist/lib/types/components/super-selection-app/funds/slate-super/api/slate.d.ts +4 -0
- package/dist/lib/types/components/super-selection-app/services/super-selection-app.routes.d.ts +0 -4
- package/dist/lib/types/components/super-selection-app/services/super-selection-app.service.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/services/super-selection.store.d.ts +1 -3
- package/dist/lib/types/components/super-selection-app/super-selection-app.d.ts +0 -2
- package/dist/lib/types/components.d.ts +2 -203
- package/package.json +1 -1
- package/dist/lib/apollo-super-selection/assets/icon-check.svg +0 -3
- package/dist/lib/apollo-super-selection/assets/logo-active.svg +0 -1
- package/dist/lib/apollo-super-selection/assets/logo-art.svg +0 -7
- package/dist/lib/apollo-super-selection/assets/logo-aus-eth.svg +0 -31
- package/dist/lib/apollo-super-selection/assets/logo-aware.svg +0 -58
- package/dist/lib/apollo-super-selection/assets/logo-first.svg +0 -15
- package/dist/lib/apollo-super-selection/assets/logo-hesta.svg +0 -5
- package/dist/lib/apollo-super-selection/assets/logo-mercer-mychoice.svg +0 -1
- package/dist/lib/apollo-super-selection/assets/logo-rei.svg +0 -27
- package/dist/lib/apollo-super-selection/assets/logo-slate.png +0 -0
- package/dist/lib/apollo-super-selection/assets/logo-spirit.svg +0 -141
- package/dist/lib/apollo-super-selection/assets/logo-unisuper.svg +0 -15
- package/dist/lib/apollo-super-selection/assets/logo-virgin.svg +0 -8
- package/dist/lib/apollo-super-selection/assets/unisuper-default-badge1.svg +0 -25
- package/dist/lib/apollo-super-selection/assets/unisuper-default-badge2.svg +0 -109
- package/dist/lib/apollo-super-selection/assets/unisuper-default-badge3.svg +0 -102
- package/dist/lib/apollo-super-selection/p-203c74a8.entry.js +0 -14
- package/dist/lib/apollo-super-selection/p-b0120851.system.entry.js +0 -69
- package/dist/lib/collection/components/super-selection-app/assets/icon-check.svg +0 -3
- package/dist/lib/collection/components/super-selection-app/consent/consent-wrapper.js +0 -32
- package/dist/lib/collection/components/super-selection-app/consent/consent.js +0 -88
- package/dist/lib/collection/components/super-selection-app/funds/constants.js +0 -43
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/active.js +0 -26
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/australian-ethical.js +0 -43
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/australian-retirement-trust.js +0 -32
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/aware.js +0 -38
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/first.js +0 -27
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/hesta-default.js +0 -34
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/mercermychoice.js +0 -33
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/rei.js +0 -33
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/slate.js +0 -32
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/spirit.js +0 -43
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/unisuper-default-v2.js +0 -56
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/unisuper-default.js +0 -49
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/funds/virgin.js +0 -37
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/promoted-fund-join-v1-page.js +0 -30
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/promoted-fund-join-v2-page.js +0 -30
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/promoted-fund.store.js +0 -10
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v1-iframe-builder.js +0 -125
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v2-iframe-builder.js +0 -271
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v2-types.js +0 -1
- package/dist/lib/collection/components/super-selection-app/funds/promoted-fund/types.js +0 -15
- package/dist/lib/collection/components/super-selection-app/funds/slate-super/services/slate-iframe-builder.js +0 -143
- package/dist/lib/collection/components/super-selection-app/funds/slate-super/slate-join-page.js +0 -30
- package/dist/lib/collection/components/super-selection-app/loading-component/loading-component.js +0 -29
- package/dist/lib/collection/components/super-selection-app/loading-super-indicator/loading-super-indicator.js +0 -11
- package/dist/lib/collection/components/super-selection-app/misc/iframe-host.js +0 -32
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-active.svg +0 -1
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-art.svg +0 -7
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-aus-eth.svg +0 -31
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-aware.svg +0 -58
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-first.svg +0 -15
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-hesta.svg +0 -5
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-mercer-mychoice.svg +0 -1
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-rei.svg +0 -27
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-slate.png +0 -0
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-spirit.svg +0 -141
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-unisuper.svg +0 -15
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/logo-virgin.svg +0 -8
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/unisuper-default-badge1.svg +0 -25
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/unisuper-default-badge2.svg +0 -109
- package/dist/lib/collection/components/super-selection-app/super-choice-page/assets/unisuper-default-badge3.svg +0 -102
- package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-item/super-choice-item-bottom.js +0 -112
- package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-item/super-choice-item-top.js +0 -178
- package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-page-wrapper.js +0 -32
- package/dist/lib/collection/components/super-selection-app/super-choice-page/super-choice-page.js +0 -171
- package/dist/lib/esm-es5/sss-button_43.entry.js +0 -69
- package/dist/lib/types/components/super-selection-app/consent/consent-wrapper.d.ts +0 -5
- package/dist/lib/types/components/super-selection-app/consent/consent.d.ts +0 -9
- package/dist/lib/types/components/super-selection-app/funds/constants.d.ts +0 -9
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/active.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/australian-ethical.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/australian-retirement-trust.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/aware.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/first.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/hesta-default.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/mercermychoice.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/rei.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/slate.d.ts +0 -4
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/spirit.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/unisuper-default-v2.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/unisuper-default.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/funds/virgin.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/promoted-fund-join-v1-page.d.ts +0 -5
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/promoted-fund-join-v2-page.d.ts +0 -5
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/promoted-fund.store.d.ts +0 -10
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v1-iframe-builder.d.ts +0 -10
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v2-iframe-builder.d.ts +0 -12
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/services/promoted-fund-join-v2-types.d.ts +0 -75
- package/dist/lib/types/components/super-selection-app/funds/promoted-fund/types.d.ts +0 -26
- package/dist/lib/types/components/super-selection-app/funds/slate-super/services/slate-iframe-builder.d.ts +0 -14
- package/dist/lib/types/components/super-selection-app/funds/slate-super/slate-join-page.d.ts +0 -5
- package/dist/lib/types/components/super-selection-app/loading-component/loading-component.d.ts +0 -4
- package/dist/lib/types/components/super-selection-app/loading-super-indicator/loading-super-indicator.d.ts +0 -3
- package/dist/lib/types/components/super-selection-app/misc/iframe-host.d.ts +0 -6
- package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-item/super-choice-item-bottom.d.ts +0 -10
- package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-item/super-choice-item-top.d.ts +0 -12
- package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-page-wrapper.d.ts +0 -5
- package/dist/lib/types/components/super-selection-app/super-choice-page/super-choice-page.d.ts +0 -10
|
@@ -284,7 +284,7 @@ class TapSubscriber extends datoramaAkita.Subscriber {
|
|
|
284
284
|
}
|
|
285
285
|
}
|
|
286
286
|
|
|
287
|
-
const AppVersion = '5.
|
|
287
|
+
const AppVersion = '5.25.54575';
|
|
288
288
|
|
|
289
289
|
// -------------------------------------------------------------------------------------
|
|
290
290
|
// guards
|
|
@@ -987,6 +987,253 @@ const Button = class {
|
|
|
987
987
|
}
|
|
988
988
|
};
|
|
989
989
|
|
|
990
|
+
function appReady() {
|
|
991
|
+
postMessage({
|
|
992
|
+
type: 'appReady'
|
|
993
|
+
});
|
|
994
|
+
}
|
|
995
|
+
function postMessage(message, origin) {
|
|
996
|
+
if (origin === undefined)
|
|
997
|
+
origin = '*';
|
|
998
|
+
message.sender = 'flare';
|
|
999
|
+
window.parent.postMessage(message, origin);
|
|
1000
|
+
}
|
|
1001
|
+
function resize(height, width) {
|
|
1002
|
+
postMessage({
|
|
1003
|
+
type: 'contentResized',
|
|
1004
|
+
height,
|
|
1005
|
+
width
|
|
1006
|
+
});
|
|
1007
|
+
}
|
|
1008
|
+
function navigation(url) {
|
|
1009
|
+
postMessage({
|
|
1010
|
+
type: 'pageNavigated',
|
|
1011
|
+
url
|
|
1012
|
+
});
|
|
1013
|
+
}
|
|
1014
|
+
function complete() {
|
|
1015
|
+
postMessage({ type: 'complete' });
|
|
1016
|
+
}
|
|
1017
|
+
function submitSuccess() {
|
|
1018
|
+
postMessage({
|
|
1019
|
+
type: 'submitSuccess'
|
|
1020
|
+
});
|
|
1021
|
+
}
|
|
1022
|
+
const iframe = { appReady, resize, navigation, complete, submitSuccess };
|
|
1023
|
+
|
|
1024
|
+
const appendToMap = (map, propName, value) => {
|
|
1025
|
+
const items = map.get(propName);
|
|
1026
|
+
if (!items) {
|
|
1027
|
+
map.set(propName, [value]);
|
|
1028
|
+
}
|
|
1029
|
+
else if (!items.includes(value)) {
|
|
1030
|
+
items.push(value);
|
|
1031
|
+
}
|
|
1032
|
+
};
|
|
1033
|
+
const debounce = (fn, ms) => {
|
|
1034
|
+
let timeoutId;
|
|
1035
|
+
return (...args) => {
|
|
1036
|
+
if (timeoutId) {
|
|
1037
|
+
clearTimeout(timeoutId);
|
|
1038
|
+
}
|
|
1039
|
+
timeoutId = setTimeout(() => {
|
|
1040
|
+
timeoutId = 0;
|
|
1041
|
+
fn(...args);
|
|
1042
|
+
}, ms);
|
|
1043
|
+
};
|
|
1044
|
+
};
|
|
1045
|
+
|
|
1046
|
+
/**
|
|
1047
|
+
* Check if a possible element isConnected.
|
|
1048
|
+
* The property might not be there, so we check for it.
|
|
1049
|
+
*
|
|
1050
|
+
* We want it to return true if isConnected is not a property,
|
|
1051
|
+
* otherwise we would remove these elements and would not update.
|
|
1052
|
+
*
|
|
1053
|
+
* Better leak in Edge than to be useless.
|
|
1054
|
+
*/
|
|
1055
|
+
const isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;
|
|
1056
|
+
const cleanupElements = debounce((map) => {
|
|
1057
|
+
for (let key of map.keys()) {
|
|
1058
|
+
map.set(key, map.get(key).filter(isConnected));
|
|
1059
|
+
}
|
|
1060
|
+
}, 2000);
|
|
1061
|
+
const stencilSubscription = ({ on }) => {
|
|
1062
|
+
const elmsToUpdate = new Map();
|
|
1063
|
+
if (typeof index.getRenderingRef === 'function') {
|
|
1064
|
+
// If we are not in a stencil project, we do nothing.
|
|
1065
|
+
// This function is not really exported by @stencil/core.
|
|
1066
|
+
on('dispose', () => {
|
|
1067
|
+
elmsToUpdate.clear();
|
|
1068
|
+
});
|
|
1069
|
+
on('get', (propName) => {
|
|
1070
|
+
const elm = index.getRenderingRef();
|
|
1071
|
+
if (elm) {
|
|
1072
|
+
appendToMap(elmsToUpdate, propName, elm);
|
|
1073
|
+
}
|
|
1074
|
+
});
|
|
1075
|
+
on('set', (propName) => {
|
|
1076
|
+
const elements = elmsToUpdate.get(propName);
|
|
1077
|
+
if (elements) {
|
|
1078
|
+
elmsToUpdate.set(propName, elements.filter(index.forceUpdate));
|
|
1079
|
+
}
|
|
1080
|
+
cleanupElements(elmsToUpdate);
|
|
1081
|
+
});
|
|
1082
|
+
on('reset', () => {
|
|
1083
|
+
elmsToUpdate.forEach((elms) => elms.forEach(index.forceUpdate));
|
|
1084
|
+
cleanupElements(elmsToUpdate);
|
|
1085
|
+
});
|
|
1086
|
+
}
|
|
1087
|
+
};
|
|
1088
|
+
|
|
1089
|
+
const createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {
|
|
1090
|
+
let states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
|
|
1091
|
+
const handlers = {
|
|
1092
|
+
dispose: [],
|
|
1093
|
+
get: [],
|
|
1094
|
+
set: [],
|
|
1095
|
+
reset: [],
|
|
1096
|
+
};
|
|
1097
|
+
const reset = () => {
|
|
1098
|
+
states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
|
|
1099
|
+
handlers.reset.forEach((cb) => cb());
|
|
1100
|
+
};
|
|
1101
|
+
const dispose = () => {
|
|
1102
|
+
// Call first dispose as resetting the state would
|
|
1103
|
+
// cause less updates ;)
|
|
1104
|
+
handlers.dispose.forEach((cb) => cb());
|
|
1105
|
+
reset();
|
|
1106
|
+
};
|
|
1107
|
+
const get = (propName) => {
|
|
1108
|
+
handlers.get.forEach((cb) => cb(propName));
|
|
1109
|
+
return states.get(propName);
|
|
1110
|
+
};
|
|
1111
|
+
const set = (propName, value) => {
|
|
1112
|
+
const oldValue = states.get(propName);
|
|
1113
|
+
if (shouldUpdate(value, oldValue, propName)) {
|
|
1114
|
+
states.set(propName, value);
|
|
1115
|
+
handlers.set.forEach((cb) => cb(propName, value, oldValue));
|
|
1116
|
+
}
|
|
1117
|
+
};
|
|
1118
|
+
const state = (typeof Proxy === 'undefined'
|
|
1119
|
+
? {}
|
|
1120
|
+
: new Proxy(defaultState, {
|
|
1121
|
+
get(_, propName) {
|
|
1122
|
+
return get(propName);
|
|
1123
|
+
},
|
|
1124
|
+
ownKeys(_) {
|
|
1125
|
+
return Array.from(states.keys());
|
|
1126
|
+
},
|
|
1127
|
+
getOwnPropertyDescriptor() {
|
|
1128
|
+
return {
|
|
1129
|
+
enumerable: true,
|
|
1130
|
+
configurable: true,
|
|
1131
|
+
};
|
|
1132
|
+
},
|
|
1133
|
+
has(_, propName) {
|
|
1134
|
+
return states.has(propName);
|
|
1135
|
+
},
|
|
1136
|
+
set(_, propName, value) {
|
|
1137
|
+
set(propName, value);
|
|
1138
|
+
return true;
|
|
1139
|
+
},
|
|
1140
|
+
}));
|
|
1141
|
+
const on = (eventName, callback) => {
|
|
1142
|
+
handlers[eventName].push(callback);
|
|
1143
|
+
return () => {
|
|
1144
|
+
removeFromArray(handlers[eventName], callback);
|
|
1145
|
+
};
|
|
1146
|
+
};
|
|
1147
|
+
const onChange = (propName, cb) => {
|
|
1148
|
+
const unSet = on('set', (key, newValue) => {
|
|
1149
|
+
if (key === propName) {
|
|
1150
|
+
cb(newValue);
|
|
1151
|
+
}
|
|
1152
|
+
});
|
|
1153
|
+
const unReset = on('reset', () => cb(defaultState[propName]));
|
|
1154
|
+
return () => {
|
|
1155
|
+
unSet();
|
|
1156
|
+
unReset();
|
|
1157
|
+
};
|
|
1158
|
+
};
|
|
1159
|
+
const use = (...subscriptions) => subscriptions.forEach((subscription) => {
|
|
1160
|
+
if (subscription.set) {
|
|
1161
|
+
on('set', subscription.set);
|
|
1162
|
+
}
|
|
1163
|
+
if (subscription.get) {
|
|
1164
|
+
on('get', subscription.get);
|
|
1165
|
+
}
|
|
1166
|
+
if (subscription.reset) {
|
|
1167
|
+
on('reset', subscription.reset);
|
|
1168
|
+
}
|
|
1169
|
+
});
|
|
1170
|
+
return {
|
|
1171
|
+
state,
|
|
1172
|
+
get,
|
|
1173
|
+
set,
|
|
1174
|
+
on,
|
|
1175
|
+
onChange,
|
|
1176
|
+
use,
|
|
1177
|
+
dispose,
|
|
1178
|
+
reset,
|
|
1179
|
+
};
|
|
1180
|
+
};
|
|
1181
|
+
const removeFromArray = (array, item) => {
|
|
1182
|
+
const index = array.indexOf(item);
|
|
1183
|
+
if (index >= 0) {
|
|
1184
|
+
array[index] = array[array.length - 1];
|
|
1185
|
+
array.length--;
|
|
1186
|
+
}
|
|
1187
|
+
};
|
|
1188
|
+
|
|
1189
|
+
const createStore = (defaultState, shouldUpdate) => {
|
|
1190
|
+
const map = createObservableMap(defaultState, shouldUpdate);
|
|
1191
|
+
stencilSubscription(map);
|
|
1192
|
+
return map;
|
|
1193
|
+
};
|
|
1194
|
+
|
|
1195
|
+
const initial = {
|
|
1196
|
+
handleSubmitFn: async function () {
|
|
1197
|
+
return;
|
|
1198
|
+
},
|
|
1199
|
+
fundName: '',
|
|
1200
|
+
fundDetails: { type: 'null' },
|
|
1201
|
+
promotedFundId: undefined
|
|
1202
|
+
};
|
|
1203
|
+
const { state } = createStore(initial);
|
|
1204
|
+
|
|
1205
|
+
var SuperSelectionAppRoutes;
|
|
1206
|
+
(function (SuperSelectionAppRoutes) {
|
|
1207
|
+
SuperSelectionAppRoutes["ExistingChoicePage"] = "/existing";
|
|
1208
|
+
SuperSelectionAppRoutes["SuperCampaign"] = "/super-campaign";
|
|
1209
|
+
SuperSelectionAppRoutes["ChoicePage"] = "/";
|
|
1210
|
+
SuperSelectionAppRoutes["MyOwnFund"] = "/super-choice/my-own-fund/";
|
|
1211
|
+
SuperSelectionAppRoutes["Prefill"] = "/super-choice/prefill/";
|
|
1212
|
+
SuperSelectionAppRoutes["PrefillInvalidMyOwnFundPage"] = "/super-choice/sss-prefill-invalid-my-own-fund/";
|
|
1213
|
+
SuperSelectionAppRoutes["PrefillMyOwnFundPage"] = "/super-choice/prefill-my-own-fund/";
|
|
1214
|
+
SuperSelectionAppRoutes["PrefillSMSFPage"] = "/super-choice/prefill-smsf/";
|
|
1215
|
+
SuperSelectionAppRoutes["PrefillInvalidSMSFPage"] = "/super-choice/prefill-invalid-smsf/";
|
|
1216
|
+
SuperSelectionAppRoutes["SelfManagedFund"] = "/super-choice/smsf/";
|
|
1217
|
+
SuperSelectionAppRoutes["DefaultFund"] = "/super-choice/default/";
|
|
1218
|
+
SuperSelectionAppRoutes["StandardChoice"] = "/standard-choice/";
|
|
1219
|
+
SuperSelectionAppRoutes["Success"] = "/success/";
|
|
1220
|
+
})(SuperSelectionAppRoutes || (SuperSelectionAppRoutes = {}));
|
|
1221
|
+
const superSelectionAppStencilRoutes = [
|
|
1222
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.ExistingChoicePage, component: "sss-existing-choice-page" }),
|
|
1223
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.SuperCampaign, component: "sss-super-campaign-host" }),
|
|
1224
|
+
index.h("stencil-route", { exact: true, url: SuperSelectionAppRoutes.ChoicePage, component: "sss-super-campaign-host" }),
|
|
1225
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.MyOwnFund, component: "sss-my-own-fund" }),
|
|
1226
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillInvalidMyOwnFundPage, component: "sss-prefill-invalid-my-own-fund" }),
|
|
1227
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.Prefill, component: "sss-prefill" }),
|
|
1228
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillMyOwnFundPage, component: "sss-prefill-my-own-fund" }),
|
|
1229
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillSMSFPage, component: "sss-prefill-smsf" }),
|
|
1230
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillInvalidSMSFPage, component: "sss-prefill-invalid-smsf" }),
|
|
1231
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.SelfManagedFund, component: "sss-self-managed-fund" }),
|
|
1232
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.DefaultFund, component: "sss-default-fund" }),
|
|
1233
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.StandardChoice, component: "sss-standard-choice-form" }),
|
|
1234
|
+
index.h("stencil-route", { url: SuperSelectionAppRoutes.Success, component: "sss-success" })
|
|
1235
|
+
];
|
|
1236
|
+
|
|
990
1237
|
function createCommonjsModule(fn, basedir, module) {
|
|
991
1238
|
return module = {
|
|
992
1239
|
path: basedir,
|
|
@@ -2450,177 +2697,6 @@ exports.sequenceArray =
|
|
|
2450
2697
|
exports.traverseArray(_function.identity);
|
|
2451
2698
|
});
|
|
2452
2699
|
|
|
2453
|
-
const appendToMap = (map, propName, value) => {
|
|
2454
|
-
const items = map.get(propName);
|
|
2455
|
-
if (!items) {
|
|
2456
|
-
map.set(propName, [value]);
|
|
2457
|
-
}
|
|
2458
|
-
else if (!items.includes(value)) {
|
|
2459
|
-
items.push(value);
|
|
2460
|
-
}
|
|
2461
|
-
};
|
|
2462
|
-
const debounce = (fn, ms) => {
|
|
2463
|
-
let timeoutId;
|
|
2464
|
-
return (...args) => {
|
|
2465
|
-
if (timeoutId) {
|
|
2466
|
-
clearTimeout(timeoutId);
|
|
2467
|
-
}
|
|
2468
|
-
timeoutId = setTimeout(() => {
|
|
2469
|
-
timeoutId = 0;
|
|
2470
|
-
fn(...args);
|
|
2471
|
-
}, ms);
|
|
2472
|
-
};
|
|
2473
|
-
};
|
|
2474
|
-
|
|
2475
|
-
/**
|
|
2476
|
-
* Check if a possible element isConnected.
|
|
2477
|
-
* The property might not be there, so we check for it.
|
|
2478
|
-
*
|
|
2479
|
-
* We want it to return true if isConnected is not a property,
|
|
2480
|
-
* otherwise we would remove these elements and would not update.
|
|
2481
|
-
*
|
|
2482
|
-
* Better leak in Edge than to be useless.
|
|
2483
|
-
*/
|
|
2484
|
-
const isConnected = (maybeElement) => !('isConnected' in maybeElement) || maybeElement.isConnected;
|
|
2485
|
-
const cleanupElements = debounce((map) => {
|
|
2486
|
-
for (let key of map.keys()) {
|
|
2487
|
-
map.set(key, map.get(key).filter(isConnected));
|
|
2488
|
-
}
|
|
2489
|
-
}, 2000);
|
|
2490
|
-
const stencilSubscription = ({ on }) => {
|
|
2491
|
-
const elmsToUpdate = new Map();
|
|
2492
|
-
if (typeof index.getRenderingRef === 'function') {
|
|
2493
|
-
// If we are not in a stencil project, we do nothing.
|
|
2494
|
-
// This function is not really exported by @stencil/core.
|
|
2495
|
-
on('dispose', () => {
|
|
2496
|
-
elmsToUpdate.clear();
|
|
2497
|
-
});
|
|
2498
|
-
on('get', (propName) => {
|
|
2499
|
-
const elm = index.getRenderingRef();
|
|
2500
|
-
if (elm) {
|
|
2501
|
-
appendToMap(elmsToUpdate, propName, elm);
|
|
2502
|
-
}
|
|
2503
|
-
});
|
|
2504
|
-
on('set', (propName) => {
|
|
2505
|
-
const elements = elmsToUpdate.get(propName);
|
|
2506
|
-
if (elements) {
|
|
2507
|
-
elmsToUpdate.set(propName, elements.filter(index.forceUpdate));
|
|
2508
|
-
}
|
|
2509
|
-
cleanupElements(elmsToUpdate);
|
|
2510
|
-
});
|
|
2511
|
-
on('reset', () => {
|
|
2512
|
-
elmsToUpdate.forEach((elms) => elms.forEach(index.forceUpdate));
|
|
2513
|
-
cleanupElements(elmsToUpdate);
|
|
2514
|
-
});
|
|
2515
|
-
}
|
|
2516
|
-
};
|
|
2517
|
-
|
|
2518
|
-
const createObservableMap = (defaultState, shouldUpdate = (a, b) => a !== b) => {
|
|
2519
|
-
let states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
|
|
2520
|
-
const handlers = {
|
|
2521
|
-
dispose: [],
|
|
2522
|
-
get: [],
|
|
2523
|
-
set: [],
|
|
2524
|
-
reset: [],
|
|
2525
|
-
};
|
|
2526
|
-
const reset = () => {
|
|
2527
|
-
states = new Map(Object.entries(defaultState !== null && defaultState !== void 0 ? defaultState : {}));
|
|
2528
|
-
handlers.reset.forEach((cb) => cb());
|
|
2529
|
-
};
|
|
2530
|
-
const dispose = () => {
|
|
2531
|
-
// Call first dispose as resetting the state would
|
|
2532
|
-
// cause less updates ;)
|
|
2533
|
-
handlers.dispose.forEach((cb) => cb());
|
|
2534
|
-
reset();
|
|
2535
|
-
};
|
|
2536
|
-
const get = (propName) => {
|
|
2537
|
-
handlers.get.forEach((cb) => cb(propName));
|
|
2538
|
-
return states.get(propName);
|
|
2539
|
-
};
|
|
2540
|
-
const set = (propName, value) => {
|
|
2541
|
-
const oldValue = states.get(propName);
|
|
2542
|
-
if (shouldUpdate(value, oldValue, propName)) {
|
|
2543
|
-
states.set(propName, value);
|
|
2544
|
-
handlers.set.forEach((cb) => cb(propName, value, oldValue));
|
|
2545
|
-
}
|
|
2546
|
-
};
|
|
2547
|
-
const state = (typeof Proxy === 'undefined'
|
|
2548
|
-
? {}
|
|
2549
|
-
: new Proxy(defaultState, {
|
|
2550
|
-
get(_, propName) {
|
|
2551
|
-
return get(propName);
|
|
2552
|
-
},
|
|
2553
|
-
ownKeys(_) {
|
|
2554
|
-
return Array.from(states.keys());
|
|
2555
|
-
},
|
|
2556
|
-
getOwnPropertyDescriptor() {
|
|
2557
|
-
return {
|
|
2558
|
-
enumerable: true,
|
|
2559
|
-
configurable: true,
|
|
2560
|
-
};
|
|
2561
|
-
},
|
|
2562
|
-
has(_, propName) {
|
|
2563
|
-
return states.has(propName);
|
|
2564
|
-
},
|
|
2565
|
-
set(_, propName, value) {
|
|
2566
|
-
set(propName, value);
|
|
2567
|
-
return true;
|
|
2568
|
-
},
|
|
2569
|
-
}));
|
|
2570
|
-
const on = (eventName, callback) => {
|
|
2571
|
-
handlers[eventName].push(callback);
|
|
2572
|
-
return () => {
|
|
2573
|
-
removeFromArray(handlers[eventName], callback);
|
|
2574
|
-
};
|
|
2575
|
-
};
|
|
2576
|
-
const onChange = (propName, cb) => {
|
|
2577
|
-
const unSet = on('set', (key, newValue) => {
|
|
2578
|
-
if (key === propName) {
|
|
2579
|
-
cb(newValue);
|
|
2580
|
-
}
|
|
2581
|
-
});
|
|
2582
|
-
const unReset = on('reset', () => cb(defaultState[propName]));
|
|
2583
|
-
return () => {
|
|
2584
|
-
unSet();
|
|
2585
|
-
unReset();
|
|
2586
|
-
};
|
|
2587
|
-
};
|
|
2588
|
-
const use = (...subscriptions) => subscriptions.forEach((subscription) => {
|
|
2589
|
-
if (subscription.set) {
|
|
2590
|
-
on('set', subscription.set);
|
|
2591
|
-
}
|
|
2592
|
-
if (subscription.get) {
|
|
2593
|
-
on('get', subscription.get);
|
|
2594
|
-
}
|
|
2595
|
-
if (subscription.reset) {
|
|
2596
|
-
on('reset', subscription.reset);
|
|
2597
|
-
}
|
|
2598
|
-
});
|
|
2599
|
-
return {
|
|
2600
|
-
state,
|
|
2601
|
-
get,
|
|
2602
|
-
set,
|
|
2603
|
-
on,
|
|
2604
|
-
onChange,
|
|
2605
|
-
use,
|
|
2606
|
-
dispose,
|
|
2607
|
-
reset,
|
|
2608
|
-
};
|
|
2609
|
-
};
|
|
2610
|
-
const removeFromArray = (array, item) => {
|
|
2611
|
-
const index = array.indexOf(item);
|
|
2612
|
-
if (index >= 0) {
|
|
2613
|
-
array[index] = array[array.length - 1];
|
|
2614
|
-
array.length--;
|
|
2615
|
-
}
|
|
2616
|
-
};
|
|
2617
|
-
|
|
2618
|
-
const createStore = (defaultState, shouldUpdate) => {
|
|
2619
|
-
const map = createObservableMap(defaultState, shouldUpdate);
|
|
2620
|
-
stencilSubscription(map);
|
|
2621
|
-
return map;
|
|
2622
|
-
};
|
|
2623
|
-
|
|
2624
2700
|
function e(e){this.message=e;}e.prototype=new Error,e.prototype.name="InvalidCharacterError";var r="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(r){var t=String(r).replace(/=+$/,"");if(t.length%4==1)throw new e("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,o,a=0,i=0,c="";o=t.charAt(i++);~o&&(n=a%4?64*n+o:o,a++%4)?c+=String.fromCharCode(255&n>>(-2*a&6)):0)o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(o);return c};function t(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw "Illegal base64url string!"}try{return function(e){return decodeURIComponent(r(e).replace(/(.)/g,(function(e,r){var t=r.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(t)}catch(e){return r(t)}}function n(e){this.message=e;}function o(e,r){if("string"!=typeof e)throw new n("Invalid token specified");var o=!0===(r=r||{}).header?0:1;try{return JSON.parse(t(e.split(".")[o]))}catch(e){throw new n("Invalid token specified: "+e.message)}}n.prototype=new Error,n.prototype.name="InvalidTokenError";
|
|
2625
2701
|
|
|
2626
2702
|
var __assign$1 = (undefined && undefined.__assign) || function () {
|
|
@@ -3310,6 +3386,11 @@ function buildBackendApiClient() {
|
|
|
3310
3386
|
});
|
|
3311
3387
|
}
|
|
3312
3388
|
|
|
3389
|
+
const slate = {
|
|
3390
|
+
fundId: 'slate',
|
|
3391
|
+
usi: '32367272075001'
|
|
3392
|
+
};
|
|
3393
|
+
|
|
3313
3394
|
function hydratePromotedFundChoiceDtoKind(dto) {
|
|
3314
3395
|
if ('slate' in dto) {
|
|
3315
3396
|
dto.kind = 'slate';
|
|
@@ -3345,33 +3426,33 @@ function hydratePromotedFundChoiceDtoKind(dto) {
|
|
|
3345
3426
|
function getPromotedFundUsi(dto) {
|
|
3346
3427
|
switch (dto.kind) {
|
|
3347
3428
|
case 'slate':
|
|
3348
|
-
return
|
|
3429
|
+
return slate.usi;
|
|
3349
3430
|
case 'australianRetirementTrust':
|
|
3350
|
-
return
|
|
3431
|
+
return dto.australianRetirementTrust.usi;
|
|
3351
3432
|
case 'aware':
|
|
3352
|
-
return
|
|
3433
|
+
return dto.aware.usi;
|
|
3353
3434
|
case 'active':
|
|
3354
|
-
return
|
|
3435
|
+
return dto.active.usi;
|
|
3355
3436
|
case 'australianEthical':
|
|
3356
|
-
return
|
|
3437
|
+
return dto.australianEthical.usi;
|
|
3357
3438
|
case 'virgin':
|
|
3358
|
-
return
|
|
3439
|
+
return dto.virgin.usi;
|
|
3359
3440
|
case 'spirit':
|
|
3360
|
-
return
|
|
3441
|
+
return dto.spirit.usi;
|
|
3361
3442
|
case 'firstSuper':
|
|
3362
|
-
return
|
|
3443
|
+
return dto.firstSuper.usi;
|
|
3363
3444
|
case 'mercerMyChoice':
|
|
3364
|
-
return
|
|
3445
|
+
return dto.mercerMyChoice.usi;
|
|
3365
3446
|
case 'generic':
|
|
3366
|
-
return
|
|
3447
|
+
return dto.generic.usi;
|
|
3367
3448
|
default:
|
|
3368
|
-
return
|
|
3449
|
+
return '';
|
|
3369
3450
|
}
|
|
3370
3451
|
}
|
|
3371
3452
|
function getPromotedFundId(dto) {
|
|
3372
3453
|
switch (dto.kind) {
|
|
3373
3454
|
case 'slate':
|
|
3374
|
-
return
|
|
3455
|
+
return slate.fundId;
|
|
3375
3456
|
case 'australianRetirementTrust':
|
|
3376
3457
|
return 'australian-retirement-trust';
|
|
3377
3458
|
case 'aware':
|
|
@@ -3397,7 +3478,7 @@ function getPromotedFundId(dto) {
|
|
|
3397
3478
|
function getSuperChoiceUsi(dto) {
|
|
3398
3479
|
switch (dto.kind) {
|
|
3399
3480
|
case 'Promoted':
|
|
3400
|
-
return getPromotedFundUsi(dto.promoted);
|
|
3481
|
+
return some(getPromotedFundUsi(dto.promoted));
|
|
3401
3482
|
case 'MyOwnFund':
|
|
3402
3483
|
return some(dto.myOwnFund.usi);
|
|
3403
3484
|
case 'SMSF':
|
|
@@ -3417,33 +3498,33 @@ function getSuperChoiceUsi(dto) {
|
|
|
3417
3498
|
function getPromotedFundMemberNumber(dto) {
|
|
3418
3499
|
switch (dto.kind) {
|
|
3419
3500
|
case 'slate':
|
|
3420
|
-
return
|
|
3501
|
+
return dto.slate.memberNumber;
|
|
3421
3502
|
case 'australianRetirementTrust':
|
|
3422
|
-
return
|
|
3503
|
+
return dto.australianRetirementTrust.memberNumber;
|
|
3423
3504
|
case 'aware':
|
|
3424
|
-
return
|
|
3505
|
+
return dto.aware.memberNumber;
|
|
3425
3506
|
case 'active':
|
|
3426
|
-
return
|
|
3507
|
+
return dto.active.memberNumber;
|
|
3427
3508
|
case 'australianEthical':
|
|
3428
|
-
return
|
|
3509
|
+
return dto.australianEthical.memberNumber;
|
|
3429
3510
|
case 'virgin':
|
|
3430
|
-
return
|
|
3511
|
+
return dto.virgin.memberNumber;
|
|
3431
3512
|
case 'spirit':
|
|
3432
|
-
return
|
|
3513
|
+
return dto.spirit.memberNumber;
|
|
3433
3514
|
case 'firstSuper':
|
|
3434
|
-
return
|
|
3515
|
+
return dto.firstSuper.memberNumber;
|
|
3435
3516
|
case 'mercerMyChoice':
|
|
3436
|
-
return
|
|
3517
|
+
return dto.mercerMyChoice.memberNumber;
|
|
3437
3518
|
case 'generic':
|
|
3438
|
-
return
|
|
3519
|
+
return dto.generic.memberNumber;
|
|
3439
3520
|
default:
|
|
3440
|
-
return
|
|
3521
|
+
return '';
|
|
3441
3522
|
}
|
|
3442
3523
|
}
|
|
3443
3524
|
function getSuperChoiceMemberNumber(dto) {
|
|
3444
3525
|
switch (dto.kind) {
|
|
3445
3526
|
case 'Promoted':
|
|
3446
|
-
return getPromotedFundMemberNumber(dto.promoted);
|
|
3527
|
+
return some(getPromotedFundMemberNumber(dto.promoted));
|
|
3447
3528
|
case 'MyOwnFund':
|
|
3448
3529
|
return some(dto.myOwnFund.memberNumber);
|
|
3449
3530
|
case 'DefinedBenefits':
|
|
@@ -3521,15 +3602,6 @@ class SuperSelectionApi {
|
|
|
3521
3602
|
}
|
|
3522
3603
|
return response;
|
|
3523
3604
|
}
|
|
3524
|
-
async getCampaignConnectAsync() {
|
|
3525
|
-
return buildBackendApiClient()
|
|
3526
|
-
.url('campaign-connect')
|
|
3527
|
-
.get()
|
|
3528
|
-
.notFound(() => {
|
|
3529
|
-
throw new Error('Failed to fetch campaign connect.');
|
|
3530
|
-
})
|
|
3531
|
-
.json();
|
|
3532
|
-
}
|
|
3533
3605
|
async clickPromotedTileAsync(payload) {
|
|
3534
3606
|
return buildBackendApiClient().url('click-promoted-tile').post(payload).res();
|
|
3535
3607
|
}
|
|
@@ -3584,10 +3656,8 @@ const initialState = {
|
|
|
3584
3656
|
profileConfiguration: Option.none,
|
|
3585
3657
|
hasSuccessPageBeenAcknowledged: false,
|
|
3586
3658
|
hasSuperSelectionBeenSubmitted: false,
|
|
3587
|
-
campaignConnectEnabled: false,
|
|
3588
3659
|
isDefinedBenefitsEligible: Option.none,
|
|
3589
|
-
|
|
3590
|
-
superCampaignEnabled: false,
|
|
3660
|
+
superCampaignEnabled: true,
|
|
3591
3661
|
superCampaignState: undefined,
|
|
3592
3662
|
superCampaignComponentStatus: SuperCampaignComponentStatus.NotLoaded,
|
|
3593
3663
|
superCampaignIsInView: false
|
|
@@ -3630,9 +3700,6 @@ class SuperSelectionAppService {
|
|
|
3630
3700
|
if (this.state.superCampaignEnabled && this.superCampaignState !== undefined) {
|
|
3631
3701
|
return this.superCampaignState.PromotedFundIds;
|
|
3632
3702
|
}
|
|
3633
|
-
if (this._state.campaignConnectEnabled && Option.isSome(this._state.campaignConnect)) {
|
|
3634
|
-
return this._state.campaignConnect.value.promotedFunds.map((v) => v.fundId);
|
|
3635
|
-
}
|
|
3636
3703
|
if (Option.isNone(this._state.promotedFunds)) {
|
|
3637
3704
|
throw Error('Promoted Funds is not set');
|
|
3638
3705
|
}
|
|
@@ -3642,35 +3709,15 @@ class SuperSelectionAppService {
|
|
|
3642
3709
|
if (this.state.superCampaignEnabled && this.superCampaignState !== undefined) {
|
|
3643
3710
|
return Option.fromNullable(this.superCampaignState.DefaultFundPosition);
|
|
3644
3711
|
}
|
|
3645
|
-
if (this._state.campaignConnectEnabled && Option.isSome(this._state.campaignConnect)) {
|
|
3646
|
-
const index = this._state.campaignConnect.value.promotedFunds.findIndex((v) => v.type === 'promoted-default');
|
|
3647
|
-
if (index === -1) {
|
|
3648
|
-
return Option.fromNullable(null);
|
|
3649
|
-
}
|
|
3650
|
-
else {
|
|
3651
|
-
return Option.fromNullable(index + 1);
|
|
3652
|
-
}
|
|
3653
|
-
}
|
|
3654
3712
|
return Option.none;
|
|
3655
3713
|
}
|
|
3656
3714
|
get promotedFundsConfig() {
|
|
3657
3715
|
return {
|
|
3658
3716
|
shownFunds: this.promotedFunds,
|
|
3659
3717
|
promotedDefaultFundPosition: Option.toUndefined(this.promotedDefaultFundPosition),
|
|
3660
|
-
promotedFundsConfigSource: this.isUsingSuperCampaign
|
|
3661
|
-
? 'superCampaign'
|
|
3662
|
-
: Option.isSome(this._state.campaignConnect)
|
|
3663
|
-
? 'campaignConnect'
|
|
3664
|
-
: 'superSelection'
|
|
3718
|
+
promotedFundsConfigSource: this.isUsingSuperCampaign ? 'superCampaign' : 'superSelection'
|
|
3665
3719
|
};
|
|
3666
3720
|
}
|
|
3667
|
-
get definedBenefitsFundId() {
|
|
3668
|
-
if (Option.isSome(this._state.campaignConnect)) {
|
|
3669
|
-
const definedBenefitsFund = this._state.campaignConnect.value.promotedFunds.find((fund) => fund.type == 'defined-benefits');
|
|
3670
|
-
return Option.fromNullable(definedBenefitsFund === null || definedBenefitsFund === void 0 ? void 0 : definedBenefitsFund.fundId);
|
|
3671
|
-
}
|
|
3672
|
-
return Option.none;
|
|
3673
|
-
}
|
|
3674
3721
|
get profileId() {
|
|
3675
3722
|
if (Option.isNone(this._state.profileId)) {
|
|
3676
3723
|
throw Error('Failed to get Profile ID from JWT');
|
|
@@ -3702,9 +3749,6 @@ class SuperSelectionAppService {
|
|
|
3702
3749
|
markSuperSelectionAsSubmitted() {
|
|
3703
3750
|
this._state.hasSuperSelectionBeenSubmitted = true;
|
|
3704
3751
|
}
|
|
3705
|
-
get campaignConnectEnabled() {
|
|
3706
|
-
return this._state.campaignConnectEnabled;
|
|
3707
|
-
}
|
|
3708
3752
|
get isDefinedBenefitsEligible() {
|
|
3709
3753
|
return this._state.isDefinedBenefitsEligible;
|
|
3710
3754
|
}
|
|
@@ -3714,17 +3758,9 @@ class SuperSelectionAppService {
|
|
|
3714
3758
|
this._state.profileConfiguration = Option.fromNullable(appStateResponse.profileConfiguration);
|
|
3715
3759
|
this._state.superBuyer = Option.fromNullable(appStateResponse.superBuyer);
|
|
3716
3760
|
this._state.promotedFunds = Option.fromNullable(appStateResponse.promotedFunds);
|
|
3717
|
-
this._state.campaignConnectEnabled = appStateResponse.campaignConnectEnabled;
|
|
3718
|
-
this._state.superCampaignEnabled = appStateResponse.superCampaignEnabled;
|
|
3719
3761
|
this._state.superChoicePrefill = Option.fromNullable(appStateResponse.prefill);
|
|
3720
3762
|
this._state.isDefinedBenefitsEligible = Option.fromNullable(appStateResponse.isDefinedBenefitsEligible);
|
|
3721
3763
|
}
|
|
3722
|
-
async loadCampaignConnectAsync() {
|
|
3723
|
-
if (this._state.campaignConnectEnabled) {
|
|
3724
|
-
const campaignConnect = await superSelectionApi.getCampaignConnectAsync();
|
|
3725
|
-
this._state.campaignConnect = Option.fromNullable(campaignConnect);
|
|
3726
|
-
}
|
|
3727
|
-
}
|
|
3728
3764
|
setSuperCampaignPromotedFundsShown(shownFunds) {
|
|
3729
3765
|
if (this._state.superCampaignState !== undefined)
|
|
3730
3766
|
this._state.superCampaignState.promotedFundsShown = shownFunds;
|
|
@@ -3768,306 +3804,33 @@ class SuperSelectionAppService {
|
|
|
3768
3804
|
}
|
|
3769
3805
|
const superSelectionAppService = new SuperSelectionAppService();
|
|
3770
3806
|
|
|
3771
|
-
|
|
3772
|
-
|
|
3773
|
-
|
|
3774
|
-
|
|
3775
|
-
|
|
3776
|
-
? 'True'
|
|
3777
|
-
: 'False';
|
|
3778
|
-
}
|
|
3779
|
-
return {
|
|
3780
|
-
isDefinedBenefitsEligible: isDefinedBenefitsEligibleString,
|
|
3781
|
-
superCampaignEnabled: superCampaignEnabled
|
|
3782
|
-
};
|
|
3807
|
+
class NavigationService {
|
|
3808
|
+
navigateInternally(history, route) {
|
|
3809
|
+
const path = `${this.appBaseUrl}${this.toRouteWithLeadingSlash(route)}`;
|
|
3810
|
+
iframe.navigation(path);
|
|
3811
|
+
history.push(path);
|
|
3783
3812
|
}
|
|
3784
|
-
|
|
3785
|
-
|
|
3786
|
-
|
|
3787
|
-
|
|
3788
|
-
|
|
3789
|
-
|
|
3813
|
+
navigateInternallyToStandardChoice(options) {
|
|
3814
|
+
state.handleSubmitFn = options.handleSubmitFn;
|
|
3815
|
+
state.fundName = options.fundName;
|
|
3816
|
+
state.fundDetails = options.fundDetails;
|
|
3817
|
+
state.promotedFundId = options.promotedFundId;
|
|
3818
|
+
this.navigateInternally(options.history, SuperSelectionAppRoutes.StandardChoice);
|
|
3790
3819
|
}
|
|
3791
|
-
|
|
3792
|
-
const
|
|
3793
|
-
|
|
3794
|
-
|
|
3795
|
-
static get Instance() {
|
|
3796
|
-
return this.instance || (this.instance = new this());
|
|
3820
|
+
toExternalUrl(url) {
|
|
3821
|
+
const externalUrl = new URL(url);
|
|
3822
|
+
externalUrl.searchParams.append('_extnav', 'true');
|
|
3823
|
+
return externalUrl.href;
|
|
3797
3824
|
}
|
|
3798
|
-
|
|
3799
|
-
|
|
3825
|
+
get appBaseUrl() {
|
|
3826
|
+
const baseUrl = superSelectionAppService.appBaseUrl;
|
|
3827
|
+
return baseUrl.replace(/\/$/, '');
|
|
3828
|
+
}
|
|
3829
|
+
toRouteWithLeadingSlash(route) {
|
|
3830
|
+
return route.length > 0 && route[0] === '/' ? route : `/${route}`;
|
|
3800
3831
|
}
|
|
3801
3832
|
}
|
|
3802
|
-
|
|
3803
|
-
class EventTrackingService {
|
|
3804
|
-
constructor() {
|
|
3805
|
-
this.eventTrackingApi = EventTrackingApi.Instance;
|
|
3806
|
-
}
|
|
3807
|
-
static get Instance() {
|
|
3808
|
-
return this.instance || (this.instance = new this());
|
|
3809
|
-
}
|
|
3810
|
-
async TrackSuperFundPdsViewedAsync(detail) {
|
|
3811
|
-
return this.trackEventAsync({
|
|
3812
|
-
SuperFundPdsViewed: detail
|
|
3813
|
-
});
|
|
3814
|
-
}
|
|
3815
|
-
async TrackPromotedSuperFundDetailViewedAsync(detail) {
|
|
3816
|
-
return this.trackEventAsync({
|
|
3817
|
-
SuperFundDetailViewed: {
|
|
3818
|
-
PromotedFund: detail
|
|
3819
|
-
}
|
|
3820
|
-
});
|
|
3821
|
-
}
|
|
3822
|
-
async TrackPromotedDefaultSuperFundDetailViewedAsync(detail) {
|
|
3823
|
-
return this.trackEventAsync({
|
|
3824
|
-
SuperFundDetailViewed: {
|
|
3825
|
-
PromotedDefaultFund: detail
|
|
3826
|
-
}
|
|
3827
|
-
});
|
|
3828
|
-
}
|
|
3829
|
-
async TrackMyOwnSuperFundDetailViewedAsync(detail) {
|
|
3830
|
-
return this.trackEventAsync({
|
|
3831
|
-
SuperFundDetailViewed: {
|
|
3832
|
-
MyOwnFund: detail
|
|
3833
|
-
}
|
|
3834
|
-
});
|
|
3835
|
-
}
|
|
3836
|
-
async TrackSmsfSuperFundDetailViewedAsync(detail) {
|
|
3837
|
-
return this.trackEventAsync({
|
|
3838
|
-
SuperFundDetailViewed: {
|
|
3839
|
-
Smsf: detail
|
|
3840
|
-
}
|
|
3841
|
-
});
|
|
3842
|
-
}
|
|
3843
|
-
async TrackDefaultSuperFundDetailViewedAsync(detail) {
|
|
3844
|
-
return this.trackEventAsync({
|
|
3845
|
-
SuperFundDetailViewed: {
|
|
3846
|
-
DefaultFund: detail
|
|
3847
|
-
}
|
|
3848
|
-
});
|
|
3849
|
-
}
|
|
3850
|
-
async TrackSuperFundNominationViewedAsync(detail) {
|
|
3851
|
-
return this.trackEventAsync({
|
|
3852
|
-
SuperFundNominationViewed: detail
|
|
3853
|
-
});
|
|
3854
|
-
}
|
|
3855
|
-
async TrackSuperFundNominationDeclinedAsync(detail) {
|
|
3856
|
-
return this.trackEventAsync({
|
|
3857
|
-
SuperFundNominationDeclined: detail
|
|
3858
|
-
});
|
|
3859
|
-
}
|
|
3860
|
-
async TrackSuperFundDisclaimerViewedAsync(detail) {
|
|
3861
|
-
return this.trackEventAsync({
|
|
3862
|
-
SuperFundDisclaimerViewed: detail
|
|
3863
|
-
});
|
|
3864
|
-
}
|
|
3865
|
-
async TrackSuperFundDisclaimerAcceptedAsync(detail) {
|
|
3866
|
-
return this.trackEventAsync({
|
|
3867
|
-
SuperFundDisclaimerAccepted: detail
|
|
3868
|
-
});
|
|
3869
|
-
}
|
|
3870
|
-
async TrackSuperFundPrefillViewedAsync(detail) {
|
|
3871
|
-
return this.trackEventAsync({
|
|
3872
|
-
SuperFundPrefillViewed: detail
|
|
3873
|
-
});
|
|
3874
|
-
}
|
|
3875
|
-
async TrackSuperFundPrefillDeclinedAsync(detail) {
|
|
3876
|
-
return this.trackEventAsync({
|
|
3877
|
-
SuperFundPrefillDeclined: detail
|
|
3878
|
-
});
|
|
3879
|
-
}
|
|
3880
|
-
async TrackSuperFundDetailChangeRequestedAsync(detail) {
|
|
3881
|
-
return this.trackEventAsync({
|
|
3882
|
-
SuperFundDetailChangeRequested: detail
|
|
3883
|
-
});
|
|
3884
|
-
}
|
|
3885
|
-
async TrackSuperCampaignActivationSucceededAsync(detail) {
|
|
3886
|
-
return this.trackEventAsync({
|
|
3887
|
-
SuperCampaignActivationSucceeded: detail
|
|
3888
|
-
});
|
|
3889
|
-
}
|
|
3890
|
-
async trackEventAsync(event) {
|
|
3891
|
-
try {
|
|
3892
|
-
await this.eventTrackingApi.PostAnalyticsEventAsync({ event });
|
|
3893
|
-
}
|
|
3894
|
-
catch (_a) {
|
|
3895
|
-
return;
|
|
3896
|
-
}
|
|
3897
|
-
}
|
|
3898
|
-
}
|
|
3899
|
-
|
|
3900
|
-
function appReady() {
|
|
3901
|
-
postMessage({
|
|
3902
|
-
type: 'appReady'
|
|
3903
|
-
});
|
|
3904
|
-
}
|
|
3905
|
-
function postMessage(message, origin) {
|
|
3906
|
-
if (origin === undefined)
|
|
3907
|
-
origin = '*';
|
|
3908
|
-
message.sender = 'flare';
|
|
3909
|
-
window.parent.postMessage(message, origin);
|
|
3910
|
-
}
|
|
3911
|
-
function resize(height, width) {
|
|
3912
|
-
postMessage({
|
|
3913
|
-
type: 'contentResized',
|
|
3914
|
-
height,
|
|
3915
|
-
width
|
|
3916
|
-
});
|
|
3917
|
-
}
|
|
3918
|
-
function navigation(url) {
|
|
3919
|
-
postMessage({
|
|
3920
|
-
type: 'pageNavigated',
|
|
3921
|
-
url
|
|
3922
|
-
});
|
|
3923
|
-
}
|
|
3924
|
-
function complete() {
|
|
3925
|
-
postMessage({ type: 'complete' });
|
|
3926
|
-
}
|
|
3927
|
-
function submitSuccess() {
|
|
3928
|
-
postMessage({
|
|
3929
|
-
type: 'submitSuccess'
|
|
3930
|
-
});
|
|
3931
|
-
}
|
|
3932
|
-
const iframe = { appReady, resize, navigation, complete, submitSuccess };
|
|
3933
|
-
|
|
3934
|
-
const initial$1 = {
|
|
3935
|
-
handleSubmitFn: async function () {
|
|
3936
|
-
return;
|
|
3937
|
-
},
|
|
3938
|
-
fundName: '',
|
|
3939
|
-
fundDetails: { type: 'null' },
|
|
3940
|
-
promotedFundId: undefined
|
|
3941
|
-
};
|
|
3942
|
-
const { state: state$1 } = createStore(initial$1);
|
|
3943
|
-
|
|
3944
|
-
var SuperSelectionAppRoutes;
|
|
3945
|
-
(function (SuperSelectionAppRoutes) {
|
|
3946
|
-
SuperSelectionAppRoutes["ConsentPage"] = "/consent";
|
|
3947
|
-
SuperSelectionAppRoutes["ExistingChoicePage"] = "/existing";
|
|
3948
|
-
SuperSelectionAppRoutes["SuperCampaign"] = "/super-campaign";
|
|
3949
|
-
SuperSelectionAppRoutes["ChoicePage"] = "/";
|
|
3950
|
-
SuperSelectionAppRoutes["SlateJoin"] = "/slate/join/";
|
|
3951
|
-
SuperSelectionAppRoutes["PromotedFundJoinV1"] = "/promoted-fund/join/v1";
|
|
3952
|
-
SuperSelectionAppRoutes["PromotedFundJoinV2"] = "/promoted-fund/join/v2";
|
|
3953
|
-
SuperSelectionAppRoutes["MyOwnFund"] = "/super-choice/my-own-fund/";
|
|
3954
|
-
SuperSelectionAppRoutes["Prefill"] = "/super-choice/prefill/";
|
|
3955
|
-
SuperSelectionAppRoutes["PrefillInvalidMyOwnFundPage"] = "/super-choice/sss-prefill-invalid-my-own-fund/";
|
|
3956
|
-
SuperSelectionAppRoutes["PrefillMyOwnFundPage"] = "/super-choice/prefill-my-own-fund/";
|
|
3957
|
-
SuperSelectionAppRoutes["PrefillSMSFPage"] = "/super-choice/prefill-smsf/";
|
|
3958
|
-
SuperSelectionAppRoutes["PrefillInvalidSMSFPage"] = "/super-choice/prefill-invalid-smsf/";
|
|
3959
|
-
SuperSelectionAppRoutes["SelfManagedFund"] = "/super-choice/smsf/";
|
|
3960
|
-
SuperSelectionAppRoutes["DefaultFund"] = "/super-choice/default/";
|
|
3961
|
-
SuperSelectionAppRoutes["StandardChoice"] = "/standard-choice/";
|
|
3962
|
-
SuperSelectionAppRoutes["Success"] = "/success/";
|
|
3963
|
-
})(SuperSelectionAppRoutes || (SuperSelectionAppRoutes = {}));
|
|
3964
|
-
const superSelectionAppStencilRoutes = [
|
|
3965
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.ConsentPage, component: "sss-consent-page-wrapper" }),
|
|
3966
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.ExistingChoicePage, component: "sss-existing-choice-page" }),
|
|
3967
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.SuperCampaign, component: "sss-super-campaign-host" }),
|
|
3968
|
-
index.h("stencil-route", { exact: true, url: SuperSelectionAppRoutes.ChoicePage, component: "sss-super-choice-page-wrapper" }),
|
|
3969
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.SlateJoin, component: "sss-slate-join-page" }),
|
|
3970
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PromotedFundJoinV1, component: "sss-promoted-fund-join-v1-page" }),
|
|
3971
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PromotedFundJoinV2, component: "sss-promoted-fund-join-v2-page" }),
|
|
3972
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.MyOwnFund, component: "sss-my-own-fund" }),
|
|
3973
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillInvalidMyOwnFundPage, component: "sss-prefill-invalid-my-own-fund" }),
|
|
3974
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.Prefill, component: "sss-prefill" }),
|
|
3975
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillMyOwnFundPage, component: "sss-prefill-my-own-fund" }),
|
|
3976
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillSMSFPage, component: "sss-prefill-smsf" }),
|
|
3977
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.PrefillInvalidSMSFPage, component: "sss-prefill-invalid-smsf" }),
|
|
3978
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.SelfManagedFund, component: "sss-self-managed-fund" }),
|
|
3979
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.DefaultFund, component: "sss-default-fund" }),
|
|
3980
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.StandardChoice, component: "sss-standard-choice-form" }),
|
|
3981
|
-
index.h("stencil-route", { url: SuperSelectionAppRoutes.Success, component: "sss-success" })
|
|
3982
|
-
];
|
|
3983
|
-
|
|
3984
|
-
class NavigationService {
|
|
3985
|
-
navigateInternally(history, route) {
|
|
3986
|
-
const path = `${this.appBaseUrl}${this.toRouteWithLeadingSlash(route)}`;
|
|
3987
|
-
iframe.navigation(path);
|
|
3988
|
-
history.push(path);
|
|
3989
|
-
}
|
|
3990
|
-
navigateInternallyToStandardChoice(options) {
|
|
3991
|
-
state$1.handleSubmitFn = options.handleSubmitFn;
|
|
3992
|
-
state$1.fundName = options.fundName;
|
|
3993
|
-
state$1.fundDetails = options.fundDetails;
|
|
3994
|
-
state$1.promotedFundId = options.promotedFundId;
|
|
3995
|
-
this.navigateInternally(options.history, SuperSelectionAppRoutes.StandardChoice);
|
|
3996
|
-
}
|
|
3997
|
-
toExternalUrl(url) {
|
|
3998
|
-
const externalUrl = new URL(url);
|
|
3999
|
-
externalUrl.searchParams.append('_extnav', 'true');
|
|
4000
|
-
return externalUrl.href;
|
|
4001
|
-
}
|
|
4002
|
-
get appBaseUrl() {
|
|
4003
|
-
const baseUrl = superSelectionAppService.appBaseUrl;
|
|
4004
|
-
return baseUrl.replace(/\/$/, '');
|
|
4005
|
-
}
|
|
4006
|
-
toRouteWithLeadingSlash(route) {
|
|
4007
|
-
return route.length > 0 && route[0] === '/' ? route : `/${route}`;
|
|
4008
|
-
}
|
|
4009
|
-
}
|
|
4010
|
-
const navigationService = new NavigationService();
|
|
4011
|
-
|
|
4012
|
-
const Link = (props, children) => {
|
|
4013
|
-
return (index.h("a", { class: props.className || 'font-medium underline underline-offset-2 hover:text-gray-600', target: "_blank", href: navigationService.toExternalUrl(props.href), onClick: props.onClick }, children));
|
|
4014
|
-
};
|
|
4015
|
-
const PoweredByFlareFS = 'Powered by Flare FS';
|
|
4016
|
-
function pdsViewedAsync(name, usi) {
|
|
4017
|
-
return EventTrackingService.Instance.TrackSuperFundPdsViewedAsync({
|
|
4018
|
-
fundUsi: usi,
|
|
4019
|
-
fundName: name,
|
|
4020
|
-
pageName: 'Panel Fund Page',
|
|
4021
|
-
superCampaignEnabled: false
|
|
4022
|
-
});
|
|
4023
|
-
}
|
|
4024
|
-
|
|
4025
|
-
const Consent = class {
|
|
4026
|
-
constructor(hostRef) {
|
|
4027
|
-
index.registerInstance(this, hostRef);
|
|
4028
|
-
this.campaignConnectRequestInProgress = false;
|
|
4029
|
-
this.eventTrackingService = EventTrackingService.Instance;
|
|
4030
|
-
}
|
|
4031
|
-
componentDidLoad() {
|
|
4032
|
-
return this.eventTrackingService.TrackSuperFundDisclaimerViewedAsync(SuperFundDisclaimerViewedDetail.create(false));
|
|
4033
|
-
}
|
|
4034
|
-
render() {
|
|
4035
|
-
if (this.campaignConnectRequestInProgress) {
|
|
4036
|
-
return index.h("sss-loading-super-indicator", null);
|
|
4037
|
-
}
|
|
4038
|
-
return (index.h("div", null, index.h("div", { class: "text-2xl sm:text-3xl font-bold text-center leading-8" }, "Important information about super"), index.h("div", { class: "sm:text-lg text-gray-600 mt-3 sm:mt-4 max-w-800 text-center leading-7 sm:leading-8" }, "The choice of superannuation fund is an important personal financial decision. Next, you\u2019ll be asked to nominate a super fund to receive your employer contributions."), index.h("div", { class: "flex justify-center mt-8 sm:mt-12" }, index.h("div", { class: "border shadow-sm p-4 pb-6 sm:p-6 sm:pb-8 max-w-560 rounded-lg" }, index.h("div", { class: "sm:text-lg font-bold leading-6" }, "By clicking \u201CContinue\u201D you acknowledge that:"), index.h("ul", { class: "list-disc list-outside ml-6 mt-3 mb-6 space-y-2 text-sm leading-6" }, index.h("li", null, "Flare (we/us) provides this paperless employee management service, will feature superannuation funds and offer you employee benefits that you may be interested in;"), index.h("li", null, "all content contained in the following pages does not take into account any of your objectives, financial situation or needs and does not constitute financial product advice;"), index.h("li", null, "in featuring any superannuation funds, we, the technology partner you are accessing us via, or your employer, are not providing any opinion or recommendation (actual or implied) in relation to the suitability or appropriateness of the featured funds;"), index.h("li", null, "Trustees of the featured superannuation funds pay fees to Flare and/or its associates. Some funds pay us a fee if you choose one of the featured funds, while others pay us to have their application form on our platform;"), index.h("li", null, "in the event that you choose one of the featured superannuation funds, we may pass on your personal information and TFN to a related party for the purpose of completing your chosen fund's application form."), index.h("li", null, "Your personal data that is provided to us will be subject to our", ' ', index.h(Link, { className: "font-medium text-blue-600 hover:text-blue-800", href: "https://www.flarehr.com/privacy-policy" }, "Privacy Policy"), ".")), index.h("sss-button", { testid: "continue-button", fillWidth: true, promiseFn: () => this.handleSuperFundDisclaimerAccepted() }, "Continue")))));
|
|
4039
|
-
}
|
|
4040
|
-
async handleSuperFundDisclaimerAccepted() {
|
|
4041
|
-
await this.eventTrackingService.TrackSuperFundDisclaimerAcceptedAsync({
|
|
4042
|
-
superCampaignEnabled: false
|
|
4043
|
-
});
|
|
4044
|
-
if (superSelectionAppService.campaignConnectEnabled) {
|
|
4045
|
-
this.campaignConnectRequestInProgress = true;
|
|
4046
|
-
await superSelectionAppService.loadCampaignConnectAsync();
|
|
4047
|
-
if (superSelectionAppService.isDefinedBenefitsEligible &&
|
|
4048
|
-
Option.isSome(superSelectionAppService.definedBenefitsFundId)) {
|
|
4049
|
-
state.fund = {
|
|
4050
|
-
id: superSelectionAppService.definedBenefitsFundId.value,
|
|
4051
|
-
type: 'DefinedBenefits'
|
|
4052
|
-
};
|
|
4053
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.PromotedFundJoinV2);
|
|
4054
|
-
return;
|
|
4055
|
-
}
|
|
4056
|
-
}
|
|
4057
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
4058
|
-
}
|
|
4059
|
-
};
|
|
4060
|
-
injectHistory(Consent);
|
|
4061
|
-
|
|
4062
|
-
const ConsentWrapper = class {
|
|
4063
|
-
constructor(hostRef) {
|
|
4064
|
-
index.registerInstance(this, hostRef);
|
|
4065
|
-
}
|
|
4066
|
-
render() {
|
|
4067
|
-
return superSelectionAppService.state.superCampaignEnabled ? (index.h("sss-super-campaign-host", null)) : (index.h("sss-consent-page", null));
|
|
4068
|
-
}
|
|
4069
|
-
};
|
|
4070
|
-
injectHistory(ConsentWrapper);
|
|
3833
|
+
const navigationService = new NavigationService();
|
|
4071
3834
|
|
|
4072
3835
|
var CustomFundTypes;
|
|
4073
3836
|
(function (CustomFundTypes) {
|
|
@@ -4116,9 +3879,9 @@ const initialStateCustomFund = {
|
|
|
4116
3879
|
}
|
|
4117
3880
|
]
|
|
4118
3881
|
};
|
|
4119
|
-
const { state: state$
|
|
3882
|
+
const { state: state$1, reset } = createStore(initialStateCustomFund);
|
|
4120
3883
|
|
|
4121
|
-
const customFundOptions = state$
|
|
3884
|
+
const customFundOptions = state$1.customFunds;
|
|
4122
3885
|
const CustomFund = class {
|
|
4123
3886
|
constructor(hostRef) {
|
|
4124
3887
|
index.registerInstance(this, hostRef);
|
|
@@ -4173,67 +3936,173 @@ class AustralianFundLookupService {
|
|
|
4173
3936
|
}
|
|
4174
3937
|
const australianFundLookupService = new AustralianFundLookupService();
|
|
4175
3938
|
|
|
4176
|
-
class
|
|
4177
|
-
|
|
4178
|
-
return
|
|
4179
|
-
.url('super-choice/default')
|
|
4180
|
-
.post(dto)
|
|
4181
|
-
.badRequest(() => {
|
|
4182
|
-
throw new Error('Failed to process default fund join request');
|
|
4183
|
-
})
|
|
4184
|
-
.text();
|
|
4185
|
-
}
|
|
4186
|
-
async submitCustomFundChoiceAsync(dto) {
|
|
4187
|
-
return buildBackendApiClient()
|
|
4188
|
-
.url('super-choice/custom-fund')
|
|
4189
|
-
.post(dto)
|
|
4190
|
-
.badRequest(() => {
|
|
4191
|
-
throw new Error('Failed to process custom fund join request');
|
|
4192
|
-
})
|
|
4193
|
-
.text();
|
|
4194
|
-
}
|
|
4195
|
-
async submitSelfManagedFundChoiceAsync(dto) {
|
|
4196
|
-
return buildBackendApiClient()
|
|
4197
|
-
.url('super-choice/smsf')
|
|
4198
|
-
.post(dto)
|
|
4199
|
-
.badRequest(() => {
|
|
4200
|
-
throw new Error('Failed to process SMSF choice request');
|
|
4201
|
-
})
|
|
4202
|
-
.text();
|
|
4203
|
-
}
|
|
4204
|
-
async submitDefinedBenefitsChoiceAsync(dto) {
|
|
4205
|
-
return buildBackendApiClient()
|
|
4206
|
-
.url('super-choice/defined-benefits')
|
|
4207
|
-
.post(dto)
|
|
4208
|
-
.badRequest(() => {
|
|
4209
|
-
throw new Error('Failed to process Defined Benefits choice request');
|
|
4210
|
-
})
|
|
4211
|
-
.text();
|
|
3939
|
+
class EventTrackingApi {
|
|
3940
|
+
static get Instance() {
|
|
3941
|
+
return this.instance || (this.instance = new this());
|
|
4212
3942
|
}
|
|
4213
|
-
async
|
|
4214
|
-
|
|
4215
|
-
.url(`super-choice/smsf/${abn}/validate`)
|
|
4216
|
-
.get()
|
|
4217
|
-
.badRequest(() => {
|
|
4218
|
-
throw new Error('Failed to verify that if the provided abn is used for regulated fund');
|
|
4219
|
-
})
|
|
4220
|
-
.json();
|
|
4221
|
-
return response.result;
|
|
3943
|
+
async PostAnalyticsEventAsync(event) {
|
|
3944
|
+
return buildBackendApiClient().url('analytics-events').post(event).res();
|
|
4222
3945
|
}
|
|
4223
3946
|
}
|
|
4224
|
-
const customFundChoiceApi = new CustomFundChoiceApi();
|
|
4225
3947
|
|
|
4226
|
-
|
|
4227
|
-
constructor(
|
|
4228
|
-
|
|
4229
|
-
this.defaultFundProductName = 'Loading fund...';
|
|
4230
|
-
this.eventTrackingService = EventTrackingService.Instance;
|
|
3948
|
+
class EventTrackingService {
|
|
3949
|
+
constructor() {
|
|
3950
|
+
this.eventTrackingApi = EventTrackingApi.Instance;
|
|
4231
3951
|
}
|
|
4232
|
-
|
|
4233
|
-
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
3952
|
+
static get Instance() {
|
|
3953
|
+
return this.instance || (this.instance = new this());
|
|
3954
|
+
}
|
|
3955
|
+
async TrackSuperFundPdsViewedAsync(detail) {
|
|
3956
|
+
return this.trackEventAsync({
|
|
3957
|
+
SuperFundPdsViewed: detail
|
|
3958
|
+
});
|
|
3959
|
+
}
|
|
3960
|
+
async TrackPromotedSuperFundDetailViewedAsync(detail) {
|
|
3961
|
+
return this.trackEventAsync({
|
|
3962
|
+
SuperFundDetailViewed: {
|
|
3963
|
+
PromotedFund: detail
|
|
3964
|
+
}
|
|
3965
|
+
});
|
|
3966
|
+
}
|
|
3967
|
+
async TrackPromotedDefaultSuperFundDetailViewedAsync(detail) {
|
|
3968
|
+
return this.trackEventAsync({
|
|
3969
|
+
SuperFundDetailViewed: {
|
|
3970
|
+
PromotedDefaultFund: detail
|
|
3971
|
+
}
|
|
3972
|
+
});
|
|
3973
|
+
}
|
|
3974
|
+
async TrackMyOwnSuperFundDetailViewedAsync(detail) {
|
|
3975
|
+
return this.trackEventAsync({
|
|
3976
|
+
SuperFundDetailViewed: {
|
|
3977
|
+
MyOwnFund: detail
|
|
3978
|
+
}
|
|
3979
|
+
});
|
|
3980
|
+
}
|
|
3981
|
+
async TrackSmsfSuperFundDetailViewedAsync(detail) {
|
|
3982
|
+
return this.trackEventAsync({
|
|
3983
|
+
SuperFundDetailViewed: {
|
|
3984
|
+
Smsf: detail
|
|
3985
|
+
}
|
|
3986
|
+
});
|
|
3987
|
+
}
|
|
3988
|
+
async TrackDefaultSuperFundDetailViewedAsync(detail) {
|
|
3989
|
+
return this.trackEventAsync({
|
|
3990
|
+
SuperFundDetailViewed: {
|
|
3991
|
+
DefaultFund: detail
|
|
3992
|
+
}
|
|
3993
|
+
});
|
|
3994
|
+
}
|
|
3995
|
+
async TrackSuperFundNominationViewedAsync(detail) {
|
|
3996
|
+
return this.trackEventAsync({
|
|
3997
|
+
SuperFundNominationViewed: detail
|
|
3998
|
+
});
|
|
3999
|
+
}
|
|
4000
|
+
async TrackSuperFundNominationDeclinedAsync(detail) {
|
|
4001
|
+
return this.trackEventAsync({
|
|
4002
|
+
SuperFundNominationDeclined: detail
|
|
4003
|
+
});
|
|
4004
|
+
}
|
|
4005
|
+
async TrackSuperFundDisclaimerViewedAsync(detail) {
|
|
4006
|
+
return this.trackEventAsync({
|
|
4007
|
+
SuperFundDisclaimerViewed: detail
|
|
4008
|
+
});
|
|
4009
|
+
}
|
|
4010
|
+
async TrackSuperFundDisclaimerAcceptedAsync(detail) {
|
|
4011
|
+
return this.trackEventAsync({
|
|
4012
|
+
SuperFundDisclaimerAccepted: detail
|
|
4013
|
+
});
|
|
4014
|
+
}
|
|
4015
|
+
async TrackSuperFundPrefillViewedAsync(detail) {
|
|
4016
|
+
return this.trackEventAsync({
|
|
4017
|
+
SuperFundPrefillViewed: detail
|
|
4018
|
+
});
|
|
4019
|
+
}
|
|
4020
|
+
async TrackSuperFundPrefillDeclinedAsync(detail) {
|
|
4021
|
+
return this.trackEventAsync({
|
|
4022
|
+
SuperFundPrefillDeclined: detail
|
|
4023
|
+
});
|
|
4024
|
+
}
|
|
4025
|
+
async TrackSuperFundDetailChangeRequestedAsync(detail) {
|
|
4026
|
+
return this.trackEventAsync({
|
|
4027
|
+
SuperFundDetailChangeRequested: detail
|
|
4028
|
+
});
|
|
4029
|
+
}
|
|
4030
|
+
async TrackSuperCampaignActivationSucceededAsync(detail) {
|
|
4031
|
+
return this.trackEventAsync({
|
|
4032
|
+
SuperCampaignActivationSucceeded: detail
|
|
4033
|
+
});
|
|
4034
|
+
}
|
|
4035
|
+
async trackEventAsync(event) {
|
|
4036
|
+
try {
|
|
4037
|
+
await this.eventTrackingApi.PostAnalyticsEventAsync({ event });
|
|
4038
|
+
}
|
|
4039
|
+
catch (_a) {
|
|
4040
|
+
return;
|
|
4041
|
+
}
|
|
4042
|
+
}
|
|
4043
|
+
}
|
|
4044
|
+
|
|
4045
|
+
class CustomFundChoiceApi {
|
|
4046
|
+
async submitDefaultFundChoiceAsync(dto) {
|
|
4047
|
+
return buildBackendApiClient()
|
|
4048
|
+
.url('super-choice/default')
|
|
4049
|
+
.post(dto)
|
|
4050
|
+
.badRequest(() => {
|
|
4051
|
+
throw new Error('Failed to process default fund join request');
|
|
4052
|
+
})
|
|
4053
|
+
.text();
|
|
4054
|
+
}
|
|
4055
|
+
async submitCustomFundChoiceAsync(dto) {
|
|
4056
|
+
return buildBackendApiClient()
|
|
4057
|
+
.url('super-choice/custom-fund')
|
|
4058
|
+
.post(dto)
|
|
4059
|
+
.badRequest(() => {
|
|
4060
|
+
throw new Error('Failed to process custom fund join request');
|
|
4061
|
+
})
|
|
4062
|
+
.text();
|
|
4063
|
+
}
|
|
4064
|
+
async submitSelfManagedFundChoiceAsync(dto) {
|
|
4065
|
+
return buildBackendApiClient()
|
|
4066
|
+
.url('super-choice/smsf')
|
|
4067
|
+
.post(dto)
|
|
4068
|
+
.badRequest(() => {
|
|
4069
|
+
throw new Error('Failed to process SMSF choice request');
|
|
4070
|
+
})
|
|
4071
|
+
.text();
|
|
4072
|
+
}
|
|
4073
|
+
async submitDefinedBenefitsChoiceAsync(dto) {
|
|
4074
|
+
return buildBackendApiClient()
|
|
4075
|
+
.url('super-choice/defined-benefits')
|
|
4076
|
+
.post(dto)
|
|
4077
|
+
.badRequest(() => {
|
|
4078
|
+
throw new Error('Failed to process Defined Benefits choice request');
|
|
4079
|
+
})
|
|
4080
|
+
.text();
|
|
4081
|
+
}
|
|
4082
|
+
async validateAbnForSMSF(abn) {
|
|
4083
|
+
const response = await buildBackendApiClient()
|
|
4084
|
+
.url(`super-choice/smsf/${abn}/validate`)
|
|
4085
|
+
.get()
|
|
4086
|
+
.badRequest(() => {
|
|
4087
|
+
throw new Error('Failed to verify that if the provided abn is used for regulated fund');
|
|
4088
|
+
})
|
|
4089
|
+
.json();
|
|
4090
|
+
return response.result;
|
|
4091
|
+
}
|
|
4092
|
+
}
|
|
4093
|
+
const customFundChoiceApi = new CustomFundChoiceApi();
|
|
4094
|
+
|
|
4095
|
+
const DefaultFund = class {
|
|
4096
|
+
constructor(hostRef) {
|
|
4097
|
+
index.registerInstance(this, hostRef);
|
|
4098
|
+
this.defaultFundProductName = 'Loading fund...';
|
|
4099
|
+
this.eventTrackingService = EventTrackingService.Instance;
|
|
4100
|
+
}
|
|
4101
|
+
async componentWillLoad() {
|
|
4102
|
+
const defaultFundUsi = superSelectionAppService.defaultFundUsi;
|
|
4103
|
+
if (Option.isNone(defaultFundUsi)) {
|
|
4104
|
+
return;
|
|
4105
|
+
}
|
|
4237
4106
|
this.isDefaultFundExists = true;
|
|
4238
4107
|
const defaultFundSearchResult = await australianFundLookupService.getFundAsync(defaultFundUsi.value, true);
|
|
4239
4108
|
if (Option.isNone(defaultFundSearchResult)) {
|
|
@@ -4442,466 +4311,6 @@ const SelectInputAsync = class {
|
|
|
4442
4311
|
};
|
|
4443
4312
|
SelectInputAsync.style = dropdownAsyncCss;
|
|
4444
4313
|
|
|
4445
|
-
const name = 'Active Super';
|
|
4446
|
-
const fund = {
|
|
4447
|
-
fundId: 'active',
|
|
4448
|
-
name,
|
|
4449
|
-
logo: 'logo-active.svg',
|
|
4450
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV1,
|
|
4451
|
-
features: [
|
|
4452
|
-
index.h("p", null, "Winner of Canstar's 2023 Outstanding Value \u2013 Superannuation Award considering investment performance, fees and product features*"),
|
|
4453
|
-
index.h("p", null, "Recognised as a leader in responsible investment"),
|
|
4454
|
-
index.h("p", null, "Calls answered in 20 seconds (average over 5 years)")
|
|
4455
|
-
],
|
|
4456
|
-
featureSubText: (index.h("span", null, "*Based on a comparison of the Active Super Accumulation Scheme held by those aged 20-69 years and balances between $30,000 and $1.5 million.")),
|
|
4457
|
-
disclaimer: (index.h("p", null,
|
|
4458
|
-
"Issued by LGSS Pty Limited as trustee for Local Government Super (Active Super ABN:28 901 371 321). Consider the PDS and TMD at",
|
|
4459
|
-
' ',
|
|
4460
|
-
index.h(Link, { onClick: () => pdsViewedAsync(name), href: "https://www.activesuper.com.au/pds" }, "activesuper.com.au"),
|
|
4461
|
-
' ',
|
|
4462
|
-
"before making a decision.")),
|
|
4463
|
-
footnoteTextOverride: Option.some(PoweredByFlareFS),
|
|
4464
|
-
dtoPropName: 'active'
|
|
4465
|
-
};
|
|
4466
|
-
|
|
4467
|
-
const name$1 = 'Australian Ethical';
|
|
4468
|
-
const pdsUrl = 'https://www.australianethical.com.au/super/pds-forms/';
|
|
4469
|
-
const fund$1 = {
|
|
4470
|
-
fundId: 'australian-ethical',
|
|
4471
|
-
name: name$1,
|
|
4472
|
-
logo: 'logo-aus-eth.svg',
|
|
4473
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4474
|
-
features: [
|
|
4475
|
-
index.h("p", null,
|
|
4476
|
-
"Fastest growing super fund in Australia",
|
|
4477
|
-
index.h("sup", { class: "text-tiny" }, "1")),
|
|
4478
|
-
index.h("p", null,
|
|
4479
|
-
"Nil investments in fossil fuel companies",
|
|
4480
|
-
index.h("sup", { class: "text-tiny" }, "2")),
|
|
4481
|
-
index.h("p", null, "Competitive returns")
|
|
4482
|
-
],
|
|
4483
|
-
featureSubText: (index.h("ol", { class: "list-decimal list-outside ml-3" },
|
|
4484
|
-
index.h("li", null, "Source: KPMG Super Insights Report 2022."),
|
|
4485
|
-
index.h("li", null, "All our options go through positive and negative ethical screening in accordance with the Australian Ethical Charter (in place since 1986)."))),
|
|
4486
|
-
disclaimer: (index.h("p", null,
|
|
4487
|
-
"Issued by Australian Ethical Superannuation Pty Ltd (ABN 43 079 259 733, RSE L0001441, AFSL 526055). Please consider the",
|
|
4488
|
-
' ',
|
|
4489
|
-
index.h(Link, { href: "https://www.australianethical.com.au/globalassets/pdf-files/forms--pds/superpension/important-information/ae-financial-services-guide_sec.pdf" }, "Financial Services Guide"),
|
|
4490
|
-
", the",
|
|
4491
|
-
' ',
|
|
4492
|
-
index.h(Link, { href: pdsUrl, onClick: () => pdsViewedAsync(name$1) }, "Product Disclosure Statement"),
|
|
4493
|
-
' ',
|
|
4494
|
-
"and",
|
|
4495
|
-
' ',
|
|
4496
|
-
index.h(Link, { href: pdsUrl, onClick: () => pdsViewedAsync(name$1) }, "Target Market Determination"),
|
|
4497
|
-
' ',
|
|
4498
|
-
"available on our",
|
|
4499
|
-
' ',
|
|
4500
|
-
index.h(Link, { href: pdsUrl, onClick: () => pdsViewedAsync(name$1) }, "website"),
|
|
4501
|
-
".")),
|
|
4502
|
-
footnoteTextOverride: Option.none,
|
|
4503
|
-
dtoPropName: 'australianEthical'
|
|
4504
|
-
};
|
|
4505
|
-
|
|
4506
|
-
const name$2 = 'Australian Retirement Trust';
|
|
4507
|
-
const fund$2 = {
|
|
4508
|
-
fundId: 'australian-retirement-trust',
|
|
4509
|
-
name: name$2,
|
|
4510
|
-
logo: 'logo-art.svg',
|
|
4511
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV1,
|
|
4512
|
-
features: [
|
|
4513
|
-
index.h("p", null, "$200 billion in retirement savings"),
|
|
4514
|
-
index.h("p", null, "2+ million members"),
|
|
4515
|
-
index.h("p", null, "A focus on delivering strong, long\u2011term returns")
|
|
4516
|
-
],
|
|
4517
|
-
featureSubText: (index.h("span", null, "QSuper is now part of Australian Retirement Trust. If you have an existing QSuper account, you will continue to hold that account by selecting this option.")),
|
|
4518
|
-
disclaimer: (index.h("p", null,
|
|
4519
|
-
"You should consider the",
|
|
4520
|
-
' ',
|
|
4521
|
-
index.h(Link, { href: "https://www.australianretirementtrust.com.au/library/media/pdfs/pds/super-savings-product-disclosure-statement-and-membership-form.pdf", onClick: () => pdsViewedAsync(name$2) }, "Product Disclosure Statement"),
|
|
4522
|
-
' ',
|
|
4523
|
-
"and",
|
|
4524
|
-
' ',
|
|
4525
|
-
index.h(Link, { href: "https://www.australianretirementtrust.com.au/tmd" }, "Target Market Determination"),
|
|
4526
|
-
' ',
|
|
4527
|
-
"before deciding to invest in or apply to become a member of this fund.")),
|
|
4528
|
-
abnInfo: name$2,
|
|
4529
|
-
abn: '60 905 115 063',
|
|
4530
|
-
footnoteTextOverride: Option.none,
|
|
4531
|
-
dtoPropName: 'australianRetirementTrust'
|
|
4532
|
-
};
|
|
4533
|
-
|
|
4534
|
-
const name$3 = 'Aware Super';
|
|
4535
|
-
const fund$3 = {
|
|
4536
|
-
fundId: 'aware',
|
|
4537
|
-
name: name$3,
|
|
4538
|
-
logo: 'logo-aware.svg',
|
|
4539
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV1,
|
|
4540
|
-
features: [
|
|
4541
|
-
index.h("p", null, "Awarded Canstar\u2019s Outstanding Value Super^ in 2022 and 2023."),
|
|
4542
|
-
index.h("p", null,
|
|
4543
|
-
"Over 1 million",
|
|
4544
|
-
index.h("sup", { class: "text-tiny" }, "\u2021"),
|
|
4545
|
-
" Australians trust us with their super."),
|
|
4546
|
-
index.h("p", null, "Our super helpful app helps you stay in control of your super.")
|
|
4547
|
-
],
|
|
4548
|
-
featureSubText: (index.h("div", { class: "space-y-0.5" },
|
|
4549
|
-
index.h("p", null,
|
|
4550
|
-
"^ See ",
|
|
4551
|
-
index.h(Link, { href: "https://aware.com.au/awards" }, "aware.com.au/awards"),
|
|
4552
|
-
" for more information"),
|
|
4553
|
-
index.h("p", null,
|
|
4554
|
-
index.h("sup", { class: "text-tiny" }, "\u2021"),
|
|
4555
|
-
" Member numbers as of December 2023"))),
|
|
4556
|
-
disclaimer: (index.h("p", null,
|
|
4557
|
-
"You should consider the",
|
|
4558
|
-
' ',
|
|
4559
|
-
index.h(Link, { href: "https://aware.com.au/member/campaign/flare-documents?cid=par-aq-no-su-Flare-PDSTMD-Direct-ImpDocs-", onClick: () => pdsViewedAsync(name$3) }, "Product Disclosure Statement and Target Market Determination"),
|
|
4560
|
-
' ',
|
|
4561
|
-
"before deciding to invest in or apply to become a member of this fund.")),
|
|
4562
|
-
abnInfo: `Aware Super Pty Ltd`,
|
|
4563
|
-
abn: '53 226 460 365',
|
|
4564
|
-
footnoteTextOverride: Option.none,
|
|
4565
|
-
dtoPropName: 'aware'
|
|
4566
|
-
};
|
|
4567
|
-
|
|
4568
|
-
const name$4 = 'First Super';
|
|
4569
|
-
const fund$4 = {
|
|
4570
|
-
fundId: 'first-super',
|
|
4571
|
-
name: name$4,
|
|
4572
|
-
logo: 'logo-first.svg',
|
|
4573
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4574
|
-
features: [
|
|
4575
|
-
index.h("p", null, "Industry SuperFund that offers five investment options and default insurance"),
|
|
4576
|
-
index.h("p", null, "Strong long-term investment returns and superior customer service - members first"),
|
|
4577
|
-
index.h("p", null, "Established super fund \u2013 anyone can join including KiwiSaver members")
|
|
4578
|
-
],
|
|
4579
|
-
disclaimer: (index.h("div", null,
|
|
4580
|
-
index.h("p", null,
|
|
4581
|
-
"General advice only which has been prepared without taking into account your objectives, financial situation or needs. Consider whether the advice is appropriate for you and read the Product Disclosure Statement (PDS) before making any investment decisions. PDS and Target Market Determination are available at our",
|
|
4582
|
-
' ',
|
|
4583
|
-
index.h(Link, { onClick: () => pdsViewedAsync(name$4), href: "https://www.firstsuper.com.au/forms-tools/product-disclosure-statements/" }, "website"),
|
|
4584
|
-
". Past performance is not a reliable indicator of future performance."),
|
|
4585
|
-
index.h("br", null),
|
|
4586
|
-
index.h("p", null, "Issued by First Super Pty Ltd ABN 42 053 498 472, AFSL 223988 (Trustee) as Trustee of First Super ABN 56 286 625 181."))),
|
|
4587
|
-
footnoteTextOverride: Option.none,
|
|
4588
|
-
dtoPropName: 'firstSuper'
|
|
4589
|
-
};
|
|
4590
|
-
|
|
4591
|
-
const name$5 = 'HESTA';
|
|
4592
|
-
const fund$5 = {
|
|
4593
|
-
fundId: 'hesta-default',
|
|
4594
|
-
name: name$5,
|
|
4595
|
-
logo: 'logo-hesta.svg',
|
|
4596
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4597
|
-
features: [
|
|
4598
|
-
index.h("p", null, "A top-performing super fund* working for real-world impact"),
|
|
4599
|
-
index.h("p", null, "1+ million members"),
|
|
4600
|
-
index.h("p", null, "Expert help whenever you need it to help you face the future with confidence")
|
|
4601
|
-
],
|
|
4602
|
-
featureSubText: undefined,
|
|
4603
|
-
disclaimer: (index.h("div", { class: "space-y-2" },
|
|
4604
|
-
index.h("p", { class: "italic" },
|
|
4605
|
-
"* SuperRatings 10 Year Platinum Performance 2014-2024 (MySuper). Investment performance contributes to but is not the only factor in determining this product rating. Product ratings and awards are only one factor to be considered. See",
|
|
4606
|
-
' ',
|
|
4607
|
-
index.h(Link, { className: "underline underline-offset-2 hover:text-gray-600", href: "https://www.hesta.com.au/ratings" }, "hesta.com.au/ratings"),
|
|
4608
|
-
' ',
|
|
4609
|
-
"for more information."),
|
|
4610
|
-
index.h("p", null,
|
|
4611
|
-
"Consider whether this product is appropriate for you by reading the Product Disclosure Statement and Target Market Determination at",
|
|
4612
|
-
' ',
|
|
4613
|
-
index.h(Link, { onClick: () => pdsViewedAsync(name$5), href: "https://www.hesta.com.au/pds" }, "hesta.com.au/pds"),
|
|
4614
|
-
' ',
|
|
4615
|
-
"In considering your own circumstances about the suitability of HESTA products, you may wish to consult an adviser or use the ATO YourSuper comparison tool. Please also consider the relevant risks."),
|
|
4616
|
-
index.h("p", null, "Issued by H.E.S.T. Australia Ltd ABN 66 006 818 695 AFSL No. 235249, Trustee of HESTA"))),
|
|
4617
|
-
footnoteTextOverride: Option.none,
|
|
4618
|
-
isPromotedDefault: true
|
|
4619
|
-
};
|
|
4620
|
-
|
|
4621
|
-
const name$6 = 'Mercer MyChoice';
|
|
4622
|
-
const fund$6 = {
|
|
4623
|
-
fundId: 'mercermychoice',
|
|
4624
|
-
name: name$6,
|
|
4625
|
-
logo: 'logo-mercer-mychoice.svg',
|
|
4626
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4627
|
-
features: [
|
|
4628
|
-
index.h("p", null, "Save more super with our low fees"),
|
|
4629
|
-
index.h("p", null, "Take control with 6 MyChoice investment options"),
|
|
4630
|
-
index.h("p", null, "Join 850,000 Australians who trust our global expertise")
|
|
4631
|
-
],
|
|
4632
|
-
disclaimer: (index.h("div", null,
|
|
4633
|
-
index.h("p", null,
|
|
4634
|
-
"You should consider the",
|
|
4635
|
-
' ',
|
|
4636
|
-
index.h(Link, { href: "https://www.mercersuper.com.au/campaign-page/mercer-mychoice", onClick: () => pdsViewedAsync(name$6) }, "Product Disclosure Statement"),
|
|
4637
|
-
' ',
|
|
4638
|
-
"and",
|
|
4639
|
-
' ',
|
|
4640
|
-
index.h(Link, { href: "https://www.mercersuper.com.au/documents/target-market-determinations" }, "Target Market Determination"),
|
|
4641
|
-
' ',
|
|
4642
|
-
"before deciding to invest in or apply to become a member of the fund."),
|
|
4643
|
-
index.h("br", null),
|
|
4644
|
-
index.h("p", null, "Issued by Mercer Superannuation (Australia) Limited (\u2018Mercer Super\u2019) ABN: 79 004 717 533"))),
|
|
4645
|
-
footnoteTextOverride: Option.some(PoweredByFlareFS),
|
|
4646
|
-
dtoPropName: 'mercerMyChoice',
|
|
4647
|
-
extraBadge: (index.h("span", { class: "text-xs bg-green-100 text-green-800 font-medium rounded-xl py-0.5 px-2.5 mr-1" }, "Low fees"))
|
|
4648
|
-
};
|
|
4649
|
-
|
|
4650
|
-
const name$7 = 'REI Super';
|
|
4651
|
-
const fund$7 = {
|
|
4652
|
-
fundId: 'reisuper',
|
|
4653
|
-
name: name$7,
|
|
4654
|
-
logo: 'logo-rei.svg',
|
|
4655
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4656
|
-
features: [
|
|
4657
|
-
index.h("p", null, "Built by and for the real estate industry"),
|
|
4658
|
-
index.h("p", null, "Consistent long-term performance with competitive fees*"),
|
|
4659
|
-
index.h("p", null, "All profits to members, not shareholders")
|
|
4660
|
-
],
|
|
4661
|
-
disclaimer: (index.h("div", { class: "space-y-2" },
|
|
4662
|
-
index.h("p", null, "*Balanced Option net investment return of 9.45% for year ending 30 June 2023."),
|
|
4663
|
-
index.h("p", null,
|
|
4664
|
-
"You should consider the",
|
|
4665
|
-
' ',
|
|
4666
|
-
index.h(Link, { href: "https://www.reisuper.com.au/docs/default-source/super/rei-super-pds.pdf?utm_source=flarehr&utm_medium=banners&utm_campaign=flarehr_join&utm_term=pds", onClick: () => pdsViewedAsync(name$7) }, "Product Disclosure Statement"),
|
|
4667
|
-
' ',
|
|
4668
|
-
"and",
|
|
4669
|
-
' ',
|
|
4670
|
-
index.h(Link, { href: "https://www.reisuper.com.au/publications-and-forms/target-market-determination?utm_source=flarehr&utm_medium=banners&utm_campaign=flarehr_join&utm_term=tmd" }, "Target Market Determination"),
|
|
4671
|
-
' ',
|
|
4672
|
-
"before deciding to invest in or apply to become a member of the fund."))),
|
|
4673
|
-
abnInfo: `REI Superannuation Fund Pty Ltd`,
|
|
4674
|
-
abn: '68 056 044 770',
|
|
4675
|
-
footnoteTextOverride: Option.none,
|
|
4676
|
-
dtoPropName: 'reisuper'
|
|
4677
|
-
};
|
|
4678
|
-
|
|
4679
|
-
const name$8 = 'Slate Super';
|
|
4680
|
-
const slateUsi = '32367272075001';
|
|
4681
|
-
const fund$8 = {
|
|
4682
|
-
fundId: 'slate',
|
|
4683
|
-
name: name$8,
|
|
4684
|
-
logo: 'logo-slate.png',
|
|
4685
|
-
route: SuperSelectionAppRoutes.SlateJoin,
|
|
4686
|
-
features: [
|
|
4687
|
-
index.h("p", null, "A lifestage investment strategy that evolves with you"),
|
|
4688
|
-
index.h("p", null, "Advanced mobile app with retirement forecast and smart features"),
|
|
4689
|
-
index.h("p", null, "Member advocates at Slate to assist with your account")
|
|
4690
|
-
],
|
|
4691
|
-
disclaimer: (index.h("p", { class: "small text-muted" },
|
|
4692
|
-
"You should consider the",
|
|
4693
|
-
' ',
|
|
4694
|
-
index.h(Link, { href: "https://slate.co/pds/?utm_source=flare&utm_medium=superselection", onClick: () => pdsViewedAsync(name$8, slateUsi) }, "Product Disclosure Statement"),
|
|
4695
|
-
' ',
|
|
4696
|
-
"and",
|
|
4697
|
-
' ',
|
|
4698
|
-
index.h(Link, { href: "https://slate.co/forms-and-documents/target-market-determination/" }, "Target Market Determination"),
|
|
4699
|
-
' ',
|
|
4700
|
-
"before deciding to invest in or apply to become a member of the fund.")),
|
|
4701
|
-
abnInfo: `Diversa Trustees Limited`,
|
|
4702
|
-
abn: '49 006 421 638',
|
|
4703
|
-
footnoteTextOverride: Option.none,
|
|
4704
|
-
dtoPropName: 'slate'
|
|
4705
|
-
};
|
|
4706
|
-
|
|
4707
|
-
const name$9 = 'Spirit Super';
|
|
4708
|
-
const fund$9 = {
|
|
4709
|
-
fundId: 'spirit',
|
|
4710
|
-
name: name$9,
|
|
4711
|
-
logo: 'logo-spirit.svg',
|
|
4712
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4713
|
-
features: [
|
|
4714
|
-
index.h("p", null, "Proud Industry SuperFund - all profits go back to members"),
|
|
4715
|
-
index.h("p", null,
|
|
4716
|
-
"Best customer experience in super",
|
|
4717
|
-
index.h("sup", { class: "text-tiny" }, "1"),
|
|
4718
|
-
" and best for value",
|
|
4719
|
-
index.h("sup", { class: "text-tiny" }, "2")),
|
|
4720
|
-
index.h("p", null,
|
|
4721
|
-
"Low fees",
|
|
4722
|
-
index.h("sup", { class: "text-tiny" }, "3"),
|
|
4723
|
-
" with a focus on strong returns and investing with impact in communities",
|
|
4724
|
-
index.h("sup", { class: "text-tiny" }, "4"))
|
|
4725
|
-
],
|
|
4726
|
-
featureSubText: (index.h("div", { class: "m-4 pt-2" },
|
|
4727
|
-
index.h("ol", { class: "list-decimal space-y-2" },
|
|
4728
|
-
index.h("li", null,
|
|
4729
|
-
index.h("span", null, "CSBA SenseCX Benchmark 2021-22")),
|
|
4730
|
-
index.h("li", null,
|
|
4731
|
-
index.h("span", null, "Awarded Best for Value in the WeMoney Superannuation Awards 2022")),
|
|
4732
|
-
index.h("li", null,
|
|
4733
|
-
index.h("span", null, "Just $67.60 + 0.15% pa admin fees, capped at $517.60")),
|
|
4734
|
-
index.h("li", null,
|
|
4735
|
-
index.h("span", null, "Rainmaker ESG Leader Rating 2022"))))),
|
|
4736
|
-
disclaimer: (index.h("p", null,
|
|
4737
|
-
"Past performance isn\u2019t a reliable indicator of future performance. Consider the PDS and TMD at",
|
|
4738
|
-
' ',
|
|
4739
|
-
index.h(Link, { href: "https://www.spiritsuper.com.au/pds", onClick: () => pdsViewedAsync(name$9) }, "www.spiritsuper.com.au/pds"),
|
|
4740
|
-
' ',
|
|
4741
|
-
"before making a decision. Issuer is Motor Trades Association of Australia Superannuation Fund Pty Ltd (AFSL 238 718, ABN 14 008 650 628), the trustee of Spirit Super (ABN 74 559 365 913). Advice is provided by Quadrant First Pty Ltd (ABN 78 102 167 877, AFSL 284443).")),
|
|
4742
|
-
footnoteTextOverride: Option.none,
|
|
4743
|
-
dtoPropName: 'spirit'
|
|
4744
|
-
};
|
|
4745
|
-
|
|
4746
|
-
const name$a = 'Unisuper';
|
|
4747
|
-
const pdsUrl$1 = 'https://www.unisuper.com.au/-/media/files/pds/accumulation-1/accumulation-1-pds.pdf?rev=eb3a50fed45543ef91e2d1a38fa1fc0b&hash=B76A6A338550310C27DE1A021C854F84';
|
|
4748
|
-
const tmdUrl = 'https://www.unisuper.com.au/-/media/files/tmd/accumulation-1/accumulation-1-tmd.pdf?rev=f4aa3f08d0494f52a7a5e02c69385ead&hash=AC77283EFBF97948DC0CF768FD3E82F8';
|
|
4749
|
-
const fund$a = {
|
|
4750
|
-
fundId: 'unisuper-default',
|
|
4751
|
-
name: name$a,
|
|
4752
|
-
logo: 'logo-unisuper.svg',
|
|
4753
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4754
|
-
features: [
|
|
4755
|
-
index.h("p", null, "Low fees, better value \u2013 Our fees are among the lowest in the industry.^"),
|
|
4756
|
-
index.h("p", null, "Strong, long-term performance \u2013 We regularly exceed industry averages.*"),
|
|
4757
|
-
index.h("p", null,
|
|
4758
|
-
"Award winning super \u2013 Continually recognised as one of Australia\u2019s best-performing funds.",
|
|
4759
|
-
index.h("sup", { class: "text-tiny" }, "#"))
|
|
4760
|
-
],
|
|
4761
|
-
disclaimer: (index.h("div", { class: "space-y-2" },
|
|
4762
|
-
index.h("p", null,
|
|
4763
|
-
"^Read more about our fees and how we compare",
|
|
4764
|
-
' ',
|
|
4765
|
-
index.h(Link, { href: "https://www.unisuper.com.au/super/products-and-fees" }, "here"),
|
|
4766
|
-
"."),
|
|
4767
|
-
index.h("p", null,
|
|
4768
|
-
"*Past performance is not an indicator of future performance. Read more about our performance and how we compare",
|
|
4769
|
-
' ',
|
|
4770
|
-
index.h(Link, { href: "https://www.unisuper.com.au/campaigns/greater-super" }, "here"),
|
|
4771
|
-
"."),
|
|
4772
|
-
index.h("p", null,
|
|
4773
|
-
index.h("sup", { class: "text-tiny" }, "#"),
|
|
4774
|
-
"See our awards",
|
|
4775
|
-
' ',
|
|
4776
|
-
index.h(Link, { href: "https://www.unisuper.com.au/about-us/who-we-are/awards-and-ratings" }, "here"),
|
|
4777
|
-
"."),
|
|
4778
|
-
index.h("p", null,
|
|
4779
|
-
"Remember to consider the",
|
|
4780
|
-
' ',
|
|
4781
|
-
index.h(Link, { href: pdsUrl$1, onClick: () => pdsViewedAsync(name$a) }, "Product Disclosure Statement"),
|
|
4782
|
-
' ',
|
|
4783
|
-
"and ",
|
|
4784
|
-
index.h(Link, { href: tmdUrl }, "Target Market Determination"),
|
|
4785
|
-
" that is relevant to you."),
|
|
4786
|
-
index.h("p", null, "Issued by UniSuper Management Pty Ltd. ABN: 91 385 943 850"))),
|
|
4787
|
-
footnoteTextOverride: Option.none,
|
|
4788
|
-
isPromotedDefault: true
|
|
4789
|
-
};
|
|
4790
|
-
|
|
4791
|
-
const name$b = 'Unisuper';
|
|
4792
|
-
const pdsUrl$2 = 'https://www.unisuper.com.au/-/media/files/pds/accumulation-1/accumulation-1-pds.pdf?rev=eb3a50fed45543ef91e2d1a38fa1fc0b&hash=B76A6A338550310C27DE1A021C854F84';
|
|
4793
|
-
const tmdUrl$1 = 'https://www.unisuper.com.au/-/media/files/tmd/accumulation-1/accumulation-1-tmd.pdf?rev=f4aa3f08d0494f52a7a5e02c69385ead&hash=AC77283EFBF97948DC0CF768FD3E82F8';
|
|
4794
|
-
const fund$b = {
|
|
4795
|
-
fundId: 'unisuper-default-v2',
|
|
4796
|
-
name: name$b,
|
|
4797
|
-
logo: 'logo-unisuper.svg',
|
|
4798
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4799
|
-
features: [
|
|
4800
|
-
index.h("p", null, "Low fees, better value \u2013 Our fees are among the lowest in the industry.^"),
|
|
4801
|
-
index.h("p", null, "Strong, long-term performance \u2013 We regularly exceed industry averages.*"),
|
|
4802
|
-
index.h("p", null,
|
|
4803
|
-
"Award winning super \u2013 Continually recognised as one of Australia\u2019s best-performing funds.",
|
|
4804
|
-
index.h("sup", { class: "text-tiny" }, "#"))
|
|
4805
|
-
],
|
|
4806
|
-
customContent: (index.h("div", { class: "mt-6 flex gap-3" },
|
|
4807
|
-
index.h("div", null,
|
|
4808
|
-
index.h("img", { alt: name$b, src: index.getAssetPath(`assets/unisuper-default-badge1.svg`) })),
|
|
4809
|
-
index.h("div", null,
|
|
4810
|
-
index.h("img", { alt: name$b, src: index.getAssetPath(`assets/unisuper-default-badge2.svg`) })),
|
|
4811
|
-
index.h("div", null,
|
|
4812
|
-
index.h("img", { alt: name$b, src: index.getAssetPath(`assets/unisuper-default-badge3.svg`) })))),
|
|
4813
|
-
disclaimer: (index.h("div", { class: "space-y-2" },
|
|
4814
|
-
index.h("p", null,
|
|
4815
|
-
"^Read more about our fees and how we compare",
|
|
4816
|
-
' ',
|
|
4817
|
-
index.h(Link, { href: "https://www.unisuper.com.au/super/products-and-fees" }, "here"),
|
|
4818
|
-
"."),
|
|
4819
|
-
index.h("p", null,
|
|
4820
|
-
"*Past performance is not an indicator of future performance. Read more about our performance and how we compare",
|
|
4821
|
-
' ',
|
|
4822
|
-
index.h(Link, { href: "https://www.unisuper.com.au/campaigns/greater-super" }, "here"),
|
|
4823
|
-
"."),
|
|
4824
|
-
index.h("p", null,
|
|
4825
|
-
index.h("sup", { class: "text-tiny" }, "#"),
|
|
4826
|
-
"See our awards",
|
|
4827
|
-
' ',
|
|
4828
|
-
index.h(Link, { href: "https://www.unisuper.com.au/about-us/who-we-are/awards-and-ratings" }, "here"),
|
|
4829
|
-
"."),
|
|
4830
|
-
index.h("p", null,
|
|
4831
|
-
"Remember to consider the",
|
|
4832
|
-
' ',
|
|
4833
|
-
index.h(Link, { href: pdsUrl$2, onClick: () => pdsViewedAsync(name$b) }, "Product Disclosure Statement"),
|
|
4834
|
-
' ',
|
|
4835
|
-
"and ",
|
|
4836
|
-
index.h(Link, { href: tmdUrl$1 }, "Target Market Determination"),
|
|
4837
|
-
" that is relevant to you."),
|
|
4838
|
-
index.h("p", null, "Issued by UniSuper Management Pty Ltd. ABN: 91 385 943 850"))),
|
|
4839
|
-
footnoteTextOverride: Option.none,
|
|
4840
|
-
isPromotedDefault: true
|
|
4841
|
-
};
|
|
4842
|
-
|
|
4843
|
-
const name$c = 'Virgin Money Super';
|
|
4844
|
-
const fund$c = {
|
|
4845
|
-
fundId: 'virgin',
|
|
4846
|
-
name: name$c,
|
|
4847
|
-
logo: 'logo-virgin.svg',
|
|
4848
|
-
route: SuperSelectionAppRoutes.PromotedFundJoinV2,
|
|
4849
|
-
features: [
|
|
4850
|
-
index.h("p", null,
|
|
4851
|
-
"Returns above industry and retail super fund medians over the past 5 years",
|
|
4852
|
-
index.h("sup", { class: "text-tiny" }, "1")),
|
|
4853
|
-
index.h("p", null, "One of the lowest fees in the market"),
|
|
4854
|
-
index.h("p", null,
|
|
4855
|
-
"Virgin Money rewards you with Velocity Points on your contributions",
|
|
4856
|
-
index.h("sup", { class: "text-tiny" }, "2"))
|
|
4857
|
-
],
|
|
4858
|
-
featureSubText: (index.h("div", { class: "m-4 pt-2" },
|
|
4859
|
-
index.h("ol", { class: "list-decimal space-y-2" },
|
|
4860
|
-
index.h("li", null,
|
|
4861
|
-
index.h("span", null, "Past performance is not a reliable indicator of future performance. Source: SuperRatings Fund Crediting Rate Survey April 2022.")),
|
|
4862
|
-
index.h("li", null,
|
|
4863
|
-
index.h("span", null,
|
|
4864
|
-
index.h(Link, { className: "underline underline-offset-2 hover:text-gray-600", href: "https://virginmoney.com.au/superannuation/forms-and-key-information/key-documents" }, "Eligibility and T&Cs apply")))))),
|
|
4865
|
-
disclaimer: (index.h("p", null,
|
|
4866
|
-
"Prepared by Virgin Money Financial Services Pty Ltd ABN 51 113 285 395 AFSL 286869 (\u2018Virgin Money\u2019). Virgin Money Super is a plan in the Mercer Super Trust ABN 19 905 422 981. Virgin Money Super is issued by Mercer Superannuation (Australia) Limited (MSAL) ABN 79 004 717 533 AFSL 235906 as trustee of the Mercer Super Trust. Consider the PDS and TMD at",
|
|
4867
|
-
' ',
|
|
4868
|
-
index.h(Link, { href: "https://virginmoney.com.au/superannuation/", onClick: () => pdsViewedAsync(name$c) }, "www.virginmoney.com.au"),
|
|
4869
|
-
' ',
|
|
4870
|
-
"before making a decision")),
|
|
4871
|
-
footnoteTextOverride: Option.some(PoweredByFlareFS),
|
|
4872
|
-
dtoPropName: 'virgin',
|
|
4873
|
-
extraBadge: (index.h("span", { class: "text-xs bg-green-100 text-green-800 font-medium rounded-xl py-0.5 px-2.5 mr-1" }, "Low fees"))
|
|
4874
|
-
};
|
|
4875
|
-
|
|
4876
|
-
const fundsById = {
|
|
4877
|
-
[fund$8.fundId]: fund$8,
|
|
4878
|
-
[fund$2.fundId]: fund$2,
|
|
4879
|
-
[fund$3.fundId]: fund$3,
|
|
4880
|
-
[fund.fundId]: fund,
|
|
4881
|
-
[fund$1.fundId]: fund$1,
|
|
4882
|
-
[fund$c.fundId]: fund$c,
|
|
4883
|
-
[fund$9.fundId]: fund$9,
|
|
4884
|
-
[fund$4.fundId]: fund$4,
|
|
4885
|
-
[fund$6.fundId]: fund$6,
|
|
4886
|
-
[fund$5.fundId]: fund$5,
|
|
4887
|
-
[fund$a.fundId]: fund$a,
|
|
4888
|
-
[fund$b.fundId]: fund$b,
|
|
4889
|
-
[fund$7.fundId]: fund$7
|
|
4890
|
-
};
|
|
4891
|
-
const allPromotedFunds = Object.values(fundsById);
|
|
4892
|
-
const getFundByDtoPropName = (dtoPropName) => {
|
|
4893
|
-
const fund = allPromotedFunds.find((f) => f.dtoPropName == dtoPropName);
|
|
4894
|
-
return fund ? some(fund) : none;
|
|
4895
|
-
};
|
|
4896
|
-
const getFundByFundId = (fundId) => {
|
|
4897
|
-
const fund = allPromotedFunds.find((f) => f.fundId == fundId);
|
|
4898
|
-
return fund ? some(fund) : none;
|
|
4899
|
-
};
|
|
4900
|
-
const getFundNameByFundId = (fundId) => fundsById[fundId] != undefined ? some(fundsById[fundId].name) : none;
|
|
4901
|
-
const getFooterTextOverrideByFundId = (fundId) => { var _a, _b; return (_b = (_a = fundsById[fundId]) === null || _a === void 0 ? void 0 : _a.footnoteTextOverride) !== null && _b !== void 0 ? _b : none; };
|
|
4902
|
-
const getFundUsiByFundId = (fundId) => fundId == fund$8.fundId ? some(slateUsi) : none;
|
|
4903
|
-
const getLogoSrcByFundId = (fundId) => fundsById[fundId] != undefined ? some(index.getAssetPath(`assets/${fundsById[fundId].logo}`)) : none;
|
|
4904
|
-
|
|
4905
4314
|
class ExistingFundService {
|
|
4906
4315
|
async GetExistingFundAsync() {
|
|
4907
4316
|
var _a;
|
|
@@ -4916,24 +4325,13 @@ class ExistingFundService {
|
|
|
4916
4325
|
const memberNumber = getSuperChoiceMemberNumber(choiceDetails);
|
|
4917
4326
|
switch (choiceDetails.kind) {
|
|
4918
4327
|
case 'Promoted': {
|
|
4919
|
-
|
|
4920
|
-
? getFundByFundId(choiceDetails.promoted['generic'].fundId)
|
|
4921
|
-
: getFundByDtoPropName(Object.keys(choiceDetails.promoted)[0]);
|
|
4922
|
-
let fundName = '';
|
|
4923
|
-
if (isSome(fund)) {
|
|
4924
|
-
fundName = fund.value.name;
|
|
4925
|
-
}
|
|
4926
|
-
else if (isSome(usi)) {
|
|
4927
|
-
const fundLookup = await this.getFundByUsiAsync(usi.value);
|
|
4928
|
-
fundName = isSome(fundLookup) ? fundLookup.value.productName : usi.value;
|
|
4929
|
-
}
|
|
4930
|
-
else {
|
|
4328
|
+
if (isNone(usi))
|
|
4931
4329
|
return none;
|
|
4932
|
-
|
|
4330
|
+
const fund = await this.getFundByUsiAsync(usi.value);
|
|
4933
4331
|
return some({
|
|
4934
4332
|
type: 'Promoted Fund',
|
|
4935
4333
|
id: getPromotedFundId(choiceDetails.promoted),
|
|
4936
|
-
name:
|
|
4334
|
+
name: isSome(fund) ? fund.value.productName : usi.value,
|
|
4937
4335
|
usi: usi,
|
|
4938
4336
|
valid: 'Active',
|
|
4939
4337
|
memberNumber: memberNumber,
|
|
@@ -5067,14 +4465,12 @@ const ExistingChoice = class {
|
|
|
5067
4465
|
this.existingFund = chosenFundOption.value;
|
|
5068
4466
|
}
|
|
5069
4467
|
else {
|
|
5070
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
4468
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5071
4469
|
}
|
|
5072
4470
|
}
|
|
5073
4471
|
render() {
|
|
5074
|
-
const PromotedFundView = (
|
|
5075
|
-
|
|
5076
|
-
const fundName = getFundNameByFundId(props.id);
|
|
5077
|
-
return (index.h("div", { class: "flex justify-center" }, index.h("img", { class: "h-16 object-contain w-full max-w-140", alt: isSome(fundName) ? fundName.value : undefined, src: isSome(logo) ? logo.value : undefined })));
|
|
4472
|
+
const PromotedFundView = (_props) => {
|
|
4473
|
+
return (index.h("div", { class: "flex justify-center" }));
|
|
5078
4474
|
};
|
|
5079
4475
|
const MyOwnFundView = () => {
|
|
5080
4476
|
return (index.h("div", { class: "flex h-20 justify-center items-center relative" }, index.h("div", { class: "h-20 w-20 rounded-full bg-primary-base opacity-10" }), index.h("div", { class: "h-10 w-10 absolute" }, index.h("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 576 512", class: "fill-primary-base" }, index.h("path", { d: "M174.7 111.8C165.1 110.3 160.1 102.1 161.5 93.35C170.4 40.37 216.5 0 272 0C320.8 0 362.3 31.19 377.6 74.67C380.6 82.1 376.2 92.14 367.9 95.09C359.5 98.03 350.4 93.66 347.5 85.33C336.5 54.24 306.8 32 272 32C232.4 32 199.5 60.82 193.1 98.65C191.6 107.4 183.4 113.2 174.7 111.8V111.8zM400 264C400 250.7 410.7 240 424 240C437.3 240 448 250.7 448 264C448 277.3 437.3 288 424 288C410.7 288 400 277.3 400 264zM488.5 125.8L480 159.1C501.1 176.5 519.6 198.5 530.7 224H544C561.7 224 576 238.3 576 256V352C576 369.7 561.7 384 544 384H512C495.5 405.1 473.5 423.6 448 434.7V464C448 490.5 426.5 512 400 512H368C341.5 512 320 490.5 320 464V448H256V464C256 490.5 234.5 512 208 512H176C149.5 512 128 490.5 128 464V416C89.14 386.8 64 340.3 64 288C28.52 287.2 0 258.2 0 222.6C0 197.8 14 175.1 36.18 164L40.84 161.7C48.75 157.7 58.36 160.9 62.31 168.8C66.26 176.7 63.06 186.4 55.16 190.3L50.49 192.6C39.16 198.3 31.1 209.9 31.1 222.6C31.1 241 46.97 256 65.44 256H67.2C82.02 182.1 146.6 128 223.1 128H376.4C394 108.4 419.6 96 448 96H465.3C480.9 96 492.3 110.7 488.5 125.8H488.5zM224 160C153.3 160 96 217.3 96 288C96 329.9 116.1 367 147.2 390.4L160 400V464C160 472.8 167.2 480 176 480H208C216.8 480 224 472.8 224 464V416H352V464C352 472.8 359.2 480 368 480H400C408.8 480 416 472.8 416 464V413.7L435.2 405.4C455.6 396.5 473.2 382.4 486.4 364.8L496 352H544V256H509.7L501.4 236.8C492.5 216.4 478.4 198.8 460.8 185.6L443.8 172.8L455 128H448C429 128 412.1 136.2 400.3 149.3L390.7 160H224z" })))));
|
|
@@ -5095,7 +4491,7 @@ const ExistingChoice = class {
|
|
|
5095
4491
|
switch (this.existingFund.type) {
|
|
5096
4492
|
case 'Promoted Fund':
|
|
5097
4493
|
case 'Promoted Default Fund':
|
|
5098
|
-
return index.h(PromotedFundView, {
|
|
4494
|
+
return index.h(PromotedFundView, { name: this.existingFund.name });
|
|
5099
4495
|
case 'Self Managed Fund':
|
|
5100
4496
|
return index.h(SelfManagedFundView, null);
|
|
5101
4497
|
case 'My Own Fund':
|
|
@@ -5132,7 +4528,7 @@ const ExistingChoice = class {
|
|
|
5132
4528
|
async handleFundNominationDeclined() {
|
|
5133
4529
|
const detail = this.createSuperFundNominationDetail(this.existingFund);
|
|
5134
4530
|
await this.eventTrackingService.TrackSuperFundNominationDeclinedAsync(detail);
|
|
5135
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
4531
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5136
4532
|
}
|
|
5137
4533
|
};
|
|
5138
4534
|
|
|
@@ -5140,7 +4536,7 @@ const DefaultFooterText = 'Powered by Flare';
|
|
|
5140
4536
|
const FooterSection = class {
|
|
5141
4537
|
constructor(hostRef) {
|
|
5142
4538
|
index.registerInstance(this, hostRef);
|
|
5143
|
-
this.footerText = () =>
|
|
4539
|
+
this.footerText = () => this.textOverride !== undefined ? this.textOverride : DefaultFooterText;
|
|
5144
4540
|
}
|
|
5145
4541
|
render() {
|
|
5146
4542
|
return (index.h("div", { class: {
|
|
@@ -5176,27 +4572,6 @@ const HeaderSection = class {
|
|
|
5176
4572
|
}
|
|
5177
4573
|
};
|
|
5178
4574
|
|
|
5179
|
-
const IFrameHost = class {
|
|
5180
|
-
constructor(hostRef) {
|
|
5181
|
-
index.registerInstance(this, hostRef);
|
|
5182
|
-
}
|
|
5183
|
-
componentDidLoad() {
|
|
5184
|
-
this.build(this.iframeElement);
|
|
5185
|
-
}
|
|
5186
|
-
render() {
|
|
5187
|
-
return (index.h("div", { class: "w-screen" }, index.h("iframe", { width: "100%", height: window.innerHeight, style: { border: 'none' }, ref: (el) => (this.iframeElement = el) })));
|
|
5188
|
-
}
|
|
5189
|
-
};
|
|
5190
|
-
|
|
5191
|
-
const LoadingComponent = class {
|
|
5192
|
-
constructor(hostRef) {
|
|
5193
|
-
index.registerInstance(this, hostRef);
|
|
5194
|
-
}
|
|
5195
|
-
render() {
|
|
5196
|
-
return (index.h("div", { class: "w-full bg-white flex flex-col items-center" }, index.h("sss-loading-indicator", null), index.h("h5", { class: "mt-4 text-xl font-bold leading-7" }, this.header), index.h("slot", null)));
|
|
5197
|
-
}
|
|
5198
|
-
};
|
|
5199
|
-
|
|
5200
4575
|
const LoadingIndicator = class {
|
|
5201
4576
|
constructor(hostRef) {
|
|
5202
4577
|
index.registerInstance(this, hostRef);
|
|
@@ -5217,15 +4592,6 @@ const LoadingPage = class {
|
|
|
5217
4592
|
}
|
|
5218
4593
|
};
|
|
5219
4594
|
|
|
5220
|
-
const LoadingComponent$1 = class {
|
|
5221
|
-
constructor(hostRef) {
|
|
5222
|
-
index.registerInstance(this, hostRef);
|
|
5223
|
-
}
|
|
5224
|
-
render() {
|
|
5225
|
-
return (index.h("sss-loading-component", { header: "Loading Super" }, index.h("p", { class: "text-base text-gray-600 mt-4 max-w-560 text-center font-normal leading-7" }, "This can take up to 30 seconds.", index.h("br", null), "Please don\u2019t navigate away or refresh your browser.")));
|
|
5226
|
-
}
|
|
5227
|
-
};
|
|
5228
|
-
|
|
5229
4595
|
const MyOwnFund = class {
|
|
5230
4596
|
constructor(hostRef) {
|
|
5231
4597
|
index.registerInstance(this, hostRef);
|
|
@@ -5243,8 +4609,8 @@ const MyOwnFund = class {
|
|
|
5243
4609
|
const isSuperCampaignFallbackActivated = superSelectionAppService.isSuperCampaignFallbackActivated;
|
|
5244
4610
|
return (index.h(index.Host, null, index.h("sss-header-section", { currentPage: "own-fund" }), index.h("div", { class: "flex justify-center mt-11" }, index.h("sss-custom-fund", null, index.h("form", { noValidate: true, onSubmit: (ev) => ev.preventDefault(), class: {
|
|
5245
4611
|
'was-validated': this.formState === 'validated'
|
|
5246
|
-
}, ref: (el) => (this.formElement = el), onInput: (_) => (this.isSubmitDisabled = !this.formElement.checkValidity()) }, index.h("div", { class: "p-4 sm:p-6 pb-6 sm:pb-8 border shadow-sm rounded-lg" }, index.h("p", { class: "sm:text-lg font-bold mb-3" }, "Fund details"), index.h("div", { class: "bg-yellow-50 border-l-4 border-yellow-400 p-4 mb-3 sm:mb-4" }, index.h("div", { class: "flex" }, index.h("div", { class: "flex-shrink-0" }, index.h("img", { class: "h-5 w-5", src: index.getAssetPath('assets/icon-exclamation.svg') })), index.h("div", { class: "ml-2" }, index.h("ul", { class: "list-disc list-outside ml-6 space-y-2 text-sm text-yellow-700 leading-5" }, index.h("li", null, "Make sure you are a current member of the fund before completing this step."), index.h("li", null, "Please check that the fund USI is correct as some funds have similar names."))))), index.h("sss-my-own-fund-inputs", { myOwnFundForm: state$
|
|
5247
|
-
state$
|
|
4612
|
+
}, ref: (el) => (this.formElement = el), onInput: (_) => (this.isSubmitDisabled = !this.formElement.checkValidity()) }, index.h("div", { class: "p-4 sm:p-6 pb-6 sm:pb-8 border shadow-sm rounded-lg" }, index.h("p", { class: "sm:text-lg font-bold mb-3" }, "Fund details"), index.h("div", { class: "bg-yellow-50 border-l-4 border-yellow-400 p-4 mb-3 sm:mb-4" }, index.h("div", { class: "flex" }, index.h("div", { class: "flex-shrink-0" }, index.h("img", { class: "h-5 w-5", src: index.getAssetPath('assets/icon-exclamation.svg') })), index.h("div", { class: "ml-2" }, index.h("ul", { class: "list-disc list-outside ml-6 space-y-2 text-sm text-yellow-700 leading-5" }, index.h("li", null, "Make sure you are a current member of the fund before completing this step."), index.h("li", null, "Please check that the fund USI is correct as some funds have similar names."))))), index.h("sss-my-own-fund-inputs", { myOwnFundForm: state$1.myOwnFundForm, showValidationErrors: this.formState === 'validated', onFormChanged: (event) => {
|
|
4613
|
+
state$1.myOwnFundForm = Object.assign(Object.assign({}, state$1.myOwnFundForm), event.detail);
|
|
5248
4614
|
this.isNotAllInformationProvidedMessageVisible = false;
|
|
5249
4615
|
} }), this.isNotAllInformationProvidedMessageVisible && (index.h("div", { class: "mt-4 rounded-md bg-red-50 p-4 text-sm text-red-700" }, "All fields are required to complete submission. Make sure you have selected a fund."))), index.h("div", { class: "flex justify-center mt-8" }, index.h("div", { class: "sm:max-w-320 w-full" }, index.h("div", { class: "mb-4", onClick:
|
|
5250
4616
|
// user clicks on disabled button (div wrapper) then validation errors will show
|
|
@@ -5255,25 +4621,25 @@ const MyOwnFund = class {
|
|
|
5255
4621
|
if (!this.formElement.checkValidity()) {
|
|
5256
4622
|
return;
|
|
5257
4623
|
}
|
|
5258
|
-
const isAllInformationProvided = isSome(state$
|
|
5259
|
-
isSome(state$
|
|
5260
|
-
isSome(state$
|
|
5261
|
-
isSome(state$
|
|
4624
|
+
const isAllInformationProvided = isSome(state$1.myOwnFundForm.fundUsi) &&
|
|
4625
|
+
isSome(state$1.myOwnFundForm.memberNumber) &&
|
|
4626
|
+
isSome(state$1.myOwnFundForm.memberFirstName) &&
|
|
4627
|
+
isSome(state$1.myOwnFundForm.memberFamilyName);
|
|
5262
4628
|
if (!isAllInformationProvided) {
|
|
5263
4629
|
this.isNotAllInformationProvidedMessageVisible = true;
|
|
5264
4630
|
return;
|
|
5265
4631
|
}
|
|
5266
4632
|
navigationService.navigateInternallyToStandardChoice({
|
|
5267
4633
|
history: this.history,
|
|
5268
|
-
fundName: this.getOrError(state$
|
|
4634
|
+
fundName: this.getOrError(state$1.myOwnFundForm.fundName),
|
|
5269
4635
|
fundDetails: {
|
|
5270
4636
|
type: 'myOwnFund',
|
|
5271
|
-
fundName: this.getOrError(state$
|
|
5272
|
-
fundUsi: this.getOrError(state$
|
|
5273
|
-
memberNumber: this.getOrError(state$
|
|
4637
|
+
fundName: this.getOrError(state$1.myOwnFundForm.fundName),
|
|
4638
|
+
fundUsi: this.getOrError(state$1.myOwnFundForm.fundUsi),
|
|
4639
|
+
memberNumber: this.getOrError(state$1.myOwnFundForm.memberNumber)
|
|
5274
4640
|
},
|
|
5275
4641
|
handleSubmitFn: async (standardChoiceFormSignature) => {
|
|
5276
|
-
const customFundChoiceDto = Object.assign({ fundUsi: this.getOrError(state$
|
|
4642
|
+
const customFundChoiceDto = Object.assign({ fundUsi: this.getOrError(state$1.myOwnFundForm.fundUsi), memberNumber: this.getOrError(state$1.myOwnFundForm.memberNumber), memberFirstName: this.getOrError(state$1.myOwnFundForm.memberFirstName), memberFamilyName: this.getOrError(state$1.myOwnFundForm.memberFamilyName), standardChoiceFormSignature }, superSelectionAppService.promotedFundsConfig);
|
|
5277
4643
|
await customFundChoiceApi.submitCustomFundChoiceAsync(customFundChoiceDto);
|
|
5278
4644
|
}
|
|
5279
4645
|
});
|
|
@@ -5324,7 +4690,7 @@ const MyOwnFundInputs = class {
|
|
|
5324
4690
|
'shadow-sm focus:ring-primary-focus focus:border-primary-base block w-full text-base sm:text-sm border-gray-300 rounded-md': true,
|
|
5325
4691
|
'invalid:border-red-300 invalid:text-red-900 invalid:focus:ring-red-500 invalid:focus:border-red-500': this
|
|
5326
4692
|
.showValidationErrors
|
|
5327
|
-
}, required: true, pattern: "[A-Za-z0-9]{4,16}", name: "memberNumber", id: "memberNumber", value: toUndefined(state$
|
|
4693
|
+
}, required: true, pattern: "[A-Za-z0-9]{4,16}", name: "memberNumber", id: "memberNumber", value: toUndefined(state$1.myOwnFundForm.memberNumber), onChange: (ev) => this.updateMemberNumber(ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid member number (only numbers and / or letters)"))), index.h("div", { class: "flex space-x-4" }, index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Given name(s)"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-given-names-input", name: "memberFirstName", readableName: "Member given name(s)", showValidationErrors: this.showValidationErrors, value: toUndefined(state$1.myOwnFundForm.memberFirstName), onChange: (ev) => this.updateMemberFirstName(ev.target.value.trim()) }))), index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Last name"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-last-name-input", name: "memberFamilyName", readableName: "Member last name", showValidationErrors: this.showValidationErrors, value: toUndefined(state$1.myOwnFundForm.memberFamilyName), onChange: (ev) => this.updateMemberFamilyName(ev.target.value.trim()) }))))));
|
|
5328
4694
|
}
|
|
5329
4695
|
updateFund(fund) {
|
|
5330
4696
|
this.formChanged.emit({ fundUsi: some(fund.value), fundName: some(fund.label) });
|
|
@@ -5426,7 +4792,7 @@ const Prefill = class {
|
|
|
5426
4792
|
return this.renderInvalidSMSF(this.prefill.data);
|
|
5427
4793
|
}
|
|
5428
4794
|
}
|
|
5429
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
4795
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5430
4796
|
return null;
|
|
5431
4797
|
}
|
|
5432
4798
|
renderMyOwnFund(data) {
|
|
@@ -5821,8 +5187,8 @@ const PrefillInvalidMyOwnFund = class {
|
|
|
5821
5187
|
}
|
|
5822
5188
|
else {
|
|
5823
5189
|
// If prefill does not exist, or is valid we should
|
|
5824
|
-
// not have landed on this page, navigate to
|
|
5825
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5190
|
+
// not have landed on this page, navigate to choice page
|
|
5191
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5826
5192
|
}
|
|
5827
5193
|
}
|
|
5828
5194
|
render() {
|
|
@@ -5833,7 +5199,7 @@ const PrefillInvalidMyOwnFund = class {
|
|
|
5833
5199
|
async handleChooseAnotherFund() {
|
|
5834
5200
|
const detail = this.createSuperFundPrefillDeclinedDetail(this.prefill);
|
|
5835
5201
|
await this.eventTrackingService.TrackSuperFundPrefillDeclinedAsync(detail);
|
|
5836
|
-
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5202
|
+
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5837
5203
|
}
|
|
5838
5204
|
};
|
|
5839
5205
|
|
|
@@ -5868,7 +5234,7 @@ const PrefillInvalidSMSF = class {
|
|
|
5868
5234
|
}
|
|
5869
5235
|
else {
|
|
5870
5236
|
// If prefill does not exist, or is valid we should
|
|
5871
|
-
// not have landed on this page, navigate to
|
|
5237
|
+
// not have landed on this page, navigate to PrefillInvalidMyOwnFundPage page
|
|
5872
5238
|
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.PrefillInvalidMyOwnFundPage);
|
|
5873
5239
|
}
|
|
5874
5240
|
}
|
|
@@ -5896,7 +5262,7 @@ const PrefillInvalidSMSF = class {
|
|
|
5896
5262
|
async handleFundNominationDeclined() {
|
|
5897
5263
|
const detail = this.createSuperFundPrefillDeclinedDetail(this.prefill);
|
|
5898
5264
|
await this.eventTrackingService.TrackSuperFundPrefillDeclinedAsync(detail);
|
|
5899
|
-
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5265
|
+
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5900
5266
|
}
|
|
5901
5267
|
};
|
|
5902
5268
|
|
|
@@ -5936,8 +5302,8 @@ const PrefillMyOwnFund = class {
|
|
|
5936
5302
|
}
|
|
5937
5303
|
else {
|
|
5938
5304
|
// If prefill does not exist, or is invalid we should
|
|
5939
|
-
// not have landed on this page, navigate to
|
|
5940
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5305
|
+
// not have landed on this page, navigate to choice page
|
|
5306
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5941
5307
|
}
|
|
5942
5308
|
}
|
|
5943
5309
|
render() {
|
|
@@ -6018,7 +5384,7 @@ const PrefillMyOwnFund = class {
|
|
|
6018
5384
|
async handleFundNominationDeclined() {
|
|
6019
5385
|
const detail = this.createSuperFundPrefillDeclinedDetail(this.prefill);
|
|
6020
5386
|
await this.eventTrackingService.TrackSuperFundPrefillDeclinedAsync(detail);
|
|
6021
|
-
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5387
|
+
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
6022
5388
|
}
|
|
6023
5389
|
};
|
|
6024
5390
|
|
|
@@ -6168,8 +5534,8 @@ const PrefillSMSF = class {
|
|
|
6168
5534
|
}
|
|
6169
5535
|
else {
|
|
6170
5536
|
// If prefill does not exist, or is invalid we should
|
|
6171
|
-
// not have landed on this page, navigate to
|
|
6172
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5537
|
+
// not have landed on this page, navigate to PrefillInvalidSMSFPage page
|
|
5538
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.PrefillInvalidSMSFPage);
|
|
6173
5539
|
}
|
|
6174
5540
|
}
|
|
6175
5541
|
render() {
|
|
@@ -6375,7 +5741,7 @@ const PrefillSMSF = class {
|
|
|
6375
5741
|
async handleFundNominationDeclined() {
|
|
6376
5742
|
const detail = this.createSuperFundPrefillDeclinedDetail(this.prefill);
|
|
6377
5743
|
await this.eventTrackingService.TrackSuperFundPrefillDeclinedAsync(detail);
|
|
6378
|
-
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
5744
|
+
return navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
6379
5745
|
}
|
|
6380
5746
|
};
|
|
6381
5747
|
|
|
@@ -6391,178 +5757,341 @@ const PrefillWarningBox = class {
|
|
|
6391
5757
|
}
|
|
6392
5758
|
};
|
|
6393
5759
|
|
|
6394
|
-
|
|
6395
|
-
|
|
6396
|
-
|
|
6397
|
-
|
|
6398
|
-
|
|
6399
|
-
|
|
6400
|
-
throw new Error('Failed to process Promoted Fund choice request');
|
|
6401
|
-
})
|
|
6402
|
-
.text();
|
|
6403
|
-
}
|
|
6404
|
-
async submitDefaultChoiceAsync(dto) {
|
|
6405
|
-
return buildBackendApiClient()
|
|
6406
|
-
.url('super-choice/promoted-fund/default')
|
|
6407
|
-
.post(dto)
|
|
6408
|
-
.badRequest(() => {
|
|
6409
|
-
throw new Error('Failed to process Promoted Default Fund choice request');
|
|
6410
|
-
})
|
|
6411
|
-
.text();
|
|
6412
|
-
}
|
|
6413
|
-
async submitDefaultChoiceWithJoinAsync(dto) {
|
|
6414
|
-
return buildBackendApiClient()
|
|
6415
|
-
.url('super-choice/promoted-fund/default-with-join')
|
|
6416
|
-
.post(dto)
|
|
6417
|
-
.badRequest(() => {
|
|
6418
|
-
throw new Error('Failed to process Promoted Default Fund With Join choice request');
|
|
6419
|
-
})
|
|
6420
|
-
.text();
|
|
5760
|
+
function validateAbn(abn) {
|
|
5761
|
+
const digitArray = abn.split('').map(Number);
|
|
5762
|
+
const isAllDigits = digitArray.every((d) => !isNaN(d));
|
|
5763
|
+
const weightingFactors = [10, 1, 3, 5, 7, 9, 11, 13, 15, 17, 19];
|
|
5764
|
+
if (!isAllDigits || digitArray.length !== weightingFactors.length) {
|
|
5765
|
+
return false;
|
|
6421
5766
|
}
|
|
5767
|
+
digitArray[0]--;
|
|
5768
|
+
const sum = digitArray.reduce((sum, digit, i) => sum + digit * weightingFactors[i], 0);
|
|
5769
|
+
return sum % 89 === 0;
|
|
6422
5770
|
}
|
|
6423
|
-
const promotedFundChoiceApi = new PromotedFundChoiceApi();
|
|
6424
5771
|
|
|
6425
|
-
class
|
|
6426
|
-
constructor() {
|
|
6427
|
-
this
|
|
6428
|
-
this.
|
|
6429
|
-
|
|
6430
|
-
|
|
6431
|
-
|
|
6432
|
-
|
|
6433
|
-
|
|
6434
|
-
|
|
6435
|
-
|
|
6436
|
-
|
|
6437
|
-
|
|
6438
|
-
|
|
6439
|
-
|
|
6440
|
-
|
|
6441
|
-
|
|
6442
|
-
|
|
6443
|
-
|
|
6444
|
-
|
|
6445
|
-
|
|
6446
|
-
|
|
6447
|
-
|
|
6448
|
-
|
|
6449
|
-
|
|
6450
|
-
|
|
6451
|
-
|
|
6452
|
-
|
|
6453
|
-
|
|
6454
|
-
|
|
6455
|
-
|
|
6456
|
-
|
|
6457
|
-
|
|
6458
|
-
|
|
6459
|
-
fundName,
|
|
6460
|
-
fundDetails: {
|
|
6461
|
-
type: 'promoted',
|
|
6462
|
-
fundName,
|
|
6463
|
-
fundUsi: usi,
|
|
6464
|
-
memberNumber: data.memberNumber,
|
|
6465
|
-
promotedFundId
|
|
6466
|
-
},
|
|
6467
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitChoiceAsync(Object.assign({ fundId: promotedFundId, memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, usi,
|
|
6468
|
-
standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig)),
|
|
6469
|
-
promotedFundId
|
|
6470
|
-
});
|
|
6471
|
-
break;
|
|
6472
|
-
}
|
|
6473
|
-
/* falls through */
|
|
6474
|
-
default:
|
|
6475
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
6476
|
-
break;
|
|
6477
|
-
}
|
|
6478
|
-
reset();
|
|
6479
|
-
return;
|
|
6480
|
-
}
|
|
6481
|
-
if (data.sender === 'promoted-fund-join') {
|
|
6482
|
-
switch (data.type) {
|
|
6483
|
-
case 'contentResized':
|
|
6484
|
-
iframe$1.height = data.height > 0 ? data.height : iframe$1.height;
|
|
6485
|
-
iframe$1.width = data.width > 0 ? data.width : iframe$1.width;
|
|
6486
|
-
break;
|
|
6487
|
-
case 'pageNavigated':
|
|
6488
|
-
window.scroll(iframe$1.offsetLeft, iframe$1.offsetTop);
|
|
6489
|
-
iframe.navigation(window.location.href);
|
|
6490
|
-
break;
|
|
5772
|
+
const SelfManagedFund = class {
|
|
5773
|
+
constructor(hostRef) {
|
|
5774
|
+
index.registerInstance(this, hostRef);
|
|
5775
|
+
this.isSubmitDisabled = true;
|
|
5776
|
+
this.isAbnValid = validateAbn(state$1.selfManagedFundForm.fundAbn);
|
|
5777
|
+
this.eventTrackingService = EventTrackingService.Instance;
|
|
5778
|
+
this.success = () => {
|
|
5779
|
+
navigationService.navigateInternallyToStandardChoice({
|
|
5780
|
+
history: this.history,
|
|
5781
|
+
fundName: 'Self-managed super fund',
|
|
5782
|
+
fundDetails: {
|
|
5783
|
+
type: 'smsf',
|
|
5784
|
+
fundName: state$1.selfManagedFundForm.fundName,
|
|
5785
|
+
fundEsa: state$1.selfManagedFundForm.fundEsa
|
|
5786
|
+
},
|
|
5787
|
+
handleSubmitFn: async (standardChoiceFormSignature) => {
|
|
5788
|
+
const requestDto = Object.assign({ smsfChoice: {
|
|
5789
|
+
abn: state$1.selfManagedFundForm.fundAbn,
|
|
5790
|
+
fundName: state$1.selfManagedFundForm.fundName,
|
|
5791
|
+
fundAddress: {
|
|
5792
|
+
addressLine1: state$1.selfManagedFundForm.addressLine1,
|
|
5793
|
+
addressLine2: state$1.selfManagedFundForm.addressLine2,
|
|
5794
|
+
city: state$1.selfManagedFundForm.city,
|
|
5795
|
+
state: state$1.selfManagedFundForm.state,
|
|
5796
|
+
postcode: state$1.selfManagedFundForm.postcode
|
|
5797
|
+
},
|
|
5798
|
+
bsb: state$1.selfManagedFundForm.bsb,
|
|
5799
|
+
bankAccountName: state$1.selfManagedFundForm.bankAccountName,
|
|
5800
|
+
bankAccountNumber: state$1.selfManagedFundForm.bankAccountNumber,
|
|
5801
|
+
electronicServiceAddress: state$1.selfManagedFundForm.fundEsa,
|
|
5802
|
+
memberFirstName: state$1.selfManagedFundForm.memberFirstName,
|
|
5803
|
+
memberFamilyName: state$1.selfManagedFundForm.memberFamilyName
|
|
5804
|
+
}, standardChoiceFormSignature }, superSelectionAppService.promotedFundsConfig);
|
|
5805
|
+
await customFundChoiceApi.submitSelfManagedFundChoiceAsync(requestDto);
|
|
6491
5806
|
}
|
|
6492
|
-
}
|
|
5807
|
+
});
|
|
5808
|
+
};
|
|
5809
|
+
}
|
|
5810
|
+
componentDidLoad() {
|
|
5811
|
+
this.updateIsSubmitDisabled();
|
|
5812
|
+
return this.eventTrackingService.TrackSmsfSuperFundDetailViewedAsync({
|
|
5813
|
+
promotedFundsShown: superSelectionAppService.promotedFunds,
|
|
5814
|
+
defaultFundUsiSet: toUndefined(superSelectionAppService.defaultFundUsi)
|
|
5815
|
+
});
|
|
5816
|
+
}
|
|
5817
|
+
render() {
|
|
5818
|
+
return (index.h(index.Host, null, index.h("sss-header-section", { currentPage: "own-fund" }), index.h("div", { class: "flex justify-center mt-11" }, index.h("sss-custom-fund", null, index.h("form", { noValidate: true, onSubmit: (ev) => ev.preventDefault(), class: {
|
|
5819
|
+
'was-validated': this.formState === 'validated'
|
|
5820
|
+
}, ref: (el) => (this.formElement = el), onInput: (_) => this.updateIsSubmitDisabled() }, index.h("div", { class: "p-4 sm:p-6 pb-6 sm:pb-8 border shadow-sm rounded-lg max-w-560" }, index.h("p", { class: "sm:text-lg font-bold" }, "Fund details"), index.h("div", { class: "bg-yellow-50 border-l-4 border-yellow-400 p-4 my-3" }, index.h("div", { class: "flex" }, index.h("div", { class: "flex-shrink-0" }, index.h("img", { class: "h-5 w-5", src: index.getAssetPath('assets/icon-exclamation.svg') })), index.h("div", { class: "ml-3 text-sm text-yellow-700 leading-5" }, "Make sure your Self-managed super fund (SMSF) is a registered fund before completing this step."))), index.h("sss-self-managed-fund-inputs", { fundForm: state$1.selfManagedFundForm, showValidationErrors: this.formState === 'validated', onFormChanged: (event) => {
|
|
5821
|
+
state$1.selfManagedFundForm = Object.assign(Object.assign({}, state$1.selfManagedFundForm), event.detail);
|
|
5822
|
+
if (event.detail.isAbnValid !== undefined)
|
|
5823
|
+
this.isAbnValid = event.detail.isAbnValid;
|
|
5824
|
+
this.updateIsSubmitDisabled();
|
|
5825
|
+
} })), index.h("div", { class: "flex justify-center mt-8" }, index.h("div", { class: "sm:max-w-320 w-full" }, index.h("div", { class: "mb-4", onClick:
|
|
5826
|
+
// user clicks on disabled button (div wrapper) then validation errors will show
|
|
5827
|
+
() => (this.formState = 'validated') }, index.h("sss-button", { testid: "continue-button", fillWidth: true, promiseFn: () => this.handleSubmitForm(), disabled: this.isSubmitDisabled }, "Continue")), index.h("stencil-route-link", { url: SuperSelectionAppRoutes.ChoicePage }, index.h("sss-button", { testid: "back-button", fillWidth: true, variant: "secondary" }, "Back")))))))));
|
|
5828
|
+
}
|
|
5829
|
+
updateIsSubmitDisabled() {
|
|
5830
|
+
this.isSubmitDisabled = !this.formElement.checkValidity() || !this.isAbnValid;
|
|
5831
|
+
}
|
|
5832
|
+
async handleSubmitForm() {
|
|
5833
|
+
this.formState = 'validated';
|
|
5834
|
+
if (this.formElement.checkValidity())
|
|
5835
|
+
this.success();
|
|
5836
|
+
}
|
|
5837
|
+
};
|
|
5838
|
+
injectHistory(SelfManagedFund);
|
|
5839
|
+
|
|
5840
|
+
var AbnValidationStatus;
|
|
5841
|
+
(function (AbnValidationStatus) {
|
|
5842
|
+
AbnValidationStatus[AbnValidationStatus["Invalid"] = 1] = "Invalid";
|
|
5843
|
+
AbnValidationStatus[AbnValidationStatus["AbnIsUsedForRegulatedFund"] = 2] = "AbnIsUsedForRegulatedFund";
|
|
5844
|
+
AbnValidationStatus[AbnValidationStatus["Valid"] = 3] = "Valid";
|
|
5845
|
+
})(AbnValidationStatus || (AbnValidationStatus = {}));
|
|
5846
|
+
const SelfManagedFundInputs = class {
|
|
5847
|
+
constructor(hostRef) {
|
|
5848
|
+
index.registerInstance(this, hostRef);
|
|
5849
|
+
this.formChanged = index.createEvent(this, "formChanged", 7);
|
|
5850
|
+
this.abnValidationStatus = AbnValidationStatus.Invalid;
|
|
5851
|
+
this.isAbnTouched = false;
|
|
5852
|
+
this.currentBank = none;
|
|
5853
|
+
this.addressErrorMessage = none;
|
|
5854
|
+
this.stateOptions = [
|
|
5855
|
+
{ value: 'NSW', label: 'NSW' },
|
|
5856
|
+
{ value: 'QLD', label: 'QLD' },
|
|
5857
|
+
{ value: 'ACT', label: 'ACT' },
|
|
5858
|
+
{ value: 'VIC', label: 'VIC' },
|
|
5859
|
+
{ value: 'TAS', label: 'TAS' },
|
|
5860
|
+
{ value: 'WA', label: 'WA' },
|
|
5861
|
+
{ value: 'SA', label: 'SA' },
|
|
5862
|
+
{ value: 'NT', label: 'NT' }
|
|
5863
|
+
];
|
|
5864
|
+
this.bsbRegex = new RegExp(/^[0-9]{3}[0-9]{3}$/);
|
|
5865
|
+
this.bankAccountNumberRegex = new RegExp(/^[0-9]{2,10}$/);
|
|
5866
|
+
}
|
|
5867
|
+
render() {
|
|
5868
|
+
const inputClass = {
|
|
5869
|
+
'relative shadow-sm focus:ring-primary-focus focus:border-primary-base block w-full text-base sm:text-sm border-gray-300 rounded-md focus:z-10': true,
|
|
5870
|
+
'invalid:border-red-300 invalid:text-red-900 invalid:placeholder-red-300 invalid:focus:ring-red-500 invalid:focus:border-red-500': this
|
|
5871
|
+
.showValidationErrors
|
|
6493
5872
|
};
|
|
6494
|
-
|
|
6495
|
-
|
|
6496
|
-
|
|
6497
|
-
|
|
6498
|
-
|
|
6499
|
-
|
|
6500
|
-
|
|
6501
|
-
|
|
6502
|
-
|
|
6503
|
-
|
|
6504
|
-
|
|
6505
|
-
const
|
|
6506
|
-
|
|
6507
|
-
|
|
6508
|
-
|
|
6509
|
-
|
|
5873
|
+
return (index.h("div", null, index.h("div", null, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund name"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundName", id: "fundName", value: state$1.selfManagedFundForm.fundName, onChange: (ev) => this.updateFormField('fundName', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid fund name"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund ABN"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundAbn", id: "fundAbn", value: state$1.selfManagedFundForm.fundAbn, inputmode: "numeric", pattern: "[0-9]*", onKeyUp: async (ev) => {
|
|
5874
|
+
const abnInput = ev.target;
|
|
5875
|
+
this.updateFormField('fundAbn', abnInput.value.trim());
|
|
5876
|
+
this.abnValidationStatus = AbnValidationStatus.Invalid;
|
|
5877
|
+
if (validateAbn(abnInput.value)) {
|
|
5878
|
+
const isAbnUsedForRegulatedFund = await this.isAbnUsedForRegulatedAsync(abnInput.value);
|
|
5879
|
+
this.abnValidationStatus = isAbnUsedForRegulatedFund
|
|
5880
|
+
? AbnValidationStatus.AbnIsUsedForRegulatedFund
|
|
5881
|
+
: AbnValidationStatus.Valid;
|
|
5882
|
+
}
|
|
5883
|
+
// We need to set a custom validity message to trigger css invalid styles for non valid cases
|
|
5884
|
+
const validityMessage = this.abnValidationStatus === AbnValidationStatus.Valid
|
|
5885
|
+
? ''
|
|
5886
|
+
: 'Enter a valid fund ABN (digits only)';
|
|
5887
|
+
abnInput.setCustomValidity(validityMessage);
|
|
5888
|
+
this.updateFormField('isAbnValid', this.abnValidationStatus === AbnValidationStatus.Valid);
|
|
5889
|
+
}, onBlur: () => (this.isAbnTouched = true) }), this.renderAbnValidationError())), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Electronic service address alias (ESA)"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundEsa", id: "fundEsa", value: state$1.selfManagedFundForm.fundEsa, onChange: (ev) => this.updateFormField('fundEsa', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid fund ESA"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund address"), index.h("div", { class: "mt-1 rounded-md shadow-sm -space-y-px" }, index.h("input", { placeholder: "Address line 1", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-t-md shadow-none': true }), required: true, minlength: "2", name: "addressLine1", id: "addressLine1", value: state$1.selfManagedFundForm.addressLine1, onChange: (ev) => {
|
|
5890
|
+
this.updateFormField('addressLine1', ev.target.value.trim());
|
|
5891
|
+
this.updateAddressErrorMessage();
|
|
5892
|
+
}, ref: (el) => (this.addressLine1Element = el) }), index.h("input", { placeholder: "Address line 2 (optional)", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none shadow-none': true }), name: "addressLine2", id: "addressLine2", value: state$1.selfManagedFundForm.addressLine2, onChange: (ev) => this.updateFormField('addressLine2', ev.target.value.trim()) }), index.h("input", { placeholder: "City/suburb", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none shadow-none': true }), name: "city", required: true, id: "city", value: state$1.selfManagedFundForm.city, onChange: (ev) => {
|
|
5893
|
+
this.updateFormField('city', ev.target.value.trim());
|
|
5894
|
+
this.updateAddressErrorMessage();
|
|
5895
|
+
}, ref: (el) => (this.cityElement = el) }), index.h("div", { class: "flex -space-x-px" }, index.h("div", { class: "w-1/2 flex-1 min-w-0" }, index.h("input", { placeholder: "Postcode", type: "text", required: true, class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-bl-md shadow-none': true }), name: "postcode", minlength: "4", maxlength: "4", pattern: "[0-9]{4}", id: "postcode", value: state$1.selfManagedFundForm.postcode, inputmode: "numeric", onChange: (ev) => {
|
|
5896
|
+
this.updateFormField('postcode', ev.target.value.trim());
|
|
5897
|
+
this.updateAddressErrorMessage();
|
|
5898
|
+
}, ref: (el) => (this.postcodeElement = el) })), index.h("div", { class: "flex-1 min-w-0" }, index.h("select", { class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-br-md shadow-none': true, 'text-gray-500': this.fundForm.state !== undefined }), name: "state", required: true, id: "state", onChange: (ev) => {
|
|
5899
|
+
this.updateFormField('state', ev.target.value.trim());
|
|
5900
|
+
this.updateAddressErrorMessage();
|
|
5901
|
+
}, ref: (el) => (this.stateElement = el) }, index.h("option", { disabled: true, selected: this.fundForm.state !== undefined, value: "" }, "State"), this.stateOptions.map((s) => (index.h("option", { value: s.value, selected: this.fundForm.state === s.value }, s.label))))))), isSome(this.addressErrorMessage) && this.showValidationErrors && (index.h("div", { class: "mt-2 text-sm text-red-600" }, this.addressErrorMessage.value))), index.h("div", { class: "flex space-x-4" }, index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Given name(s)"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-given-names-input", name: "memberFirstName", readableName: "Member given name(s)", showValidationErrors: this.showValidationErrors, value: state$1.selfManagedFundForm.memberFirstName, onChange: (ev) => this.updateFormField('memberFirstName', ev.target.value.trim()) }))), index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Last name"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-last-name-input", name: "memberFamilyName", readableName: "Member last name", showValidationErrors: this.showValidationErrors, value: state$1.selfManagedFundForm.memberFamilyName, onChange: (ev) => this.updateFormField('memberFamilyName', ev.target.value.trim()) })))), index.h("h3", { class: "text-lg font-bold mt-6" }, "Fund bank details"), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Account name"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bankAccountName", minlength: "2", id: "bankAccountName", value: state$1.selfManagedFundForm.bankAccountName, onChange: (ev) => this.updateFormField('bankAccountName', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid bank account name"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "BSB"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bsb", id: "bsb", minlength: "6", maxlength: "7", inputmode: "numeric", onKeyUp: (ev) => this.updateCurrentBank(ev), pattern: this.bsbRegex.source, value: state$1.selfManagedFundForm.bsb }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid BSB"))), isSome(this.currentBank) && (index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Bank name"), index.h("div", { class: "mt-1 shadow-sm px-3 py-2 rounded-md border border-gray-300 bg-gray-50 text-gray-500 text-sm" }, this.currentBank.value))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Account number"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bankAccountNumber", id: "bankAccountNumber", minlength: "2", maxlength: "11", pattern: this.bankAccountNumberRegex.source, inputmode: "numeric", value: state$1.selfManagedFundForm.bankAccountNumber, onKeyUp: (ev) => this.updateCurrentBankAccountNumber(ev), onChange: (ev) => this.updateFormField('bankAccountNumber', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid bank account number")))));
|
|
5902
|
+
}
|
|
5903
|
+
updateFormField(key, value) {
|
|
5904
|
+
this.formChanged.emit({ [key]: value });
|
|
5905
|
+
}
|
|
5906
|
+
async isAbnUsedForRegulatedAsync(abn) {
|
|
5907
|
+
return !(await customFundChoiceApi.validateAbnForSMSF(abn));
|
|
5908
|
+
}
|
|
5909
|
+
renderAbnValidationError() {
|
|
5910
|
+
if (this.isAbnTouched || this.showValidationErrors) {
|
|
5911
|
+
switch (this.abnValidationStatus) {
|
|
5912
|
+
case AbnValidationStatus.Invalid:
|
|
5913
|
+
return index.h("div", { class: "mt-2 text-sm text-red-600" }, "Enter a valid fund ABN (digits only)");
|
|
5914
|
+
case AbnValidationStatus.AbnIsUsedForRegulatedFund:
|
|
5915
|
+
return (index.h("div", { class: "mt-2 text-sm text-red-600" }, "The supplied ABN is for a regulated fund"));
|
|
5916
|
+
case AbnValidationStatus.Valid:
|
|
5917
|
+
return [];
|
|
6510
5918
|
}
|
|
6511
5919
|
}
|
|
6512
|
-
|
|
6513
|
-
iframeDoc.close();
|
|
6514
|
-
form.submit();
|
|
5920
|
+
return [];
|
|
6515
5921
|
}
|
|
6516
|
-
|
|
6517
|
-
|
|
6518
|
-
const superBuyer = superSelectionAppService.superBuyer;
|
|
6519
|
-
return {
|
|
6520
|
-
title: superBuyer.userProfile.title,
|
|
6521
|
-
firstName: superBuyer.userProfile.firstName,
|
|
6522
|
-
middleName: superBuyer.userProfile.middleName,
|
|
6523
|
-
lastName: superBuyer.userProfile.lastName,
|
|
6524
|
-
dateOfBirth: superBuyer.userProfile.dateOfBirth,
|
|
6525
|
-
gender: superBuyer.userProfile.gender,
|
|
6526
|
-
email: superBuyer.userProfile.email,
|
|
6527
|
-
mobilePhone: superBuyer.userProfile.mobilePhone,
|
|
6528
|
-
taxFileNumber: (_a = superBuyer.tfn) !== null && _a !== void 0 ? _a : '',
|
|
6529
|
-
addressLine1: superBuyer.userProfile.address.addressLine1,
|
|
6530
|
-
addressLine2: (_b = superBuyer.userProfile.address.addressLine2) !== null && _b !== void 0 ? _b : '',
|
|
6531
|
-
city: superBuyer.userProfile.address.city,
|
|
6532
|
-
state: superBuyer.userProfile.address.state,
|
|
6533
|
-
postCode: superBuyer.userProfile.address.postcode
|
|
6534
|
-
};
|
|
5922
|
+
filterDigits(str) {
|
|
5923
|
+
return str.replace(/[^0-9]/g, '');
|
|
6535
5924
|
}
|
|
6536
|
-
|
|
6537
|
-
const
|
|
5925
|
+
updateCurrentBank(ev) {
|
|
5926
|
+
const value = this.filterDigits(ev.target.value);
|
|
5927
|
+
const firstTwoNumbers = value.substring(0, 2);
|
|
5928
|
+
const firstThreeNumbers = value.substring(0, 3);
|
|
5929
|
+
const firstTwoNumberBankName = bsbNumbers[firstTwoNumbers];
|
|
5930
|
+
const firstThreeNumberBankName = bsbNumbers[firstThreeNumbers];
|
|
5931
|
+
if (firstTwoNumberBankName)
|
|
5932
|
+
this.currentBank = some(firstTwoNumberBankName);
|
|
5933
|
+
if (firstThreeNumberBankName)
|
|
5934
|
+
this.currentBank = some(firstThreeNumberBankName);
|
|
5935
|
+
if (value === '' || value.length > 6)
|
|
5936
|
+
this.currentBank = none;
|
|
5937
|
+
this.updateFormField('bsb', value);
|
|
5938
|
+
}
|
|
5939
|
+
updateCurrentBankAccountNumber(ev) {
|
|
5940
|
+
const value = this.filterDigits(ev.target.value);
|
|
5941
|
+
this.updateFormField('bankAccountNumber', value);
|
|
5942
|
+
}
|
|
5943
|
+
updateAddressErrorMessage() {
|
|
5944
|
+
let message = none;
|
|
5945
|
+
if (isNone(message) && !this.addressLine1Element.checkValidity()) {
|
|
5946
|
+
message = some('Enter a valid address line 1');
|
|
5947
|
+
}
|
|
5948
|
+
if (isNone(message) && !this.cityElement.checkValidity()) {
|
|
5949
|
+
message = some('Enter a valid city/suburb');
|
|
5950
|
+
}
|
|
5951
|
+
if (isNone(message) && !this.postcodeElement.checkValidity()) {
|
|
5952
|
+
message = some('Enter a valid post code');
|
|
5953
|
+
}
|
|
5954
|
+
if (isNone(message) && !this.stateElement.checkValidity()) {
|
|
5955
|
+
message = some('Select a state');
|
|
5956
|
+
}
|
|
5957
|
+
this.addressErrorMessage = message;
|
|
5958
|
+
}
|
|
5959
|
+
};
|
|
6538
5960
|
|
|
6539
|
-
const
|
|
5961
|
+
const StandardChoiceFormInputDefaultFund = class {
|
|
6540
5962
|
constructor(hostRef) {
|
|
6541
5963
|
index.registerInstance(this, hostRef);
|
|
5964
|
+
this.standardChoiceFormSignature = '';
|
|
5965
|
+
this.isSubmitDisabled = true;
|
|
5966
|
+
this.eventTrackingService = EventTrackingService.Instance;
|
|
5967
|
+
this.ignorePopState = () => window.history.pushState(null, '', null);
|
|
5968
|
+
}
|
|
5969
|
+
connectedCallback() {
|
|
5970
|
+
this.ignorePopState();
|
|
5971
|
+
window.addEventListener('popstate', this.ignorePopState);
|
|
5972
|
+
}
|
|
5973
|
+
disconnectedCallback() {
|
|
5974
|
+
window.removeEventListener('popstate', this.ignorePopState);
|
|
6542
5975
|
}
|
|
6543
5976
|
render() {
|
|
6544
|
-
return (index.h("
|
|
5977
|
+
return (index.h(index.Host, null, index.h("div", { class: "text-2xl sm:text-3xl font-bold text-center" }, "Confirm your super choice"), index.h("div", { class: "sm:text-lg text-gray-600 max-w-800 mt-4 text-center leading-7 sm:leading-8" }, "Your authorisation is required to complete your super choice by signing the standard choice form, which informs your employer of your choice of fund."), index.h("div", { class: "flex justify-center mt-8 sm:mt-12" }, index.h("div", { class: "max-w-560" }, index.h("div", { class: "p-4 sm:p-6 border shadow-sm rounded-lg flex flex-col sm:flex-row" }, this.renderLogo(), index.h("div", { class: "flex justify-between w-full" }, index.h("div", null, index.h("div", { class: "text-xs font-semibold text-gray-500 uppercase" }, "Nominated fund"), index.h("div", { class: "text-sm mt-2" }, state.fundName)), index.h("div", { class: "grid content-center ml-4" }, index.h("sss-button", { testid: "change-fund-button", size: "xs", variant: "secondary", promiseFn: async () => {
|
|
5978
|
+
await this.trackChangeRequestedAsync();
|
|
5979
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
5980
|
+
} }, "Change")))), index.h("div", { class: "mt-4 p-4 sm:p-6 border shadow-sm rounded-lg" }, index.h("div", { class: "sm:text-lg font-bold" }, "Superannuation Standard Choice Form"), index.h("div", { class: "bg-blue-50 border-l-4 border-blue-400 p-4 mt-3" }, index.h("div", { class: "flex" }, index.h("div", { class: "flex-shrink-0" }, index.h("img", { class: "h-5 w-5", src: index.getAssetPath('assets/icon-information-circle.svg') })), index.h("div", { class: "ml-2" }, index.h("p", { class: "text-sm text-blue-800 leading-5" }, "Applying your full name in the text field below is the same as applying your written signature and is legally binding.")))), index.h("form", { noValidate: true, onSubmit: (ev) => ev.preventDefault(), class: {
|
|
5981
|
+
'mt-3': true,
|
|
5982
|
+
'was-validated': this.formState === 'validated'
|
|
5983
|
+
}, ref: (el) => (this.formElement = el), onInput: (_) => (this.isSubmitDisabled = !this.formElement.checkValidity()) }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Type your full name"), index.h("input", { "data-testid": "standard-choice-form-signature-input", type: "text", autocomplete: "off", class: {
|
|
5984
|
+
'shadow-sm focus:ring-primary-focus focus:border-primary-focus w-full text-base sm:text-sm border-gray-300 rounded-md mt-1': true,
|
|
5985
|
+
'invalid:border-red-300 invalid:text-red-900 invalid:focus:ring-red-500 invalid:focus:border-red-500': this.formState === 'validated'
|
|
5986
|
+
}, required: true, minlength: "2", name: "standardChoiceFormSignature", id: "standardChoiceFormSignature", value: this.standardChoiceFormSignature, onInput: (event) => (this.standardChoiceFormSignature = event.target.value) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Type your full name"), index.h("div", { class: "mt-6" }, index.h("sss-button", { testid: "confirm-and-continue-button", fillWidth: true, promiseFn: () => this.handleSubmitForm(), disabled: this.isSubmitDisabled }, "Confirm and continue"))))))));
|
|
5987
|
+
}
|
|
5988
|
+
// TODO: fetch external promoted fund logo
|
|
5989
|
+
renderLogo() {
|
|
5990
|
+
return;
|
|
5991
|
+
// if (standardChoiceFormState.promotedFundId == undefined) return;
|
|
5992
|
+
// const logoSource = getLogoSrcByFundId(standardChoiceFormState.promotedFundId);
|
|
5993
|
+
// if (isSome(logoSource)) {
|
|
5994
|
+
// return (
|
|
5995
|
+
// <div class="pb-4 mb-4 border-b flex justify-center sm:pb-0 sm:mb-0 sm:border-b-0 sm:pr-8 sm:mr-8 sm:border-r sm:justify-start">
|
|
5996
|
+
// <img
|
|
5997
|
+
// class="h-16 max-w-140 sm:h-12 sm:max-w-[100px] object-contain"
|
|
5998
|
+
// alt={standardChoiceFormState.fundName}
|
|
5999
|
+
// src={logoSource.value}
|
|
6000
|
+
// />
|
|
6001
|
+
// </div>
|
|
6002
|
+
// );
|
|
6003
|
+
// }
|
|
6004
|
+
}
|
|
6005
|
+
async trackChangeRequestedAsync() {
|
|
6006
|
+
const common = {
|
|
6007
|
+
promotedFundsShown: superSelectionAppService.promotedFunds,
|
|
6008
|
+
defaultFundUsiSet: toUndefined(superSelectionAppService.defaultFundUsi)
|
|
6009
|
+
};
|
|
6010
|
+
switch (state.fundDetails.type) {
|
|
6011
|
+
case 'default':
|
|
6012
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6013
|
+
DefaultFund: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6014
|
+
});
|
|
6015
|
+
break;
|
|
6016
|
+
case 'myOwnFund':
|
|
6017
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6018
|
+
MyOwnFund: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6019
|
+
});
|
|
6020
|
+
break;
|
|
6021
|
+
case 'smsf':
|
|
6022
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6023
|
+
Smsf: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6024
|
+
});
|
|
6025
|
+
break;
|
|
6026
|
+
case 'promoted':
|
|
6027
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6028
|
+
PromotedFund: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6029
|
+
});
|
|
6030
|
+
break;
|
|
6031
|
+
case 'promotedDefault':
|
|
6032
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6033
|
+
PromotedDefaultFund: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6034
|
+
});
|
|
6035
|
+
break;
|
|
6036
|
+
case 'promotedDefaultWithJoin':
|
|
6037
|
+
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
6038
|
+
PromotedDefaultFundWithJoin: Object.assign(Object.assign({}, state.fundDetails), common)
|
|
6039
|
+
});
|
|
6040
|
+
break;
|
|
6041
|
+
case 'null':
|
|
6042
|
+
throw 'standardChoiceFormState.fundDetails was not set';
|
|
6043
|
+
}
|
|
6044
|
+
}
|
|
6045
|
+
async handleSubmitForm() {
|
|
6046
|
+
this.formState = 'validated';
|
|
6047
|
+
if (this.formElement.checkValidity()) {
|
|
6048
|
+
await state.handleSubmitFn(this.standardChoiceFormSignature.trim());
|
|
6049
|
+
superSelectionAppService.markSuperSelectionAsSubmitted();
|
|
6050
|
+
}
|
|
6545
6051
|
}
|
|
6546
6052
|
};
|
|
6547
6053
|
|
|
6548
|
-
|
|
6549
|
-
|
|
6550
|
-
|
|
6551
|
-
|
|
6552
|
-
|
|
6553
|
-
|
|
6554
|
-
|
|
6555
|
-
|
|
6556
|
-
|
|
6557
|
-
|
|
6558
|
-
|
|
6559
|
-
|
|
6560
|
-
|
|
6561
|
-
|
|
6562
|
-
|
|
6563
|
-
|
|
6564
|
-
|
|
6565
|
-
|
|
6054
|
+
const Success = class {
|
|
6055
|
+
constructor(hostRef) {
|
|
6056
|
+
index.registerInstance(this, hostRef);
|
|
6057
|
+
this.ignorePopState = () => window.history.pushState(null, '', null);
|
|
6058
|
+
}
|
|
6059
|
+
connectedCallback() {
|
|
6060
|
+
this.ignorePopState();
|
|
6061
|
+
window.addEventListener('popstate', this.ignorePopState);
|
|
6062
|
+
}
|
|
6063
|
+
disconnectedCallback() {
|
|
6064
|
+
window.removeEventListener('popstate', this.ignorePopState);
|
|
6065
|
+
}
|
|
6066
|
+
render() {
|
|
6067
|
+
const CheckIcon = () => {
|
|
6068
|
+
return (index.h("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 448 512", class: "fill-primary-base" }, index.h("path", { d: "M443.3 100.7C449.6 106.9 449.6 117.1 443.3 123.3L171.3 395.3C165.1 401.6 154.9 401.6 148.7 395.3L4.686 251.3C-1.562 245.1-1.562 234.9 4.686 228.7C10.93 222.4 21.06 222.4 27.31 228.7L160 361.4L420.7 100.7C426.9 94.44 437.1 94.44 443.3 100.7H443.3z" })));
|
|
6069
|
+
};
|
|
6070
|
+
return (index.h(index.Host, { class: "text-center" }, index.h("div", { class: "flex justify-center" }, index.h("div", { class: "relative" }, index.h("div", { class: "h-20 w-20 rounded-full bg-primary-base opacity-10" }), index.h("div", { class: "h-8 w-8 absolute top-1/2 left-1/2 -translate-y-1/2 -translate-x-1/2" }, index.h(CheckIcon, null)))), index.h("h3", { class: "text-2xl leading-8 font-bold mt-4" }, "Your super choice has been submitted"), index.h("p", { class: "mt-4 text-center text-gray-600 leading-7 max-w-560 mx-auto" }, "Your superannuation details have been updated successfully and will be submitted to your employer."), index.h("div", { class: "flex justify-center mt-8" }, index.h("div", { class: "max-w-[200px] w-full" }, index.h("sss-button", { testid: "continue-button", size: "xl", fillWidth: true, onClick: this.handleContinueButtonClick }, index.h("span", null, "Continue"))))));
|
|
6071
|
+
}
|
|
6072
|
+
handleContinueButtonClick(_event) {
|
|
6073
|
+
superSelectionAppService.completeSuperSelectionFlow();
|
|
6074
|
+
}
|
|
6075
|
+
};
|
|
6076
|
+
|
|
6077
|
+
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
6078
|
+
// Licensed under the MIT License.
|
|
6079
|
+
var strShimFunction = "function";
|
|
6080
|
+
var strShimObject = "object";
|
|
6081
|
+
var strShimUndefined = "undefined";
|
|
6082
|
+
var strShimPrototype = "prototype";
|
|
6083
|
+
var strShimHasOwnProperty = "hasOwnProperty";
|
|
6084
|
+
/**
|
|
6085
|
+
* Returns the current global scope object, for a normal web page this will be the current
|
|
6086
|
+
* window, for a Web Worker this will be current worker global scope via "self". The internal
|
|
6087
|
+
* implementation returns the first available instance object in the following order
|
|
6088
|
+
* - globalThis (New standard)
|
|
6089
|
+
* - self (Will return the current window instance for supported browsers)
|
|
6090
|
+
* - window (fallback for older browser implementations)
|
|
6091
|
+
* - global (NodeJS standard)
|
|
6092
|
+
* - <null> (When all else fails)
|
|
6093
|
+
* While the return type is a Window for the normal case, not all environments will support all
|
|
6094
|
+
* of the properties or functions.
|
|
6566
6095
|
*/
|
|
6567
6096
|
function getGlobal() {
|
|
6568
6097
|
if (typeof globalThis !== strShimUndefined && globalThis) {
|
|
@@ -16153,819 +15682,123 @@ class AppConfigurationQuery extends datoramaAkita.Query {
|
|
|
16153
15682
|
}
|
|
16154
15683
|
get configuration() {
|
|
16155
15684
|
const configuration = this.getValue().appConfiguration;
|
|
16156
|
-
if (isNone(configuration)) {
|
|
16157
|
-
throw Error('App configuration is not yet loaded');
|
|
16158
|
-
}
|
|
16159
|
-
return configuration.value;
|
|
16160
|
-
}
|
|
16161
|
-
}
|
|
16162
|
-
const appConfigurationQuery = new AppConfigurationQuery(sessionStore);
|
|
16163
|
-
|
|
16164
|
-
class AppInsightsService {
|
|
16165
|
-
constructor() {
|
|
16166
|
-
this.appInsights = new Lazy(() => new Initialization({
|
|
16167
|
-
config: {
|
|
16168
|
-
instrumentationKey: appConfigurationQuery.configuration.AppInsightsKey,
|
|
16169
|
-
enableAutoRouteTracking: true,
|
|
16170
|
-
autoTrackPageVisitTime: true,
|
|
16171
|
-
maxBatchInterval: 1000,
|
|
16172
|
-
enableUnhandledPromiseRejectionTracking: true
|
|
16173
|
-
}
|
|
16174
|
-
}));
|
|
16175
|
-
}
|
|
16176
|
-
init() {
|
|
16177
|
-
this.appInsights.value.loadAppInsights();
|
|
16178
|
-
index.setErrorHandler((err) => this.appInsightsErrorHandler(err));
|
|
16179
|
-
}
|
|
16180
|
-
getAppInsights() {
|
|
16181
|
-
return this.appInsights.value;
|
|
16182
|
-
}
|
|
16183
|
-
addCustomProperties(properties) {
|
|
16184
|
-
this.appInsights.value.addTelemetryInitializer((envelope) => {
|
|
16185
|
-
envelope.data = envelope.data ? envelope.data : {};
|
|
16186
|
-
for (const [k, v] of Object.entries(properties)) {
|
|
16187
|
-
envelope.data[k] = v;
|
|
16188
|
-
}
|
|
16189
|
-
});
|
|
16190
|
-
}
|
|
16191
|
-
trackErrorTrace(message) {
|
|
16192
|
-
this.appInsights.value.trackTrace({ message, severityLevel: SeverityLevel.Error });
|
|
16193
|
-
}
|
|
16194
|
-
appInsightsErrorHandler(error) {
|
|
16195
|
-
this.appInsights.value.trackException({
|
|
16196
|
-
error: error,
|
|
16197
|
-
severityLevel: SeverityLevel.Error
|
|
16198
|
-
});
|
|
16199
|
-
// eslint-disable-next-line no-console
|
|
16200
|
-
const defaultStencilErrorHandler = (error) => console.error(error);
|
|
16201
|
-
defaultStencilErrorHandler(error);
|
|
16202
|
-
}
|
|
16203
|
-
}
|
|
16204
|
-
const appInsights = new AppInsightsService();
|
|
16205
|
-
|
|
16206
|
-
class PromotedFundJoinV2IFrameBuilder {
|
|
16207
|
-
constructor() {
|
|
16208
|
-
this.getFundName = (fundId) => {
|
|
16209
|
-
return _function.pipe(getFundNameByFundId(fundId), Option.getOrElse(() => ''));
|
|
16210
|
-
};
|
|
16211
|
-
this.cleanUsi = (usi) => {
|
|
16212
|
-
return usi.replace(/ /g, '');
|
|
16213
|
-
};
|
|
16214
|
-
this.stringIsNullOrEmtpty = (s) => {
|
|
16215
|
-
return !(typeof s === 'string' && s.trim().length > 0);
|
|
16216
|
-
};
|
|
16217
|
-
this.environmentDiscriminator = () => {
|
|
16218
|
-
const discriminator = window.location.hostname.toLowerCase().split('.')[0];
|
|
16219
|
-
switch (discriminator) {
|
|
16220
|
-
case 'autodev-partner':
|
|
16221
|
-
case 'test-partner':
|
|
16222
|
-
case 'partner':
|
|
16223
|
-
case 'sandbox-partner':
|
|
16224
|
-
return discriminator.replace('partner', '');
|
|
16225
|
-
default:
|
|
16226
|
-
return 'autodev-';
|
|
16227
|
-
}
|
|
16228
|
-
};
|
|
16229
|
-
this.promotedFundJoinAppUrl = () => {
|
|
16230
|
-
return `https://${this.environmentDiscriminator()}api.simplefinancialchoices.com/promoted-funds/embed`;
|
|
16231
|
-
};
|
|
16232
|
-
}
|
|
16233
|
-
build(iframe$1, history) {
|
|
16234
|
-
if (!(iframe$1 === null || iframe$1 === void 0 ? void 0 : iframe$1.contentDocument))
|
|
16235
|
-
return;
|
|
16236
|
-
const postData = Object.assign(Object.assign({}, this.getMemberData()), { partnerId: superSelectionAppService.partnerIdOrDefault, accountId: superSelectionAppService.accountIdOrDefault, fundId: state.fund.id, authToken: superSelectionAppService.jwt, employerDefault: state.fund.type === 'PromotedDefault', definedBenefitsEligibility: Option.toUndefined(superSelectionAppService.isDefinedBenefitsEligible) });
|
|
16237
|
-
const handleMessage = async (event) => {
|
|
16238
|
-
const { data } = event;
|
|
16239
|
-
if (!data) {
|
|
16240
|
-
return;
|
|
16241
|
-
}
|
|
16242
|
-
if (data.sender === 'promoted-fund-redirect') {
|
|
16243
|
-
window.removeEventListener('message', handleMessage);
|
|
16244
|
-
switch (data.type) {
|
|
16245
|
-
case 'cancel':
|
|
16246
|
-
if (state.fund.type === 'DefinedBenefits') {
|
|
16247
|
-
// Note: we don't expect a cancel event from Defined Benefits flow but just in case
|
|
16248
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ConsentPage);
|
|
16249
|
-
}
|
|
16250
|
-
else {
|
|
16251
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16252
|
-
}
|
|
16253
|
-
break;
|
|
16254
|
-
case 'success': {
|
|
16255
|
-
const promotedFundId = state.fund.id;
|
|
16256
|
-
const fundName = this.getFundName(promotedFundId);
|
|
16257
|
-
const usi = this.cleanUsi(data.usi);
|
|
16258
|
-
switch (state.fund.type) {
|
|
16259
|
-
case 'Promoted':
|
|
16260
|
-
if (this.stringIsNullOrEmtpty(data.memberNumber) ||
|
|
16261
|
-
this.stringIsNullOrEmtpty(data.usi)) {
|
|
16262
|
-
appInsights.trackErrorTrace('PFJ C# did not return (Promoted) memberNumber and/or usi');
|
|
16263
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16264
|
-
break;
|
|
16265
|
-
}
|
|
16266
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16267
|
-
history,
|
|
16268
|
-
fundName,
|
|
16269
|
-
promotedFundId,
|
|
16270
|
-
fundDetails: {
|
|
16271
|
-
type: 'promoted',
|
|
16272
|
-
fundName,
|
|
16273
|
-
fundUsi: usi,
|
|
16274
|
-
memberNumber: data.memberNumber,
|
|
16275
|
-
promotedFundId
|
|
16276
|
-
},
|
|
16277
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitChoiceAsync(Object.assign({ fundId: promotedFundId, memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, usi: data.usi.replace(/ /g, ''), standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig))
|
|
16278
|
-
});
|
|
16279
|
-
break;
|
|
16280
|
-
case 'PromotedDefault':
|
|
16281
|
-
if (this.stringIsNullOrEmtpty(data.usi)) {
|
|
16282
|
-
appInsights.trackErrorTrace('PFJ C# did not return (PromotedDefault) usi');
|
|
16283
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16284
|
-
break;
|
|
16285
|
-
}
|
|
16286
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16287
|
-
history,
|
|
16288
|
-
fundName,
|
|
16289
|
-
promotedFundId,
|
|
16290
|
-
fundDetails: {
|
|
16291
|
-
type: 'promotedDefault',
|
|
16292
|
-
fundName,
|
|
16293
|
-
fundUsi: usi,
|
|
16294
|
-
promotedFundId
|
|
16295
|
-
},
|
|
16296
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitDefaultChoiceAsync(Object.assign({ fundId: promotedFundId, usi,
|
|
16297
|
-
standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig))
|
|
16298
|
-
});
|
|
16299
|
-
break;
|
|
16300
|
-
case 'DefinedBenefits':
|
|
16301
|
-
throw Error('DefinedBenefits is not supported in legacy "success" message');
|
|
16302
|
-
case 'null':
|
|
16303
|
-
throw Error('PromotedFundState.type was not set.');
|
|
16304
|
-
}
|
|
16305
|
-
break;
|
|
16306
|
-
}
|
|
16307
|
-
case 'success-promoted': {
|
|
16308
|
-
if (this.stringIsNullOrEmtpty(data.memberNumber) ||
|
|
16309
|
-
this.stringIsNullOrEmtpty(data.usi)) {
|
|
16310
|
-
appInsights.trackErrorTrace('PFJ C# did not return (Promoted) memberNumber and/or usi');
|
|
16311
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16312
|
-
break;
|
|
16313
|
-
}
|
|
16314
|
-
const usi = this.cleanUsi(data.usi);
|
|
16315
|
-
const fundName = this.getFundName(data.fundId);
|
|
16316
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16317
|
-
history,
|
|
16318
|
-
fundName,
|
|
16319
|
-
promotedFundId: data.fundId,
|
|
16320
|
-
fundDetails: {
|
|
16321
|
-
type: 'promoted',
|
|
16322
|
-
fundName,
|
|
16323
|
-
fundUsi: usi,
|
|
16324
|
-
memberNumber: data.memberNumber,
|
|
16325
|
-
promotedFundId: data.fundId
|
|
16326
|
-
},
|
|
16327
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitChoiceAsync(Object.assign({ fundId: data.fundId, memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, usi,
|
|
16328
|
-
standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig))
|
|
16329
|
-
});
|
|
16330
|
-
break;
|
|
16331
|
-
}
|
|
16332
|
-
case 'success-promoted-default': {
|
|
16333
|
-
if (this.stringIsNullOrEmtpty(data.usi)) {
|
|
16334
|
-
appInsights.trackErrorTrace('PFJ C# did not return (PromotedDefault) usi');
|
|
16335
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16336
|
-
break;
|
|
16337
|
-
}
|
|
16338
|
-
const usi = this.cleanUsi(data.usi);
|
|
16339
|
-
const fundName = this.getFundName(data.fundId);
|
|
16340
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16341
|
-
history,
|
|
16342
|
-
fundName,
|
|
16343
|
-
promotedFundId: data.fundId,
|
|
16344
|
-
fundDetails: {
|
|
16345
|
-
type: 'promotedDefault',
|
|
16346
|
-
fundName,
|
|
16347
|
-
fundUsi: usi,
|
|
16348
|
-
promotedFundId: data.fundId
|
|
16349
|
-
},
|
|
16350
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitDefaultChoiceAsync(Object.assign({ fundId: data.fundId, usi,
|
|
16351
|
-
standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig))
|
|
16352
|
-
});
|
|
16353
|
-
break;
|
|
16354
|
-
}
|
|
16355
|
-
case 'success-promoted-default-with-join': {
|
|
16356
|
-
if (this.stringIsNullOrEmtpty(data.memberNumber) ||
|
|
16357
|
-
this.stringIsNullOrEmtpty(data.usi)) {
|
|
16358
|
-
appInsights.trackErrorTrace('PFJ C# did not return (PromotedDefaultWithJoin) memberNumber and/or usi');
|
|
16359
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16360
|
-
break;
|
|
16361
|
-
}
|
|
16362
|
-
const usi = this.cleanUsi(data.usi);
|
|
16363
|
-
const fundName = this.getFundName(data.fundId);
|
|
16364
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16365
|
-
history,
|
|
16366
|
-
fundName,
|
|
16367
|
-
promotedFundId: data.fundId,
|
|
16368
|
-
fundDetails: {
|
|
16369
|
-
type: 'promotedDefaultWithJoin',
|
|
16370
|
-
fundName,
|
|
16371
|
-
fundUsi: usi,
|
|
16372
|
-
memberNumber: data.memberNumber,
|
|
16373
|
-
promotedFundId: data.fundId
|
|
16374
|
-
},
|
|
16375
|
-
handleSubmitFn: (standardChoiceFormSignature) => promotedFundChoiceApi.submitDefaultChoiceWithJoinAsync(Object.assign({ fundId: data.fundId, memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, usi,
|
|
16376
|
-
standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig))
|
|
16377
|
-
});
|
|
16378
|
-
break;
|
|
16379
|
-
}
|
|
16380
|
-
case 'success-defined-benefits':
|
|
16381
|
-
if (this.stringIsNullOrEmtpty(data.memberNumber) ||
|
|
16382
|
-
this.stringIsNullOrEmtpty(data.usi)) {
|
|
16383
|
-
appInsights.trackErrorTrace('PFJ C# did not return (DefinedBenefits) memberNumber and/or usi');
|
|
16384
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ConsentPage);
|
|
16385
|
-
break;
|
|
16386
|
-
}
|
|
16387
|
-
await customFundChoiceApi.submitDefinedBenefitsChoiceAsync(Object.assign(Object.assign({ fundUsi: this.cleanUsi(data.usi) }, data), superSelectionAppService.promotedFundsConfig));
|
|
16388
|
-
superSelectionAppService.markSuperSelectionAsSubmitted();
|
|
16389
|
-
break;
|
|
16390
|
-
/* falls through */
|
|
16391
|
-
default:
|
|
16392
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16393
|
-
break;
|
|
16394
|
-
}
|
|
16395
|
-
reset();
|
|
16396
|
-
return;
|
|
16397
|
-
}
|
|
16398
|
-
if (data.sender === 'promoted-fund-join') {
|
|
16399
|
-
switch (data.type) {
|
|
16400
|
-
case 'contentResized':
|
|
16401
|
-
iframe$1.height = data.height > 0 ? String(data.height) : iframe$1.height;
|
|
16402
|
-
iframe$1.width = data.width > 0 ? String(data.width) : iframe$1.width;
|
|
16403
|
-
break;
|
|
16404
|
-
case 'pageNavigated':
|
|
16405
|
-
window.scroll(iframe$1.offsetLeft, iframe$1.offsetTop);
|
|
16406
|
-
iframe.navigation(window.location.href);
|
|
16407
|
-
break;
|
|
16408
|
-
}
|
|
16409
|
-
}
|
|
16410
|
-
};
|
|
16411
|
-
window.addEventListener('message', handleMessage);
|
|
16412
|
-
const iframeDoc = iframe$1.contentDocument;
|
|
16413
|
-
iframeDoc.open();
|
|
16414
|
-
const form = iframeDoc.createElement('form');
|
|
16415
|
-
form.method = 'POST';
|
|
16416
|
-
form.target = '_self';
|
|
16417
|
-
form.action = this.promotedFundJoinAppUrl();
|
|
16418
|
-
let prop;
|
|
16419
|
-
for (prop in postData) {
|
|
16420
|
-
const value = postData[prop];
|
|
16421
|
-
if (value !== undefined) {
|
|
16422
|
-
const input = document.createElement('input');
|
|
16423
|
-
input.name = prop;
|
|
16424
|
-
input.type = 'hidden';
|
|
16425
|
-
if (typeof value === 'boolean') {
|
|
16426
|
-
input.value = value ? 'true' : 'false';
|
|
16427
|
-
}
|
|
16428
|
-
else {
|
|
16429
|
-
input.value = value;
|
|
16430
|
-
}
|
|
16431
|
-
form.append(input);
|
|
16432
|
-
}
|
|
16433
|
-
}
|
|
16434
|
-
iframeDoc.appendChild(form);
|
|
16435
|
-
iframeDoc.close();
|
|
16436
|
-
form.submit();
|
|
16437
|
-
}
|
|
16438
|
-
getMemberData() {
|
|
16439
|
-
var _a, _b;
|
|
16440
|
-
const superBuyer = superSelectionAppService.superBuyer;
|
|
16441
|
-
return {
|
|
16442
|
-
title: superBuyer.userProfile.title,
|
|
16443
|
-
firstName: superBuyer.userProfile.firstName,
|
|
16444
|
-
middleName: superBuyer.userProfile.middleName,
|
|
16445
|
-
lastName: superBuyer.userProfile.lastName,
|
|
16446
|
-
dateOfBirth: superBuyer.userProfile.dateOfBirth,
|
|
16447
|
-
gender: superBuyer.userProfile.gender,
|
|
16448
|
-
email: superBuyer.userProfile.email,
|
|
16449
|
-
mobilePhone: superBuyer.userProfile.mobilePhone,
|
|
16450
|
-
taxFileNumber: (_a = superBuyer.tfn) !== null && _a !== void 0 ? _a : '',
|
|
16451
|
-
addressLine1: superBuyer.userProfile.address.addressLine1,
|
|
16452
|
-
addressLine2: (_b = superBuyer.userProfile.address.addressLine2) !== null && _b !== void 0 ? _b : '',
|
|
16453
|
-
city: superBuyer.userProfile.address.city,
|
|
16454
|
-
state: superBuyer.userProfile.address.state,
|
|
16455
|
-
postCode: superBuyer.userProfile.address.postcode
|
|
16456
|
-
};
|
|
16457
|
-
}
|
|
16458
|
-
}
|
|
16459
|
-
const PromotedFundJoinV2IFrameBuilder$1 = new PromotedFundJoinV2IFrameBuilder();
|
|
16460
|
-
|
|
16461
|
-
const PromotedFundJoinV2Page = class {
|
|
16462
|
-
constructor(hostRef) {
|
|
16463
|
-
index.registerInstance(this, hostRef);
|
|
16464
|
-
}
|
|
16465
|
-
render() {
|
|
16466
|
-
return (index.h("sss-iframe-host", { build: (iframe) => PromotedFundJoinV2IFrameBuilder$1.build(iframe, this.history) }));
|
|
16467
|
-
}
|
|
16468
|
-
};
|
|
16469
|
-
|
|
16470
|
-
function validateAbn(abn) {
|
|
16471
|
-
const digitArray = abn.split('').map(Number);
|
|
16472
|
-
const isAllDigits = digitArray.every((d) => !isNaN(d));
|
|
16473
|
-
const weightingFactors = [10, 1, 3, 5, 7, 9, 11, 13, 15, 17, 19];
|
|
16474
|
-
if (!isAllDigits || digitArray.length !== weightingFactors.length) {
|
|
16475
|
-
return false;
|
|
16476
|
-
}
|
|
16477
|
-
digitArray[0]--;
|
|
16478
|
-
const sum = digitArray.reduce((sum, digit, i) => sum + digit * weightingFactors[i], 0);
|
|
16479
|
-
return sum % 89 === 0;
|
|
16480
|
-
}
|
|
16481
|
-
|
|
16482
|
-
const SelfManagedFund = class {
|
|
16483
|
-
constructor(hostRef) {
|
|
16484
|
-
index.registerInstance(this, hostRef);
|
|
16485
|
-
this.isSubmitDisabled = true;
|
|
16486
|
-
this.isAbnValid = validateAbn(state$2.selfManagedFundForm.fundAbn);
|
|
16487
|
-
this.eventTrackingService = EventTrackingService.Instance;
|
|
16488
|
-
this.success = () => {
|
|
16489
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16490
|
-
history: this.history,
|
|
16491
|
-
fundName: 'Self-managed super fund',
|
|
16492
|
-
fundDetails: {
|
|
16493
|
-
type: 'smsf',
|
|
16494
|
-
fundName: state$2.selfManagedFundForm.fundName,
|
|
16495
|
-
fundEsa: state$2.selfManagedFundForm.fundEsa
|
|
16496
|
-
},
|
|
16497
|
-
handleSubmitFn: async (standardChoiceFormSignature) => {
|
|
16498
|
-
const requestDto = Object.assign({ smsfChoice: {
|
|
16499
|
-
abn: state$2.selfManagedFundForm.fundAbn,
|
|
16500
|
-
fundName: state$2.selfManagedFundForm.fundName,
|
|
16501
|
-
fundAddress: {
|
|
16502
|
-
addressLine1: state$2.selfManagedFundForm.addressLine1,
|
|
16503
|
-
addressLine2: state$2.selfManagedFundForm.addressLine2,
|
|
16504
|
-
city: state$2.selfManagedFundForm.city,
|
|
16505
|
-
state: state$2.selfManagedFundForm.state,
|
|
16506
|
-
postcode: state$2.selfManagedFundForm.postcode
|
|
16507
|
-
},
|
|
16508
|
-
bsb: state$2.selfManagedFundForm.bsb,
|
|
16509
|
-
bankAccountName: state$2.selfManagedFundForm.bankAccountName,
|
|
16510
|
-
bankAccountNumber: state$2.selfManagedFundForm.bankAccountNumber,
|
|
16511
|
-
electronicServiceAddress: state$2.selfManagedFundForm.fundEsa,
|
|
16512
|
-
memberFirstName: state$2.selfManagedFundForm.memberFirstName,
|
|
16513
|
-
memberFamilyName: state$2.selfManagedFundForm.memberFamilyName
|
|
16514
|
-
}, standardChoiceFormSignature }, superSelectionAppService.promotedFundsConfig);
|
|
16515
|
-
await customFundChoiceApi.submitSelfManagedFundChoiceAsync(requestDto);
|
|
16516
|
-
}
|
|
16517
|
-
});
|
|
16518
|
-
};
|
|
16519
|
-
}
|
|
16520
|
-
componentDidLoad() {
|
|
16521
|
-
this.updateIsSubmitDisabled();
|
|
16522
|
-
return this.eventTrackingService.TrackSmsfSuperFundDetailViewedAsync({
|
|
16523
|
-
promotedFundsShown: superSelectionAppService.promotedFunds,
|
|
16524
|
-
defaultFundUsiSet: toUndefined(superSelectionAppService.defaultFundUsi)
|
|
16525
|
-
});
|
|
16526
|
-
}
|
|
16527
|
-
render() {
|
|
16528
|
-
return (index.h(index.Host, null, index.h("sss-header-section", { currentPage: "own-fund" }), index.h("div", { class: "flex justify-center mt-11" }, index.h("sss-custom-fund", null, index.h("form", { noValidate: true, onSubmit: (ev) => ev.preventDefault(), class: {
|
|
16529
|
-
'was-validated': this.formState === 'validated'
|
|
16530
|
-
}, ref: (el) => (this.formElement = el), onInput: (_) => this.updateIsSubmitDisabled() }, index.h("div", { class: "p-4 sm:p-6 pb-6 sm:pb-8 border shadow-sm rounded-lg max-w-560" }, index.h("p", { class: "sm:text-lg font-bold" }, "Fund details"), index.h("div", { class: "bg-yellow-50 border-l-4 border-yellow-400 p-4 my-3" }, index.h("div", { class: "flex" }, index.h("div", { class: "flex-shrink-0" }, index.h("img", { class: "h-5 w-5", src: index.getAssetPath('assets/icon-exclamation.svg') })), index.h("div", { class: "ml-3 text-sm text-yellow-700 leading-5" }, "Make sure your Self-managed super fund (SMSF) is a registered fund before completing this step."))), index.h("sss-self-managed-fund-inputs", { fundForm: state$2.selfManagedFundForm, showValidationErrors: this.formState === 'validated', onFormChanged: (event) => {
|
|
16531
|
-
state$2.selfManagedFundForm = Object.assign(Object.assign({}, state$2.selfManagedFundForm), event.detail);
|
|
16532
|
-
if (event.detail.isAbnValid !== undefined)
|
|
16533
|
-
this.isAbnValid = event.detail.isAbnValid;
|
|
16534
|
-
this.updateIsSubmitDisabled();
|
|
16535
|
-
} })), index.h("div", { class: "flex justify-center mt-8" }, index.h("div", { class: "sm:max-w-320 w-full" }, index.h("div", { class: "mb-4", onClick:
|
|
16536
|
-
// user clicks on disabled button (div wrapper) then validation errors will show
|
|
16537
|
-
() => (this.formState = 'validated') }, index.h("sss-button", { testid: "continue-button", fillWidth: true, promiseFn: () => this.handleSubmitForm(), disabled: this.isSubmitDisabled }, "Continue")), index.h("stencil-route-link", { url: SuperSelectionAppRoutes.ChoicePage }, index.h("sss-button", { testid: "back-button", fillWidth: true, variant: "secondary" }, "Back")))))))));
|
|
16538
|
-
}
|
|
16539
|
-
updateIsSubmitDisabled() {
|
|
16540
|
-
this.isSubmitDisabled = !this.formElement.checkValidity() || !this.isAbnValid;
|
|
16541
|
-
}
|
|
16542
|
-
async handleSubmitForm() {
|
|
16543
|
-
this.formState = 'validated';
|
|
16544
|
-
if (this.formElement.checkValidity())
|
|
16545
|
-
this.success();
|
|
16546
|
-
}
|
|
16547
|
-
};
|
|
16548
|
-
injectHistory(SelfManagedFund);
|
|
16549
|
-
|
|
16550
|
-
var AbnValidationStatus;
|
|
16551
|
-
(function (AbnValidationStatus) {
|
|
16552
|
-
AbnValidationStatus[AbnValidationStatus["Invalid"] = 1] = "Invalid";
|
|
16553
|
-
AbnValidationStatus[AbnValidationStatus["AbnIsUsedForRegulatedFund"] = 2] = "AbnIsUsedForRegulatedFund";
|
|
16554
|
-
AbnValidationStatus[AbnValidationStatus["Valid"] = 3] = "Valid";
|
|
16555
|
-
})(AbnValidationStatus || (AbnValidationStatus = {}));
|
|
16556
|
-
const SelfManagedFundInputs = class {
|
|
16557
|
-
constructor(hostRef) {
|
|
16558
|
-
index.registerInstance(this, hostRef);
|
|
16559
|
-
this.formChanged = index.createEvent(this, "formChanged", 7);
|
|
16560
|
-
this.abnValidationStatus = AbnValidationStatus.Invalid;
|
|
16561
|
-
this.isAbnTouched = false;
|
|
16562
|
-
this.currentBank = none;
|
|
16563
|
-
this.addressErrorMessage = none;
|
|
16564
|
-
this.stateOptions = [
|
|
16565
|
-
{ value: 'NSW', label: 'NSW' },
|
|
16566
|
-
{ value: 'QLD', label: 'QLD' },
|
|
16567
|
-
{ value: 'ACT', label: 'ACT' },
|
|
16568
|
-
{ value: 'VIC', label: 'VIC' },
|
|
16569
|
-
{ value: 'TAS', label: 'TAS' },
|
|
16570
|
-
{ value: 'WA', label: 'WA' },
|
|
16571
|
-
{ value: 'SA', label: 'SA' },
|
|
16572
|
-
{ value: 'NT', label: 'NT' }
|
|
16573
|
-
];
|
|
16574
|
-
this.bsbRegex = new RegExp(/^[0-9]{3}[0-9]{3}$/);
|
|
16575
|
-
this.bankAccountNumberRegex = new RegExp(/^[0-9]{2,10}$/);
|
|
16576
|
-
}
|
|
16577
|
-
render() {
|
|
16578
|
-
const inputClass = {
|
|
16579
|
-
'relative shadow-sm focus:ring-primary-focus focus:border-primary-base block w-full text-base sm:text-sm border-gray-300 rounded-md focus:z-10': true,
|
|
16580
|
-
'invalid:border-red-300 invalid:text-red-900 invalid:placeholder-red-300 invalid:focus:ring-red-500 invalid:focus:border-red-500': this
|
|
16581
|
-
.showValidationErrors
|
|
16582
|
-
};
|
|
16583
|
-
return (index.h("div", null, index.h("div", null, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund name"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundName", id: "fundName", value: state$2.selfManagedFundForm.fundName, onChange: (ev) => this.updateFormField('fundName', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid fund name"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund ABN"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundAbn", id: "fundAbn", value: state$2.selfManagedFundForm.fundAbn, inputmode: "numeric", pattern: "[0-9]*", onKeyUp: async (ev) => {
|
|
16584
|
-
const abnInput = ev.target;
|
|
16585
|
-
this.updateFormField('fundAbn', abnInput.value.trim());
|
|
16586
|
-
this.abnValidationStatus = AbnValidationStatus.Invalid;
|
|
16587
|
-
if (validateAbn(abnInput.value)) {
|
|
16588
|
-
const isAbnUsedForRegulatedFund = await this.isAbnUsedForRegulatedAsync(abnInput.value);
|
|
16589
|
-
this.abnValidationStatus = isAbnUsedForRegulatedFund
|
|
16590
|
-
? AbnValidationStatus.AbnIsUsedForRegulatedFund
|
|
16591
|
-
: AbnValidationStatus.Valid;
|
|
16592
|
-
}
|
|
16593
|
-
// We need to set a custom validity message to trigger css invalid styles for non valid cases
|
|
16594
|
-
const validityMessage = this.abnValidationStatus === AbnValidationStatus.Valid
|
|
16595
|
-
? ''
|
|
16596
|
-
: 'Enter a valid fund ABN (digits only)';
|
|
16597
|
-
abnInput.setCustomValidity(validityMessage);
|
|
16598
|
-
this.updateFormField('isAbnValid', this.abnValidationStatus === AbnValidationStatus.Valid);
|
|
16599
|
-
}, onBlur: () => (this.isAbnTouched = true) }), this.renderAbnValidationError())), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Electronic service address alias (ESA)"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", class: inputClass, required: true, minlength: "2", name: "fundEsa", id: "fundEsa", value: state$2.selfManagedFundForm.fundEsa, onChange: (ev) => this.updateFormField('fundEsa', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid fund ESA"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Fund address"), index.h("div", { class: "mt-1 rounded-md shadow-sm -space-y-px" }, index.h("input", { placeholder: "Address line 1", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-t-md shadow-none': true }), required: true, minlength: "2", name: "addressLine1", id: "addressLine1", value: state$2.selfManagedFundForm.addressLine1, onChange: (ev) => {
|
|
16600
|
-
this.updateFormField('addressLine1', ev.target.value.trim());
|
|
16601
|
-
this.updateAddressErrorMessage();
|
|
16602
|
-
}, ref: (el) => (this.addressLine1Element = el) }), index.h("input", { placeholder: "Address line 2 (optional)", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none shadow-none': true }), name: "addressLine2", id: "addressLine2", value: state$2.selfManagedFundForm.addressLine2, onChange: (ev) => this.updateFormField('addressLine2', ev.target.value.trim()) }), index.h("input", { placeholder: "City/suburb", type: "text", class: Object.assign(Object.assign({}, inputClass), { 'rounded-none shadow-none': true }), name: "city", required: true, id: "city", value: state$2.selfManagedFundForm.city, onChange: (ev) => {
|
|
16603
|
-
this.updateFormField('city', ev.target.value.trim());
|
|
16604
|
-
this.updateAddressErrorMessage();
|
|
16605
|
-
}, ref: (el) => (this.cityElement = el) }), index.h("div", { class: "flex -space-x-px" }, index.h("div", { class: "w-1/2 flex-1 min-w-0" }, index.h("input", { placeholder: "Postcode", type: "text", required: true, class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-bl-md shadow-none': true }), name: "postcode", minlength: "4", maxlength: "4", pattern: "[0-9]{4}", id: "postcode", value: state$2.selfManagedFundForm.postcode, inputmode: "numeric", onChange: (ev) => {
|
|
16606
|
-
this.updateFormField('postcode', ev.target.value.trim());
|
|
16607
|
-
this.updateAddressErrorMessage();
|
|
16608
|
-
}, ref: (el) => (this.postcodeElement = el) })), index.h("div", { class: "flex-1 min-w-0" }, index.h("select", { class: Object.assign(Object.assign({}, inputClass), { 'rounded-none rounded-br-md shadow-none': true, 'text-gray-500': this.fundForm.state !== undefined }), name: "state", required: true, id: "state", onChange: (ev) => {
|
|
16609
|
-
this.updateFormField('state', ev.target.value.trim());
|
|
16610
|
-
this.updateAddressErrorMessage();
|
|
16611
|
-
}, ref: (el) => (this.stateElement = el) }, index.h("option", { disabled: true, selected: this.fundForm.state !== undefined, value: "" }, "State"), this.stateOptions.map((s) => (index.h("option", { value: s.value, selected: this.fundForm.state === s.value }, s.label))))))), isSome(this.addressErrorMessage) && this.showValidationErrors && (index.h("div", { class: "mt-2 text-sm text-red-600" }, this.addressErrorMessage.value))), index.h("div", { class: "flex space-x-4" }, index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Given name(s)"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-given-names-input", name: "memberFirstName", readableName: "Member given name(s)", showValidationErrors: this.showValidationErrors, value: state$2.selfManagedFundForm.memberFirstName, onChange: (ev) => this.updateFormField('memberFirstName', ev.target.value.trim()) }))), index.h("div", { class: "mt-3 w-1/2" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Last name"), index.h("div", { class: "mt-1" }, index.h("sss-name-input", { testId: "member-last-name-input", name: "memberFamilyName", readableName: "Member last name", showValidationErrors: this.showValidationErrors, value: state$2.selfManagedFundForm.memberFamilyName, onChange: (ev) => this.updateFormField('memberFamilyName', ev.target.value.trim()) })))), index.h("h3", { class: "text-lg font-bold mt-6" }, "Fund bank details"), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Account name"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bankAccountName", minlength: "2", id: "bankAccountName", value: state$2.selfManagedFundForm.bankAccountName, onChange: (ev) => this.updateFormField('bankAccountName', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid bank account name"))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "BSB"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bsb", id: "bsb", minlength: "6", maxlength: "7", inputmode: "numeric", onKeyUp: (ev) => this.updateCurrentBank(ev), pattern: this.bsbRegex.source, value: state$2.selfManagedFundForm.bsb }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid BSB"))), isSome(this.currentBank) && (index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Bank name"), index.h("div", { class: "mt-1 shadow-sm px-3 py-2 rounded-md border border-gray-300 bg-gray-50 text-gray-500 text-sm" }, this.currentBank.value))), index.h("div", { class: "mt-3" }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Account number"), index.h("div", { class: "mt-1" }, index.h("input", { type: "text", required: true, class: inputClass, name: "bankAccountNumber", id: "bankAccountNumber", minlength: "2", maxlength: "11", pattern: this.bankAccountNumberRegex.source, inputmode: "numeric", value: state$2.selfManagedFundForm.bankAccountNumber, onKeyUp: (ev) => this.updateCurrentBankAccountNumber(ev), onChange: (ev) => this.updateFormField('bankAccountNumber', ev.target.value.trim()) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Enter a valid bank account number")))));
|
|
16612
|
-
}
|
|
16613
|
-
updateFormField(key, value) {
|
|
16614
|
-
this.formChanged.emit({ [key]: value });
|
|
16615
|
-
}
|
|
16616
|
-
async isAbnUsedForRegulatedAsync(abn) {
|
|
16617
|
-
return !(await customFundChoiceApi.validateAbnForSMSF(abn));
|
|
16618
|
-
}
|
|
16619
|
-
renderAbnValidationError() {
|
|
16620
|
-
if (this.isAbnTouched || this.showValidationErrors) {
|
|
16621
|
-
switch (this.abnValidationStatus) {
|
|
16622
|
-
case AbnValidationStatus.Invalid:
|
|
16623
|
-
return index.h("div", { class: "mt-2 text-sm text-red-600" }, "Enter a valid fund ABN (digits only)");
|
|
16624
|
-
case AbnValidationStatus.AbnIsUsedForRegulatedFund:
|
|
16625
|
-
return (index.h("div", { class: "mt-2 text-sm text-red-600" }, "The supplied ABN is for a regulated fund"));
|
|
16626
|
-
case AbnValidationStatus.Valid:
|
|
16627
|
-
return [];
|
|
16628
|
-
}
|
|
16629
|
-
}
|
|
16630
|
-
return [];
|
|
16631
|
-
}
|
|
16632
|
-
filterDigits(str) {
|
|
16633
|
-
return str.replace(/[^0-9]/g, '');
|
|
16634
|
-
}
|
|
16635
|
-
updateCurrentBank(ev) {
|
|
16636
|
-
const value = this.filterDigits(ev.target.value);
|
|
16637
|
-
const firstTwoNumbers = value.substring(0, 2);
|
|
16638
|
-
const firstThreeNumbers = value.substring(0, 3);
|
|
16639
|
-
const firstTwoNumberBankName = bsbNumbers[firstTwoNumbers];
|
|
16640
|
-
const firstThreeNumberBankName = bsbNumbers[firstThreeNumbers];
|
|
16641
|
-
if (firstTwoNumberBankName)
|
|
16642
|
-
this.currentBank = some(firstTwoNumberBankName);
|
|
16643
|
-
if (firstThreeNumberBankName)
|
|
16644
|
-
this.currentBank = some(firstThreeNumberBankName);
|
|
16645
|
-
if (value === '' || value.length > 6)
|
|
16646
|
-
this.currentBank = none;
|
|
16647
|
-
this.updateFormField('bsb', value);
|
|
16648
|
-
}
|
|
16649
|
-
updateCurrentBankAccountNumber(ev) {
|
|
16650
|
-
const value = this.filterDigits(ev.target.value);
|
|
16651
|
-
this.updateFormField('bankAccountNumber', value);
|
|
16652
|
-
}
|
|
16653
|
-
updateAddressErrorMessage() {
|
|
16654
|
-
let message = none;
|
|
16655
|
-
if (isNone(message) && !this.addressLine1Element.checkValidity()) {
|
|
16656
|
-
message = some('Enter a valid address line 1');
|
|
16657
|
-
}
|
|
16658
|
-
if (isNone(message) && !this.cityElement.checkValidity()) {
|
|
16659
|
-
message = some('Enter a valid city/suburb');
|
|
16660
|
-
}
|
|
16661
|
-
if (isNone(message) && !this.postcodeElement.checkValidity()) {
|
|
16662
|
-
message = some('Enter a valid post code');
|
|
16663
|
-
}
|
|
16664
|
-
if (isNone(message) && !this.stateElement.checkValidity()) {
|
|
16665
|
-
message = some('Select a state');
|
|
16666
|
-
}
|
|
16667
|
-
this.addressErrorMessage = message;
|
|
16668
|
-
}
|
|
16669
|
-
};
|
|
16670
|
-
|
|
16671
|
-
class InteropQuery extends datoramaAkita.Query {
|
|
16672
|
-
constructor(store) {
|
|
16673
|
-
super(store);
|
|
16674
|
-
this.store = store;
|
|
16675
|
-
}
|
|
16676
|
-
isReactNativeInteropEnabled() {
|
|
16677
|
-
return isSome(this.getValue().reactNativeInterop);
|
|
16678
|
-
}
|
|
16679
|
-
isIframeInteropEnabled() {
|
|
16680
|
-
return isSome(this.getValue().iframeInterop);
|
|
16681
|
-
}
|
|
16682
|
-
getIframeInteropMode() {
|
|
16683
|
-
const iframeInterop = this.getValue().iframeInterop;
|
|
16684
|
-
if (isNone(iframeInterop)) {
|
|
16685
|
-
throw Error('Failed to get iframe interop information: no data in store');
|
|
16686
|
-
}
|
|
16687
|
-
if (!this.isIframeInteropEnabled()) {
|
|
16688
|
-
throw Error('Failed to get iframe interop information: iframe mode is disabled');
|
|
16689
|
-
}
|
|
16690
|
-
return iframeInterop.value;
|
|
16691
|
-
}
|
|
16692
|
-
}
|
|
16693
|
-
const interopQuery = new InteropQuery(sessionStore);
|
|
16694
|
-
|
|
16695
|
-
class SlateChoiceApi {
|
|
16696
|
-
async submitSlateChoiceAsync(dto) {
|
|
16697
|
-
return buildBackendApiClient()
|
|
16698
|
-
.url('super-choice/slate')
|
|
16699
|
-
.post(dto)
|
|
16700
|
-
.badRequest(() => {
|
|
16701
|
-
throw new Error('Failed to process Slate join request');
|
|
16702
|
-
})
|
|
16703
|
-
.text();
|
|
16704
|
-
}
|
|
16705
|
-
}
|
|
16706
|
-
const slateChoiceApi = new SlateChoiceApi();
|
|
16707
|
-
|
|
16708
|
-
class SlateIFrameBuilder {
|
|
16709
|
-
constructor() {
|
|
16710
|
-
this.hostIsLocalSuperSelection = () => window.location.origin === 'http://localhost:7100';
|
|
16711
|
-
this.hostIsDeployed = () => window.location.origin.endsWith('partner.flarehr.com');
|
|
16712
|
-
this.skipConsolidation = () => (interopQuery.isReactNativeInteropEnabled() ? 'true' : 'false');
|
|
16713
|
-
this.skipInsurance = () => (interopQuery.isReactNativeInteropEnabled() ? 'true' : 'false');
|
|
16714
|
-
this.environmentDiscriminator = () => {
|
|
16715
|
-
const discriminator = window.location.hostname.toLowerCase().split('.')[0];
|
|
16716
|
-
switch (discriminator) {
|
|
16717
|
-
case 'autodev-partner':
|
|
16718
|
-
case 'test-partner':
|
|
16719
|
-
case 'partner':
|
|
16720
|
-
case 'sandbox-partner':
|
|
16721
|
-
return discriminator.replace('partner', '');
|
|
16722
|
-
default:
|
|
16723
|
-
return 'autodev-';
|
|
16724
|
-
}
|
|
16725
|
-
};
|
|
16726
|
-
this.slateJoinAppUrl = () => {
|
|
16727
|
-
return `https://${this.environmentDiscriminator()}join.slatesuper.com.au/confirm`;
|
|
16728
|
-
};
|
|
16729
|
-
}
|
|
16730
|
-
build(iframe, history) {
|
|
16731
|
-
if (!(iframe === null || iframe === void 0 ? void 0 : iframe.contentDocument))
|
|
16732
|
-
return;
|
|
16733
|
-
const baseUrl = this.hostIsLocalSuperSelection() || this.hostIsDeployed()
|
|
16734
|
-
? `${window.location.origin}/super-selection/embed/v1.0/app`
|
|
16735
|
-
: 'https://autodev-partner.flarehr.com/super-selection/embed/v1.0/app';
|
|
16736
|
-
const redirectUrl = `${baseUrl}/slate-redirect.html`;
|
|
16737
|
-
const postData = Object.assign(Object.assign({}, this.getSlateJoinMemberData()), { successRedirectUrl: redirectUrl, cancelRedirectUrl: redirectUrl, skipConsolidation: this.skipConsolidation(), skipInsurance: this.skipInsurance() });
|
|
16738
|
-
if (this.includeJwt()) {
|
|
16739
|
-
postData.authToken = superSelectionAppService.jwt;
|
|
16740
|
-
}
|
|
16741
|
-
const handleMessage = (event) => {
|
|
16742
|
-
const { data, origin } = event;
|
|
16743
|
-
if (!data) {
|
|
16744
|
-
return;
|
|
16745
|
-
}
|
|
16746
|
-
if (data.sender === 'slate-redirect') {
|
|
16747
|
-
window.removeEventListener('message', handleMessage);
|
|
16748
|
-
switch (data.type) {
|
|
16749
|
-
case 'success':
|
|
16750
|
-
if (data.memberNumber) {
|
|
16751
|
-
navigationService.navigateInternallyToStandardChoice({
|
|
16752
|
-
history,
|
|
16753
|
-
fundName: fund$8.name,
|
|
16754
|
-
fundDetails: {
|
|
16755
|
-
type: 'promoted',
|
|
16756
|
-
fundName: fund$8.name,
|
|
16757
|
-
fundUsi: slateUsi,
|
|
16758
|
-
memberNumber: data.memberNumber,
|
|
16759
|
-
promotedFundId: fund$8.fundId
|
|
16760
|
-
},
|
|
16761
|
-
handleSubmitFn: (standardChoiceFormSignature) => slateChoiceApi.submitSlateChoiceAsync(Object.assign({ memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, standardChoiceFormSignature, defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi) }, superSelectionAppService.promotedFundsConfig)),
|
|
16762
|
-
promotedFundId: fund$8.fundId
|
|
16763
|
-
});
|
|
16764
|
-
break;
|
|
16765
|
-
}
|
|
16766
|
-
/* falls through */
|
|
16767
|
-
default:
|
|
16768
|
-
navigationService.navigateInternally(history, SuperSelectionAppRoutes.ChoicePage);
|
|
16769
|
-
break;
|
|
16770
|
-
}
|
|
16771
|
-
reset();
|
|
16772
|
-
return;
|
|
16773
|
-
}
|
|
16774
|
-
if (data.sender === 'flare' && origin.endsWith('join.slatesuper.com.au')) {
|
|
16775
|
-
switch (data.type) {
|
|
16776
|
-
case 'contentResized':
|
|
16777
|
-
iframe.height = data.height > 0 ? data.height : iframe.height;
|
|
16778
|
-
iframe.width = data.width > 0 ? data.width : iframe.width;
|
|
16779
|
-
break;
|
|
16780
|
-
}
|
|
16781
|
-
}
|
|
16782
|
-
};
|
|
16783
|
-
window.addEventListener('message', handleMessage);
|
|
16784
|
-
const iframeDoc = iframe.contentDocument;
|
|
16785
|
-
iframeDoc.open();
|
|
16786
|
-
const form = iframeDoc.createElement('form');
|
|
16787
|
-
form.method = 'POST';
|
|
16788
|
-
form.target = '_self';
|
|
16789
|
-
form.action = this.slateJoinAppUrl();
|
|
16790
|
-
let prop;
|
|
16791
|
-
for (prop in postData) {
|
|
16792
|
-
const value = postData[prop];
|
|
16793
|
-
if (value !== undefined) {
|
|
16794
|
-
const input = document.createElement('input');
|
|
16795
|
-
input.type = 'hidden';
|
|
16796
|
-
input.name = prop;
|
|
16797
|
-
input.value = value;
|
|
16798
|
-
form.append(input);
|
|
16799
|
-
}
|
|
16800
|
-
}
|
|
16801
|
-
iframeDoc.appendChild(form);
|
|
16802
|
-
iframeDoc.close();
|
|
16803
|
-
form.submit();
|
|
16804
|
-
}
|
|
16805
|
-
getSlateJoinMemberData() {
|
|
16806
|
-
var _a, _b;
|
|
16807
|
-
const superBuyer = superSelectionAppService.superBuyer;
|
|
16808
|
-
const toSlateGender = (gender) => {
|
|
16809
|
-
switch (gender) {
|
|
16810
|
-
case 'Male':
|
|
16811
|
-
return 'Male';
|
|
16812
|
-
case 'Female':
|
|
16813
|
-
return 'Female';
|
|
16814
|
-
case 'Intersex':
|
|
16815
|
-
return 'Intersex/Indeterminate';
|
|
16816
|
-
default:
|
|
16817
|
-
return 'Unknown';
|
|
16818
|
-
}
|
|
16819
|
-
};
|
|
16820
|
-
return {
|
|
16821
|
-
firstName: superBuyer.userProfile.firstName,
|
|
16822
|
-
middleName: superBuyer.userProfile.middleName,
|
|
16823
|
-
lastName: superBuyer.userProfile.lastName,
|
|
16824
|
-
dateOfBirth: superBuyer.userProfile.dateOfBirth,
|
|
16825
|
-
gender: toSlateGender(superBuyer.userProfile.gender),
|
|
16826
|
-
email: superBuyer.userProfile.email,
|
|
16827
|
-
mobilePhone: superBuyer.userProfile.mobilePhone,
|
|
16828
|
-
taxFileNumber: (_a = superBuyer.tfn) !== null && _a !== void 0 ? _a : '',
|
|
16829
|
-
addressLine1: superBuyer.userProfile.address.addressLine1,
|
|
16830
|
-
addressLine2: (_b = superBuyer.userProfile.address.addressLine2) !== null && _b !== void 0 ? _b : '',
|
|
16831
|
-
city: superBuyer.userProfile.address.city,
|
|
16832
|
-
state: superBuyer.userProfile.address.state,
|
|
16833
|
-
postCode: superBuyer.userProfile.address.postcode
|
|
16834
|
-
};
|
|
16835
|
-
}
|
|
16836
|
-
includeJwt() {
|
|
16837
|
-
return !this.slateJoinAppUrl().match(/autodev|sandbox/);
|
|
15685
|
+
if (isNone(configuration)) {
|
|
15686
|
+
throw Error('App configuration is not yet loaded');
|
|
15687
|
+
}
|
|
15688
|
+
return configuration.value;
|
|
16838
15689
|
}
|
|
16839
15690
|
}
|
|
16840
|
-
const
|
|
15691
|
+
const appConfigurationQuery = new AppConfigurationQuery(sessionStore);
|
|
16841
15692
|
|
|
16842
|
-
|
|
16843
|
-
constructor(
|
|
16844
|
-
|
|
15693
|
+
class AppInsightsService {
|
|
15694
|
+
constructor() {
|
|
15695
|
+
this.appInsights = new Lazy(() => new Initialization({
|
|
15696
|
+
config: {
|
|
15697
|
+
instrumentationKey: appConfigurationQuery.configuration.AppInsightsKey,
|
|
15698
|
+
enableAutoRouteTracking: true,
|
|
15699
|
+
autoTrackPageVisitTime: true,
|
|
15700
|
+
maxBatchInterval: 1000,
|
|
15701
|
+
enableUnhandledPromiseRejectionTracking: true
|
|
15702
|
+
}
|
|
15703
|
+
}));
|
|
16845
15704
|
}
|
|
16846
|
-
|
|
16847
|
-
|
|
15705
|
+
init() {
|
|
15706
|
+
this.appInsights.value.loadAppInsights();
|
|
15707
|
+
index.setErrorHandler((err) => this.appInsightsErrorHandler(err));
|
|
16848
15708
|
}
|
|
16849
|
-
|
|
16850
|
-
|
|
16851
|
-
const StandardChoiceFormInputDefaultFund = class {
|
|
16852
|
-
constructor(hostRef) {
|
|
16853
|
-
index.registerInstance(this, hostRef);
|
|
16854
|
-
this.standardChoiceFormSignature = '';
|
|
16855
|
-
this.isSubmitDisabled = true;
|
|
16856
|
-
this.eventTrackingService = EventTrackingService.Instance;
|
|
16857
|
-
this.ignorePopState = () => window.history.pushState(null, '', null);
|
|
15709
|
+
getAppInsights() {
|
|
15710
|
+
return this.appInsights.value;
|
|
16858
15711
|
}
|
|
16859
|
-
|
|
16860
|
-
this.
|
|
16861
|
-
|
|
15712
|
+
addCustomProperties(properties) {
|
|
15713
|
+
this.appInsights.value.addTelemetryInitializer((envelope) => {
|
|
15714
|
+
envelope.data = envelope.data ? envelope.data : {};
|
|
15715
|
+
for (const [k, v] of Object.entries(properties)) {
|
|
15716
|
+
envelope.data[k] = v;
|
|
15717
|
+
}
|
|
15718
|
+
});
|
|
16862
15719
|
}
|
|
16863
|
-
|
|
16864
|
-
|
|
15720
|
+
trackErrorTrace(message) {
|
|
15721
|
+
this.appInsights.value.trackTrace({ message, severityLevel: SeverityLevel.Error });
|
|
16865
15722
|
}
|
|
16866
|
-
|
|
16867
|
-
|
|
16868
|
-
|
|
16869
|
-
|
|
16870
|
-
|
|
16871
|
-
|
|
16872
|
-
|
|
16873
|
-
|
|
16874
|
-
'mt-3': true,
|
|
16875
|
-
'was-validated': this.formState === 'validated'
|
|
16876
|
-
}, ref: (el) => (this.formElement = el), onInput: (_) => (this.isSubmitDisabled = !this.formElement.checkValidity()) }, index.h("label", { class: "text-sm font-medium text-gray-700" }, "Type your full name"), index.h("input", { "data-testid": "standard-choice-form-signature-input", type: "text", autocomplete: "off", class: {
|
|
16877
|
-
'shadow-sm focus:ring-primary-focus focus:border-primary-focus w-full text-base sm:text-sm border-gray-300 rounded-md mt-1': true,
|
|
16878
|
-
'invalid:border-red-300 invalid:text-red-900 invalid:focus:ring-red-500 invalid:focus:border-red-500': this.formState === 'validated'
|
|
16879
|
-
}, required: true, minlength: "2", name: "standardChoiceFormSignature", id: "standardChoiceFormSignature", value: this.standardChoiceFormSignature, onInput: (event) => (this.standardChoiceFormSignature = event.target.value) }), index.h("div", { class: "invalid-feedback mt-2 text-sm text-red-600" }, "Type your full name"), index.h("div", { class: "mt-6" }, index.h("sss-button", { testid: "confirm-and-continue-button", fillWidth: true, promiseFn: () => this.handleSubmitForm(), disabled: this.isSubmitDisabled }, "Confirm and continue"))))))));
|
|
15723
|
+
appInsightsErrorHandler(error) {
|
|
15724
|
+
this.appInsights.value.trackException({
|
|
15725
|
+
error: error,
|
|
15726
|
+
severityLevel: SeverityLevel.Error
|
|
15727
|
+
});
|
|
15728
|
+
// eslint-disable-next-line no-console
|
|
15729
|
+
const defaultStencilErrorHandler = (error) => console.error(error);
|
|
15730
|
+
defaultStencilErrorHandler(error);
|
|
16880
15731
|
}
|
|
16881
|
-
|
|
16882
|
-
|
|
16883
|
-
|
|
16884
|
-
|
|
16885
|
-
|
|
16886
|
-
|
|
16887
|
-
}
|
|
15732
|
+
}
|
|
15733
|
+
const appInsights = new AppInsightsService();
|
|
15734
|
+
|
|
15735
|
+
class SuperCampaignErrorApi {
|
|
15736
|
+
static get Instance() {
|
|
15737
|
+
return this.instance || (this.instance = new this());
|
|
16888
15738
|
}
|
|
16889
|
-
async
|
|
16890
|
-
|
|
16891
|
-
promotedFundsShown: superSelectionAppService.promotedFunds,
|
|
16892
|
-
defaultFundUsiSet: toUndefined(superSelectionAppService.defaultFundUsi)
|
|
16893
|
-
};
|
|
16894
|
-
switch (state$1.fundDetails.type) {
|
|
16895
|
-
case 'default':
|
|
16896
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16897
|
-
DefaultFund: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16898
|
-
});
|
|
16899
|
-
break;
|
|
16900
|
-
case 'myOwnFund':
|
|
16901
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16902
|
-
MyOwnFund: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16903
|
-
});
|
|
16904
|
-
break;
|
|
16905
|
-
case 'smsf':
|
|
16906
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16907
|
-
Smsf: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16908
|
-
});
|
|
16909
|
-
break;
|
|
16910
|
-
case 'promoted':
|
|
16911
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16912
|
-
PromotedFund: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16913
|
-
});
|
|
16914
|
-
break;
|
|
16915
|
-
case 'promotedDefault':
|
|
16916
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16917
|
-
PromotedDefaultFund: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16918
|
-
});
|
|
16919
|
-
break;
|
|
16920
|
-
case 'promotedDefaultWithJoin':
|
|
16921
|
-
await this.eventTrackingService.TrackSuperFundDetailChangeRequestedAsync({
|
|
16922
|
-
PromotedDefaultFundWithJoin: Object.assign(Object.assign({}, state$1.fundDetails), common)
|
|
16923
|
-
});
|
|
16924
|
-
break;
|
|
16925
|
-
case 'null':
|
|
16926
|
-
throw 'standardChoiceFormState.fundDetails was not set';
|
|
16927
|
-
}
|
|
15739
|
+
async PostError(error) {
|
|
15740
|
+
buildBackendApiClient().url('super-campaign/errors').post(error);
|
|
16928
15741
|
}
|
|
16929
|
-
|
|
16930
|
-
|
|
16931
|
-
|
|
16932
|
-
|
|
16933
|
-
|
|
15742
|
+
}
|
|
15743
|
+
|
|
15744
|
+
const SuperFundDisclaimerViewedDetail = {
|
|
15745
|
+
create: (superCampaignEnabled) => {
|
|
15746
|
+
let isDefinedBenefitsEligibleString = 'Not set';
|
|
15747
|
+
if (Option.isSome(superSelectionAppService.isDefinedBenefitsEligible)) {
|
|
15748
|
+
isDefinedBenefitsEligibleString = superSelectionAppService.isDefinedBenefitsEligible.value
|
|
15749
|
+
? 'True'
|
|
15750
|
+
: 'False';
|
|
16934
15751
|
}
|
|
15752
|
+
return {
|
|
15753
|
+
isDefinedBenefitsEligible: isDefinedBenefitsEligibleString,
|
|
15754
|
+
superCampaignEnabled: superCampaignEnabled
|
|
15755
|
+
};
|
|
16935
15756
|
}
|
|
16936
15757
|
};
|
|
16937
15758
|
|
|
16938
|
-
|
|
16939
|
-
|
|
16940
|
-
|
|
16941
|
-
|
|
16942
|
-
|
|
16943
|
-
|
|
16944
|
-
|
|
16945
|
-
|
|
16946
|
-
|
|
16947
|
-
disconnectedCallback() {
|
|
16948
|
-
window.removeEventListener('popstate', this.ignorePopState);
|
|
15759
|
+
class PromotedFundChoiceApi {
|
|
15760
|
+
async submitChoiceAsync(dto) {
|
|
15761
|
+
return buildBackendApiClient()
|
|
15762
|
+
.url('super-choice/promoted-fund')
|
|
15763
|
+
.post(dto)
|
|
15764
|
+
.badRequest(() => {
|
|
15765
|
+
throw new Error('Failed to process Promoted Fund choice request');
|
|
15766
|
+
})
|
|
15767
|
+
.text();
|
|
16949
15768
|
}
|
|
16950
|
-
|
|
16951
|
-
|
|
16952
|
-
|
|
16953
|
-
|
|
16954
|
-
|
|
15769
|
+
async submitDefaultChoiceAsync(dto) {
|
|
15770
|
+
return buildBackendApiClient()
|
|
15771
|
+
.url('super-choice/promoted-fund/default')
|
|
15772
|
+
.post(dto)
|
|
15773
|
+
.badRequest(() => {
|
|
15774
|
+
throw new Error('Failed to process Promoted Default Fund choice request');
|
|
15775
|
+
})
|
|
15776
|
+
.text();
|
|
16955
15777
|
}
|
|
16956
|
-
|
|
16957
|
-
|
|
15778
|
+
async submitDefaultChoiceWithJoinAsync(dto) {
|
|
15779
|
+
return buildBackendApiClient()
|
|
15780
|
+
.url('super-choice/promoted-fund/default-with-join')
|
|
15781
|
+
.post(dto)
|
|
15782
|
+
.badRequest(() => {
|
|
15783
|
+
throw new Error('Failed to process Promoted Default Fund With Join choice request');
|
|
15784
|
+
})
|
|
15785
|
+
.text();
|
|
16958
15786
|
}
|
|
16959
|
-
}
|
|
15787
|
+
}
|
|
15788
|
+
const promotedFundChoiceApi = new PromotedFundChoiceApi();
|
|
16960
15789
|
|
|
16961
|
-
class
|
|
16962
|
-
|
|
16963
|
-
return
|
|
16964
|
-
|
|
16965
|
-
|
|
16966
|
-
|
|
15790
|
+
class SlateChoiceApi {
|
|
15791
|
+
async submitSlateChoiceAsync(dto) {
|
|
15792
|
+
return buildBackendApiClient()
|
|
15793
|
+
.url('super-choice/slate')
|
|
15794
|
+
.post(dto)
|
|
15795
|
+
.badRequest(() => {
|
|
15796
|
+
throw new Error('Failed to process Slate join request');
|
|
15797
|
+
})
|
|
15798
|
+
.text();
|
|
16967
15799
|
}
|
|
16968
15800
|
}
|
|
15801
|
+
const slateChoiceApi = new SlateChoiceApi();
|
|
16969
15802
|
|
|
16970
15803
|
class MiscService {
|
|
16971
15804
|
trackClickPromotedTileAsync(payload) {
|
|
@@ -17125,9 +15958,6 @@ const SuperCampaignHost = class {
|
|
|
17125
15958
|
}
|
|
17126
15959
|
return Promise.resolve();
|
|
17127
15960
|
};
|
|
17128
|
-
this.getFundName = (fundId) => {
|
|
17129
|
-
return _function.pipe(getFundNameByFundId(fundId), Option.getOrElse(() => ''));
|
|
17130
|
-
};
|
|
17131
15961
|
this.stringIsNullOrEmtpty = (s) => {
|
|
17132
15962
|
return !(typeof s === 'string' && s.trim().length > 0);
|
|
17133
15963
|
};
|
|
@@ -17137,21 +15967,20 @@ const SuperCampaignHost = class {
|
|
|
17137
15967
|
return;
|
|
17138
15968
|
}
|
|
17139
15969
|
const usi = Usi.clean(data.usi);
|
|
17140
|
-
const fundName = this.getFundName(data.fundId);
|
|
17141
15970
|
const defaultFundUsiSet = Option.toUndefined(superSelectionAppService.defaultFundUsi);
|
|
17142
15971
|
navigationService.navigateInternallyToStandardChoice({
|
|
17143
15972
|
history: this.history,
|
|
17144
|
-
fundName,
|
|
15973
|
+
fundName: data.fundName,
|
|
17145
15974
|
promotedFundId: data.fundId,
|
|
17146
15975
|
fundDetails: {
|
|
17147
15976
|
type: 'promoted',
|
|
17148
|
-
fundName,
|
|
15977
|
+
fundName: data.fundName,
|
|
17149
15978
|
fundUsi: usi,
|
|
17150
15979
|
memberNumber: data.memberNumber,
|
|
17151
15980
|
promotedFundId: data.fundId
|
|
17152
15981
|
},
|
|
17153
15982
|
handleSubmitFn: async (standardChoiceFormSignature) => {
|
|
17154
|
-
if (data.fundId ==
|
|
15983
|
+
if (data.fundId == slate.fundId) {
|
|
17155
15984
|
await slateChoiceApi.submitSlateChoiceAsync(Object.assign({ memberNumber: data.memberNumber, memberFirstName: data.memberFirstName, memberFamilyName: data.memberFamilyName, standardChoiceFormSignature,
|
|
17156
15985
|
defaultFundUsiSet }, this.PromotedFundsConfig));
|
|
17157
15986
|
}
|
|
@@ -17169,14 +15998,13 @@ const SuperCampaignHost = class {
|
|
|
17169
15998
|
return;
|
|
17170
15999
|
}
|
|
17171
16000
|
const usi = Usi.clean(data.usi);
|
|
17172
|
-
const fundName = this.getFundName(data.fundId);
|
|
17173
16001
|
navigationService.navigateInternallyToStandardChoice({
|
|
17174
16002
|
history: this.history,
|
|
17175
|
-
fundName,
|
|
16003
|
+
fundName: data.fundName,
|
|
17176
16004
|
promotedFundId: data.fundId,
|
|
17177
16005
|
fundDetails: {
|
|
17178
16006
|
type: 'promotedDefault',
|
|
17179
|
-
fundName,
|
|
16007
|
+
fundName: data.fundName,
|
|
17180
16008
|
fundUsi: usi,
|
|
17181
16009
|
promotedFundId: data.fundId
|
|
17182
16010
|
},
|
|
@@ -17190,14 +16018,13 @@ const SuperCampaignHost = class {
|
|
|
17190
16018
|
return;
|
|
17191
16019
|
}
|
|
17192
16020
|
const usi = Usi.clean(data.usi);
|
|
17193
|
-
const fundName = this.getFundName(data.fundId);
|
|
17194
16021
|
navigationService.navigateInternallyToStandardChoice({
|
|
17195
16022
|
history: this.history,
|
|
17196
|
-
fundName,
|
|
16023
|
+
fundName: data.fundName,
|
|
17197
16024
|
promotedFundId: data.fundId,
|
|
17198
16025
|
fundDetails: {
|
|
17199
16026
|
type: 'promotedDefaultWithJoin',
|
|
17200
|
-
fundName,
|
|
16027
|
+
fundName: data.fundName,
|
|
17201
16028
|
fundUsi: usi,
|
|
17202
16029
|
memberNumber: data.memberNumber,
|
|
17203
16030
|
promotedFundId: data.fundId
|
|
@@ -17230,7 +16057,7 @@ const SuperCampaignHost = class {
|
|
|
17230
16057
|
async componentWillLoad() {
|
|
17231
16058
|
if (superSelectionAppService.state.superCampaignComponentStatus ===
|
|
17232
16059
|
SuperCampaignComponentStatus.NotWorking) {
|
|
17233
|
-
|
|
16060
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.MyOwnFund);
|
|
17234
16061
|
return;
|
|
17235
16062
|
}
|
|
17236
16063
|
let superCampaingScriptPath = undefined;
|
|
@@ -17304,136 +16131,6 @@ const SuperCampaignHost = class {
|
|
|
17304
16131
|
};
|
|
17305
16132
|
injectHistory(SuperCampaignHost);
|
|
17306
16133
|
|
|
17307
|
-
const SuperChoiceItemBottom = class {
|
|
17308
|
-
constructor(hostRef) {
|
|
17309
|
-
index.registerInstance(this, hostRef);
|
|
17310
|
-
this.joinFundClicked = index.createEvent(this, "joinFundClicked", 7);
|
|
17311
|
-
}
|
|
17312
|
-
render() {
|
|
17313
|
-
return (index.h(index.Host, null, index.h("div", { class: "py-6 px-4 flex flex-col justify-between h-full" }, index.h("div", null, index.h("div", { class: { 'md:max-w-[240px]': true, 'lg:max-w-full': this.isMultiFund } }, index.h("sss-button", { testid: "choose-this-fund-button", class: "uuid-button-continue", fillWidth: true, onClick: () => this.handleFundClick() }, "Choose this fund")), index.h("div", { class: "text-xs text-gray-500 mt-6 leading-4" }, this.disclaimer)), this.abnInfo && this.abn && (index.h("div", { class: "text-xs text-gray-500 mt-2" }, index.h("p", null, "Issued by ", this.abnInfo, "."), index.h("p", null, "ABN: ", this.abn))))));
|
|
17314
|
-
}
|
|
17315
|
-
handleFundClick() {
|
|
17316
|
-
return this.joinFundClicked.emit();
|
|
17317
|
-
}
|
|
17318
|
-
};
|
|
17319
|
-
|
|
17320
|
-
const SuperChoiceItemTop = class {
|
|
17321
|
-
constructor(hostRef) {
|
|
17322
|
-
index.registerInstance(this, hostRef);
|
|
17323
|
-
}
|
|
17324
|
-
render() {
|
|
17325
|
-
return (index.h(index.Host, null, index.h("div", { class: "px-4 pt-6" }, index.h("div", { class: "text-right w-100 -mt-5 -mr-2" }, this.extraBadge, this.isPromotedDefault && (index.h("span", { class: "text-xs bg-blue-100 text-blue-800 font-medium rounded-xl py-0.5 px-2.5 mr-1" }, "Employer Default")), index.h("span", { class: "text-xs bg-gray-100 text-gray-800 font-medium rounded-xl py-0.5 px-2.5 mr-0.5" }, "Featured")), index.h("div", { class: { 'flex lg:block mt-2 md:mt-0': true, 'lg:mt-4': this.isMultiFund } }, index.h("img", { class: {
|
|
17326
|
-
'h-12 md:h-14 lg:h-16 object-contain w-[80px] md:w-[96px] lg:w-[140px] md:hidden lg:object-left': true,
|
|
17327
|
-
'lg:block': this.isMultiFund
|
|
17328
|
-
}, alt: this.name, src: index.getAssetPath(`assets/${this.logo}`) }), index.h("div", { class: "grid content-center" }, index.h("p", { class: {
|
|
17329
|
-
'text-base md:text-lg font-bold ml-4 md:ml-0 md:mb-0': true,
|
|
17330
|
-
'lg:mt-4': this.isMultiFund
|
|
17331
|
-
} }, this.name))), index.h("div", { class: "mt-4 sm:mt-2 text-sm space-y-2" }, this.features.map((feature) => (index.h("div", { class: "flex" }, index.h("div", { class: "h-5 w-5 flex-none mr-1.5" }, index.h("img", { alt: "checked", src: index.getAssetPath(`assets/icon-check.svg`) })), index.h("div", { class: "leading-5" }, feature))))), this.featureSubText && (index.h("p", { class: "text-xs text-gray-500 italic mt-4 leading-4" }, this.featureSubText)), this.customContent)));
|
|
17332
|
-
}
|
|
17333
|
-
};
|
|
17334
|
-
|
|
17335
|
-
const SuperChoicePage = class {
|
|
17336
|
-
constructor(hostRef) {
|
|
17337
|
-
index.registerInstance(this, hostRef);
|
|
17338
|
-
this.promotedFunds = this.getPromotedFunds();
|
|
17339
|
-
this.eventTrackingService = EventTrackingService.Instance;
|
|
17340
|
-
}
|
|
17341
|
-
async componentDidLoad() {
|
|
17342
|
-
const promotedFundsShown = this.promotedFunds.map((item) => item.fundId);
|
|
17343
|
-
await superSelectionAppService.viewSuperFundPanelAsync(promotedFundsShown);
|
|
17344
|
-
}
|
|
17345
|
-
render() {
|
|
17346
|
-
const mygovLink = 'https://my.gov.au';
|
|
17347
|
-
const mygovLinkDisplay = 'www.my.gov.au';
|
|
17348
|
-
const superfundsLink = 'https://www.apra.gov.au/register-of-superannuation-institutions';
|
|
17349
|
-
const superfundsLinkDisplay = 'www.apra.gov.au';
|
|
17350
|
-
const isMultiFund = this.promotedFunds.length > 1;
|
|
17351
|
-
return (index.h(index.Host, null, index.h("div", null, index.h("sss-header-section", { currentPage: "choice" }), index.h("div", { class: "mt-8 text-sm text-center leading-6" }, index.h("p", { class: "leading-6" }, "Not ready to join a new fund, or want to nominate another super fund?"), index.h("stencil-route-link", { url: SuperSelectionAppRoutes.MyOwnFund }, index.h("span", { class: "inline-block text-primary-base font-medium mt-3" }, "Skip Featured Funds\u00A0", index.h("svg", { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 24 24", "stroke-width": "1.5", stroke: "currentColor", class: "inline h-5 w-5 fill-primary-base group-hover:fill-white" }, index.h("path", { "stroke-linecap": "round", "stroke-linejoin": "round", d: "M17.25 8.25L21 12m0 0l-3.75 3.75M21 12H3" }))))), index.h("div", { class: "flex justify-center mt-8" }, index.h("div", { class: {
|
|
17352
|
-
'lg:grid border-l border-t lg:border-b rounded-lg': true,
|
|
17353
|
-
'lg:grid-cols-1 max-w-720': this.promotedFunds.length === 1,
|
|
17354
|
-
'lg:grid-cols-2 max-w-720': this.promotedFunds.length === 2,
|
|
17355
|
-
'lg:grid-cols-3 max-w-960': this.promotedFunds.length === 3
|
|
17356
|
-
} }, this.promotedFunds.map((fund, index$1) => (index.h("div", { class: {
|
|
17357
|
-
'border-r': true,
|
|
17358
|
-
'rounded-tr-lg': index$1 === 0,
|
|
17359
|
-
'lg:rounded-tr-none': index$1 === 0 && index$1 !== this.promotedFunds.length - 1,
|
|
17360
|
-
'rounded-br-lg lg:rounded-br-none lg:rounded-tr-lg': index$1 === this.promotedFunds.length - 1
|
|
17361
|
-
} }, index.h("div", { class: {
|
|
17362
|
-
'flex border-b lg:border-b-0': true,
|
|
17363
|
-
'rounded-b-lg': index$1 === this.promotedFunds.length - 1
|
|
17364
|
-
} }, index.h("div", { class: {
|
|
17365
|
-
'hidden md:flex w-36 justify-center pt-6 pl-6': true,
|
|
17366
|
-
'lg:hidden': isMultiFund
|
|
17367
|
-
} }, index.h("img", { class: "h-16 object-contain w-full max-w-[96px]", alt: fund.name, src: index.getAssetPath(`assets/${fund.logo}`) })), index.h("div", { class: "w-full" }, index.h("sss-super-choice-item-top", { logo: fund.logo, name: fund.name, features: fund.features, featureSubText: fund.featureSubText, customContent: fund.customContent, isMultiFund: isMultiFund, isPromotedDefault: fund.isPromotedDefault, extraBadge: fund.extraBadge }), index.h("div", { class: { 'lg:hidden': isMultiFund } }, index.h("sss-super-choice-item-bottom", { disclaimer: fund.disclaimer, abnInfo: fund.abnInfo, abn: fund.abn, isMultiFund: isMultiFund, onJoinFundClicked: async () => this.handleJoinSuperClickAsync(fund) }))))))), this.promotedFunds.map((fund, index$1) => (index.h("div", { class: {
|
|
17368
|
-
'hidden border-r': true,
|
|
17369
|
-
'lg:block': isMultiFund,
|
|
17370
|
-
'rounded-br-lg': index$1 === this.promotedFunds.length - 1
|
|
17371
|
-
} }, index.h("sss-super-choice-item-bottom", { disclaimer: fund.disclaimer, abnInfo: fund.abnInfo, abn: fund.abn, isMultiFund: isMultiFund, onJoinFundClicked: async () => this.handleJoinSuperClickAsync(fund) })))))), index.h("div", { class: "flex justify-center mt-8 sm:mt-12" }, index.h("div", { class: "pb-8 sm:pb-12 max-w-720 border-b" }, index.h("h5", { class: "font-bold sm:text-lg" }, "Or, choose another super fund:"), index.h("ul", { class: "list-disc list-outside ml-6 mt-3 mb-6 space-y-2 leading-6 text-sm sm:text-base" }, index.h("li", null, "Select this option if you'd like to use your current account with another super fund, your self-managed super fund, or your employer's default fund."), index.h("li", null, "If you are unsure of your current super fund details, you can find out at", ' ', index.h("a", { class: "text-primary-base font-medium hover:text-primary-hover", target: "_blank", href: navigationService.toExternalUrl(mygovLink) }, mygovLinkDisplay)), index.h("li", null, "A full list of super funds can be viewed at", ' ', index.h("a", { class: "text-primary-base font-medium hover:text-primary-hover", target: "_blank", href: navigationService.toExternalUrl(superfundsLink) }, superfundsLinkDisplay))), index.h("stencil-route-link", { url: SuperSelectionAppRoutes.MyOwnFund }, index.h("sss-button", { testid: "choose-another-super-fund-button", fillWidthOnMobile: true }, "Choose another super fund")))), index.h("div", { class: "flex justify-center" }, index.h("div", { class: "pt-8 sm:pt-12 max-w-720" }, index.h("h5", { class: "font-semibold" }, "IMPORTANT INFORMATION:"), index.h("ul", { class: "list-disc list-outside ml-6 mt-3 space-y-2 text-sm leading-6" }, index.h("li", null, "The superannuation funds featured above are for your information only. The order, position and placement of content should not be interpreted as an opinion or recommendation (actual or implied) by Flare as to the suitability or appropriateness of any superannuation fund for you. In featuring these superannuation funds, Flare has not taken into account your objectives, financial situation or needs."), index.h("li", null, "This is not a comparison service. This page contains factual information only and does not constitute either general or personal advice about any financial products. We do not take into account your objectives, financial situation or needs. If you have questions or need help making a decision about your superannuation fund, you should speak to a licensed financial product advice provider."), index.h("li", null, "Flare, the technology partner you are accessing Flare via and your employer do not endorse or accept responsibility for any financial product advice or services provided by the promoters or trustees of the featured superannuation funds. Flare does not endorse or accept responsibility for any of the content shown about any of the featured superannuation funds."), index.h("li", null, "You should consider the relevant superannuation fund\u2019s PDS and TMD (if applicable) in deciding whether to apply to join the superannuation fund. Each of the superannuation funds featured above include a link to their PDS and TMD (if applicable) for your convenience. If you are considering joining another superannuation fund, you can typically find the PDS and TMD (if applicable) on that fund\u2019s website."), index.h("li", null, "You should be aware that the trustees of featured superannuation funds pay fees to Flare and/or its associates. Some funds pay us a fee if you choose one of the featured funds, while others pay us to have their application form on our platform.")))))));
|
|
17372
|
-
}
|
|
17373
|
-
getPromotedFunds() {
|
|
17374
|
-
const fundTiles = [];
|
|
17375
|
-
superSelectionAppService.promotedFunds.forEach((fundId) => {
|
|
17376
|
-
const fund = allPromotedFunds.find((fund) => fundId === fund.fundId);
|
|
17377
|
-
if (fund !== undefined) {
|
|
17378
|
-
fundTiles.push(fund);
|
|
17379
|
-
}
|
|
17380
|
-
});
|
|
17381
|
-
return fundTiles;
|
|
17382
|
-
}
|
|
17383
|
-
async handleJoinSuperClickAsync(fund) {
|
|
17384
|
-
const promotedFundsShown = superSelectionAppService.promotedFunds;
|
|
17385
|
-
const fundUsi = getFundUsiByFundId(fund.fundId);
|
|
17386
|
-
const fundName = getFundNameByFundId(fund.fundId);
|
|
17387
|
-
await Promise.all([
|
|
17388
|
-
fund.isPromotedDefault == true
|
|
17389
|
-
? this.eventTrackingService.TrackPromotedDefaultSuperFundDetailViewedAsync({
|
|
17390
|
-
fundUsi: Option.isSome(fundUsi) ? fundUsi.value : '',
|
|
17391
|
-
fundName: Option.isSome(fundName) ? fundName.value : '',
|
|
17392
|
-
promotedFundId: fund.fundId,
|
|
17393
|
-
promotedFundsShown,
|
|
17394
|
-
defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi),
|
|
17395
|
-
superCampaignEnabled: false
|
|
17396
|
-
})
|
|
17397
|
-
: this.eventTrackingService.TrackPromotedSuperFundDetailViewedAsync({
|
|
17398
|
-
fundUsi: Option.isSome(fundUsi) ? fundUsi.value : undefined,
|
|
17399
|
-
fundName: Option.isSome(fundName) ? fundName.value : '',
|
|
17400
|
-
promotedFundId: fund.fundId,
|
|
17401
|
-
promotedFundsShown,
|
|
17402
|
-
defaultFundUsiSet: Option.toUndefined(superSelectionAppService.defaultFundUsi),
|
|
17403
|
-
superCampaignEnabled: false
|
|
17404
|
-
}),
|
|
17405
|
-
miscService.trackClickPromotedTileAsync(fund.isPromotedDefault
|
|
17406
|
-
? {
|
|
17407
|
-
promotedDefault: {
|
|
17408
|
-
fundId: fund.fundId
|
|
17409
|
-
}
|
|
17410
|
-
}
|
|
17411
|
-
: {
|
|
17412
|
-
promoted: {
|
|
17413
|
-
fundId: fund.fundId
|
|
17414
|
-
}
|
|
17415
|
-
})
|
|
17416
|
-
]);
|
|
17417
|
-
state.fund = {
|
|
17418
|
-
id: fund.fundId,
|
|
17419
|
-
type: fund.isPromotedDefault ? 'PromotedDefault' : 'Promoted'
|
|
17420
|
-
};
|
|
17421
|
-
return navigationService.navigateInternally(this.history, fund.route);
|
|
17422
|
-
}
|
|
17423
|
-
static get assetsDirs() { return ["assets"]; }
|
|
17424
|
-
};
|
|
17425
|
-
injectHistory(SuperChoicePage);
|
|
17426
|
-
|
|
17427
|
-
const SuperChoicePageWrapper = class {
|
|
17428
|
-
constructor(hostRef) {
|
|
17429
|
-
index.registerInstance(this, hostRef);
|
|
17430
|
-
}
|
|
17431
|
-
render() {
|
|
17432
|
-
return superSelectionAppService.state.superCampaignEnabled ? (index.h("sss-super-campaign-host", null)) : (index.h("sss-super-choice-page", null));
|
|
17433
|
-
}
|
|
17434
|
-
};
|
|
17435
|
-
injectHistory(SuperChoicePageWrapper);
|
|
17436
|
-
|
|
17437
16134
|
const routeCss = "stencil-route.inactive{display:none}";
|
|
17438
16135
|
|
|
17439
16136
|
const Route = class {
|
|
@@ -18430,7 +17127,7 @@ const SuperSelectionApp = class {
|
|
|
18430
17127
|
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ExistingChoicePage);
|
|
18431
17128
|
}
|
|
18432
17129
|
else {
|
|
18433
|
-
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.
|
|
17130
|
+
navigationService.navigateInternally(this.history, SuperSelectionAppRoutes.ChoicePage);
|
|
18434
17131
|
}
|
|
18435
17132
|
}
|
|
18436
17133
|
authTokenChanged(newValue) {
|
|
@@ -18442,24 +17139,12 @@ const SuperSelectionApp = class {
|
|
|
18442
17139
|
render() {
|
|
18443
17140
|
return (index.h(index.Host, null, index.h("link", { rel: "stylesheet", href: index.getAssetPath('apollo-super-selection.css'), media: "all" }), this.renderAppContent()));
|
|
18444
17141
|
}
|
|
18445
|
-
isFundJoinPage() {
|
|
18446
|
-
return (window.location.pathname.includes(SuperSelectionAppRoutes.SlateJoin) ||
|
|
18447
|
-
window.location.pathname.includes(SuperSelectionAppRoutes.PromotedFundJoinV1) ||
|
|
18448
|
-
window.location.pathname.includes(SuperSelectionAppRoutes.PromotedFundJoinV2));
|
|
18449
|
-
}
|
|
18450
|
-
getFooterTextOverride() {
|
|
18451
|
-
return getFooterTextOverrideByFundId(state.fund.id);
|
|
18452
|
-
}
|
|
18453
17142
|
routerBaseUrl() {
|
|
18454
17143
|
var _a;
|
|
18455
17144
|
return ((_a = this.appBaseUrl) === null || _a === void 0 ? void 0 : _a.replace(/\/$/, '')) + '/';
|
|
18456
17145
|
}
|
|
18457
17146
|
renderAppContent() {
|
|
18458
|
-
return (index.h("stencil-router", { root: this.routerBaseUrl(), class: "font-inter" }, index.h("stencil-route-switch", { scrollTopOffset: 0 }, this.isAppInitialised ? (index.h("div", { class: {
|
|
18459
|
-
'pt-28': true,
|
|
18460
|
-
'-mt-12 pb-6': !this.isFundJoinPage(),
|
|
18461
|
-
'-mt-28': this.isFundJoinPage() // -mt value same as pt to negate it in embedded fund join pages
|
|
18462
|
-
} }, superSelectionAppStencilRoutes, index.h("sss-footer-section", { textOverride: this.getFooterTextOverride() }))) : (index.h("div", { class: "flex justify-center py-20" }, index.h("sss-loading-indicator", null))))));
|
|
17147
|
+
return (index.h("stencil-router", { root: this.routerBaseUrl(), class: "font-inter" }, index.h("stencil-route-switch", { scrollTopOffset: 0 }, this.isAppInitialised ? (index.h("div", { class: "pt-28 -mt-12 pb-6" }, superSelectionAppStencilRoutes, index.h("sss-footer-section", null))) : (index.h("div", { class: "flex justify-center py-20" }, index.h("sss-loading-indicator", null))))));
|
|
18463
17148
|
}
|
|
18464
17149
|
static get assetsDirs() { return ["assets"]; }
|
|
18465
17150
|
static get watchers() { return {
|
|
@@ -19072,6 +17757,30 @@ class AuthenticationService {
|
|
|
19072
17757
|
}
|
|
19073
17758
|
const authenticationService = new AuthenticationService();
|
|
19074
17759
|
|
|
17760
|
+
class InteropQuery extends datoramaAkita.Query {
|
|
17761
|
+
constructor(store) {
|
|
17762
|
+
super(store);
|
|
17763
|
+
this.store = store;
|
|
17764
|
+
}
|
|
17765
|
+
isReactNativeInteropEnabled() {
|
|
17766
|
+
return isSome(this.getValue().reactNativeInterop);
|
|
17767
|
+
}
|
|
17768
|
+
isIframeInteropEnabled() {
|
|
17769
|
+
return isSome(this.getValue().iframeInterop);
|
|
17770
|
+
}
|
|
17771
|
+
getIframeInteropMode() {
|
|
17772
|
+
const iframeInterop = this.getValue().iframeInterop;
|
|
17773
|
+
if (isNone(iframeInterop)) {
|
|
17774
|
+
throw Error('Failed to get iframe interop information: no data in store');
|
|
17775
|
+
}
|
|
17776
|
+
if (!this.isIframeInteropEnabled()) {
|
|
17777
|
+
throw Error('Failed to get iframe interop information: iframe mode is disabled');
|
|
17778
|
+
}
|
|
17779
|
+
return iframeInterop.value;
|
|
17780
|
+
}
|
|
17781
|
+
}
|
|
17782
|
+
const interopQuery = new InteropQuery(sessionStore);
|
|
17783
|
+
|
|
19075
17784
|
class IFrameInteropService {
|
|
19076
17785
|
static completeSuperSelectionStep() {
|
|
19077
17786
|
const { successRedirectionUrl } = interopQuery.getIframeInteropMode();
|
|
@@ -19236,19 +17945,14 @@ const SuperSelectionAppHost = class {
|
|
|
19236
17945
|
SuperSelectionAppHost.style = superSelectionAppHostCss;
|
|
19237
17946
|
|
|
19238
17947
|
exports.sss_button = Button;
|
|
19239
|
-
exports.sss_consent_page = Consent;
|
|
19240
|
-
exports.sss_consent_page_wrapper = ConsentWrapper;
|
|
19241
17948
|
exports.sss_custom_fund = CustomFund;
|
|
19242
17949
|
exports.sss_default_fund = DefaultFund;
|
|
19243
17950
|
exports.sss_dropdown_async = SelectInputAsync;
|
|
19244
17951
|
exports.sss_existing_choice_page = ExistingChoice;
|
|
19245
17952
|
exports.sss_footer_section = FooterSection;
|
|
19246
17953
|
exports.sss_header_section = HeaderSection;
|
|
19247
|
-
exports.sss_iframe_host = IFrameHost;
|
|
19248
|
-
exports.sss_loading_component = LoadingComponent;
|
|
19249
17954
|
exports.sss_loading_indicator = LoadingIndicator;
|
|
19250
17955
|
exports.sss_loading_page = LoadingPage;
|
|
19251
|
-
exports.sss_loading_super_indicator = LoadingComponent$1;
|
|
19252
17956
|
exports.sss_my_own_fund = MyOwnFund;
|
|
19253
17957
|
exports.sss_my_own_fund_inputs = MyOwnFundInputs;
|
|
19254
17958
|
exports.sss_name_input = MemberNameInput;
|
|
@@ -19260,18 +17964,11 @@ exports.sss_prefill_invalid_smsf = PrefillInvalidSMSF;
|
|
|
19260
17964
|
exports.sss_prefill_my_own_fund = PrefillMyOwnFund;
|
|
19261
17965
|
exports.sss_prefill_smsf = PrefillSMSF;
|
|
19262
17966
|
exports.sss_prefill_warning_box = PrefillWarningBox;
|
|
19263
|
-
exports.sss_promoted_fund_join_v1_page = PromotedFundJoinV1Page;
|
|
19264
|
-
exports.sss_promoted_fund_join_v2_page = PromotedFundJoinV2Page;
|
|
19265
17967
|
exports.sss_self_managed_fund = SelfManagedFund;
|
|
19266
17968
|
exports.sss_self_managed_fund_inputs = SelfManagedFundInputs;
|
|
19267
|
-
exports.sss_slate_join_page = SlateJoinPage;
|
|
19268
17969
|
exports.sss_standard_choice_form = StandardChoiceFormInputDefaultFund;
|
|
19269
17970
|
exports.sss_success = Success;
|
|
19270
17971
|
exports.sss_super_campaign_host = SuperCampaignHost;
|
|
19271
|
-
exports.sss_super_choice_item_bottom = SuperChoiceItemBottom;
|
|
19272
|
-
exports.sss_super_choice_item_top = SuperChoiceItemTop;
|
|
19273
|
-
exports.sss_super_choice_page = SuperChoicePage;
|
|
19274
|
-
exports.sss_super_choice_page_wrapper = SuperChoicePageWrapper;
|
|
19275
17972
|
exports.stencil_route = Route;
|
|
19276
17973
|
exports.stencil_route_link = RouteLink$1;
|
|
19277
17974
|
exports.stencil_route_switch = RouteSwitch;
|