@jjlmoya/utils-forensic-science 1.5.0 → 1.7.0
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/package.json +4 -2
- package/src/category/index.ts +3 -1
- package/src/entries.ts +5 -1
- package/src/index.ts +1 -0
- package/src/layouts/PreviewLayout.astro +7 -2
- package/src/tests/locale_completeness.test.ts +2 -2
- package/src/tests/pagespeed_best_practices.test.ts +198 -0
- package/src/tests/tool_validation.test.ts +2 -2
- package/src/tool/bloodstain-pattern-origin-analyzer/component.astro +39 -39
- package/src/tool/forensic-blood-test-simulator/dom-utils.ts +3 -3
- package/src/tool/forensic-fiber-comparison-microscope/component.astro +2 -2
- package/src/tool/forensic-fiber-comparison-microscope/view.ts +3 -2
- package/src/tool/forensic-fingerprint-minutiae-identifier/component.astro +8 -4
- package/src/tool/forensic-sex-determinator/component.astro +1 -1
- package/src/tool/forensic-stature-estimator/components/OsteometricSelector.astro +1 -1
- package/src/tool/forensic-toolmark-striation-matcher/bibliography.astro +6 -0
- package/src/tool/forensic-toolmark-striation-matcher/bibliography.ts +16 -0
- package/src/tool/forensic-toolmark-striation-matcher/component.astro +121 -0
- package/src/tool/forensic-toolmark-striation-matcher/entry.ts +32 -0
- package/src/tool/forensic-toolmark-striation-matcher/forensic-toolmark-striation-matcher.css +580 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/de.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/en.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/es.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/fr.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/id.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/it.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/ja.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/ko.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/nl.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/pl.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/pt.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/ru.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/sv.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/tr.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/i18n/zh.ts +301 -0
- package/src/tool/forensic-toolmark-striation-matcher/index.ts +11 -0
- package/src/tool/forensic-toolmark-striation-matcher/logic.ts +71 -0
- package/src/tool/forensic-toolmark-striation-matcher/renderer.ts +237 -0
- package/src/tool/forensic-toolmark-striation-matcher/seo.astro +15 -0
- package/src/tool/forensic-toolmark-striation-matcher/view.ts +291 -0
- package/src/tool/widmark-alcohol-simulator/component.astro +6 -6
- package/src/tools.ts +3 -1
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
---
|
|
2
|
+
import './forensic-toolmark-striation-matcher.css';
|
|
3
|
+
|
|
4
|
+
interface Props {
|
|
5
|
+
ui: Record<string, string>;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
const { ui } = Astro.props;
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
<section class="toolmark-shell" data-toolmark-tool>
|
|
12
|
+
<div class="toolmark-stage">
|
|
13
|
+
<div class="toolmark-view-wrap">
|
|
14
|
+
<div class="toolmark-view" aria-label={ui.viewerAria}>
|
|
15
|
+
<canvas id="toolmark-canvas" width="980" height="640"></canvas>
|
|
16
|
+
<input id="toolmark-split" class="toolmark-split" type="range" min="22" max="78" value="50" aria-label={ui.splitLabel} />
|
|
17
|
+
<div class="toolmark-handle" aria-hidden="true">
|
|
18
|
+
<span></span>
|
|
19
|
+
</div>
|
|
20
|
+
<div class="toolmark-score" id="toolmark-score-card">
|
|
21
|
+
<span>{ui.correlation}</span>
|
|
22
|
+
<strong id="toolmark-correlation">{ui.emptyValue}</strong>
|
|
23
|
+
<small id="toolmark-verdict">{ui.emptyValue}</small>
|
|
24
|
+
</div>
|
|
25
|
+
</div>
|
|
26
|
+
<div class="toolmark-strip" aria-hidden="true">
|
|
27
|
+
<span></span>
|
|
28
|
+
<span></span>
|
|
29
|
+
<span></span>
|
|
30
|
+
</div>
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
<aside class="toolmark-controls">
|
|
34
|
+
<div class="toolmark-panel">
|
|
35
|
+
<span class="toolmark-panel-label">{ui.loadImages}</span>
|
|
36
|
+
<label class="toolmark-upload">
|
|
37
|
+
<span>{ui.uploadKnown}</span>
|
|
38
|
+
<strong id="toolmark-known-name">{ui.noFile}</strong>
|
|
39
|
+
<input id="toolmark-known-file" type="file" accept="image/*" />
|
|
40
|
+
</label>
|
|
41
|
+
<label class="toolmark-upload">
|
|
42
|
+
<span>{ui.uploadQuestioned}</span>
|
|
43
|
+
<strong id="toolmark-questioned-name">{ui.noFile}</strong>
|
|
44
|
+
<input id="toolmark-questioned-file" type="file" accept="image/*" />
|
|
45
|
+
</label>
|
|
46
|
+
</div>
|
|
47
|
+
|
|
48
|
+
<div class="toolmark-panel">
|
|
49
|
+
<div class="toolmark-panel-head">
|
|
50
|
+
<span class="toolmark-panel-label">{ui.alignImage}</span>
|
|
51
|
+
<div class="toolmark-unit-toggle" role="group" aria-label={ui.units}>
|
|
52
|
+
<button type="button" data-toolmark-unit="metric" data-active="true">{ui.metric}</button>
|
|
53
|
+
<button type="button" data-toolmark-unit="imperial" data-active="false">{ui.imperial}</button>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
<label class="toolmark-slider">
|
|
57
|
+
<span><b>{ui.offset}</b><strong id="toolmark-offset-label">-</strong></span>
|
|
58
|
+
<input id="toolmark-offset" type="range" min="-180" max="180" value="34" step="1" />
|
|
59
|
+
</label>
|
|
60
|
+
|
|
61
|
+
<label class="toolmark-slider">
|
|
62
|
+
<span><b>{ui.rotation}</b><strong id="toolmark-rotation-label">-</strong></span>
|
|
63
|
+
<input id="toolmark-rotation" type="range" min="-12" max="12" value="2.5" step="0.1" />
|
|
64
|
+
</label>
|
|
65
|
+
|
|
66
|
+
<label class="toolmark-slider">
|
|
67
|
+
<span><b>{ui.zoom}</b><strong id="toolmark-zoom-label">-</strong></span>
|
|
68
|
+
<input id="toolmark-zoom" type="range" min="50" max="260" value="100" step="2" />
|
|
69
|
+
</label>
|
|
70
|
+
</div>
|
|
71
|
+
|
|
72
|
+
<div class="toolmark-panel">
|
|
73
|
+
<span class="toolmark-panel-label">{ui.adjustImage}</span>
|
|
74
|
+
<div class="toolmark-tune">
|
|
75
|
+
<label>
|
|
76
|
+
<span>{ui.contrast}</span>
|
|
77
|
+
<input id="toolmark-contrast" type="range" min="50" max="180" value="108" step="1" />
|
|
78
|
+
</label>
|
|
79
|
+
<label>
|
|
80
|
+
<span>{ui.brightness}</span>
|
|
81
|
+
<input id="toolmark-brightness" type="range" min="55" max="150" value="100" step="1" />
|
|
82
|
+
</label>
|
|
83
|
+
</div>
|
|
84
|
+
</div>
|
|
85
|
+
|
|
86
|
+
<div class="toolmark-actions" aria-label={ui.outputControls}>
|
|
87
|
+
<button type="button" id="toolmark-reset">{ui.center}</button>
|
|
88
|
+
<button type="button" id="toolmark-grid" data-active="true">{ui.grid}</button>
|
|
89
|
+
<button type="button" id="toolmark-export">{ui.exportImage}</button>
|
|
90
|
+
</div>
|
|
91
|
+
|
|
92
|
+
<details class="toolmark-demo">
|
|
93
|
+
<summary>{ui.demoOptions}</summary>
|
|
94
|
+
<div class="toolmark-profile" role="group" aria-label={ui.toolProfile}>
|
|
95
|
+
<button type="button" data-toolmark-profile="screwdriver" data-active="true"><span>{ui.screwdriver}</span></button>
|
|
96
|
+
<button type="button" data-toolmark-profile="prybar" data-active="false"><span>{ui.prybar}</span></button>
|
|
97
|
+
<button type="button" data-toolmark-profile="boltCutter" data-active="false"><span>{ui.boltCutter}</span></button>
|
|
98
|
+
</div>
|
|
99
|
+
<div class="toolmark-bars">
|
|
100
|
+
<div>
|
|
101
|
+
<span>{ui.phaseFit}<strong id="toolmark-phase-label">{ui.zeroPercent}</strong></span>
|
|
102
|
+
<meter id="toolmark-phase" min="0" max="100" value="0"></meter>
|
|
103
|
+
</div>
|
|
104
|
+
<div>
|
|
105
|
+
<span>{ui.rotationFit}<strong id="toolmark-rotation-fit-label">{ui.zeroPercent}</strong></span>
|
|
106
|
+
<meter id="toolmark-rotation-fit" min="0" max="100" value="0"></meter>
|
|
107
|
+
</div>
|
|
108
|
+
</div>
|
|
109
|
+
</details>
|
|
110
|
+
|
|
111
|
+
<p class="toolmark-interpretation" id="toolmark-interpretation" aria-live="polite">{ui.emptyValue}</p>
|
|
112
|
+
</aside>
|
|
113
|
+
</div>
|
|
114
|
+
</section>
|
|
115
|
+
|
|
116
|
+
<script id="toolmark-ui" type="application/json" set:html={JSON.stringify(ui)}></script>
|
|
117
|
+
<script>
|
|
118
|
+
import { initToolmarkStriationMatcher } from './view';
|
|
119
|
+
|
|
120
|
+
initToolmarkStriationMatcher(JSON.parse(document.getElementById('toolmark-ui')?.textContent || '{}'));
|
|
121
|
+
</script>
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import type { ScienceToolEntry, ToolLocaleContent } from '../../types';
|
|
2
|
+
|
|
3
|
+
export interface ToolmarkStriationMatcherUI {
|
|
4
|
+
[key: string]: string;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export type ToolmarkStriationMatcherLocaleContent = ToolLocaleContent<ToolmarkStriationMatcherUI>;
|
|
8
|
+
|
|
9
|
+
export const forensicToolmarkStriationMatcher: ScienceToolEntry<ToolmarkStriationMatcherUI> = {
|
|
10
|
+
id: 'forensic-toolmark-striation-matcher',
|
|
11
|
+
icons: {
|
|
12
|
+
bg: 'mdi:tools',
|
|
13
|
+
fg: 'mdi:vector-polyline',
|
|
14
|
+
},
|
|
15
|
+
i18n: {
|
|
16
|
+
de: () => import('./i18n/de').then((m) => m.content),
|
|
17
|
+
en: () => import('./i18n/en').then((m) => m.content),
|
|
18
|
+
es: () => import('./i18n/es').then((m) => m.content),
|
|
19
|
+
fr: () => import('./i18n/fr').then((m) => m.content),
|
|
20
|
+
id: () => import('./i18n/id').then((m) => m.content),
|
|
21
|
+
it: () => import('./i18n/it').then((m) => m.content),
|
|
22
|
+
ja: () => import('./i18n/ja').then((m) => m.content),
|
|
23
|
+
ko: () => import('./i18n/ko').then((m) => m.content),
|
|
24
|
+
nl: () => import('./i18n/nl').then((m) => m.content),
|
|
25
|
+
pl: () => import('./i18n/pl').then((m) => m.content),
|
|
26
|
+
pt: () => import('./i18n/pt').then((m) => m.content),
|
|
27
|
+
ru: () => import('./i18n/ru').then((m) => m.content),
|
|
28
|
+
sv: () => import('./i18n/sv').then((m) => m.content),
|
|
29
|
+
tr: () => import('./i18n/tr').then((m) => m.content),
|
|
30
|
+
zh: () => import('./i18n/zh').then((m) => m.content),
|
|
31
|
+
},
|
|
32
|
+
};
|