@striae-org/striae 3.0.4
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/.env.example +100 -0
- package/LICENSE +190 -0
- package/NOTICE +18 -0
- package/README.md +133 -0
- package/app/components/actions/case-export/core-export.ts +328 -0
- package/app/components/actions/case-export/data-processing.ts +167 -0
- package/app/components/actions/case-export/download-handlers.ts +900 -0
- package/app/components/actions/case-export/index.ts +41 -0
- package/app/components/actions/case-export/metadata-helpers.ts +107 -0
- package/app/components/actions/case-export/types-constants.ts +56 -0
- package/app/components/actions/case-export/validation-utils.ts +25 -0
- package/app/components/actions/case-export.ts +4 -0
- package/app/components/actions/case-import/annotation-import.ts +35 -0
- package/app/components/actions/case-import/confirmation-import.ts +363 -0
- package/app/components/actions/case-import/image-operations.ts +61 -0
- package/app/components/actions/case-import/index.ts +39 -0
- package/app/components/actions/case-import/orchestrator.ts +420 -0
- package/app/components/actions/case-import/storage-operations.ts +270 -0
- package/app/components/actions/case-import/validation.ts +189 -0
- package/app/components/actions/case-import/zip-processing.ts +413 -0
- package/app/components/actions/case-manage.ts +524 -0
- package/app/components/actions/case-review.ts +4 -0
- package/app/components/actions/confirm-export.ts +351 -0
- package/app/components/actions/generate-pdf.ts +210 -0
- package/app/components/actions/image-manage.ts +385 -0
- package/app/components/actions/notes-manage.ts +33 -0
- package/app/components/actions/signout.module.css +15 -0
- package/app/components/actions/signout.tsx +50 -0
- package/app/components/audit/user-audit-viewer.tsx +975 -0
- package/app/components/audit/user-audit.module.css +568 -0
- package/app/components/auth/auth-provider.tsx +78 -0
- package/app/components/auth/mfa-enrollment.module.css +268 -0
- package/app/components/auth/mfa-enrollment.tsx +398 -0
- package/app/components/auth/mfa-verification.module.css +251 -0
- package/app/components/auth/mfa-verification.tsx +295 -0
- package/app/components/button/button.module.css +63 -0
- package/app/components/button/button.tsx +46 -0
- package/app/components/canvas/box-annotations/box-annotations.module.css +170 -0
- package/app/components/canvas/box-annotations/box-annotations.tsx +634 -0
- package/app/components/canvas/canvas.module.css +314 -0
- package/app/components/canvas/canvas.tsx +449 -0
- package/app/components/canvas/confirmation/confirmation.module.css +187 -0
- package/app/components/canvas/confirmation/confirmation.tsx +214 -0
- package/app/components/colors/colors.module.css +59 -0
- package/app/components/colors/colors.tsx +68 -0
- package/app/components/form/base-form.tsx +21 -0
- package/app/components/form/form-button.tsx +28 -0
- package/app/components/form/form-field.tsx +53 -0
- package/app/components/form/form-message.tsx +17 -0
- package/app/components/form/form-toggle.tsx +23 -0
- package/app/components/form/form.module.css +427 -0
- package/app/components/form/index.ts +6 -0
- package/app/components/icon/icon.module.css +3 -0
- package/app/components/icon/icon.tsx +27 -0
- package/app/components/icon/icons.svg +102 -0
- package/app/components/icon/manifest.json +110 -0
- package/app/components/sidebar/case-export/case-export.module.css +386 -0
- package/app/components/sidebar/case-export/case-export.tsx +317 -0
- package/app/components/sidebar/case-import/case-import.module.css +626 -0
- package/app/components/sidebar/case-import/case-import.tsx +404 -0
- package/app/components/sidebar/case-import/components/CasePreviewSection.tsx +72 -0
- package/app/components/sidebar/case-import/components/ConfirmationDialog.tsx +72 -0
- package/app/components/sidebar/case-import/components/ConfirmationPreviewSection.tsx +71 -0
- package/app/components/sidebar/case-import/components/ExistingCaseSection.tsx +40 -0
- package/app/components/sidebar/case-import/components/FileSelector.tsx +161 -0
- package/app/components/sidebar/case-import/components/ProgressSection.tsx +46 -0
- package/app/components/sidebar/case-import/hooks/useFilePreview.ts +101 -0
- package/app/components/sidebar/case-import/hooks/useImportExecution.ts +152 -0
- package/app/components/sidebar/case-import/hooks/useImportState.ts +88 -0
- package/app/components/sidebar/case-import/index.ts +18 -0
- package/app/components/sidebar/case-import/utils/file-validation.ts +43 -0
- package/app/components/sidebar/cases/case-sidebar.tsx +827 -0
- package/app/components/sidebar/cases/cases-modal.module.css +166 -0
- package/app/components/sidebar/cases/cases-modal.tsx +201 -0
- package/app/components/sidebar/cases/cases.module.css +713 -0
- package/app/components/sidebar/files/files-modal.module.css +209 -0
- package/app/components/sidebar/files/files-modal.tsx +239 -0
- package/app/components/sidebar/hash/hash-utility.module.css +366 -0
- package/app/components/sidebar/hash/hash-utility.tsx +982 -0
- package/app/components/sidebar/notes/notes-modal.tsx +51 -0
- package/app/components/sidebar/notes/notes-sidebar.tsx +491 -0
- package/app/components/sidebar/notes/notes.module.css +360 -0
- package/app/components/sidebar/sidebar-container.tsx +149 -0
- package/app/components/sidebar/sidebar.module.css +321 -0
- package/app/components/sidebar/sidebar.tsx +215 -0
- package/app/components/sidebar/upload/image-upload-zone.module.css +123 -0
- package/app/components/sidebar/upload/image-upload-zone.tsx +330 -0
- package/app/components/theme-provider/theme-provider.tsx +131 -0
- package/app/components/theme-provider/theme.ts +155 -0
- package/app/components/toast/toast.module.css +137 -0
- package/app/components/toast/toast.tsx +56 -0
- package/app/components/toolbar/toolbar-color-selector.module.css +171 -0
- package/app/components/toolbar/toolbar-color-selector.tsx +129 -0
- package/app/components/toolbar/toolbar.module.css +42 -0
- package/app/components/toolbar/toolbar.tsx +167 -0
- package/app/components/user/delete-account.module.css +274 -0
- package/app/components/user/delete-account.tsx +471 -0
- package/app/components/user/inactivity-warning.module.css +145 -0
- package/app/components/user/inactivity-warning.tsx +84 -0
- package/app/components/user/manage-profile.module.css +190 -0
- package/app/components/user/manage-profile.tsx +253 -0
- package/app/components/user/mfa-phone-update.tsx +739 -0
- package/app/config-example/admin-service.json +13 -0
- package/app/config-example/config.json +17 -0
- package/app/config-example/firebase.ts +21 -0
- package/app/config-example/inactivity.ts +13 -0
- package/app/config-example/meta-config.json +6 -0
- package/app/contexts/auth.context.ts +12 -0
- package/app/entry.client.tsx +12 -0
- package/app/entry.server.tsx +44 -0
- package/app/hooks/useInactivityTimeout.ts +110 -0
- package/app/root.tsx +170 -0
- package/app/routes/_index.tsx +16 -0
- package/app/routes/auth/emailActionHandler.module.css +232 -0
- package/app/routes/auth/emailActionHandler.tsx +405 -0
- package/app/routes/auth/emailVerification.tsx +120 -0
- package/app/routes/auth/login.module.css +523 -0
- package/app/routes/auth/login.tsx +654 -0
- package/app/routes/auth/passwordReset.module.css +274 -0
- package/app/routes/auth/passwordReset.tsx +154 -0
- package/app/routes/auth/route.ts +16 -0
- package/app/routes/mobile-prevented/mobilePrevented.module.css +47 -0
- package/app/routes/mobile-prevented/mobilePrevented.tsx +26 -0
- package/app/routes/mobile-prevented/route.ts +14 -0
- package/app/routes/striae/striae.module.css +30 -0
- package/app/routes/striae/striae.tsx +417 -0
- package/app/services/audit-export.service.ts +755 -0
- package/app/services/audit.service.ts +1454 -0
- package/app/services/firebase-errors.ts +106 -0
- package/app/services/firebase.ts +15 -0
- package/app/styles/legal-pages.module.css +113 -0
- package/app/styles/root.module.css +146 -0
- package/app/tailwind.css +225 -0
- package/app/types/annotations.ts +45 -0
- package/app/types/audit.ts +301 -0
- package/app/types/case.ts +90 -0
- package/app/types/export.ts +8 -0
- package/app/types/file.ts +30 -0
- package/app/types/import.ts +107 -0
- package/app/types/index.ts +24 -0
- package/app/types/user.ts +38 -0
- package/app/utils/SHA256.ts +461 -0
- package/app/utils/annotation-timestamp.ts +25 -0
- package/app/utils/audit-export-signature.ts +117 -0
- package/app/utils/auth-action-settings.ts +48 -0
- package/app/utils/auth.ts +34 -0
- package/app/utils/batch-operations.ts +135 -0
- package/app/utils/confirmation-signature.ts +193 -0
- package/app/utils/data-operations.ts +871 -0
- package/app/utils/device-detection.ts +5 -0
- package/app/utils/html-sanitizer.ts +80 -0
- package/app/utils/id-generator.ts +36 -0
- package/app/utils/meta.ts +48 -0
- package/app/utils/mfa-phone.ts +97 -0
- package/app/utils/mfa.ts +79 -0
- package/app/utils/password-policy.ts +28 -0
- package/app/utils/permissions.ts +562 -0
- package/app/utils/signature-utils.ts +160 -0
- package/app/utils/style.ts +83 -0
- package/app/utils/version.ts +5 -0
- package/firebase.json +11 -0
- package/functions/[[path]].ts +10 -0
- package/package.json +138 -0
- package/postcss.config.js +6 -0
- package/public/.well-known/publickey.info@striae.org.asc +17 -0
- package/public/.well-known/security.txt +7 -0
- package/public/_headers +28 -0
- package/public/_routes.json +13 -0
- package/public/assets/striae.jpg +0 -0
- package/public/clear.jpg +0 -0
- package/public/favicon.ico +0 -0
- package/public/favicon.svg +9 -0
- package/public/icon-256.png +0 -0
- package/public/icon-512.png +0 -0
- package/public/logo-dark.png +0 -0
- package/public/manifest.json +25 -0
- package/public/oin-badge.png +0 -0
- package/public/shortcut.png +0 -0
- package/public/social-image.png +0 -0
- package/public/striae-ascii.txt +10 -0
- package/scripts/deploy-all.sh +100 -0
- package/scripts/deploy-config.sh +940 -0
- package/scripts/deploy-pages.sh +34 -0
- package/scripts/deploy-worker-secrets.sh +215 -0
- package/scripts/dev.cjs +23 -0
- package/scripts/install-workers.sh +88 -0
- package/scripts/run-eslint.cjs +35 -0
- package/scripts/update-compatibility-dates.cjs +124 -0
- package/scripts/update-markdown-versions.cjs +43 -0
- package/tailwind.config.ts +22 -0
- package/tsconfig.json +33 -0
- package/vite.config.ts +35 -0
- package/worker-configuration.d.ts +7490 -0
- package/workers/audit-worker/package.json +17 -0
- package/workers/audit-worker/src/audit-worker.example.ts +195 -0
- package/workers/audit-worker/worker-configuration.d.ts +7448 -0
- package/workers/audit-worker/wrangler.jsonc.example +29 -0
- package/workers/data-worker/package.json +17 -0
- package/workers/data-worker/src/data-worker.example.ts +267 -0
- package/workers/data-worker/src/signature-utils.ts +79 -0
- package/workers/data-worker/src/signing-payload-utils.ts +290 -0
- package/workers/data-worker/worker-configuration.d.ts +7448 -0
- package/workers/data-worker/wrangler.jsonc.example +30 -0
- package/workers/image-worker/package.json +17 -0
- package/workers/image-worker/src/image-worker.example.ts +180 -0
- package/workers/image-worker/worker-configuration.d.ts +7447 -0
- package/workers/image-worker/wrangler.jsonc.example +22 -0
- package/workers/keys-worker/package.json +17 -0
- package/workers/keys-worker/src/keys.example.ts +66 -0
- package/workers/keys-worker/src/keys.ts +66 -0
- package/workers/keys-worker/worker-configuration.d.ts +7447 -0
- package/workers/keys-worker/wrangler.jsonc.example +22 -0
- package/workers/pdf-worker/package.json +17 -0
- package/workers/pdf-worker/src/format-striae.ts +534 -0
- package/workers/pdf-worker/src/pdf-worker.example.ts +119 -0
- package/workers/pdf-worker/src/report-types.ts +69 -0
- package/workers/pdf-worker/worker-configuration.d.ts +7448 -0
- package/workers/pdf-worker/wrangler.jsonc.example +26 -0
- package/workers/user-worker/package.json +17 -0
- package/workers/user-worker/src/user-worker.example.ts +636 -0
- package/workers/user-worker/worker-configuration.d.ts +7448 -0
- package/workers/user-worker/wrangler.jsonc.example +29 -0
- package/wrangler.toml.example +8 -0
package/.env.example
ADDED
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
# ================================
|
|
2
|
+
# STRIAE ENVIRONMENT VARIABLES EXAMPLE
|
|
3
|
+
# ================================
|
|
4
|
+
# Copy this file to .env and fill in your actual values
|
|
5
|
+
|
|
6
|
+
# ================================
|
|
7
|
+
# CLOUDFLARE CORE CONFIGURATION
|
|
8
|
+
# ================================
|
|
9
|
+
ACCOUNT_ID=your_cloudflare_account_id_here
|
|
10
|
+
|
|
11
|
+
# ================================
|
|
12
|
+
# SHARED AUTHENTICATION & STORAGE
|
|
13
|
+
# ================================
|
|
14
|
+
USER_DB_AUTH=your_custom_user_db_auth_token_here
|
|
15
|
+
R2_KEY_SECRET=your_custom_r2_secret_here
|
|
16
|
+
IMAGES_API_TOKEN=your_cloudflare_images_api_token_here
|
|
17
|
+
|
|
18
|
+
# ================================
|
|
19
|
+
# FIREBASE AUTH CONFIGURATION
|
|
20
|
+
# ================================
|
|
21
|
+
API_KEY=your_firebase_api_key_here
|
|
22
|
+
AUTH_DOMAIN=your_firebase_auth_domain_here
|
|
23
|
+
PROJECT_ID=your_firebase_project_id_here
|
|
24
|
+
STORAGE_BUCKET=your_firebase_storage_bucket_here
|
|
25
|
+
MESSAGING_SENDER_ID=your_firebase_messaging_sender_id_here
|
|
26
|
+
APP_ID=your_firebase_app_id_here
|
|
27
|
+
MEASUREMENT_ID=your_firebase_measurement_id_here
|
|
28
|
+
|
|
29
|
+
# ===============================
|
|
30
|
+
# FIREBASE SERVICE ACCOUNT CONFIGURATION
|
|
31
|
+
# ===============================
|
|
32
|
+
# **PULLED FROM ADMIN-SERVICE.JSON FILE ONLY**
|
|
33
|
+
PROJECT_ID=your_firebase_project_id_here
|
|
34
|
+
FIREBASE_SERVICE_ACCOUNT_EMAIL=your_firebase_service_account_email_here
|
|
35
|
+
FIREBASE_SERVICE_ACCOUNT_PRIVATE_KEY=your_firebase_service_account_private_key_here
|
|
36
|
+
|
|
37
|
+
# ================================
|
|
38
|
+
# PAGES WORKER ENVIRONMENT VARIABLES
|
|
39
|
+
# ================================
|
|
40
|
+
PAGES_PROJECT_NAME=your_pages_project_name_here
|
|
41
|
+
PAGES_CUSTOM_DOMAIN=your_custom_domain_here
|
|
42
|
+
|
|
43
|
+
# ================================
|
|
44
|
+
# KEYS WORKER ENVIRONMENT VARIABLES
|
|
45
|
+
# ================================
|
|
46
|
+
KEYS_WORKER_NAME=your_keys_worker_name_here
|
|
47
|
+
KEYS_WORKER_DOMAIN=your_keys_worker_domain_here
|
|
48
|
+
KEYS_AUTH=your_custom_keys_auth_token_here
|
|
49
|
+
ACCOUNT_HASH=your_cloudflare_images_account_hash_here
|
|
50
|
+
|
|
51
|
+
# ================================
|
|
52
|
+
# USER WORKER ENVIRONMENT VARIABLES
|
|
53
|
+
# ================================
|
|
54
|
+
USER_WORKER_NAME=your_user_worker_name_here
|
|
55
|
+
USER_WORKER_DOMAIN=your_user_worker_domain_here
|
|
56
|
+
KV_STORE_ID=your_kv_store_id_here
|
|
57
|
+
|
|
58
|
+
# ================================
|
|
59
|
+
# DATA WORKER ENVIRONMENT VARIABLES
|
|
60
|
+
# ================================
|
|
61
|
+
DATA_WORKER_NAME=your_data_worker_name_here
|
|
62
|
+
DATA_BUCKET_NAME=your_data_bucket_name_here
|
|
63
|
+
DATA_WORKER_DOMAIN=your_data_worker_domain_here
|
|
64
|
+
# Auto-generated by scripts/deploy-config.sh when placeholders are detected.
|
|
65
|
+
MANIFEST_SIGNING_PRIVATE_KEY=your_manifest_signing_private_key_here
|
|
66
|
+
MANIFEST_SIGNING_KEY_ID=forensic-signing-key-v1
|
|
67
|
+
MANIFEST_SIGNING_PUBLIC_KEY=your_manifest_signing_public_key_here
|
|
68
|
+
|
|
69
|
+
# ================================
|
|
70
|
+
# AUDIT WORKER ENVIRONMENT VARIABLES
|
|
71
|
+
# ================================
|
|
72
|
+
AUDIT_WORKER_NAME=your_audit_worker_name_here
|
|
73
|
+
AUDIT_BUCKET_NAME=your_audit_bucket_name_here
|
|
74
|
+
AUDIT_WORKER_DOMAIN=your_audit_worker_domain_here
|
|
75
|
+
|
|
76
|
+
# ================================
|
|
77
|
+
# IMAGES WORKER ENVIRONMENT VARIABLES
|
|
78
|
+
# ================================
|
|
79
|
+
IMAGES_WORKER_NAME=your_images_worker_name_here
|
|
80
|
+
IMAGES_WORKER_DOMAIN=your_images_worker_domain_here
|
|
81
|
+
API_TOKEN=your_cloudflare_images_api_token_here
|
|
82
|
+
HMAC_KEY=your_cloudflare_images_hmac_key_here
|
|
83
|
+
|
|
84
|
+
# ================================
|
|
85
|
+
# PDF WORKER ENVIRONMENT VARIABLES
|
|
86
|
+
# ================================
|
|
87
|
+
PDF_WORKER_NAME=your_pdf_worker_name_here
|
|
88
|
+
PDF_WORKER_DOMAIN=your_pdf_worker_domain_here
|
|
89
|
+
|
|
90
|
+
# ================================
|
|
91
|
+
# QUICK MANUAL SETUP CHECKLIST
|
|
92
|
+
# ================================
|
|
93
|
+
# □ Copy this file to .env
|
|
94
|
+
# □ Fill in all Cloudflare credentials
|
|
95
|
+
# □ Generate secure random tokens for custom auth
|
|
96
|
+
# □ Set environment variables in each worker's Cloudflare Dashboard
|
|
97
|
+
# □ Set environment variables in Pages Dashboard
|
|
98
|
+
# □ Configure KV binding in user-worker/wrangler.jsonc
|
|
99
|
+
# □ Configure R2 binding in data-worker/wrangler.jsonc
|
|
100
|
+
# □ Configure R2 binding in audit-worker/wrangler.jsonc
|
package/LICENSE
ADDED
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
https://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
Striae © 2025. All rights reserved.
|
|
179
|
+
|
|
180
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
181
|
+
you may not use this file except in compliance with the License.
|
|
182
|
+
You may obtain a copy of the License at
|
|
183
|
+
|
|
184
|
+
https://www.apache.org/licenses/LICENSE-2.0
|
|
185
|
+
|
|
186
|
+
Unless required by applicable law or agreed to in writing, software
|
|
187
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
188
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
189
|
+
See the License for the specific language governing permissions and
|
|
190
|
+
limitations under the License.
|
package/NOTICE
ADDED
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
NOTICE
|
|
2
|
+
|
|
3
|
+
Striae – A Firearms Examiner’s Comparison Companion
|
|
4
|
+
|
|
5
|
+
Striae © 2025. All rights reserved.
|
|
6
|
+
|
|
7
|
+
Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License in the repository’s LICENSE file.
|
|
8
|
+
|
|
9
|
+
This product includes software developed by Stephen J. Lu.
|
|
10
|
+
|
|
11
|
+
Attributions for bundled components:
|
|
12
|
+
|
|
13
|
+
Portions of this product may include open-source software licensed under their respective licenses, including but not limited to: Remix, Cloudflare Workers, Firebase, Tailwind CSS, Vite, and other npm packages. License texts for third-party components are provided in their respective source files or in node_modules as applicable.
|
|
14
|
+
|
|
15
|
+
No trademark rights are granted for “Striae” or any associated names or logos.
|
|
16
|
+
|
|
17
|
+
The background image used in the application landing page and marketing materials is sourced from:
|
|
18
|
+
Mattijssen, Erwin & Kerkhoff, Wim & Berger, Charles & Dror, Itiel & Stoel, Reinoud. (2016). Implementing context information management in forensic casework: Minimizing contextual bias in firearms examination. Science & Justice. 56. 113-122. <https://www.researchgate.net/publication/288700798_Implementing_context_information_management_in_forensic_casework_Minimizing_contextual_bias_in_firearms_examination>.
|
package/README.md
ADDED
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
# @striae-org/striae
|
|
2
|
+
|
|
3
|
+
Striae is a cloud-native forensic annotation application for firearms identification, built with Remix and Cloudflare Workers.
|
|
4
|
+
|
|
5
|
+
This npm package publishes the Striae application source and deployment scaffolding for teams that run their own Striae environment.
|
|
6
|
+
|
|
7
|
+
## Live Project
|
|
8
|
+
|
|
9
|
+
- Application: [https://www.striae.org](https://www.striae.org)
|
|
10
|
+
- Source repository: [https://github.com/striae-org/striae](https://github.com/striae-org/striae)
|
|
11
|
+
- Releases: [https://github.com/striae-org/striae/releases](https://github.com/striae-org/striae/releases)
|
|
12
|
+
- Security policy: [https://github.com/striae-org/striae/security/policy](https://github.com/striae-org/striae/security/policy)
|
|
13
|
+
|
|
14
|
+
## What This Package Is
|
|
15
|
+
|
|
16
|
+
- A deployable source distribution of Striae app code.
|
|
17
|
+
- A package that includes worker examples and example configuration files.
|
|
18
|
+
|
|
19
|
+
## What This Package Is Not
|
|
20
|
+
|
|
21
|
+
- Not a small client SDK.
|
|
22
|
+
- Not a zero-config, ready-to-run desktop app.
|
|
23
|
+
|
|
24
|
+
## npm Package, Installation, and Full Deployment
|
|
25
|
+
|
|
26
|
+
**Striae Package Links**
|
|
27
|
+
|
|
28
|
+
- npmjs: [https://www.npmjs.com/package/@striae-org/striae](https://www.npmjs.com/package/@striae-org/striae)
|
|
29
|
+
- GitHub Packages: [https://github.com/orgs/striae-org/packages/npm/package/striae](https://github.com/orgs/striae-org/packages/npm/package/striae)
|
|
30
|
+
|
|
31
|
+
1) Install the latest package:
|
|
32
|
+
|
|
33
|
+
```bash
|
|
34
|
+
npm i @striae-org/striae
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
2) Copy the package scaffold into the project root
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
cp -R node_modules/@striae-org/striae/. .
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
3) Reinstall using Striae's own package.json (includes dev deps like wrangler/remix)
|
|
44
|
+
|
|
45
|
+
```bash
|
|
46
|
+
rm -rf node_modules package-lock.json
|
|
47
|
+
npm install
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
4) Prepare Firebase admin credentials (required before deploy-config can pass)
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
mkdir -p app/config
|
|
54
|
+
cp -f app/config-example/admin-service.json app/config/admin-service.json
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
5) Replace `app/config/admin-service.json` with your actual Firebase service account JSON
|
|
58
|
+
|
|
59
|
+
6) Authenticate Cloudflare CLI
|
|
60
|
+
|
|
61
|
+
```bash
|
|
62
|
+
npx wrangler login
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
6) Run guided config + full deployment
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
npm run deploy:all
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
## Publish To npmjs And GitHub Packages
|
|
72
|
+
|
|
73
|
+
1) Verify auth for both registries
|
|
74
|
+
|
|
75
|
+
```bash
|
|
76
|
+
npm whoami --registry=https://registry.npmjs.org/
|
|
77
|
+
npm whoami --registry=https://npm.pkg.github.com/
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
2) Publish current version to npmjs (public)
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
npm run publish:npm
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
3) Publish the same version to GitHub Packages
|
|
87
|
+
|
|
88
|
+
```bash
|
|
89
|
+
npm run publish:github
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
4) Optional dry-runs before a real release
|
|
93
|
+
|
|
94
|
+
```bash
|
|
95
|
+
npm run publish:npm:dry-run
|
|
96
|
+
npm run publish:github:dry-run
|
|
97
|
+
npm run publish:all:dry-run
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
## NPM Package Content Policy
|
|
101
|
+
|
|
102
|
+
This package intentionally includes only non-sensitive defaults and runtime source needed for setup.
|
|
103
|
+
|
|
104
|
+
Included:
|
|
105
|
+
|
|
106
|
+
- `app/` source (with `app/config-example/`)
|
|
107
|
+
- `functions/`, `public/`, `scripts/`
|
|
108
|
+
- Worker package manifests
|
|
109
|
+
- Worker source files except runtime entry files (`workers/*/src/*.ts` and excluding `workers/*/src/*worker.ts`)
|
|
110
|
+
- Worker example Wrangler configs (`workers/*/wrangler.jsonc.example`)
|
|
111
|
+
- Project-level example and build config (`.env.example`, `wrangler.toml.example`, `tsconfig.json`, etc.)
|
|
112
|
+
|
|
113
|
+
Excluded (by design):
|
|
114
|
+
|
|
115
|
+
- Real runtime config under `app/config/`
|
|
116
|
+
- Real worker config files (for example `workers/*/wrangler.jsonc`)
|
|
117
|
+
- Local secrets and machine-specific files
|
|
118
|
+
- Extra repository metadata not required for npm consumers
|
|
119
|
+
|
|
120
|
+
## Security Notes
|
|
121
|
+
|
|
122
|
+
- Do not commit secrets to `app/config/`, `.env`, or worker config files.
|
|
123
|
+
- Use only example files as templates and provide real values in your own private environment.
|
|
124
|
+
- Review release notes for security updates before deployment.
|
|
125
|
+
|
|
126
|
+
## License
|
|
127
|
+
|
|
128
|
+
See `LICENSE` and `NOTICE`.
|
|
129
|
+
|
|
130
|
+
## Support
|
|
131
|
+
|
|
132
|
+
- Support page: [https://www.striae.org/support](https://www.striae.org/support)
|
|
133
|
+
- Contact: [info@striae.org](mailto:info@striae.org)
|