feat: initial project prototype (#2)
Node.js CI / Lint and Test (push) Has been cancelled

### Explanation

_No response_

### Issue

_No response_

### Attestations

- [x] I have read and agree to the [Code of Conduct](https://docs.nhcarrigan.com/community/coc/)
- [x] I have read and agree to the [Community Guidelines](https://docs.nhcarrigan.com/community/guide/).
- [x] My contribution complies with the [Contributor Covenant](https://docs.nhcarrigan.com/dev/covenant/).

### Dependencies

- [x] I have pinned the dependencies to a specific patch version.

### Style

- [x] I have run the linter and resolved any errors.
- [x] My pull request uses an appropriate title, matching the conventional commit standards.
- [x] My scope of feat/fix/chore/etc. correctly matches the nature of changes in my pull request.

### Tests

- [ ] My contribution adds new code, and I have added tests to cover it.
- [ ] My contribution modifies existing code, and I have updated the tests to reflect these changes.
- [x] All new and existing tests pass locally with my changes.
- [x] Code coverage remains at or above the configured threshold.

### Documentation

_No response_

### Versioning

Major - My pull request introduces a breaking change.

Reviewed-on: nhcarrigan/forms#2
Co-authored-by: Naomi Carrigan <commits@nhcarrigan.com>
Co-committed-by: Naomi Carrigan <commits@nhcarrigan.com>
This commit was merged in pull request #2.
This commit is contained in:
2025-02-17 14:03:32 -08:00
committed by Naomi Carrigan
parent b43bfd612b
commit e8f5078aa3
120 changed files with 15657 additions and 0 deletions
+5
View File
@@ -0,0 +1,5 @@
import NaomisConfig from "@nhcarrigan/eslint-config";
export default [
...NaomisConfig,
]
+23
View File
@@ -0,0 +1,23 @@
{
"name": "@repo/types",
"version": "0.0.0",
"private": true,
"description": "Type-definitions shared between client and server.",
"type": "module",
"main": "prod/index.js",
"scripts": {
"build": "tsc",
"lint": "eslint src --max-warnings 0",
"test": "echo \"Error: no test specified\" && exit 0"
},
"keywords": [],
"author": "",
"license": "See License in LICENSE.md",
"devDependencies": {
"@nhcarrigan/eslint-config": "5.2.0",
"@nhcarrigan/typescript-config": "4.0.0",
"@types/node": "22.13.4",
"eslint": "9.20.1",
"typescript": "5.7.3"
}
}
+25
View File
@@ -0,0 +1,25 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
import type { Platform } from "../unions/platform.js";
import type { Sanction } from "../unions/sanction.js";
export interface Appeal {
consent: boolean;
email: string;
firstName: string;
lastName: string;
understandBinding: boolean;
sanctionType: Sanction;
caseNumber: number;
sanctionPlatform: Platform;
platformUsername: string;
sanctionReason: string;
sanctionFair: string;
behaviourViolation: string;
appealReason: string;
behaviourImprove: string;
}
+14
View File
@@ -0,0 +1,14 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface Commission {
consent: boolean;
email: string;
firstName: string;
lastName: string;
companyName: string;
request: string;
}
+14
View File
@@ -0,0 +1,14 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface Contact {
consent: boolean;
email: string;
firstName: string;
lastName: string;
companyName: string;
request: string;
}
+21
View File
@@ -0,0 +1,21 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface Event {
consent: boolean;
email: string;
firstName: string;
lastName: string;
companyName: string;
eventDescription: string;
eventTopic: string;
eventLocation: string;
eventDate: string;
eventBudget: string;
travelCovered: boolean;
lodgingCovered: boolean;
foodCovered: boolean;
}
+18
View File
@@ -0,0 +1,18 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
import type { SessionLength } from "../unions/session.js";
export interface Meeting {
consent: boolean;
email: string;
firstName: string;
lastName: string;
companyName: string;
sessionLength: SessionLength;
sessionGoal: string;
paymentUnderstanding: boolean;
}
+16
View File
@@ -0,0 +1,16 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface Mentorship {
consent: boolean;
email: string;
firstName: string;
lastName: string;
companyName: string;
mentorshipGoal: string;
currentFocus: string;
paymentUnderstanding: boolean;
}
+24
View File
@@ -0,0 +1,24 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
import type { Platform } from "../unions/platform.js";
export interface Staff {
consent: boolean;
email: string;
firstName: string;
lastName: string;
understandVolunteer: boolean;
platform: Platform;
platformUsername: string;
whyJoin: string;
currentBehaviour: string;
priorExperience: string;
internalConflict: string;
handlingTrauma: string;
difficultSituation: string;
leadershipSituation: string;
}
+31
View File
@@ -0,0 +1,31 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
import type { Appeal } from "./forms/appeal.js";
import type { Commission } from "./forms/commission.js";
import type { Contact } from "./forms/contact.js";
import type { Event } from "./forms/event.js";
import type { Meeting } from "./forms/meeting.js";
import type { Mentorship } from "./forms/mentorship.js";
import type { Staff } from "./forms/staff.js";
import type { ReviewRequest } from "./requests/review.js";
import type { DataResponse } from "./responses/data.js";
import type { ErrorResponse } from "./responses/error.js";
import type { SuccessResponse } from "./responses/success.js";
export type {
Appeal,
Commission,
Contact,
Event,
Meeting,
Mentorship,
Staff,
ReviewRequest,
DataResponse,
ErrorResponse,
SuccessResponse,
};
+8
View File
@@ -0,0 +1,8 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface ReviewRequest {
submissionId: string;
}
+8
View File
@@ -0,0 +1,8 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface DataResponse {
data: unknown;
}
+8
View File
@@ -0,0 +1,8 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface ErrorResponse {
error: string;
}
+8
View File
@@ -0,0 +1,8 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export interface SuccessResponse {
success: true;
}
+7
View File
@@ -0,0 +1,7 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export type Platform = "Forum" | "IRC" | "Matrix" | "Gitea" | "Fediverse";
+7
View File
@@ -0,0 +1,7 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export type Sanction = "reminder" | "warning" | "temporary" | "permanent";
+7
View File
@@ -0,0 +1,7 @@
/**
* @copyright nhcarrigan
* @license Naomi's Public License
* @author Naomi Carrigan
*/
export type SessionLength = 15 | 30 | 60;
+8
View File
@@ -0,0 +1,8 @@
{
"extends": "@nhcarrigan/typescript-config",
"compilerOptions": {
"rootDir": "./src",
"outDir": "./prod",
"declaration": true,
},
}