@elaraai/e3-ui 1.0.94 → 1.0.95
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/src/allocation/adapters.d.ts +159 -0
- package/dist/src/allocation/adapters.d.ts.map +1 -0
- package/dist/src/allocation/adapters.js +241 -0
- package/dist/src/allocation/adapters.js.map +1 -0
- package/dist/src/allocation/functions.d.ts +664 -0
- package/dist/src/allocation/functions.d.ts.map +1 -0
- package/dist/src/allocation/functions.js +782 -0
- package/dist/src/allocation/functions.js.map +1 -0
- package/dist/src/allocation/index.d.ts +2985 -0
- package/dist/src/allocation/index.d.ts.map +1 -0
- package/dist/src/allocation/index.js +499 -0
- package/dist/src/allocation/index.js.map +1 -0
- package/dist/src/allocation/types.d.ts +832 -0
- package/dist/src/allocation/types.d.ts.map +1 -0
- package/dist/src/allocation/types.js +360 -0
- package/dist/src/allocation/types.js.map +1 -0
- package/dist/src/bind/func.d.ts +14 -0
- package/dist/src/bind/func.d.ts.map +1 -1
- package/dist/src/bind/func.js +22 -1
- package/dist/src/bind/func.js.map +1 -1
- package/dist/src/calendar/index.d.ts +510 -1639
- package/dist/src/calendar/index.d.ts.map +1 -1
- package/dist/src/calendar/index.js +56 -29
- package/dist/src/calendar/index.js.map +1 -1
- package/dist/src/flowchart/canvas.d.ts +9 -21
- package/dist/src/flowchart/canvas.d.ts.map +1 -1
- package/dist/src/flowchart/canvas.js +10 -22
- package/dist/src/flowchart/canvas.js.map +1 -1
- package/dist/src/flowchart/flowchart.d.ts +19 -13
- package/dist/src/flowchart/flowchart.d.ts.map +1 -1
- package/dist/src/flowchart/flowchart.js.map +1 -1
- package/dist/src/flowchart/index.d.ts +44 -21
- package/dist/src/flowchart/index.d.ts.map +1 -1
- package/dist/src/flowchart/index.js +43 -20
- package/dist/src/flowchart/index.js.map +1 -1
- package/dist/src/flowchart/library.d.ts +166 -81
- package/dist/src/flowchart/library.d.ts.map +1 -1
- package/dist/src/flowchart/library.js +232 -105
- package/dist/src/flowchart/library.js.map +1 -1
- package/dist/src/flowchart/over.d.ts +9 -16
- package/dist/src/flowchart/over.d.ts.map +1 -1
- package/dist/src/flowchart/over.js +9 -16
- package/dist/src/flowchart/over.js.map +1 -1
- package/dist/src/flowchart/payload.d.ts +710 -508
- package/dist/src/flowchart/payload.d.ts.map +1 -1
- package/dist/src/flowchart/payload.js +128 -74
- package/dist/src/flowchart/payload.js.map +1 -1
- package/dist/src/flowchart/window.d.ts +132 -347
- package/dist/src/flowchart/window.d.ts.map +1 -1
- package/dist/src/flowchart/window.js +48 -55
- package/dist/src/flowchart/window.js.map +1 -1
- package/dist/src/index.d.ts +11 -7
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js +14 -6
- package/dist/src/index.js.map +1 -1
- package/dist/src/internal.d.ts +18 -7
- package/dist/src/internal.d.ts.map +1 -1
- package/dist/src/internal.js +28 -9
- package/dist/src/internal.js.map +1 -1
- package/dist/src/plan/event-rows.d.ts +26 -10
- package/dist/src/plan/event-rows.d.ts.map +1 -1
- package/dist/src/plan/event-rows.js +39 -13
- package/dist/src/plan/event-rows.js.map +1 -1
- package/dist/src/plan/ir.d.ts +244 -815
- package/dist/src/plan/ir.d.ts.map +1 -1
- package/dist/src/plan/ir.js +8 -6
- package/dist/src/plan/ir.js.map +1 -1
- package/dist/src/plan/library.d.ts +3 -0
- package/dist/src/plan/library.d.ts.map +1 -1
- package/dist/src/plan/library.js +1 -1
- package/dist/src/plan/library.js.map +1 -1
- package/dist/src/plan/ordered-source.d.ts +1 -0
- package/dist/src/plan/ordered-source.d.ts.map +1 -1
- package/dist/src/plan/plan.d.ts +559 -1667
- package/dist/src/plan/plan.d.ts.map +1 -1
- package/dist/src/plan/plan.js +123 -45
- package/dist/src/plan/plan.js.map +1 -1
- package/dist/src/plan/root.d.ts +16 -20
- package/dist/src/plan/root.d.ts.map +1 -1
- package/dist/src/plan/root.js +23 -33
- package/dist/src/plan/root.js.map +1 -1
- package/dist/src/roster/coverage.d.ts +17 -231
- package/dist/src/roster/coverage.d.ts.map +1 -1
- package/dist/src/roster/coverage.js +94 -90
- package/dist/src/roster/coverage.js.map +1 -1
- package/dist/src/roster/fit.d.ts +59 -0
- package/dist/src/roster/fit.d.ts.map +1 -0
- package/dist/src/roster/fit.js +155 -0
- package/dist/src/roster/fit.js.map +1 -0
- package/dist/src/roster/index.d.ts +2862 -3662
- package/dist/src/roster/index.d.ts.map +1 -1
- package/dist/src/roster/index.js +383 -81
- package/dist/src/roster/index.js.map +1 -1
- package/dist/src/roster/library.d.ts +37 -92
- package/dist/src/roster/library.d.ts.map +1 -1
- package/dist/src/roster/library.js +25 -64
- package/dist/src/roster/library.js.map +1 -1
- package/dist/src/roster/lists.d.ts +195 -0
- package/dist/src/roster/lists.d.ts.map +1 -0
- package/dist/src/roster/lists.js +233 -0
- package/dist/src/roster/lists.js.map +1 -0
- package/dist/src/roster/rules.d.ts +17 -260
- package/dist/src/roster/rules.d.ts.map +1 -1
- package/dist/src/roster/rules.js +135 -132
- package/dist/src/roster/rules.js.map +1 -1
- package/dist/src/roster/targets.d.ts +115 -0
- package/dist/src/roster/targets.d.ts.map +1 -0
- package/dist/src/roster/targets.js +213 -0
- package/dist/src/roster/targets.js.map +1 -0
- package/dist/src/roster/times.d.ts +251 -0
- package/dist/src/roster/times.d.ts.map +1 -0
- package/dist/src/roster/times.js +174 -0
- package/dist/src/roster/times.js.map +1 -0
- package/dist/src/roster/types.d.ts +828 -183
- package/dist/src/roster/types.d.ts.map +1 -1
- package/dist/src/roster/types.js +224 -97
- package/dist/src/roster/types.js.map +1 -1
- package/dist/src/schedule/accessor.d.ts +28 -0
- package/dist/src/schedule/accessor.d.ts.map +1 -0
- package/dist/src/schedule/accessor.js +39 -0
- package/dist/src/schedule/accessor.js.map +1 -0
- package/dist/src/schedule/events.d.ts +170 -42
- package/dist/src/schedule/events.d.ts.map +1 -1
- package/dist/src/schedule/events.js +431 -171
- package/dist/src/schedule/events.js.map +1 -1
- package/dist/src/schedule/index.d.ts +41 -4
- package/dist/src/schedule/index.d.ts.map +1 -1
- package/dist/src/schedule/index.js +35 -3
- package/dist/src/schedule/index.js.map +1 -1
- package/dist/src/schedule/library.d.ts +13 -3
- package/dist/src/schedule/library.d.ts.map +1 -1
- package/dist/src/schedule/library.js +11 -4
- package/dist/src/schedule/library.js.map +1 -1
- package/dist/src/schedule/periods.d.ts +115 -0
- package/dist/src/schedule/periods.d.ts.map +1 -0
- package/dist/src/schedule/periods.js +215 -0
- package/dist/src/schedule/periods.js.map +1 -0
- package/dist/src/schedule/record-window.d.ts +25 -3
- package/dist/src/schedule/record-window.d.ts.map +1 -1
- package/dist/src/schedule/record-window.js +31 -18
- package/dist/src/schedule/record-window.js.map +1 -1
- package/dist/src/schedule/resources.d.ts +82 -4
- package/dist/src/schedule/resources.d.ts.map +1 -1
- package/dist/src/schedule/resources.js +44 -14
- package/dist/src/schedule/resources.js.map +1 -1
- package/dist/src/schedule/session.d.ts +69 -0
- package/dist/src/schedule/session.d.ts.map +1 -0
- package/dist/src/schedule/session.js +121 -0
- package/dist/src/schedule/session.js.map +1 -0
- package/dist/src/schedule/templates.d.ts +14 -2
- package/dist/src/schedule/templates.d.ts.map +1 -1
- package/dist/src/schedule/templates.js +5 -3
- package/dist/src/schedule/templates.js.map +1 -1
- package/dist/src/schedule/types.d.ts +1671 -37
- package/dist/src/schedule/types.d.ts.map +1 -1
- package/dist/src/schedule/types.js +196 -5
- package/dist/src/schedule/types.js.map +1 -1
- package/dist/src/schedule/window.d.ts +14 -0
- package/dist/src/schedule/window.d.ts.map +1 -1
- package/dist/src/schedule/window.js +14 -4
- package/dist/src/schedule/window.js.map +1 -1
- package/dist/src/schedule/words.d.ts +22 -0
- package/dist/src/schedule/words.d.ts.map +1 -0
- package/dist/src/schedule/words.js +25 -0
- package/dist/src/schedule/words.js.map +1 -0
- package/dist/src/sheet/index.d.ts +61 -27
- package/dist/src/sheet/index.d.ts.map +1 -1
- package/dist/src/sheet/index.js +59 -25
- package/dist/src/sheet/index.js.map +1 -1
- package/dist/src/sheet/library.d.ts +21 -3
- package/dist/src/sheet/library.d.ts.map +1 -1
- package/dist/src/sheet/library.js +23 -6
- package/dist/src/sheet/library.js.map +1 -1
- package/dist/src/sheet/registers.d.ts +100 -85
- package/dist/src/sheet/registers.d.ts.map +1 -1
- package/dist/src/sheet/registers.js +100 -85
- package/dist/src/sheet/registers.js.map +1 -1
- package/dist/src/sheet/root.d.ts +8 -12
- package/dist/src/sheet/root.d.ts.map +1 -1
- package/dist/src/sheet/root.js +6 -40
- package/dist/src/sheet/root.js.map +1 -1
- package/dist/src/sheet/sheet.d.ts +598 -2349
- package/dist/src/sheet/sheet.d.ts.map +1 -1
- package/dist/src/sheet/sheet.js +124 -37
- package/dist/src/sheet/sheet.js.map +1 -1
- package/dist/src/sheet/sub-rows.d.ts +74 -28
- package/dist/src/sheet/sub-rows.d.ts.map +1 -1
- package/dist/src/sheet/sub-rows.js +74 -28
- package/dist/src/sheet/sub-rows.js.map +1 -1
- package/dist/src/sheet/templates.d.ts +98 -34
- package/dist/src/sheet/templates.d.ts.map +1 -1
- package/dist/src/sheet/templates.js +102 -58
- package/dist/src/sheet/templates.js.map +1 -1
- package/dist/src/sheet/types.d.ts +289 -1359
- package/dist/src/sheet/types.d.ts.map +1 -1
- package/dist/src/sheet/types.js +20 -26
- package/dist/src/sheet/types.js.map +1 -1
- package/dist/src/sheet/views.d.ts +10 -11
- package/dist/src/sheet/views.d.ts.map +1 -1
- package/dist/src/sheet/views.js +15 -20
- package/dist/src/sheet/views.js.map +1 -1
- package/dist/src/{roster/visibility.d.ts → utils/key-visibility.d.ts} +42 -7
- package/dist/src/utils/key-visibility.d.ts.map +1 -0
- package/dist/src/utils/key-visibility.js +36 -0
- package/dist/src/utils/key-visibility.js.map +1 -0
- package/dist/src/utils/ordered-source.d.ts +1 -0
- package/dist/src/utils/ordered-source.d.ts.map +1 -1
- package/dist/src/utils/ordered-source.js +8 -3
- package/dist/src/utils/ordered-source.js.map +1 -1
- package/dist/src/utils/record-sources.d.ts +107 -0
- package/dist/src/utils/record-sources.d.ts.map +1 -0
- package/dist/src/utils/record-sources.js +132 -0
- package/dist/src/utils/record-sources.js.map +1 -0
- package/dist/test/allocation/allocation.examples.d.ts +2902 -0
- package/dist/test/allocation/allocation.examples.d.ts.map +1 -0
- package/dist/test/allocation/allocation.examples.js +643 -0
- package/dist/test/allocation/allocation.examples.js.map +1 -0
- package/dist/test/allocation/fit.examples.d.ts +546 -0
- package/dist/test/allocation/fit.examples.d.ts.map +1 -0
- package/dist/test/allocation/fit.examples.js +171 -0
- package/dist/test/allocation/fit.examples.js.map +1 -0
- package/dist/test/allocation/kiln-yard.d.ts +181 -0
- package/dist/test/allocation/kiln-yard.d.ts.map +1 -0
- package/dist/test/allocation/kiln-yard.js +228 -0
- package/dist/test/allocation/kiln-yard.js.map +1 -0
- package/dist/test/bind/data/data.examples.d.ts +651 -1
- package/dist/test/bind/data/data.examples.d.ts.map +1 -1
- package/dist/test/bind/data/data.examples.js +140 -2
- package/dist/test/bind/data/data.examples.js.map +1 -1
- package/dist/test/bind/func/func.examples.d.ts +10 -1
- package/dist/test/bind/func/func.examples.d.ts.map +1 -1
- package/dist/test/bind/func/func.examples.js +8 -1
- package/dist/test/bind/func/func.examples.js.map +1 -1
- package/dist/test/bind/record/record.examples.d.ts +633 -1
- package/dist/test/bind/record/record.examples.d.ts.map +1 -1
- package/dist/test/bind/record/record.examples.js +26 -2
- package/dist/test/bind/record/record.examples.js.map +1 -1
- package/dist/test/calendar/calendar-records.examples.d.ts.map +1 -1
- package/dist/test/calendar/calendar-records.examples.js +18 -14
- package/dist/test/calendar/calendar-records.examples.js.map +1 -1
- package/dist/test/calendar/calendar.examples.d.ts +521 -16
- package/dist/test/calendar/calendar.examples.d.ts.map +1 -1
- package/dist/test/calendar/calendar.examples.js +182 -135
- package/dist/test/calendar/calendar.examples.js.map +1 -1
- package/dist/test/examples-package.d.ts +75 -0
- package/dist/test/examples-package.d.ts.map +1 -0
- package/dist/test/examples-package.js +263 -0
- package/dist/test/examples-package.js.map +1 -0
- package/dist/test/flowchart/flowchart.examples.d.ts +211 -19
- package/dist/test/flowchart/flowchart.examples.d.ts.map +1 -1
- package/dist/test/flowchart/flowchart.examples.js +102 -75
- package/dist/test/flowchart/flowchart.examples.js.map +1 -1
- package/dist/test/plan/plan-events.examples.d.ts +1439 -209
- package/dist/test/plan/plan-events.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-events.examples.js +199 -59
- package/dist/test/plan/plan-events.examples.js.map +1 -1
- package/dist/test/plan/plan-records.examples.d.ts +420 -0
- package/dist/test/plan/plan-records.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-records.examples.js +70 -19
- package/dist/test/plan/plan-records.examples.js.map +1 -1
- package/dist/test/plan/plan-windows.examples.d.ts +636 -55
- package/dist/test/plan/plan-windows.examples.d.ts.map +1 -1
- package/dist/test/plan/plan-windows.examples.js +69 -33
- package/dist/test/plan/plan-windows.examples.js.map +1 -1
- package/dist/test/plan/plan.examples.d.ts +153 -31
- package/dist/test/plan/plan.examples.d.ts.map +1 -1
- package/dist/test/plan/plan.examples.js +178 -101
- package/dist/test/plan/plan.examples.js.map +1 -1
- package/dist/test/roster/domain.examples.d.ts +467 -250
- package/dist/test/roster/domain.examples.d.ts.map +1 -1
- package/dist/test/roster/domain.examples.js +92 -29
- package/dist/test/roster/domain.examples.js.map +1 -1
- package/dist/test/roster/roster-records.examples.d.ts +430 -586
- package/dist/test/roster/roster-records.examples.d.ts.map +1 -1
- package/dist/test/roster/roster-records.examples.js +102 -43
- package/dist/test/roster/roster-records.examples.js.map +1 -1
- package/dist/test/roster/roster.examples.d.ts +2319 -606
- package/dist/test/roster/roster.examples.d.ts.map +1 -1
- package/dist/test/roster/roster.examples.js +456 -148
- package/dist/test/roster/roster.examples.js.map +1 -1
- package/dist/test/roster/warehouse.d.ts +172 -63
- package/dist/test/roster/warehouse.d.ts.map +1 -1
- package/dist/test/roster/warehouse.js +172 -39
- package/dist/test/roster/warehouse.js.map +1 -1
- package/dist/test/schedule/schedule.examples.d.ts +3499 -0
- package/dist/test/schedule/schedule.examples.d.ts.map +1 -0
- package/dist/test/schedule/schedule.examples.js +192 -0
- package/dist/test/schedule/schedule.examples.js.map +1 -0
- package/dist/test/sheet/sheet-records.examples.d.ts.map +1 -1
- package/dist/test/sheet/sheet-records.examples.js +22 -18
- package/dist/test/sheet/sheet-records.examples.js.map +1 -1
- package/dist/test/sheet/sheet.examples.d.ts +715 -26
- package/dist/test/sheet/sheet.examples.d.ts.map +1 -1
- package/dist/test/sheet/sheet.examples.js +204 -130
- package/dist/test/sheet/sheet.examples.js.map +1 -1
- package/package.json +17 -10
- package/dist/src/roster/people.d.ts +0 -50
- package/dist/src/roster/people.d.ts.map +0 -1
- package/dist/src/roster/people.js +0 -32
- package/dist/src/roster/people.js.map +0 -1
- package/dist/src/roster/visibility.d.ts.map +0 -1
- package/dist/src/roster/visibility.js +0 -25
- package/dist/src/roster/visibility.js.map +0 -1
|
@@ -0,0 +1,832 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* The Allocation's East types (#1371, `Builder Interfaces Spec.md` §6.3). A
|
|
7
|
+
* day is the board's reading of the app's own rows — each bin the app's row,
|
|
8
|
+
* with the roles the board reads from it — carried in the fit's and the
|
|
9
|
+
* check's requests and in the renderer, and stored nowhere: the bins and the
|
|
10
|
+
* days are the app's records. Beside them, the arrivals and resources an app
|
|
11
|
+
* gives the board, and the fit's question and answer.
|
|
12
|
+
*
|
|
13
|
+
* The types over a day take the app's bin row type, `R`: each is a
|
|
14
|
+
* constructor, and the same `R` gives the same East type (`isTypeEqual`), so a
|
|
15
|
+
* row type declared once matches the board's bin kind and the fit's request.
|
|
16
|
+
*
|
|
17
|
+
* @packageDocumentation
|
|
18
|
+
*/
|
|
19
|
+
import { ArrayType, BooleanType, DateTimeType, DictType, FloatType, IntegerType, NullType, OptionType, StringType, StructType, VariantType, type EastType } from "@elaraai/east";
|
|
20
|
+
import { TimeStepType } from "@elaraai/east-ui";
|
|
21
|
+
/**
|
|
22
|
+
* A lane: it takes one bin each `every` (an hour by default), at its offset
|
|
23
|
+
* past it.
|
|
24
|
+
*
|
|
25
|
+
* @property key - Its key, what a bin's lane names: its row's key in the lanes' resource kind
|
|
26
|
+
* @property label - Its name (`B-1`)
|
|
27
|
+
* @property offset - How far past each slot's start its bins are booked (`minutes 15`)
|
|
28
|
+
*/
|
|
29
|
+
export declare const AllocationLaneType: StructType<{
|
|
30
|
+
readonly key: StringType;
|
|
31
|
+
readonly label: StringType;
|
|
32
|
+
readonly offset: VariantType<{
|
|
33
|
+
readonly minutes: FloatType;
|
|
34
|
+
readonly hours: FloatType;
|
|
35
|
+
readonly days: FloatType;
|
|
36
|
+
readonly weeks: FloatType;
|
|
37
|
+
readonly months: FloatType;
|
|
38
|
+
}>;
|
|
39
|
+
}>;
|
|
40
|
+
/** Type representing {@link AllocationLaneType}. */
|
|
41
|
+
export type AllocationLaneType = typeof AllocationLaneType;
|
|
42
|
+
/**
|
|
43
|
+
* A day's status: Schedule's period status, read from the app's days record
|
|
44
|
+
* (`Schedule.periods`).
|
|
45
|
+
*
|
|
46
|
+
* @property draft - An editable day
|
|
47
|
+
* @property published - A read-only day, and when it was published when the app's published case holds the time
|
|
48
|
+
* @property other - Another case of the app's status, by its name: read-only
|
|
49
|
+
*/
|
|
50
|
+
export declare const AllocationStatusType: VariantType<{
|
|
51
|
+
readonly draft: NullType;
|
|
52
|
+
readonly published: StructType<{
|
|
53
|
+
readonly at: OptionType<DateTimeType>;
|
|
54
|
+
}>;
|
|
55
|
+
readonly other: StringType;
|
|
56
|
+
}>;
|
|
57
|
+
/** Type representing {@link AllocationStatusType}. */
|
|
58
|
+
export type AllocationStatusType = typeof AllocationStatusType;
|
|
59
|
+
/** The fields of a {@link AllocationBinType}, over the app's bin row type `R`. */
|
|
60
|
+
export type AllocationBinFields<R extends EastType> = {
|
|
61
|
+
lane: StringType;
|
|
62
|
+
at: DateTimeType;
|
|
63
|
+
arrival: OptionType<StringType>;
|
|
64
|
+
quantity: FloatType;
|
|
65
|
+
kind: OptionType<StringType>;
|
|
66
|
+
hold: typeof TimeStepType;
|
|
67
|
+
parts: DictType<StringType, FloatType>;
|
|
68
|
+
row: R;
|
|
69
|
+
};
|
|
70
|
+
/** A bin over the app's bin row type `R` — what {@link AllocationBinTypeFor} constructs. */
|
|
71
|
+
export type AllocationBinType<R extends EastType> = StructType<AllocationBinFields<R>>;
|
|
72
|
+
/**
|
|
73
|
+
* One bin, as the board reads it from the app's row (`R`): its roles — one
|
|
74
|
+
* booking in a lane slot, and the quantity it puts on each resource — beside
|
|
75
|
+
* the row itself, every field of it.
|
|
76
|
+
*
|
|
77
|
+
* @remarks
|
|
78
|
+
* Composed from the bin kind's roles (its `rows` and `read`) and the row. A
|
|
79
|
+
* bin keeps what it was booked with — its kind and its hold come from its
|
|
80
|
+
* arrival when it is booked, as its row's other fields do, and stay with it
|
|
81
|
+
* when it moves — so a bin can differ from its arrival, as a delivery measured
|
|
82
|
+
* on arrival does. A reservation books no arrival, and holds no quantity, no
|
|
83
|
+
* kind and no hold.
|
|
84
|
+
*
|
|
85
|
+
* @typeParam R - The app's bin row type
|
|
86
|
+
* @param row - The app's bin row type
|
|
87
|
+
* @returns `StructType({ lane, at, arrival, quantity, kind, hold, parts, row })`
|
|
88
|
+
*
|
|
89
|
+
* @property lane - Its lane's key
|
|
90
|
+
* @property at - Its time; a batch's bins follow one minute apart
|
|
91
|
+
* @property arrival - The arrival it books, by key; `none` for a reservation
|
|
92
|
+
* @property quantity - Its quantity; 0 for a reservation
|
|
93
|
+
* @property kind - What it goes with on a resource (its arrival's kind when booked); `none` for a kind with no `kind` role
|
|
94
|
+
* @property hold - How long a resource holds it from the plan day (its arrival's hold when booked)
|
|
95
|
+
* @property parts - The quantity on each resource, by key; empty while it is not linked
|
|
96
|
+
* @property row - The app's row, every field of it
|
|
97
|
+
*/
|
|
98
|
+
export declare function AllocationBinTypeFor<R extends EastType>(row: R): AllocationBinType<R>;
|
|
99
|
+
/** A day over the app's bin row type `R` — what {@link AllocationDayTypeFor} constructs. */
|
|
100
|
+
export type AllocationDayType<R extends EastType> = StructType<{
|
|
101
|
+
status: AllocationStatusType;
|
|
102
|
+
bins: DictType<StringType, AllocationBinType<R>>;
|
|
103
|
+
}>;
|
|
104
|
+
/**
|
|
105
|
+
* One day of the app's bins, as the board reads them: its period's status and
|
|
106
|
+
* its bins, the drafts in place.
|
|
107
|
+
*
|
|
108
|
+
* @typeParam R - The app's bin row type
|
|
109
|
+
* @param row - The app's bin row type
|
|
110
|
+
* @returns `StructType({ status, bins })`
|
|
111
|
+
*
|
|
112
|
+
* @property status - The day's status, from the app's days record; a draft with no `periods`, or no row for the day
|
|
113
|
+
* @property bins - The bins whose `at` falls in the day, by their keys
|
|
114
|
+
*/
|
|
115
|
+
export declare function AllocationDayTypeFor<R extends EastType>(row: R): AllocationDayType<R>;
|
|
116
|
+
/**
|
|
117
|
+
* A span of time, `[from, to)`.
|
|
118
|
+
*
|
|
119
|
+
* @property from - Its start
|
|
120
|
+
* @property to - Its end
|
|
121
|
+
*/
|
|
122
|
+
export declare const AllocationIntervalType: StructType<{
|
|
123
|
+
readonly from: DateTimeType;
|
|
124
|
+
readonly to: DateTimeType;
|
|
125
|
+
}>;
|
|
126
|
+
/** Type representing {@link AllocationIntervalType}. */
|
|
127
|
+
export type AllocationIntervalType = typeof AllocationIntervalType;
|
|
128
|
+
/**
|
|
129
|
+
* Other work on a resource: a job covering the plan day's start makes it busy
|
|
130
|
+
* until the job ends; one starting later is its next job.
|
|
131
|
+
*
|
|
132
|
+
* @property label - Its name (`C-3142`)
|
|
133
|
+
* @property start - When it starts
|
|
134
|
+
* @property end - When it ends, and the resource is released
|
|
135
|
+
*/
|
|
136
|
+
export declare const AllocationJobType: StructType<{
|
|
137
|
+
readonly label: StringType;
|
|
138
|
+
readonly start: DateTimeType;
|
|
139
|
+
readonly end: DateTimeType;
|
|
140
|
+
}>;
|
|
141
|
+
/** Type representing {@link AllocationJobType}. */
|
|
142
|
+
export type AllocationJobType = typeof AllocationJobType;
|
|
143
|
+
/**
|
|
144
|
+
* One line of an arrival's details, shown read-only in a bin's inspector.
|
|
145
|
+
*
|
|
146
|
+
* @property label - Its label (`Settings`)
|
|
147
|
+
* @property value - Its text
|
|
148
|
+
*/
|
|
149
|
+
export declare const AllocationDetailType: StructType<{
|
|
150
|
+
readonly label: StringType;
|
|
151
|
+
readonly value: StringType;
|
|
152
|
+
}>;
|
|
153
|
+
/** Type representing {@link AllocationDetailType}. */
|
|
154
|
+
export type AllocationDetailType = typeof AllocationDetailType;
|
|
155
|
+
/**
|
|
156
|
+
* What the board books from: an arrival, resolved from the app's rows
|
|
157
|
+
* (`Allocation.arrivals`).
|
|
158
|
+
*
|
|
159
|
+
* @property key - Its key in the app's rows, what a bin's `arrival` names
|
|
160
|
+
* @property label - Its code on cards, chips and lists (`LD-2231`)
|
|
161
|
+
* @property meta - Its second line (`BRK · R2 · spec MC12`)
|
|
162
|
+
* @property quantity - Its quantity, booked whole unless split
|
|
163
|
+
* @property hold - How long a resource holds a bin of it
|
|
164
|
+
* @property kind - What it goes with: a resource holding the same kind ranks higher in `Allocation.fit`
|
|
165
|
+
* @property due - When it is due; overdue before the plan day
|
|
166
|
+
* @property window - Its ready window
|
|
167
|
+
* @property details - Read-only lines in a bin's inspector
|
|
168
|
+
*/
|
|
169
|
+
export declare const AllocationArrivalType: StructType<{
|
|
170
|
+
readonly key: StringType;
|
|
171
|
+
readonly label: StringType;
|
|
172
|
+
readonly meta: OptionType<StringType>;
|
|
173
|
+
readonly quantity: FloatType;
|
|
174
|
+
readonly hold: VariantType<{
|
|
175
|
+
readonly minutes: FloatType;
|
|
176
|
+
readonly hours: FloatType;
|
|
177
|
+
readonly days: FloatType;
|
|
178
|
+
readonly weeks: FloatType;
|
|
179
|
+
readonly months: FloatType;
|
|
180
|
+
}>;
|
|
181
|
+
readonly kind: OptionType<StringType>;
|
|
182
|
+
readonly due: OptionType<DateTimeType>;
|
|
183
|
+
readonly window: OptionType<StructType<{
|
|
184
|
+
readonly from: DateTimeType;
|
|
185
|
+
readonly to: DateTimeType;
|
|
186
|
+
}>>;
|
|
187
|
+
readonly details: ArrayType<StructType<{
|
|
188
|
+
readonly label: StringType;
|
|
189
|
+
readonly value: StringType;
|
|
190
|
+
}>>;
|
|
191
|
+
}>;
|
|
192
|
+
/** Type representing {@link AllocationArrivalType}. */
|
|
193
|
+
export type AllocationArrivalType = typeof AllocationArrivalType;
|
|
194
|
+
/**
|
|
195
|
+
* A resource bins are allocated to, resolved from the app's rows through its
|
|
196
|
+
* resource kind's accessors (`Schedule.resources`).
|
|
197
|
+
*
|
|
198
|
+
* @property key - Its key in the app's rows, what a bin's `parts` name
|
|
199
|
+
* @property label - Its name (`K-203`)
|
|
200
|
+
* @property group - Its group (`Hall B`)
|
|
201
|
+
* @property meta - Its free line (`Hall B · 40 m³`)
|
|
202
|
+
* @property note - A line about its next job, after the inspector's next fill
|
|
203
|
+
* @property min - Its minimum, in the quantity's unit
|
|
204
|
+
* @property max - Its maximum
|
|
205
|
+
* @property hold - How long a reservation on it is checked for, and how long it is held when it holds only reservations
|
|
206
|
+
* @property jobs - Other work on it
|
|
207
|
+
*/
|
|
208
|
+
export declare const AllocationResourceType: StructType<{
|
|
209
|
+
readonly key: StringType;
|
|
210
|
+
readonly label: StringType;
|
|
211
|
+
readonly group: OptionType<StringType>;
|
|
212
|
+
readonly meta: OptionType<StringType>;
|
|
213
|
+
readonly note: OptionType<StringType>;
|
|
214
|
+
readonly min: FloatType;
|
|
215
|
+
readonly max: FloatType;
|
|
216
|
+
readonly hold: VariantType<{
|
|
217
|
+
readonly minutes: FloatType;
|
|
218
|
+
readonly hours: FloatType;
|
|
219
|
+
readonly days: FloatType;
|
|
220
|
+
readonly weeks: FloatType;
|
|
221
|
+
readonly months: FloatType;
|
|
222
|
+
}>;
|
|
223
|
+
readonly jobs: ArrayType<StructType<{
|
|
224
|
+
readonly label: StringType;
|
|
225
|
+
readonly start: DateTimeType;
|
|
226
|
+
readonly end: DateTimeType;
|
|
227
|
+
}>>;
|
|
228
|
+
}>;
|
|
229
|
+
/** Type representing {@link AllocationResourceType}. */
|
|
230
|
+
export type AllocationResourceType = typeof AllocationResourceType;
|
|
231
|
+
/**
|
|
232
|
+
* The built-in rules an app may turn off.
|
|
233
|
+
*
|
|
234
|
+
* @property under - Whether `Allocation.fit` and `Allocation.check` warn under a resource's minimum
|
|
235
|
+
*/
|
|
236
|
+
export declare const AllocationRulesType: StructType<{
|
|
237
|
+
readonly under: BooleanType;
|
|
238
|
+
}>;
|
|
239
|
+
/** Type representing {@link AllocationRulesType}. */
|
|
240
|
+
export type AllocationRulesType = typeof AllocationRulesType;
|
|
241
|
+
/**
|
|
242
|
+
* Everything a fit and the checks read besides the day: the board's
|
|
243
|
+
* configuration, every arrival and every resource — whatever the narrowing
|
|
244
|
+
* hides.
|
|
245
|
+
*
|
|
246
|
+
* @property lanes - The lanes, in order
|
|
247
|
+
* @property every - The slot spacing
|
|
248
|
+
* @property arrivals - Every arrival, by key
|
|
249
|
+
* @property resources - Every resource, by key
|
|
250
|
+
* @property rules - The built-in rules
|
|
251
|
+
* @property unit - The quantity's unit (`m³`), or empty
|
|
252
|
+
*/
|
|
253
|
+
export declare const AllocationContextType: StructType<{
|
|
254
|
+
readonly lanes: ArrayType<StructType<{
|
|
255
|
+
readonly key: StringType;
|
|
256
|
+
readonly label: StringType;
|
|
257
|
+
readonly offset: VariantType<{
|
|
258
|
+
readonly minutes: FloatType;
|
|
259
|
+
readonly hours: FloatType;
|
|
260
|
+
readonly days: FloatType;
|
|
261
|
+
readonly weeks: FloatType;
|
|
262
|
+
readonly months: FloatType;
|
|
263
|
+
}>;
|
|
264
|
+
}>>;
|
|
265
|
+
readonly every: VariantType<{
|
|
266
|
+
readonly minutes: FloatType;
|
|
267
|
+
readonly hours: FloatType;
|
|
268
|
+
readonly days: FloatType;
|
|
269
|
+
readonly weeks: FloatType;
|
|
270
|
+
readonly months: FloatType;
|
|
271
|
+
}>;
|
|
272
|
+
readonly arrivals: DictType<StringType, StructType<{
|
|
273
|
+
readonly key: StringType;
|
|
274
|
+
readonly label: StringType;
|
|
275
|
+
readonly meta: OptionType<StringType>;
|
|
276
|
+
readonly quantity: FloatType;
|
|
277
|
+
readonly hold: VariantType<{
|
|
278
|
+
readonly minutes: FloatType;
|
|
279
|
+
readonly hours: FloatType;
|
|
280
|
+
readonly days: FloatType;
|
|
281
|
+
readonly weeks: FloatType;
|
|
282
|
+
readonly months: FloatType;
|
|
283
|
+
}>;
|
|
284
|
+
readonly kind: OptionType<StringType>;
|
|
285
|
+
readonly due: OptionType<DateTimeType>;
|
|
286
|
+
readonly window: OptionType<StructType<{
|
|
287
|
+
readonly from: DateTimeType;
|
|
288
|
+
readonly to: DateTimeType;
|
|
289
|
+
}>>;
|
|
290
|
+
readonly details: ArrayType<StructType<{
|
|
291
|
+
readonly label: StringType;
|
|
292
|
+
readonly value: StringType;
|
|
293
|
+
}>>;
|
|
294
|
+
}>>;
|
|
295
|
+
readonly resources: DictType<StringType, StructType<{
|
|
296
|
+
readonly key: StringType;
|
|
297
|
+
readonly label: StringType;
|
|
298
|
+
readonly group: OptionType<StringType>;
|
|
299
|
+
readonly meta: OptionType<StringType>;
|
|
300
|
+
readonly note: OptionType<StringType>;
|
|
301
|
+
readonly min: FloatType;
|
|
302
|
+
readonly max: FloatType;
|
|
303
|
+
readonly hold: VariantType<{
|
|
304
|
+
readonly minutes: FloatType;
|
|
305
|
+
readonly hours: FloatType;
|
|
306
|
+
readonly days: FloatType;
|
|
307
|
+
readonly weeks: FloatType;
|
|
308
|
+
readonly months: FloatType;
|
|
309
|
+
}>;
|
|
310
|
+
readonly jobs: ArrayType<StructType<{
|
|
311
|
+
readonly label: StringType;
|
|
312
|
+
readonly start: DateTimeType;
|
|
313
|
+
readonly end: DateTimeType;
|
|
314
|
+
}>>;
|
|
315
|
+
}>>;
|
|
316
|
+
readonly rules: StructType<{
|
|
317
|
+
readonly under: BooleanType;
|
|
318
|
+
}>;
|
|
319
|
+
readonly unit: StringType;
|
|
320
|
+
}>;
|
|
321
|
+
/** Type representing {@link AllocationContextType}. */
|
|
322
|
+
export type AllocationContextType = typeof AllocationContextType;
|
|
323
|
+
/**
|
|
324
|
+
* A resource's state on the plan day.
|
|
325
|
+
*
|
|
326
|
+
* @property free - It holds nothing and is not busy
|
|
327
|
+
* @property loading - It holds bins today
|
|
328
|
+
* @property busy - A job covers the day's start
|
|
329
|
+
*/
|
|
330
|
+
export declare const AllocationLoadStateType: VariantType<{
|
|
331
|
+
readonly free: NullType;
|
|
332
|
+
readonly loading: NullType;
|
|
333
|
+
readonly busy: NullType;
|
|
334
|
+
}>;
|
|
335
|
+
/** Type representing {@link AllocationLoadStateType}. */
|
|
336
|
+
export type AllocationLoadStateType = typeof AllocationLoadStateType;
|
|
337
|
+
/**
|
|
338
|
+
* A resource's load on the plan day.
|
|
339
|
+
*
|
|
340
|
+
* @property resource - The resource's key
|
|
341
|
+
* @property fill - What its bins put on it
|
|
342
|
+
* @property bins - How many bins are on it, reservations included
|
|
343
|
+
* @property hold - From the plan day for its longest bin's hold (its own hold when it holds only reservations); `none` with no bins
|
|
344
|
+
* @property state - Free, loading or busy
|
|
345
|
+
*/
|
|
346
|
+
export declare const AllocationLoadType: StructType<{
|
|
347
|
+
readonly resource: StringType;
|
|
348
|
+
readonly fill: FloatType;
|
|
349
|
+
readonly bins: IntegerType;
|
|
350
|
+
readonly hold: OptionType<StructType<{
|
|
351
|
+
readonly from: DateTimeType;
|
|
352
|
+
readonly to: DateTimeType;
|
|
353
|
+
}>>;
|
|
354
|
+
readonly state: VariantType<{
|
|
355
|
+
readonly free: NullType;
|
|
356
|
+
readonly loading: NullType;
|
|
357
|
+
readonly busy: NullType;
|
|
358
|
+
}>;
|
|
359
|
+
}>;
|
|
360
|
+
/** Type representing {@link AllocationLoadType}. */
|
|
361
|
+
export type AllocationLoadType = typeof AllocationLoadType;
|
|
362
|
+
/**
|
|
363
|
+
* A resource's line on the plan day, as its row and its bins' cards show it
|
|
364
|
+
* (A16, A19).
|
|
365
|
+
*
|
|
366
|
+
* @property text - Its line: the load it holds (`11 m³ · max 9 · 2 over`, `reserved · takes 26–48`, with `· 1 d into next job`), `busy until Fri 14`, or what it is and takes when free (`Hall B · 40 m³ · takes 20–40 m³`)
|
|
367
|
+
* @property tone - `danger` over its maximum, `warning` overlapping its next job or under its minimum, else `neutral`
|
|
368
|
+
* @property over - Whether it holds more than its maximum
|
|
369
|
+
* @property under - Whether it holds something, but less than its minimum
|
|
370
|
+
* @property overlap - Whether its hold runs into its next job
|
|
371
|
+
* @property next - Its next job: where an overlap starts
|
|
372
|
+
*/
|
|
373
|
+
export declare const AllocationResourceLineType: StructType<{
|
|
374
|
+
readonly text: StringType;
|
|
375
|
+
readonly tone: VariantType<{
|
|
376
|
+
readonly success: NullType;
|
|
377
|
+
readonly warning: NullType;
|
|
378
|
+
readonly danger: NullType;
|
|
379
|
+
readonly info: NullType;
|
|
380
|
+
readonly neutral: NullType;
|
|
381
|
+
}>;
|
|
382
|
+
readonly over: BooleanType;
|
|
383
|
+
readonly under: BooleanType;
|
|
384
|
+
readonly overlap: BooleanType;
|
|
385
|
+
readonly next: OptionType<StructType<{
|
|
386
|
+
readonly label: StringType;
|
|
387
|
+
readonly start: DateTimeType;
|
|
388
|
+
readonly end: DateTimeType;
|
|
389
|
+
}>>;
|
|
390
|
+
}>;
|
|
391
|
+
/** Type representing {@link AllocationResourceLineType}. */
|
|
392
|
+
export type AllocationResourceLineType = typeof AllocationResourceLineType;
|
|
393
|
+
/**
|
|
394
|
+
* One quantity on one resource, against the drafted day: what a fit is asked
|
|
395
|
+
* about, one candidate at a time.
|
|
396
|
+
*
|
|
397
|
+
* @property day - The plan day
|
|
398
|
+
* @property bin - The bin it is for; `none` for an arrival not yet booked and for a new reservation
|
|
399
|
+
* @property reserve - Whether it reserves a slot (a reservation, or a bin booking no arrival): checked with no quantity, and refused when the resource is full
|
|
400
|
+
* @property quantity - What the resource would hold of it
|
|
401
|
+
* @property arrival - Its arrival, if it has one
|
|
402
|
+
* @property kind - Its kind
|
|
403
|
+
* @property resource - The resource
|
|
404
|
+
* @property load - The resource's load as the day stands
|
|
405
|
+
* @property after - What the resource would hold with it: the other bins' parts, and its quantity
|
|
406
|
+
* @property hold - From the plan day for the longer of its hold and the resource's other bins' holds
|
|
407
|
+
* @property spare - The days between the hold's end and the resource's next job; `none` with no next job
|
|
408
|
+
* @property kindMates - Whether a bin of its kind is already on the resource
|
|
409
|
+
* @property otherMates - Whether the resource holds other bins, none of its kind
|
|
410
|
+
* @property rules - The built-in rules
|
|
411
|
+
* @property unit - The quantity's unit
|
|
412
|
+
*/
|
|
413
|
+
export declare const AllocationCandidateType: StructType<{
|
|
414
|
+
readonly day: DateTimeType;
|
|
415
|
+
readonly bin: OptionType<StringType>;
|
|
416
|
+
readonly reserve: BooleanType;
|
|
417
|
+
readonly quantity: FloatType;
|
|
418
|
+
readonly arrival: OptionType<StructType<{
|
|
419
|
+
readonly key: StringType;
|
|
420
|
+
readonly label: StringType;
|
|
421
|
+
readonly meta: OptionType<StringType>;
|
|
422
|
+
readonly quantity: FloatType;
|
|
423
|
+
readonly hold: VariantType<{
|
|
424
|
+
readonly minutes: FloatType;
|
|
425
|
+
readonly hours: FloatType;
|
|
426
|
+
readonly days: FloatType;
|
|
427
|
+
readonly weeks: FloatType;
|
|
428
|
+
readonly months: FloatType;
|
|
429
|
+
}>;
|
|
430
|
+
readonly kind: OptionType<StringType>;
|
|
431
|
+
readonly due: OptionType<DateTimeType>;
|
|
432
|
+
readonly window: OptionType<StructType<{
|
|
433
|
+
readonly from: DateTimeType;
|
|
434
|
+
readonly to: DateTimeType;
|
|
435
|
+
}>>;
|
|
436
|
+
readonly details: ArrayType<StructType<{
|
|
437
|
+
readonly label: StringType;
|
|
438
|
+
readonly value: StringType;
|
|
439
|
+
}>>;
|
|
440
|
+
}>>;
|
|
441
|
+
readonly kind: OptionType<StringType>;
|
|
442
|
+
readonly resource: StructType<{
|
|
443
|
+
readonly key: StringType;
|
|
444
|
+
readonly label: StringType;
|
|
445
|
+
readonly group: OptionType<StringType>;
|
|
446
|
+
readonly meta: OptionType<StringType>;
|
|
447
|
+
readonly note: OptionType<StringType>;
|
|
448
|
+
readonly min: FloatType;
|
|
449
|
+
readonly max: FloatType;
|
|
450
|
+
readonly hold: VariantType<{
|
|
451
|
+
readonly minutes: FloatType;
|
|
452
|
+
readonly hours: FloatType;
|
|
453
|
+
readonly days: FloatType;
|
|
454
|
+
readonly weeks: FloatType;
|
|
455
|
+
readonly months: FloatType;
|
|
456
|
+
}>;
|
|
457
|
+
readonly jobs: ArrayType<StructType<{
|
|
458
|
+
readonly label: StringType;
|
|
459
|
+
readonly start: DateTimeType;
|
|
460
|
+
readonly end: DateTimeType;
|
|
461
|
+
}>>;
|
|
462
|
+
}>;
|
|
463
|
+
readonly load: StructType<{
|
|
464
|
+
readonly resource: StringType;
|
|
465
|
+
readonly fill: FloatType;
|
|
466
|
+
readonly bins: IntegerType;
|
|
467
|
+
readonly hold: OptionType<StructType<{
|
|
468
|
+
readonly from: DateTimeType;
|
|
469
|
+
readonly to: DateTimeType;
|
|
470
|
+
}>>;
|
|
471
|
+
readonly state: VariantType<{
|
|
472
|
+
readonly free: NullType;
|
|
473
|
+
readonly loading: NullType;
|
|
474
|
+
readonly busy: NullType;
|
|
475
|
+
}>;
|
|
476
|
+
}>;
|
|
477
|
+
readonly after: FloatType;
|
|
478
|
+
readonly hold: StructType<{
|
|
479
|
+
readonly from: DateTimeType;
|
|
480
|
+
readonly to: DateTimeType;
|
|
481
|
+
}>;
|
|
482
|
+
readonly spare: OptionType<FloatType>;
|
|
483
|
+
readonly kindMates: BooleanType;
|
|
484
|
+
readonly otherMates: BooleanType;
|
|
485
|
+
readonly rules: StructType<{
|
|
486
|
+
readonly under: BooleanType;
|
|
487
|
+
}>;
|
|
488
|
+
readonly unit: StringType;
|
|
489
|
+
}>;
|
|
490
|
+
/** Type representing {@link AllocationCandidateType}. */
|
|
491
|
+
export type AllocationCandidateType = typeof AllocationCandidateType;
|
|
492
|
+
/** Why something does not fit — Schedule's, shared with the Roster. */
|
|
493
|
+
export declare const AllocationRefusalType: StructType<{
|
|
494
|
+
readonly group: StringType;
|
|
495
|
+
readonly reason: StringType;
|
|
496
|
+
readonly measure: VariantType<{
|
|
497
|
+
readonly none: NullType;
|
|
498
|
+
readonly amount: StructType<{
|
|
499
|
+
readonly lead: StringType;
|
|
500
|
+
readonly value: FloatType;
|
|
501
|
+
}>;
|
|
502
|
+
readonly day: StructType<{
|
|
503
|
+
readonly lead: StringType;
|
|
504
|
+
readonly at: DateTimeType;
|
|
505
|
+
}>;
|
|
506
|
+
}>;
|
|
507
|
+
}>;
|
|
508
|
+
/** Type representing {@link AllocationRefusalType}. */
|
|
509
|
+
export type AllocationRefusalType = typeof AllocationRefusalType;
|
|
510
|
+
/** One verdict of a fit — Schedule's, shared with the Roster. */
|
|
511
|
+
export declare const AllocationFitType: VariantType<{
|
|
512
|
+
readonly fits: StructType<{
|
|
513
|
+
readonly score: FloatType;
|
|
514
|
+
readonly why: StringType;
|
|
515
|
+
readonly warn: OptionType<StringType>;
|
|
516
|
+
}>;
|
|
517
|
+
readonly refused: StructType<{
|
|
518
|
+
readonly group: StringType;
|
|
519
|
+
readonly reason: StringType;
|
|
520
|
+
readonly measure: VariantType<{
|
|
521
|
+
readonly none: NullType;
|
|
522
|
+
readonly amount: StructType<{
|
|
523
|
+
readonly lead: StringType;
|
|
524
|
+
readonly value: FloatType;
|
|
525
|
+
}>;
|
|
526
|
+
readonly day: StructType<{
|
|
527
|
+
readonly lead: StringType;
|
|
528
|
+
readonly at: DateTimeType;
|
|
529
|
+
}>;
|
|
530
|
+
}>;
|
|
531
|
+
}>;
|
|
532
|
+
}>;
|
|
533
|
+
/** Type representing {@link AllocationFitType}. */
|
|
534
|
+
export type AllocationFitType = typeof AllocationFitType;
|
|
535
|
+
/**
|
|
536
|
+
* The question a fit answers.
|
|
537
|
+
*
|
|
538
|
+
* @property place - Where can this subject — a bin, or an arrival — go with this quantity: a verdict per resource
|
|
539
|
+
* @property take - What can this resource take: a verdict per bin, one per arrival the day has not booked, and one for reserving an empty slot on it
|
|
540
|
+
*/
|
|
541
|
+
export declare const AllocationFitAskType: VariantType<{
|
|
542
|
+
readonly place: StructType<{
|
|
543
|
+
readonly subject: VariantType<{
|
|
544
|
+
readonly bin: StringType;
|
|
545
|
+
readonly arrival: StringType;
|
|
546
|
+
}>;
|
|
547
|
+
readonly quantity: FloatType;
|
|
548
|
+
}>;
|
|
549
|
+
readonly take: StructType<{
|
|
550
|
+
readonly resource: StringType;
|
|
551
|
+
}>;
|
|
552
|
+
}>;
|
|
553
|
+
/** Type representing {@link AllocationFitAskType}. */
|
|
554
|
+
export type AllocationFitAskType = typeof AllocationFitAskType;
|
|
555
|
+
/** A fit's request over the app's bin row type `R` — what {@link AllocationFitRequestTypeFor} constructs. */
|
|
556
|
+
export type AllocationFitRequestType<R extends EastType> = StructType<{
|
|
557
|
+
day: DateTimeType;
|
|
558
|
+
plan: AllocationDayType<R>;
|
|
559
|
+
ask: AllocationFitAskType;
|
|
560
|
+
context: AllocationContextType;
|
|
561
|
+
}>;
|
|
562
|
+
/**
|
|
563
|
+
* One question to the app's fit, about the drafted day.
|
|
564
|
+
*
|
|
565
|
+
* @typeParam R - The app's bin row type
|
|
566
|
+
* @param row - The app's bin row type
|
|
567
|
+
* @returns `StructType({ day, plan, ask, context })`
|
|
568
|
+
*
|
|
569
|
+
* @property day - The plan day
|
|
570
|
+
* @property plan - The day as drafted: each bin its roles and its own row
|
|
571
|
+
* @property ask - The question
|
|
572
|
+
* @property context - Every arrival and resource, and the board's configuration
|
|
573
|
+
*/
|
|
574
|
+
export declare function AllocationFitRequestTypeFor<R extends EastType>(row: R): AllocationFitRequestType<R>;
|
|
575
|
+
/**
|
|
576
|
+
* A fit's answer. It echoes its question, so the board matches each answer to
|
|
577
|
+
* the question it asked.
|
|
578
|
+
*
|
|
579
|
+
* @property ask - The question answered
|
|
580
|
+
* @property resources - A place's verdicts, by resource
|
|
581
|
+
* @property bins - A take's verdicts, by bin
|
|
582
|
+
* @property arrivals - A take's verdicts for booking each arrival the day has not booked onto the resource, by arrival (the Table's arrival Chooser, a reservation's Book list)
|
|
583
|
+
* @property reserve - A take's verdict for reserving an empty slot
|
|
584
|
+
* @property basis - How the fits are ranked, in words (`ranked by load, kind and spare days`)
|
|
585
|
+
*/
|
|
586
|
+
export declare const AllocationFitResultType: StructType<{
|
|
587
|
+
readonly ask: VariantType<{
|
|
588
|
+
readonly place: StructType<{
|
|
589
|
+
readonly subject: VariantType<{
|
|
590
|
+
readonly bin: StringType;
|
|
591
|
+
readonly arrival: StringType;
|
|
592
|
+
}>;
|
|
593
|
+
readonly quantity: FloatType;
|
|
594
|
+
}>;
|
|
595
|
+
readonly take: StructType<{
|
|
596
|
+
readonly resource: StringType;
|
|
597
|
+
}>;
|
|
598
|
+
}>;
|
|
599
|
+
readonly resources: DictType<StringType, VariantType<{
|
|
600
|
+
readonly fits: StructType<{
|
|
601
|
+
readonly score: FloatType;
|
|
602
|
+
readonly why: StringType;
|
|
603
|
+
readonly warn: OptionType<StringType>;
|
|
604
|
+
}>;
|
|
605
|
+
readonly refused: StructType<{
|
|
606
|
+
readonly group: StringType;
|
|
607
|
+
readonly reason: StringType;
|
|
608
|
+
readonly measure: VariantType<{
|
|
609
|
+
readonly none: NullType;
|
|
610
|
+
readonly amount: StructType<{
|
|
611
|
+
readonly lead: StringType;
|
|
612
|
+
readonly value: FloatType;
|
|
613
|
+
}>;
|
|
614
|
+
readonly day: StructType<{
|
|
615
|
+
readonly lead: StringType;
|
|
616
|
+
readonly at: DateTimeType;
|
|
617
|
+
}>;
|
|
618
|
+
}>;
|
|
619
|
+
}>;
|
|
620
|
+
}>>;
|
|
621
|
+
readonly bins: DictType<StringType, VariantType<{
|
|
622
|
+
readonly fits: StructType<{
|
|
623
|
+
readonly score: FloatType;
|
|
624
|
+
readonly why: StringType;
|
|
625
|
+
readonly warn: OptionType<StringType>;
|
|
626
|
+
}>;
|
|
627
|
+
readonly refused: StructType<{
|
|
628
|
+
readonly group: StringType;
|
|
629
|
+
readonly reason: StringType;
|
|
630
|
+
readonly measure: VariantType<{
|
|
631
|
+
readonly none: NullType;
|
|
632
|
+
readonly amount: StructType<{
|
|
633
|
+
readonly lead: StringType;
|
|
634
|
+
readonly value: FloatType;
|
|
635
|
+
}>;
|
|
636
|
+
readonly day: StructType<{
|
|
637
|
+
readonly lead: StringType;
|
|
638
|
+
readonly at: DateTimeType;
|
|
639
|
+
}>;
|
|
640
|
+
}>;
|
|
641
|
+
}>;
|
|
642
|
+
}>>;
|
|
643
|
+
readonly arrivals: DictType<StringType, VariantType<{
|
|
644
|
+
readonly fits: StructType<{
|
|
645
|
+
readonly score: FloatType;
|
|
646
|
+
readonly why: StringType;
|
|
647
|
+
readonly warn: OptionType<StringType>;
|
|
648
|
+
}>;
|
|
649
|
+
readonly refused: StructType<{
|
|
650
|
+
readonly group: StringType;
|
|
651
|
+
readonly reason: StringType;
|
|
652
|
+
readonly measure: VariantType<{
|
|
653
|
+
readonly none: NullType;
|
|
654
|
+
readonly amount: StructType<{
|
|
655
|
+
readonly lead: StringType;
|
|
656
|
+
readonly value: FloatType;
|
|
657
|
+
}>;
|
|
658
|
+
readonly day: StructType<{
|
|
659
|
+
readonly lead: StringType;
|
|
660
|
+
readonly at: DateTimeType;
|
|
661
|
+
}>;
|
|
662
|
+
}>;
|
|
663
|
+
}>;
|
|
664
|
+
}>>;
|
|
665
|
+
readonly reserve: OptionType<VariantType<{
|
|
666
|
+
readonly fits: StructType<{
|
|
667
|
+
readonly score: FloatType;
|
|
668
|
+
readonly why: StringType;
|
|
669
|
+
readonly warn: OptionType<StringType>;
|
|
670
|
+
}>;
|
|
671
|
+
readonly refused: StructType<{
|
|
672
|
+
readonly group: StringType;
|
|
673
|
+
readonly reason: StringType;
|
|
674
|
+
readonly measure: VariantType<{
|
|
675
|
+
readonly none: NullType;
|
|
676
|
+
readonly amount: StructType<{
|
|
677
|
+
readonly lead: StringType;
|
|
678
|
+
readonly value: FloatType;
|
|
679
|
+
}>;
|
|
680
|
+
readonly day: StructType<{
|
|
681
|
+
readonly lead: StringType;
|
|
682
|
+
readonly at: DateTimeType;
|
|
683
|
+
}>;
|
|
684
|
+
}>;
|
|
685
|
+
}>;
|
|
686
|
+
}>>;
|
|
687
|
+
readonly basis: StringType;
|
|
688
|
+
}>;
|
|
689
|
+
/** Type representing {@link AllocationFitResultType}. */
|
|
690
|
+
export type AllocationFitResultType = typeof AllocationFitResultType;
|
|
691
|
+
/**
|
|
692
|
+
* An issue's fix.
|
|
693
|
+
*
|
|
694
|
+
* @property choose - Choose a resource for the bin
|
|
695
|
+
* @property move - Open this bin's resource choices (`Move LD-2205…`)
|
|
696
|
+
* @property find - Find a fit for the bin's unallocated quantity
|
|
697
|
+
*/
|
|
698
|
+
export declare const AllocationFixType: VariantType<{
|
|
699
|
+
readonly choose: NullType;
|
|
700
|
+
readonly move: StringType;
|
|
701
|
+
readonly find: NullType;
|
|
702
|
+
}>;
|
|
703
|
+
/** Type representing {@link AllocationFixType}. */
|
|
704
|
+
export type AllocationFixType = typeof AllocationFixType;
|
|
705
|
+
/**
|
|
706
|
+
* What an issue is about.
|
|
707
|
+
*
|
|
708
|
+
* @property unlinked - A bin with no resource
|
|
709
|
+
* @property unallocated - A bin whose parts leave some of it unallocated
|
|
710
|
+
* @property over - A resource over its maximum
|
|
711
|
+
* @property under - A resource under its minimum
|
|
712
|
+
* @property overlap - A resource whose hold runs into its next job
|
|
713
|
+
* @property custom - One of the app's, by its group's name (`Spec mismatch`)
|
|
714
|
+
*/
|
|
715
|
+
export declare const AllocationIssueKindType: VariantType<{
|
|
716
|
+
readonly unlinked: NullType;
|
|
717
|
+
readonly unallocated: NullType;
|
|
718
|
+
readonly over: NullType;
|
|
719
|
+
readonly under: NullType;
|
|
720
|
+
readonly overlap: NullType;
|
|
721
|
+
readonly custom: StringType;
|
|
722
|
+
}>;
|
|
723
|
+
/** Type representing {@link AllocationIssueKindType}. */
|
|
724
|
+
export type AllocationIssueKindType = typeof AllocationIssueKindType;
|
|
725
|
+
/**
|
|
726
|
+
* One warning about the drafted day. Issues never block Save or Publish.
|
|
727
|
+
*
|
|
728
|
+
* @property kind - What it is about
|
|
729
|
+
* @property tone - Its tone; warning and danger issues are counted, neutral and info ones listed only
|
|
730
|
+
* @property title - Its title (`K-207`)
|
|
731
|
+
* @property detail - Its detail (`44 m³ · max 40 · 4 over · over max`)
|
|
732
|
+
* @property bin - The bin it is about, if any
|
|
733
|
+
* @property resource - The resource it is about, if any
|
|
734
|
+
* @property flag - A bin card's short mark (`≠ spec`)
|
|
735
|
+
* @property fix - Its fix
|
|
736
|
+
*/
|
|
737
|
+
export declare const AllocationIssueType: StructType<{
|
|
738
|
+
readonly kind: VariantType<{
|
|
739
|
+
readonly unlinked: NullType;
|
|
740
|
+
readonly unallocated: NullType;
|
|
741
|
+
readonly over: NullType;
|
|
742
|
+
readonly under: NullType;
|
|
743
|
+
readonly overlap: NullType;
|
|
744
|
+
readonly custom: StringType;
|
|
745
|
+
}>;
|
|
746
|
+
readonly tone: VariantType<{
|
|
747
|
+
readonly success: NullType;
|
|
748
|
+
readonly warning: NullType;
|
|
749
|
+
readonly danger: NullType;
|
|
750
|
+
readonly info: NullType;
|
|
751
|
+
readonly neutral: NullType;
|
|
752
|
+
}>;
|
|
753
|
+
readonly title: StringType;
|
|
754
|
+
readonly detail: StringType;
|
|
755
|
+
readonly bin: OptionType<StringType>;
|
|
756
|
+
readonly resource: OptionType<StringType>;
|
|
757
|
+
readonly flag: OptionType<StringType>;
|
|
758
|
+
readonly fix: OptionType<VariantType<{
|
|
759
|
+
readonly choose: NullType;
|
|
760
|
+
readonly move: StringType;
|
|
761
|
+
readonly find: NullType;
|
|
762
|
+
}>>;
|
|
763
|
+
}>;
|
|
764
|
+
/** Type representing {@link AllocationIssueType}. */
|
|
765
|
+
export type AllocationIssueType = typeof AllocationIssueType;
|
|
766
|
+
/** The app's check's input over the app's bin row type `R` — what {@link AllocationCheckContextTypeFor} constructs. */
|
|
767
|
+
export type AllocationCheckContextType<R extends EastType> = StructType<{
|
|
768
|
+
day: DateTimeType;
|
|
769
|
+
plan: AllocationDayType<R>;
|
|
770
|
+
context: AllocationContextType;
|
|
771
|
+
loads: DictType<StringType, AllocationLoadType>;
|
|
772
|
+
}>;
|
|
773
|
+
/**
|
|
774
|
+
* What the app's `check` is given: the drafted day and every load.
|
|
775
|
+
*
|
|
776
|
+
* @typeParam R - The app's bin row type
|
|
777
|
+
* @param row - The app's bin row type
|
|
778
|
+
* @returns `StructType({ day, plan, context, loads })`
|
|
779
|
+
*
|
|
780
|
+
* @property day - The plan day
|
|
781
|
+
* @property plan - The day as drafted: each bin its roles and its own row, which the app's check reads
|
|
782
|
+
* @property context - Every arrival and resource
|
|
783
|
+
* @property loads - Every resource's load, by key
|
|
784
|
+
*/
|
|
785
|
+
export declare function AllocationCheckContextTypeFor<R extends EastType>(row: R): AllocationCheckContextType<R>;
|
|
786
|
+
/**
|
|
787
|
+
* A slot's state.
|
|
788
|
+
*
|
|
789
|
+
* @property free - No bin is in it
|
|
790
|
+
* @property booked - A bin booking an arrival is in it
|
|
791
|
+
* @property reserved - Only reservations are in it
|
|
792
|
+
*/
|
|
793
|
+
export declare const AllocationSlotStatusType: VariantType<{
|
|
794
|
+
readonly free: NullType;
|
|
795
|
+
readonly booked: NullType;
|
|
796
|
+
readonly reserved: NullType;
|
|
797
|
+
}>;
|
|
798
|
+
/** Type representing {@link AllocationSlotStatusType}. */
|
|
799
|
+
export type AllocationSlotStatusType = typeof AllocationSlotStatusType;
|
|
800
|
+
/**
|
|
801
|
+
* One lane slot of the plan day: a Table's row, or one per bin of its batch.
|
|
802
|
+
*
|
|
803
|
+
* @property lane - Its lane's key
|
|
804
|
+
* @property at - Its time: the slot's start and its lane's offset
|
|
805
|
+
* @property status - Free, booked or reserved
|
|
806
|
+
* @property bins - Its bins, by time
|
|
807
|
+
*/
|
|
808
|
+
export declare const AllocationSlotType: StructType<{
|
|
809
|
+
readonly lane: StringType;
|
|
810
|
+
readonly at: DateTimeType;
|
|
811
|
+
readonly status: VariantType<{
|
|
812
|
+
readonly free: NullType;
|
|
813
|
+
readonly booked: NullType;
|
|
814
|
+
readonly reserved: NullType;
|
|
815
|
+
}>;
|
|
816
|
+
readonly bins: ArrayType<StringType>;
|
|
817
|
+
}>;
|
|
818
|
+
/** Type representing {@link AllocationSlotType}. */
|
|
819
|
+
export type AllocationSlotType = typeof AllocationSlotType;
|
|
820
|
+
/**
|
|
821
|
+
* The board's layout.
|
|
822
|
+
*
|
|
823
|
+
* @property timeline - Lanes, links and resources
|
|
824
|
+
* @property table - One row per slot
|
|
825
|
+
*/
|
|
826
|
+
export declare const AllocationLayoutType: VariantType<{
|
|
827
|
+
readonly timeline: NullType;
|
|
828
|
+
readonly table: NullType;
|
|
829
|
+
}>;
|
|
830
|
+
/** Type representing {@link AllocationLayoutType}. */
|
|
831
|
+
export type AllocationLayoutType = typeof AllocationLayoutType;
|
|
832
|
+
//# sourceMappingURL=types.d.ts.map
|