@cratis/scene.blueprint.hr 4.53.1 → 4.56.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/blueprintCatalog.json +16 -0
- package/dist/cjs/hrParts.js.map +1 -1
- package/dist/cjs/hrQueries.js +3 -0
- package/dist/cjs/hrQueries.js.map +1 -1
- package/dist/cjs/hrScreenSet.js +7 -0
- package/dist/cjs/hrScreenSet.js.map +1 -1
- package/dist/cjs/index.js +2 -0
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/navigation.js +9 -1
- package/dist/cjs/navigation.js.map +1 -1
- package/dist/cjs/templates/index.js +3 -0
- package/dist/cjs/templates/index.js.map +1 -1
- package/dist/cjs/templates/teamCalendarTemplate.js +99 -0
- package/dist/cjs/templates/teamCalendarTemplate.js.map +1 -0
- package/dist/esm/hrParts.d.ts +1 -1
- package/dist/esm/hrParts.d.ts.map +1 -1
- package/dist/esm/hrParts.js.map +1 -1
- package/dist/esm/hrQueries.d.ts +3 -0
- package/dist/esm/hrQueries.d.ts.map +1 -1
- package/dist/esm/hrQueries.js +3 -0
- package/dist/esm/hrQueries.js.map +1 -1
- package/dist/esm/hrScreenSet.d.ts.map +1 -1
- package/dist/esm/hrScreenSet.js +7 -0
- package/dist/esm/hrScreenSet.js.map +1 -1
- package/dist/esm/index.js +1 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/navigation.d.ts.map +1 -1
- package/dist/esm/navigation.js +9 -1
- package/dist/esm/navigation.js.map +1 -1
- package/dist/esm/templates/index.d.ts +1 -0
- package/dist/esm/templates/index.d.ts.map +1 -1
- package/dist/esm/templates/index.js +3 -1
- package/dist/esm/templates/index.js.map +1 -1
- package/dist/esm/templates/teamCalendarTemplate.d.ts +3 -0
- package/dist/esm/templates/teamCalendarTemplate.d.ts.map +1 -0
- package/dist/esm/templates/teamCalendarTemplate.js +97 -0
- package/dist/esm/templates/teamCalendarTemplate.js.map +1 -0
- package/dist/esm/tsconfig.tsbuildinfo +1 -1
- package/hrParts.ts +1 -1
- package/hrQueries.ts +3 -0
- package/hrScreenSet.ts +1 -0
- package/navigation.ts +2 -1
- package/package.json +10 -10
- package/sampleData/hr-nordic.json +150 -1
- package/templates/index.ts +3 -1
- package/templates/teamCalendarTemplate.ts +33 -0
- package/thumbnails/HrTeamCalendar.svg +16 -0
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export * from './listTemplates';
|
|
2
2
|
export * from './recordTemplates';
|
|
3
3
|
export * from './orgChartTemplate';
|
|
4
|
+
export * from './teamCalendarTemplate';
|
|
4
5
|
export * from './formTemplates';
|
|
5
6
|
export declare const hrScreenTemplates: import("@cratis/scene.model/screens").ScreenTemplate[];
|
|
6
7
|
export { hrQuickCreateDialogs as hrDialogTemplates } from './formTemplates';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../templates/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../templates/index.ts"],"names":[],"mappings":"AAQA,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,oBAAoB,CAAC;AACnC,cAAc,wBAAwB,CAAC;AACvC,cAAc,iBAAiB,CAAC;AAGhC,eAAO,MAAM,iBAAiB,wDAK7B,CAAC;AAEF,OAAO,EAAE,oBAAoB,IAAI,iBAAiB,EAAE,MAAM,iBAAiB,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { hrEmployeeDirectoryTemplate, hrTimeOffListTemplate, hrTimeOffBalanceListTemplate, hrOnboardingListTemplate } from './listTemplates.js';
|
|
2
2
|
import { hrOrgChartTemplate } from './orgChartTemplate.js';
|
|
3
|
+
import { hrTeamCalendarTemplate } from './teamCalendarTemplate.js';
|
|
3
4
|
import { hrEmployeePageTemplate, hrOnboardingChecklistTemplate } from './recordTemplates.js';
|
|
4
5
|
export { hrQuickCreateDialogs as hrDialogTemplates, hrQuickCreateDialogs } from './formTemplates.js';
|
|
5
6
|
|
|
@@ -11,9 +12,10 @@ export { hrQuickCreateDialogs as hrDialogTemplates, hrQuickCreateDialogs } from
|
|
|
11
12
|
hrOrgChartTemplate,
|
|
12
13
|
hrTimeOffListTemplate,
|
|
13
14
|
hrTimeOffBalanceListTemplate,
|
|
15
|
+
hrTeamCalendarTemplate,
|
|
14
16
|
hrOnboardingListTemplate,
|
|
15
17
|
hrOnboardingChecklistTemplate
|
|
16
18
|
];
|
|
17
19
|
|
|
18
|
-
export { hrEmployeeDirectoryTemplate, hrEmployeePageTemplate, hrOnboardingChecklistTemplate, hrOnboardingListTemplate, hrOrgChartTemplate, hrScreenTemplates, hrTimeOffBalanceListTemplate, hrTimeOffListTemplate };
|
|
20
|
+
export { hrEmployeeDirectoryTemplate, hrEmployeePageTemplate, hrOnboardingChecklistTemplate, hrOnboardingListTemplate, hrOrgChartTemplate, hrScreenTemplates, hrTeamCalendarTemplate, hrTimeOffBalanceListTemplate, hrTimeOffListTemplate };
|
|
19
21
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../templates/index.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { hrEmployeeDirectoryTemplate, hrOnboardingListTemplate, hrTimeOffBalanceListTemplate, hrTimeOffListTemplate } from './listTemplates';\nimport { hrOrgChartTemplate } from './orgChartTemplate';\nimport { hrEmployeePageTemplate, hrOnboardingChecklistTemplate } from './recordTemplates';\n\nexport * from './listTemplates';\nexport * from './recordTemplates';\nexport * from './orgChartTemplate';\nexport * from './formTemplates';\n\n/** Every screen template this blueprint provides, in the order the manifest lists them. */\nexport const hrScreenTemplates = [\n hrEmployeeDirectoryTemplate, hrEmployeePageTemplate,\n hrOrgChartTemplate,\n hrTimeOffListTemplate, hrTimeOffBalanceListTemplate,\n hrOnboardingListTemplate, hrOnboardingChecklistTemplate,\n];\n\nexport { hrQuickCreateDialogs as hrDialogTemplates } from './formTemplates';\n"],"names":["hrScreenTemplates","hrEmployeeDirectoryTemplate","hrEmployeePageTemplate","hrOrgChartTemplate","hrTimeOffListTemplate","hrTimeOffBalanceListTemplate","hrOnboardingListTemplate","hrOnboardingChecklistTemplate"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../templates/index.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { hrEmployeeDirectoryTemplate, hrOnboardingListTemplate, hrTimeOffBalanceListTemplate, hrTimeOffListTemplate } from './listTemplates';\nimport { hrOrgChartTemplate } from './orgChartTemplate';\nimport { hrTeamCalendarTemplate } from './teamCalendarTemplate';\nimport { hrEmployeePageTemplate, hrOnboardingChecklistTemplate } from './recordTemplates';\n\nexport * from './listTemplates';\nexport * from './recordTemplates';\nexport * from './orgChartTemplate';\nexport * from './teamCalendarTemplate';\nexport * from './formTemplates';\n\n/** Every screen template this blueprint provides, in the order the manifest lists them. */\nexport const hrScreenTemplates = [\n hrEmployeeDirectoryTemplate, hrEmployeePageTemplate,\n hrOrgChartTemplate,\n hrTimeOffListTemplate, hrTimeOffBalanceListTemplate, hrTeamCalendarTemplate,\n hrOnboardingListTemplate, hrOnboardingChecklistTemplate,\n];\n\nexport { hrQuickCreateDialogs as hrDialogTemplates } from './formTemplates';\n"],"names":["hrScreenTemplates","hrEmployeeDirectoryTemplate","hrEmployeePageTemplate","hrOrgChartTemplate","hrTimeOffListTemplate","hrTimeOffBalanceListTemplate","hrTeamCalendarTemplate","hrOnboardingListTemplate","hrOnboardingChecklistTemplate"],"mappings":";;;;;;AAAA;AACA;AAaA,4FACO,MAAMA,iBAAAA,GAAoB;AAC7BC,IAAAA,2BAAAA;AAA6BC,IAAAA,sBAAAA;AAC7BC,IAAAA,kBAAAA;AACAC,IAAAA,qBAAAA;AAAuBC,IAAAA,4BAAAA;AAA8BC,IAAAA,sBAAAA;AACrDC,IAAAA,wBAAAA;AAA0BC,IAAAA;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"teamCalendarTemplate.d.ts","sourceRoot":"","sources":["../../../templates/teamCalendarTemplate.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAiC,MAAM,qBAAqB,CAAC;AAUpF,eAAO,MAAM,sBAAsB,EAAE,cAmBpC,CAAC"}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import { TemplateScope, WidthSizeClass } from '@cratis/scene.model';
|
|
2
|
+
import { component, column, slotLeaf, grid } from '@cratis/scene.blueprint.default';
|
|
3
|
+
import { localeOfData, fromQuery, HrQuery } from '../hrQueries.js';
|
|
4
|
+
import { hrMetadata, withBehaviors, opensDialog, actionButton } from '../hrParts.js';
|
|
5
|
+
|
|
6
|
+
// Copyright (c) Cratis. All rights reserved.
|
|
7
|
+
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
|
8
|
+
/**
|
|
9
|
+
* The team calendar: who is away and when, on a month, a week or as an agenda (the foundation's `calendarGrid`). A request spans the days it asks for, the kind of
|
|
10
|
+
* leave is told in words as well as by color, and the day and view are kept in the address, so a link shares the calendar as it is. A filter narrows it to a person
|
|
11
|
+
* or a kind of leave, and the list beside it names everyone away in the period.
|
|
12
|
+
*/ const hrTeamCalendarTemplate = {
|
|
13
|
+
name: 'HrTeamCalendar',
|
|
14
|
+
fitsSlot: 'content',
|
|
15
|
+
slots: [
|
|
16
|
+
{
|
|
17
|
+
name: 'header'
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
name: 'filters'
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
name: 'calendar'
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
name: 'away'
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
arrangement: {
|
|
30
|
+
root: column([
|
|
31
|
+
slotLeaf('header'),
|
|
32
|
+
slotLeaf('filters'),
|
|
33
|
+
grid([
|
|
34
|
+
slotLeaf('calendar', {
|
|
35
|
+
span: 2
|
|
36
|
+
}),
|
|
37
|
+
slotLeaf('away')
|
|
38
|
+
], 3, 16)
|
|
39
|
+
], 16),
|
|
40
|
+
overrides: [
|
|
41
|
+
{
|
|
42
|
+
width: WidthSizeClass.Compact,
|
|
43
|
+
root: column([
|
|
44
|
+
slotLeaf('header'),
|
|
45
|
+
slotLeaf('filters'),
|
|
46
|
+
slotLeaf('calendar'),
|
|
47
|
+
slotLeaf('away')
|
|
48
|
+
], 16)
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
},
|
|
52
|
+
content: {
|
|
53
|
+
header: [
|
|
54
|
+
component('HrTeamCalendar-header', 'pageHeader', {
|
|
55
|
+
title: 'Team calendar',
|
|
56
|
+
subtitle: 'Who is away and when'
|
|
57
|
+
}, {
|
|
58
|
+
actions: [
|
|
59
|
+
withBehaviors(actionButton('HrTeamCalendar-request', 'Request time off', 'primary'), opensDialog('HrRequestTimeOff'))
|
|
60
|
+
]
|
|
61
|
+
})
|
|
62
|
+
],
|
|
63
|
+
filters: [
|
|
64
|
+
component('HrTeamCalendar-filter', 'filterBuilder', {
|
|
65
|
+
fields: fromQuery(HrQuery.TeamCalendarFilterFields)
|
|
66
|
+
})
|
|
67
|
+
],
|
|
68
|
+
calendar: [
|
|
69
|
+
component('HrTeamCalendar-grid', 'calendarGrid', {
|
|
70
|
+
label: 'Team calendar',
|
|
71
|
+
events: fromQuery(HrQuery.TeamCalendarEvents),
|
|
72
|
+
date: fromQuery(HrQuery.Settings, '0.calendarDay'),
|
|
73
|
+
urlKey: 'day',
|
|
74
|
+
...localeOfData
|
|
75
|
+
})
|
|
76
|
+
],
|
|
77
|
+
away: [
|
|
78
|
+
component('HrTeamCalendar-away', 'dataList', {
|
|
79
|
+
label: 'Away in this period',
|
|
80
|
+
rows: fromQuery(HrQuery.TeamCalendarEvents),
|
|
81
|
+
columns: fromQuery(HrQuery.TeamCalendarColumns),
|
|
82
|
+
titleField: 'person',
|
|
83
|
+
pageSize: 6,
|
|
84
|
+
...localeOfData
|
|
85
|
+
})
|
|
86
|
+
]
|
|
87
|
+
},
|
|
88
|
+
displayName: 'HR team calendar',
|
|
89
|
+
description: 'Who is away and when, on a month, a week or as an agenda, with the kind of leave told in words.',
|
|
90
|
+
metadata: hrMetadata('HrTeamCalendar', 'Calendar', [
|
|
91
|
+
TemplateScope.Module,
|
|
92
|
+
TemplateScope.Feature
|
|
93
|
+
])
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
export { hrTeamCalendarTemplate };
|
|
97
|
+
//# sourceMappingURL=teamCalendarTemplate.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"teamCalendarTemplate.js","sources":["../../../templates/teamCalendarTemplate.ts"],"sourcesContent":["// Copyright (c) Cratis. All rights reserved.\n// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n\nimport { ScreenTemplate, TemplateScope, WidthSizeClass } from '@cratis/scene.model';\nimport { column, grid, slotLeaf } from '@cratis/scene.blueprint.default';\nimport { HrQuery, fromQuery, localeOfData } from '../hrQueries';\nimport { actionButton, component, hrMetadata, opensDialog, withBehaviors } from '../hrParts';\n\n/**\n * The team calendar: who is away and when, on a month, a week or as an agenda (the foundation's `calendarGrid`). A request spans the days it asks for, the kind of\n * leave is told in words as well as by color, and the day and view are kept in the address, so a link shares the calendar as it is. A filter narrows it to a person\n * or a kind of leave, and the list beside it names everyone away in the period.\n */\nexport const hrTeamCalendarTemplate: ScreenTemplate = {\n name: 'HrTeamCalendar',\n fitsSlot: 'content',\n slots: [{ name: 'header' }, { name: 'filters' }, { name: 'calendar' }, { name: 'away' }],\n arrangement: {\n root: column([slotLeaf('header'), slotLeaf('filters'), grid([slotLeaf('calendar', { span: 2 }), slotLeaf('away')], 3, 16)], 16),\n overrides: [{ width: WidthSizeClass.Compact, root: column([slotLeaf('header'), slotLeaf('filters'), slotLeaf('calendar'), slotLeaf('away')], 16) }],\n },\n content: {\n header: [component('HrTeamCalendar-header', 'pageHeader', { title: 'Team calendar', subtitle: 'Who is away and when' }, {\n actions: [withBehaviors(actionButton('HrTeamCalendar-request', 'Request time off', 'primary'), opensDialog('HrRequestTimeOff'))],\n })],\n filters: [component('HrTeamCalendar-filter', 'filterBuilder', { fields: fromQuery(HrQuery.TeamCalendarFilterFields) })],\n calendar: [component('HrTeamCalendar-grid', 'calendarGrid', { label: 'Team calendar', events: fromQuery(HrQuery.TeamCalendarEvents), date: fromQuery(HrQuery.Settings, '0.calendarDay'), urlKey: 'day', ...localeOfData })],\n away: [component('HrTeamCalendar-away', 'dataList', { label: 'Away in this period', rows: fromQuery(HrQuery.TeamCalendarEvents), columns: fromQuery(HrQuery.TeamCalendarColumns), titleField: 'person', pageSize: 6, ...localeOfData })],\n },\n displayName: 'HR team calendar',\n description: 'Who is away and when, on a month, a week or as an agenda, with the kind of leave told in words.',\n metadata: hrMetadata('HrTeamCalendar', 'Calendar', [TemplateScope.Module, TemplateScope.Feature]),\n};\n"],"names":["hrTeamCalendarTemplate","name","fitsSlot","slots","arrangement","root","column","slotLeaf","grid","span","overrides","width","WidthSizeClass","Compact","content","header","component","title","subtitle","actions","withBehaviors","actionButton","opensDialog","filters","fields","fromQuery","HrQuery","TeamCalendarFilterFields","calendar","label","events","TeamCalendarEvents","date","Settings","urlKey","localeOfData","away","rows","columns","TeamCalendarColumns","titleField","pageSize","displayName","description","metadata","hrMetadata","TemplateScope","Module","Feature"],"mappings":";;;;;AAAA;AACA;AAOA;;;;UAKaA,sBAAAA,GAAyC;IAClDC,IAAAA,EAAM,gBAAA;IACNC,QAAAA,EAAU,SAAA;IACVC,KAAAA,EAAO;AAAC,QAAA;YAAEF,IAAAA,EAAM;AAAS,SAAA;AAAG,QAAA;YAAEA,IAAAA,EAAM;AAAU,SAAA;AAAG,QAAA;YAAEA,IAAAA,EAAM;AAAW,SAAA;AAAG,QAAA;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