@things-factory/work-shift 10.1.202 → 10.1.205

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.
@@ -1,31 +1,105 @@
1
+ import '@operato/input/ox-input-select-buttons.js';
2
+ import '@operato/list-state/ox-list-state.js';
3
+ import '@operato/list-state/ox-page-state.js';
1
4
  import { PageView } from '@operato/shell';
2
- export declare class WorkShift extends PageView {
5
+ declare const WorkShift_base: (new (...args: any[]) => import("lit").LitElement) & typeof PageView;
6
+ /**
7
+ * 근무 교대 — the shift arrangement in force, what is about to change, and what it was before.
8
+ *
9
+ * One arrangement is in force at a time. Changing it means writing a whole new arrangement with a reason and
10
+ * the moment it takes effect; where the site requires approval, the change goes through ops-master's approval
11
+ * and takes effect once approved. Work already recorded keeps the shift it was recorded under.
12
+ *
13
+ * The rules this screen applies - weekday groups, the end day of a shift, what blocks a save, where each
14
+ * revision belongs - live in shift-editing.ts, shift-revisions.ts and shift-coverage.ts, with tests.
15
+ */
16
+ export declare class WorkShift extends WorkShift_base {
3
17
  static styles: import("lit").CSSResult[];
4
18
  private overview;
5
- private draft;
6
- private message;
7
- private busy;
8
- private statuses;
19
+ private loading;
20
+ private error;
21
+ private approvals;
22
+ private draft?;
9
23
  private dirty;
10
- get context(): any;
11
- pageUpdated(): Promise<void>;
12
- private current;
13
- private run;
24
+ private busy;
25
+ private saveError;
26
+ /** A save was tried: from then on every blocking problem is shown, not only the ones a person touched. */
27
+ private tried;
28
+ private opened?;
29
+ get context(): {
30
+ title: string;
31
+ frame: string;
32
+ help: string;
33
+ actions: {
34
+ title: string;
35
+ icon: string;
36
+ emphasis: {
37
+ raised: boolean;
38
+ };
39
+ action: () => void;
40
+ }[] | ({
41
+ title: string;
42
+ action: () => Promise<void>;
43
+ icon?: undefined;
44
+ emphasis?: undefined;
45
+ } | {
46
+ title: string;
47
+ action: () => Promise<boolean>;
48
+ icon?: undefined;
49
+ emphasis?: undefined;
50
+ } | {
51
+ title: string;
52
+ icon: string;
53
+ emphasis: {
54
+ raised: boolean;
55
+ };
56
+ action: () => Promise<void>;
57
+ })[];
58
+ };
59
+ private actions;
60
+ pageUpdated(changes: any): Promise<void>;
14
61
  private load;
62
+ /** Approval states come from ops-master's approval flow, one revision at a time. */
63
+ private readApprovals;
64
+ private get placed();
15
65
  private begin;
66
+ private resume;
67
+ private enterEditor;
68
+ private close;
16
69
  private change;
17
70
  private changeShift;
18
- private save;
19
- private submit;
20
- private rowStatus;
21
- private weekdays;
22
- private timeLabel;
23
- private band;
24
- private problemText;
25
- private weekGroups;
26
- private weekLabel;
27
- private historyBands;
28
- private coverage;
29
- private shiftEditor;
71
+ private content;
72
+ private run;
73
+ private mutate;
74
+ /** Saves the editor as a draft and keeps it open. Returns false when it did not save. */
75
+ private saveDraft;
76
+ /** Puts the change into effect, or asks for approval where the site requires it. */
77
+ private commit;
78
+ private dayWord;
79
+ private clock;
80
+ private span;
81
+ private hours;
82
+ private daysText;
83
+ private bar;
84
+ /**
85
+ * The day bars of an arrangement, one per group of weekdays that run the same shifts, and what is wrong with them.
86
+ * The editor passes the week's overlaps: they include a Friday night running into Saturday, which no single
87
+ * day's bar shows, and the server refuses every one of them.
88
+ */
89
+ private timeline;
90
+ private shiftTable;
91
+ private shiftLines;
92
+ private stateTag;
93
+ private period;
94
+ private viewCurrent;
95
+ private viewScheduled;
96
+ /** A person's reason as written; the recorded first arrangement in plain words, with where it came from. */
97
+ private reasonCell;
98
+ private viewOpen;
99
+ private viewHistory;
100
+ private issueText;
101
+ private shiftRow;
102
+ private editor;
30
103
  render(): import("lit-html").TemplateResult<1>;
31
104
  }
105
+ export {};