@dcrackel/hematournamentui 1.0.701 → 1.0.702
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/HemaTournamentUI-lib.es.js +1181 -830
- package/dist/HemaTournamentUI-lib.umd.js +1 -1
- package/dist/hematournamentui-tailwind.css +9 -0
- package/package.json +92 -92
- package/src/stories/Molecules/Buttons/ButtonBar/ButtonBar.vue +1 -1
- package/src/stories/Organisms/Cards/KioskCard/KioskCard.vue +26 -7
- package/src/stories/Organisms/Cards/WaitlistFencerCard/WaitlistFencerCard.vue +129 -0
- package/src/stories/Organisms/Containers/KioskContainer/KioskContainer.vue +13 -9
- package/src/stories/Organisms/Headers/AttendanceSummary/AttendanceSummary.vue +45 -19
- package/src/stories/Templates/EventManagement/EventAttendance/EventAttendance.stories.js +49 -14
- package/src/stories/Templates/EventManagement/EventAttendance/EventAttendance.vue +124 -27
- package/src/stories/Templates/EventManagement/KioskDisplay/KioskDisplay.vue +10 -6
|
@@ -1187,6 +1187,9 @@
|
|
|
1187
1187
|
.min-w-0 {
|
|
1188
1188
|
min-width: calc(var(--spacing) * 0);
|
|
1189
1189
|
}
|
|
1190
|
+
.min-w-20 {
|
|
1191
|
+
min-width: calc(var(--spacing) * 20);
|
|
1192
|
+
}
|
|
1190
1193
|
.min-w-40 {
|
|
1191
1194
|
min-width: calc(var(--spacing) * 40);
|
|
1192
1195
|
}
|
|
@@ -1295,6 +1298,9 @@
|
|
|
1295
1298
|
.flex-row {
|
|
1296
1299
|
flex-direction: row;
|
|
1297
1300
|
}
|
|
1301
|
+
.flex-nowrap {
|
|
1302
|
+
flex-wrap: nowrap;
|
|
1303
|
+
}
|
|
1298
1304
|
.flex-wrap {
|
|
1299
1305
|
flex-wrap: wrap;
|
|
1300
1306
|
}
|
|
@@ -1810,6 +1816,9 @@
|
|
|
1810
1816
|
.pt-6 {
|
|
1811
1817
|
padding-top: calc(var(--spacing) * 6);
|
|
1812
1818
|
}
|
|
1819
|
+
.pt-7 {
|
|
1820
|
+
padding-top: calc(var(--spacing) * 7);
|
|
1821
|
+
}
|
|
1813
1822
|
.pr-2 {
|
|
1814
1823
|
padding-right: calc(var(--spacing) * 2);
|
|
1815
1824
|
}
|
package/package.json
CHANGED
|
@@ -1,92 +1,92 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@dcrackel/hematournamentui",
|
|
3
|
-
"private": false,
|
|
4
|
-
"version": "1.0.
|
|
5
|
-
"type": "module",
|
|
6
|
-
"main": "dist/HemaTournamentUI-lib.umd.js",
|
|
7
|
-
"module": "dist/HemaTournamentUI-lib.es.js",
|
|
8
|
-
"style": "dist/hematournamentui.css",
|
|
9
|
-
"exports": {
|
|
10
|
-
".": {
|
|
11
|
-
"import": "./dist/HemaTournamentUI-lib.es.js",
|
|
12
|
-
"require": "./dist/HemaTournamentUI-lib.umd.js"
|
|
13
|
-
},
|
|
14
|
-
"./styles.css": "./dist/hematournamentui.css",
|
|
15
|
-
"./tailwind.css": "./dist/hematournamentui-tailwind.css"
|
|
16
|
-
},
|
|
17
|
-
"scripts": {
|
|
18
|
-
"dev-donotuse": "vite",
|
|
19
|
-
"build": "npm version patch && vite build && npm run build:package-css",
|
|
20
|
-
"build:package-css": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./dist/hematournamentui-tailwind.css",
|
|
21
|
-
"publish:package": "npm publish",
|
|
22
|
-
"preview": "vite preview",
|
|
23
|
-
"build-storybook": "npm run build:tailwind && storybook build",
|
|
24
|
-
"build:tailwind": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./tailwind/output.css",
|
|
25
|
-
"storybook": "concurrently \"npm run watch:tailwind\" \"npm run watch:storybook\"",
|
|
26
|
-
"watch:storybook": "storybook dev -p 6006",
|
|
27
|
-
"watch:tailwind": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./tailwind/output.css --watch",
|
|
28
|
-
"lint": "eslint --ext .ts,.vue .",
|
|
29
|
-
"test": "vitest",
|
|
30
|
-
"coverage": "vitest run --coverage",
|
|
31
|
-
"postinstall": "patch-package"
|
|
32
|
-
},
|
|
33
|
-
"dependencies": {
|
|
34
|
-
"@fontsource/fira-code": "^5.2.7",
|
|
35
|
-
"@fontsource/inter": "^5.2.8",
|
|
36
|
-
"@fontsource/roboto-mono": "^5.2.9",
|
|
37
|
-
"@storybook/icons": "^2.0.2",
|
|
38
|
-
"@tiptap/extension-bold": "^2.1.13",
|
|
39
|
-
"@tiptap/extension-highlight": "^2.1.13",
|
|
40
|
-
"@tiptap/extension-text-align": "^2.1.13",
|
|
41
|
-
"@tiptap/starter-kit": "^2.1.13",
|
|
42
|
-
"@tiptap/vue-3": "^2.1.13",
|
|
43
|
-
"cropperjs": "^2.1.1",
|
|
44
|
-
"font-awesome": "^4.7.0",
|
|
45
|
-
"glob": "^13.0.6",
|
|
46
|
-
"lru-cache": "^11.3.6",
|
|
47
|
-
"node-fetch": "^3.3.2",
|
|
48
|
-
"postcss-nesting": "^14.0.0",
|
|
49
|
-
"rimraf": "^6.1.3",
|
|
50
|
-
"vue": "^3.5.34",
|
|
51
|
-
"vue-avatar-cropper": "^6.1.1",
|
|
52
|
-
"vue-google-autocomplete": "^1.1.4",
|
|
53
|
-
"vue3-draggable": "^2.0.9",
|
|
54
|
-
"vuedraggable": "^4.1.0"
|
|
55
|
-
},
|
|
56
|
-
"devDependencies": {
|
|
57
|
-
"@babel/eslint-parser": "^7.28.6",
|
|
58
|
-
"@chromatic-com/storybook": "^5.
|
|
59
|
-
"@eslint/eslintrc": "^3.3.5",
|
|
60
|
-
"@storybook/addon-docs": "^10.
|
|
61
|
-
"@storybook/addon-links": "^10.
|
|
62
|
-
"@storybook/react": "^10.
|
|
63
|
-
"@storybook/vue3-vite": "^10.
|
|
64
|
-
"@tailwindcss/cli": "^4.3.0",
|
|
65
|
-
"@tailwindcss/postcss": "^4.3.0",
|
|
66
|
-
"@typescript-eslint/eslint-plugin": "^8.59.3",
|
|
67
|
-
"@typescript-eslint/parser": "^8.59.3",
|
|
68
|
-
"@vitejs/plugin-vue": "^6.0.7",
|
|
69
|
-
"@vitest/coverage-v8": "^4.1.6",
|
|
70
|
-
"@vue/test-utils": "^2.4.10",
|
|
71
|
-
"@vuepic/vue-datepicker": "^12.1.0",
|
|
72
|
-
"autoprefixer": "^10.5.0",
|
|
73
|
-
"concurrently": "^9.2.1",
|
|
74
|
-
"eslint": "^9.9.0",
|
|
75
|
-
"eslint-plugin-jest": "^29.15.2",
|
|
76
|
-
"eslint-plugin-prettier": "^5.5.5",
|
|
77
|
-
"eslint-plugin-storybook": "^10.
|
|
78
|
-
"eslint-plugin-vue": "^10.9.1",
|
|
79
|
-
"happy-dom": "^20.9.0",
|
|
80
|
-
"patch-package": "^8.0.1",
|
|
81
|
-
"postcss": "^8.5.14",
|
|
82
|
-
"storybook": "^10.
|
|
83
|
-
"storybook-vue3-router": "^7.0.0",
|
|
84
|
-
"tailwindcss": "^4.3.0",
|
|
85
|
-
"vite": "^8.0.13",
|
|
86
|
-
"vitest": "^4.1.6",
|
|
87
|
-
"vue-eslint-parser": "^10.4.0"
|
|
88
|
-
},
|
|
89
|
-
"overrides": {
|
|
90
|
-
"@storybook/preview-api": "^9.1.5"
|
|
91
|
-
}
|
|
92
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "@dcrackel/hematournamentui",
|
|
3
|
+
"private": false,
|
|
4
|
+
"version": "1.0.702",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "dist/HemaTournamentUI-lib.umd.js",
|
|
7
|
+
"module": "dist/HemaTournamentUI-lib.es.js",
|
|
8
|
+
"style": "dist/hematournamentui.css",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": {
|
|
11
|
+
"import": "./dist/HemaTournamentUI-lib.es.js",
|
|
12
|
+
"require": "./dist/HemaTournamentUI-lib.umd.js"
|
|
13
|
+
},
|
|
14
|
+
"./styles.css": "./dist/hematournamentui.css",
|
|
15
|
+
"./tailwind.css": "./dist/hematournamentui-tailwind.css"
|
|
16
|
+
},
|
|
17
|
+
"scripts": {
|
|
18
|
+
"dev-donotuse": "vite",
|
|
19
|
+
"build": "npm version patch && vite build && npm run build:package-css",
|
|
20
|
+
"build:package-css": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./dist/hematournamentui-tailwind.css",
|
|
21
|
+
"publish:package": "npm publish",
|
|
22
|
+
"preview": "vite preview",
|
|
23
|
+
"build-storybook": "npm run build:tailwind && storybook build",
|
|
24
|
+
"build:tailwind": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./tailwind/output.css",
|
|
25
|
+
"storybook": "concurrently \"npm run watch:tailwind\" \"npm run watch:storybook\"",
|
|
26
|
+
"watch:storybook": "storybook dev -p 6006",
|
|
27
|
+
"watch:tailwind": "npx @tailwindcss/cli -i ./tailwind/tailwind.css -o ./tailwind/output.css --watch",
|
|
28
|
+
"lint": "eslint --ext .ts,.vue .",
|
|
29
|
+
"test": "vitest",
|
|
30
|
+
"coverage": "vitest run --coverage",
|
|
31
|
+
"postinstall": "patch-package"
|
|
32
|
+
},
|
|
33
|
+
"dependencies": {
|
|
34
|
+
"@fontsource/fira-code": "^5.2.7",
|
|
35
|
+
"@fontsource/inter": "^5.2.8",
|
|
36
|
+
"@fontsource/roboto-mono": "^5.2.9",
|
|
37
|
+
"@storybook/icons": "^2.0.2",
|
|
38
|
+
"@tiptap/extension-bold": "^2.1.13",
|
|
39
|
+
"@tiptap/extension-highlight": "^2.1.13",
|
|
40
|
+
"@tiptap/extension-text-align": "^2.1.13",
|
|
41
|
+
"@tiptap/starter-kit": "^2.1.13",
|
|
42
|
+
"@tiptap/vue-3": "^2.1.13",
|
|
43
|
+
"cropperjs": "^2.1.1",
|
|
44
|
+
"font-awesome": "^4.7.0",
|
|
45
|
+
"glob": "^13.0.6",
|
|
46
|
+
"lru-cache": "^11.3.6",
|
|
47
|
+
"node-fetch": "^3.3.2",
|
|
48
|
+
"postcss-nesting": "^14.0.0",
|
|
49
|
+
"rimraf": "^6.1.3",
|
|
50
|
+
"vue": "^3.5.34",
|
|
51
|
+
"vue-avatar-cropper": "^6.1.1",
|
|
52
|
+
"vue-google-autocomplete": "^1.1.4",
|
|
53
|
+
"vue3-draggable": "^2.0.9",
|
|
54
|
+
"vuedraggable": "^4.1.0"
|
|
55
|
+
},
|
|
56
|
+
"devDependencies": {
|
|
57
|
+
"@babel/eslint-parser": "^7.28.6",
|
|
58
|
+
"@chromatic-com/storybook": "^5.3.0",
|
|
59
|
+
"@eslint/eslintrc": "^3.3.5",
|
|
60
|
+
"@storybook/addon-docs": "^10.5.6",
|
|
61
|
+
"@storybook/addon-links": "^10.5.6",
|
|
62
|
+
"@storybook/react": "^10.5.6",
|
|
63
|
+
"@storybook/vue3-vite": "^10.5.6",
|
|
64
|
+
"@tailwindcss/cli": "^4.3.0",
|
|
65
|
+
"@tailwindcss/postcss": "^4.3.0",
|
|
66
|
+
"@typescript-eslint/eslint-plugin": "^8.59.3",
|
|
67
|
+
"@typescript-eslint/parser": "^8.59.3",
|
|
68
|
+
"@vitejs/plugin-vue": "^6.0.7",
|
|
69
|
+
"@vitest/coverage-v8": "^4.1.6",
|
|
70
|
+
"@vue/test-utils": "^2.4.10",
|
|
71
|
+
"@vuepic/vue-datepicker": "^12.1.0",
|
|
72
|
+
"autoprefixer": "^10.5.0",
|
|
73
|
+
"concurrently": "^9.2.1",
|
|
74
|
+
"eslint": "^9.9.0",
|
|
75
|
+
"eslint-plugin-jest": "^29.15.2",
|
|
76
|
+
"eslint-plugin-prettier": "^5.5.5",
|
|
77
|
+
"eslint-plugin-storybook": "^10.5.6",
|
|
78
|
+
"eslint-plugin-vue": "^10.9.1",
|
|
79
|
+
"happy-dom": "^20.9.0",
|
|
80
|
+
"patch-package": "^8.0.1",
|
|
81
|
+
"postcss": "^8.5.14",
|
|
82
|
+
"storybook": "^10.5.6",
|
|
83
|
+
"storybook-vue3-router": "^7.0.0",
|
|
84
|
+
"tailwindcss": "^4.3.0",
|
|
85
|
+
"vite": "^8.0.13",
|
|
86
|
+
"vitest": "^4.1.6",
|
|
87
|
+
"vue-eslint-parser": "^10.4.0"
|
|
88
|
+
},
|
|
89
|
+
"overrides": {
|
|
90
|
+
"@storybook/preview-api": "^9.1.5"
|
|
91
|
+
}
|
|
92
|
+
}
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
@click="selectButton(button.id)"
|
|
8
8
|
>
|
|
9
9
|
<div
|
|
10
|
-
class="w-20 py-2 transition-all duration-400 ease-in-out border border-dropdownSelect shadow-md"
|
|
10
|
+
class="min-w-20 px-4 py-2 transition-all duration-400 ease-in-out border border-dropdownSelect shadow-md"
|
|
11
11
|
:class="{
|
|
12
12
|
'rounded-l-lg': index === 0,
|
|
13
13
|
'rounded-r-lg': index === buttons.length - 1,
|
|
@@ -49,9 +49,18 @@
|
|
|
49
49
|
width="max-w-56"
|
|
50
50
|
@update:selectedItem="handleEventChange"
|
|
51
51
|
/>
|
|
52
|
-
</div>
|
|
53
|
-
<div class="flex justify-end w-full pr-4">
|
|
54
|
-
<
|
|
52
|
+
</div>
|
|
53
|
+
<div class="flex justify-end w-full pr-4">
|
|
54
|
+
<BaseButton
|
|
55
|
+
v-if="editableKiosk.Type === 'ScoreBoard'"
|
|
56
|
+
:label="isTestMode ? 'Testing' : 'Test'"
|
|
57
|
+
size="xs"
|
|
58
|
+
type="primary"
|
|
59
|
+
:selected="isTestMode"
|
|
60
|
+
class="mr-6 shrink-0"
|
|
61
|
+
@buttonClick="handleScoreboardTest"
|
|
62
|
+
/>
|
|
63
|
+
<ButtonBar
|
|
55
64
|
v-if="userRole !== 'Director'"
|
|
56
65
|
:buttons="typeButtons"
|
|
57
66
|
:selected="editableKiosk.Type || 'Unassigned'"
|
|
@@ -131,7 +140,7 @@ const connectedColorByType = {
|
|
|
131
140
|
export default {
|
|
132
141
|
name: 'KioskCardPC',
|
|
133
142
|
components: { BaseIcon, BaseText, DropDownMenu, ButtonBar, BaseButton },
|
|
134
|
-
emits: ['update:kiosk', 'update:ringChange', 'update:staffChange', 'update:eventChange', 'update:selectedType', 'update:assignToMe', 'update:editKiosk', 'remove:kiosk'],
|
|
143
|
+
emits: ['update:kiosk', 'update:ringChange', 'update:staffChange', 'update:eventChange', 'update:selectedType', 'update:assignToMe', 'update:editKiosk', 'test:scoreboard', 'remove:kiosk'],
|
|
135
144
|
props: {
|
|
136
145
|
displayObject: {
|
|
137
146
|
type: Object,
|
|
@@ -177,7 +186,10 @@ export default {
|
|
|
177
186
|
localSelectedEvent: { text: this.displayObject.Event?.EventName || 'Select Event', link: this.displayObject.Event?.EventId || '' }
|
|
178
187
|
};
|
|
179
188
|
},
|
|
180
|
-
computed: {
|
|
189
|
+
computed: {
|
|
190
|
+
isTestMode() {
|
|
191
|
+
return Boolean(this.displayObject.TestMode);
|
|
192
|
+
},
|
|
181
193
|
getIcon() {
|
|
182
194
|
const iconMap = this.editableKiosk.Connected ? connectedIconByType : disconnectedIconByType;
|
|
183
195
|
return iconMap[this.editableKiosk.Type] || (this.editableKiosk.Connected ? 'fa-wifi-exclamation' : 'fa-wifi-slash');
|
|
@@ -270,8 +282,15 @@ export default {
|
|
|
270
282
|
}
|
|
271
283
|
}
|
|
272
284
|
},
|
|
273
|
-
methods: {
|
|
274
|
-
|
|
285
|
+
methods: {
|
|
286
|
+
handleScoreboardTest() {
|
|
287
|
+
this.$emit('test:scoreboard', {
|
|
288
|
+
...this.displayObject,
|
|
289
|
+
...this.editableKiosk,
|
|
290
|
+
TestMode: !this.isTestMode
|
|
291
|
+
});
|
|
292
|
+
},
|
|
293
|
+
handleRingChange(item) {
|
|
275
294
|
this.localSelectedRing = item;
|
|
276
295
|
this.editableKiosk.DisplayName = item.text;
|
|
277
296
|
this.editableKiosk.AssignedTo = item.link;
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div v-if="person"
|
|
3
|
+
class="flex items-center border border-dropdownSelect rounded-lg shadow-lg bg-poolBox hover:border-bright">
|
|
4
|
+
<div class="hidden md:block mr-4 border-r border-dropdownSelect h-20 w-10 items-center text-center pt-7">
|
|
5
|
+
<BaseText :text="queueLabel" size="md" color="quaternary" weight="bold"/>
|
|
6
|
+
</div>
|
|
7
|
+
<div class="block md:hidden mr-4 border-r border-dropdownSelect h-16 w-5 items-center text-center pt-5">
|
|
8
|
+
<BaseText :text="queueLabel" size="sm" color="quaternary" weight="bold"/>
|
|
9
|
+
</div>
|
|
10
|
+
|
|
11
|
+
<div class="hidden md:block mr-4">
|
|
12
|
+
<div v-if="!portraitURL" class="w-14 h-14 rounded-xl bg-dropdownSelect flex items-center justify-center">
|
|
13
|
+
<BaseText text="" size="sm" color="neutral" weight="bold"/>
|
|
14
|
+
</div>
|
|
15
|
+
<img v-if="portraitURL" :src="portraitURL" alt="Portrait" class="w-14 h-14 rounded-xl">
|
|
16
|
+
</div>
|
|
17
|
+
|
|
18
|
+
<div class="flex flex-col w-3/4 md:w-4/12 justify-start">
|
|
19
|
+
<button class="flex justify-start overflow-hidden text-left" type="button" @click="handleForwardToProfile">
|
|
20
|
+
<BaseText :text="displayName" size="md" color="quaternary" weight="bold" class="text-sm md:text-xl truncate"/>
|
|
21
|
+
</button>
|
|
22
|
+
<span class="w-full flex justify-start">
|
|
23
|
+
<BaseText :text="clubName" size="md" color="quinary" weight="normal" class="hidden md:block"/>
|
|
24
|
+
<BaseText :text="clubShortName" size="xs" color="quinary" weight="normal" class="block md:hidden"/>
|
|
25
|
+
</span>
|
|
26
|
+
|
|
27
|
+
<div class="grid md:hidden grid-cols-2 gap-x-4 mr-10">
|
|
28
|
+
<div class="flex">
|
|
29
|
+
<BaseText text="M2: " size="xs" color="quaternary" weight="normal" class="mr-1"/>
|
|
30
|
+
<BaseText :text="M2Rating" size="xs" color="quinary" weight="bold" class="ml-1"/>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="flex">
|
|
33
|
+
<BaseText text="HR: " size="xs" color="quaternary" weight="normal" class="mr-1"/>
|
|
34
|
+
<BaseText :text="HEMARating" size="xs" color="quinary" weight="bold" class="ml-1"/>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
|
|
39
|
+
<div class="hidden md:grid grid-cols-1 gap-x-4 mr-4 w-36">
|
|
40
|
+
<div class="flex">
|
|
41
|
+
<BaseText text="M2Rating:" size="sm" color="quaternary" weight="normal" class="mr-2"/>
|
|
42
|
+
<BaseText :text="M2Rating" size="sm" color="quinary" weight="bold" class="pt-0.5"/>
|
|
43
|
+
</div>
|
|
44
|
+
<div class="flex">
|
|
45
|
+
<BaseText text="HemaRating:" size="sm" color="quaternary" weight="normal" class="mr-2"/>
|
|
46
|
+
<BaseText :text="HEMARating" size="sm" color="quinary" weight="bold"/>
|
|
47
|
+
</div>
|
|
48
|
+
</div>
|
|
49
|
+
|
|
50
|
+
<div class="mr-2 md:mr-4 md:ml-auto flex flex-row">
|
|
51
|
+
<div class="flex justify-center w-20">
|
|
52
|
+
<div class="hidden md:flex border border-dropdownSelect shadow-md rounded-lg bg-natural h-9 px-3 items-center">
|
|
53
|
+
<BaseText text="Unpaid" size="xs" color="quinary" weight="bold"/>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
<div class="w-44 flex justify-end">
|
|
57
|
+
<BaseButton label="Move to Active" size="xs" type="primary" icon-name="fa-arrow-up-from-bracket"
|
|
58
|
+
class="border border-dropdownSelect shadow-md rounded-l-lg bg-natural w-40 m-0! p-0! h-10"
|
|
59
|
+
@buttonClick="handleMoveToActive"/>
|
|
60
|
+
</div>
|
|
61
|
+
</div>
|
|
62
|
+
|
|
63
|
+
<div
|
|
64
|
+
class="block md:ml-4 border-l border-dropdownSelect h-16 w-9 md:h-20 md:w-10 items-center text-center hover:bg-eventBoxRed rounded-tr-lg rounded-br-lg pt-5 md:pt-6">
|
|
65
|
+
<BaseIcon icon-name="fa-circle-xmark" size="" color="quinary" hover="alarm"
|
|
66
|
+
@click="handleRemoveFencer" class="text-md md:text-2xl"/>
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
</template>
|
|
70
|
+
|
|
71
|
+
<script>
|
|
72
|
+
import BaseIcon from "../../../Atoms/Icon/BaseIcon.vue";
|
|
73
|
+
import BaseText from "../../../Atoms/Text/BaseText.vue";
|
|
74
|
+
import BaseButton from "../../../Molecules/Buttons/BaseButton/BaseButton.vue";
|
|
75
|
+
|
|
76
|
+
export default {
|
|
77
|
+
name: 'WaitlistFencerCard',
|
|
78
|
+
components: {BaseButton, BaseIcon, BaseText},
|
|
79
|
+
emits: ['forward:toProfile', 'move:active', 'remove:fencer'],
|
|
80
|
+
props: {
|
|
81
|
+
person: {
|
|
82
|
+
type: Object,
|
|
83
|
+
required: true
|
|
84
|
+
},
|
|
85
|
+
queuePosition: {
|
|
86
|
+
type: Number,
|
|
87
|
+
required: true
|
|
88
|
+
}
|
|
89
|
+
},
|
|
90
|
+
computed: {
|
|
91
|
+
queueLabel() {
|
|
92
|
+
return `#${this.queuePosition}`;
|
|
93
|
+
},
|
|
94
|
+
displayName() {
|
|
95
|
+
return this.person?.Person?.DisplayName || 'Unknown fencer';
|
|
96
|
+
},
|
|
97
|
+
clubName() {
|
|
98
|
+
return this.person?.Person?.Club?.Name || 'No club listed';
|
|
99
|
+
},
|
|
100
|
+
clubShortName() {
|
|
101
|
+
return this.person?.Person?.Club?.ShortName || this.clubName;
|
|
102
|
+
},
|
|
103
|
+
portraitURL() {
|
|
104
|
+
const images = this.person?.Person?.Images || [];
|
|
105
|
+
const portrait = images.find(image => image.Type === 'Portrait');
|
|
106
|
+
return portrait ? portrait.URL : '';
|
|
107
|
+
},
|
|
108
|
+
HEMARating() {
|
|
109
|
+
const rating = this.person?.Person?.HEMARatings?.[0]?.Rating;
|
|
110
|
+
return rating || 0;
|
|
111
|
+
},
|
|
112
|
+
M2Rating() {
|
|
113
|
+
const rating = this.person?.Person?.M2Ratings?.[0]?.Rating;
|
|
114
|
+
return rating || 'U';
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
methods: {
|
|
118
|
+
handleMoveToActive() {
|
|
119
|
+
this.$emit('move:active', {...this.person});
|
|
120
|
+
},
|
|
121
|
+
handleRemoveFencer() {
|
|
122
|
+
this.$emit('remove:fencer', {...this.person});
|
|
123
|
+
},
|
|
124
|
+
handleForwardToProfile() {
|
|
125
|
+
this.$emit('forward:toProfile', this.person.PersonId);
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
};
|
|
129
|
+
</script>
|
|
@@ -13,9 +13,9 @@
|
|
|
13
13
|
</div>
|
|
14
14
|
</section>
|
|
15
15
|
<section v-if="localDisplays.length > 0" class="flex flex-col">
|
|
16
|
-
<div v-if="scoreboards.length > 0">
|
|
17
|
-
<BaseText text="Scoreboards" size="lg" color="quinary" weight="bold" class="w-full text-left"/>
|
|
18
|
-
<div class="border-b border-dropdownSelect mb-4"/>
|
|
16
|
+
<div v-if="scoreboards.length > 0">
|
|
17
|
+
<BaseText text="Scoreboards" size="lg" color="quinary" weight="bold" class="w-full text-left"/>
|
|
18
|
+
<div class="border-b border-dropdownSelect mb-4"/>
|
|
19
19
|
<div v-for="scoreboard in scoreboards" :key="scoreboard.DisplayId + '-' + scoreboard.Type"
|
|
20
20
|
class="flex flex-col py-2">
|
|
21
21
|
<KioskCard :displayObject="scoreboard"
|
|
@@ -28,9 +28,10 @@
|
|
|
28
28
|
@update:ringChange="handeRingChange"
|
|
29
29
|
@remove:kiosk="handleRemove"
|
|
30
30
|
@update:assignToMe="handleAssignToMe"
|
|
31
|
-
@update:selectedType="handleChangeType"
|
|
32
|
-
@update:editKiosk="handleEditKiosk"
|
|
33
|
-
|
|
31
|
+
@update:selectedType="handleChangeType"
|
|
32
|
+
@update:editKiosk="handleEditKiosk"
|
|
33
|
+
@test:scoreboard="handleScoreboardTest"
|
|
34
|
+
/>
|
|
34
35
|
</div>
|
|
35
36
|
</div>
|
|
36
37
|
|
|
@@ -103,7 +104,7 @@ export default {
|
|
|
103
104
|
BaseText,
|
|
104
105
|
emptyDesertIcon
|
|
105
106
|
},
|
|
106
|
-
emits: ['remove:kiosk', 'update:selectedStaff', 'update:selectedEvent', 'update:ringChange','update:selectedType', 'submit:kiosk', 'update:assignToMe'],
|
|
107
|
+
emits: ['remove:kiosk', 'test:scoreboard', 'update:selectedStaff', 'update:selectedEvent', 'update:ringChange','update:selectedType', 'submit:kiosk', 'update:assignToMe'],
|
|
107
108
|
props: {
|
|
108
109
|
displays: {
|
|
109
110
|
type: Array,
|
|
@@ -158,8 +159,11 @@ export default {
|
|
|
158
159
|
});
|
|
159
160
|
}
|
|
160
161
|
},
|
|
161
|
-
methods: {
|
|
162
|
-
|
|
162
|
+
methods: {
|
|
163
|
+
handleScoreboardTest(display) {
|
|
164
|
+
this.$emit('test:scoreboard', display);
|
|
165
|
+
},
|
|
166
|
+
transformAssignedTo(display) {
|
|
163
167
|
if (display.Person) {
|
|
164
168
|
if (display.Person.DisplayName === 'BYE') {
|
|
165
169
|
return {text: 'Unassigned', link: 'Unassigned'};
|
|
@@ -5,17 +5,19 @@
|
|
|
5
5
|
<BaseText :text="event.RuleSummary" size="" color="quinary" weight="normal" class="text-xs md:text-md" />
|
|
6
6
|
<span class="hidden md:h-8"></span>
|
|
7
7
|
</section>
|
|
8
|
-
<section class="hidden md:flex flex-col">
|
|
9
|
-
<div class="flex justify-center items-center">
|
|
10
|
-
<BaseText text="Fencer Counts" size="sm" color="quinary" />
|
|
11
|
-
</div>
|
|
12
|
-
<div class="flex">
|
|
13
|
-
<EventStatusBox :status-count="absent" status-label="ABSENT" box-color="bg-eventBoxBlue" />
|
|
14
|
-
<EventStatusBox :status-count="present" status-label="PRESENT" box-color="bg-eventBoxGreen" />
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
</
|
|
8
|
+
<section class="hidden md:flex flex-col">
|
|
9
|
+
<div class="flex justify-center items-center">
|
|
10
|
+
<BaseText text="Fencer Counts" size="sm" color="quinary" />
|
|
11
|
+
</div>
|
|
12
|
+
<div class="flex flex-row flex-nowrap">
|
|
13
|
+
<EventStatusBox :status-count="absent" status-label="ABSENT" box-color="bg-eventBoxBlue" />
|
|
14
|
+
<EventStatusBox :status-count="present" status-label="PRESENT" box-color="bg-eventBoxGreen" />
|
|
15
|
+
<EventStatusBox v-if="showRosterCounts" :status-count="activeRosterLabel" status-label="ACTIVE" box-color="bg-eventBoxBlueTwo" />
|
|
16
|
+
<EventStatusBox v-if="showRosterCounts" :status-count="waitlistCount" status-label="WAITLIST" box-color="bg-eventBoxGreenTwo" />
|
|
17
|
+
</div>
|
|
18
|
+
</section>
|
|
19
|
+
</div>
|
|
20
|
+
</template>
|
|
19
21
|
|
|
20
22
|
<script>
|
|
21
23
|
import EventStatusBox from "../../../Molecules/Boxes/EventStatusBox/EventStatusBox.vue";
|
|
@@ -37,11 +39,35 @@ export default {
|
|
|
37
39
|
default: "0",
|
|
38
40
|
required: true,
|
|
39
41
|
},
|
|
40
|
-
present: {
|
|
41
|
-
type: [Number, String],
|
|
42
|
-
default: "0",
|
|
43
|
-
required: true,
|
|
44
|
-
},
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
42
|
+
present: {
|
|
43
|
+
type: [Number, String],
|
|
44
|
+
default: "0",
|
|
45
|
+
required: true,
|
|
46
|
+
},
|
|
47
|
+
activeCount: {
|
|
48
|
+
type: [Number, String],
|
|
49
|
+
default: '',
|
|
50
|
+
},
|
|
51
|
+
waitlistCount: {
|
|
52
|
+
type: [Number, String],
|
|
53
|
+
default: '',
|
|
54
|
+
},
|
|
55
|
+
capacity: {
|
|
56
|
+
type: [Number, String],
|
|
57
|
+
default: '',
|
|
58
|
+
},
|
|
59
|
+
},
|
|
60
|
+
computed: {
|
|
61
|
+
showRosterCounts() {
|
|
62
|
+
return this.activeCount !== '' || this.waitlistCount !== '';
|
|
63
|
+
},
|
|
64
|
+
activeRosterLabel() {
|
|
65
|
+
if (!this.capacity) {
|
|
66
|
+
return this.activeCount;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
return `${this.activeCount}/${this.capacity}`;
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
};
|
|
73
|
+
</script>
|
|
@@ -1,9 +1,35 @@
|
|
|
1
1
|
import EditEvents from './EventAttendance.vue';
|
|
2
|
-
import eventPersonGetEventById from '../../../../mocks/eventpersonGetEventById.js';
|
|
3
|
-
import personsAllMock from '../../../../mocks/personGetAllMock.js';
|
|
4
|
-
import clubsMock from '../../../../mocks/clubGetAllMock.js';
|
|
5
|
-
|
|
6
|
-
|
|
2
|
+
import eventPersonGetEventById from '../../../../mocks/eventpersonGetEventById.js';
|
|
3
|
+
import personsAllMock from '../../../../mocks/personGetAllMock.js';
|
|
4
|
+
import clubsMock from '../../../../mocks/clubGetAllMock.js';
|
|
5
|
+
|
|
6
|
+
const makeEventWithCapacity = (event, capacity) => ({
|
|
7
|
+
...event,
|
|
8
|
+
EventRules: [
|
|
9
|
+
...(event.EventRules || []),
|
|
10
|
+
{
|
|
11
|
+
Rules: {RuleName: 'CutOffNumber'},
|
|
12
|
+
RuleValue: capacity
|
|
13
|
+
}
|
|
14
|
+
]
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
const makeWaitlistPerson = (person, waitlistPosition) => ({
|
|
18
|
+
...person,
|
|
19
|
+
Id: `${person.Id}-waitlist`,
|
|
20
|
+
Status: 'Waitlist',
|
|
21
|
+
WaitlistPosition: waitlistPosition,
|
|
22
|
+
Person: {
|
|
23
|
+
...person.Person,
|
|
24
|
+
PersonId: `${person.Person.PersonId}-waitlist`,
|
|
25
|
+
DisplayName: `${person.Person.DisplayName} WL`
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
|
|
29
|
+
const waitlistedPersons = eventPersonGetEventById.persons.slice(0, 3).map((person, index) => makeWaitlistPerson(person, index + 1));
|
|
30
|
+
const activeRoster = eventPersonGetEventById.persons.slice(3);
|
|
31
|
+
|
|
32
|
+
export default {
|
|
7
33
|
title: 'Templates/EventManagement/EventAttendance',
|
|
8
34
|
component: EditEvents,
|
|
9
35
|
tags: ['autodocs'],
|
|
@@ -67,12 +93,21 @@ export const NoPeople = {
|
|
|
67
93
|
}
|
|
68
94
|
};
|
|
69
95
|
|
|
70
|
-
export const peopleAndLoading = {
|
|
71
|
-
args: {
|
|
72
|
-
personsInTournament: eventPersonGetEventById.persons,
|
|
73
|
-
personsAll: personsAllMock,
|
|
74
|
-
fencingClubs: clubsMock,
|
|
75
|
-
event: eventPersonGetEventById.event,
|
|
76
|
-
loading: true
|
|
77
|
-
}
|
|
78
|
-
};
|
|
96
|
+
export const peopleAndLoading = {
|
|
97
|
+
args: {
|
|
98
|
+
personsInTournament: eventPersonGetEventById.persons,
|
|
99
|
+
personsAll: personsAllMock,
|
|
100
|
+
fencingClubs: clubsMock,
|
|
101
|
+
event: eventPersonGetEventById.event,
|
|
102
|
+
loading: true
|
|
103
|
+
}
|
|
104
|
+
};
|
|
105
|
+
|
|
106
|
+
export const WithWaitlist = {
|
|
107
|
+
args: {
|
|
108
|
+
personsInTournament: [...activeRoster, ...waitlistedPersons],
|
|
109
|
+
personsAll: personsAllMock,
|
|
110
|
+
fencingClubs: clubsMock,
|
|
111
|
+
event: makeEventWithCapacity(eventPersonGetEventById.event, activeRoster.length)
|
|
112
|
+
}
|
|
113
|
+
};
|