placementt-core 1.400.458 → 1.400.461
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/.github/workflows/publish.yaml +30 -0
- package/deploy-all.js +91 -91
- package/lib/config.d.ts +3 -3
- package/lib/features/contacts/contactsSlice.d.ts +5 -5
- package/lib/features/jobs/jobsSlice.d.ts +1 -1
- package/lib/features/logs/logsSlice.d.ts +5 -5
- package/lib/features/placements/studentPlacements/activePlacement.d.ts +2 -2
- package/lib/features/placements/studentPlacements/completedStudentPlacementsSlice.d.ts +3 -3
- package/lib/features/placements/studentPlacements/upcomingStudentPlacementsSlice.d.ts +3 -3
- package/lib/firebase/firebaseConfig.js +1 -1
- package/lib/firebase/firebaseConfig.js.map +1 -1
- package/lib/hooks.d.ts +2 -2
- package/lib/images/GatsbyBenchmarks.d.ts +2 -1
- package/lib/reduxHooks.d.ts +2 -2
- package/lib/typeDefinitions.d.ts +2 -2
- package/package.json +23 -5
- package/src/firebase/firebaseConfig.tsx +2 -2
- package/src/typeDefinitions.ts +2 -2
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
name: Deploy
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches:
|
|
6
|
+
- main
|
|
7
|
+
permissions:
|
|
8
|
+
contents: read # default for repo checkout
|
|
9
|
+
id-token: write # <-- required for npm provenance
|
|
10
|
+
jobs:
|
|
11
|
+
publish:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v4
|
|
15
|
+
|
|
16
|
+
- name: Setup Node
|
|
17
|
+
uses: actions/setup-node@v4
|
|
18
|
+
with:
|
|
19
|
+
node-version: 22
|
|
20
|
+
registry-url: https://registry.npmjs.org
|
|
21
|
+
- name: Install NPM
|
|
22
|
+
run: npm install -g npm@latest
|
|
23
|
+
- name: Install dependencies
|
|
24
|
+
run: yarn install --frozen-lockfile
|
|
25
|
+
|
|
26
|
+
- name: Build
|
|
27
|
+
run: yarn tsc
|
|
28
|
+
|
|
29
|
+
- name: Deploy All
|
|
30
|
+
run: node deploy-all.js
|
package/deploy-all.js
CHANGED
|
@@ -1,98 +1,98 @@
|
|
|
1
1
|
const fs = require('fs');
|
|
2
|
-
const readline = require('readline');
|
|
3
2
|
const { execSync } = require('child_process');
|
|
4
3
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
output: process.stdout
|
|
8
|
-
});
|
|
9
|
-
|
|
10
|
-
function askQuestion(query) {
|
|
11
|
-
return new Promise(resolve => rl.question(query, resolve));
|
|
4
|
+
function run(cmd) {
|
|
5
|
+
execSync(cmd, { stdio: 'inherit' });
|
|
12
6
|
}
|
|
13
7
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
//
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
if (!/^[0-9]+$/.test(versionNumber)) {
|
|
31
|
-
console.error("❌ Invalid version number. Must be a single number.");
|
|
32
|
-
process.exit(1);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
// Function to update package.json version
|
|
36
|
-
function updateVersion(version) {
|
|
37
|
-
packageJson.version = version;
|
|
38
|
-
fs.writeFileSync('package.json', JSON.stringify(packageJson, null, 2) + '\n');
|
|
39
|
-
console.log(`✅ Updated version to ${version}`);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
// Publish 1.0.x
|
|
43
|
-
const prodVersion = `1.1.${versionNumber}`;
|
|
44
|
-
updateVersion(prodVersion);
|
|
45
|
-
console.log("🚀 Running TypeScript compiler...");
|
|
46
|
-
execSync('tsc', { stdio: 'inherit' });
|
|
47
|
-
console.log("📤 Publishing version " + prodVersion);
|
|
48
|
-
execSync('yarn publish --new-version '+prodVersion, { stdio: 'inherit' });
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
// Modify firebaseConfig.tsx
|
|
52
|
-
console.log("🛠 Modifying firebaseConfig.tsx for dev version...");
|
|
53
|
-
let firebaseConfig = fs.readFileSync('src/firebase/firebaseConfig.tsx', 'utf8');
|
|
54
|
-
firebaseConfig = firebaseConfig.replace(/\(credentialsProd\)/g, '(credentialsDev)'); // Modify as needed
|
|
55
|
-
fs.writeFileSync('src/firebase/firebaseConfig.tsx', firebaseConfig);
|
|
56
|
-
|
|
57
|
-
let hooks = fs.readFileSync('src/hooks.tsx', 'utf8');
|
|
58
|
-
hooks = hooks.replace(/XMPXCMUUOJ/g, 'A0ZB50I7VS'); // Modify as needed
|
|
59
|
-
fs.writeFileSync('src/hooks.tsx', hooks);
|
|
60
|
-
|
|
61
|
-
const devVersion = `1.400.${versionNumber}`;
|
|
62
|
-
updateVersion(devVersion);
|
|
63
|
-
console.log("🚀 Running TypeScript compiler for dev version...");
|
|
64
|
-
execSync('tsc', { stdio: 'inherit' });
|
|
65
|
-
console.log("📤 Publishing version " + devVersion);
|
|
66
|
-
execSync('yarn publish --new-version '+devVersion, { stdio: 'inherit' });
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
console.log("🛠 Modifying firebaseConfig.tsx for emulator...");
|
|
70
|
-
firebaseConfig = firebaseConfig.replace(/getFunctions}/g, 'connectFunctionsEmulator, getFunctions}'); // Modify as needed
|
|
71
|
-
firebaseConfig = firebaseConfig.replace(/\/\/ con/g, 'con'); // Modify as needed
|
|
72
|
-
fs.writeFileSync('src/firebase/firebaseConfig.tsx', firebaseConfig);
|
|
73
|
-
|
|
74
|
-
// Publish 1.300.x
|
|
75
|
-
const emulatorVersion = `1.300.${versionNumber}`;
|
|
76
|
-
updateVersion(emulatorVersion);
|
|
77
|
-
console.log("🚀 Running TypeScript compiler again...");
|
|
78
|
-
execSync('tsc', { stdio: 'inherit' });
|
|
79
|
-
console.log("📤 Publishing version " + emulatorVersion);
|
|
80
|
-
execSync('yarn publish --new-version '+emulatorVersion, { stdio: 'inherit' });
|
|
81
|
-
|
|
82
|
-
console.log("🛠 Resetting firebaseConfig.tsx...");
|
|
83
|
-
firebaseConfig = firebaseConfig.replace(/\(credentialsDev\)/g, '(credentialsProd)'); // Modify as needed
|
|
84
|
-
firebaseConfig = firebaseConfig.replace(/connectFunctionsEmulator, getFunctions}/g, 'getFunctions}'); // Modify as needed
|
|
85
|
-
firebaseConfig = firebaseConfig.replace(/connectFunctionsEmulator\(/g, '// connectFunctionsEmulator('); // Modify as needed
|
|
86
|
-
|
|
87
|
-
fs.writeFileSync('src/firebase/firebaseConfig.tsx', firebaseConfig);
|
|
88
|
-
|
|
89
|
-
hooks = hooks.replace(/A0ZB50I7VS/g, 'XMPXCMUUOJ'); // Modify as needed
|
|
90
|
-
fs.writeFileSync('src/hooks.tsx', hooks);
|
|
91
|
-
|
|
92
|
-
console.log("🎉 Deployment complete!");
|
|
8
|
+
console.log("📦 Starting automated deploy-all process...");
|
|
9
|
+
|
|
10
|
+
// ---- Read & bump version ----
|
|
11
|
+
const packageJsonPath = 'package.json';
|
|
12
|
+
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf8'));
|
|
13
|
+
|
|
14
|
+
const [major, minor, patch] = packageJson.version.split('.').map(Number);
|
|
15
|
+
const nextPatch = patch + 1;
|
|
16
|
+
|
|
17
|
+
console.log(`🔍 Current version: ${packageJson.version}`);
|
|
18
|
+
console.log(`🔢 Next patch version: ${nextPatch}`);
|
|
19
|
+
|
|
20
|
+
function updateVersion(version) {
|
|
21
|
+
packageJson.version = version;
|
|
22
|
+
fs.writeFileSync(packageJsonPath, JSON.stringify(packageJson, null, 2) + '\n');
|
|
23
|
+
console.log(`✅ Updated version to ${version}`);
|
|
93
24
|
}
|
|
94
25
|
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
26
|
+
// ---- Keep original file contents for reset ----
|
|
27
|
+
const firebaseConfigPath = 'src/firebase/firebaseConfig.tsx';
|
|
28
|
+
const hooksPath = 'src/hooks.tsx';
|
|
29
|
+
|
|
30
|
+
const originalFirebaseConfig = fs.readFileSync(firebaseConfigPath, 'utf8');
|
|
31
|
+
const originalHooks = fs.readFileSync(hooksPath, 'utf8');
|
|
32
|
+
|
|
33
|
+
// -------------------------------
|
|
34
|
+
// 1️⃣ PROD VERSION
|
|
35
|
+
// -------------------------------
|
|
36
|
+
const prodVersion = `1.1.${nextPatch}`;
|
|
37
|
+
updateVersion(prodVersion);
|
|
38
|
+
|
|
39
|
+
console.log("🚀 Building (prod)...");
|
|
40
|
+
run('yarn tsc');
|
|
41
|
+
|
|
42
|
+
console.log(`📤 Publishing ${prodVersion}`);
|
|
43
|
+
run('npm publish --tag prod');
|
|
44
|
+
|
|
45
|
+
// -------------------------------
|
|
46
|
+
// 2️⃣ DEV VERSION
|
|
47
|
+
// -------------------------------
|
|
48
|
+
console.log("🛠 Switching to DEV config...");
|
|
49
|
+
|
|
50
|
+
let firebaseConfig = originalFirebaseConfig.replace(
|
|
51
|
+
/\(credentialsProd\)/g,
|
|
52
|
+
'(credentialsDev)'
|
|
53
|
+
);
|
|
54
|
+
fs.writeFileSync(firebaseConfigPath, firebaseConfig);
|
|
55
|
+
|
|
56
|
+
let hooks = originalHooks.replace(
|
|
57
|
+
/XMPXCMUUOJ/g,
|
|
58
|
+
'A0ZB50I7VS'
|
|
59
|
+
);
|
|
60
|
+
fs.writeFileSync(hooksPath, hooks);
|
|
61
|
+
|
|
62
|
+
const devVersion = `1.400.${nextPatch}`;
|
|
63
|
+
updateVersion(devVersion);
|
|
64
|
+
|
|
65
|
+
console.log("🚀 Building (dev)...");
|
|
66
|
+
run('yarn tsc');
|
|
67
|
+
|
|
68
|
+
console.log(`📤 Publishing ${devVersion}`);
|
|
69
|
+
run('npm publish --tag dev');
|
|
70
|
+
|
|
71
|
+
// -------------------------------
|
|
72
|
+
// 3️⃣ EMULATOR VERSION
|
|
73
|
+
// -------------------------------
|
|
74
|
+
console.log("🛠 Switching to EMULATOR config...");
|
|
75
|
+
|
|
76
|
+
firebaseConfig = firebaseConfig
|
|
77
|
+
.replace(/getFunctions}/g, 'connectFunctionsEmulator, getFunctions}')
|
|
78
|
+
.replace(/\/\/ con/g, 'con');
|
|
79
|
+
|
|
80
|
+
fs.writeFileSync(firebaseConfigPath, firebaseConfig);
|
|
81
|
+
|
|
82
|
+
const emulatorVersion = `1.300.${nextPatch}`;
|
|
83
|
+
updateVersion(emulatorVersion);
|
|
84
|
+
|
|
85
|
+
console.log("🚀 Building (emulator)...");
|
|
86
|
+
run('yarn tsc');
|
|
87
|
+
|
|
88
|
+
console.log(`📤 Publishing ${emulatorVersion}`);
|
|
89
|
+
run('npm publish --tag emu');
|
|
90
|
+
|
|
91
|
+
// -------------------------------
|
|
92
|
+
// RESET FILES
|
|
93
|
+
// -------------------------------
|
|
94
|
+
console.log("🧹 Resetting source files...");
|
|
95
|
+
fs.writeFileSync(firebaseConfigPath, originalFirebaseConfig);
|
|
96
|
+
fs.writeFileSync(hooksPath, originalHooks);
|
|
97
|
+
|
|
98
|
+
console.log("🎉 Deployment complete!");
|
package/lib/config.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const store: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<
|
|
1
|
+
export declare const store: import("@reduxjs/toolkit/dist/configureStore").ToolkitStore<{
|
|
2
2
|
upcomingStudentPlacements: import("./features/placements/studentPlacements/upcomingStudentPlacementsSlice").UpcomingPlacementState;
|
|
3
3
|
completedStudentPlacements: import("./features/placements/types").PlacementState;
|
|
4
4
|
contacts: {
|
|
@@ -25,7 +25,7 @@ export declare const store: import("@reduxjs/toolkit/dist/configureStore").Toolk
|
|
|
25
25
|
[key: string]: import("@firebase/firestore").DocumentData;
|
|
26
26
|
};
|
|
27
27
|
};
|
|
28
|
-
} & import("redux-persist/es/persistReducer").PersistPartial, import("
|
|
28
|
+
} & import("redux-persist/es/persistReducer").PersistPartial, import("@reduxjs/toolkit").AnyAction, import("@reduxjs/toolkit").MiddlewareArray<[import("@reduxjs/toolkit").ThunkMiddleware<{
|
|
29
29
|
upcomingStudentPlacements: import("./features/placements/studentPlacements/upcomingStudentPlacementsSlice").UpcomingPlacementState;
|
|
30
30
|
completedStudentPlacements: import("./features/placements/types").PlacementState;
|
|
31
31
|
contacts: {
|
|
@@ -52,7 +52,7 @@ export declare const store: import("@reduxjs/toolkit/dist/configureStore").Toolk
|
|
|
52
52
|
[key: string]: import("@firebase/firestore").DocumentData;
|
|
53
53
|
};
|
|
54
54
|
};
|
|
55
|
-
} & import("redux-persist/es/persistReducer").PersistPartial, import("
|
|
55
|
+
} & import("redux-persist/es/persistReducer").PersistPartial, import("@reduxjs/toolkit").AnyAction>]>>;
|
|
56
56
|
export type RootStateType = ReturnType<typeof store.getState>;
|
|
57
57
|
export type RootState = {
|
|
58
58
|
upcomingStudentPlacements: RootStateType["upcomingStudentPlacements"];
|
|
@@ -13,7 +13,7 @@ export declare const fetchContacts: import("@reduxjs/toolkit").AsyncThunk<QueryS
|
|
|
13
13
|
formattedConstraints?: QueryConstraint | QueryConstraint[];
|
|
14
14
|
}, {
|
|
15
15
|
state?: unknown;
|
|
16
|
-
dispatch?: import("
|
|
16
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
17
17
|
extra?: unknown;
|
|
18
18
|
rejectValue?: unknown;
|
|
19
19
|
serializedErrorType?: unknown;
|
|
@@ -26,7 +26,7 @@ export declare const addContact: import("@reduxjs/toolkit").AsyncThunk<Contact,
|
|
|
26
26
|
userId: string;
|
|
27
27
|
}, {
|
|
28
28
|
state?: unknown;
|
|
29
|
-
dispatch?: import("
|
|
29
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
30
30
|
extra?: unknown;
|
|
31
31
|
rejectValue?: unknown;
|
|
32
32
|
serializedErrorType?: unknown;
|
|
@@ -42,7 +42,7 @@ export declare const updateContact: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
42
42
|
attributes: any;
|
|
43
43
|
}, {
|
|
44
44
|
state?: unknown;
|
|
45
|
-
dispatch?: import("
|
|
45
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
46
46
|
extra?: unknown;
|
|
47
47
|
rejectValue?: unknown;
|
|
48
48
|
serializedErrorType?: unknown;
|
|
@@ -54,7 +54,7 @@ export declare const deleteContact: import("@reduxjs/toolkit").AsyncThunk<string
|
|
|
54
54
|
contactId: string;
|
|
55
55
|
}, {
|
|
56
56
|
state?: unknown;
|
|
57
|
-
dispatch?: import("
|
|
57
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
58
58
|
extra?: unknown;
|
|
59
59
|
rejectValue?: unknown;
|
|
60
60
|
serializedErrorType?: unknown;
|
|
@@ -77,5 +77,5 @@ export declare const contactsSlice: import("@reduxjs/toolkit").Slice<InitialCont
|
|
|
77
77
|
}) => void;
|
|
78
78
|
}, "contacts">;
|
|
79
79
|
export declare const setContacts: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "contacts/setContacts">, setLastContact: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "contacts/setLastContact">, addContacts: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "contacts/addContacts">;
|
|
80
|
-
declare const _default: import("
|
|
80
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<InitialContactState>;
|
|
81
81
|
export default _default;
|
|
@@ -46,5 +46,5 @@ export declare const JobsSlice: import("@reduxjs/toolkit").Slice<InitialJobState
|
|
|
46
46
|
}) => void;
|
|
47
47
|
}, "jobs">;
|
|
48
48
|
export declare const setJobs: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "jobs/setJobs">, addJob: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "jobs/addJob">, setMarkRead: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "jobs/setMarkRead">, setJobStatus: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "jobs/setJobStatus">, updateJob: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "jobs/updateJob">;
|
|
49
|
-
declare const _default: import("
|
|
49
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<InitialJobState>;
|
|
50
50
|
export default _default;
|
|
@@ -13,7 +13,7 @@ export declare const fetchLogs: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
13
13
|
selectedDate: string;
|
|
14
14
|
}, {
|
|
15
15
|
state?: unknown;
|
|
16
|
-
dispatch?: import("
|
|
16
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
17
17
|
extra?: unknown;
|
|
18
18
|
rejectValue?: unknown;
|
|
19
19
|
serializedErrorType?: unknown;
|
|
@@ -34,7 +34,7 @@ export declare const editLog: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
34
34
|
placementId: string;
|
|
35
35
|
}, {
|
|
36
36
|
state?: unknown;
|
|
37
|
-
dispatch?: import("
|
|
37
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
38
38
|
extra?: unknown;
|
|
39
39
|
rejectValue?: unknown;
|
|
40
40
|
serializedErrorType?: unknown;
|
|
@@ -55,7 +55,7 @@ export declare const addLogFile: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
55
55
|
placementId: string;
|
|
56
56
|
}, {
|
|
57
57
|
state?: unknown;
|
|
58
|
-
dispatch?: import("
|
|
58
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
59
59
|
extra?: unknown;
|
|
60
60
|
rejectValue?: unknown;
|
|
61
61
|
serializedErrorType?: unknown;
|
|
@@ -80,7 +80,7 @@ export declare const deleteLogFile: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
80
80
|
placementId: string;
|
|
81
81
|
}, {
|
|
82
82
|
state?: unknown;
|
|
83
|
-
dispatch?: import("
|
|
83
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
84
84
|
extra?: unknown;
|
|
85
85
|
rejectValue?: unknown;
|
|
86
86
|
serializedErrorType?: unknown;
|
|
@@ -89,5 +89,5 @@ export declare const deleteLogFile: import("@reduxjs/toolkit").AsyncThunk<{
|
|
|
89
89
|
rejectedMeta?: unknown;
|
|
90
90
|
}>;
|
|
91
91
|
export declare const logsSlice: import("@reduxjs/toolkit").Slice<InitialLogsState, {}, "logs">;
|
|
92
|
-
declare const _default: import("
|
|
92
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<InitialLogsState>;
|
|
93
93
|
export default _default;
|
|
@@ -7,7 +7,7 @@ export declare const fetchActivePlacement: import("@reduxjs/toolkit").AsyncThunk
|
|
|
7
7
|
userId: string;
|
|
8
8
|
}, {
|
|
9
9
|
state?: unknown;
|
|
10
|
-
dispatch?: import("
|
|
10
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
11
11
|
extra?: unknown;
|
|
12
12
|
rejectValue?: unknown;
|
|
13
13
|
serializedErrorType?: unknown;
|
|
@@ -26,5 +26,5 @@ export declare const activePlacementSlice: import("@reduxjs/toolkit").Slice<Init
|
|
|
26
26
|
}) => void;
|
|
27
27
|
}, "activePlacement">;
|
|
28
28
|
export declare const setActivePlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "activePlacement/setActivePlacement">, editActivePlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "activePlacement/editActivePlacement">;
|
|
29
|
-
declare const _default: import("
|
|
29
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<InitialActivePlacementSlice>;
|
|
30
30
|
export default _default;
|
|
@@ -8,7 +8,7 @@ export declare const updateCompletedStudentPlacement: import("@reduxjs/toolkit")
|
|
|
8
8
|
attributes: Partial<StudentPlacementData>;
|
|
9
9
|
}, {
|
|
10
10
|
state?: unknown;
|
|
11
|
-
dispatch?: import("
|
|
11
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
12
12
|
extra?: unknown;
|
|
13
13
|
rejectValue?: unknown;
|
|
14
14
|
serializedErrorType?: unknown;
|
|
@@ -20,7 +20,7 @@ export declare const deleteCompletedStudentPlacement: import("@reduxjs/toolkit")
|
|
|
20
20
|
placementId: string;
|
|
21
21
|
}, {
|
|
22
22
|
state?: unknown;
|
|
23
|
-
dispatch?: import("
|
|
23
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
24
24
|
extra?: unknown;
|
|
25
25
|
rejectValue?: unknown;
|
|
26
26
|
serializedErrorType?: unknown;
|
|
@@ -55,5 +55,5 @@ export declare const completedStudentPlacementsSlice: import("@reduxjs/toolkit")
|
|
|
55
55
|
}) => void;
|
|
56
56
|
}, "completedStudentPlacements">;
|
|
57
57
|
export declare const addCompletedStudentPlacements: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/addCompletedStudentPlacements">, addCompletedStudentPlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/addCompletedStudentPlacement">, setCompletedStudentPlacements: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/setCompletedStudentPlacements">, setLastCompletedPlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/setLastCompletedPlacement">, setCompletedStatus: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/setCompletedStatus">, setCompletedIsDraft: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "completedStudentPlacements/setCompletedIsDraft">;
|
|
58
|
-
declare const _default: import("
|
|
58
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<PlacementState>;
|
|
59
59
|
export default _default;
|
|
@@ -11,7 +11,7 @@ export declare const updateUpcomingStudentPlacement: import("@reduxjs/toolkit").
|
|
|
11
11
|
attributes: Partial<StudentPlacementData>;
|
|
12
12
|
}, {
|
|
13
13
|
state?: unknown;
|
|
14
|
-
dispatch?: import("
|
|
14
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
15
15
|
extra?: unknown;
|
|
16
16
|
rejectValue?: unknown;
|
|
17
17
|
serializedErrorType?: unknown;
|
|
@@ -23,7 +23,7 @@ export declare const deleteUpcomingStudentPlacement: import("@reduxjs/toolkit").
|
|
|
23
23
|
placementId: string;
|
|
24
24
|
}, {
|
|
25
25
|
state?: unknown;
|
|
26
|
-
dispatch?: import("
|
|
26
|
+
dispatch?: import("@reduxjs/toolkit").Dispatch;
|
|
27
27
|
extra?: unknown;
|
|
28
28
|
rejectValue?: unknown;
|
|
29
29
|
serializedErrorType?: unknown;
|
|
@@ -62,5 +62,5 @@ export declare const upcomingStudentsPlacementsSlice: import("@reduxjs/toolkit")
|
|
|
62
62
|
}) => void;
|
|
63
63
|
}, "upcomingStudentsPlacements">;
|
|
64
64
|
export declare const addUpcomingStudentPlacements: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/addUpcomingStudentPlacements">, addUpcomingStudentPlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/addUpcomingStudentPlacement">, setUpcomingStudentPlacements: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/setUpcomingStudentPlacements">, setLastUpcomingPlacement: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/setLastUpcomingPlacement">, setUpcoming: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/setUpcoming">, setUpcomingStatus: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/setUpcomingStatus">, setUpcomingIsDraft: import("@reduxjs/toolkit").ActionCreatorWithPayload<any, "upcomingStudentsPlacements/setUpcomingIsDraft">;
|
|
65
|
-
declare const _default: import("
|
|
65
|
+
declare const _default: import("@reduxjs/toolkit").Reducer<UpcomingPlacementState>;
|
|
66
66
|
export default _default;
|
|
@@ -43,5 +43,5 @@ exports.auth = (0, auth_1.getAuth)(firebaseConfig);
|
|
|
43
43
|
exports.db = (0, firestore_1.getFirestore)(firebaseConfig);
|
|
44
44
|
exports.functions = (0, functions_1.getFunctions)(firebaseConfig, "europe-west2");
|
|
45
45
|
exports.storage = (0, storage_1.getStorage)(firebaseConfig);
|
|
46
|
-
|
|
46
|
+
(0, functions_1.connectFunctionsEmulator)(exports.functions, "localhost", 5001);
|
|
47
47
|
//# sourceMappingURL=firebaseConfig.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"firebaseConfig.js","sourceRoot":"","sources":["../../src/firebase/firebaseConfig.tsx"],"names":[],"mappings":";;;;;;AAAA,4CAA4C;AAC5C,8FAAqE;AACrE,sCAA4D;AAC5D,wCAAsD;AACtD,kDAAqE;AACrE,
|
|
1
|
+
{"version":3,"file":"firebaseConfig.js","sourceRoot":"","sources":["../../src/firebase/firebaseConfig.tsx"],"names":[],"mappings":";;;;;;AAAA,4CAA4C;AAC5C,8FAAqE;AACrE,sCAA4D;AAC5D,wCAAsD;AACtD,kDAAqE;AACrE,kDAA0E;AAC1E,8CAA4C;AAC5C,+CAAwD;AAE3C,QAAA,cAAc,GAAG;IAC1B,MAAM,EAAE,yCAAyC;IACjD,UAAU,EAAE,gCAAgC;IAC5C,SAAS,EAAE,gBAAgB;IAC3B,aAAa,EAAE,4BAA4B;IAC3C,iBAAiB,EAAE,cAAc;IACjC,KAAK,EAAE,2CAA2C;IAClD,aAAa,EAAE,cAAc;CAChC,CAAC;AAEW,QAAA,eAAe,GAAG;IAC3B,MAAM,EAAE,yCAAyC;IACjD,UAAU,EAAE,kCAAkC;IAC9C,SAAS,EAAE,kBAAkB;IAC7B,aAAa,EAAE,8BAA8B;IAC7C,iBAAiB,EAAE,cAAc;IACjC,KAAK,EAAE,2CAA2C;IAClD,aAAa,EAAE,cAAc;CAChC,CAAC;AAEF,OAAO,CAAC,GAAG,CAAC,uBAAe,EAAE,sBAAc,CAAC,CAAA;AAE5C,MAAM,cAAc,GAAG,CAAC,IAAA,aAAO,GAAE,CAAC,MAAM,CAAC,CAAC,CAAC,IAAA,mBAAa,EAAC,sBAAc,CAAC,CAAC,CAAC,CAAC,IAAA,YAAM,GAAE,CAAC;AAEpF,IAAA,qBAAc,EAAC,cAAc,EAAE;IAC3B,WAAW,EAAE,IAAA,uCAAyB,EAAC,uBAAY,CAAC;CACvD,CAAC,CAAC;AAEH,IAAA,+BAAmB,EAAC,cAAc,EAAE;IAChC,yBAAyB,EAAE,IAAI;IAC/B,iCAAiC,EAAE,IAAI;CAC1C,CAAC,CAAC;AAEU,QAAA,IAAI,GAAG,IAAA,cAAO,EAAC,cAAc,CAAC,CAAC;AAC/B,QAAA,EAAE,GAAG,IAAA,wBAAY,EAAC,cAAc,CAAC,CAAC;AAClC,QAAA,SAAS,GAAG,IAAA,wBAAY,EAAC,cAAc,EAAE,cAAc,CAAC,CAAC;AACzD,QAAA,OAAO,GAAG,IAAA,oBAAU,EAAC,cAAc,CAAC,CAAC;AAElD,IAAA,oCAAwB,EAAC,iBAAS,EAAE,WAAW,EAAE,IAAI,CAAC,CAAC"}
|
package/lib/hooks.d.ts
CHANGED
|
@@ -396,7 +396,7 @@ export declare function useWorkflowEditor({ user, initialData, onSubmit, cohortI
|
|
|
396
396
|
tutorialActive: boolean;
|
|
397
397
|
onDeleteArrow: (data: ArrowObject) => void;
|
|
398
398
|
workflowNodes: WorkflowStage[];
|
|
399
|
-
containerRef: import("react").RefObject<HTMLFormElement>;
|
|
399
|
+
containerRef: import("react").RefObject<HTMLFormElement | null>;
|
|
400
400
|
setError: import("react").Dispatch<import("react").SetStateAction<string | undefined>>;
|
|
401
401
|
setArrows: import("react").Dispatch<import("react").SetStateAction<ArrowObject[]>>;
|
|
402
402
|
setWorkflowNodes: import("react").Dispatch<import("react").SetStateAction<WorkflowStage[] | ApplicantStage[]>>;
|
|
@@ -444,7 +444,7 @@ export declare function useApplicantWorkflowEditor({ user, initialData, onSubmit
|
|
|
444
444
|
tutorialActive: boolean;
|
|
445
445
|
onDeleteArrow: (data: ArrowObject) => void;
|
|
446
446
|
workflowNodes: ApplicantStage[];
|
|
447
|
-
containerRef: import("react").RefObject<HTMLFormElement>;
|
|
447
|
+
containerRef: import("react").RefObject<HTMLFormElement | null>;
|
|
448
448
|
setError: import("react").Dispatch<import("react").SetStateAction<string | undefined>>;
|
|
449
449
|
setArrows: import("react").Dispatch<import("react").SetStateAction<ArrowObject[]>>;
|
|
450
450
|
setWorkflowNodes: import("react").Dispatch<import("react").SetStateAction<ApplicantStage[]>>;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import * as React from "react";
|
|
2
|
+
export default function GatsbyBenchmarks(): React.JSX.Element;
|
package/lib/reduxHooks.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import { RootState } from "./config";
|
|
|
4
4
|
import { Job } from "./features/jobs/jobsSlice";
|
|
5
5
|
import { Address, Application, CohortData, Contact, EmailTemplate, FileItem, InstituteData, PlacementListing, ProviderData, StudentPlacementData, UserData, UserGroupData } from "./typeDefinitions";
|
|
6
6
|
export declare const useAppSelector: TypedUseSelectorHook<RootState>;
|
|
7
|
-
export declare const useAppDispatch: () => import("
|
|
7
|
+
export declare const useAppDispatch: () => import("@reduxjs/toolkit").ThunkDispatch<{
|
|
8
8
|
upcomingStudentPlacements: import("./features/placements/studentPlacements/upcomingStudentPlacementsSlice").UpcomingPlacementState;
|
|
9
9
|
completedStudentPlacements: import("./features/placements/types").PlacementState;
|
|
10
10
|
contacts: {
|
|
@@ -31,7 +31,7 @@ export declare const useAppDispatch: () => import("redux-thunk").ThunkDispatch<i
|
|
|
31
31
|
[key: string]: DocumentData;
|
|
32
32
|
};
|
|
33
33
|
};
|
|
34
|
-
} & import("redux-persist/es/persistReducer").PersistPartial, undefined, import("
|
|
34
|
+
} & import("redux-persist/es/persistReducer").PersistPartial, undefined, import("@reduxjs/toolkit").AnyAction> & import("@reduxjs/toolkit").Dispatch<import("@reduxjs/toolkit").AnyAction>;
|
|
35
35
|
export declare function useStudent({ user }: {
|
|
36
36
|
user: UserData;
|
|
37
37
|
}): {
|
package/lib/typeDefinitions.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { DocumentData, DocumentReference, Timestamp, WhereFilterOp } from "firebase/firestore";
|
|
2
2
|
import { Descendant } from "slate";
|
|
3
|
-
import { emailTemplates } from "./constants";
|
|
3
|
+
import { emailTemplates, skillLabelColours } from "./constants";
|
|
4
4
|
import { FilterObject } from "./hooks";
|
|
5
5
|
export type Products = "institutes" | "providers" | "students" | "admin";
|
|
6
6
|
export type StudentPlacementData = {
|
|
@@ -2005,7 +2005,7 @@ export type EmailInteraction = {
|
|
|
2005
2005
|
export type SkillLabel = {
|
|
2006
2006
|
label: string;
|
|
2007
2007
|
description: string;
|
|
2008
|
-
category:
|
|
2008
|
+
category: keyof typeof skillLabelColours;
|
|
2009
2009
|
public: boolean;
|
|
2010
2010
|
};
|
|
2011
2011
|
export {};
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"private": false,
|
|
3
3
|
"name": "placementt-core",
|
|
4
4
|
"author": "Placementt",
|
|
5
|
-
"version": "1.400.
|
|
5
|
+
"version": "1.400.461",
|
|
6
6
|
"main": "lib/index.js",
|
|
7
7
|
"types": "lib/index.d.ts",
|
|
8
8
|
"scripts": {
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"@reduxjs/toolkit": "^1.9.7",
|
|
21
21
|
"@types/jest": "29.5.0",
|
|
22
22
|
"@types/ngeohash": "0.6.4",
|
|
23
|
-
"@types/scheduler": "0.
|
|
23
|
+
"@types/scheduler": "0.26.0",
|
|
24
24
|
"algoliasearch": "^4.23.3",
|
|
25
25
|
"expo": "^52.0.7",
|
|
26
26
|
"firebase": "9.16.0",
|
|
@@ -31,9 +31,9 @@
|
|
|
31
31
|
"path": "^0.12.7",
|
|
32
32
|
"react": "18.2.0",
|
|
33
33
|
"react-dom": "18.2.0",
|
|
34
|
-
"react-redux": "
|
|
34
|
+
"react-redux": "9.2.0",
|
|
35
|
+
"redux": "^5.0.1",
|
|
35
36
|
"redux-persist": "^6.0.0",
|
|
36
|
-
"scheduler": "0.23.0",
|
|
37
37
|
"slate": "^0.84.0",
|
|
38
38
|
"slate-history": "^0.66.0",
|
|
39
39
|
"slate-react": "^0.83.2",
|
|
@@ -45,9 +45,27 @@
|
|
|
45
45
|
"rimraf": "^3.0.2"
|
|
46
46
|
},
|
|
47
47
|
"resolutions": {
|
|
48
|
-
"@types/react": "
|
|
48
|
+
"@types/react": "19.0.0"
|
|
49
49
|
},
|
|
50
50
|
"engines": {
|
|
51
51
|
"node": "22"
|
|
52
|
+
},
|
|
53
|
+
"publishConfig": {
|
|
54
|
+
"access": "public"
|
|
55
|
+
},
|
|
56
|
+
"compilerOptions": {
|
|
57
|
+
"target": "ES2022",
|
|
58
|
+
"lib": [
|
|
59
|
+
"ES2022",
|
|
60
|
+
"DOM"
|
|
61
|
+
],
|
|
62
|
+
"moduleResolution": "bundler",
|
|
63
|
+
"types": [
|
|
64
|
+
"node",
|
|
65
|
+
"react",
|
|
66
|
+
"react-dom"
|
|
67
|
+
],
|
|
68
|
+
"jsx": "react-jsx",
|
|
69
|
+
"skipLibCheck": false
|
|
52
70
|
}
|
|
53
71
|
}
|
|
@@ -3,7 +3,7 @@ import AsyncStorage from "@react-native-async-storage/async-storage";
|
|
|
3
3
|
import {getApp, getApps, initializeApp} from "firebase/app";
|
|
4
4
|
import {getAuth, initializeAuth} from "firebase/auth";
|
|
5
5
|
import {getFirestore, initializeFirestore} from "firebase/firestore";
|
|
6
|
-
import {getFunctions} from "firebase/functions";
|
|
6
|
+
import {connectFunctionsEmulator, getFunctions} from "firebase/functions";
|
|
7
7
|
import {getStorage} from "firebase/storage";
|
|
8
8
|
import {getReactNativePersistence} from "./persistence";
|
|
9
9
|
|
|
@@ -45,6 +45,6 @@ export const db = getFirestore(firebaseConfig);
|
|
|
45
45
|
export const functions = getFunctions(firebaseConfig, "europe-west2");
|
|
46
46
|
export const storage = getStorage(firebaseConfig);
|
|
47
47
|
|
|
48
|
-
|
|
48
|
+
connectFunctionsEmulator(functions, "localhost", 5001);
|
|
49
49
|
|
|
50
50
|
|
package/src/typeDefinitions.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {DocumentData, DocumentReference, Timestamp, WhereFilterOp} from "firebase/firestore";
|
|
2
2
|
import {Descendant} from "slate";
|
|
3
|
-
import {emailTemplates} from "./constants";
|
|
3
|
+
import {emailTemplates, skillLabelColours} from "./constants";
|
|
4
4
|
import {FilterObject} from "./hooks";
|
|
5
5
|
|
|
6
6
|
export type Products = "institutes"|"providers"|"students"|"admin";
|
|
@@ -1932,6 +1932,6 @@ export type EmailInteraction = {
|
|
|
1932
1932
|
export type SkillLabel = {
|
|
1933
1933
|
label: string,
|
|
1934
1934
|
description: string,
|
|
1935
|
-
category:
|
|
1935
|
+
category: keyof typeof skillLabelColours,
|
|
1936
1936
|
public: boolean,
|
|
1937
1937
|
}
|